# Undecimated Wavelet Transform (a trous algorithm) - how to determine 'anchor'/'center' of convolution filter

i am currently implementing the 'Undecimated Wavelet Transform' with the 'a trous' algorithm. See e.g. http://www.znu.ac.ir/data/members/fazli_saeid/DIP/Paper/ISSUE2/04060954_2.pdf, section II-A.

As far as I understand, the implementation (in 1D) for the 'decomposition' and 'reconstruction' phase is very simple, it boils down to the convolution with a low-pass and high-pass filter (where for levels > 0, one has to add zeros between the coefficients of the filters).

E.g. for the decomposition filter of the 'Bior1.3' wavelet, i have the following filters for level 0, 1, 2 of size 6, 11 (6+5) and 16 (6 + 10):

level 0: [c1 c2 c3 c4 c5 c6]

level 1: [c1 0 c2 0 c3 0 c4 0 c5 0 c6]

level 2: [c1 0 0 c2 0 0 c3 0 0 c4 0 0 c5 0 0 c6]

I hope I inserted the zeros on the right places, if not please correct me. The actual values of the coefficients c1, c2, c3, c4, c5, c6 can be found at http://wavelets.pybytes.com/wavelet/bior1.3/.

My questions is now, what is the 'anchor' of this filter kernels, how can the anchor be calculated in a general way (for decomposition/reconstruction filters of different wavelet classes) ? I suppose its something like 'anchor_index = round_down(kernel_size / 2)', when anchor_index is 0-indexed, but i'm not sure.

Note that for implementing a convolution with a certain kernel, one has to know always the 'anchor' of the kernel (the index of the coefficient in the filter which is multiplied with the 'current' array element).

• visit this to write in Latex : meta.math.stackexchange.com/questions/5020/… – Shobhit Sep 4 '13 at 9:29
• In short, level 2 would be 3 zeros in between instead of 2. Level 3 would be 7 zeros in between, level k would be $2^k-1$ zeros in between. This is because of the dyadic down-sampling, usually throwing away every second sample after one level is finished. – mathreadler Jun 21 '15 at 22:43

If down-sampling is not done, then $[c_1,0,c_2,0,c_3,\cdots]$ will be the filter to apply on the next level. Since the ordinary is DWT dyadic, the next step will be $[c_1,0,0,0,c_2,0,0,0,c_3,\cdots]$, where every fourth position is a filter coefficient. Next level it will be every eight, and so on.