Fix ramsey_policy with histval

Since 38152c34a4, the M_.endo_histval variable is
generated via dynamic_set_auxiliary_dseries.m. But the latter file does not
handle auxiliary variables for Lagrange multiplier. We therefore now set them
by hand (at an initial value of zero).
issue#70
Sébastien Villemot 2018-12-20 14:48:41 +01:00
parent 9e66627375
commit a69c65361c
No known key found for this signature in database
GPG Key ID: 2CECE9350ECEBE4A
1 changed files with 2 additions and 2 deletions

View File

@ -358,10 +358,10 @@ HistValStatement::writeOutput(ostream &output, const string &basename, bool mini
output << "%" << endl
<< "% HISTVAL instructions" << endl
<< "%" << endl
<< "M_.histval_dseries = dseries(zeros(M_.orig_maximum_lag_with_diffs_expanded, M_.orig_endo_nbr"
<< "M_.histval_dseries = dseries(zeros(M_.orig_maximum_lag_with_diffs_expanded, M_.orig_endo_nbr+sum([M_.aux_vars.type]==6)"
<< (symbol_table.exo_nbr() > 0 ? "+M_.exo_nbr" : "")
<< (symbol_table.exo_det_nbr() > 0 ? "+M_.exo_det_nbr" : "")
<< "), dates(sprintf('%dY', -M_.orig_maximum_lag_with_diffs_expanded+1)), [ M_.endo_names(1:M_.orig_endo_nbr); "
<< "), dates(sprintf('%dY', -M_.orig_maximum_lag_with_diffs_expanded+1)), [ M_.endo_names(1:M_.orig_endo_nbr); M_.endo_names([M_.aux_vars(find([M_.aux_vars.type]==6)).endo_index]); "
<< (symbol_table.exo_nbr() > 0 ? "M_.exo_names; " : "")
<< (symbol_table.exo_det_nbr() > 0 ? "M_.exo_det_names; " : "")
<< "]);" << endl;