Goto Chapter: Top 1 2 3 4 5 6 7 8 9 10 11 12 13 A B C Bib Ind

### 3 Quick Start

This chapter should give you a quick guide to create your first example in homalg.

#### 3.1 Why are all examples in this manual over ℤ or ℤ/mℤ?

As the reader might notice, all examples in this manual will be either over ℤ or over one of its residue class rings ℤ/mℤ. There are two reasons for this. The first reason is that GAP does not natively support rings other than ℤ in a sufficient way (--> Rings supported in a sufficient way).

The second and more important reason is to underline the fact the all effective homological constructions that are relevant for Modules have only as much to do with the Gröbnerbasis algorithm as they do with the Hermite algorithm for the ring ℤ; both algorithms are used to effectively solve inhomogeneous linear systems over the respective ring. And Modules is designed to use rings and matrices over these rings together with all their operations as a black box. In other words: Because Modules works for , it works by its design for all other computable rings.

#### 3.2 gap> ExamplesForHomalg();

To quickly create a ring for use with Modules enter

ExamplesForHomalg();

which will load the package ExamplesForHomalg (if installed) and provide a step by step guide to create the ring. For the full core functionality you need to install the packages homalg, HomalgToCAS, IO_ForHomalg, RingsForHomalg, Gauss, and GaussForHomalg. They are part of the homalg project.

#### 3.3 A typical example

##### 3.3-1 HomHom

The following example is taken from Section 2 of [BR06].

The computation takes place over the residue class ring R=ℤ/2^8ℤ using the generic support for residue class rings provided by the subpackage ResidueClassRingForHomalg of the MatricesForHomalg package. For a native support of the rings R=ℤ/p^nℤ use the GaussForHomalg package.

Here we compute the (infinite) long exact homology sequence of the covariant functor Hom(Hom(-,ℤ/2^7ℤ),ℤ/2^4ℤ) (and its left derived functors) applied to the short exact sequence

0 -> M_=ℤ/2^2ℤ --alpha_1--> M=ℤ/2^5ℤ --alpha_2--> _M=ℤ/2^3ℤ -> 0.

gap> ZZ := HomalgRingOfIntegers( );
Z
gap> Display( ZZ );
<An internal ring>
gap> R := ZZ / 2^8;
Z/( 256 )
gap> Display( R );
<A residue class ring>
gap> M := LeftPresentation( [ 2^5 ], R );
<A cyclic left module presented by 1 relation for a cyclic generator>
gap> Display( M );
Z/( 256 )/< |[ 32 ]| >
gap> _M := LeftPresentation( [ 2^3 ], R );
<A cyclic left module presented by 1 relation for a cyclic generator>
gap> Display( _M );
Z/( 256 )/< |[ 8 ]| >
gap> alpha2 := HomalgMap( [ 1 ], M, _M );
<A "homomorphism" of left modules>
gap> IsMorphism( alpha2 );
true
gap> alpha2;
<A homomorphism of left modules>
gap> Display( alpha2 );
[ [  1 ] ]

modulo [ 256 ]

the map is currently represented by the above 1 x 1 matrix
gap> M_ := Kernel( alpha2 );
<A cyclic left module presented by yet unknown relations for a cyclic generato\
r>
gap> alpha1 := KernelEmb( alpha2 );
<A monomorphism of left modules>
gap> seq := HomalgComplex( alpha2 );
<An acyclic complex containing a single morphism of left modules at degrees
[ 0 .. 1 ]>
gap> Add( seq, alpha1 );
gap> seq;
<A sequence containing 2 morphisms of left modules at degrees [ 0 .. 2 ]>
gap> IsShortExactSequence( seq );
true
gap> seq;
<A short exact sequence containing 2 morphisms of left modules at degrees
[ 0 .. 2 ]>
gap> Display( seq );
-------------------------
at homology degree: 2
Z/( 256 )/< |[ 4 ]| >
-------------------------
[ [  24 ] ]

modulo [ 256 ]

the map is currently represented by the above 1 x 1 matrix
------------v------------
at homology degree: 1
Z/( 256 )/< |[ 32 ]| >
-------------------------
[ [  1 ] ]

modulo [ 256 ]

the map is currently represented by the above 1 x 1 matrix
------------v------------
at homology degree: 0
Z/( 256 )/< |[ 8 ]| >
-------------------------
gap> K := LeftPresentation( [ 2^7 ], R );
<A cyclic left module presented by 1 relation for a cyclic generator>
gap> L := RightPresentation( [ 2^4 ], R );
<A cyclic right module on a cyclic generator satisfying 1 relation>
gap> triangle := LHomHom( 4, seq, K, L, "t" );
<An exact triangle containing 3 morphisms of left complexes at degrees
[ 1, 2, 3, 1 ]>
gap> lehs := LongSequence( triangle );
<A sequence containing 14 morphisms of left modules at degrees [ 0 .. 14 ]>
gap> ByASmallerPresentation( lehs );
<A non-zero sequence containing 14 morphisms of left modules at degrees
[ 0 .. 14 ]>
gap> IsExactSequence( lehs );
false
gap> lehs;
<A non-zero left acyclic complex containing
14 morphisms of left modules at degrees [ 0 .. 14 ]>
gap> Assert( 0, IsLeftAcyclic( lehs ) );
gap> Display( lehs );
-------------------------
at homology degree: 14
Z/( 256 )/< |[ 4 ]| >
-------------------------
[ [  4 ] ]

modulo [ 256 ]

the map is currently represented by the above 1 x 1 matrix
------------v------------
at homology degree: 13
Z/( 256 )/< |[ 8 ]| >
-------------------------
[ [  2 ] ]

modulo [ 256 ]

the map is currently represented by the above 1 x 1 matrix
------------v------------
at homology degree: 12
Z/( 256 )/< |[ 8 ]| >
-------------------------
[ [  2 ] ]

modulo [ 256 ]

the map is currently represented by the above 1 x 1 matrix
------------v------------
at homology degree: 11
Z/( 256 )/< |[ 4 ]| >
-------------------------
[ [  4 ] ]

modulo [ 256 ]

the map is currently represented by the above 1 x 1 matrix
------------v------------
at homology degree: 10
Z/( 256 )/< |[ 8 ]| >
-------------------------
[ [  2 ] ]

modulo [ 256 ]

the map is currently represented by the above 1 x 1 matrix
------------v------------
at homology degree: 9
Z/( 256 )/< |[ 8 ]| >
-------------------------
[ [  2 ] ]

modulo [ 256 ]

the map is currently represented by the above 1 x 1 matrix
------------v------------
at homology degree: 8
Z/( 256 )/< |[ 4 ]| >
-------------------------
[ [  4 ] ]

modulo [ 256 ]

the map is currently represented by the above 1 x 1 matrix
------------v------------
at homology degree: 7
Z/( 256 )/< |[ 8 ]| >
-------------------------
[ [  2 ] ]

modulo [ 256 ]

the map is currently represented by the above 1 x 1 matrix
------------v------------
at homology degree: 6
Z/( 256 )/< |[ 8 ]| >
-------------------------
[ [  2 ] ]

modulo [ 256 ]

the map is currently represented by the above 1 x 1 matrix
------------v------------
at homology degree: 5
Z/( 256 )/< |[ 4 ]| >
-------------------------
[ [  4 ] ]

modulo [ 256 ]

the map is currently represented by the above 1 x 1 matrix
------------v------------
at homology degree: 4
Z/( 256 )/< |[ 8 ]| >
-------------------------
[ [  2 ] ]

modulo [ 256 ]

the map is currently represented by the above 1 x 1 matrix
------------v------------
at homology degree: 3
Z/( 256 )/< |[ 8 ]| >
-------------------------
[ [  2 ] ]

modulo [ 256 ]

the map is currently represented by the above 1 x 1 matrix
------------v------------
at homology degree: 2
Z/( 256 )/< |[ 4 ]| >
-------------------------
[ [  8 ] ]

modulo [ 256 ]

the map is currently represented by the above 1 x 1 matrix
------------v------------
at homology degree: 1
Z/( 256 )/< |[ 16 ]| >
-------------------------
[ [  1 ] ]

modulo [ 256 ]

the map is currently represented by the above 1 x 1 matrix
------------v------------
at homology degree: 0
Z/( 256 )/< |[ 8 ]| >
-------------------------

Goto Chapter: Top 1 2 3 4 5 6 7 8 9 10 11 12 13 A B C Bib Ind

generated by GAPDoc2HTML