| ??? 11/28/07 10:43 Read: times |
#147493 - Source for the algorithm. Responding to: ???'s previous message |
I'm not sure I follow your method---more details would be appreciated.
I think the algorithm is described here. It's in python, but since it only consists of fairly simple steps it should be easy to translate to C or even assembly. And while python probably uses floating point numbers, the algorithm will work just as well with fixed-point numbers. http://en.wikipedia.org/wiki/Binary_logarithm How would this method apply to finding log base 10 of numbers between, say 200 & 50000? to 3 digit accuracy (log(30000)=4.48) Well, once you can calculate the logarithm of a number for one base a, you can calculate the logarithm of any number for any base. log[base x](y) = log[base a](y) / log[base a](x) |



