-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Optimization with quantified SMT solving #1711
Comments
Correct, but why integrate this with opt when this encoding works directly with solvers? |
Thank you for reply! Providing a uniform interface in
Maybe I can collect some benchmarks for comparison. |
I tried integrating qsat for QF_LRA optimization. My results (on a single example) were poor in my view so it is disabled. |
What is the best way to use quantifiers in with OMT? |
@rainoftime, Asking the question again in more detail. Do you have any suggestions on how to encode a quantified formula like the following to a non-quantified one (to be used with OMT)?: W = RealVector('w', 5) **Here SumProduct is a user defined function |
A humble approach is: Pre-instantiate the quantifier with a suitable set of terms. Do ground optimization, then check if the result can be improved using quantified formula. An improvement provides additional instances. |
The standard optimization problem: min$f(x)$ s.t. $P(x)$ (P is a quantifier-free formula)$P(x) \land \forall y . ( P(y) \to f(x) \leq f(y) )$
can be encoded as the logic formula:
Therefore, it seems the
opt
module of z3 can provide an option for optimization with quantified SMT solving. For example, for bit-vector optimization problem, theufbv
tactic can be applied to solve the constructed quantified bit-vector formula.Could you please give some advice on how to integrate such a mechanism into
opt
?The text was updated successfully, but these errors were encountered: