create_PSI_DWT

PURPOSE ^

Arrange DWT syntheis matrices over P overlapping windows (edges ignored)

SYNOPSIS ^

function PSI = create_PSI_DWT(in)

DESCRIPTION ^

 Arrange DWT syntheis matrices over P overlapping windows (edges ignored)

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function PSI = create_PSI_DWT(in)
0002 % Arrange DWT syntheis matrices over P overlapping windows (edges ignored)
0003 
0004 % Input
0005 %   P -- desired number of interval
0006 %   Psi -- a fixed matrix or a function handle to create Psi over one
0007 %   interval
0008 %   Np -- length of intervals
0009 %           Example: Np = [N, N, N, ... ]
0010 %   wType -- type of wavelets
0011 %   Jp   -- depth of wavelet scales at pth interval...
0012 %   sym -- type of signal extension at the border
0013 
0014 P = in.P;
0015 
0016 if ~isfield(in,'Np');
0017     Psi = in.Psi; 
0018     [L N] = size(Psi); 
0019     
0020     PSI = [];
0021     for p = 1:P
0022         PSI((p-1)*N+1:(p-1)*N+L,(p-1)*N+1:p*N) = Psi;
0023     end
0024 else
0025     Np = in.Np; 
0026     Jp = in.Jp; 
0027     wType = in.wType;
0028     sym = in.sym;
0029     if length(Np) ~= length(Jp)
0030         error('number of wavelet parameters is not correct');
0031     end
0032     PSI = [];
0033     pr = 1; pc = 1;
0034     for p = 1:length(Np)
0035         N = Np(p);
0036         J = Jp(p); 
0037         in_Psi = []; in_Psi.N = N; in_Psi.wType = wType; in_Psi.J = J; in_Psi.sym = sym;
0038         Psi = create_DWT(in_Psi); % DWT synthesis matrix over a window
0039         L = size(Psi,1);
0040         PSI(pr:pr+L-1,pc:pc+N-1) = Psi;
0041         pr = pr+N;
0042         pc = pc+N;
0043     end
0044 end

Generated on Mon 10-Jun-2013 23:03:23 by m2html © 2005