moerjielovecookie

Sawen_Blog

一个普通工科牲的博客网站
x
github
follow
email

Limited Word Length Effect

The essence of digital signal processing is numerical computation. During the computation process, coefficients, inputs, outputs, etc., in the system must be stored in finite-length storage units in binary form, and at this point, the precision of finite-length numbers is limited. Errors may occur in specific implementations. The factors causing errors in digital systems due to finite word length are mainly the following three:

  1. Quantization effects produced when the AD converter converts the analog input signal into a set of discrete levels.
  2. Quantization effects produced when coefficients are represented by finite-length binary numbers.
  3. Finite word length effects caused by truncation operations performed to limit word length and by compressing signal levels to prevent overflow.

1 Finite Word Length Effect of AD Conversion#

AD converters can be divided into two parts: sampling and quantization. Sampling converts continuous analog signals into discrete signals, while quantization represents each sampled value using finite word length. Its statistically equivalent structure is shown in the figure:
image
The quantized values can be expressed as the sum of the exact sampled value and the quantization error, that is,

x^(n)=Q[x(n)]=x(n)+e(n)\hat{x}(n)=Q[x(n)]=x(n)+e(n)

This model is based on the following assumptions:

  • $e(n)$ is a stationary random sampling sequence
  • $e(n)$ has uniform distribution characteristics
  • $e(n)$ has a white noise process
  • $e(n)$ is uncorrelated with $x(n)$
    Since $e(n)$ has a uniform distribution, the probability distributions of rounding errors, two's complement truncation, and sign-magnitude truncation are shown as follows:
    image
  • For rounding, the mean is 0, and the variance is $\frac{\delta^2}{2}$
  • For two's complement truncation, the mean is $-\frac{\delta}{2}$, and the variance is $\frac{\delta^2}{12}$
  • For sign-magnitude truncation, the mean is 0, and the variance is $\frac{\delta^2}{3}$
    The expression for quantization signal-to-noise ratio is
SNRAD=10lg(δx2δe2)=10lg(12×22Lδx2)=6.02B+10.79+10lg(δx2)SNR_{AD}=10\lg(\frac{\delta^2_x}{\delta_e^2})=10\lg(12\times2^{2L}\delta_x^2)\\ =6.02B+10.79+10\lg(\delta^2_x)

It can be concluded that after rounding, for each additional bit of word length, the SNR increases by approximately 6dB.

2 Finite Word Length Effect in System Computation#

For binary operations, the addition of fixed-point numbers does not change the word length but may cause data overflow. The multiplication of fixed-point numbers has a word length effect because multiplying two fixed-point numbers of B bits requires data of 2B bits to retain all significant bits, and data truncation or rounding will inevitably introduce word length effects.
If the word length is increased during the computation process to ensure that the results do not suffer from truncation and rounding, resource consumption increases. This can be done in systems without feedback. However, in systems with feedback networks, such as digital filters, each closed-loop operation increases a portion of the word length, leading to an increasing demand for resources over repeated operations.

Loading...
Ownership of this post data is guaranteed by blockchain and smart contracts to the creator alone.