public QuadraticCharactersBuilder(Polynomial polynomial, IRootFinder rootFinder, long lowerBound, long size)
 {
     _lowerBound = lowerBound;
     _size       = size;
     _rootFinder = rootFinder;
     _polynomial = polynomial;
 }
Beispiel #2
0
        private static void ListDrives(Roots root)
        {
            RootFinderFactory factory = RootFinderFactory.GetInstance();
            IRootFinder       finder  = factory.Create(root);
            List <string>     roots   = finder.GetRoots();

            foreach (var rt in roots)
            {
                Console.WriteLine("Root Name :" + rt);
            }
        }
        public IRootFinder Create(Roots root)
        {
            IRootFinder finder = null;

            switch (root)
            {
            case Roots.ACTIVE: finder = new ActiveRootFinder();
                break;

            case Roots.SYSTEM: finder = new SystemRootFinder();
                break;

            default:
                break;
            }
            return(finder);
        }
Beispiel #4
0
 public AlgebraicFactorbaseBuilder(Polynomial polynomial, IRootFinder rootFinder, long primeBound)
 {
     _primeBound = primeBound;
     _rootFinder = rootFinder;
     _polynomial = polynomial;
 }