shh.csparse
Class SparseEltField
Object
SparseElt
SparseEltEuc
SparseEltField
- Direct Known Subclasses:
- SparseEltMod2, SparseEltModp
- public abstract class SparseEltField
- extends SparseEltEuc
A class of SparseElts should implement this interface if
its underlying integral domain is a field.
- Author:
- Mark McConnell
| Methods inherited from class SparseElt |
add, bitLength, copy, divides, equals, getIndex, getNegOne, getOne, getPrintValue, getZero, hashCode, isEqualValue, isNegOne, isOne, isZero, multiply, multiply, negate, subtract, toString |
SparseEltField
public SparseEltField()
eucNorm
public Number eucNorm()
- Description copied from class:
SparseEltEuc
- Returns the Euclidean norm. An implementing class may return
BigInteger, Integer, etc., as long as it's
consistent.
- Specified by:
eucNorm in class SparseEltEuc
getEucNormComparator
public Comparator getEucNormComparator()
- Description copied from class:
SparseEltEuc
- Returns a Comparator
C that compares by Euclidean
norm. C.compare(a,b) should give the same results
as
a.eucNorm().compareTo(b.eucNorm()),
where compareTo is the usual <, but
C.compare might be more efficient.
- Specified by:
getEucNormComparator in class SparseEltEuc
dividedBy
public abstract SparseEltField dividedBy(SparseEltField y)
- Returns
this/y. The index is that of
this.
- Throws:
ArithmeticException - If y is 0.