PRACTICAL MATLAB® FOR ENGINEERS PRACTICAL MATLAB

(sharon) #1

342 Practical MATLAB® Applications for Engineers


^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Nyquist default points
w real[H(w)] imag[H(w)]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

ans =
1.0e+003 *
0 0.0010 0
0.0001 0.0010 -0.0001
0.0001 0.0010 -0.0001
0.0001 0.0010 -0.0001
............................................................
0.0010 0.0010 -0.0011
0.0011 0.0009 -0.0012
............................................................
0.0014 -0.0003 -0.0017
0.0015 -0.0004 -0.0016
............................................................
0.0031 -0.0002 0.0000
0.0036 -0.0001 0.0000
............................................................
0.0202 -0.0000 0.0000
............................................................
0.5356 -0.0000 0.0000
0.6261 -0.0000 0.0000
0.7318 -0.0000 0.0000
0.8555 -0.0000 0.0000
1.0000 -0.0000 0.0000
***********************************

R.4.70 The MATLAB command F = fourier (f, x) returns the FT of f (denoted by f(t) → F(w)),
where f is given as a symbolic object.


R.4.71 For example, use MATLAB to obtain the FT of the following time functions:


a. f1(t) = cos(3t)
b. f2(t) = cos(3t + π/4), and factor F2(w)
c. f3(t) = sin(3t)
d. f4(t) = 1/t
e. f5(t) = e−tu(t), and pretty F5(w)
f. f6(t) = t  e−tu(t)
g. f7(t) = e−[t]
h. f8(t) = Pul 2 (t) = u(t + 1) − u(t − 1)
i. f9(t) = u(t)

MATLAB Solution[[TI1]]
>> syms t w
>> F1 = fourier(cos(3*t)) % part (a)
Free download pdf