MCPcopy Create free account
hub / github.com/BasisResearch/lean.py / maximize

Method maximize

lean_py/z3/solver.py:817–820  ·  view source on GitHub ↗

Add maximization objective (returns handle index).

(self, expr: ExprRef)

Source from the content-addressed store, hash-verified

815 self._assertions.append(a)
816
817 def maximize(self, expr: ExprRef) -> int:
818 """Add maximization objective (returns handle index)."""
819 self._objectives.append(("max", expr))
820 return len(self._objectives) - 1
821
822 def minimize(self, expr: ExprRef) -> int:
823 """Add minimization objective (returns handle index)."""

Callers 2

test_maximizeMethod · 0.95
test_reprMethod · 0.95

Calls

no outgoing calls

Tested by 2

test_maximizeMethod · 0.76
test_reprMethod · 0.76