edu.jas.gb
Class GroebnerBaseSeqPairParallel<C extends RingElem<C>>

java.lang.Object
  extended by edu.jas.gb.GroebnerBaseAbstract<C>
      extended by edu.jas.gb.GroebnerBaseSeqPairParallel<C>
Type Parameters:
C - coefficient type
All Implemented Interfaces:
GroebnerBase<C>, java.io.Serializable

public class GroebnerBaseSeqPairParallel<C extends RingElem<C>>
extends GroebnerBaseAbstract<C>

Groebner Base parallel algorithm. Makes some effort to produce the same sequence of critical pairs as in the sequential version. However already reduced pairs are not rereduced if new polynomials appear. Implements a shared memory parallel version of Groebner bases. Slaves maintain pairlist.

Author:
Heinz Kredel
See Also:
Serialized Form

Field Summary
protected  ThreadPool pool
          Pool of threads to use.
protected  int threads
          Number of threads to use.
 
Fields inherited from class edu.jas.gb.GroebnerBaseAbstract
blas, red, strategy
 
Constructor Summary
GroebnerBaseSeqPairParallel()
          Constructor.
GroebnerBaseSeqPairParallel(int threads)
          Constructor.
GroebnerBaseSeqPairParallel(int threads, Reduction<C> red)
          Constructor.
GroebnerBaseSeqPairParallel(int threads, ThreadPool pool)
          Constructor.
GroebnerBaseSeqPairParallel(int threads, ThreadPool pool, Reduction<C> red)
          Constructor.
 
Method Summary
 int cancel()
          Cancel ThreadPool.
 java.util.List<GenPolynomial<C>> GB(int modv, java.util.List<GenPolynomial<C>> F)
          Parallel Groebner base using sequential pair order class.
 java.util.List<GenPolynomial<C>> minimalGB(java.util.List<GenPolynomial<C>> Fp)
          Minimal ordered groebner basis, parallel.
 void terminate()
          Cleanup and terminate ThreadPool.
 
Methods inherited from class edu.jas.gb.GroebnerBaseAbstract
commonZeroTest, extGB, extGB, GB, isGB, isGB, isReductionMatrix, isReductionMatrix, minimalExtendedGB, normalizeMatrix
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

threads

protected final int threads
Number of threads to use.


pool

protected final ThreadPool pool
Pool of threads to use.

Constructor Detail

GroebnerBaseSeqPairParallel

public GroebnerBaseSeqPairParallel()
Constructor.


GroebnerBaseSeqPairParallel

public GroebnerBaseSeqPairParallel(int threads)
Constructor.

Parameters:
threads - number of threads to use.

GroebnerBaseSeqPairParallel

public GroebnerBaseSeqPairParallel(int threads,
                                   ThreadPool pool)
Constructor.

Parameters:
threads - number of threads to use.
pool - ThreadPool to use.

GroebnerBaseSeqPairParallel

public GroebnerBaseSeqPairParallel(int threads,
                                   Reduction<C> red)
Constructor.

Parameters:
threads - number of threads to use.
red - parallelism aware reduction engine

GroebnerBaseSeqPairParallel

public GroebnerBaseSeqPairParallel(int threads,
                                   ThreadPool pool,
                                   Reduction<C> red)
Constructor.

Parameters:
threads - number of threads to use.
pool - ThreadPool to use.
red - parallelism aware reduction engine
Method Detail

terminate

public void terminate()
Cleanup and terminate ThreadPool.

Overrides:
terminate in class GroebnerBaseAbstract<C extends RingElem<C>>

cancel

public int cancel()
Cancel ThreadPool.

Overrides:
cancel in class GroebnerBaseAbstract<C extends RingElem<C>>

GB

public java.util.List<GenPolynomial<C>> GB(int modv,
                                           java.util.List<GenPolynomial<C>> F)
Parallel Groebner base using sequential pair order class. Slaves maintain pairlist.

Parameters:
modv - number of module variables.
F - polynomial list.
Returns:
GB(F) a Groebner base of F.

minimalGB

public java.util.List<GenPolynomial<C>> minimalGB(java.util.List<GenPolynomial<C>> Fp)
Minimal ordered groebner basis, parallel.

Specified by:
minimalGB in interface GroebnerBase<C extends RingElem<C>>
Overrides:
minimalGB in class GroebnerBaseAbstract<C extends RingElem<C>>
Parameters:
Fp - a Groebner base.
Returns:
minimalGB(F) a minimal Groebner base of Fp.