Error"The steady state contains NaN or Inf"

Dear Prof. Jpfeifer and Dynare User
My name is Le Thanh Ha.
I am working in the research relating trending inflation, from Ascari paper (2014). I develope the paper from Ireland and use the same idea about the trending inflation as Ascari at el (2014).

I wrote a Dynare code to simulate the completed model .This Dynare code is written based on the Dynare code of Prof. Jpfeifer.
When I run this code the problem come out as below

[code]Residuals of the static equations:

Equation number 1 : NaN
Equation number 2 : NaN
Equation number 3 : NaN
Equation number 4 : 0
Equation number 5 : 0
Equation number 6 : 0
Equation number 7 : 0
Equation number 8 : 0
Equation number 9 : NaN
Equation number 10 : NaN
Equation number 11 : 0
Equation number 12 : NaN
Equation number 13 : NaN
Equation number 14 : 0
Equation number 15 : 0
Equation number 16 : 0
Equation number 17 : 0
Equation number 18 : 0

Error using print_info (line 90)
The steady state contains NaN or Inf[/code]

I spent time checking my computation that derived the stationary nonlinear system, the steady-state system and log-linear system. Everthing is seemingly fine. I guess the problems stemming from the Dynare code I wrote.
Please tell me some ways to help me get around this problem.
I greatly appriciate any help.
Thank you so much

Please focus on

[quote]Warning: Some of the parameters have no value (chi_N, rho_r, bar_i, bar_r, bar_y) when using steady. If these parameters
are not initialized in a steadystate file or a steady_state_model-block, Dynare may not be able to solve the model…
[/quote]

For example, chi_N is never set.

[quote=“jpfeifer”]Please focus on

[quote]Warning: Some of the parameters have no value (chi_N, rho_r, bar_i, bar_r, bar_y) when using steady. If these parameters
are not initialized in a steadystate file or a steady_state_model-block, Dynare may not be able to solve the model…
[/quote]

For example, chi_N is never set.[/quote]

Dear Professor
Thank you Professor for your suggestion. I fix my code following your instruction and the code run quite well.
However, when I attempt to draw the figure corresponding different experiments such as under an impact of monetary shock only (with adjustment of parameters) or technology shock, cost push shock only …, I only see the path of macroeconomic variables under impacts of monetary shock , but not technology or other shock. I also do not know that the figure corresponds which situation.
Please let me know how to draw all necessary figures.
Thank you Professor so much
Best

Your posted mod-file does not run, because chi_N, bar_i, bar_y are still not initialized.

Dear Professor
I am sorry about that. My mistake, because of I am still in process on improving my code that I attached a wrong file.
I have several problems that I need some suggestion from Professor

  1. For nonlinear_Calvo_ir.mod
    I attempt to draw the figure corresponding different experiments such as under an impact of monetary shock only (with adjustment of parameters) or technology shock, cost push shock only …, I only see the path of macroeconomic variables under impacts of monetary shock , but not technology or other shock. I also do not know that the figure corresponds which situation?
    Here, I want to draw all figure immediately corresponding different experiments. If I made mistakes in the code, please tell me how to fix it.

2.For nonlinear_Calvo_m.mod
This figure is quite wierd, Only output responds to the monetary shock (here I assume the money growth rule, instead of the Taylor rule). I do now know where the problems come from.
In order to improve it, you can tell me some ways to make it better?

3.For nonlinear_Rotem_ir

The figure only dictates the respond of macroeconomic variable when the inflation rate is 6%. However, I think that in my code I try to draw with respect to different level of inflation.
Please help me solve this problem.

Thank you Professor so much. I greatly appreciate your kind and support when you always help us solve our problem through the deep and necessary suggestion
Thank you so much
Best

You should not simply copy and paste code without thinking about it.

  1. All graphs are assembled manually using Matlab statements. You yourself need to control which shocks to enable in the shocks-blocks and which to plot.
  2. You copy and pasted ylim-statements that do not even remotely match the size of the IRF