Skip to content
Snippets Groups Projects
Commit 9bdf75a5 authored by Stéphane Adjemian's avatar Stéphane Adjemian
Browse files

Fixed bug in the initialization of the homotopy for perfect foresight models.

parent 402a8263
Branches
Tags
No related merge requests found
......@@ -111,7 +111,7 @@ if ~oo_.deterministic_simulation.status && ~options_.no_homotopy
path_with_nans = any(any(isnan(oo_.endo_simul)));
path_with_cplx = any(any(~isreal(oo_.endo_simul)));
if isequal(iteration,1) && (path_with_nans || path_with_cplx)
if isequal(iteration,1)
oo_.endo_simul(:,M_.maximum_lag+1:end-M_.maximum_lead) = endoinit(:,1:options_.periods);
elseif path_with_nans || path_with_cplx
oo_.endo_simul(:,M_.maximum_lag+1:end-M_.maximum_lead) = saved_endo_simul(:,1+M_.maximum_endo_lag:end-M_.maximum_endo_lead);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment