Sébastien Villemot
15b6e6e6b3
MEX files: no longer use “virtual” keyword when overriding a method
...
Automatically detected by clang-tidy with modernize-use-override check.
2023-12-06 22:24:55 +01:00
Sébastien Villemot
d82eecfd39
C++11 modernization: use std::array and std::vector instead of C arrays
...
Automatically detected by clang-tidy using modernize-avoid-c-arrays check.
2023-12-06 22:24:52 +01:00
Sébastien Villemot
11c1f6175e
Add [[nodiscard]] attribute to various functions
...
Automatically detected using clang-tidy with modernize-use-nodiscard check.
2023-12-05 15:44:23 +01:00
Sébastien Villemot
857e5b00f5
C++ modernization: pass by value and use std::move when relevant
...
Automatically detected and fixed using clang-tidy with modernize-pass-by-value
check.
2023-12-04 18:20:43 +01:00
Sébastien Villemot
c6a7801ba8
clang-format configuration: set “PackConstructorInitializers: NextLine”
2023-11-30 14:37:05 +01:00
Sébastien Villemot
ed332e3ba1
MEX files: reformat C++ source code using clang-format 15
2023-11-29 19:00:51 +01:00
Sébastien Villemot
70866c7b70
Remove warnings about comparison of integer expressions of different signedness (-Wsign-compare)
2023-09-20 16:48:29 +02:00
Normann Rion
710589eb5b
Adds pruning in k_order_simul
...
See issue #1643 about beyond-third-order pruning
2023-07-20 06:58:35 +01:00
Sébastien Villemot
c3e1480a52
C++17 modernization: use std::extent_v to get raw arrays size
...
This can prevent mistakes when the array is modified.
2023-01-24 13:43:02 +01:00
Sébastien Villemot
218bb1a15f
k_order_welfare MEX: check number of arguments
2022-07-05 11:55:40 +02:00
Sébastien Villemot
ce2c1e0d30
No longer use C++ UTF-8 string literals
...
They don’t bring any added value, and break compilation in C++20 mode (because
they are then of type “const char8_t *” which is distinct from “const char *”).
2022-05-04 18:32:52 +02:00
Sébastien Villemot
d5472d2338
Tighten input sanity checks of various MEX files
...
Note that the unitary test in lyapunov_solver.m that checks sparse matrix input
had to be removed. Previously, this test was passing by chance (because the
sparse test matrices had actually no zero element, hence the internal double
float storage was the same as in the dense case). Now it consistently fails
with the additional checks in disclyap_fast MEX.
2022-03-18 22:49:46 +01:00
Normann Rion
cf829fb28e
A few fixes for k-order welfare assesment in `evaluate_planner_objective`
...
As suggested in !1962
2021-12-07 12:19:30 +01:00
NormannR
f889a25e86
Amend the k_order_welfare routine for it to return the adequate output variables
2021-11-24 17:16:03 +01:00
Johannes Pfeifer
66dcef2754
k_order_welfare.cc: remove gratuitous screen output
2021-07-22 15:12:59 +02:00
Normann Rion
3d27672c58
kth-order approximation of conditional welfare
...
Partially addresses issue #1680 :
- unconditional welfare resorts to dynare++ simulation tools, which shall be updated very soon
TO DO:
- implement a function computing kth-order approximation of simulated moments of y
2021-06-15 15:04:31 +02:00