Commit Graph

60 Commits (7dd2dd5e24a343fbeaf3522ea5e535c27d8b9f95)

Author SHA1 Message Date
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
Sébastien Villemot 757a9067c0 Global reindentation of MATLAB files 2011-02-04 17:17:48 +01:00
George Perendia 595675d333 Partial information changes that make adjustment for Octave and use rcond() < 1e-8 ..." to determine if a matrix is invertible plus some minor bug and formatting changes in dr1_PI.m 2011-01-17 20:40:41 +00:00
George Perendia 17bc655159 Partial Information: Update with improved, generalised recursive PCL solution method 2011-01-11 21:57:57 +00:00
George Perendia e8a193bbfb Track #21: Add partial information: Correcting bug stemming from the differences in QZ calculation under Octave and Matlab: modified PI_gensys to use C.Sims' Lapack zgges based qzcomplex() qz decomposition routine under Octave which gives nearly identical complex results to Matlab QZ (except for transpose of q matrix and few sign changes in the output matrices) 2010-10-20 11:50:06 +01:00
Sébastien Villemot a5b8819518 Partial information: added missing copyright notice 2010-10-11 17:16:52 +02:00
Sébastien Villemot 44b268ec67 Moved qzdiv.m and qzswitch.m to top-level (they are now used by both partial information code and mjdgges.m) 2010-10-11 17:14:33 +02:00
Sébastien Villemot cf9f901ef8 Partial information: moved disclyap_fast to the partial_information subdir 2010-10-11 17:11:05 +02:00
Sébastien Villemot 8849dd2bc9 Partial info/Octave compatibility fix: ismember() does not work with char arrays under Octave 2010-10-11 16:48:16 +02:00
Sébastien Villemot d6c035aaea Partial info/Octave compatibility fix: operator "|" never short-circuit, use "||" instead 2010-10-11 16:47:36 +02:00