encyclopegia.org

Polynomial evaluation

In mathematics and computer science, polynomial evaluation refers to computation of the value of a polynomial when its indeterminates are substituted for some values.[src] In other words, evaluating the polynomial P(x_1, x_2) = 2x_1x_2 + x_1^3 + 4 at x_1=2, x_2=3 consists of computing P(2,3)= 2\cdot 2\cdot 3 + 2^3+4=24.[src] See also For evaluating the univariate polynomial a_nx^n+a_{n-1}x^{n-1}+\cdots +a_0, the most naive method would use n multiplications to compute a_n x^n , use n-1 multiplications to compute a_{n-1} x^{n-1} and so on for a total of \tfrac{n(n+1)}{2} multiplications and n additions.[src] Using better methods, such as Horner's rule, this can be reduced to n multiplications and n additions.[src] If some preprocessing is allowed, even more savings are possible.[src]

In mathematics and computer science, polynomial evaluation refers to computation of the value of a polynomial when its indeterminates are substituted for some values.[src] In other words, evaluating the polynomial P(x_1, x_2) = 2x_1x_2 + x_1^3 + 4 at x_1=2, x_2=3 consists of computing P(2,3)= 2\cdot 2\cdot 3 + 2^3+4=24.[src] See also For evaluating the univariate polynomial a_nx^n+a_{n-1}x^{n-1}+\cdots +a_0, the most naive method would use n multiplications to compute a_n x^n , use n-1 multiplications to compute a_{n-1} x^{n-1} and so on for a total of \tfrac{n(n+1)}{2} multiplications and n additions.[src] Using better methods, such as Horner's rule, this can be reduced to n multiplications and n additions.[src] If some preprocessing is allowed, even more savings are possible.[src] \begin{align} a_0 + &a_1x + a_2x^2 + a_3x^3 + \cdots + a_nx^n \\ &= a_0 + x \bigg(a_1 + x \Big(a_2 + x \big(a_3 + \cdots + x(a_{n-1} + x\,a_n) \cdots \big) \Big) \bigg).[src] \end{align} This method reduces the number of multiplications and additions to just n Horner's method is so common that the "multiply–accumulate operation" is included within the instruction set of many computer processors, which allows for the addition and multiplication operations to be performed in one combined step.[src] P(x, y) = 4 + x + 2 x y + 2 x^2 y + x^2 y^2 can be written as \begin{align} P(x, y) &= 4 + x (1 + y(2) + x (y(2 + y))) \quad\text{or}\\ P(x, y) &= 4 + x + y(x(2 + x(2)) + y(x^2)).[src] \end{align} An efficient version of this approach was described by Carnicer and Gasca.[src] \begin{align} P(x) = (a_0 + a_1 x) + (a_2 + a_3 x) x^2 + ((a_4 + a_5 x) + (a_6 + a_7 x) x^2)x^4.[src] \end{align} Combined by exponentiation by squaring, this allows parallelizing the computation.[src] A similar idea enables to involve fast matrix multiplication algorithms to evaluate a polynomial in a series of points.[src] P(x)=x^4 + a_3 x^3 + a_2 x^2 + a_1 x + a_0 can be written as y = (x+\beta_0)x+\beta_1,\quad P(x)=(y+x+\beta_2)y+\beta_3, where the values \beta_0, \dots, \beta_3 are computed in advance, based on a_0, \dots, a_3 .[src] Motzkin's method uses just 3 multiplications compared to Horner's 4.[src] The values for each \beta_i can be easily computed by expanding P(x) and equating the coefficients: \begin{align} \beta_0&=\tfrac12(a_3-1),\quad &z&=a_2-\beta_0(\beta_0+1),\quad &\beta_1&=a_1-\beta_0 z,\\ \beta_2&=z-2\beta_1, \quad &\beta_3&=a_0-\beta_1(\beta_1+\beta_2).\end{align} y = (x+1.5)x+11.625,\quad P(x)=(y+x-15)y/24+2.63477.[src] Improving over the equivalent Horner form (that is P(x) = 1 + x (1 + x (1/2 + x(1/6 + x/24))) ) by 1 multiplication.[src] Some general methods include the Knuth–Eve algorithm and the Rabin–Winograd algorithm.[src] The idea is to define two polynomials that are zero in respectively the first and second half of the points: m_0(x)=(x-x_1)\cdots(x-x_{n/2}) and m_1(x)=(x-x_{n/2+1})\cdots(x-x_{n}) .[src] We then compute R_0 = P \bmod m_0 and R_1 = P \bmod m_1 using the Polynomial remainder theorem, which can be done in O(n\log n) time using a fast Fourier transform.[src] This means P(x) = Q_0(x)m_0(x) + R_0(x) and P(x) = Q_1(x)m_1(x) + R_1(x) by construction, where R_0 and R_1 are polynomials of degree at most n/2 .[src] Because of how m_0 and m_1 were defined, we have \begin{align} R_0(x_i) &= P(x_i) \quad\text{for } i \le n/2 \quad\text{and}\\ R_1(x_i) &= P(x_i) \quad\text{for } i > n/2.[src] \end{align} Thus to compute P on all n of the x_i , it suffices to compute the smaller polynomials R_0 and R_1 on each half of the points.[src] This gives us a divide-and-conquer algorithm with T(n) = 2T(n/2) + n\log n , which implies T(n)=O(n(\log n)^2) by the master theorem.[src] In the case where the points in which we wish to evaluate the polynomials have some structure, simpler methods exist.[src] For example, Knuth section 4.6.4 gives a method for tabulating polynomial values of the type P(x_0 + h), P(x_0 + 2h), \dots.[src] The idea is to transform P(x) of degree n into a multivariate polynomial f(x_1, x_2, \dots, x_m) , such that P(x) = f(x, x^d, x^{d^2}, \dots, x^{d^m}) and the individual degrees of f is at most d .[src] Since this is over \bmod q , the largest value f can take (over \mathbb Z ) is M = d^m (q-1)^{dm} .[src] Using the Chinese remainder theorem, it suffices to evaluate f modulo different primes p_1, \dots, p_\ell with a product at least M .[src] Each prime can be taken to be roughly \log M = O(dm\log q) , and the number of primes needed, \ell , is roughly the same.[src] Doing this process recursively, we can get the primes as small as \log\log q .[src] That means we can compute and store f on all the possible values in T = (\log\log q)^m time and space.[src] If we take d = \log q , we get m = \tfrac{\log n}{\log\log q} , so the time/space requirement is n^\frac{\log\log q}{\log\log\log q}.[src] Kedlaya and Umans further show how to combine this preprocessing with fast multipoint evaluation using the fast Fourier transform.[src] This allows optimal algorithms for many important algebraic problems, such as polynomial modular composition.[src] For example, the polynomial P(x)=x^2+2x+1 can be computed using just one multiplication and one addition since P(x)=(x+1)^2 .[src] P(x)=\sum_{k=0}^n 2^{2^{kn^3}}x^k cannot be evaluated with less than \tfrac12 n - 2 multiplications and n - 4 additions.[src] At least this bound holds if only operations of those types are allowed, giving rise to a so-called "polynomial chain of length ".[src] The polynomial given by Strassen has very large coefficients, but by probabilistic methods, one can show there must exist even polynomials with coefficients just 0's and 1's such that the evaluation requires at least \Omega(n/\log n) multiplications.[src] For other simple polynomials, the complexity is unknown.[src] The polynomial (x+1)(x+2)\cdots(x+n) is conjectured to not be computable in time (\log n)^{c} for any c .[src] This is supported by the fact that, if it can be computed fast, then integer factorization can be computed in polynomial time, breaking the RSA cryptosystem.[src] showed how to compute a degree n polynomial using only O(\sqrt n) non scalar multiplications and O(n) scalar multiplications.[src] Thus a matrix polynomial of degree can be evaluated in O(m^\alpha\sqrt{n} + m^2n) time, where is the time needed for multiplying two matices.[src] If m=n this is O(n^\beta), where or deprending whether usual or fast matrix multiplication is used.[src] This is to be compared to the usual Horner method, which gives or respectively.[src] This method works as follows: For a polynomial P(M)=a_{n-1} M^{n-1} + \dots + a_{1}M + a_0 I, let be the least integer not smaller than \sqrt{n}.[src] The powers M, M^2, \dots, M^k are computed with k matrix multiplications, and M^{2k}, M^{3k}, \dots, M^{k^2-k} are then computed by repeated multiplication by M^k.[src] Now, \begin{align}P(M) = &\,(a_0 I + a_1 M + \dots + a_{k-1}M^{k-1}) \\+&\,(a_k I + a_{k+1} M + \dots + a_{2k-1}M^{k-1})M^k \\+&\,\dots \\+&\,(a_{n-k} I + a_{n-k+1} M + \dots + a_{n-1}M^{k-1})M^{k^2-k}, \end{align} , where a_i=0 for .[src] This requires just k more non-scalar multiplications.[src] The direct application of this method uses 2\sqrt{n} non-scalar multiplications, but combining it with Evaluation with preprocessing, Paterson and Stockmeyer show you can reduce this to \sqrt{2n} .[src] Methods based on matrix polynomial multiplications and additions have been proposed allowing to save nonscalar matrix multiplications with respect to the Paterson-Stockmeyer method.[src]

56 sentences · 56 cited inline · 0 references stored

References

No reference rows published for this article.

Cite this article

MLA

"Polynomial evaluation." encyclopegia.org, 2026, https://encyclopegia.org/wiki/polynomial-evaluation. Accessed 30 November 2026.

Chicago

"Polynomial evaluation." encyclopegia.org. Accessed November 30, 2026. https://encyclopegia.org/wiki/polynomial-evaluation.

APA

encyclopegia.org. (2026). Polynomial evaluation. Retrieved November 30, 2026, from https://encyclopegia.org/wiki/polynomial-evaluation

Accessed November 30, 2026 · CC BY-SA 4.0 · citation page · JSON

CC BY-SA 4.0 · share-alike · https://en.wikipedia.org/w/index.php?oldid=1365855222 · 0.5 · snapshot enwiki-001365855222

Cite · JSON · Search

Related services and records

Services

  • Estate — measured countries, lanes and facts
  • Intel — live corroborated events
  • Legal — statutes, cases and citations
  • Encyclopedia — articles with inline sources
  • Space — launches, satellites and orbits
  • Search — federated search and reports
  • Pass — passport account and SSO
  • Corpora — read-only corpus origins
  • e01 — self-hosted corpora and tools
  • Careers — open roles: frontier engineers and sales partners
  • Index — every corpus, paper and record
  • Estate guide — what a public data estate is
  • Founder — Lois-Kleinner Alpasan
  • Records — DOIs and external deposits
  • Documents — one-pagers, PDFs and QR codes
  • Brand kit — logos and share images
  • Papers — plain-language briefs with citations
  • Browser — search engine, PWA and bookmarklet
  • Anticloud — the operator and its projects

As seen in Business Insider · 336 outlets · evidence DOIs · plain-language papers

Text and metadata only; each target carries its own sources. Missing data is published as no-data, never estimated.