An element of an object M is internally represented by a morphism from the "structure object" to the object M. In particular, the data structure for object elements automatically profits from the intrinsic realization of morphisms in the homalg project.
‣ IsHomalgElement( M ) | ( category ) |
Returns: true or false
The GAP category of object elements.
‣ IsElementOfAnObjectGivenByAMorphismRep( M ) | ( representation ) |
Returns: true or false
The GAP representation of elements of finitley presented objects.
(It is a representation of the GAP category IsHomalgElement (5.1-1).)
‣ IsZero( m ) | ( property ) |
Returns: true or false
Check if the object element m is zero.
‣ IsCyclicGenerator( m ) | ( property ) |
Returns: true or false
Check if the object element m is a cyclic generator.
‣ IsTorsion( m ) | ( property ) |
Returns: true or false
Check if the object element m is a torsion element.
‣ Annihilator( e ) | ( attribute ) |
Returns: a homalg subobject
The annihilator of the object element e as a subobject of the structure object.
‣ in( m, N ) | ( attribute ) |
Returns: true or false
Is the element m of the object M included in the subobject N≤ M, i.e., does the morphism (with the unit object as source and M as target) underling the element m of M factor over the subobject morphism N-> M?
gap> ZZ := HomalgRingOfIntegers( ); Z gap> M := 2 * ZZ; <A free left module of rank 2 on free generators> gap> a := HomalgModuleElement( "[ 6, 0 ]", M ); ( 6, 0 ) gap> N := Subobject( HomalgMap( "[ 2, 0 ]", 1 * ZZ, M ) ); <A free left submodule given by a cyclic generator> gap> K := Subobject( HomalgMap( "[ 4, 0 ]", 1 * ZZ, M ) ); <A free left submodule given by a cyclic generator> gap> a in M; true gap> a in N; true gap> a in UnderlyingObject( N ); true gap> a in K; false gap> a in UnderlyingObject( K ); false gap> a in 3 * ZZ; false
InstallMethod( \in,
"for homalg elements",
[ IsHomalgElement, IsStaticFinitelyPresentedSubobjectRep ],
function( m, N )
local phi, psi;
phi := UnderlyingMorphism( m );
psi := MorphismHavingSubobjectAsItsImage( N );
if not IsIdenticalObj( Range( phi ), Range( psi ) ) then
Error( "the super object of the subobject and the range ",
"of the morphism underlying the element do not coincide\n" );
fi;
return IsZero( PreCompose( phi, CokernelEpi( psi ) ) );
end );
generated by GAPDoc2HTML