定点FIR滤波器通常在数字信号处理器,FPGA和ASIC上实现。固定点过滤器使用定点算术,并由具有固定点系数的方程式表示。如果FIR滤波器的累加器和输出没有足够的位来表示其数据,则溢出会发生并扭曲信号。使用这两个规则自动确定FIR过滤精度设置。目的是在避免溢出的同时最大程度地减少资源利用率(内存/存储和处理元素)。由于规则是根据输入精度,系数精度和系数值进行优化的,因此FIR滤波器必须具有非延期系数。
The precision rules define the minimum and the maximum values of the FIR filter output. To determine these values, perform min/max analysis on the FIR filter coefficients.
FIR滤波器定义为:
X[[n这是给予的是输入信号。
y [n]是输出信号。
Hk一世s the
n一世s the length of the filter.
具有真实输入和真实系数的FIR过滤器的输出限制
Let the minimum value of the input signal be
如果Thesum of all the positive coefficients is
一个nd the sum of all the negative coefficients is denoted as
Thenyou can express the minimum output of the filter as
和过滤器的最大输出为
因此,滤波器的输出位于间隔[
复杂的滤波卷积方程
您可以根据其信号和系数的真实部分和虚构部分来定义复杂的过滤器(复杂的输入和复杂系数):
如信号流程图中所示,将复合滤波器分解为四个实际过滤器。每个信号都用一个间隔表示范围注释。
具有复杂输入和复杂系数的FIR过滤器的输出限制
you can extend the real filter min/max analysis to complex filters. Assume that both the real and imaginary parts of the input signal lie in the interval [
复杂的过滤器包含两个实例回覆(
根据对真实过滤器的最小/最大分析,您可以表达
G+回覆一世s the sum of the positive real parts of
G-回覆是负面实际部分的总和
G+我是一世s the sum of the positive imaginary parts of
G-我是是负面虚构部分的总和
The minimum and maximum values of the real and imaginary parts of the output are:
输出的真实或虚构部分最低和最大值的最小值和最大值由
定点精度规则根据累加器单词长度和分数长度来定义过滤器的输出单词长度和分数。
完整精确的蓄能器规则
假设输入是带有单词长度的签名或未签名的固定点信号
累加器分数长度等于产品分数长度,这是输入和系数分数长度的总和。
如果y最小= 0,然后累加器没有单词长度
如果y最小<0,然后累加器用单词长度签名
CEIL操作员向最近的整数朝向 +∞。
Output Same Word Length as Input Rule
This rule sets the output word length to be the same as the input word length. Then, it adjusts the fraction length to avoid overflow.
截断累加器以使输出单词长度与输入单词长度相同。
。
设置输出分数长度
。
您可以将这些规则扩展到多相FIR插值器和清除器。
FIR Interpolators
Treat each polyphase branch of the FIR interpolator as a separate FIR filter. The output data type of the FIR interpolator is the worst-case data type of all the polyphase branches.
FIR Decimators
For decimators, the polyphase branches add up at the output. Hence, the output data type is computed as if it were a single FIR filter with all the coefficients of all the polyphase branches.