3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-05-02 13:27:01 +00:00

add missing tactic descriptions, add rewrite for tamagochi

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
Nikolaj Bjorner 2023-01-08 13:32:26 -08:00
parent 95cb06d8cf
commit fcea32344e
19 changed files with 147 additions and 49 deletions

View file

@ -13,6 +13,42 @@ Author:
Nikolaj Bjorner (nbjorner) 2022-10-30
Tactic Documentation:
## Tactic elim-predicates
### Short Description
Eliminates predicates and macros from a formula.
### Long Description
The tactic subsumes the functionality of `macro-finder` and `quasi-macros`.
Besides finding macros, it eliminates predicates using Davis-Putnam
resolution.
### Example
the predicate `p` occurs once positively. All negative occurrences of `p` are resolved against this positive occurrence.
The result of resolution is a set of equalities between arguments to `p`. The function `f` is replaced by a partial solution.
```
(declare-fun f (Int Int Int) Int)
(declare-fun p (Int) Bool)
(declare-const a Int)
(declare-const b Int)
(assert (forall ((x Int) (y Int)) (= (f x y (+ x y)) (* 2 x y))))
(assert (p (f 8 a (+ a 8))))
(assert (not (p (f 0 a (+ a 8)))))
(assert (not (p (f 2 a (+ a 8)))))
(assert (not (p (f 1 a (+ a b)))))
(apply elim-predicates)
```
### Notes
* support unsat cores
* does not support proofs
--*/
#pragma once