diff --git a/src/storage/dd/DdManager.cpp b/src/storage/dd/DdManager.cpp index 5ad46ac53..0f1e65fee 100644 --- a/src/storage/dd/DdManager.cpp +++ b/src/storage/dd/DdManager.cpp @@ -106,6 +106,21 @@ namespace storm { return result; } +#ifdef STORM_HAVE_CARL + template + template<> + Add DdManager::getIdentity(storm::expressions::Variable const& variable) const { + storm::dd::DdMetaVariable const& metaVariable = this->getMetaVariable(variable); + + Add result = this->getAddZero(); + for (int_fast64_t value = metaVariable.getLow(); value <= metaVariable.getHigh(); ++value) { + storm::RationalFunction constantFunction(value); + result += this->getEncoding(variable, value).template toAdd() * this->getConstant(constantFunction); + } + return result; + } +#endif + template std::pair DdManager::addMetaVariable(std::string const& name, int_fast64_t low, int_fast64_t high) { // Check whether the variable name is legal.