Question
Let $$f(z) = \sum_{k=0}^{n}c_{k}z^{k}$$ be a polynomial, where $c_{k}\in\mathbb{C}$.
Prove that
$$\int_{-1}^{1}|f(x)|^{2}dx\leq\pi\int_{0}^{2\pi}|f(e^{i\theta})|^{2}\frac{d\theta}{2\pi} = \pi\sum_{k=0}^{n}|c_{k}|^{2}$$
I tried letting $c_{k} = a_{k}+ib_{k}$ for real $a_{k},b_{k}$ and got to $$\int_{-1}^{1}|f(x)|^{2}dx = \int_{-1}^{1}\left(\sum_{k=0}^{n}a^{k}x^{k}\right)^{2}+\left(\sum_{k=0}^{n}b^{k}x^{k}\right)^{2}dx$$ but I'm not sure how to go from here. Am I on the right track (if so can you outline the next few steps?) or should I be approaching this another way?
What I know;
- In the previous part of the question I proved for real $c_{k}$ $$\int_{-1}^{1}[f(x)]^{2}dx\leq\pi\int_{0}^{2\pi}|f(e^{i\theta})|^{2}\frac{d\theta}{2\pi} = \pi\sum_{k=0}^{n}c_{k}^{2}$$ using the Cauchy Theorem and two integrals around the uppper/lower unit semicircles:
Proof (if helpful) Consider the counter-clockwise contour from traversing the real axis from $(-1,0)$ to $(1,0)$, and then a semicircle of radius 1 from $(1,0)$ to $(-1,0)$. By the Cauchy Theorem the integral is $0$ as $f$ is holomorphic everywhere, so splitting the integrals into one along the real axis and one along the arc gives: $$\int_{-1}^{1}[f(x)]^{2}dx = -\int_{0}^{\pi}ie^{i\theta}[f(e^{i\theta})]^{2}d\theta$$
Now since $f$ is real valued if $c_{k}\in\mathbb{R}$, $|f|^{2}\geq 0$, so $$\int_{-1}^{1}[f(x)]^{2}dx = \left|\int_{-1}^{1}[f(x)]^{2}dx\right| = \left|-\int_{0}^{\pi}ie^{i\theta}[f(e^{i\theta})]^{2}d\theta\right|\leq \int_{0}^{\pi}|f(e^{i\theta})|^{2}d\theta$$
Similarly by considering the contour traversing the real axis from $(1,0)$ to $(-1,0)$ and then along the semicircle of radius 1 from $(-1,0)$ to $(1,0)$, we get $$\int_{-1}^{1} [f(x)]^{2}dx\leq \int_{\pi}^{2\pi}|f(e^{i\theta})|^{2}d\theta $$ Adding the two then gives the equality $$\int_{-1}^{1}[f(x)]^{2}dx\leq\pi\int_{0}^{2\pi}|f(e^{i\theta})|^{2}\frac{d\theta}{2\pi} = \pi\sum_{k=0}^{n}c_{k}^{2}$$ - I know how to prove the equality $$\pi\int_{0}^{2\pi}|f(e^{i\theta})|^{2}\frac{d\theta}{2\pi} = \pi\sum_{k=0}^{n}|c_{k}|^{2}$$
Here is the full question for reference; (note I only need help for the second part)

Write $c_k=a_k+\text{i}b_k$ for $k=0,1,2,\ldots,n$, where $a_k,b_k\in\mathbb{R}$. Then, $$f(z)=g(z)+\text{i}\,h(z)\,,$$ where $g(z):=\sum\limits_{k=0}^n\,a_k\,z^k$ and $h(z):=\sum\limits_{k=0}^n\,b_k\,z^k$ are polynomials with real coefficients.
Note that, for $x\in\mathbb{R}$, $$\big|f(x)\big|^2=\big(g(x)\big)^2+\big(h(x)\big)^2\,.$$ Applying Part (a) of the question, you get $$\int_{-1}^{+1}\,\big(g(x)\big)^2\,\text{d}x\leq \pi\,\sum_{k=0}^n\,a_k^2$$ and $$\int_{-1}^{+1}\,\big(h(x)\big)^2\,\text{d}x\leq \pi\,\sum_{k=0}^n\,b_k^2\,.$$ Adding the two inequalities above yields $$\int_{-1}^{+1}\,\big|f(x)\big|^2\,\text{d}x\leq \pi\,\sum_{k=0}^n\,|c_k|^2\,.$$