(二)(1) The Legendre polynomials \(P_n(x)\) are orthogonal with respect to the weight function \(w(x)=1\) on the interval \((-1,1)\) and
\(\|P_n\|^2=\displaystyle\int_{-1}^{1}[P_n(x)]^2dx=\dfrac{2}{2n+1}\),where \(n\ge0\).
\(P_0(x)=1,\ P_1(x)=x,\ P_2(x)=\tfrac12(3x^2-1),\dots\)
Therefore, the coefficients in the Fourier-Legendre series, \(\sum_{n=0}^{\infty}C_nP_n(x)\), for an arbitrary function \(f(x)\) are given by \(C_n=\dfrac{2n+1}{2}\displaystyle\int_{-1}^{1}f(x)P_n(x)\,dx,\ n\ge0\). Now, it is given that
\(f(x)=\begin{cases}x,&0\le x\le1\\-x,&-1\le x\le0.\end{cases}\)
Find the Fourier-Legendre series for \(f(x)\).