I hope you are doing well. I have been working on solving the following macro model using Dynare. As I am not too familiar with Dynare yet, I was hoping to get some help.

I have the following model file model.mod (2.2 KB) . In order to figure out the initial values, and since I can’t get an analytical solution for the steady state values, I tried to use fsolve to numerically solve for the initial values using fsolve. However, I have not been successful.

Then I tried to use an external steady state file model_steadystate.m (2.1 KB) , by commenting out the initial value in the .mod file. However, I get the following error message:

Error using model.driver
Error: File: driver.m Line: 314 Column: 1
Illegal use of reserved keyword “end”.

Error in dynare (line 293)
evalin(‘base’,[fname ‘.driver’]) ;

My questions are:

what does this error mean? driver.m file seems to be a file that is generated when I run the model.mod file, but I’m not sure why the error is on the generated file.

Is there a good way to find the initial value?

Is there a tutorial for learning how to use the “*_steadystate.m” file to get the initial value?

Your steady state file does not contain valid Matlab code. In Matlab, you cannot define implicit equations like

Lambda-beta;

There needs to be exactly one variable on the left of an equal sign.
2. You are currently using a steady state file. It needs to provide an exact steady state, not initial values.
3. No, as of now we don’t have something like this.

You could try to write a Matlab file to find the steady state following Kenneth Judd’s “Numerical Methods in Economics” book. In chapter 5.6 he defines a procedure that can be used to calculate the steady state.

@DoubleBass Each of the generic procedures boils down to solving a nonlinear equation system. That is what Dynare does automatically. But here it fails, potentially because of a mistake in the model specification.
For reference:

That is the reason why you should help steady state finding by using a sensible analytical approach instead of brute force.

That is true, first approach should always be pen and pencil. But for some models this, out of my limited experience, does not work the whole way. So what I use to do is to solve analytically as far as possible, in order to reduce the system, and then use some kind of solver for the rest to get some guesses for initial values of the system.
Sorry for the confusion.