GAP (FinInG) - Chapter 3: Incidence Geometry

Goto Chapter: Top 1 2 3 4 5 6 7 8 9 10 11 12 13 14 A B C Bib Ind
[Top of Book] [Contents] [Previous Chapter] [Next Chapter]

[MathJax off]

3 Incidence Geometry
3.1 Incidence structures
3.1-1 IsIncidenceStructure
3.1-2 IsIncidenceGeometry
3.1-3 IncidenceStructure
3.1-4 Main categories in `IsIncidenceGeometry`
3.1-5 Examples of categories of incidence geometries
3.1-6 TypesOfElementsOfIncidenceStructure
3.1-7 Rank
3.1-8 IncidenceGraph
3.2 Elements of incidence structures
3.2-1 Main categories for individual elements of incidence structures
3.2-2 UnderlyingObject
3.2-3 Type
3.2-4 ObjectToElement
3.2-5 Main categories for collections of all the elements of a given type of an incidence structure
3.2-6 ElementsOfIncidenceStructure
3.2-7 ElementsOfIncidenceStructure
3.2-8 Short names for ElementsOfIncidenceStructure
3.2-9 NrElementsOfIncidenceStructure
3.2-10 Random
3.2-11 IsIncident
3.2-12 AmbientGeometry
3.3 Flags of incidence structures
3.3-1 FlagOfIncidenceStructure
3.3-2 IsChamberOfIncidenceStructure
3.3-3 IsEmptyFlag
3.3-4 ElementsOfFlag
3.3-5 Rank
3.3-6 Size
3.3-7 AmbientGeometry
3.3-8 Type
3.3-9 IsIncident
3.4 Shadow of elements
3.4-1 ShadowOfElement
3.4-2 ElementsIncidentWithElementOfIncidenceStructure
3.4-3 ShadowOfFlag
3.4-4 ResidueOfFlag
3.4-5 Short names for ElementsIncidentWithElementOfIncidenceStructure
3.5 Enumerating elements of an incidence structure
3.5-1 Iterator
3.5-2 Enumerator
3.5-3 List
3.5-4 AsList
3.6 Lie geometries
3.6-1 Main categories in `IsLieGeometry`
3.6-2 AmbientSpace
3.6-3 UnderlyingVectorSpace
3.6-4 ProjectiveDimension
3.6-5 IsEmptySubspace
3.7 Elements of Lie geometries
3.7-1 VectorSpaceToElement
3.7-2 UnderlyingObject
`3.7-3 \in`
3.7-4 More short names for `ElementsIncidentWithElementOfIncidenceStructure`
3.8 Changing the ambient geometry of elements of a Lie geometry
3.8-1 ElementToElement

### 3 Incidence Geometry

We follow [BC13] for the definitions of incidence structure and incidence geometry. An incidence structure consists of a set of elements, a symmetric relation on the elements and a type function from the set of elements to an index set (i.e., every element has a ``type''). It satisfies the following axiom: (i) no two elements of the same type are incident. An incidence structure without type function is in fact a multipartite graph where the adjacency is the incidence (so with a loop on each vertex). The term geometry, or incidence geometry, is interpreted broadly in this package. Particularly, an incidence geometry is an incidence structure satisfying the following axiom: (ii) every maximal flag contains an element of each type. In graph terminology, this means that every maximal clique contains an element of each type. Thus, a projective 5-space is an incidence geometry with five types of elements: points, lines, planes, solids, and hyperplanes. A finite classical polar space of rank 3 is an incidence geometry with three types of elements: points, lines, and planes. Depending on the viewpoint, the Grassmann variety of the lines of a projective 4-space, is an incidence structure that is not an incidence geometry.

FinInG concerns itself primarily with the most commonly studied incidence geometries of rank at least 2: projective spaces, polar spaces, and affine spaces. Throughout, no matter the geometry, we have made the convention that an element of type 1 is a ``point'', an element of type 2 is a ``line'', and so forth. The examples we use in this section use projective spaces, which have not yet been introduced to the reader in this manual. For further information on projective spaces, see Chapter 4.

In this chapter we describe functionality that is declared for incidence structures, which does not imply that operations described here will work for arbitrary user-constructed incidence structures. Its aim is furthermore to allow the user to become familiar with the general philosophy of the package, using examples that are self-explanatory. Not all details of the commands used in the examples will be explained in this chapter, therefore we refer to the relevant chapter for the commands. These can easily be found using the index.

#### 3.1 Incidence structures

Incidence structures can be more general than incidence geometries, e.g., if they do not satisfy axiom (ii) mentioned above. We allow the construction of such objects. This explains one of the top level categories in FinInG.

##### 3.1-1 IsIncidenceStructure

`‣ IsIncidenceStructure` | ( category )

Top level category for all objects representing an incidence structure.

##### 3.1-2 IsIncidenceGeometry

`‣ IsIncidenceGeometry` | ( category )

Category for all objects representing an incidence geometry. All particular geometries implemented in FinInG are incidence geometries.

##### 3.1-3 IncidenceStructure

`‣ IncidenceStructure`( eles, inc_rel, type, typeset ) | ( operation )

Returns: an incidence structure

eles is a set containing the elements of the incidence structure. inc_rel must be a function that determines whether two objects in the set eles are incident. type is a function mapping any element to its type, which is a unique element in the set typeset.

In the following example we define an incidence structure that is not an incidence geometry. The example used is the incidence structure with elements the subspaces contained in the line Grassmannian of PG(4,2). This example is not meant to create this incidence structure in an efficient way, but just to demonstrate the general philosophy.

    gap> pg := PG(4,2);
    ProjectiveSpace(4, 2)
    gap> pg2 := PG(9,2);
    ProjectiveSpace(9, 2)
    gap> points := List(Lines(pg),x->VectorSpaceToElement(pg2,GrassmannCoordinates(x)));;
    gap> flags := Concatenation(List(Points(pg),x->List(Planes(x),y->FlagOfIncidenceStructure(pg,[x,y]))));;
    gap> prelines := List(flags,flag->ShadowOfFlag(pg,flag,2));;
    gap> lines := List(prelines,x->VectorSpaceToElement(pg2,List(x,y->GrassmannCoordinates(y))));;
    gap> flags2 := Concatenation(List(Points(pg),x->List(Solids(x),y->FlagOfIncidenceStructure(pg,[x,y]))));;
    gap> preplanes := List(flags2,flag->ShadowOfFlag(pg,flag,2));;
    gap> planes := List(preplanes,x->VectorSpaceToElement(pg2,List(x,y->GrassmannCoordinates(y))));;
    gap> maximals1 := List(Planes(pg),x->VectorSpaceToElement(pg2,List(Lines(x),y->GrassmannCoordinates(y))));;
    gap> maximals2 := List(Points(pg),x->VectorSpaceToElement(pg2,List(Lines(x),y->GrassmannCoordinates(y))));;
    gap> elements := Union(points,lines,planes,maximals1,maximals2);;
    gap> Length(elements);
    1891
    gap> type := x -> ProjectiveDimension(x)+1;
    function( x ) ... end
    gap> inc_rel := \*;
    <Operation "*">
    gap> inc := IncidenceStructure(elements,inc_rel,type,[1,2,3,4]);
    Incidence structure of rank 4
    gap> Rank(inc);
    4

Lie Geometries, i.e., geometries with a projective space as ambient space, affine spaces and generalised polygons have their own category, which is a subcategory of `IsIncidenceGeometry`.

##### 3.1-4 Main categories in `IsIncidenceGeometry`

`‣ IsLieGeometry` | ( category )

`‣ IsAffineSpace` | ( category )

`‣ IsGeneralisedPolygon` | ( category )

`‣ IsCosetGeometry` | ( category )

Within each category, several subcategories are declared. Subcategories of `IsLieGeometry` are discussed in Section 3.6 and subcategories of `IsGeneralisedPolygon` are discussed in Chapter 12

##### 3.1-5 Examples of categories of incidence geometries

    gap> CategoriesOfObject(ProjectiveSpace(5,7));
    [ "IsIncidenceStructure", "IsIncidenceGeometry", "IsLieGeometry",
      "IsProjectiveSpace" ]
    gap> CategoriesOfObject(HermitianPolarSpace(5,9));
    [ "IsIncidenceStructure", "IsIncidenceGeometry", "IsLieGeometry",
      "IsClassicalPolarSpace", "IsAlgebraicVariety", "IsProjectiveVariety",
      "IsHermitianVariety" ]
    gap> CategoriesOfObject(AffineSpace(3,3));
    [ "IsIncidenceStructure", "IsIncidenceGeometry", "IsAffineSpace" ]
    gap> CategoriesOfObject(SymplecticSpace(3,11));
    [ "IsIncidenceStructure", "IsIncidenceGeometry", "IsLieGeometry",
      "IsClassicalPolarSpace", "IsGeneralisedPolygon", "IsGeneralisedQuadrangle",
      "IsClassicalGQ" ]
    gap> CategoriesOfObject(SplitCayleyHexagon(9));
    [ "IsIncidenceStructure", "IsIncidenceGeometry", "IsLieGeometry",
      "IsGeneralisedPolygon", "IsGeneralisedHexagon",
      "IsClassicalGeneralisedHexagon" ]
    gap> CategoriesOfObject(ParabolicQuadric(4,16));
    [ "IsIncidenceStructure", "IsIncidenceGeometry", "IsLieGeometry",
      "IsClassicalPolarSpace", "IsGeneralisedPolygon", "IsGeneralisedQuadrangle",
      "IsClassicalGQ", "IsAlgebraicVariety", "IsProjectiveVariety" ]

##### 3.1-6 TypesOfElementsOfIncidenceStructure

`‣ TypesOfElementsOfIncidenceStructure`( inc ) | ( attribute )

`‣ TypesOfElementsOfIncidenceStructurePlural`( inc ) | ( attribute )

Returns: a list of strings or integers

Both attributes are declared for objects in the category `IsIncidenceStructure`. Any incidence structure has a set of types, which is usually just the list \([1..n]\). If specific names are given to each type, like points, lines, etc., this attribute returns the names for the particular incidence structure inc. The second variant returns the list of plurals of these names. For generically constructed incidence structures, the names of the Elements are also generic: elements of type 1, elements of type 2, etc.

    gap> TypesOfElementsOfIncidenceStructure(ProjectiveSpace(5,4));
    [ "point", "line", "plane", "solid", "proj. 4-space" ]
    gap> TypesOfElementsOfIncidenceStructurePlural(AffineSpace(7,4));
    [ "points", "lines", "planes", "solids", "affine. subspaces of dim. 4",
      "affine. subspaces of dim. 5", "affine. subspaces of dim. 6" ]

##### 3.1-7 Rank

`‣ Rank`( inc ) | ( operation )

`‣ RankAttr`( inc ) | ( attribute )

Returns: rank of inc, an object which must belong to the category `IsIncidenceStructure`

The operation `Rank` returns the rank of the incidence structure `inc`. The highest level method for `Rank`, applicable to objects in `IsIncidenceStructure` simply refers to the attribute `RankAttr`. In FinInG, the rank of an incidence structure is determined upon creation, when also `RankAttr` is set.

    gap> Rank(ProjectiveSpace(5,5));
    5
    gap> Rank(AffineSpace(3,5));
    3
    gap> Rank(SymplecticSpace(5,5));
    3

##### 3.1-8 IncidenceGraph

`‣ IncidenceGraph`( inc ) | ( attribute )

Returns: a graph

The vertices are the elements of inc, adjacency between different vertices is equal to incidence, and there are of course no loops. For generic incidence structures, i.e. constructed through `IncidenceStructure`, there is no efficient method installed, so this operation can be time consuming.

If inc is a generic incidence structure, i.e. created using `IncidenceStructure`, the vertex names of the graph are integers. It is not by default possible to use the elements of inc as vertex names, since it is not known in the generic case whether the elements of different type of inc can be ordered. For particular incidence geometries, e.g. projective spaces, etc., the vertex names will be the elements, which will be demonstrated through examples in the appropriate chapters.

In the example we consider the so-called doubling of the smallest generalised quadrangle: the points of the incidence structure are the points and the lines of the GQ, the lines of the incidence structure are all the point-line flags of the GQ. The incidence is the natural one. It is then checked that diameter and girth of the incidence graph are 8 and 16 respectively, which makes that the incidence structure is a generalised octagon.

    gap> ps := SymplecticSpace(3,2);
    W(3, 2)
    gap> pts := List(Points(ps));;
    gap> lines := List(Lines(ps));;
    gap> flags := Union(List(pts,x->List(Lines(x),y->FlagOfIncidenceStructure(ps,[x,y]))));;
    gap> inc := function(x,y)
    > if x = y then
    >     return true;
    > elif IsFlagOfIncidenceStructure(x) and IsElementOfIncidenceStructure(y) then
    >     return IsIncident(x,y);
    > elif IsElementOfIncidenceStructure(x) and IsElementOfIncidenceStructure(y) then
    >     return false;
    > elif IsFlagOfIncidenceStructure(x) and IsFlagOfIncidenceStructure(y) then
    >     return false;
    > else
    >     return inc(y,x);
    > fi;
    > end;
    function( x, y ) ... end
    gap> type := function(x)
    > if IsList(Type(x)) then
    >     return 2;
    > else
    >     return 1;
    > fi;
    > end;
    function( x ) ... end
    gap> els := Union(pts,lines,flags);;
    gap> struc := IncidenceStructure(els,inc,type,[1,2]);
    Incidence structure of rank 2
    gap> gamma := IncidenceGraph(struc);
    rec( adjacencies := [ [ 31, 32, 33 ], [ 34, 35, 36 ], [ 37, 38, 39 ],
          [ 40, 41, 42 ], [ 43, 44, 45 ], [ 46, 47, 48 ], [ 49, 50, 51 ],
          [ 52, 53, 54 ], [ 55, 56, 57 ], [ 58, 59, 60 ], [ 61, 62, 63 ],
          [ 64, 65, 66 ], [ 67, 68, 69 ], [ 70, 71, 72 ], [ 73, 74, 75 ],
          [ 31, 40, 43 ], [ 32, 52, 55 ], [ 33, 64, 67 ], [ 34, 41, 46 ],
          [ 35, 53, 58 ], [ 36, 65, 70 ], [ 37, 42, 49 ], [ 38, 54, 61 ],
          [ 39, 66, 73 ], [ 44, 59, 74 ], [ 45, 62, 71 ], [ 47, 56, 75 ],
          [ 50, 57, 72 ], [ 48, 63, 68 ], [ 51, 60, 69 ], [ 1, 16 ], [ 1, 17 ],
          [ 1, 18 ], [ 2, 19 ], [ 2, 20 ], [ 2, 21 ], [ 3, 22 ], [ 3, 23 ],
          [ 3, 24 ], [ 4, 16 ], [ 4, 19 ], [ 4, 22 ], [ 5, 16 ], [ 5, 25 ],
          [ 5, 26 ], [ 6, 19 ], [ 6, 27 ], [ 6, 29 ], [ 7, 22 ], [ 7, 28 ],
          [ 7, 30 ], [ 8, 17 ], [ 8, 20 ], [ 8, 23 ], [ 9, 17 ], [ 9, 27 ],
          [ 9, 28 ], [ 10, 20 ], [ 10, 25 ], [ 10, 30 ], [ 11, 23 ], [ 11, 26 ],
          [ 11, 29 ], [ 12, 18 ], [ 12, 21 ], [ 12, 24 ], [ 13, 18 ], [ 13, 29 ],
          [ 13, 30 ], [ 14, 21 ], [ 14, 26 ], [ 14, 28 ], [ 15, 24 ], [ 15, 25 ],
          [ 15, 27 ] ], group := Group(()), isGraph := true, names := [ 1 .. 75 ],
      order := 75,
      representatives := [ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16,
          17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,
          35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52,
          53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70,
          71, 72, 73, 74, 75 ],
      schreierVector := [ -1, -2, -3, -4, -5, -6, -7, -8, -9, -10, -11, -12, -13,
          -14, -15, -16, -17, -18, -19, -20, -21, -22, -23, -24, -25, -26, -27,
          -28, -29, -30, -31, -32, -33, -34, -35, -36, -37, -38, -39, -40, -41,
          -42, -43, -44, -45, -46, -47, -48, -49, -50, -51, -52, -53, -54, -55,
          -56, -57, -58, -59, -60, -61, -62, -63, -64, -65, -66, -67, -68, -69,
          -70, -71, -72, -73, -74, -75 ] )
    gap> Diameter(gamma);
    8
    gap> Girth(gamma);
    16

#### 3.2 Elements of incidence structures

##### 3.2-1 Main categories for individual elements of incidence structures

`‣ IsElementOfIncidenceStructure` | ( category )

`‣ IsElementOfIncidenceGeometry` | ( category )

`‣ IsElementOfLieGeometry` | ( category )

`‣ IsElementOfAffineSpace` | ( category )

`‣ IsElementOfCosetGeometry` | ( category )

`‣ IsSubspaceOfProjectiveSpace` | ( category )

`‣ IsSubspaceOfClassicalPolarSpace` | ( category )

`‣ IsElementOfGeneralisedPolygon` | ( category )

In general, elements of an incidence structure belonging to `IsIncStr`, are in the category `IsElementOfIncStr`. The inclusion for different categories of geometries is followed for their elements, with an exception for `IsSubspaceOfClassicalPolarSpace`, which is a subcategory of `IsSubspaceOfProjectiveSpace`, while `IsClassicalPolarSpace` is not a subcategory of `IsProjectiveSpace`.

    gap> Random(Lines(SplitCayleyHexagon(3)));
    #I  for Split Cayley Hexagon
    #I  Computing nice monomorphism...
    #I  Found permutation domain...
    <a line in H(3)>
    gap> CategoriesOfObject(last);
    [ "IsElementOfIncidenceStructure", "IsElementOfIncidenceGeometry",
      "IsElementOfLieGeometry", "IsSubspaceOfProjectiveSpace",
      "IsSubspaceOfClassicalPolarSpace", "IsElementOfGeneralisedPolygon" ]
    gap> Random(Solids(AffineSpace(7,17)));
    <a solid in AG(7, 17)>
    gap> CategoriesOfObject(last);
    [ "IsElementOfIncidenceStructure", "IsElementOfIncidenceGeometry",
      "IsSubspaceOfAffineSpace" ]

##### 3.2-2 UnderlyingObject

`‣ UnderlyingObject`( el ) | ( operation )

Returns: an object

An element of an incidence structure has a type and an underlying object. E.g. a line of a projective space is determined by a two dimensional sub vector space, which is determined by a basis. Elements of incidence structure can also be objects representing elements of other incidence structures, as is e.g. the case in the example of 3.1-3. The examples shows the underlying objects of elements of three totally different incidence geometries.

    gap> pg := PG(2,2);
    ProjectiveSpace(2, 2)
    gap> p := Random(Points(pg));
    <a point in ProjectiveSpace(2, 2)>
    gap> UnderlyingObject(p);
    <cvec over GF(2,1) of length 3>
    gap> l := Random(Lines(pg));
    <a line in ProjectiveSpace(2, 2)>
    gap> UnderlyingObject(l);
    <cmat 2x3 over GF(2,1)>
    gap> mat := [ [ 1, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0 ],
    >   [ 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0 ],
    >   [ 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0 ],
    >   [ 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0 ],
    >   [ 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0 ],
    >   [ 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0 ],
    >   [ 0, 0, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0 ],
    >   [ 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0 ],
    >   [ 0, 0, 0, 0, 1, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0 ],
    >   [ 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0 ],
    >   [ 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0 ],
    >   [ 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 1 ],
    >   [ 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1 ],
    >   [ 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0 ],
    >   [ 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 1 ] ];
    [ [ 1, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0 ],
      [ 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0 ],
      [ 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0 ],
      [ 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0 ],
      [ 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0 ],
      [ 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0 ],
      [ 0, 0, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0 ],
      [ 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0 ],
      [ 0, 0, 0, 0, 1, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0 ],
      [ 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0 ],
      [ 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0 ],
      [ 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 1 ],
      [ 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1 ],
      [ 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0 ],
      [ 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 1 ] ]
    gap> gp := GeneralisedPolygonByIncidenceMatrix(mat);
    <generalised quadrangle of order [ 2, 2 ]>
    gap> p := Random(Points(gp));
    <a point in <generalised quadrangle of order [ 2, 2 ]>>
    gap> UnderlyingObject(p);
    15
    gap> l := Random(Lines(gp));
    <a line in <generalised quadrangle of order [ 2, 2 ]>>
    gap> UnderlyingObject(l);
    [ 7, 13, 15 ]
    gap> egq := EGQByBLTSet(BLTSetByqClan(LinearqClan(3)));
    #I  Now embedding dual BLT-set into W(5,q)...
    #I  Computing elation group...
    <EGQ of order [ 9, 3 ] and basepoint in W(5, 3 ) >
    gap> p := Random(Points(egq));
    <a point in <EGQ of order [ 9, 3 ] and basepoint in W(5, 3 ) >>
    gap> UnderlyingObject(p);
    <a point in W(5, 3)>

##### 3.2-3 Type

`‣ Type`( el ) | ( operation )

Returns: an integer

An element of an incidence structure has a type and an underlying object. Its type is always a non-negative integer. This operation returns the type of an element.

    gap> pg := PG(2,2);
    ProjectiveSpace(2, 2)
    gap> p := Random(Points(pg));
    <a point in ProjectiveSpace(2, 2)>
    gap> Type(p);
    1
    gap> l := Random(Lines(pg));
    <a line in ProjectiveSpace(2, 2)>
    gap> Type(l);
    2

##### 3.2-4 ObjectToElement

`‣ ObjectToElement`( inc, t, obj ) | ( operation )

Returns: an element of the incidence structure inc

If obj represents an element of inc of type t, this operation returns the element. An error (or no method found error) is shown when obj does not represent an element of type t. Note that `ObjectToElement` is a generic operation. Versions with a different argument set and even alternative operations exist for some particular geometries to construct particular elements.

##### 3.2-5 Main categories for collections of all the elements of a given type of an incidence structure

`‣ IsElementsOfIncidenceStructure` | ( category )

`‣ IsElementsOfIncidenceGeometry` | ( category )

`‣ IsElementsOfLieGeometry` | ( category )

`‣ IsElementsOfAffineSpace` | ( category )

`‣ IsElementsOfCosetGeometry` | ( category )

`‣ IsSubspacesOfProjectiveSpace` | ( category )

`‣ IsSubspacesOfClassicalPolarSpace` | ( category )

For a given incidence structure, the collection of elements of a given type can be constructed. constructed here means that an object is returned that represents all the elements of a given type, rather than listing them immediately, to avoid long computation times. Such an abstract object is e.g. used as a range for In general, the collection of elements of a given type of an incidence structure belonging to `IsIncStr`, is in the category `IsElementsOfIncStr`. The inclusion for different categories of geometries is followed for their collection of elements of a given type, with an exception for `IsSubspacesOfClassicalPolarSpace`, which is a subcategory of `IsSubspacesOfProjectiveSpace`, while `IsClassicalPolarSpace` is not a subcategory of `IsProjectiveSpace`.

The object representing the set of elements of a given type can be computed using the general operation `ElementsOfIncidenceStructure`.

##### 3.2-6 ElementsOfIncidenceStructure

`‣ ElementsOfIncidenceStructure`( inc, j ) | ( operation )

`‣ ElementsOfIncidenceStructure`( inc, str ) | ( operation )

Returns: a collection of elements

inc must be an incidence structure, j must be a type of element of inc. This function returns all elements of inc of type j, and an error is displayed if inc has no elements of type j. Calling the elements (of a given type) of inc yields an object in the category `IsElementsOfIncidenceStructure` (or the appropriate category for projective spaces and classical polar spaces), which does not imply that all elements are computed and stored. In an alternative form of this function str can be one of the strings found in the list obtained by calling `TypesOfElementsOfIncidenceStructurePlural(inc)`. E.g. for projective spaces, ``points", ``lines", ``planes" or ``solids" are the names for elements of type 1,2,3 or 4, respectively, of course if inc has elements of the deduced type.

    gap> ps := ProjectiveSpace(3,3);
    ProjectiveSpace(3, 3)
    gap> l := ElementsOfIncidenceStructure(ps,2);
    <lines of ProjectiveSpace(3, 3)>
    gap> ps := EllipticQuadric(5,9);
    Q-(5, 9)
    gap> lines := ElementsOfIncidenceStructure(ps,2);
    <lines of Q-(5, 9)>
    gap> planes := ElementsOfIncidenceStructure(ps,3);
    Error, <geo> has no elements of type <j> called from
    <function "unknown">( <arguments> )
     called from read-eval loop at line 12 of *stdin*
    you can 'quit;' to quit to outer loop, or
    you can 'return;' to continue
    brk> quit;
    gap> as := AffineSpace(3,9);
    AG(3, 9)
    gap> lines := ElementsOfIncidenceStructure(as,"lines");
    <lines of AG(3, 9)>

##### 3.2-7 ElementsOfIncidenceStructure

`‣ ElementsOfIncidenceStructure`( inc ) | ( operation )

Returns: a collection of elements

inc must be an incidence structure, then this operation returns the collection of all elements of inc. Such a collection can e.g. be the range of a geometry morphism. Note that this operation has no method for generic incidence structures constructed using `Incidence Structure`.

##### 3.2-8 Short names for ElementsOfIncidenceStructure

`‣ Points`( inc ) | ( operation )

`‣ Lines`( inc ) | ( operation )

`‣ Planes`( inc ) | ( operation )

`‣ Solids`( inc ) | ( operation )

Returns: The points, lines, planes, solids, respectively of inc

For geometries in `IsLieGeometry`, `IsAffineSpace`, and `IsGeneralisedPolygon`, the elements of type 1,2,3,4 respectively are called usually points, lines, planes, solids, respectively. These methods are, for such geometries, are shortcuts to `ElementsOfIncidenceStructure(inc,j)`, with j equal to 1,2,3,4, respectively.

    gap> Points(HermitianVariety(2,64));
    <points of Hermitian Variety in ProjectiveSpace(2, 64)>
    gap> Lines(EllipticQuadric(5,2));
    <lines of Q-(5, 2)>
    gap> Planes(SymplecticSpace(7,3));
    <planes of W(7, 3)>
    gap> Lines(TwistedTrialityHexagon(2^3));
    <lines of T(8, 2)>

##### 3.2-9 NrElementsOfIncidenceStructure

`‣ NrElementsOfIncidenceStructure`( inc, j ) | ( operation )

`‣ NrElementsOfIncidenceStructure`( inc, str ) | ( operation )

Returns: a positive integer

inc must be an incidence structure, j must be a type of element of inc. This function returns the number of elements of inc of type j, and an error is displayed if inc has no elements of type j. In the alternative form of this function str can be one of ``points", ``lines", ``planes" or ``solids" and the function returns the number of elements of type 1, 2, 3 or 4 respectively, of course if inc has elements of the deduced type. For geometries in the category `IsLieGeometry`, `IsAffineSpace`, and `IsGeneralisedPolygon`, the number of elements of a given type is known upon construction of the geometry. As such, for these geometries, this operation requires no computing time.

    gap> ps:=ProjectiveSpace(4,3);
    ProjectiveSpace(4, 3)
    gap> NrElementsOfIncidenceStructure(ps, 2);
    1210
    gap> NrElementsOfIncidenceStructure(ps, "points");
    121

##### 3.2-10 Random

`‣ Random`( C ) | ( operation )

Returns: an element in the collection C

C is a collection of elements of an incidence structure, i.e., an object in the category `IsElementsOfIncidenceStructure`. `Random(C)` will return a random element in C provided there is a method installed. The generic method will compute all elements in C and return a random member from the list. For e.g. Lie geometries, more efficient methods are installed.

    gap> coll := Hyperplanes(PG(5,7));
    <proj. 4-subspaces of ProjectiveSpace(5, 7)>
    gap> Random(coll);
    <a proj. 4-space in ProjectiveSpace(5, 7)>

##### 3.2-11 IsIncident

`‣ IsIncident`( u, v ) | ( operation )

`‣ \*`( u, v ) | ( operation )

Returns: true or false

u and v must be elements of an incidence structure. This function returns true if and only if u is incident with v. Recall that `IsIncident` is a symmetric relation, while `in` is not. A method for the operation `\*` is installed, applicable to objects in `IsElementOfIncidenceStructure`. It just calls `IsIncident`.

    gap> p := Random(Points(PG(5,4)));
    <a point in ProjectiveSpace(5, 4)>
    gap> l := Random(Lines(p));
    <a line in ProjectiveSpace(5, 4)>
    gap> IsIncident(p,l);
    true
    gap> IsIncident(l,p);
    true
    gap> p * l;
    true
    gap> l * p;
    true
    gap> p * p;
    true
    gap> l * l;
    true

##### 3.2-12 AmbientGeometry

`‣ AmbientGeometry`( v ) | ( operation )

Returns: the ambient geometry of the element v

If v is an element of an incidence geometry currently implemented in FinInG, then this operation returns the ambient geometry of v, i.e., in general the geometry in which v was created. If an incidence structure is created with elements that are a subset of elements of another incidence structure, the ambient geometry might stay unchanged.

    gap> plane := Random(Planes(HyperbolicQuadric(5,2)));
    <a plane in Q+(5, 2)>
    gap> AmbientGeometry(plane);
    Q+(5, 2)
    gap> l := Random(Lines(SplitCayleyHexagon(3)));
    #I  for Split Cayley Hexagon
    #I  Computing nice monomorphism...
    #I  Found permutation domain...
    <a line in H(3)>
    gap> Print(l);
    NewMatrix(IsCMatRep,GF(3,1),7,[[ Z(3)^0, 0*Z(3), 0*Z(3), 0*Z(3), 0*Z(3),
      Z(3)^0, Z(3)^0 ],[ 0*Z(3), Z(3)^0, Z(3), Z(3)^0, 0*Z(3), Z(3)^0, 0*Z(3) ],])
    gap> AmbientGeometry(l);
    H(3)
    gap> p := Random(Points(EGQByBLTSet(BLTSetByqClan(LinearqClan(3)))));
    #I  Now embedding dual BLT-set into W(5,q)...
    #I  Computing elation group...
    <a point in <EGQ of order [ 9, 3 ] and basepoint in W(5, 3 ) >>
    gap> Print(p);
    NewRowVector(IsCVecRep,GF(3,1),[Z(3)^0,Z(3),Z(3),Z(3),Z(3)^0,0*Z(3),])
    gap> AmbientGeometry(p);
    <EGQ of order [ 9, 3 ] and basepoint in W(5, 3 ) >

#### 3.3 Flags of incidence structures

A flag of an incidence structure \(S\) is a set \(F\) of elements of \(S\) that are two by two incident. This implies that all elements in \(F\) have a different type. A flag is maximal if it cannot be extended with more elements. FinInG provides a basic category `IsFlagOfIncidenceStructure`. For different types of incidence structures, methods to create a flag can be installed. A chamber is a flag of size \(n\), where \(n\) is the rank of the incidence structure. Recall that an incidence structure is an incidence geometry if every maximal flag is a chamber.

##### 3.3-1 FlagOfIncidenceStructure

`‣ FlagOfIncidenceStructure`( inc, l ) | ( operation )

Returns: the flag consisting of the elements of inc in the list l

It is checked if all elements in l are incident and belong to the same incidence structure. An empty list is allowed.

    gap> ps := PG(3,7);
    ProjectiveSpace(3, 7)
    gap> point := VectorSpaceToElement(ps,[1,2,0,0]*Z(7)^0);
    <a point in ProjectiveSpace(3, 7)>
    gap> line := VectorSpaceToElement(ps,[[1,0,0,0],[0,1,0,0]]*Z(7)^0);
    <a line in ProjectiveSpace(3, 7)>
    gap> plane := VectorSpaceToElement(ps,[[1,0,0,0],[0,1,0,0],[0,0,0,1]]*Z(7)^0);
    <a plane in ProjectiveSpace(3, 7)>
    gap> flag := FlagOfIncidenceStructure(ps,[point,line,plane]);
    <a flag of ProjectiveSpace(3, 7)>

##### 3.3-2 IsChamberOfIncidenceStructure

`‣ IsChamberOfIncidenceStructure`( flag ) | ( operation )

Returns: true if and only if flag contains an element of each type

The incidence structure is determined by the elements.

    gap> ps := PG(3,7);
    ProjectiveSpace(3, 7)
    gap> point := VectorSpaceToElement(ps,[1,2,0,0]*Z(7)^0);
    <a point in ProjectiveSpace(3, 7)>
    gap> line := VectorSpaceToElement(ps,[[1,0,0,0],[0,1,0,0]]*Z(7)^0);
    <a line in ProjectiveSpace(3, 7)>
    gap> plane := VectorSpaceToElement(ps,[[1,0,0,0],[0,1,0,0],[0,0,0,1]]*Z(7)^0);
    <a plane in ProjectiveSpace(3, 7)>
    gap> flag1 := FlagOfIncidenceStructure(ps,[point,plane]);
    <a flag of ProjectiveSpace(3, 7)>
    gap> IsChamberOfIncidenceStructure(flag1);
    false
    gap> flag2 := FlagOfIncidenceStructure(ps,[point,line,plane]);
    <a flag of ProjectiveSpace(3, 7)>
    gap> IsChamberOfIncidenceStructure(flag2);
    true

##### 3.3-3 IsEmptyFlag

`‣ IsEmptyFlag`( flag ) | ( operation )

Returns: true or false

It is possible to construct the empty flag of an incidence structure. This operation tests whether a given flag is empty.

##### 3.3-4 ElementsOfFlag

`‣ ElementsOfFlag`( flag ) | ( operation )

Returns: a list of elements

This operations simply returns the list of elements that define flag

    gap> gp := SplitCayleyHexagon(4);
    H(4)
    gap> p := Random(Points(gp));
    #I  for Split Cayley Hexagon
    #I  Computing nice monomorphism...
    #I  Found permutation domain...
    <a point in H(4)>
    gap> l := Random(Lines(p));
    <a line in H(4)>
    gap> flag := FlagOfIncidenceStructure(gp,[l,p]);
    <a flag of H(4)>
    gap> ElementsOfFlag(flag);
    [ <a point in H(4)>, <a line in H(4)> ]

##### 3.3-5 Rank

`‣ Rank`( flag ) | ( attribute )

Returns: an integer

This operations returns the number of elements that define flag

    gap> ps := ParabolicQuadric(8,3);
    Q(8, 3)
    gap> l := Random(Lines(ps));
    <a line in Q(8, 3)>
    gap> plane := Random(Planes(l));
    <a plane in Q(8, 3)>
    gap> solid := Random(Solids(plane));
    <a solid in Q(8, 3)>
    gap> flag := FlagOfIncidenceStructure(ps,[l,plane,solid]);
    <a flag of Q(8, 3) >
    gap> Rank(flag);
    3

##### 3.3-6 Size

`‣ Size`( flag ) | ( attribute )

Returns: an integer

This operations returns the number of elements that define flag

    gap> ps := SymplecticSpace(5,7);
    W(5, 7)
    gap> p := Random(Points(ps));
    <a point in W(5, 7)>
    gap> plane := Random(Planes(p));
    <a plane in W(5, 7)>
    gap> flag := FlagOfIncidenceStructure(ps,[p,p,plane]);
    <a flag of W(5, 7) >
    gap> Size(flag);
    2
    gap> ElementsOfFlag(flag);
    [ <a point in W(5, 7)>, <a plane in W(5, 7)> ]

##### 3.3-7 AmbientGeometry

`‣ AmbientGeometry`( flag ) | ( attribute )

Returns: an incidence structure

This operations returns the ambient geometry of the flag

    gap> ps := SymplecticSpace(5,7);
    W(5, 7)
    gap> p := Random(Points(ps));
    <a point in W(5, 7)>
    gap> plane := Random(Planes(p));
    <a plane in W(5, 7)>
    gap> flag := FlagOfIncidenceStructure(ps,[p,p,plane]);
    <a flag of W(5, 7) >
    gap> Size(flag);
    2
    gap> ElementsOfFlag(flag);
    [ <a point in W(5, 7)>, <a plane in W(5, 7)> ]

##### 3.3-8 Type

`‣ Type`( flag ) | ( operation )

Returns: an list of integers

This operations returns the list of types of the elements defining flag

    gap> pg := PG(8,9);
    ProjectiveSpace(8, 9)
    gap> l := Random(Lines(pg));
    <a line in ProjectiveSpace(8, 9)>
    gap> s := Random(Solids(l));
    <a solid in ProjectiveSpace(8, 9)>
    gap> flag := FlagOfIncidenceStructure(pg,[l,s]);
    <a flag of ProjectiveSpace(8, 9)>
    gap> Type(flag);
    [ 2, 4 ]
    gap> p := Random(Points(pg));
    <a point in ProjectiveSpace(8, 9)>
    gap> flag := FlagOfIncidenceStructure(pg,[p]);
    <a flag of ProjectiveSpace(8, 9)>
    gap> Type(flag);
    [ 1 ]

##### 3.3-9 IsIncident

`‣ IsIncident`( el, flag ) | ( operation )

`‣ IsIncident`( flag, el ) | ( operation )

Returns: true or false

An element is incident with a flag if and only if it is incident with all elements defining the flag.

    gap> pg := PG(3,5);
    ProjectiveSpace(3, 5)
    gap> p := Random(Points(pg));
    <a point in ProjectiveSpace(3, 5)>
    gap> l := Random(Lines(p));
    <a line in ProjectiveSpace(3, 5)>
    gap> plane := Random(Planes(l));
    <a plane in ProjectiveSpace(3, 5)>
    gap> flag := FlagOfIncidenceStructure(pg,[l,plane]);
    <a flag of ProjectiveSpace(3, 5)>
    gap> IsIncident(flag,l);
    true
    gap> IsIncident(l,flag);
    true

#### 3.4 Shadow of elements

##### 3.4-1 ShadowOfElement

`‣ ShadowOfElement`( inc, v, str ) | ( operation )

`‣ ShadowOfElement`( inc, v, j ) | ( operation )

Returns: The collection of elements of type str or type j incident with v

inc is an incidence structure, v must be an element of inc, str must be a string which is the plural of the name of one of the types of the elements of inc. For the second variant, j is an integer representing one of the types of the elements of inc. This first variant relies on `TypesOfElementsOfIncidenceStructurePlural` and on a particular method installed for the second variant for particular incidence structures. The use of the argument inc makes it flexible, i.e., if the element v can belong to different incidence structures, its shadow can be different, as the second example shows.

    gap> ps := ProjectiveSpace(3,3);
    ProjectiveSpace(3, 3)
    gap> pi := Random(Planes(ps));
    <a plane in ProjectiveSpace(3, 3)>
    gap> lines := ShadowOfElement(ps,pi,"lines");
    <shadow lines in ProjectiveSpace(3, 3)>
    gap> Size(lines);
    13

    gap> p := Random(Points(PG(3,3)));
    <a point in ProjectiveSpace(3, 3)>
    gap> lines1 := ShadowOfElement(SymplecticSpace(3,3),p,2);
    <shadow lines in W(3, 3)>
    gap> Size(lines1);
    4
    gap> lines2 := ShadowOfElement(PG(3,3),p,2);
    <shadow lines in ProjectiveSpace(3, 3)>
    gap> Size(lines2);
    13

##### 3.4-2 ElementsIncidentWithElementOfIncidenceStructure

`‣ ElementsIncidentWithElementOfIncidenceStructure`( v, j ) | ( operation )

Returns: The collection of elements of type j incident with v

This operation is applicable for objects v belonging to `IsElementOfIncidenceStructure`, and is a shortcut to `ShadowOfElement(AmbientGeometry(v),v,j)`.

##### 3.4-3 ShadowOfFlag

`‣ ShadowOfFlag`( inc, flag, str ) | ( operation )

`‣ ShadowOfFlag`( inc, list, str ) | ( operation )

`‣ ShadowOfFlag`( inc, flag, j ) | ( operation )

`‣ ShadowOfFlag`( inc, list, j ) | ( operation )

Returns: The collection of elements of type str or type j incident with all elements of flag, or with all elements of list

Variants 2 and 4 convert list to a flag of inc, using `FlagOfIcidenceStructure`, which performs the necessary checks. Variants 1 and 2 rely on variants 3 and 4 respectively, for which a method must be installed for the particular incidence structure inc.

    gap> ps := PG(3,7);
    ProjectiveSpace(3, 7)
    gap> point := VectorSpaceToElement(ps,[1,2,0,0]*Z(7)^0);
    <a point in ProjectiveSpace(3, 7)>
    gap> plane := VectorSpaceToElement(ps,[[1,0,0,0],[0,1,0,0],[0,0,0,1]]*Z(7)^0);
    <a plane in ProjectiveSpace(3, 7)>
    gap> flag := FlagOfIncidenceStructure(ps,[point,plane]);
    <a flag of ProjectiveSpace(3, 7)>
    gap> lines := ShadowOfFlag(ps,flag,"lines");
    <shadow lines in ProjectiveSpace(3, 7)>

##### 3.4-4 ResidueOfFlag

`‣ ResidueOfFlag`( flag ) | ( operation )

Returns: an incidence structure

Consider the flag flag, and its ambient geometry \(G\). All elements of \(G\) incident with all elements of flag, together with the incidence of \(G\), determine an incidence structure. This incidence structure is returned by this operation. Note that independently of the Category of \(G\), the returned incidence structure is constructed using the operation `IncidenceStructure`.

    gap> pg := PG(4,5);
    ProjectiveSpace(4, 5)
    gap> p := Random(Points(pg));
    <a point in ProjectiveSpace(4, 5)>
    gap> l := Random(Lines(p));
    <a line in ProjectiveSpace(4, 5)>
    gap> flag := FlagOfIncidenceStructure(pg,[p,l]);
    <a flag of ProjectiveSpace(4, 5)>
    gap> res := ResidueOfFlag(flag);
    Incidence structure of rank 2
    gap> gamma := IncidenceGraph(res);;
    gap> Diameter(gamma);
    3
    gap> Girth(gamma);
    6

##### 3.4-5 Short names for ElementsIncidentWithElementOfIncidenceStructure

`‣ Points`( inc, v ) | ( operation )

`‣ Lines`( inc, v ) | ( operation )

`‣ Planes`( inc, v ) | ( operation )

`‣ Solids`( inc, v ) | ( operation )

`‣ Points`( v ) | ( operation )

`‣ Lines`( v ) | ( operation )

`‣ Planes`( v ) | ( operation )

`‣ Solids`( v ) | ( operation )

Returns: The collections of elements of inc of respective type 1, 2, 3 and 4, that are incident with v

If inc, or the ambient geometry of v is an incidence structure, where the elements of type 1, 2, 3 and 4 are called "points", "lines", "planes", and "solids" respectively, these operations are shortcuts to `ShadowOfElement`. If this is not the case, a method for these operations is not installed.

    gap> line := Random(Lines(AG(5,4)));
    <a line in AG(5, 4)>
    gap> Points(line);
    <shadow points in AG(5, 4)>
    gap> Planes(line);
    <shadow planes in AG(5, 4)>

#### 3.5 Enumerating elements of an incidence structure

In several situations, it can be useful to compute a complete list of objects satisfying one or more conditions. To list all elements of a given type of an incidence structure, is a typical example. FinInG provides functionality that is common in GAP for this purpose.

In FinInG, typically a list of all elements satisfying a property, e.g. all points of a projective space, are represented by a GAP object that is a collection. The word 'collection' is important here. E.g. subspaces of a vector space are not calculated on calling `Subspaces`, rather primitive information is stored in an `IsComponentObjectRep`. So for example

    gap> v:=GF(31)^5;
    ( GF(31)^5 )
    gap> subs:=Subspaces(v,1);
    Subspaces( ( GF(31)^5 ), 1 )

For a given collection C, one can use the GAP function `List` to compute all objects in the collection C. Such a list can be used to iterate over all objects in the list. However, if one needs only few random objects from C, or if one needs to iterate over the list of objects until a certain condition is satisfied, it can be highly inefficient to first compute all these objects. Therefore iterators and enumerators come into the picture.

An iterator is a GAP object that gives a user friendly way to loop over all elements without repetition. Only three operations are applicable on an iterator: `NextIterator`, `IsDoneIterator` and `ShallowCopy`. Clearly, all elements of a collection can be obtained by using an available iterator.

##### 3.5-1 Iterator

`‣ Iterator`( C ) | ( operation )

Returns: an iterator for the collection C

C is a collection of elements of an incidence structure. An iterator is returned. The second example demonstrates how an iterator is used by `First`. Clearly, not all points of the projective space are computed.

    gap> ps := PG(3,7);
    ProjectiveSpace(3, 7)
    gap> planes := Planes(ps);
    <planes of ProjectiveSpace(3, 7)>
    gap> iter := Iterator(planes);
    <iterator>
    gap> NextIterator(iter);
    <a plane in ProjectiveSpace(3, 7)>
    gap> IsDoneIterator(iter);
    false

    gap> pg := PG(12,81);
    ProjectiveSpace(12, 81)
    gap> pts := Points(pg);
    <points of ProjectiveSpace(12, 81)>
    gap> Size(pts);
    80763523615333416236653
    gap> ps := ParabolicQuadric(12,81);
    Q(12, 81)
    gap> First(pts,x->x in ps);
    <a point in ProjectiveSpace(12, 81)>
    gap> time;
    23

In its simplest form, an enumerator is just a list containing all the elements of the collection. Given any object in the list, it is possible to retrieve its number in the list (which is then just its position). Also, given any number between 1 and the length of the list, it is possible to get the corresponding element. For some collections of elements of particular incidence structures, a more advanced version of enumerators is implemented. Such an advanced version is an object containing the two functions `ElementNumber` and `NumberElement`. Such functions are able to compute directly, without listing all elements, the element with a given number, or, conversely, compute directly the number of a given element. Clearly, using an enumerator, it is possible to obtain a list containing all elements of a collection.

##### 3.5-2 Enumerator

`‣ Enumerator`( C ) | ( operation )

Returns: an enumerator for the collection C

C is a collection of elements of an incidence structure. An enumerator is returned. The second example demonstrates how an enumerator is used by `Random`. Clearly, not all points of the polar space are to obtain an random point.

    gap> lines := Lines( ParabolicQuadric(6,3) );
    <lines of Q(6, 3)>
    gap> enum := Enumerator( lines );
    EnumeratorOfSubspacesOfClassicalPolarSpace( <lines of Q(6, 3)> )
    gap> s := Size(enum);
    3640
    gap> n := Random([1..s]);
    3081
    gap> l := enum[n];
    <a line in Q(6, 3)>
    gap> Position(enum, l);
    3081

    gap> ps := ParabolicQuadric(16,7^4);
    Q(16, 2401)
    gap> pts := Points(ps);
    <points of Q(16, 2401)>
    gap> Size(pts);
    508233536514931541724405776067904925314839705888016
    gap> Random(pts);
    <a point in Q(16, 2401)>
    gap> time;
    565

When an iterator or enumerator is installed for a collection, `List` can be used to obtain all objects in that collection.

##### 3.5-3 List

`‣ List`( C ) | ( operation )

Returns: all objects in the collection C

    gap> pg := PG(2,2);
    ProjectiveSpace(2, 2)
    gap> List(Points(pg));
    [ <a point in ProjectiveSpace(2, 2)>, <a point in ProjectiveSpace(2, 2)>,
      <a point in ProjectiveSpace(2, 2)>, <a point in ProjectiveSpace(2, 2)>,
      <a point in ProjectiveSpace(2, 2)>, <a point in ProjectiveSpace(2, 2)>,
      <a point in ProjectiveSpace(2, 2)> ]
    gap> List(Lines(pg));
    [ <a line in ProjectiveSpace(2, 2)>, <a line in ProjectiveSpace(2, 2)>,
      <a line in ProjectiveSpace(2, 2)>, <a line in ProjectiveSpace(2, 2)>,
      <a line in ProjectiveSpace(2, 2)>, <a line in ProjectiveSpace(2, 2)>,
      <a line in ProjectiveSpace(2, 2)> ]
    gap> ps := ParabolicQuadric(6,2);
    Q(6, 2)
    gap> lines := List(Lines(ps));
    [ <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)> ]
    gap> time;
    3661
    gap> Size(lines);
    315

From the example in 3.5-3 it can be noted that although the number of lines is only 315, already 3 seconds of computing time are needed. This is typically observed for elements of classical polar spaces different from points or generators, and is explained by the recursive nature of the implementation of the enumerator. Computing a list of these objects as an orbit under the collineation group is, even taking into account the computation of the nice monomorphism of the collineation group, often much faster. Given a collection C, the function `AsList` performs this computation using the collineation group.

##### 3.5-4 AsList

`‣ AsList`( C ) | ( operation )

Returns: an ORB object containing all objects in C

The returned object is an ORB object. All objects can easily be obtained by applying the operation `List`.

    gap> ps := ParabolicQuadric(6,2);
    Q(6, 2)
    gap> lines := AsList(Lines(ps));
    <closed orbit, 315 points>
    gap> time;
    58
    gap> List(lines);
    [ <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)>,
      <a line in Q(6, 2)>, <a line in Q(6, 2)>, <a line in Q(6, 2)> ]
    gap> time;
    1

#### 3.6 Lie geometries

##### 3.6-1 Main categories in `IsLieGeometry`

`‣ IsProjectiveSpace` | ( category )

`‣ IsClassicalPolarSpace` | ( category )

In FinInG, a Lie geometry \(G\) refers to a geometry whose automorphism group is a (subgroup of a) group of Lie type. Generally spoken, one could say that a Lie geometry is an incidence geometry, such that each element of type \(i\) is represented by a sub space of dimension \(i+1\) of a vector space \(V\). The projective space \(P\) associated with \(V\) is naturally the ambient space of \(G\). However, as one may also consider subspaces of the given vector space over subfields of the ground field of \(V\), one cannot not just say that the set of elements of \(G\) of a given type \(i\), is a subset of the set of elements of type \(i\) of \(P\). Geometrically, this means that embeddings may be full or not, i.e. when a line of a Lie geometry is embedded into \(P\) as a line \(l\), the embedding is full only if all projective points of \(l\) have a pre image in \(G\). Embeddings of finite classical polar spaces are full, and indeed the set of elements of type \(i\) is a proper subset of the set of elements of type \(i\) of \(P\). Subgeometries of projective spaces behave differently, and indeed, a line of a subgeometry can be embedded into \(P\), but will not be identified with a line of \(P\). All geometries in FinInG that have a projective space as ambient space, belong to a subcategory of `IsLieGeometry`.

One common fact of Lie geometries is that their elements are represented by subspaces of a vector space. In these geometries, incidence is symmetrized set-theoretic containment. In this section we describe methods that are declared in a generic way for (elements of) Lie geometries. These operations are applicable to Lie geometries and related objects.

##### 3.6-2 AmbientSpace

`‣ AmbientSpace`( ig ) | ( attribute )

Returns: the ambient projective space of a Lie geometry ig

    gap> AmbientSpace(PG(3,4));
    ProjectiveSpace(3, 4)
    gap> AmbientSpace(ParabolicQuadric(4,4));
    ProjectiveSpace(4, 4)
    gap> AmbientSpace(SplitCayleyHexagon(3));
    ProjectiveSpace(6, 3)

##### 3.6-3 UnderlyingVectorSpace

`‣ UnderlyingVectorSpace`( ig ) | ( operation )

Returns: the underlying vector space of the Lie geometry ig

    gap> UnderlyingVectorSpace(PG(5,4));
    ( GF(2^2)^6 )
    gap> UnderlyingVectorSpace(HermitianPolarSpace(4,4));
    ( GF(2^2)^5 )

##### 3.6-4 ProjectiveDimension

`‣ ProjectiveDimension`( ig ) | ( operation )

Returns: the projective dimension of the ambient projective space of ig

    gap> ProjectiveDimension(PG(7,7));
    7
    gap> ProjectiveDimension(EllipticQuadric(5,2));
    5

Mathematically, it makes sense to implement an object representing the empty subspace, since this is typically obtained as a result of a Meet operation, which computes the intersection of two or more elements. On the other hand, we do not consider the empty subspace as an element of the incidence geometry. Hence, using the empty subspace as an argument of `IsIncident` (and consequently of `\*`), will result in a ``no method found'' error.

##### 3.6-5 IsEmptySubspace

`‣ IsEmptySubspace` | ( category )

Category for objects representing the empty subspace of a particular Lie geometry. Empty subspaces of different geometries will be different objects, and have a different ambient geometry.

#### 3.7 Elements of Lie geometries

Elements of a Lie geometry are constructed using a list of vectors. The methods installed for the particular Lie geometries check whether the subspace of the vector space represents an element of the Lie geometry.

##### 3.7-1 VectorSpaceToElement

`‣ VectorSpaceToElement`( ig, v ) | ( operation )

`‣ VectorSpaceToElement`( ig, l ) | ( operation )

Returns: the element of ig, represented by the subspace spanned by v or l, or returns the empty subspace.

The first variant of this operation takes as second argument a vector of the underlying vector space of ig. Such a vector possibly represents a point of ig. The second variant takes as second argument a list of vectors in the underlying vector space of ig. Such a list represents a subspace of the vector space. If the dimension of the subspace generated by l is larger than zero and strictly less than the dimension of the vector space, it is checked if the subspace represents an element of ig, except when ig is a projective space. If l is a list of vectors generating the whole vector space, then ig is returned if and only if ig is a projective space, otherwise an error is produced. An empty list is not allowed as second argument.

    gap> v := [1,1,1,0,0,0]*Z(7)^0;
    [ Z(7)^0, Z(7)^0, Z(7)^0, 0*Z(7), 0*Z(7), 0*Z(7) ]
    gap> w := [0,0,0,1,1,1]*Z(7)^0;
    [ 0*Z(7), 0*Z(7), 0*Z(7), Z(7)^0, Z(7)^0, Z(7)^0 ]
    gap> VectorSpaceToElement(PG(5,7),v);
    <a point in ProjectiveSpace(5, 7)>
    gap> VectorSpaceToElement(PG(5,7),[v,w]);
    <a line in ProjectiveSpace(5, 7)>
    gap> VectorSpaceToElement(SymplecticSpace(5,7),v);
    <a point in W(5, 7)>
    gap> VectorSpaceToElement(SymplecticSpace(5,7),[v,w]);
    Error, <x> does not generate an element of <geom> called from
    <function "unknown">( <arguments> )
     called from read-eval loop at line 13 of *stdin*
    you can 'quit;' to quit to outer loop, or
    you can 'return;' to continue
    brk> quit;
    gap> VectorSpaceToElement(HyperbolicQuadric(5,7),v);
    Error, <v> does not generate an element of <geom> called from
    <function "unknown">( <arguments> )
     called from read-eval loop at line 13 of *stdin*
    you can 'quit;' to quit to outer loop, or
    you can 'return;' to continue
    brk> quit;
    gap> VectorSpaceToElement(HyperbolicQuadric(5,7),0*v);
    < empty subspace >

##### 3.7-2 UnderlyingObject

`‣ UnderlyingObject`( v ) | ( operation )

Returns: a CVEC object, which is the vector or matrix representing the element v

The argument v must be an element, so it is not allowed that v is the empty subspace, or just a projective space. Note that `Unpack` can be used to convert the CVEC object into a usual GAP vector or matrix.

    gap> l := Random(Lines(PG(4,3)));
    <a line in ProjectiveSpace(4, 3)>
    gap> UnderlyingObject(l);
    <cmat 2x5 over GF(3,1)>
    gap> Unpack(last);
    [ [ Z(3)^0, Z(3), 0*Z(3), 0*Z(3), Z(3) ],
      [ 0*Z(3), 0*Z(3), Z(3)^0, Z(3)^0, 0*Z(3) ] ]

##### `3.7-3 \in`

`‣ \in`( u, v ) | ( operation )

Returns: true if and only if the element u is set-theoretically contained in the element w

Both arguments must be elements of the same Lie geometry. The empty subspace and a Lie geometry are also allowed as arguments. This relation is not symmetric, and the methods for `IsIncident` use this method to test incidence between elements.

    gap> p := VectorSpaceToElement(PG(3,3),[1,0,0,0]*Z(3)^0);
    <a point in ProjectiveSpace(3, 3)>
    gap> l := VectorSpaceToElement(PG(3,3),[[1,0,0,0],[0,1,0,0]]*Z(3)^0);
    <a line in ProjectiveSpace(3, 3)>
    gap> p in l;
    true
    gap> p in p;
    true
    gap> l in p;
    false
    gap> l in PG(3,3);
    true

##### 3.7-4 More short names for `ElementsIncidentWithElementOfIncidenceStructure`

`‣ Hyperplanes`( inc, v ) | ( operation )

`‣ Hyperplanes`( v ) | ( operation )

Returns: the elements of type \(j-1\) incident with v, which is an element of type \(j\)

This operation is a shortcut to the operation `ShadowOfElement`, where the geometry is taken from v, and where the elements of type one less than the type of v are asked. v is allowed to be a complete projective space here, yielding the hyperplanes of that space.

    gap> pg := PG(3,7);
    ProjectiveSpace(3, 7)
    gap> hyp := Random(Hyperplanes(pg));
    <a plane in ProjectiveSpace(3, 7)>
    gap> h1 := Random(Hyperplanes(hyp));
    <a line in ProjectiveSpace(3, 7)>
    gap> h2 := Random(Hyperplanes(h1));
    <a point in ProjectiveSpace(3, 7)>
    gap> ps := SymplecticSpace(7,3);
    W(7, 3)
    gap> solid := Random(Solids(ps));
    <a solid in W(7, 3)>
    gap> plane := Random(Hyperplanes(solid));
    <a plane in W(7, 3)>

#### 3.8 Changing the ambient geometry of elements of a Lie geometry

A Lie geometry, i.e., an object in the category `IsLieGeometry`, is naturally embedded in a projective space. This is of course in a mathematical sense. In FinInG, certain embeddings are implemented by providing a mapping between geometries. The Lie geometries are in some sense hard wired embedded, just simply because a category containing elements of a Lie geometry, is always a subcategory of `IsSubspaceOfProjectiveSpace`. As a consequence, operations applicable to objects in the category `IsSubspaceOfProjectiveSpace` are by default applicable to objects in any subcategory, so to elements of any Lie geometry. When dealing with elements of e.g. different polar spaces in the same projective space, this yields a natural way of working with them, and investigating relations between them, without bothering about all necessary mappings. On the other hand, in some situations, it is impossible to decide in which geometry an element has to be considered. An easy example is the following. Consider two different quadrics in the same projective space. The intersection of two elements, one of each quadric, is clearly an element of the ambient projective space. But also of both quadrics. Without extra input of the user, the system cannot decide in which geometry to construct the intersection. To avoid complicated methods with many arguments, in such situations, the resulting element will be constructed in the common ambient projective space. Only in clear situations, where the ambient geometry of all elements is the same, and equal to the geometry of the resulting element, the resulting element will be constructed in this common geometry. We provide however conversion operations for elements of Lie geometries.

##### 3.8-1 ElementToElement

`‣ ElementToElement`( ps, el ) | ( operation )

`‣ Embed`( ps, el ) | ( operation )

Returns: el as an element of ps

Let ps be any Lie geometry. This method returns `VectorSpaceToElement(ps,ElementToVectorSpace(el))`, if the conversion is possible. `Embed` is declared as a synonym of `ElementToElement`.

    gap> p := VectorSpaceToElement(PG(3,7),[0,1,0,0]*Z(7)^0);
    <a point in ProjectiveSpace(3, 7)>
    gap> q := ElementToElement(HyperbolicQuadric(3,7),p);
    <a point in Q+(3, 7)>
    gap> r := VectorSpaceToElement(PG(3,7),[1,1,0,0]*Z(7)^0);
    <a point in ProjectiveSpace(3, 7)>
    gap> ElementToElement(HyperbolicQuadric(3,7),r);
    Error, <v> does not generate an element of <geom> called from
    VectorSpaceToElement( geom, Unpack( v ) ) called from
    VectorSpaceToElement( ps, UnderlyingObject( el ) ) called from
    <function "unknown">( <arguments> )
     called from read-eval loop at line 11 of *stdin*
    you can 'quit;' to quit to outer loop, or
    you can 'return;' to continue
    brk> quit;

[Top of Book] [Contents] [Previous Chapter] [Next Chapter]
Goto Chapter: Top 1 2 3 4 5 6 7 8 9 10 11 12 13 14 A B C Bib Ind

generated by GAPDoc2HTML