# Can't Plot Fourier Series [closed]

I have been trying to plot fourier series but the plot is allways empty. I guess there is something wrong in my code but i dont know exactly what is it.

Looking here for some previous questions/answers I plotted the function in a lot of different ways but none of them worked.

Can someone help me with this :) ?

fx[n_, t_] := !( *UnderoverscriptBox[([Sum]), (i = (-n)), (n)](((Exp[ I*(((-1)*ima))*[Pi]]*((I*1 + ima*[Pi])) - 1))* Exp[I*ima*[Pi]*t]))

psums = Table[fx[n, t], {n, 1, 10}];

Plot[Evaluate[psums], {t, -4, 4}]

-

## closed as off-topic by Sjoerd C. de Vries, m_goldberg, Yves Klett, ciao, Michael E2Apr 27 '14 at 23:22

This question appears to be off-topic. The users who voted to close gave this specific reason:

• "This question arises due to a simple mistake such as a trivial syntax error, incorrect capitalization, spelling mistake, or other typographical error and is unlikely to help any future visitors, or else it is easily found in the documentation." – Sjoerd C. de Vries, m_goldberg, Yves Klett, ciao, Michael E2
If this question can be reworded to fit the rules in the help center, please edit the question.

Please provide your code as text rather than an image. It discourages people from helping you if you force them to retype something that you could easily have provided in the question. –  Oleksandr R. Apr 27 '14 at 18:29
Thanks for the reply, I added the code bellow. –  Emiliano Apr 27 '14 at 18:38
To view the real part or the imaginary part you can use: psums = Table[Re@fx[n, t], {n, 1, 10}]; or psums = Table[Im@fx[n, t], {n, 1, 10}]; –  Kardashev3 Apr 27 '14 at 18:40
The result is imaginary, your code is fine. –  Gregory Rut Apr 27 '14 at 18:40
Thanks for the replys, i had an error on the series expansion. ![enter image description here][1] [1]:i.imgur.com/xWakSVH.png –  Emiliano Apr 27 '14 at 18:46

To view the real part you can use:

psums1 = Table[Re@fx[n, t], {n, 1, 10}];
Plot[Evaluate[psums1], {t, -4, 4}, PlotRange -> All]


and to view the imaginary part you can use:

psums2 = Table[Im@fx[n, t], {n, 1, 10}];
Plot[Evaluate[psums2], {t, -4, 4}, PlotRange -> All]


-