parameters.h Source File

CPP API: parameters.h Source File
glct_secir/parameters.h
Go to the documentation of this file.
1 /*
2 * Copyright (C) 2020-2026 MEmilio
3 *
4 * Authors: Lena Ploetzke
5 *
6 * Contact: Martin J. Kuehn <Martin.Kuehn@DLR.de>
7 *
8 * Licensed under the Apache License, Version 2.0 (the "License");
9 * you may not use this file except in compliance with the License.
10 * You may obtain a copy of the License at
11 *
12 * http://www.apache.org/licenses/LICENSE-2.0
13 *
14 * Unless required by applicable law or agreed to in writing, software
15 * distributed under the License is distributed on an "AS IS" BASIS,
16 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 * See the License for the specific language governing permissions and
18 * limitations under the License.
19 */
20 
21 #ifndef MIO_GLCT_SECIR_PARAMS_H
22 #define MIO_GLCT_SECIR_PARAMS_H
23 
24 #include "memilio/config.h"
26 #include "memilio/math/eigen.h"
29 #include "memilio/utils/logging.h"
30 
31 namespace mio
32 {
33 namespace glsecir
34 {
35 
36 /***********************************************
37 * Define Parameters of the GLCT-SECIHURD model *
38 ***********************************************/
39 
41 template <typename FP>
43  using Type = Eigen::VectorX<FP>;
48  static Type get_default(size_t numExposed)
49  {
50  Eigen::VectorX<FP> def = Eigen::VectorX<FP>::Zero(numExposed);
51  def[0] = 1.;
52  return def;
53  }
54  static std::string name()
55  {
56  return "StartingProbabilitiesExposed";
57  }
58 };
59 
61 template <typename FP>
63  using Type = Eigen::MatrixX<FP>;
69  static Type get_default(size_t numExposed, FP timeExposed = 1.)
70  {
71  Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(numExposed, -(FP)numExposed / timeExposed).asDiagonal();
72  def.diagonal(1).setConstant((FP)numExposed / timeExposed);
73  return def;
74  }
75  static std::string name()
76  {
77  return "TransitionMatrixExposedToInfectedNoSymptoms";
78  }
79 };
80 
82 template <typename FP>
84  using Type = Eigen::VectorX<FP>;
89  static Type get_default(size_t numInfectedNoSymptoms)
90  {
91  Eigen::VectorX<FP> def = Eigen::VectorX<FP>::Zero(numInfectedNoSymptoms);
92  def[0] = 1.;
93  return def;
94  }
95  static std::string name()
96  {
97  return "StartingProbabilitiesInfectedNoSymptoms";
98  }
99 };
100 
105 template <typename FP>
107  using Type = Eigen::MatrixX<FP>;
114  static Type get_default(size_t dimension, FP time = 1.)
115  {
116  Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(dimension, -(FP)dimension / time).asDiagonal();
117  def.diagonal(1).setConstant((FP)dimension / time);
118  return def;
119  }
120  static std::string name()
121  {
122  return "TransitionMatrixInfectedNoSymptomsToInfectedSymptoms";
123  }
124 };
125 
130 template <typename FP>
132  using Type = Eigen::MatrixX<FP>;
139  static Type get_default(size_t dimension, FP time = 1.)
140  {
141  Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(dimension, -(FP)dimension / time).asDiagonal();
142  def.diagonal(1).setConstant((FP)dimension / time);
143  return def;
144  }
145  static std::string name()
146  {
147  return "TransitionMatrixInfectedNoSymptomsToInfectedSymptomsToRecovered";
148  }
149 };
150 
152 template <typename FP>
154  using Type = Eigen::VectorX<FP>;
159  static Type get_default(size_t numInfectedSymptoms)
160  {
161  Eigen::VectorX<FP> def = Eigen::VectorX<FP>::Zero(numInfectedSymptoms);
162  def[0] = 1.;
163  return def;
164  }
165  static std::string name()
166  {
167  return "StartingProbabilitiesInfectedSymptoms";
168  }
169 };
170 
175 template <typename FP>
177  using Type = Eigen::MatrixX<FP>;
184  static Type get_default(size_t dimension, FP time = 1.)
185  {
186  Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(dimension, -(FP)dimension / time).asDiagonal();
187  def.diagonal(1).setConstant((FP)dimension / time);
188  return def;
189  }
190  static std::string name()
191  {
192  return "TransitionMatrixInfectedSymptomsToInfectedSevere";
193  }
194 };
195 
200 template <typename FP>
202  using Type = Eigen::MatrixX<FP>;
209  static Type get_default(size_t dimension, FP time = 1.)
210  {
211  Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(dimension, -(FP)dimension / time).asDiagonal();
212  def.diagonal(1).setConstant((FP)dimension / time);
213  return def;
214  }
215  static std::string name()
216  {
217  return "TransitionMatrixInfectedSymptomsToRecovered";
218  }
219 };
220 
222 template <typename FP>
224  using Type = Eigen::VectorX<FP>;
229  static Type get_default(size_t numInfectedSevere)
230  {
231  Eigen::VectorX<FP> def = Eigen::VectorX<FP>::Zero(numInfectedSevere);
232  def[0] = 1.;
233  return def;
234  }
235  static std::string name()
236  {
237  return "StartingProbabilitiesInfectedSevere";
238  }
239 };
240 
245 template <typename FP>
247  using Type = Eigen::MatrixX<FP>;
254  static Type get_default(size_t dimension, FP time = 1.)
255  {
256  Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(dimension, -(FP)dimension / time).asDiagonal();
257  def.diagonal(1).setConstant((FP)dimension / time);
258  return def;
259  }
260  static std::string name()
261  {
262  return "TransitionMatrixInfectedSevereToInfectedCritical";
263  }
264 };
265 
270 template <typename FP>
272  using Type = Eigen::MatrixX<FP>;
279  static Type get_default(size_t dimension, FP time = 1.)
280  {
281  Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(dimension, -(FP)dimension / time).asDiagonal();
282  def.diagonal(1).setConstant((FP)dimension / time);
283  return def;
284  }
285  static std::string name()
286  {
287  return "TransitionMatrixInfectedSevereToRecovered";
288  }
289 };
290 
292 template <typename FP>
294  using Type = Eigen::VectorX<FP>;
299  static Type get_default(size_t numInfectedCritical)
300  {
301  Eigen::VectorX<FP> def = Eigen::VectorX<FP>::Zero(numInfectedCritical);
302  def[0] = 1.;
303  return def;
304  }
305  static std::string name()
306  {
307  return "StartingProbabilitiesInfectedCritical";
308  }
309 };
310 
315 template <typename FP>
317  using Type = Eigen::MatrixX<FP>;
324  static Type get_default(size_t dimension, FP time = 1.)
325  {
326  Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(dimension, -(FP)dimension / time).asDiagonal();
327  def.diagonal(1).setConstant((FP)dimension / time);
328  return def;
329  }
330  static std::string name()
331  {
332  return "TransitionMatrixInfectedCriticalToDead";
333  }
334 };
335 
340 template <typename FP>
342  using Type = Eigen::MatrixX<FP>;
349  static Type get_default(size_t dimension, FP time = 1.)
350  {
351  Eigen::MatrixX<FP> def = Eigen::VectorX<FP>::Constant(dimension, -(FP)dimension / time).asDiagonal();
352  def.diagonal(1).setConstant((FP)dimension / time);
353  return def;
354  }
355  static std::string name()
356  {
357  return "TransitionMatrixInfectedCriticalToRecovered";
358  }
359 };
360 
362 template <typename FP>
364  using Type = FP;
365  static Type get_default()
366  {
367  return Type(1.0);
368  }
369  static std::string name()
370  {
371  return "TransmissionProbabilityOnContact";
372  }
373 };
374 
376 template <typename FP>
379 
380  static Type get_default()
381  {
382  ContactMatrixGroup<FP> contact_matrix = ContactMatrixGroup<FP>(1, 1);
383  contact_matrix[0] = mio::ContactMatrix<FP>(Eigen::MatrixX<FP>::Constant(1, 1, 10.));
384  return Type(contact_matrix);
385  }
386  static std::string name()
387  {
388  return "ContactPatterns";
389  }
390 };
391 
393 template <typename FP>
395  using Type = FP;
396  static Type get_default()
397  {
398  return Type(0.5);
399  }
400  static std::string name()
401  {
402  return "RelativeTransmissionNoSymptoms";
403  }
404 };
405 
407 template <typename FP>
409  using Type = FP;
410  static Type get_default()
411  {
412  return Type(0.5);
413  }
414  static std::string name()
415  {
416  return "RiskOfInfectionFromSymptomatic";
417  }
418 };
419 
426 template <typename FP>
427 struct StartDay {
428  using Type = FP;
429  static Type get_default(size_t)
430  {
431  return Type(0.0);
432  }
433  static std::string name()
434  {
435  return "StartDay";
436  }
437 };
438 
444 template <typename FP>
445 struct Seasonality {
446  using Type = FP;
447  static Type get_default()
448  {
449  return Type(0.);
450  }
451  static std::string name()
452  {
453  return "Seasonality";
454  }
455 };
456 
457 template <typename FP>
468 
470 template <typename FP>
471 class Parameters : public ParametersBase<FP>
472 {
473 public:
476  : ParametersBase<FP>()
477  {
478  }
479 
486  bool check_constraints() const
487  {
488  // --- Parameters affecting the transmission of the virus. ---
489  if (this->template get<TransmissionProbabilityOnContact<FP>>() < 0.0 ||
490  this->template get<TransmissionProbabilityOnContact<FP>>() > 1.0) {
491  log_error("Constraint check: Parameter TransmissionProbabilityOnContact smaller {} or larger {}", 0, 1);
492  return true;
493  }
494 
495  if (this->template get<RelativeTransmissionNoSymptoms<FP>>() < 0.0 ||
496  this->template get<RelativeTransmissionNoSymptoms<FP>>() > 1.0) {
497  log_error("Constraint check: Parameter RelativeTransmissionNoSymptoms smaller {} or larger {}", 0, 1);
498  return true;
499  }
500 
501  if (this->template get<RiskOfInfectionFromSymptomatic<FP>>() < 0.0 ||
502  this->template get<RiskOfInfectionFromSymptomatic<FP>>() > 1.0) {
503  log_error("Constraint check: Parameter RiskOfInfectionFromSymptomatic smaller {} or larger {}", 0, 1);
504  return true;
505  }
506 
507  if (this->template get<Seasonality<FP>>() < 0.0 || this->template get<Seasonality<FP>>() > 0.5) {
508  log_warning("Constraint check: Parameter Seasonality should lie between {} and {}", 0.0, 0.5);
509  return true;
510  }
511 
512  // --- Parameters affecting the phase-type distributions. ---
513  // --- Check that the dimensions are consistent. ---
514  if ((this->template get<TransitionMatrixExposedToInfectedNoSymptoms<FP>>().cols() !=
515  this->template get<TransitionMatrixExposedToInfectedNoSymptoms<FP>>().rows()) ||
516  (this->template get<TransitionMatrixInfectedNoSymptomsToInfectedSymptoms<FP>>().cols() !=
517  this->template get<TransitionMatrixInfectedNoSymptomsToInfectedSymptoms<FP>>().rows()) ||
518  (this->template get<TransitionMatrixInfectedNoSymptomsToRecovered<FP>>().cols() !=
519  this->template get<TransitionMatrixInfectedNoSymptomsToRecovered<FP>>().rows()) ||
520  (this->template get<TransitionMatrixInfectedSymptomsToInfectedSevere<FP>>().cols() !=
521  this->template get<TransitionMatrixInfectedSymptomsToInfectedSevere<FP>>().rows()) ||
522  (this->template get<TransitionMatrixInfectedSymptomsToRecovered<FP>>().cols() !=
523  this->template get<TransitionMatrixInfectedSymptomsToRecovered<FP>>().rows()) ||
524  (this->template get<TransitionMatrixInfectedSevereToInfectedCritical<FP>>().cols() !=
525  this->template get<TransitionMatrixInfectedSevereToInfectedCritical<FP>>().rows()) ||
526  (this->template get<TransitionMatrixInfectedSevereToRecovered<FP>>().cols() !=
527  this->template get<TransitionMatrixInfectedSevereToRecovered<FP>>().rows()) ||
528  (this->template get<TransitionMatrixInfectedCriticalToDead<FP>>().cols() !=
529  this->template get<TransitionMatrixInfectedCriticalToDead<FP>>().rows()) ||
530  (this->template get<TransitionMatrixInfectedCriticalToRecovered<FP>>().cols() !=
531  this->template get<TransitionMatrixInfectedCriticalToRecovered<FP>>().rows())) {
532  log_error("Constraint check: At least one of the matrices used for the TransitionMatrix parameters is not "
533  "quadratic.");
534  return true;
535  }
536 
537  if (this->template get<StartingProbabilitiesExposed<FP>>().rows() !=
538  this->template get<TransitionMatrixExposedToInfectedNoSymptoms<FP>>().rows()) {
539  log_error("Constraint check: Dimensions of StartingProbabilitiesExposed and "
540  "TransitionMatrixExposedToInfectedNoSymptoms are not matching.");
541  return true;
542  }
543 
544  if (this->template get<StartingProbabilitiesInfectedNoSymptoms<FP>>().rows() !=
545  this->template get<TransitionMatrixInfectedNoSymptomsToInfectedSymptoms<FP>>().rows() +
546  this->template get<TransitionMatrixInfectedNoSymptomsToRecovered<FP>>().rows()) {
547  log_error("Constraint check: Dimensions of StartingProbabilitiesInfectedNoSymptoms and "
548  "TransitionMatrices of InfectedNoSymptoms compartment are not matching.");
549  return true;
550  }
551 
552  if (this->template get<StartingProbabilitiesInfectedSymptoms<FP>>().rows() !=
553  this->template get<TransitionMatrixInfectedSymptomsToInfectedSevere<FP>>().rows() +
554  this->template get<TransitionMatrixInfectedSymptomsToRecovered<FP>>().rows()) {
555  log_error("Constraint check: Dimensions of StartingProbabilitiesInfectedSymptoms and "
556  "TransitionMatrices of InfectedSymptoms compartment are not matching.");
557  return true;
558  }
559 
560  if (this->template get<StartingProbabilitiesInfectedSevere<FP>>().rows() !=
561  this->template get<TransitionMatrixInfectedSevereToInfectedCritical<FP>>().rows() +
562  this->template get<TransitionMatrixInfectedSevereToRecovered<FP>>().rows()) {
563  log_error("Constraint check: Dimensions of StartingProbabilitiesInfectedSevere and "
564  "TransitionMatrices of InfectedSevere compartment are not matching.");
565  return true;
566  }
567 
568  if (this->template get<StartingProbabilitiesInfectedCritical<FP>>().rows() !=
569  this->template get<TransitionMatrixInfectedCriticalToDead<FP>>().rows() +
570  this->template get<TransitionMatrixInfectedCriticalToRecovered<FP>>().rows()) {
571  log_error("Constraint check: Dimensions of StartingProbabilitiesInfectedCritical and "
572  "TransitionMatrices of InfectedCritical compartment are not matching.");
573  return true;
574  }
575 
576  // --- Check constraints of the starting probability vectors. ---
577  if ((!floating_point_equal<FP>(1., this->template get<StartingProbabilitiesExposed<FP>>().sum())) ||
578  (!floating_point_equal<FP>(1., this->template get<StartingProbabilitiesInfectedNoSymptoms<FP>>().sum())) ||
579  (!floating_point_equal<FP>(1., this->template get<StartingProbabilitiesInfectedSymptoms<FP>>().sum())) ||
580  (!floating_point_equal<FP>(1., this->template get<StartingProbabilitiesInfectedSevere<FP>>().sum())) ||
581  (!floating_point_equal<FP>(1., this->template get<StartingProbabilitiesInfectedCritical<FP>>().sum()))) {
582  log_warning(
583  "Constraint check: At least one of the vectors for the starting probabilities does not sum to one.");
584  return true;
585  }
586 
587  if ((this->template get<StartingProbabilitiesExposed<FP>>().array() < -1e-10).any() ||
588  (this->template get<StartingProbabilitiesInfectedNoSymptoms<FP>>().array() < -1e-10).any() ||
589  (this->template get<StartingProbabilitiesInfectedSymptoms<FP>>().array() < -1e-10).any() ||
590  (this->template get<StartingProbabilitiesInfectedSevere<FP>>().array() < -1e-10).any() ||
591  (this->template get<StartingProbabilitiesInfectedCritical<FP>>().array() < -1e-10).any()) {
592  log_warning("Constraint check: At least one of the vectors for the starting probabilities has at least one "
593  "negative entry.");
594  return true;
595  }
596 
597  // --- Check that we have no flows back from one compartment to the previous one
598  // (only in between of the subcompartments). ---
599  if (((this->template get<TransitionMatrixExposedToInfectedNoSymptoms<FP>>() *
600  Eigen::VectorX<FP>::Ones(this->template get<TransitionMatrixExposedToInfectedNoSymptoms<FP>>().rows()))
601  .array() > 1e-10)
602  .any()) {
603  log_warning(
604  "Constraint check: The entries of TransitionMatrixExposedToInfectedNoSymptoms lead to a negative "
605  "flow ExposedToInfectedNoSymptoms.");
606  return true;
607  }
608  if (((this->template get<TransitionMatrixInfectedNoSymptomsToInfectedSymptoms<FP>>() *
609  Eigen::VectorX<FP>::Ones(
610  this->template get<TransitionMatrixInfectedNoSymptomsToInfectedSymptoms<FP>>().rows()))
611  .array() > 1e-10)
612  .any()) {
613  log_warning("Constraint check: The entries of TransitionMatrixInfectedNoSymptomsToInfectedSymptoms lead to "
614  "a negative "
615  "flow InfectedNoSymptomsToInfectedSymptoms.");
616  return true;
617  }
618  if (((this->template get<TransitionMatrixInfectedNoSymptomsToRecovered<FP>>() *
619  Eigen::VectorX<FP>::Ones(this->template get<TransitionMatrixInfectedNoSymptomsToRecovered<FP>>().rows()))
620  .array() > 1e-10)
621  .any()) {
622  log_warning(
623  "Constraint check: The entries of TransitionMatrixInfectedNoSymptomsToRecovered lead to a negative "
624  "flow InfectedNoSymptomsToRecovered.");
625  return true;
626  }
627  if (((this->template get<TransitionMatrixInfectedSymptomsToInfectedSevere<FP>>() *
628  Eigen::VectorX<FP>::Ones(
629  this->template get<TransitionMatrixInfectedSymptomsToInfectedSevere<FP>>().rows()))
630  .array() > 1e-10)
631  .any()) {
632  log_warning(
633  "Constraint check: The entries of TransitionMatrixInfectedSymptomsToInfectedSevere lead to a negative "
634  "flow InfectedSymptomsToInfectedSevere.");
635  return true;
636  }
637  if (((this->template get<TransitionMatrixInfectedSymptomsToRecovered<FP>>() *
638  Eigen::VectorX<FP>::Ones(this->template get<TransitionMatrixInfectedSymptomsToRecovered<FP>>().rows()))
639  .array() > 1e-10)
640  .any()) {
641  log_warning(
642  "Constraint check: The entries of TransitionMatrixInfectedSymptomsToRecovered lead to a negative "
643  "flow InfectedSymptomsToRecovered.");
644  return true;
645  }
646  if (((this->template get<TransitionMatrixInfectedSevereToInfectedCritical<FP>>() *
647  Eigen::VectorX<FP>::Ones(
648  this->template get<TransitionMatrixInfectedSevereToInfectedCritical<FP>>().rows()))
649  .array() > 1e-10)
650  .any()) {
651  log_warning(
652  "Constraint check: The entries of TransitionMatrixInfectedSevereToInfectedCritical lead to a negative "
653  "flow InfectedSevereToInfectedCritical.");
654  return true;
655  }
656  if (((this->template get<TransitionMatrixInfectedSevereToRecovered<FP>>() *
657  Eigen::VectorX<FP>::Ones(this->template get<TransitionMatrixInfectedSevereToRecovered<FP>>().rows()))
658  .array() > 1e-10)
659  .any()) {
660  log_warning("Constraint check: The entries of TransitionMatrixInfectedSevereToRecovered lead to a negative "
661  "flow InfectedSevereToRecovered.");
662  return true;
663  }
664  if (((this->template get<TransitionMatrixInfectedCriticalToDead<FP>>() *
665  Eigen::VectorX<FP>::Ones(this->template get<TransitionMatrixInfectedCriticalToDead<FP>>().rows()))
666  .array() > 1e-10)
667  .any()) {
668  log_warning("Constraint check: The entries of TransitionMatrixInfectedCriticalToDead lead to a negative "
669  "flow InfectedCriticalToDead.");
670  return true;
671  }
672  if (((this->template get<TransitionMatrixInfectedCriticalToRecovered<FP>>() *
673  Eigen::VectorX<FP>::Ones(this->template get<TransitionMatrixInfectedCriticalToRecovered<FP>>().rows()))
674  .array() > 1e-10)
675  .any()) {
676  log_warning(
677  "Constraint check: The entries of TransitionMatrixInfectedCriticalToRecovered lead to a negative "
678  "flow InfectedCriticalToRecovered.");
679  return true;
680  }
681 
682  return false;
683  }
684 
685 private:
687  : ParametersBase<FP>(std::move(base))
688  {
689  }
690 
691 public:
696  template <class IOContext>
697  static IOResult<Parameters> deserialize(IOContext& io)
698  {
699  BOOST_OUTCOME_TRY(auto&& base, ParametersBase<FP>::deserialize(io));
700  return success(Parameters(std::move(base)));
701  }
702 };
703 
704 } // namespace glsecir
705 } // namespace mio
706 
707 #endif // MIO_GLCT_SECIR_PARAMS_H
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
a set of parameters defined at compile time
Definition: parameter_set.h:205
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
Parameters of an GLCT-SECIR model.
Definition: glct_secir/parameters.h:472
static IOResult< Parameters > deserialize(IOContext &io)
deserialize an object of this class.
Definition: glct_secir/parameters.h:697
Parameters()
Default constructor.
Definition: glct_secir/parameters.h:475
bool check_constraints() const
Checks that all parameters satisfy their corresponding constraints and logs an error if constraints a...
Definition: glct_secir/parameters.h:486
Parameters(ParametersBase< FP > &&base)
Definition: glct_secir/parameters.h:686
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:112
auto success()
Create an object that is implicitly convertible to a succesful IOResult<void>.
Definition: io.h:359
void log_error(spdlog::string_view_t fmt, const Args &... args)
Definition: logging.h:100
boost::outcome_v2::unchecked< T, IOStatus > IOResult
Value-or-error type for operations that return a value but can fail.
Definition: io.h:353
Definition: io.h:94
The contact patterns within the society are modelled using an UncertainContactMatrix.
Definition: glct_secir/parameters.h:377
static Type get_default()
Definition: glct_secir/parameters.h:380
static std::string name()
Definition: glct_secir/parameters.h:386
UncertainContactMatrix< FP > Type
Definition: glct_secir/parameters.h:378
The relative InfectedNoSymptoms infectability.
Definition: glct_secir/parameters.h:394
static Type get_default()
Definition: glct_secir/parameters.h:396
static std::string name()
Definition: glct_secir/parameters.h:400
FP Type
Definition: glct_secir/parameters.h:395
The risk of infection from symptomatic cases in the GLCT-SECIR model.
Definition: glct_secir/parameters.h:408
static Type get_default()
Definition: glct_secir/parameters.h:410
static std::string name()
Definition: glct_secir/parameters.h:414
FP Type
Definition: glct_secir/parameters.h:409
The seasonality in the GLCT-SECIR model.
Definition: glct_secir/parameters.h:445
static std::string name()
Definition: glct_secir/parameters.h:451
FP Type
Definition: glct_secir/parameters.h:446
static Type get_default()
Definition: glct_secir/parameters.h:447
The start day in the GLCT-SECIR model.
Definition: glct_secir/parameters.h:427
FP Type
Definition: glct_secir/parameters.h:428
static std::string name()
Definition: glct_secir/parameters.h:433
static Type get_default(size_t)
Definition: glct_secir/parameters.h:429
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:293
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:299
static std::string name()
Definition: glct_secir/parameters.h:305
Eigen::VectorX< FP > Type
Definition: glct_secir/parameters.h:294
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:316
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:324
static std::string name()
Definition: glct_secir/parameters.h:330
Eigen::MatrixX< FP > Type
Definition: glct_secir/parameters.h:317
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 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: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:271
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
Eigen::MatrixX< FP > Type
Definition: glct_secir/parameters.h:272
static std::string name()
Definition: glct_secir/parameters.h:285
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:363
static Type get_default()
Definition: glct_secir/parameters.h:365
static std::string name()
Definition: glct_secir/parameters.h:369
FP Type
Definition: glct_secir/parameters.h:364