MATLAB: How to find psi function in Haar continuous wavlelet transform:CWT

haar wavelet transform

Dear all, I has a problem when i try to use Haar wavelet to reconstruct an impact force-F if I know response (strain-e). Lets me describe:
I have impact force (F is a matrix 1×1024) and response (strain e: matrix 1×1024). After using CWT in matlab with scale m=2,4,8,16,32,64,128,256,512,1024, i got a matrix of coefficient (1024×10). And I know that CWT is actually a convolution between F and Psi(Haar wavelet function).
I would like to ask How can i get Psi(Haar wavelet func…) which corresponds to each scale of m?
Thank you so much for your help

Best Answer

Hi Hai Tran, If you are using dyadic scales as you do above, I think you would be better to use the MODWT (introduced in R2015b, rather than the CWT). With the MODWT, you do not lose time resolution just like with the CWT but if you are willing to restrict yourself to the dyadic scales, the MODWT has a lot of advantages (energy preservation -- perfect reconstruction just to name a couple important ones).
That said, here is a way to get an idea what the "daughter" wavelets look like at each scale.
scales = 2.^(1:10);
delta = zeros(1024,1);
% Only provides daughter wavelets at one translation
delta(500) = 1;
dwaves = cwt(delta,scales,'haar');
Now each row of dwaves will actually be the time-reverse of the Haar wavelet at that scale.
For scale 32 (2^5)
w5 = fliplr(dwaves(5,:));