# Error Message in obtaining steady state in Dynare

**URL:** <https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857>\
**Category:** Steady state\
**Created:** [11 April 2021 08:47 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857 "2021-04-11T08:47:48Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![MJallow](https://forum.dynare.org/letter_avatar_proxy/v4/letter/m/e480ec/32.png) [@MJallow](https://forum.dynare.org/u/MJallow)\
**Post date:** [11 April 2021 08:47 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/1 "2021-04-11T08:47:49Z")

</div>

I am not able to abtain the sstate for my model. this is the error message i get:

Error using print\_info (line 32)  
Impossible to find the steady state (the sum of square residuals of the static equations is 14.4437). Either the model  
doesn’t have a steady state, there are an infinity of steady states, or the guess values are too far from the solution.

Could someone help

---

<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:** [11 April 2021 08:56 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/2 "2021-04-11T08:56:59Z")

</div>

Without the mod-file, further diagnostics are impossible.

---

<div class="post-metadata">

**Author:** ![MJallow](https://forum.dynare.org/letter_avatar_proxy/v4/letter/m/e480ec/32.png) [@MJallow](https://forum.dynare.org/u/MJallow)\
**Post date:** [11 April 2021 09:28 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/3 "2021-04-11T09:28:15Z")

</div>

[dsge1.mod](https://forum.dynare.org/uploads/short-url/1erlnBrAomg4UIZJDJKNUCTtEcX.mod) (1.8 KB)

this is my model

---

<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:** [11 April 2021 09:44 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/4 "2021-04-11T09:44:33Z")

</div>

Check your model. For example,

```auto
              y_t = exp(x)*(k_t)^cf1 *(lab_t)^1-cf1;

```

is missing brackets for the exponent.

---

<div class="post-metadata">

**Author:** ![MJallow](https://forum.dynare.org/letter_avatar_proxy/v4/letter/m/e480ec/32.png) [@MJallow](https://forum.dynare.org/u/MJallow)\
**Post date:** [11 April 2021 10:16 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/5 "2021-04-11T10:16:03Z")

</div>

Thank you. checked and adjusted the model but still getting the same error message

---

<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:** [11 April 2021 14:13 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/6 "2021-04-11T14:13:03Z")

</div>

Always provide the most recent version.

---

<div class="post-metadata">

**Author:** ![MJallow](https://forum.dynare.org/letter_avatar_proxy/v4/letter/m/e480ec/32.png) [@MJallow](https://forum.dynare.org/u/MJallow)\
**Post date:** [11 April 2021 14:16 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/7 "2021-04-11T14:16:50Z")

</div>

[dsge1.mod](https://forum.dynare.org/uploads/short-url/bwxV2USQINkmKL2CSJKKn6oq6eN.mod) (1.8 KB)

here is the updated version

---

<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:** [12 April 2021 08:11 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/8 "2021-04-12T08:11:35Z")

</div>

From what I can see

```auto
                m = m(-1) + e*(t-u)*exp(q);
              i_r = i_r(-1) + (1-u)*exp(q);

```

implies two unit roots in your model. Thus, there are infinitely many steady states and you cannot let Dynare compute one endogenously. You need to provide one.

---

<div class="post-metadata">

**Author:** ![MJallow](https://forum.dynare.org/letter_avatar_proxy/v4/letter/m/e480ec/32.png) [@MJallow](https://forum.dynare.org/u/MJallow)\
**Post date:** [15 April 2021 10:43 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/9 "2021-04-15T10:43:36Z")

</div>

Thanks…any suggestions as to how to go about that.

---

<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:** [15 April 2021 17:01 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/10 "2021-04-15T17:01:19Z")

</div>

Either get rid of the unit roots or compute the steady state with pencil and paper.

---

<div class="post-metadata">

**Author:** ![MJallow](https://forum.dynare.org/letter_avatar_proxy/v4/letter/m/e480ec/32.png) [@MJallow](https://forum.dynare.org/u/MJallow)\
**Post date:** [19 April 2021 11:35 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/11 "2021-04-19T11:35:05Z")

</div>

[dsge1.mod](https://forum.dynare.org/uploads/short-url/qgyR32nCWjA0beJa6IwQJxwanxC.mod) (1.6 KB) [dsge1\_steadystate.m](https://forum.dynare.org/uploads/short-url/ttknjAGP6Mng9S8tdkzPbbQ5pFo.m) (4.0 KB)

Thank you for your time.

I have obtain the steady state analytically and written a steady state file. However, i get an error message of of variables not declare while all variables are indeed declared.

I have also tried providing a steady state model block within the dynare script but it gives me the same error of variables not declared.

I also removed the unit roots but still couldn’t work either

---

<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:** [19 April 2021 18:19 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/12 "2021-04-19T18:19:27Z")

</div>

Your steady state file does not contain a valid computation. For example

```auto
1-ca1/((p_n)*(c_n)= ca1/(e)*(c_t);

```

is not a proper Matlab assignment. You cannot use implicit definitions.

---

<div class="post-metadata">

**Author:** ![MJallow](https://forum.dynare.org/letter_avatar_proxy/v4/letter/m/e480ec/32.png) [@MJallow](https://forum.dynare.org/u/MJallow)\
**Post date:** [27 April 2021 13:35 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/13 "2021-04-27T13:35:48Z")

</div>

Thank you for your help. I was able to obtain the steady state after rewriting the explicit definitions. I have attached file for you to see if the steady states are correctly computed.

Apart from that I have the following questions:

1. I want to normalized some variables to one at SS so that i can track the changes. How can i do this on dynare.

2. I have 3 shocks q,t u. I will only apply shock on q while t and u will take the values of 1 and zero at SS. I know how to apply shock on q but where can i place the t and u such that they will carry the assigned values.

Thanks once again  
[ds1.mod](https://forum.dynare.org/uploads/short-url/xgkClhRtZxFPxRw3bDr3dwmPIaZ.mod) (2.8 KB)

---

<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:** [28 April 2021 07:08 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/14 "2021-04-28T07:08:38Z")

</div>

1. What do you mean with normalize?
2. You need to specify a `shocks`- block.

---

<div class="post-metadata">

**Author:** ![MJallow](https://forum.dynare.org/letter_avatar_proxy/v4/letter/m/e480ec/32.png) [@MJallow](https://forum.dynare.org/u/MJallow)\
**Post date:** [28 April 2021 10:51 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/15 "2021-04-28T10:51:34Z")

</div>

1. I want the value of some key variables e.g y, c, p etc to be equal to one in the prior steady state. This will enable me track the changes once i introduce the shock.

Thank you

---

<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:** [28 April 2021 11:31 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/16 "2021-04-28T11:31:33Z")

</div>

This requires introducing normalizing constants.

---

<div class="post-metadata">

**Author:** ![MJallow](https://forum.dynare.org/letter_avatar_proxy/v4/letter/m/e480ec/32.png) [@MJallow](https://forum.dynare.org/u/MJallow)\
**Post date:** [1 May 2021 12:29 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/17 "2021-05-01T12:29:00Z")

</div>

Any suggestion or reference on how to go about introducing normalizing constants.

Also from the mod file above, can i take the first SS as the prior SS and the second as the posterior SS.

---

<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 2021 12:09 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/18 "2021-05-02T12:09:07Z")

</div>

Is that even necessary? Can’t you simply express the Variables as a fraction of the initial steady state?

---

<div class="post-metadata">

**Author:** ![MJallow](https://forum.dynare.org/letter_avatar_proxy/v4/letter/m/e480ec/32.png) [@MJallow](https://forum.dynare.org/u/MJallow)\
**Post date:** [2 May 2021 12:36 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/19 "2021-05-02T12:36:45Z")

</div>

How do you mean specifically?

---

<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:** [3 May 2021 17:45 UTC](https://forum.dynare.org/t/error-message-in-obtaining-steady-state-in-dynare/17857/20 "2021-05-03T17:45:46Z")

</div>

The first entry of the simulated series will be the old steady state. So you can divide all series by this value to obtain ratios.
