Browse Source

Merge pull request 'Adapt Property Ctors with ShieldingExpression Parameter' (#44) from storm_prs_and_updates into main

Reviewed-on: https://git.pranger.xyz/TEMPEST/tempest-devel/pulls/44
tempestpy_adaptions
Stefan Pranger 3 years ago
parent
commit
f4fb0188be
  1. 6
      src/storm-gspn/builder/JaniGSPNBuilder.cpp
  2. 2
      src/storm-pars-cli/storm-pars.cpp

6
src/storm-gspn/builder/JaniGSPNBuilder.cpp

@ -281,7 +281,7 @@ namespace storm {
auto reachFormula = std::make_shared<storm::logic::ProbabilityOperatorFormula>( auto reachFormula = std::make_shared<storm::logic::ProbabilityOperatorFormula>(
std::make_shared<storm::logic::EventuallyFormula>(atomicFormula, storm::logic::FormulaContext::Probability), std::make_shared<storm::logic::EventuallyFormula>(atomicFormula, storm::logic::FormulaContext::Probability),
storm::logic::OperatorInformation(optimizationDirection)); storm::logic::OperatorInformation(optimizationDirection));
standardProperties.emplace_back(dirShort + "PrReach" + name, reachFormula, emptySet, "The " + dirLong + " probability to eventually reach " + description + ".");
standardProperties.emplace_back(dirShort + "PrReach" + name, reachFormula, emptySet, nullptr, "The " + dirLong + " probability to eventually reach " + description + ".");
// Build time bounded reachability property // Build time bounded reachability property
// Add variable for time bound // Add variable for time bound
@ -295,7 +295,7 @@ namespace storm {
auto reachTimeBoundFormula = std::make_shared<storm::logic::ProbabilityOperatorFormula>( auto reachTimeBoundFormula = std::make_shared<storm::logic::ProbabilityOperatorFormula>(
std::make_shared<storm::logic::BoundedUntilFormula>(trueFormula, atomicFormula, boost::none, tb, tbr), std::make_shared<storm::logic::BoundedUntilFormula>(trueFormula, atomicFormula, boost::none, tb, tbr),
storm::logic::OperatorInformation(optimizationDirection)); storm::logic::OperatorInformation(optimizationDirection));
standardProperties.emplace_back(dirShort + "PrReach" + name + "TB", reachTimeBoundFormula, emptySet, "The " + dirLong + " probability to reach " + description + " within 'TIME_BOUND' steps.");
standardProperties.emplace_back(dirShort + "PrReach" + name + "TB", reachTimeBoundFormula, emptySet, nullptr, "The " + dirLong + " probability to reach " + description + " within 'TIME_BOUND' steps.");
// Use complementary direction for expected time // Use complementary direction for expected time
dirShort = maximal ? "Min" : "Max"; dirShort = maximal ? "Min" : "Max";
@ -306,7 +306,7 @@ namespace storm {
auto expTimeFormula = std::make_shared<storm::logic::TimeOperatorFormula>( auto expTimeFormula = std::make_shared<storm::logic::TimeOperatorFormula>(
std::make_shared<storm::logic::EventuallyFormula>(atomicFormula, storm::logic::FormulaContext::Time), std::make_shared<storm::logic::EventuallyFormula>(atomicFormula, storm::logic::FormulaContext::Time),
storm::logic::OperatorInformation(optimizationDirection)); storm::logic::OperatorInformation(optimizationDirection));
standardProperties.emplace_back(dirShort + "ExpTime" + name, expTimeFormula, emptySet, "The " + dirLong + " expected time to reach " + description + ".");
standardProperties.emplace_back(dirShort + "ExpTime" + name, expTimeFormula, emptySet, nullptr, "The " + dirLong + " expected time to reach " + description + ".");
return standardProperties; return standardProperties;
} }

2
src/storm-pars-cli/storm-pars.cpp

@ -822,7 +822,7 @@ namespace storm {
auto formula = preprocessingResult.formulas.get().at(i); auto formula = preprocessingResult.formulas.get().at(i);
STORM_LOG_ASSERT(i < input.properties.size(), "Index " << i << " greater than number of properties."); STORM_LOG_ASSERT(i < input.properties.size(), "Index " << i << " greater than number of properties.");
storm::jani::Property property = input.properties.at(i); storm::jani::Property property = input.properties.at(i);
newProperties.push_back(storm::jani::Property(property.getName(), formula, property.getUndefinedConstants(), property.getComment()));
newProperties.push_back(storm::jani::Property(property.getName(), formula, property.getUndefinedConstants(), nullptr, property.getComment()));
} }
input.properties = newProperties; input.properties = newProperties;
} }

Loading…
Cancel
Save