First time here? Check out the FAQ!

Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

answered 6 years ago

nbruin gravatar image

There's the source:

https://git.sagemath.org/sage.git/tree/src/sage/rings/real_mpfi.pyx

Quickly browsing the file shows RIF elements are pairs of mprf floats, one with "round up" and the other with "round down". It's just relying on mpfr doing its rounding properly.

click to hide/show revision 2
No.2 Revision

There's the source:

https://git.sagemath.org/sage.git/tree/src/sage/rings/real_mpfi.pyx

Quickly browsing the file shows RIF elements are pairs of mprf floats, one with "round up" and the other with "round down". It's just relying on mpfr doing its rounding properly.

For more advanced functionality, however, it's using a library, MPFI:

http://perso.ens-lyon.fr/nathalie.revol/software.html

your should probably reference that library, and the documentation there hopefully has the information you're looking for.