eft-horner
▸ function EFTHorner
(p
: number[], x
: number): object
Defined in evaluate/double/eft-horner.ts:28
Returns an EFT (error free transformation) for the Horner evaluation of a polymial at a specified x. The result is returned as an object with properties: r̂ -> the calculated evaluation, pπ and pσ -> two polynomials with coefficients around 2^53 times smaller than the input polynomial.
r̂ + pπ(x) + pσ(x) = the exact evaluation (no error)
see also Horner's Method
Parameters:
Name | Type | Description |
---|---|---|
p | number[] | a polynomial with coefficients given densely as an array of double floating point numbers from highest to lowest power, e.g. [5,-3,0] represents the polynomial 5x^2 - 3x |
x | number | the value at which to evaluate the polynomial |
Returns: object
Name | Type |
---|---|
r̂ | number |
pπ | number[] |
pσ | number[] |