Discrete-time Fourier transform explained

In mathematics, the discrete-time Fourier transform (DTFT) is a form of Fourier analysis that is applicable to a sequence of discrete values.

The DTFT is often used to analyze samples of a continuous function. The term discrete-time refers to the fact that the transform operates on discrete data, often samples whose interval has units of time. From uniformly spaced samples it produces a function of frequency that is a periodic summation of the continuous Fourier transform of the original continuous function. In simpler terms, when you take the DTFT of regularly-spaced samples of a continuous signal, you get repeating (and possibly overlapping) copies of the signal's frequency spectrum, spaced at intervals corresponding to the sampling frequency. Under certain theoretical conditions, described by the sampling theorem, the original continuous function can be recovered perfectly from the DTFT and thus from the original discrete samples. The DTFT itself is a continuous function of frequency, but discrete samples of it can be readily calculated via the discrete Fourier transform (DFT) (see), which is by far the most common method of modern Fourier analysis.

Both transforms are invertible. The inverse DTFT reconstructs the original sampled data sequence, while the inverse DFT produces a periodic summation of the original sequence. The Fast Fourier Transform (FFT) is an algorithm for computing one cycle of the DFT, and its inverse produces one cycle of the inverse DFT.

Introduction

Relation to Fourier Transform

Let

s(t)

be a continuous function in the time domain.We begin with a common definition of the continuous Fourier transform,where

f

represents frequency in hertz and

t

represents time in seconds:

S(f)\triangleq

infty
\int
-infty

s(t)e-idt.

We can reduce the integral into a summation by sampling

s(t)

at intervals of

T

seconds(see).Specifically, we can replace

s(t)

with a discrete sequence of its samples,

s(nT)

, for integer values of

n

,and replace the differential element

dt

with the sampling period

T

.Thus, we obtain one formulation for the discrete-time Fourier transform (DTFT):

S1/T(f)\triangleq

infty
\sum
n=-infty

\underbrace{Ts(nT)}s[n]e-i.

This Fourier series (in frequency) is a continuous periodic function, whose periodicity is the sampling frequency

1/T

.The subscript

1/T

distinguishes it from the continuous Fourier transform

S(f)

,and from the angular frequency form of the DTFT.The latter is obtained by defining an angular frequency variable,

\omega\triangleq2\pifT

(which has normalized units of radians/sample), giving us a periodic function of angular frequency, with periodicity

2\pi

:

The utility of the DTFT is rooted in the Poisson summation formula, which tells us that the periodic function represented by the Fourier series is a periodic summation of the continuous Fourier transform:The components of the periodic summation are centered at integer values (denoted by

k

) of a normalized frequency (cycles per sample). Ordinary/physical frequency (cycles per second) is the product of

k

and the sample-rate,

fs=1/T.

  For sufficiently large

fs,

the

k=0

term can be observed in the region

[-fs/2,fs/2]

with little or no distortion (aliasing) from the other terms.  Fig.1 depicts an example where

1/T

is not large enough to prevent aliasing.

We also note that

e-i2\pi

is the Fourier transform of

\delta(t-nT).

Therefore, an alternative definition of DTFT is:

The modulated Dirac comb function is a mathematical abstraction sometimes referred to as impulse sampling.

Inverse transform

An operation that recovers the discrete data sequence from the DTFT function is called an inverse DTFT. For instance, the inverse continuous Fourier transform of both sides of produces the sequence in the form of a modulated Dirac comb function:

infty
\sum
n=-infty

s[n]\delta(t-nT)=l{F}-1\left\{S1/T(f)\right\}\triangleq

infty
\int
-infty

S1/T(f)eidf.

However, noting that

S1/T(f)

is periodic, all the necessary information is contained within any interval of length

1/T.

  In both and, the summations over

n

are a Fourier series, with coefficients

s[n].

  The standard formulas for the Fourier coefficients are also the inverse transforms:

Periodic data

When the input data sequence

s[n]

is

N

-periodic, can be computationally reduced to a discrete Fourier transform (DFT), because:

N

samples.

S1/T(f)

converges to zero everywhere except at integer multiples of

1/(NT),

known as harmonic frequencies. At those frequencies, the DTFT diverges at different frequency-dependent rates. And those rates are given by the DFT of one cycle of the

s[n]

sequence.

(1/T)/(1/(NT))=N.

The DFT of one cycle of the

s[n]

sequence is:

S[k]\triangleq\underbrace{\sumNs[n]

-i2\pi
k
N
n
e
}_, \quad k \in \mathbf.

And

s[n]

can be expressed in terms of the inverse transform, which is sometimes referred to as a Discrete Fourier series (DFS):

s[n]=

1
N

\underbrace{\sumNS[k]

i2\pi
k
N
n
e
}_, \quad n \in \mathbf.With these definitions, we can demonstrate the relationship between the DTFT and the DFT:

\begin{align} S1/T(f)&\triangleq

infty
\sum
n=-infty

s[n]e-i\\ &=

infty
\sum\left[
n=-infty
1
N
N-1
\sum
k=0

S[k]

i2\pi
k
N
n
e

\right]e-i\\ &=

1
N
N-1
\sum
k=0

S[k]

infty
\underbrace{\left[\sum
n=-infty
i2\pi
k
N
n
e

e-i\right]}\operatorname{DTFT

i2\pi
k
N
n
\left(e

\right)}\\ &=

1
N
N-1
\sum
k=0

S[k]

1
T
infty
\sum
M=-infty

\delta\left(f-\tfrac{k}{NT}-\tfrac{M}{T}\right) \end{align}

     

Due to the

N

-periodicity of both functions of

k,

this can be simplified to:

S1/T(f)=

1
NT
infty
\sum
k=-infty

S[k]\delta\left(f-

k
NT

\right),

which satisfies the inverse transform requirement:

\begin{align} s[n]&=T

1
T
\int
0

S1/T(f)eidf\\ &=

1
N
infty
\sum
k=-infty

S[k]

1
T
\underbrace{\int
0

\delta\left(f-\tfrac{k}{NT}\right)eidf}zerofor\\ &=

1
N
N-1
\sum
k=0

S[k]

1
T
\int
0

\delta\left(f-\tfrac{k}{NT}\right)eidf\\ &=

1
N
N-1
\sum
k=0

S[k]ei{NT}nT}\\ &=

1
N
N-1
\sum
k=0

S[k]ei{N}n} \end{align}

Sampling the DTFT

When the DTFT is continuous, a common practice is to compute an arbitrary number of samples

(N)

of one cycle of the periodic function

S1/T

:  

\begin{align} \underbrace{S1/T\left(

k
NT
\right)}
Sk

&=

infty
\sum
n=-infty

s[n]

-i2\pi
k
N
n
e

k=0,...,N-1\\ &=\underbrace{\sumN

s
N

[n]

-i2\pi
k
N
n
e

,}DFT\scriptstyle{(sumoveranyn-sequenceoflengthN)} \end{align}

where

s
N
is a periodic summation:
s
N
infty
[n]\triangleq\sum
m=-infty

s[n-mN].

    (see Discrete Fourier series)

The

s
N
sequence is the inverse DFT. Thus, our sampling of the DTFT causes the inverse transform to become periodic. The array of
2
|S
k|
values is known as a periodogram, and the parameter

N

is called NFFT in the Matlab function of the same name.

In order to evaluate one cycle of

s
N
numerically, we require a finite-length

s[n]

sequence. For instance, a long sequence might be truncated by a window function of length

L

resulting in three cases worthy of special mention. For notational simplicity, consider the

s[n]

values below to represent the values modified by the window function.

Case: Frequency decimation.

L=NI,

for some integer

I

(typically 6 or 8)

A cycle of

s
N
reduces to a summation of

I

segments of length

N.

  The DFT then goes by various names, such as:

Recall that decimation of sampled data in one domain (time or frequency) produces overlap (sometimes known as aliasing) in the other, and vice versa. Compared to an

L

-length DFT, the
s
N
summation/overlap causes decimation in frequency, leaving only DTFT samples least affected by spectral leakage. That is usually a priority when implementing an FFT filter-bank (channelizer). With a conventional window function of length

L,

scalloping loss would be unacceptable. So multi-block windows are created using FIR filter design tools.  Their frequency profile is flat at the highest point and falls off quickly at the midpoint between the remaining DTFT samples. The larger the value of parameter

I,

the better the potential performance.

Case:

L=N+1

When a symmetric,

L

-length window function (

s

) is truncated by 1 coefficient it is called periodic or DFT-even. That is a common practice, but the truncation affects the DTFT (spectral leakage) by a small amount. It is at least of academic interest to characterize that effect.  An

N

-length DFT of the truncated window produces frequency samples at intervals of

1/N,

instead of

1/L.

  The samples are real-valued,  but their values do not exactly match the DTFT of the symmetric window. The periodic summation,
s
N

,

along with an

N

-length DFT, can also be used to sample the DTFT at intervals of

1/N.

  Those samples are also real-valued and do exactly match the DTFT (example:). To use the full symmetric window for spectral analysis at the

1/N

spacing, one would combine the

n=0

and

n=N

data samples (by addition, because the symmetrical window weights them equally) and then apply the truncated symmetric window and the

N

-length DFT.

Case: Frequency interpolation.

L\leN

In this case, the DFT simplifies to a more familiar form:

Sk=

N-1
\sum
n=0

s[n]

-i2\pi
k
N
n
e

.

In order to take advantage of a fast Fourier transform algorithm for computing the DFT, the summation is usually performed over all

N

terms, even though

N-L

of them are zeros. Therefore, the case

L<N

is often referred to as zero-padding.

Spectral leakage, which increases as

L

decreases, is detrimental to certain important performance metrics, such as resolution of multiple frequency components and the amount of noise measured by each DTFT sample. But those things don't always matter, for instance when the

s[n]

sequence is a noiseless sinusoid (or a constant), shaped by a window function. Then it is a common practice to use zero-padding to graphically display and compare the detailed leakage patterns of window functions. To illustrate that for a rectangular window, consider the sequence:

s[n]=

i2\pi
1
8
n
e

,

and

L=64.

Figures 2 and 3 are plots of the magnitude of two different sized DFTs, as indicated in their labels. In both cases, the dominant component is at the signal frequency:

f=1/8=0.125

. Also visible in Fig 2 is the spectral leakage pattern of the

L=64

rectangular window. The illusion in Fig 3 is a result of sampling the DTFT at just its zero-crossings. Rather than the DTFT of a finite-length sequence, it gives the impression of an infinitely long sinusoidal sequence. Contributing factors to the illusion are the use of a rectangular window, and the choice of a frequency (1/8 = 8/64) with exactly 8 (an integer) cycles per 64 samples. A Hann window would produce a similar result, except the peak would be widened to 3 samples (see DFT-even Hann window).

Convolution

The convolution theorem for sequences is:

s*y = \scriptstyle{\rmDTFT}-1\displaystyle\left[\scriptstyle{\rmDTFT}\displaystyle\{s\}\scriptstyle{\rmDTFT}\displaystyle\{y\}\right].

An important special case is the circular convolution of sequences and defined by
s
N

*y,

where
s
N
is a periodic summation. The discrete-frequency nature of

\scriptstyle{\rmDTFT}\displaystyle

\{s
N

\}

means that the product with the continuous function

\scriptstyle{\rmDTFT}\displaystyle\{y\}

is also discrete, which results in considerable simplification of the inverse transform:
s
N

*y = \scriptstyle{\rmDTFT}-1\displaystyle\left[\scriptstyle{\rmDTFT}\displaystyle

\{s
N

\}\scriptstyle{\rmDTFT}\displaystyle\{y\}\right] = \scriptstyle{\rmDFT}-1\displaystyle\left[\scriptstyle{\rmDFT}\displaystyle

\{s
N

\}\scriptstyle{\rmDFT}\displaystyle

\{y
N

\}\right].

For and sequences whose non-zero duration is less than or equal to, a final simplification is:

s
N

*y = \scriptstyle{\rmDFT}-1\displaystyle\left[\scriptstyle{\rmDFT}\displaystyle\{s\}\scriptstyle{\rmDFT}\displaystyle\{y\}\right].

The significance of this result is explained at Circular convolution and Fast convolution algorithms.

Symmetry properties

When the real and imaginary parts of a complex function are decomposed into their even and odd parts, there are four components, denoted below by the subscripts RE, RO, IE, and IO. And there is a one-to-one mapping between the four components of a complex time function and the four components of its complex frequency transform:

\begin{array}{rlcccccccc} Time domain&s&=&

s
RE

&+&

s
RO

&+&

is
IE

&+&

\underbrace{is
IO
} \\&\Bigg\Updownarrow\mathcal & &\Bigg\Updownarrow\mathcal & &\ \ \Bigg\Updownarrow\mathcal & &\ \ \Bigg\Updownarrow\mathcal & &\ \ \Bigg\Updownarrow\mathcal\\\mathsf & S & = & S_\text & + & \overbrace & + & i\ S_\text & + & S_\text\end

From this, various relationships are apparent, for example:

(s
RE
+s
RO

)

is the conjugate symmetric function

SRE+iSIO.

Conversely, a conjugate symmetric transform implies a real-valued time-domain.
(is
IE
+is
IO

)

is the conjugate antisymmetric function

SRO+iSIE,

and the converse is true.
(s
RE
+is
IO

)

is the real-valued function

SRE+SRO,

and the converse is true.
(s
RO
+is
IE

)

is the imaginary-valued function

iSIE+iSIO,

and the converse is true.

Relationship to the Z-transform

S2\pi(\omega)

is a Fourier series that can also be expressed in terms of the bilateral Z-transform.  I.e.:

S2\pi(\omega)=\left.Sz(z)

\right|
z=ei

=

i\omega
S
z(e

),

where the

Sz

notation distinguishes the Z-transform from the Fourier transform. Therefore, we can also express a portion of the Z-transform in terms of the Fourier transform:
i\omega
\begin{align} S
z(e

)&=S1/T\left(\tfrac{\omega}{2\piT}\right)  =

infty
\sum
k=-infty

S\left(\tfrac{\omega}{2\piT}-k/T\right)\\ &=

infty
\sum
k=-infty

S\left(\tfrac{\omega-2\pik}{2\piT}\right). \end{align}

Note that when parameter changes, the terms of

S2\pi(\omega)

remain a constant separation

2\pi

apart, and their width scales up or down. The terms of remain a constant width and their separation scales up or down.

Table of discrete-time Fourier transforms

Some common transform pairs are shown in the table below. The following notation applies:

\omega=2\pifT

is a real number representing continuous angular frequency (in radians per sample). (

f

is in cycles/sec, and

T

is in sec/sample.) In all cases in the table, the DTFT is 2π-periodic (in

\omega

).

S2\pi(\omega)

designates a function defined on

-infty<\omega<infty

.

So(\omega)

designates a function defined on

-\pi<\omega\le\pi

, and zero elsewhere. Then: S_(\omega)\ \triangleq \sum_^ S_o(\omega - 2\pi k).

\delta(\omega)

is the Dirac delta function

\operatorname{sinc}(t)

is the normalized sinc function

\operatorname{rect}\left[{n\overL}\right]\triangleq\begin{cases} 1&|n|\leqL/2\\ 0&|n|>L/2 \end{cases}

\operatorname{tri}(t)

is the triangle function

u[n]

is the discrete-time unit step function

\delta[n]

is the Kronecker delta

\deltan,0

Time domain
s[''n'']
Frequency domain
S2π(ω)
RemarksReference

\delta[n]

S2\pi(\omega)=1

\delta[n-M]

S2\pi(\omega)=e-i\omega

integer

M

infty
\sum
m=-infty

\delta[n-Mm]

S2\pi(\omega)=

infty
\sum
m=-infty

e-i=

2\pi
M
infty
\sum
k=-infty

\delta\left(\omega-

2\pik
M

\right)


So(\omega)=

2\pi
M
(M-1)/2
\sum
k=-(M-1)/2

\delta\left(\omega-

2\pik
M

\right)

    odd M

So(\omega)=

2\pi
M
M/2
\sum
k=-M/2+1

\delta\left(\omega-

2\pik
M

\right)

    even M
integer

M>0

u[n]

S2\pi(\omega)=

1
1-e-i

+\pi

infty
\sum
k=-infty

\delta(\omega-2\pik)


So(\omega)=

1
1-e-i

+\pi\delta(\omega)\

The

1/(1-e-i)

term must be interpreted as a distribution in the sense of a Cauchy principal value around its poles at

\omega=2\pik

.

anu[n]

S2\pi(\omega)=

1
1-ae-i

0<

a< 1

e-i

So(\omega)=2\pi\delta(\omega+a),

    -π < a < π

S2\pi(\omega)=2\pi

infty
\sum
k=-infty

\delta(\omega+a-2\pik)

real number

a

\cos(an)

So(\omega)=\pi\left[\delta\left(\omega-a\right)+\delta\left(\omega+a\right)\right],


S2\pi(\omega)\triangleq

infty
\sum
k=-infty

So(\omega-2\pik)

real number

a

with

-\pi<a<\pi

\sin(an)

So(\omega)=

\pi
i

\left[\delta\left(\omega-a\right)-\delta\left(\omega+a\right)\right]

real number

a

with

-\pi<a<\pi

\operatorname{rect}\left[{n-M\overN}\right]\equiv\operatorname{rect}\left[{n-M\overN-1}\right]

So(\omega)={\sin(N\omega/2)\over\sin(\omega/2)}e

integer

M,

and odd integer

N

\operatorname{sinc}(W(n+a))

So(\omega)=

1
W

\operatorname{rect}\left({\omega\over2\piW}\right)eia\omega

real numbers

W,a

with

0<W<1

\operatorname{sinc}2(Wn)

So(\omega)=

1
W

\operatorname{tri}\left({\omega\over2\piW}\right)

real number

W

,

0<W<0.5

\begin{cases} 0&n=0\\

(-1)n
n

&elsewhere \end{cases}

So(\omega)=j\omega

it works as a differentiator filter
1
(n+a)

\left\{\cos[\piW(n+a)]-\operatorname{sinc}[W(n+a)]\right\}

So(\omega)=

j\omega
W

\operatorname{rect}\left({\omega\over\piW}\right)ej

real numbers

W,a

with

0<W<1

\begin{cases} \pi
2

&n=0\\

(-1)n-1
\pin2

&otherwise \end{cases}

So(\omega)=

\omega

\begin{cases} 0;&neven\\

2
\pin

;&nodd \end{cases}

So(\omega)=\begin{cases} j&\omega<0\\ 0&\omega=0\\ -j&\omega>0 \end{cases}

Hilbert transform
C(A+B)
2\pi

\operatorname{sinc}\left[

A-B
2\pi

n\right]\operatorname{sinc}\left[

A+B
2\pi

n\right]

So(\omega)=

real numbers

A,B


complex

C

Properties

This table shows some mathematical operations in the time domain and the corresponding effects in the frequency domain.

*

is the discrete convolution of two sequences

s*[n]

is the complex conjugate of

s[n].

PropertyTime domain
Frequency domain

S2\pi(\omega)

RemarksReference
Linearity

as[n]+by[n]

aS2\pi(\omega)+bY2\pi(\omega)

complex numbers

a,b

Time reversal / Frequency reversal

s[-n]

S2\pi(-\omega)

Time conjugation

s*[n]

*(-\omega)
S
2\pi

Time reversal & conjugation

s*[-n]

*(\omega)
S
2\pi

Real part in time

\operatorname{Re}{(s[n])}

1
2

(S2\pi(\omega)+

*(-\omega))
S
2\pi
Imaginary part in time

\operatorname{Im}{(s[n])}

1
2i

(S2\pi(\omega)-

*(-\omega))
S
2\pi
Real part in frequency
1
2

(s[n]+s*[-n])

\operatorname{Re}{(S2\pi(\omega))}

Imaginary part in frequency
1
2i

(s[n]-s*[-n])

\operatorname{Im}{(S2\pi(\omega))}

Shift in time / Modulation in frequency

s[n-k]

S2\pi(\omega)e-i\omega

integer
Shift in frequency / Modulation in time

s[n]eian

S2\pi(\omega-a)

real number

a

Decimation

s[nM]

1
M
M-1
\sum
m=0

S2\pi\left(\tfrac{\omega-2\pim}{M}\right)

 
integer

M

Time Expansion

\scriptstyle\begin{cases} s[n/M]&n=multipleofM\\ 0&otherwise \end{cases}

S2\pi(M\omega)

integer

M

Derivative in frequency
n
i

s[n]

dS2\pi(\omega)
d\omega

Integration in frequency

Differencing in time

s[n]-s[n-1]

\left(1-e-i\right)S2\pi(\omega)

Summation in time
n
\sum
m=-infty

s[m]

1
\left(1-e-i\right)

S2\pi(\omega)+\piS(0)

infty
\sum
k=-infty

\delta(\omega-2\pik)

Convolution in time / Multiplication in frequency

s[n]*y[n]

S2\pi(\omega)Y2\pi(\omega)

Multiplication in time / Convolution in frequency

s[n]y[n]

1
2\pi
\pi
\int
-\pi

S2\pi(\nu)Y2\pi(\omega-\nu)d\nu

Periodic convolution
Cross correlation

\rhosy[n]=s*[-n]*y[n]

Rsy(\omega)=

*(\omega)
S
2\pi

Y2\pi(\omega)

Esy=

infty
\sum
n=-infty

{s[n]y*[n]}

Esy=

1
2\pi
\pi
\int
-\pi

{S2\pi(\omega)

*(\omega)
Y
2\pi

d\omega}

See also

Further reading