Storm
A Modern Probabilistic Model Checker
|
A class that uses gaussian elimination to implement the LinearEquationSolver interface. More...
#include <EliminationLinearEquationSolver.h>
Public Member Functions | |
EliminationLinearEquationSolver () | |
EliminationLinearEquationSolver (storm::storage::SparseMatrix< ValueType > const &A) | |
EliminationLinearEquationSolver (storm::storage::SparseMatrix< ValueType > &&A) | |
virtual void | setMatrix (storm::storage::SparseMatrix< ValueType > const &A) override |
virtual void | setMatrix (storm::storage::SparseMatrix< ValueType > &&A) override |
virtual LinearEquationSolverProblemFormat | getEquationProblemFormat (Environment const &env) const override |
Retrieves the format in which this solver expects to solve equations. | |
![]() | |
LinearEquationSolver () | |
virtual | ~LinearEquationSolver () |
bool | solveEquations (Environment const &env, std::vector< ValueType > &x, std::vector< ValueType > const &b) const |
If the solver expects the equation system format, it solves Ax = b. | |
virtual LinearEquationSolverRequirements | getRequirements (Environment const &env) const |
Retrieves the requirements of the solver under the current settings. | |
void | setCachingEnabled (bool value) const |
Sets whether some of the generated data during solver calls should be cached. | |
bool | isCachingEnabled () const |
Retrieves whether some of the generated data during solver calls should be cached. | |
virtual void | clearCache () const |
![]() | |
AbstractEquationSolver () | |
void | setTerminationCondition (std::unique_ptr< TerminationCondition< ValueType > > terminationCondition) |
Sets a custom termination condition that is used together with the regular termination condition of the solver. | |
void | resetTerminationCondition () |
Removes a previously set custom termination condition. | |
bool | hasCustomTerminationCondition () const |
Retrieves whether a custom termination condition has been set. | |
bool | terminateNow (std::vector< ValueType > const &values, SolverGuarantee const &guarantee) const |
Checks whether the solver can terminate wrt. | |
bool | hasRelevantValues () const |
Retrieves whether this solver has particularly relevant values. | |
storm::storage::BitVector const & | getRelevantValues () const |
Retrieves the relevant values (if there are any). | |
boost::optional< storm::storage::BitVector > const & | getOptionalRelevantValues () const |
void | setRelevantValues (storm::storage::BitVector &&valuesOfInterest) |
Sets the relevant values. | |
void | setRelevantValues (storm::storage::BitVector const &valuesOfInterest) |
Sets the relevant values. | |
void | clearRelevantValues () |
Removes the values of interest (if there were any). | |
bool | hasLowerBound (BoundType const &type=BoundType::Any) const |
Retrieves whether this solver has a lower bound. | |
bool | hasUpperBound (BoundType const &type=BoundType::Any) const |
Retrieves whether this solver has an upper bound. | |
void | setLowerBound (ValueType const &value) |
Sets a lower bound for the solution that can potentially be used by the solver. | |
void | setUpperBound (ValueType const &value) |
Sets an upper bound for the solution that can potentially be used by the solver. | |
void | setBounds (ValueType const &lower, ValueType const &upper) |
Sets bounds for the solution that can potentially be used by the solver. | |
ValueType const & | getLowerBound () const |
Retrieves the lower bound (if there is any). | |
ValueType const & | getLowerBound (uint64_t const &index) const |
Retrieves the lower bound for the variable with the given index (if there is any lower bound). | |
ValueType | getLowerBound (bool convertLocalBounds) const |
Retrieves the lower bound (if there is any). | |
ValueType const & | getUpperBound () const |
Retrieves the upper bound (if there is any). | |
ValueType const & | getUpperBound (uint64_t const &index) const |
Retrieves the upper bound for the variable with the given index (if there is any upper bound). | |
ValueType | getUpperBound (bool convertLocalBounds) const |
Retrieves the upper bound (if there is any). | |
std::vector< ValueType > const & | getLowerBounds () const |
Retrieves a vector containing the lower bounds (if there are any). | |
std::vector< ValueType > const & | getUpperBounds () const |
Retrieves a vector containing the upper bounds (if there are any). | |
void | setLowerBounds (std::vector< ValueType > const &values) |
Sets lower bounds for the solution that can potentially be used by the solver. | |
void | setLowerBounds (std::vector< ValueType > &&values) |
Sets lower bounds for the solution that can potentially be used by the solver. | |
void | setUpperBounds (std::vector< ValueType > const &values) |
Sets upper bounds for the solution that can potentially be used by the solver. | |
void | setUpperBounds (std::vector< ValueType > &&values) |
Sets upper bounds for the solution that can potentially be used by the solver. | |
void | setBounds (std::vector< ValueType > const &lower, std::vector< ValueType > const &upper) |
Sets bounds for the solution that can potentially be used by the solver. | |
void | setBoundsFromOtherSolver (AbstractEquationSolver< ValueType > const &other) |
void | clearBounds () |
Removes all specified solution bounds. | |
bool | isShowProgressSet () const |
Retrieves whether progress is to be shown. | |
uint64_t | getShowProgressDelay () const |
Retrieves the delay between progress emissions. | |
void | startMeasureProgress (uint64_t startingIteration=0) const |
Starts to measure progress. | |
void | showProgressIterative (uint64_t iterations, boost::optional< uint64_t > const &bound=boost::none) const |
Shows progress if this solver is asked to do so. | |
Protected Member Functions | |
virtual bool | internalSolveEquations (Environment const &env, std::vector< ValueType > &x, std::vector< ValueType > const &b) const override |
![]() | |
TerminationCondition< ValueType > const & | getTerminationCondition () const |
Retrieves the custom termination condition (if any was set). | |
std::unique_ptr< TerminationCondition< ValueType > > const & | getTerminationConditionPointer () const |
void | createUpperBoundsVector (std::vector< ValueType > &upperBoundsVector) const |
void | createUpperBoundsVector (std::unique_ptr< std::vector< ValueType > > &upperBoundsVector, uint64_t length) const |
void | createLowerBoundsVector (std::vector< ValueType > &lowerBoundsVector) const |
void | reportStatus (SolverStatus status, boost::optional< uint64_t > const &iterations=boost::none) const |
Report the current status of the solver. | |
SolverStatus | updateStatus (SolverStatus status, std::vector< ValueType > const &x, SolverGuarantee const &guarantee, uint64_t iterations, uint64_t maximalNumberOfIterations) const |
Update the status of the solver with respect to convergence, early termination, abortion, etc. | |
SolverStatus | updateStatus (SolverStatus status, bool earlyTermination, uint64_t iterations, uint64_t maximalNumberOfIterations) const |
Update the status of the solver with respect to convergence, early termination, abortion, etc. | |
Additional Inherited Members | |
![]() | |
enum class | BoundType { Global , Local , Any } |
![]() | |
std::unique_ptr< std::vector< ValueType > > | cachedRowVector |
![]() | |
std::unique_ptr< TerminationCondition< ValueType > > | terminationCondition |
boost::optional< storm::storage::BitVector > | relevantValues |
boost::optional< ValueType > | lowerBound |
boost::optional< ValueType > | upperBound |
boost::optional< std::vector< ValueType > > | lowerBounds |
boost::optional< std::vector< ValueType > > | upperBounds |
A class that uses gaussian elimination to implement the LinearEquationSolver interface.
Definition at line 13 of file EliminationLinearEquationSolver.h.
storm::solver::EliminationLinearEquationSolver< ValueType >::EliminationLinearEquationSolver | ( | ) |
Definition at line 23 of file EliminationLinearEquationSolver.cpp.
storm::solver::EliminationLinearEquationSolver< ValueType >::EliminationLinearEquationSolver | ( | storm::storage::SparseMatrix< ValueType > const & | A | ) |
Definition at line 28 of file EliminationLinearEquationSolver.cpp.
storm::solver::EliminationLinearEquationSolver< ValueType >::EliminationLinearEquationSolver | ( | storm::storage::SparseMatrix< ValueType > && | A | ) |
Definition at line 33 of file EliminationLinearEquationSolver.cpp.
|
overridevirtual |
Retrieves the format in which this solver expects to solve equations.
If the solver expects the equation system format, it solves Ax = b. If it it expects a fixed point format, it solves Ax + b = x.
Implements storm::solver::LinearEquationSolver< ValueType >.
Definition at line 101 of file EliminationLinearEquationSolver.cpp.
|
overrideprotectedvirtual |
Implements storm::solver::LinearEquationSolver< ValueType >.
Definition at line 52 of file EliminationLinearEquationSolver.cpp.
|
overridevirtual |
Implements storm::solver::LinearEquationSolver< ValueType >.
Definition at line 45 of file EliminationLinearEquationSolver.cpp.
|
overridevirtual |
Implements storm::solver::LinearEquationSolver< ValueType >.
Definition at line 38 of file EliminationLinearEquationSolver.cpp.