I have a Heaviside function here. $$H(x):=\begin{cases} 1, & x > 0\\ 0, & x=0\\ -1, & x<0 \end{cases}$$
I want to approximate this function by polynomial of degree 2 on (-1,1). The hint I got from my professor is the following:
$$H_n=C_n\int_0^xcos^n(\frac{\pi}{2}t)dt, x∈[−1,1]$$ with a normalizing constant $C_n:=\int_0^1cos^n(\frac{π}{2}t)dt.$
Then, one can show that $∥H_n−H∥_{L^2_w[a,b]}<ϵ$ for large enough n.
I don't really know how to show this since I think as $n$ approches infinity, $C_n$ would be approchinng $0$. I don't know if I got the integration wrong but I'm really confused.