How to Find Fourier Series for a Periodic Function?

Click For Summary

Homework Help Overview

The discussion revolves around finding the Fourier series for the periodic function f(x) = 2x + 1, defined on the interval from -π to π. Participants are exploring the characteristics of the function, including its periodicity and whether it is odd or even, as well as the implications for calculating the Fourier coefficients.

Discussion Character

  • Conceptual clarification, Assumption checking, Mathematical reasoning

Approaches and Questions Raised

  • Participants discuss the periodic nature of the function and its classification as odd or even, questioning the validity of their assumptions. There are attempts to compute the Fourier coefficients a0, ak, and bk, with some confusion regarding the sine and cosine series. The idea of restricting the function to a specific domain and extending it is also raised.

Discussion Status

There is an ongoing examination of the calculations for the Fourier coefficients, with some participants acknowledging potential errors in their previous work. A few participants have provided calculations and corrections, while others are still questioning the assumptions made about the function's properties.

Contextual Notes

Participants are working under the constraints of homework guidelines, which may limit the information available or the methods they can use. There is a focus on ensuring the function is treated correctly in terms of its periodicity and symmetry.

Kuma
Messages
129
Reaction score
0

Homework Statement



Given f(x) = 2x+1 periodic from -pi<x<pi. Find the Fourier series from (-pi to pi) as well as the sine series from [0, pi] and cosine series from (0,pi)

Homework Equations


The Attempt at a Solution



So since f(x) is periodic it is odd, so then a0 and ak = 0.

for bk:

bk = 1/pi int f(x) sin kx from -pi to pi.
skipping forward, I get bk = [(-1)^ k][-4/k]

now I am a bit confused about the sine and cosine series. I thought if f(x) was odd then it turns into a sine series automatically so isn't it basically the same thing as what I got?

And the cosine series should just be 0?
 
Physics news on Phys.org
Kuma said:
So since f(x) is periodic it is odd, so then a0 and ak = 0.
f isn't odd. For example, f(1) = 3 while f(-1) = -1. Clearly, f(1) ≠ -f(-1).

now I'm a bit confused about the sine and cosine series. I thought if f(x) was odd then it turns into a sine series automatically so isn't it basically the same thing as what I got?

And the cosine series should just be 0?
The idea is to restrict f to the domain [0, π] and then extend it so that it's an even or odd function on the interval [-π, π]. In other words, when -π≤x<0, you have f(x) = ±f(|x|).
 
vela said:
f isn't odd. For example, f(1) = 3 while f(-1) = -1. Clearly, f(1) ≠ -f(-1).The idea is to restrict f to the domain [0, π] and then extend it so that it's an even or odd function on the interval [-π, π]. In other words, when -π≤x<0, you have f(x) = ±f(|x|).

I thought when you have f(x+p) when its periodic it is just equal to f(x)?
Regardless I got ak and a0 as 0 even when I used f(x) = 2x+1

And shouldn't it be f(x) = f(-x)?

if x E [0,pi] then f(x) = 2x +1 and if x E [-pi,0], f(-x) = 2x+1??
 
Last edited:
Kuma said:
I thought when you have f(x+p) when its periodic it is just equal to f(x)?
If p is the period, then yes. But what does that have to do with anything about f being even or odd?

Regardless I got ak and a0 as 0 even when I used f(x) = 2x+1
All I can say is you got the wrong answer since you haven't shown your work.

And shouldn't it be f(x) = f(-x)?
Yes, if f is an even function.

if x E [0,pi] then f(x) = 2x +1 and if x E [-pi,0], f(-x) = 2x+1??
No, that's not right. Take ##x=+\pi/2 \in [0,\pi]## so ##f(\pi/2) = \pi+1##. Now take ##x=-\pi/2 \in [-\pi,0]##. You're saying ##f(-x) = 2x+1##, but you have
$$f(-x) = f(-(-\pi/2)) = f(\pi/2) = \pi+1$$ whereas
$$2x+1 = 2(-\pi/2) + 1 = -\pi + 1.$$ Clearly, f(-x) ≠ 2x+1.
 
Ok I figured it out. For the Fourier series I got ak and a0 as 0? But for the cosine series i did this
F(x) = f(x) for 0<x<pi
F(x) = -f(-x) for -pi<x<0

where f(x) = 2x+1

that results in an even function so I solved for a0 and ak from there.
 
How are you getting a0=0 for the regular Fourier series?
 
Oh yeah I made a calculation error i believe.

ao = 1/2pi int from pi to -pi 2x+1 dx
= 1/2pi (x^2 + x) from pi to -pi
= 1/2pi [pi^2 + pi - ((-pi)^2 -pi]
= 1

ak = 1/pi int 2x+1 cos kx dx from -pi to pi

u = 2x+1 dv = cos kx
du = 2 dx v = 1/k sin kx

x from -pi to pi
=1/pi[(2x+1 sin kx)/k) - 2/k int (sin kx) from -pi to pi]

= 1/pi[0 - 2/k (-1/k cos kx from -pi to pi)]
= 1/pi[2/k^2 (cos kx from -pi to pi)] = 0

that right?
 
Looks good.
 

Similar threads

  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 14 ·
Replies
14
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K
Replies
3
Views
2K
  • · Replies 6 ·
Replies
6
Views
2K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 16 ·
Replies
16
Views
2K
  • · Replies 2 ·
Replies
2
Views
1K