Main Content

upwlev2

Single-level reconstruction of 2-D wavelet decomposition

Syntax

[NC,NS,cA] = upwlev2(C,S,wname)
[NC,NS,cA] = upwlev2(C,S,Lo_R,Hi_R)

Description

upwlev2 is a two-dimensional wavelet analysis function.

[NC,NS,cA] = upwlev2(C,S,wname) performs the single-level reconstruction of wavelet decomposition structure [C,S] giving the new one [NC,NS], and extracts the last approximation coefficients matrix cA.

[C,S] is a decomposition at level n = size(S,1)-2, so [NC,NS] is the same decomposition at level n-1 and cA is the approximation matrix at level n.

wname is a character vector or string scalar specifying the wavelet, C is the original wavelet decomposition vector, and S the corresponding bookkeeping matrix (for detailed storage information, see wavedec2).

Instead of giving the wavelet name, you can give the filters.

For [NC,NS,cA] = upwlev2(C,S,Lo_R,Hi_R), Lo_R is the reconstruction low-pass filter and Hi_R is the reconstruction high-pass filter.

Examples

% The current extension mode is zero-padding (see dwtmode).

% Load original image. 
load woman; 
% X contains the loaded image.

% Perform decomposition at level 2 
% of X using db1. 
[c,s] = wavedec2(X,2,'db1');
sc = size(c)

sc =
    1   65536

val_s = s 

val_s =
    64   64 
    64   64 
    128  128 
    256  256

% One step reconstruction of wavelet 
% decomposition structure [c,s]. 
[nc,ns] = upwlev2(c,s,'db1');
snc = size(nc)

snc =
    1   65536

val_ns = ns

val_ns =
    128   128 
    128   128 
    256   256

Version History

Introduced before R2006a

See Also

| |