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

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

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

Groebner Base distributed algorithm. Implements a distributed memory parallel version of Groebner bases. Using pairlist class, distributed tasks do reduction, one communication channel per task.

Author:
Heinz Kredel
See Also:
Serialized Form

Field Summary
protected static int DEFAULT_PORT
          Default server port.
protected static int DEFAULT_THREADS
          Default number of threads.
protected  ThreadPool pool
          Pool of threads to use.
protected  int port
          Server port to use.
protected  int threads
          Number of threads to use.
 
Fields inherited from class edu.jas.gb.GroebnerBaseAbstract
blas, red, strategy
 
Constructor Summary
GroebnerBaseDistributed()
          Constructor.
GroebnerBaseDistributed(int threads)
          Constructor.
GroebnerBaseDistributed(int threads, int port)
          Constructor.
GroebnerBaseDistributed(int threads, PairList<C> pl, int port)
          Constructor.
GroebnerBaseDistributed(int threads, ThreadPool pool, int port)
          Constructor.
GroebnerBaseDistributed(int threads, ThreadPool pool, PairList<C> pl, int port)
          Constructor.
 
Method Summary
 void clientPart(java.lang.String host)
          GB distributed client.
 java.util.List<GenPolynomial<C>> GB(int modv, java.util.List<GenPolynomial<C>> F)
          Distributed Groebner base.
 java.util.List<GenPolynomial<C>> minimalGB(java.util.List<GenPolynomial<C>> Fp)
          Minimal ordered groebner basis.
 void terminate()
          Cleanup and terminate ThreadPool.
 
Methods inherited from class edu.jas.gb.GroebnerBaseAbstract
cancel, 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.


DEFAULT_THREADS

protected static final int DEFAULT_THREADS
Default number of threads.

See Also:
Constant Field Values

pool

protected final ThreadPool pool
Pool of threads to use. Note: No ComputerThreads for one node tests


DEFAULT_PORT

protected static final int DEFAULT_PORT
Default server port.

See Also:
Constant Field Values

port

protected final int port
Server port to use.

Constructor Detail

GroebnerBaseDistributed

public GroebnerBaseDistributed()
Constructor.


GroebnerBaseDistributed

public GroebnerBaseDistributed(int threads)
Constructor.

Parameters:
threads - number of threads to use.

GroebnerBaseDistributed

public GroebnerBaseDistributed(int threads,
                               int port)
Constructor.

Parameters:
threads - number of threads to use.
port - server port to use.

GroebnerBaseDistributed

public GroebnerBaseDistributed(int threads,
                               ThreadPool pool,
                               int port)
Constructor.

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

GroebnerBaseDistributed

public GroebnerBaseDistributed(int threads,
                               PairList<C> pl,
                               int port)
Constructor.

Parameters:
threads - number of threads to use.
pl - pair selection strategy
port - server port to use.

GroebnerBaseDistributed

public GroebnerBaseDistributed(int threads,
                               ThreadPool pool,
                               PairList<C> pl,
                               int port)
Constructor.

Parameters:
threads - number of threads to use.
pool - ThreadPool to use.
pl - pair selection strategy
port - server port to use.
Method Detail

terminate

public void terminate()
Cleanup and terminate ThreadPool.

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

GB

public java.util.List<GenPolynomial<C>> GB(int modv,
                                           java.util.List<GenPolynomial<C>> F)
Distributed Groebner base.

Parameters:
modv - number of module variables.
F - polynomial list.
Returns:
GB(F) a Groebner base of F or null, if a IOException occurs.

clientPart

public void clientPart(java.lang.String host)
                throws java.io.IOException
GB distributed client.

Parameters:
host - the server runns on.
Throws:
java.io.IOException

minimalGB

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

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:
a reduced Groebner base of Fp.