Skip to content

Commit

Permalink
number.py: accuracy needs to work with cypari and cypari2
Browse files Browse the repository at this point in the history
  • Loading branch information
NathanDunfield committed Jan 7, 2025
1 parent f06e184 commit aae6a46
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion python/number.py
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,8 @@ def __init__(self, data, accuracy=None, precision=None):
self.accuracy = self.decimal_precision
else:
if accuracy is None:
accuracy = self.gen.precision()
accuracy = prec_bits_to_dec(64 * (self.gen.sizeword() - 2))

self.accuracy = min(accuracy, self.decimal_precision)
self._parent = SnapPyNumbers(self._precision)
if _within_sage:
Expand Down

0 comments on commit aae6a46

Please sign in to comment.