  
  [1m[4m[31m3. The GAP object types SCSimplicicalComplex and SCNormalSurface[0m
  
  The  [1msimpcomp[0m  package  defines  a  new GAP object type [22m[32mSCSimplicialComplex[0m,
  which  is  used  to  store  simplicial  complexes and their properties. As a
  property  should  not  be  calculated  multiple times if the complex was not
  altered,   [1msimpcomp[0m   caches   all   calculated   properties   (the  ``known
  properties'')  of a simplicial complex within the [22m[32mSCSimplicialComplex[0m object
  such  that  each property is only calculated once (see [1m[34mSCForceRecalc[0m ([1m3.1-4[0m)
  for  a  way  of switching off this behaviour). Internally, this behaviour is
  accomplished  by making [22m[32mSCSimplicialComplex[0m a subtype of [22m[32mSCPropertyObject[0m, a
  GAP  object  type defined by [1msimpcomp[0m that provides the means to store (i.e.
  cache)   certain   properties   of   objects  and  also  provides  means  of
  (de)serializing these objects to and from a XML format (see section [1m8.[0m).
  
  
  [1m[4m[31m3.1 The object types [22m[32mSCSimplicialComplex[1m[4m[31m and [22m[32mSCPropertyObject[1m[4m[31m[0m
  
  The  object  type  [22m[32mSCPropertyObject[0m  provides  a  GAP  object  consisting of
  permanent  and  temporary  attributes.  While  the  permanent attributes are
  serialized  to  and from XML (and thus are persistent), this is not the case
  for  temporary  attributes.  The  permanent  and  temporary  properties of a
  [22m[32mSCPropertyObject[0m    can    be   accessed   directly   with   the   functions
  [22m[32mSCPropertyByName[0m,   [22m[32mSCPropertyTmpByName[0m   and  changed  with  [22m[32mSCPropertySet[0m,
  [22m[32mSCPropertyTmpSet[0m.  But this direct access to property objects is discouraged
  when  working  with  [1msimpcomp[0m,  as  the  internal consistency of the objects
  cannot  be  guaranteed  when the properties of the objects are accessed (and
  modified)  in  this way. Instead, the access to the object properties via so
  called   property   handlers  is  strongly  recommended  (and  actually  the
  [22m[32mSCProperty...[0m-functions  are only meant for internal use). For each property
  that  an object of type [22m[32mSCPropertyObject[0m can have, a function referred to as
  property  handler  ensures the integrity of the property and handles caching
  of  this  property. See section [1m3.2[0m below for a description of how to access
  properties  of  a  [22m[32mSCSimplicialComplex[0m  object.  Note  that  all  properties
  returned  by  such  property  handlers  are  immutable  objects. You can use
  [22m[32mShallowCopy[0m  to  obtain  mutable  copies.  For  a  list  of  properties that
  [22m[32mSCSimplicialComplex[0m  handles,  see chapter [1m4.[0m. For a few fundamental methods
  and  functions  (such  as checking the object class, copying objects of this
  type, etc.) for [22m[32mSCSimplcicialComplex[0m see below.
  
  [1m[4m[31m3.1-1 SCIsSimplicialComplex[0m
  
  [1m[34m> SCIsSimplicialComplex( [0m[22m[34mobject[0m[1m[34m ) ____________________________________[0mfilter
  [1mReturns:[0m  [22m[32mtrue[0m, if [22m[34mobject[0m is of type [22m[32mSCSimplicialComplex[0m, [22m[32mfalse[0m otherwise.
  
  Filter  for  the  category  of a simplicial complex [22m[32mSCSimplicialComplex[0m. The
  category [22m[32mSCSimplicialComplex[0m is derived from the category [22m[32mSCPropertyObject[0m.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> c:=SCEmpty();;[0m
    [22m[35m gap> SCIsSimplicialComplex(c);[0m
    [22m[35m true[0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.1-2 SCCopy[0m
  
  [1m[34m> SCCopy( [0m[22m[34mcomplex[0m[1m[34m ) _______________________________________________[0moperation
  [1mReturns:[0m  a copy of [22m[34mcomplex[0m upon success, [22m[32mfail[0m otherwise.
  
  Makes  a ``deep copy'' of [22m[34mcomplex[0m -- this is a copy such that all properties
  of the copy can be altered without changing the original complex.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> c:=SCBdSimplex(4);;[0m
    [22m[35m gap> d:=SCCopy(c)-1;;[0m
    [22m[35m gap> c.Facets=d.Facets;[0m
    [22m[35m false[0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> c:=SCBdSimplex(4);;[0m
    [22m[35m gap> d:=SCCopy(c);;[0m
    [22m[35m gap> IsIdenticalObj(c,d);[0m
    [22m[35m false[0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.1-3 ShallowCopy (SCSimplicialComplex)[0m
  
  [1m[34m> ShallowCopy (SCSimplicialComplex)( [0m[22m[34mcomplex[0m[1m[34m ) ____________________[0moperation
  [1mReturns:[0m  a copy of [22m[34mcomplex[0m upon success, [22m[32mfail[0m otherwise.
  
  Makes  a  copy  of  [22m[34mcomplex[0m.  This is actually a ``deep copy'' such that all
  properties of the copy can be altered without changing the original complex.
  Internally calls [1m[34mSCCopy[0m ([1m3.1-2[0m).
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> c:=SCLib.Load(87);;[0m
    [22m[35m gap> d:=ShallowCopy(c)+10;;[0m
    [22m[35m gap> c.Facets=d.Facets;[0m
    [22m[35m false[0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.1-4 SCForceRecalc[0m
  
  [1m[34m> SCForceRecalc( [0m[22m[34mcomplex, flag[0m[1m[34m ) ___________________________________[0mfunction
  [1mReturns:[0m  [22m[34mtrue[0m upon success, [22m[32mfail[0m otherwise.
  
  An  object  of  the  type [22m[32mSCSimplicialComplex[0m normally caches its previously
  calculated  properties  such  that  each  property only has to be calculated
  once. With this function this behaviour can be changed, if [22m[34mflag[0m equals [22m[32mtrue[0m,
  caching is turned off, for [22m[34mflag[0m equals [22m[32mfalse[0m, caching is turned on.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> c:=SCFromFacets(Combinations([1..16],15));;[0m
    [22m[35m gap> c.F;; time;[0m
    [22m[35m 2000[0m
    [22m[35m gap> c.F;; time;[0m
    [22m[35m 0[0m
    [22m[35m gap> SCForceRecalc(c,true);[0m
    [22m[35m true[0m
    [22m[35m gap> c.F;; time;[0m
    [22m[35m 2036[0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  
  [1m[4m[31m3.2 Accessing properties of a [22m[32mSCSimplicialComplex[1m[4m[31m object[0m
  
  As  described  in  section  [1m3.1[0m  the  object  type  [22m[32mSCSimplicialComplex[0m  has
  properties  that  are handled by so called property handlers. These handlers
  take care of the internal consistency of objects of type [22m[32mSCSimplicialComplex[0m
  and (re)compute necessary object attributes if necessary. There are two ways
  of  accessing  properties  of  a [22m[32mSCSimplicialComplex[0m object. The first is to
  call  a  property  handler  function of the property one wishes to calculate
  directly.  The  first argument of such a property handler function is always
  the  simplicial  complex  for  which  the  property  should  be  calculated,
  optionally  followed  by further arguments of the property handler function.
  An example would be:
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35mgap> c:=SCBdSimplex(3);; # create a simplicial complex object[0m
    [22m[35mgap> SCFVector(c);[0m
    [22m[35m[ 4, 6, 4 ][0m
    [22m[35mgap> SCSkel(c,0);[0m
    [22m[35m[ [ 1 ], [ 2 ], [ 3 ], [ 4 ] ][0m
  [22m[35m------------------------------------------------------------------[0m
  
  Here  the functions [22m[32mSCFVector[0m and [22m[32mSCSkel[0m are the property handler functions,
  see chapter [1m10.[0m for a list of all property handlers of a [22m[32mSCSimplicialComplex[0m
  object.  Apart  from this (standard) method of calling the property handlers
  directly  with a [22m[32mSCSimplicialComplex[0m object, [1msimpcomp[0m provides the user with
  another  more  object  oriented  method  of  calling  property handlers of a
  [22m[32mSCSimplicialComplex[0m object inderectly and more conveniently:
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35mgap> c:=SCBdSimplex(3);; # create a simplicial complex object[0m
    [22m[35mgap> c.F;[0m
    [22m[35m[ 4, 6, 4 ][0m
    [22m[35mgap> c.Skel(0);[0m
    [22m[35m[ [ 1 ], [ 2 ], [ 3 ], [ 4 ] ][0m
  [22m[35m------------------------------------------------------------------[0m
  
  Note  that the code in this example calculates the same properties as in the
  first  example above, but the properties of a [22m[32mSCSimplicialComplex[0m object are
  accessed  via  the  [22m[32m.[0m  operator  (the  record access operator). As GAP lacks
  object  orientation,  this behaviour is internally accomplished via a helper
  function  (that calls the property handlers), such that accessing properties
  in  this  (indirect)  way  is  a tiny bit slower than with the direct method
  described  above. But this tiny drawback in speed is traded for a great deal
  of  less  and  easier  things  that  have to be typed (also note that [22m[32mc.F[0m is
  accessed  like  a list, although internally the property handler function is
  called).  If  one is interested in utmost efficiency one must either use the
  direct calling method of property handlers or use a software package that is
  optimized  for  performance,  such  as  polymake  [GJ00].  For each property
  handler  of  a  [22m[32mSCSimplicialComplex[0m object the short object oriented form of
  this  property  handler  is given in the description of the property handler
  function.  In  most cases it is just formed by dropping the prefix ``[22m[32mSC[0m'' of
  the property handler functions.
  
  
  [1m[4m[31m3.3 Overloaded operators of [22m[32mSCSimplicialComplex[1m[4m[31m[0m
  
  [1msimpcomp[0m   overloads   some   standard   operations   for  the  object  type
  [22m[32mSCSimplcicialComplex[0m  if  this  definition  is  intuitive and mathematically
  sound. See a list of overloaded operators below.
  
  [1m[4m[31m3.3-1 Operation + (SCSimplicialComplex, Integer)[0m
  
  [1m[34m> Operation + (SCSimplicialComplex, Integer)( [0m[22m[34mcomplex, value[0m[1m[34m ) ____[0moperation
  [1mReturns:[0m  the  simplicial  complex  passed  as  argument  upon success, [22m[32mfail[0m
            otherwise.
  
  Positively  shifts  the  vertex labels of [22m[34mcomplex[0m by the amount specified in
  [22m[34mvalue[0m.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> c:=SCBdSimplex(3)+10;;[0m
    [22m[35m gap> c.Facets;[0m
    [22m[35m [[11, 12, 13], [11, 12, 14], [11, 13, 14], [12, 13, 14]][0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.3-2 Operation - (SCSimplicialComplex, Integer)[0m
  
  [1m[34m> Operation - (SCSimplicialComplex, Integer)( [0m[22m[34mcomplex, value[0m[1m[34m ) ____[0moperation
  [1mReturns:[0m  the  simplicial  complex  passed  as  argument unpon success, [22m[32mfail[0m
            otherwise.
  
  Negatively  shifts  the  vertex labels of [22m[34mcomplex[0m by the amount specified in
  [22m[34mvalue[0m.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> c:=SCBdSimplex(3)-1;;[0m
    [22m[35m gap> c.Facets;[0m
    [22m[35m [[0, 1, 2], [0, 1, 3], [0, 2, 3], [1, 2, 3]][0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.3-3 Operation mod (SCSimplicialComplex, Integer)[0m
  
  [1m[34m> Operation mod (SCSimplicialComplex, Integer)( [0m[22m[34mcomplex, value[0m[1m[34m ) __[0moperation
  [1mReturns:[0m  the  simplicial  complex  passed  as  argument unpon success, [22m[32mfail[0m
            otherwise.
  
  Takes  all  vertex  labels  of  [22m[34mcomplex[0m modulo the value specified in [22m[34mvalue[0m.
  Warning:  this  might  result  in different vertices being assigned the same
  label, so be careful.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> c:=(SCBdSimplex(3)*10) mod 7;;[0m
    [22m[35m gap> c.Facets;[0m
    [22m[35m [[3, 6, 2], [3, 6, 5], [3, 2, 5], [6, 2, 5]][0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.3-4 Operation ^ (SCSimplicialComplex, Integer)[0m
  
  [1m[34m> Operation ^ (SCSimplicialComplex, Integer)( [0m[22m[34mcomplex, value[0m[1m[34m ) ____[0moperation
  [1mReturns:[0m  a new simplicial complex upon success, [22m[32mfail[0m otherwise.
  
  Forms the [22m[34mvalue[0m-th cartesian power of [22m[34mcomplex[0m, i.e. the [22m[34mvalue[0m-fold cartesian
  product of copies of [22m[34mcomplex[0m. The complex passed as argument is not altered.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> c:=SCBdSimplex(2)^2; #a torus[0m
    [22m[35m [SimplicialComplex[0m
    [22m[35m [0m
    [22m[35m  Properties known: Dim, Facets, Name, TopologicalType, VertexLabels.[0m
    [22m[35m [0m
    [22m[35m  Name="(S^1_3)^2"[0m
    [22m[35m  Dim=2[0m
    [22m[35m  TopologicalType="(S^1)^2"[0m
    [22m[35m [0m
    [22m[35m /SimplicialComplex][0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.3-5 Operation + (SCSimplicialComplex, SCSimplicialComplex)[0m
  
  [1m[34m> Operation + (SCSimplicialComplex, SCSimplicialComplex)( [0m[22m[34mcomplex1, complex2[0m[1m[34m ) [0moperation
  [1mReturns:[0m  a new simplicial complex upon success, [22m[32mfail[0m otherwise.
  
  Forms  the  connected  sum  of  [22m[34mcomplex1[0m  and  [22m[34mcomplex2[0m.  Currently uses the
  lexicographically  first  facets  of  both  complex  to  do  the gluing. The
  complexes passed as arguments are not altered.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> SCLib.SearchByName("RP^3");[0m
    [22m[35m [ [ 45, "RP^3" ], [ 103, "RP^3=L(2,1) (VT)" ], [ 246, "(S^2~S^1)#RP^3" ], [0m
    [22m[35m   [ 247, "(S^2xS^1)#RP^3" ], [ 283, "(S^2~S^1)#2#RP^3" ], [0m
    [22m[35m   [ 285, "(S^2xS^1)#2#RP^3" ], [ 409, "RP^3#RP^3" ], ...[0m
    [22m[35m gap> SCLib.SearchByName("S^2~S^1");[0m
    [22m[35m [ [ 14, "S^2~S^1 (VT)" ], [ 29, "S^2~S^1 (VT)" ], [ 34, "S^2~S^1 (VT)" ], [0m
    [22m[35m   [ 42, "S^2~S^1 (VT)" ], [ 48, "S^2~S^1 (VT)" ], [ 49, "S^2~S^1 (VT)" ], [0m
    [22m[35m   [ 84, "S^2~S^1 (VT)" ], [ 87, "S^2~S^1 (VT)" ], ...[0m
    [22m[35m gap> c:=SCLib.Load(45)+SCLib.Load(14); #form RP^3#(S^2~S^1)[0m
    [22m[35m [SimplicialComplex[0m
    [22m[35m [0m
    [22m[35m  Properties known: Dim, Facets, Name, VertexLabels, Vertices.[0m
    [22m[35m [0m
    [22m[35m  Name="RP^3#+-S^2~S^1 (VT)"[0m
    [22m[35m  Dim=3[0m
    [22m[35m [0m
    [22m[35m /SimplicialComplex][0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.3-6 Operation - (SCSimplicialComplex, SCSimplicialComplex)[0m
  
  [1m[34m> Operation - (SCSimplicialComplex, SCSimplicialComplex)( [0m[22m[34mcomplex1, complex2[0m[1m[34m ) [0moperation
  [1mReturns:[0m  a new simplicial complex upon success, [22m[32mfail[0m otherwise.
  
  Calls [1m[34mSCDifference[0m ([1m4.6-5[0m)([22m[34mcomplex1[0m, [22m[34mcomplex2[0m)
  
  [1m[4m[31m3.3-7 Operation * (SCSimplicialComplex, SCSimplicialComplex)[0m
  
  [1m[34m> Operation * (SCSimplicialComplex, SCSimplicialComplex)( [0m[22m[34mcomplex1, complex2[0m[1m[34m ) [0moperation
  [1mReturns:[0m  a new simplicial complex upon success, [22m[32mfail[0m otherwise.
  
  Forms the cartesian product of [22m[34mcomplex1[0m and [22m[34mcomplex2[0m.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> SCLib.SearchByName("RP^2");[0m
    [22m[35m [ [ 3, "RP^2 (VT)" ], [ 284, "RP^2xS^1" ] ][0m
    [22m[35m gap> c:=SCLib.Load(3)*SCBdSimplex(3); #form RP^2 x S^2[0m
    [22m[35m [SimplicialComplex[0m
    [22m[35m [0m
    [22m[35m  Properties known: Dim, Facets, Name, VertexLabels.[0m
    [22m[35m [0m
    [22m[35m  Name="RP^2 (VT)xS^2_4"[0m
    [22m[35m  Dim=4[0m
    [22m[35m [0m
    [22m[35m /SimplicialComplex][0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.3-8 Operation = (SCSimplicialComplex, SCSimplicialComplex)[0m
  
  [1m[34m> Operation = (SCSimplicialComplex, SCSimplicialComplex)( [0m[22m[34mcomplex1, complex2[0m[1m[34m ) [0moperation
  [1mReturns:[0m  [22m[32mtrue[0m or [22m[32mfalse[0m upon success, [22m[32mfail[0m otherwise.
  
  Calculates whether two simplicial complexes are equal, i.e. have equal facet
  sets  in  standard  labeling.  Returns  [22m[32mtrue[0m  if  the facet sets in standard
  labeling  are equal as sets, [22m[32mfalse[0m otherwise. Note: this check only compares
  the facet lists in standard labeling.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> c:=SCBdSimplex(3);;[0m
    [22m[35m gap> c=c+10;[0m
    [22m[35m true[0m
    [22m[35m gap> c=SCBdCrossPolytope(4);[0m
    [22m[35m false[0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.3-9 Operation Union (SCSimplicialComplex, SCSimplicialComplex)[0m
  
  [1m[34m> Operation Union (SCSimplicialComplex, SCSimplicialComplex)( [0m[22m[34mcomplex1, complex2[0m[1m[34m ) [0moperation
  [1mReturns:[0m  a new simplicial complex upon success, [22m[32mfail[0m otherwise.
  
  Computes the union of two simplicial complexes by calling [1m[34mSCUnion[0m ([1m4.6-24[0m).
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> c:=Union(SCBdSimplex(3),SCBdSimplex(3)+3); #a wedge of two 2-spheres[0m
    [22m[35m [SimplicialComplex[0m
    [22m[35m [0m
    [22m[35m  Properties known: Dim, Facets, Name, VertexLabels.[0m
    [22m[35m [0m
    [22m[35m  Name="S^2_4 cup S^2_4"[0m
    [22m[35m  Dim=2[0m
    [22m[35m [0m
    [22m[35m /SimplicialComplex][0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.3-10 Operation Difference (SCSimplicialComplex, SCSimplicialComplex)[0m
  
  [1m[34m> Operation Difference (SCSimplicialComplex, SCSimplicialComplex)( [0m[22m[34mcomplex1, complex2[0m[1m[34m ) [0moperation
  [1mReturns:[0m  a new simplicial complex upon success, [22m[32mfail[0m otherwise.
  
  Computes   the   ``difference''  of  two  simplicial  complexes  by  calling
  [1m[34mSCDifference[0m ([1m4.6-5[0m).
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> c:=SCBdSimplex(3);;[0m
    [22m[35m gap> d:=SC([[1,2,3]]);;[0m
    [22m[35m gap> disc:=Difference(c,d);;[0m
    [22m[35m gap> disc.Facets;[0m
    [22m[35m [ [ 1, 2, 4 ], [ 1, 3, 4 ], [ 2, 3, 4 ] ][0m
    [22m[35m gap> empty:=Difference(d,c);;[0m
    [22m[35m gap> empty.Dim;[0m
    [22m[35m -1[0m
    [22m[35m gap> [0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.3-11 Operation Intersection (SCSimplicialComplex, SCSimplicialComplex)[0m
  
  [1m[34m> Operation Intersection (SCSimplicialComplex, SCSimplicialComplex)( [0m[22m[34mcomplex1, complex2[0m[1m[34m ) [0moperation
  [1mReturns:[0m  a new simplicial complex upon success, [22m[32mfail[0m otherwise.
  
  Computes  the  ``intersection''  of  two  simplicial  complexes  by  calling
  [1m[34mSCIntersection[0m ([1m4.6-7[0m).
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> c:=SCBdSimplex(3);;        [0m
    [22m[35m gap> d:=SCBdSimplex(3);;        [0m
    [22m[35m gap> d:=SCMove(d,[[1,2,3],[]]);;[0m
    [22m[35m gap> d:=d+1;;                   [0m
    [22m[35m gap> s1:=SCIntersection(c,d);   [0m
    [22m[35m [SimplicialComplex[0m
    [22m[35m [0m
    [22m[35m  Properties known: Dim, Facets, Name, VertexLabels.[0m
    [22m[35m [0m
    [22m[35m  Name="S^2_4 cap unnamed complex n"[0m
    [22m[35m  Dim=1[0m
    [22m[35m [0m
    [22m[35m /SimplicialComplex][0m
    [22m[35m gap> s1.Facets;                 [0m
    [22m[35m [ [ 2, 3 ], [ 2, 4 ], [ 3, 4 ] ][0m
    [22m[35m gap> [0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  
  [1m[4m[31m3.4 [22m[32mSCSimplicialComplex[1m[4m[31m as a subtype of [22m[32mSet[1m[4m[31m[0m
  
  Apart   from  being  a  subtype  of  [22m[32mSCPropertyObject[0m,  an  object  of  type
  [22m[32mSCSimplicialComplex[0m  also  behaves  like a GAP [22m[32mSet[0m type. The elements of the
  set  are  given  by  the  facets  of the simplical complex, grouped by their
  dimensionality,  i.e.  if  [22m[32mcomplex[0m is an object of type [22m[32mSCSimplicialComplex[0m,
  [22m[32mc[1][0m refers to the 0-faces of [22m[32mcomplex[0m, [22m[32mc[2][0m to the 1-faces, etc.
  
  [1m[4m[31m3.4-1 Size (SCSimplicialComplex)[0m
  
  [1m[34m> Size (SCSimplicialComplex)( [0m[22m[34mcomplex[0m[1m[34m ) ___________________________[0moperation
  [1mReturns:[0m  an integer upon success, [22m[32mfail[0m otherwise.
  
  Returns  the  ``size''  of a simplicial complex. This is d+1, where d is the
  dimension  of the complex. d+1 is returned instead of d, as all lists in GAP
  are  indexed  beginning  with  1  --  thus  this also holds for all the face
  lattice related properties of the complex.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> SCLib.SearchByAttribute("F=·[12,66,108,54]");[0m
    [22m[35m [ [ 116, "S^2xS^1 (VT)" ], [ 117, "S^2xS^1 (VT)" ], [0m
    [22m[35m   [ 118, "(S^2xS^1)#(S^2xS^1) (VT)" ], [ 119, "S^2~S^1 (VT)" ], [0m
    [22m[35m   [ 120, "(S^2xS^1)#(S^2xS^1) (VT)" ], [ 121, "(S^2xS^1)#(S^2xS^1) (VT)" ], [0m
    [22m[35m   [ 122, "S^2xS^1 (VT)" ], [ 123, "(S^2xS^1)#(S^2xS^1) (VT)" ], ...[0m
    [22m[35m gap> c:=SCLib.Load(116);;[0m
    [22m[35m gap> for i in [1..Size(c)] do Print(c.F[i],"\n"); od;[0m
    [22m[35m 12[0m
    [22m[35m 66[0m
    [22m[35m 108[0m
    [22m[35m 54[0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.4-2 Length (SCSimplicialComplex)[0m
  
  [1m[34m> Length (SCSimplicialComplex)( [0m[22m[34mcomplex[0m[1m[34m ) _________________________[0moperation
  [1mReturns:[0m  an integer upon success, [22m[32mfail[0m otherwise.
  
  Returns the ``size'' of a simplicial complex by calling [22m[32mSize([0m[22m[34mcomplex[0m[22m[32m)[0m.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> SCLib.SearchByAttribute("F=¸[12,66,108,54]");[0m
    [22m[35m [ [ 116, "Sˆ2xSˆ1 (VT)" ], [ 117, "Sˆ2xSˆ1 (VT)" ],[0m
    [22m[35m [ 118, "(Sˆ2xSˆ1)#(Sˆ2xSˆ1) (VT)" ], [ 119, "Sˆ2˜Sˆ1 (VT)" ],[0m
    [22m[35m [ 120, "(Sˆ2xSˆ1)#(Sˆ2xSˆ1) (VT)" ], [ 121, "(Sˆ2xSˆ1)#(Sˆ2xSˆ1) (VT)" ],[0m
    [22m[35m [ 122, "Sˆ2xSˆ1 (VT)" ], [ 123, "(Sˆ2xSˆ1)#(Sˆ2xSˆ1) (VT)" ], ...[0m
    [22m[35m gap> c:=SCLib.Load(116);;[0m
    [22m[35m gap> for i in [1..Length(c)] do Print(c.F[i],"\n"); od;[0m
    [22m[35m 12[0m
    [22m[35m 66[0m
    [22m[35m 108[0m
    [22m[35m 54[0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.4-3 Operation [] (SCSimplicialComplex)[0m
  
  [1m[34m> Operation [] (SCSimplicialComplex)( [0m[22m[34mcomplex, pos[0m[1m[34m ) ______________[0moperation
  [1mReturns:[0m  a list of faces upon success, [22m[32mfail[0m otherwise.
  
  Returns the (pos-1)-dimensional faces of [22m[34mcomplex[0m as list. If pos <= 0 or pos
  >= d+2, where d is the dimension of [22m[34mcomplex[0m, the empty set is returned.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> SCLib.SearchByName("K^2");[0m
    [22m[35m [ [ 19, "K^2 (VT)" ], [ 230, "K^2 (VT)" ] ][0m
    [22m[35m gap> c:=SCLib.Load(230);;[0m
    [22m[35m gap> c[2];[0m
    [22m[35m [ [ 1, 2 ], [ 1, 3 ], [ 1, 7 ], [ 1, 9 ], [ 1, 13 ], [ 1, 14 ], [ 2, 3 ], [0m
    [22m[35m   [ 2, 4 ], [ 2, 8 ], [ 2, 10 ], [ 2, 14 ], [ 3, 4 ], [ 3, 5 ], [ 3, 9 ], [0m
    [22m[35m   [ 3, 11 ], [ 4, 5 ], [ 4, 6 ], [ 4, 10 ], [ 4, 12 ], [ 5, 6 ], [ 5, 7 ], [0m
    [22m[35m   [ 5, 11 ], [ 5, 13 ], [ 6, 7 ], [ 6, 8 ], [ 6, 12 ], [ 6, 14 ], [ 7, 8 ], [0m
    [22m[35m   [ 7, 9 ], [ 7, 13 ], [ 8, 9 ], [ 8, 10 ], [ 8, 14 ], [ 9, 10 ], [ 9, 11 ], [0m
    [22m[35m   [ 10, 11 ], [ 10, 12 ], [ 11, 12 ], [ 11, 13 ], [ 12, 13 ], [ 12, 14 ], [0m
    [22m[35m   [ 13, 14 ] ][0m
    [22m[35m gap> c[4];[0m
    [22m[35m [  ][0m
    [22m[35m gap> [0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.4-4 IsBound (SCSimplicialComplex)[0m
  
  [1m[34m> IsBound (SCSimplicialComplex)( [0m[22m[34mcomplex, pos[0m[1m[34m ) ___________________[0moperation
  [1mReturns:[0m  [22m[32mtrue[0m or [22m[32mfalse[0m upon success, [22m[32mfail[0m otherwise.
  
  Returns  [22m[32mtrue[0m  when  [22m[34mcomplex[0m  has  proper  faces of dimension (pos-1), [22m[32mfalse[0m
  otherwise.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> c:=SCBdCrossPolytope(4);;[0m
    [22m[35m gap> IsBound(c[4]);[0m
    [22m[35m true[0m
    [22m[35m gap> IsBound(c[5]);[0m
    [22m[35m false[0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.4-5 Iterator (SCSimplicialComplex)[0m
  
  [1m[34m> Iterator (SCSimplicialComplex)( [0m[22m[34mcomplex[0m[1m[34m ) _______________________[0moperation
  [1mReturns:[0m  an  iterator  on  the  face  lattice of [22m[34mcomplex[0m upon success, [22m[32mfail[0m
            otherwise.
  
  Provides an iterator object for the face lattice of a simplicial complex.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> c:=SCBdCrossPolytope(4);;[0m
    [22m[35m gap> for faces in c do Print(Length(faces),"\n"); od;[0m
    [22m[35m 8[0m
    [22m[35m 24[0m
    [22m[35m 32[0m
    [22m[35m 16[0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  
  [1m[4m[31m3.5 The object types [22m[32mSCNormalSurface[1m[4m[31m as asubtyope of [22m[32mSCPropertyObject[1m[4m[31m[0m
  
  The  [1msimpcomp[0m  package defines a GAP object type [22m[32mSCNormalSurface[0m to describe
  normal  surfaces  /  slicings  (level  sets  of discrete Morse functions) in
  combinatorial  3-manifolds.  Internally  [22m[32mSCNormalSurface[0m  is  a  subtype  of
  [22m[32mSCPropertyObject[0m and, thus, mostly behaves like a [22m[32mSCSimplicialComplex[0m object
  (see section [1m3.1[0m). For a very short introduction to normal surfaces see [1m2.4[0m,
  for some fundamental methods and functions for [22m[32mSCNormalSurface[0m see below.
  
  
  [1m[4m[31m3.6 Overloaded operators of [22m[32mSCNormalSurface[1m[4m[31m[0m
  
  As  with  the  object  type  [22m[32mSCSimplcicialComplex[0m,  [1msimpcomp[0m  overloads some
  standard  operations  for  the  object  type  [22m[32mSCNormalSurface[0m. See a list of
  overloaded operators below.
  
  [1m[4m[31m3.6-1 Operation + (SCNormalSurface, Integer)[0m
  
  [1m[34m> Operation + (SCNormalSurface, Integer)( [0m[22m[34mcomplex, value[0m[1m[34m ) ________[0moperation
  [1mReturns:[0m  the   normal   surface  passed  as  argument  upon  success,  [22m[32mfail[0m
            otherwise.
  
  Positively  shifts  the  vertex labels of [22m[34mcomplex[0m by the amount specified in
  [22m[34mvalue[0m.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> ns:=SCNSSlicing(SCBdSimplex(4),[[1],[2..5]]);;[0m
    [22m[35m gap> ns.Facets;                                    [0m
    [22m[35m [ [ [ 1, 2 ], [ 1, 3 ], [ 1, 4 ] ], [ [ 1, 2 ], [ 1, 3 ], [ 1, 5 ] ], [0m
    [22m[35m   [ [ 1, 2 ], [ 1, 4 ], [ 1, 5 ] ], [ [ 1, 3 ], [ 1, 4 ], [ 1, 5 ] ] ][0m
    [22m[35m gap> ns:=ns + 2;;                                  [0m
    [22m[35m gap> ns.Facets;  [0m
    [22m[35m [ [ [ 3, 4 ], [ 3, 5 ], [ 3, 6 ] ], [ [ 3, 4 ], [ 3, 5 ], [ 3, 7 ] ], [0m
    [22m[35m   [ [ 3, 4 ], [ 3, 6 ], [ 3, 7 ] ], [ [ 3, 5 ], [ 3, 6 ], [ 3, 7 ] ] ][0m
    [22m[35m gap> [0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.6-2 Operation - (SCNormalSurface, Integer)[0m
  
  [1m[34m> Operation - (SCNormalSurface, Integer)( [0m[22m[34mcomplex, value[0m[1m[34m ) ________[0moperation
  [1mReturns:[0m  the   normal  surface  passed  as  argument  unpon  success,  [22m[32mfail[0m
            otherwise.
  
  Negatively  shifts  the  vertex labels of [22m[34mcomplex[0m by the amount specified in
  [22m[34mvalue[0m.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> ns:=SCNSSlicing(SCBdSimplex(4),[[1],[2..5]]);;[0m
    [22m[35m gap> ns.Facets;                                    [0m
    [22m[35m [ [ [ 1, 2 ], [ 1, 3 ], [ 1, 4 ] ], [ [ 1, 2 ], [ 1, 3 ], [ 1, 5 ] ], [0m
    [22m[35m   [ [ 1, 2 ], [ 1, 4 ], [ 1, 5 ] ], [ [ 1, 3 ], [ 1, 4 ], [ 1, 5 ] ] ][0m
    [22m[35m gap> ns:=ns - 2;;                                  [0m
    [22m[35m gap> ns.Facets;  [0m
    [22m[35m [ [ [ -1, 0 ], [ -1, 1 ], [ -1, 2 ] ], [ [ -1, 0 ], [ -1, 1 ], [ -1, 3 ] ], [0m
    [22m[35m   [ [ -1, 0 ], [ -1, 2 ], [ -1, 3 ] ], [ [ -1, 1 ], [ -1, 2 ], [ -1, 3 ] ] ][0m
    [22m[35m gap> [0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.6-3 Operation mod (SCNormalSurface, Integer)[0m
  
  [1m[34m> Operation mod (SCNormalSurface, Integer)( [0m[22m[34mcomplex, value[0m[1m[34m ) ______[0moperation
  [1mReturns:[0m  the   normal  surface  passed  as  argument  unpon  success,  [22m[32mfail[0m
            otherwise.
  
  Takes  all  vertex  labels  of  [22m[34mcomplex[0m modulo the value specified in [22m[34mvalue[0m.
  Warning:  this  might  result  in different vertices being assigned the same
  label, so be careful.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> ns:=SCNSSlicing(SCBdSimplex(4),[[1],[2..5]]);;    [0m
    [22m[35m gap> ns.Facets;[0m
    [22m[35m [ [ [ 1, 2 ], [ 1, 3 ], [ 1, 4 ] ], [ [ 1, 2 ], [ 1, 3 ], [ 1, 5 ] ], [0m
    [22m[35m   [ [ 1, 2 ], [ 1, 4 ], [ 1, 5 ] ], [ [ 1, 3 ], [ 1, 4 ], [ 1, 5 ] ] ][0m
    [22m[35m gap> ns:=ns mod 2;;[0m
    [22m[35m gap> ns.Facets;    [0m
    [22m[35m [ [ [ 1, 0 ], [ 1, 1 ], [ 1, 0 ] ], [ [ 1, 0 ], [ 1, 1 ], [ 1, 1 ] ], [0m
    [22m[35m   [ [ 1, 0 ], [ 1, 0 ], [ 1, 1 ] ], [ [ 1, 1 ], [ 1, 0 ], [ 1, 1 ] ] ][0m
    [22m[35m gap> [0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.6-4 Operation = (SCNormalSurface, SCNormalSurface)[0m
  
  [1m[34m> Operation = (SCNormalSurface, SCNormalSurface)( [0m[22m[34mcomplex1, complex2[0m[1m[34m ) [0moperation
  [1mReturns:[0m  [22m[32mtrue[0m or [22m[32mfalse[0m upon success, [22m[32mfail[0m otherwise.
  
  Calculates  whether two normal surface are equal, i.e. have equal facet sets
  in  standard  labeling.  Returns [22m[32mtrue[0m if the facet sets in standard labeling
  are equal as sets, [22m[32mfalse[0m otherwise. Note: this check only compares the facet
  lists in standard labeling.
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> ns:=SCNSSlicing(SCBdSimplex(4),[[1],[2..5]]);;[0m
    [22m[35m gap> ns1:=SCNSSlicing(SCBdSimplex(4),[[1],[2..5]]);;[0m
    [22m[35m gap> ns2:=SCNSSlicing(SCBdSimplex(4),[[2],[1,3,4,5]]);;   [0m
    [22m[35m gap> ns1=ns2;[0m
    [22m[35m true[0m
    [22m[35m gap> ns2:=SCNSSlicing(SCBdSimplex(4),[[1,2],[3,4,5]]);;  [0m
    [22m[35m gap> ns1=ns2;                                          [0m
    [22m[35m false[0m
    [22m[35m gap> [0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  [1m[4m[31m3.6-5 Operation Union (SCNormalSurface, SCNormalSurface)[0m
  
  [1m[34m> Operation Union (SCNormalSurface, SCNormalSurface)( [0m[22m[34mcomplex1, complex2[0m[1m[34m ) [0moperation
  [1mReturns:[0m  a new normnal surface upon success, [22m[32mfail[0m otherwise.
  
  Computes the union of two normal surfaces by calling [1m[34mSCUnion[0m ([1m4.6-24[0m).
  
  [22m[35m---------------------------  Example  ----------------------------[0m
    [22m[35m gap> SCLib.SearchByAttribute("F=[6,15,18,9]");[0m
    [22m[35m [ [ 4, "S^3 (VT)" ] ][0m
    [22m[35m gap> c:=SCLib.Load(4);;[0m
    [22m[35m gap> ns1:=SCNSSlicing(c,[[1,3,5],[2,4,6]]);;[0m
    [22m[35m gap> ns2:=SCNSSlicing(c,[[1,3,5],[2,4,6]])+10;;[0m
    [22m[35m gap> SCNSTopologicalType(ns1);[0m
    [22m[35m "T^2"[0m
    [22m[35m gap> SCNSTopologicalType(ns2);[0m
    [22m[35m "T^2"[0m
    [22m[35m gap> ns3:=Union(ns1,ns2);;[0m
    [22m[35m gap> SCNSTopologicalType(ns3);[0m
    [22m[35m "T^2 U T^2"[0m
    [22m[35m gap> [0m
    [22m[35m [0m
  [22m[35m------------------------------------------------------------------[0m
  
  
  [1m[4m[31m3.7 [22m[32mSCNormalSurface[1m[4m[31m as a subtype of [22m[32mSet[1m[4m[31m[0m
  
  Like  objects of type [22m[32mSCSimplicialComplex[0m, an object of type [22m[32mSCNormalSurface[0m
  behaves like a GAP [22m[32mSet[0m type. The elements of the set are given by the facets
  of  the  normal  surface,  grouped by their dimensionality and type, i.e. if
  [22m[32mcomplex[0m  is an object of type [22m[32mSCNormalSurface[0m, [22m[32mc[1][0m refers to the 0-faces of
  [22m[32mcomplex[0m,  [22m[32mc[2][0m  to  the  1-faces,  [22m[32mc[3][0m  to  the  triangles  and [22m[32mc[4][0m to the
  quadrilaterals. See section [1m3.4[0m for details.
  
