summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Reynolds <andrew.j.reynolds@gmail.com>2020-06-22 11:45:41 -0500
committerGitHub <noreply@github.com>2020-06-22 11:45:41 -0500
commit0045ba2af7b31243c545828494d11f53e16f59db (patch)
tree43a790c1870422901d015d7ce893d872284cd246
parent4bd54ef0cc862ae8736c97ecca07f80ab31396df (diff)
Add trascendental function kinds to list of unevaluated operators (#4640)
Fixes #4636. This adds transcendental function kinds to the list of unevaluated operators (operators that don't necessarily rewrite to constants when applied to constant children). One consequence of this is that when models are enabled, we cannot solve for equations like (= a (cos b)), since the value of (cos b) is not necessarily evaluable, and hence must be approximated. As a result, we answer the benchmark on #4636 instead of generating an incorrect model (when models are enabled). When models are disabled, we answer "sat". A regression had a similar issue which happened to be succeeding. I've added --no-check-models to this regression (or otherwise we would answer unknown for this benchmark).
-rw-r--r--src/theory/arith/theory_arith.cpp4
-rw-r--r--test/regress/regress0/nl/issue3729-cm-solved-tf.smt22
2 files changed, 5 insertions, 1 deletions
diff --git a/src/theory/arith/theory_arith.cpp b/src/theory/arith/theory_arith.cpp
index b63566c29..c25090f38 100644
--- a/src/theory/arith/theory_arith.cpp
+++ b/src/theory/arith/theory_arith.cpp
@@ -72,6 +72,10 @@ void TheoryArith::finishInit()
{
// witness is used to eliminate square root
tm->setUnevaluatedKind(kind::WITNESS);
+ // we only need to add the operators that are not syntax sugar
+ tm->setUnevaluatedKind(kind::EXPONENTIAL);
+ tm->setUnevaluatedKind(kind::SINE);
+ tm->setUnevaluatedKind(kind::PI);
}
}
diff --git a/test/regress/regress0/nl/issue3729-cm-solved-tf.smt2 b/test/regress/regress0/nl/issue3729-cm-solved-tf.smt2
index 69bb74e84..75d4b6e3a 100644
--- a/test/regress/regress0/nl/issue3729-cm-solved-tf.smt2
+++ b/test/regress/regress0/nl/issue3729-cm-solved-tf.smt2
@@ -1,4 +1,4 @@
-; COMMAND-LINE: --quiet
+; COMMAND-LINE: --quiet --no-check-models
; EXPECT: sat
(set-logic QF_NRAT)
(set-info :status sat)
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback