Steady state TANK model

Hi everyone. I’m trying to run a TANK model to assess QE policies, but I have some problems with the steady state. When I run the model, some equations have residuals different from zero, as you can see below:

Equation number 26 : 0 : 26
Equation number 27 : -0.0044324 : Omega
Equation number 28 : -0.0029219 : phi
Equation number 29 : -14.8959 : 29
Equation number 30 : 7.2305e-06 : 30
Equation number 31 : 0.0055792 : n

I know that the problem may be related with the variables in equation 29, but I’m strugling to solve. Could somebody please help me.

Thanks.

execute_lr2023.m (7.5 KB)
lr_2023.mod (8.6 KB)

No, you should put resid before steady. You will see

Equation number 9 : 12.0489 : 9
Equation number 10 : -10.2945 : 10
Equation number 11 : 0.022574 : 11
Equation number 12 : -1.2492 : 12

Those are the most problematic ones. Potentially, there is even a problem with the model equations, because the numerical solver yields big residuals in equation 29 when it tries to lower the ones in the other equations