diff options
author | Andres Noetzli <andres.noetzli@gmail.com> | 2019-11-18 17:59:22 -0800 |
---|---|---|
committer | Andrew Reynolds <andrew.j.reynolds@gmail.com> | 2019-11-18 19:59:22 -0600 |
commit | 45bcf28ab55c0fe471b445820fc21627495beee8 (patch) | |
tree | 3eabd78b5163075e5b4dcd00d0370a8a8f339bca /test/regress/regress0/nl | |
parent | 7ac4aac015e69a6f377c5254c600bea386d58577 (diff) |
Fix reduction of `sqrt` (#3478)
Diffstat (limited to 'test/regress/regress0/nl')
-rw-r--r-- | test/regress/regress0/nl/issue3475.smt2 | 6 | ||||
-rw-r--r-- | test/regress/regress0/nl/sqrt.smt2 | 39 |
2 files changed, 45 insertions, 0 deletions
diff --git a/test/regress/regress0/nl/issue3475.smt2 b/test/regress/regress0/nl/issue3475.smt2 new file mode 100644 index 000000000..128d08a18 --- /dev/null +++ b/test/regress/regress0/nl/issue3475.smt2 @@ -0,0 +1,6 @@ +(set-logic ALL) +(declare-fun x () Real) +(assert (< x 0)) +(assert (not (= (/ (sqrt x) (sqrt x)) x))) +(set-info :status sat) +(check-sat) diff --git a/test/regress/regress0/nl/sqrt.smt2 b/test/regress/regress0/nl/sqrt.smt2 new file mode 100644 index 000000000..fdcec3d62 --- /dev/null +++ b/test/regress/regress0/nl/sqrt.smt2 @@ -0,0 +1,39 @@ +; EXPECT: sat +; EXPECT: sat +; EXPECT: unsat +; EXPECT: sat +; EXPECT: unsat +(set-option :incremental true) +(set-logic ALL) +(declare-fun x () Real) +(declare-fun y () Real) +(declare-fun z () Real) + +(push) +(assert (= (sqrt 1.0) 1.0)) +(check-sat) +(pop) + +(push) +(assert (= (sqrt 1.0) (- 1.0))) +(check-sat) +(pop) + +(push) +(assert (= x 1.0)) +(assert (not (= (sqrt 1.0) (sqrt x)))) +(check-sat) +(pop) + +(push) +(assert (< x 0)) +(assert (= (sqrt 1.0) (sqrt x))) +(check-sat) +(pop) + +(push) +(assert (= (sqrt y) z)) +(assert (= (sqrt x) (sqrt y))) +(assert (not (= (sqrt x) z))) +(check-sat) +(pop) |