autocorrelation with 0 lag for LPC in speex library

Started by Anton July 28, 2006

I saw in the sources for the speex library (
that they add some value to the first autocorrelation result.
The results are used to produce a IIR with a levinson durbin

   float d;
   int i;
   while (lag--) 
      for (i = lag, d = 0; i < n; i++) 
         d += x[i] * x[i-lag];
      ac[lag] = d;

   ac[0] += 10;

So the autocorrelation with zero lag is just the
 signal energy, right?  I played around with this value
and if I don't add something here the levison durbin recursion
produces unstable filters.

Does anybody understand why that is necessary and what
exactly the effect of it is?

I thought that I once read that LPC coefficients produced by
autocorrelation -> levinson durbin are guaranteed to be stable.