3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-23 17:15:31 +00:00
Commit graph

15853 commits

Author SHA1 Message Date
Nikolaj Bjorner
5cfe273460 #5211
```
 (declare-fun v5 () Bool)
 (declare-fun i1 () Int)
 (declare-fun i2 () Int)
 (declare-fun i4 () Int)
 (declare-fun i5 () Int)
 (declare-fun i6 () Int)
 (declare-fun i9 () Int)
 (declare-fun i10 () Int)
 (assert (or (not (=> (= 23 i6 i4 i2 85) v5)) (<= i1 8 i9 i9 (+ (+ i1 349 i10 i6) i5)) (>= i4 782)))
 (check-sat)
```
2021-04-22 22:10:39 -07:00
Nikolaj Bjorner
bcb33a5b3a remove unused functions 2021-04-22 21:46:31 -07:00
Nikolaj Bjorner
4c4810c611 fix #5207 2021-04-22 13:10:11 -07:00
Nikolaj Bjorner
d67919373e add bailout option for code review #5208
@levnach
Could you review and maybe make this much more streamlined?
The patch is to simply bail out the iterator if it fails to find canonical monics.
If m_ff could produce the existing canonical monics up front this kind of bail-out could maybe avoided.
2021-04-22 11:30:11 -07:00
Jakob Rath
12444c7e8b
Phase saving and some minor changes (#5209)
* Implement phase saving

* Implement signed comparison on BDD vectors

* Add fdd::non_zero

* Simplify construction of fdds over disjoint variables

* Minor changes to adding constraint
2021-04-22 09:47:46 -07:00
Nikolaj Bjorner
09f31ebb0a working on pivot
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-20 17:46:09 -07:00
Nikolaj Bjorner
2d8769dc64 working on pivot
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-20 17:42:33 -07:00
Nikolaj Bjorner
36cd80748f working on pivot
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-20 17:42:01 -07:00
Nikolaj Bjorner
80751bdd12 na
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-20 14:20:39 -07:00
Nikolaj Bjorner
80492e65ea na
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-20 14:11:46 -07:00
Nikolaj Bjorner
3049ec82de na
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-20 14:08:38 -07:00
Nikolaj Bjorner
ee081f7434 na
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-20 14:05:28 -07:00
Nikolaj Bjorner
ce8184382d add dummy implementations
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-20 14:02:12 -07:00
Tias Guns
a52b485d9c
marco: immediately shrink to core if not subset (#5203)
Small improvement, found while translating it in another system
2021-04-20 12:29:52 -07:00
Nikolaj Bjorner
fc60690742 tidy, initial polysat
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-20 12:21:50 -07:00
Nikolaj Bjorner
82bc6474a3 Merge branch 'polysat' of https://github.com/z3prover/z3 into polysat 2021-04-20 12:03:33 -07:00
Nikolaj Bjorner
831edba1c8 fixplex
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-20 12:03:28 -07:00
Nikolaj Bjorner
8263d20e0d add code review comment 2021-04-20 11:30:25 -07:00
Nikolaj Bjorner
b658934bd8 fix #5197 fix #5193 2021-04-20 10:16:44 -07:00
Nikolaj Bjorner
44d77a978a cw review comments #5200 2021-04-20 09:27:59 -07:00
Nikolaj Bjorner
770c79a939 prepare for std::vector 2021-04-20 09:24:24 -07:00
Jakob Rath
77350d97da
BDD vectors: add subtract and quot_rem, move finite domain abstraction out of bdd_manager (#5201)
* Coding style

* Simplify bddv class

* mk_eq: run loop from below

* Add unit test for bddv unsigned comparison

* Add test that shows contains_num/find_num fail after reordering

* Add BDD vector subtraction

* Call apply_rec in mk_ite_rec instead of apply

* Question about mk_quant

* Implement quot_rem over BDD vectors

* Move shl/shr to bddv

* Make unit test smaller

* Add class dd::fdd to manage association between BDDs and numbers

* Remove contains_num/find_num from bdd_manager
2021-04-20 09:09:32 -07:00
alexandernutz
bc695a5a97
monotonicity unit tests (#5202)
* monotonicity unit tests

* indentation
2021-04-20 09:09:17 -07:00
Zachary Wimer
831afa8124
Cpp api add missing fp methods (return type correction) (#5200)
* added is_nan and is_inf to API

* added support to to_ieee_bv

* bug fix
2021-04-19 17:55:23 -07:00
Zachary Wimer
10e9345cd7
C++ API add missing FP methods (#5199)
* added is_nan and is_inf to API

* added support to to_ieee_bv
2021-04-19 15:24:09 -07:00
Jakob Rath
4da1b7b03c
Add functionality for BDD vectors (#5198)
* Fix XOR over BDDs

* Add operator<< for find_int_t

* Add equality assertion macro that prints expression values on failure

* Adapt contains_int and find_int to take externally-defined bits

* Add more operations on BDD vectors

* Remove old functions

* Additional bddv functions

* Rename some things

* Make bddv a class and add operators

* Fix find_num/contains_num calls
2021-04-19 09:05:19 -07:00
Zachary Wimer
542878dea3
Add sge and sgt to API; now has sge,sgt,sle,slt, and unsigned counterparts (#5194) 2021-04-19 08:53:43 -07:00
Zachary Wimer
f8228ff50e
[c++ api] add const (#5195) 2021-04-19 10:24:12 +01:00
Nikolaj Bjorner
981839ee73 separate out search throttle
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-17 14:36:50 -07:00
Nikolaj Bjorner
0d65b19c20 cr
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-17 14:27:47 -07:00
Nikolaj Bjorner
4b35c75712 add code review and replacement for mk_int
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-17 14:19:17 -07:00
Nuno Lopes
e67b9ebcf7 try to fix ARM32 build (#2776) 2021-04-17 16:14:05 +01:00
Nikolaj Bjorner
572197aede add some code review comments, stubs for ule
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-16 12:43:23 -07:00
Nikolaj Bjorner
9df7e9a029 add outline for ule constraints, change bit to var constraints
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-16 12:31:11 -07:00
Nikolaj Bjorner
5706c7a93b addition
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-16 10:37:53 -07:00
Nikolaj Bjorner
c7868579c0 add sample bdd vector operations
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-16 10:22:48 -07:00
Nikolaj Bjorner
af2376e9e4 fix build
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-16 10:00:44 -07:00
Jakob Rath
f72e30e539
Add BDD utilities; use them for narrowing/propagation of linear equality constraints (#5192)
* Add a few helper methods for encoding sets of integers as BDDs

* Use BDD functions in solver

* Add bdd::find_int

* Use bdd::find_int in solver

* Add narrowing for linear equality constraints

* Simplify code for linear propagation

* Add test for later

* Narrowing can only handle linear constraints with a single variable

* Need to push_cjust
2021-04-16 08:44:18 -07:00
Zachary Wimer
a1741e0e16
z3 c++ api: delete implicit constructor (#5191) 2021-04-16 10:46:03 +01:00
Nikolaj Bjorner
e970fe5034 sketch bit-constraints
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-15 23:04:25 -07:00
Nikolaj Bjorner
dce9740a38 na
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-15 21:53:27 -07:00
Nikolaj Bjorner
12ccd99e84 trail
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-15 17:39:00 -07:00
Nikolaj Bjorner
549b984c88 move to self-contained trail instructions
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-15 17:38:36 -07:00
Nikolaj Bjorner
2eadcd586a add new file for eq_constraint
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-15 14:34:01 -07:00
Nikolaj Bjorner
c733789467 move more equality functionality
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-15 14:24:50 -07:00
Zachary Wimer
239ace4353
expr move semantics supported via ast (#5190) 2021-04-15 13:37:31 -07:00
Nikolaj Bjorner
5163492d5b move constraint handler functionality to self-contained / separate classes.
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-15 13:08:25 -07:00
Nikolaj Bjorner
0d78a10630 na
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-04-15 12:11:33 -07:00
Jakob Rath
55a908e357
Fix Windows build (#5188) 2021-04-15 09:18:20 -07:00
Jakob Rath
cb9dda19dd
Polysat (#5187)
* test_l2 works now

* Linear propagation: test whether a is odd

* Linear propagation with even coefficients (wip)
2021-04-15 08:37:14 -07:00