function rsig=iwt(w,s,m)

%%%backward dyadic wavelet transform%%%%%%

%w--------wavelet coefficients
%s--------smoothed signal

%rsig-----reconstructed signal

[J,n]=size(w);

j=J;
while j>0
  r=conv(s,getnh(j-1))+conv(w(j,:),getk(j-1));
  s=r(128:128+n-1);
  j=j-1; 
end

rsig=s(m+1:n-m);

return;