# An NK-DSGE model problemss

**URL:** <https://forum.dynare.org/t/an-nk-dsge-model-problemss/20188>\
**Category:** Stochastic simulations\
**Created:** [23 April 2022 15:06 UTC](https://forum.dynare.org/t/an-nk-dsge-model-problemss/20188 "2022-04-23T15:06:40Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![ZJL](https://forum.dynare.org/letter_avatar_proxy/v4/letter/z/f475e1/32.png) [@ZJL](https://forum.dynare.org/u/ZJL)\
**Post date:** [23 April 2022 15:06 UTC](https://forum.dynare.org/t/an-nk-dsge-model-problemss/20188/1 "2022-04-23T15:06:40Z")

</div>

Hello, I’ve got a problem when solving an NK-DSGE model, and the error is presented below, and my mod file is  
[COVID.mod](https://forum.dynare.org/uploads/short-url/z07ZzRWV4Cf1cpZBsnMaqjpz5qq.mod) (5.4 KB)  
I’m just stuck with this error for days, and cannot find a solution by myself, need help, thank you!!

There are 8 eigenvalue(s) larger than 1 in modulus  
for 7 forward-looking variable(s)

The rank condition ISN’T verified!

Blanchard & Kahn conditions are not satisfied: no  
stable equilibrium.

---

<div class="post-metadata">

**Author:** ![jpfeifer](https://forum.dynare.org/user_avatar/forum.dynare.org/jpfeifer/32/5044_2.png) [@jpfeifer](https://forum.dynare.org/u/jpfeifer)\
**Post date:** [23 April 2022 15:34 UTC](https://forum.dynare.org/t/an-nk-dsge-model-problemss/20188/2 "2022-04-23T15:34:25Z")

</div>

Have you tried whether a different parameterization works? It may have to do with your fiscal rules. Also `B=0` is quite unusual. What happens if you omit this variable as it will drop out?

---

<div class="post-metadata">

**Author:** ![ZJL](https://forum.dynare.org/letter_avatar_proxy/v4/letter/z/f475e1/32.png) [@ZJL](https://forum.dynare.org/u/ZJL)\
**Post date:** [23 April 2022 16:18 UTC](https://forum.dynare.org/t/an-nk-dsge-model-problemss/20188/3 "2022-04-23T16:18:05Z")

</div>

My parameters were calibrated by real economic data, in order to do a research on a simulation of the real economy. I have calculated the initial values by my self.

At the beginning, the residuals are quite big, so after several change of the initial values, and with the command(steady(maxit = 1000000,tolf = 3e-03,solve\_algo = 1);)I can get the model working now.  
Then I run the command(model\_diagnostics), and it tells me the steady state cannot be computed, and I got the error stated above.

The B=0 is a try when I try to reduce the residuals of the former version (not this one).  
And if I omit B=0, it works too.

---

<div class="post-metadata">

**Author:** ![jpfeifer](https://forum.dynare.org/user_avatar/forum.dynare.org/jpfeifer/32/5044_2.png) [@jpfeifer](https://forum.dynare.org/u/jpfeifer)\
**Post date:** [23 April 2022 17:43 UTC](https://forum.dynare.org/t/an-nk-dsge-model-problemss/20188/4 "2022-04-23T17:43:02Z")

</div>

Then the `B=0` is most likely the problem.

---

<div class="post-metadata">

**Author:** ![ZJL](https://forum.dynare.org/letter_avatar_proxy/v4/letter/z/f475e1/32.png) [@ZJL](https://forum.dynare.org/u/ZJL)\
**Post date:** [24 April 2022 04:50 UTC](https://forum.dynare.org/t/an-nk-dsge-model-problemss/20188/5 "2022-04-24T04:50:56Z")

</div>

I try to omit the B=0, change the model a little bit and still get the same error.

MODEL\_DIAGNOSTICS: The steady state cannot be computed.  
What should I check when it tells me the ss cannot be computed. Should I check the model equations? or other optional settings?

Thanks a lot for your reply!

---

<div class="post-metadata">

**Author:** ![jpfeifer](https://forum.dynare.org/user_avatar/forum.dynare.org/jpfeifer/32/5044_2.png) [@jpfeifer](https://forum.dynare.org/u/jpfeifer)\
**Post date:** [24 April 2022 08:48 UTC](https://forum.dynare.org/t/an-nk-dsge-model-problemss/20188/6 "2022-04-24T08:48:46Z")

</div>

You should put the `model_diagnostics` after your call to steady.

---

<div class="post-metadata">

**Author:** ![ZJL](https://forum.dynare.org/letter_avatar_proxy/v4/letter/z/f475e1/32.png) [@ZJL](https://forum.dynare.org/u/ZJL)\
**Post date:** [2 May 2022 14:27 UTC](https://forum.dynare.org/t/an-nk-dsge-model-problemss/20188/7 "2022-05-02T14:27:57Z")

</div>

Sorry to bother you again  
I’ve modified the model a little bit, and this is the new mod file:  
[COVID1.mod](https://forum.dynare.org/uploads/short-url/9eaovA3EookXjqFNCBqCxUG7Uiq.mod) (4.6 KB)  
But this time the error becomes:  
_Blanchard & Kahn conditions are not satisfied:_  
_indeterminacy._  
_MODEL\_DIAGNOSTICS: No obvious problems with this mod-file were detected._  
What can I do to solve this problem?

---

<div class="post-metadata">

**Author:** ![jpfeifer](https://forum.dynare.org/user_avatar/forum.dynare.org/jpfeifer/32/5044_2.png) [@jpfeifer](https://forum.dynare.org/u/jpfeifer)\
**Post date:** [2 May 2022 20:04 UTC](https://forum.dynare.org/t/an-nk-dsge-model-problemss/20188/8 "2022-05-02T20:04:51Z")

</div>

Most often it’s a timing error, occasionally an issue with the parameters. These problems are usually hard to debug. The generic advice is: try to simplify the model to see where the problem comes from.

---

<div class="post-metadata">

**Author:** ![ZJL](https://forum.dynare.org/letter_avatar_proxy/v4/letter/z/f475e1/32.png) [@ZJL](https://forum.dynare.org/u/ZJL)\
**Post date:** [3 May 2022 12:06 UTC](https://forum.dynare.org/t/an-nk-dsge-model-problemss/20188/9 "2022-05-03T12:06:43Z")

</div>

OK, thank you very much indeed!
