Lecture2 1
Lecture2 1
Time Signals ➔ ➔
Systems
Convolution
Frequency Fourier series
Fourier transforms
Frequency response
Generalized z / Laplace Transforms
Frequency
Transfer Functions
System Stability
Mixed Signal Sampling
1-2
Periodic Signals
• A signal has period T if x(t + T) = x(t) for all t
Also periodic with periods 2T, 3T, etc., and –T, –2T, etc.
Smallest positive period is called the fundamental period
• Signal cos(2 p f0 t + f) has period T0 = 1 / f0
Using cosine property cos(x + 2p) = cos(x),
cos(2p f0 (t + T0) + f) = cos(2p f0 t + 2p f0 T0 + f) = cos(2p f0 t + f)
when 2p f0 T0 = 2p or when f0 T0 = 1 or when T0 = 1 / f0
5 cos(2p f0 t)
t t
-1 -1/2 0 1/2 1 3/2 -1 -1/2 0 1/2 1 3/2
Ts = 1/100;
rect(t+1/2) Shift to
1
t = -1.5 : Ts : 2.5;
the left x = rectpuls(t-1);
plot(t, x);
t ylim( [-0.5 1.5] );
-1 -1/2 0 1/2 1 3/2
2-4
Phase Shift
• For sinusoidal signals, time shift causes phase shift
x0(t) = A cos(2 p f0 t) cos(2p 440 t + 2p)
x0(t - t1) = A cos(2 p f0 (t – t1)) = A cos(2 p f0 t – 2 p f0 t1) = cos(2p 440 t)
Time shift of t1 causes phase shift of f = –2 p f0 t1
• Initial interpretation of this phase shift
Positive time shift causes negative phase shift
Negative time shift causes positive phase shift
• Phase shift: ambiguity of multiples of 2p f0 = 440;
Due to cosine property cos(x + 2p) = cos(x) fs = 24*f0;
Ts = 1/fs;
Each multiple of 2p corresponds to picking t = 0 : Ts : 4/f0;
different peak x = cos(2*pi*f0*t);
plot(t, x);
2-5
Sampling
• Many signals originate as continuous-time signals, e.g.
voice or conventional music
• Sample continuous-time signal at equally-spaced points in
time to obtain discrete-time signal
y[n] = y(n Ts)
n {…, -2, -1, 0, 1, 2,…} y[n]
Ts is sampling period Ts
• Sinusoidal signal 3 4 5 6 7
n
1 2
y (t ) = A cos(2 p f 0 t + f )
y(t)
y[n] = y (n Ts ) = A cos(2 p f 0 Ts n + f )
2-6
Ts = 0.0050s
Plotting Signals fs = 200Hz = 5f0
5 samples/cycle
• Sample signals before plotting them
in Matlab
x(t) = 20 cos(2p 40 t – 0.4p)
Ts = 0.0025s
Uniformly sample at points in
fs = 400Hz = 10f0
continuous time t = n Ts : 10 samples/cycle
x(nTs) = 20 cos(80p nTs – 0.4p)
• How small does Ts have to be in
order to produce an accurate plot?
Ts = 0.0001s
fs = 10kHz = 250f0
f0 = 40; Ts = 0.0001;
250 samples/cycle
t = -0.03 : Ts : 0.045;
x = 20*cos(2*pi*f0*t - 0.4*pi);
figure; plot(t, x);
hold; stem(t, x);
2-7