up previous next
RealRootsApprox

computes approximations to the real roots of a univariate polynomial

Syntax
RealRootsApprox(F: RINGELEM): LIST
RealRootsApprox(F: RINGELEM, Precision: RAT): LIST
RealRootsApprox(F: RINGELEM, Precision: RAT, Interval:[RAT, RAT]): LIST

Description
This function computes rational approximations to the real roots of a univariate polyomial (with rational coefficients).

An optional second argument specifies the maximum separation between the approximations produced and the corresponding exact root. An optional third argument specifies a closed interval in which to search for roots.

Example
/**/  RealRootsApprox(x^2-2);
[-3037000499/2147483648, 3037000499/2147483648]

/**/  RR := RealRootsApprox(x^2-2, 10^(-15), [0, 2]);
/**/  RR;
[6521908912666391107/4611686018427387904]

/**/  FloatStr(RR[1], 15);
1.41421356237310*10^0

See Also