In the finite field of $q$ elements, the product of all monic irreducible polynomials with degree dividing $n$ is known to be $X^{q^n}-X$. Why is this?
I understand that $q^n=\sum_{d\mid n}dm_d(q)$, where $m_d(q)$ is the number of irreducible monic polynomials with degree $d$, and that each element of the field satisfies $X^{q}-X$.
How does the conclusion follow from this? I tried substituting the exponent to $X^{\sum_{d\mid n}dm_d(q)}-X$ but this doesn't seem to do much good.
There are two steps here.
First prove that for integers $d,n$, $x^{q^d}-x\mid x^{q^n}-x$ if and only if $d\mid n$.
I'll prove the first part of (1) for you. If $\deg(\pi(x))=d$, and $d\mid n$ then consider the field $F=\mathbb F_q[x]\big /{\left<\pi(x)\right>}$. It is of order $q^d$, so we know that for every element $y\in F$, $y^{q^d}=y$. In particular, $x$ is an element of $\mathbb F_q[x]$, so the image $\bar x$ of $x$ in $F$ has the property that ${\bar x}^{q^d}-\bar{x}=0$. But that means that $x^{q^d}-x$ is in the kernel of the map from $\mathbb F_q[x]$ to $F$. So $x^{q^d}-x$ is divisible by $\pi(x)$. So, by our first step above, $x^{q^n}-x$ is divisible by $\pi(x)$ when $d\mid n$.