Suppose $p$ and $q$ primes and $p$ is odd. Then, are there nice and clever ways to factorize polynomials of the form $$f(x)=1+x+\cdots +x^{p-1}$$ in the ring $\mathbb{F}_q[x]$ ? What about the case when $q=2$ ?
I know that there are factorization algorithms but they are too general. I want to know if there are clever ways to do this for these special type of polynomials. Like for example, in $\mathbb{F}_2$ one might add terms $x^r+x^r$ and rearrange them so that $f(x)$ gets factorized.
In case there are no good methods to factorize, are there nice ways to check whether $f(x)$ is irreducible in $\mathbb{F}_q[x]$ ?
We can write $f(x)=\frac{x^p-1}{x-1}$, so it suffices to see how $x^p-1$ factors.
If $p=q$, then $x^p-1=(x-1)^p$.
If $q\neq p$, then $x^p-1$ is separable (and its solutions are the $p^{th}$ roots of unity). We know what the multiplicative group $\mathbb{F}_{q'}^{\times}$ is for any field extension $\mathbb{F}_{q'}$ of $\mathbb{F}_{q}$ (namely, a cyclic group of order $q'-1$). Then we can solve for the minimum value of $q'$ such that $x^p-1$ splits by finding when $p$ divides $q'-1$. Then, to factor over $\mathbb{F}_{q}$, we can take Galois orbits of the $p^{th}$ roots of unity under the Galois extension $\mathbb{F}_{q'}$ of $\mathbb{F}_{q}$.