Distance of functions to subspaces of $L^2$

Let $a>0$ and \begin{eqnarray} L_o&=&\{u \in L^2[-a,a]:\ u(-t) =-u(t)\ \text{ for a.e. } t\},\\ L_e&=&\{u \in L^2[-a,a]:\ u(-t) =u(t)\ \text{ for a.e. } t\}. \end{eqnarray} Find the distance (in $L^2[-a,a]$) of $u(t)=t^2 + t$ from $L_o$ and from $L_e$. Find also the distance of an arbitrary $u \in L^2[-a,a]$ from $L_o$ and from $L_e$.

-

Notice that $L_o\perp L_e$ and $L^2([-a,a])=L_o\oplus L_e$. Therefore any $u \in L^2([-a,a])$ may be written in a unique way as $u=u_1+u_2$, where $u_1\in L_o$ and $u_2 \in L_e$. To be more precise we have $$u_1(t)=\frac{u(t)-u(-t)}{2},\quad u_2(t)=\frac{u(t)+u(-t)}{2}.$$
Also, for every $v_1 \in L_o$ and every $v_2 \in L_e$ we have $v_1v_2 \in L_o$ and .
Let now $u \in L^2([-a,a])$ and $v \in L_o$. Then $$\|u-v\|_2^2=\|(u_1-v)+u_2\|_2^2=\|u_1-v\|_2^2+\|u_2\|_2^2.$$ Since $u_1 \in L_o$, we have $$\inf_{v \in L_o}\|u_1-v\|_2^2=0.$$ Hence \begin{eqnarray} \text{dist}(u,L_o)&=&\inf_{v \in L_o}\|u-v\|_2=\|u_2\|_2=\Big(2\int_0^au_2^2(t)\,dt\Big)^{1/2}\\ &=&\frac{1}{\sqrt{2}}\Big(\int_0^a[u^2(t)+2u(-t)u(t)+u^2(-t)]\,dt\Big)^{1/2}. \end{eqnarray} Similarly, we have