Package edu.jas.gb
Class GroebnerBaseDistributedEC<C extends RingElem<C>>
java.lang.Object
edu.jas.gb.GroebnerBaseAbstract<C>
edu.jas.gb.GroebnerBaseDistributedEC<C>
- Type Parameters:
C
- coefficient type
- All Implemented Interfaces:
GroebnerBase<C>
,Serializable
Groebner Base distributed algorithm. Implements a distributed memory parallel
version of Groebner bases with executable channels. Using pairlist class,
distributed tasks do reduction, one communication channel per task.
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final int
Default server port.protected static final int
Default number of threads.protected final int
Default distributed hash table server port.private final DistHashTableServer
<Integer> Distributed hash table server to use.private final DistThreadPool
Distributed thread pool to use.private static final org.apache.logging.log4j.Logger
protected final String
machine file to use.protected final ExecutorService
Pool of threads to use.protected final int
Server port to use.protected final int
Number of threads to use.Fields inherited from class edu.jas.gb.GroebnerBaseAbstract
blas, red, strategy
-
Constructor Summary
ConstructorsConstructorDescriptionGroebnerBaseDistributedEC
(String mfile) Constructor.GroebnerBaseDistributedEC
(String mfile, int threads) Constructor.GroebnerBaseDistributedEC
(String mfile, int threads, int port) Constructor.GroebnerBaseDistributedEC
(String mfile, int threads, PairList<C> pl, int port) Constructor.GroebnerBaseDistributedEC
(String mfile, int threads, ExecutorService pool, int port) Constructor.GroebnerBaseDistributedEC
(String mfile, int threads, ExecutorService pool, PairList<C> pl, int port) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionstatic <C extends RingElem<C>>
voidclientPart
(String host, int port, int dhtport) GB distributed client part.GB
(int modv, List<GenPolynomial<C>> F) Distributed Groebner base.(package private) List
<GenPolynomial<C>> GBMaster
(int modv, List<GenPolynomial<C>> F) Distributed Groebner base.minimalGB
(List<GenPolynomial<C>> Fp) Minimal ordered groebner basis.void
Cleanup and terminate ExecutorService.void
terminate
(boolean shutDown) Terminates the distributed thread pools.Methods inherited from class edu.jas.gb.GroebnerBaseAbstract
cancel, commonZeroTest, constructUnivariate, criterion3, extGB, extGB, GB, GB, GB, isGB, isGB, isGB, isGB, isGB, isGB, isGBidem, isGBsimple, isMinimalGB, isMinReductionMatrix, isMinReductionMatrix, isReductionMatrix, isReductionMatrix, minimalExtendedGB, normalizeMatrix, normalizeZerosOnes, toString, univariateDegrees
-
Field Details
-
logger
private static final org.apache.logging.log4j.Logger logger -
threads
protected final int threadsNumber of threads to use. -
DEFAULT_THREADS
protected static final int DEFAULT_THREADSDefault number of threads.- See Also:
-
pool
Pool of threads to use. Note: No ComputerThreads for one node tests -
DEFAULT_PORT
protected static final int DEFAULT_PORTDefault server port.- See Also:
-
DHT_PORT
protected final int DHT_PORTDefault distributed hash table server port. -
port
protected final int portServer port to use. -
mfile
machine file to use. -
dtp
Distributed thread pool to use. -
dhts
Distributed hash table server to use.
-
-
Constructor Details
-
GroebnerBaseDistributedEC
Constructor.- Parameters:
mfile
- name of the machine file.
-
GroebnerBaseDistributedEC
Constructor.- Parameters:
mfile
- name of the machine file.threads
- number of threads to use.
-
GroebnerBaseDistributedEC
Constructor.- Parameters:
mfile
- name of the machine file.threads
- number of threads to use.port
- server port to use.
-
GroebnerBaseDistributedEC
Constructor.- Parameters:
mfile
- name of the machine file.threads
- number of threads to use.pool
- ExecutorService to use.port
- server port to use.
-
GroebnerBaseDistributedEC
Constructor.- Parameters:
mfile
- name of the machine file.threads
- number of threads to use.pl
- pair selection strategyport
- server port to use.
-
GroebnerBaseDistributedEC
public GroebnerBaseDistributedEC(String mfile, int threads, ExecutorService pool, PairList<C> pl, int port) Constructor.- Parameters:
mfile
- name of the machine file.threads
- number of threads to use.pool
- ExecutorService to use.pl
- pair selection strategyport
- server port to use.
-
-
Method Details
-
terminate
public void terminate()Cleanup and terminate ExecutorService.- Overrides:
terminate
in classGroebnerBaseAbstract<C extends RingElem<C>>
-
terminate
public void terminate(boolean shutDown) Terminates the distributed thread pools.- Parameters:
shutDown
- true, if shut-down of the remote executable servers is requested, false, if remote executable servers stay alive.
-
GB
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.
-
GBMaster
Distributed Groebner base.- Parameters:
modv
- number of module variables.F
- non empty monic polynomial list.- Returns:
- GB(F) a Groebner base of F or null, if a IOException occurs.
-
clientPart
public static <C extends RingElem<C>> void clientPart(String host, int port, int dhtport) throws IOException GB distributed client part.- Parameters:
host
- the server runs on.port
- the server runs.dhtport
- of the DHT server.- Throws:
IOException
-
minimalGB
Minimal ordered groebner basis.- Specified by:
minimalGB
in interfaceGroebnerBase<C extends RingElem<C>>
- Overrides:
minimalGB
in classGroebnerBaseAbstract<C extends RingElem<C>>
- Parameters:
Fp
- a Groebner base.- Returns:
- a reduced Groebner base of Fp.
-