On Thursday 08 July 2010 16:00:46 Fredrik Johansson wrote: > On Thu, Jul 8, 2010 at 4:51 PM, Jason Moxham <ja...@njkfrudils.plus.com>wrote: > > The mulhi and mullo are exact unlike the mulmid , we could do an > > approximate > > mulhi which would be marginally faster. > > > > Jason > > Yes, that would be very nice. I assume approximate mulhi would be give the > exact result +/- 1? > > Fredrik
maybe , I would have to look it up , basically mulhi goes like this calculate mul_short (either basecase or divide and conquer) mul_short is like mul_high but with 2 extra digits calculated , these 2 extra digits give enough info that the mul_high product is almost always right except in easy to tell situations . If the product is not an exact mul_high then just do a full mull.The probability of having to do a full mul is something like n/2^64 (for n limbs), how far the mul_short differs from mul_high would be easy to calculate but I dont know what it is (perhaps n?) I think the sourcecode has all the info , or you can read the relevant paper which is referenced somewhere. Jason -- You received this message because you are subscribed to the Google Groups "mpir-devel" group. To post to this group, send email to mpir-de...@googlegroups.com. To unsubscribe from this group, send email to mpir-devel+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/mpir-devel?hl=en.