Storm 1.11.1.1
A Modern Probabilistic Model Checker
Loading...
Searching...
No Matches
GraphConditions.h
Go to the documentation of this file.
1#pragma once
2
3#include <type_traits>
4#include <unordered_set>
5
6#pragma clang diagnostic push
7#pragma clang diagnostic ignored "-Wmacro-redefined" // clash for likely() macro between Ginac and Sylvan
8#include <carl/formula/Formula.h>
9#pragma clang diagnostic pop
10
13
14namespace storm {
15namespace analysis {
16
17template<typename ValueType, typename Enable = void>
19 typedef void* val;
20};
21
22template<typename ValueType>
23struct ConstraintType<ValueType, typename std::enable_if<std::is_same<storm::RationalFunction, ValueType>::value>::type> {
24 typedef carl::Formula<typename storm::RationalFunction::PolyType::PolyType> val;
25};
26
30template<typename ValueType>
32 private:
33 // A set of constraints that says that the DTMC actually has valid probability distributions in all states.
34 std::unordered_set<typename ConstraintType<ValueType>::val> wellformedConstraintSet;
35
36 // A set of constraints that makes sure that the underlying graph of the model does not change depending
37 // on the parameter values.
38 std::unordered_set<typename ConstraintType<ValueType>::val> graphPreservingConstraintSet;
39
40 // A set of variables
41 std::set<storm::RationalFunctionVariable> variableSet;
42
43 void wellformedRequiresNonNegativeEntries(std::vector<ValueType> const&);
44
45 public:
53
59 std::unordered_set<typename ConstraintType<ValueType>::val> const& getWellformedConstraints() const;
60
66 std::unordered_set<typename ConstraintType<ValueType>::val> const& getGraphPreservingConstraints() const;
67
72 std::set<storm::RationalFunctionVariable> const& getVariables() const;
73
80
87};
88
89} // namespace analysis
90} // namespace storm
Class to collect constraints on parametric Markov chains.
std::unordered_set< typename ConstraintType< ValueType >::val > const & getWellformedConstraints() const
Returns the set of wellformed-ness constraints.
std::unordered_set< typename ConstraintType< ValueType >::val > const & getGraphPreservingConstraints() const
Returns the set of graph-preserving constraints.
std::set< storm::RationalFunctionVariable > const & getVariables() const
Returns the set of variables in the model.
void operator()(storm::models::sparse::Model< ValueType > const &model)
Constructs the constraints for the given Model by calling the process method.
Base class for all sparse models.
Definition Model.h:32
void process()