# Fourier factor frustration

## Homework Statement

I have conflicting notes and even textbooks about where i should and shouldn't have factors of 2 when doing fourier series. I just want to check once and for all i'm doing it right and not introducing erroneous factors of 2 or omitting any

## Homework Equations

$$\tilde{f}(x)= \frac{a_0}{2} + \sum^{\inf}_{n=1} [a_n cos(\frac{n \pi x}{L}) + b_n sin(\frac{n\pi x}{L})]$$

$$a_n = \frac{1}{L} \int^{L}_{-L} cos \frac{n\pi x}{L} f(x) dx$$

$$b_n = \frac{1}{L} \int^{L}_{-L} sin(\frac{n\pi x}{L}) f(x) dx$$

$$a_0 = \frac{1}{2L} \int^{L}_{-L} f(x) dx$$

where the interval is [-L,L] and the period is 2L

## The Attempt at a Solution

Is the above formulation correct (i'm particularly unsure about the 1/2L associated with a0)

Last edited:

Related Calculus and Beyond Homework Help News on Phys.org
vela
Staff Emeritus
Homework Helper
Just plug in the series for f(x) into the integrals and see if the coefficients work out correctly.

jbunniii
Homework Helper
Gold Member
Is the above formulation correct (i'm particularly unsure about the 1/2L associated with a0)
You have an extra factor of 1/2 associated with $a_0$. To see that this is the case, set $f(x) = 1$. Then according to your formulas, $a_0 = 1$ and the Fourier series is

$$\tilde{f}(x) = 1/2$$.

There should be a 1/2 either on the defining integral for $a_0$ or on the $a_0$ term in the series expansion, but not both.

You can check your other coefficients in a similar way by setting

$$f(x) = \cos(n\pi x/L)$$

or

$$f(x) = \sin(n \pi x/L)$$

thank you guys!

I had tried checking it but couldn't be certain it wasn't my dodgy arithmetic!