- #1
Captain1024
- 45
- 2
Homework Statement
Link: http://i.imgur.com/klFmtTH.png
Homework Equations
[itex]a_0=\frac{1}{T_0}\int ^{T_0}_{0}x(t)dt[/itex]
[itex]a_n=\frac{2}{T_0}\int ^{\frac{T_0}{2}}_{\frac{-T_0}{2}}x(t)cos(n\omega t)dt[/itex]
[itex]\omega =2\pi f=\frac{2\pi}{T_0}[/itex]
The Attempt at a Solution
Firstly, x(t) is an even function because x=1/2 when [itex]t=-t_0[/itex] and [itex]t=t_0[/itex]. Therefore, all bn coefficients of the Fourier series will be zero.
[itex]T_0=4, \omega =\frac{2\pi}{4}=\frac{\pi}{2}, t_0=1[/itex]
a0 is basicly the average value of x(t) over the period. By inspection a0 = 2/4 = 1/2
It makes sense to me to split up x(t) into regions:
x(t) = 0 when [itex]\frac{-T_0}{2}<t<-t_0, t_0<t<\frac{T_0}{2}[/itex]
x(t) = 1/2 when [itex]t=^+_-t_0[/itex]
x(t) = 1 when [itex]-t_0<t<t_0[/itex]
[itex]a_n=\frac{2}{T_0}[\frac{1}{2}\int ^{-t_0}_{-t_0}cos(n\omega t)dt+\int ^{t_0}_{-t_0}cos(n\omega t)dt+\frac{1}{2}\int ^{t_0}_{t_0}cos(n\omega t)][/itex]
[itex]=\frac{2}{n\omega T_0}(1+[sin(\frac{\pi}{2}nt)]^{t_0}_{-t_0})[/itex]
[itex]=\frac{2}{n\omega T_0}[1+(sin(\frac{\pi}{2}nt_0)-sin(\frac{-\pi}{2}nt_0)][/itex]
[itex]=\frac{2}{n\omega T_0}[1+2sin(\frac{\pi n}{2})][/itex]
[itex]a_0=\frac{1}{2}, a_1=\frac{3}{\pi}, a_2=\frac{1}{2\pi}, a_3=\frac{-1}{3\pi}, a_4=\frac{1}{4\pi}, a_5=\frac{3}{5\pi}, a_6=\frac{1}{6\pi}[/itex]
(1) asks for coefficients in exponential and trigonometric forms. Are the coefficients I calculated above correct for either of those forms? How do I get the coefficients in the other form?
(2) & (3) ask for a MatLab plots. We haven't gone over any MatLab in class. If someone could point me in the right direction I think I can figure it out. I've worked with MatLab in the past.
Thanks for your time.
-Captain1024