# Concerning "bits of precision"

I am a newcomer to Sage. I learn Sage to compute Gröbner bases.

Concerning polynomial ring, if I type:

R = PolynomialRing(QQ, 't')
R


I get:

Univariate Polynomial Ring in t over Rational Field


But if I type:

R = PolynomialRing(RR, 't')
R


I get:

Univariate Polynomial Ring in t over Real Field with 53 bits of precision


What does "with 53 bits of precision" mean? If I don't know its meaning, will it matter when I compute Gröbner bases? I would appreciate any help with this situation.

edit retag close merge delete

Sort by » oldest newest most voted

When sage works with "real numbers", it works with floating point approximations to them. They suffer from precision loss:

sage: RR(1)+RR(10^40)-RR(10^40) == 0
True


That means that if you wanted to do groebner basis computations for polynomial rings over RR, you'd have to be very careful about numerical stability, precision loss, and the fact that "cancellation" is almost never exact due to rounding. It's quite different from groebner basis computations over rings with exact element representations. I am not aware of support for groebner bases over RR in sage.

Finite fields, QQ, and algebraic coefficients should be OK, though, Perhaps you can get by with those?

more