Page 1 of 1

Notation Issues

PostPosted: Sat Feb 26, 2011 9:26 pm
by petros_varth
Hi All,

I have two questions:

1) I introduce a large equation in the block model;....end;.How can i break the large equation in two or three lines.

Say k=(1-delta)*k(-1)... ????

2)I want to introduce a model in exp-logs.So i denote the variables

var n;

parameters eta;

and the n^(eta) i introduce it as eta*exp(n)

Should i repeat n in order to Dynare understand that n is log thus eta*exp(nn) ???


Thanks in advance,

Petros

Re: Notation Issues

PostPosted: Sun Feb 27, 2011 8:38 am
by jpfeifer
Hi,

1) Dynare takes everything that is not separated by a semicolon as one line. So you can just wrap around without using the Matlab "...";. Empty spaces are simply ignored. However, there may be problems if you use tabulators or other special characters to indent the lines. For example:
Code: Select all
k=(1-delta)*k(-1)
      +i;


2) What you do is perform a variable substitution, i.e. you replace all variables x with exp(x), but you do not log-linearize yourself. Hence, n_original^(eta) becomes exp(n)^eta, because in this way, n is implicitly defined as log(n_original) and thus n_original^(eta)=exp(n)^eta. See other forum posts like e.g. http://www.dynare.org/phpBB3/viewtopic.php?f=1&t=3013. This also means you do not have to tell Dynare that you performed a substitution.

Re: Notation Issues

PostPosted: Sun Feb 27, 2011 3:25 pm
by petros_varth
jpfeifer wrote:Hi,

1) Dynare takes everything that is not separated by a semicolon as one line. So you can just wrap around without using the Matlab "...";. Empty spaces are simply ignored. However, there may be problems if you use tabulators or other special characters to indent the lines. For example:
Code: Select all
k=(1-delta)*k(-1)
      +i;


2) What you do is perform a variable substitution, i.e. you replace all variables x with exp(x), but you do not log-linearize yourself. Hence, n_original^(eta) becomes exp(n)^eta, because in this way, n is implicitly defined as log(n_original) and thus n_original^(eta)=exp(n)^eta. See other forum posts like e.g. http://www.dynare.org/phpBB3/viewtopic.php?f=1&t=3013. This also means you do not have to tell Dynare that you performed a substitution.




Many thanks jpfeifer, this was very useful.

Petros