Connexions

You are here: Home » Content » Digital Signals and Their Transforms

Recently Viewed

This feature requires Javascript to be enabled.

Digital Signals and Their Transforms

In this lab, we learn how to compute the continuous-time Fourier transform (CTFT), normally referred to as Fourier transform, numerically and examine its properties. Also, we explore noise cancellation and amplitude modulation as applications of Fourier transform.

In the previous labs, different mathematical transforms for processing analog or continuous-time signals were covered. Now let us explore the mathematical transforms for processing digital signals. Digital signals are sampled (discrete-time) and quantized version of analog signals. The conversion of analog-to-digital signals is implemented with an analog-to-digital (A/D) converter, and the conversion of digital-to-analog signals is implemented with a digital-to-analog (D/A) converter. In the first part of the lab, we learn how to choose an appropriate sampling frequency to achieve a proper analog-to-digital conversion. In the second part of the lab, we examine the A/D and D/A processes.

Sampling and Aliasing

Sampling is the process of generating discrete-time samples from an analog signal. First, it is helpful to mention the relationship between analog and digital frequencies. Consider an analog sinusoidal signal x(t)=Acos(ωt+φ)x(t)=Acos(ωt+φ) size 12{x $$t$$ =A"cos" $$ωt+φ$$ } {}. Sampling this signal at t=nTst=nTs size 12{t= ital "nT" rSub { size 8{s} } } {}, with the sampling time interval of TsTs size 12{T rSub { size 8{s} } } {}, generates the discrete-time signal

x[n]=Acos(ωnTs+φ)=Acos(θn+φ),n=0,1,2,...,x[n]=Acos(ωnTs+φ)=Acos(θn+φ),n=0,1,2,..., size 12{x $n$ =A"cos" $$ω ital "nT" rSub { size 8{s} } +φ$$ =A"cos" $$θn+φ$$ , matrix { {} # n=0,1,2, "." "." "." ,{} } } {}
(1)

where θ=ωTs=2πffsθ=ωTs=2πffs size 12{θ=ωT rSub { size 8{s} } = { {2πf} over {f rSub { size 8{s} } } } } {} denotes digital frequency with units being radians (as compared to analog frequency ω with units being radians/second).

The difference between analog and digital frequencies is more evident by observing that the same discrete-time signal is obtained from different continuous-time signals if the product ωTsωTs size 12{ωT rSub { size 8{s} } } {} remains the same. (An example is shown in Figure 1.) Likewise, different discrete-time signals are obtained from the same analog or continuous-time signal when the sampling frequency is changed. (An example is shown in Figure 2.) In other words, both the frequency of an analog signal ff size 12{f} {} and the sampling frequency fsfs size 12{f rSub { size 8{s} } } {} define the digital frequency θθ size 12{θ} {}of the corresponding digital signal.

It helps to understand the constraints associated with the above sampling process by examining signals in the frequency domain. The Fourier transform pairs for analog and digital signals are stated as

 Fourier transform pair for analog signals { X ( jω ) = ∫ − ∞ ∞ x ( t ) e − jωt dt x ( t ) = 1 2π ∫ − ∞ ∞ X ( jω ) e jωt dω { X ( jω ) = ∫ − ∞ ∞ x ( t ) e − jωt dt x ( t ) = 1 2π ∫ − ∞ ∞ X ( jω ) e jωt dω size 12{ left lbrace matrix { X $$jω$$ = Int rSub { size 8{ - infinity } } rSup { size 8{ infinity } } {x $$t$$ e rSup { size 8{ - jωt} } ital "dt"} {} ## x $$t$$ = { {1} over {2π} } Int rSub { size 8{ - infinity } } rSup { size 8{ infinity } } {X $$jω$$ e rSup { size 8{jωt} } dω} } right none } {} Fourier transform pair for discrete signals { X ( e jθ ) = ∑ n = − ∞ ∞ x [ n ] e − jn θ , θ = ωT s x [ n ] = 1 2π ∫ − π π X ( e jθ ) e jn θ dθ { X ( e jθ ) = ∑ n = − ∞ ∞ x [ n ] e − jn θ , θ = ωT s x [ n ] = 1 2π ∫ − π π X ( e jθ ) e jn θ dθ size 12{ left lbrace matrix { X $$e rSup { size 8{jθ} }$$ = Sum cSub { size 8{n= - infinity } } cSup { size 8{ infinity } } {x $n$ e rSup { size 8{ - ital "jn"θ} } } matrix { , {} # θ=ωT rSub { size 8{s} } {} } {} ## x $n$ = { {1} over {2π} } Int rSub { size 8{ - π} } rSup { size 8{π} } {X $$e rSup { size 8{jθ} }$$ e rSup { size 8{ ital "jn"θ} } dθ} } right none } {}

As illustrated in Figure 3, when an analog signal with a maximum bandwidth of WW size 12{W} {}(or a maximum frequency of fmaxfmax size 12{f rSub { size 8{"max"} } } {}) is sampled at a rate of Ts=1fsTs=1fs size 12{T rSub { size 8{s} } = { {1} over {f rSub { size 8{s} } } } } {}, its corresponding frequency response is repeated every size 12{2π} {} radians, or fsfs size 12{f rSub { size 8{s} } } {}. In other words, the Fourier transform in the digital domain becomes a periodic version of the Fourier transform in the analog domain. That is why, for discrete signals, one is interested only in the frequency range 0,fs/20,fs/2 size 12{ left [0,f rSub { size 8{s} } /2 right ]} {}.

Therefore, to avoid any aliasing or distortion of the discrete signal frequency content and to be able to recover or reconstruct the frequency content of the original analog signal, we must have fs2fmaxfs2fmax size 12{f rSub { size 8{s} } >= 2f rSub { size 8{"max"} } } {}. This is known as the Nyquist rate. The sampling frequency should be at least twice the highest frequency in the analog signal. Normally, before any digital manipulation, a front-end anti-aliasing lowpass analog filter is used to limit the highest frequency of the analog signal.

Let us further examine the aliasing problem by considering an undersampled sinusoid as depicted in Figure 4 . In this figure, a 1 kHz sinusoid is sampled at fs=0.8fs=0.8 size 12{f rSub { size 8{s} } =0 "." 8} {}kHz, which is less than the Nyquist rate of 2 kHz. The dashed-line signal is a 200 Hz sinusoid passing through the same sample points. Thus, at the sampling frequency of 0.8 kHz, the output of an A/D converter is the same if one uses the 1 kHz or 200 Hz sinusoid as the input signal. On the other hand, oversampling a signal provides a richer description than that of the signal sampled at the Nyquist rate.

Quantization

An A/D converter has a finite number of bits (or resolution). As a result, continuous amplitude values get represented or approximated by discrete amplitude levels. The process of converting continuous into discrete amplitude levels is called quantization. This approximation leads to errors called quantization noise. The input/output characteristic of a 3-bit A/D converter is shown in Figure 5 to illustrate how analog voltage values are approximated by discrete voltage levels.

Quantization interval depends on the number of quantization or resolution levels, as illustrated in Figure 6. Clearly the amount of quantization noise generated by an A/D converter depends on the size of the quantization interval. More quantization bits translate into a narrower quantization interval and, hence, into a lower amount of quantization noise.

In Figure 6, the spacing Δ between two consecutive quantization levels corresponds to one least significant bit (LSB). Usually, it is assumed that quantization noise is signal-independent and is uniformly distributed over –0.5 LSB and 0.5 LSB. Figure 7 also shows the quantization noise of an analog signal quantized by a 3-bit A/D converter and the corresponding bit stream.

A/D and D/A Conversions

Because it is not possible to have an actual analog signal within a computer programming environment, an analog sinusoidal signal is often simulated by sampling it at a very high sampling frequency. Consider the following analog sine wave:

x(t)=cos(1000t)x(t)=cos(1000t) size 12{x $$t$$ ="cos" $$2π"1000"t$$ } {}
(2)

Sample this sine wave at 40 kHz to generate 0.125 seconds of x(t)x(t) size 12{x $$t$$ } {}. Note that the sampling interval, seconds, is very short, so x(t)x(t) size 12{x $$t$$ } {} appears as an analog signal.

Sampling involves taking samples from an analog signal every seconds. The above example generates a discrete signal x[n]x[n] size 12{x $n$ } {} by taking one sample from the analog signal every seconds. To get a digital signal, apply quantization to the discrete signal.

According to the Nyquist theorem, an analog signal z can be reconstructed from its samples by using the following equation:

z(t)=k=z[kTs]sinc(tkTsTs)z(t)=k=z[kTs]sinc(tkTsTs) size 12{z $$t$$ = Sum cSub { size 8{k= - infinity } } cSup { size 8{ infinity } } {z $ital "kT" rSub { size 8{s} } }$ "sin"c $${ {t - ital "kT" rSub { size 8{s} } } over {T rSub { size 8{s} } } }$$ } {}
(3)

This reconstruction is based on the summations of shifted sinc (sinx/x) functions. Figure 8 illustrates the reconstruction of a sine wave from its samples achieved in this manner.

It is difficult to generate sinc functions by electronic circuitry. That is why, in practice, one uses an approximation of a sinc function. Figure 9 shows an approximation of a sinc function by a pulse, which is easy to realize in electronic circuitry. In fact, the well-known sample and hold circuit performs this approximation.

DTFT and DFT

Fourier transformation pairs for analog and discrete signals are expressed in Table 1. Note that the discrete-time Fourier transform (DTFT) for discrete-time signals is the counterpart to the continuous-time Fourier transform (CTFT) for continuous-time signals. Also, the discrete Fourier transform (DFT) is the counterpart to the Fourier series (FS) for continuous-time signals as shown in Table 2 . Table 3 shows a list of these transformations and their behavior in the time and frequency domains.

 Fourier series for periodic analog signals {Xk=1T∫−T/2T/2x(t)e−jω0ktdtx(t)=∑k=−∞∞Xkejω0kt{Xk=1T∫−T/2T/2x(t)e−jω0ktdtx(t)=∑k=−∞∞Xkejω0kt size 12{ left lbrace matrix { X rSub { size 8{k} } = { {1} over {T} } Int rSub { - T/2} rSup {T/2} {x $$t$$ e rSup { size 8{ - jω rSub { size 6{0} } ital "kt"} } ital "dt"} {} ## size 12{x $$t$$ = Sum cSub {k= - infinity } cSup { infinity } {X rSub {k} size 12{e rSup {jω rSub { size 6{0} } ital "kt"} }} } } right none } {}, where T denotes period andω0 fundamental frequency Discrete Fourier transform (DFT) for periodic discrete signals { X [ k ] = ∑ n = 0 N − 1 x [ n ] e − j 2π N nk , k = 0,1, . . . , N − 1 x [ n ] = 1 N ∑ k = 0 N − 1 X [ k ] e j 2π N nk , n = 0,1, . . . , N − 1 { X [ k ] = ∑ n = 0 N − 1 x [ n ] e − j 2π N nk , k = 0,1, . . . , N − 1 x [ n ] = 1 N ∑ k = 0 N − 1 X [ k ] e j 2π N nk , n = 0,1, . . . , N − 1 size 12{ left lbrace matrix { X $k$ = Sum cSub { size 8{n=0} } cSup { size 8{N - 1} } {x $n$ e rSup { size 8{ - j { {2π} over {N} } ital "nk"} } } matrix { , {} # k=0,1, "." "." "." ,N - 1{} } {} ## x $n$ = { {1} over {N} } Sum cSub { size 8{k=0} } cSup { size 8{N - 1} } {X $k$ e rSup { size 8{j { {2π} over {N} } ital "nk"} } matrix { , {} # n=0,1, "." "." "." ,N - 1{} } } {} } right none } {}
 Time domain Spectrum characteristics Transformation type Continuous (periodic) Discrete FS Continuous (aperiodic) Continuous CTFT Discrete (periodic) Discrete (periodic) DFT Discrete (aperiodic) Continuous (periodic) DTFT

Content actions

Give feedback:

My Favorites (?)

'My Favorites' is a special kind of lens which you can use to bookmark modules and collections. 'My Favorites' can only be seen by you, and collections saved in 'My Favorites' can remember the last module you were on. You need an account to use 'My Favorites'.

| A lens I own (?)

Definition of a lens

Lenses

A lens is a custom view of the content in the repository. You can think of it as a fancy kind of list that will let you see content through the eyes of organizations and people you trust.

What is in a lens?

Lens makers point to materials (modules and collections), creating a guide that includes their own comments and descriptive tags about the content.

Who can create a lens?

Any individual member, a community, or a respected organization.

What are tags?

Tags are descriptors added by lens makers to help label content, attaching a vocabulary that is meaningful in the context of the lens.

| External bookmarks