DeclareHandlingByNiceBasis( name, info ) F
InstallHandlingByNiceBasis( name, record ) F
These functions are used to implement a new kind of free left modules that shall be handled via the mechanism of nice bases (see Vector Spaces Handled By Nice Bases).
name must be a string, a filter f with this name is created, and
a logical implication from f to IsHandledByNiceBasis
(see IsHandledByNiceBasis) is installed.
record must be a record with the following components.
detect false (then l is nonempty);
the function returns true if V shall lie in the filter f,
and false otherwise;
the return value may also be fail, which indicates that V is
not to be handled via the mechanism of nice bases at all,
NiceFreeLeftModuleInfo NiceFreeLeftModuleInfo method for left modules in f,
NiceVector NiceVector method for left modules V in f;
called with V and a vector v Î V, this function returns the
nice vector r associated with v, and
UglyVector UglyVector method for left modules V in f;
called with V and a vector r in the NiceFreeLeftModule value
of V, this function returns the vector v Î V to which r is
associated.
The idea is that all one has to do for implementing a new kind of free
left modules handled by the mechanism of nice bases is to call
DeclareHandlingByNiceBasis and InstallHandlingByNiceBasis,
which causes the installation of the necessary methods and adds the pair
[ f, record \.detect ] to the global list NiceBasisFiltersInfo.
The LeftModuleByGenerators methods call CheckForHandlingByNiceBasis
(see CheckForHandlingByNiceBasis), which sets the appropriate filter
for the desired left module if applicable.
NiceBasisFiltersInfo V
An overview of all kinds of vector spaces that are currently handled by
nice bases is given by the global list NiceBasisFiltersInfo.
Examples of such vector spaces are vector spaces of field elements
(but not the fields themselves) and non-Gaussian row and matrix spaces
(see IsGaussianSpace).
CheckForHandlingByNiceBasis( R, gens, M, zero ) F
Whenever a free left module is constructed for which the filter
IsHandledByNiceBasis may be useful, CheckHandlingByNiceBasis should
be called.
(This is done in the methods for VectorSpaceByGenerators,
AlgebraByGenerators, IdealBygenerators etc. in the GAP library.)
The arguments of this function are the coefficient ring R, the list
gens of generators, the constructed module M itself, and the zero
element zero of M;
if gens is nonempty then the zero value may also be false.
GAP 4 manual