Forum Discussion
Altera_Forum
Honored Contributor
13 years agoand where did you attach the doc to?
I tried my luck numbers and here I managed to get expected values: Bin = 8; %input width N = 4; %stages of comb or integrator M = 2; %differential delay R = 512; %interpolation rate %cic decimator at any stage Bout = N * log2(R*M) + Bin; %cic interpolator per ith stage %stages 1~N for i = 1:N G = 2^i; Bout = Bin + log2(G); d(i) = Bout; end %N+1 ~ 2N stages for i = N+1:N*2 G = 2^(2*N-1)*(R*M)^(i-N)/R; Bout = Bin + log2(G) - i + 1; d(i) = Bout; end for i = 1:N*2 fprintf('%i %i\r',i,d(i)); end