[m-users.] Possible Speedup for Arbitrary Precision Integers
rbuckley at ieee.org
Tue Apr 21 01:48:46 AEST 2015
Thanks, Matthias. Robert Buckley
On Mon, Apr 20, 2015 at 8:25 AM, Matthias Güdemann <
matthias.guedemann at googlemail.com> wrote:
> I created a first pull-request which included changes to the power
> function in `integer.m`.
> This adds a simple version of square and multiply, which - for me - is
> faster than the current implementation, and already gives some speed-up
> (see the PL for examples) for the proposed Miller-Rabin solution. I
> tested it on the `tests/hard_coded` test cases.
> I deliberately left the division by two instead of a left shift by one;
> I did observe any speed-up when using `>>`. In addition, once there is a
> faster division algorithm, there may be even more benefit here.
> Best regards,
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the users