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

1035323 views
1
2
4 Functions and operations for the GAP object type SCPolyhedralComplex
3
4
In the following all operations for the GAP object type SCPolyhedralComplex
5
are listed. I. e. for the following operations only one method is
6
implemented to deal with all geometric objects derived from this object
7
type.
8
9
10
4.1 Computing properties of objects of type SCPolyhedralComplex
11
12
The following functions compute basic properties of objects of type
13
SCPolyhedralComplex (and thus also of objects of type SCSimplicialComplex
14
and SCNormalSurface). None of these functions alter the complex. All
15
properties are returned as immutable objects (this ensures data consistency
16
of the cached properties of a simplicial complex). Use ShallowCopy or the
17
internal simpcomp function SCIntFunc.DeepCopy to get a mutable copy.
18
19
Note: every object is internally stored with the standard vertex labeling
20
from 1 to n and a maptable to restore the original vertex labeling. Thus, we
21
have to relabel some of the complex properties (facets, etc...) whenever we
22
want to return them to the user. As a consequence, some of the functions
23
exist twice, one of them with the appendix "Ex". These functions return the
24
standard labeling whereas the other ones relabel the result to the original
25
labeling.
26
27
4.1-1 SCFacets
28
29
SCFacets( complex )  method
30
Returns: a facet list upon success, fail otherwise.
31
32
Returns the facets of a simplicial complex in the original vertex labeling.
33
34
 Example 
35
 gap> c:=SC([[2,3],[3,4],[4,2]]);;
36
 gap> SCFacets(c);
37
 [ [ 2, 3 ], [ 2, 4 ], [ 3, 4 ] ]
38
 
39

40
41
4.1-2 SCFacetsEx
42
43
SCFacetsEx( complex )  method
44
Returns: a facet list upon success, fail otherwise.
45
46
Returns the facets of a simplicial complex as they are stored, i. e. with
47
standard vertex labeling from 1 to n.
48
49
 Example 
50
 gap> c:=SC([[2,3],[3,4],[4,2]]);;
51
 gap> SCFacetsEx(c);
52
 [ [ 1, 2 ], [ 1, 3 ], [ 2, 3 ] ]
53
 
54

55
56
4.1-3 SCVertices
57
58
SCVertices( complex )  method
59
Returns: a list of vertex labels of complex upon success, fail otherwise.
60
61
Returns the vertex labels of a simplicial complex complex.
62
63
 Example 
64
 gap> sphere:=SC([["x",45,[1,1]],["x",45,["b",3]],["x",[1,1],
65
 ["b",3]],[45,[1,1],["b",3]]]);;
66
 gap> SCVerticesEx(sphere);
67
 [ 1 .. 4 ]
68
 gap> SCVertices(sphere);
69
 [ 45, [ 1, 1 ], "x", [ "b", 3 ] ]
70
 
71

72
73
4.1-4 SCVerticesEx
74
75
SCVerticesEx( complex )  method
76
Returns: [ 1, ... , n ] upon success, fail otherwise.
77
78
Returns [1, ... , n ], where n is the number of vertices of a simplicial
79
complex complex.
80
81
 Example 
82
 gap> c:=SC([[1,4,5],[4,9,8],[12,13,14,15,16,17]]);;
83
 gap> SCVerticesEx(c);
84
 [ 1 .. 11 ]
85
 
86

87
88
89
4.2 Vertex labelings and label operations
90
91
This section focuses on functions operating on the labels of a complex such
92
as the name or the vertex labeling.
93
94
Internally, simpcomp uses the standard labeling [1, ... , n]. It is
95
recommended to use simple vertex labels like integers and, whenever
96
possible, the standard labeling, see also SCRelabelStandard (4.2-7).
97
98
4.2-1 SCLabelMax
99
100
SCLabelMax( complex )  method
101
Returns: vertex label of complex (an integer, a short list, a character, a
102
short string) upon success, fail otherwise.
103
104
The maximum over all vertex labels is determined by the GAP function
105
MaximumList.
106
107
 Example 
108
 gap> c:=SCBdSimplex(3);;
109
 gap> SCRelabel(c,[10,100,100000,3500]);;
110
 gap> SCLabelMax(c);
111
 100000
112
 
113

114
115
 Example 
116
 gap> c:=SCBdSimplex(3);;
117
 gap> SCRelabel(c,["a","bbb",5,[1,1]]);;
118
 gap> SCLabelMax(c);
119
 "bbb"
120
 
121

122
123
4.2-2 SCLabelMin
124
125
SCLabelMin( complex )  method
126
Returns: vertex label of complex (an integer, a short list, a character, a
127
short string) upon success, fail otherwise.
128
129
The minimum over all vertex labels is determined by the GAP function
130
MinimumList.
131
132
 Example 
133
 gap> c:=SCBdSimplex(3);;
134
 gap> SCRelabel(c,[10,100,100000,3500]);;
135
 gap> SCLabelMin(c);
136
 10
137
 
138

139
140
 Example 
141
 gap> c:=SCBdSimplex(3);;
142
 gap> SCRelabel(c,["a","bbb",5,[1,1]]);;
143
 gap> SCLabelMin(c);
144
 5
145
 
146

147
148
4.2-3 SCLabels
149
150
SCLabels( complex )  method
151
Returns: a list of vertex labels of complex (a list of integers, short
152
lists, characters, short strings, ...) upon success, fail
153
otherwise.
154
155
Returns the vertex labels of complex as a list. This is a synonym of
156
SCVertices (4.1-3).
157
158
 Example 
159
 gap> c:=SCFromFacets(Combinations(["a","b","c","d"],3));;
160
 gap> SCLabels(c);
161
 [ "a", "b", "c", "d" ]
162
 
163

164
165
4.2-4 SCName
166
167
SCName( complex )  operation
168
Returns: a string upon success, fail otherwise.
169
170
Returns the name of a simplicial complex complex.
171
172
 Example 
173
 gap> c:=SCBdSimplex(5);;
174
 gap> SCName(c);
175
 "S^4_6"
176
 
177

178
179
 Example 
180
 gap> c:=SC([[1,2],[2,3],[3,1]]);;
181
 gap> SCName(c);
182
 "unnamed complex 2"
183
 
184

185
186
4.2-5 SCReference
187
188
SCReference( complex )  operation
189
Returns: a string upon success, fail otherwise.
190
191
Returns a literature reference of a polyhedral complex complex.
192
193
 Example 
194
 gap> c:=SCLib.Load(253);;
195
 gap> SCReference(c);
196
 "F.H.Lutz: 'The Manifold Page', http://www.math.tu-berlin.de/diskregeom/stella\
197
 r/"
198
 gap> c:=SC([[1,2],[2,3],[3,1]]);;
199
 gap> SCReference(c);
200
 #I SCReference: complex lacks reference.
201
 fail
202
 
203

204
205
4.2-6 SCRelabel
206
207
SCRelabel( complex, maptable )  method
208
Returns: true upon success, fail otherwise.
209
210
maptable has to be a list of length n where n is the number of vertices of
211
complex. The function maps the i-th entry of maptable to the i-th entry of
212
the current vertex labels. If complex has the standard vertex labeling [1,
213
... , n] the vertex label i is mapped to maptable[i].
214
215
Note that the elements of maptable must admit a total ordering. Hence,
216
following Section 4.11 of the GAP manual, they must be members of one of the
217
following families: rationals IsRat, cyclotomics IsCyclotomic, finite field
218
elements IsFFE, permutations IsPerm, booleans IsBool, characters IsChar and
219
lists (strings) IsList.
220
221
Internally the property ``SCVertices'' of complex is replaced by maptable.
222
223
 Example 
224
 gap> list:=SCLib.SearchByAttribute("F[1]=12");; 
225
 gap> c:=SCLib.Load(list[1][1]);;
226
 gap> SCVertices(c);
227
 [ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12 ]
228
 gap> SCRelabel(c,["a","b","c","d","e","f","g","h","i","j","k","l"]);
229
 true
230
 gap> SCLabels(c);
231
 [ "a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l" ]
232
 
233

234
235
4.2-7 SCRelabelStandard
236
237
SCRelabelStandard( complex )  method
238
Returns: true upon success, fail otherwise.
239
240
Maps vertex labels v_1 , ... , v_n of complex to [1 , ... , n]. Internally
241
the property "SCVertices" is replaced by [1 , ... , n].
242
243
 Example 
244
 gap> list:=SCLib.SearchByAttribute("F[1]=12");; 
245
 gap> c:=SCLib.Load(list[1][1]);;
246
 gap> SCRelabel(c,[4..15]);
247
 true
248
 gap> SCVertices(c);
249
 [ 4 .. 15 ]
250
 gap> SCRelabelStandard(c);
251
 true
252
 gap> SCLabels(c);
253
 [ 1 .. 12 ]
254
 
255

256
257
4.2-8 SCRelabelTransposition
258
259
SCRelabelTransposition( complex, pair )  method
260
Returns: true upon success, fail otherwise.
261
262
Permutes vertex labels of a single pair of vertices. pair has to be a list
263
of length 2 and a sublist of the property ``SCVertices''.
264
265
The function is equivalent to SCRelabel (4.2-6) with maptable = [
266
SCVertices[1] , ... , SCVertices[j] , ... , SCVertices[i] , dots ,
267
SCVertices[n]] if pair = [ SCVertices[j] , SCVertices[i]], j ≤ i, j ≠ i.
268
269
 Example 
270
 gap> c:=SCBdSimplex(3);;
271
 gap> SCVertices(c);
272
 [ 1, 2, 3, 4 ]
273
 gap> SCRelabelTransposition(c,[1,2]);;
274
 gap> SCLabels(c);
275
 [ 2, 1, 3, 4 ]
276
 
277

278
279
4.2-9 SCRename
280
281
SCRename( complex, name )  method
282
Returns: true upon success, fail otherwise.
283
284
Renames a polyhedral complex. The argument name has to be given in form of a
285
string.
286
287
 Example 
288
 gap> c:=SCBdSimplex(5);;
289
 gap> SCName(c);
290
 "S^4_6"
291
 gap> SCRename(c,"mySphere");
292
 true
293
 gap> SCName(c);
294
 "mySphere"
295
 
296

297
298
4.2-10 SCSetReference
299
300
SCSetReference( complex, ref )  method
301
Returns: true upon success, fail otherwise.
302
303
Sets the literature reference of a polyhedral complex. The argument ref has
304
to be given in form of a string.
305
306
 Example 
307
 gap> c:=SCBdSimplex(5);;
308
 gap> SCReference(c);
309
 #I SCReference: complex lacks reference.
310
 fail
311
 gap> SCSetReference(c,"my 5-sphere in my cool paper");
312
 true
313
 gap> SCReference(c);
314
 "my 5-sphere in my cool paper"
315
 
316

317
318
4.2-11 SCUnlabelFace
319
320
SCUnlabelFace( complex, face )  method
321
Returns: a list upon success, fail otherwise.
322
323
Computes the standard labeling of face in complex.
324
325
 Example 
326
 gap> c:=SCBdSimplex(3);;
327
 gap> SCRelabel(c,["a","bbb",5,[1,1]]);;
328
 gap> SCUnlabelFace(c,["a","bbb",5]);
329
 [ 1, 2, 3 ]
330
 
331

332
333
334
4.3 Operations on objects of type SCPolyhedralComplex
335
336
The following functions perform operations on objects of type
337
SCPolyhedralComplex and all of its subtypes. Most of them return simplicial
338
complexes. Thus, this section is closely related to the Sections 6.6 (for
339
objects of type SCSimplicialComplex), ''Generate new complexes from old''.
340
However, the data generated here is rather seen as an intrinsic attribute of
341
the original complex and not as an independent complex.
342
343
4.3-1 SCAntiStar
344
345
SCAntiStar( complex, face )  method
346
Returns: simplicial complex of type SCSimplicialComplex upon success, fail
347
otherwise .
348
349
Computes the anti star of face (a face given as a list of vertices or a
350
scalar interpreted as vertex) in complex, i. e. the complement of face in
351
complex.
352
353
 Example 
354
 gap> SCLib.SearchByName("RP^2"); 
355
 [ [ 3, "RP^2 (VT)" ], [ 635, "RP^2xS^1" ] ]
356
 gap> rp2:=SCLib.Load(last[1][1]);;
357
 gap> SCVertices(rp2);
358
 [ 1, 2, 3, 4, 5, 6 ]
359
 gap> SCAntiStar(rp2,1);
360
 [SimplicialComplex
361
 
362
 Properties known: Dim, FacetsEx, Name, Vertices.
363
 
364
 Name="ast([ 1 ]) in RP^2 (VT)"
365
 Dim=2
366
 
367
 /SimplicialComplex]
368
 gap> last.Facets;
369
 [ [ 2, 3, 4 ], [ 2, 4, 5 ], [ 2, 5, 6 ], [ 3, 4, 6 ], [ 3, 5, 6 ] ]
370
 
371

372
373
4.3-2 SCLink
374
375
SCLink( complex, face )  method
376
Returns: simplicial complex of type SCSimplicialComplex upon success, fail
377
otherwise.
378
379
Computes the link of face (a face given as a list of vertices or a scalar
380
interpreted as vertex) in a polyhedral complex complex, i. e. all facets
381
containing face, reduced by face. if complex is pure, the resulting complex
382
is of dimension dim(complex) - dim(face) -1. If face is not a face of
383
complex the empty complex is returned.
384
385
 Example 
386
 gap> SCLib.SearchByName("RP^2"); 
387
 [ [ 3, "RP^2 (VT)" ], [ 635, "RP^2xS^1" ] ]
388
 gap> rp2:=SCLib.Load(last[1][1]);;
389
 gap> SCVertices(rp2);
390
 [ 1, 2, 3, 4, 5, 6 ]
391
 gap> SCLink(rp2,[1]);
392
 [SimplicialComplex
393
 
394
 Properties known: Dim, FacetsEx, Name, Vertices.
395
 
396
 Name="lk([ 1 ]) in RP^2 (VT)"
397
 Dim=1
398
 
399
 /SimplicialComplex]
400
 gap> last.Facets;
401
 [ [ 2, 3 ], [ 2, 6 ], [ 3, 5 ], [ 4, 5 ], [ 4, 6 ] ]
402
 
403

404
405
4.3-3 SCLinks
406
407
SCLinks( complex, k )  method
408
Returns: a list of simplicial complexes of type SCSimplicialComplex upon
409
success, fail otherwise.
410
411
Computes the link of all k-faces of the polyhedral complex complex and
412
returns them as a list of simplicial complexes. Internally calls SCLink
413
(4.3-2) for every k-face of complex.
414
415
 Example 
416
 gap> c:=SCBdSimplex(4);;
417
 gap> SCLinks(c,0);
418
 [ [SimplicialComplex
419
 
420
 Properties known: Dim, FacetsEx, Name, Vertices.
421
 
422
 Name="lk([ 1 ]) in S^3_5"
423
 Dim=2
424
 
425
 /SimplicialComplex], [SimplicialComplex
426
 
427
 Properties known: Dim, FacetsEx, Name, Vertices.
428
 
429
 Name="lk([ 2 ]) in S^3_5"
430
 Dim=2
431
 
432
 /SimplicialComplex], [SimplicialComplex
433
 
434
 Properties known: Dim, FacetsEx, Name, Vertices.
435
 
436
 Name="lk([ 3 ]) in S^3_5"
437
 Dim=2
438
 
439
 /SimplicialComplex], [SimplicialComplex
440
 
441
 Properties known: Dim, FacetsEx, Name, Vertices.
442
 
443
 Name="lk([ 4 ]) in S^3_5"
444
 Dim=2
445
 
446
 /SimplicialComplex], [SimplicialComplex
447
 
448
 Properties known: Dim, FacetsEx, Name, Vertices.
449
 
450
 Name="lk([ 5 ]) in S^3_5"
451
 Dim=2
452
 
453
 /SimplicialComplex] ]
454
 gap> SCLinks(c,1);
455
 [ [SimplicialComplex
456
 
457
 Properties known: Dim, FacetsEx, Name, Vertices.
458
 
459
 Name="lk([ 1, 2 ]) in S^3_5"
460
 Dim=1
461
 
462
 /SimplicialComplex], [SimplicialComplex
463
 
464
 Properties known: Dim, FacetsEx, Name, Vertices.
465
 
466
 Name="lk([ 1, 3 ]) in S^3_5"
467
 Dim=1
468
 
469
 /SimplicialComplex], [SimplicialComplex
470
 
471
 Properties known: Dim, FacetsEx, Name, Vertices.
472
 
473
 Name="lk([ 1, 4 ]) in S^3_5"
474
 Dim=1
475
 
476
 /SimplicialComplex], [SimplicialComplex
477
 
478
 Properties known: Dim, FacetsEx, Name, Vertices.
479
 
480
 Name="lk([ 1, 5 ]) in S^3_5"
481
 Dim=1
482
 
483
 /SimplicialComplex], [SimplicialComplex
484
 
485
 Properties known: Dim, FacetsEx, Name, Vertices.
486
 
487
 Name="lk([ 2, 3 ]) in S^3_5"
488
 Dim=1
489
 
490
 /SimplicialComplex], [SimplicialComplex
491
 
492
 Properties known: Dim, FacetsEx, Name, Vertices.
493
 
494
 Name="lk([ 2, 4 ]) in S^3_5"
495
 Dim=1
496
 
497
 /SimplicialComplex], [SimplicialComplex
498
 
499
 Properties known: Dim, FacetsEx, Name, Vertices.
500
 
501
 Name="lk([ 2, 5 ]) in S^3_5"
502
 Dim=1
503
 
504
 /SimplicialComplex], [SimplicialComplex
505
 
506
 Properties known: Dim, FacetsEx, Name, Vertices.
507
 
508
 Name="lk([ 3, 4 ]) in S^3_5"
509
 Dim=1
510
 
511
 /SimplicialComplex], [SimplicialComplex
512
 
513
 Properties known: Dim, FacetsEx, Name, Vertices.
514
 
515
 Name="lk([ 3, 5 ]) in S^3_5"
516
 Dim=1
517
 
518
 /SimplicialComplex], [SimplicialComplex
519
 
520
 Properties known: Dim, FacetsEx, Name, Vertices.
521
 
522
 Name="lk([ 4, 5 ]) in S^3_5"
523
 Dim=1
524
 
525
 /SimplicialComplex] ]
526
 
527

528
529
4.3-4 SCStar
530
531
SCStar( complex, face )  method
532
Returns: simplicial complex of type SCSimplicialComplex upon success, fail
533
otherwise .
534
535
Computes the star of face (a face given as a list of vertices or a scalar
536
interpreted as vertex) in a polyhedral complex complex, i. e. the set of
537
facets of complex that contain face.
538
539
 Example 
540
 gap> SCLib.SearchByName("RP^2"); 
541
 [ [ 3, "RP^2 (VT)" ], [ 635, "RP^2xS^1" ] ]
542
 gap> rp2:=SCLib.Load(last[1][1]);;
543
 gap> SCVertices(rp2);
544
 [ 1, 2, 3, 4, 5, 6 ]
545
 gap> SCStar(rp2,1);
546
 [SimplicialComplex
547
 
548
 Properties known: Dim, FacetsEx, Name, Vertices.
549
 
550
 Name="star([ 1 ]) in RP^2 (VT)"
551
 Dim=2
552
 
553
 /SimplicialComplex]
554
 gap> last.Facets;
555
 [ [ 1, 2, 3 ], [ 1, 2, 6 ], [ 1, 3, 5 ], [ 1, 4, 5 ], [ 1, 4, 6 ] ]
556
 
557

558
559
4.3-5 SCStars
560
561
SCStars( complex, k )  method
562
Returns: a list of simplicial complexes of type SCSimplicialComplex upon
563
success, fail otherwise.
564
565
Computes the star of all k-faces of the polyhedral complex complex and
566
returns them as a list of simplicial complexes. Internally calls SCStar
567
(4.3-4) for every k-face of complex.
568
569
 Example 
570
 gap> SCLib.SearchByName("T^2"){[1..6]};
571
 [ [ 4, "T^2 (VT)" ], [ 5, "T^2 (VT)" ], [ 9, "T^2 (VT)" ], [ 10, "T^2 (VT)" ],
572
 [ 18, "T^2 (VT)" ], [ 20, "(T^2)#2" ] ]
573
 gap> torus:=SCLib.Load(last[1][1]);; # the minimal 7-vertex torus
574
 gap> SCStars(torus,0); # 7 2-discs as vertex stars
575
 [ [SimplicialComplex
576
 
577
 Properties known: Dim, FacetsEx, Name, Vertices.
578
 
579
 Name="star([ 1 ]) in T^2 (VT)"
580
 Dim=2
581
 
582
 /SimplicialComplex], [SimplicialComplex
583
 
584
 Properties known: Dim, FacetsEx, Name, Vertices.
585
 
586
 Name="star([ 2 ]) in T^2 (VT)"
587
 Dim=2
588
 
589
 /SimplicialComplex], [SimplicialComplex
590
 
591
 Properties known: Dim, FacetsEx, Name, Vertices.
592
 
593
 Name="star([ 3 ]) in T^2 (VT)"
594
 Dim=2
595
 
596
 /SimplicialComplex], [SimplicialComplex
597
 
598
 Properties known: Dim, FacetsEx, Name, Vertices.
599
 
600
 Name="star([ 4 ]) in T^2 (VT)"
601
 Dim=2
602
 
603
 /SimplicialComplex], [SimplicialComplex
604
 
605
 Properties known: Dim, FacetsEx, Name, Vertices.
606
 
607
 Name="star([ 5 ]) in T^2 (VT)"
608
 Dim=2
609
 
610
 /SimplicialComplex], [SimplicialComplex
611
 
612
 Properties known: Dim, FacetsEx, Name, Vertices.
613
 
614
 Name="star([ 6 ]) in T^2 (VT)"
615
 Dim=2
616
 
617
 /SimplicialComplex], [SimplicialComplex
618
 
619
 Properties known: Dim, FacetsEx, Name, Vertices.
620
 
621
 Name="star([ 7 ]) in T^2 (VT)"
622
 Dim=2
623
 
624
 /SimplicialComplex] ]
625
 
626

627
628
629