Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
Download

GAP 4.8.9 installation with standard packages -- copy to your CoCalc project to get it

563574 views
1
2
3 Quick Start
3
4
This chapter should give you a quick guide to create your first example in
5
homalg.
6
7
8
3.1 Why are all examples in this manual over ℤ or ℤ/mℤ?
9
10
As the reader might notice, all examples in this manual will be either over
11
ℤ or over one of its residue class rings ℤ/mℤ. There are two reasons for
12
this. The first reason is that GAP does not natively support rings other
13
than ℤ in a sufficient way (--> 1.1-2).
14
15
The second and more important reason is to underline the fact the all
16
effective homological constructions that are relevant for Modules have only
17
as much to do with the Gröbnerbasis algorithm as they do with the Hermite
18
algorithm for the ring ℤ; both algorithms are used to effectively solve
19
inhomogeneous linear systems over the respective ring. And Modules is
20
designed to use rings and matrices over these rings together with all their
21
operations as a black box. In other words: Because Modules works for ℤ, it
22
works by its design for all other computable rings.
23
24
25
3.2 gap> ExamplesForHomalg();
26
27
To quickly create a ring for use with Modules enter
28
ExamplesForHomalg();
29
which will load the package ExamplesForHomalg (if installed) and provide a
30
step by step guide to create the ring. For the full core functionality you
31
need to install the packages homalg, HomalgToCAS, IO_ForHomalg,
32
RingsForHomalg, Gauss, and GaussForHomalg. They are part of the homalg
33
project.
34
35
36
3.3 A typical example
37
38
39
3.3-1 HomHom
40
41
The following example is taken from Section 2 of [BR06].
42
The computation takes place over the residue class ring R=ℤ/2^8ℤ using the
43
generic support for residue class rings provided by the subpackage
44
ResidueClassRingForHomalg of the MatricesForHomalg package. For a native
45
support of the rings R=ℤ/p^nℤ use the GaussForHomalg package.
46
47
Here we compute the (infinite) long exact homology sequence of the covariant
48
functor Hom(Hom(-,ℤ/2^7ℤ),ℤ/2^4ℤ) (and its left derived functors) applied to
49
the short exact sequence
50
0 -> M_=ℤ/2^2ℤ --alpha_1--> M=ℤ/2^5ℤ --alpha_2--> _M=ℤ/2^3ℤ -> 0.
51
52
 Example 
53
gap> ZZ := HomalgRingOfIntegers( );
54
Z
55
gap> Display( ZZ );
56
<An internal ring>
57
gap> R := ZZ / 2^8;
58
Z/( 256 )
59
gap> Display( R );
60
<A residue class ring>
61
gap> M := LeftPresentation( [ 2^5 ], R );
62
<A cyclic left module presented by 1 relation for a cyclic generator>
63
gap> Display( M );
64
Z/( 256 )/< |[ 32 ]| >
65
gap> _M := LeftPresentation( [ 2^3 ], R );
66
<A cyclic left module presented by 1 relation for a cyclic generator>
67
gap> Display( _M );
68
Z/( 256 )/< |[ 8 ]| >
69
gap> alpha2 := HomalgMap( [ 1 ], M, _M );
70
<A "homomorphism" of left modules>
71
gap> IsMorphism( alpha2 );
72
true
73
gap> alpha2;
74
<A homomorphism of left modules>
75
gap> Display( alpha2 );
76
[ [ 1 ] ]
77

78
modulo [ 256 ]
79

80
the map is currently represented by the above 1 x 1 matrix
81
gap> M_ := Kernel( alpha2 );
82
<A cyclic left module presented by yet unknown relations for a cyclic generato\
83
r>
84
gap> alpha1 := KernelEmb( alpha2 );
85
<A monomorphism of left modules>
86
gap> seq := HomalgComplex( alpha2 );
87
<An acyclic complex containing a single morphism of left modules at degrees 
88
[ 0 .. 1 ]>
89
gap> Add( seq, alpha1 );
90
gap> seq;
91
<A sequence containing 2 morphisms of left modules at degrees [ 0 .. 2 ]>
92
gap> IsShortExactSequence( seq );
93
true
94
gap> seq;
95
<A short exact sequence containing 2 morphisms of left modules at degrees 
96
[ 0 .. 2 ]>
97
gap> Display( seq );
98
-------------------------
99
at homology degree: 2
100
Z/( 256 )/< |[ 4 ]| > 
101
-------------------------
102
[ [ 24 ] ]
103

104
modulo [ 256 ]
105

106
the map is currently represented by the above 1 x 1 matrix
107
------------v------------
108
at homology degree: 1
109
Z/( 256 )/< |[ 32 ]| > 
110
-------------------------
111
[ [ 1 ] ]
112

113
modulo [ 256 ]
114

115
the map is currently represented by the above 1 x 1 matrix
116
------------v------------
117
at homology degree: 0
118
Z/( 256 )/< |[ 8 ]| > 
119
-------------------------
120
gap> K := LeftPresentation( [ 2^7 ], R );
121
<A cyclic left module presented by 1 relation for a cyclic generator>
122
gap> L := RightPresentation( [ 2^4 ], R );
123
<A cyclic right module on a cyclic generator satisfying 1 relation>
124
gap> triangle := LHomHom( 4, seq, K, L, "t" );
125
<An exact triangle containing 3 morphisms of left complexes at degrees 
126
[ 1, 2, 3, 1 ]>
127
gap> lehs := LongSequence( triangle );
128
<A sequence containing 14 morphisms of left modules at degrees [ 0 .. 14 ]>
129
gap> ByASmallerPresentation( lehs );
130
<A non-zero sequence containing 14 morphisms of left modules at degrees 
131
[ 0 .. 14 ]>
132
gap> IsExactSequence( lehs );
133
false
134
gap> lehs;
135
<A non-zero left acyclic complex containing 
136
14 morphisms of left modules at degrees [ 0 .. 14 ]>
137
gap> Assert( 0, IsLeftAcyclic( lehs ) );
138
gap> Display( lehs );
139
-------------------------
140
at homology degree: 14
141
Z/( 256 )/< |[ 4 ]| > 
142
-------------------------
143
[ [ 4 ] ]
144

145
modulo [ 256 ]
146

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

154
modulo [ 256 ]
155

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

163
modulo [ 256 ]
164

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

172
modulo [ 256 ]
173

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

181
modulo [ 256 ]
182

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

190
modulo [ 256 ]
191

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

199
modulo [ 256 ]
200

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

208
modulo [ 256 ]
209

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

217
modulo [ 256 ]
218

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

226
modulo [ 256 ]
227

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

235
modulo [ 256 ]
236

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

244
modulo [ 256 ]
245

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

253
modulo [ 256 ]
254

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

262
modulo [ 256 ]
263

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

270
271
272