# Cyclotomic polynomial

## Definition

The cyclotomic polynomials are recursively defined as $x^n-1=\prod_{d \vert n} \Phi_n (x)$, for $n \geq 1$. All cyclotomic polynomials are irreducible.

## Roots

The roots of $\Phi_n(x)$ are $e^{\frac{2\pi i d}{n}}$, where $\gcd(d, n) = 1$. For this reason, due to the Fundamental Theorem of Algebra, we have $\Phi_n(x) = \prod_{d: \gcd(d, n) = 1} (x - e^{\frac{2\pi i d}{n}})$.

Therefore, $x^{n}-1$ can be factored as $\Phi_{d_{1}}x*\Phi_{d_{2}}x*\Phi_{d_{3}}x*\cdots*\Phi_{d_{k}}$ where $d_1, d_2, d_3\cdots, d_k$ are the positive divisors of $n$.

## Examples

For a prime $p$, $\Phi_p (x)=x^{p-1}+x^{p-2}+ \cdots + 1$, because for a prime $p$, $\Phi_p (x) \cdot \Phi_1 (x)=x^p - 1$ and so we can factorise $x^p - 1$ to obtain the required result.

The first few cyclotomic polynomials are as shown: \begin{align*} \Phi_1(x)&=x-1 \\ \Phi_2(x)&=x+1 \\ \Phi_3(x)&=x^2+x+1 \\ \Phi_4(x)&=x^2+1 \\ \Phi_5(x)&=x^4+x^3+x^2+x+1 \\ \Phi_6(x)&=x^2-x+1 \\ \Phi_7(x)&=x^6+x^5+\cdots + 1 \\ \Phi_8(x)&=x^4+1 \\ \Phi_9(x)&=x^6+x^3+1 \\ \Phi_{10}(x)&=x^4-x^3+x^2-x+1\\ \end{align*}