The Frequency Domain DS-GA 1013 / MATH-GA 2824 Mathematical Tools - - PowerPoint PPT Presentation

the frequency domain
SMART_READER_LITE
LIVE PREVIEW

The Frequency Domain DS-GA 1013 / MATH-GA 2824 Mathematical Tools - - PowerPoint PPT Presentation

The Frequency Domain DS-GA 1013 / MATH-GA 2824 Mathematical Tools for Data Science https://cims.nyu.edu/~cfgranda/pages/MTDS_spring20/index.html Carlos Fernandez-Granda The frequency domain Sampling Discrete Fourier transform Frequency


slide-1
SLIDE 1

The Frequency Domain

DS-GA 1013 / MATH-GA 2824 Mathematical Tools for Data Science

https://cims.nyu.edu/~cfgranda/pages/MTDS_spring20/index.html Carlos Fernandez-Granda

slide-2
SLIDE 2

The frequency domain Sampling Discrete Fourier transform Frequency representations in multiple dimensions

slide-3
SLIDE 3

Discussion

slide-4
SLIDE 4

Signal processing

Signal: any structured object of interest (images, audio, video, etc.) Modeled as function of space, time, etc. Finding adequate representations is crucial to process signals effectively

slide-5
SLIDE 5

Electrocardiogram

1 2 3 4 5 6 7 8

Time (s)

1 1 2 3

Voltage (mV)

slide-6
SLIDE 6

Signals as functions

We model signals as square-integrable functions on an interval [a, b] ⊂ R Inner product: x, y := b

a

x (t) y (t) dt Goal: Find basis functions to represent periodic signals

slide-7
SLIDE 7

Sinusoids

Sinusoidal function: a cos(2πft + θ) ◮ Amplitude: a ◮ Frequency: f ◮ Time index: t (periodic with period 1/f ) ◮ Phase: θ

slide-8
SLIDE 8

Problem

Is this a reasonable basis?

slide-9
SLIDE 9

Complex sinusoid

The complex sinusoid with frequency f ∈ R is given by exp(i2πft) := cos(2πft) + i sin(2πft)

slide-10
SLIDE 10

Complex sinusoid

slide-11
SLIDE 11

Complex sinusoid

We can express any real sinusoid in terms of complex sinusoids cos(2πft + θ) = exp(i2πft + iθ) + exp(−i2πft − iθ) 2 = exp(iθ) 2 exp(i2πft) + exp(−iθ) 2 exp(−i2πft) The phase is encoded in the complex amplitude! Linear subspace spanned by exp(i2πft) and exp(−i2πft) contains all real sinusoids with frequency f If we add two sinusoids with frequency f the result is a sinusoid with frequency f

slide-12
SLIDE 12

Orthogonality of complex sinusoids

The family of complex sinusoids with integer frequencies φk (t) := exp i2πkt T

  • ,

k ∈ Z, is an orthogonal set on [a, a + T], where a, T ∈ R and T > 0

slide-13
SLIDE 13

Proof

φk, φj = a+T

a

φk (t) φj (t) dt = a+T

a

exp i2π (k − j) t T

  • dt

= T i2π (k − j)

  • exp

i2π (k − j) (a + T) T

  • − exp

i2π (k − j) a T

  • = 0
slide-14
SLIDE 14

Fourier series

The Fourier series coefficients of x ∈ L2 [a, a + T], a, T ∈ R, T > 0, are ˆ x[k] := x, φk = a+T

a

x(t) exp

  • −i2πkt

T

  • dt.

The Fourier series of order kc is defined as Fkc {x} := 1 T

kc

  • k=−kc

ˆ x[k]φk The Fourier series of x is limkc→∞ Fkc {x}

slide-15
SLIDE 15

Fourier series as a projection

Pspan({φ−kc ,φ−kc +1,...,φkc }) x =

kc

  • k=−kc
  • x,

1 √ T φk

  • 1

√ T φk = Fkc {x}

slide-16
SLIDE 16

Electrocardiogram

1 2 3 4 5 6 7 8

Time (s)

1 1 2 3

Voltage (mV)

slide-17
SLIDE 17

Electrocardiogram: Fourier coefficients (magnitude)

60 40 20 20 40 60

Frequency (Hz)

0.00 0.05 0.10 0.15 0.20 0.25 0.30

Magnitude

slide-18
SLIDE 18

Electrocardiogram: Fourier coefficients (phase)

60 40 20 20 40 60

Frequency (Hz)

3 2 1 1 2 3

Phase (radians)

slide-19
SLIDE 19

Convergence of Fourier series

For any function x ∈ L2[0, T), where a, T ∈ R and T > 0, lim

k→∞ ||x − Fk {x}||L2 = 0

slide-20
SLIDE 20

Electrocardiogram: Fourier components

1 2 3 4 5 6 7 8

Time (s)

0.4 0.2 0.0 0.2 0.4

Voltage (mV) 0 mHz 125 mHz 375 mHz 2 Hz

slide-21
SLIDE 21

Electrocardiogram: Fourier series

1 2 3 4 5 6 7 8

Time (s)

1 1 2 3

Voltage (mV) Signal 0 mHz 125 mHz 375 mHz 2 Hz

slide-22
SLIDE 22

Electrocardiogram: Fourier components

3.40 3.45 3.50 3.55 3.60 3.65 3.70 3.75 3.80

Time (s)

0.04 0.02 0.00 0.02 0.04

Voltage (mV) 5 Hz 10 Hz 50 Hz

slide-23
SLIDE 23

Electrocardiogram: Fourier series

3.40 3.45 3.50 3.55 3.60 3.65 3.70 3.75 3.80

Time (s)

1.0 0.5 0.0 0.5 1.0 1.5

Voltage (mV) Signal 5 Hz 10 Hz 50 Hz

slide-24
SLIDE 24

Electrocardiogram data

1 2 3 4 5 6 7 8

Time (s)

1 1 2 3

Voltage (mV)

slide-25
SLIDE 25

Electrocardiogram features

slide-26
SLIDE 26

Problem: Baseline wandering

1 2 3 4 5 6 7 8

Time (s)

1 1 2 3

Voltage (mV)

slide-27
SLIDE 27

Electrocardiogram: Fourier coefficients (magnitude)

60 40 20 20 40 60

Frequency (Hz)

10

4

10

3

10

2

10

1

Magnitude

slide-28
SLIDE 28

Filtered electrocardiogram

60 40 20 20 40 60

Frequency (Hz)

10

4

10

3

10

2

10

1

Magnitude

slide-29
SLIDE 29

Filtered electrocardiogram

1 2 3 4 5 6 7 8

Time (s)

1.0 0.5 0.0 0.5 1.0 1.5 2.0

Voltage (mV)

slide-30
SLIDE 30

Problem: Interference

3.2 3.3 3.4 3.5 3.6 3.7 3.8 3.9 4.0

Time (s)

0.5 0.0 0.5 1.0 1.5 2.0

Voltage (mV)

slide-31
SLIDE 31

Fourier coefficients (magnitude)

60 40 20 20 40 60

Frequency (Hz)

10

4

10

3

10

2

10

1

Magnitude

slide-32
SLIDE 32

Filtered electrocardiogram

60 40 20 20 40 60

Frequency (Hz)

10

4

10

3

10

2

10

1

Magnitude

slide-33
SLIDE 33

Filtered electrocardiogram

3.2 3.3 3.4 3.5 3.6 3.7 3.8 3.9 4.0

Time (s)

0.5 0.0 0.5 1.0 1.5 2.0

Voltage (mV)

slide-34
SLIDE 34

Electrocardiogram features

slide-35
SLIDE 35

The frequency domain Sampling Discrete Fourier transform Frequency representations in multiple dimensions

slide-36
SLIDE 36

Sampling

Signals are often model continuous objects Challenge: How to measure them so that they can stored/processed A common way is sampling their values at specific locations

slide-37
SLIDE 37

Sampling a complex sinusoid

Complex sinusoid φk in [0, T) Samples at jT

N , j ∈ {0, 1, . . . , N − 1}

φk jT N

  • = exp

i2πkjT TN

  • = exp

i2πkj N

  • = exp

i2π(k + pN)j N

  • for any integer p

= φk+pN jT N

slide-38
SLIDE 38

Sampling a complex sinusoid

Indistinguishable frequencies: . . . , k − 2N, k − N, k, k + N, k + 2N, . . . N := 2kc + 1, how many between −kc and kc? All frequencies between −kc/T and kc/T are distinguishable

slide-39
SLIDE 39

Discrete complex sinusoids

The discrete complex sinusoid ψk ∈ CN with frequency k is ψk [j] := exp i2πkj N

  • ,

0 ≤ j, k ≤ N − 1 Complex sinusoids scaled by 1/ √ N form an orthonormal basis of CN

slide-40
SLIDE 40

ψ2 (N=10)

slide-41
SLIDE 41

ψ3 (N=10)

slide-42
SLIDE 42

Orthogonality

ψk, ψl =

N−1

  • j=0

ψk [j] ψl [j] =

N−1

  • j=0

exp i2π (k − l) j N

  • =

1 − exp

  • i2π(k−l)N

N

  • 1 − exp
  • i2π(k−l)

N

  • = 0

if k = l

slide-43
SLIDE 43

Bandlimited signals

A bandlimited signal cut-off frequency kc/T is equal to its Fourier series

  • f order kc

x(t) = 1 T

kc

  • k=−kc

ˆ x[k] exp i2πkt T

  • Bandlimited signals have a finite representation (2kc + 1 coefficients)
slide-44
SLIDE 44

Sampling a bandlimited signal on a uniform grid

Bandlimited signal x measured at N equispaced points in interval T Samples: x

N

  • , x

T

N

  • , x

2T

N

  • , . . . , x
  • (N−1)T

N

  • Using Fourier series representation

x jT N

  • = 1

T

kc

  • k=−kc

ˆ xk exp i2πkjT NT

  • = 1

T

kc

  • k=−kc

ˆ xk exp i2πkj N

slide-45
SLIDE 45

In matrix form

             x

  • N
  • x
  • T

N

  • · · ·

x jT

N

  • · · ·

x

  • T − T

N

            = 1 T              1 1 · · · 1 exp i2π(−kc )

N

  • exp

i2π(−kc +1)

N

  • · · ·

exp i2πkc

N

  • · · ·

· · · · · · · · · exp i2π(−kc )j

N

  • exp

i2π(−kc +1)j

N

  • · · ·

exp i2πkc j

N

  • · · ·

· · · · · · · · · exp i2π(−kc )(N−1)

N

  • exp

i2π(−kc +1)(N−1)

N

  • · · ·

exp i2πkc (N−1)

N

                   ˆ x[−kc ] ˆ x[−kc + 1] · · · ˆ x[kc ]       

x[N] = 1 T

  • F[N]ˆ

x[kc]

slide-46
SLIDE 46

Nyquist-Shannon-Kotelnikov sampling theorem

Any bandlimited signal x ∈ L2[0, T), where T > 0, with cut-off frequency kc/T can be recovered exactly from N uniformly spaced samples x (0), x (T/N), . . . , x (T − T/N) as long as N ≥ 2kc + 1, where 2kc + 1 is known as the Nyquist rate

slide-47
SLIDE 47

Recovery

ˆ x[kc] = T N

  • F ∗

[N]x[N]

  • F[N] :=

        1 1 · · · 1 exp i2π(−kc )

N

  • exp

i2π(−kc +1)

N

  • · · ·

exp

  • i2πkc

N

  • · · ·

· · · · · · · · · exp i2π(−kc )(N−1)

N

  • exp

i2π(−kc +1)(N−1)

N

  • · · ·

exp i2πkc (N−1)

N

      

slide-48
SLIDE 48

Proof

For −kc ≤ k ≤ −1 and 0 ≤ j ≤ N − 1, exp i2πkj N

  • = exp

i2π (N + k) j N

  • F[N] =
  • ψN−kc

· · · ψN−1 ψ0 · · · ψkc

  • F[N] is orthogonal!
slide-49
SLIDE 49

Audio

Range of frequencies that human beings can hear is from 20 Hz to 20 kHz At what frequency should we sample (at least)? Typical rates used in practice: 44.1 kHz (CD), 48 kHz, 88.2 kHz, 96 kHz

slide-50
SLIDE 50

Sampling a real sinusoid

Consider a real sinusoid with frequency equal to 4 Hz x(t) := cos(8πt) = 0.5 exp(−i2π4t) + 0.5 exp(i2π4t) measured over one second, i.e. T = 1 s kc? 4 Hz Nyquist rate? 9 Hz

slide-51
SLIDE 51

Recovered Fourier coefficients (N = 10)

6 4 2 2 4 6

Frequency (Hz)

0.0 0.1 0.2 0.3 0.4 0.5

Magnitude Signal Reconstruction

slide-52
SLIDE 52

Recovered signal (N = 10)

0.0 0.2 0.4 0.6 0.8 1.0

Time (s)

1.00 0.75 0.50 0.25 0.00 0.25 0.50 0.75 1.00

Signal Reconstruction Samples

slide-53
SLIDE 53

Sampling a real sinusoid

x(t) := cos(8πt) = 0.5 exp(−i2π4t) + 0.5 exp(i2π4t) N = 5 (as if kc = 2) ˆ xrec[k] =

  • {(m−k) mod 5=0}

ˆ x[m] ˆ xrec[−2] = 0 ˆ xrec[−1] = ˆ xrec[4] = 0.5 ˆ xrec[0] = 0 ˆ xrec[1] = ˆ xrec[−4] = 0.5 ˆ xrec[2] = 0

slide-54
SLIDE 54

Recovered Fourier coefficients (N = 5)

6 4 2 2 4 6

Frequency (Hz)

0.0 0.1 0.2 0.3 0.4 0.5

Magnitude Signal Reconstruction

slide-55
SLIDE 55

Recovered signal (N = 5)

0.0 0.2 0.4 0.6 0.8 1.0

Time (s)

1.00 0.75 0.50 0.25 0.00 0.25 0.50 0.75 1.00

Signal Reconstruction Samples

slide-56
SLIDE 56

Aliasing

Show videos

slide-57
SLIDE 57

What happens if we sample too slowly?

Let x be a signal that is with cut-off frequency ktrue/T We measure x[N], N samples of x at 0, T/N, 2T/N, . . . T − T/N What happens if we recover the signal assuming it is bandlimited with cut-off freq ksamp/T, N = 2ksamp + 1, but actually ktrue > ksamp? ˆ xrec[k] := 1 N ( F ∗

[N]x[N])[k]

=

  • {(m−k) mod N=0}

ˆ x[m] This is called aliasing

slide-58
SLIDE 58

Proof

1 N ( F ∗

[N]x[N])[k] = 1

N

N−1

  • j=0

exp

  • −i2πkj

N

  • ktrue
  • m=−ktrue

ˆ x[m] exp i2πmj N

  • = 1

N

  • ψk,

ktrue

  • m=−ktrue

ˆ x[m]ψm

  • =
  • {(m−k) mod N=0}

ˆ x[m]

slide-59
SLIDE 59

Electrocardiogram: Fourier coefficients (magnitude)

60 40 20 20 40 60

Frequency (Hz)

10

4

10

3

10

2

10

1

Magnitude

slide-60
SLIDE 60

Sampling an electrocardiogram

Signal is approximately bandlimited at 50 Hz T = 8 s, so kc = 50/(1/T) = 400 To avoid aliasing N ≥ 801

slide-61
SLIDE 61

Recovered Fourier coefficients (N=1,000)

80 60 40 20 20 40 60 80

Frequency (Hz)

10

5

10

4

10

3

10

2

10

1

Magnitude Signal Reconstruction

slide-62
SLIDE 62

Recovered signal (N=1,000)

3.40 3.45 3.50 3.55 3.60 3.65 3.70 3.75

Time (s)

1.0 0.5 0.0 0.5 1.0 1.5

Voltage (mV) Signal Reconstruction Samples

slide-63
SLIDE 63

Sampling an electrocardiogram

Signal is approximately bandlimited at 50 Hz T = 8 s, so kc = 50/(1/T) = 400 N = 625 ˆ xrec[k] =

  • {(m−k) mod 625=0}

ˆ x[m] Component at m = ±400 (50 Hz) shows up at ±225 (28.1 Hz)

slide-64
SLIDE 64

Recovered Fourier coefficients (N = 625)

80 60 40 20 20 40 60 80

Frequency (Hz)

10

5

10

4

10

3

10

2

10

1

Magnitude Signal Reconstruction

slide-65
SLIDE 65

Recovered signal (N = 625)

3.40 3.45 3.50 3.55 3.60 3.65 3.70 3.75

Time (s)

1.0 0.5 0.0 0.5 1.0 1.5

Voltage (mV) Signal Reconstruction Samples

slide-66
SLIDE 66

The frequency domain Sampling Discrete Fourier transform Frequency representations in multiple dimensions

slide-67
SLIDE 67

Discrete complex sinusoids

The discrete complex sinusoid ψk ∈ CN with frequency k is ψk [j] := exp i2πkj N

  • ,

0 ≤ j, k ≤ N − 1 Discrete complex sinusoids scaled by 1/ √ N: orthonormal basis of CN

slide-68
SLIDE 68

ψ2 (N=10)

slide-69
SLIDE 69

ψ3 (N=10)

slide-70
SLIDE 70

Discrete Fourier transform

The discrete Fourier transform (DFT) of x ∈ CN is

ˆ x :=          1 1 1 · · · 1 1 exp

  • − i2π

N

  • exp
  • − i2π2

N

  • · · ·

exp

  • − i2π(N−1)

N

  • 1

exp

  • − i2π2

N

  • exp
  • − i2π4

N

  • · · ·

exp

  • − i2π2(N−1)

N

  • · · ·

· · · · · · · · · · · · 1 exp

  • − i2π(N−1)

N

  • exp
  • − i2π2(N−1)

N

  • · · ·

exp

  • − i2π(N−1)2

N

        x = F[N]x

ˆ x [k] = x, ψk , 0 ≤ k ≤ N − 1

slide-71
SLIDE 71

Inverse discrete Fourier transform

The inverse DFT of a vector ˆ y ∈ CN equals y = 1 N F ∗

[N]ˆ

y It inverts the DFT

slide-72
SLIDE 72

Interpretation in terms of bandlimited signals

If x ∈ CN contains samples of a bandlimited signal such that 2kc + 1 ≤ N the DFT contains the Fourier series coefficients of the function ˆ x[kc] = 1 N

  • F ∗

[N]x[N]

  • F[N] :=

        1 1 · · · 1 exp i2π(−kc )

N

  • exp

i2π(−kc +1)

N

  • · · ·

exp

  • i2πkc

N

  • · · ·

· · · · · · · · · exp i2π(−kc )(N−1)

N

  • exp

i2π(−kc +1)(N−1)

N

  • · · ·

exp i2πkc (N−1)

N

      

Rows of F[N] equal rows of F[N] in a different order!

slide-73
SLIDE 73

Complexity of computing the DFT

Complexity of multiplying N × N matrix with N-dim. vector is N2 Very slow! We can exploit the structure of the matrix to do much better

slide-74
SLIDE 74

Fast Fourier transform

The most important numerical algorithm of our lifetime (G. Strang) Main insight: Action of N-order DFT matrix on vector can be decomposed into action of N/2-order DFT submatrices on subvectors

slide-75
SLIDE 75

Separation in even/odd columns and top/bottom rows

  • x[0]
  • x[1]
  • x[2]
  • x[3]
  • x[4]
  • x[5]
  • x[6]
  • x[7]

ˆ x[0] ˆ x[1] ˆ x[2] ˆ x[3] ˆ x[4] ˆ x[5] ˆ x[6] ˆ x[7]

=

slide-76
SLIDE 76

Even columns can be scaled to yield odd columns

= e−2πi(0)/8 e−2πi(1)/8 e−2πi(2)/8 e−2πi(3)/8 e−2πi(4)/8 e−2πi(5)/8 e−2πi(6)/8 e−2πi(7)/8

slide-77
SLIDE 77

Top even submatrix and bottom even submatrix are both an N/2-order DFT matrix

=

slide-78
SLIDE 78

FFT identity

  • x[0]
  • x[2]
  • x[4]
  • x[6]

+ e−2πi(0)/8 e−2πi(1)/8 e−2πi(2)/8 e−2πi(3)/8

  • x[1]
  • x[3]
  • x[5]
  • x[7]
  • x[0]
  • x[2]
  • x[4]
  • x[6]

+ e−2πi(4)/8 e−2πi(5)/8 e−2πi(6)/8 e−2πi(7)/8

  • x[1]
  • x[3]
  • x[5]
  • x[7]

ˆ x[0] ˆ x[1] ˆ x[2] ˆ x[3] = ˆ x[4] ˆ x[5] ˆ x[6] ˆ x[7] =

slide-79
SLIDE 79

Cooley-Tukey Fast Fourier transform

  • 1. Compute F[N/2]xeven.
  • 2. Compute F[N/2]xodd.
  • 3. For k = 0, 1, . . . , N/2 − 1 set

F[N]x [k] := F[N/2]xeven [k] + exp

  • −i2πk

N

  • F[N/2]xodd [k] ,

F[N]x [k + N/2] := F[N/2]xeven [k] − exp

  • −i2πk

N

  • F[N/2]xodd [k] .
slide-80
SLIDE 80

Complexity

DFT2L DFT2L−1 DFT2L−1 DFT2L−2 DFT2L−2 DFT2L−2 DFT2L−2 DFT2L−3 DFT2L−3 DFT2L−3 DFT2L−3 DFT2L−3 DFT2L−3 DFT2L−3 DFT2L−3

slide-81
SLIDE 81

Complexity

Assume N = 2L L = log2 N levels At level m ∈ {1, . . . , L} there are 2m nodes At each node, scale a vector of dim 2L−m and add to another vector Complexity at each node: 2L−m Complexity at each level: 2L−m2m = 2L = N Complexity is O(N log N)!

slide-82
SLIDE 82

In practice

102 103 104

N

10

5

10

4

10

3

10

2

10

1

Running time (s) DFT (matrix) FFT (recursive)

slide-83
SLIDE 83

The frequency domain Sampling Discrete Fourier transform Frequency representations in multiple dimensions

slide-84
SLIDE 84

Multidimensional signals

Square-integrable functions defined on a hyperrectangle I := [a1, b1] × . . . × [ap, bp] ⊂ Rp Inner product: x, y :=

  • I

x (t ) y (t ) dt. Goal: Extension of frequency representations to multidimensional signals

slide-85
SLIDE 85

Multidimensional sinusoid

a cos (2πf , t + θ) . The frequency and time indices are now d-dimensional Periodic with period 1/ ||f ||2 in direction of f For any integer m a cos

  • f , t +

m ||f ||2 f ||f ||2

  • + θ
  • = a cos (2πf , t + 2πm + θ)

= a cos (2πf , t + θ)

slide-86
SLIDE 86

2D sinusoid

0.0 0.2 0.4 0.6 0.8 1.0

t2

0.0 0.2 0.4 0.6 0.8 1.0

t1

1.00 0.75 0.50 0.25 0.00 0.25 0.50 0.75 1.00

slide-87
SLIDE 87

Multidimensional complex sinusoids

Complex sinusoid with frequency f ∈ Rd: exp(i2πf , t ) := cos(2πf , t ) + i sin(2πf , t ). cos (i2πf , t + θ) = exp(iθ) 2 exp(i2πf , t ) + exp(−iθ) 2 exp(−i2πf , t )

slide-88
SLIDE 88

Multidimensional complex sinusoids

Can be expressed as product of 1D complex sinusoids exp(i2πf , t ) := exp  i2π

d

  • j=1

f [j]t [j]   =

d

  • j=1

exp(i2πf [j]t [j]) From now on d = 2: t [1] = t1, t [2] = t2

slide-89
SLIDE 89

Orthogonality of multidimensional complex sinusoids

The family of complex sinusoids with integer frequencies φ2D

k1,k2 (t1, t2) := exp

i2πk1t1 T

  • exp

i2πk2t2 T

  • ,

k1, k2 ∈ Z, is an orthogonal set of functions on any interval of the form [a, a + T] × [b, b + T], a, b, T ∈ R and T > 0

slide-90
SLIDE 90

Proof

We have φ2D

k1,k2 (t1, t2) = φk1 (t1) φk2 (t2) ,

so that

  • φ2D

k1,k2, φ2D j1,j2

  • =

a+T

t1=a

b+T

t2=b

φk1 (t1) φk2 (t2) φj1 (t1) φj2 (t2) dt1 dt2 = φk1, φj1 φk2, φj2 = 0 as long as j1 = k1 or j2 = k2

slide-91
SLIDE 91

φ2D

0,5 + φ2D 0,−5

10 9 8 7 6 5 4 3 2 1 0 1 2 3 4 5 6 7 8 9 10

k2

10 9 8 7 6 5 4 3 2 1 1 2 3 4 5 6 7 8 9 10

k1

slide-92
SLIDE 92

φ2D

0,5 + φ2D 0,−5

0.0 0.2 0.4 0.6 0.8 1.0

t2

0.0 0.2 0.4 0.6 0.8 1.0

t1

1.00 0.75 0.50 0.25 0.00 0.25 0.50 0.75 1.00

slide-93
SLIDE 93

φ2D

10,0 + φ2D −10,0

10 9 8 7 6 5 4 3 2 1 0 1 2 3 4 5 6 7 8 9 10

k2

10 9 8 7 6 5 4 3 2 1 1 2 3 4 5 6 7 8 9 10

k1

slide-94
SLIDE 94

φ2D

10,0 + φ2D −10,0

0.0 0.2 0.4 0.6 0.8 1.0

t2

0.0 0.2 0.4 0.6 0.8 1.0

t1

1.00 0.75 0.50 0.25 0.00 0.25 0.50 0.75 1.00

slide-95
SLIDE 95

φ2D

3,4 + φ2D −3,−4

10 9 8 7 6 5 4 3 2 1 0 1 2 3 4 5 6 7 8 9 10

k2

10 9 8 7 6 5 4 3 2 1 1 2 3 4 5 6 7 8 9 10

k1

slide-96
SLIDE 96

φ2D

3,4 + φ2D −3,−4

0.0 0.2 0.4 0.6 0.8 1.0

t2

0.0 0.2 0.4 0.6 0.8 1.0

t1

1.00 0.75 0.50 0.25 0.00 0.25 0.50 0.75 1.00

slide-97
SLIDE 97

φ2D

8,−6 + φ2D −8,6

10 9 8 7 6 5 4 3 2 1 0 1 2 3 4 5 6 7 8 9 10

k2

10 9 8 7 6 5 4 3 2 1 1 2 3 4 5 6 7 8 9 10

k1

slide-98
SLIDE 98

φ2D

8,−6 + φ2D −8,6

0.0 0.2 0.4 0.6 0.8 1.0

t2

0.0 0.2 0.4 0.6 0.8 1.0

t1

1.00 0.75 0.50 0.25 0.00 0.25 0.50 0.75 1.00

slide-99
SLIDE 99

2D Fourier series

The Fourier series coefficients of a function x ∈ L2 [a, a + T] for any a, T ∈ R, T > 0, are given by ˆ x[k1, k2] :=

  • x, φ2D

k1,k2

  • =

a+T

t1=a

b+T

t2=b

x(t1, t2) exp

  • −i2πk1t1

T

  • exp
  • −i2πk2t2

T

  • dt1 dt2

The Fourier series of order kc,1, kc,2 is defined as Fkc,1,kc,2 {x} := 1 T

kc,1

  • k1=−kc,1

kc,2

  • k2=−kc,2

ˆ x[k1, k2]φ2D

k1,k2.

slide-100
SLIDE 100

Magnetic resonance imaging

Non-invasive medical-imaging technique Measures response of atomic nuclei in biological tissues to high-frequency radio waves when placed in a strong magnetic field Radio waves adjusted so that each measurement equals 2D Fourier coefficients of proton density of hydrogen atoms in a region of interest

slide-101
SLIDE 101

Data

  • 3.0 -2.0 -1.0

0.0 1.0 2.0 3.0

k2 (1/cm)

  • 3.0
  • 2.0
  • 1.0

0.0 1.0 2.0 3.0

k1 (1/cm)

10

6

10

5

10

4

10

3

10

2

slide-102
SLIDE 102

Recovered image

0.0 5.0 10.0 15.0 20.0 25.0

t2 (cm)

0.0 5.0 10.0 15.0 20.0 25.0

t1 (cm)

0.00 0.05 0.10 0.15 0.20 0.25 0.30 0.35

slide-103
SLIDE 103

Data

  • 3.0 -2.0 -1.0

0.0 1.0 2.0 3.0

k2 (1/cm)

  • 3.0
  • 2.0
  • 1.0

0.0 1.0 2.0 3.0

k1 (1/cm)

10

6

10

5

10

4

10

3

10

2

slide-104
SLIDE 104

Recovered image

0.0 5.0 10.0 15.0 20.0 25.0

t2 (cm)

0.0 5.0 10.0 15.0 20.0 25.0

t1 (cm)

0.00 0.05 0.10 0.15 0.20 0.25 0.30 0.35

slide-105
SLIDE 105

Data

  • 3.0 -2.0 -1.0

0.0 1.0 2.0 3.0

k2 (1/cm)

  • 3.0
  • 2.0
  • 1.0

0.0 1.0 2.0 3.0

k1 (1/cm)

10

6

10

5

10

4

10

3

10

2

slide-106
SLIDE 106

Recovered image

0.0 5.0 10.0 15.0 20.0 25.0

t2 (cm)

0.0 5.0 10.0 15.0 20.0 25.0

t1 (cm)

0.00 0.05 0.10 0.15 0.20 0.25 0.30 0.35

slide-107
SLIDE 107

Data

  • 3.0 -2.0 -1.0

0.0 1.0 2.0 3.0

k2 (1/cm)

  • 3.0
  • 2.0
  • 1.0

0.0 1.0 2.0 3.0

k1 (1/cm)

10

6

10

5

10

4

10

3

10

2

slide-108
SLIDE 108

Recovered image

0.0 5.0 10.0 15.0 20.0 25.0

t2 (cm)

0.0 5.0 10.0 15.0 20.0 25.0

t1 (cm)

0.00 0.05 0.10 0.15 0.20 0.25 0.30 0.35 0.40

slide-109
SLIDE 109

Bandlimited signal

A signal defined on the 2D rectangle [a, a + T] × [b, b + T], where a, b, T ∈ R and T > 0 is bandlimited with a cut-off frequency kc if it is equal to its Fourier series representation of order kc, i.e. x(t1, t2) =

kc

  • k1=−kc

kc

  • k2=−kc

ˆ x[k1, k2] exp i2πk1t1 T

  • exp

i2πk2t2 T

slide-110
SLIDE 110

Equispaced grid

X[N] :=         x

N , 0 N

  • x

N , T N

  • · · ·

x

N , T − T N

  • x

T

N , 0 N

  • x

T

N , T N

  • · · ·

x T

N , T − T N

  • · · ·

· · · · · · · · · x

  • T − T

N , 0 N

  • x
  • T − T

N , T N

  • · · ·

x

  • T − T

N , T − T N

       .

slide-111
SLIDE 111

Nyquist-Shannon-Kotelnikov sampling theorem

Any bandlimited signal x ∈ L2[0, T)2, where T > 0, with cut-off frequency kc can be recovered from N2 uniformly spaced samples if N ≥ 2kc + 1, where 2kc + 1 is known as the Nyquist rate

slide-112
SLIDE 112

2D discrete signals

We represent 2D signals as matrices belonging to the vector space of CN×N matrices endowed with the standard inner product A, B := tr (A∗B) , A, B ∈ CN×N. Equivalent to dot product between vectorized matrices

slide-113
SLIDE 113

Discrete complex sinusoids

The discrete complex sinusoid Φk1,k2 ∈ CN×N with integer frequencies k1 and k2 is defined as Φk1,k2 [j1, j2] := exp i2πk1j1 N

  • exp

i2πk2j2 N

  • ,

0 ≤ j1, j2 ≤ N − 1, Equivalently Φk1,k2 = ψk1ψ T

k2.

The discrete complex exponentials 1

N Φk1,k2, 0 ≤ k1, k2 ≤ N − 1, form an

  • rthonormal basis of CN×N
slide-114
SLIDE 114

Proof

Φk1,k2, Φl1,l2 = tr ((Φl1,l2)∗ Φk1,k2) = (ψk1)∗ψl1(ψk2)∗ψl2

slide-115
SLIDE 115

2D discrete Fourier transform

The discrete Fourier transform (DFT) of a 2D array X ∈ CN×N is

  • X [k1, k2] := X, Φk1,k2 ,

0 ≤ k1, k2 ≤ N − 1,

  • r equivalently
  • X := F[N]X F[N],

where F[N] is the 1D DFT matrix

slide-116
SLIDE 116

Inverse 2D discrete Fourier transform

The inverse DFT of a 2D array Y ∈ CN×N equals Y = 1 N2 F ∗

[N]

Y F ∗

[N]

It inverts the 2D DFT

slide-117
SLIDE 117

2D discrete Fourier transform

Can be interpreted as Fourier series of samples (as in 1D) Complexity O(N2 log N) instead of O(N3) (FFT)