Fejér–Riesz theorem (source code)

= Fejér–Riesz theorem
{c}
{title2=$p(z)=|q(z)|^2\quad(|z|=1)$}

= Nonnegative trigonometric polynomial factorization
{synonym}

A <trigonometric polynomial> nonnegative on the <unit circle> has a <polynomial> modulus-square factor of <polynomial degree> at most its trigonometric order. For a nonzero <trigonometric polynomial> of actual order $d$, <conjugate symmetry of trigonometric polynomial coefficients> yields <reciprocal-conjugate root pairing> for $P=z^dp$. <Even multiplicity of unit-circle roots of a nonnegative trigonometric polynomial> permits pairing all $2d$ <roots of a polynomial>. Select representatives $\zeta_1,\ldots,\zeta_d$ and use
$$
z-\frac1{\overline{\zeta_i}}
=-\frac z{\overline{\zeta_i}}(\overline z-\overline{\zeta_i})
\quad(|z|=1).
$$
It follows that $p(z)=c\prod_i|z-\zeta_i|^2$ with $c=(-1)^dp_d/\prod_i\overline{\zeta_i}$. Evaluating away from the <roots of a polynomial> gives $c>0$. Thus $q(z)=\sqrt c\prod_i(z-\zeta_i)$ works. Constant and zero <trigonometric polynomials> have constant or zero factors. Different selections of <roots of a polynomial> and constant phases can give different factors.