# Harmonics to Noise Ratio Estimation

I'm willing to estimate the Harmonics to Noise Ratio (HNR) of a speech signal x[k] and using autocorrelation method.

Theoretically, HNR is given as,

$$\ HNR = \frac{R_{xx}[T_0] }{R_{xx}-R_{xx}[T_0]}$$

where $$\ R_{xx}$$ is the autocorrelation function (ACF) and estimated as,

$$R_{xx,biased}[l] = \frac{1}{N} \sum_{k=l}^{N-1}{x[k]x[k-l]}$$

and,

$$R_{xx,unbiased}[l] = \frac{1}{N-l} \sum_{k=l}^{N-1}{x[k]x[k-l]}$$

My question is how can I choose ACF function? Should it be biased or unbiased?

Constraints are signal x should be stationary (so I use the small part of the signal to be stationary) and noise is white and should be uncorreleated (N should be large enough). But these constraints has nothing to do the with type of the ACF estimation.

• Did you find a solution for this? Any Matlab code? – Filipe Pinto Jun 14 '18 at 11:10
• Filipe Pinto there is no matlab code but unbiased one should be used. I figured out that under noise biased version performs worse. Estimate returns larger error. – kubicwerke Jun 15 '18 at 18:19
• what is $T_0$ ? – robert bristow-johnson Sep 15 '18 at 2:27

It means it has many nice properties for $N \to \infty$.
The Unbiased version is Minimum Variance Unbiased Estimator (MVUE) of the problem. Yet in practice when $N$ is large, as in your case, it won't matter much and there won't be any difference between the two.