---
title: "Central Extensions"
canonical: "https://docs.magma-maths.org/v2.30-1/FiniteGroups/FiniteSolubleGroups/central-extensions.html"
source: "https://docs.magma-maths.org/v2.30-1/FiniteGroups/FiniteSolubleGroups/central-extensions.md"
part: "Finite Groups"
chapter: "Finite Soluble Groups"
breadcrumbs:
  - {"title": "Magma Handbook", "source": "https://docs.magma-maths.org/v2.30-1/index.md"}
  - {"title": "Finite Groups", "source": "https://docs.magma-maths.org/v2.30-1/FiniteGroups/index-finite-groups.md"}
  - {"title": "Finite Soluble Groups", "source": "https://docs.magma-maths.org/v2.30-1/FiniteGroups/FiniteSolubleGroups/index-finite-soluble-groups.md"}
prev: {"title": "Representation Theory", "source": "https://docs.magma-maths.org/v2.30-1/FiniteGroups/FiniteSolubleGroups/character-representation.md"}
next: {"title": "Transfer Between Group Categories", "source": "https://docs.magma-maths.org/v2.30-1/FiniteGroups/FiniteSolubleGroups/transfer-functions.md"}
intrinsics:
  - {"name": "ExtGenerators", "signature": "ExtGenerators(G, U): GrpPC, GrpPC -> [<AlgMatElt, RngIntElt>]"}
  - {"name": "HomGenerators", "signature": "HomGenerators(G, U): GrpPC, GrpPC -> [<AlgMatElt, RngIntElt>]"}
  - {"name": "ElementSequence", "signature": "ElementSequence(G): GrpPC -> SeqEnum"}
  - {"name": "RepresentativeCocycles", "signature": "RepresentativeCocycles(G, U, Ext, Hom): GrpPC, GrpPC, [AlgMatElt], [AlgMatElt] -> [AlgMatElt]"}
  - {"name": "CentralExtension", "signature": "CentralExtension(G, U, A): GrpPC, GrpPC, AlgMatElt -> GrpPC"}
  - {"name": "CentralExtensions", "signature": "CentralExtensions(G, U, Q): GrpPC, GrpPC, [AlgMatElt] -> [GrpPC]"}
  - {"name": "CentralExtensionProcess", "signature": "CentralExtensionProcess(G, U): GrpPC, GrpPC -> Proc"}
  - {"name": "NextExtension", "signature": "NextExtension(~P): Rec -> GrpPC"}
  - {"name": "IsEmpty", "signature": "IsEmpty(P): Rec -> BoolElt"}
examples:
  - "ex-b4d774"
---

# Central Extensions

We now describe functions to construct $H^2(G,U)$ for a finite soluble group $G$ and finite abelian group $U$ (a trivial $G$-module). We also present functions to construct central extensions of $U$ by $G$.

Denote by $Z^2(G,U)$ the abelian group of all cocycles from $G$ to $U$, under pointwise multiplication. The values $\psi(g,h)$ of $\psi \in Z^2(G, U)$ may be represented as a “cocyclic matrix” with entries in $U$.

If $\phi \colon G \rightarrow U$ is a set map with $\phi (1_G) = 1_U$, then there is a coboundary $\partial \phi \in Z^2(G,U)$ defined by $\partial \phi(g,h) = \phi(g) \phi (h) \phi(gh)^{-1}$. The group of all coboundaries from $G$ to $U$ is denoted $B^2(G,U)$, and we have $H^2(G,U) = Z^2(G,U)/B^2(G,U)$. Then $H^2(G,U)=I\times T$, where $I$ is the (faithful) image of Ext$(G/G', U) \leq H^2(G/G', U)$ under inflation, and $T$ is the (faithful) image of Hom$(H_2(G), U)$ under a certain transgression homomorphism. Here we provide functions which construct representatives for the elements in a generating set for each of these two factors.

For details of the theory and the algorithm used, see [[FO00](https://docs.magma-maths.org/v2.30-1/references.md#cite-fo-centex)].

`SetVerbose ("Cocycle", 1)` will provide additional information on the calculations in the functions.

<a id="function-extgenerators-grppc-grppc"></a>
## `ExtGenerators(G, U): GrpPC, GrpPC -> [<AlgMatElt, RngIntElt>]`

Given a soluble group $G$ and an abelian group $U$ (both defined by pc-presentations) the function returns a sequence of tuples describing generators for Ext$(G/G', U)$ as cocyclic matrices; the first entry in each tuple is a representative of a generator, the second is the order of the coset of the representative in $H^2(G, U)$.

<a id="function-homgenerators-grppc-grppc"></a>
## `HomGenerators(G, U): GrpPC, GrpPC -> [<AlgMatElt, RngIntElt>]`

Given a soluble group $G$ and an abelian group $U$ (both defined by pc-presentations) the function returns a sequence of tuples describing generators for Hom$(H_2 (G), U)$ as cocyclic matrices; the first entry in each tuple is a representative of a generator, the second is the order of the coset of the representative in $H^2(G, U)$.

<a id="function-elementsequence-grppc"></a>
## `ElementSequence(G): GrpPC -> SeqEnum`

For a soluble group $G$, the function returns an indexed set of elements of $G$ listed in the order used by `ExtGenerators` and `HomGenerators`.

<a id="function-representativecocycles-grppc-grppc-algmatelt-algmatelt"></a>
## `RepresentativeCocycles(G, U, Ext, Hom): GrpPC, GrpPC, [AlgMatElt], [AlgMatElt] -> [AlgMatElt]`

Let $G$ be a soluble group $G$ and $U$ be an abelian group both defined by pc-presentations. Let $Ext$ and $Hom$ be the values returned by calling `ExtGenerators` and `HomGenerators` respectively. The function `RepresentativeCocycles` returns a complete and irredundant set of representatives for the elements of $H^2(G,U)$ as cocyclic matrices.

<a id="function-centralextension-grppc-grppc-algmatelt"></a>
## `CentralExtension(G, U, A): GrpPC, GrpPC, AlgMatElt -> GrpPC`

Let $G$ be a soluble group $G$ and $U$ be an abelian group, both defined by pc-presentations. Further, let $A$ be a cocyclic matrix (as determined by the function `RepresentativeCocycles`). Then, this function returns the central extension of $U$ by $G$ determined by the cocyclic matrix $A$.

<a id="function-centralextensions-grppc-grppc-algmatelt"></a>
## `CentralExtensions(G, U, Q): GrpPC, GrpPC, [AlgMatElt] -> [GrpPC]`

If $G$ is a soluble group $G$ and $U$ is an abelian group, both defined by pc-presentations, and $Q$ is a sequence of cocyclic matrices (as determined by the function `RepresentativeCocycles`), this function returns the corresponding sequence of central extension of $U$ by $G$ determined by the sequence of cocyclic matrices $A$. Note that the central extensions thereby constructed need not be mutually non-isomorphic.

<a id="function-centralextensionprocess-grppc-grppc"></a>
## `CentralExtensionProcess(G, U): GrpPC, GrpPC -> Proc`

Given a soluble group $G$ and an abelian group $U$ (both defined by pc-presentations) the function creates a process $P$ for central extensions of $U$ by $G$. Note that the list of central extensions constructed by this process will contain all isomorphism types but the extensions need not be mutually non-isomorphic.

<a id="function-nextextension-rec-ref"></a>
## `NextExtension(~P): Rec -> GrpPC`

Given a central extension process $P$, construct the next central extension determined by $P$.

<a id="function-isempty-rec"></a>
## `IsEmpty(P): Rec -> BoolElt`

Return `true` if all central extensions determined by the process $P$ have been constructed; otherwise return `false`.

<a id="example-ex-b4d774"></a>
## `Example: Central Extensions of a Dihedral Group (ex-b4d774)`

We compute the abelian invariants of $H^2 (D_4, C_2)$.

```magma
> G := DihedralGroup(GrpPC, 4);
> U := AbelianGroup(GrpPC, [2]);
>
> Ext := ExtGenerators(G, U);
> Ext[1];
    <[Id(U) Id(U) Id(U) Id(U) Id(U) Id(U) Id(U) Id(U)]
    [Id(U) Id(U) Id(U) Id(U) Id(U) Id(U) Id(U) Id(U)]
    [Id(U) Id(U) Id(U) Id(U) Id(U) Id(U) Id(U) Id(U)]
    [Id(U) Id(U) Id(U) Id(U) Id(U) Id(U) Id(U) Id(U)]
    [Id(U) Id(U) Id(U) Id(U) U.1 U.1 U.1 U.1]
    [Id(U) Id(U) Id(U) Id(U) U.1 U.1 U.1 U.1]
    [Id(U) Id(U) Id(U) Id(U) U.1 U.1 U.1 U.1]
    [Id(U) Id(U) Id(U) Id(U) U.1 U.1 U.1 U.1], 2>,
>
> Hom := HomGenerators(G, U);
> Hom;
[
    <[Id(U) Id(U) Id(U) Id(U) Id(U) Id(U) Id(U) Id(U)]
    [Id(U) U.1 U.1 Id(U) Id(U) U.1 U.1 Id(U)]
    [Id(U) Id(U) Id(U) Id(U) Id(U) Id(U) Id(U) Id(U)]
    [Id(U) U.1 U.1 Id(U) Id(U) U.1 U.1 Id(U)]
    [Id(U) Id(U) Id(U) U.1 Id(U) U.1 U.1 U.1]
    [Id(U) U.1 Id(U) Id(U) U.1 U.1 Id(U) U.1]
    [Id(U) Id(U) Id(U) U.1 Id(U) U.1 U.1 U.1]
    [Id(U) U.1 Id(U) Id(U) U.1 U.1 Id(U) U.1], 2>
]
>
> AbelianInvariants(Ext, Hom);
[ 2, 2, 2 ]
```

We now compute the central extension of U by G determined by a single cocyclic matrix.

```magma
> A := RepresentativeCocycles(G, U, Ext, Hom);
> E := CentralExtension(G, U, A[2]);
> E;
GrpPC : E of order 16 = 2^4
PC-Relations:
    E.1^2 = E.4,
    E.2^2 = E.3 * E.4,
    E.2^E.1 = E.2 * E.3
```

Alternatively we can build all central extensions of U by G.

```magma
> E := CentralExtensions(G, U, A);
> "Number of extensions is ", #E;
Number of extensions is  8
```

Next, we provide an example of using the central extension process. Firstly, we create the groups and initialize the process.

```magma
> G := SmallGroup(12, 5);
> U := AbelianGroup(GrpPC, [2, 3]);
> P := CentralExtensionProcess(G, U);
```

Now we run over the central extensions and count conjugacy classes.

```magma
> C := [];
> while IsEmpty(P) eq false do
>    NextExtension(~P, ~E);
>    Append(~C, #Classes (E));
> end while;
> "# conjugacy classes is ", C;
# conjugacy classes is  [ 45, 72, 45, 72, 45, 72, 45, 72, 45, 72, 45,
72, 45, 72, 45, 72, 45, 72, 45, 72, 45, 72, 45, 72 ]
```
