Professional Documents
Culture Documents
| |
= +
|
\
Also, suppose one samples discretely at a sampling frequency fs = 15 Hz, i.e. 15 times per
second, or one sample every 1/15 = 0.06666... s.
A half second of both the signal and the discretely sampled data points is shown on the
graph below:
8
The aliasing is obvious - the perceived signal looks nothing like the original! In fact, the
apparent frequency of the inferred or perceived signal (formed by connecting the discrete
data points with straight line segments) is 5 Hz, and it is an odd-looking trapezoidal
waveform rather than a sine wave.
If the sampling frequency is greater than twice the actual frequency, there is no aliasing
frequeny.
9
For sampling frequencies less than twice the actual frequency, the aliasing frequency must
be calculated using the folding diagram. A summary of the procedure is given below:
o Calculate the folding frequency, 2
N s
f f =
o Locate
actual N
f f on the folding diagram, duplicated below:
o Note: For values of
actual N
f f greater than 4, the folding diagram can easily be
extended, following the obvious pattern.
o Read straight up from the value of
actual N
f f to obtain the value of
apparent N
f f on
the vertical axis.
10
What is the difference between aliasing and folding? Consider the following two cases:
o CASE 1: Aliasing.
Suppose we sample a continuous time signal
( )
0
( ) cos 2 x t A f t = + at a
sampling rate 2
s N
f f = . This generates the discrete-time signal
( )
0
[ ] cos 2
s
x N A f nT = + where 1
s s
T f = .
Now consider another sinusoid ( ) y t with the same amplitude and phase but
with a frequency
0 s
f kf + , where k is a positive or negative integer. Therefore,
( ) ( )
0
( ) cos 2
s
y t A f kf t = + + .
If we sample this waveform at a sampling rate
s
f , we obtain
( ) ( )
( )
0
0
1
0
[ ] cos 2
cos 2 2
cos 2 2
s s
s s s
s
y n A f kf nT
A f nT nk f T
A f nT nk
= + +
| |
= + +
|
|
\
= + +
The result is
( )
0
[ ] cos 2 [ ]
s
y n A f nT x n = + = !
As a result, [ ] y n is indistinguishable from [ ] x n , and we say that the frequencies
0 s
f kf + are aliases of
0
f .
11
o CASE 2: Folding.
This comes from the negative frequency component of the cosine wave.
Now consider another sinusoid ( ) y t with the same amplitude and opposite
phase but with a frequency
0 s
f kf + where k is a positive or negative integer.
Therefore,
( ) ( )
0
( ) cos 2
s
y t A f kf t = + .
If we sample this waveform at a sampling rate
s
f , we obtain
( ) ( )
( )
0
0
1
0
[ ] cos 2
cos 2 2
cos 2 2
s s
s s s
s
y n A f kf nT
A f nT nk f T
A f nT nk
= +
| |
= +
|
|
\
= +
The result is
( )
0
[ ] cos 2 [ ]
s
y n A f nT x n = + = since the cosine is an even
function, cos( ) cos( ) x x = .
As a result, [ ] y n is indistinguishable from [ ] x n , and we say that the
frequencies
0 s
f kf + are folded frequencies of
0
f .
12
Here is another example. For the same sine wave (10 Hz), the signal is plotted for 1
second. Data are sampled discretely at 11
s
f = Hz.
Note that the perceived signal looks like a sine wave at 1 Hz! In this case, the aliasing
frequency is, in fact, 1 Hz, i.e. 11 - 10 Hz.
One more example for the same sine wave (f = 10 Hz): Data are sampled discretely at fs =
9 Hz.
13
Note that the perceived signal also looks like a sine wave at 1 Hz! In this case, the
aliasing frequency is, in fact, 1 Hz, i.e., since
2
2
3
s
f f f < < ,
( )
9 10 1
a s
f f f Hz Hz = = =
14
5.6 Nyquist Theorem
The sampling rate theorem helps one avoid aliasing. The sampling rate theorem is stated
as follows:
To avoid aliasing, the sampling frequency must be greater than twice the highest
frequency component of the analog signal.
Some references call this the Nyquist theorem, and that the Nyquist criterion must be
met in order to avoid aliasing. The Nyquist criterion can be stated as follows:
To avoid aliasing, one must sample at a frequency at least twice the highest frequency
component of the analog signal.
15
5.7 Signal Reconstruction
If the Nyquist criterion is followed, one can theoretically reconstruct the original analog
waveform from a set of discrete samples.
This is accomplished using the cardinal series. If there are an infinite number of discrete
samples, the cardinal series will reconstruct the waveform exactly. In practice, however,
with only a finite number of samples available, the cardinal series will still do a fairly
good job of reconstructing the original signal. For N discrete samples, the cardinal series
is
( )
1
0
sin
1
( )
N
d
n
t
n
t
f t f n t
t
n
t
=
(
| |
|
(
\
=
| |
where t is time (assuming that the signal starts at t = 0), n is the sample number (the
summation is over all N discrete samples), ( ) f t is the reconstructed waveform, N is the
total number of discrete samples available, 1
s
t f = is the time period between
discrete samples, and for the n
th
discretely sampled data point,
( )
d
f n t is the discretely
sampled value.
16
Example - The function
( ) ( )
( ) sin 2 10 0.2sin 2 6
a
f t t t = + represents a superposition of
two sine waves, the primary one at 10 Hz, and the secondary one at 6 Hz. The 6 Hz wave
has an amplitude of 0.2, while the 10 Hz wave has an amplitude of 1.0. Discrete data
were acquired at 25 Hz, which exceeds the Nyquist criterion. Samples were acquired for
0.6 seconds (a total of N = 16 discrete data points). A plot of the actual (analog) signal,
( )
a
f t , the discrete samples, and the reconstructed waveform, ( ) f t appears below:
Taken alone, the discrete values (red dots) do not appear to contain enough information to
reconstruct the original signal, but as can be seen, the cardinal series reconstruction is
excellent, and deviates significantly only near the end points of the time span.
The cardinal series will not work properly if the Nyquist criterion is not satisfied.