* Changed verbose mode in extended_path.m

* Fixed  the evaluation of  the distance  to the  deterministic steady
  state in perfect_foresight_simulation.m (when options_.terminal_condition==2).


git-svn-id: https://www.dynare.org/svn/dynare/trunk@3299 ac1d8469-bf42-47a9-8791-bf33cf982152
time-shift
stepan 2010-01-04 10:35:11 +00:00
parent 9b3718b50f
commit a86149657e
2 changed files with 8 additions and 5 deletions

View File

@ -104,8 +104,9 @@ for t=1:sample_size
end
time = info.time;
if verbose
t
[t,options_.periods]
info
info.iterations
end
if ~info.convergence
info = homotopic_steps(tdx,positive_var_indx,shocks,norme,.5,init);

View File

@ -166,10 +166,12 @@ for iter = 1:options_.maxit_
end
end
if options_.terminal_condition==2
distance_to_steady_state = abs(((oo_.endo_simul(:,end-1)-oo_.endo_simul(:,end))./oo_.endo_simul(:,end)))*100;
disp('Distance to steady state at the end is (in percentage):')
distance_to_steady_state
if stop && options_.terminal_condition==2
% Compute the distance to the deterministic steady state (for the subset of endogenous variables with a non zero
% steady state) at the last perdiod.
idx = find(abs(oo_.steady_state)>0);
distance_to_steady_state = abs(((oo_.endo_simul(idx,end)-oo_.steady_state(idx))./oo_.steady_state(idx)))*100;
disp(['(max) Distance to steady state at the end is (in percentage):' num2str(max(distance_to_steady_state))])
end
if ~stop