Fourier series

The app builds the Fourier series of a function on an interval taken as one period (without one on [−π, π]), or the sine or cosine series of a function on [0, L]. The function can also be given piecewise.

It computes the coefficients by integrals with the full working (integration by parts with the parameter n), substitutes sin nπ = 0 and cos nπ = (−1)ⁿ and uses symmetry for even and odd functions. At discontinuities it determines the sum of the series by Dirichlet's theorem, and by substituting a point and by Parseval's identity it derives sums of numerical series (such as Σ 1/n² = π²/6). The graph shows the periodic extension of the function and the partial sums with a slider.

How to enter it

fourier(x^2, -pi, pi)The function and the interval.
fouriersin(x, 0, pi)The sine series (fouriercos – the cosine series).
-1, -pi < x < 0
1, 0 < x < pi
A piecewise function line by line, with the “Fourier series” chip.
x^2A function with the “Fourier series” chip – choose the kind of series and the interval there.

Examples

An even function – cosines only; the sums Σ 1/n² and Σ 1/n⁴.
Input: fourier(x^2)
fourier(x^2)
fourier(x^2)fourier(x^2)fourier(x^2)fourier(x^2)
A piecewise function – jumps and the Gibbs phenomenon.
Input: -1, -pi < x < 0
1, 0 < x < pi
Fourier series
-1, -pi < x < 0
1, 0 < x < pi
-1, -pi < x < 0
1, 0 < x < pi-1, -pi < x < 0
1, 0 < x < pi-1, -pi < x < 0
1, 0 < x < pi-1, -pi < x < 0
1, 0 < x < pi
A sine series and the sum 1 − 1/3³ + 1/5³ − … = π³/32.
Input: fouriersin(x*(pi - x), 0, pi)
fouriersin(x*(pi - x), 0, pi)
fouriersin(x*(pi - x), 0, pi)fouriersin(x*(pi - x), 0, pi)fouriersin(x*(pi - x), 0, pi)fouriersin(x*(pi - x), 0, pi)

Known limitations