I'm trying to solve the following exercise, Let $\left(e_n\right)_{n \geq 1}$ be an orthonormal sequence in $H=L^2(0,1)$. Let $p(t)$ be a given function in $H$. Deduce that
$$ (1) \quad\sum_{n=1}^{\infty}\left|\int_0^t p(s) e_n(s) d s\right|^2 \leq \int_0^t|p(s)|^2 d s . $$ $$ (2) \quad \sum_{n=1}^{\infty} \int_0^1\left|\int_0^t p(s) e_n(s) d s\right|^2 d t \leq \int_0^1|p(t)|^2(1-t) d t. $$
I'm having trouble trying to deduce (2), I imagine that I have to integrate (1) and use monotone convergence to get left side, but how do i get that $(1-t)$ factor on right side.
Also, It seems like (2) with equality implies (1) with equality how does this happen?.
Any help would be appreciated, thank you in advance.
The Fourier series for $\chi_{[0,t]}(s)p(s)$ is $$ \sum_{n=1}^{\infty}\int_0^1\chi_{[0,t]}(s')p(s')e_n(s')ds'\, e_n(s) \sim \chi_{[0,t]}(s)p(s) \\ \sum_{n=1}^{\infty}\int_0^tp(s')e_n(s')ds'e_n(s)\sim \chi_{[0,t]}(s)p(s). $$ The corresponding Parseval identity for this function of $s$ is: $$ \sum_{n=1}^{\infty}\left|\int_0^tp(s')e_n(s')ds'\right|^2 =\int_0^t|p(s')|^2ds' $$ The second inequality that you want is obtained by integrating the above in $t$ and by using the monotone convergence theorem: $$ \sum_{n=1}^{k}\left|\int_0^tp(s')e_n(s')ds'\right|^2 \le \int_0^t|p(s')|^2ds' \\ \sum_{n=1}^{k}\int_0^1\left|\int_0^tp(s')e_n(s')ds'\right|^2dt \le \int_0^1\int_0^t|p(s')|^2ds'dt $$ Now it's a matter of interchanging the order of integration on the right in order to obtained the desired inequality: $$ \int_0^1\int_0^t|p(s')|^2ds'dt = \int_0^1\int_0^1|p(s')|^2\chi_{[0,t]}(s')ds'\, dt \\ = \int_0^1|p(s')|^2\int_0^1\chi_{[0,t]}(s')dt\, ds' \\ = \int_t^1|p(s')|^2 (1-s')ds' $$