Class ModuleList<C extends RingElem<C>>
java.lang.Object
edu.jas.poly.ModuleList<C>
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
OptimizedModuleList, OrderedModuleList
List of vectors of polynomials. Mainly for storage and printing / toString
and conversions to other representations.
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionfinal intNumber of columns in the data structure.final List<List<GenPolynomial<C>>> The data structure is a List of Lists of polynomials.private static final org.apache.logging.log4j.Loggerfinal GenPolynomialRing<C> The factory for the solvable polynomial ring.final intNumber of rows in the data structure. -
Constructor Summary
ConstructorsConstructorDescriptionModuleList(GenPolynomialRing<C> r, List<List<GenPolynomial<C>>> l) Constructor.Constructor.ModuleList(GenVectorModul<GenPolynomial<C>> r, List<GenVector<GenPolynomial<C>>> l) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionstatic <C extends RingElem<C>>
List<List<GenPolynomial<C>>> castToList(List<List<GenSolvablePolynomial<C>>> slist) Get a solvable polynomials list as List of GenPolynomials.Get list as List of GenSolvablePolynomials.booleanComparison with any other object.Get PolynomialList.getPolynomialList(boolean top) Get PolynomialList.getPolynomialList(GenPolynomialRing<C> pfac) Get PolynomialList.inthashCode()Hash code for this module list.booleanisEmpty()Test if list is empty.booleanisZERO()Test all elements are zero.static <C extends RingElem<C>>
List<List<GenPolynomial<C>>> padCols(GenPolynomialRing<C> ring, List<List<GenPolynomial<C>>> l) Pad columns and remove zero rows.toScript()Get a scripting compatible string representation.toString()String representation of the module list.static <C extends RingElem<C>>
List<List<GenPolynomial<C>>> vecToList(List<GenVector<GenPolynomial<C>>> vlist) Get a list of vectors as List of list of GenPolynomials.
-
Field Details
-
ring
The factory for the solvable polynomial ring. -
list
-
rows
public final int rowsNumber of rows in the data structure. -
cols
public final int colsNumber of columns in the data structure. -
logger
private static final org.apache.logging.log4j.Logger logger
-
-
Constructor Details
-
ModuleList
Constructor.- Parameters:
r- polynomial ring factory.l- list of list of polynomials.
-
ModuleList
Constructor.- Parameters:
r- solvable polynomial ring factory.l- list of list of solvable polynomials.
-
ModuleList
Constructor.- Parameters:
r- polynomial ring factory.l- list of vectors of polynomials.
-
-
Method Details
-
equals
-
hashCode
-
isEmpty
public boolean isEmpty()Test if list is empty.- Returns:
- true if this is empty, else false.
-
isZERO
public boolean isZERO()Test all elements are zero.- Returns:
- true if all elements are zero, else false.
-
toString
-
toScript
Get a scripting compatible string representation.- Returns:
- script compatible representation for this ModuleList.
-
padCols
public static <C extends RingElem<C>> List<List<GenPolynomial<C>>> padCols(GenPolynomialRing<C> ring, List<List<GenPolynomial<C>>> l) Pad columns and remove zero rows. Make all rows have the same number of columns.- Parameters:
ring- polynomial ring factory.l- list of list of polynomials.- Returns:
- list of list of polynomials with same number of columns.
-
getPolynomialList
Get PolynomialList. Embed module in a polynomial ring.- Returns:
- polynomial list corresponding to this.
- See Also:
-
getPolynomialList
Get PolynomialList. Embed module in a polynomial ring.- Parameters:
top- true for TOP term order, false for POT term order.- Returns:
- polynomial list corresponding to this.
- See Also:
-
getPolynomialList
Get PolynomialList. Embed module in a polynomial ring.- Parameters:
pfac- polynomial ring.- Returns:
- polynomial list corresponding to pfac and this.
- See Also:
-
castToSolvableList
Get list as List of GenSolvablePolynomials. Required because no List casts allowed. Equivalent to cast (List<List<GenSolvablePolynomial<C>>>) list.- Returns:
- list of solvable polynomial lists from this.
-
castToList
public static <C extends RingElem<C>> List<List<GenPolynomial<C>>> castToList(List<List<GenSolvablePolynomial<C>>> slist) Get a solvable polynomials list as List of GenPolynomials. Required because no List casts allowed. Equivalent to cast (List<List<GenPolynomial<C>>>) list.- Parameters:
slist- list of solvable polynomial lists.- Returns:
- list of polynomial lists from slist.
-
vecToList
public static <C extends RingElem<C>> List<List<GenPolynomial<C>>> vecToList(List<GenVector<GenPolynomial<C>>> vlist) Get a list of vectors as List of list of GenPolynomials.- Parameters:
vlist- list of vectors of polynomials.- Returns:
- list of polynomial lists from vlist.
-