FP Numerals.
More...
|
def | sign (self) |
|
def | sign_as_bv (self) |
|
def | significand (self) |
|
def | significand_as_long (self) |
|
def | significand_as_bv (self) |
|
def | exponent (self, biased=True) |
|
def | exponent_as_long (self, biased=True) |
|
def | exponent_as_bv (self, biased=True) |
|
def | isNaN (self) |
|
def | isInf (self) |
|
def | isZero (self) |
|
def | isNormal (self) |
|
def | isSubnormal (self) |
|
def | isPositive (self) |
|
def | isNegative (self) |
|
def | as_string (self) |
|
def | sort (self) |
|
def | ebits (self) |
|
def | sbits (self) |
|
def | __le__ (self, other) |
|
def | __lt__ (self, other) |
|
def | __ge__ (self, other) |
|
def | __gt__ (self, other) |
|
def | __add__ (self, other) |
|
def | __radd__ (self, other) |
|
def | __sub__ (self, other) |
|
def | __rsub__ (self, other) |
|
def | __mul__ (self, other) |
|
def | __rmul__ (self, other) |
|
def | __pos__ (self) |
|
def | __neg__ (self) |
|
def | __div__ (self, other) |
|
def | __rdiv__ (self, other) |
|
def | __truediv__ (self, other) |
|
def | __rtruediv__ (self, other) |
|
def | __mod__ (self, other) |
|
def | __rmod__ (self, other) |
|
def | as_ast (self) |
|
def | get_id (self) |
|
def | sort_kind (self) |
|
def | __eq__ (self, other) |
|
def | __hash__ (self) |
|
def | __ne__ (self, other) |
|
def | params (self) |
|
def | decl (self) |
|
def | num_args (self) |
|
def | arg (self, idx) |
|
def | children (self) |
|
def | __init__ (self, ast, ctx=None) |
|
def | __del__ (self) |
|
def | __deepcopy__ (self, memo={}) |
|
def | __str__ (self) |
|
def | __repr__ (self) |
|
def | __nonzero__ (self) |
|
def | __bool__ (self) |
|
def | sexpr (self) |
|
def | ctx_ref (self) |
|
def | eq (self, other) |
|
def | translate (self, target) |
|
def | __copy__ (self) |
|
def | hash (self) |
|
def | use_pp (self) |
|
FP Numerals.
The sign of the numeral.
>>> x = FPVal(+1.0, FPSort(8, 24))
>>> x.sign()
False
>>> x = FPVal(-1.0, FPSort(8, 24))
>>> x.sign()
True
Definition at line 9080 of file z3py.py.
◆ as_string()
Return a Z3 floating point expression as a Python string.
Reimplemented from FPRef.
Definition at line 9194 of file z3py.py.
9194 def as_string(self):
9196 return (
"FPVal(%s, %s)" % (s, self.sort()))
◆ exponent()
def exponent |
( |
|
self, |
|
|
|
biased = True |
|
) |
| |
Definition at line 9137 of file z3py.py.
9137 def exponent(self, biased=True):
◆ exponent_as_bv()
def exponent_as_bv |
( |
|
self, |
|
|
|
biased = True |
|
) |
| |
Definition at line 9156 of file z3py.py.
9156 def exponent_as_bv(self, biased=True):
◆ exponent_as_long()
def exponent_as_long |
( |
|
self, |
|
|
|
biased = True |
|
) |
| |
Definition at line 9146 of file z3py.py.
9146 def exponent_as_long(self, biased=True):
9147 ptr = (ctypes.c_longlong * 1)()
9149 raise Z3Exception(
"error retrieving the exponent of a numeral.")
◆ isInf()
◆ isNaN()
◆ isNegative()
Definition at line 9184 of file z3py.py.
9184 def isNegative(self):
◆ isNormal()
◆ isPositive()
Definition at line 9180 of file z3py.py.
9180 def isPositive(self):
◆ isSubnormal()
Definition at line 9176 of file z3py.py.
9176 def isSubnormal(self):
◆ isZero()
◆ sign()
Definition at line 9090 of file z3py.py.
9091 l = (ctypes.c_int)()
9093 raise Z3Exception(
"error retrieving the sign of a numeral.")
◆ sign_as_bv()
Definition at line 9100 of file z3py.py.
9100 def sign_as_bv(self):
◆ significand()
Definition at line 9109 of file z3py.py.
9109 def significand(self):
◆ significand_as_bv()
def significand_as_bv |
( |
|
self | ) |
|
Definition at line 9128 of file z3py.py.
9128 def significand_as_bv(self):
◆ significand_as_long()
def significand_as_long |
( |
|
self | ) |
|
Definition at line 9118 of file z3py.py.
9118 def significand_as_long(self):
9119 ptr = (ctypes.c_ulonglong * 1)()
9121 raise Z3Exception(
"error retrieving the significand of a numeral.")
bool Z3_API Z3_fpa_is_numeral_positive(Z3_context c, Z3_ast t)
Checks whether a given floating-point numeral is positive.
bool Z3_API Z3_fpa_is_numeral_inf(Z3_context c, Z3_ast t)
Checks whether a given floating-point numeral is a +oo or -oo.
Z3_ast Z3_API Z3_fpa_get_numeral_exponent_bv(Z3_context c, Z3_ast t, bool biased)
Retrieves the exponent of a floating-point literal as a bit-vector expression.
bool Z3_API Z3_fpa_get_numeral_exponent_int64(Z3_context c, Z3_ast t, int64_t *n, bool biased)
Return the exponent value of a floating-point numeral as a signed 64-bit integer.
bool Z3_API Z3_fpa_is_numeral_negative(Z3_context c, Z3_ast t)
Checks whether a given floating-point numeral is negative.
Z3_string Z3_API Z3_get_numeral_string(Z3_context c, Z3_ast a)
Return numeral value, as a decimal string of a numeric constant term.
bool Z3_API Z3_fpa_get_numeral_significand_uint64(Z3_context c, Z3_ast t, uint64_t *n)
Return the significand value of a floating-point numeral as a uint64.
Z3_ast Z3_API Z3_fpa_get_numeral_sign_bv(Z3_context c, Z3_ast t)
Retrieves the sign of a floating-point literal as a bit-vector expression.
bool Z3_API Z3_fpa_is_numeral_nan(Z3_context c, Z3_ast t)
Checks whether a given floating-point numeral is a NaN.
Z3_string Z3_API Z3_fpa_get_numeral_significand_string(Z3_context c, Z3_ast t)
Return the significand value of a floating-point numeral as a string.
Z3_string Z3_API Z3_fpa_get_numeral_exponent_string(Z3_context c, Z3_ast t, bool biased)
Return the exponent value of a floating-point numeral as a string.
bool Z3_API Z3_fpa_is_numeral_subnormal(Z3_context c, Z3_ast t)
Checks whether a given floating-point numeral is subnormal.
bool Z3_API Z3_fpa_get_numeral_sign(Z3_context c, Z3_ast t, int *sgn)
Retrieves the sign of a floating-point literal.
bool Z3_API Z3_fpa_is_numeral_normal(Z3_context c, Z3_ast t)
Checks whether a given floating-point numeral is normal.
bool Z3_API Z3_fpa_is_numeral_zero(Z3_context c, Z3_ast t)
Checks whether a given floating-point numeral is +zero or -zero.
Z3_ast Z3_API Z3_fpa_get_numeral_significand_bv(Z3_context c, Z3_ast t)
Retrieves the significand of a floating-point literal as a bit-vector expression.