On Fri, 24 Oct 2003, John N. Power wrote: > Several months ago I wrote a treatment of an old algorithm for finding the > square root of an integer without using floating point numbers, > multiplication, or division. The method was an old one, and rather slow, so > I decided to come up with a comparable treatment of a more contemporary > algorithm. I finally finished it, so here it is, if anyone is interested. > > www.bcpl.net/~jpower/fastsqrt.pdf John, This one is much more efficient than the previous one you posted. It looks like it takes on the order of 130 cycles on average. This is a little slower than the one: http://www.dattalo.com/technical/software/pic/picsqrt.html (The second sqrt routine averages 109 cycles). OTOH, your routine is 2 instructions shorter. Good job! Scott -- http://www.piclist.com hint: PICList Posts must start with ONE topic: [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads