Inverse Continuous wavelet transformation
1 view (last 30 days)
Show older comments
I am using a simple sine wave to find its cwt and using the cwt out put parameters in icwt function i am looking to get the original sine wave. But I am not getting the initial sine wave after applying ICWT. The amplitudes are not also same. Please help me out. I am attaching the code below.
clc
clear all
close all
time = 2;
samp = 1000;
dt = time/samp;
t = [0:dt:time];
y = 5*sin(2*pi*10.*t);
[cfs,f] = cwt(y,(1/dt));
xrec = icwt(cfs,[],f,[9.6 10.5]);
subplot(2,1,1)
plot(t,y)
grid on
title("Original Data")
ylabel("Amplitude")
axis tight
subplot(2,1,2)
plot(t,xrec)
grid on
title("Reconstructed");
xlabel("Time (s)")
ylabel("Amplitude")
axis tight
0 Comments
Answers (1)
Nadia Shaik
on 9 Jan 2023
Hi Subrat,
I understand that you are applying 'cwt' function to a sine wave and then performing 'icwt' and are observing some deviation between the original signal and the reconstructed signal.
In the code shared by you, a frequency range is mentioned for which the inverse continuous wavelet transform values are calculated, which resulted in a large deviation between the original signal and reconstructed signal. Consider removing the frequency range and observe the changes. However, note that there can still be some deviations between the original and reconstructed signals.
I hope this helps.
0 Comments
See Also
Categories
Find more on Continuous Wavelet Transforms in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!