LPC - Linear Predictive Coding

DSP.LPC.lpcFunction
lpc(x::AbstractVector, p::Integer, [LPCBurg()])

Given input signal x and prediction order p, returns IIR coefficients a and average reconstruction error prediction_err. Note that this method does NOT return the leading $1$ present in the true autocorrelative estimate; it omits it as it is implicit in every LPC estimate, and must be manually reintroduced if the returned vector should be treated as a polynomial.

The algorithm used is determined by the last optional parameter, and can be either LPCBurg (arburg) or LPCLevinson (levinson).

source
DSP.LPC.arburgFunction
arburg(x::AbstractVector, p::Integer)

LPC (Linear Predictive Coding) estimation, using the Burg method. This function implements the mathematics published in [Lagrange], and the recursion relation as noted in [Vos], in turn referenced from [Andersen].

source
DSP.LPC.levinsonFunction
levinson(x::AbstractVector, p::Integer)

Implements Levinson recursion, as described in [Levinson], to find the solution a of the linear equation

\[\mathbf{T} (-\vec{a}) = \begin{bmatrix} x_2 \\ \vdots \\ x_{p+1} \end{bmatrix}\]

in the case where $\mathbf{T}$ is Hermitian and Toeplitz, with first column x[1:p]. This function can be used for LPC (Linear Predictive Coding) estimation, by providing LPCLevinson() as an argument to lpc.

source
  • LagrangeEnhanced Partial Tracking Using Linear Prediction. [DAFX 2003 article, Lagrange et al] (http://www.sylvain-marchand.info/Publications/dafx03.pdf)
  • Vos[A Fast Implementation of Burg’s Method] (https://www.opus-codec.org/docs/vos_fastburg.pdf). © 2013 Koen Vos, licensed under [CC BY 3.0] (https://creativecommons.org/licenses/by/3.0/)
  • AndersenN. Andersen. Comments on the performance of maximum entropy algorithms. Proceedings of the IEEE 66.11: 1581-1582, 1978.
  • LevinsonThe Wiener (RMS) Error Criterion in Filter Design and Prediction. N. Levinson, Studies in Applied Mathematics 25(1946), 261-278.
    https://doi.org/10.1002/sapm1946251261