Site Feedback

# Introduction

In this module, we will derive an expansion for discrete-time, periodic functions, and in doing so, derive the Discrete Time Fourier Series (DTFS), or the Discrete Fourier Transform (DFT).

# Eigenfunction analysis

Since complex exponentials are eigenfunctions of linear time-invariant (LTI) systems, calculating the output of an LTI system $ℋℋ$ given $ei⁢ω⁢n ω n$ as an input amounts to simple multiplication, where $ω 0 =2⁢π⁢kN ω 0 2 k N$ , and where $H⁢k∈C H k$ is the eigenvalue corresponding to k. As shown in the figure, a simple exponential input would yield the output

$y⁢n=H⁢k⁢ei⁢ω⁢n y n H k ω n$
1

Using this and the fact that $ℋℋ$ is linear, calculating $y⁢n y n$ for combinations of complex exponentials is also straightforward.

$c 1 ⁢ei⁢ ω 1 ⁢n+ c 2 ⁢ei⁢ ω 2 ⁢n→ c 1 ⁢H⁢ k 1 ⁢ei⁢ ω 1 ⁢n+ c 2 ⁢H⁢ k 2 ⁢ei⁢ ω 1 ⁢n c 1 ω 1 n c 2 ω 2 n c 1 H k 1 ω 1 n c 2 H k 2 ω 1 n$ $∑l c l ⁢ei⁢ ω l ⁢n→∑l c l ⁢H⁢ k l ⁢ei⁢ ω l ⁢n l c l ω l n l c l H k l ω l n$

The action of $HH$ on an input such as those in the two equations above is easy to explain. $ℋℋ$ independently scales each exponential component $ei⁢ ω l ⁢n ω l n$ by a different complex number $H⁢ k l ∈C H k l$. As such, if we can write a function $y⁢n y n$ as a combination of complex exponentials it allows us to easily calculate the output of a system.

# DTFS synthesis

It can be demonstrated that an arbitrary Discrete Time-periodic function $f⁢n f n$ can be written as a linear combination of harmonic complex sinusoids

$f⁢n=∑ k =0N−1 c k ⁢ei⁢ ω 0 ⁢k⁢n f n k N 1 0 c k ω 0 k n$
2
where $ω 0 =2⁢πN ω 0 2 N$ is the fundamental frequency. For almost all $f⁢n f n$ of practical interest, there exists $c n c n$ to make Equation 2 true. If $f⁢n f n$ is finite energy ( $f⁢n∈L20N f n L 0 N 2$), then the equality in Equation 2 holds in the sense of energy convergence; with discrete-time signals, there are no concerns for divergence as there are with continuous-time signals.

The $c n c n$ - called the Fourier coefficients - tell us "how much" of the sinusoid $ej⁢ ω 0 ⁢k⁢n j ω 0 k n$ is in $f⁢n f n$. The formula shows $f⁢n f n$ as a sum of complex exponentials, each of which is easily processed by an LTI system (since it is an eigenfunction of every LTI system). Mathematically, it tells us that the set of complex exponentials $∀ k ,k∈Z:ej⁢ ω 0 ⁢k⁢n k k j ω 0 k n$ form a basis for the space of N-periodic discrete time functions.

# DTFS Analysis

Say we have the following set of numbers that describe a periodic, discrete-time signal, where $N=4 N 4$: $…32-213… … 3 2 -2 1 3 …$ Such a periodic, discrete-time signal (with period $NN$) can be thought of as a finite set of numbers. For example, we can represent this signal as either a periodic signal or as just a single interval as follows:

Note:
The cardinalsity of the set of discrete time signals with period $NN$ equals $CN N$.
Here, we are going to form a basis using harmonic sinusoids. Before we look into this, it will be worth our time to look at the discrete-time, complex sinusoids in a little more detail.

# Complex Sinusoids

If you are familiar with the basic sinusoid signal and with complex exponentials then you should not have any problem understanding this section. In most texts, you will see the the discrete-time, complex sinusoid noted as: $ei⁢ω⁢n ω n$

Example 1
Example 2

# In the Complex Plane

The complex sinusoid can be directly mapped onto our complex plane, which allows us to easily visualize changes to the complex sinusoid and extract certain properties. The absolute value of our complex sinusoid has the following characteristic:

$∀ n ,n∈R:|ei⁢ω⁢n|=1 n n ω n 1$
3
which tells that our complex sinusoid only takes values on the unit circle. As for the angle, the following statement holds true:
$∠⁢ei⁢ω⁢n=w⁢n ∠ ω n w n$
4
For more information, see the section on the Discrete Time Complex Exponential to learn about Aliasing , Negative Frequencies, and the formal definition of the Complex Conjugate .

Now that we have looked over the concepts of complex sinusoids, let us turn our attention back to finding a basis for discrete-time, periodic signals. After looking at all the complex sinusoids, we must answer the question of which discrete-time sinusoids do we need to represent periodic sequences with a period $NN$.

Equivalent Question:
Find a set of vectors $∀ n ,n=0…N−1: b k =ei⁢ ω k ⁢n n n 0 … N 1 b k ω k n$ such that $b k b k$ are a basis for $ℂ n ℂ n$
In answer to the above question, let us try the "harmonic" sinusoids with a fundamental frequency $ω 0 =2⁢πN ω 0 2 N$:
Harmonic Sinusoid
$ei⁢2⁢πN⁢k⁢n 2 N k n$
5

$ei⁢2⁢πN⁢k⁢n 2 N k n$ is periodic with period $N N$ and has $kk$ "cycles" between $n=0 n 0$ and $n=N−1 n N 1$.

Theorem 1

If we let $∀ n ,n=0…N−1: b k ⁢n=1N⁢ei⁢2⁢πN⁢k⁢n n n 0 … N 1 b k n 1 N 2 N k n$ where the exponential term is a vector in $CN N$, then $b k | k=0…N−1 k 0 … N 1 b k$ is an orthonormal basis for $CN N$.

Proof

First of all, we must show $b k b k$ is orthonormal, i.e. $⟨ b k , b l ⟩= δ k l b k b l δ k l$ $⟨ b k , b l ⟩=∑ n =0N−1 b k ⁢n⁢ b l ⁢n¯=1N⁢∑ n =0N−1ei⁢2⁢πN⁢k⁢n⁢e−(i⁢2⁢πN⁢l⁢n) b k b l n N 1 0 b k n b l n 1 N n N 1 0 2 N k n 2 N l n$

$⟨ b k , b l ⟩=1N⁢∑ n =0N−1ei⁢2⁢πN⁢(l−k)⁢n b k b l 1 N n N 1 0 2 N l k n$
6
If $l=k l k$, then
$⟨ b k , b l ⟩=1N⁢∑ n =0N−11=1 b k b l 1 N n N 1 0 1 1$
7
If $l≠k l k$, then we must use the "partial summation formula" shown below: $∑ n =0N−1αn=∑ n =0∞αn−∑ n =N∞αn=11−α−αN1−α=1−αN1−α n N 1 0 α n n 0 α n n N α n 1 1 α α N 1 α 1 α N 1 α$ $⟨ b k , b l ⟩=1N⁢∑ n =0N−1ei⁢2⁢πN⁢(l−k)⁢n b k b l 1 N n N 1 0 2 N l k n$ where in the above equation we can say that $α=ei⁢2⁢πN⁢(l−k) α 2 N l k$, and thus we can see how this is in the form needed to utilize our partial summation formula. $⟨ b k , b l ⟩=1N⁢1−ei⁢2⁢πN⁢(l−k)⁢N1−ei⁢2⁢πN⁢(l−k)=1N⁢1−11−ei⁢2⁢πN⁢(l−k)=0 b k b l 1 N 1 2 N l k N 1 2 N l k 1 N 1 1 1 2 N l k 0$ So,
8
Therefore: $b k b k$ is an orthonormal set. $b k b k$ is also a basis, since there are $NN$ vectors which are linearly independent (orthogonality implies linear independence).

And finally, we have shown that the harmonic sinusoids $1N⁢ei⁢2⁢πN⁢k⁢n 1 N 2 N k n$ form an orthonormal basis for $ℂ n ℂ n$

# Periodic Extension to DTFS

Now that we have an understanding of the discrete-time Fourier series (DTFS), we can consider the periodic extension of $c⁢k c k$ (the Discrete-time Fourier coefficients). Figure 7 shows a simple illustration of how we can represent a sequence as a periodic signal mapped over an infinite number of intervals.

Exercise 1

Why does a periodic extension to the DTFS coefficients $c⁢k c k$ make sense?

Solution

Aliasing: $b k =ei⁢2⁢πN⁢k⁢n b k 2 N k n$

$b k + N =ei⁢2⁢πN⁢(k+N)⁢n=ei⁢2⁢πN⁢k⁢n⁢ei⁢2⁢π⁢n=ei⁢2⁢πN⁢n= b k b k + N 2 N k N n 2 N k n 2 n 2 N n b k$
9
→ DTFS coefficients are also periodic with period $NN$.

# Examples

Example 3: Discrete time square wave

Calculate the DTFS $c⁢k c k$ using:

$c⁢k=1N⁢∑n=0N−1f⁢n⁢e−(i⁢2⁢πN⁢k⁢n) c k 1 N n 0 N 1 f n 2 N k n$
10
Just like continuous time Fourier series, we can take the summation over any interval, so we have
$c k =1N⁢∑n=− N 1 N 1 e−(i⁢2⁢πN⁢k⁢n) c k 1 N n N 1 N 1 2 N k n$
11
Let $m=n+ N 1 m n N 1$ (so we can get a geometric series starting at 0)
$c k =1N⁢∑m=02⁢ N 1 e−(i⁢2⁢πN⁢(m− N 1 )⁢k)=1N⁢ei⁢2⁢πN⁢k⁢∑m=02⁢ N 1 e−(i⁢2⁢πN⁢m⁢k) c k 1 N m 0 2 N 1 2 N m N 1 k 1 N 2 N k m 0 2 N 1 2 N m k$
12
Now, using the "partial summation formula"
$∑n=0Man=1−aM+11−a n 0 M a n 1 a M 1 1 a$
13
$c k =1N⁢ei⁢2⁢πN⁢ N 1 ⁢k⁢∑m=02⁢ N 1 e−(i⁢2⁢πN⁢k)m=1N⁢ei⁢2⁢πN⁢ N 1 ⁢k⁢1−e−(i⁢2⁢πN⁢(2⁢ N 1 +1))1−e−(i⁢k⁢2⁢πN) c k 1 N 2 N N 1 k m 0 2 N 1 2 N k m 1 N 2 N N 1 k 1 2 N 2 N 1 1 1 k 2 N$
14
Manipulate to make this look like a sinc function (distribute):
$c k =1N⁢e−(i⁢k⁢2⁢π2⁢N)⁢(ei⁢k⁢2⁢πN⁢( N 1 +12)−e−(i⁢k⁢2⁢πN⁢( N 1 +12)))e−(i⁢k⁢2⁢π2⁢N)⁢(ei⁢k⁢2⁢πN⁢12−e−(i⁢k⁢2⁢πN⁢12))=1N⁢sin2⁢π⁢k⁢( N 1 +12)Nsinπ⁢kN= digital sinc c k 1 N k 2 2 N k 2 N N 1 1 2 k 2 N N 1 1 2 k 2 2 N k 2 N 1 2 k 2 N 1 2 1 N 2 k N 1 1 2 N k N digital sinc$
15
Note:
It's periodic! Figure 9, Figure 10, and Figure 11show our above function and coefficients for various values of $N 1 N 1$.

# DTFS conclusion

Using the steps shown above in the derivation and our previous understanding of Hilbert Spaces and Orthogonal Expansions, the rest of the derivation is automatic. Given a discrete-time, periodic signal (vector in $ℂ n ℂ n$) $f⁢n f n$, we can write:

$f⁢n=1N⁢∑ k =0N−1 c k ⁢ei⁢2⁢πN⁢k⁢n f n 1 N k N 1 0 c k 2 N k n$
16
$c k =1N⁢∑ n =0N−1f⁢n⁢e−(i⁢2⁢πN⁢k⁢n) c k 1 N n N 1 0 f n 2 N k n$
17
Note: Most people collect both the $1N 1 N$ terms into the expression for $c k c k$.
Discrete Time Fourier Series:
Here is the common form of the DTFS with the above note taken into account: $f⁢n=∑ k =0N−1 c k ⁢ei⁢2⁢πN⁢k⁢n f n k N 1 0 c k 2 N k n$ $c k =1N⁢∑ n =0N−1f⁢n⁢e−(i⁢2⁢πN⁢k⁢n) c k 1 N n N 1 0 f n 2 N k n$ This is what the fft command in MATLAB does.