File: ramst_pf_controlled_paths.mod

package info (click to toggle)
dynare 7.0-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 79,248 kB
  • sloc: cpp: 82,011; ansic: 28,583; objc: 12,573; yacc: 5,105; pascal: 2,374; lex: 1,502; python: 1,118; sh: 1,116; makefile: 605; lisp: 162; xml: 18
file content (18 lines) | stat: -rw-r--r-- 644 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// Performs a simulation with a perfect_foresight_controlled_paths block
// with the default stack_solve_algo=0

@#define shocks = true
@#include "ramst_pf_controlled_paths_common.inc"

perfect_foresight_setup(periods=30, first_simulation_period = 2001Y);
perfect_foresight_solver(stack_solve_algo = 0);

if ~oo_.deterministic_simulation.status
   error('Perfect foresight simulation failed')
end

if oo_.endo_simul(1, 3) ~= 1.6 || any(oo_.endo_simul(1, 5:6) ~= 1.7) || any(oo_.endo_simul(2, 8:10) ~= 13) ...
   || any(oo_.endo_simul(3, 4:6) ~= 0.5) || oo_.exo_simul(2, 1) ~= 1.2
   error('Perfect foresight with controlled paths failed')
end