# Proof: Two polynomials $P(x)$ and $Q(x)$ attain same value for every $x \in \mathbb R$ if and only if coefficients $p_i = q_i$ are equal for every $i$

Proof: Two polynomials $P(x)$ and $Q(x)$ attain same value for every $x \in \mathbb R$ if and only if coefficients $p_i = q_i$ are equal for every $i$

I've been thinking how to prove this. I know we can write both polynomials as a product of irreducible polynomials corresponding to roots, however this only prove that the values attained by the polynomials are equal for every $x \in \mathbb R$ not that the coefficients are equal.

Also we could let $x = 0$ to conclude $p_0 = q_0$. However we may not cancel $x$ by division on both sides ? Then we cannot continue the procedure, since division by zero is undefined.

Could someone give me a hint ?

Besides the standard proof considering the roots of $P-Q$ (which works for polynomials over any infinite integral domain) there is another approach that works for polynomials over the real (or complex) numbers specifically. If the polynomial functions associated to $P$ and $Q$ are equal, then so must their derivative functions, to any order, be. Now the $n$-th derivative of $P$ evaluated at $x=0$ gives you $n!$ times the coefficient of $x^n$ in$~P$. From this you can conclude that all coefficients of $P$ and $Q$ coincide.

• Thanks, I really like your derivative approach. This procedure will terminate since finite numbers of non-zero terms. Nov 30, 2013 at 9:53

Let $S(x) = \sum_{i=0}^ns_ix^i$ be a degree-$n$ polynomial for some $n \ge 0$ (so that $s_n \ne 0$). As $|x|$ grows without limit, the highest-order term $s_nx^n$ comes to dominate all the other terms, in the sense that it is bigger in absolute value than all the other terms added together. Specifically, this happens when

$$|x| > \frac1{|s_n|}\sum_{i=0}^{n-1}|s_i|$$

(as long as $|x| > 1$). So if the above inequality holds, then $|S(x)|$ must be strictly greater than zero. This means that $S$ can't be zero on the whole of $\mathbb R$.

Now just put $S(x) = P(x) - Q(x)$. Your hypothesis implies that $S$ is zero on the whole of $\mathbb R$, so it can't be a degree-$n$ polynomial for any $n \ge 0$. Hence all its coefficients $s_i = p_i - q_i$ must be zero.

Do you know that over any field a polynomial of degree $\;n\;$ has at most $\;n\;$ different roots? Well then, look at the real polynomial $\;h(x):=P(x)-Q(x)\;$ ...

• $h(x)$ has $\infty$ roots. But a polynomial of degree $n$ has a t most $n$ different roots in a domain. So we can conclude that $h(x)$ doesn't confirm to our proved theorem. The only possibility is that $h(x) = 0$ the zero polynomial ? Nov 30, 2013 at 9:56
• Yes, @NicolasLykkeIversen . Nov 30, 2013 at 12:12

Consider $P(x) - Q(x)$ as a polynomial. How many roots does it have? What can you say about a polynomial that has that many roots?

• It has $\infty$ roots. Thus is must be the zero polynomial ? Nov 30, 2013 at 9:52