CIC Decimator Gain and Zeros Follow the Rate Definitions
2026-11-25

CIC Decimator Gain and Zeros Follow the Rate Definitions

CIC Decimator Gain can explain a scale change in a robot sensor-data exercise even when the input is constant. A cascaded integrator-comb filter combines accumulation, rate reduction and delayed subtraction. Its compact implementation uses two sample rates, so a delay measured in output samples must not be confused with the same number of input samples. A small ideal example exposes the gain and frequency zeros without configuring any hardware.

Define stage count, rate factor and differential delay

Let R denote the integer decimation factor, M the differential delay in each low-rate comb stage, and N the number of integrator stages and also the number of comb stages. There are N of each type, rather than N blocks in total. Choose R = 4, M = 1 and N = 2 for this example. Two integrators process every input sample, a downsampler keeps every fourth sample, and two comb stages then process the lower-rate sequence.

An integrator updates its accumulated value by adding the current input. A comb subtracts a delayed value from the current value. In the efficient multirate structure, a one-sample comb delay is measured at the output rate. With a fourfold rate change it spans four input-sample intervals. This rate label is part of the mathematical description, not just a detail of the block drawing.

N2R4M1input8000output2000onecombdelayfourinputintervals.
Rate structure only; no device-specific first-output alignment. Source: Zhilianhai editorial desk, original AI-assisted conceptual illustration.

Derive an equivalent filter at the input rate

Before rate reduction, the equivalent single-rate response is H(z) = [(1 - z to the power minus RM)/(1 - z to the power minus one)] to the power N. For the selected values this becomes (1 + z to the power minus one + z to the power minus two + z to the power minus three) squared. It is two four-sample rectangular sums in cascade, followed by keeping every fourth filtered output.

Convolving the two rectangular sequences gives seven coefficients: 1, 2, 3, 4, 3, 2, 1. Their sum is sixteen, matching the general unnormalized DC gain (RM) to the power N. A settled constant input of three therefore produces forty-eight before scaling, under ideal arithmetic and consistent initial conditions. Dividing by sixteen restores a unity DC gain. That scaling choice belongs in the data record rather than being silently assumed.

The FIR representation also gives an independent check on the response despite the recursive-looking integrator implementation. The individual accumulators can grow while the matched combs recover a finite difference. This does not permit ignoring implementation arithmetic: finite word width, overflow conventions and truncation need separate treatment. The example uses unbounded integer or ordinary mathematical arithmetic and makes no fixed-point sizing claim.

Place comb zeros on the input-frequency axis

Assume an invented input sample rate of eight thousand samples per second. The output rate is two thousand samples per second. The equivalent filter has nonzero-frequency zeros at multiples of the input rate divided by RM, so its first zero is at two thousand hertz. Another occurs at four thousand hertz, the input Nyquist frequency. The zero at zero frequency is canceled by the integrator denominator; the DC gain is sixteen, not zero.

Normalize the seven coefficients by sixteen and evaluate their complex frequency sum. At five hundred hertz, the magnitude is approximately 0.82107, about minus 1.71 decibels. At two thousand hertz it is zero in the ideal model. These calculations use frequencies relative to the input sample rate. A frequency plotted as one quarter of the input rate is not one quarter of the output rate; omitting that reference would shift the interpretation by the factor of four.

Coefficients1234321sum16mag500Hz.82107zero2000Hzatinputfs8000.
Independent ideal arithmetic, without word-length or full alias claims. Source: Zhilianhai editorial desk, original AI-assisted conceptual illustration.

Keep passband droop and alias limits visible

The five-hundred-hertz result demonstrates passband droop: unity gain at DC does not imply unity gain across the useful band. The exact zeros suppress particular frequencies, while frequencies between those zeros generally have nonzero response. Downsampling can fold remaining high-frequency components into the lower-rate band. The existence of a comb zero therefore does not establish complete alias rejection for every possible sensor input.

A useful exercise records R, M, N, input and output sample rates, gain normalization and frequency-axis convention together. If comparing implementations, it should also record retained-sample phase, startup conditions and delay placement. Different integrator delay conventions can alter sequence latency even when the magnitude response agrees. This article verifies a single-rate equivalent and rate structure, without claiming a device-specific first-output alignment.

The seven coefficients provide a compact cross-check: they sum to sixteen, show a finite impulse response, and reproduce the calculated zero and droop. That makes an unexpected scale factor in a learning plot explainable before it is mistaken for a sensor calibration change. The illustration is a local mathematical example; it is not a downloaded waveform or a qualification of a robot's acquisition chain.

Related topics appear in technical articles and equipment reference topics.

Primary references: MathWorks CIC decimation equations and algorithms; AMD CIC Compiler decimator chapter.

18028484626 CONTACT US

公司:智联海(惠州)科技有限公司

地址:惠州仲恺高新区陈江街道白云山工业大道 5 号六楼 601

Q Q:18028484626

Copyright © 2002-2026

咨询 在线留言 电话:18028484626
微信 微信扫码添加我