|
mCRL2
|
#include <bdd_prover.h>
Public Types | |
| using | substitution_type = rewriter::substitution_type |
Public Member Functions | |
| BDD_Prover (const data_specification &data_spec, const used_data_equation_selector &equations_selector, mcrl2::data::rewriter::strategy a_rewrite_strategy=mcrl2::data::rewrite_strategy::jitty, double a_time_limit=0, bool a_path_eliminator=false, smt_solver_type a_solver_type=smt_solver_type::solver_type_cvc, bool a_apply_induction=false) | |
| BDD_Prover (const rewriter &r, double time_limit=0, bool apply_induction=false) | |
| void | set_substitution (substitution_type &sigma) |
| Set the substitution to be used to construct the BDD. | |
| void | set_substitution_internal (substitution_type &sigma) |
| Set the substitution in internal format to be used to construct the BDD. | |
| Answer | is_tautology () |
| Indicates whether or not the formula Prover::f_formula is a tautology. | |
| Answer | is_contradiction () |
| Indicates whether or not the formula Prover::f_formula is a contradiction. | |
| data_expression | get_bdd () |
| Returns the BDD BDD_Prover::f_bdd. | |
| data_expression | get_witness () |
| Returns all the guards on a path in the BDD that leads to a leaf labelled "true", if such a leaf exists. | |
| data_expression | get_counter_example () |
| Returns all the guards on a path in the BDD that leads to a leaf labelled "false", if such a leaf exists. | |
| std::shared_ptr< detail::Rewriter > | get_rewriter () |
| Returns the rewriter used by this prover (i.e. it returns Prover::f_rewriter). | |
| strategy | rewriter_strategy () const |
| Returns the strategy of the rewriter used inside this proving rewriter. | |
| void | set_formula (const data_expression &formula) |
| Sets Prover::f_formula to formula. precondition: the argument passed as parameter formula is an expression of sort Bool. | |
| BDD_Prover | clone () |
| void | thread_initialise () |
Protected Attributes | |
| data_expression | f_formula |
| An expression of sort Bool. | |
| const Info | f_info = Info(f_full, f_reverse) |
| A class that provides information about expressions. | |
| Manipulator | f_manipulator = Manipulator(f_info) |
| A class that can be used to manipulate expressions. | |
| bool | f_processed = false |
| A flag that indicates whether or not the formala Prover::f_formula has been processed. | |
| Answer | f_tautology |
| A flag that indicates whether or not the formala Prover::f_formula is a tautology. | |
| Answer | f_contradiction |
| A flag that indicates whether or not the formala Prover::f_formula is a contradiction. | |
| const double | f_time_limit |
| An integer representing the maximal amount of seconds to be spent on processing a formula. | |
| std::chrono::milliseconds | f_deadline {} |
| A timestamp representing the moment when the maximal amount of milliseconds has been spent on processing the current formula. | |
| substitution_type | bdd_sigma |
| A binary decision diagram in the internal representation of the rewriter. | |
| data_expression | f_bdd |
| A binary decision diagram in the internal representation of mCRL2. | |
Protected Attributes inherited from mcrl2::data::basic_rewriter< data_expression > | |
| std::shared_ptr< detail::Rewriter > | m_rewriter |
| The wrapped Rewriter. | |
Private Member Functions | |
| void | build_bdd () |
| Constructs the EQ-BDD corresponding to the formula Prover::f_formula. | |
| std::string | indent (size_t n) |
| data_expression | bdd_down (const data_expression &formula, const size_t a_indent=0) |
| Creates the EQ-BDD corresponding to the formula formula. | |
| void | eliminate_paths () |
| Removes all inconsistent paths from the BDD BDD_Prover::f_bdd. | |
| void | update_answers () |
| Updates the values of Prover::f_tautology and Prover::f_contradiction. | |
| bool | smallest (const data_expression &formula, data_expression &result) |
| Returns the smallest guard in the formula formula. | |
| bool | get_branch (const data_expression &a_bdd, const bool a_polarity, data_expression &result) |
| Returns branch of the BDD a_bdd, depending on the polarity a_polarity. | |
Private Attributes | |
| bool | f_apply_induction |
| A flag indicating whether or not induction on lists is applied. | |
| std::vector< variable > | f_variables |
| The variables in the expression in order. | |
| std::unordered_map< data_expression, data_expression > | f_formula_to_bdd |
| A hashtable that maps formulas to BDDs. | |
| std::unordered_map< data_expression, data_expression > | f_smallest |
| A hashtable that maps formulas to the smallest guard occuring in those formulas. | |
| std::shared_ptr< BDD_Simplifier > | f_bdd_simplifier |
| Class that simplifies a BDD. | |
| Induction | f_induction |
| Class that creates all statements needed to prove a given property using induction. | |
Static Private Attributes | |
| static constexpr bool | f_reverse = true |
| Flag indicating whether or not the result of the comparison between the first two arguments. | |
| static constexpr bool | f_full = true |
| Flag indicating whether or not the arguments of equality functions are taken into account. | |
Additional Inherited Members | |
Protected Types inherited from mcrl2::data::rewriter | |
| using | substitution_type = basic_rewriter< data_expression >::substitution_type |
Protected Types inherited from mcrl2::data::basic_rewriter< data_expression > | |
| using | substitution_type = data::mutable_indexed_substitution<> |
| The type for the substitution that is used internally. | |
| using | term_type = data_expression |
| The type for expressions manipulated by the rewriter. | |
| using | strategy = rewrite_strategy |
| The rewrite strategies of the rewriter. | |
Protected Member Functions inherited from mcrl2::data::rewriter | |
| rewriter (const std::shared_ptr< detail::Rewriter > &r) | |
| Constructor for internal use. | |
| rewriter (const rewriter &r)=default | |
| Constructor. | |
| rewriter (const data_specification &d=rewriter::default_specification(), const strategy s=rewrite_strategy::jitty) | |
| Constructor. | |
| template<typename EquationSelector > | |
| rewriter (const data_specification &d, const EquationSelector &selector, const strategy s=rewrite_strategy::jitty) | |
| Constructor. | |
| rewriter | clone () |
| Create a clone of the rewriter in which the underlying rewriter is copied, and not passed as a shared pointer. | |
| void | thread_initialise () |
| Initialises this rewriter with thread dependent information. | |
| data_expression | operator() (const data_expression &d) const |
| Rewrites a data expression. | |
| void | operator() (data_expression &result, const data_expression &d) const |
| Rewrites a data expression. | |
| template<IsSubstitution SubstitutionFunction> | |
| data_expression | operator() (const data_expression &d, const SubstitutionFunction &sigma) const |
| Rewrites the data expression d, and on the fly applies a substitution function. to data variables. | |
| template<IsSubstitution SubstitutionFunction> | |
| void | operator() (data_expression &result, const data_expression &d, const SubstitutionFunction &sigma) const |
| Rewrites the data expression d, and on the fly applies a substitution function. to data variables. | |
| data_expression | operator() (const data_expression &d, substitution_type &sigma) const |
| Rewrites the data expression d, and on the fly applies a substitution function to data variables. | |
| void | operator() (data_expression &result, const data_expression &d, substitution_type &sigma) const |
| Rewrites the data expression d, and on the fly applies a substitution function to data variables. | |
| ~rewriter () | |
Protected Member Functions inherited from mcrl2::data::basic_rewriter< data_expression > | |
| basic_rewriter (const std::shared_ptr< detail::Rewriter > &r) | |
| Constructor. | |
| basic_rewriter (const basic_rewriter &other)=default | |
| Copy Constructor. | |
| basic_rewriter (const data_specification &d, const strategy s=rewrite_strategy::jitty) | |
| Constructor. | |
| basic_rewriter (const data_specification &d, const used_data_equation_selector &equation_selector, const strategy s=rewrite_strategy::jitty) | |
| Constructor. | |
| basic_rewriter & | operator= (const basic_rewriter &other)=default |
| Assignment operator. | |
| const data::enumerator_identifier_generator & | identifier_generator () const |
| Expose the identifier generator present in m_rewriter. | |
Static Protected Member Functions inherited from mcrl2::data::rewriter | |
| static substitution_type & | empty_substitution () |
| static const data_specification & | default_specification () |
| Default specification used if no specification is specified at construction. | |
Definition at line 84 of file bdd_prover.h.
Definition at line 87 of file bdd_prover.h.
|
inline |
Definition at line 470 of file bdd_prover.h.
|
inline |
Definition at line 513 of file bdd_prover.h.
|
inlineprivate |
Creates the EQ-BDD corresponding to the formula formula.
Definition at line 184 of file bdd_prover.h.
|
inlineprivate |
Constructs the EQ-BDD corresponding to the formula Prover::f_formula.
Definition at line 147 of file bdd_prover.h.
|
inline |
Definition at line 633 of file bdd_prover.h.
|
inlineprivate |
Removes all inconsistent paths from the BDD BDD_Prover::f_bdd.
Definition at line 248 of file bdd_prover.h.
|
inline |
Returns the BDD BDD_Prover::f_bdd.
Definition at line 549 of file bdd_prover.h.
|
inlineprivate |
Returns branch of the BDD a_bdd, depending on the polarity a_polarity.
Definition at line 423 of file bdd_prover.h.
|
inline |
Returns all the guards on a path in the BDD that leads to a leaf labelled "false", if such a leaf exists.
Definition at line 584 of file bdd_prover.h.
|
inline |
Returns the rewriter used by this prover (i.e. it returns Prover::f_rewriter).
Definition at line 612 of file bdd_prover.h.
|
inline |
Returns all the guards on a path in the BDD that leads to a leaf labelled "true", if such a leaf exists.
Definition at line 556 of file bdd_prover.h.
|
inlineprivate |
Definition at line 178 of file bdd_prover.h.
|
inline |
Indicates whether or not the formula Prover::f_formula is a contradiction.
Definition at line 542 of file bdd_prover.h.
|
inline |
Indicates whether or not the formula Prover::f_formula is a tautology.
Definition at line 535 of file bdd_prover.h.
|
inline |
Returns the strategy of the rewriter used inside this proving rewriter.
Definition at line 618 of file bdd_prover.h.
|
inline |
Sets Prover::f_formula to formula. precondition: the argument passed as parameter formula is an expression of sort Bool.
Definition at line 625 of file bdd_prover.h.
|
inline |
Set the substitution to be used to construct the BDD.
Definition at line 523 of file bdd_prover.h.
|
inline |
Set the substitution in internal format to be used to construct the BDD.
Definition at line 529 of file bdd_prover.h.
|
inlineprivate |
Returns the smallest guard in the formula formula.
Definition at line 338 of file bdd_prover.h.
|
inline |
Definition at line 638 of file bdd_prover.h.
|
inlineprivate |
Updates the values of Prover::f_tautology and Prover::f_contradiction.
Definition at line 266 of file bdd_prover.h.
|
protected |
A binary decision diagram in the internal representation of the rewriter.
Definition at line 464 of file bdd_prover.h.
|
private |
A flag indicating whether or not induction on lists is applied.
Definition at line 127 of file bdd_prover.h.
|
protected |
A binary decision diagram in the internal representation of mCRL2.
Definition at line 467 of file bdd_prover.h.
|
private |
Class that simplifies a BDD.
Definition at line 141 of file bdd_prover.h.
|
protected |
A flag that indicates whether or not the formala Prover::f_formula is a contradiction.
Definition at line 117 of file bdd_prover.h.
|
protected |
A timestamp representing the moment when the maximal amount of milliseconds has been spent on processing the current formula.
Definition at line 123 of file bdd_prover.h.
|
protected |
An expression of sort Bool.
Definition at line 102 of file bdd_prover.h.
|
private |
A hashtable that maps formulas to BDDs.
If the BDD of a formula is unknown, it maps this formula to 0.
Definition at line 134 of file bdd_prover.h.
|
staticconstexprprivate |
Flag indicating whether or not the arguments of equality functions are taken into account.
when determining the order of expressions.
Definition at line 98 of file bdd_prover.h.
|
private |
Class that creates all statements needed to prove a given property using induction.
Definition at line 144 of file bdd_prover.h.
A class that provides information about expressions.
Definition at line 105 of file bdd_prover.h.
|
protected |
A class that can be used to manipulate expressions.
Definition at line 108 of file bdd_prover.h.
|
protected |
A flag that indicates whether or not the formala Prover::f_formula has been processed.
Definition at line 111 of file bdd_prover.h.
|
staticconstexprprivate |
Flag indicating whether or not the result of the comparison between the first two arguments.
weighs stronger than the result of the comparison between the second pair of arguments of an
equation, when determining the order of expressions.
Definition at line 94 of file bdd_prover.h.
|
private |
A hashtable that maps formulas to the smallest guard occuring in those formulas.
If the smallest guard of a formula is unknown, it maps this formula to 0.
Definition at line 138 of file bdd_prover.h.
|
protected |
A flag that indicates whether or not the formala Prover::f_formula is a tautology.
Definition at line 114 of file bdd_prover.h.
|
protected |
An integer representing the maximal amount of seconds to be spent on processing a formula.
Definition at line 120 of file bdd_prover.h.
|
private |
The variables in the expression in order.
Definition at line 130 of file bdd_prover.h.