Complex fourier series coefficients

Sorry if this is in the wrong section. I just saw some other fourier qns in here so thought it might go in here.

Just need some homework help (not assessed)

So first part of the question is to write the coefficient c_n, of the periodic function,

f(t) = cos(1/2pi*t) for |t|< 1 and f(t) = 0 for 1<|t|< T/2, where T= period

so from the definition of c_n, i obtained the integral from [-1,1]

$\displaystyle c_n= 1/T \int cos(\frac{\pi}{2}t)e^{-inwt} dt $

by using integration by parts twice,

I arrived at

$\displaystyle c_n= \frac{1}{(4(inw)^2-\pi^2)T} (e^{inw}+e^{-inw}) =\frac{ 2cos(nw)}{(4(inw)^2-\pi^2)T}$

I am pretty sure this is correct ( Please correct me if iam wrong)

But the second question asks to wirte cos(pi/2t) in terms of complex exponentials and perform integration to find c_n as a function of w_n=(2pi)n/T and T.

I am not really sure what they are asking. Do they want me to find $\displaystyle \hat{f}(w_n)=Tc_n$?

Re: Complex fourier series coefficients

What they are asking you to do is to use the fact that $\displaystyle cos(x)= \frac{e^{ix}+ e^{-ix}}{2}$ so that your integral can be written entirely in terms of the exponential.

Re: Complex fourier series coefficients

So does that mean i didnt have to really do the first part of the question?

They say at the end comment on the features of $\displaystyle \hat{f(w_n)}}=Tc_n$ as a function of $\displaystyle w_n$