edu.jas.structure
Interface ModulFactory<M extends ModulElem<M,C>,C extends RingElem<C>>

Type Parameters:
M - module type
C - coefficient type
All Superinterfaces:
AbelianGroupFactory<M>, ElemFactory<M>, java.io.Serializable
All Known Implementing Classes:
GenVectorModul

public interface ModulFactory<M extends ModulElem<M,C>,C extends RingElem<C>>
extends AbelianGroupFactory<M>

Module factory interface. Defines conversion from list and sparse random.

Author:
Heinz Kredel

Method Summary
 M fromList(java.util.List<C> v)
          Convert list to module.
 M random(int k, float q)
          Random vector.
 
Methods inherited from interface edu.jas.structure.AbelianGroupFactory
getZERO
 
Methods inherited from interface edu.jas.structure.ElemFactory
copy, fromInteger, fromInteger, generators, isFinite, parse, parse, random, random, toScript
 

Method Detail

fromList

M fromList(java.util.List<C> v)
Convert list to module.

Parameters:
v - list of ring elements.
Returns:
a module element with the elements from v.

random

M random(int k,
         float q)
Random vector.

Parameters:
k - size of coefficients.
q - fraction of non zero elements.
Returns:
a random vector.