My function y(x) is $C^{1}$ in $[0,\pi]$ , and $y(0)=y(\pi)=0 $.
I want to show that $\int_{0}^{\pi} |y(x)|^{2} dx \le \int_{0}^{\pi} |y'(x)|^{2} dx $
$Hint:\,Extend \,\, y(x)\, to\, an\, odd\,function $
I used the hint, and hence I wrote $y(x)=\sum_{1}^{\infty} b_{n}sin(nx)$ for $x\in[0,\pi]$.
There is a theorem in my book stating that $\frac{2}{\pi}\int_{0}^\pi|y(x)|^{2} dx = \sum_{1}^\infty |b_{n}|^{2}$. Could I say that the left hand side of the inequality equals to this?
And for the right side I can just differentiate $y(x)$ ? So then $y'(x)=\sum_{1}^\infty b_{n}ncos(nx) $
Can I then say that $\int_{0}^{\pi} |y'(x)|^{2} dx = \sum_{1}^\infty n^{2}|b_{n}|^{2}$.
And hence the inequality should hold, or am I thinking wrong?
Following the hint, extend $y$ to an odd function $\tilde{y}$ in $L^2(\Bbb{T})$ (we can do this because $y(0)=y(\pi)=0$).
Verify (by integration by parts for $n \neq 0$) that $$ \hat{\tilde{y}}(n) = \begin{cases}0 & n=0 \\ \frac{1}{in}\widehat{\tilde{y}'}(n) & n \neq 0\end{cases} $$
Now \begin{align*} \int_{0}^{\pi} |y(x)|^{2} \,dx &= \frac{1}{2} \int_{-\pi}^{\pi} |\tilde{y}(x)|^{2} \,dx \\ &=\pi \| \tilde{y} \|_2^2 \\ &=\pi \sum_{n \in \mathbb{Z}} |\hat{\tilde{y}}(n)|^2 & \text{by Parseval} \\ &=\pi \sum_{\substack{n \in \mathbb{Z} \\ n \neq 0}} \frac{1}{n^2} |\widehat{\tilde{y}'}(n)|^2 \\ &\leq \pi \sum_{n \in \mathbb{Z}} |\widehat{\tilde{y}'}(n)|^2 \\ &=\pi \| \tilde{y}' \|_2^2 & \text{by Parseval} \\ &= \frac{1}{2} \int_{-\pi}^{\pi} |\tilde{y}'(x)|^{2} \,dx \\ &= \int_{0}^{\pi} |y'(x)|^{2} \,dx \end{align*}
Note that the last equality comes from the fact that if $\tilde{y}$ is odd then $\tilde{y}'$ is even.