全部版块 我的主页
论坛 经济学论坛 三区 宏观经济学
10964 20
2014-03-29
建了个垄断竞争的模型,放在dynare中运行了一下,结果如下。菜鸟一枚,求大神指点迷津,这是说明什么问题呢?
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 2 with respect to Variable n  (initial value of n: 0)
STEADY:  Derivative of Equation 2 with respect to Variable W  (initial value of W: 0)
STEADY:  Derivative of Equation 7 with respect to Variable W  (initial value of W: 0)
STEADY:  Derivative of Equation 2 with respect to Variable P  (initial value of P: 0)
STEADY:  Derivative of Equation 3 with respect to Variable P  (initial value of P: 0)
STEADY:  Derivative of Equation 4 with respect to Variable P  (initial value of P: 0)
STEADY:  Derivative of Equation 7 with respect to Variable P  (initial value of P: 0)
STEADY:  Derivative of Equation 8 with respect to Variable P  (initial value of P: 0)
STEADY:  Derivative of Equation 9 with respect to Variable P  (initial value of P: 0)
STEADY:  Derivative of Equation 3 with respect to Variable M  (initial value of M: 0)
STEADY:  Derivative of Equation 18 with respect to Variable M  (initial value of M: 0)
STEADY:  Derivative of Equation 3 with respect to Variable pi  (initial value of pi: 0)
STEADY:  Derivative of Equation 10 with respect to Variable pi  (initial value of pi: 0)
STEADY:  Derivative of Equation 13 with respect to Variable pi  (initial value of pi: 0)
STEADY:  Derivative of Equation 6 with respect to Variable K  (initial value of K: 0)
STEADY:  Derivative of Equation 7 with respect to Variable A  (initial value of A: 0)
STEADY:  Derivative of Equation 16 with respect to Variable A  (initial value of A: 0)
STEADY:  Derivative of Equation 8 with respect to Variable MC  (initial value of MC: 0)
STEADY:  Derivative of Equation 9 with respect to Variable MC  (initial value of MC: 0)
STEADY:  Derivative of Equation 10 with respect to Variable MC  (initial value of MC: 0)
STEADY:  Derivative of Equation 8 with respect to Variable y  (initial value of y: 0)
STEADY:  Derivative of Equation 9 with respect to Variable y  (initial value of y: 0)
STEADY:  Derivative of Equation 10 with respect to Variable y  (initial value of y: 0)
STEADY:  Derivative of Equation 13 with respect to Variable y  (initial value of y: 0)
STEADY:  Derivative of Equation 17 with respect to Variable g  (initial value of g: 0)
STEADY:  Derivative of Equation 2 with respect to Variable lam  (initial value of lam: 0)
STEADY:  Derivative of Equation 3 with respect to Variable lam  (initial value of lam: 0)
STEADY:  Derivative of Equation 4 with respect to Variable lam  (initial value of lam: 0)
STEADY:  Derivative of Equation 4 with respect to Variable q  (initial value of q: 0)
STEADY:  Derivative of Equation 4 with respect to Variable Z  (initial value of Z: 0)
STEADY:  Derivative of Equation 7 with respect to Variable Z  (initial value of Z: 0)
STEADY:  Derivative of Equation 1 with respect to Variable z  (initial value of z: 0)
STEADY:  Derivative of Equation 14 with respect to Variable z  (initial value of z: 0)
STEADY:  Derivative of Equation 15 with respect to Variable x  (initial value of x: 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.
Error using dynare_solve (line 60)
An element of the Jacobian is not finite or NaN

二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

全部回复
2014-3-29 19:01:17
已经提示的很清楚了,除0错误,导数不存在。
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2014-3-29 21:37:13
yuanxinqiang 发表于 2014-3-29 19:01
已经提示的很清楚了,除0错误,导数不存在。
谢谢,可就是线性化的模型呀,这种问题如何解决呢?本人小白,请您不吝赐教
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2014-3-29 21:47:08
yuanxinqiang 发表于 2014-3-29 19:01
已经提示的很清楚了,除0错误,导数不存在。
我后来运行了一下手册中的程序(第五章:5.8, p54),可还是有如下问题,这是怎么回事呢?

You did not declare endogenous variables after the estimation/calib_smoother command.
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2014-3-29 22:26:49
没有声明内生变量
用关键词var声明
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2014-3-30 09:45:08
yuanxinqiang 发表于 2014-3-29 22:26
没有声明内生变量
用关键词var声明
我声明了呀,程序如下,能不能帮我看下有什么问题,谢谢
var y c k i l yl w r z;
varexo e;
parameters beta psi delta alpha rho epsilon;
model;
(1/c) = beta*(1/c(+1))*(1+r(+1)-delta);
psi*c/(1-l) = w;
c+i = y;
y = (k(-1)^alpha)*(exp(z)*l)^(1-alpha);
w = y*((epsilon-1)/epsilon)*(1-alpha)/l;
r = y*((epsilon-1)/epsilon)*alpha/k(-1);
i = k-(1-delta)*k(-1);
yl = y/l;
z = rho*z(-1)+e;
end;
varobs y i;
initval;
k = 9;
c = 0.76;
l = 0.3;
w = 2.07;
r = 0.03;
z = 0;
e = 0;
end;
estimated_params;
alpha,beta_pdf,0.35,0.02;
beta,beta_pdf,0.99,0.002;
delta,beta_pdf,0.025,0.003;
psi,gamma_pdf,1.75,0.1;
rho,beta_pdf,0.95,0.05;
epsilon,gamma_pdf,10,0.5;
stderr e,inv_gamma_pdf,0.01,inf;
end;
estimation(datafile=biyelunwen,nobs=200,mh_replic=2000,mh_nblocks=2,mh_drop=0.45,mh_jscale=0.8,
mode_compute=4)y i;
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

点击查看更多内容…
相关推荐
栏目导航
热门文章
推荐文章

说点什么

分享

扫码加好友,拉您进群
各岗位、行业、专业交流群