WOLFRAM

HornerForm[poly]

puts the polynomial poly in Horner form.

HornerForm[poly,vars]

puts poly in Horner form with respect to the variable or variable list vars.

HornerForm[poly1/poly2]

puts the rational function poly1/poly2 in Horner form by nesting poly1 and poly2.

HornerForm[poly1/poly2,vars1,vars2]

puts poly1/poly2 in Horner form using the variables or variable lists vars1 and vars2 for poly1 and poly2, respectively.

Details

  • When variables are not specified, HornerForm puts the polynomial or rational function into Horner form with respect to the variables identified using Variables.

Examples

open allclose all

Basic Examples  (3)Summary of the most common use cases

Horner form of a polynomial in x:

Out[1]=1

Put a polynomial into Horner form with respect to a given variable:

Out[1]=1

Horner form of a rational function:

Out[1]=1

Scope  (2)Survey of the scope of standard use cases

Order a bivariate polynomial with respect to x then y:

Out[1]=1

With respect to y then x:

Out[2]=2

Construct a rational function in two variables:

Out[1]=1

Convert the function to Horner form:

Out[2]=2

Convert to Horner form using y before x in the numerator:

Out[3]=3

Generalizations & Extensions  (1)Generalized and extended use cases

An expression with rational exponents:

Out[1]=1

Applications  (1)Sample problems that can be solved with this function

Improve speed and stability for numeric evaluation of large polynomials:

Out[2]=2
Out[3]=3

Properties & Relations  (2)Properties of the function, and connections to other functions

Horner form of a rational function is the ratio of Horner forms:

Out[2]=2

Obtained as a ratio of Horner forms:

Out[3]=3

HornerForm recursively factors out powers of variables:

Out[1]=1
Out[2]=2

Collect groups based on powers of variables:

Out[3]=3

Factor gives the factored form:

Out[4]=4

Possible Issues  (1)Common pitfalls and unexpected behavior

Exponents must be integers or rationals:

Out[1]=1

Neat Examples  (1)Surprising or curious use cases

Out[1]=1
Out[2]=2
Wolfram Research (2007), HornerForm, Wolfram Language function, https://reference.wolfram.com/language/ref/HornerForm.html.
Wolfram Research (2007), HornerForm, Wolfram Language function, https://reference.wolfram.com/language/ref/HornerForm.html.

Text

Wolfram Research (2007), HornerForm, Wolfram Language function, https://reference.wolfram.com/language/ref/HornerForm.html.

Wolfram Research (2007), HornerForm, Wolfram Language function, https://reference.wolfram.com/language/ref/HornerForm.html.

CMS

Wolfram Language. 2007. "HornerForm." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/HornerForm.html.

Wolfram Language. 2007. "HornerForm." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/HornerForm.html.

APA

Wolfram Language. (2007). HornerForm. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/HornerForm.html

Wolfram Language. (2007). HornerForm. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/HornerForm.html

BibTeX

@misc{reference.wolfram_2025_hornerform, author="Wolfram Research", title="{HornerForm}", year="2007", howpublished="\url{https://reference.wolfram.com/language/ref/HornerForm.html}", note=[Accessed: 29-March-2025 ]}

@misc{reference.wolfram_2025_hornerform, author="Wolfram Research", title="{HornerForm}", year="2007", howpublished="\url{https://reference.wolfram.com/language/ref/HornerForm.html}", note=[Accessed: 29-March-2025 ]}

BibLaTeX

@online{reference.wolfram_2025_hornerform, organization={Wolfram Research}, title={HornerForm}, year={2007}, url={https://reference.wolfram.com/language/ref/HornerForm.html}, note=[Accessed: 29-March-2025 ]}

@online{reference.wolfram_2025_hornerform, organization={Wolfram Research}, title={HornerForm}, year={2007}, url={https://reference.wolfram.com/language/ref/HornerForm.html}, note=[Accessed: 29-March-2025 ]}