DSPRelated.com
Forums
Online · Live + on demand
February 9-11, 2027
Price goes up Jan 1: register now to lock in today's rate
Register Now →

Digital Atten&Ampl. ?

Started by Roger Bourne ●March 24, 2006
Roger Bourne wrote:

-- snip --

>> >>So you are left with a choise as how to deal with this: Either get a >>numerically accurate result, obtained at the cost of increasing the >>number of bits in the bus after each multiplication, or keep a fixed >>number of bits all through and accept the numerical error creeping in. > > > This thougth ocurred to me too. If I do not want to relenquish any of > the precison of the products obtained from the [coeffcients] and the > [delayed-input-and-output-samples], the databus width at the output of > the IIR filter would have to be INFINITY. According, to the direct-form > I diagram of the IIR filter, if the precision of the output is not > trimmed down when the output is delayed and [multiplied and summed > back], then the width of the output bus will perputually keep on > increasing. Are there guidelines concerning the databus width at > different points in the IIR filter? >
Yes, but it requires some analysis. Look at the expected noise spectrum on the input, and calculate the expected output noise spectrum assuming a perfect filter. Now calculate the expected noise contribution at each point where quantization occurs (i.e. each point where bits are thrown away). Make your data paths wide enough that the noise from quantization is less than the noise from the input data -or- make the data paths just wide enough that the quantization noise + input noise is acceptable for your product, regardless of whether you're losing good information. -- Tim Wescott Wescott Design Services http://www.wescottdesign.com Posting from Google? See http://cfaj.freeshell.org/google/
Tim Wescott wrote:
> Roger Bourne wrote: > > -- snip -- > > >> > >>So you are left with a choise as how to deal with this: Either get a > >>numerically accurate result, obtained at the cost of increasing the > >>number of bits in the bus after each multiplication, or keep a fixed > >>number of bits all through and accept the numerical error creeping in. > > > > > > This thougth ocurred to me too. If I do not want to relenquish any of > > the precison of the products obtained from the [coeffcients] and the > > [delayed-input-and-output-samples], the databus width at the output of > > the IIR filter would have to be INFINITY. According, to the direct-form > > I diagram of the IIR filter, if the precision of the output is not > > trimmed down when the output is delayed and [multiplied and summed > > back], then the width of the output bus will perputually keep on > > increasing. Are there guidelines concerning the databus width at > > different points in the IIR filter? > > > > Yes, but it requires some analysis. Look at the expected noise spectrum > on the input, and calculate the expected output noise spectrum assuming > a perfect filter. Now calculate the expected noise contribution at each > point where quantization occurs (i.e. each point where bits are thrown > away). Make your data paths wide enough that the noise from > quantization is less than the noise from the input data -or- make the > data paths just wide enough that the quantization noise + input noise is > acceptable for your product, regardless of whether you're losing good > information. >
I get the impression that the math/theory for the quantization process is not something I can (easily, comfortably) derive. The word "quantization" makes me cringe. What would be a good book/website/ect... that explains well the quantization impact, analysis, error in the digital filters ? I am currently expecting Richard Lyons book in the mail (I forgot what it is called). -Roger
Roger Bourne wrote:
> I get the impression that the math/theory for the quantization process > is not something I can (easily, comfortably) derive. The word > "quantization" makes me cringe. What would be a good > book/website/ect... that explains well the quantization impact, > analysis, error in the digital filters ? I am currently expecting > Richard Lyons book in the mail (I forgot what it is called).
Welcome to Dark Arts 101 :-) Steve
Roger Bourne wrote:

> Tim Wescott wrote: > >>Roger Bourne wrote: >> >>-- snip -- >> >> >>>>So you are left with a choise as how to deal with this: Either get a >>>>numerically accurate result, obtained at the cost of increasing the >>>>number of bits in the bus after each multiplication, or keep a fixed >>>>number of bits all through and accept the numerical error creeping in. >>> >>> >>>This thougth ocurred to me too. If I do not want to relenquish any of >>>the precison of the products obtained from the [coeffcients] and the >>>[delayed-input-and-output-samples], the databus width at the output of >>>the IIR filter would have to be INFINITY. According, to the direct-form >>>I diagram of the IIR filter, if the precision of the output is not >>>trimmed down when the output is delayed and [multiplied and summed >>>back], then the width of the output bus will perputually keep on >>>increasing. Are there guidelines concerning the databus width at >>>different points in the IIR filter? >>> >> >>Yes, but it requires some analysis. Look at the expected noise spectrum >>on the input, and calculate the expected output noise spectrum assuming >>a perfect filter. Now calculate the expected noise contribution at each >>point where quantization occurs (i.e. each point where bits are thrown >>away). Make your data paths wide enough that the noise from >>quantization is less than the noise from the input data -or- make the >>data paths just wide enough that the quantization noise + input noise is >>acceptable for your product, regardless of whether you're losing good >>information. >> > > > I get the impression that the math/theory for the quantization process > is not something I can (easily, comfortably) derive. The word > "quantization" makes me cringe. What would be a good > book/website/ect... that explains well the quantization impact, > analysis, error in the digital filters ? I am currently expecting > Richard Lyons book in the mail (I forgot what it is called). > > -Roger >
Quantization is actually pretty easy -- you just calculate the magnitude of the roundoff error, and treat it as noise. If you want to be optimistic you treat it as white noise; if you want to be pessimistic (some would say realistic) you treat it as happening at the worst possible frequency. -- Tim Wescott Wescott Design Services http://www.wescottdesign.com Posting from Google? See http://cfaj.freeshell.org/google/