Skip to content
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

Clarify optimizer guarantees #7030

Merged
merged 4 commits into from
Dec 4, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/api/dotnet/Optimize.cs
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ public Handle AssertSoft(BoolExpr constraint, uint weight, string group)
/// <summary>
/// Check satisfiability of asserted constraints.
/// Produce a model that (when the objectives are bounded and
/// don't use strict inequalities) meets the objectives.
/// don't use strict inequalities) is optimal.
/// </summary>
///
public Status Check(params Expr[] assumptions)
Expand Down
2 changes: 1 addition & 1 deletion src/api/java/Optimize.java
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ public Handle<?> AssertSoft(Expr<BoolSort> constraint, String weight, String gro
/**
* Check satisfiability of asserted constraints.
* Produce a model that (when the objectives are bounded and
* don't use strict inequalities) meets the objectives.
* don't use strict inequalities) is optimal.
**/
public Status Check(Expr<BoolSort>... assumptions)
{
Expand Down
2 changes: 1 addition & 1 deletion src/api/ml/z3.mli
Original file line number Diff line number Diff line change
Expand Up @@ -3481,7 +3481,7 @@ sig
(** Add minimization objective. *)
val minimize : optimize -> Expr.expr -> handle

(** Checks whether the assertions in the context are satisfiable and solves objectives. *)
(** Check consistency and produce optimal values. *)
val check : optimize -> Solver.status

(** Retrieve model from satisfiable context *)
Expand Down
2 changes: 1 addition & 1 deletion src/api/python/z3/z3.py
Original file line number Diff line number Diff line change
Expand Up @@ -8046,7 +8046,7 @@ def pop(self):
Z3_optimize_pop(self.ctx.ref(), self.optimize)

def check(self, *assumptions):
"""Check satisfiability while optimizing objective functions."""
"""Check consistency and produce optimal values."""
assumptions = _get_args(assumptions)
num = len(assumptions)
_assumptions = (Ast * num)()
Expand Down