Commit Graph

69 Commits (master)

Author SHA1 Message Date
Sébastien Villemot a623cb1d12
Partial information: use the sparse representation of the static model 2024-02-07 13:57:24 +01:00
Stéphane Adjemian (Ryûk) 4982ce06b4
Remove unnecessary square brackets. 2023-12-18 10:49:49 +01:00
Stéphane Adjemian (Ryûk) 735bd66d4d
Remove unused output arguments. 2023-12-18 07:48:27 +01:00
Stéphane Adjemian (Ryûk) c841f1474c
isinf(X)~= ⇔ isinf(X). 2023-12-17 08:30:56 +01:00
Stéphane Adjemian (Guts) 44119077db
Separate outputs with commas. 2023-12-15 16:55:24 +01:00
Sébastien Villemot e4a4d2d8e6
Bytecode MEX: get M_ and options_ through input arguments rather than as global variables 2023-10-11 18:50:32 -04:00
Johannes Pfeifer cbf57b1af6
set_state_space.m: remove unused options_ input argument 2023-10-11 09:30:45 -04:00
Johannes Pfeifer ed7fe89bfa Remove unused exo_names_orig_ord 2023-06-23 08:41:12 -04:00
Sébastien Villemot 421eb1482c
Octave compatibility: qz() will be MATLAB-compatible in version 9
[skip ci]
2023-04-07 10:26:54 +02:00
Sébastien Villemot 10af04c6d8
Use Unicode copyright symbol (in UTF-8 encoding) in all source files
It is now supported by the MATLAB editor (as of R2022a).

The old ASCII notation is left in some files that we copy as-is from other
sources (e.g. in the contrib/ and m4/ subdirectories).

The particles submodule is not updated at this point, because it is in an
inconsistent state.

[skip ci]
2022-04-13 14:54:25 +02:00
Stéphane Adjemian (Ryûk) ff9cf3814a
Remove useless copies of options_. 2022-04-10 22:17:45 +02:00
Stéphane Adjemian (Charybdis) f1aff2b370
Remove calls to dbstack in dynare_solve.
Adding three input parameters for maxit, tolf and tolx.

Closes #1841.
2022-04-10 20:29:57 +02:00
Johannes Pfeifer 440a0e460b
Storage of results: use subfolder
Ref. #1758
2021-07-23 14:12:17 +02:00
Sébastien Villemot 766fff88f6
Use secure URL for link to GNU licenses 2021-06-09 17:35:05 +02:00
Sébastien Villemot dc6e3406e5 Merge branch 'tolerance' into 'master'
Correctly distinguish tolerance between steady and perfect foresight

See merge request Dynare/dynare!1746
2020-07-07 09:46:28 +00:00
Johannes Pfeifer 607a273bb0 Correctly distinguish tolerance between steady and perfect foresight
steady uses options_.solve_tolf as a termination criterion, so subsequent checks should do the same. Similarly, solve_tolx was never used.
2020-07-06 13:11:23 +02:00
Johannes Pfeifer 287ec91982 disclyap_fast.m: bugfixes and improvements
- loop termination criterion did not match subsequent check
- dimensions of NaN were incorrect
- exitflag was mostly meaningless due to erroring out
- Make max_iter an optional input
- Move file from partial information folder to Matlab
2020-06-30 16:43:00 +02:00
Sébastien Villemot 7e770f69e7
Remove workaround for errors in MEX files
Because at some point throwing exceptions from MEX files (with mexErrMsgTxt())
was not working under Windows 64-bit, we had designed a workaround to avoid
using exceptions.

Most MEX files were returning an error code as their first (or sometimes last)
argument, and that code would have to be checked from the MATLAB code.

Since this workaround is no longer needed, this commit removes it. As a
consequence, the interface of many MEX files is modified.

For some background, see https://www.dynare.org/pipermail/dev/2010-September/000895.html
2020-01-10 18:33:11 +01:00
Sébastien Villemot 49dc997073
Global reindentation of MATLAB code (excluding submodules)
Also convert to Unix end-of-lines, and remove trailing whitespaces.
2019-12-20 16:30:27 +01:00
Sébastien Villemot 89a3e94cbf
Use true/false instead of 1/0 for boolean options
This is more elegant, and makes it easier to distinguish them from integer
options.

Also simplify test expressions for these boolean options.
2019-03-19 15:21:16 +01:00
Sébastien Villemot 7a75872f72
Modernization: use tilde (~) syntax for ignored output arguments 2018-11-13 18:02:09 +01:00
Sébastien Villemot 87bb0c6997 Fix mistake in previous commit w.r.t. steadystate file 2018-06-27 17:15:13 +02:00
Sébastien Villemot a1b8bd39b2 Move the location of various generated files on the filesystem
- M and MEX files are now under +${MODELNAME}/
- bytecode, C source and JSON now under ${MODELNAME}/model/
2018-06-27 17:03:39 +02:00
Sébastien Villemot 02084ce310 Remove qzcomplex Oct-file
It's actually not needed. The QZ complex decomposition can be obtained in
Octave on real matrices by casting them to the complex type.
2018-05-17 12:11:15 +02:00
Sébastien Villemot 14fbfa028b Move qzdiv.m and qzswitch.m to partial_information/ subdir
They are no longer used in the main codebase.
2018-05-16 17:12:48 +02:00
Stéphane Adjemian (Scylla) 7be8f10e0e Use cells of strings instead of char arrays. 2018-01-09 22:30:01 +01:00
Stéphane Adjemian (Charybdis) 1bf81c9f5a Fixed copyright notices. 2017-05-18 18:36:38 +02:00
Stéphane Adjemian (Charybdis) 5417b27ac7 Fixed indentation of matlab files. 2017-05-16 15:10:20 +02:00
Stéphane Adjemian (Charybdis) a53636e24e Fixed copyright notices. 2017-05-16 14:11:15 +02:00
Stéphane Adjemian (Charybdis) 88e1701289 Removed useless commas and semicolons. 2017-05-16 13:24:46 +02:00
Johannes Pfeifer 2c5b1fed2d Use master function lyapunov_solver.m to call individual solvers 2017-01-04 11:25:44 +01:00
Johannes Pfeifer 9b82c72e4f Remove global options structure from dyntable 2016-06-14 11:52:17 +02:00
Johannes Pfeifer aee579ecc1 Add iteration maximum to disclyap_fast.m prevent infinite loops 2015-07-22 15:08:25 +02:00
Michel Juillard 1b822a9105 fix calls to dynare_solve() when Jacobian of function must be computed
numerically. Fix call to dynare_solve() in simulation_core()
2015-05-26 15:51:09 +02:00
Michel Juillard f03839cf12 removed "global options_" in dynare_solve.m and made it an
argument. Modified all calling functions.
2015-05-25 17:15:09 +02:00
Sébastien Villemot 66c1aa78f0 Move add_auxiliary_variables_to_steadystate to partial_information directory.
This function is obsolete, but the PI solver still uses it, so make that
relationship explicit.
2014-01-28 17:48:08 +01:00
Stéphane Adjemian (Charybdis) ddd95361ba Cosmetic changes. Added isoctave function to replace exist('OCTAVE_VERSION'). 2013-11-04 10:54:45 +01:00
Sébastien Villemot c121aa14b1 Remove oo_.dr.{nstatic,npred,nboth,nfwrd,nspred,nsfwrd}
Replace them by equivalents in M_ (and an extra one: M_.dynamic).

IMPORTANT POINT: oo_.dr.npred used to count both purely backward and mixed/both
variables. This was the cause of lots of confusion. The new M_.npred only
counts purely backward variables.

We now have the following indentities:

M_.npred + M_.nboth + M_.nfwrd + M_.nstatic = M_.endo_nbr
M_.nspred = M_.npred + M_.nboth
M_.nsfwrd = M_.nfwrd + M_.nboth
M_.ndynamic = M_.npred + M_.nboth + M_.nfwrd
2012-11-16 20:05:13 +01:00
Sébastien Villemot ddbeb8ceaa Remove unused oo_.dr.kae, oo_.dr.kad 2012-11-16 17:51:25 +01:00
Stéphane Adjemian (Charybdis) 1fb89a07e9 Removed global from set_state_space. 2012-07-03 11:29:18 +02:00
Sébastien Villemot 1f9cea669a Update copyright notices 2012-06-08 18:22:34 +02:00
Sébastien Villemot 1dfba1b99f Merge remote-tracking branch 'ferhat/master' 2012-04-20 21:15:09 +02:00
Ferhat eed54fb08a - Adds new algorithms to solve Lyapunov equations: Doubling algorithm and Square root solver. Their respective names are "doubling" and "square_root_solver".
- Adds the tolerance criteria for the iterative solvers (sylvester_fixed_point_tol, lyapunov_fixed_point_tol and lyapunov_doubling_tol)
- Updates the reference manual
2012-04-20 19:23:00 +02:00
Sébastien Villemot edbf3bd175 Remove useless calls to set_default_option 2012-04-20 17:08:11 +02:00
Stéphane Adjemian (Charybdis) a36cf30118 Make options_.dynatol specific to x/f by adding dynatol.x and dynatol.f. By default dynatol.x=dynatol.f= old default value of dynatol. 2011-12-12 14:20:14 +01:00
Sébastien Villemot 181186a205 Patch from George: fixes bug in partial information (closes #179) 2011-05-02 10:25:25 +02:00
Michel Juillard 55bb27c5f6 new correction for steady_state operator bug. Steady_state vector is passed as argument to *_dynamic model function. As a result, bytecode is currently broken. 2011-03-13 17:06:57 +01:00
Sébastien Villemot a153f81156 Partial information:
- fix various bugs
- do not fallback on full information in case of error, this is confusing
2011-02-22 14:46:24 +01:00
Houtan Bastani 43479f6ef3 use short-circuit ops (|| and &&) as opposed to (| and &) to avoid warnings in Octave (and save time) 2011-02-10 15:54:23 +01:00
Sébastien Villemot 02652f6eb8 Updated copyright notices 2011-02-04 17:27:33 +01:00