Learn / Math / Multivariate & Multilinear Polynomials
24. Multivariate & Multilinear Polynomials
Multivariate Polynomials · Lesson 25 of 26 · 13:00
How polynomials in several variables generalize everything built so far, why restricting each variable to appear at most once — multilinear — gives a unique polynomial through any table of values, and how the Schwartz–Zippel lemma turns that into the soundness argument behind every random spot-check.

Every polynomial up to now has taken one input: f(x)f(x). This lesson lets a polynomial take several, which is what the rest of the series — and the sumcheck protocol in particular — actually runs on. One running example carries the lesson: a table of four values, the unique polynomial through them, and how confident a single random check can be that two polynomials agree everywhere.

From one variable to many

The jump from one variable to several changes what “degree” means, but evaluation still works exactly the same way.

from one variable to many What changes when a polynomial has more than one variable? ONE VARIABLE   f(x) = 2 + 3x + x2 (one input, degree 2) TWO VARIABLES   f(x, y) = 3x2y + 2xy + 5 (the input is a pair (x, y)) TOTAL DEGREE   x2y has degree 2 + 1 = 3, so total degree = 3 DEGREE IN EACH VARIABLE   x → 2, y → 1 EVALUATE AT (2, 3) IN F(13) 3×22×3 + 2×2×3 + 5 = 36 + 12 + 5 = 53 = 1 f(2, 3) = 1 ✓ MANY VARIABLES: ONE POINT IN, ONE NUMBER OUT Total degree controls how often a random point hits zero.
Fig. 1 — f(x) = 2 + 3x + x² has one input and degree 2; f(x, y) = 3x²y + 2xy + 5 takes a pair (x, y), where the term x²y has total degree 3 and degree 2 in x, degree 1 in y. Evaluating at (2, 3) in F(13) still gives one number.
Total degree

deg⁡(x2y)=2+1=3,deg⁡(f)=max⁡termsdeg⁡(term)\deg(x^2y) = 2 + 1 = 3, \qquad \deg(f) = \max_{\text{terms}} \deg(\text{term})

A monomial’s degree is the sum of its exponents across every variable; a polynomial’s total degree is the largest of those over all its terms. f(x,y)=3x2y+2xy+5f(x, y) = 3x^2y + 2xy + 5 has total degree 33, from the x2yx^2y term — even though the whole polynomial has only two variables. Plugging in a point is unchanged: substitute every value and reduce mod pp, same as with one variable.

Multilinear: each variable at most once

Restrict every variable to appear to the power 11 at most, and the polynomial becomes exactly as expressive as a table of values on the Boolean hypercube — no more, no less.

multilinear: each variable at most once What if every variable may only appear to the power 1? ALLOWED   3 + 2x + 5y + 4xy ✓ NOT ALLOWED   x2 or x2y ✗ MONOMIALS   1, x, y, xy → 4 = 22 coefficients. With n variables there are 2n. (0, 1) → 8 (1, 1) → 14 = 1 (0, 0) → 3 (1, 0) → 5 the Boolean hypercube {0, 1}2, all values in F(13) CHECK   f(1, 1) = 3 + 2 + 5 + 4 = 14 = 1 ✓ 2ⁿ COEFFICIENTS MATCH 2ⁿ CORNERS The four corner values pin down the whole polynomial.
Fig. 2 — 3 + 2x + 5y + 4xy is multilinear: x and y never appear squared. With n variables there are 2ⁿ monomials — one for every subset of variables that could be multiplied together — matching the 2ⁿ corners of the Boolean hypercube {0,1}ⁿ.
Multilinear polynomials

f(x1,…,xn)=∑S⊆{1,…,n}cS∏i∈Sxif(x_1, \ldots, x_n) = \sum_{S \subseteq \{1,\ldots,n\}} c_S \prod_{i \in S} x_i

A multilinear polynomial in nn variables is a sum over every subset SS of variables, each with its own coefficient cSc_S multiplying the product of that subset — 2n2^n coefficients for 2n2^n subsets. That count isn’t a coincidence: it matches the 2n2^n corners of {0,1}n\{0,1\}^n, the set of all 0/10/1 assignments to the nn variables.

From a table to a polynomial

Given values at the four corners of {0,1}2\{0,1\}^2, there’s exactly one multilinear polynomial that hits all of them — and selector polynomials build it directly.

from a table to a polynomial Given four corner values, which multilinear polynomial passes through all of them? TABLE   (0,0) → 3, (1,0) → 5, (0,1) → 8, (1,1) → 1 SELECTORS   each corner gets a selector that is 1 at that corner and 0 at the other three: (1 − x)(1 − y), x(1 − y), (1 − x)y, xy BUILD   f(x,y) = 3×(1−x)(1−y) + 5×x(1−y) + 8×(1−x)y + 1×xy EXPAND   constant 3, x: −3+5=2, y: −3+8=5, xy: 3−5−8+1=−9=4 so f(x, y) = 3 + 2x + 5y + 4xy TEST AT (2,3), SELECTOR FORM   3×2+5×(−4)+8×(−3)+1×6=6−20−24+6=−32=7 TEST AT (2,3), EXPANDED FORM   3+4+15+24=46=7 both forms give 7 ✓ A TABLE HAS EXACTLY ONE MULTILINEAR POLYNOMIAL It's called the multilinear extension — and it works at points that aren't corners too.
Fig. 3 — four corner values (0,0)→3, (1,0)→5, (0,1)→8, (1,1)→1 combine with four selector polynomials, each equal to 1 at its own corner and 0 at the other three, to build f(x, y) = 3 + 2x + 5y + 4xy — checked at (2, 3) two ways, both giving 7.
Selector polynomials

χ(a,b)(x,y)=xa(1−x)1−a⋅yb(1−y)1−b\chi_{(a,b)}(x,y) = x^{a}(1-x)^{1-a} \cdot y^{b}(1-y)^{1-b}

The selector for corner (a,b)(a, b) is 11 exactly at that corner and 00 at every other corner — built from xx or (1−x)(1-x) depending on whether aa is 11 or 00, same for yy. Summing each corner’s value times its selector gives a polynomial that matches the table everywhere on the hypercube; because a degree-11-per-variable polynomial is pinned down by that few points, it’s the only one that does, and it’s called the multilinear extension of the table.

How often can a polynomial hit zero?

Lesson 10 introduced this bound for a single variable: a nonzero polynomial can still equal zero at plenty of points, but not too many. The same argument carries over unchanged to several variables, and that’s the fact the next two sections build on.

how often can a polynomial hit zero? A polynomial isn't zero everywhere. How likely is a random point to be a root anyway? ONE VARIABLE   degree d has at most d roots, so chance ≤ d/p THE RULE   nonzero polynomial, total degree d, random point in F(p) → chance of zero ≤ d/p EXAMPLE   f(x, y) = x × y in F(13), total degree 2 ZEROS   x = 0 or y = 0 → 13 + 13 − 1 = 25 points out of 169 COMPARE   actual 25/169 ≈ 14.8%, bound 2/13 = 26/169 ≈ 15.4% 25 ≤ 26 ✓ REAL FIELD   p ≈ 2254 and d = 220 → chance ≤ 2−234 A NONZERO POLYNOMIAL ALMOST NEVER VANISHES AT RANDOM This bound is the Schwartz–Zippel lemma.
Fig. 4 — f(x, y) = xy in F(13) has total degree 2 and vanishes at 25 of 169 points, right under the Schwartz–Zippel bound of 26 of 169; at the scale of a real proof system, the same bound makes a random point's chance of hitting zero astronomically small.
Schwartz–Zippel lemma

f≢0, deg⁡(f)=d  ⟹  Pr⁡r←Fn[f(r)=0]≤d∣F∣f \not\equiv 0, \ \deg(f) = d \implies \Pr_{r \leftarrow F^n}[f(r) = 0] \leq \frac{d}{|F|}

For any nonzero polynomial of total degree dd over a field FF, a uniformly random point is a root with probability at most d/∣F∣d / |F|. Over a small field like F(13)F(13) that bound is a real constraint — degree 22 vanishes up to about 15%15\% of the time. Over the 254254-bit fields real proof systems use, with dd in the thousands or millions, that probability is smaller than the chance of guessing a fair coin flip correctly forty times running.

One random check catches a cheater

Flip the lemma around: if two polynomials disagree anywhere, a random point almost certainly reveals it — which is the entire soundness argument behind spot-checking a claim instead of verifying it in full.

one random check catches a cheater Why does checking at one random point actually catch a lie? CLAIM   prover says A(x) × B(x) = C(x) for every x in F(13) CHECK   verifier picks random r, tests A(r) × B(r) =? C(r) WHY IT WORKS   g(x) = A(x)B(x) − C(x) is nonzero, degree ≤ 2 → at most 2 roots CHEAT EXAMPLE   this false claim's g(x) happens to vanish at x = 1 and x = 7 TRY r = 1   g(1) = 0 → check passes, cheater gets lucky ✗ TRY r = 2   g(2) = 5 ≠ 0 → check fails, cheater is caught ✓ repeat 3 times: chance every check gets lucky ≤ (2/13)3 ≈ 0.4% A FEW RANDOM CHECKS SHRINK THE CHEATING CHANCE FAST In a huge field, one check is already enough.
Fig. 5 — testing whether A(x) × B(x) = C(x) everywhere by picking one random point; the difference polynomial g = AB − C has at most 2 roots out of 13, so one unlucky check can miss it, but a second catches it, and three checks together bring the miss chance under half a percent.
Soundness error

ε≤d∣F∣,εk≤(d∣F∣)k after k independent checks\varepsilon \leq \frac{d}{|F|}, \qquad \varepsilon_k \leq \left(\frac{d}{|F|}\right)^k \text{ after } k \text{ independent checks}

If a dishonest prover’s claim is false, the gap g=AB−Cg = AB - C is a nonzero polynomial of degree dd, so by Schwartz–Zippel a single random check misses it with probability at most d/∣F∣d/|F| — that’s the protocol’s soundness error. Repeating the check kk times with fresh randomness multiplies that error down to (d/∣F∣)k(d/|F|)^k; in a 254254-bit field, even one check already makes cheating practically impossible.

Preview: peeling off one variable

One last idea closes the lesson: a claimed sum over every corner of the hypercube can be checked one variable at a time, each round shrinking the claim by one variable.

preview: peeling off one variable Can a prover convince a verifier of a sum without the verifier adding it up? CLAIM   sum over x, y in {0,1} of f(x, y) = 4 ROUND 1   prover sends g₁(x) = f(x,0) + f(x,1) = 11 + 8x, keeping x free CHECK   g₁(0) + g₁(1) = 11 + 19 = 4, matches the claim ✓ CHALLENGE   verifier picks a random r = 2, prover continues at x = 2 ROUND 2   new claim is g₁(2) = 1, and only y is left to pin down two variables, two rounds, one small check each ✓ N VARIABLES, N ROUNDS, ONE VARIABLE PEELED EACH TIME This full protocol — the sumcheck — is coming up next in the series.
Fig. 6 — a claimed sum of 4 over f's hypercube is checked by sending the univariate slice g₁(x) = f(x,0) + f(x,1), confirming g₁(0) + g₁(1) matches the claim, then continuing with a fresh random x = 2, leaving only y to pin down.

Instead of summing 2n2^n values directly, the prover sends one variable’s worth of the sum at a time, the verifier checks consistency with two evaluations, picks a random point to collapse that variable, and passes a smaller claim on to the next round. nn variables become nn rounds, each round a small, cheap check — and each one backed by exactly the Schwartz–Zippel argument from this lesson. That protocol, the sumcheck, is built in full next.

Key takeaways
  • A polynomial in several variables has a total degree (the largest sum of exponents in any term) and a degree in each variable separately; evaluation still means “plug in every value and reduce.”
  • A multilinear polynomial lets each variable appear to the power 11 at most, giving exactly 2n2^n coefficients for nn variables — one per subset, matching the 2n2^n corners of the Boolean hypercube.
  • Selector polynomials, each 11 at one corner and 00 at the rest, build the unique multilinear polynomial through any table of hypercube values — its multilinear extension.
  • The Schwartz–Zippel lemma bounds how often a nonzero degree-dd polynomial can vanish at a random point: at most d/∣F∣d / |F| of the time, a vanishingly small chance in the large fields real proof systems use.
  • That same bound is the soundness argument behind a single random spot-check, and it’s what makes the sumcheck protocol — checking a sum one variable at a time — provably hard to cheat.