Steve
2016-09-19 14:36:30 UTC
I know this is 20 year old code, but in looking for why my program produces
different pitch values (off by a fraction), I am looking at this algorithm
in lpc.c:
void levinson_durbin( float R[], float lpcs[], int order) {
float a[order+1][order+1]; <---- automatic no initialization
for(i=1; i<=order; i++) {
sum = 0.0;
for(j=1; j<=i-1; j++)
sum += a[i-1][j]*R[i-j]; <-- R multiplied by unknown data
I've even looked at the referenced Makhoul paper, and it glosses over
whatever "a" is supposed to be initially assigned.
I tried assigning 1.0 to "a" elements. Even -1.0 just for kicks.
I guess it doesn't really matter what "a" is, as it seems to work anyway??
different pitch values (off by a fraction), I am looking at this algorithm
in lpc.c:
void levinson_durbin( float R[], float lpcs[], int order) {
float a[order+1][order+1]; <---- automatic no initialization
for(i=1; i<=order; i++) {
sum = 0.0;
for(j=1; j<=i-1; j++)
sum += a[i-1][j]*R[i-j]; <-- R multiplied by unknown data
I've even looked at the referenced Makhoul paper, and it glosses over
whatever "a" is supposed to be initially assigned.
I tried assigning 1.0 to "a" elements. Even -1.0 just for kicks.
I guess it doesn't really matter what "a" is, as it seems to work anyway??