Finding Fourier Series for f(x)

In summary: For b_n to be non-zero, n must be of the form 2k+1 for some integer, k. But then b_n=-1 if n is odd and 1 if n is even. That is, b_n=-1/(2k+1) if k is even and 1/(2k+1) if k is odd. So the Fourier sine series is[tex]1+ \sum_{k=0}^\infty \frac{2(-1)^k}{(2k+1}\pi} sin((2k+1)x)[/tex].
  • #1
Juggler123
83
0
I need to find the Fourier series for the function f;

0 if -[tex]\pi[/tex] [tex]\prec[/tex] x [tex]\leq[/tex] -[tex]\frac{\pi}{2}[/tex]

1+x if -[tex]\frac{\pi}{2}[/tex] [tex]\prec[/tex] x [tex]\prec[/tex] [tex]\frac{\pi}{2}[/tex]

0 if [tex]\frac{\pi}{2}[/tex] [tex]\leq[/tex] x [tex]\leq[/tex] [tex]\pi[/tex]

I've never done a Fourier series computation before so I don't really know if any of what I'm doing is correct.

I've got than a(0)=1, a(n)=[tex]\frac{2sin\frac{n\pi}{2}}{n\pi}[/tex] and
b(n)=[tex]\frac{2sin\frac{n\pi}{2}}{n^{2}\pi}[/tex] - [tex]\frac{cos\frac{n\pi}{2}}{n}[/tex]

I know the formula for a Fourier series but none of the examples I've seen are in the form of the a(n) and b(n) that I've got so I don't know where to go next.
Could anyone help please? Thankyou.
 
Physics news on Phys.org
  • #2
You are going to use the fact that [itex]sin(n\pi/2)= 0[/itex] if n is even, aren't you? And that [itex]sin(n\pi/2)= 1[/itex] if n is "congruent to 1 mod 4" (i.e. n= 4k+ 1 for some integer k) while [itex]sin(n\pi/2)= -1[/itex] if n is "contruent to 3 mod 4" (i.e. n= 4k+ 3 for some k. That is, [itex]a_2= 0[/itex], [itex]a_3= -1/3\pi[/itex], [itex]a_4= 0[/itex], [itex]a_5= 1/5\pi[/itex], etc.

Like wise [itex]cos(n\pi/2)= 0[/itex] if n is odd, [itex]cos(n\pi/2)= 1[/itex] if n is "congruent to 2 mod 4" (divisible by 2 but not by 4), and [itex]cos(n\pi/2)= -1[/itex] if n is "congruent to 0 mod 4" (divisible by 4). Notice that for all n, one of the [itex](2sin(n\pi)/2)/n\pi[/itex] or [itex]cos(n\pi/2)/n\pi[/itex] is 0 so you are not actually "subtracting".
 
  • #3
I can see the sequences that a(n) and b(n) make, but I can't write down a formula for them. I'm using trial and error really but I can't find any functions dependent on n that will describe the sequences a(n) and b(n) exactly. Is there a formula for caculating these type of functions?
 
  • #4
You said that a(n)= [tex]\frac{2sin\frac{n\pi}{2}}{n\pi}[/tex]

Since [itex]sin(n\pi/2)= 0[/itex] for n even, for a(n) to be non-zero, n must be of the form 2k+1 for some integer, k. But then [itex]sin(n\pi/2)= sin((2k+1)\pi/2)= sin(k\pi+ \pi/2)= 1[/itex] if k is even and -1 if k is odd. That is, [itex]sin((2k+1)\pi/2)= (-1)^k[/itex].

So a(n)= 0 if n is even and, if n is odd, n= 2k+1, [itex]a(n)= a(2k+1)= 2(-1)^k/(2k+1)\pi[/itex]. You could write the Fourier cosine series as
[tex]1+ \sum_{k=0}^\infty \frac{2(-1)^k}{(2k+1}\pi} cos((2k+1)x)[/itex].

The sine series, [itex]\sum b_n sin(nx)[/itex] is a little more complicated but the same idea.
 

What is a Fourier series and why is it used?

A Fourier series is a way to represent a periodic function as a sum of sine and cosine functions. It is used in many areas of science and engineering to analyze and model periodic phenomena, such as sound and electromagnetic waves.

How do you find the coefficients for a Fourier series?

To find the coefficients for a Fourier series, you can use the Fourier series formula or use integration techniques to solve for the coefficients. The specific method used may depend on the function being analyzed and the desired level of accuracy.

What is the difference between a Fourier series and a Fourier transform?

A Fourier series is used to represent a periodic function, while a Fourier transform is used to represent a non-periodic function. The Fourier transform also yields a continuous spectrum of frequencies, while the Fourier series only has discrete frequencies.

Can you use a Fourier series to approximate any function?

No, a Fourier series can only approximate periodic functions. For non-periodic functions, a different method, such as the Fourier transform, would be needed.

How can I check the accuracy of a Fourier series approximation?

The accuracy of a Fourier series approximation can be checked by evaluating the function at different points and comparing it to the approximation. The more terms included in the series, the closer the approximation will be to the original function.

Similar threads

Replies
4
Views
347
Replies
5
Views
384
Replies
11
Views
860
Replies
3
Views
1K
Replies
2
Views
1K
  • Calculus and Beyond Homework Help
Replies
1
Views
216
Replies
3
Views
1K
Replies
1
Views
934
  • Topology and Analysis
Replies
4
Views
274
Replies
2
Views
1K
Back
Top