* fixed a bug with EXPECTATION operator: now handle model local variables
* substitute EXPECTATION operator even in deterministic models (for avoiding crashes, even if use of this operator doesn't make sense there)
* forbid the use of EXPECTATION and STEADY_STEATE outside model block
* minor implementation changes in EXPECTATION and STEADY_STATE operators
reference manual:
* documented EXPECTATION and STEADY_STATE operators
* added a note in write_latex_{static,dynamic}_model commands documentation about auxiliary variables and other model transformations
git-svn-id: https://www.dynare.org/svn/dynare/trunk@3145 ac1d8469-bf42-47a9-8791-bf33cf982152
* reworked a little bit the implementation
* documented the command in the reference manual
* added a test
git-svn-id: https://www.dynare.org/svn/dynare/trunk@3143 ac1d8469-bf42-47a9-8791-bf33cf982152
* fixed substitution of endogenous with leads >= 2: take into account exogenous with leads in non-linear terms
* fixed substitution of exogenous with leads: take into account other variables with leads in non-linear terms
git-svn-id: https://www.dynare.org/svn/dynare/trunk@3027 ac1d8469-bf42-47a9-8791-bf33cf982152
* In stochastic mode, now transforms the model by removing leads and lags greater or equal to 2 (creating auxiliary variables and equations in the process)
* Information about these variables is in structure M_.aux_vars
* Automatically add the necessary initialization for auxiliary vars after the initval block or load_params_and_steady_state
git-svn-id: https://www.dynare.org/svn/dynare/trunk@3002 ac1d8469-bf42-47a9-8791-bf33cf982152
* Allow the STEADY_STATE operator to work with exogenous/exogenous_det with non zero lead/lag
* Other cosmetic changes
git-svn-id: https://www.dynare.org/svn/dynare/trunk@2917 ac1d8469-bf42-47a9-8791-bf33cf982152
- mfs: new option for 'steady' and 'model' commands. Determines the equation belonging to the set of feedback variables.
mfs = 0 => all variables are considered as feedback variables (default value)
mfs = 1 => using only naturally normalized equation as potential recursive equations (all variables assigned to unnormalized equations are considered as feedback variable)
mfs = 2 => adding to the set of potential recursive equation with mfs = 1 the linear equation in endogenous variable normalized (all variables assigned to nonlinear unnormalized equations are considered as feedback variable)
mfs = 3 => adding to the set of potential recursive equation with mfs = 2 the non linear equation in endogenous variable normalized
- correction of few buggs in simulate.dll
- block_mfs_dll: new option for 'steady' command. Use simulate.dll to solve the steady state model (speedup the computation of the steady-state and the homotopy)
git-svn-id: https://www.dynare.org/svn/dynare/trunk@2866 ac1d8469-bf42-47a9-8791-bf33cf982152
* new ExprNode method for computing set of ModelLocalVariables of an expression
* factorized code with collectEndogenous() and collectExogenous() methods
git-svn-id: https://www.dynare.org/svn/dynare/trunk@2839 ac1d8469-bf42-47a9-8791-bf33cf982152
* StaticModel: dropped creation of C file in USE_DLL mode
* StaticModel: added computation of derivatives for block MFS mode
* DynamicModel: catch error codes of mkdir()
* ModelTree: moved "mode" member variable to DynamicModel
* ModFile::writeOutput(): moved manipulations relative to dynamic model file to DynamicModel
git-svn-id: https://www.dynare.org/svn/dynare/trunk@2818 ac1d8469-bf42-47a9-8791-bf33cf982152
* moved some declarations from ExprNode.hh to BlockTriangular.hh to which they conceptually belong
* replaced non standard boolean operators (and, or, not) by standard ones (&&, ||, !)
git-svn-id: https://www.dynare.org/svn/dynare/trunk@2812 ac1d8469-bf42-47a9-8791-bf33cf982152
* fixed a bug in the handling of VariableNode: we now make a copy of the recursive_variables map, instead of modifying that of the caller
* factorized code shared with standard derivation
* various minor cleanups
git-svn-id: https://www.dynare.org/svn/dynare/trunk@2811 ac1d8469-bf42-47a9-8791-bf33cf982152
* fixed bug in the dynamic version (was putting time subscripts to parameters)
* changed symbol for multiplication to a space (was a dot)
git-svn-id: https://www.dynare.org/svn/dynare/trunk@2802 ac1d8469-bf42-47a9-8791-bf33cf982152
- normalize an equation linear in its endogenous variable
- Chained rule derivatives (necessary to reduce a block to the feedback equations and variables)
git-svn-id: https://www.dynare.org/svn/dynare/trunk@2726 ac1d8469-bf42-47a9-8791-bf33cf982152
* fixed bug with normcdf() when converting to static model
* fixed description of derivative computation
git-svn-id: https://www.dynare.org/svn/dynare/trunk@2655 ac1d8469-bf42-47a9-8791-bf33cf982152
* added support for derivatives of Hessian w.r. to parameters
* added "identification" command which does nothing for the moment, except triggering those derivatives w.r. to params
git-svn-id: https://www.dynare.org/svn/dynare/trunk@2613 ac1d8469-bf42-47a9-8791-bf33cf982152
* created a distinct expression tree for the static model (thus giving better sharing of sub-expressions and better computation of temporary terms for the static model)
* for that purpose, created StaticModel and DynamicModel classes (ModelTree still persists, but only contains code shared between StaticModel and DynamicModel)
* removed sparse static file (to be later replaced by new algorithm for steady state computation on large models)
git-svn-id: https://www.dynare.org/svn/dynare/trunk@2592 ac1d8469-bf42-47a9-8791-bf33cf982152
* reorganized symbol table so that internally symbols have a unique integer ID (as a result, sparse code is temporarily in a broken state)
* rewritten from scratch ModFile::evalAllExpressions()
* {load,save}_params_and_steady_state moved to NumericalInitialization.{cc,hh}
* fixed bug related to endval block
git-svn-id: https://www.dynare.org/svn/dynare/trunk@2441 ac1d8469-bf42-47a9-8791-bf33cf982152
* updated copyright headers of all files modified since January 1st: the copyright notice now encompasses 2009
* fixed various other copyright header issues
git-svn-id: https://www.dynare.org/svn/dynare/trunk@2364 ac1d8469-bf42-47a9-8791-bf33cf982152
- temporary terms computed just before the equation where they appeared => important for "evaluated blocks" where temporary terms depend on endogenous computed in the block
git-svn-id: https://www.dynare.org/svn/dynare/trunk@2351 ac1d8469-bf42-47a9-8791-bf33cf982152
- simplifications of model blocks management in Modeltree
- corrections of the temporary variables management with sparse option
git-svn-id: https://www.dynare.org/svn/dynare/trunk@2341 ac1d8469-bf42-47a9-8791-bf33cf982152
- lead and lag on exogenous variables
- corrections in dr1_sparse and dr11_sparse
- minor corrections in simulate
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@2255 ac1d8469-bf42-47a9-8791-bf33cf982152