Problem with Code

This forum is closed. You can read the posts but cannot write. We have migrated the forum to a new location where you will have to reset your password.
Forum rules
This forum is closed. You can read the posts but cannot write. We have migrated the forum to a new location (https://forum.dynare.org) where you will have to reset your password.

Problem with Code

Postby despeinada » Wed Apr 17, 2013 7:39 pm

Hi,

I get this error message but i do not know how to solve it:

Configuring Dynare ...
[mex] Generalized QZ.
[mex] Sylvester equation solution.
[mex] Kronecker products.
[mex] Sparse kronecker products.
[mex] Bytecode evaluation.
[mex] k-order perturbation solver.
[mex] k-order solution simulation.

Starting Dynare (version 4.1.1).
Starting preprocessing of the model file ...
Found 14 equation(s).
Evaluating expressions...done
Computing static model derivatives:
- order 1
Computing dynamic model derivatives:
- order 1
- order 2
Processing outputs ...done
Preprocessing completed.
Starting MATLAB/Octave computing.

Warning: Divide by zero.
> In baseline1_static at 61
In resol at 91
In check at 45
In baseline1 at 134
In dynare at 132
Warning: Divide by zero.
> In baseline1_static at 61
In dynare_solve at 70
In resol at 93
In check at 45
In baseline1 at 134
In dynare at 132
Warning: Divide by zero.
> In baseline1_static at 114
In dynare_solve at 70
In resol at 93
In check at 45
In baseline1 at 134
In dynare at 132
Warning: Divide by zero.
> In baseline1_static at 115
In dynare_solve at 70
In resol at 93
In check at 45
In baseline1 at 134
In dynare at 132
Warning: Divide by zero.
> In baseline1_static at 116
In dynare_solve at 70
In resol at 93
In check at 45
In baseline1 at 134
In dynare at 132
STEADY: numerical initial values incompatible with the following equations
3 7 13

??? Error using ==> dynare_solve
exiting ...

Error in ==> resol at 93
[dr.ys,check1] = dynare_solve(fh,dr.ys,options_.jacobian_flag,...

Error in ==> check at 45
[dr, info] = resol(oo_.steady_state,1);

Error in ==> baseline1 at 134
check;

Error in ==> dynare at 132
evalin('base',fname) ;

Thanks in advance for your time and help. Best,
Attachments
baseline1.mod
(1.43 KiB) Downloaded 182 times
despeinada
 
Posts: 3
Joined: Wed Apr 17, 2013 7:33 pm

Re: Problem with Code

Postby fabiover » Thu Apr 18, 2013 5:40 pm

I run your code with Dynare 4.3.2 and got the following message:


STEADY: numerical initial values or parameters incompatible with the following equations
3 7 13

Please check for example
i) if all parameters occurring in these equations are defined
ii) that no division by an endogenous variable initialized to 0 occurs
Fabio Verona
Research Economist
Monetary Policy and Research Department
BANK OF FINLAND
Snellmaninaukio, Helsinki
PO Box 160, FI-00101 HELSINKI, FINLAND
phone +358 10 831 2464
www.bof.fi
http://fabioverona.rvsteam.net/
fabiover
 
Posts: 9
Joined: Wed Sep 26, 2012 10:10 am
Location: Helsinki

Re: Problem with Code

Postby despeinada » Fri Apr 19, 2013 5:28 am

thanks a lot for your reply. I have checked and there are no undefined parameterns but equation 13 could be the problem becuase it may yield the division by zero. I set initval of bu=1 and bs=1, but still gives me problems...
Attachments
baseline1.mod
(1.47 KiB) Downloaded 171 times
despeinada
 
Posts: 3
Joined: Wed Apr 17, 2013 7:33 pm

Re: Problem with Code

Postby jpfeifer » Sat Apr 20, 2013 7:53 am

You have for example k^(alpha-1) in equation 3. As the exponent is smaller than 0, this is equal 1/(k^(1-alpha)) which is 1/0. Please provide initial values for all variables. If a variable cannot be 0, set a small positive initval.
------------
Johannes Pfeifer
University of Cologne
https://sites.google.com/site/pfeiferecon/
jpfeifer
 
Posts: 6940
Joined: Sun Feb 21, 2010 4:02 pm
Location: Cologne, Germany

Re: Problem with Code

Postby despeinada » Sun Apr 21, 2013 8:58 am

thanks a lot! i will try to give all variables an intial value...
despeinada
 
Posts: 3
Joined: Wed Apr 17, 2013 7:33 pm


Return to Dynare contributions and examples

Who is online

Users browsing this forum: No registered users and 2 guests