Page 1 of 1

An element of the Jacobian is not finite or NaN

PostPosted: Sat Jun 24, 2017 1:59 pm
by azeem
I have been trying to code for the first time in Dynare. However I am getting this error message. Please help.
STEADY: The Jacobian contains Inf or NaN. The problem arises from:

STEADY: Derivative of Equation 1 with respect to Variable c (initial value of c: 0)
STEADY: Derivative of Equation 8 with respect to Variable z (initial value of z: 1)
STEADY: Derivative of Equation 2 with respect to Variable k (initial value of k: 0)
STEADY: Derivative of Equation 5 with respect to Variable k (initial value of k: 0)
STEADY: Derivative of Equation 6 with respect to Variable k (initial value of k: 0)
STEADY: Derivative of Equation 8 with respect to Variable k (initial value of k: 0)
STEADY: Derivative of Equation 5 with respect to Variable i (initial value of i: 0)
STEADY: Derivative of Equation 8 with respect to Variable i (initial value of i: 0)
STEADY: Derivative of Equation 7 with respect to Variable r (initial value of r: 1.0101)
STEADY: Derivative of Equation 8 with respect to Variable q (initial value of q: 1)

STEADY: The problem most often occurs, because a variable with
STEADY: exponent smaller than 1 has been initialized to 0. Taking the derivative
STEADY: and evaluating it at the steady state then results in a division by 0.
Error using dynare_solve (line 60)
An element of the Jacobian is not finite or NaN
Error in evaluate_steady_state (line 66)
[ys,check] = dynare_solve([M.fname '_static'],...
Error in steady_ (line 54)
[steady_state,params,info] = evaluate_steady_state(oo_.steady_state,M_,options_,oo_,~options_.steadystate.nocheck);
Error in steady (line 81)
[steady_state,M_.params,info] = steady_(M_,options_,oo_);
Error in SOE3 (line 207)
steady;
Error in dynare (line 180)
evalin('base',fname) ;

Re: An element of the Jacobian is not finite or NaN

PostPosted: Sat Jun 24, 2017 3:43 pm
by chenp2002
i have the same problem,i also do not know how to fix it.

Re: An element of the Jacobian is not finite or NaN

PostPosted: Mon Jun 26, 2017 6:09 pm
by jpfeifer
The problem was that in the initval block k is used before it is defined/set.

Re: An element of the Jacobian is not finite or NaN

PostPosted: Tue Jun 27, 2017 2:15 am
by chenp2002
hi,professor jpfeifer
thanks for your reponse,so how to handle with the var k?

Re: An element of the Jacobian is not finite or NaN

PostPosted: Tue Jun 27, 2017 4:17 pm
by jpfeifer
Your model may be different. So please provide the file. My reply referred to @azeem's file.