Page 1 of 1

STEADY: The Jacobian contains Inf or NaN?

PostPosted: Sun Oct 12, 2014 4:07 pm
by zhuzixiang
I simplified the agtrend.mod code written by Sastien Villemot and Johannes Pfeifer and add three shock including the preference shock, interest rate shock and demand shock similar as financial friction model. But I got this result,

STEADY: The Jacobian contains Inf or NaN. The problem arises from:

STEADY: Derivative of Equation 2 with respect to Variable c (initial value of c: 0.551597)
STEADY: Derivative of Equation 2 with respect to Variable l (initial value of l: 0.448813)
STEADY: Derivative of Equation 2 with respect to Variable v (initial value of v: 0)

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.

Could anyone tell me why?
Thanks

Re: STEADY: The Jacobian contains Inf or NaN?

PostPosted: Mon Oct 13, 2014 5:06 am
by jpfeifer
You are having the pathological case with sigma=1, i.e. log utility. This results in 0 divided by 0 in the initval for u. If you want log utility, specify it this way.