4.1  Polynomials as Coefficient Sequences

At school a polynomial is an expression such as 3x2−x+2, and x is a number that has not been chosen yet. This chapter replaces that picture by a definition that works over every commutative ring of Number Systems: From N to R, Chapter 2 (Number Systems: From N to R, Definition 2.3.1): over Q, over the fields Fp of Chapter 2, and over rings such as Z/6Z, where a product of two non-zero elements can be zero. This section makes the one decision the whole chapter rests on: a polynomial is its list of coefficients. It then collects the finite sums, powers and multiples that the next sections compute with.

Throughout, R is a commutative ring, with a−b:=a+(−b).

4.1.1. What goes wrong with “an expression in x”

Take the field F2={0,1} of Definition 2.2.1, in which 1+1=0. Read x2+x the school way, as a rule: replace x by an element c and compute cc+c. The tables of Example (Arithmetic on Z/nZ and the Field F2) give 0⋅0+0=0,1⋅1+1=1+1=0. So the rule c↦cc+c and the rule c↦0 give the same output at both elements of F2. As functions F2→F2 they are equal, by Sets, Relations, and Cardinality, Proposition 1.4.1: same domain, same codomain, same values.

If a polynomial were the function it defines, then x2+x would be the zero polynomial over F2. So would x3+x and x4+x2, which also give 0 at 0 and 1+1=0 at 1. None of them would have a highest power of x, and the rule “the degree of a product is the sum of the degrees”, which we want over every field, would fail for x⋅(x+1)=x2+x: degrees 1 and 1, product “zero”. Over Q the problem never shows (Section 5.4 proves that over an infinite field a non-zero polynomial never gives the zero function), which is why school algebra can afford the picture. Over a finite ring with 1≠0 it cannot.

So we decide the other way. Two polynomials are the same when their coefficients are the same, and the letter x is not a number at all.

A polynomial is its list of coefficients; the letter x only marks the positions.

4.1.2. Polynomials over a commutative ring

A list of coefficients that goes on forever is a sequence, that is, a function on N. We keep only the sequences that stop being non-zero.

Definition 4.1.1 (Polynomial)

Let R be a commutative ring. A polynomial over R (in the indeterminate x) is a function p:N→R, written p=(p0,p1,p2,…), such that only finitely many pk are non-zero: there exists N∈N with pk=0 for every k>N. Such an N is called admissible for p. The element pk is the coefficient of xk in p.

For a∈R and n∈N, the monomial axn is the polynomial with a in position n and 0 in every other position. We set x:=1x1, and for a∈R the constant a is the monomial ax0. The zero polynomial is 0:=(0,0,0,…). The set of all polynomials over R is written R[x].

In words: the first clause says that a polynomial is an infinite list of elements of R, indexed from 0; the second says that from some position on, every entry is 0. The quantifiers are in the order “there is one N that works for every later k”: a sequence with infinitely many non-zero entries, however sparse, is excluded. A monomial has at most one non-zero entry, so n is admissible for it, and it is a polynomial. The symbol x is the particular sequence (0,1,0,0,…): an element of R[x], never an element of R, and never a variable that takes values.

Equality. Two polynomials p,q∈R[x] are functions with the same domain N and the same codomain R. By Sets, Relations, and Cardinality, Proposition 1.4.1, p=q⟺pk=qk  for every k∈N. To prove an identity between polynomials we therefore compute the k-th coefficient of both sides, for an arbitrary k. We call this move compare coefficients. It is Number Systems: From N to R, Chapter 2’s “reduce to the level below” once more: a statement about polynomials becomes a statement about elements of R, one position at a time.

The display. If N is admissible for p, we write p=∑k=0Npkxk=p0+p1x+p2x2+⋯+pNxN. For now this is notation only. No addition of polynomials has been defined yet, so the plus signs are not an operation: the display names the sequence by listing its entries, each with a marker xk for its position. We drop terms whose coefficient is 0, write ax for ax1, a for ax0, xk for 1xk, and −axk for (−a)xk. So 3x2−x+2 over Q names the sequence with p0=2, p1=−1, p2=3 and pk=0 for k≥3. Section 4.2 defines the sum of two polynomials and proves that the display is then an honest sum of monomials.

There is one thing to check about the display. The admissible N is not unique: if N is admissible, so is every M≥N, since k>M implies k>N. Passing from N to M only adds the terms 0xk for N<k≤M, which the convention drops. So every admissible N names the same sequence, and the display is well defined.

Why “only finitely many”. Two later uses need it. In Section 4.4 we put an element c∈R in place of x and form ∑kpkck; in a ring only finite sums are defined, and finiteness is what makes the sum finite. In Section 4.3 every non-zero polynomial gets a degree, the highest position holding a non-zero coefficient; without finiteness there may be no highest position.

The degenerate cases. The zero polynomial has every N admissible, including N=0, and it is the monomial 0xn for every n. It is the one polynomial with no non-zero coefficient at all, and Section 4.3 will need a convention for its degree. At the other extreme, let R be the zero ring {0} of the examples after Number Systems: From N to R, Definition 2.3.1, where 1=0. There is exactly one function N→{0}, so R[x] has exactly one element, the zero polynomial, and x=1x1=0x1=0. This is why some results below assume 1≠0 in R.

Example (Reading off coefficient sequences)

Write the coefficient sequence of each polynomial, and check it against Definition 4.1.1. In a ring Z/nZ, a natural number m written as an element stands for m⋅[1]=[m] (Number Systems: From N to R, Theorem 3.4.3 (d)), just as Definition 2.2.1 does for Fp.

  • (a) 3x2−x+2∈Q[x].
  • (b) x2+x∈F2[x].
  • (c) [3]x+[4]∈(Z/6Z)[x].
  • (d) The constant 7, over Z, over Z/5Z and over F2.
  • (e) 0∈R[x], for any R.

Solution.

  • (a) (2,−1,3,0,0,…). The entries lie in Q, and N=2 is admissible, so it is a polynomial over Q.

  • (b) (0,1,1,0,0,…), with entries in F2 and N=2 admissible. It is not the zero sequence, since its entry in position 1 is 1≠0. So x2+x≠0 in F2[x], although the rule c↦cc+c is the zero function on F2, as computed above.

  • (c) ([4],[3],[0],[0],…): the constant term comes first. The entries lie in Z/6Z (Number Systems: From N to R, Definition 3.4.2) and N=1 is admissible.

  • (d) Over Z: (7,0,0,…). Over Z/5Z: ([7],[0],[0],…), and [7]=[2] because 7−2=5 is a multiple of 5; so this is the constant [2]. Over F2: (1,0,0,…), because 7=1 in F2 (7−1=6=3⋅2). The same symbol 7 names three different polynomials, one in each ring, and in each ring N=0 is admissible.

  • (e) (0,0,0,…), with every N admissible: the degenerate case.

Now a non-example, by a minimal change. Start from 1+x+x2∈Q[x], the sequence (1,1,1,0,0,…), and change every later 0 to 1. The result (1,1,1,1,…), informally “1+x+x2+⋯”, is still a function N→Q. The one clause that fails is only finitely many: for every N, the entry in position N+1 is 1≠0, so no N is admissible. It is a formal power series, met again in the exercises of Section 4.2, but not a polynomial. An expression such as x−1+1 fails for a more basic reason: it would need an entry in position −1, and a polynomial is a function on N.

R and C are commutative rings too (for R, Number Systems: From N to R, Chapter 5; for C, Chapter 1), so R[x] and C[x] are defined, and they are the main examples of the linear-algebra companion. No proof in this chapter needs them; our examples come from Z, Q, Z/nZ and Fp, the rings this series has built.

Where R matters. Nothing in Definition 4.1.1 mentions inverses, an order, or size. It makes sense word for word over Z/6Z, where [2][3]=[0] (Number Systems: From N to R, Example (Multiplication modulo six and modulo five)), and over the zero ring. The price is that school rules about polynomials cannot be assumed: each one that survives is proved, here or (division with remainder, counting roots) in Chapter 5, and each result says what it needs from R (nothing at all, no zero divisors, a unit leading coefficient, finiteness with 1≠0, or, for the derivative, the characteristic of a field).

Warning. p2 is a coefficient; p(2) will be a value. Section 4.4 writes p(c) for the result of putting c∈R in place of x. For p=x2+1∈Z[x], the coefficient p2 is 1, while the value at 2 will be 2⋅2+1=5. Both are integers, so a reader who writes p(k) for “the k-th coefficient” gets 1=5. This book never writes p(k) for a coefficient: the coefficient of xk is pk, always with a subscript.

Quick check. Is 6x2 equal to the zero polynomial in (Z/6Z)[x]? In Z[x]?

Solution. In (Z/6Z)[x], yes: 6x2 is the monomial [6]x2, and [6]=[0], so every entry is [0] and the two sequences agree in every position. In Z[x], no: the entry in position 2 is 6≠0, while the zero polynomial has 0 there. Same display, two rings, two answers.

4.1.3. Sums, powers and multiples

The next section defines the product of two polynomials by a formula whose k-th coefficient is a finite sum ∑i=0kpiqk−i of products in R. Later sections raise elements of R, and polynomials, to powers, and use multiples k⋅a. This subsection collects what we use about all three. Most of it is already proved: finite sums and multiples in a commutative ring are Chapter 2’s (Lemma 2.6.1, Lemma 2.5.1), and the recursions follow the patterns that Sets, Relations, and Cardinality, Section 2.3 set up for real numbers (Sets, Relations, and Cardinality, Definition 2.3.1, Sets, Relations, and Cardinality, Definition 2.3.2). The patterns are reused; no fact about R is.

One point deserves care before we start. The sums of polynomials in Section 4.2 must be formed before we know that R[x] is a commutative ring, because they are used to prove it. So part (a) below asks for an addition and a left-neutral element 0, and nothing more.

Lemma 4.1.1 (Finite Sums, Powers and Multiples)

Let R be a commutative ring.

  • (a) (Sums.) Let T be a set with a function +:T×T→T and an element 0∈T with 0+u=u for every u∈T. For a sequence (ui)i∈N in T there is exactly one way to define ∑i=0kui∈T, for k∈N, such that ∑i=00ui=u0,∑i=0k+1ui=∑i=0kui+uk+1, starting from the empty sum 0. The sum ∑i=0kui depends only on u0,…,uk; so a finite list u0,…,uk has a sum, computed from any extension of the list to a sequence. Likewise, a finite list s1,…,sr in R has a product ∏j=1rsj, with ∏j=10sj=1 and ∏j=1r+1sj=(∏j=1rsj)sr+1.

  • (b) (Rules for sums in R.) For k∈N, c∈R and elements ui,vi∈R:

    (Σ1) ∑i=0k(ui+vi)=∑i=0kui+∑i=0kvi;

    (Σ2) c∑i=0kui=∑i=0kcui;

    (Σ3) for j∈N: if ui=0 for every i≤k with i≠j, then ∑i=0kui=uj when j≤k, and ∑i=0kui=0 when j>k;

    (Σ4) −∑i=0kui=∑i=0k(−ui).

  • (c) (Powers.) For s∈R and n∈N, s0:=1 and sn+1:=sns define sn for every n, and for all s,t∈R and m,n∈N, sm+n=smsn,(sm)n=smn,(st)n=sntn.

  • (d) (Multiples.) For all a,b∈R and m,n∈Z, (m+n)⋅a=m⋅a+n⋅a,m⋅(a+b)=m⋅a+m⋅b,(m⋅a)b=m⋅(ab),(m⋅1)a=m⋅a,(mn)⋅a=m⋅(n⋅a).

In words: (a) says that a finite list in a set with an addition has a sum, built one term at a time, and that terms beyond the list do not matter; it needs no law of addition beyond 0+u=u. (b) says that a finite sum of ring elements can be split into two sums, multiplied through by a constant, collapsed to its one non-zero term, or negated term by term. (c) is the three laws of exponents in a commutative ring. (d) is the arithmetic of the multiples m⋅a of Number Systems: From N to R, Section 2.3 (“Multiples”), extended to m∈Z in Chapter 2: a dot with an integer on its left is always a multiple, and the product of two ring elements is written by juxtaposition.

Parts (b) and (d) are cited from Chapter 2: (Σ1)–(Σ4) are Lemma 2.6.1 (a), (b), (d), (e) (for (Σ3), apply Lemma 2.6.1 (d) to the sequence that agrees with u0,…,uk and is 0 beyond k; by the finite-lists clause of part (a) above it has the same sum), and the five rules of part (d) above are Lemma 2.5.1 (c), (d). Parts (a) and (c) are the recursions of Sets, Relations, and Cardinality, Section 2.3, read in T and in R; each is built by Sets, Relations, and Cardinality, Theorem 2.3.1, and each of its laws is one short induction. Chapter 1 proves the same three power laws for every commutative ring (Proposition 1.1.3); we only compare with it, and prove (c) again from the template, so that this chapter’s main line rests on Chapter 2 and not on Chapter 1.

Second readingProofs of (a) and (c)

Idea. Each statement comes from Sets, Relations, and Cardinality, Theorem 2.3.1, and each law is one induction on one index, following the clauses of the recursion: the base case uses the starting value, and the step peels off the last term or factor. Only the laws of R named at each step are used.

Proof. (a) Apply Sets, Relations, and Cardinality, Theorem 2.3.1 (read on N=ω through Number Systems: From N to R, Corollary 1.7.3 (b)) with X=T, starting value 0 and step (j,y)↦y+uj, a function N×T→T because + maps T×T into T. It gives exactly one sequence (Sj)j∈N in T with S0=0 and Sj+1=Sj+uj. Set ∑i=0kui:=Sk+1. Then ∑i=00ui=0+u0=u0 by the hypothesis on 0, and ∑i=0k+1ui=Sk+1+uk+1=∑i=0kui+uk+1. Any assignment obeying the two displayed equations agrees with this one at every k, by Logic and Proof, Axiom 4.2.1 on k.

For the dependence on u0,…,uk, let (vi) be a second sequence with vi=ui for i≤k, and let (Sj′) be its sequence of partial sums. We prove by Logic and Proof, Axiom 4.2.1 on j the statement “if j≤k+1, then Sj=Sj′”. For j=0 both are 0. If j+1≤k+1, then j≤k+1 and j≤k, so Sj=Sj′ by the hypothesis and uj=vj; hence Sj+1=Sj+uj=Sj′+vj=Sj+1′. At j=k+1 this gives ∑i=0kui=∑i=0kvi. The argument used only that + is a function on T. The product of a list is Sets, Relations, and Cardinality, Theorem 2.3.1 with X=R, starting value 1 and step (j,y)↦ysj+1 (with sj:=1, say, for j>r), the pattern of the product in Sets, Relations, and Cardinality, Definition 2.3.1; its dependence on s1,…,sr only is the same induction.

(c) The powers are Sets, Relations, and Cardinality, Theorem 2.3.1 with X=R, starting value 1 and step (n,y)↦ys, the pattern of Sets, Relations, and Cardinality, Definition 2.3.2. For the first law fix m and induct on n (Logic and Proof, Axiom 4.2.1). For n=0: sm+0=sm=sm⋅1=sms0, by (F7). If sm+n=smsn, then sm+(n+1)=s(m+n)+1=sm+ns=(smsn)s=sm(sns)=smsn+1, using m+(n+1)=(m+n)+1 (Number Systems: From N to R, Theorem 1.5.3 (c)), the recursion, the hypothesis and (F5). For the second law fix m: (sm)0=1=s0=sm⋅0 (Number Systems: From N to R, Definition 1.5.1 (b)), and if (sm)n=smn, then (sm)n+1=(sm)nsm=smnsm=smn+m=sm(n+1), by the first law and m(n+1)=mn+m (Number Systems: From N to R, Theorem 1.5.3 (d), (e)). For the third: (st)0=1=1⋅1=s0t0, by (F7), and if (st)n=sntn, then (st)n+1=(st)n(st)=(sntn)(st)=(sns)(tnt)=sn+1tn+1, regrouping by (F5) and (F6). This proves (a) and (c).

We will use (a) twice over: for sums of ring elements, as in the product formula of Section 4.2, and for sums in R[x] of finitely many monomials, which Section 4.2 forms with its coefficientwise addition before any ring law of R[x] is known. In both cases 0+u=u holds, in R by (F1) and (F3), and in R[x] position by position.

4.1.4. Exercises

A. Check your understanding

Exercise (A1)
  • (a) Write the coefficient sequences of x3−2x∈Z[x] and of [2]x2+[4]x∈(Z/4Z)[x]. Is the second one a monomial?
  • (b) Is “1+x+x2+⋯”, the sequence (1,1,1,…) of rationals, a polynomial over Q? Name the clause of Definition 4.1.1 that decides it.
  • (c) True or false: two polynomials p,q over F2 whose rules c↦∑k=0Npkck and c↦∑k=0Nqkck, for an N admissible for both, agree at 0 and at 1 are equal. Justify your answer.
  • (d) Which N are admissible for 3x2−x+2∈Q[x]?

Solution.

  • (a) x3−2x is (0,−2,0,1,0,0,…): the constant term is 0, the coefficient of x is −2, and that of x3 is 1. The second is ([0],[4],[2],[0],…), and [4]=[0] in Z/4Z, since 4−0=4. So it is ([0],[0],[2],[0],…), the monomial [2]x2.

  • (b) No. The clause only finitely many fails: for every N∈N the entry in position N+1 is 1≠0, so no N is admissible.

  • (c) False. The polynomials x2+x and 0 over F2 give the rules c↦cc+c and c↦0, which agree at 0 and at 1 (the computation at the start of the section). But x2+x=(0,1,1,0,…) differs from 0 in position 1, so the polynomials are not equal.

  • (d) Every N≥2. The coefficient of x2 is 3≠0, so N=0 and N=1 fail (position 2>N holds a non-zero entry); and every N≥2 works, since all positions k≥3 hold 0.

B. Practice

Exercise (B1: Polynomials of bounded length as tuples)

Let N∈N and PN:={p∈R[x]:pk=0 for every k>N}. Prove that Θ:PN→RN+1,p↦(p0,p1,…,pN), is a bijection (Sets, Relations, and Cardinality, Definition 1.4.5), where RN+1 is the set of (N+1)-tuples of elements of R, indexed here from 0 (Sets, Relations, and Cardinality, Definition 1.3.2; for N=0, where the book has no 1-tuples, we read R1 as R, with (a0) standing for a0, and Θ as p↦p0). Hence list the elements of P2 for R=F2.

Solution. Injective. Let p,q∈PN with Θ(p)=Θ(q). Then pk=qk for k≤N, and pk=0=qk for k>N by the definition of PN. So pk=qk for every k, and p=q by Sets, Relations, and Cardinality, Proposition 1.4.1.

Surjective. Let (a0,…,aN)∈RN+1. Define p:N→R by pk:=ak for k≤N and pk:=0 for k>N: extend by zeros. Then N is admissible for p, so p∈R[x] and p∈PN, and Θ(p)=(a0,…,aN).

So Θ is a bijection; its inverse is “extend by zeros”. For R=F2 and N=2, each ai is 0 or 1, and the eight triples (a0,a1,a2) give the eight polynomials 0,1,x,x+1,x2,x2+1,x2+x,x2+x+1. Section 4.4 returns to this list and asks which functions F2→F2 they define.

Exercise (B2: Determine which)

Each formula below defines a sequence N→Z/4Z. Determine which of them are polynomials over Z/4Z. Justify your answer, and for each polynomial give the least admissible N and the polynomial in the notation of the display.

  • (a) pk:=[2k].
  • (b) pk:=[k2].
  • (c) pk:=[k(k−1)(k−2)(k−3)].
  • (d) pk:=[2k].

Solution. By Number Systems: From N to R, Theorem 3.4.3 (b), [0],[1],[2],[3] are four different classes; in particular [1]≠[0] and [2]≠[0].

  • (a) A polynomial. The first entries are [1],[2],[4],[8],…, and for k≥2, 2k=4⋅2k−2 (Lemma 4.1.1 (c)), so [2k]=[0]. The least admissible N is 1: N=1 works, and N=0 does not, since p1=[2]≠[0]. The polynomial is 1+[2]x.

  • (b) Not a polynomial. For odd k=2j+1, k2=4(j2+j)+1, so pk=[1]≠[0]. Given any N, the odd number k=2N+1>N has pk≠[0], so no N is admissible.

  • (c) A polynomial: the zero polynomial. Let k∈N. By Number Systems: From N to R, Theorem 3.1.2 (a), k=4q+r with 0≤r≤3, so k−r=4q is one of the four factors k,k−1,k−2,k−3. Hence the product is a multiple of 4, and pk=[0] for every k (for k≤3 the multiple is 0, since then q=0). Every N is admissible; the least is 0, and the display is 0.

  • (d) Not a polynomial. For odd k=2j+1, 2k=4j+2, so pk=[2]≠[0], and as in (b) no N is admissible.

The sequences in (b) and (d) have infinitely many non-zero entries even though their values repeat; (c) shows that a formula in k can describe the zero polynomial.

C. Going deeper

Exercise (C1: Finitely many, in the sense of finite sets)

For a sequence p:N→R, let S:={k∈N:pk≠0}, the set of positions that hold a non-zero entry. Prove that some N∈N is admissible for p if and only if S is finite (Sets, Relations, and Cardinality, Definition 3.1.2). So “only finitely many pk are non-zero” in Definition 4.1.1 means exactly what it says.

Solution. (⇒) Let N be admissible. If k∈S, then pk≠0, so k≤N; hence S⊆{0,…,N}. The set {0,…,N} has N+1 elements (the third example after Sets, Relations, and Cardinality, Definition 3.1.2), so its subset S is finite by Sets, Relations, and Cardinality, Proposition 3.1.6.

(⇐) We prove by Logic and Proof, Axiom 4.2.1 on n∈N: every subset A⊆N with n elements has an upper bound b∈N, that is, a≤b for every a∈A. For n=0, A=∅ (the first example after Sets, Relations, and Cardinality, Definition 3.1.2), and b=0 works vacuously. Suppose the statement holds for n, and let φ:{1,…,n+1}→A be a bijection. Put z:=φ(n+1) and A′:=A∖{z}. The restriction of φ to {1,…,n} maps into A′ (if φ(j)=z then j=n+1, by injectivity), is injective, and is onto A′ (an element of A′ is φ(j) with j≠n+1, so j≤n). So A′ has n elements and an upper bound b′. By trichotomy (Number Systems: From N to R, Theorem 1.6.1 (a)), the larger b of b′ and z is defined, and it bounds every element of A=A′∪{z}.

Now let S be finite, with an upper bound N. If k>N, then k∉S, that is, pk=0. So N is admissible.

The proof of (⇐) never needed a greatest element of S, only an upper bound. The greatest element exists when S is non-empty and finite (an upper bound in N⊆Z gives one by Number Systems: From N to R, Proposition 2.3.6), and Section 4.3 calls it the degree.

Marking scheme. (10 points) - 3: (⇒) shows S⊆{0,…,N} and concludes that S is finite, citing that {0,…,N} is finite and that a subset of a finite set is finite (Sets, Relations, and Cardinality, Proposition 3.1.6). - 2: (⇐) sets up an induction on the number of elements of a finite A⊆N, with the claim that A has an upper bound, and handles A=∅. - 2: in the step, removes one element z and shows that the rest A′ has n elements (by restricting the bijection, or by Sets, Relations, and Cardinality, Corollary 3.1.7). - 1: takes the larger of b′ and z, by trichotomy, as a bound for A=A′∪{z}. - 2: concludes that an upper bound N of S is admissible: k>N implies k∉S, so pk=0.

Fatal errors (0 for the step): using a greatest element of S without justification; overlooking S=∅ in (⇐).