Browse Source

intermediate commit

Former-commit-id: 6acb50ec62
tempestpy_adaptions
sjunges 9 years ago
parent
commit
5e9c42f2af
  1. 3
      src/models/sparse/Model.cpp
  2. 1
      src/models/sparse/Model.h
  3. 8
      src/storage/SparseMatrix.h

3
src/models/sparse/Model.cpp

@ -320,6 +320,9 @@ namespace storm {
return this->rewardModels;
}
std::set<storm::Variable> getProbabilityParameters(Model<storm::RationalNumber> const& model) {
return storm::storage::getVariables(model.getTransitionMatrix());
}
template class Model<double>;
template class Model<float>;

1
src/models/sparse/Model.h

@ -345,6 +345,7 @@ namespace storm {
boost::optional<std::vector<LabelSet>> choiceLabeling;
};
std::set<storm::Variable> getProbabilityParameters(Model<storm::RationalFunction> const& model);
} // namespace sparse
} // namespace models
} // namespace storm

8
src/storage/SparseMatrix.h

@ -970,6 +970,14 @@ namespace storm {
};
std::set<storm::Variable> getVariables(SparseMatrix<storm::RationalFunction> const& matrix) {
std::set<storm::Variable> result;
for(auto const& entry : matrix) {
entry.probability.gatherVariables(result);
}
return result;
}
} // namespace storage
} // namespace storm

Loading…
Cancel
Save