Storm 1.11.1.1
A Modern Probabilistic Model Checker
Loading...
Searching...
No Matches
StateEliminator.cpp
Go to the documentation of this file.
2
7
8namespace storm {
9namespace solver {
10namespace stateelimination {
11
13
14template<typename ValueType>
17 : EliminatorBase<ValueType, ScalingMode::DivideOneMinus>(transitionMatrix, backwardTransitions) {
18 // Intentionally left empty.
19}
20
21template<typename ValueType>
23 STORM_LOG_TRACE("Eliminating state " << state << ".");
24 if (this->matrix.hasTrivialRowGrouping()) {
25 this->eliminate(state, state, removeForwardTransitions);
26 } else {
27 STORM_LOG_THROW(this->matrix.getRowGroupSize(state) == 1, storm::exceptions::IllegalArgumentException,
28 "Invoked state elimination on a state with multiple choices. This is not supported.");
29 this->eliminate(this->matrix.getRowGroupIndices()[state], state, removeForwardTransitions);
30 }
31}
32
33template class StateEliminator<double>;
34
37} // namespace stateelimination
38} // namespace solver
39} // namespace storm
StateEliminator(storm::storage::FlexibleSparseMatrix< ValueType > &transitionMatrix, storm::storage::FlexibleSparseMatrix< ValueType > &backwardTransitions)
void eliminateState(storm::storage::sparse::state_type state, bool removeForwardTransitions)
The flexible sparse matrix is used during state elimination.
#define STORM_LOG_TRACE(message)
Definition logging.h:12
#define STORM_LOG_THROW(cond, exception, message)
Definition macros.h:30