parameters.h Source File
|
CPP API
|
glct_secir/parameters.h
Go to the documentation of this file.
71 Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(numExposed, -(FP)numExposed / timeExposed).asDiagonal();
116 Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(dimension, -(FP)dimension / time).asDiagonal();
141 Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(dimension, -(FP)dimension / time).asDiagonal();
186 Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(dimension, -(FP)dimension / time).asDiagonal();
211 Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(dimension, -(FP)dimension / time).asDiagonal();
256 Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(dimension, -(FP)dimension / time).asDiagonal();
281 Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(dimension, -(FP)dimension / time).asDiagonal();
306 Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(dimension, -(FP)dimension / time).asDiagonal();
351 Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(dimension, -(FP)dimension / time).asDiagonal();
376 Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(dimension, -(FP)dimension / time).asDiagonal();
485 StartingProbabilitiesInfectedNoSymptoms<FP>, TransitionMatrixInfectedNoSymptomsToInfectedSymptoms<FP>,
487 TransitionMatrixInfectedSymptomsToInfectedSevere<FP>, TransitionMatrixInfectedSymptomsToRecovered<FP>,
517 log_error("Constraint check: Parameter TransmissionProbabilityOnContact smaller {} or larger {}", 0, 1);
523 log_error("Constraint check: Parameter RelativeTransmissionNoSymptoms smaller {} or larger {}", 0, 1);
529 log_error("Constraint check: Parameter RiskOfInfectionFromSymptomatic smaller {} or larger {}", 0, 1);
533 if (this->template get<Seasonality<FP>>() < 0.0 || this->template get<Seasonality<FP>>() > 0.5) {
560 log_error("Constraint check: At least one of the matrices used for the TransitionMatrix parameters is not "
606 if ((!floating_point_equal<FP>(1., this->template get<StartingProbabilitiesExposed<FP>>().sum())) ||
607 (!floating_point_equal<FP>(1., this->template get<StartingProbabilitiesInfectedNoSymptoms<FP>>().sum())) ||
608 (!floating_point_equal<FP>(1., this->template get<StartingProbabilitiesInfectedSymptoms<FP>>().sum())) ||
609 (!floating_point_equal<FP>(1., this->template get<StartingProbabilitiesInfectedSevere<FP>>().sum())) ||
610 (!floating_point_equal<FP>(1., this->template get<StartingProbabilitiesInfectedCritical<FP>>().sum()))) {
612 "Constraint check: At least one of the vectors for the starting probabilities does not sum to one.");
621 log_warning("Constraint check: At least one of the vectors for the starting probabilities has at least one "
629 Eigen::VectorX<FP>::Ones(this->template get<TransitionMatrixExposedToInfectedNoSymptoms<FP>>().rows()))
633 "Constraint check: The entries of TransitionMatrixExposedToInfectedNoSymptoms lead to a negative "
642 log_warning("Constraint check: The entries of TransitionMatrixInfectedNoSymptomsToInfectedSymptoms lead to "
648 Eigen::VectorX<FP>::Ones(this->template get<TransitionMatrixInfectedNoSymptomsToRecovered<FP>>().rows()))
652 "Constraint check: The entries of TransitionMatrixInfectedNoSymptomsToRecovered lead to a negative "
662 "Constraint check: The entries of TransitionMatrixInfectedSymptomsToInfectedSevere lead to a negative "
667 Eigen::VectorX<FP>::Ones(this->template get<TransitionMatrixInfectedSymptomsToRecovered<FP>>().rows()))
671 "Constraint check: The entries of TransitionMatrixInfectedSymptomsToRecovered lead to a negative "
681 "Constraint check: The entries of TransitionMatrixInfectedSevereToInfectedCritical lead to a negative "
686 Eigen::VectorX<FP>::Ones(this->template get<TransitionMatrixInfectedSevereToDead<FP>>().rows()))
689 log_warning("Constraint check: The entries of TransitionMatrixInfectedSevereToDead lead to a negative "
694 Eigen::VectorX<FP>::Ones(this->template get<TransitionMatrixInfectedSevereToRecovered<FP>>().rows()))
697 log_warning("Constraint check: The entries of TransitionMatrixInfectedSevereToRecovered lead to a negative "
702 Eigen::VectorX<FP>::Ones(this->template get<TransitionMatrixInfectedCriticalToDead<FP>>().rows()))
705 log_warning("Constraint check: The entries of TransitionMatrixInfectedCriticalToDead lead to a negative "
710 Eigen::VectorX<FP>::Ones(this->template get<TransitionMatrixInfectedCriticalToRecovered<FP>>().rows()))
714 "Constraint check: The entries of TransitionMatrixInfectedCriticalToRecovered lead to a negative "
represents a collection of contact frequency matrices that whose sum is the total number of contacts.
Definition: contact_matrix.h:536
represents time dependent contact frequencies between groups.
Definition: contact_matrix.h:505
const ParameterTagTraits< Tag >::Type & get() const
get value of a parameter
Definition: parameter_set.h:262
The UncertainContactMatrix class consists of a ContactMatrix with fixed baseline and uncertain Dampin...
Definition: uncertain_matrix.h:43
static IOResult< Parameters > deserialize(IOContext &io)
deserialize an object of this class.
Definition: glct_secir/parameters.h:734
Parameters()
Default constructor.
Definition: glct_secir/parameters.h:501
bool check_constraints() const
Checks that all parameters satisfy their corresponding constraints and logs an error if constraints a...
Definition: glct_secir/parameters.h:512
Parameters(ParametersBase< FP > &&base)
Definition: glct_secir/parameters.h:723
A collection of classes to simplify handling of matrix shapes in meta programming.
Definition: models/abm/analyze_result.h:30
void log_warning(spdlog::string_view_t fmt, const Args &... args)
Definition: logging.h:126
auto success()
Create an object that is implicitly convertible to a succesful IOResult<void>.
Definition: io.h:360
void log_error(spdlog::string_view_t fmt, const Args &... args)
Definition: logging.h:114
boost::outcome_v2::unchecked< T, IOStatus > IOResult
Value-or-error type for operations that return a value but can fail.
Definition: io.h:354
Definition: io.h:95
The contact patterns within the society are modelled using an UncertainContactMatrix.
Definition: glct_secir/parameters.h:402
static Type get_default()
Definition: glct_secir/parameters.h:405
UncertainContactMatrix< FP > Type
Definition: glct_secir/parameters.h:403
The relative InfectedNoSymptoms infectability.
Definition: glct_secir/parameters.h:419
static Type get_default()
Definition: glct_secir/parameters.h:421
static std::string name()
Definition: glct_secir/parameters.h:425
The risk of infection from symptomatic cases in the GLCT-SECIR model.
Definition: glct_secir/parameters.h:433
static Type get_default()
Definition: glct_secir/parameters.h:435
static std::string name()
Definition: glct_secir/parameters.h:439
The seasonality in the GLCT-SECIR model.
Definition: glct_secir/parameters.h:470
static Type get_default()
Definition: glct_secir/parameters.h:472
static Type get_default(size_t)
Definition: glct_secir/parameters.h:454
Vector with the probability to start in any of the subcompartments of the Exposed compartment.
Definition: glct_secir/parameters.h:42
static Type get_default(size_t numExposed)
Default parameters can be used to get an Erlang distributed stay time in the Exposed compartment.
Definition: glct_secir/parameters.h:48
static std::string name()
Definition: glct_secir/parameters.h:54
Eigen::VectorX< FP > Type
Definition: glct_secir/parameters.h:43
Vector with the probability to start in any of the subcompartments of the InfectedCritical compartmen...
Definition: glct_secir/parameters.h:318
static Type get_default(size_t numInfectedCritical)
Default parameters can be used to get an Erlang distributed stay time in InfectedCritical compartment...
Definition: glct_secir/parameters.h:324
static std::string name()
Definition: glct_secir/parameters.h:330
Eigen::VectorX< FP > Type
Definition: glct_secir/parameters.h:319
Vector with the probability to start in any of the subcompartments of the InfectedNoSymptoms compartm...
Definition: glct_secir/parameters.h:83
Eigen::VectorX< FP > Type
Definition: glct_secir/parameters.h:84
static Type get_default(size_t numInfectedNoSymptoms)
Default parameters can be used to get an Erlang distributed stay time in InfectedNoSymptoms compartme...
Definition: glct_secir/parameters.h:89
static std::string name()
Definition: glct_secir/parameters.h:95
Vector with the probability to start in any of the subcompartments of the InfectedSevere compartment.
Definition: glct_secir/parameters.h:223
static Type get_default(size_t numInfectedSevere)
Default parameters can be used to get an Erlang distributed stay time in InfectedSevere compartment.
Definition: glct_secir/parameters.h:229
static std::string name()
Definition: glct_secir/parameters.h:235
Eigen::VectorX< FP > Type
Definition: glct_secir/parameters.h:224
Vector with the probability to start in any of the subcompartments of the InfectedSymptoms compartmen...
Definition: glct_secir/parameters.h:153
static std::string name()
Definition: glct_secir/parameters.h:165
Eigen::VectorX< FP > Type
Definition: glct_secir/parameters.h:154
static Type get_default(size_t numInfectedSymptoms)
Default parameters can be used to get an Erlang distributed stay time in InfectedSymptoms compartment...
Definition: glct_secir/parameters.h:159
Transition matrix of the Exposed compartment.
Definition: glct_secir/parameters.h:62
Eigen::MatrixX< FP > Type
Definition: glct_secir/parameters.h:63
static Type get_default(size_t numExposed, FP timeExposed=1.)
Default parameters can be used to get an Erlang distributed stay time in the Exposed compartment.
Definition: glct_secir/parameters.h:69
static std::string name()
Definition: glct_secir/parameters.h:75
Transition matrix of the phase-type distribution describing the stay time in the InfectedCritical com...
Definition: glct_secir/parameters.h:341
static Type get_default(size_t dimension, FP time=1.)
Default parameters can be used to get an Erlang distributed stay time in InfectedCritical compartment...
Definition: glct_secir/parameters.h:349
static std::string name()
Definition: glct_secir/parameters.h:355
Eigen::MatrixX< FP > Type
Definition: glct_secir/parameters.h:342
Transition matrix of the phase-type distribution describing the stay time in the InfectedCritical com...
Definition: glct_secir/parameters.h:366
static Type get_default(size_t dimension, FP time=1.)
Default parameters can be used to get an Erlang distributed stay time in InfectedCritical compartment...
Definition: glct_secir/parameters.h:374
static std::string name()
Definition: glct_secir/parameters.h:380
Eigen::MatrixX< FP > Type
Definition: glct_secir/parameters.h:367
Transition matrix of the phase-type distribution describing the stay time in the InfectedNoSymptoms c...
Definition: glct_secir/parameters.h:106
Eigen::MatrixX< FP > Type
Definition: glct_secir/parameters.h:107
static Type get_default(size_t dimension, FP time=1.)
Default parameters can be used to get an Erlang distributed stay time in InfectedNoSymptoms compartme...
Definition: glct_secir/parameters.h:114
static std::string name()
Definition: glct_secir/parameters.h:120
Transition matrix of the phase-type distribution describing the stay time in the InfectedNoSymptoms c...
Definition: glct_secir/parameters.h:131
static std::string name()
Definition: glct_secir/parameters.h:145
Eigen::MatrixX< FP > Type
Definition: glct_secir/parameters.h:132
static Type get_default(size_t dimension, FP time=1.)
Default parameters can be used to get an Erlang distributed stay time in InfectedNoSymptoms compartme...
Definition: glct_secir/parameters.h:139
Transition matrix of the phase-type distribution describing the stay time in the InfectedSevere compa...
Definition: glct_secir/parameters.h:271
static std::string name()
Definition: glct_secir/parameters.h:285
Eigen::MatrixX< FP > Type
Definition: glct_secir/parameters.h:272
static Type get_default(size_t dimension, FP time=1.)
Default parameters can be used to get an Erlang distributed stay time in InfectedSevere compartment b...
Definition: glct_secir/parameters.h:279
Transition matrix of the phase-type distribution describing the stay time in the InfectedSevere compa...
Definition: glct_secir/parameters.h:246
static std::string name()
Definition: glct_secir/parameters.h:260
Eigen::MatrixX< FP > Type
Definition: glct_secir/parameters.h:247
static Type get_default(size_t dimension, FP time=1.)
Default parameters can be used to get an Erlang distributed stay time in InfectedSevere compartment b...
Definition: glct_secir/parameters.h:254
Transition matrix of the phase-type distribution describing the stay time in the InfectedSevere compa...
Definition: glct_secir/parameters.h:296
static Type get_default(size_t dimension, FP time=1.)
Default parameters can be used to get an Erlang distributed stay time in InfectedSevere compartment b...
Definition: glct_secir/parameters.h:304
Eigen::MatrixX< FP > Type
Definition: glct_secir/parameters.h:297
static std::string name()
Definition: glct_secir/parameters.h:310
Transition matrix of the phase-type distribution describing the stay time in the InfectedNoSymptoms c...
Definition: glct_secir/parameters.h:176
static Type get_default(size_t dimension, FP time=1.)
Default parameters can be used to get an Erlang distributed stay time in the InfectedSymptoms compart...
Definition: glct_secir/parameters.h:184
static std::string name()
Definition: glct_secir/parameters.h:190
Eigen::MatrixX< FP > Type
Definition: glct_secir/parameters.h:177
Transition matrix of the phase-type distribution describing the stay time in the InfectedSymptoms com...
Definition: glct_secir/parameters.h:201
Eigen::MatrixX< FP > Type
Definition: glct_secir/parameters.h:202
static Type get_default(size_t dimension, FP time=1.)
Default parameters can be used to get an Erlang distributed stay time in the InfectedSymptoms compart...
Definition: glct_secir/parameters.h:209
static std::string name()
Definition: glct_secir/parameters.h:215
Probability of getting infected from a contact.
Definition: glct_secir/parameters.h:388
static Type get_default()
Definition: glct_secir/parameters.h:390
static std::string name()
Definition: glct_secir/parameters.h:394
Generated by