# Thread: Basic Fourier Series question

1. ## Basic Fourier Series question

In comparison to the rest of the question in this section this will hopefully be easier for someone, here goes.

Let $\displaystyle f$be a function with period 2, such that:

$\displaystyle f(x) = \left\{ \begin{array}{l l} -1 & \quad -1 \leq x < 0\\ 1 & \quad 0 \leq x < 1\\ \end{array} \right.$

Find the Fourier Series of $\displaystyle f$.

$\displaystyle f$ is an odd function so $\displaystyle a_0 = a_n = 0$, and we know that $\displaystyle b_n = 2 \int^1_0 f(x) \sin{\pi n x}$.

I'm just not sure what to put for the $\displaystyle f(x)$, would it be 1 or -1?

Cheers for the help

2. Originally Posted by craig
In comparison to the rest of the question in this section this will hopefully be easier for someone, here goes.

Let $\displaystyle f$be a function with period 2, such that:

$\displaystyle f(x) = \left\{ \begin{array}{l l} -1 & \quad -1 \leq x < 0\\ 1 & \quad 0 \leq x < 1\\ \end{array} \right.$

Find the Fourier Series of $\displaystyle f$.

$\displaystyle f$ is an odd function so $\displaystyle a_0 = a_n = 0$, and we know that $\displaystyle b_n = 2 \int^1_0 f(x) \sin{\pi n x}$.

I'm just not sure what to put for the $\displaystyle f(x)$, would it be 1 or -1?

Cheers for the help
The way you have written it it would need to be $\displaystyle 1$

if you used the limits of integration

$\displaystyle 2\int_{-1}^{0}f(x)\sin(\pi n x)dx$ then it would be $\displaystyle -1$

both integrals will give the same value.

3. Many thanks