Goto Chapter: Top 1 2 3 4 5 6 7 8 9 10 11 12 13 Ind
 [Top of Book]  [Contents]   [Previous Chapter]   [Next Chapter] 

5 Example on category of rows
 5.1 Constructors of objects
 5.2 Constructors of morphisms
 5.3 A few categorical constructions for category of rows
 5.4 Simplifications

5 Example on category of rows

5.1 Constructors of objects

gap> S := HomalgRingOfIntegers();;
gap> rows := CategoryOfRows( S );
Rows( Z )
gap> obj1 := CategoryOfRowsObject( 2, rows );
<A row module over Z of rank 2>
gap> obj2 := CategoryOfRowsObject( 8, rows );
<A row module over Z of rank 8>

5.2 Constructors of morphisms

gap> obj3 := CategoryOfRowsObject( 1, rows );
<A row module over Z of rank 1>
gap> IsWellDefined( obj1 );
true
gap> obj4 := CategoryOfRowsObject( 2, rows );
<A row module over Z of rank 2>
gap> mor := CategoryOfRowsMorphism( obj3, HomalgMatrix( [[1,2]], 1, 2, S ), obj4 );
<A morphism in Rows( Z )>
gap> IsWellDefined( mor );
true
gap> Display( Source( mor ) );
A row module over Z of rank 1
gap> Display( Range( mor ) );
A row module over Z of rank 2
gap> Display( UnderlyingMatrix( mor ) );
[ [  1, 2 ] ]

5.3 A few categorical constructions for category of rows

gap> Length( AdditiveGenerators( rows ) );
1
gap> ZeroObject( rows );
<A row module over Z of rank 0>
gap> obj5 := CategoryOfRowsObject( 2, rows );
<A row module over Z of rank 2>
gap> Display( ZeroMorphism( ZeroObject( rows ), obj5 ) );
A zero, split monomorphism in Rows( Z )

Source: 
A row module over Z of rank 0

Matrix: 
(an empty 0 x 2 matrix)

Range: 
A row module over Z of rank 2
gap> obj6 := CategoryOfRowsObject( 1, rows );
<A row module over Z of rank 1>
gap> Display( IdentityMorphism( obj6 ) );
An identity morphism in Rows( Z )

Source: 
A row module over Z of rank 1

Matrix: 
[ [  1 ] ]

Range: 
A row module over Z of rank 1
gap> directSum := DirectSum( [ obj5, obj6 ] );
<A row module over Z of rank 3>
gap> Display( directSum );
A row module over Z of rank 3
gap> i1 := InjectionOfCofactorOfDirectSum( [ obj5, obj6 ], 1 );
<A morphism in Rows( Z )>
gap> Display( i1 );
A morphism in Rows( Z )

Source: 
A row module over Z of rank 2

Matrix: 
[ [  1,  0,  0 ],
  [  0,  1,  0 ] ]

Range: 
A row module over Z of rank 3
gap> i2 := InjectionOfCofactorOfDirectSum( [ obj5, obj6 ], 2 );
<A morphism in Rows( Z )>
gap> Display( i2 );
A morphism in Rows( Z )

Source: 
A row module over Z of rank 1

Matrix: 
[ [  0,  0,  1 ] ]

Range: 
A row module over Z of rank 3
gap> proj1 := ProjectionInFactorOfDirectSum( [ obj5, obj6 ], 1 );
<A morphism in Rows( Z )>
gap> Display( proj1 );
A morphism in Rows( Z )

Source: 
A row module over Z of rank 3

Matrix: 
[ [  1,  0 ],
  [  0,  1 ],
  [  0,  0 ] ]

Range: 
A row module over Z of rank 2
gap> proj2 := ProjectionInFactorOfDirectSum( [ obj5, obj6 ], 2 );
<A morphism in Rows( Z )>
gap> Display( proj2 );
A morphism in Rows( Z )

Source: 
A row module over Z of rank 3

Matrix: 
[ [  0 ],
  [  0 ],
  [  1 ] ]

Range: 
A row module over Z of rank 1
gap> k := WeakKernelEmbedding( proj1 );
<A morphism in Rows( Z )>
gap> Display( k );
A morphism in Rows( Z )

Source: 
A row module over Z of rank 1

Matrix: 
[ [  0,  0,  1 ] ]

Range: 
A row module over Z of rank 3
gap> ck := WeakCokernelProjection( k );
<A morphism in Rows( Z )>
gap> Display( ck );
A morphism in Rows( Z )

Source: 
A row module over Z of rank 3

Matrix: 
[ [   0,  -1 ],
  [   1,   0 ],
  [   0,   0 ] ]

Range: 
A row module over Z of rank 2
gap> IsMonomorphism( k );
true
gap> IsEpimorphism( k );
false
gap> IsMonomorphism( ck );
false
gap> IsEpimorphism( ck );
true
gap> mor1 := CategoryOfRowsMorphism( obj5, HomalgMatrix( [[ 1 ], [ 2 ]], 2, 1, S ), obj6 );
<A morphism in Rows( Z )>
gap> Display( mor1 );
A morphism in Rows( Z )

Source: 
A row module over Z of rank 2

Matrix: 
[ [  1 ],
  [  2 ] ]

Range: 
A row module over Z of rank 1
gap> mor2 := IdentityMorphism( obj6 );
<An identity morphism in Rows( Z )>
gap> Display( mor2 );
An identity morphism in Rows( Z )

Source: 
A row module over Z of rank 1

Matrix: 
[ [  1 ] ]

Range: 
A row module over Z of rank 1
gap> lift := Lift( mor1, mor2 );
<A morphism in Rows( Z )>
gap> Display( lift );
A morphism in Rows( Z )

Source: 
A row module over Z of rank 2

Matrix: 
[ [  1 ],
  [  2 ] ]

Range: 
A row module over Z of rank 1
gap> source := CategoryOfRowsObject( 1, rows );
<A row module over Z of rank 1>
gap> range := CategoryOfRowsObject( 2, rows );
<A row module over Z of rank 2>
gap> mor := CategoryOfRowsMorphism( source, HomalgMatrix( [[ 2, 3 ]], 1, 2, S ), range );
<A morphism in Rows( Z )>
gap> colift := Colift( mor2, mor );
<A morphism in Rows( Z )>
gap> Display( colift );
A morphism in Rows( Z )

Source: 
A row module over Z of rank 1

Matrix: 
[ [  2,  3 ] ]

Range: 
A row module over Z of rank 2
gap> fp := WeakBiFiberProduct( mor1, mor2 );
<A row module over Z of rank 2>
gap> fp_proj := ProjectionOfBiasedWeakFiberProduct( mor1, mor2 );
<A morphism in Rows( Z )>
gap> Display( fp_proj );
A morphism in Rows( Z )

Source: 
A row module over Z of rank 2

Matrix: 
[ [  -2,   1 ],
  [  -1,   0 ] ]

Range: 
A row module over Z of rank 2
gap> po := WeakBiPushout( mor, mor2 );
<A row module over Z of rank 2>
gap> inj_push := InjectionOfBiasedWeakPushout( mor, mor2 );
<A morphism in Rows( Z )>
gap> Display( inj_push );
A morphism in Rows( Z )

Source: 
A row module over Z of rank 2

Matrix: 
[ [  -3,   1 ],
  [   2,  -1 ] ]

Range: 
A row module over Z of rank 2
gap> Q := HomalgFieldOfRationals();;
gap> rows := CategoryOfRows( Q );;
gap> homalg_matrix := HomalgMatrix( [ [ 1, 0 ],
>                                  [ 0, 1 ],
>                                  [ -2, 0] ], 3, 2, Q );;
gap> alpha := homalg_matrix / rows;;
gap> diagram := [ alpha, (2 / Q) * alpha, (3 / Q) * alpha ];;
gap> equalizer := EmbeddingOfEqualizer( diagram );;
gap> Display( EntriesOfHomalgMatrixAsListList( UnderlyingMatrix( equalizer ) ) );
[ [ 2, 0, 1 ] ]
gap> equalizer_d1 := PreCompose( equalizer, diagram[1] );;
gap> equalizer_d2 := PreCompose( equalizer, diagram[2] );;
gap> equalizer_d3 := PreCompose( equalizer, diagram[3] );;
gap> IsEqualForMorphisms( equalizer_d1, equalizer_d2 );
true
gap> IsEqualForMorphisms( equalizer_d2, equalizer_d3 );
true
gap> IsEqualForMorphisms( equalizer_d1, equalizer_d3 );
true
gap> universal_morphism := UniversalMorphismIntoEqualizer( Source(alpha), diagram, Source( (2 / Q) * equalizer ), (2 / Q) * equalizer );;
gap> Display( EntriesOfHomalgMatrixAsListList( UnderlyingMatrix( universal_morphism ) ) );
[ [ 2 ] ]
gap> IsEqualForMorphisms( PreCompose( universal_morphism, equalizer ), (2 / Q) * equalizer );
true
gap> Q := HomalgFieldOfRationals();;
gap> rows := CategoryOfRows( Q );;
gap> homalg_matrix := HomalgMatrix( [ [ 1, 0, -2 ],
>                                  [ 0, 1, 0 ] ], 2, 3, Q );;
gap> alpha := homalg_matrix / rows;;
gap> diagram := [ alpha, (2 / Q) * alpha, (3 / Q) * alpha ];;
gap> coequalizer := ProjectionOntoCoequalizer( diagram );;
gap> Display( EntriesOfHomalgMatrixAsListList( UnderlyingMatrix( coequalizer ) ) );
[ [ 2 ], [ 0 ], [ 1 ] ]
gap> coequalizer_d1 := PreCompose( diagram[1], coequalizer );;
gap> coequalizer_d2 := PreCompose( diagram[2], coequalizer );;
gap> coequalizer_d3 := PreCompose( diagram[3], coequalizer );;
gap> IsEqualForMorphisms( coequalizer_d1, coequalizer_d2 );
true
gap> IsEqualForMorphisms( coequalizer_d2, coequalizer_d3 );
true
gap> IsEqualForMorphisms( coequalizer_d1, coequalizer_d3 );
true
gap> universal_morphism := UniversalMorphismFromCoequalizer( Range(alpha), diagram, Range( (2 / Q) * coequalizer ), (2 / Q) * coequalizer );;
gap> Display( EntriesOfHomalgMatrixAsListList( UnderlyingMatrix( universal_morphism ) ) );
[ [ 2 ] ]
gap> IsEqualForMorphisms( PreCompose( coequalizer,  universal_morphism ), (2 / Q) * coequalizer );
true

5.4 Simplifications

gap> R := HomalgRingOfIntegers();;
gap> rows := CategoryOfRows( R );;
gap> M := HomalgMatrix( [ [ 2, 2, 2 ], [ 3, 3, 3 ] ], 2, 3, R );;
gap> alpha := AsCategoryOfRowsMorphism( M, rows );;
gap> pi := PreCompose( [
>     SimplifySourceAndRange_IsoFromInputSource( alpha, infinity ),
>     SimplifySourceAndRange( alpha, infinity ),
>     SimplifySourceAndRange_IsoToInputRange( alpha, infinity ) ] );;
gap> IsCongruentForMorphisms( pi, alpha );
true
gap> IsOne(
>     PreCompose( SimplifySourceAndRange_IsoFromInputSource( alpha, infinity ), SimplifySourceAndRange_IsoToInputSource( alpha, infinity ) )
> );
true
gap> IsOne(
>     PreCompose( SimplifySourceAndRange_IsoFromInputRange( alpha, infinity ), SimplifySourceAndRange_IsoToInputRange( alpha, infinity ) )
> );
true
gap> pi2 := PreCompose(
>     SimplifySource_IsoFromInputObject( alpha, infinity ),
>     SimplifySource( alpha, infinity )
> );;
gap> IsCongruentForMorphisms( pi2, alpha );
true
gap> IsOne( PreCompose( SimplifySource_IsoFromInputObject( alpha, infinity ), SimplifySource_IsoToInputObject( alpha, infinity ) ) );
true
gap> pi3 := PreCompose(
>     SimplifyRange( alpha, infinity ),
>     SimplifyRange_IsoToInputObject( alpha, infinity )
> );;
gap> IsCongruentForMorphisms( pi3, alpha );
true
gap> IsOne( PreCompose( SimplifyRange_IsoFromInputObject( alpha, infinity ), SimplifyRange_IsoToInputObject( alpha, infinity ) ) );
true
gap> R := HomalgRingOfIntegers();;
gap> cols := CategoryOfColumns( R );;
gap> M := HomalgMatrix( [ [ 2, 2, 2 ], [ 3, 3, 3 ] ], 2, 3, R );;
gap> alpha := AsCategoryOfColumnsMorphism( M, cols );;
gap> pi := PreCompose( [
>     SimplifySourceAndRange_IsoFromInputSource( alpha, infinity ),
>     SimplifySourceAndRange( alpha, infinity ), 
>     SimplifySourceAndRange_IsoToInputRange( alpha, infinity ) ] );;
gap> IsCongruentForMorphisms( pi, alpha );
true
gap> IsOne(
>     PreCompose( SimplifySourceAndRange_IsoFromInputSource( alpha, infinity ), SimplifySourceAndRange_IsoToInputSource( alpha, infinity ) )
> );
true
gap> IsOne(
>     PreCompose( SimplifySourceAndRange_IsoFromInputRange( alpha, infinity ), SimplifySourceAndRange_IsoToInputRange( alpha, infinity ) )
> );
true
gap> pi2 := PreCompose(
>     SimplifySource_IsoFromInputObject( alpha, infinity ),
>     SimplifySource( alpha, infinity )
> );;
gap> IsCongruentForMorphisms( pi2, alpha );
true
gap> IsOne( PreCompose( SimplifySource_IsoFromInputObject( alpha, infinity ), SimplifySource_IsoToInputObject( alpha, infinity ) ) );
true
gap> pi3 := PreCompose(
>     SimplifyRange( alpha, infinity ),
>     SimplifyRange_IsoToInputObject( alpha, infinity )
> );;
gap> IsCongruentForMorphisms( pi3, alpha );
true
gap> IsOne( PreCompose( SimplifyRange_IsoFromInputObject( alpha, infinity ), SimplifyRange_IsoToInputObject( alpha, infinity ) ) );
true
 [Top of Book]  [Contents]   [Previous Chapter]   [Next Chapter] 
Goto Chapter: Top 1 2 3 4 5 6 7 8 9 10 11 12 13 Ind

generated by GAPDoc2HTML