Commit 248ad188 authored by Stéphane Adjemian's avatar Stéphane Adjemian
Browse files

Merge remote-tracking branch 'Dynare/master' into enterprise

Fixed conflicts in:

 - .gitlab-ci.yml
 - matlab/dynare_config.m
 - matlab/dynare_solve.m
 - matlab/initvalf.m
 - matlab/perfect-foresight-models/make_ex_.m
 - matlab/perfect-foresight-models/perfect_foresight_setup.m
 - mex/build/matlab/Makefile.am
 - mex/build/matlab/configure.ac
 - mex/build/octave/Makefile.am
 - mex/build/octave/configure.ac
 - mex/sources/Makefile.am
 - preprocessor
 - tests/Makefile.am
parents 367daa86 9a726e61
...@@ -2,7 +2,7 @@ variables: ...@@ -2,7 +2,7 @@ variables:
GIT_SUBMODULE_STRATEGY: recursive GIT_SUBMODULE_STRATEGY: recursive
TERM: linux TERM: linux
MATLAB_VERSION: R2020a MATLAB_VERSION: R2020a
OLD_MATLAB_VERSION: R2009b OLD_MATLAB_VERSION: R2014a
# The next stanza creates the version number used for the source tarball and the # The next stanza creates the version number used for the source tarball and the
# binary packages. Here are the following possible cases: # binary packages. Here are the following possible cases:
...@@ -85,12 +85,10 @@ pkg_windows: ...@@ -85,12 +85,10 @@ pkg_windows:
cache: cache:
key: "$CI_JOB_NAME-$CI_COMMIT_REF_SLUG" key: "$CI_JOB_NAME-$CI_COMMIT_REF_SLUG"
paths: paths:
- windows/deps/sources32/
- windows/deps/sources64/ - windows/deps/sources64/
- windows/deps/lib32/
- windows/deps/lib64/ - windows/deps/lib64/
# We do not cache lib{32,64}-msys2, mingw{32,64}, octave{32,64} and # We do not cache lib64-msys2, mingw64, octave64 and
# matlab{32,64}, because those are simply extracted from a tarball. It # matlab64, because those are simply extracted from a tarball. It
# would be a waste of space and of (re-compression) time. # would be a waste of space and of (re-compression) time.
artifacts: artifacts:
paths: paths:
...@@ -232,7 +230,7 @@ deploy_release_enterprise: ...@@ -232,7 +230,7 @@ deploy_release_enterprise:
- pkg_windows - pkg_windows
- pkg_macOS - pkg_macOS
script: script:
- f=(windows/exe/*) && osslsigncode sign -pkcs12 ~/dynare-object-signing.p12 -n Dynare -i https://www.dynare.org -t http://timestamp.digicert.com -in ${f[0]} -out ${f[0]}.signed && mv ${f[0]}.signed ${f[0]} - f=(windows/exe/*) && osslsigncode sign -pkcs12 ~/cepremap-comodo-sectigo-code-signing.p12 -n Dynare -i https://www.dynare.org -t http://timestamp.comodoca.com -in ${f[0]} -out ${f[0]}.signed && mv ${f[0]}.signed ${f[0]}
- cp *.tar.xz /srv/www.dynare.org/release_ecb/source/ - cp *.tar.xz /srv/www.dynare.org/release_ecb/source/
- cp windows/exe/* /srv/www.dynare.org/release_ecb/windows/ - cp windows/exe/* /srv/www.dynare.org/release_ecb/windows/
- cp windows/7z/* /srv/www.dynare.org/release_ecb/windows-7z/ - cp windows/7z/* /srv/www.dynare.org/release_ecb/windows-7z/
......
Announcement for Dynare 4.6.2 (on 2020-09-07)
=============================================
We are pleased to announce the release of Dynare 4.6.2.
This maintenance release fixes various bugs.
The Windows, macOS and source packages are already available for download at
[the Dynare website](https://www.dynare.org/download/).
All users are strongly encouraged to upgrade.
This release is compatible with MATLAB versions ranging from 7.9 (R2009b) to
9.8 (R2020a), and with GNU Octave versions 5.2.0 (under Windows) and 4.4.1
(under macOS).
*Note for Windows users:* upon launching the Dynare installer, you may get a
warning emitted by Windows Defender SmartScreen, saying that this is an
unrecognized app and that it was prevented from starting. You can safely ignore
this warning, as long as you can verify on the next screen that CEPREMAP is the
editor of the software. This security warning is due to the fact that we had to
renew our code signing certificate (which had expired), and it takes some time
to rebuild our reputation as a software editor using the new certificate.
Here is a list of the problems identified in version 4.6.1 and that have been
fixed in version 4.6.2:
* Perfect foresight simulations of purely backward models could deliver an
incorrect result if some exogenous variable appeared with a lag of 2 or more
(and neither `block` nor `bytecode` option was used)
* Perfect foresight simulations of linear models could deliver an incorrect
result if the following four conditions were met:
+ the model was actually declared as linear through the `linear` option
+ there was an exogenous variable with a lead or a lag
+ `stack_solve_algo` was equal to 0 (the default) or 7
+ neither `block` nor `bytecode` option was used
* In stochastic simulations, for variables that actually do not leave the
steady state, reported simulated moments could be spurious (due to division
by zero)
* Displayed variance decompositions would only take into account measurement
errors if measurement errors were present for all observed variables
* The posterior variance decompositions with measurement errors computed with
`moments_varendo` were incorrect
* `moments_varendo` would not update `oo_.PosteriorTheoreticalMoments` if it
was already present, from *e.g.* an earlier run of `estimation`
* Identification would in some cases compute wrong Jacobian of moments
* Identification would display incorrect results if parameter dependence was
implemented via a steady state file
* `generate_trace_plots` would crash when measurement errors were present
* `estimation` would crash for correlated measurement errors
* Parallel execution/testing could crash instead of aborting with a proper
error message
* Under macOS, Dynare would incorrectly claim that it is compiled for Octave
5.2.0 (it is actually compiled for Octave 4.4.1)
* Using external functions in a model local variable would crash the
preprocessor
* Tolerance criteria for steady state computations were inconsistently set
* `stoch_simul` with its default `order=2` would crash with a message about
`hessian_eq_zero` not existing if an explicit `order=1` was present somewhere
else in the `.mod` file
* Model local variables were not written to the `modfile.json` JSON file
* Model local variables names would have two spurious underscores at their
point of definition in the `dynamic.json` and `static.json` files (but only
in the definition, not when they were used, which is inconsistent)
* The `solve_algo=9` option was not accessible. The `solve_algo=10` and
`solve_algo=11` options were not accessible with `block` (without `bytecode`)
* Under certain circumstances, `extended_path` would crash when used in
conjunction with the `block` option
* `extended_path` was not working with the `bytecode` option
* `shock_decomposition` was not accepting the options of `estimation` related
to smoothing
* `conditional_forecast` would display a warning even if the simulation was
successful
* The `prior_trunc` option of `identification` was not working
* The `rand_multivariate_student` value of the `proposal_distribution` option
was not working when used with the
`tailored_random_block_metropolis_hastings` posterior sampling method
* Perfect foresight simulations of backward models would crash if convergence
failed with complex-valued residuals
* The diffuse Kalman smoother would crash if `Finf` became singular
Announcement for Dynare 4.6.1 (on 2020-03-13) Announcement for Dynare 4.6.1 (on 2020-03-13)
============================================= =============================================
......
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
}} }}
\author{S\'ebastien Villemot\thanks{Paris School of Economics and \author{S\'ebastien Villemot\thanks{Paris School of Economics and
CEPREMAP.} \and Johannes Pfeifer\thanks{University of Cologne. E-mail: \href{mailto:jpfeifer@uni-koeln.de}{\texttt{jpfeifer@uni-koeln.de}}.}} CEPREMAP.} \and Johannes Pfeifer\thanks{Universität der Bundeswehr München. E-mail: \href{mailto:johannes.pfeifer@unibw.de}{\texttt{johannes.pfeifer@unibw.de}}.}}
\date{First version: September 2007 \hspace{1cm} This version: May 2017} \date{First version: September 2007 \hspace{1cm} This version: May 2017}
\maketitle \maketitle
......
...@@ -4,7 +4,7 @@ The Dynare Reference Manual, version |version| ...@@ -4,7 +4,7 @@ The Dynare Reference Manual, version |version|
Currently the development team of Dynare is composed of: Currently the development team of Dynare is composed of:
* Stéphane Adjemian (Université du Maine, Gains) * Stéphane Adjemian (Université du Maine, Gains)
* Houtan Bastani (CEPREMAP) * Houtan Bastani
* Michel Juillard (Banque de France) * Michel Juillard (Banque de France)
* Sumudu Kankanamge (Toulouse School of Economics) * Sumudu Kankanamge (Toulouse School of Economics)
* Frédéric Karamé (Université du Maine, Gains and CEPREMAP) * Frédéric Karamé (Université du Maine, Gains and CEPREMAP)
...@@ -12,7 +12,7 @@ Currently the development team of Dynare is composed of: ...@@ -12,7 +12,7 @@ Currently the development team of Dynare is composed of:
* Junior Maih (Norges Bank) * Junior Maih (Norges Bank)
* Ferhat Mihoubi (Université Paris-Est Créteil, Érudite and CEPREMAP) * Ferhat Mihoubi (Université Paris-Est Créteil, Érudite and CEPREMAP)
* Willi Mutschler (University of Münster) * Willi Mutschler (University of Münster)
* Johannes Pfeifer (University of Cologne) * Johannes Pfeifer (Universität der Bundeswehr München)
* Marco Ratto (European Commission, Joint Research Centre - JRC) * Marco Ratto (European Commission, Joint Research Centre - JRC)
* Sébastien Villemot (CEPREMAP) * Sébastien Villemot (CEPREMAP)
......
...@@ -14,7 +14,7 @@ are necessary in that case. ...@@ -14,7 +14,7 @@ are necessary in that case.
In order to run Dynare, you need one of the following: In order to run Dynare, you need one of the following:
* MATLAB version 7.9 (R2009b) or above; * MATLAB version 8.3 (R2014a) or above;
* GNU Octave version 4.4 or above, with the statistics package from * GNU Octave version 4.4 or above, with the statistics package from
`Octave-Forge`_. Note however that the Dynare installers for Windows and `Octave-Forge`_. Note however that the Dynare installers for Windows and
macOS require a more specific version of Octave, as indicated on the download macOS require a more specific version of Octave, as indicated on the download
......
...@@ -229,7 +229,8 @@ by the ``dynare`` command. ...@@ -229,7 +229,8 @@ by the ``dynare`` command.
.. option:: json = parse|check|transform|compute .. option:: json = parse|check|transform|compute
Causes the preprocessor to output a version of the ``.mod`` file in Causes the preprocessor to output a version of the ``.mod`` file in
JSON format. When the JSON output is created depends on the value JSON format to ``<<M_.dname>>/model/json/``.
When the JSON output is created depends on the value
passed. These values represent various steps of processing in the passed. These values represent various steps of processing in the
preprocessor. preprocessor.
...@@ -257,7 +258,8 @@ by the ``dynare`` command. ...@@ -257,7 +258,8 @@ by the ``dynare`` command.
.. option:: jsonstdout .. option:: jsonstdout
Instead of writing output requested by ``json`` to files, Instead of writing output requested by ``json`` to files,
write to standard out. write to standard out, i.e. to the MATLAB/Octave command window
(and the log-file).
.. option:: onlyjson .. option:: onlyjson
......
This diff is collapsed.
...@@ -34,7 +34,7 @@ from docutils.parsers.rst import Directive, directives ...@@ -34,7 +34,7 @@ from docutils.parsers.rst import Directive, directives
from sphinx import addnodes from sphinx import addnodes
from sphinx.domains import Domain, ObjType from sphinx.domains import Domain, ObjType
from sphinx.locale import l_, _ from sphinx.locale import _
from sphinx.directives import ObjectDescription from sphinx.directives import ObjectDescription
from sphinx.roles import XRefRole from sphinx.roles import XRefRole
from sphinx.util.nodes import make_refnode from sphinx.util.nodes import make_refnode
...@@ -140,14 +140,14 @@ class DynCallable(DynObject): ...@@ -140,14 +140,14 @@ class DynCallable(DynObject):
has_arguments = True has_arguments = True
doc_field_types = [ doc_field_types = [
TypedField('arguments', label=l_('Arguments'), TypedField('arguments', label=_('Arguments'),
names=('argument', 'arg', 'parameter', 'param'), names=('argument', 'arg', 'parameter', 'param'),
typerolename='func', typenames=('paramtype', 'type')), typerolename='func', typenames=('paramtype', 'type')),
Field('returnvalue', label=l_('Returns'), has_arg=False, Field('returnvalue', label=_('Returns'), has_arg=False,
names=('returns', 'return')), names=('returns', 'return')),
Field('returntype', label=l_('Return type'), has_arg=False, Field('returntype', label=_('Return type'), has_arg=False,
names=('rtype',)), names=('rtype',)),
Field('example', label=l_('Example'), has_arg=False, Field('example', label=_('Example'), has_arg=False,
names=('ex',)), names=('ex',)),
] ]
...@@ -157,10 +157,10 @@ class DynClass(DynObject): ...@@ -157,10 +157,10 @@ class DynClass(DynObject):
allow_nesting = True allow_nesting = True
doc_field_types = [ doc_field_types = [
TypedField('members', label=l_('Members'), TypedField('members', label=_('Members'),
names=('argument', 'arg', ), names=('argument', 'arg', ),
typerolename='func', typenames=('type', )), typerolename='func', typenames=('type', )),
Field('example', label=l_('Example'), has_arg=False, Field('example', label=_('Example'), has_arg=False,
names=('ex',)), names=('ex',)),
] ]
...@@ -291,22 +291,22 @@ class DynareDomain(Domain): ...@@ -291,22 +291,22 @@ class DynareDomain(Domain):
name = 'dynare' name = 'dynare'
label = 'Dynare' label = 'Dynare'
object_types = { object_types = {
'function': ObjType(l_('function'), 'func'), 'function': ObjType(_('function'), 'func'),
'datesmethod': ObjType(l_('method'), 'datmeth'), 'datesmethod': ObjType(_('method'), 'datmeth'),
'dseriesmethod': ObjType(l_('method'), 'dsermeth'), 'dseriesmethod': ObjType(_('method'), 'dsermeth'),
'reportingmethod': ObjType(l_('method'), 'repmeth'), 'reportingmethod': ObjType(_('method'), 'repmeth'),
'matcomm': ObjType(l_('matlab command'), 'mcomm'), 'matcomm': ObjType(_('matlab command'), 'mcomm'),
'command': ObjType(l_('command'), 'comm'), 'command': ObjType(_('command'), 'comm'),
'class': ObjType(l_('class'), 'class'), 'class': ObjType(_('class'), 'class'),
'block': ObjType(l_('block'), 'bck'), 'block': ObjType(_('block'), 'bck'),
'confblock': ObjType(l_('config block'), 'cbck'), 'confblock': ObjType(_('config block'), 'cbck'),
'macrodir': ObjType(l_('macro directive'), 'mdir'), 'macrodir': ObjType(_('macro directive'), 'mdir'),
'construct': ObjType(l_('constructor'), 'cstr'), 'construct': ObjType(_('constructor'), 'cstr'),
'matvar': ObjType(l_('matlab variable'), 'mvar'), 'matvar': ObjType(_('matlab variable'), 'mvar'),
'specvar': ObjType(l_('special variable'), 'svar'), 'specvar': ObjType(_('special variable'), 'svar'),
'operator': ObjType(l_('operator'), 'op'), 'operator': ObjType(_('operator'), 'op'),
'constant': ObjType(l_('constant'), 'const'), 'constant': ObjType(_('constant'), 'const'),
'option': ObjType(l_('option'), 'opt'), 'option': ObjType(_('option'), 'opt'),
} }
directives = { directives = {
'function': DynFunction, 'function': DynFunction,
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
\author{Ondra Kamen\'\i k} \author{Ondra Kamen\'\i k}
\date{February 2011, updated August 2016} \date{First version: February 2011 \\ This version: September 2020}
\maketitle \maketitle
\tableofcontents \tableofcontents
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
\section{Setup} \section{Setup}
The Dynare++ setup procedure is pretty straightforward as Dynare++ is included in the Dynare installation The Dynare++ setup procedure is pretty straightforward as Dynare++ is included in the Dynare installation
packages which can be downloaded from \url{http://www.dynare.org}. Take the following steps: packages which can be downloaded from \url{https://www.dynare.org}. Take the following steps:
\begin{enumerate} \begin{enumerate}
\item Add the {\tt dynare++} subdirectory of the root Dynare installation directory to the your \item Add the {\tt dynare++} subdirectory of the root Dynare installation directory to the your
operating system path. This ensures that your OS will find the {\tt dynare++} executable. operating system path. This ensures that your OS will find the {\tt dynare++} executable.
...@@ -159,10 +159,7 @@ file {\tt example1.jnl} and a MATLAB MAT-4 {\tt example1.mat}. The ...@@ -159,10 +159,7 @@ file {\tt example1.jnl} and a MATLAB MAT-4 {\tt example1.mat}. The
journal file contains information about time, memory and processor journal file contains information about time, memory and processor
resources needed for all steps of solution. The output file is more resources needed for all steps of solution. The output file is more
interesting. It contains various simulation results. It can be loaded interesting. It contains various simulation results. It can be loaded
into MATLAB or Scilab and examined.% into MATLAB or Octave and examined.
\footnote{For MATLAB {\tt load example1.mat}, for Scilab {\tt
mtlb\_load example1.mat}} The following examples are done in MATLAB,
everything would be very similar in Scilab.
Let us first examine the contents of the MAT file: Let us first examine the contents of the MAT file:
{\small {\small
...@@ -431,7 +428,7 @@ vcov = [ ...@@ -431,7 +428,7 @@ vcov = [
} }
After this model file has been run, we can load the resulting MAT-file After this model file has been run, we can load the resulting MAT-file
into the MATLAB (or Scilab) and examine its contents: into the MATLAB and examine its contents:
{\small {\small
\begin{verbatim} \begin{verbatim}
>> load kp1980_2.mat >> load kp1980_2.mat
...@@ -628,7 +625,11 @@ reported. They might be useful for confidence interval calculations. ...@@ -628,7 +625,11 @@ reported. They might be useful for confidence interval calculations.
For each shock, Dynare++ calculates IRF for two impulses, positive and For each shock, Dynare++ calculates IRF for two impulses, positive and
negative. Size of an impulse is one standard error of a respective negative. Size of an impulse is one standard error of a respective
shock. shock.\footnote{Note that if the exogenous shocks are correlated, Dynare++ will
ignore the correlation when computing the IRFs, and simulate the impulse on
each shock independently of the others. Note that Dynare behaves differently
in this case, and computes IRFs after performing an orthogonalization of the
shocks (via a Cholesky decomposition of the variance-covariance matrix).}
The rest of this subsection is divided to three parts giving account The rest of this subsection is divided to three parts giving account
on real-time simulations, conditional simulations, and on the way how on real-time simulations, conditional simulations, and on the way how
...@@ -924,7 +925,7 @@ This section deals with Dynare++ input. The first subsection ...@@ -924,7 +925,7 @@ This section deals with Dynare++ input. The first subsection
\ref{dynpp_opts} provides a list of command line options, next \ref{dynpp_opts} provides a list of command line options, next
subsection \ref{dynpp_mod} deals with a format of Dynare++ model file, subsection \ref{dynpp_mod} deals with a format of Dynare++ model file,
and the last subsection discusses incompatibilities between Dynare and the last subsection discusses incompatibilities between Dynare
MATLAB and Dynare++. and Dynare++.
\subsection{Command Line Options} \subsection{Command Line Options}
\label{dynpp_opts} \label{dynpp_opts}
...@@ -1143,7 +1144,7 @@ $t+1$. The realization of $u_t$ is included in the information set of ...@@ -1143,7 +1144,7 @@ $t+1$. The realization of $u_t$ is included in the information set of
$E_t$. See an explanation of Dynare++ timing on page \pageref{timing}. $E_t$. See an explanation of Dynare++ timing on page \pageref{timing}.
\end{itemize} \end{itemize}
The model equations are formulated in the same way as in MATLAB The model equations are formulated in the same way as in
Dynare. The time indexes different from $t$ are put to round Dynare. The time indexes different from $t$ are put to round
parenthesis in this way: {\tt C(-1)}, {\tt C}, {\tt C(+1)}. parenthesis in this way: {\tt C(-1)}, {\tt C}, {\tt C(+1)}.
...@@ -1181,16 +1182,16 @@ Y-Y_SS = rho*(Y(-1)-Y_SS)+EPS; ...@@ -1181,16 +1182,16 @@ Y-Y_SS = rho*(Y(-1)-Y_SS)+EPS;
\end{verbatim} \end{verbatim}
} }
\subsection{Incompatibilities with MATLAB Dynare} \subsection{Incompatibilities with Dynare}
This section provides a list of incompatibilities between a model file This section provides a list of incompatibilities between a model file
for Dy\-na\-re++ and MATLAB Dynare. These must be considered when a model for Dy\-na\-re++ and for Dynare. These must be considered when a model
file for MATLAB Dynare is being migrated to Dynare++. The list is the file for Dynare is being migrated to Dynare++. The list is the
following: following:
\begin{itemize} \begin{itemize}
\item There is no {\tt periods} keyword. \item There is no {\tt periods} keyword.
\item The parameters cannot be lagged or leaded, I think that Dynare \item The parameters cannot be lagged or leaded; Dynare
MATLAB allows it, but the semantics is the same (parameter is a allows it, though the semantics is the same (parameter is a
constant). constant).
\item There are no commands like {\tt steady}, {\tt check}, {\tt \item There are no commands like {\tt steady}, {\tt check}, {\tt
simul}, {\tt stoch\_simul}, etc. simul}, {\tt stoch\_simul}, etc.
......
/* /*
* This file implements the Baseline New Keynesian DSGE model described in * This file implements the Baseline New Keynesian DSGE model described in
* much detail in Jesús Fernández-Villaverde and Juan F. Rubio-Ramírez (2006): "A Baseline DSGE * much detail in Jesús Fernández-Villaverde and Juan F. Rubio-Ramírez (2006): “A Baseline DSGE
* Model", available at http://economics.sas.upenn.edu/~jesusfv/benchmark_DSGE.pdf * Model”, available at http://economics.sas.upenn.edu/~jesusfv/benchmark_DSGE.pdf
* *
* The parametrization is based on the estimated version of this model in * The parametrization is based on the estimated version of this model in
* Jesús Fernández-Villaverde (2010): "The econometrics of DSGE models",  
* SERIEs, Vol. 1, pp. 3-49, DOI 10.1007/s13209-009-0014-7 * SERIEs, Vol. 1, pp. 3-49, DOI 10.1007/s13209-009-0014-7
* *
* This implementation was written by Benjamin Born and Johannes Pfeifer. In * This implementation was written by Benjamin Born and Johannes Pfeifer. In
* case you spot mistakes, email us at jpfeifer@gmx.de * case you spot mistakes, email us at jpfeifer@gmx.de
* *
* This mod-file implements a non-linearized version of the New Keynesian * This mod-file implements a non-linearized version of the New Keynesian
* model based on a recursive formulation of the price and wage setting * model based on a recursive formulation of the price and wage setting
* equations. Moreover, it makes use of a steady state file to i) set * equations. Moreover, it makes use of a steady state file to i) set
* parameters that depend on other parameters that are potentially estimated * parameters that depend on other parameters that are potentially estimated
* and ii) solve a nonlinear equation using a numerical solver to find the steady * and ii) solve a nonlinear equation using a numerical solver to find the steady
* state of labor. It provides an example on how the steady state file can be used * state of labor. It provides an example on how the steady state file can be used
* to circumvent some of the limitation of Dynare mod-file by accessing an external * to circumvent some of the limitation of Dynare mod-file by accessing an external
* file that allows calling general MATLAB routines. These capacities will mostly be * file that allows calling general MATLAB routines. These capacities will mostly be
* interesting for power users. If one just wants to provide analytical steady state * interesting for power users. If one just wants to provide analytical steady state
* values and update parameters, the steady_state_model-block allows an easy and convenient * values and update parameters, the steady_state_model-block allows an easy and convenient
* alternative. It even allows calling numerical solvers like fsolve. For an example, see * alternative. It even allows calling numerical solvers like fsolve. For an example, see
* example3.mod * example3.mod
* *
* The model is written in the beginning of period stock notation. To make the model * The model is written in the beginning of period stock notation. To make the model
* conform with Dynare's end of period stock notation, we use the * conform with Dynare’s end of period stock notation, we use the
* predetermined_variables-command. * predetermined_variables-command.
* *
* Please note that the following copyright notice only applies to this Dynare * Please note that the following copyright notice only applies to this Dynare
* implementation of the model. * implementation of the model.
*/ */
...@@ -79,7 +79,7 @@ var d (long_name='preference shock') ...@@ -79,7 +79,7 @@ var d (long_name='preference shock')
phi (long_name='labor disutility shock') phi (long_name='labor disutility shock')
F (long_name='firm profits') F (long_name='firm profits')
; ;
varexo epsd (long_name='Innovation preference shock') varexo epsd (long_name='Innovation preference shock')
epsphi (long_name='Innovation labor disutility shock') epsphi (long_name='Innovation labor disutility shock')
epsmu_I (long_name='Innovation investment-specific technology') epsmu_I (long_name='Innovation investment-specific technology')
...@@ -125,7 +125,7 @@ parameters h (long_name='consumption habits') ...@@ -125,7 +125,7 @@ parameters h (long_name='consumption habits')
//Note that the parameter naming in FV(2010) differs from FV(2006) //Note that the parameter naming in FV(2010) differs from FV(2006)
//Fixed parameters, taken from FV(2010), Table 2, p. 37 //Fixed parameters, taken from FV(2010), Table 2, p. 37
delta=0.025; delta=0.025;
epsilon=10; epsilon=10;
eta= 10; eta= 10;
Phi=0; Phi=0;
...@@ -162,7 +162,7 @@ LambdaA = 2.8e-3; ...@@ -162,7 +162,7 @@ LambdaA = 2.8e-3;
/* /*
The following parameters are set in the steady state file as they depend on other The following parameters are set in the steady state file as they depend on other
deep parameters (some were estimated in the original study). Setting them in the deep parameters (some were estimated in the original study). Setting them in the
steady state file means they are updated for every parameter draw in the MCMC steady state file means they are updated for every parameter draw in the MCMC
algorithm, while the parameters initialized here are only set once for the initial algorithm, while the parameters initialized here are only set once for the initial
...@@ -181,7 +181,7 @@ The following model equations are the stationary model equations, taken from ...@@ -181,7 +181,7 @@ The following model equations are the stationary model equations, taken from
FV(2006), p. 20, section 3.2. FV(2006), p. 20, section 3.2.
*/ */
model; model;
[name='FOC consumption'] [name='FOC consumption']
d*(c-h*c(-1)*mu_z^(-1))^(-1)-h*betta*d(+1)*(c(+1)*mu_z(+1)-h*c)^(-1)=lambda; d*(c-h*c(-1)*mu_z^(-1))^(-1)-h*betta*d(+1)*(c(+1)*mu_z(+1)-h*c)^(-1)=lambda;
[name='Euler equation'] [name='Euler equation']
...@@ -221,7 +221,7 @@ yd=c+x+mu_z^(-1)*mu_I^(-1)*(gammma1*(u-1)+gammma2/2*(u-1)^2)*k; ...@@ -221,7 +221,7 @@ yd=c+x+mu_z^(-1)*mu_I^(-1)*(gammma1*(u-1)+gammma2/2*(u-1)^2)*k;
[name='Aggregate production'] [name='Aggregate production']
yd=(mu_A*mu_z^(-1)*(u*k)^alppha*ld^(1-alppha)-Phi)/vp; yd=(mu_A*mu_z^(-1)*(u*k)^alppha*ld^(1-alppha)-Phi)/vp;
[name='Aggregate labor market'] [name='Aggregate labor market']
l=vw*ld; l=vw*ld;
[name='LOM Price dispersion term'] [name='LOM Price dispersion term']
vp=thetap*(PI(-1)^chi/PI)^(-epsilon)*vp(-1)+(1-thetap)*PIstar^(-epsilon); vp=thetap*(PI(-1)^chi/PI)^(-epsilon)*vp(-1)+(1-thetap)*PIstar^(-epsilon);
[name='LOM Wage dispersion term'] [name='LOM Wage dispersion term']
...@@ -241,7 +241,7 @@ log(phi)=rhophi*log(phi(-1))+epsphi; ...@@ -241,7 +241,7 @@ log(phi)=rhophi*log(phi(-1))+epsphi;
[name='Investment specific technology'] [name='Investment specific technology']
log(mu_I)=Lambdamu+epsmu_I; log(mu_I)=Lambdamu+epsmu_I;
[name='Neutral technology'] [name='Neutral technology']
log(mu_A)=LambdaA+epsA; log(mu_A)=LambdaA+epsA;
[name='Defininition composite technology'] [name='Defininition composite technology']
mu_z=mu_A^(1/(1-alppha))*mu_I^(alppha/(1-alppha)); mu_z=mu_A^(1/(1-alppha))*mu_I^(alppha/(1-alppha));
......
/* /*
* This file replicates the model studied in: * This file replicates the model studied in:
* Aguiar, Mark and Gopinath, Gita (2004): "Emerging Market Business Cycles: * Aguiar, Mark and Gopinath, Gita (2004): “Emerging Market Business Cycles:
* The Cycle is the Trend" (NBER WP 10734). It is different from version published * The Cycle is the Trend(NBER WP 10734). It is different from version published
* in the Journal of Political Economy. * in the Journal of Political Economy.
* *
* This model file is intended to show the capabilities of the Dynare macro * This model file is intended to show the capabilities of the Dynare macro
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
* The mod-file reproduces Figure 4 of the working paper, which displays the * The mod-file reproduces Figure 4 of the working paper, which displays the
* model response to 1 percent shock to trend and cyclical TFP. * model response to 1 percent shock to trend and cyclical TFP.
* *
* This implementation was written by Sbastien Villemot and Johannes Pfeifer. * This implementation was written by Sébastien Villemot and Johannes Pfeifer.
* Please note that the following copyright notice only applies to this Dynare * Please note that the following copyright notice only applies to this Dynare
* implementation of the model. * implementation of the model.
*/ */
......
...@@ -207,12 +207,6 @@ Copyright: 1993-1996 Kurt Hornik ...@@ -207,12 +207,6 @@ Copyright: 1993-1996 Kurt Hornik
2016-2017 Dynare Team 2016-2017 Dynare Team
License: GPL-3+