SMT-RAT
24.02
Toolbox for Strategic and Parallel Satisfiability-Modulo-Theories Solving
|
#include <PBPPStrategyNorm_LIA.h>
Public Member Functions | |
PBPPStrategyNorm_LIA () | |
bool | inform (const FormulaT &_constraint) |
Informs the solver about a constraint. More... | |
void | deinform (const FormulaT &_constraint) |
The inverse of informing about a constraint. More... | |
bool | add (const FormulaT &_subformula, bool _containsUnknownConstraints=true) |
Adds the given formula to the conjunction of formulas, which will be considered for the next satisfiability check. More... | |
Answer | check (bool _full=true) |
Checks the so far added formulas for satisfiability. More... | |
void | push () |
Pushes a backtrack point to the stack of backtrack points. More... | |
bool | pop () |
Pops a backtrack point from the stack of backtrack points. More... | |
void | pop (size_t _levels) |
void | clear () |
void | setObjectiveVariable (carl::Variable var) |
const carl::Variable & | objectiveVariable () const |
void | reset () |
const std::vector< FormulaSetT > & | infeasibleSubsets () const |
std::list< std::vector< carl::Variable > > | getModelEqualities () const |
Determines variables assigned by the currently found satisfying assignment to an equal value in their domain. More... | |
const Model & | model () const |
const std::vector< Model > & | allModels () const |
std::vector< FormulaT > | lemmas () |
Returns the lemmas/tautologies which were made during the last solving provoked by check(). More... | |
const ModuleInput & | formula () const |
ModuleInput::iterator | formulaBegin () |
ModuleInput::iterator | formulaEnd () |
void | printAssignment () const |
Prints the currently found assignment of variables occurring in the so far added formulas to values of their domains, if the conjunction of these formulas is satisfiable. More... | |
void | printAllAssignments (std::ostream &_out=std::cout) |
Prints all assignments of variables occurring in the so far added formulas to values of their domains, if the conjunction of these formulas is satisfiable. More... | |
void | printInfeasibleSubset (std::ostream &_out=std::cout) const |
Prints the first found infeasible subset of the set of received formulas. More... | |
void | printBackTrackStack (std::ostream &_out=std::cout) const |
Prints the stack of backtrack points. More... | |
void | printStrategyGraph (std::ostream &_out=std::cout) const |
Prints the strategy of the solver maintained by this manager. More... | |
const std::vector< Module * > & | getAllGeneratedModules () const |
std::ostream & | rDebugOutputChannel () |
auto | logic () const |
auto & | rLogic () |
void | addInformationRelevantFormula (const FormulaT &formula) |
Adds formula to InformationRelevantFormula. More... | |
void | clearInformationRelevantFormula () |
Deletes all InformationRelevantFormula. More... | |
void | setLemmaLevel (LemmaLevel level) |
Sets the current level for lemma generation. More... | |
bool | isLemmaLevel (LemmaLevel level) |
Checks if current lemma level is greater or equal to given level. More... | |
std::pair< bool, FormulaT > | getInputSimplified () |
ModuleInput::iterator | remove (ModuleInput::iterator _subformula) |
Removes the formula at the given position in the conjunction of formulas, which will be considered for the next satisfiability check. More... | |
ModuleInput::iterator | remove (const FormulaT &_subformula) |
Temporarily added: (TODO: Discuss with Gereon) Removes the given formula in the conjunction of formulas, which will be considered for the next satisfiability check. More... | |
Protected Member Functions | |
void | setStrategy (const std::initializer_list< BackendLink > &backends) |
void | setStrategy (const BackendLink &backend) |
template<typename Module > | |
BackendLink | addBackend (const std::initializer_list< BackendLink > &backends={}) |
template<typename Module > | |
BackendLink | addBackend (const BackendLink &backend) |
BackendLink & | addEdge (std::size_t from, std::size_t to) |
std::vector< Module * > | getAllBackends (Module *_module) const |
Gets all backends so far instantiated according the strategy and all previous enquiries of the given module. More... | |
std::vector< Module * > | getBackends (Module *_requiredBy, std::atomic_bool *_foundAnswer) |
Get the backends to call for the given problem instance required by the given module. More... | |
const std::set< FormulaT > & | getInformationRelevantFormulas () |
Gets all InformationRelevantFormulas. More... | |
Private Attributes | |
smtrat::Conditionals | mPrimaryBackendFoundAnswer |
a vector of flags, which indicate that an answer has been found of an antecessor module of the primary module More... | |
ModuleInput * | mpPassedFormula |
the constraints so far passed to the primary backend More... | |
carl::Condition | mPropositions |
The propositions of the passed formula. More... | |
std::vector< ModuleInput::iterator > | mBacktrackPoints |
Contains the backtrack points, that are iterators to the last formula to be kept when backtracking to the respective point. More... | |
std::vector< Module * > | mGeneratedModules |
all generated instances of modules More... | |
std::map< const Module *const, std::vector< Module * > > | mBackendsOfModules |
a mapping of each module to its backends More... | |
Module * | mpPrimaryBackend |
the primary backends More... | |
bool | mBackendsUptodate |
a Boolean showing whether the manager has received new constraint after the last consistency check More... | |
StrategyGraph | mStrategyGraph |
primary strategy More... | |
std::ostream | mDebugOutputChannel |
channel to write debug output More... | |
carl::Logic | mLogic |
the logic this solver considers More... | |
std::set< FormulaT > | mInformationRelevantFormula |
List of formula which are relevant for certain tasks. More... | |
LemmaLevel | mLemmaLevel |
Level of lemma generation. More... | |
carl::Variable | mObjectiveVariable |
objective variable More... | |
Definition at line 17 of file PBPPStrategyNorm_LIA.h.
|
inline |
|
inherited |
Adds the given formula to the conjunction of formulas, which will be considered for the next satisfiability check.
_subformula | The formula to add. |
_containsUnknownConstraints | true, if the formula to add contains constraints, about which this solver was not yet informed. |
Definition at line 86 of file Manager.cpp.
|
inlineprotectedinherited |
|
inlineprotectedinherited |
|
inlineprotectedinherited |
|
inlineinherited |
|
inlineinherited |
Note, that an assignment is only provided if the conjunction of so far added formulas is satisfiable. Furthermore, when solving non-linear real arithmetic formulas the assignment could contain other variables or freshly introduced variables.
Definition at line 213 of file Manager.h.
|
inherited |
Checks the so far added formulas for satisfiability.
Definition at line 115 of file Manager.cpp.
|
inlineinherited |
|
inlineinherited |
|
inherited |
The inverse of informing about a constraint.
All data structures which were kept regarding this constraint are going to be removed. Note, that this makes only sense if it is not likely enough that a formula with this constraint must be solved again.
_constraint | The constraint to remove from internal data structures. |
Definition at line 81 of file Manager.cpp.
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
|
inlineprotectedinherited |
Gets all backends so far instantiated according the strategy and all previous enquiries of the given module.
_module | The module to get all backends so far instantiated according the strategy and all previous enquiries of this module. |
Definition at line 411 of file Manager.h.
|
inlineinherited |
|
protectedinherited |
Get the backends to call for the given problem instance required by the given module.
_requiredBy | The module asking for a backend. |
_foundAnswer | A conditional |
Definition at line 279 of file Manager.cpp.
|
inlineprotectedinherited |
|
inherited |
Definition at line 149 of file Manager.cpp.
|
inherited |
Determines variables assigned by the currently found satisfying assignment to an equal value in their domain.
Definition at line 127 of file Manager.cpp.
|
inherited |
Note, that the conjunction of the so far added formulas must be inconsistent to receive an infeasible subset.
Definition at line 122 of file Manager.cpp.
|
inherited |
Informs the solver about a constraint.
Optimally, it should be informed about all constraints, which it will receive eventually, before any of them is added as part of a formula with the interface add(..).
_constraint | The constraint to inform about. |
Definition at line 76 of file Manager.cpp.
|
inlineinherited |
|
inherited |
Returns the lemmas/tautologies which were made during the last solving provoked by check().
These lemmas can be used in the same manner as infeasible subsets are used.
Definition at line 138 of file Manager.cpp.
|
inlineinherited |
|
inherited |
Note, that an assignment is only provided if the conjunction of so far added formulas is satisfiable. Furthermore, when solving non-linear real arithmetic formulas the assignment could contain other variables or freshly introduced variables.
Definition at line 132 of file Manager.cpp.
|
inlineinherited |
|
inherited |
Pops a backtrack point from the stack of backtrack points.
This provokes, that all formulas which have been added after that backtrack point are removed.
Note, that this interface has not necessarily be used to apply a solver constructed with SMT-RAT, but is often required by state-of-the-art SMT solvers when embedding a theory solver constructed with SMT-RAT into them.
Definition at line 166 of file Manager.cpp.
|
inherited |
|
inlineinherited |
|
inherited |
Prints the currently found assignment of variables occurring in the so far added formulas to values of their domains, if the conjunction of these formulas is satisfiable.
Definition at line 154 of file Manager.cpp.
|
inherited |
Prints the stack of backtrack points.
_out | The stream to print on. |
Definition at line 258 of file Manager.cpp.
|
inherited |
Prints the first found infeasible subset of the set of received formulas.
_out | The stream to print on. |
Definition at line 237 of file Manager.cpp.
|
inlineinherited |
|
inlineinherited |
Pushes a backtrack point to the stack of backtrack points.
Note, that this interface has not necessarily be used to apply a solver constructed with SMT-RAT, but is often required by state-of-the-art SMT solvers when embedding a theory solver constructed with SMT-RAT into them.
Definition at line 142 of file Manager.h.
|
inlineinherited |
|
inlineinherited |
Temporarily added: (TODO: Discuss with Gereon) Removes the given formula in the conjunction of formulas, which will be considered for the next satisfiability check.
_subformula | The formula to remove. |
Definition at line 378 of file Manager.h.
|
inherited |
Removes the formula at the given position in the conjunction of formulas, which will be considered for the next satisfiability check.
_subformula | The position of the formula to remove. |
Definition at line 159 of file Manager.cpp.
|
inherited |
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
|
inlineprotectedinherited |
|
inlineprotectedinherited |
|
privateinherited |
|
privateinherited |
|
privateinherited |
|
privateinherited |
|
privateinherited |
|
privateinherited |
|
privateinherited |
|
privateinherited |
|
privateinherited |
|
privateinherited |
|
privateinherited |
|
privateinherited |
|
privateinherited |