// Woodford "Control of Public Debt: A requirement for price stability?" // Basic simulation - Does not seem to work var m, i, x, ex, p, d, q, e, eta; varexo u, eps; parameters chi,sigma, beta, kappa, lambda, gamma, phi_1, phi_2, phi_3 , rhoe, rhop, a, b, c; chi = 1; sigma = 1; beta = 0.95; kappa = 0.3; lambda = 0.8; gamma = 0.1; rhoe = 0.99; rhop = 0.00; phi_1 = 0.1; phi_2 = 0.5; phi_3 = 0.5; a = 0.5; b = 1.5; c = 0; model; x = ex - sigma*(i - p(+1))+0.1*d + phi_1*q; ex = x(+1)+ e; p = beta*p(+1) + kappa*x - eta; q = q(+1)- phi_2*(i - p(+1))+ phi_3*x; d(+1) = i + (beta^-1)*(d-p)+gamma*(m(-1)-m-p); m = chi*((sigma^-1)*x-(beta/(1-beta))*i); i = a*x + b*p + c*q; e = rhoe*e(-1) + u; eta = rhop*eta(-1)+ eps; end; initval; m = 0; i = 0; p = 0; x = 0; d = 0; q = 0; e = 0; eta = 0; end; shocks; var u; stderr 0.09; var eps; stderr 0.09; end; stoch_simul(periods=210, irf=20);