Storm 1.11.1.1
A Modern Probabilistic Model Checker
Loading...
Searching...
No Matches
BELogNormal.cpp
Go to the documentation of this file.
1#include "BELogNormal.h"
2
3#include <boost/math/distributions/lognormal.hpp>
4
7
8namespace storm::dft {
9namespace storage {
10namespace elements {
11
12template<>
13double BELogNormal<double>::getUnreliability(double time) const {
14 // Compute via boost as no closed form formula exists
15 // TODO: initialize once if performance is an issue
16 boost::math::lognormal_distribution<double> distribution(this->mean(), this->standardDeviation());
17 return boost::math::cdf(distribution, time);
18}
19
20template<typename ValueType>
21ValueType BELogNormal<ValueType>::getUnreliability(ValueType time) const {
22 STORM_LOG_THROW(false, storm::exceptions::NotSupportedException, "Computing cumulative failure probability not supported for this data type.");
23}
24
25// Explicitly instantiate the class.
26template class BELogNormal<double>;
28
29} // namespace elements
30} // namespace storage
31} // namespace storm::dft
BE with log-normal failure distribution.
Definition BELogNormal.h:13
ValueType getUnreliability(ValueType time) const override
Return the unreliability of the BE up to the given time point.
#define STORM_LOG_THROW(cond, exception, message)
Definition macros.h:30