ramsey policy in dynare 4 : Is it a bug?

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.

ramsey policy in dynare 4 : Is it a bug?

Postby sub_macro » Sat Apr 30, 2011 12:30 am

Hi,

I am trying to solve a ramsey policy problem in a closed economy setup.I got the first order conditions and the steady states and I went ahead in coding the problem in Dynare version 4.2.0 (with Matlab version R2010a in windows). However after having finished coding in dynare, when I run the model.mod file which I have written I get the following error message.
Code: Select all
??? Error using ==> lnsrch1 at 53
Some element of Newton direction isn't finite. Jacobian maybe singular or there is a
problem with initial values

Error in ==> solve1 at 127
[x,f,fvec,check]=lnsrch1(xold,fold,g,p,stpmax,func,j1,j2,varargin{:});

Error in ==> dynare_solve at 124
[x,info]=solve1(func,x,j1(r(i):r(i+1)-1),j2(r(i):r(i+1)-1),jacobian_flag,
bad_cond_flag, varargin{:});

Error in ==> dr1 at 124
[oo_.steady_state,info1] = dynare_solve('dyn_ramsey_static_', ...

Error in ==> resol at 145
[dr,info,M_,options_,oo_] = dr1(dr,check_flag,M_,options_,oo_);

Error in ==> stoch_simul at 66
[oo_.dr, info] = resol(oo_.steady_state,0);

Error in ==> ramsey_policy at 25
info = stoch_simul(var_list);

Error in ==> model at 160
ramsey_policy(var_list_);

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



So I decided to write a matlab file called model_steadystate.m to solve the problem. Now when I run the model.mod file again I get the following error message.

Code: Select all
??? Reference to non-existent field 'instruments'.

Error in ==> dr1 at 94
instruments = options_.instruments;

Error in ==> resol at 145
[dr,info,M_,options_,oo_] = dr1(dr,check_flag,M_,options_,oo_);

Error in ==> stoch_simul at 66
[oo_.dr, info] = resol(oo_.steady_state,0);

Error in ==> ramsey_policy at 25
info = stoch_simul(var_list);

Error in ==> model at 160
ramsey_policy(var_list_);

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

I am attaching my model.mod and model_steadystate.m files. My main aim is to get the optimal policy and transition functions and the IRFs. Any help or comment is greatly appreciated. I have a paper to submit within a week, so anyone please help me out!!.
Thanks in advance!!
Attachments
model_steadystate.m
(917 Bytes) Downloaded 179 times
model.mod
(1.49 KiB) Downloaded 232 times
sub_macro
 
Posts: 5
Joined: Wed Apr 27, 2011 5:52 pm

Re: ramsey policy in dynare 4 : Is it a bug?

Postby ripatti » Thu Aug 25, 2011 11:41 am

Hi,

Did you ever solve the problem of non-existent field 'instruments'

Cheers,

Antti
ripatti
 
Posts: 59
Joined: Mon Jan 16, 2006 6:28 am
Location: Helsinki

Re: ramsey policy in dynare 4 : Is it a bug?

Postby SébastienVillemot » Wed Sep 14, 2011 12:49 pm

Hi,
posting.php?mode=reply&f=1&t=3119
The problem comes from the fact that it is not straightforward to write a steady_state file with planner_objective. One has to tell Dynare what endogenous variables will be used as policy instruments.

There is an undocumented "instruments" option for this purpose, and this explains your crash.

We still have to document this option and the procedure of creating a steady_state file with planner_objective. Please wait a little bit. We have a ticket in our issue tracker for that problem:
https://www.dynare.org/trac/ticket/63

Best,
Sébastien Villemot
Economist at OFCE – Sciences Po
SébastienVillemot
 
Posts: 706
Joined: Fri Dec 07, 2007 2:29 pm
Location: Paris, France

Re: ramsey policy in dynare 4 : Is it a bug?

Postby MichelJuillard » Fri Apr 20, 2012 2:09 pm

The 'instruments' option is now documented in the unstable version of Dynare

Dynare takes advantage of the fact that the Lagrange multipliers appear linearly in the equations of the steady state of the model under optimal policy. Nevertheless, it is in general very difficult to compute the steady state with simply a numerical guess in initval for the endogenous variables.

It greatly facilitates the computation, if the user provides an analytical solution for the steady state (in steady_state_model block or in a ..._steadystate.m file). In this case, it is necessary to provide a steady state solution CONDITIONAL on the value of the instruments in the optimal policy problem and declared with option instruments. Note that choosing the instruments is partly a matter of interpretation and you can choose instruments that are handy from a mathematical point of view but different from the instruments you would refer to in the analysis of the paper. Typical example is choosing inflation or nominal interest rate as an instrument.


Best

Michel
MichelJuillard
 
Posts: 680
Joined: Thu Nov 18, 2004 10:51 am

Re: ramsey policy in dynare 4 : Is it a bug?

Postby YHS » Tue May 15, 2012 3:55 pm

I have a question about the steady state values of Lagrangian multipliers under Ramsey policy.

My model is a linear one with the planner's objective being the utility of a representative household (also log-linearised). When I run it under Ramsey policy using Dynare (v.4.2.5 with Matlab R2010a), the steady-state results of all the variables are zero but those of the multipliers are not. It makes sense to me that the ss values of variables are zero (the deviations from steady-state must be zero at ss), but I can't understand why the ss results of the multipliers are non-zero. At the zero-inflation steady-state, I suppose the equilibrium equations would all reduce to zero and hence not binding, and that would result in the multipliers being zero too?

Have I understood anything wrongly? What are the possible reason(s) for non-zero multipliers at the steady-state in a linear model?

Any help would be very much appreciated. Thanks!
YHS
 
Posts: 8
Joined: Fri May 11, 2012 11:41 pm


Return to Dynare help

Who is online

Users browsing this forum: No registered users and 5 guests

cron