9template<storm::dd::DdType Type,
typename ValueType>
11 std::ofstream filestream;
13 filestream <<
"// storm exported dd\n";
14 filestream <<
"%transitions\n";
16 symbolicModel->getTransitionMatrix().exportToText(filename);
18 filestream <<
"%initial\n";
20 symbolicModel->getInitialStates().template toAdd<ValueType>().exportToText(filename);
21 for (
auto const& label : symbolicModel->getLabels()) {
23 filestream <<
"\n%label " << label <<
'\n';
25 symbolicModel->getStates(label).template toAdd<ValueType>().exportToText(filename);
Base class for all symbolic models.
template void explicitExportSymbolicModel< storm::dd::DdType::CUDD, double >(std::string const &, std::shared_ptr< storm::models::symbolic::Model< storm::dd::DdType::CUDD, double > > sparseModel)
template void explicitExportSymbolicModel< storm::dd::DdType::Sylvan, storm::RationalFunction >(std::string const &, std::shared_ptr< storm::models::symbolic::Model< storm::dd::DdType::Sylvan, storm::RationalFunction > > sparseModel)
template void explicitExportSymbolicModel< storm::dd::DdType::Sylvan, storm::RationalNumber >(std::string const &, std::shared_ptr< storm::models::symbolic::Model< storm::dd::DdType::Sylvan, storm::RationalNumber > > sparseModel)
void explicitExportSymbolicModel(std::string const &filename, std::shared_ptr< storm::models::symbolic::Model< Type, ValueType > > symbolicModel)
Exports a sparse model into the explicit drdd format.
void closeFile(std::ofstream &stream)
Close the given file after writing.
void openFile(std::string const &filepath, std::ofstream &filestream, bool append=false, bool silent=false)
Open the given file for writing.
template void explicitExportSymbolicModel< storm::dd::DdType::Sylvan, double >(std::string const &, std::shared_ptr< storm::models::symbolic::Model< storm::dd::DdType::Sylvan, double > > sparseModel)