|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.uacalc.alg.GeneralAlgebra
public class GeneralAlgebra
This class represents general algebras that may or may not be "computer finite".
| Field Summary | |
|---|---|
protected CongruenceLattice |
con
|
protected java.lang.String |
description
|
static ProgressReport |
monitor
|
protected java.lang.String |
name
|
protected java.util.List<Operation> |
operations
|
protected java.util.Map<OperationSymbol,Operation> |
operationsMap
|
protected SimilarityType |
similarityType
|
protected int |
size
|
protected SubalgebraLattice |
sub
|
protected java.util.Set |
universe
|
| Fields inherited from interface org.uacalc.alg.Algebra |
|---|
CARDINALITY_COUNTABLE, CARDINALITY_COUNTABLY_INFINITE, CARDINALITY_FINITE, CARDINALITY_INFINITE, CARDINALITY_UNKNOWN |
| Constructor Summary | |
|---|---|
protected |
GeneralAlgebra(java.lang.String name)
|
|
GeneralAlgebra(java.lang.String name,
java.util.Set univ)
|
|
GeneralAlgebra(java.lang.String name,
java.util.Set univ,
java.util.List<Operation> operations)
|
| Method Summary | |
|---|---|
int |
cardinality()
|
CongruenceLattice |
con()
|
java.util.List |
constantOperations()
This gives a list of the operations of arity 0, which is a little different from the constants. |
java.lang.String |
getDescription()
|
ProgressReport |
getMonitor()
|
java.lang.String |
getName()
|
Operation |
getOperation(OperationSymbol sym)
Get the operation correspond to a symbol or null if the symbol is not part of the similarityType. |
java.util.Map<OperationSymbol,Operation> |
getOperationsMap()
|
int |
inputSize()
The sum of the cardinality of the algebra raised to the arity of the operations. |
boolean |
isIdempotent()
Test if all of the operations are idempotent. |
boolean |
isSimilarTo(Algebra alg2)
|
boolean |
isTotal()
This will fail only if there are some OperationWithDefaultValue's which are not total. |
boolean |
isUnary()
|
java.util.Iterator |
iterator()
returns the iterator of the universe. |
void |
makeOperationTables()
Make operation tables to speed up the evaluation of operations at the cost using more space. |
boolean |
monitoring()
|
java.util.List<Operation> |
operations()
|
SmallAlgebra |
parent()
|
java.util.List<SmallAlgebra> |
parents()
|
void |
resetConAndSub()
This does nothing but is overwritten for BasicAlgebra's. |
void |
setDescription(java.lang.String desc)
|
void |
setMonitor(ProgressReport m)
|
void |
setName(java.lang.String v)
|
protected void |
setOperations(java.util.List<Operation> ops)
|
protected void |
setUniverse(java.util.Set univ)
|
SimilarityType |
similarityType()
|
SubalgebraLattice |
sub()
|
java.util.Set |
universe()
We use java.util.Set to hold the universe of the algebra. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected java.util.List<Operation> operations
protected java.util.Map<OperationSymbol,Operation> operationsMap
protected SimilarityType similarityType
protected java.util.Set universe
protected CongruenceLattice con
protected SubalgebraLattice sub
protected java.lang.String name
protected java.lang.String description
protected int size
public static ProgressReport monitor
| Constructor Detail |
|---|
protected GeneralAlgebra(java.lang.String name)
public GeneralAlgebra(java.lang.String name,
java.util.Set univ)
public GeneralAlgebra(java.lang.String name,
java.util.Set univ,
java.util.List<Operation> operations)
| Method Detail |
|---|
public final void setMonitor(ProgressReport m)
setMonitor in interface Algebrapublic final ProgressReport getMonitor()
getMonitor in interface Algebrapublic final boolean monitoring()
monitoring in interface Algebrapublic boolean isTotal()
Algebra
isTotal in interface Algebraprotected void setUniverse(java.util.Set univ)
protected void setOperations(java.util.List<Operation> ops)
public java.util.Map<OperationSymbol,Operation> getOperationsMap()
getOperationsMap in interface Algebrapublic java.util.List<Operation> operations()
operations in interface Algebrapublic Operation getOperation(OperationSymbol sym)
Algebra
getOperation in interface Algebrapublic boolean isUnary()
isUnary in interface Algebrapublic java.util.List constantOperations()
constantOperations in interface Algebrapublic SimilarityType similarityType()
similarityType in interface Algebrapublic java.lang.String getName()
getName in interface Algebrapublic void setName(java.lang.String v)
setName in interface Algebrapublic java.lang.String getDescription()
getDescription in interface Algebrapublic void setDescription(java.lang.String desc)
setDescription in interface Algebrapublic boolean isSimilarTo(Algebra alg2)
isSimilarTo in interface Algebrapublic java.util.Iterator iterator()
Algebra
iterator in interface Algebrapublic int cardinality()
cardinality in interface Algebrapublic int inputSize()
Algebra
inputSize in interface Algebrapublic java.util.Set universe()
Algebra
universe in interface Algebrapublic CongruenceLattice con()
public SubalgebraLattice sub()
public void resetConAndSub()
public void makeOperationTables()
Algebra
makeOperationTables in interface AlgebraOperation.makeTablepublic SmallAlgebra parent()
public java.util.List<SmallAlgebra> parents()
public boolean isIdempotent()
Algebra
isIdempotent in interface Algebra
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||