Class Lehman_Smith


  • public class Lehman_Smith
    extends FactorAlgorithm
    An attempt to reproduce Warren D. Smith's Lehman implementation used by YaFu, using fast inverse trial division. This attempt may not match the original accurately.
    Author:
    Tilman Neumann
    • Constructor Detail

      • Lehman_Smith

        public Lehman_Smith​(boolean doTDivFirst)
        Full constructor.
        Parameters:
        doTDivFirst - If true then trial division is done before the Lehman loop. This is recommended if arguments N are known to have factors < cbrt(N) frequently.
    • Method Detail

      • getName

        public String getName()
        Specified by:
        getName in class FactorAlgorithm
        Returns:
        The name of the algorithm, possibly including important parameters.
      • findSingleFactor

        public long findSingleFactor​(long N)
      • main

        public static void main​(String[] args)
        Test.
        Parameters:
        args - ignored