14namespace bisimulation {
16template<storm::dd::DdType DdType,
typename ValueType>
22template<storm::dd::DdType DdType,
typename ValueType>
24 std::vector<std::string>
const& labels) {
25 for (
auto const& label : labels) {
26 this->addLabel(label);
31template<storm::dd::DdType DdType,
typename ValueType>
33 std::vector<storm::expressions::Expression>
const& expressions) {
34 for (
auto const& e : expressions) {
35 this->addExpression(e);
39template<storm::dd::DdType DdType,
typename ValueType>
41 std::vector<std::shared_ptr<storm::logic::Formula const>>
const& formulas) {
42 if (formulas.empty()) {
44 for (
auto const& label : model.
getLabels()) {
45 this->addLabel(label);
49 this->addRewardModel(rewardModel.first);
52 for (
auto const& formula : formulas) {
53 for (
auto const& expressionFormula : formula->getAtomicExpressionFormulas()) {
54 this->addExpression(expressionFormula->getExpression());
56 for (
auto const& labelFormula : formula->getAtomicLabelFormulas()) {
57 this->addLabel(labelFormula->getLabel());
58 std::string
const& label = labelFormula->getLabel();
59 STORM_LOG_THROW(model.
hasLabel(label), storm::exceptions::InvalidPropertyException,
"Property refers to illegal label '" << label <<
"'.");
62 for (
auto const& rewardModel : formula->getReferencedRewardModels()) {
63 if (rewardModel ==
"") {
65 this->addRewardModel(rewardModel);
68 "Property refers to the default reward model, but it does not exist or is not unique.");
72 this->addRewardModel(rewardModel);
79template<storm::dd::DdType DdType,
typename ValueType>
84template<storm::dd::DdType DdType,
typename ValueType>
86 expressions.insert(expression);
89template<storm::dd::DdType DdType,
typename ValueType>
91 rewardModelNames.insert(name);
94template<storm::dd::DdType DdType,
typename ValueType>
99template<storm::dd::DdType DdType,
typename ValueType>
104template<storm::dd::DdType DdType,
typename ValueType>
106 return rewardModelNames;
Base class for all symbolic models.
virtual storm::expressions::Expression getExpression(std::string const &label) const
Returns the expression for the given label.
virtual std::string const & getUniqueRewardModelName() const override
Retrieves the name of the unique reward model, if there exists exactly one.
virtual bool hasRewardModel(std::string const &rewardModelName) const override
Retrieves whether the model has a reward model with the given name.
std::vector< std::string > getLabels() const
virtual bool hasLabel(std::string const &label) const
Retrieves whether the given label is a valid label in this model.
std::unordered_map< std::string, RewardModelType > & getRewardModels()
virtual bool hasUniqueRewardModel() const override
Retrieves whether the model has a unique reward model.
#define STORM_LOG_THROW(cond, exception, message)