Find a polynomial $p(x)\in \mathbb{Z}/5\mathbb{Z}[x]$ such that, when we divide $p(x)$ by $x+1$ we obtain a remainder of $1$, and when we divide $p(x)$ by $2x-1$ we obtain a remainder of $2$. Explain how you found that polynomial.
-
2This appears to be an application of the Chinese Remainder Theorem I believe. – M D Oct 06 '19 at 19:04
-
1You know that value of $p(x)$ at $x=-1=4$ as well as at $x=1/2=3$. What does Lagrange interpolation tell you? – Jyrki Lahtonen Oct 06 '19 at 19:29
-
@Jyrki Lagrange is overkill since here the solution is obvious - see my answer. – Bill Dubuque Oct 07 '19 at 01:39
2 Answers
The problem can be rephrased as: Find some $p(x)$ such that the following system of congruences is satisfied:
$$p(x) \equiv 1 \textrm{ mod }(x+1)$$ $$p(x) \equiv 2 \textrm{ mod }(2x-1)$$
The Chinese Remainder Theorem gives us a way to find solutions to a system of congruences like this. When we want:
$$p(x) \equiv a_1 \textrm{ mod }q_1(x)$$ $$p(x) \equiv a_2 \textrm{ mod }q_2(x)$$ $$...$$ $$p(x) \equiv a_n \textrm{ mod }q_n(x)$$
The following equation gives a solution:
$$p(x) = a_1 \cdot m_1(x) \cdot y_1 + a_2 \cdot m_2(x) \cdot y_2 + ... + a_n \cdot m_n(x) \cdot y_n $$
Where $$m_i(x) = \frac{q_1(x) \cdot q_2(x) \cdot ... \cdot q_n(x)}{q_i(x)}$$.
and $y_i$ is the inverse of $m_i(x)$ mod $q_i(x)$.
When we only have two congruences to satisfy, this becomes much more simple to state:
$$p(x) = a_1 \cdot q_2(x) \cdot y_1 + a_2 \cdot q_1(x) \cdot y_2$$
We know the following: $$a_1 = 1$$ $$a_2 = 2$$ $$q_1(x) = x+1$$ $$q_2(x) = 2x-1$$
All that remains is to find the inverses ($y_1$ and $y_2$). To do this we can use the Euclidean Algorithm:
$$2x-1 = 2(x+1) - 3$$ $$3 = 2(x+1) - (2x-1)$$ Multiplying by 2 and reducing mod 5 we get: $$1 = 4(x+1) +3(2x-1)$$
So we can see that $y_1 = 3$ and $y_2 = 4$
Putting this all together we have:
$$p(x) = 1 \cdot (2x-1) \cdot 3 + 2 \cdot (x+1) \cdot 4$$ $$p(x) = 6x-3 + 8x+8$$ $$p(x) = 14x + 5$$
And then reducing mod 5 we have:
$$p(x) = 4x$$
It is easy to check that this polynomial leaves the desired remainders when divided by the given polynomials.

- 724
-
According to your answer $p(-1) \neq 1$ where as in the question it is give $ p(-1) = 1$ – Akshaj Bansal Oct 06 '19 at 21:14
-
@Akshaj Bansal We are working in $\mathbb{Z}/5\mathbb{Z}[x]$, so $p(-1)=-4=1$. – M D Oct 06 '19 at 21:35
Hint$\ \bmod 5\!:\ \begin{align} p(1)\,\equiv\, -1\\[.2em] \smash[b]{p(\underbrace{1/2}_{\textstyle -2})}\,\equiv\, 2\\ \end{align}\ $ has $\,\ \bbox[5px,border:1px solid #c00]{p(x) \equiv -x}\,$ as an obvious solution.
$\phantom{.}$

- 272,048
-
Generally we can use CRT / Lagrange / mod distributivity $\ \ \ $ – Bill Dubuque Oct 07 '19 at 01:41