|
Storm 2.0.0.3
A Modern Probabilistic Model Checker
|
This class caches the backward transitions of a given forward transition matrix. More...
#include <BackwardTransitionCache.h>
Public Member Functions | |
| BackwardTransitionCache (SparseMatrix< ValueType > const &forwardTransitionMatrix, bool keepZeros=false) | |
| BackwardTransitionCache (SparseMatrix< ValueType > const &forwardTransitionMatrix, SparseMatrix< ValueType > &&backwardTransitionMatrix, bool keepZeros=false) | |
| BackwardTransitionCache ()=delete | |
| BackwardTransitionCache (BackwardTransitionCache const &)=default | |
| BackwardTransitionCache (BackwardTransitionCache &&)=default | |
| BackwardTransitionCache & | operator= (BackwardTransitionCache const &)=delete |
| BackwardTransitionCache & | operator= (BackwardTransitionCache &&)=delete |
| SparseMatrix< ValueType > const & | get () const |
| Retrieves the backward transitions. | |
| void | clearCache () const |
| Clears the cache (for this and all copies of this cache). | |
| bool | isCached () const |
| Retrieves whether the backward transitions are currently cached. | |
This class caches the backward transitions of a given forward transition matrix.
The backward transitions are computed (using SparseMatrix::transpose) the first time they are requested. They have a trivial row grouping, i.e., there is one row for each state. By default, forward transitions with value zero are dropped, i.e., the backward transitions only contain entries for non-zero forward transitions (see parameter keepZeros of the constructors). The forward transition matrix reference needs to remain valid throughout the lifetime of this cache. The cache can be copied and moved (but not assigned), and the actual backward transitions are shared. This means that if the matrix is computed (or cleared) in one of the copies, this is also the case for all other copies.
| ValueType |
Definition at line 22 of file BackwardTransitionCache.h.
|
explicit |
| forwardTransitionMatrix | the forward transitions |
| keepZeros | if true, zero entries of the forward transition matrix are also contained in the backward transitions. Otherwise, they are dropped. |
Definition at line 10 of file BackwardTransitionCache.cpp.
|
explicit |
| forwardTransitionMatrix | the forward transitions |
| backwardTransitionMatrix | the (already computed) backward transitions |
| keepZeros | if true, zero entries are kept when the backward transitions have to be recomputed (after clearing the cache). |
Definition at line 18 of file BackwardTransitionCache.cpp.
|
delete |
|
default |
|
default |
| void storm::storage::BackwardTransitionCache< ValueType >::clearCache | ( | ) | const |
Clears the cache (for this and all copies of this cache).
Definition at line 36 of file BackwardTransitionCache.cpp.
| SparseMatrix< ValueType > const & storm::storage::BackwardTransitionCache< ValueType >::get | ( | ) | const |
Retrieves the backward transitions.
They are computed if they are not cached yet.
Definition at line 27 of file BackwardTransitionCache.cpp.
| bool storm::storage::BackwardTransitionCache< ValueType >::isCached | ( | ) | const |
Retrieves whether the backward transitions are currently cached.
Definition at line 42 of file BackwardTransitionCache.cpp.
|
delete |
|
delete |