Replies: 1 comment
-
Use "define-const" and "define-fun" |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Consider the following formula:
Formula 1
It takes few milliseconds to output
sat
. However, if I want to rewrite the formula by introducing aliases for expressions as following:Formula 2
See how much shorter it is. But for some reason Z3 is x100 times slower on this example. Why? I guess in the first example Z3 is using all the values as intermediate results and discard them after they are no longer needed, but in the second example Z3 keeps track of all auxiliary variables in case
get-model
is invoked.How can I instruct Z3 to consider all of the auxiliary variables as aliases for expressions and exclude them from the final model? I don't even want to call
get-model
at all, so Z3 can discard all variables, all I want is to know the satisfiability. Basically, what is the optimal way to define an alias for an expression that may occur multiple times in the formula?Thanks.
Beta Was this translation helpful? Give feedback.
All reactions