delay of swt command
4 次查看(过去 30 天)
显示 更早的评论
Hi, I am trying to decompose a 1D signal with swt command. What I find is that the decomposed signals always have a (negative) delay compared to the original signal.
For example, the following code will generate the attached plot. Is there a way to get rid of this delay? (PS: I am trying to implement the a trous alogrithm.)
clear all
close all
clc
%%construct signal
N = 128;
ecg = zeros(N,1);
ecg(N/2) = 1;
%%decompose with wavelet transform
h = [+1 +3 +3 +1]/8;
g = [-2 +2];
[ecga,ecgd] = swt(ecg,5,h,g);
%%plot
figure
set(gcf,'unit','normalized')
set(gcf,'position',[0.05 0.05 0.7 0.7])
ax(1) = subplot(5,1,1);
plot(ecg)
grid on
box on
ax(2) = subplot(5,1,2);
plot(ecgd(1,:))
grid on
box on
ax(3) = subplot(5,1,3);
plot(ecgd(2,:))
grid on
box on
ax(4) = subplot(5,1,4);
plot(ecgd(3,:))
grid on
box on
ax(5) = subplot(5,1,5);
plot(ecgd(4,:))
grid on
box on
linkaxes(ax,'x')
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/146163/image.jpeg)
0 个评论
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Continuous Wavelet Transforms 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!