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

1034943 views
1
2
5 The GAP object types SCSimplicialComplex and SCNormalSurface
3
4
Currently, the GAP package simpcomp supports data structures for two
5
different kinds of geometric objects, namely simplicial complexes
6
(SCSimplicialComplex) and discrete normal surfaces (SCNormalSurface) which
7
are both subtypes of the GAP object type SCPolyhedralComplex
8
9
10
5.1 The object type SCSimplicialComplex
11
12
A major part of simpcomp deals with the object type SCSimplicialComplex. For
13
a complete list of properties that SCSimplicialComplex handles, see Chapter
14
6. For a few fundamental methods and functions (such as checking the object
15
class, copying objects of this type, etc.) for SCSimplicialComplex see
16
below.
17
18
5.1-1 SCIsSimplicialComplex
19
20
SCIsSimplicialComplex( object )  filter
21
Returns: true or false upon success, fail otherwise.
22
23
Checks if object is of type SCSimplicialComplex. The object type
24
SCSimplicialComplex is derived from the object type SCPropertyObject.
25
26
 Example 
27
 gap> c:=SCEmpty();;
28
 gap> SCIsSimplicialComplex(c);
29
 true
30
 
31

32
33
5.1-2 SCCopy
34
35
SCCopy( complex )  method
36
Returns: a copy of complex upon success, fail otherwise.
37
38
Makes a ``deep copy'' of complex -- this is a copy such that all properties
39
of the copy can be altered without changing the original complex.
40
41
 Example 
42
 gap> c:=SCBdSimplex(4);;
43
 gap> d:=SCCopy(c)-1;;
44
 gap> c.Facets=d.Facets;
45
 false
46
 
47

48
49
 Example 
50
 gap> c:=SCBdSimplex(4);;
51
 gap> d:=SCCopy(c);;
52
 gap> IsIdenticalObj(c,d);
53
 false
54
 
55

56
57
5.1-3 ShallowCopy (SCSimplicialComplex)
58
59
ShallowCopy (SCSimplicialComplex)( complex )  method
60
Returns: a copy of complex upon success, fail otherwise.
61
62
Makes a copy of complex. This is actually a ``deep copy'' such that all
63
properties of the copy can be altered without changing the original complex.
64
Internally calls SCCopy (5.1-2).
65
66
 Example 
67
 gap> c:=SCBdCrossPolytope(7);;
68
 gap> d:=ShallowCopy(c)+10;;
69
 gap> c.Facets=d.Facets;
70
 false
71
 
72

73
74
5.1-4 SCPropertiesDropped
75
76
SCPropertiesDropped( complex )  function
77
Returns: a object of type SCSimplicialComplex upon success, fail otherwise.
78
79
An object of the type SCSimplicialComplex caches its previously calculated
80
properties such that each property only has to be calculated once. This
81
function returns a copy of complex with all properties (apart from Facets,
82
Dim and Name) dropped, clearing all previously computed properties. See also
83
SCPropertyDrop (18.1-8) and SCPropertyTmpDrop (18.1-13).
84
85
 Example 
86
 gap> c:=SC(SCFacets(SCBdCyclicPolytope(10,12)));
87
 [SimplicialComplex
88
 
89
 Properties known: Dim, FacetsEx, Name, Vertices.
90
 
91
 Name="unnamed complex 27"
92
 Dim=9
93
 
94
 /SimplicialComplex]
95
 gap> c.F; time; 
96
 [ 12, 66, 220, 495, 792, 922, 780, 465, 180, 36 ]
97
 48
98
 gap> c.F; time; 
99
 [ 12, 66, 220, 495, 792, 922, 780, 465, 180, 36 ]
100
 0
101
 gap> c:=SCPropertiesDropped(c); 
102
 [SimplicialComplex
103
 
104
 Properties known: Dim, FacetsEx, Name, Vertices.
105
 
106
 Name="unnamed complex 27"
107
 Dim=9
108
 
109
 /SimplicialComplex]
110
 gap> c.F; time; 
111
 [ 12, 66, 220, 495, 792, 922, 780, 465, 180, 36 ]
112
 44
113
 
114

115
116
117
5.2 Overloaded operators of SCSimplicialComplex
118
119
simpcomp overloads some standard operations for the object type
120
SCSimplicialComplex if this definition is intuitive and mathematically
121
sound. See a list of overloaded operators below.
122
123
5.2-1 Operation + (SCSimplicialComplex, Integer)
124
125
Operation + (SCSimplicialComplex, Integer)( complex, value )  method
126
Returns: the simplicial complex passed as argument upon success, fail
127
otherwise.
128
129
Positively shifts the vertex labels of complex (provided that all labels
130
satisfy the property IsAdditiveElement) by the amount specified in value.
131
132
 Example 
133
 gap> c:=SCBdSimplex(3)+10;;
134
 gap> c.Facets;
135
 [ [ 11, 12, 13 ], [ 11, 12, 14 ], [ 11, 13, 14 ], [ 12, 13, 14 ] ]
136
 
137

138
139
5.2-2 Operation - (SCSimplicialComplex, Integer)
140
141
Operation - (SCSimplicialComplex, Integer)( complex, value )  method
142
Returns: the simplicial complex passed as argument upon success, fail
143
otherwise.
144
145
Negatively shifts the vertex labels of complex (provided that all labels
146
satisfy the property IsAdditiveElement) by the amount specified in value.
147
148
 Example 
149
 gap> c:=SCBdSimplex(3)-1;;
150
 gap> c.Facets;
151
 [ [ 0, 1, 2 ], [ 0, 1, 3 ], [ 0, 2, 3 ], [ 1, 2, 3 ] ]
152
 
153

154
155
5.2-3 Operation mod (SCSimplicialComplex, Integer)
156
157
Operation mod (SCSimplicialComplex, Integer)( complex, value )  method
158
Returns: the simplicial complex passed as argument upon success, fail
159
otherwise.
160
161
Takes all vertex labels of complex modulo the value specified in value
162
(provided that all labels satisfy the property IsAdditiveElement). Warning:
163
this might result in different vertices being assigned the same label or
164
even in invalid facet lists, so be careful.
165
166
 Example 
167
 gap> c:=(SCBdSimplex(3)*10) mod 7;;
168
 gap> c.Facets;
169
 [ [ 2, 3, 5 ], [ 2, 3, 6 ], [ 2, 5, 6 ], [ 3, 5, 6 ] ]
170
 
171

172
173
5.2-4 Operation ^ (SCSimplicialComplex, Integer)
174
175
Operation ^ (SCSimplicialComplex, Integer)( complex, value )  method
176
Returns: simplicial complex of type SCSimplicialComplex upon success, fail
177
otherwise.
178
179
Forms the value-th simplicial cartesian power of complex, i.e. the
180
value-fold cartesian product of copies of complex. The complex passed as
181
argument is not altered. Internally calls SCCartesianPower (6.6-1).
182
183
 Example 
184
 gap> c:=SCBdSimplex(2)^2; #a torus
185
 [SimplicialComplex
186
 
187
 Properties known: Dim, FacetsEx, Name, TopologicalType, Vertices.
188
 
189
 Name="(S^1_3)^2"
190
 Dim=2
191
 TopologicalType="(S^1)^2"
192
 
193
 /SimplicialComplex]
194
 
195

196
197
5.2-5 Operation + (SCSimplicialComplex, SCSimplicialComplex)
198
199
Operation + (SCSimplicialComplex, SCSimplicialComplex)( complex1, complex2 )  method
200
Returns: simplicial complex of type SCSimplicialComplex upon success, fail
201
otherwise.
202
203
Forms the connected sum of complex1 and complex2. Uses the lexicographically
204
first facets of both complexes to do the gluing. The complexes passed as
205
arguments are not altered. Internally calls SCConnectedSum (6.6-5).
206
207
 Example 
208
 gap> SCLib.SearchByName("RP^3");
209
 [ [ 45, "RP^3" ], [ 113, "RP^3=L(2,1) (VT)" ], [ 589, "(S^2~S^1)#RP^3" ], 
210
 [ 590, "(S^2xS^1)#RP^3" ], [ 632, "(S^2~S^1)#2#RP^3" ], 
211
 [ 633, "(S^2xS^1)#2#RP^3" ], [ 2414, "RP^3#RP^3" ], 
212
 [ 2426, "RP^3=L(2,1) (VT)" ], [ 2488, "(S^2~S^1)#3#RP^3" ], 
213
 [ 2489, "(S^2xS^1)#3#RP^3" ], [ 2502, "RP^3=L(2,1) (VT)" ], 
214
 [ 7473, "(S^2~S^1)#4#RP^3" ], [ 7474, "(S^2xS^1)#4#RP^3" ], 
215
 [ 7504, "(S^2~S^1)#5#RP^3" ], [ 7505, "(S^2xS^1)#5#RP^3" ] ]
216
 gap> c:=SCLib.Load(last[1][1]);;
217
 gap> SCLib.SearchByName("S^2~S^1"){[1..3]};
218
 [ [ 12, "S^2~S^1 (VT)" ], [ 27, "S^2~S^1 (VT)" ], [ 28, "S^2~S^1 (VT)" ] ]
219
 gap> d:=SCLib.Load(last[1][1]);;
220
 gap> c:=c+d; #form RP^3#(S^2~S^1)
221
 [SimplicialComplex
222
 
223
 Properties known: Dim, FacetsEx, Name, Vertices.
224
 
225
 Name="RP^3#+-S^2~S^1 (VT)"
226
 Dim=3
227
 
228
 /SimplicialComplex]
229
 
230

231
232
5.2-6 Operation - (SCSimplicialComplex, SCSimplicialComplex)
233
234
Operation - (SCSimplicialComplex, SCSimplicialComplex)( complex1, complex2 )  method
235
Returns: simplicial complex of type SCSimplicialComplex upon success, fail
236
otherwise.
237
238
Calls SCDifference (6.10-5)(complex1, complex2)
239
240
5.2-7 Operation * (SCSimplicialComplex, SCSimplicialComplex)
241
242
Operation * (SCSimplicialComplex, SCSimplicialComplex)( complex1, complex2 )  method
243
Returns: simplicial complex of type SCSimplicialComplex upon success, fail
244
otherwise.
245
246
Forms the simplicial cartesian product of complex1 and complex2. Internally
247
calls SCCartesianProduct (6.6-2).
248
249
 Example 
250
 gap> SCLib.SearchByName("RP^2");
251
 [ [ 3, "RP^2 (VT)" ], [ 635, "RP^2xS^1" ] ]
252
 gap> c:=SCLib.Load(last[1][1])*SCBdSimplex(3); #form RP^2 x S^2
253
 [SimplicialComplex
254
 
255
 Properties known: Dim, FacetsEx, Name, Vertices.
256
 
257
 Name="RP^2 (VT)xS^2_4"
258
 Dim=4
259
 
260
 /SimplicialComplex]
261
 
262

263
264
5.2-8 Operation = (SCSimplicialComplex, SCSimplicialComplex)
265
266
Operation = (SCSimplicialComplex, SCSimplicialComplex)( complex1, complex2 )  method
267
Returns: true or false upon success, fail otherwise.
268
269
Calculates whether two simplicial complexes are isomorphic, i.e. are equal
270
up to a relabeling of the vertices.
271
272
 Example 
273
 gap> c:=SCBdSimplex(3);;
274
 gap> c=c+10;
275
 true
276
 gap> c=SCBdCrossPolytope(4);
277
 false
278
 
279

280
281
282
5.3 SCSimplicialComplex as a subtype of Set
283
284
Apart from being a subtype of SCPropertyObject, an object of type
285
SCSimplicialComplex also behaves like a GAP Set type. The elements of the
286
set are given by the facets of the simplical complex, grouped by their
287
dimensionality, i.e. if complex is an object of type SCSimplicialComplex,
288
c[1] refers to the 0-faces of complex, c[2] to the 1-faces, etc.
289
290
5.3-1 Operation Union (SCSimplicialComplex, SCSimplicialComplex)
291
292
Operation Union (SCSimplicialComplex, SCSimplicialComplex)( complex1, complex2 )  method
293
Returns: simplicial complex of type SCSimplicialComplex upon success, fail
294
otherwise.
295
296
Computes the union of two simplicial complexes by calling SCUnion (7.3-16).
297
298
 Example 
299
 gap> c:=Union(SCBdSimplex(3),SCBdSimplex(3)+3); #a wedge of two 2-spheres
300
 [SimplicialComplex
301
 
302
 Properties known: Dim, FacetsEx, Name, Vertices.
303
 
304
 Name="S^2_4 cup S^2_4"
305
 Dim=2
306
 
307
 /SimplicialComplex]
308
 
309

310
311
5.3-2 Operation Difference (SCSimplicialComplex, SCSimplicialComplex)
312
313
Operation Difference (SCSimplicialComplex, SCSimplicialComplex)( complex1, complex2 )  method
314
Returns: simplicial complex of type SCSimplicialComplex upon success, fail
315
otherwise.
316
317
Computes the ``difference'' of two simplicial complexes by calling
318
SCDifference (6.10-5).
319
320
 Example 
321
 gap> c:=SCBdSimplex(3);;
322
 gap> d:=SC([[1,2,3]]);;
323
 gap> disc:=Difference(c,d);;
324
 gap> disc.Facets;
325
 [ [ 1, 2, 4 ], [ 1, 3, 4 ], [ 2, 3, 4 ] ]
326
 gap> empty:=Difference(d,c);;
327
 gap> empty.Dim;
328
 -1
329
 
330

331
332
5.3-3 Operation Intersection (SCSimplicialComplex, SCSimplicialComplex)
333
334
Operation Intersection (SCSimplicialComplex, SCSimplicialComplex)( complex1, complex2 )  method
335
Returns: simplicial complex of type SCSimplicialComplex upon success, fail
336
otherwise.
337
338
Computes the ``intersection'' of two simplicial complexes by calling
339
SCIntersection (6.10-8).
340
341
 Example 
342
 gap> c:=SCBdSimplex(3);; 
343
 gap> d:=SCBdSimplex(3);; 
344
 gap> d:=SCMove(d,[[1,2,3],[]]);;
345
 gap> d:=d+1;; 
346
 gap> s1:=SCIntersection(c,d); 
347
 [SimplicialComplex
348
 
349
 Properties known: Dim, FacetsEx, Name, Vertices.
350
 
351
 Name="S^2_4 cap unnamed complex 20"
352
 Dim=1
353
 
354
 /SimplicialComplex]
355
 gap> s1.Facets; 
356
 [ [ 2, 3 ], [ 2, 4 ], [ 3, 4 ] ]
357
 
358

359
360
5.3-4 Size (SCSimplicialComplex)
361
362
Size (SCSimplicialComplex)( complex )  method
363
Returns: an integer upon success, fail otherwise.
364
365
Returns the ``size'' of a simplicial complex. This is d+1, where d is the
366
dimension of the complex. d+1 is returned instead of d, as all lists in GAP
367
are indexed beginning with 1 -- thus this also holds for all the face
368
lattice related properties of the complex.
369
370
 Example 
371
 gap> SCLib.SearchByAttribute("F=[12,66,108,54]");
372
 [ [ 139, "L_3_1" ], [ 140, "S^2~S^1 (VT)" ], 
373
 [ 141, "(S^2xS^1)#(S^2xS^1) (VT)" ], [ 142, "S^2xS^1 (VT)" ], 
374
 [ 143, "S^2xS^1 (VT)" ], [ 144, "S^2xS^1 (VT)" ], [ 145, "S^2xS^1 (VT)" ], 
375
 [ 146, "S^2~S^1 (VT)" ], [ 147, "S^2~S^1 (VT)" ], [ 148, "S^2~S^1 (VT)" ], 
376
 [ 149, "S^2~S^1 (VT)" ], [ 150, "S^2~S^1 (VT)" ], 
377
 [ 151, "(S^2xS^1)#(S^2xS^1) (VT)" ], [ 152, "S^2xS^1 (VT)" ], 
378
 [ 153, "(S^2xS^1)#(S^2xS^1) (VT)" ], [ 154, "S^2xS^1 (VT)" ], 
379
 [ 155, "S^2xS^1 (VT)" ], [ 156, "S^2~S^1 (VT)" ], [ 157, "S^2~S^1 (VT)" ], 
380
 [ 158, "(S^2xS^1)#(S^2xS^1) (VT)" ], [ 159, "S^2xS^1 (VT)" ], 
381
 [ 160, "S^2xS^1 (VT)" ], [ 161, "(S^2xS^1)#(S^2xS^1) (VT)" ] ]
382
 gap> c:=SCLib.Load(last[1][1]);;
383
 gap> for i in [1..Size(c)] do Print(c.F[i],"\n"); od;
384
 12
385
 66
386
 108
387
 54
388
 
389

390
391
5.3-5 Length (SCSimplicialComplex)
392
393
Length (SCSimplicialComplex)( complex )  method
394
Returns: an integer upon success, fail otherwise.
395
396
Returns the ``size'' of a simplicial complex by calling Size(complex).
397
398
 Example 
399
 gap> SCLib.SearchByAttribute("F=[12,66,108,54]");
400
 [ [ 139, "L_3_1" ], [ 140, "S^2~S^1 (VT)" ], 
401
 [ 141, "(S^2xS^1)#(S^2xS^1) (VT)" ], [ 142, "S^2xS^1 (VT)" ], 
402
 [ 143, "S^2xS^1 (VT)" ], [ 144, "S^2xS^1 (VT)" ], [ 145, "S^2xS^1 (VT)" ], 
403
 [ 146, "S^2~S^1 (VT)" ], [ 147, "S^2~S^1 (VT)" ], [ 148, "S^2~S^1 (VT)" ], 
404
 [ 149, "S^2~S^1 (VT)" ], [ 150, "S^2~S^1 (VT)" ], 
405
 [ 151, "(S^2xS^1)#(S^2xS^1) (VT)" ], [ 152, "S^2xS^1 (VT)" ], 
406
 [ 153, "(S^2xS^1)#(S^2xS^1) (VT)" ], [ 154, "S^2xS^1 (VT)" ], 
407
 [ 155, "S^2xS^1 (VT)" ], [ 156, "S^2~S^1 (VT)" ], [ 157, "S^2~S^1 (VT)" ], 
408
 [ 158, "(S^2xS^1)#(S^2xS^1) (VT)" ], [ 159, "S^2xS^1 (VT)" ], 
409
 [ 160, "S^2xS^1 (VT)" ], [ 161, "(S^2xS^1)#(S^2xS^1) (VT)" ] ]
410
 gap> c:=SCLib.Load(last[1][1]);;
411
 gap> for i in [1..Length(c)] do Print(c.F[i],"\n"); od;
412
 12
413
 66
414
 108
415
 54
416
 
417

418
419
5.3-6 Operation [] (SCSimplicialComplex)
420
421
Operation [] (SCSimplicialComplex)( complex, pos )  method
422
Returns: a list of faces upon success, fail otherwise.
423
424
Returns the (pos-1)-dimensional faces of complex as a list. If pos ≥ d+2,
425
where d is the dimension of complex, the empty set is returned. Note that
426
pos must be ≥ 1.
427
428
 Example 
429
 gap> SCLib.SearchByName("K^2");
430
 [ [ 17, "K^2 (VT)" ], [ 571, "K^2 (VT)" ] ]
431
 gap> c:=SCLib.Load(last[1][1]);;
432
 gap> c[2];
433
 [ [ 1, 2 ], [ 1, 3 ], [ 1, 5 ], [ 1, 7 ], [ 1, 9 ], [ 1, 10 ], [ 2, 3 ], 
434
 [ 2, 4 ], [ 2, 6 ], [ 2, 8 ], [ 2, 10 ], [ 3, 4 ], [ 3, 5 ], [ 3, 7 ], 
435
 [ 3, 9 ], [ 4, 5 ], [ 4, 6 ], [ 4, 8 ], [ 4, 10 ], [ 5, 6 ], [ 5, 7 ], 
436
 [ 5, 9 ], [ 6, 7 ], [ 6, 8 ], [ 6, 10 ], [ 7, 8 ], [ 7, 9 ], [ 8, 9 ], 
437
 [ 8, 10 ], [ 9, 10 ] ]
438
 gap> c[4];
439
 [ ]
440
 
441

442
443
5.3-7 Iterator (SCSimplicialComplex)
444
445
Iterator (SCSimplicialComplex)( complex )  method
446
Returns: an iterator on the face lattice of complex upon success, fail
447
otherwise.
448
449
Provides an iterator object for the face lattice of a simplicial complex.
450
451
 Example 
452
 gap> c:=SCBdCrossPolytope(4);;
453
 gap> for faces in c do Print(Length(faces),"\n"); od;
454
 8
455
 24
456
 32
457
 16
458
 
459

460
461
462
5.4 The object type SCNormalSurface
463
464
The GAP object type SCNormalSurface is designed to describe slicings (level
465
sets of discrete Morse functions) of combinatorial 3-manifolds, i. e.
466
discrete normal surfaces. Internally SCNormalSurface is a subtype of
467
SCPolyhedralComplex and, thus, mostly behaves like a SCSimplicialComplex
468
object (see Section 5.1). For a very short introduction to normal surfaces
469
see 2.4, for a more thorough introduction to the field see [Spr11b]. For
470
some fundamental methods and functions for SCNormalSurface see below. For
471
more functions related to the SCNormalSurface object type see Chapter 7.
472
473
474
5.5 Overloaded operators of SCNormalSurface
475
476
As with the object type SCSimplicialComplex, simpcomp overloads some
477
standard operations for the object type SCNormalSurface. See a list of
478
overloaded operators below.
479
480
5.5-1 Operation + (SCNormalSurface, Integer)
481
482
Operation + (SCNormalSurface, Integer)( complex, value )  method
483
Returns: the discrete normal surface passed as argument upon success, fail
484
otherwise.
485
486
Positively shifts the vertex labels of complex (provided that all labels
487
satisfy the property IsAdditiveElement) by the amount specified in value.
488
489
 Example 
490
 gap> sl:=SCNSSlicing(SCBdSimplex(4),[[1],[2..5]]);;
491
 gap> sl.Facets; 
492
 [ [ [ 1, 2 ], [ 1, 3 ], [ 1, 4 ] ], [ [ 1, 2 ], [ 1, 3 ], [ 1, 5 ] ], 
493
 [ [ 1, 2 ], [ 1, 4 ], [ 1, 5 ] ], [ [ 1, 3 ], [ 1, 4 ], [ 1, 5 ] ] ]
494
 gap> sl:=sl + 2;; 
495
 gap> sl.Facets; 
496
 [ [ [ 3, 4 ], [ 3, 5 ], [ 3, 6 ] ], [ [ 3, 4 ], [ 3, 5 ], [ 3, 7 ] ], 
497
 [ [ 3, 4 ], [ 3, 6 ], [ 3, 7 ] ], [ [ 3, 5 ], [ 3, 6 ], [ 3, 7 ] ] ]
498
 
499

500
501
5.5-2 Operation - (SCNormalSurface, Integer)
502
503
Operation - (SCNormalSurface, Integer)( complex, value )  method
504
Returns: the discrete normal surface passed as argument upon success, fail
505
otherwise.
506
507
Negatively shifts the vertex labels of complex (provided that all labels
508
satisfy the property IsAdditiveElement) by the amount specified in value.
509
510
 Example 
511
 gap> sl:=SCNSSlicing(SCBdSimplex(4),[[1],[2..5]]);;
512
 gap> sl.Facets; 
513
 [ [ [ 1, 2 ], [ 1, 3 ], [ 1, 4 ] ], [ [ 1, 2 ], [ 1, 3 ], [ 1, 5 ] ], 
514
 [ [ 1, 2 ], [ 1, 4 ], [ 1, 5 ] ], [ [ 1, 3 ], [ 1, 4 ], [ 1, 5 ] ] ]
515
 gap> sl:=sl - 2;; 
516
 gap> sl.Facets; 
517
 [ [ [ -1, 0 ], [ -1, 1 ], [ -1, 2 ] ], [ [ -1, 0 ], [ -1, 1 ], [ -1, 3 ] ], 
518
 [ [ -1, 0 ], [ -1, 2 ], [ -1, 3 ] ], [ [ -1, 1 ], [ -1, 2 ], [ -1, 3 ] ] ]
519
 
520

521
522
5.5-3 Operation mod (SCNormalSurface, Integer)
523
524
Operation mod (SCNormalSurface, Integer)( complex, value )  method
525
Returns: the discrete normal surface passed as argument upon success, fail
526
otherwise.
527
528
Takes all vertex labels of complex modulo the value specified in value
529
(provided that all labels satisfy the property IsAdditiveElement). Warning:
530
this might result in different vertices being assigned the same label or
531
even invalid facet lists, so be careful.
532
533
 Example 
534
 gap> sl:=SCNSSlicing(SCBdSimplex(4),[[1],[2..5]]);; 
535
 gap> sl.Facets;
536
 [ [ [ 1, 2 ], [ 1, 3 ], [ 1, 4 ] ], [ [ 1, 2 ], [ 1, 3 ], [ 1, 5 ] ], 
537
 [ [ 1, 2 ], [ 1, 4 ], [ 1, 5 ] ], [ [ 1, 3 ], [ 1, 4 ], [ 1, 5 ] ] ]
538
 gap> sl:=sl mod 2;;
539
 gap> sl.Facets; 
540
 [ [ [ 1, 0 ], [ 1, 0 ], [ 1, 1 ] ], [ [ 1, 0 ], [ 1, 0 ], [ 1, 1 ] ], 
541
 [ [ 1, 0 ], [ 1, 1 ], [ 1, 1 ] ], [ [ 1, 0 ], [ 1, 1 ], [ 1, 1 ] ] ]
542
 
543

544
545
546
5.6 SCNormalSurface as a subtype of Set
547
548
Like objects of type SCSimplicialComplex, an object of type SCNormalSurface
549
behaves like a GAP Set type. The elements of the set are given by the facets
550
of the normal surface, grouped by their dimensionality and type, i.e. if
551
complex is an object of type SCNormalSurface, c[1] refers to the 0-faces of
552
complex, c[2] to the 1-faces, c[3] to the triangles and c[4] to the
553
quadrilaterals. See below for some examples and Section 5.3 for details.
554
555
5.6-1 Operation Union (SCNormalSurface, SCNormalSurface)
556
557
Operation Union (SCNormalSurface, SCNormalSurface)( complex1, complex2 )  method
558
Returns: discrete normal surface of type SCNormalSurface upon success, fail
559
otherwise.
560
561
Computes the union of two discrete normal surfaces by calling SCUnion
562
(7.3-16).
563
564
 Example 
565
 gap> SCLib.SearchByAttribute("F = [ 10, 35, 50, 25 ]");
566
 [ [ 19, "S^3 (VT)" ] ]
567
 gap> c:=SCLib.Load(last[1][1]);;
568
 gap> sl1:=SCNSSlicing(c,[[1,3,5,7,9],[2,4,6,8,10]]);;
569
 gap> sl2:=sl1+10;;
570
 gap> SCTopologicalType(sl1);
571
 "T^2"
572
 gap> sl3:=Union(sl1,sl2);;
573
 gap> SCTopologicalType(sl3);
574
 "T^2 U T^2"
575
 
576

577
578
579