  
  [1X13 Interfaces to other software packages[0X
  
  [5Xsimpcomp[0m contains various interfaces to other software packages (see Chapter
  [14X12[0m  for  file-related export and import formats). In this chapter, some more
  sophisticated interfaces to other software packages are described.
  
  Note  that  this chapter is subject to change and extension as it is planned
  to  expand  [5Xsimpcomp[0m's  functionality in this area in the course of the next
  versions.
  
  
  [1X13.1 Interface to the [5XGAP[1X-package [5Xhomalg[1X[0X
  
  As of Version 1.5, [5Xsimpcomp[0m is equipped with an interface to the [5XGAP[0m-package
  [5Xhomalg[0m  [BR08]  by  Mohamed  Barakat.  This  allows to use [5Xhomalg[0m's powerful
  capabilities  in  the  field  of  homological algebra to compute topological
  properties of simplicial complexes.
  
  For the time being, the only functions provided are ones allowing to compute
  the  homology  and  cohomology groups of simplicial complexes with arbitrary
  coefficients.  It  is planned to extend the functionality in future releases
  of  [5Xsimpcomp[0m. See below for a list of functions that provide an interface to
  [5Xhomalg[0m.
  
  [1X13.1-1 SCHomalgBoundaryMatrices[0m
  
  [2X> SCHomalgBoundaryMatrices( [0X[3Xcomplex, modulus[0X[2X ) _______________________[0Xmethod
  [6XReturns:[0X  a list of [5Xhomalg[0m objects upon success, [9Xfail[0m otherwise.
  
  This  function  computes  the  boundary operator matrices for the simplicial
  complex [3Xcomplex[0m with a ring of coefficients as specified by [3Xmodulus[0m: a value
  of [10X0[0m yields Q-matrices, a value of [10X1[0m yields Z-matrices and a value of [10Xq[0m, q a
  prime or a prime power, computes the F_q-matrices.
  
  [4X---------------------------  Example  ----------------------------[0X
    [4X gap> SCLib.SearchByName("CP^2 (VT)");[0X
    [4X [ [ 16, "CP^2 (VT)" ] ][0X
    [4X gap> c:=SCLib.Load(last[1][1]);;[0X
    [4X gap> SCHomalgBoundaryMatrices(c,0);[0X
    [4X [ [A 36 x 9 matrix over an internal ring], [0X
    [4X   [A 84 x 36 matrix over an internal ring], [0X
    [4X   [A 90 x 84 matrix over an internal ring], [0X
    [4X   [A 36 x 90 matrix over an internal ring], [0X
    [4X   [An unevaluated 0 x 36 zero matrix over an internal ring] ][0X
    [4X [0X
  [4X------------------------------------------------------------------[0X
  
  [1X13.1-2 SCHomalgCoboundaryMatrices[0m
  
  [2X> SCHomalgCoboundaryMatrices( [0X[3Xcomplex, modulus[0X[2X ) _____________________[0Xmethod
  [6XReturns:[0X  a list of [5Xhomalg[0m objects upon success, [9Xfail[0m otherwise.
  
  This  function  computes the coboundary operator matrices for the simplicial
  complex [3Xcomplex[0m with a ring of coefficients as specified by [3Xmodulus[0m: a value
  of [10X0[0m yields Q-matrices, a value of [10X1[0m yields Z-matrices and a value of [10Xq[0m, q a
  prime or a prime power, computes the F_q-matrices.
  
  [4X---------------------------  Example  ----------------------------[0X
    [4X gap> SCLib.SearchByName("CP^2 (VT)");[0X
    [4X [ [ 16, "CP^2 (VT)" ] ][0X
    [4X gap> c:=SCLib.Load(last[1][1]);;[0X
    [4X gap> SCHomalgCoboundaryMatrices(c,0);[0X
    [4X [ [A 9 x 36 matrix over an internal ring], [0X
    [4X   [A 36 x 84 matrix over an internal ring], [0X
    [4X   [A 84 x 90 matrix over an internal ring], [0X
    [4X   [A 90 x 36 matrix over an internal ring], [0X
    [4X   [An unevaluated 36 x 0 zero matrix over an internal ring] ][0X
    [4X [0X
  [4X------------------------------------------------------------------[0X
  
  [1X13.1-3 SCHomalgHomology[0m
  
  [2X> SCHomalgHomology( [0X[3Xcomplex, modulus[0X[2X ) _______________________________[0Xmethod
  [6XReturns:[0X  a list of integers upon success, [9Xfail[0m otherwise.
  
  This  function  computes  the ranks of the homology groups of [3Xcomplex[0m with a
  ring  of  coefficients  as  specified  by [3Xmodulus[0m: a value of [10X0[0m computes the
  Q-homology, a value of [10X1[0m computes the Z-homology and a value of [10Xq[0m, q a prime
  or a prime power, computes the F_q-homology ranks.
  
  Note  that  if  you  are  interested  not  only in the ranks of the homology
  groups,  but  rather  their  full  structure,  have  a  look at the function
  [2XSCHomalgHomologyBasis[0m ([14X13.1-4[0m).
  
  [4X---------------------------  Example  ----------------------------[0X
    [4X gap> SCLib.SearchByName("K3");[0X
    [4X [ [ 7494, "K3 surface" ] ][0X
    [4X gap> c:=SCLib.Load(last[1][1]);;[0X
    [4X gap> SCHomalgHomology(c,0);[0X
    [4X #I  SCHomalgHomologyOp: Q-homology ranks: [ 1, 0, 22, 0, 1 ][0X
    [4X [ 1, 0, 22, 0, 1 ][0X
    [4X [0X
  [4X------------------------------------------------------------------[0X
  
  [1X13.1-4 SCHomalgHomologyBasis[0m
  
  [2X> SCHomalgHomologyBasis( [0X[3Xcomplex, modulus[0X[2X ) __________________________[0Xmethod
  [6XReturns:[0X  a [5Xhomalg[0m object upon success, [9Xfail[0m otherwise.
  
  This  function computes the homology groups (including explicit bases of the
  modules  involved)  of  [3Xcomplex[0m  with a ring of coefficients as specified by
  [3Xmodulus[0m:  a  value  of  [10X0[0m computes the Q-homology, a value of [10X1[0m computes the
  Z-homology  and  a  value  of  [10Xq[0m,  q  a prime or a prime power, computes the
  F_q-homology groups.
  
  The    k-th    homology    group    [10Xhk[0m    can   be   obtained   by   calling
  [10Xhk:=CertainObject(homology,k);[0m, where [10Xhomology[0m is the [5Xhomalg[0m object returned
  by   this   function.  The  generators  of  [10Xhk[0m  can  then  be  obtained  via
  [10XGeneratorsOfModule(hk);[0m.
  
  Note  that  if  you are only interested in the ranks of the homology groups,
  then  it is better to use the funtion [2XSCHomalgHomology[0m ([14X13.1-3[0m) which is way
  faster.
  
  [4X---------------------------  Example  ----------------------------[0X
    [4X gap> SCLib.SearchByName("K3");[0X
    [4X [ [ 7494, "K3 surface" ] ][0X
    [4X gap> c:=SCLib.Load(last[1][1]);;[0X
    [4X gap> SCHomalgHomologyBasis(c,0);[0X
    [4X #I  SCHomalgHomologyBasisOp: constructed Q-homology groups.[0X
    [4X [A graded homology object consisting of 5 left modules at degrees [ 0 .. 4 ]][0X
    [4X [0X
  [4X------------------------------------------------------------------[0X
  
  [1X13.1-5 SCHomalgCohomology[0m
  
  [2X> SCHomalgCohomology( [0X[3Xcomplex, modulus[0X[2X ) _____________________________[0Xmethod
  [6XReturns:[0X  a list of integers upon success, [9Xfail[0m otherwise.
  
  This  function computes the ranks of the cohomology groups of [3Xcomplex[0m with a
  ring  of  coefficients  as  specified  by [3Xmodulus[0m: a value of [10X0[0m computes the
  Q-cohomology,  a  value of [10X1[0m computes the Z-cohomology and a value of [10Xq[0m, q a
  prime or a prime power, computes the F_q-cohomology ranks.
  
  Note  that  if  you  are  interested not only in the ranks of the cohomology
  groups,  but  rather  their  full  structure,  have  a  look at the function
  [2XSCHomalgCohomologyBasis[0m ([14X13.1-6[0m).
  
  [4X---------------------------  Example  ----------------------------[0X
    [4X gap> SCLib.SearchByName("K3");[0X
    [4X [ [ 7494, "K3 surface" ] ][0X
    [4X gap> c:=SCLib.Load(last[1][1]);;[0X
    [4X gap> SCHomalgCohomology(c,0);[0X
    [4X #I  SCHomalgCohomologyOp: Q-cohomology ranks: [ 1, 0, 22, 0, 1 ][0X
    [4X [ 1, 0, 22, 0, 1 ][0X
    [4X [0X
  [4X------------------------------------------------------------------[0X
  
  [1X13.1-6 SCHomalgCohomologyBasis[0m
  
  [2X> SCHomalgCohomologyBasis( [0X[3Xcomplex, modulus[0X[2X ) ________________________[0Xmethod
  [6XReturns:[0X  a [5Xhomalg[0m object upon success, [9Xfail[0m otherwise.
  
  This  function  computes  the cohomology groups (including explicit bases of
  the modules involved) of [3Xcomplex[0m with a ring of coefficients as specified by
  [3Xmodulus[0m:  a  value of [10X0[0m computes the Q-cohomology, a value of [10X1[0m computes the
  Z-cohomology  and  a  value  of  [10Xq[0m, q a prime or a prime power, computes the
  F_q-homology groups.
  
  The    k-th    cohomology    group   [10Xck[0m   can   be   obtained   by   calling
  [10Xck:=CertainObject(cohomology,k);[0m,  where  [10Xcohomology[0m  is  the  [5Xhomalg[0m object
  returned  by  this  function.  The generators of [10Xck[0m can then be obtained via
  [10XGeneratorsOfModule(ck);[0m.
  
  Note  that if you are only interested in the ranks of the cohomology groups,
  then  it  is  better to use the funtion [2XSCHomalgCohomology[0m ([14X13.1-5[0m) which is
  way faster.
  
  [4X---------------------------  Example  ----------------------------[0X
    [4X gap> SCLib.SearchByName("K3");[0X
    [4X [ [ 7494, "K3 surface" ] ][0X
    [4X gap> c:=SCLib.Load(last[1][1]);;[0X
    [4X gap> SCHomalgCohomologyBasis(c,0);[0X
    [4X #I  SCHomalgCohomologyBasisOp: constructed Q-cohomology groups.[0X
    [4X [A graded cohomology object consisting of 5 left modules at degrees [0X
    [4X [ 1 .. 5 ]][0X
    [4X [0X
  [4X------------------------------------------------------------------[0X
  
