= Solution
For the <Fourier sine series> on $(0,1)$, <orthogonality> gives
$$
b_n=2\int_0^1x\sin(n\pi x)\,dx
=2\left[-\frac{x\cos(n\pi x)}{n\pi}+\frac{\sin(n\pi x)}{n^2\pi^2}\right]_0^1
=\frac{2(-1)^{n+1}}{n\pi}.
$$
Therefore
$$
\boxed{x=\sum_{n=1}^{\infty}\frac{2(-1)^{n+1}}{n\pi}\sin(n\pi x),\qquad 0<x<1.}
$$
The series is that of the odd, two-periodic extension. At $x=0$ its value is zero, agreeing with $f(0)$; at $x=1$ every summand is zero and the series converges to zero, the average of the two one-sided extension limits. Thus it represents the function in the interior and in the square-integrable sense, \b[not the prescribed value one at the endpoint $x=1$]. This endpoint issue matters when using sine expansions with homogeneous boundary conditions.
Back to article page