![]() |
LINE Solver (C++)
Templated C++ port of the LINE queueing solver
|
The options SolverMAM reads. More...
#include <line/solvers/mam/mam_types.h>
Public Member Functions | |
| bool | preserve_det_resolved () const |
| preserve_det with the reference's method-dependent default applied, and the ONLY spelling any analyzer should read. | |
Public Attributes | |
| std::string | method = "default" |
| double | tol = 1e-4 |
| int | iter_max = 100 |
| SolverOptions('MAM') lowers this from the global 1000 to 100. | |
| std::size_t | space_max = 128 |
| options.config.space_max: the order budget of the per-station arrival superposition, handed to mmap_super_safe. | |
| std::optional< bool > | preserve_det |
| options.config.preserveDet: keep a Det service as Det so the exact MAP/D/c solver can claim it, instead of Erlang-approximating it. | |
| std::size_t | nonmkv_order = 20 |
| options.config.nonmkvorder: the phase budget sn_nonmarkov_toph spends replacing a non-Markovian service law. | |
| bool | phfit_cme = true |
| options.config.phfit: true selects the two-moment concentrated-ME fit (the reference default), false the Bernstein density fit. | |
| std::size_t | num_cdf_pts = 200 |
| options.config.num_cdf_pts: how many points the response-time CDF is evaluated at. | |
| std::size_t | cutoff = 0 |
| options.cutoff: the level truncation getProb / getProbMarg use for an OPEN model, where the queue length is unbounded. | |
| std::size_t | bgstates_max = 0 |
| options.config.bgstates_max: the cap on the number of states of the bgchain background chain, which enumerates the closed-class population vector and so grows as nchoosek(N+Mc-1,Mc-1) per background class. | |
| std::size_t | bgaggr = 0 |
| options.config.bgaggr: the number G of AGGREGATE background classes the bgchain method carries, so the chain has 1 + G classes. | |
| std::size_t | qbdphases_max = 0 |
| options.config.qbdphases_max: the cap on the phase count of one bgchain station QBD, the product (arrival order) x (environment states) x (service phases). | |
| std::size_t | fj_accuracy = 100 |
| options.config.fj_accuracy: the FJ_codes truncation C of the queue-length DIFFERENCE between the two fork-join branches. | |
| std::string | fj_tmode = "NARE" |
| options.config.fj_tmode: which route computeT.m takes to the T matrix, 'NARE' (Riccati, the reference default) or 'Sylves' (the fixed-point iteration of Section 5.1). | |
| std::string | timescale = "auto" |
| options.config.timescale: "auto", "discrete" or "continuous". | |
| double | slotlength = 1.0 |
| options.config.slotlength: the slot in model time units. | |
| double | timespan_start = 0.0 |
| options.timespan: the transient horizon. | |
| double | timespan_end = std::numeric_limits<double>::infinity() |
The options SolverMAM reads.
Defaults are SolverOptions('MAM').
Definition at line 30 of file mam_types.h.
|
inline |
preserve_det with the reference's method-dependent default applied, and the ONLY spelling any analyzer should read.
'bgchain' builds a phase-type MIXTURE of the open service laws and has no deterministic-service branch at all, so a Det that survives to it arrives with no (D0,D1) pair to mix. It therefore needs the Det FITTED to PH, which is what solver_mam_analyzer.m:47 says by defaulting preserveDet to ~strcmpi(options.method,'bgchain'). Every other method wants the Det preserved so the exact MAP/D/c branch can claim it.
The method name is compared exactly, not case-insensitively as the reference's strcmpi does, because check_method has already refused anything that is not one of list_valid_methods' lowercase names by the time an analyzer reads this.
Definition at line 143 of file mam_types.h.
References method, and preserve_det.
| std::size_t line::mam::MamOptions::bgaggr = 0 |
options.config.bgaggr: the number G of AGGREGATE background classes the bgchain method carries, so the chain has 1 + G classes.
G = 1 is the classic tagged/aggregate pair and the default; G >= R-1 aggregates nothing and carries every closed chain exactly. 0 selects the default of 1.
Definition at line 91 of file mam_types.h.
| std::size_t line::mam::MamOptions::bgstates_max = 0 |
options.config.bgstates_max: the cap on the number of states of the bgchain background chain, which enumerates the closed-class population vector and so grows as nchoosek(N+Mc-1,Mc-1) per background class.
0 selects the default of 20000. Exceeding it is a named error, not a silent degradation.
Definition at line 84 of file mam_types.h.
| std::size_t line::mam::MamOptions::cutoff = 0 |
options.cutoff: the level truncation getProb / getProbMarg use for an OPEN model, where the queue length is unbounded.
0 selects the reference's default of 100.
Definition at line 76 of file mam_types.h.
| std::size_t line::mam::MamOptions::fj_accuracy = 100 |
options.config.fj_accuracy: the FJ_codes truncation C of the queue-length DIFFERENCE between the two fork-join branches.
Larger is more accurate and costs (C + 1) m^2 ma in every matrix dimension; the reference default is 100.
Definition at line 104 of file mam_types.h.
| std::string line::mam::MamOptions::fj_tmode = "NARE" |
options.config.fj_tmode: which route computeT.m takes to the T matrix, 'NARE' (Riccati, the reference default) or 'Sylves' (the fixed-point iteration of Section 5.1).
Definition at line 110 of file mam_types.h.
| int line::mam::MamOptions::iter_max = 100 |
SolverOptions('MAM') lowers this from the global 1000 to 100.
Definition at line 34 of file mam_types.h.
Referenced by line::mam::solver_mam_basic_mmap_closed().
| std::string line::mam::MamOptions::method = "default" |
Definition at line 31 of file mam_types.h.
Referenced by preserve_det_resolved().
| std::size_t line::mam::MamOptions::nonmkv_order = 20 |
options.config.nonmkvorder: the phase budget sn_nonmarkov_toph spends replacing a non-Markovian service law.
The reference default is 20.
Definition at line 56 of file mam_types.h.
| std::size_t line::mam::MamOptions::num_cdf_pts = 200 |
options.config.num_cdf_pts: how many points the response-time CDF is evaluated at.
The GLOBAL default is 200, not the 100 that solver_mam_passage_time.m's own fallback names – the fallback is dead, because SolverOptions always sets the field. Measured: MATLAB returns 200 rows for a model whose options.config was never touched.
Definition at line 70 of file mam_types.h.
| bool line::mam::MamOptions::phfit_cme = true |
options.config.phfit: true selects the two-moment concentrated-ME fit (the reference default), false the Bernstein density fit.
MAM consumes a matrix exponential happily, so the default stands here.
Definition at line 62 of file mam_types.h.
| std::optional<bool> line::mam::MamOptions::preserve_det |
options.config.preserveDet: keep a Det service as Det so the exact MAP/D/c solver can claim it, instead of Erlang-approximating it.
EMPTY MEANS NOT GIVEN, which is the whole point of the optional. The reference defaults the field only when the caller left it unset (solver_mam_analyzer.m:43-47), and the default it picks is METHOD-DEPENDENT, so a plain = true here is not the same thing: it cannot say "on unless bgchain" and cannot let an explicit request win.
Definition at line 51 of file mam_types.h.
Referenced by preserve_det_resolved().
| std::size_t line::mam::MamOptions::qbdphases_max = 0 |
options.config.qbdphases_max: the cap on the phase count of one bgchain station QBD, the product (arrival order) x (environment states) x (service phases).
0 selects the default of 500.
Definition at line 97 of file mam_types.h.
| double line::mam::MamOptions::slotlength = 1.0 |
options.config.slotlength: the slot in model time units.
Definition at line 118 of file mam_types.h.
| std::size_t line::mam::MamOptions::space_max = 128 |
options.config.space_max: the order budget of the per-station arrival superposition, handed to mmap_super_safe.
dec.poisson is exactly this set to 1, which collapses every stream to marked Poisson.
Definition at line 40 of file mam_types.h.
Referenced by line::mam::solver_mam_basic_mmap_closed().
| std::string line::mam::MamOptions::timescale = "auto" |
options.config.timescale: "auto", "discrete" or "continuous".
"auto" lets the distributions decide whether the model is slotted; the other two force the reading and raise when the model does not admit it.
Definition at line 116 of file mam_types.h.
| double line::mam::MamOptions::timespan_end = std::numeric_limits<double>::infinity() |
Definition at line 125 of file mam_types.h.
| double line::mam::MamOptions::timespan_start = 0.0 |
options.timespan: the transient horizon.
SolverOptions('MAM') defaults it to [Inf, Inf], i.e. steady state only, and runAnalyzer treats a finite upper bound as the request for a transient solve.
Definition at line 124 of file mam_types.h.
| double line::mam::MamOptions::tol = 1e-4 |
Definition at line 32 of file mam_types.h.