This question arose while I was tutoring a student on the topic of the Remainder Theorem. Now, the Remainder Theorem tells us that when a polynomial $p(x)$ is divided by a linear factor $(x-a)$, the remainder is simply $p(a)$. However, in this case we have a product of linear factors.

Using the Remainder Theorem we can see that neither $(x-1)$ nor $(x+2)$ is a factor of $f(x)$. Also, if we try to find the remainder using long division, we get a relatively ugly remainder of $$ 3(14x - 13) $$ I assume this is not the correct approach as all other questions in this topic used the Remainder Theorem. So perhaps there is a more elegant approach?

  • 2
    $\begingroup$ Hint $\ $ The remainder $\,r(x)\,$ is a linear polynomial and you know two values $\,r(1) = f(1),\ $ and $\,r(-2) = f(-2)\,$ $\endgroup$ – Bill Dubuque Nov 19 '16 at 19:44
  • $\begingroup$ Long division is using brute force, but it's fairly intuitive. Many high school students I tutor have a tough time grappling with the remainder theorem. Depending on the level of the student, showing both approaches in tandem could be instructive. $\endgroup$ – zahbaz Nov 19 '16 at 21:07

Hint: the remainder will be a polynomial of degree (at most) $1$ so:

$$f(x) = (x-1)(x+2)q(x) + ax + b$$

Substitute $x=1,-2$ in the above and you get two equations in $a,b$.

[ EDIT ]   For a less conventional approach (justified in the answer here) note that $(x-1)(x+2)=0 \iff x^2=-x+2$. Repeatedly using the latter substitution:

$$ \begin{align} 3x^5 - 5x^2 + 4x + 1 &= 3 (x^2)^2 \cdot x - 5(x^2) + 4x + 1 \\ &= 3(x^2-4x+4)x - 5(-x+2) + 4x +1 \\ &= 3(-x+2-4x+4)x + 9x -9 \\ &= -15(x^2)+ 18x + 9x - 9 \\ &= -15(-x+2) + 27 x - 9 \\ &= 42 x -39 \end{align} $$

  • $\begingroup$ This must be the intended strategy. Thank you. $\endgroup$ – Shaun Nov 19 '16 at 19:51
  • $\begingroup$ @Shaun Likely so, and probably the quickest in this case. I edited my answer to add an alternative approach, but that doesn't necessarily save much time here. $\endgroup$ – dxiv Nov 19 '16 at 20:03

The solution is easy by employing $\ gf\bmod gh\, =\, g(f\bmod h)\ \ $ [mod Distributive Law]

$$\begin{align}f(x)\!-\!f(a)\bmod (x\!-\!a)(x\!-\!b) &= (x\!-\!a)\left(\dfrac{f(x)\!-\!f(a)}{x\!-\!a}\bmod x\!-\!b\right)\\ &= (x\!-\!a)\left(\dfrac{f(b)\!-\!f(a)}{b\!-\!a}\right)\ \ {\rm if}\ \ a\neq b\\ &= (x\!-\!a)\,\ f'(a)\qquad\qquad\ \ \, {\rm if}\ \ a = b \end{align}$$

In the OP $\,a=1,b=-2\,$ so above is $\,f(x)\!-\!3 \equiv (x\!-\!1)(42)\ $ so $\ f(x) \equiv 42x-39$

Note that this method does not require solving a system of equations - as some methods do.

Below is a simple example - which may help to clarify the essence of the matter.

$\,\ \underbrace{x\!+\!2\mid f}_{\large f(-2)\ =\ 0\ }\Rightarrow\, f\bmod x^2\!-\!4\,$ $=\, (x\!+\!2)\Bigg[\dfrac{f}{x\!+\!2}\bmod x\!-\!\color{#c00}2\Bigg]$ $ =\, \underbrace{(x\!+\!2)\left[\dfrac{f(\color{#c00}{2})}{\color{#c00}2\!+\!2}\right] =\, 2(x\!+\!2)}_{\large f\bmod x-\color{#c00}2\,\ =\,\ f(\color{#c00}{2})\,\,\ =\,\ 8}$

Remark $ $ Alternatively, if modular arithmetic is unfamiliar we can eliminate it.

Write $\ f = f(a) + (x\!-\!a) g\,\ $ by dividing $\,f\,$ by $\,x\!-\!a.\,$ Dividing $\,g\,$ by $\,x\!-\!b\,$ yields

that $\,\ \ f = f(a) + (x\!-\!a)(g(a)+(x\!-\!b)h)$

So $\ f(b) = f(a) + (b\!-\!a)\,g(a)\,$ by eval at $\,x=b.\,$ Solving for $\,\color{#c00}{g(a)}\,$ and substituting in above

$$ f(x)\, =\, \underbrace{f(a)\,+\,\color{#c00}{\dfrac{f(b)-f(a)}{b-a}} (x\!-\!a)}_{\large f(x)\,\bmod\, \color{#0a0}{(x-a)(x-b)}}\, +\, \color{#0a0}{(x\!-\!a)(x\!-\!b)} h(x)$$

The above Newton / Lagrange interpolant is precisely the Easy CRT solution of the system $$\begin{align} f(x) \equiv f(a) &\pmod{x\!-\!a}\\ f(x)\equiv f(b)&\pmod{x\!-\!b}\end{align}$$ Generally Lagrange interpolation is a special case of CRT = Chinese remainder Theorem. The first solution amounts to using the mod distributive law to derive Easy CRT as explained here.

If we specialize $\,b = a\,$ above then we get the first order Taylor series expansion. For polynomials this can be done purely algebraically (no limits) - see this purely algebraic definition of the derivative).

The $\!\bmod\!$ Distributive Law can be viewed as an equivalent "shifty" operational reformulation of CRT = Chinese Remainder Theorem, as I explain in the end of my Remark here. It is often more convenient to apply in practice because of its operational nature, e.g. here are many examples.


You can mimic the proof of the remainder theorem. We want to find $r(x)$, where $$ p(x)=(x-1)(x+2)q(x)+r(x) $$ and $r(x)$ has degree at most $1$. From this equation, it follows that $r(1)=p(1)=3$, and $r(-2)=p(-2)=-123$. Since $r$ has degree at most $1$, it is linear with slope $\frac{3-(-123)}{1-(-2)}=42$, and then the point-slope formula tells us that its equation is $$ y=42(x-1)+3=42x-39 $$


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.