Torbjorn Granlund <t...@gmplib.org> writes:

> Is your code different from perfpow.c's binv_sqroot?

I think so. I don't fully understand the binv_sqroot, but some
differences:

* As far as I see, it doesn't take any advantage of cancellation in the
  iteration.

* It uses powlo in some way which I haven't figured out.

* And they return different values, a^{1/2} and a^{-1/2}, respectively
  (but that's a minor issue; I'm not sure which value makes the most
  sense to return).

* And the binv_sqrt function is a lot simpler than mine.

Regards,
/Niels

-- 
Niels Möller. PGP-encrypted email is preferred. Keyid C0B98E26.
Internet email is subject to wholesale government surveillance.
_______________________________________________
gmp-devel mailing list
gmp-devel@gmplib.org
http://gmplib.org/mailman/listinfo/gmp-devel

Reply via email to