edu.jas.ufd
Class GreatestCommonDivisorModular<MOD extends GcdRingElem<MOD> & Modular>

java.lang.Object
  extended by edu.jas.ufd.GreatestCommonDivisorAbstract<BigInteger>
      extended by edu.jas.ufd.GreatestCommonDivisorModular<MOD>
All Implemented Interfaces:
GreatestCommonDivisor<BigInteger>, java.io.Serializable

public class GreatestCommonDivisorModular<MOD extends GcdRingElem<MOD> & Modular>
extends GreatestCommonDivisorAbstract<BigInteger>

Greatest common divisor algorithms with modular computation and chinese remainder algorithm.

Author:
Heinz Kredel
See Also:
Serialized Form

Field Summary
protected  GreatestCommonDivisorAbstract<BigInteger> iufd
           
protected  GreatestCommonDivisorAbstract<MOD> mufd
           
 
Constructor Summary
GreatestCommonDivisorModular()
          Constructor to set recursive algorithm.
GreatestCommonDivisorModular(boolean simple)
          Constructor to set recursive algorithm.
 
Method Summary
 GenPolynomial<BigInteger> baseGcd(GenPolynomial<BigInteger> P, GenPolynomial<BigInteger> S)
          Univariate GenPolynomial greatest comon divisor.
 GenPolynomial<BigInteger> gcd(GenPolynomial<BigInteger> P, GenPolynomial<BigInteger> S)
          GenPolynomial greatest comon divisor, modular algorithm.
 GenPolynomial<GenPolynomial<BigInteger>> recursiveUnivariateGcd(GenPolynomial<GenPolynomial<BigInteger>> P, GenPolynomial<GenPolynomial<BigInteger>> S)
          Univariate GenPolynomial recursive greatest comon divisor.
 
Methods inherited from class edu.jas.ufd.GreatestCommonDivisorAbstract
baseContent, baseExtendedGcd, baseGcdDiophant, baseHalfExtendedGcd, basePartialFraction, basePartialFraction, basePartialFraction, basePartialFractionValue, basePrimitivePart, baseRecursiveContent, baseRecursivePrimitivePart, content, coPrime, coPrime, coPrimeRec, divide, gcd, isBasePartialFraction, isBasePartialFraction, isCoPrime, isCoPrime, lcm, primitivePart, recursiveContent, recursiveGcd, recursivePrimitivePart, resultant, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

mufd

protected final GreatestCommonDivisorAbstract<MOD extends GcdRingElem<MOD> & Modular> mufd

iufd

protected final GreatestCommonDivisorAbstract<BigInteger> iufd
Constructor Detail

GreatestCommonDivisorModular

public GreatestCommonDivisorModular()
Constructor to set recursive algorithm. Use modular evaluation GCD algorithm.


GreatestCommonDivisorModular

public GreatestCommonDivisorModular(boolean simple)
Constructor to set recursive algorithm.

Parameters:
simple - , true if the simple PRS should be used.
Method Detail

baseGcd

public GenPolynomial<BigInteger> baseGcd(GenPolynomial<BigInteger> P,
                                         GenPolynomial<BigInteger> S)
Univariate GenPolynomial greatest comon divisor. Delegate to subresultant baseGcd, should not be needed.

Specified by:
baseGcd in class GreatestCommonDivisorAbstract<BigInteger>
Parameters:
P - univariate GenPolynomial.
S - univariate GenPolynomial.
Returns:
gcd(P,S).

recursiveUnivariateGcd

public GenPolynomial<GenPolynomial<BigInteger>> recursiveUnivariateGcd(GenPolynomial<GenPolynomial<BigInteger>> P,
                                                                       GenPolynomial<GenPolynomial<BigInteger>> S)
Univariate GenPolynomial recursive greatest comon divisor. Delegate to subresultant recursiveGcd, should not be needed.

Specified by:
recursiveUnivariateGcd in class GreatestCommonDivisorAbstract<BigInteger>
Parameters:
P - univariate recursive GenPolynomial.
S - univariate recursive GenPolynomial.
Returns:
gcd(P,S).

gcd

public GenPolynomial<BigInteger> gcd(GenPolynomial<BigInteger> P,
                                     GenPolynomial<BigInteger> S)
GenPolynomial greatest comon divisor, modular algorithm.

Specified by:
gcd in interface GreatestCommonDivisor<BigInteger>
Overrides:
gcd in class GreatestCommonDivisorAbstract<BigInteger>
Parameters:
P - GenPolynomial.
S - GenPolynomial.
Returns:
gcd(P,S).