Dear all

Could anybody please tell me why my code doesn’t work? The model is as follows:

model;

(1/b)*((a*c^b+(1-a)*m^b)^((1/b)-1))*(a*b*c^(b-1)) = beta*(1/b)*(((a*(c(+1))^b)+(1-a)*(m(+1))^b)^((1/b)-1))*(a*b*(c(+1))^(b-1))*(alpha*((k)^(alpha-1))+1-delta);

((1-a)/a)*((c/m)^(1-b)) = i;
r = alpha*(k(-1)^(alpha-1))-delta;

i = r + pi;

m=((1+x)/(1+pi(-1)))*m(-1);

c+inv = y;

y = (k(-1)^alpha);

inv= k-(1-delta)*k(-1);

x = exp(g)-1;

g=u;

end;

It is a Sidrauski model without labor, with CES utility function between consumption and money balances, in order to analyse monetary shocks.

It is really weird, with b=2 (the “rho” in CES) the model works fine, but theoretically we require b<1. For any other parameter velue the model won’t give something good. An example of the errors is

??? Error using ==> print_info

Blanchard Kahn conditions are not satisfied: no stable equilibrium

Error in ==> stoch_simul at 49

print_info(info);

Error in ==> ra at 133

info=stoch_simul(var_list_);

Error in ==> dynare at 26

evalin(‘base’,fname) ;

for b=.5. For b=1.5 I get

??? Error using ==> reshape

To RESHAPE the number of elements must not change.

Error in ==> th_autocovariances at 158

Gamma_y{1} = reshape(imathp_col(1,:),nvar,nvar);

Error in ==> disp_th_moments at 33

[Gamma_y,ivar] = th_autocovariances(dr,ivar);

Error in ==> stoch_simul at 74

disp_th_moments(dr_,var_list);

Error in ==> ra at 133

info=stoch_simul(var_list_);

Error in ==> dynare at 26

evalin(‘base’,fname) ;

Thanks for helping me out. I am desperate !!

Jean Paul

ps: code attached

ra.mod (1.83 KB)