# HG changeset patch
# User Paul Zimmermann <zimmerma@loria.fr>
# Date 1266961804 -3600
# Node ID 1bc5cd577f888df838d501d693afb51737aebaf5
# Parent 5b7040fd9e7dc9192ee2b0ce7f699d9120d78358
increased precision limit for RealField from 2^24 to 2^31-1, which is the
maximum possible (within Sage) [together with Francois Maltey]
diff -r 5b7040fd9e7d -r 1bc5cd577f88 sage/rings/real_mpfr.pyx
a
|
b
|
|
177 | 177 | """ |
178 | 178 | return MPFR_PREC_MIN |
179 | 179 | |
180 | | cdef int MY_MPFR_PREC_MAX = 16777216 |
| 180 | cdef int MY_MPFR_PREC_MAX = 2147483647 |
181 | 181 | def mpfr_prec_max(): |
182 | 182 | global MY_MPFR_PREC_MAX |
183 | | # lots of things in mpfr *crash* if we use MPFR_PREC_MAX! |
184 | | # So don't. Using 2**24 seems to work well. (see above) |
| 183 | # We use 2^31-1 as the largest precision, since 2^31 is not representable |
| 184 | # as a 32-bit int |
185 | 185 | return MY_MPFR_PREC_MAX |
186 | 186 | |
187 | 187 | #***************************************************************************** |