Steady States

Hello, i’m having a problem how to calculate and implement the steady state values of the endogenous variables from the non-linear model to the equations of the **log-linearized model **in the model block. What is the best way to calculate these steady state values of the non linear model and plug them in the equations of the log linearized model. I know of a few possibilities of doing so:

  1. write the steady state values of the endogenous variables as parameters and then write the steady state relationships in a recursive way. I have tried this but get the following error message:
    STEADY: numerical initial values incompatible with the following equations
    4 6 7
    Plus I get NAN value for 3 of the steady state variables (defined as parameters). What is the best way to overcome this problem ? Could it be because I have a non-linear relationship in one of the equations which cannot be solved without an initial guess ? If so, what should I specifically do in this case ?

  2. write a matlab seperate file and use fsolve to calculate the steady state values. However, if i define for example mcss as the steady state value of mc, how does dynare / matlab recognize that this is indeed the steady state value? I’ve got a steady state equation for mcss which relates to other steady state values of endogenous variables. Moreover, my model equations (linear) depend on these steady state values (mcss, iLss etc…) so how do I programme the mod file to take these values for these equations ?

Any suggestions and help would be very much appreciated, thank you !

I’m not sure I fully understand the question, but for (2), you can include terms like steady_state(mc) in your model. So you can have an equation like
y(t)=gamma*(mc(t)-steady_state(mc))+beta*x(t+1). Hope this helps.

Solution 1) is not directly implementable in Dynare using a single MOD file. With some programming it is possible to do it using two MOD files: one for computing the steady state and saving it in a MAT file, the other one loading the MAT file, assigning values to the parameters and running the simulation.

Solution 2) is the simplest way to go. Declare mcss as a parameter, and assign the result of your function to it.