Hi all,

i want to log-linearize a model by Dynare. I calculated the steady state values by hand and wrote the model in terms of exp(log(variable)). Running the file generates always an error.
It would be great if you could help me. thank you
model.mod (2 KB)

When you put

after your initval-command, Dynare shows you the residuals:

Hence, your steady state is incorrect. The reason may be your try to get a loglinearization. Do not put variables as exp(log(x)). Rather, you have to use exp(x) because if in your original model you used x_orig and now you use exp(x), it means that you performed a variable substitution: x=log(x_orig).
But when you use exp(log(x)), exp and log cancel and you are back to x=x_orig. Note also that if a variable is already in logs in the original model (for example if you have shocks that are defined as percentage deviations from steady state), you do not replace them by their logs through putting exp() as you would then get log(log(x)).

Thank you for your hints! I changed the model, as you told me. I also tried writing the error terms not in exp()-form.But i still get an error message, that the steady state values are wrong. i can’t understand that, because i calculated them by hand and the model is very easy. Do you have any idea, where there problem might be?

Could you post the new mod-file? And did you consider that the steady state value of a variable transformed to be in logs has to be the log of the steady state value of the original variable? Moreover, by using the resid(1) command you can look at the residuals of the equations in order to get the steady state one by one. Try starting with the equations for the exogenous processes and work from there to the more complicated ones.

1 Like