Multilevel 1-D wavelet decomposition.
[C,L] = wavedec(X,N,'
wname') [C,L] = wavedec(X,N,Lo_D,Hi_D)
wavedec performs a multilevel one-dimensional wavelet analysis using either a specific wavelet ('
wname') or a specific wavelet decomposition filters (
[C,L] = wavedec(X,N,'
) returns the wavelet decomposition of the signal
X at level
N, using '
N must be a strictly positive integer (see
wmaxlev for more information). The output decomposition structure contains the wavelet decomposition vector
C and the bookkeeping vector
L. The structure is organized as in this level-3 decomposition example:
[C,L] = wavedec(X,N,Lo_D,Hi_D) returns the decomposition structure as above, given the low- and high-pass decomposition filters you specify.
% The current extension mode is zero-padding (see
dwtmode). % Load original one-dimensional signal. load sumsin; s = sumsin; % Perform decomposition at level 3 of s using db1. [c,l] = wavedec(s,3,'db1'); % Using some plotting commands, % the following figure is generated.
Given a signal s of length N, the DWT consists of log2 N stages at most. The first step produces, starting from s, two sets of coefficients: approximation coefficients CA1, and detail coefficients CD1. These vectors are obtained by convolving s with the low-pass filter
Lo_D for approximation, and with the high-pass filter
Hi_D for detail, followed by dyadic decimation (downsampling).
More precisely, the first step is:
The length of each filter is equal to 2N. If n = length(s), the signals F and G are of length n + 2N - 1 and the coefficients cA1 and cD1 are of length:
The next step splits the approximation coefficients cA1 in two parts using the same scheme, replacing s by cA1, and producing cA2 and cD2, and so on
The wavelet decomposition of the signal s analyzed at level j has the following structure: [cAj, cDj, ..., cD1].
This structure contains, for J = 3, the terminal nodes of the following tree:
dwt, waveinfo, wfilters, wmaxlev
Daubechies, I. (1992), Ten lectures on wavelets, CBMS-NSF conference series in applied mathematics. SIAM Ed.
Mallat, S. (1989), "A theory for multiresolution signal decomposition: the wavelet representation," IEEE Pattern Anal. and Machine Intell., vol. 11, no. 7, pp 674-693.
Meyer, Y. (1990), Ondelettes et opérateurs, Tome 1, Hermann Ed. (English translation: Wavelets and operators, Cambridge Univ. Press. 1993.)