(Fourier Series) I'm confused as to why in the Mathematica documentation on Fourier Series, when you specify a coefficient you want it to solve for, it doesn't let you specify the bounds to evaluate it-how are you supposed to get a fourier coefficient without using bounds given to do so?!? http://reference.wolfram.com/language/ref/FourierCoefficient.html
(e.g. bounds to specify the periodicity of the given function, I don't see a place to specify the period)
im currently being hacked right now!
Sometimes I find it really hard to like you, dan. I'll talk to you later.
@Kainui
ok lets see
they are using complex representation of the fourier series, can u write that out
Yeah, either complex or trig, that's not what I'm asking about; I'm saying in the general form I don't see where the bounds are to establish the period of the function.
Alright, great, looks like he's not getting "Hacked!" anymore.
Yeah, I just don't see in the documentation how you can specify the period of a function, I see that you can specify the function itself, the variable of the given function, and the number of coefficients.
@Kainui , do you get what I'm saying.
I think I do, but I'm not sure. Can you give me an exact example of something you'd like to compute as an example so I understand what it is you want that you think you won't be able to receive?
Let's say the Fourier series of x, where -pi<x<pi. You need -pi and pi obviously to compute it.
It looks like you'll need to change the settings here http://reference.wolfram.com/language/ref/FourierParameters.html Honestly I am not very familiar with Mathematica, but I understand what you're interested in finding.
Fourier Parameters refers to the Fourier Transform.
I looked at that, too, thinking that was it, but it says in the heading that it's for the transform.
Gotta go to an exam, I'll talk to you later, and thank you, nonetheless.
Yeah good luck, I have no clue as far as Mathematica is concerned, sorry.
@phi
the coefficients are found by integrating from 0 to T , where T is the period of your periodic function... or any lower bound to upper bound that represents the period. It looks like mathematica assumes -pi/2 to +pi/2
Alright, so if you want to specify a bound that is different from -pi/2 to pi/2, you just need to use the Integrate [f(x),x] command?
And find the coefficient separately from using the FourierSeries commands?
What I'm trying to do is check my work for Fourier Series where there isn't a listed answer (my book has almost no answers, I'm okay with no solutions, but no answers makes everything kind of massively useless).
actually, it looks like {1,1} is the default and they say that means -pi to +pi
Wait, what? I didn't understand that. Can you change the default, or not? I couldn't figure it out from looking at the documentation,
You can tweak it
what exactly are you trying to check?
I think I figured out something that should partly do the job, if anybody interested comes across this: http://classes.engineering.wustl.edu/jemt3170/Mathematica%20-%20Fourier%20Series.pdf I'm taking a look at what you put, too. The problem with the FourierParams things that I don't understand is that there isn't an example with the FourierSeries command, only ones for the Fourier Transform.
Do you have Mathematica, or no? I really need to find someone who has this and knows how to use the software in general.
Now I just have more questions on top of the old ones.
Do you or do you not have Mathematica/have you used it a ton? it's absolutely fine if you haven't, I just want to know to think about what I probably can or cannot get.
I have used Matlab, and Sage (does stuff similar to mathematica, but its openware) I assume you did the example on page 5 It shows using the FourierParams
I can ask them in a separate thread if you want me to, but I have a bunch of questions relating to mathematica. On the document I just posted, I don't understand how the integrals on the second page or so at the top-in integral form and all, not code-are listed as input. How the hell did they get that as input? That makes no sense to me, that looks exactly like output.
My main goal here is not numerically calculating a fourier series to a certain number of terms, but finding the general coefficients in a fourier series for a given term over a given period
In[4], In[7], and In[8]
Can you duplicate the stuff on page 1 ?
Yeah, do you want me to? I don't understand how that would help with the page 2 stuff, but I'll definitely do it, one moment. And I'm also confused about the random gaps in between the input and output numbers, e.g. Out[4] to In[7]
I'm not sure why, but I got this: http://i.imgur.com/e2Jd6Uf.png I'll check out the very end now
I got a garbage page for the letter L, I think a link was bad or something.
extra comma
But what about the weblink? I'll fix the extra comma, but I got this for the webpage: http://i.imgur.com/obZmmfo.png Which I'm guessing is exactly not what you intended
no, I'm working on it. It's a pdf file I am trying to link to
Alright, replicated everything in the first page
now do In[4] I assume you have to type it as 1/(2*Pi) Integrate[ f[x] ...
I hope so, one sec.
Also, thank you so much for your help so far, this has been comparatively really productive.
What should I do about a_0 in In[4]? I haven't defined it and it doesn't appear to...oh well
I think you type a0= ?
This is what I did, and it was wrong, it looks like a O lowercase, so I'm not sure why it would be a0 instead of ao
they are just evaluating the first coefficient (which uses a different formula than for a1, a2, ...) I would try In[]:= x= 1/(2*Pi) Integrate(f[x], {x, -Pi, Pi} )
It says in the Mathematica documentation that a b and a*b are identical, but I'll try that
make that x[t], {t, -Pi, Pi}
It didn't like the parentheses, and when the parentheses were changed to brackets, it didn't work: http://i.imgur.com/ZWkgSjA.png
In[]:= a0= 1/(2 Pi) Integrate[ x[t], {t, -Pi, Pi} ]
One sec
Also the In[] stuff always shows up regardless of what you do, I don't believe it needs to be written, I don't think
No, it types the In[]:= but I assume you would not type that part.
(Lol, I wasn't sure, I was assuming you wouldn't put that in there then, my bad)
Partial success, it did evaluate correctly, but it evaluated immediately and didn't give me that input that looked like an integral and all that jazz in formal math rather than code; the good news is, I can at the very least do stuff, what I don't understand from the written code is how it knows what x[t] is, in my mind that's literally just like f(x), it's not a function, it's just the general notation for one
Hey, I think I might've figured it out
x[t] was still defined when you did the page 1 stuff
It might have to do with this: https://reference.wolfram.com/language/tutorial/FormsOfInputAndOutput.html http://reference.wolfram.com/language/tutorial/ExecutingNotebookCommandsDirectlyInTheFrontEnd.html
I know it somehow "delays" something, but I didn't understand what the difference would be in the first page had I left out the underscore in defining x, I mean, immediately thereafter I executed and got the graph, how would leaving the underscore out change things? I also can't thank you enough for this, this is a good conversation and I'm learning a lot at least about Mathematica.
I interpreted the t_ in x[t_] to mean x is a function of t, with t not yet being assigned a value.
For what its worth, here is the fourier series stuff
And had it been assigned a value, how would that change things? I'll go plug in otherwise, but I don't understand how with the graph at least it would've changed anything, nor how or when t was assigned a value. I'm not a programming person at all so I don't really know what I'm talking about, but how/when did we assign t a value, in the computer's eyes?
t gets assigned when you typed in {t, -Pi, Pi} inside the integrate operation
Alright, cool. I couldn't really interpret the stuff about the kernel and all, but did you figure out/see how to put the input like that? If not, it doesn't really matter at all, I can still do the exact same thing functionally, and that's what matters.
the "front-end" you are typing into can be a notebook. you would have to figure out how to start up the notebook
Alright, cool. Thanks for the help!
Join our real-time social learning platform and learn together with your friends!