Forum Discussion
Altera_Forum
Honored Contributor
15 years agobit shifting arithmetic
Hi there! I am trying to get my around some binary arithmetic. Basically, I don't want to deal with floating points, so I have a problem that was originally 400 * 0.0615 = 24.6 ...
Altera_Forum
Honored Contributor
15 years agobit shifting is only useful for multiplies when you have only a few 2^n coefficients. for example:
0.75 = 0.5 (2^-1) + 0.25(2^-2) so 5 x 0.75 = 5x0.5 + 5x0.25 When you have more than a couple, it is more sensible to use a multiplier instead because it can calculate results faster than a large adder chain.