Problem 329
Medium Remainders and Fourier Series

1^()circ Expand f(x)=cases pi x-x², x in(0,pi), x²-3 pi

$1^\circ$ Expand $f(x)=\begin{cases}\pi x-x^2, & x\in(0,\pi)\\x^2-3\pi x+2\pi^2, & x\in(\pi,2\pi)\end{cases}$ in a Fourier series. $2^\circ$ Show $\sum_{n=1}^\infty\frac{(-1)^{n-1}}{(2n-1)^3}=\frac{\pi^3}{32}$.

Explanation of Method

Both pieces are congruent parabolic arcs, and the function is continuous and odd (as a $2\pi$-periodic extension) about $x=0$, so only sine terms appear. Two integrations by parts give coefficients decaying like $1/n^3$, all with the same sign. Evaluating at $x=\pi/2$ then produces the cubed-reciprocal alternating series.

  1. Confirm odd symmetry, so $a_n=0$.
  2. Compute $b_n$ via double integration by parts on each piece.
  3. Evaluate the series at $x=\pi/2$ to extract the target sum.

Step 1 · Symmetry and continuity

At $x=\pi$: both pieces give $f(\pi^-)=f(\pi^+)=0$, and at $x=0,2\pi$: $f(0^+)=0=f(2\pi^-)$, so $f$ is continuous on $(0,2\pi)$. As a $2\pi$-periodic function it is odd about $0$, so $a_0=a_n=0$ for all $n$; only sine terms appear.

Step 2 · Computing $b_n$

$$ b_n = \frac1\pi\left[\int_0^\pi(\pi x-x^2)\sin(nx)\,dx+\int_\pi^{2\pi}(x^2-3\pi x+2\pi^2)\sin(nx)\,dx\right]. $$ After integration by parts (twice, for the quadratic pieces), the terms combine to give, for odd $n=2k-1$: $$ b_{2k-1} = \frac8{\pi(2k-1)^3}, \qquad b_{2k}=0. $$ (Verified numerically: direct numerical integration gives $b_1\approx2.5465=\frac8\pi$, $b_3\approx0.09431=\frac8{27\pi}$, $b_5\approx0.02037=\frac8{125\pi}$ — confirming the essential factor of $1/\pi$ that is easy to drop in the hand computation.)

Step 3 · Fourier series

$$ \boxed{f(x) = \frac8\pi\sum_{k=1}^\infty\frac{\sin((2k-1)x)}{(2k-1)^3}} $$ (Verified numerically at several points, e.g. $x=1.5$: series gives $\approx2.46239$, matching $f(1.5)=\pi(1.5)-1.5^2\approx2.46239$ exactly.)

Part 2° · The sum $\sum\frac{(-1)^{n-1}}{(2n-1)^3}$

At $x=\dfrac\pi2$: $f\!\left(\dfrac\pi2\right)=\pi\cdot\dfrac\pi2-\dfrac{\pi^2}4=\dfrac{\pi^2}4$, and $\sin\dfrac{(2k-1)\pi}2=(-1)^{k-1}$, so $$ \frac{\pi^2}4 = \frac8\pi\sum_{k=1}^\infty\frac{(-1)^{k-1}}{(2k-1)^3} \implies \boxed{\sum_{n=1}^\infty\frac{(-1)^{n-1}}{(2n-1)^3}=\frac{\pi^3}{32}}. $$ (Verified numerically: partial sums to $200{,}000$ terms give $\approx0.968946$, matching $\pi^3/32\approx0.968946$.)


Summary Table

PropertyValue
Fourier series$f(x)=\frac8\pi\sum\frac{\sin((2k-1)x)}{(2k-1)^3}$
Sum$\sum\frac{(-1)^{n-1}}{(2n-1)^3}=\frac{\pi^3}{32}$

Additional Notes

Result

$$ f(x) = \frac8\pi\sum_{k=1}^\infty\frac{\sin((2k-1)x)}{(2k-1)^3}; \qquad \sum_{n=1}^\infty\frac{(-1)^{n-1}}{(2n-1)^3}=\frac{\pi^3}{32}. $$