Second order linearization does not generate IRFS

cg_utility_Passive_Wel.mod (7.7 KB)

Hello, I am trying to calculate the welfare cost for a New-Keynesian model. For this I take the 2nd order approximation. But the stoch_simul (order =2) does not generate the IRFs (NaN). If I take the first order approximation stoch_simul (order =1), then it generates the IRFS. Any idea why it is the case and what is the solution? I have attached the mod file.

If you want to generate GIRFs at higher order, you need to use pruning.

Thanks a lot Dr. Pfeifer for the help! It works!