# Show $f(X)=a_nX^n+\cdots+a_1X+a_0$ has degree $n$ modulo $N$, $f(a)\equiv 0$ (mod $N$) then $f(X) \equiv (X-a)g(X)$(mod $N$)

In Niels Lauritzen, Concrete Abstract Algebra, I'm having trouble showing the following:

The problem starts out like this:

$f(X)=a_nX^n+\cdots+a_1X+a_0, a_i \in \mathbb Z, n \in \mathbb N$

Part (i) which I think I've done right:

i) Show $X-a \mid X^n-a^n$: $X^n - a^n = (X-a)(X^{n-1} + X^{n-2}a + \cdots + Xa^{n-2} + a^{n-1}), n\ge2 \Rightarrow X-a \mid X^n-a^n$.

Part (ii) which I am having trouble solving:

ii) Show that if: $a, N \in \mathbb Z$, $f$ has degree $n$ modulo $N$, $f(a) \equiv 0$ (mod $N$) then $f(X) \equiv (X-a)g(X)$ (mod $N$) and $g$ has degree $n-1$ modulo $N$.

Hint: use (i) and $f(X) \equiv f(X) - f(a)$ (mod $N$).

$f$ has degree $n$ modulo $N$ means $N$ does not divide $a_n$.

Somehow the statement is unnatural und unnecessarily complicated.

If $R$ is an arbitrary commutative ring, and $r \in R$ is a root of a polynomial $f \in R[X]$, then $X-r$ divides $f$. Proof: Using the transformation $X \mapsto X-r$ it suffices to check the case $r=0$. But then $f$ has no constant term and the claim follows.

Now apply this to $R=\mathbb{Z}/N$.

Hint: Ignoring modulo $N$, what would be the coefficient of $x^{n-1}$ in $g(x)$.

Hint: If this coefficient is 0 modulo $N$, what can we say about the coefficient of $x^{n}$ in $f$?

• I must show $g$ has degree $n-1$ modulo $N$. I don't understand your hint. Also I must show $f(X) \equiv (X-a)g(X) \equiv f(X) - f(a)$ for some $g$. – Shuzheng Sep 11 '13 at 15:46
• What can I say about this coefficient in $g(X)$ ? It's $a_n$ ? And if it's $a_n$ then the degree is $n$ ? – Shuzheng Sep 11 '13 at 18:03

Of course $(x-a)g(x)$ vanishes at $x=a$, so $a$ is a root also for this polynomial. If the degree of $f$ is $n$ modulo $N$, then $N$ does not divide $a_n$, which consequently must be the leading coefficient of $g(x)$. As a consequence, the degree of $g(x)$ must be exactly $n-1$, otherwise $(x-a)g(x) \neq f(x)$ mod $N$.