# Problem with running Dynare

**URL:** <https://forum.dynare.org/t/problem-with-running-dynare/2604>\
**Category:** Dynare help (legacy posts)\
**Created:** [30 June 2012 20:19 UTC](https://forum.dynare.org/t/problem-with-running-dynare/2604 "2012-06-30T20:19:33Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![shako](https://forum.dynare.org/letter_avatar_proxy/v4/letter/s/c2a13f/32.png) [@shako](https://forum.dynare.org/u/shako)\
**Post date:** [30 June 2012 20:19 UTC](https://forum.dynare.org/t/problem-with-running-dynare/2604/1 "2012-06-30T20:19:33Z")

</div>

Hello guys,  
I’m getting some error message while executing the MOD file.  
I have installed GNU Octave version 3.4.0 and Dynare version 4.3.0 for Mac OS X.  
Here is the error I get:

[quote]  
octave-3.4.0:9\> addpath /Applications/Dynare/4.3.0/matlab  
octave-3.4.0:16\> dynare NK\_GM05.mod

Configuring Dynare …  
[mex] Generalized QZ.  
[mex] Sylvester equation solution.  
[mex] Kronecker products.  
[mex] Sparse kronecker products.  
[mex] Local state space iteration (second order).  
[mex] Bytecode evaluation.  
[mex] k-order perturbation solver.  
[mex] k-order solution simulation.  
[mex] Quasi Monte-Carlo sequence (Sobol).

Starting Dynare (version 4.3.0).  
Starting preprocessing of the model file …  
Substitution of endo leads \>= 2: added 6 auxiliary variables and equations.  
Substitution of endo lags \>= 2: added 11 auxiliary variables and equations.  
Found 36 equation(s).  
Evaluating expressions…done  
Computing static model derivatives:

- order 1  
Computing dynamic model derivatives:
- order 1
- order 2  
Processing outputs …done  
Preprocessing completed.  
Starting MATLAB/Octave computing.

error: value on right hand side of assignment is undefined  
error: called from:  
error: /Users/shako/Desktop/MMB/NK/NK\_GM05.m at line 326, column 10  
error: /Applications/Dynare/4.3.0/matlab/dynare.m at line 120, column 1  
octave-3.4.0:16\> [/quote]

and this is the line in NK\_GM05.m at line 326:

> [@](#):
>
> thispath = cd;

If you need some extra information please ask.  
Any help would be much appreciated.

Best regards,  
Shako

---

<div class="post-metadata">

**Author:** ![HoutanBastani](https://forum.dynare.org/user_avatar/forum.dynare.org/houtanbastani/32/5052_2.png) [@HoutanBastani](https://forum.dynare.org/u/HoutanBastani)\
**Post date:** [3 July 2012 10:07 UTC](https://forum.dynare.org/t/problem-with-running-dynare/2604/2 "2012-07-03T10:07:57Z")

</div>

Hi, please post your mod file so I can try to replicate the problem.

---

<div class="post-metadata">

**Author:** ![shako](https://forum.dynare.org/letter_avatar_proxy/v4/letter/s/c2a13f/32.png) [@shako](https://forum.dynare.org/u/shako)\
**Post date:** [3 July 2012 13:08 UTC](https://forum.dynare.org/t/problem-with-running-dynare/2604/3 "2012-07-03T13:08:11Z")

</div>

Here is the MOD file attached  
[NK\_GM05.mod](https://forum.dynare.org/uploads/default/original/2X/5/51a9eba268c1416bef7e7a706900a04a5788921b.mod) (8.9 KB)

---

<div class="post-metadata">

**Author:** ![HoutanBastani](https://forum.dynare.org/user_avatar/forum.dynare.org/houtanbastani/32/5052_2.png) [@HoutanBastani](https://forum.dynare.org/u/HoutanBastani)\
**Post date:** [4 July 2012 07:36 UTC](https://forum.dynare.org/t/problem-with-running-dynare/2604/4 "2012-07-04T07:36:24Z")

</div>

This is an error in your modfile. cd does not produce any output in Octave, it is only used for changing directories. Use the pwd command instead.

---

<div class="post-metadata">

**Author:** ![shako](https://forum.dynare.org/letter_avatar_proxy/v4/letter/s/c2a13f/32.png) [@shako](https://forum.dynare.org/u/shako)\
**Post date:** [9 July 2012 10:05 UTC](https://forum.dynare.org/t/problem-with-running-dynare/2604/5 "2012-07-09T10:05:03Z")

</div>

> [@HoutanBastani](#):
>
> This is an error in your modfile. cd does not produce any output in Octave, it is only used for changing directories. Use the pwd command instead.

It worked. Thanks a lot!
