Unexpected behaviour of the deterministic shock

Dear all,

I am trying to simulate a deterministic model with a dummy variable (i.e DUM) that switches the fiscal policy from a decifit-rule to a debt-rule, from a certain period onward. i.e.:


The dummy variable, DUM, is declared as an exogenous variable which is set to 1 for the first 100 periods, and then to 0 until steady-state. For this purpose, I am using the shocks block, ie.:

var DUM;
periods 1:100 101:1000;
values 1 0;

However, when simulating it, I can see from the oo_.exo_simul that the variable of the DUM is taking a value of 0.5964 for the first 100 periods and not of 1. Could you explain me why this is?
I am using Dynare version 4.6.1 and I attach the .mod file.
CBO_Deficit_calibrated.mod (6.2 KB)

I cannot run your file due to k0 not being defined.

I attach the updated .mod file with the vars properly initialized - it should run with no issues.

Many thanks in advance, Professor Pfeifer.
CBO_Deficit_calibrated.mod (6.2 KB)

The setup is correct. But you are taking a look at oo_.exo_simul after perfect_foresight_solver failed. In that case, the contents are at the last unsuccessful step of homotopy.