This function carries out a modified wavelet reconstruction: It reconstructs the signal with the wavelet coefficients from only one single level. All other coefficients are set zero. This operation is useful for some wavelet analysis, e.g. multi-resolution analysis and wavelet de-noising.
The definitions of input parameters, c and len, are same as the function wavDec().
Refer to the section of wavelet Families for the detailed information about the available wavelets.
The default input values provide a quick example.
function wavRec1 input Real c[:] = {-0.707, -0.707, -0.707, -0.7069999999999999, -0.707, -0.7069999999999999, 0.707, 0.0, -1.9993959999999997, -1.9993959999999997, 0.49984899999999993, -1.4135729719999994, 3.1805391869999995, 5.6542918879999995, 3.887325672999999} "Wavelet coefficients of all levels"; input Integer len[:] = {13, 7, 4, 2, 2} "Lengths of coefficients of all levels"; input Real lor[:] = {0.707, 0.707} "Low pass filter for reconstruction"; input Real hir[size(lor, 1)] = {0.707, -0.707} "High pass filter for reconstruction"; input Integer level = 2 "The level to be reconstructed. 1..N are for the detail levels, where N is the maximum decomposition level. 1 stands for the most detail level (highest frequency). N+1 is for the approximation level."; output Real y[:] "Reconstructed signal"; end wavRec1;