Optimize.
More...
Optimize.
Definition at line 7930 of file z3py.py.
◆ __init__()
__init__ |
( |
| self, |
|
|
| opt, |
|
|
| value, |
|
|
| is_max ) |
Definition at line 7931 of file z3py.py.
7931 def __init__(self, opt, value, is_max):
7932 self._opt = opt
7933 self._value = value
7934 self._is_max = is_max
7935
◆ __str__()
Definition at line 7958 of file z3py.py.
7958 def __str__(self):
7959 return "%s:%s" % (self._value, self._is_max)
7960
7961
◆ lower()
Definition at line 7936 of file z3py.py.
7936 def lower(self):
7937 opt = self._opt
7939
Z3_ast Z3_API Z3_optimize_get_lower(Z3_context c, Z3_optimize o, unsigned idx)
Retrieve lower bound value or approximation for the i'th optimization objective.
◆ lower_values()
Definition at line 7944 of file z3py.py.
7944 def lower_values(self):
7945 opt = self._opt
7947
Z3_ast_vector Z3_API Z3_optimize_get_lower_as_vector(Z3_context c, Z3_optimize o, unsigned idx)
Retrieve lower bound value or approximation for the i'th optimization objective. The returned vector ...
◆ upper()
Definition at line 7940 of file z3py.py.
7940 def upper(self):
7941 opt = self._opt
7943
Z3_ast Z3_API Z3_optimize_get_upper(Z3_context c, Z3_optimize o, unsigned idx)
Retrieve upper bound value or approximation for the i'th optimization objective.
◆ upper_values()
Definition at line 7948 of file z3py.py.
7948 def upper_values(self):
7949 opt = self._opt
7951
Z3_ast_vector Z3_API Z3_optimize_get_upper_as_vector(Z3_context c, Z3_optimize o, unsigned idx)
Retrieve upper bound value or approximation for the i'th optimization objective.
◆ value()
Definition at line 7952 of file z3py.py.
7952 def value(self):
7953 if self._is_max:
7954 return self.upper()
7955 else:
7956 return self.lower()
7957
◆ _is_max
◆ _opt
◆ _value