Up: Digital Audio Restoration Previous: Click and Pop detection

Click Repair using Least Squares AutoRegressive Interpolation

Now that we've identified the audio sample damaged by the click (whose true values are unknown), we need to estimate the unknown samples. First we start by finding P coefficients a[i] for the autoregressive model, which is:

(1) \( s[n]=\sum\limits _{i=1}^{P}s[n-i]a[i]+e[n] \)

where s[n] is the signal value for the sample number n, and e[n] is the error term of the autoregressive model for sample n. For a simple example we'll let P=2 and n=6. The coefficients are determined using ordinary least squares techniques using good samples before and behind the unkown section. (1) can be rearranged:

(2) \( e[n]=s[n]-\sum\limits _{i=1}^{P}s[n-1]a[i] \)

This can be further written in matrix notation as:

e = A * s

s (the original row vector of signal data) is modified, so that all the unknown sample values are set to zero, i.e. s = [s1 s2 0 0 s5 s6 ].

A is constructed so the product A * s will produce (2):

A = \( \left[ \begin{array}{cccccc}
-a_{2} & -a_{1} & 1 & 0 & 0 & 0\\
0 & -a_{2} & ...
...-a_{2} & -a_{1} & 1 & 0\\
0 & 0 & 0 & -a_{2} & -a_{1} & 1
\end{array}\right] \)

Au is now constructed from the columns in A corresponding to the unknown signal columns in s:

Au = \( \left[ \begin{array}{cc}
1 & 0\\
-a_{1} & 1\\
-a_{2} & -a_{1}\\
0 & -a_{2}
\end{array}\right] \)

(And then a matrix algebra miracle occurs), ``the minimum variance unbiased missing estimator for the missing data 1'' is

\( s_{u}=-(A_{u}^{T}*A_{u})^{-1}*A_{u}^{T}*A*s \)


next up previous
Up: Digital Audio Restoration Previous: Click and Pop detection

2001-09-11