Let $u, \eta$ be smooth functions and $\eta$ compactly supported in $(0,1)$. Integrating by parts, we can easily prove $$-\int\_0^1 u\_{xxx}u\_x \eta = \int\_0^1 (u\_{xx})^2\eta - \int\_0^1 \frac{1}{2} (u\_x)^2 \eta\_{xx}$$


Can we obtain the same result using only the Fourier series  

$$u(x) = \sum\_{n=1}^\infty \sqrt 2 \cos (\pi n x) \, a\_n, \qquad \eta(x) = \sum\_{n=1}^\infty \sqrt 2 \cos (\pi n x) \, b\_n $$
as a tool?



Using Fourier series to prove $-\int_0^1 u_{xxx}u_x \eta = \int_0^1 (u_{xx})^2\eta - \int_0^1 \frac{1}{2} (u_x)^2 \eta_{xx}$
term on left hand side:
$$L=-\int\_0^1 dx\, u\_{xxx}u\_x \eta =2^{3/2}\pi^4 \sum\_{n,m,k=1}^\infty n^3m a\_na\_mb\_k \int\_0^1 dx\,\sin(n\pi x)\sin(m\pi x)\cos(k\pi x)=$$
$$=2^{3/2}\pi^4 \frac{1}{4}\sum\_{n,m,k=1}^\infty n^3m a\_na\_mb\_k \left(\delta\_{m,n+k}+\delta\_{n,m+k}-\delta\_{k,n+m}\right).$$
two terms on right hand side
$$R\_1=\int\_0^1 dx\, u\_{xx}^2 \eta =2^{3/2}\pi^4 \sum\_{n,m,k=1}^\infty n^2m^2 a\_na\_mb\_k \int\_0^1 dx\,\cos(n\pi x)\cos(m\pi x)\cos(k\pi x)=$$
$$=2^{3/2}\pi^4 \frac{1}{4}\sum\_{n,m,k=1}^\infty n^2m^2 a\_na\_mb\_k \left(\delta\_{m,n+k}+\delta\_{n,m+k}+\delta\_{k,n+m}\right).$$
$$R\_2=-\frac{1}{2}\int\_0^1 dx\, u\_{x}^2 \eta\_{xx} =\frac{1}{2}2^{3/2}\pi^4 \sum\_{n,m,k=1}^\infty nmk^2 a\_na\_mb\_k \int\_0^1 dx\,\sin(n\pi x)\sin(m\pi x)\cos(k\pi x)=$$
$$=\frac{1}{2}2^{3/2}\pi^4 \frac{1}{4}\sum\_{n,m,k=1}^\infty nmk^2 a\_na\_mb\_k \left(\delta\_{m,n+k}+\delta\_{n,m+k}-\delta\_{k,n+m}\right).$$
left hand side minus right hand side
$$L-R\_1-R\_2=2^{3/2}\pi^4 \frac{1}{4}\left(\frac{1}{2}\sum\_{n=1}^\infty\sum\_{m=n+1}^\infty (mn^3-nm^3)a\_na\_m b\_{m-n}+\frac{1}{2}\sum\_{m=1}^\infty\sum\_{n=m+1}^\infty (mn^3-nm^3)a\_{n}a\_m b\_{n-m}\right.$$
$$\left.+\frac{1}{2}\sum\_{n,m=1}^\infty m n (m^2 -n^2)a\_na\_m b\_{n+m}\right)=0.$$


