A 32 point FFT in embedded MATLAB using fixed point arithmetic
DFT plays important role in DSP and used in wide variety of applications like correlation and spectral analysis. Understanding quantization errors in its computation is an important aspect of its design either for s/w or h/w implementation.
A complex DFT of N points has N complex (4N real) mutliplications. In the fixed point implementation of the DFT each mutliplication introduces a quantization error (all the errors are mutually uncorrelated and uncorrelated with input sequence as well).
FFT provides an efficient way to compute DFT. Even though FFT has significantly less number of multiplications the quantization errors do not decreate accordingly. Each butterfly operation (ignoring some multiplications are trivial +/-1) involves one complex (four real) multiplication(s). The quantization errors introduced in each butterfly propagate through N/2 stages.
Analysis of quantization related noise effects in a FFT is a challenge. Since FFT algorithm consists of sequence of stages, it is possible to have different scaling strategies in each stage. The attached model shows how fixed point numeric type and fimath can be changed at each stage of the FFT (implemented as a sub function in the embedded MATLAB script).
To achieve desired numerical behavior of the algorithm for the specific application requirements, each multiplication and sum in the attached model can be tweaked independently. The complex magnitude result of FFT output is plotted and compared to its corresponding behavioral block.
引用
Kiran Kintali (2024). A 32 point FFT in embedded MATLAB using fixed point arithmetic (https://www.mathworks.com/matlabcentral/fileexchange/15837-a-32-point-fft-in-embedded-matlab-using-fixed-point-arithmetic), MATLAB Central File Exchange. に取得済み.
MATLAB リリースの互換性
プラットフォームの互換性
Windows macOS Linuxカテゴリ
タグ
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!