From 2e211f486c9d0df36f6e92dc6b78a90baf85e17e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?S=C3=A9bastien=20Villemot?= <sebastien@dynare.org>
Date: Wed, 14 Jun 2023 19:14:07 +0200
Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20Steady=20state:=20wrong=20value?=
 =?UTF-8?q?=20of=20maxit=20was=20used=20for=20some=20block/bytecode=20case?=
 =?UTF-8?q?s?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

It was using the value of maxit for perfect foresight simulations.

(manually cherry picked from commit 30c17ad346dcac307ad5061dee96b04072c8fb0b)
---
 matlab/dynare_solve_block_or_bytecode.m | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/matlab/dynare_solve_block_or_bytecode.m b/matlab/dynare_solve_block_or_bytecode.m
index ca5125ac3c..f2213409e7 100644
--- a/matlab/dynare_solve_block_or_bytecode.m
+++ b/matlab/dynare_solve_block_or_bytecode.m
@@ -38,7 +38,7 @@ if options.block && ~options.bytecode
             else
                 n = length(M.block_structure_stat.block(b).variable);
                 [ss, T, ~, check] = solve_one_boundary([M.fname '.static' ], ss, exo, ...
-                                                       params, [], T, M.block_structure_stat.block(b).variable, n, 1, false, b, 0, options.simul.maxit, ...
+                                                       params, [], T, M.block_structure_stat.block(b).variable, n, 1, false, b, 0, options.steady.maxit, ...
                                                        options.solve_tolf, ...
                                                        options.slowc, 0, options.solve_algo, true, false, false, M, options, []);
                 if check
-- 
GitLab