  
  [1X14 [33X[0;0YFundamental domains for Bianchi groups[133X[101X
  
  
  [1X14.1 [33X[0;0YBianchi groups[133X[101X
  
  [33X[0;0YThe  [13XBianchi  groups[113X are the groups [22XG_-d=PSL_2(cal O_-d)[122X where [22Xd[122X is a square
  free  positive integer and [22Xcal O_-d[122X is the ring of integers of the imaginary
  quadratic field [22XQ(sqrt-d)[122X. These groups act on [13Xupper-half space[113X[133X
  
  
  [24X[33X[0;6Y{\frak h}^3 =\{(z,t) \in \mathbb C\times \mathbb R\ |\ t > 0\}[133X
  
  [124X
  
  [33X[0;0Yby the formula[133X
  
  
  [24X[33X[0;6Y\left(\begin{array}{ll}a&b\\  c  &d  \end{array}\right)\cdot  (z+tj)  \  = \
  \left(a(z+tj)+b\right)\left(c(z+tj)+d\right)^{-1}\[133X
  
  [124X
  
  [33X[0;0Ywhere  we  use the symbol [22Xj[122X satisfying [22Xj^2=-1[122X, [22Xij=-ji[122X and write [22Xz+tj[122X instead
  of [22X(z,t)[122X. Alternatively, the action is given by[133X
  
  
  [24X[33X[0;6Y\left(\begin{array}{ll}a&b\\  c  &d  \end{array}\right)\cdot  (z+tj)  \  = \
  \frac{(az+b)\overline{(cz+d)  }  + a\overline c t^2}{|cz +d|^2 + |c|^2t^2} \
  +\ \frac{t}{|cz+d|^2+|c|^2t^2}\, j \ .[133X
  
  [124X
  
  [33X[0;0YWe  take  the  boundary  [22X∂  frak  h^3[122X to be the Riemann sphere [22XC ∪ ∞[122X and let
  [22Xoverlinefrak  h^3[122X  denote the union of [22Xfrak h^3[122X and its boundary. The action
  of  [22XG_-d[122X  extends  to  the  boundary.  The element [22X∞[122X and each element of the
  number  field  [22XQ(sqrt-d)[122X  are thought of as lying in the boundary [22X∂ frak h^3[122X
  and  are  referred  to as [13Xcusps[113X. Let [22XX[122X denote the union of [22Xfrak h^3[122X with the
  set  of cusps, [22XX=frak h^3 ∪ {∞} ∪ Q(sqrt-d)[122X. It follows from work of Bianchi
  and  Humbert  that  the space [22XX[122X admits the structure of a regular CW-complex
  (depending  on  [22Xd[122X)  for  which  the  action of [22XG_-d[122X on [22Xfrak h^3[122X extends to a
  cellular  action on [22XX[122X which permutes cells. Moreover, [22XG_-d[122X acts transitively
  on  the [22X3[122X-cells of [22XX[122X and each [22X3[122X-cell has trivial stabilizer in [22XG_-d[122X. Details
  are provided in Richard Swan's paper [Swa71b].[133X
  
  [33X[0;0YWe  refer  to  the closure in [22XX[122X of any one of these [22X3[122X-cells as a [13Xfundamental
  domain[113X  for  the  action  [22XG_-d[122X.  Cohomology  of  [22XG_-d[122X can be computed from a
  knowledge of the combinatorial structure of this fundamental domain together
  with a knowledge of the stabilizer groups of the cells of dimension [22X≤ 2[122X.[133X
  
  
  [1X14.2 [33X[0;0YSwan's description of a fundamental domain[133X[101X
  
  [33X[0;0YA  pair  [22X(a,b)[122X of elements in [22Xcal O_-d[122X is said to be [13Xunimodular[113X if the ideal
  generated by [22Xa,b[122X is the whole ring [22Xcal O_-d[122X and [22Xane 0[122X. A unimodular pair can
  be  represented by a hemisphere in [22Xoverlinefrak h^3[122X with base centred at the
  point [22Xb/a ∈ C[122X and of radius [22X|1/a|[122X. The radius is [22X≤ 1[122X. Think of the points in
  [22Xfrak  h^3[122X  as  lying  strictly  above  [22XC[122X. Let [22XB[122X denote the space obtained by
  removing the interiors of all such hemispheres from [22Xfrak h^3[122X.[133X
  
  [33X[0;0YWhen [22Xd ≡ 3 mod 4[122X let [22XF[122X be the subspace of [22Xoverlinefrak h^3[122X consisting of the
  points  [22Xx+iy+jt[122X with [22X-1/2 ≤ x ≤ 1/2[122X, [22X-1/4 ≤ y ≤ 1/4[122X, [22Xt ≥ 0[122X. Otherwise, let [22XF[122X
  be  the  subspace  of [22Xoverlinefrak h^3[122X consisting of the points [22Xx+iy+jt[122X with
  [22X-1/2 ≤ x ≤ 1/2[122X, [22X-1/2 ≤ y ≤ 1/2[122X, [22Xt ≥ 0[122X.[133X
  
  [33X[0;0YIt  is  explained  in  [Swa71b] that [22XF∩ B[122X is a [22X3[122X-cell in the above mentioned
  regular CW-complex structure on [22XX[122X.[133X
  
  
  [1X14.3 [33X[0;0YComputing a fundamental domain[133X[101X
  
  [33X[0;0YExplicit  fundamental  domains  for  certain  values of [22Xd[122X were calculated by
  Bianchi  in  the  1890s  and  further calculations were made by Swan in 1971
  [Swa71b].   In   the   1970s,   building   on   Swan's  work,  Robert  Riley
  ([7Xhttps://www.sciencedirect.com/science/article/pii/S0723086913000042[107X)
  developed  a  computer  program for computing fundamental domains of certain
  Kleinian  groups  (including  Bianchi  groups).  In  their  2010  PhD theses
  Alexander Rahm ([7Xhttps://theses.hal.science/tel-00526976/en/[107X) and M.T. Aranes
  ([7Xhttps://wrap.warwick.ac.uk/id/eprint/35128/[107X)     independently    developed
  Pari/GP  and  Sage  software  based  on  Swan's  ideas.  In  2011 Dan Yasaki
  ([7Xhttps://mathstats.uncg.edu/sites/yasaki/publications/bianchipolytope.pdf[107X)
  used  a different approach based on Voronoi's theory of perfect forms in his
  Magma  software  for  fundamental  domains  of  Bianchi  groups.  Aurel Page
  ([7Xhttp://www.normalesup.org/~page/Recherche/Logiciels/logiciels-en.html[107X)
  developed  software  for  fundamental domains of Kleinian groups in his 2010
  masters       thesis.       In       2018       Sebastian      Schoennenbeck
  ([7Xhttps://github.com/schoennenbeck/VMH-DivisionAlgebras[107X)  used a more general
  approach  based  on  perfect  forms  in  his  Magma  software  for computing
  fundamental  domains  of  Bianchi  and other groups. Output from the code of
  Alexander  Rahm  and  Sebastian Schoennenbeck for certain Bianchi groups has
  been stored iin [12XHAP[112X for use in constructing free resolutions.[133X
  
  [33X[0;0YMore  recently a [12XGAP[112X implementation of Swan's algorithm has been included in
  [12XHAP[112X.  The  implementation  uses  exact  computations  in  [22XQ(sqrt-d)[122X  and  in
  [22XQ(sqrtd)[122X.  A  bespoke  implementation  of  these  two  fields is part of the
  implementation  so  as  to  avoid making apparently slower computations with
  cyclotomic  numbers.  The  account  of  Swan's  algorithm  in  the thesis of
  Alexander Rahm was the main reference during the implementation.[133X
  
  
  [1X14.4 [33X[0;0YExamples[133X[101X
  
  [33X[0;0YThe  fundamental domain [22XD=overlineF ∩ B[122X (where the overline denotes closure)
  has boundary [22X∂ D[122X involving the four vertical quadrilateral [22X2[122X-cells contained
  in  the four vertical quadrilateral [22X2[122X-cells of [22X∂ F[122X. We refer to these as the
  [13Xvertical  [22X2[122X-cells[113X of [22XD[122X. When visualizing [22XD[122X we ignore the [22X3[122X-cell and the four
  vertical  [22X2[122X-cells  entirely  and visualize only the remaining [22X2[122X-cells. These
  [22X2[122X-cells  can  be viewed as a [22X2[122X-dimensional image by projecting them onto the
  complex plane, or they can be viewed as an interactive [22X3[122X-dimensional image.[133X
  
  [33X[0;0YA  fundamental  domain  for  [22XG_-39[122X  can  be  visualized  using the following
  commands.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD:=BianchiPolyhedron(-39);[127X[104X
    [4X[28X3-dimensional Bianchi polyhedron over OQ( Sqrt(-39) ) [128X[104X
    [4X[28Xinvolving hemispheres of minimum squared radius 1/39 [128X[104X
    [4X[28Xand non-cuspidal vertices of minimum squared height 1/49 . [128X[104X
    [4X[28X[128X[104X
    [4X[25Xgap>[125X [27XDisplay3D(D);;[127X[104X
    [4X[25Xgap>[125X [27XDisplay2D(D);;[127X[104X
    [4X[28X[128X[104X
  [4X[32X[104X
  
  [33X[0;0YA  [13Xcusp  vertex[113X  of  [22XD[122X  is  any  vertex  of  [22XD[122X  lying in [22XC ∪ ∞[122X. In the above
  visualizations   for  [22XG_-39[122X  several  cusp  vertices  in  [22XC[122X  are  :  in  the
  2-dimensional  visualization  they  are  represented  by  red dots. Computer
  calculations  show  that these cusps lie in precisely three orbits under the
  action  of  [22XG_-d[122X. Thus, together with the orbit of [22X∞[122X there are four distinct
  orbits  of  cusps.  By the well-known correspondence between cusp orbits and
  elements of the class group it follows that the class group of [22XQ(sqrt-39)[122X is
  of order [22X4[122X.[133X
  
  [33X[0;0YThe  following  additional  commands  comvert  the Bianchi polyhedron [22XD[122X to a
  regular CW-complex and then display its [22X1[122X-skeleton.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD:=BianchiPolyhedron(-39);;[127X[104X
    [4X[25Xgap>[125X [27XY:=RegularCWComplex(D);[127X[104X
    [4X[28XRegular CW-complex of dimension 2[128X[104X
    [4X[28X[128X[104X
    [4X[25Xgap>[125X [27XDisplay(GraphOfRegularCWComplex(Y));[127X[104X
    [4X[28X[128X[104X
  [4X[32X[104X
  
  [33X[0;0YA  fundamental  domain  for  [22XG_-22[122X  can  be  visualized  using the following
  commands.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD:=BianchiPolyhedron(-22);;[127X[104X
    [4X[25Xgap>[125X [27XDisplay3D(OQ,D);;[127X[104X
    [4X[25Xgap>[125X [27XDisplay2D(OQ,D);;[127X[104X
    [4X[28X[128X[104X
  [4X[32X[104X
  
  [33X[0;0YTwo  cusps are visible in the visualizations for [22XG_-22[122X. They lie in a single
  orbit. Thus, together with the orbit of [22X∞[122X, there are two orbits of cusps for
  this group.[133X
  
  [33X[0;0YA  fundamental  domain  for  [22XG_-163[122X  can  be  visualized using the following
  commands.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD:=BianchiPolyhedron(-163);;[127X[104X
    [4X[25Xgap>[125X [27XDisplay3D(OQ,D);;[127X[104X
    [4X[25Xgap>[125X [27XDisplay2D(OQ,D);;[127X[104X
    [4X[28X[128X[104X
  [4X[32X[104X
  
  [33X[0;0YThere  is just a single orbit of cusps in this example, the orbit containing
  [22X∞[122X, since [22XQ(sqrt-163)[122X is a principal ideal domain and hence has trivial class
  group.[133X
  
  [33X[0;0YA fundamental domain for [22XG_-33[122X is visualized using the following commands.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD:=BianchiPolyhedron(-33);;[127X[104X
    [4X[25Xgap>[125X [27XDisplay3D(OQ,D);;[127X[104X
    [4X[25Xgap>[125X [27XDisplay2D(OQ,D);;[127X[104X
    [4X[28X[128X[104X
  [4X[32X[104X
  
  
  [1X14.5 [33X[0;0YEstablishing correctness of a fundamental domain[133X[101X
  
  [33X[0;0YThe  cusps  of  a  fundamental domain can be calculated independently of the
  domain  computation. The remaining vertices of the domain will have positive
  heights.  To prove that the computation is correct we need to establish that
  no  non-cuspidal  vertex  lies  below any hemishpere centered on the complex
  plane  at  [22Xb/a∈  C[122X  with  [22X(a,b)[122X a unimodular pair. As these hemispheres have
  increasingly  smaller  radius  we  only  need  to  check those finitely many
  hemispheres  with  radius smaller than the height of the lowest non-cuspidal
  vertex.[133X
  
  [33X[0;0YFor  a few values of [22Xd[122X the smallest radius [22Xr[122X of a hemisphere contributing to
  the  fundamental  domain  boundary  has  been  stored.  For cases where this
  smallest  radius  is  not  stored  a  very  slow  method  for  finding  [22Xr[122X is
  implemented  and the user is advised to speed things up by guessiing a value
  [22XN=1/r^2[122X  and  then  test  that  this  value of [22XN[122X is indeed large enough. The
  following commands illustrate this for [22Xd=-46[122X with a guess of [22XN=600[122X. Once the
  test  is  done  we  can see that in fact a smaller guess of [22XN=441[122X would have
  sufficed.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XP:=BianchiPolyhedron(-46);[127X[104X
    [4X[28XTry [128X[104X
    [4X[28X  P:=BianchiPolyhedron(OQ,N);[128X[104X
    [4X[28Xfor some guessed positive integer value of N and then try[128X[104X
    [4X[28X  SwanBianchiCriterion(P);[128X[104X
    [4X[28Xto test if the value of N was large enough. If the test returns false then you\[128X[104X
    [4X[28X'll need to try a larger value of N.[128X[104X
    [4X[28X[128X[104X
    [4X[28XA successful value of N can be stored as a pair [d,N] in the list HAPRECORD wh\[128X[104X
    [4X[28Xich can be edited manually in the file hap/lib/Congruence/bianchi.gi .[128X[104X
    [4X[28X[128X[104X
    [4X[28X[128X[104X
    [4X[25Xgap>[125X [27XP:=BianchiPolyhedron(-46,600);[127X[104X
    [4X[28X3-dimensional Bianchi polyhedron over OQ( Sqrt([128X[104X
    [4X[28X-46) ) involving hemispheres of minimum squared radius 1/[128X[104X
    [4X[28X441 and non-cuspidal vertices of minimum squared height 1/8280 . [128X[104X
    [4X[28X[128X[104X
    [4X[25Xgap>[125X [27XSwanBianchiCriterion(P);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[28X[128X[104X
  [4X[32X[104X
  
  
  [1X14.6 [33X[0;0YComputing a free resolution for [22XSL_2(mathcal O_-d)[122X[101X[1X[133X[101X
  
  [33X[0;0YThe  above fundamental domains can be used to construct free resolutions for
  [22XSL_2(mathcal   O_-d)[122X   and   [22XPSL_2(mathcal  O_-d)[122X.  The  following  commands
  illustrate  the  computation of free resolutions for [22XSL_2(mathcal O_-43)[122X and
  [22XSL_2(mathcal  O_-10)[122X  and  [22XSL_2(mathcal  O_-14)[122X  and their integral homology
  (which  in  each  case is periodic of period dividing [22X4[122X in degrees [22X≥ 3[122X). The
  computation  of  fundamental  domains uses exact arithmetic in the two field
  extensions [22XQ(sqrtd)[122X and [22XQ(sqrt-d)[122X.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XK:=BianchiGcomplex(-43);;[127X[104X
    [4X[25Xgap>[125X [27XR:=FreeGResolution(K,11);;[127X[104X
    [4X[25Xgap>[125X [27XC:=TensorWithIntegers(R);;[127X[104X
    [4X[25Xgap>[125X [27XList([0..10],n->Homology(C,n));[127X[104X
    [4X[28X[ [ 0 ], [ 0, 0 ], [ 2, 2, 12, 0 ], [ 2, 2, 24 ], [ 2, 2 ], [ 2 ], [128X[104X
    [4X[28X  [ 2, 2, 12 ], [ 2, 2, 24 ], [ 2, 2 ], [ 2 ], [ 2, 2, 12 ] ][128X[104X
    [4X[28X[128X[104X
    [4X[25Xgap>[125X [27XK:=BianchiGcomplex(-10);;[127X[104X
    [4X[25Xgap>[125X [27XR:=FreeGResolution(K,11);;[127X[104X
    [4X[25Xgap>[125X [27XList([0..10],k->Homology(TensorWithIntegers(R),k));[127X[104X
    [4X[28X[ [ 0 ], [ 2, 2, 0, 0, 0 ], [ 2, 2, 2, 12, 0, 0 ], [ 2, 2, 2, 24 ], [128X[104X
    [4X[28X  [ 2, 4, 12 ], [ 2, 2, 2, 6 ], [ 2, 2, 2, 12 ], [ 2, 2, 2, 24 ], [128X[104X
    [4X[28X  [ 2, 4, 12 ], [ 2, 2, 2, 6 ], [ 2, 2, 2, 12 ] ][128X[104X
    [4X[28X[128X[104X
    [4X[25Xgap>[125X [27XK:=BianchiGcomplex(-14);;[127X[104X
    [4X[25Xgap>[125X [27XR:=FreeGResolution(K,11);;[127X[104X
    [4X[25Xgap>[125X [27XList([0..10],k->Homology(TensorWithIntegers(R),k));[127X[104X
    [4X[28X[ [ 0 ], [ 6, 0, 0, 0, 0, 0 ], [ 2, 2, 2, 4, 12, 0, 0, 0, 0 ], [128X[104X
    [4X[28X  [ 2, 2, 2, 2, 24 ], [ 2, 2, 2, 4, 12 ], [ 2, 2, 2, 2, 24 ], [128X[104X
    [4X[28X  [ 2, 2, 2, 4, 12 ], [ 2, 2, 2, 2, 24 ], [ 2, 2, 2, 4, 12 ], [128X[104X
    [4X[28X  [ 2, 2, 2, 2, 24 ], [ 2, 2, 2, 4, 12 ] ][128X[104X
    [4X[28X[128X[104X
  [4X[32X[104X
  
  [33X[0;0YThe  following  commands count the number of orbits of cusps (in addition to
  the  orbit  of [22X∞[122X). They determine that there is precisely one element in the
  ideal  class group of [22Xmathcal O_-43[122X (i.e it is a principal ideal domain) and
  that  there  are  precisely two elements in the ideal class group of [22Xmathcal
  O_-10[122X and precisely four elements in the ideal class group of [22Xmathcal O_-14[122X.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XK:=BianchiGcomplex(-43);;[127X[104X
    [4X[25Xgap>[125X [27XList([1..K!.dimension(0)],k->Order(K!.stabilizer(0,k)));[127X[104X
    [4X[28X[ 24, 24, 6, 6, 4, 4, 12, 12 ][128X[104X
    [4X[28X[128X[104X
    [4X[25Xgap>[125X [27XK:=BianchiGcomplex(-10);;[127X[104X
    [4X[25Xgap>[125X [27XList([1..K!.dimension(0)],k->Order(K!.stabilizer(0,k)));[127X[104X
    [4X[28X[ 6, 6, 4, 4, 6, infinity ][128X[104X
    [4X[28X[128X[104X
    [4X[25Xgap>[125X [27XK:=BianchiGcomplex(-14);;[127X[104X
    [4X[25Xgap>[125X [27XList([1..K!.dimension(0)],k->Order(K!.stabilizer(0,k)));[127X[104X
    [4X[28X[ 6, 6, 2, 2, 2, infinity, infinity, 2, infinity, 6, 4 ][128X[104X
    [4X[28X[128X[104X
  [4X[32X[104X
  
  
  [1X14.7 [33X[0;0YSome sanity checks[133X[101X
  
  [33X[0;0YThere  is ample scope for bugs in the implementation of the above method for
  computing  resolutions  of  Bianchi groups. The following sanity checks lend
  confidence to the implementation.[133X
  
  
  [1X14.7-1 [33X[0;0YEquivariant Euler characteristic[133X[101X
  
  [33X[0;0YLet  [22XX[122X  be  any cell complex with an action of a group [22XG[122X such that (i) [22XX[122X has
  finitely  many  [22XG[122X-orbits of cells, and (ii) the stabilizer subgroup in [22XG[122X for
  each  cell  is  either  finite  or free abelian. One defines the [13Xequivariant
  Euler  characteristic[113X  $$\chi_G(X)  =  \sum_e  (-1)^{dim~ e} / |Stab_G(e)|$$
  where  [22Xe[122X  ranges  over a set of representatives of the orbits of those cells
  with  finite  stabilizers. If [22XG[122X has a finite index torsion free subgroup and
  if   the   complex   [22XX[122X  is  contractible  then  one  can  define  the  Euler
  characteristic  of  the  group  to  be  [22Xχ(G)  =  χ_G(X)[122X.  It is known that [22Xχ
  (SL_n(mathcal O)) = χ(GL_n(mathcal O)) =0[122X for [22Xmathcal O[122X the ring of integers
  of a number field [DSGG+16].[133X
  
  [33X[0;0YOne  easy  test to make in our computations is to check that the equivariant
  Euler characteristic of the [22X2[122X-complex is indeed zero. The following commands
  perform this test for the group [22XSL_2(mathcal O_-23)[122X.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XK:=BianchiGcomplex(-23);;[127X[104X
    [4X[28X[128X[104X
    [4X[25Xgap>[125X [27Xchi:=0;;[127X[104X
    [4X[25Xgap>[125X [27Xfor n in [0..2] do[127X[104X
    [4X[25X>[125X [27Xfor k in [1..K!.dimension(n)] do[127X[104X
    [4X[25X>[125X [27Xg:=Order(K!.stabilizer(n,k));[127X[104X
    [4X[25X>[125X [27Xif g < infinity then chi:=chi + (-1)^n/g; fi;[127X[104X
    [4X[25X>[125X [27Xod;od;[127X[104X
    [4X[25Xgap>[125X [27Xchi;[127X[104X
    [4X[28X0[128X[104X
    [4X[28X[128X[104X
  [4X[32X[104X
  
  
  [1X14.7-2 [33X[0;0YBoundary squares to zero[133X[101X
  
  [33X[0;0YThe  signs in the boundary maps of the free resolution are delicate. Another
  easy  test  is to check that the boundary in the resolution squares to zero.
  The following commands perform this check for the group [22XSL_2(mathcal O_-23)[122X.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XK:=BianchiGcomplex(-23);;[127X[104X
    [4X[25Xgap>[125X [27XR:=FreeGResolution(K,10);;[127X[104X
    [4X[25Xgap>[125X [27Xn:=2;;List([1..R!.dimension(n)],k->ResolutionBoundaryOfWord(R,n-1,R!.boundary(n,k)));[127X[104X
    [4X[28X[ [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [128X[104X
    [4X[28X  [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [128X[104X
    [4X[28X  [  ], [  ], [  ] ][128X[104X
    [4X[25Xgap>[125X [27Xn:=3;;List([1..R!.dimension(n)],k->ResolutionBoundaryOfWord(R,n-1,R!.boundary(n,k)));[127X[104X
    [4X[28X[ [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [128X[104X
    [4X[28X  [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [128X[104X
    [4X[28X  [  ], [  ], [  ] ][128X[104X
    [4X[25Xgap>[125X [27Xn:=4;;List([1..R!.dimension(n)],k->ResolutionBoundaryOfWord(R,n-1,R!.boundary(n,k)));[127X[104X
    [4X[28X[ [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [128X[104X
    [4X[28X  [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [128X[104X
    [4X[28X  [  ], [  ], [  ] ][128X[104X
    [4X[25Xgap>[125X [27Xn:=5;;List([1..R!.dimension(n)],k->ResolutionBoundaryOfWord(R,n-1,R!.boundary(n,k)));[127X[104X
    [4X[28X[ [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [128X[104X
    [4X[28X  [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [  ], [128X[104X
    [4X[28X  [  ], [  ], [  ] ][128X[104X
    [4X[28X[128X[104X
  [4X[32X[104X
  
  
  [1X14.7-3 [33X[0;0YCompare different algorithms or implementations[133X[101X
  
  [33X[0;0YSebastian  Schoennenbeck  in  his  thesis  work  computed  some contractible
  [22X2[122X-complexes  on  which Bianchi groups act with finite stabilizers (even when
  the  ideal  class  is  greater than [22X1[122X) using a different approach to that of
  Swan.  These computed complexes are stored in [12XHAP[112X and provide an alternative
  way  of  computing  cohomology  for the stored groups. Alexander Rahm in his
  thesis  work  implemented  Swan's approach and has provided some [22X2[122X-complexes
  that are also stored in [12XHAP[112X in cases where the ideal class is equal to [22X1[122X.[133X
  
  [33X[0;0YThe  following  commands  test  that Sebastian Schoennenbeck's [22X2[122X-complex for
  [22XSL_2(mathcal  O_-23)[122X  yields  the  same  integral  homology as the above [12XHAP[112X
  implementation.   Both  computations  use  [12XHAP[112X's  implementation  of  Wall's
  perturbation technique for computing the resolution from the [22X2[122X-complex.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XK:=ContractibleGcomplex("SL(2,O-23)");;[127X[104X
    [4X[25Xgap>[125X [27XR:=FreeGResolution(K,10);;[127X[104X
    [4X[25Xgap>[125X [27XList([0..9],n->Homology(TensorWithIntegers(R),n));[127X[104X
    [4X[28X[ [ 0 ], [ 12, 0, 0, 0 ], [ 2, 2, 12, 0, 0 ], [ 2, 2, 12 ], [ 2, 2, 12 ], [128X[104X
    [4X[28X  [ 2, 2, 12 ], [ 2, 2, 12 ], [ 2, 2, 12 ], [ 2, 2, 12 ], [ 2, 2, 12 ] ][128X[104X
    [4X[28X[128X[104X
    [4X[25Xgap>[125X [27XK:=BianchiGcomplex(-23);;[127X[104X
    [4X[25Xgap>[125X [27XR:=FreeGResolution(K,10);;[127X[104X
    [4X[25Xgap>[125X [27XList([0..9],n->Homology(TensorWithIntegers(R),n));[127X[104X
    [4X[28X[ [ 0 ], [ 12, 0, 0, 0 ], [ 2, 2, 12, 0, 0 ], [ 2, 2, 12 ], [ 2, 2, 12 ], [128X[104X
    [4X[28X  [ 2, 2, 12 ], [ 2, 2, 12 ], [ 2, 2, 12 ], [ 2, 2, 12 ], [ 2, 2, 12 ] ][128X[104X
    [4X[28X[128X[104X
  [4X[32X[104X
  
  
  [1X14.7-4 [33X[0;0YCompare geometry to algebra[133X[101X
  
  [33X[0;0YThe  number  of  cusps  (i.e. the number of orbits of vertices with infinite
  stabilizer  subgroup) must be precisely one less than the number of elements
  in  the ideal class group of [22Xmathcal O_-d[122X. The following commands check this
  for [22XSL_2(mathcal O_-23)[122X where [22Xmathcal O_-23[122X is known to have class number 3.
  (This class number is easily computed from a formula in Swan's paper.)[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XK:=BianchiGcomplex(-23);;[127X[104X
    [4X[25Xgap>[125X [27XList([1..K!.dimension(0)],k->Order(K!.stabilizer(0,k)));[127X[104X
    [4X[28X[ 6, 2, 2, 4, infinity, infinity ][128X[104X
    [4X[28X[128X[104X
  [4X[32X[104X
  
  [33X[0;0YA  visualization  of  the fundamental domain tells us a certain amount about
  the algebra. In the case of [22XSL_2(mathcal O_-23)[122X[133X
  
  [33X[0;0Ya  fundamental  domain  for  the  action  on  [22XC[122X  by the translation subgroup
  generated   by   the   matrices   $$   \left(\begin{array}{ll}   1   &1\\  0
  &1\end{array}\right),      \left(\begin{array}{ll}     1     &\omega\\     0
  &1\end{array}\right)  $$  [22Xω  =  (1+sqrt-23)/2[122X  is  indicated  by  the  white
  rectangle.  From  this  we  see that under the action of [22XSL_2(mathcal O_-23)[122X
  there  are  at  most  [22X11[122X  orbits  of  [22X2[122X-cells,  the  central decagon and ten
  quadrilaterals.  However,  the  matrix  $$ \left(\begin{array}{rr} 0 &-1\\ 1
  &0\end{array}\right)  $$  maps  [22X(z,0)[122X  to  [22X(-1/z,0)[122X  and  fixes  [22X(0,1)[122X. This
  isometry  identifies  points  on the boundary of the decagon pairwise. These
  observations  are  consistent  with  the  above  listing  of  the  six orbit
  stabilizers and the following algebraic information on the boundaries of the
  [22X2[122X-cells in the Bianchi [22X2[122X-complex.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XK:=BianchiGcomplex(-23);;[127X[104X
    [4X[25Xgap>[125X [27XList([1..K!.dimension(2)],k->Length(K!.boundary(2,k)));[127X[104X
    [4X[28X[ 10, 4, 4, 4, 4, 4 ][128X[104X
    [4X[28X[128X[104X
  [4X[32X[104X
  
  
  [1X14.8 [33X[0;0YGroup presentations[133X[101X
  
  [33X[0;0YSwan's  reason for studying fundamental domains was to obtain explicit group
  presentations  for [22XSL_2(mathcal O_-d)[122X for various values of [22Xd[122X. The following
  commands obtain a presentation for [22XSL_2(mathcal O_-23)[122X.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XK:=BianchiGcomplex(-23);;[127X[104X
    [4X[25Xgap>[125X [27XR:=FreeGResolution(K,2);;[127X[104X
    [4X[25Xgap>[125X [27XP:=PresentationOfResolution(R);[127X[104X
    [4X[25Xgap>[125X [27XG:=SimplifiedFpGroup(P!.freeGroup/P!.relators);[127X[104X
    [4X[28X<fp group on the generators [ k, r, s, w, x ]>[128X[104X
    [4X[25Xgap>[125X [27XRelatorsOfFpGroup(G);[127X[104X
    [4X[28X[ w^-1*k*w*k^-1, s^-1*r*s*r^-1, k^6, x^-1*k^-3*x*k^-3, s^-1*k^-3*s*k^-3, [128X[104X
    [4X[28X  r^-1*w*x^-1*s*r*w^-1*x*s^-1, r^-1*k^-3*r*k^-3, [128X[104X
    [4X[28X  x*k^-2*r^-1*x*r^-1*s^-1*k^-1*s^-1, x^-1*k^3*s*r*x^-1*s*r ][128X[104X
    [4X[28X[128X[104X
    [4X[25Xgap>[125X [27X#Next we identify the generators as matrices[127X[104X
    [4X[25Xgap>[125X [27XGeneratorsOfGroup(P!.freeGroup);[127X[104X
    [4X[28X[ k, m, n, p, q, r, s, t, u, v, w, x, y, z ][128X[104X
    [4X[25Xgap>[125X [27XP!.gens;[127X[104X
    [4X[28X[ 19, 6, 6, 20, 6, 21, 22, 6, 52, 53, 2, 50, 1, 4 ][128X[104X
    [4X[28X[128X[104X
    [4X[25Xgap>[125X [27Xk:=R!.elts[19];[127X[104X
    [4X[28X[ [ 1, 1 ], [128X[104X
    [4X[28X  [ -1, 0 ] ][128X[104X
    [4X[25Xgap>[125X [27Xr:=R!.elts[21];[127X[104X
    [4X[28X[ [ 3, 3 + -1 Sqrt(-23) ], [128X[104X
    [4X[28X  [ -3/2 + -1/2 Sqrt(-23), -5 ] ][128X[104X
    [4X[25Xgap>[125X [27Xs:=R!.elts[22];[127X[104X
    [4X[28X[ [ 2 + 1 Sqrt(-23), 13/2 + 1/2 Sqrt(-23) ], [128X[104X
    [4X[28X  [ 5/2 + -1/2 Sqrt(-23), -1 Sqrt(-23) ] ][128X[104X
    [4X[25Xgap>[125X [27Xw:=R!.elts[2];[127X[104X
    [4X[28X[ [ 3/2 + 1/2 Sqrt(-23), -3/2 + 1/2 Sqrt(-23) ], [128X[104X
    [4X[28X  [ 3/2 + -1/2 Sqrt(-23), 3 ] ][128X[104X
    [4X[25Xgap>[125X [27Xx:=R!.elts[50];[127X[104X
    [4X[28X[ [ 11/2 + 1/2 Sqrt(-23), 15/2 + -1/2 Sqrt(-23) ], [128X[104X
    [4X[28X  [ -1 Sqrt(-23), -4 + -1 Sqrt(-23) ] ][128X[104X
    [4X[28X[128X[104X
  [4X[32X[104X
  
  
  [1X14.8-1 [33X[0;0YSwan's generators[133X[101X
  
  [33X[0;0YThe  five  generators  in the above presentation for [22XSL_2(mathcal O_-23)[122X are
  obtained  by  constructing  the  low  dimensions  of a CW-classifying space,
  forming  a maximal tree in its [22X1[122X-skeleton, constructing a presentation whose
  generators  correspond  to  edges  not in the tree, and then applying Tietze
  operations  to  simplify  this  presentation.  Swan's  approach instead uses
  generators  corresponding  to  the  "face  pairings"  of  the  [22X3[122X-dimensional
  fundamental domain. For [22Xdne 1, 3[122X the number of these face-pairing generators
  in  [22XSL_2(mathcal O_-d)[122X is equal to [22X3[122X plus the number of orbits of [22X2[122X-cells in
  the  equivariant  [22X2[122X-complex  [22XK[122X.  The  three  extra  generators  are  the two
  translations  corresponding  to  the  vertical  faces  of  the [22X3[122X-dimensional
  fundamental  domain  which  get  homotopied  to edges in [22XK[122X, plus the element
  [22X(beginarrayrr  -1  &  00 & -1endarray)[122X which acts trivially on [22Xfrak H^3[122X. For
  [22Xd=1,3[122X  there  is  one  further generator due to the existence of non-trivial
  units in [22Xmathcal O( Q(sqrt-1))[122X and [22Xmathcal O( Q(sqrt-3))[122X.[133X
  
  [33X[0;0YThe  following commands show that for [22XSL_2(mathcal O_-23)[122X there are 6 orbits
  of [22X2[122X-cells in [22XK[122X and then lists Swan's 9 generators.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XK:=BianchiGcomplex(-23);;[127X[104X
    [4X[25Xgap>[125X [27XK!.dimension(2);[127X[104X
    [4X[28X6[128X[104X
    [4X[25Xgap>[125X [27Xfor g in GeneratorsOfGroup(K!.group) do[127X[104X
    [4X[25X>[125X [27XPrint(g,"\n");[127X[104X
    [4X[25X>[125X [27Xod;[127X[104X
    [4X[28X[ [ -1, 0 ], [ 0, -1 ] ][128X[104X
    [4X[28X[ [ 1, 1 ], [ 0, 1 ] ][128X[104X
    [4X[28X[ [ 1, 1/2 + 1/2 Sqrt(-23) ], [ 0, 1 ] ][128X[104X
    [4X[28X[ [ -1, 0 ], [ 1, -1 ] ][128X[104X
    [4X[28X[ [ 5 + 2 Sqrt(-23), -11 ], [ 3/2 + -1/2 Sqrt(-23), 3/2 + 1/2 Sqrt(-23) ] ][128X[104X
    [4X[28X[ [ 208 + 25 Sqrt(-23), -225 + 25 Sqrt(-23) ], [ 3/2 + 1/2 Sqrt(-23), -3 ] ][128X[104X
    [4X[28X[ [ 18 + 91 Sqrt(-23), -437 ], [ 5/2 + 1/2 Sqrt(-23), -5/2 + 1/2 Sqrt(-23) ] ][128X[104X
    [4X[28X[ [ 1 + -6 Sqrt(-23), -29 ], [ 5/2 + -1/2 Sqrt(-23), -5/2 + -1/2 Sqrt(-23) ] ][128X[104X
    [4X[28X[ [ 1 Sqrt(-23), -6 ], [ 4, 1 Sqrt(-23) ] ][128X[104X
    [4X[28X[128X[104X
  [4X[32X[104X
  
  
  [1X14.9 [33X[0;0YFinite index subgroups[133X[101X
  
  [33X[0;0YThe  following  commands  compute  the  integral  homology  of  a congruence
  subgroup  [22XG[122X  of  index  24  in  [22XSL_2(mathcal  O_-23)[122X.  They  also  compute a
  presentation for [22XG[122X with 13 generators and 24 relators.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XOQ:=RingOfIntegers(QuadraticNumberField(-23));;[127X[104X
    [4X[25Xgap>[125X [27XI:=QuadraticIdeal(OQ,[Sqrt(-23)]);[127X[104X
    [4X[28Xideal of norm 23 in O(Q(Sqrt(-23)))[128X[104X
    [4X[25Xgap>[125X [27XG:=HAP_CongruenceSubgroupGamma0(I);[127X[104X
    [4X[28X<group of 2x2 matrices in characteristic 0>[128X[104X
    [4X[25Xgap>[125X [27XIndexInSL2O(G);[127X[104X
    [4X[28X24[128X[104X
    [4X[28X[128X[104X
    [4X[25Xgap>[125X [27XK:=BianchiGcomplex(-23);;[127X[104X
    [4X[25Xgap>[125X [27XR:=FreeGResolution(K,11);;[127X[104X
    [4X[25Xgap>[125X [27XR:=QuadraticToCyclotomicCoefficients(R);;[127X[104X
    [4X[25Xgap>[125X [27XS:=ResolutionFiniteSubgroup(R,G);;[127X[104X
    [4X[25Xgap>[125X [27XList([0..10],n->Homology(TensorWithIntegers(S),n));[127X[104X
    [4X[28X[ [ 0 ], [ 2, 0, 0, 0, 0, 0, 0, 0, 0 ], [128X[104X
    [4X[28X  [ 2, 2, 2, 2, 2, 2, 2, 2, 0, 0, 0, 0, 0, 0, 0 ], [ 2, 2, 2, 2, 2, 2, 2, 2 ],[128X[104X
    [4X[28X  [ 2, 2, 2, 2, 2, 2, 2, 2 ], [ 2, 2, 2, 2, 2, 2, 2, 2 ], [128X[104X
    [4X[28X  [ 2, 2, 2, 2, 2, 2, 2, 2 ], [ 2, 2, 2, 2, 2, 2, 2, 2 ], [128X[104X
    [4X[28X  [ 2, 2, 2, 2, 2, 2, 2, 2 ], [ 2, 2, 2, 2, 2, 2, 2, 2 ], [128X[104X
    [4X[28X  [ 2, 2, 2, 2, 2, 2, 2, 2 ] ][128X[104X
    [4X[28X[128X[104X
    [4X[25Xgap>[125X [27XP:=PresentationOfResolution(S);;[127X[104X
    [4X[25Xgap>[125X [27XH:=SimplifiedFpGroup(P!.freeGroup/P!.relators);[127X[104X
    [4X[28X<fp group on the generators [ f8, f10, f15, f70, f86, f125, f132, f138, f182, [128X[104X
    [4X[28X  f187, f191, f273, f279 ]>[128X[104X
    [4X[25Xgap>[125X [27XLength(RelatorsOfFpGroup(H));[127X[104X
    [4X[28X24[128X[104X
    [4X[28X[128X[104X
  [4X[32X[104X
  
  
  [1X14.10 [33X[0;0YTotally real quadratic fields / Hilbert modular group[133X[101X
  
  [33X[0;0YFor square free [22Xd>0[122X the group [22XG_d=PSL_2(mathcal O_d)[122X is a subgroup of [22XPSL_2(
  R)[122X  but  not a discrete subgroup. It embeds as a discrete subgroup of [22XPSL_2(
  R)× PSL_2( R)[122X but a fundamental domain for its action on [22Xfrak h^2 × frak h^2[122X
  is  not  implemented  in  HAP. One can obtain a contractible [22XG_d[122X-equivariant
  complex     using    Sebastian    Schoennenbeck's    Magma    implementation
  ([7Xhttps://github.com/schoennenbeck/VMH-TotallyRealNumberFields[107X)  of Voronoi's
  algorithm  to  produce  text files that can be read into HAP. A few of these
  text  files are stored in HAP. The following commands use one such text file
  to  compute integral homology groups of [22XGL_2(mathcal O( Q(sqrt14)))[122X. In this
  example  the  contractible  complex  is  [22X4[122X-dimensional  and has [22X33[122X orbits of
  [22X4[122X-dimensional cells.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XK:=ContractibleGcomplex("GL(2,O14)");[127X[104X
    [4X[28XNon-free resolution in characteristic 0 for matrix group . [128X[104X
    [4X[28XNo contracting homotopy available. [128X[104X
    [4X[28X[128X[104X
    [4X[25Xgap>[125X [27XList([0..5],K!.dimension);[127X[104X
    [4X[28X[ 144, 463, 532, 234, 33, 0 ][128X[104X
    [4X[28X[128X[104X
    [4X[25Xgap>[125X [27XR:=FreeGResolution(K,6);;[127X[104X
    [4X[25Xgap>[125X [27XList([0..5],n->Homology(TensorWithIntegers(R),n));[127X[104X
    [4X[28X[ [ 0 ], [ 2, 2, 2, 0 ], [ 2, 2, 2, 2, 2, 2, 0, 0, 0, 0 ], [128X[104X
    [4X[28X  [ 2, 2, 2, 2, 2, 2, 2, 2, 2, 4, 4, 24, 24, 0, 0, 0, 0 ], [128X[104X
    [4X[28X  [ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 4, 4, 4, 12, 24 ], [128X[104X
    [4X[28X  [ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 4, 4, 4, 4 ] ][128X[104X
    [4X[28X[128X[104X
  [4X[32X[104X
  
