Forum Discussion
Altera_Forum
Honored Contributor
15 years agoI think I saw an algorithm somewhere that would map well to an integer/fixed point square root. Basically you pull out all the powers of 2 of the input value until you get it down to larger than 0 and less than 4. Then you could use a lookup table to take care of the rest (you are not using floating point so I'm guessing accuracy doesn't matter to you). Really the lookup table makes more sense for fixed point or if you want to do some rounding of an integer answer. Some people use this method for floating point square roots only they use something a bit more accurate than a lookup table at the end.