328 Practical MATLAB® Applications for Engineers
b. If f(t) = −f(−t), indicating that f(t) is an odd function with respect to t, thenft() bnsin(nwt 0 )
n∑
whereb
T
n ft nwtdt nT
4
0
02
()sin( )
∫ for 1, and all the coefficients an^0− 4 − 2 0 2 4− 1−0.500.511.522.533.54nw 0 (rad/s)Line spectrum− 4 − 2 0 2 4− 3− 2− 10123456nw 0 (rad/s)Angle ofFn(rad)Phase spectrumAmplitude ofFnFIGURE 4.1
Plots of line spectrum.
− 4 − 2 0 2 4− 1−0.500.511.522.533.54nw 0 (rad/s)Magnitude ofFnMagnitude spectrum− 4 − 2 0 2 4− 1012345678910nw 0 (rad/s)mag (Fn(^2) )
(w
)
Power spectrum (for T = 1)
FIGURE 4.2
Plots of magnitude and power spectrum.