![]() |
LINE Solver (C++)
Templated C++ port of the LINE queueing solver
|
Classes | |
| struct | LqnsOptions |
| Knobs of the wrapper, the subset of SolverOptions that reaches lqns. More... | |
| struct | LqnsRawAvg |
| Everything the .lqxo carries, indexed as the struct is. More... | |
| struct | LqnsSolution |
| The six measures, on the element index space, with a defined mask each. More... | |
| struct | QnsOptions |
| SolverLQNS.defaultOptions on a flat Network plus the knobs the JMVA document carries. More... | |
| class | SolverLQNS |
| The layered model solved by lqns or lqsim. More... | |
Functions | |
| const std::string & | lqns_version () |
| The version banner of the local lqns, empty when there is none. | |
| int | lqns_major_version () |
| The major release number, 0 when no binary answered. | |
| bool | lqns_is_available () |
| True when lqns is installed AND is a release this port speaks. | |
| std::vector< std::string > | qns_methods () |
| Port of SolverLQNS.listValidMethods on a flat Network. | |
| bool | is_qns_method (const std::string &method) |
| True for qns and every qns.NAME. | |
| std::string | qns_multiserver (const std::string &method) |
| The multiserver approximation a Network method selects: the part after qns.
| |
| bool | is_qnsolver_multiserver (const std::string &m) |
| The approximations qnsolver -m accepts; the rest reach it only via LQNS. | |
| template<class T> | |
| std::string | qns_method_refusal (const qn::NetworkStruct< T > &L, const std::string &method) |
| SolverLQNS.supportsModelMethod's structural rules on a Network, as the REASON they refuse, empty when the pair is served. | |
| bool | qnsolver_is_available () |
| Port of SolverLQNS.hasQnsolver: a native qnsolver binary on the PATH. | |
| void | check_qns_method (const std::string &method) |
| Port of runAnalyzerNetwork's method gate. | |
| std::string | resolve_multiserver (const QnsOptions &opt) |
| Port of the method -> options.config.multiserver map of runAnalyzerNetwork.m. | |
| template<class T> | |
| void | check_qnsolver_supported (const qn::NetworkStruct< T > &L) |
| The gate runAnalyzer.m reaches through runAnalyzerChecks, narrowed to what the JMVA document can actually carry. | |
| template<class T> | |
| mva::AvgResult< T > | solve_network_run_analyzer (const qn::NetworkStruct< T > &L, const QnsOptions &opt) |
| Port of @@SolverLQNS/runAnalyzerNetwork.m and solver_qns.m: SolverLQNS on a flat Network. | |
|
inline |
Port of runAnalyzerNetwork's method gate.
Definition at line 197 of file lqns_qnsolver.h.
References check_qns_method(), line::InputError::InputError(), and qns_methods().
Referenced by check_qns_method(), and solve_network_run_analyzer().
| void line::lqns::check_qnsolver_supported | ( | const qn::NetworkStruct< T > & | L | ) |
The gate runAnalyzer.m reaches through runAnalyzerChecks, narrowed to what the JMVA document can actually carry.
The reference's feature set admits nodes – a Cache, a Place, a Transition – that writeJMVA then drops on the floor, and the tool answers a SMALLER model than the caller handed it with no indication that it did. A station the document cannot express is refused by name here instead.
Definition at line 305 of file lqns_qnsolver.h.
References check_qnsolver_supported(), line::qn::NetworkStruct< T >::has_priorities(), line::qn::NetworkStruct< T >::nodes, line::qn::NetworkStruct< T >::nstations, line::qn::NetworkStruct< T >::station_to_node, line::qn::NetworkStruct< T >::stations, and line::UnsupportedError::UnsupportedError().
Referenced by check_qnsolver_supported().
|
inline |
True for qns and every qns.NAME.
Definition at line 103 of file lqns_qnsolver.h.
References is_qns_method().
Referenced by is_qns_method(), and resolve_multiserver().
|
inline |
The approximations qnsolver -m accepts; the rest reach it only via LQNS.
Definition at line 123 of file lqns_qnsolver.h.
References is_qnsolver_multiserver().
Referenced by is_qnsolver_multiserver(), and qns_method_refusal().
|
inline |
True when lqns is installed AND is a release this port speaks.
LINE requires 6.0 or greater: the 5.x .lqxo grammar spells several result attributes differently, so an older binary would parse into a table of NaNs rather than fail, and the caller would read "not reported" as an answer.
Definition at line 69 of file lqns_probe.h.
References lqns_is_available(), and lqns_major_version().
Referenced by line::autosolver::auto_layered_is_available(), line::lqns::SolverLQNS< T >::is_available(), and lqns_is_available().
|
inline |
The major release number, 0 when no binary answered.
Definition at line 55 of file lqns_probe.h.
References lqns_major_version(), and lqns_version().
Referenced by lqns_is_available(), and lqns_major_version().
|
inline |
The version banner of the local lqns, empty when there is none.
Definition at line 49 of file lqns_probe.h.
References lqns_version().
Referenced by line::lqns::SolverLQNS< T >::has_local_binary(), lqns_major_version(), lqns_version(), and line::lqns::SolverLQNS< T >::version().
| std::string line::lqns::qns_method_refusal | ( | const qn::NetworkStruct< T > & | L, |
| const std::string & | method ) |
SolverLQNS.supportsModelMethod's structural rules on a Network, as the REASON they refuse, empty when the pair is served.
A STRING RATHER THAN A THROW, the shape ba::method_refusal and ag::runner_detail::method_refusal already carry: the AUTO report has to ASK the question without raising, so that a pair it offers is a pair the run accepts. solve_network_run_analyzer keeps the throws, which are the same two rules stated where the run reaches them.
Mirrors matlab/src/solvers/wrappers/LQNS/qns_immfeed_refusal.m and qns_multiserver_refusal.m, and the JAR's qnsImmfeedRefusal / qnsMultiserverRefusal.
Definition at line 142 of file lqns_qnsolver.h.
References line::qn::NetworkStruct< T >::has_immediate_feedback(), is_qnsolver_multiserver(), line::qn::NetworkStruct< T >::nstations, qns_method_refusal(), qns_multiserver(), and line::qn::NetworkStruct< T >::stations.
Referenced by line::autosolver::auto_family_refusal(), and qns_method_refusal().
|
inline |
Port of SolverLQNS.listValidMethods on a flat Network.
Definition at line 97 of file lqns_qnsolver.h.
References qns_methods().
Referenced by line::autosolver::auto_family_methods(), check_qns_method(), and qns_methods().
|
inline |
The multiserver approximation a Network method selects: the part after qns.
, or default for default and qns. This bare name is what the engine speaks, and what the JMVA document and the -m switch carry.
Definition at line 115 of file lqns_qnsolver.h.
References qns_multiserver().
Referenced by qns_method_refusal(), qns_multiserver(), resolve_multiserver(), and solve_network_run_analyzer().
|
inline |
Port of SolverLQNS.hasQnsolver: a native qnsolver binary on the PATH.
There is no container fallback, here as in the other three codebases: qnsolver ships with LQNS, whose licence forbids providing the software to another party, so no LINE code path resolves or runs an image carrying it.
Definition at line 189 of file lqns_qnsolver.h.
References line::util::capture(), line::util::ProcResult::exitCode, and qnsolver_is_available().
Referenced by qnsolver_is_available().
|
inline |
Port of the method -> options.config.multiserver map of runAnalyzerNetwork.m.
Either spelling of the method is taken: the qns name or the bare name the engine speaks.
default resolves to rolia, as runAnalyzerNetwork.m does. THE REFERENCE HAS TWO ENTRY POINTS AND THEY DISAGREE on an explicit config: runAnalyzerNetwork.m overwrites options.config.multiserver unconditionally at method default, so a MATLAB caller who sets it through the solver constructor is silently ignored, while solver_qns.m called directly honours it and maps its own default to CONWAY. This resolves the pair the only way that is a superset of neither: the method wins when named, an explicit config is honoured (the low-level reference's behaviour, and the only way a caller can express the choice at all), and an unset one gives rolia (the high-level reference's). Native Python currently leaves default at CONWAY here, which is a genuine divergence from MATLAB and the JAR; see the report accompanying this audit.
Definition at line 222 of file lqns_qnsolver.h.
References is_qns_method(), qns_multiserver(), and resolve_multiserver().
Referenced by resolve_multiserver().
| mva::AvgResult< T > line::lqns::solve_network_run_analyzer | ( | const qn::NetworkStruct< T > & | L, |
| const QnsOptions & | opt ) |
Port of @@SolverLQNS/runAnalyzerNetwork.m and solver_qns.m: SolverLQNS on a flat Network.
The caller's qns method name is translated to the bare approximation name the engine speaks, and the engine's label is reported back under the qns names: qns.NAME, default/qns.NAME (a bare default stays as it is).
| L | the refreshed struct |
| opt | the method, the multiserver rule and the JMVA sample cap |
Definition at line 625 of file lqns_qnsolver.h.
References line::mva::AvgResult< T >::actualmethod, check_qns_method(), line::lqns::QnsOptions::method, line::mva::AvgResult< T >::method, qns_multiserver(), and solve_network_run_analyzer().
Referenced by solve_network_run_analyzer().