# Steady state files for deterministic models

**URL:** <https://forum.dynare.org/t/steady-state-files-for-deterministic-models/2480>\
**Category:** Dynare help (legacy posts)\
**Created:** [20 April 2012 21:00 UTC](https://forum.dynare.org/t/steady-state-files-for-deterministic-models/2480 "2012-04-20T21:00:00Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![boskar](https://forum.dynare.org/user_avatar/forum.dynare.org/boskar/32/6615_2.png) [@boskar](https://forum.dynare.org/u/boskar)\
**Post date:** [20 April 2012 21:00 UTC](https://forum.dynare.org/t/steady-state-files-for-deterministic-models/2480/1 "2012-04-20T21:00:00Z")

</div>

Hi Everyone!  
I would like to study **permanent shock** in my model.  
For the steady state I use /matlab/ steady state file with the same name as model file (model\_steadystate.m). And for temporary shocks there is no problem. Everything works properly.  
But when it comes to permanent shock I use the /steady/ command twice. As I understand the first steady state comes from the /matlab/ file. But how to deliver the second steady state, in the /endval/ block. How to do this externaly like in the case of /initval/ block?  
Unfortunalety I have many endogenous variables in my model and their steady state values are obtained numerically. So writing everything in the /endval/ block is very time consuming and difficult. Is it possible to implement in some way t **wo different steady states** for the /initval/ and /endval/ block?

---

<div class="post-metadata">

**Author:** ![MichelJuillard](https://forum.dynare.org/user_avatar/forum.dynare.org/micheljuillard/32/5318_2.png) [@MichelJuillard](https://forum.dynare.org/u/MichelJuillard)\
**Post date:** [21 April 2012 12:34 UTC](https://forum.dynare.org/t/steady-state-files-for-deterministic-models/2480/2 "2012-04-21T12:34:38Z")

</div>

Look at the attached example. Once you have defined a steady\_state\_model block, you need only to set the value of the exogenous variables in initval and endval. I have not tested it with the old format of a separate \<mod\_filename\>\_steadystate.m file, but I think that it should work as well.  
Please, let me know.

Best

Michel  
[rbc\_det4.mod](https://forum.dynare.org/uploads/default/original/2X/f/fa5ace38fed0e8cc6bf77ef9d1ec51b31590da35.mod) (2.24 KB)

---

<div class="post-metadata">

**Author:** ![boskar](https://forum.dynare.org/user_avatar/forum.dynare.org/boskar/32/6615_2.png) [@boskar](https://forum.dynare.org/u/boskar)\
**Post date:** [22 April 2012 21:43 UTC](https://forum.dynare.org/t/steady-state-files-for-deterministic-models/2480/3 "2012-04-22T21:43:10Z")

</div>

**Thank You very much.** From Your answer I finally have understood what is the idea of getting permanent shocks in /dynare/. I have used this in my case by writing external /matlab/ steady state file where I exploit not only /global M\_/ but also /global oo\_/ calling for the values form the main /dynare/ file with the whole model specification. It is very nice that I didn’t have to write any additional file or change anything in the source files.

Best regards  
Karolina

PS. For anyone interested. Everythings goes similarly like in fs2000ns steadystate.m (in the models folder under UserGuide). So there is:  
k = M\_.params(1); and so on  
but I use also  
epsFE = oo\_.exo\_steady\_state(1); and so on.

---

<div class="post-metadata">

**Author:** ![bpyemba](https://forum.dynare.org/letter_avatar_proxy/v4/letter/b/e5b9ba/32.png) [@bpyemba](https://forum.dynare.org/u/bpyemba)\
**Post date:** [30 April 2013 16:15 UTC](https://forum.dynare.org/t/steady-state-files-for-deterministic-models/2480/4 "2013-04-30T16:15:52Z")

</div>

I am getting that error and I don’t know how to solve it. I have attached my code. Someone can help me?

??? Error using ==\> print\_info at 57  
Impossible to find the steady state. 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

Error in ==\> steady at 92  
print\_info(info,options\_.noprint);

Error in ==\> paper4 at 322  
steady;

Error in ==\> dynare at 120  
evalin(‘base’,fname) ;  
[Paper4.mod](https://forum.dynare.org/uploads/default/original/2X/9/9cdb9c3aae38aafc2c41babd3677688cdc062b5d.mod) (2.98 KB)
