mirror of
https://github.com/Z3Prover/z3
synced 2025-04-27 02:45:51 +00:00
Add API for extracting numerator/denominator of RCF numerals. Add field to store the original isolating interval before refinement.
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
This commit is contained in:
parent
991a1528cd
commit
799fe073db
4 changed files with 101 additions and 47 deletions
|
@ -154,3 +154,8 @@ class RCFNum:
|
|||
v = _to_rcfnum(other, self.ctx)
|
||||
return Z3_rcf_neq(self.ctx_ref(), self.num, v.num)
|
||||
|
||||
def split(self):
|
||||
n = (RCFNumObj * 1)()
|
||||
d = (RCFNumObj * 1)()
|
||||
Z3_rcf_get_numerator_denominator(self.ctx_ref(), self.num, n, d)
|
||||
return (RCFNum(n[0], self.ctx), RCFNum(d[0], self.ctx))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue