Lesson-2 Discrete-time Sinusoids and sampling
Outlines 1 Discrete Time Sinusoidal signals 2. Sampling in time domain
Discrete Time Sinusoidal signals A discrete-time sinusoidal signal may be expressed as
x(n) = A cos(ωn + θ), −∞ < n < ∞ where n is an integer variable, called the sample number, A is the amplitude of the sinusoid, ω is the frequency in radians per sample, and θ is the phase in radians.
Example of a discrete-time sinusoidal signal (ω = π/6 and θ = π/3).
Discrete-time sinusoids are characterized by the following properties: Property 1:
A discrete-time sinusoid is periodic only if its frequency f is a rational number. Proof :
By definition, a discrete-time signal x(n) is periodic with period N(N > 0) if and only if x(n + N) = x(n) for all n The smallest value of N for which the above equation is true is called the fundamental period.
For a sinusoid with frequency f0 to be periodic, we should have
cos[2πf0(N + n) + θ] = cos(2πf0n + θ)
This relation is true if and only if there exists an integer k such that 2πf0N = 2kπ or, equivalently, f0 = k/N Therefore, a discrete-time sinusoidal signal is periodic only if its frequency f0 can be expressed as the ratio of two integers (i.e., f0 is rational).
How to determine the fundamental period N of a periodic sinusoid: Express its frequency f0 in the form f0= k/N and cancel common factors so that k and N are relatively prime. Then the fundamental period of the sinusoid is equal to N.
For example, f1 = 31/60 implies that N1 = 60, whereas f2 = 30/60 results in N2 = 2.
Example 2.1: Example 2.1 Determine whether the two following sinusoids are periodic or not. (a) x1 (n) cos 0.125 n
(b) x2 (n) cos 0.5n
(b) The digital frequency,
Solution: (a) The digital frequency,
0.125 1 f 2 16
Which is rational.
x1(n) is periodic of period 16.
0.5 1 f 2 4
Which is not rational.
x2(n) is not periodic . See the figure in the next slide
Property 2:
Discrete‐Time Harmonics Are Always Periodic in Frequency
In other words: Discrete‐time sinusoids whose frequencies are separated by an integer multiple of 2π are identical.
Proof: If we start with the sinusoid cos(ω0n) and add a multiple of 2π with ω0, we get,
cos[(0 2 k )n] cos (0 n 2 kn) cos (0 n)
This result says that discrete‐time (DT) sinusoids at the angular frequencies ω0 and ω0+2πk are identical.
It defines the principal period as,
0 Or, in terms of digital frequency,
1 1 f 2 2
Showing periodicity in frequency:
Observation: The first sinusoid has digital frequency, f1= 0.0265 The second sinusoid has digital frequency, f2= 1.0265 Any of them gives the same sinusoid !!!
Just f is increased by 1
Important Information 1. A DT sinusoid can be uniquely identified only if its frequency falls in the principal range. 2. A DT sinusoid with a frequency outside this range can always be expressed as a DT sinusoid with a frequency that falls in the principal period by subtracting out an integer.
Analog to digital and digital to analog conversion: Analog to digital conversion: To process analog signals by digital means, it is first necessary to convert them into digital form, that is, to convert them to a sequence of numbers having finite precision. This procedure is called analog-to-digital (A/D) conversion, and the corresponding devices are called A/D converters (ADCs).
Conceptually, we view A/D conversion as a three‐step process.
1.Sampling. 2.Quantization 3.Encoding
This process is illustrated in the following figure:
Sampling. This is the conversion of a continuous-time signal into a discrete-time signal obtained by taking “samples” of the continuous-time signal at discrete time instants. Thus, if xa(t) is the input to the sampler, the output is xa(nT ) ≡ x(n), where T is called the sampling interval.
Quantization. This is the conversion of a discrete-time continuous-valued signal into a discrete-time, discrete-valued (digital) signal. The value of each signal sample is represented by a value selected from a finite set of possible values. The difference between the unquantized sample x(n) and the quantized output xq(n) is called the quantization error.
Coding. In the coding process, each discrete value xq(n) is represented by a b-bit binary sequence.
In this lesson, we will study Sampling and the next lesson will illustrate the others.
Sampling: The Bridge from Continuous to Discrete Generally, sampling is considered as any process that records a signal at discrete instances. In this course , we restrict our attention to uniform sampling. In uniform sampling, sample values are equally spaced from one another by a fixed sampling interval T . The reciprocal of the sampling interval is called the sampling frequency (or sampling rate)
Fs=1/T,
which has units of hertz.
Periodic or uniform sampling: A type of sampling used most often in practice. This is described by the relation: x(n) = xa(nT ), −∞ < n < ∞ where x(n) is the discrete-time signal obtained by taking samples of the analog signal xa(t) every T seconds. The conversion is obtained by using simply
n t nT Fs
Illustrated in the figure shown in the next slide
Periodic sampling of an analog signal.
Sampling of an analog sinusoid: Consider an analog sinusoidal signal of the form x (t) = A cos(2πFt + θ) a
which, when sampled periodically at a rate Fs=1/T samples per second, yields, x (n )= x a (n T )
Here, we define the digital = A c o s(2 F n T ) frequency f as, F = A c o s(2 n) Fs
= A c o s(2 f n )
F f Fs
or, equivalently, as ω = ΩT
Relation between continuous frequency and discrete frequency
ω = ΩT
f = FT
Comparison of continuous frequency and discrete frequency
Continuous frequency
−∞ < F < ∞ −∞ < Ω< ∞
Discrete frequency
−1/2 < f <1/2 −π < ω <π
We get,
1 1 f 2 2 F 1 Fs 2
1 2
Fs Fs F 2 2 Fs F 2 Fs 2 | F |
The frequency FN=2|F| is called the Nyquist’s frequency Fs/2 is called the folding frequency.
A very important insight
where
Thus an infinite number of continuous-time sinusoids is represented by sampling the same discrete-time signal (i.e., by the same set of samples). Consequently, if we are given the sequence x(n), an ambiguity exists as to which continuous-time signal xa(t) these values represent. Equivalently, we can say that the frequencies
Fk = F0 +kFs , −∞ < k < ∞ (k integer)
are indistinguishable from the frequency F0 after sampling and hence they are aliases of F0.
To avoid aliasing we must sample the analog signal at least at Nyquist frequency, i.e., at least at twice the analog frequency.
Example 2.2
Solution:
Example 2.3
Solution:
Example 2.4
Solution:
(Aliasing and Its Effects)
Example 2.5
Solution: