Commit Graph

145 Commits (9af2e461c39a93c5ff41ce1a9082e66b3bd13877)

Author SHA1 Message Date
ferhat 9af2e461c3 New release of deterministic simulation.
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1292 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-06-01 11:43:49 +00:00
sebastien 8fb8b0ff99 v4 parser:
* added pre-computing of numerical constants (i.e. 1+1 is replaced by 2)
* removed appending of ".0" for integer constants
* refactoring of NumericalConstants


git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1255 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-05-08 19:16:35 +00:00
sebastien 3f6a51bfd4 v4 parser: fixed problem with C code compilation (+ beautification of the code)
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1254 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-04-30 14:49:08 +00:00
sebastien 9f33835d6a v4 parser:
* implemented handling of mod file local variables (eModFileLocalVariable)
* renamed "local parameters" to model local variables (eModelLocalVariables)


git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1253 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-04-30 12:09:05 +00:00
michel 8ee3650ac3 v3+4 parser: reverted wrong correction to histval a few months ago
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1251 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-04-16 15:59:29 +00:00
michel 4271844ffe v4 parser: M_.params initialized with Nan rather than zeros
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1243 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-04-14 16:49:41 +00:00
michel 59f3fa5185 v4 parser: when ramseypolicy instruction is present one must compute derivatives
to one order more than the order of approximation of the solution


git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1206 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-03-10 20:41:35 +00:00
sebastien c188e1e1be v4 parser: removed OperatorTable (no longer needed)
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1205 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-03-10 08:44:18 +00:00
sebastien 573227a044 v4 parser:
* removed Expression class; the "ExprNode" class is therefore now used everywhere
* removed interprete class, and replaced it by a method in ExprNode and an global evaluation context in ModFile
* fixed breakage of SparseDLL / Block decomposition code introduced in previous revision


git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1204 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-03-09 17:27:46 +00:00
sebastien 30c70a35e3 v4 parser:
* reorganised code in ModelTree so that block decomposition and SparseDLL code is clearly separated
* replaced DataTree::offset by ModelTree::mode, using an enumeration of the three modes which is more explicit
* reorganised ExprNode::writeOutput method by using a sixfold enumeration type (ExprNodeOutputType) corresponding to the 6 different contexts in which an expression can be written


git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1203 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-03-06 17:14:35 +00:00
sebastien 68c57ae019 v4 parser: no temporary terms in local parameters declaration
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1200 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-02-28 10:21:20 +00:00
michel cf200ccd4c v4 parser: updating DynareBison.cc/hh
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1199 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-02-24 15:22:02 +00:00
michel aa6e833462 v4 parser: bug correction in ModelTree.cc
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1198 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-02-24 15:21:08 +00:00
michel eb5ab33a71 v4 parser: reverting DataTree.cc to revision 1190
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1197 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-02-24 15:20:23 +00:00
michel f4d669f3e3 v4 parser: write local parameters before temporary terms in ModelTree
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1196 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-02-24 15:04:03 +00:00
michel abd3b96583 v4 parser: added initialization of node_counter in DataTree
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1195 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-02-24 15:02:07 +00:00
sebastien feec20209d v4 parser: merged Fehrat's changes
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1190 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-02-21 23:28:16 +00:00
sebastien 934f5f21a7 v4 parser:
* added third order derivatives in dynamic file (triggered by order=3 option of stoch_simul/olr/osr/ramsey_policy)
* don't output hessian in dynamic file if order=1 is specified


git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1180 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-02-08 11:56:46 +00:00
sebastien c3d114a7a1 v4 parser:
* declared ExprNode::cost as const
* Makefile: removed DynareBison.{cc,hh} from "clean" rule. Added a "distclean" rule for that purpose
* various minor changes


git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1179 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-02-05 09:55:41 +00:00
michel ba57343ac3 v4 parser: adding position.hh for people who have an old bison
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1177 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-02-01 20:05:36 +00:00
michel 4bc9ebeeb6 v4 parser: adding location.hh for people who have an old bison
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1176 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-02-01 20:04:31 +00:00
michel b514885d99 v4 parser: adding stack.hh for people who have an old bison
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1175 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-02-01 20:03:09 +00:00
michel 6c31af64cc v4 parser: adding DynareBison.cc .hh for people who have an old bison
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1174 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-02-01 20:00:44 +00:00
michel 5b17081b2b v4 parser.src: corrected bug in EstimatedParamStatement::WriteOutput
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1151 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-01-13 21:10:16 +00:00
sebastien 0c16f52806 v4 parser:
* reshaped DataTree/ModelTree using a more object-oriented approach
* improved expression sharing algorithm (temporary terms in output files), resulting in smaller output files for big models
* optimized performance (both in computing time and memory consumption)
* bugfix: the expressions stored in local parameters of models (pound expressions) are now derived
* bugfix: cosh(0) = 1
* removed some useless parentheses in output


git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1148 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-01-09 19:00:05 +00:00
michel f67d00cd34 v4 parser: corrected Hessian when declared exogenous variables aren't all present in the model;
add VariableTable::get_dyn_var_nbr()

git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1141 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-01-06 11:29:32 +00:00
michel 3773ad9cc3 v4 parser: used initializer to initialize ModelTree::eq_nbr
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1138 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-01-05 19:56:39 +00:00
michel 7793bc700f v4 parser: added initialization of eq_nbr=0 in ModelTree::ModelTree()
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1135 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-01-04 22:25:39 +00:00
michel 77cdcce658 v4: adding Ramsey policy to parser;
changes to Ramsey policy Matlab code

git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1133 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-01-04 14:42:27 +00:00
sebastien e3bb760692 v4 parser: made OperatorTable static
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1132 ac1d8469-bf42-47a9-8791-bf33cf982152
2007-01-02 15:43:18 +00:00
michel 6b761cf937 v4 parser: added option mh_revover
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1131 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-12-26 09:23:01 +00:00
sebastien 637ca0f86e v4 parser DynareFlex/DynareBison: removed unused tokens and other minor cosmetic changes
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1130 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-12-22 11:42:31 +00:00
sebastien 022ddd81ba v4 parser ParsingDriver: reintroduce check for existence of symbol in expressions
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1127 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-12-18 23:50:18 +00:00
sebastien 5bbd779bab v4 parser:
* added planner_objective statement, which triggers the creation of filename_objective_static.m
* added computing pass
* added the possibility of writing the hessian in static output file



git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1126 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-12-18 23:28:52 +00:00
sebastien 0f9ed33f7d v4 parser: removed ModelParameters class, and moved its components to the relevant places
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1125 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-12-18 11:29:10 +00:00
michel d035175627 v4 parser: 'check' is also a computing task
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1123 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-12-17 14:59:39 +00:00
sebastien c445ce3a98 v4 parser:
* added a computing pass
* ModelTree:
  - separated checking pass, computing pass, and output writing
  - reorganized static and dynamic model file output code


git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1121 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-12-15 17:31:31 +00:00
sebastien 73d3e17540 v4 parser:
* added an embryonic checking pass after parsing
* modified the decision of which derivatives to compute:
  - if a simul statement is present, compute the jacobian vs endogenous variables only, and no hessian
  - if a stoch_simul/estimation/olr/osr statement is present, compute the jacobian vs all variables, plus the hessian
  - if the two previous conditions are simultaneously fulfilled, abort with an error
  - if none of these two conditions are fulfilled, abort with an error (nothing to compute)
* fixed a minor bug with the size of the jacobian matrix when computing it only vs endogenous variables


git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1120 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-12-15 11:44:58 +00:00
sebastien be18e12a43 v4 parser VariableTable:
* cleaned and simplified the code
* incorporated VariableTable as a private member of DataTree/ModelTree


git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1118 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-12-14 22:19:39 +00:00
sebastien 4f9e8a6e27 v4 parser:
* clearly separated the parsing process from the output writing, using an abstract intermediary representation of the mod file
* created the Statement class, and its derivatives, for that purpose
* fixed bug with "corr" statements in "shocks" blocks (variables indexes given to matlab were incorrect)
* fixed bug with "optim" option of "estimation" (this option was not passed to matlab)
* fixed bug with "dynatype" and "dynasave" (variable list was not passed correctly to matlab)
* fixed bug with "calib" and "calib_var" (they were unusable because of flex misspecification)
* fixed segmentation fault with "estimated_params_bound" and "estimation_params_init"


git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1117 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-12-12 11:54:30 +00:00
sebastien 09c165f386 v4 parser: fixed bug related to non-associativity of POWER operator
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1113 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-11-28 15:14:14 +00:00
sebastien f84feddb02 v4 parser: added missing tokens in DynareFlex.ll; added error message for unrecognized characters; fixed minor bugs in DynareBison.yy
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1112 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-11-28 14:26:06 +00:00
sebastien 4e324b8410 v4 parser DynareFlex.ll: adding missing pound (#) token; removed catch-all rule
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1111 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-11-28 13:39:04 +00:00
sebastien d5ac5b1fbd v4 parser: created ModFile class, which is the abstract representation of a mod file; removed all static variables
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1110 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-11-28 11:56:02 +00:00
michel 2a63a0f0e8 v4 parser.src: Makefile for cross compilation on Linux with
CROSS_WIN32=yes
	       Uses i586-mingw32msvc-g++


git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1100 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-11-25 20:12:55 +00:00
michel d9e6129dc6 v4 parser.src: Makefile for cross compilaton
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1099 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-11-25 20:09:29 +00:00
michel f2b1f68e75 v4: prior_analysis, again
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1098 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-11-25 17:55:02 +00:00
sebastien 9ff865e84b v4 parser NumericalConstants.{cc,hh}: optimization to avoid multiple IDs for the same constant
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1094 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-11-23 19:10:41 +00:00
sebastien 56f54de49a v4 parser: removed Objects class; fixed memory leaks associated to parsing
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1093 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-11-22 19:01:40 +00:00
sebastien b36a248d85 v4 parser: merged Makefiles for Linux and Windows; switched to level 3 optimization (-O3)
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1086 ac1d8469-bf42-47a9-8791-bf33cf982152
2006-11-20 15:04:51 +00:00