Problem

Source: 2018 Swedish Mathematical Competition p6

Tags: algebra, polynomial



For which positive integers $n$ can the polynomial $p(x) = 1 + x^n + x^{2n}$ is written as a product of two polynomials with integer coefficients (of degree $\ge 1$)?