Homology Groups#

This module defines a HomologyGroup() class which is an abelian group that prints itself in a way that is suitable for homology groups.

sage.homology.homology_group.HomologyGroup(n, base_ring, invfac=None)[source]#

Abelian group on \(n\) generators which represents a homology group in a fixed degree.

INPUT:

  • n – integer; the number of generators

  • base_ring – ring; the base ring over which the homology is computed

  • inv_fac – list of integers; the invariant factors – ignored if the base ring is a field

OUTPUT:

A class that can represent the homology group in a fixed homological degree.

EXAMPLES:

sage: from sage.homology.homology_group import HomologyGroup
sage: G = AbelianGroup(5, [5,5,7,8,9]); G                                       # needs sage.groups
Multiplicative Abelian group isomorphic to C5 x C5 x C7 x C8 x C9
sage: H = HomologyGroup(5, ZZ, [5,5,7,8,9]); H
C5 x C5 x C7 x C8 x C9
sage: AbelianGroup(4)                                                           # needs sage.groups
Multiplicative Abelian group isomorphic to Z x Z x Z x Z
sage: HomologyGroup(4, ZZ)
Z x Z x Z x Z

sage: # needs sage.libs.flint (otherwise timeout)
sage: HomologyGroup(100, ZZ)
Z^100
>>> from sage.all import *
>>> from sage.homology.homology_group import HomologyGroup
>>> G = AbelianGroup(Integer(5), [Integer(5),Integer(5),Integer(7),Integer(8),Integer(9)]); G                                       # needs sage.groups
Multiplicative Abelian group isomorphic to C5 x C5 x C7 x C8 x C9
>>> H = HomologyGroup(Integer(5), ZZ, [Integer(5),Integer(5),Integer(7),Integer(8),Integer(9)]); H
C5 x C5 x C7 x C8 x C9
>>> AbelianGroup(Integer(4))                                                           # needs sage.groups
Multiplicative Abelian group isomorphic to Z x Z x Z x Z
>>> HomologyGroup(Integer(4), ZZ)
Z x Z x Z x Z

>>> # needs sage.libs.flint (otherwise timeout)
>>> HomologyGroup(Integer(100), ZZ)
Z^100
class sage.homology.homology_group.HomologyGroup_class(n, invfac)[source]#

Bases: AdditiveAbelianGroup_fixed_gens

Discrete Abelian group on \(n\) generators. This class inherits from AdditiveAbelianGroup_fixed_gens; see sage.groups.additive_abelian.additive_abelian_group for more documentation. The main difference between the classes is in the print representation.

EXAMPLES:

sage: from sage.homology.homology_group import HomologyGroup
sage: G = AbelianGroup(5, [5,5,7,8,9]); G                                       # needs sage.groups
Multiplicative Abelian group isomorphic to C5 x C5 x C7 x C8 x C9
sage: H = HomologyGroup(5, ZZ, [5,5,7,8,9]); H
C5 x C5 x C7 x C8 x C9
sage: G == loads(dumps(G))                                                      # needs sage.groups
True
sage: AbelianGroup(4)                                                           # needs sage.groups
Multiplicative Abelian group isomorphic to Z x Z x Z x Z
sage: HomologyGroup(4, ZZ)
Z x Z x Z x Z
sage: HomologyGroup(100, ZZ)
Z^100
>>> from sage.all import *
>>> from sage.homology.homology_group import HomologyGroup
>>> G = AbelianGroup(Integer(5), [Integer(5),Integer(5),Integer(7),Integer(8),Integer(9)]); G                                       # needs sage.groups
Multiplicative Abelian group isomorphic to C5 x C5 x C7 x C8 x C9
>>> H = HomologyGroup(Integer(5), ZZ, [Integer(5),Integer(5),Integer(7),Integer(8),Integer(9)]); H
C5 x C5 x C7 x C8 x C9
>>> G == loads(dumps(G))                                                      # needs sage.groups
True
>>> AbelianGroup(Integer(4))                                                           # needs sage.groups
Multiplicative Abelian group isomorphic to Z x Z x Z x Z
>>> HomologyGroup(Integer(4), ZZ)
Z x Z x Z x Z
>>> HomologyGroup(Integer(100), ZZ)
Z^100