- #1
Tony Hau
- 104
- 30
- Homework Statement
- Given : ## f(x) = \begin{cases}
0, & -\pi \lt x \lt 0 \\
1, & 0 \lt x \lt \frac{\pi}{2} \\
0, & \frac{\pi}{2} \lt x \lt \pi
\end{cases} ##,
Find the Fourier Series of ##f(x)##.
- Relevant Equations
- ##a_n =\frac{1}{\pi} \int_{-\pi}^{\pi} f(x) \cos(nx)dx##
##b_n =\frac{1}{\pi} \int_{-\pi}^{\pi} f(x) \sin(nx)dx##
The answer in the textbook writes: $$ f(x) = \frac{1}{4} +\frac{1}{\pi}(\frac{\cos(x)}{1}-\frac{\cos(3x)}{3}+\frac{\cos(5x)}{5} \dots) + \frac{1}{\pi}(\frac{\sin(x)}{1}-\frac{2\sin(2x)}{2}+\frac{\sin(3x)}{3} + \frac{\sin(5x)}{5}\dots)$$
I am ok with the two trigonometric series in the answer. However, I don't understand where that ##\frac{1}{4}## comes from.
Since the formula for ##a_0## is ##a_0 =\frac{1}{\pi} \int_{0}^{\frac{\pi}{2}} dx##, which gives ##\frac{1}{2}##, isn't that constant equal to ##\frac{1}{2}## instead of ##\frac{1}{4}##.
I am ok with the two trigonometric series in the answer. However, I don't understand where that ##\frac{1}{4}## comes from.
Since the formula for ##a_0## is ##a_0 =\frac{1}{\pi} \int_{0}^{\frac{\pi}{2}} dx##, which gives ##\frac{1}{2}##, isn't that constant equal to ##\frac{1}{2}## instead of ##\frac{1}{4}##.