mirror of
https://github.com/Z3Prover/z3
synced 2025-05-02 13:27:01 +00:00
more tactic descriptions
This commit is contained in:
parent
0d8a472aac
commit
c07b6ab38f
10 changed files with 233 additions and 46 deletions
|
@ -14,7 +14,29 @@ Author:
|
|||
|
||||
Nikolaj and Nuno
|
||||
|
||||
Notes:
|
||||
Tactic Documentation:
|
||||
|
||||
## Tactic dom-simplify
|
||||
|
||||
### Short Description
|
||||
|
||||
Apply dominator simplification rules
|
||||
|
||||
### Long Description
|
||||
|
||||
Dominator-based simplification is a context dependent simplification function that uses a dominator tree to control the number of paths it
|
||||
visits during simplification. The expression DAG may have an exponential number of paths, but only paths corresponding to a dominator
|
||||
tree are visited. Since the paths selected by the dominator trees are limited, the simplifier may easily fail to simplify within a context.
|
||||
|
||||
### Example
|
||||
|
||||
```z3
|
||||
(declare-const a Bool)
|
||||
(declare-const b Bool)
|
||||
(assert (and a (or a b)))
|
||||
(apply dom-simplify)
|
||||
```
|
||||
|
||||
|
||||
--*/
|
||||
|
||||
|
|
|
@ -5,20 +5,42 @@ Module Name:
|
|||
|
||||
occf_tactic.h
|
||||
|
||||
Abstract:
|
||||
|
||||
Put clauses in the assertion set in
|
||||
OOC (one constraint per clause) form.
|
||||
Constraints occurring in formulas that
|
||||
are not clauses are ignored.
|
||||
The formula can be put into CNF by
|
||||
using mk_sat_preprocessor strategy.
|
||||
|
||||
Author:
|
||||
|
||||
Leonardo de Moura (leonardo) 2011-12-28.
|
||||
|
||||
Revision History:
|
||||
Tactic Documentation:
|
||||
|
||||
## Tactic occf
|
||||
|
||||
### Short Description
|
||||
|
||||
Put goal in one constraint per clause normal form
|
||||
|
||||
### Long Description
|
||||
|
||||
Put clauses in the assertion set in
|
||||
OOC (one constraint per clause) form.
|
||||
Constraints occurring in formulas that
|
||||
are not clauses are ignored.
|
||||
The formula can be put into CNF by
|
||||
using `mk_sat_preprocessor` strategy.
|
||||
|
||||
### Example
|
||||
|
||||
```z3
|
||||
(declare-const x Int)
|
||||
(declare-const y Int)
|
||||
|
||||
(assert (or (= x y) (> x (- y))))
|
||||
(assert (or (= x y) (< x (- y))))
|
||||
(apply occf)
|
||||
```
|
||||
|
||||
### Notes
|
||||
|
||||
* Does not support proofs
|
||||
* only clauses are considered
|
||||
|
||||
--*/
|
||||
#pragma once
|
||||
|
|
|
@ -13,7 +13,20 @@ Author:
|
|||
|
||||
Nikolaj (nbjorner) 2011-05-31
|
||||
|
||||
Notes:
|
||||
|
||||
Tactic Documentation:
|
||||
|
||||
## Tactic symmetry-reduce
|
||||
|
||||
### Short Description
|
||||
|
||||
Apply symmetry reduction
|
||||
|
||||
### Long Description
|
||||
|
||||
The tactic applies symmetry reduction for uninterpreted functions and equalities.
|
||||
It applies a straight-forward adaption of an algorithm proposed for veriT.
|
||||
|
||||
|
||||
--*/
|
||||
#pragma once
|
||||
|
|
|
@ -7,43 +7,63 @@ Module Name:
|
|||
|
||||
Abstract:
|
||||
|
||||
Puts an assertion set in CNF.
|
||||
Auxiliary variables are used to avoid blowup.
|
||||
|
||||
Features:
|
||||
|
||||
- Efficient encoding is used for commonly used patterns such as:
|
||||
(iff a (iff b c))
|
||||
(or (not (or a b)) (not (or a c)) (not (or b c)))
|
||||
|
||||
- Efficient encoding is used for chains of if-then-elses
|
||||
|
||||
- Distributivity is applied to non-shared nodes if the blowup is acceptable.
|
||||
|
||||
- The features above can be disabled/enabled using parameters.
|
||||
|
||||
- The assertion-set is only modified if the resultant set of clauses
|
||||
is "acceptable".
|
||||
|
||||
Notes:
|
||||
|
||||
- Term-if-then-else expressions are not handled by this strategy.
|
||||
This kind of expression should be processed by other strategies.
|
||||
|
||||
- Quantifiers are treated as "theory" atoms. They are viewed
|
||||
as propositional variables by this strategy.
|
||||
|
||||
- The assertion set may contain free variables.
|
||||
|
||||
- This strategy assumes the assertion_set_rewriter was
|
||||
used before invoking it.
|
||||
In particular, it is more effective when "and" operators
|
||||
were eliminated.
|
||||
|
||||
Author:
|
||||
|
||||
Leonardo (leonardo) 2011-12-29
|
||||
|
||||
Tactic Documentation:
|
||||
|
||||
## Tactic tseitin-cnf
|
||||
|
||||
### Short Description
|
||||
|
||||
Convert goal into CNF using tseitin-like encoding (note: quantifiers are ignored).
|
||||
|
||||
### Long Description
|
||||
|
||||
Puts an assertion set in CNF.
|
||||
Auxiliary variables are used to avoid blowup.
|
||||
|
||||
Features:
|
||||
|
||||
- Efficient encoding is used for commonly used patterns such as:
|
||||
`(iff a (iff b c))`
|
||||
`(or (not (or a b)) (not (or a c)) (not (or b c)))`
|
||||
|
||||
- Efficient encoding is used for chains of if-then-elses
|
||||
|
||||
- Distributivity is applied to non-shared nodes if the blowup is acceptable.
|
||||
|
||||
- The features above can be disabled/enabled using parameters.
|
||||
|
||||
- The assertion-set is only modified if the resultant set of clauses is "acceptable".
|
||||
|
||||
Notes:
|
||||
|
||||
- Term-if-then-else expressions are not handled by this strategy.
|
||||
This kind of expression should be processed by other strategies.
|
||||
|
||||
- Quantifiers are treated as "theory" atoms. They are viewed
|
||||
as propositional variables by this strategy.
|
||||
|
||||
- The assertion set may contain free variables.
|
||||
|
||||
- This strategy assumes the assertion_set_rewriter was used before invoking it.
|
||||
In particular, it is more effective when "and" operators
|
||||
were eliminated.
|
||||
|
||||
### Example
|
||||
|
||||
```z3
|
||||
(declare-const a Bool)
|
||||
(declare-const b Bool)
|
||||
(declare-const c Bool)
|
||||
|
||||
(assert (= a (= b c)))
|
||||
(apply tseitin-cnf)
|
||||
```
|
||||
|
||||
--*/
|
||||
#pragma once
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue