79
An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC University Joseph Fourier Grenoble, France An Introduction to Wavelets and some Applications – p.1/54

An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

  • Upload
    others

  • View
    15

  • Download
    0

Embed Size (px)

Citation preview

Page 1: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

An Introduction to Wavelets andsome Applications

Milan, May 2003

Anestis Antoniadis

Laboratoire IMAG-LMC

University Joseph Fourier

Grenoble, France

An Introduction to Wavelets and some Applications – p.1/54

Page 2: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Outline

General facts on wavelet decompositions

An Introduction to Wavelets and some Applications – p.2/54

Page 3: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Outline

General facts on wavelet decompositions

Multiresolution analyses

An Introduction to Wavelets and some Applications – p.2/54

Page 4: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Outline

General facts on wavelet decompositions

Multiresolution analyses

Computational algorithms

An Introduction to Wavelets and some Applications – p.2/54

Page 5: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Outline

General facts on wavelet decompositions

Multiresolution analyses

Computational algorithms

Approximation and Compression

An Introduction to Wavelets and some Applications – p.2/54

Page 6: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Outline

General facts on wavelet decompositions

Multiresolution analyses

Computational algorithms

Approximation and Compression

Linear

An Introduction to Wavelets and some Applications – p.2/54

Page 7: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Outline

General facts on wavelet decompositions

Multiresolution analyses

Computational algorithms

Approximation and Compression

Linear

Nonlinear

An Introduction to Wavelets and some Applications – p.2/54

Page 8: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Outline

General facts on wavelet decompositions

Multiresolution analyses

Computational algorithms

Approximation and Compression

Linear

Nonlinear

Estimation and Denoising

An Introduction to Wavelets and some Applications – p.2/54

Page 9: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Outline

General facts on wavelet decompositions

Multiresolution analyses

Computational algorithms

Approximation and Compression

Linear

Nonlinear

Estimation and Denoising

Regularization

An Introduction to Wavelets and some Applications – p.2/54

Page 10: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Outline

General facts on wavelet decompositions

Multiresolution analyses

Computational algorithms

Approximation and Compression

Linear

Nonlinear

Estimation and Denoising

Regularization

Asymptotics and Applications

An Introduction to Wavelets and some Applications – p.2/54

Page 11: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Generalities

Interest in representing an "observed” signal as anappropriate superposition of "elementary” functions inan adapted way.

An Introduction to Wavelets and some Applications – p.3/54

Page 12: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Generalities

Interest in representing an "observed” signal as anappropriate superposition of "elementary” functions inan adapted way.

To obtain such representations that can be useful inpractice, one needs fast computational algorithms.

An Introduction to Wavelets and some Applications – p.3/54

Page 13: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Generalities

Interest in representing an "observed” signal as anappropriate superposition of "elementary” functions inan adapted way.

To obtain such representations that can be useful inpractice, one needs fast computational algorithms.

Once such representations are derived, one would liketo simplify them in a efficient way by choosingappropriately only few elementary components. Thismay be seen as an approximation or compression task.

An Introduction to Wavelets and some Applications – p.3/54

Page 14: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

The Haar basis

The Haar basis is the simplest example of a wavelet basis. Itallows us to introduce in a clear and simple way thewavelet idea, without going to far into mathematicaldetails.Suppose we are given a discretized version of an integrablefunction f on [0, 1] on an equidistant grid of 8 values.

An Introduction to Wavelets and some Applications – p.4/54

Page 15: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

The Haar basis

The Haar basis is the simplest example of a wavelet basis. Itallows us to introduce in a clear and simple way thewavelet idea, without going to far into mathematicaldetails.Suppose we are given a discretized version of an integrablefunction f on [0, 1] on an equidistant grid of 8 values. Letthe discrete signal be:

[2 4 8 12 14 0 2 1]

A digital signal on [0, 1]

An Introduction to Wavelets and some Applications – p.4/54

Page 16: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

We could represent the above digital signal in a different

way in order to exploit a possible correlation between

adjacent points. To this end, for every pair of neighbors we

compute their averages to obtain: [3 10 7 1.5]

Averages of neighbor values

To avoid any loss of information we also need to record some

other values that represent the loss of information when going

from the finer grid to the coarser.

An Introduction to Wavelets and some Applications – p.5/54

Page 17: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

We choose[−1 − 2 7 0.5]

Differences of Input and its approximation

Indeed, 3+(-1)=2, 3-(-1)=4, 10+(-2)=8, . . .

An Introduction to Wavelets and some Applications – p.6/54

Page 18: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

We choose[−1 − 2 7 0.5]

Differences of Input and its approximation

Indeed, 3+(-1)=2, 3-(-1)=4, 10+(-2)=8, . . .

input signal = signal with lower resolution (4 values) and a

quadruple of differences (the details).

An Introduction to Wavelets and some Applications – p.6/54

Page 19: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

The Haar transform

We can repeat the procedure over the averages again andagain to obtain:

Resolution Averages Details

8 [ 2 4 8 12 14 0 2 1]

4 [ 3 10 7 1.5] [ -1 -2 7 0.5]

2 [ 6.5 4.25 ] [ -3.5 2.75 ]

1 [ 5.375 ] [ 1.125 ]

thus representing the input as:

[5.3751.125 − 3.52.75 − 1 − 270.5]

An Introduction to Wavelets and some Applications – p.7/54

Page 20: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Difference

Difference

Difference

Input = digital signal

Average

Average

Average

The Haar transform An Introduction to Wavelets and some Applications – p.8/54

Page 21: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

The digital input may be considered as a piecewise constant

function on [0, 1] on the intervals I3,k = [2−3k, 2−3(k + 1)[,

k = 0, . . . , 23 − 1. If φ(x) = I[0,1[(x) and φj,k(x) = φ(2jx − k),

the function may be written as

f (x) = 2φ3,0(x) + 4φ3,1(x) + 8φ3,2(x) + 12φ3,3(x) + · · ·14φ3,4(x) + 0φ3,5(x) + 2φ3,6(x) + 1φ3,7(x).

We then may re-write:

f (x) = 3φ2,0(x) + 10φ2,1(x) + 7φ2,2(x) + 1.5φ2,3(x) + · · ·(−1)ψ2,0(x) + (−2)ψ2,1(x) + 7ψ2,2(x) + 0.5ψ2,3(x),

where ψ(x) = I[0,1/2[(x) − I[1/2,1[(x).An Introduction to Wavelets and some Applications – p.9/54

Page 22: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

V0 subspace of L2([0, 1[) spanned by the constant

functions on [0, 1[.

An Introduction to Wavelets and some Applications – p.10/54

Page 23: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

V0 subspace of L2([0, 1[) spanned by the constant

functions on [0, 1[.

V1 subspace spanned by the piecewise constant

functions on [0, 1/2[ and [1/2, 1[

An Introduction to Wavelets and some Applications – p.10/54

Page 24: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

V0 subspace of L2([0, 1[) spanned by the constant

functions on [0, 1[.

V1 subspace spanned by the piecewise constant

functions on [0, 1/2[ and [1/2, 1[

Vj subspace spanned by the piecewise constant functions

on the intervals Ij,k, k = 0, 2j − 1.

An Introduction to Wavelets and some Applications – p.10/54

Page 25: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

V0 subspace of L2([0, 1[) spanned by the constant

functions on [0, 1[.

V1 subspace spanned by the piecewise constant

functions on [0, 1/2[ and [1/2, 1[

Vj subspace spanned by the piecewise constant functions

on the intervals Ij,k, k = 0, 2j − 1.

They are nested. Moreover, for each of them, the families

{φj,k, k = 0, . . . , 2j − 1} form a basis. For the usual inner prod-

uct 〈 f , g〉 =∫ 1

0 f (x)g(x)dx, these families are orthogonal and

{ψj,k, k = 0, . . . , 2j − 1} is a basis of the vector space Wj, or-

thogonal complement of Vj in Vj+1. An Introduction to Wavelets and some Applications – p.10/54

Page 26: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Multiresolution analysis on the R

A multiresolution analysis of L2(R) is a nested sequence of

closed subspaces Vj, j ∈ Z, of L2(R),

· · · ⊂ V−2 ⊂ V−1 ⊂ V0 ⊂ V1 ⊂ V2 ⊂ · · · ,

such that

∩jVj = {0}, ∪jVj = L2(R), f (x) ∈ Vj ⇔ f (2x) ∈ Vj+1,

There exists a function φ ∈ V0 such that

V0 =

{

f ∈ L2(R) : f (x) = ∑k∈Z

αkφ(x − k)

}

,

{φk, k ∈ Z} is a "stable” basis of V0, i.e. 0 < m ≤ ‖φk‖ ≤ M <

∞ and A‖ f ‖2 ≤ ∑k α2k ≤ B‖ f ‖2.

An Introduction to Wavelets and some Applications – p.11/54

Page 27: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

The function φ is called the scaling function of the MRA. Let

φj,k(x) = 2j/2φ(2jx − k).

For an orthogonal MRA, an orthonormal basis of Vj is

{φj,k : k ∈ Z} and

Pj f = ∑k∈Z

< f , φj,k > φj,k ,

is the approximation of f at resolution 2−j.If Wj is the orthogonal complement of Vj in Vj+1, we obtain

another sequence {Wj : j ∈ Z} of closed orthogonal

subspaces of L2(R), such that each Wj is a refinement of W0,

and their direct sum is L2(R).

An Introduction to Wavelets and some Applications – p.12/54

Page 28: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

One can show that there exists a function ψ such that W0 isspanned by its integer translates. Then ψ is called thewavelet associated to ϕ. For each integer j,the family

{ψj,k, k ∈ Z}

is an orthonormal basis of Wj.

If g ∈ L2(R) we have:

g = ∑k∈Z

cj0,k ϕj0,k + ∑j≥j0

∑k∈Z

dj,kψj,k

where j0 is a level of coarse approximation.

An Introduction to Wavelets and some Applications – p.13/54

Page 29: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

The first part in the right hand side is the orthogonalprojection Pj0 g of g on Vj0 , and the second part represents

the details. The coefficients are defined by

cj,k = 〈g, φj,k〉

anddj,k = 〈g, ψj,k〉.

The c’s are called the scaling coefficients while the d’s are the

wavelet coefficients.

An Introduction to Wavelets and some Applications – p.14/54

Page 30: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Filter banks

Since V0 ⊂ V1, any function of V0 has an expansion in termsof the basis {φ1,k, k ∈ Z} of V1. For φ(x) = φ0(x) = φ0,0(x)

we have

φ(x) = ∑k∈Z

akφ1,k(x) =√

2 ∑k∈Z

akφ(2x − k)

withak = 〈φ, φ1,k〉 ∈ `2(Z).

An Introduction to Wavelets and some Applications – p.15/54

Page 31: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

When the scaling functions are compactly supported, thereis only a finite number of non zero coefficients among theak’s and

φ(x) =√

2D−1

∑k=0

akφ(2x − k)

The coefficients a = {ak} define the filter corresponding toφ.

The scaling function is compactly supported if and only if a

has a finite number of non zero coefficients.

An Introduction to Wavelets and some Applications – p.16/54

Page 32: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

By analogy, and since W0 ⊂ V1 we also have

ψ(x) =√

2D−1

∑k=0

bkφ(2x − k)

withbk = 〈ψ, φ1,k〉 ∈ `2(Z).

The filters {ak} and {bk} are conjugate mirror filter banks.

An Introduction to Wavelets and some Applications – p.17/54

Page 33: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

A perfect reconstruction filter bank decomposes a signal byfiltering and subsampling. It reconstructs it by insertingzeroes, filtering and summation.

The filter bank is said to be a perfect reconstruction filter

bank when a2 = a0. If, additionally, h = h2 and g = g2, the

filters are called conjugate mirror filters.

An Introduction to Wavelets and some Applications – p.18/54

Page 34: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Numerical evaluation

No analytic formulas for evaluating numerically φ and ψ.

For compactly supported wavelets we have twoalgorithms :

An iterative algorithm (Daubechies and Lagariascascade algorithm).

An iterative method for solving the dilatationequations

An Introduction to Wavelets and some Applications – p.19/54

Page 35: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

The Cascade Algorithm

Build φ using the filter a0, . . . , aD−1 with D even and ≥ 4.Start with φ0(x) = I[0,1[(x). Compute then recursively the

successive approximations of φ(x) using a0, . . . , aD−1, i.e.

φm(x) =D−1

∑k=0

akφm−1(2x − k).

One can show that this algorithm converges towards φ,

when the iterations m converge to ∞. In practice, 8 iterations

suffice for a good discretization of φ.

An Introduction to Wavelets and some Applications – p.20/54

Page 36: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Example: φ Daubechies D = 4

0.5 1 1.5 2 2.5 3

-0.25

0.25

0.5

0.75

1

1.25

0.5 1 1.5 2 2.5 3

-0.25

0.25

0.5

0.75

1

1.25

0.5 1 1.5 2 2.5 3

-0.25

0.25

0.5

0.75

1

1.25

0.5 1 1.5 2 2.5 3

-0.25

0.25

0.5

0.75

1

1.25

0.5 1 1.5 2 2.5 3

-0.25

0.25

0.5

0.75

1

1.25

0.5 1 1.5 2 2.5 3

-0.25

0.25

0.5

0.75

1

1.25

Building φ by the cascade algorithm

An Introduction to Wavelets and some Applications – p.21/54

Page 37: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Periodic wavelets

Until now the functions were defined on R.While this seems reasonable for some applications, inpractice most functions are observed over boundeddomains .

There exist many ways to define a MRA adapted to abounded domain.

One of these, the most simple and direct way, is by usingperiodic wavelets.

Let the scaling function φ ∈ L2(R) and the associated

wavelet ψ ∈ L2(R) be given.

An Introduction to Wavelets and some Applications – p.22/54

Page 38: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

For all j, l ∈ Z, we define the periodic scaling function ofperiod 1, by

φj,l(x) =+∞

∑n=−∞

φj,l(x + n)

and the associated periodic wavelet by

ψj,l(x) =+∞

∑n=−∞

ψj,l(x + n).

An Introduction to Wavelets and some Applications – p.23/54

Page 39: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Note that, for j ≤ 0 and l ∈ Z,

φj,l(x) = 2j/2 ∑n

φ(2j(x + n − 2−jl)) = φj,0(x)

Therefore

j ≤ 0 φj,l(x) = 2−j/2.

Similarly we can show that

∀j ≤ −1, ψj,l = 0.

An Introduction to Wavelets and some Applications – p.24/54

Page 40: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

For φ and ψ generated with a filter of length D:

φj,l(x) = 2−j/2 for all j ≤ 0 and all l ∈ Z.

An Introduction to Wavelets and some Applications – p.25/54

Page 41: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

For φ and ψ generated with a filter of length D:

φj,l(x) = 2−j/2 for all j ≤ 0 and all l ∈ Z.

ψj,l(x) = 0 for all j ≤ −1 and all l ∈ Z.

An Introduction to Wavelets and some Applications – p.25/54

Page 42: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

For φ and ψ generated with a filter of length D:

φj,l(x) = 2−j/2 for all j ≤ 0 and all l ∈ Z.

ψj,l(x) = 0 for all j ≤ −1 and all l ∈ Z.

for all j > J0 ≥ log2(D − 1) and x ∈ [0, 1],

φj,l(x) = φj,l(x)IIj,l(x) + φj,l(x + 1)IIc

j,l(x)

with an identical relation for ψ.

An Introduction to Wavelets and some Applications – p.25/54

Page 43: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

For φ and ψ generated with a filter of length D:

φj,l(x) = 2−j/2 for all j ≤ 0 and all l ∈ Z.

ψj,l(x) = 0 for all j ≤ −1 and all l ∈ Z.

for all j > J0 ≥ log2(D − 1) and x ∈ [0, 1],

φj,l(x) = φj,l(x)IIj,l(x) + φj,l(x + 1)IIc

j,l(x)

with an identical relation for ψ.∫ 1

0f (x)φj,l(x)dx =

∫ ∞

−∞

f (x)φj,l(x)dx

(similarly for ψ) where f (x) = f (x − [x]), x ∈ R.

An Introduction to Wavelets and some Applications – p.25/54

Page 44: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

The periodic scaling functions and corresponding periodic

wavelets define an orthonormal MRA of L2([0, 1]).

The approximation and details spaces are given by:

Vj = span{

φj,l , l = 0, . . . , 2j − 1}

and

Wj = span{

ψj,l , l = 0, . . . , 2j − 1}

We obtain, for J0 ≥ 0 the following decomposition of

L2([0, 1]):

L2([0, 1]) = VJ0⊕(

⊕j≥J0Wj

)

.

An Introduction to Wavelets and some Applications – p.26/54

Page 45: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Fast discrete wavelet transform

Orthogonality of the scaling functions and the associatedwavelets lead to a fast computational algorithm fordecomposing or synthetizing a function of Vj.

Let f ∈ L2(R). We have

(PVjf )(x) = (PVj−1

f )(x) + (PWj−1f )(x),

formulated as

(PVjf )(x) = ∑

`∈Z

cj−1,`φj−1,`(x) + ∑`∈Z

dj−1,`ψj−1,`(x).

Aim: find a relation between the sequence of coefficients cj,`

and the sequences cj−1,` and dj−1,`.

An Introduction to Wavelets and some Applications – p.27/54

Page 46: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

The key is

φj−1,`(x) =D−1

∑k=0

akφj,2`+k(x) and ψj−1,`(x) =D−1

∑k=0

bkφj,2`+k(x)

We have

cj−1,` =

f (x)φj−1,`(x)dx =

f (x)D−1

∑k=0

akφj,2`+k(x)dx

=D−1

∑k=0

ak

f (x)φj,2`+k(x)dx =D−1

∑k=0

akcj,2`+k

and dj−1,` = ∑D−1k=0 bkcj,2`+k.

An Introduction to Wavelets and some Applications – p.28/54

Page 47: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Conversely, noting that

φj,`(x) = ∑k

a`−2kφj−1,k(x) + ∑k

b`−2kψj−1,k(x)

we obtain

cj,` = ∑k

a`−2kcj−1,k + ∑k

b`−2kdj−1,k(x)

These two above equations lead to the discrete fast wavelet

transform.

An Introduction to Wavelets and some Applications – p.29/54

Page 48: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

An example

As an example, let

c =

c3,0

c3,1

c3,2

c3,3

c3,4

c3,5

c3,6

c3,7

.

An Introduction to Wavelets and some Applications – p.30/54

Page 49: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

The decomposition steps are:

c3,0

c3,1

c3,2

c3,3

c3,4

c3,5

c3,6

c3,7

−→

c2,0

c2,1

c2,2

c2,3

d2,0

d2,1

d2,3

d2,4

−→

c1,0

c1,1

d1,0

d1,1

d2,0

d2,1

d2,3

d2,4

−→

c0,0

d0,0

d1,0

d1,1

d2,0

d2,1

d2,2

d2,4

.

The final vector is the results of the DWT of the initialvalues.

An Introduction to Wavelets and some Applications – p.31/54

Page 50: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Matrix Representation of the DWT

Let

cj = (cj,0, . . . , cj,2j−1)T

anddj = (dj,0, . . . , dj,2j−1)

T

The DWT equations define linear maps from R2j

to R2j−1

and may be written as:

cj−1 = Ajcj

dj−1 = Bjcj

where Aj and Bj are 2j−1 × 2j matrices defined via the filters.

An Introduction to Wavelets and some Applications – p.32/54

Page 51: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Approximation properties

A linear approximation of square integrable function f onan orthonormal basis B = {en}n∈Z projects f on the spacespanned by M vectors chosen a priori in B:

fM =M−1

∑n=0

〈 f , en〉en.

The quality of the approximation

‖ f − fM‖2 = ∑n≥M

|〈 f , en〉|2

depends on the properties of f with respect to B.

An Introduction to Wavelets and some Applications – p.33/54

Page 52: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Fourier analysis provides efficient approximations forglobal smooth functions by projecting them on the spacespanned by sinusoidal waves of frequencies the first M lowfrequencies.

In a wavelet basis the signal is projected on VM.

Here too, the quality of approximation depends on the

global regularity of the function l f .

An Introduction to Wavelets and some Applications – p.34/54

Page 53: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Nonlinear approximation

A linear approximation of f may be enhanced if the Mvectors are chosen a posteriori, in a way that depends on f .

For M fixed, the approximation error is minimized bytaking the M vectors for which the coefficients |〈 f , en〉| arethe largest.

If B is a wavelet basis,the amplitude of the coefficients isrelated to the local regularity of f and a nonlinearapproximation amounts in using an adaptative samplingwhose resolution increases locally where the function isirregular.

An Introduction to Wavelets and some Applications – p.35/54

Page 54: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

First application: Compression

Consider a function f expanded in a basis as

f (x) =m

∑k=1

ckek(x).

The input data are the coefficients c1, . . . , cm. The aim ofcompression is to define an approximation of f using muchless coefficients (possible in a different basis) with aminimum loss of information.Given an upper bound for the error, say ε > 0, we seek

f (x) =m

∑k=1

ck ek(x)

with m < m and ‖ f − f ‖ ≤ ε. An Introduction to Wavelets and some Applications – p.36/54

Page 55: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

For simplicity consider that the basis is fixed one for all andthat it is orthonormal.Let σ be a permutation of {1, 2, . . . , m} and let f theapproximation using the first m coefficients of thepermutation σ :

f (x) =m

∑k=1

cσ(k)eσ(k)(x).

The L2 error of this approximation is ‖ f − f ‖22 =

∑mk=m+1 |cσ(k)|2. To minimize it σ must rank the coefficients

in a decreasing order of their absolute magnitude.

An Introduction to Wavelets and some Applications – p.37/54

Page 56: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Example

JumpSine Signal

0.0 0.2 0.4 0.6 0.8 1.0

-15

-10

-50

51

0

0.0 0.2 0.4 0.6 0.8 1.0

-15

-10

-50

51

0

50 Top Wavelet Coeffs

error = 0.0027

0.0 0.2 0.4 0.6 0.8 1.0

-15

-10

-50

51

0

0.0 0.2 0.4 0.6 0.8 1.0

-15

-10

-50

51

0

800 Top Fourier Coeffs

error =0.0130

0.0 0.2 0.4 0.6 0.8 1.0

-15

-10

-50

51

0

0.0 0.2 0.4 0.6 0.8 1.0

-15

-10

-50

51

0

50 Top Fourier Coeffs

0.0 0.2 0.4 0.6 0.8 1.0

-15

-10

-50

51

0

Compression

Compression exampleAn Introduction to Wavelets and some Applications – p.38/54

Page 57: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Second application: denoising

Data :Yj = f (tj) + εj, j = 1, . . . , n

Usually : tj equidistant, n = 2m, and εj i.i.d mean 0 and

variance σ2. In practice,

nonequispaced design;

An Introduction to Wavelets and some Applications – p.39/54

Page 58: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Second application: denoising

Data :Yj = f (tj) + εj, j = 1, . . . , n

Usually : tj equidistant, n = 2m, and εj i.i.d mean 0 and

variance σ2. In practice,

nonequispaced design;

number of data points not a power of 2.

An Introduction to Wavelets and some Applications – p.39/54

Page 59: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Second application: denoising

Data :Yj = f (tj) + εj, j = 1, . . . , n

Usually : tj equidistant, n = 2m, and εj i.i.d mean 0 and

variance σ2. In practice,

nonequispaced design;

number of data points not a power of 2.

design may be random;

An Introduction to Wavelets and some Applications – p.39/54

Page 60: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Second application: denoising

Data :Yj = f (tj) + εj, j = 1, . . . , n

Usually : tj equidistant, n = 2m, and εj i.i.d mean 0 and

variance σ2. In practice,

nonequispaced design;

number of data points not a power of 2.

design may be random;

the errors may not be of constant variance;

An Introduction to Wavelets and some Applications – p.39/54

Page 61: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Linear methods

Extension of penalized least-squares methods

An Introduction to Wavelets and some Applications – p.40/54

Page 62: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Linear methods

Extension of penalized least-squares methods

choice of the smoothing parameter by GCV.

An Introduction to Wavelets and some Applications – p.40/54

Page 63: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Linear methods

Extension of penalized least-squares methods

choice of the smoothing parameter by GCV.

An example.

An Introduction to Wavelets and some Applications – p.40/54

Page 64: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Simple idea:

Approximate 2m/2〈 f , φm,k〉 ∼ f (k/2m) and replace the raw

data {Yi} by its interpolation in Vm:

fm(t) = 2−m/2 ∑k∈Z

Ykφm,k(t)

Minimize‖ fm − f ‖2

L2([0,1])+ λJ

pspp(PVJ0

f )

where J0 is given et Jspp is norm on Bspp([0, 1]).

An Introduction to Wavelets and some Applications – p.41/54

Page 65: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

The norm of g ∈ Bspq([0, 1]) is equivalent to

Jspq(α, β) = ‖αj0·‖p +

(

∑j=0

(2j(s+(1/2)−(1/p))‖β j·‖p)q

)1/q

.

An Introduction to Wavelets and some Applications – p.42/54

Page 66: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

The solution

fλ =2j0−1

∑k=0

cj0,k ϕJ0,k +m

∑j=J0

2j−1

∑k=0

β j,kψj,k,

• cj0,k, k = 0, . . . , 2j0 − 1 are the scaling coefficients of the

DWT of fm.

• β j,k =dj,k

1+λ22sj , j ≥ j0, k = 0, . . . , 2j − 1, with dj,k the

wavelet coefficients of W fm.

An Introduction to Wavelets and some Applications – p.43/54

Page 67: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Cross validation

One may choose J0 and λ given the data and show that theresulting estimation has good properties (at leastasymptotically). One popular method is cross validation.

voltage drop vs time.

0 2 4 6 8 10 12 14 16 187

8

9

10

11

12

13

14

15

16

A real data example with D8 compared to spline smoothing

An Introduction to Wavelets and some Applications – p.44/54

Page 68: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Nonlinear methods

Decompose the signal into its wavelet coefficients

An Introduction to Wavelets and some Applications – p.45/54

Page 69: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Nonlinear methods

Decompose the signal into its wavelet coefficients

Extract the most significant coefficients by shrinkageor thresholding.

An Introduction to Wavelets and some Applications – p.45/54

Page 70: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Nonlinear methods

Decompose the signal into its wavelet coefficients

Extract the most significant coefficients by shrinkageor thresholding.

Denoise by applying the inverse wavelet transform onthe resulting coefficients.

An Introduction to Wavelets and some Applications – p.45/54

Page 71: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Almost all existing nonlinear methods are of the form:

2−1n

∑i=1

(zi − θi)2 + λ ∑

i≥i0

p(|θi|),

where zi is the ith row of z = WYn and pλ is anappropriate penalty function.

An Introduction to Wavelets and some Applications – p.46/54

Page 72: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Hard thresholding

1. Transform the data via DWT : Θ = W · Y.

2. To separate the signal form its noise, threshold the

coefficients: set θj,k = θj,k if |θj,k| is large, 0 otherwise.

3. Estimate the signal by f = W−1 · Θ.

An Introduction to Wavelets and some Applications – p.47/54

Page 73: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Soft thresholding

1. Transform the data via DWT : Θ = W · Y.

2. To separate the signal form its noise, threshold thecoefficients: set

θj,k =

{

θj,k − λ, si |θj,k| > λ,

0, si |θj,k| ≤ λ,

3. Estimate the signal by f = W−1 · Θ.

Many ways for choosing the thresholds.The initial resolu-

tion j0 is usually set to (log2 N)/2.

An Introduction to Wavelets and some Applications – p.48/54

Page 74: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Examples

(a) Lp penalty with p = 1 (soft (p=1)), p = 0.6 (short dash)

and p = 0.2 (solid); (b) hard; (c) SCAD (robust); (d)transformed soft.

-5 0 50

0.5

1

1.5

2

2.5

3

(a) Lp penalties p=1, 0.6, 0.2

θ

penalty

-5 0 50

0.5

1

1.5

2

2.5

3 (b) Hard thresholding

θ

penalty

-5 0 50

0.5

1

1.5

2

2.5

3

(c) Smoothly clipped L1 penalty

θ

penalty

-5 0 50

0.5

1

1.5

2

2.5

3

(d) Transformed L1 penalty

penalty

θAn Introduction to Wavelets and some Applications – p.49/54

Page 75: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

-5 0 5-5

0

5

(a) Hard thresholding and L1 penalty

-5 0 5-5

0

5

(b) Lp penalty (p=0.6)

-5 0 5-5

0

5

(c) Smoothly clipped L1 penalty

-5 0 5-5

0

5

(d)Transformed L1

penalty

Corresponding estimates

An Introduction to Wavelets and some Applications – p.50/54

Page 76: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Universal thresholding (VisuShrink)

When the noise is Gaussina, most of the coefficients

(normalized as:√

Ndj,k/σ) are essentially white noise. This

suggests to take λ =√

2 log N, producing the principleVisuShrink implemented in the package wavethresh of R.

Noisy Signal

0.0 0.2 0.4 0.6 0.8 1.0

-10

-50

5

0 200 400 600 800 1000

s6

d6

d5

d4

d3

d2

d1

idwt

Wavelet Coeffs

Reconstruction

0.0 0.2 0.4 0.6 0.8 1.0

-10

-50

5

0 200 400 600 800 1000

s6

d6

d5

d4

d3

d2

d1

idwt

VisuShrink

VisuShrinkAn Introduction to Wavelets and some Applications – p.51/54

Page 77: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Properties

When compared, it seems that hard thresholding producesestimates with larger variance while soft thresholding ismore biased.Some authors propose a robust version:

θλ1,λ2j,k =

0 si |θj,k| ≤ λ1

sgn(θj,k)λ2(|θj,k|−λ1)

λ2−λ1si λ1 < |θj,k| ≤ λ2

θj,k si |θj,k| > λ2,

which groups the advantages of both thresholding methods

An Introduction to Wavelets and some Applications – p.52/54

Page 78: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

References

Newland D. E (1994) An Introduction to Random Vibrations,Spectral and Wavelet Analysis, Third Edition, (Wiley).

Koornwinder, T H (1993) Wavelets: An ElementaryTreatment in Theory and Applications, (World Scientific,Singapore).

Strang, G. (1989) Wavelets and Dilation equations: A BriefIntroduction, dans SIAM Review, 31(4) 614-627.

Daubechies, I. (1992) Ten Lectures on Wavelets, CBMS-NSFSeries in Applied Mathematics (SIAM Publications,Philadelphia).

Chui, C. K. (1992) An Introduction to Wavelets, (AcademicPress).

An Introduction to Wavelets and some Applications – p.53/54

Page 79: An Introduction to Wavelets and some Applications · An Introduction to Wavelets and some Applications Milan, May 2003 Anestis Antoniadis Laboratoire IMAG-LMC ... without going to

Software

WaveLab for Matlab.

Wavelet Toolbox for Matlab.

Wavelab for Scilab.

S+Wavelets for S-plus.

Wavetresh 2.2 for S-plus and R.

Many new denoising algorithms are implemented inMATLAB and are available at

www-lmc.imag.fr/SMS/software

An Introduction to Wavelets and some Applications – p.54/54