Fourier Series: How to interpret the function?

13 replies · 2K views · last reply
NicolaiTheDane
Messages
100
Reaction score
10
This is a rather simple question, but am I understanding the following correctly?

1. Homework Statement

Printed definition: f is the 2π-periodic function with f(x) = x for all x in [0, π) ∪ [3π, 4π).


The Attempt at a Solution


Maple session defining f as the piecewise function x for 0 ≤ x < π and x for 3π ≤ x < 4π, with its plot over 0 to 4π: a rising segment from 0 to π, zero from π to 3π, then a rising segment from 3π to 4π.


This isn't really the problem, but I have a feeling my problem the assignments, is me misunderstanding the function description. I don't see how this 2 pi periodic, but I also do not understand how else to interpret it.
 
Attachments
  • Printed definition: f is the 2π-periodic function with f(x) = x for all x in [0, π) ∪ [3π, 4π).
    upload_2018-11-7_14-1-54.png
    3.1 KB · Views: 752
  • Maple session defining f as the piecewise function x for 0 ≤ x < π and x for 3π ≤ x < 4π, with its plot over 0 to 4π: a rising segment from 0 to π, zero from π to 3π, then a rising segment from 3π to 4π.
    upload_2018-11-7_14-2-13.png
    10.9 KB · Views: 921
So it's ##4\pi## periodic, a simple typo. What comes after your snippet ?
 
BvU said:
So it's ##4\pi## periodic, a simple typo. What comes after your snippet ?

I should have mentioned that it is dealing with Fourier series, so it HAS to be ##2*\pi## periodic. Is it correct to assume, that I then have to make it that way. That is fill in the span between ##(\pi,3*\pi)## in such a way as to make the fuction into a ##2*\pi## function?
 
What comes after your snippet ? O, I asked that already...

NicolaiTheDane said:
it HAS to be ##2*\pi## periodic
So, compress with ##x'= x/2## and proceed with ##x'##
 
BvU said:
What comes after your snippet ? O, I asked that already...So, compress with ##x'= x/2## and proceed with ##x'##

Doing that wouldn't fit with the last part of the interval. As for the other assignments:

Printed question: ii) Is f continuous? If not, find all the points where f is discontinuous.


This is easily shown using a Theorem in my book, and the points seem to be ##n*\pi, n = 1,2,3..## Now ofc this is only right if my assumption about function is correct (not the one I have written above), which is:
Maple plot of a sawtooth-like function on 0 to 4pi with jumps at pi, 2pi and 3pi; a piecewise definition for f(x) is shown beside it, with f(x)=x on [0,pi), x+2pi on [pi,2pi), x-2pi on [2pi,3pi) and x on [3pi,4pi).


However this is what I aren't sure about, but its the only option that I can think of, which also satisfies the next assignment

Printed question: iii) Is the Fourier series for f convergent at x = 0 and x = π? If so, calculate the sum.


Now I know this part has to be ##2*\pi##. Assuming that it means the sum at the mentioned discontinousities, this would be mean:

$$\frac{1}{2}*a_0 + \sum_{n=0}^\infty \left(a_n*\cos(x_0*n)+b_n*\sin(x_0*n) \right) = \frac{1}{2}*\left(\lim_{n \rightarrow +x} {x_0} + \lim_{n \rightarrow -x} {x_0}\right)$$

Which means the sum for each point is just the limit going from both sides added and divided by 2. If my assumption is correct, then both at ##\pi## and at ##0## the sum becomes ##2*\pi## as it should. However like I said at the very beginning, my problem is whether I understand how to interpret the function correctly or not.
 
Attachments
  • Printed question: ii) Is f continuous? If not, find all the points where f is discontinuous.
    upload_2018-11-7_20-31-4.png
    1.4 KB · Views: 410
  • Printed question: iii) Is the Fourier series for f convergent at x = 0 and x = π? If so, calculate the sum.
    upload_2018-11-7_20-32-32.png
    1.6 KB · Views: 417
  • Maple plot of a sawtooth-like function on 0 to 4pi with jumps at pi, 2pi and 3pi; a piecewise definition for f(x) is shown beside it, with f(x)=x on [0,pi), x+2pi on [pi,2pi), x-2pi on [2pi,3pi) and x on [3pi,4pi).
    upload_2018-11-7_20-33-31.png
    6.1 KB · Views: 511
Assuming we are talking about the function in post #5, you are thinking correctly but expressing it poorly. You have the given function ##f(x)## and its FS. Let's call the sum of the FS ##s(x)##. What you have is that ##f(x) = s(x)## at all points where ##f## is continuous. At any points where ##f## has a step discontinuity (##n\pi## in this case) the theorem you are using might be better stated that$$
s(n\pi) =\frac{ \lim_{x\to n\pi^+} f(x) + \lim_{x\to n\pi^-} f(x)}{2} = 2\pi $$The right side of your last equation doesn't make much sense.
 
  • Like
Likes   Reactions: NicolaiTheDane
NicolaiTheDane said:
I should have mentioned that it is dealing with Fourier series, so it HAS to be ##2*\pi## periodic. Is it correct to assume, that I then have to make it that way. That is fill in the span between ##(\pi,3*\pi)## in such a way as to make the fuction into a ##2*\pi## function?

No, it does NOT have to be ##2\pi## periodic; it just needs to be periodic. If it is periodic with period ##T## (say on a base interval ##[a,a+T]##) then there are standard formulas for the Fourier series and its coefficients. Every textbook has this material, and a Google search of "Fourier series" will produce many web pages giving the details.
 
Well, one thing I learned from this thread was the discont = 'true' option in Maple when plotting piecewise continuous functions to get nice plots including correct end points:
> restart: with(plots):
> f := piecewise(0 <= x and x <= 1, 1, x > 1 and x <= 3, x-1);
> plot(f, x = -1 .. 4, discont = 'true', scaling = constrained);
Plot of a piecewise function on x from -1 to 4 and y from 0 to 2: a horizontal segment at y = 1 for 0 to 1, then a line rising from (1, 0) to (3, 2), with open and closed endpoint markers.

Complete with the dots in the right places. Thanks to @NicolaiTheDane
 
Attachments
  • Plot of a piecewise function on x from -1 to 4 and y from 0 to 2: a horizontal segment at y = 1 for 0 to 1, then a line rising from (1, 0) to (3, 2), with open and closed endpoint markers.
    piecewise.jpg
    5.2 KB · Views: 728
Last edited:
LCKurtz said:
Well, one thing I learned from this thread was the discont = 'true' option in Maple when plotting piecewise continuous functions to get nice plots including correct end points:
> restart; with(plots);
> f := piecewise(0 <= x and x <= 1, 1, `and`(x > 1, x <= 3), x-1);
> plot(f, x = -1 .. 4, discont = 'true', scaling = constrained);
View attachment 233610
Complete with the dots in the right places. Thanks to @NicolaiTheDane

Happy i could give something back, even if its trivial xD

Ray Vickson said:
No, it does NOT have to be ##2\pi## periodic; it just needs to be periodic. If it is periodic with period ##T## (say on a base interval ##[a,a+T]##) then there are standard formulas for the Fourier series and its coefficients. Every textbook has this material, and a Google search of "Fourier series" will produce many web pages giving the details.

I don't doubt your right, you shown me on other occations you know your stuff. However it hasn't been covered in the lectures, and assignments never demand that we know something, that hasn't been covered. That said do you think its wrong to assume as I did in post #5?
 
NicolaiTheDane said:
Happy i could give something back, even if its trivial xD
I don't doubt your right, you shown me on other occations yoIf
NicolaiTheDane said:
Happy i could give something back, even if its trivial xD
I don't doubt your right, you shown me on other occations you know your stuff. However it hasn't been covered in the lectures, and assignments never demand that we know something, that hasn't been covered. That said do you think its wrong to assume as I did in post #5?

I am responding to your original problem in post #1, where you have a period of ##4 \pi.## BVU in post #4 showed you how to do it, but in case you did not understand his answer, let me expand on it a little bit. You have some function ##f(t)## defined on ##[0,4 \pi]##, whose Fourier series you want. However, you only know how to get Fourier series for functions on ##[0, 2 \pi].## You can set ##t = 2 \tau## and define ##g(\tau) = f(2\tau)##, ##\tau \in [0,2 \pi].## Now just get the Fourier series for ##g(\tau).## Then put back ##\tau = t/2## in the final ##\tau##-series formula.

Basically, that is how everybody obtains Fourier series on intervals like ##t \in [a , a+T]##: just let
$$ t = a + \frac{b}{2 \pi} \tau$$ and then use the standard Fourier formulas for ##\tau \in [0, 2 \pi].## Once you have done that, put back the definition of ##\tau## in terms of ##t## to get the formula for the Fourier series in terms of the original variable ##t.##
 
Last edited:
NicolaiTheDane said:
Doing that wouldn't fit with the last part of the interval
How so ?

And: What comes after your snippet ? O, I asked that already... twice
Please show the full problem statement, or better: type it
 
BvU said:
How so ?

And: What comes after your snippet ? O, I asked that already... twice
Please show the full problem statement, or better: type it

It doesn't fit, because the assignment clearly states, that the function is ##2\cdot\pi## periodic. If you simply rewrite the equation to be so, on the first ##\pi## interval by half stepping, the function does not fit on ##(3\cdot\pi,4\cdot\pi)## as the function value will be still have to be ##f(3\cdot\pi) = 3\cdot\pi## for example, as it is defined to be ##f(x)=x## on that interval. The only way to make it fit the ##2\cdot\pi## periodic scheme, AND fit with the given intervals for ##x##, is to treat it as 2 halves of a ##2\cdot\pi## periodic, thus leading to what I showed in post #5

However if you don't think that's right (and I think its silly my course leader thinks its funny to make the problem statements intentionally vague), doing half steps won't fit the solutions provided for assignment (ii) and (iii), which are:

(ii) ##n\cdot\pi, n\in\mathbb{N}##
(iii) ##2\cdot\pi##

As per your asking for what comes after BvU. I do not want to be rude, but I have already shown you all there is. I even say "as for the other assignments" in post #5. I left out assignment (i), because its merely asking me to sketch the graph, but that is it. For convenience I'll show it all in one snip.

Printed problem statement: Problem A. Let f be the 2π-periodic function given by f(x) = x for all x in [0, π[ ∪ [3π, 4π[. Parts (i) sketch the graph of f, (ii) is f continuous, and (iii) is the Fourier series convergent at x = 0 and x = π.
 
Attachments
  • Printed problem statement: Problem A. Let f be the 2π-periodic function given by f(x) = x for all x in [0, π[ ∪ [3π, 4π[. Parts (i) sketch the graph of f, (ii) is f continuous, and (iii) is the Fourier series convergent at x = 0 and x = π.
    upload_2018-11-8_10-6-31.png
    8.8 KB · Views: 385
NicolaiTheDane said:
I do not want to be rude
No offence taken; thanks. You even provide the solution -- which is great: it can sometimes unveil what was intended.

From that solution I favour the picture in #5 over that in #1: it satisfies the answers (both of them)!

How the intended function follows from ## f(x) = x \quad\forall \ x\in [0,\pi[ \; \cup \; [3\pi, 4\pi [ \ \ ## is a mystery to me. Perhaps something to do with the left "[" instead of the right "]", but I doubt it.

That function description, when interpreted as in #1 falls short anyway: it doesn't tell you what the function value is for ##x\in [\pi,\;3\pi]## and you have to assume something (like 0 as you did).

Assuming 0, the exercise can still be done, but the answers come out different ( I think :rolleyes: ):
(ii) ##n\pi\cup (2n+1)\pi##
(iii) ##2\pi## and ##\pi/2##
 
BvU said:
No offence taken; thanks. You even provide the solution -- which is great: it can sometimes unveil what was intended.

From that solution I favour the picture in #5 over that in #1: it satisfies the answers (both of them)!

How the intended function follows from ## f(x) = x \quad\forall \ x\in [0,\pi[ \; \cup \; [3\pi, 4\pi [ \ \ ## is a mystery to me. Perhaps something to do with the left "[" instead of the right "]", but I doubt it.

That function description, when interpreted as in #1 falls short anyway: it doesn't tell you what the function value is for ##x\in [\pi,\;3\pi]## and you have to assume something (like 0 as you did).

Assuming 0, the exercise can still be done, but the answers come out different ( I think :rolleyes: ):
(ii) ##n\pi\cup (2n+1)\pi##
(iii) ##2\pi## and ##\pi/2##

Exactly what I got as well. Honestly I'll be having a chat with my course leader on monday, as this isn't the first time he is intentionally vague, or outright deceptive in his assignment descriptions. Thanks for all the inputs though, I'll make an additional reply, if it turns out he meant something completely different.
 
  • Like
Likes   Reactions: BvU