* * CASSKOOPMANS.RPF * RATS Version 8, Reference Manual, Example from DSGE * dec series c lambda k dec real u0 u1 f0 beta * frml(identity) f1 = u0-u1*c-lambda frml(identity) f2 = f0*lambda-1.0/beta*lambda{1} frml(identity) f3 = f0*k{1}-k-c{1} * * Set parameters of the model * compute beta=.95,f0=1.3,u0=1.0,u1=0.2 * group casskoopmans f1 f2 f3 * * Because the model is linear, there's no need to compute an expansion * point to get the state space representation; it's being done here to * get the steady state so create the simulation scenarios. * dsge(expand=linear,steadystate=ss,a=a,z=z,model=casskoopmans) c k lambda disp "Steady State" disp "Consumption" @20 ss(1) disp "Capital" @20 ss(2) * * Starting consumption below the steady state * dlm(x0=||3.0,17.0,u0-u1*3.0||,a=a,z=z,presample=x1) 1 20 xstates set c 1 20 = xstates(t)(1) set k 1 20 = xstates(t)(2) spgraph(vfields=2,footer="Initial consumption below steady state") graph(hlabel="Consumption") # c graph(hlabel="Capital") # k spgraph(done) * * Starting consumption above the steady state * dlm(x0=||6.0,17.0,u0-u1*6.0||,a=a,z=z,presample=x1) 1 20 xstates set c 1 20 = xstates(t)(1) set k 1 20 = xstates(t)(2) spgraph(vfields=2,footer="Initial consumption above steady state") graph(hlabel="Consumption") # c graph(hlabel="Capital") # k spgraph(done) * * Initial capital above the steady state * dlm(x0=||5.0,20.0,u0-u1*3.0||,a=a,z=z,presample=x1) 1 20 xstates set c 1 20 = xstates(t)(1) set k 1 20 = xstates(t)(2) spgraph(vfields=2,footer="Initial capital above steady state") graph(hlabel="Consumption") # c graph(hlabel="Capital") # k spgraph(done)