math.wiki
Functions › Polynomial functions › Building a polynomial from its zeros
Open on the map
Algebra 2

Building a polynomial from its zeros

You know where a polynomial is zero. How do you get the polynomial back, and when is there only one?

Where you are 6 in Polynomial functions

When you reach for it

Graphing a polynomial starts from the rule and draws the curve. This move runs the other way. You know where a polynomial is zero, how many times, and perhaps one other point on its graph, and you want the rule. That happens when you read a formula off a drawn graph, when you design a curve that must meet the axis at chosen places, and whenever a problem says “a cubic with zeros 2, 5 and 7” and the cubic has to be written down.

For a quadratic this is factored form read backwards. Here it works at any degree, with repeated zeros, fractional zeros and non-real zeros.

The procedure

Each zero gives a factor

By the factor theorem, c is a zero of p exactly when (x - c) is a factor of p. A zero of multiplicity m means (x - c)^m is a factor (zeros and multiplicity). Suppose p has degree n and zeros c_1, \dots, c_k with multiplicities m_1, \dots, m_k that add up to n. Then p contains the product

(x - c_1)^{m_1}(x - c_2)^{m_2}\cdots(x - c_k)^{m_k}

and that product already has degree n. Dividing p by it leaves a quotient of degree 0, a constant. So, for some number a \neq 0,

p(x) = a(x - c_1)^{m_1}\cdots(x - c_k)^{m_k}

Each factor carries the opposite sign of its zero: the zero -2 gives (x - (-2)) = (x + 2). The fundamental theorem of algebra says a polynomial of degree n has exactly n zeros counted with multiplicity, complex ones included, so a list whose multiplicities add to n is the whole list.

The leading coefficient is free

Every non-zero a gives a polynomial with the same zeros. Multiplying by a stretches the graph vertically, and flips it when a < 0, but a height of 0 stays 0, so the x-intercepts never move. The zeros alone describe a family of polynomials, one for each a.

−2 −1 x y
a = 1
a = -1
a = -3
(1, 12)
Figure 1The family a\,x(x + 3)(x - 2) from Example 1. Every member has the same zeros; only a = -3 passes through (1, 12).

One more point fixes a

Suppose the graph also passes through (x_0, y_0), where x_0 is not a zero. Substituting,

y_0 = a(x_0 - c_1)^{m_1}\cdots(x_0 - c_k)^{m_k}

The product on the right is a number, and it is not 0, because no factor is 0. Dividing by it leaves exactly one value of a. The y-intercept (0, p(0)) is usually the easiest point, since every factor becomes a plain number.

Why the answer is unique. Any polynomial with the given degree and the given zeros and multiplicities has the form a times the product, and the point allows one value of a. So two polynomials that share the degree, the zeros with their multiplicities, and one point that is not a zero, are the same polynomial. Each piece is needed. Without the point, every a works. Without the degree, a factor such as (x^2 + 1) could be multiplied in and a chosen again, giving a second polynomial with the same real zeros through the same point.

Integer coefficients

A fractional zero such as \displaystyle \frac{5}{2} gives the factor \displaystyle \left(x - \frac{5}{2}\right), whose constant is a fraction. Since a is free, choose it to clear the fraction: \displaystyle 2\left(x - \frac{5}{2}\right) = 2x - 5. The zero is unchanged, because 2x - 5 = 0 exactly when \displaystyle x = \frac{5}{2}. In general a zero \displaystyle \frac{r}{s} gives the integer factor (sx - r).

Real coefficients and non-real zeros

If p has real coefficients and z is a non-real zero, then its conjugate \bar{z} is a zero too (conjugate pairs). So when real coefficients are wanted and a zero h + ki is given, h - ki comes with it, unstated. Their two factors multiply to a real quadratic, by the difference of squares and i^2 = -1:

\begin{aligned} &(x - (h + ki))(x - (h - ki)) \\ &\quad = (x - h)^2 - (ki)^2 = (x - h)^2 + k^2 \end{aligned}

Reading zeros off a graph

A graph shows the real zeros as its x-intercepts, and the parity of each multiplicity in what the graph does there: a crossing at a slant suggests multiplicity 1, a touch that turns back 2, a flat crossing 3. Take the smallest multiplicities that fit. They give the polynomial of lowest degree the graph allows, which is the usual question, since a picture cannot tell 2 from 4. Fix a with one more point the graph shows, then check its sign against the end behavior. If the ends of the graph disagree with the sign of a and the degree, a zero or a multiplicity was misread.

Worked examples

Example 1

A family, then one member

Find every polynomial of degree 3 with zeros -3, 0 and 2. Then find the one whose graph passes through (1, 12).

Solution

The zero -3 gives (x + 3), the zero 0 gives (x - 0) = x, and the zero 2 gives (x - 2). Three linear factors already make degree 3, so the only freedom left is a constant a \neq 0:

p(x) = a\,x(x + 3)(x - 2)

Since 0 is a zero, every member passes through (0, 0), so the y-intercept cannot pick one out. Use (1, 12) instead:

12 = a(1)(1 + 3)(1 - 2) = -4a

so a = -3. Expanding, x(x + 3)(x - 2) = x(x^2 + x - 6) = x^3 + x^2 - 6x, and

p(x) = -3x^3 - 3x^2 + 18x

Check. p(1) = -3 - 3 + 18 = 12.

Example 2

A repeated zero and the y-intercept

Find the polynomial of degree 4 with zeros -2, 1 (multiplicity 2) and 4, whose graph passes through (0, 16).

Solution

The double zero gives (x - 1)^2. The multiplicities add to 1 + 2 + 1 = 4, the degree, so

p(x) = a(x + 2)(x - 1)^2(x - 4)

At x = 0 every factor is a number:

16 = a(2)(-1)^2(-4) = -8a

so a = -2 and p(x) = -2(x + 2)(x - 1)^2(x - 4). To expand, pair the factors so they share a piece: (x + 2)(x - 4) = x^2 - 2x - 8 and (x - 1)^2 = x^2 - 2x + 1. With u = x^2 - 2x their product is (u - 8)(u + 1) = u^2 - 7u - 8, so

\begin{aligned} p(x) &= -2(u^2 - 7u - 8) \\ &= -2(x^4 - 4x^3 - 3x^2 + 14x - 8) \\ &= -2x^4 + 8x^3 + 6x^2 - 28x + 16 \end{aligned}

The constant term is 16, as the y-intercept requires. The factored form is usually the more useful answer, because it shows the zeros at a glance.

Example 3

A fractional zero and integer coefficients

Find a polynomial of degree 3 with integer coefficients whose zeros are 3, -1 and \displaystyle \frac{5}{2}.

Solution

The family is \displaystyle a(x - 3)(x + 1)\left(x - \frac{5}{2}\right). With a = 1 the constant term would be \displaystyle (-3)(1)\left(-\frac{5}{2}\right) = \frac{15}{2}, not an integer. Take a = 2 and give the 2 to the fractional factor, \displaystyle 2\left(x - \frac{5}{2}\right) = 2x - 5, which is still zero exactly at \displaystyle x = \frac{5}{2}:

\begin{aligned} p(x) &= (x - 3)(x + 1)(2x - 5) \\ &= (x^2 - 2x - 3)(2x - 5) \\ &= 2x^3 - 9x^2 + 4x + 15 \end{aligned}

Check at \displaystyle \frac{5}{2}: \displaystyle 2 \cdot \frac{125}{8} - 9 \cdot \frac{25}{4} + 10 + 15 is \displaystyle \frac{125}{4} - \frac{225}{4} + 25 = 0.

The question says “a polynomial” because there are more. Every answer of degree 3 is k times this one, and its coefficients are integers exactly when 2k and 9k are, which forces k = 9k - 4(2k) to be an integer.

Example 4

A non-real zero and real coefficients

Find the polynomial of degree 3 with real coefficients, zeros 2 and 4 + i, and y-intercept 68.

Solution

Real coefficients force the conjugate 4 - i to be a zero as well, which makes three zeros for degree 3. Leaving it out would not even give real coefficients: (x - 2)(x - (4 + i)) expands to x^2 - (6 + i)x + 8 + 2i.

Pair the conjugate factors first:

\begin{aligned} (x - 4 - i)(x - 4 + i) &= (x - 4)^2 - i^2 \\ &= x^2 - 8x + 17 \end{aligned}

So p(x) = a(x - 2)(x^2 - 8x + 17), and at x = 0, 68 = a(-2)(17) = -34a, so a = -2:

\begin{aligned} p(x) &= -2(x - 2)(x^2 - 8x + 17) \\ &= -2(x^3 - 10x^2 + 33x - 34) \\ &= -2x^3 + 20x^2 - 66x + 68 \end{aligned}

The graph crosses the x-axis only once, at x = 2. The pair 4 \pm i leaves no intercept.

Example 5

Reading a polynomial off its graph

The graph below touches the x-axis at -3, crosses it at 2, and passes through (0, -18). Find the polynomial of lowest degree it could be.

−4 −3 −2 −1 1 2 −20 −10 10 20 x y (0, −18)
Figure 2The graph in Example 5. It touches the axis at -3, crosses at 2, and passes through (0, -18).
Solution

At -3 the graph touches and turns back, so that zero has even multiplicity; the smallest is 2, giving (x + 3)^2. At 2 it crosses at a slant, not flat, so multiplicity 1, giving (x - 2). The lowest degree is 2 + 1 = 3:

p(x) = a(x + 3)^2(x - 2)

The y-intercept gives -18 = a(3)^2(-2) = -18a, so a = 1 and

\begin{aligned} p(x) &= (x + 3)^2(x - 2) \\ &= x^3 + 4x^2 - 3x - 18 \end{aligned}

Check against the ends. Odd degree with a > 0 falls on the left and rises on the right, which is what the graph does. A rule such as a(x + 3)^4(x - 2) also touches at -3 and crosses at 2; only the words “lowest degree” rule it out.

Example 6

A cubic that takes one value three times

Find the polynomial p of degree 3 with p(-1) = p(1) = p(4) = 6 and p(0) = 2.

Solution

p is not zero at those places, but q(x) = p(x) - 6 is: q(-1) = q(1) = q(4) = 0. Subtracting a constant does not change the degree, so q is a cubic with three known zeros,

q(x) = a(x + 1)(x - 1)(x - 4)

and q(0) = p(0) - 6 = -4. So -4 = a(1)(-1)(-4) = 4a, and a = -1. Then

\begin{aligned} p(x) &= -(x + 1)(x - 1)(x - 4) + 6 \\ &= -(x^3 - 4x^2 - x + 4) + 6 \\ &= -x^3 + 4x^2 + x + 2 \end{aligned}

Check. p(4) = -64 + 64 + 4 + 2 = 6 and p(0) = 2. On the graph, the line y = 6 meets the curve at x = -1, 1 and 4, and those are the zeros of the curve moved down by 6.

Boundaries

The extra point must not be a zero. At a zero the equation reads 0 = a \cdot 0, true for every a. When 0 is itself a zero, the y-intercept is such a point, as in Example 1.

The multiplicities must add to the degree. If they add to less, what remains of p is not a constant, and one number a cannot describe it. For a real polynomial the gap may be a pair of non-real zeros, which a graph never shows. If they add to more, no polynomial of that degree has those zeros.

Conjugates come from asking for real coefficients. With complex coefficients allowed, (x - 2)(x - (4 + i)) is a perfectly good polynomial of degree 2. Asking for real coefficients adds the conjugate, and each conjugate costs one degree.

Clearing denominators works for rational zeros. A zero \displaystyle \frac{r}{s} becomes (sx - r). An irrational zero such as \displaystyle \sqrt{2} has no linear factor with integer coefficients; it needs the partner \displaystyle -\sqrt{2} as well, and \displaystyle (x - \sqrt{2})(x + \sqrt{2}) = x^2 - 2.

A graph does not show the exact multiplicity. A touch could be 2 or 4, a flat crossing 3 or 5. “Lowest degree” picks the smallest multiplicity that fits each intercept. That is a choice the question makes, not a fact the picture proves.

a is never 0. a = 0 gives the zero polynomial, which is zero everywhere and has no degree.

Where this goes next

This is the step that turns a picture or a list of zeros into a formula. Modeling with polynomials uses it when the zeros of a quantity are known from the situation, such as the cut size at which a folded box has no volume. The fundamental theorem of algebra guarantees that a polynomial of degree n always has n zeros to build from, so the factored form never misses a piece. Example 6 is a first taste of a larger idea: a polynomial of degree n is fixed by its values at n + 1 points, which is how a curve is threaded through measured data.

Exercises

Zeros and one point

  1. Write every polynomial of degree 3 with zeros -4, 1 and 3. Then expand the one with leading coefficient 1.
  2. Find the polynomial of degree 3 with zeros -2, 3 and 5 whose graph passes through (4, 12).
  3. Find the polynomial of degree 4 with zeros 3 (multiplicity 2), -1 and -4, and y-intercept -18.
  4. Find the polynomial of degree 4 with zeros -1 (multiplicity 3) and 2, and p(1) = 24.
  5. Find the polynomial of degree 3 with zeros 0, 4 and -4 whose graph passes through (2, 6). Expand it.

Integer coefficients

  1. Find a polynomial of degree 3 with integer coefficients and zeros \displaystyle \frac{3}{2}, -2 and 1.
  2. Find a polynomial of degree 3 with integer coefficients and zeros \displaystyle \frac{2}{3}, \displaystyle -\frac{1}{4} and 1.

Non-real zeros

  1. Find the polynomial of degree 3 with real coefficients, leading coefficient 1, and zeros -1 and 3 - 2i.
  2. Find the polynomial of degree 4 with real coefficients, zeros 2i and -3 (multiplicity 2), and p(0) = 72.
  3. Find the polynomial of degree 4 with real coefficients and leading coefficient 1 whose zeros include 1 + i and 2 - i.
  4. What is the lowest degree of a polynomial with real coefficients whose zeros include 1, i and 2i? Write one.

From a graph

−1 1 2 3 4 x y (0, 8) A −2 −1 1 2 x y (−1, 4) B
Figure 3Graphs A and B for exercises 12 and 13. Each is a polynomial of lowest degree.
  1. Find the polynomial of lowest degree for graph A, which passes through (0, 8).
  2. Find the polynomial of lowest degree for graph B, which passes through (-1, 4).
  3. The graph of a cubic touches the x-axis at 4, crosses it at -1, and passes through (0, 32). Find the cubic, and say which way its ends point.

Using the idea

  1. Find the polynomial p of degree 3 with p(-1) = p(2) = p(5) = 4 and p(0) = 14.
  2. A polynomial p of degree 3 has zeros -2, 1 and 3, and p(2) = 8. Find p(4).
  3. The polynomial p(x) = (x - 1)(x - 2)(x - k) has p(0) = 6. Find k.

Reasoning

  1. Tullia and Uchenna each write a polynomial of degree 3 with zeros -1, 2 and 6, and their polynomials are different. Explain how both can be right, and what one extra fact would make them agree.
  2. Rozenn knows p has degree 3 and zeros -1, 2 and 6, and tries to find a from the point (2, 0). Explain why this fails.
  3. Prove that if p and q both have degree n, the same zeros with multiplicities adding to n, and p(x_0) = q(x_0) \neq 0 for one number x_0, then p = q.
  4. Explain why no quadratic with real coefficients has zeros 3 and 1 - 2i, and give the lowest degree a polynomial with real coefficients and both zeros can have.
Answers
  1. a(x + 4)(x - 1)(x - 3) with a \neq 0; for a = 1, (x + 4)(x^2 - 4x + 3), which is x^3 - 13x + 12.
  2. p(x) = -2(x + 2)(x - 3)(x - 5). 12 = a(6)(1)(-1) = -6a, so a = -2.
  3. \displaystyle p(x) = -\frac{1}{2}(x - 3)^2(x + 1)(x + 4). -18 = a(9)(1)(4) = 36a.
  4. p(x) = -3(x + 1)^3(x - 2). 24 = a(2)^3(-1) = -8a.
  5. \displaystyle p(x) = -\frac{1}{4}x(x - 4)(x + 4), which expands to \displaystyle -\frac{1}{4}x^3 + 4x. Since 0 is a zero, the y-intercept cannot fix a, so use (2, 6): 6 = a(2)(-2)(6) = -24a.
  6. (2x - 3)(x + 2)(x - 1), which expands to 2x^3 - x^2 - 7x + 6, or any non-zero integer multiple. The fraction clears as \displaystyle 2\left(x - \frac{3}{2}\right) = 2x - 3.
  7. (3x - 2)(4x + 1)(x - 1), which expands to 12x^3 - 17x^2 + 3x + 2, or any non-zero integer multiple. Each fraction clears in its own factor.
  8. (x + 1)(x^2 - 6x + 13), which expands to x^3 - 5x^2 + 7x + 13. The conjugate 3 + 2i is also a zero, and the two conjugate factors multiply to (x - 3)^2 + 4.
  9. p(x) = 2(x^2 + 4)(x + 3)^2. The conjugate -2i joins 2i, and (x - 2i)(x + 2i) = x^2 + 4. Then 72 = a(4)(9) = 36a.
  10. (x^2 - 2x + 2)(x^2 - 4x + 5), which expands to x^4 - 6x^3 + 15x^2 - 18x + 10. The conjugates 1 - i and 2 + i are forced, which makes four zeros for degree 4.
  11. Degree 5, for example (x - 1)(x^2 + 1)(x^2 + 4). The conjugates -i and -2i are forced, so there are at least five zeros.
  12. \displaystyle p(x) = -\frac{1}{2}(x + 1)(x - 2)^2(x - 4). Slanted crossings at -1 and 4, a touch at 2; then 8 = a(1)(4)(-4) = -16a. Even degree with a < 0 matches both ends pointing down.
  13. \displaystyle p(x) = -\frac{1}{2}(x + 2)(x - 1)^3. A slanted crossing at -2, a flat crossing at 1; then 4 = a(1)(-2)^3 = -8a. Even degree with a < 0 matches both ends pointing down.
  14. p(x) = 2(x - 4)^2(x + 1); it falls on the left and rises on the right. 32 = a(16)(1), so a = 2 > 0, with odd degree.
  15. p(x) = (x + 1)(x - 2)(x - 5) + 4, which expands to x^3 - 6x^2 + 3x + 14. p(x) - 4 has zeros -1, 2 and 5, and p(0) - 4 = 10 = a(1)(-2)(-5) = 10a, so a = 1.
  16. p(4) = -36. 8 = a(4)(1)(-1) gives a = -2, and p(4) = -2(6)(3)(1).
  17. k = -3. p(0) = (-1)(-2)(-k) = -2k = 6.
  18. The zeros fix the polynomial only up to the constant factor: both are a(x + 1)(x - 2)(x - 6), with different values of a. Agreeing on one point (x_0, y_0) with x_0 not a zero, or on the leading coefficient, fixes a and makes them the same.
  19. 2 is a zero, so substituting gives 0 = a(3)(0)(-4), which is 0 = 0 for every a. Every member of the family passes through (2, 0). She needs a point whose x is not -1, 2 or 6.
  20. By the factor theorem and the meaning of multiplicity, both contain the product f(x) = (x - c_1)^{m_1}\cdots(x - c_k)^{m_k}, which has degree n, so each quotient has degree 0: p = af and q = bf for constants a and b. Since p(x_0) \neq 0, f(x_0) \neq 0, and af(x_0) = bf(x_0) gives a = b. So p = q.
  21. A polynomial with real coefficients and the zero 1 - 2i also has the zero 1 + 2i. With 3 that is three zeros, and a quadratic has at most two. The lowest degree is 3, for example (x - 3)(x^2 - 2x + 5).
kg1128 · updated 2026-10-14 · CC-BY-SA-4.0