Compute the coefficients of $\sum\limits_{n=1}^\infty A_n\sin\frac{n\pi x}{l}=\frac{x^2-x}{4}.$
If I already computed the coefficient for $\sum\limits_{n=1}^\infty A_n\sin\frac{n\pi x}{l}=x^2$ and $\sum\limits_{n=1}^\infty A_n\sin\frac{n\pi x}{l}=x,$ can I just divide both series by 4 and then subtract them and the sum would be the coefficient $A_n$ of $\sum\limits_{n=1}^\infty A_n\sin\frac{n\pi x}{l}=\frac{x^2-x}{4}$ ,
Am I right?
If I am not right, then is there an easier way to compute the coefficient other than compute the complicated integral ?
The coefficients of $f(x)=\sum_{n=1}^\infty A_n\sin \tfrac{n \pi x}{l}$ are $A_n=\frac{1}{l}\int_{-l}^l f(x)\sin \tfrac{n \pi x}{l}\; dx$.
The coefficients of $g(x)=\sum_{n=1}^\infty B_n\sin \tfrac{n \pi x}{l}$ are $B_n=\frac{1}{l}\int_{-l}^l g(x)\sin \tfrac{n \pi x}{l}\; dx$.
Thus, the coefficients of $\alpha f(x)+\beta g(x)=\sum_{n=1}^\infty C_n\sin \tfrac{n \pi x}{l}$ are \begin{align*}C_n&=\frac{1}{l}\int_{-l}^l (\alpha f(x)+\beta g(x))\sin \tfrac{n \pi x}{l}\; dx\\ &=\alpha\frac{1}{l}\int_{-l}^l f(x)\sin \tfrac{n \pi x}{l}\; dx+\beta\frac{1}{l}\int_{-l}^l g(x)\sin \tfrac{n \pi x}{l}\; dx\\ &=\alpha A_n+\beta B_n\end{align*}
Taking $f(x)=x^2$, $g(x)=x$, $\alpha=\tfrac{1}{4}$ and $\beta=-\tfrac{1}{4}$ we conclude that
where
So, yes. You can.