DSPRelated.com
Forums

frequency response of cic

Started by alex65111 July 20, 2008
Not clearly, why instead of four petals one is drawn only

R = 8; % Decimation factor
M = 1; % Differential delay
N = 9; % Number of stages

f=0:0.001:0.5;
fcic=(abs(sin(pi*M*f)./(eps+sin(pi*f/R)))).^N;

plot(fcic)

On Jul 20, 5:26 am, "alex65111" <alex65...@list.ru> wrote:
> Not clearly, why instead of four petals one is drawn only
Where do you get four from? The response is basically a power of a sinc function (sin x/x), and has an infinite number of peaks of diminishing magnitude, subject only to doing the calculation with sufficient resolution to see them. Try taking 20log10 of the function and plotting that, it may make it easier to see in dB scale.
>On Jul 20, 5:26 am, "alex65111" <alex65...@list.ru> wrote: >> Not clearly, why instead of four petals one is drawn only > >Where do you get four from? > >The response is basically a power of a sinc function (sin x/x), and >has an infinite number of peaks of diminishing magnitude, subject only >to doing the calculation with sufficient resolution to see them. > >Try taking 20log10 of the function and plotting that, it may make it >easier to see in dB scale. >
Application note 455 - Understanding CIC compensation filters (Altera), figure 3.
On Jul 20, 3:26 pm, "alex65111" <alex65...@list.ru> wrote:
> >On Jul 20, 5:26 am, "alex65111" <alex65...@list.ru> wrote: > >> Not clearly, why instead of four petals one is drawn only > > >Where do you get four from?
> Application note 455 - Understanding CIC compensation filters (Altera), > figure 3.
They aren't showing you the whole picture, just the part of it that can be represented by the input sample rate. Just as the sinc function that it's a power of, the response has lobes extending to infinity in both positive and negative frequency, it's just that the further out you go the weaker they get. In their example, the second lobe is already over 100 dB down. That would mean for example that with 16 bit math it's indistinguishable from zero. You probably aren't looking with enough precision to see more than the main lobe - or if you aren't plotting on a log scale, it's just too small for you to see even if you have enough precision for it to still exist in the data. Also be aware that because the CIC is a multi-rate filter, many of the lobes will show up as susceptibility to energy that will then by aliased or folded into the main lobe as a result of the sample rate change. In a decimator for example, those additional lobes represents susceptibility to out-of-channel signals that after the decimation will be (weakly) aliased right on top of the ones genuinely located in the main lobe.
>On Jul 20, 3:26 pm, "alex65111" <alex65...@list.ru> wrote: >> >On Jul 20, 5:26 am, "alex65111" <alex65...@list.ru> wrote: >> >> Not clearly, why instead of four petals one is drawn only >> >> >Where do you get four from? > >> Application note 455 - Understanding CIC compensation filters
(Altera),
>> figure 3. > >They aren't showing you the whole picture, just the part of it that >can be represented by the input sample rate. Just as the sinc >function that it's a power of, the response has lobes extending to >infinity in both positive and negative frequency, it's just that the >further out you go the weaker they get. > >In their example, the second lobe is already over 100 dB down. That >would mean for example that with 16 bit math it's indistinguishable >from zero. You probably aren't looking with enough precision to see >more than the main lobe - or if you aren't plotting on a log scale, >it's just too small for you to see even if you have enough precision >for it to still exist in the data. > >Also be aware that because the CIC is a multi-rate filter, many of the >lobes will show up as susceptibility to energy that will then by >aliased or folded into the main lobe as a result of the sample rate >change. In a decimator for example, those additional lobes represents >susceptibility to out-of-channel signals that after the decimation >will be (weakly) aliased right on top of the ones genuinely located in >the main lobe. > >
On the one hand all is clear, but on the other hand not clearly in what limits should vary in formula 4 'f' to receive figure 3. (precision double float and log scale).
On Jul 22, 2:46 am, "alex65111" <alex65...@list.ru> wrote:

> On the one hand all is clear, but on the other hand not clearly in what > limits should vary in formula 4 'f' to receive figure 3. (precision double > float and log scale).
Multiply the normalized frequencies by the decimation ratio (8) and plug that into the formula and you will get their graph. I'm still thinking about the justification if any for this. Figure 3 does not tell you if the frequency is normalized relative to the input sample rate or the output one...