[
https://issues.apache.org/jira/browse/NUMBERS-133?focusedWorklogId=282297&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-282297
]
ASF GitHub Bot logged work on NUMBERS-133:
------------------------------------------
Author: ASF GitHub Bot
Created on: 24/Jul/19 21:26
Start Date: 24/Jul/19 21:26
Worklog Time Spent: 10m
Work Description: coveralls commented on issue #68: [NUMBERS-133] Use
iteration algorithm from bounded trial division in Primes.nextPrime(int)
URL: https://github.com/apache/commons-numbers/pull/68#issuecomment-514806407
[](https://coveralls.io/builds/24777975)
Coverage increased (+0.002%) to 94.257% when pulling
**53010235fc00bf6d80a497feb950c5ff3322db14 on Schamschi:NUMBERS-133** into
**08962e853b9843d0ad98e66241fef6cc7d69faeb on apache:master**.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
Issue Time Tracking
-------------------
Worklog Id: (was: 282297)
Time Spent: 20m (was: 10m)
> Speed up Primes.nextPrime(int)
> ------------------------------
>
> Key: NUMBERS-133
> URL: https://issues.apache.org/jira/browse/NUMBERS-133
> Project: Commons Numbers
> Issue Type: Improvement
> Components: primes
> Affects Versions: 1.0
> Reporter: Heinrich Bohne
> Priority: Minor
> Time Spent: 20m
> Remaining Estimate: 0h
>
> The method {{Primes.nextPrime(int)}} can use the same algorithm to skip
> multiples of certain primes as {{SmallPrimes.boundedTrialDivision(int, int,
> List<Integer>)}} uses, instead of hard-coding the alternating increment of
> the trial candidate into a loop.
> Also, if the argument of the method is smaller than or equal to the 512th
> prime number, the method can just infer the next higher prime number directly
> from the array {{SmallPrimes.PRIMES}} without performing any calculations.
--
This message was sent by Atlassian JIRA
(v7.6.14#76016)