# Subgroups of Modular Abelian Varieties

## Creation

Subgroups can be created from a sequence of elements of a modular abelian variety which generate it. It is also possible to create $n$-torsion subgroups $A[n]$ and to create subgroups as kernels of homomorphisms or by taking an image of the difference of two cusps.

If a subgroup $G$ contains elements that are not known exactly (i.e., they are defined by floating point approximations to real homology elements), a group of torsion points that approximates $G$ can be found.

### `Subgroup(X): [ModAbVarElt] -> ModAbVarSubGrp`

The subgroup of $A$ generated by the nonempty sequence $X$ of elements of modular abelian variety $A$.

### `ZeroSubgroup(A): ModAbVar -> ModAbVarSubGrp`

The zero subgroup of the abelian variety $A$.

### `nTorsionSubgroup(A, n): ModAbVar, RngIntElt -> ModAbVarSubGrp`

The kernel $A[n]$ of the multiplication by $n$ isogeny on the modular abelian variety $A$.

### `nTorsionSubgroup(G, n): ModAbVarSubGrp, RngIntElt -> ModAbVarSubGrp`

The kernel $G[n]$ of the multiplication by $n$ homomorphism on the subgroup $G$ of a modular abelian variety.

### `ApproximateByTorsionGroup(G : parameters): ModAbVarSubGrp -> ModAbVarSubGrp`

```magma
Cutoff: RngIntElt                    Default: 10^3
```

The subgroup generated by torsion approximations of a set of generators of the subgroup $G$ of a modular abelian variety.

### `Example: Subgrp Creation (ex-05950a)`

First we list the elements of the $2$-torsion subgroup of the elliptic curve 100A, then we compute the $0$ subgroup.

```magma
> A := ModularAbelianVariety("100A"); A;
Modular abelian variety 100A of dimension 1 and level 2^2*5^2
over Q
> G := nTorsionSubgroup(A,2); G;
Finitely generated subgroup of abelian variety with invariants [ 2, 2 ]
> Elements(G);
[
    0,
    Element of abelian variety defined by [1/2 0] modulo homology,
    Element of abelian variety defined by [0 1/2] modulo homology,
    Element of abelian variety defined by [1/2 1/2] modulo homology
]
> ZeroSubgroup(A);
{ 0 }: finitely generated subgroup of abelian variety with
invariants []

```

We can also use the `nTorsionSubgroup` command on subgroups.

```magma
> nTorsionSubgroup(G,2);
Finitely generated subgroup of abelian variety with
invariants [ 2, 2 ]
> nTorsionSubgroup(G,3);
{ 0 }: finitely generated subgroup of abelian variety with
invariants []

```

One of the $2$-torsion elements generates a subgroup $H$ of order $2$.

```magma
> G.1;
Element of abelian variety defined by [0 1/2] modulo homology
> H := Subgroup([G.1]); H;
Finitely generated subgroup of abelian variety
> #H;
2

```

To illustrate the approximation command, we consider the subgroup generated by an approximation to one of the $2$-torsion elements.

```magma
> K := Subgroup([1.00001*G.1]);
> L := ApproximateByTorsionGroup(K);
Finitely generated subgroup of abelian variety with
invariants [ 2 ]
> L eq H;
true

```

## Elements

These commands enumerate elements of a finite subgroup of a modular abelian variety and allow access to the generators.

### `Elements(G): ModAbVarSubGrp -> SeqEnum`

A sequence of all elements of the finite subgroup $G$ of a modular abelian variety.

### `Generators(G): ModAbVarSubGrp -> SeqEnum`

A sequence of generators for the subgroup $G$ of a modular abelian variety. These correspond to generators for the underlying abelian group.

### `Ngens(G): ModAbVarSubGrp -> RngIntElt`

The number generators of the subgroup $G$ of a modular abelian variety.

### `G . i: ModAbVarSubGrp, RngIntElt -> ModAbVarElt`

The $i$-th generator of the subgroup $G$ of a modular abelian variety.

### `Example: Subgrp Elements (ex-74abb1)`

We illustrate each of the commands using the kernel of the Hecke operator $T_3$ acting on $J_0(67)$.

```magma
> J := JZero(67);
> T := HeckeOperator(J,3);
> G := Kernel(T);
> #G;
4
> Elements(G);
[
    0,
    Element of abelian variety defined by [0 0 1/2 0 0 -1/2 -1/2 0 1/2 0] modulo
    homology,
    Element of abelian variety defined by [1/2 -1/2 0 0 -1/2 0 0 -1/2 1/2 0]
    modulo homology,
    Element of abelian variety defined by [1/2 -1/2 1/2 0 -1/2 -1/2 -1/2 -1/2 1 0]
    modulo homology
]
> Generators(G);
[
    Element of abelian variety defined by [1/2 -1/2 0 0 -1/2 0 0 -1/2 1/2 0]
    modulo homology,
    Element of abelian variety defined by [0 0 1/2 0 0 -1/2 -1/2 0 1/2 0]
    modulo homology
]
> Ngens(G);
2
> G.1;
Element of abelian variety defined by [1/2 -1/2 0 0 -1/2 0 0 -1/2 1/2 0] modulo
homology
> G.2;
Element of abelian variety defined by [0 0 1/2 0 0 -1/2 -1/2 0 1/2 0] modulo
homology

```

## Arithmetic

Quotients of abelian varieties by finite subgroups can be formed, finite subgroups can be intersected with other finite subgroups or abelian varieties, and the group generated by two subgroups can be computed.

For several of the arithmetic operations below, finite groups or abelian varieties are replaced by their image in a common abelian variety, so the operation makes sense. This common abelian variety is the one returned by [`FindCommonEmbeddings`](arithabvar.md#function-fce). Note that the “embedding” is only guaranteed to be an embedding up to isogeny.

### `Quotient(A, G): ModAbVar, ModAbVarSubGrp -> ModAbVar, MapModAbVar`

The quotient of the abelian variety $A$ by the finite subgroup $G$ of $A$, the isogeny $A\to$ $A/G$ and an isogeny $A/G\to$ $A$, such that composition of the two isogenies is multiplication by the exponent of $G$.

### `Quotient(G): ModAbVarSubGrp -> ModAbVar, MapModAbVar, MapModAbVar`

The quotient $A/G$, where $A$ is the ambient variety of the subgroup $G$ of an abelian variety, an isogeny from $A$ to $A/G$ with kernel $G$, and an isogeny from $A/G$ to $A$ such that the composition of the two isogenies is multiplication by the exponent of $G$.

### `A / G: ModAbVar, ModAbVarSubGrp -> ModAbVar, MapModAbVar, MapModAbVar`

Given an abelian variety $A$ and a subgroup $G$ of an abelian variety return the quotient $A/G$, the isogeny $A\to$ $A/G$ with kernel $G$, and an isogeny $A/G\to$ $A$ where $A$ is not necessarily the ambient variety of $G$.

### `A meet G: ModAbVar, ModAbVarSubGrp -> ModAbVarSubGrp`

### `G meet A: ModAbVarSubGrp, ModAbVar -> ModAbVarSubGrp`

The intersection of the finite subgroup $G$ of an abelian variety $B$ with the abelian variety $A$. If $A$ is not equal to $B$, then $G$ and $A$ are replaced by their image in a common abelian variety.

### `G1 + G2: ModAbVarSubGrp, ModAbVarSubGrp -> ModAbVarSubGrp`

The sum of the subgroups $G_1$ and $G_2$ of abelian varieties $A_1$ and $A_2$. If $A_1$ is not equal to $A_2$, then $G_1$ and $G_2$ are replaced by their image in a common abelian variety.

### `G1 meet G2: ModAbVarSubGrp, ModAbVarSubGrp -> ModAbVarSubGrp`

The intersection of the finite subgroups $G_1$ and $G_2$ of an abelian variety. If their ambient varieties are not equal, $G_1$ and $G_2$ are replaced by their image in a common abelian variety.

### `Example: Subgrp Arithmetic (ex-180932)`

We illustrate these commands using the $2$-torsion of $J_0(67)$. First we compute the kernel of $T_3$, which is a $2$-torsion group of order $4$.

```magma
> J := JZero(67); J;
Modular abelian variety JZero(67) of dimension 5 and level 67 over Q
> T := HeckeOperator(J,3);
> Factorization(CharacteristicPolynomial(T));
[
    <x + 2, 2>,
    <x^2 - x - 1, 2>,
    <x^2 + 3*x + 1, 2>
]
> G := Kernel(T); #G;
4

```

Next we quotient $J_0(67)$ out by this subgroup of order $4$.

```magma
> A := Quotient(J,G); A;
Modular abelian variety of dimension 5 and level 67 over Q

```

The result is, of course, isogenous to $J_0(67)$. Unfortunately, testing of isomorphism in this generality is not yet implemented.

```magma
> IsIsogenous(A,J);
true
> Degree(ModularParameterization(A));
4

```

If the `Quotient` command is given only one argument then the variety being quotiented out by is the ambient variety.

```magma
> B := Quotient(G); B;
Modular abelian variety of dimension 5 and level 67 over Q
> Degree(ModularParameterization(B));
4

```

We can also use the divides notation for quotients.

```magma
> C := J/G; C;
Modular abelian variety of dimension 5 and level 67 over Q

```

Next we list the $2$-torsion subgroups of the simple factors of $J_0(67)$. Interestingly, the sum of the $2$-torsion subgroups of these simple factors is much smaller than the full $2$-torsion subgroup $J_0(67)[2]$.

```magma
> D := Decomposition(J); D;
[
    Modular abelian variety 67A of dimension 1, level 67 and
    conductor 67 over Q,
    Modular abelian variety 67B of dimension 2, level 67 and
    conductor 67^2 over Q,
    Modular abelian variety 67C of dimension 2, level 67 and
    conductor 67^2 over Q
]
> for A in D do print #(A meet G); end for;
4
1
1
> G2 := nTorsionSubgroup(D[2],2);
> G3 := nTorsionSubgroup(D[3],2);
> H := G + G2 + G3;
> #H;
64
> H eq nTorsionSubgroup(J,2);
false
> #nTorsionSubgroup(J,2);
1024
> G2 eq G3;
true
> G meet G2;
{ 0 }: finitely generated subgroup of abelian variety with invariants []

```

## Underlying Abelian Group and Lattice

### `AbelianGroup(G): ModAbVarSubGrp -> GrpAb, Map, Map`

Let $G$ be a finitely generated subgroup of an abelian variety $A$. Return an abstract abelian group $H$ which is isomorphic to $G$ along with isomorphisms in both directions.

### `Lattice(G): ModAbVarSubGrp -> Lat`

Let $G$ be a finite torsion subgroup of its ambient abelian variety $A$ whose elements are all known exactly, i.e. $G$ is generated by elements of $H_1(A,{\mathbb{Q}})/H_1(A,{\mathbb{Z}})$. Return the lattice $L$ in the rational homology of $A$ generated by $H_1(A,{\mathbb{Z}})$ and all $x$ such that $G$ can be viewed as a set of equivalence classes of the form $x+H_1(A,{\mathbb{Z}})$.

### `Example: Subgrp Underlying Abelian Group And Lattice (ex-0af396)`

This examples illustrate these commands for the $3$-torsion subgroup of $J_0(11)$.

```magma
> A := JZero(11);
> G := nTorsionSubgroup(A,3);
> H,f,g := AbelianGroup(G);
> H;
Abelian Group isomorphic to Z/3 + Z/3
Defined on 2 generators
Relations:
    3*H.1 = 0
    3*H.2 = 0

```

The lattice of $G$ is $1/3$ times the integral homology.

```magma
> Lattice(G);
Lattice of rank 2 and degree 2
Basis:
[Identity matrix]
Basis Denominator: 3
> L := IntegralHomology(A); L;
Standard Lattice of rank 2 and degree 2
> Lattice(G)/L;
Abelian Group isomorphic to Z/3 + Z/3
Defined on 2 generators
Relations:
    3*$.1 = 0
    3*$.2 = 0

```

## Invariants

### `AmbientVariety(G): ModAbVarSubGrp -> ModAbVar`

Let $G$ be a finitely generated subgroup of an abelian variety. Return the abelian variety whose elements were used to create $G$.

### `Exponent(G): ModAbVarSubGrp -> RngIntElt`

Given a finitely generated subgroup $G$ of an abelian variety, return the smallest positive integer $e$ which kills $G$, i.e. such that $eG = 0$. We assume $G$ is finite.

### `Invariants(G): ModAbVarSubGrp -> SeqEnum`

Given a finitely generated subgroup of an abelian variety, return the invariants of an abstract abelian group isomorphic to $G$.

### `Order(G): ModAbVarSubGrp -> RngIntElt`

### `# G: ModAbVarSubGrp -> RngIntElt`

Given a finitely generated subgroup $G$ of an abelian variety, return the number of elements in $G$, when $G$ is known to be finite (an error occurs otherwise).

### `FieldOfDefinition(G): ModAbVarSubGrp -> Fld`

Given a finitely generated subgroup $G$ of an abelian variety return a field over which the group $G$ is defined. This is a field $K$ such that if $\sigma$ is an automorphism that fixes $K$, then $\sigma(G)=G$. Note that $K$ *is not guaranteed to be minimal*.

### `Example: Subgrp Invariants (ex-df8fad)`

We illustrate each command using the kernel of $T_3$ on $J_0(67)$.

```magma
> A := JZero(67);
> T3 := HeckeOperator(A,3);
> G := Kernel(T3); G;
Finitely generated subgroup of abelian variety with
[ 2, 2 ]
> AmbientVariety(G);
Modular abelian variety JZero(67) of dimension 5 and level 67 over Q
> Exponent(G);
2
> Invariants(G);
[ 2, 2 ]
> Order(G);
4
> #G;
4

```

The field of definition of $G$ is ${\mathbb{Q}}$, since $G$ is the kernel of a homomorphism defined over ${\mathbb{Q}}$ (a Hecke operator).

```magma
> FieldOfDefinition(G);
Rational Field

```

However, the field of definition of the subgroup of $G$ generated by one of the elements of $G$ could take significant extra work to determine. Currently Magma simply chooses the easiest answer, which is $\overline{{\mathbb{Q}}}$.

```magma
> H := Subgroup([G.1]);
> FieldOfDefinition(H);
Algebraically closed field with no variables

```

## Predicates and Comparisons

A subgroup $G$ of an abelian variety is finite exactly when every element of $G$ is known exactly, since then all elements are torsion and $G$ is finitely generated.

Abelian varieties and subgroups thereof can be tested for inclusion and equality. Equality and subset testing is liberal, in that if the ambient varieties containing the two groups are not equal, then Magma attempts to find a natural embedding of both subgroups into a common ambient variety, and checks equality or inclusion there.

### `IsFinite(G): ModAbVarSubGrp -> RngIntElt`

Return `true` if the subgroup $G$ of a modular abelian variety is known to be finite, i.e., generated by torsion elements. If $G$ is not known exactly, i.e., has elements defined by floating point approximations to homology, then return `false`.

### `G1 subset G2: ModAbVarSubGrp, ModAbVarSubGrp -> BoolElt`

Return `true` if $G1$ is a subset of $G2$, where $G1$ and $G2$ are both subgroups of modular abelian varieties.

### `G subset A: ModAbVarSubGrp, ModAbVar -> BoolElt`

Return `true` if the subgroup $G$ is a subset of the abelian variety $A$. If $A$ is not the ambient variety of $G$, then $G$ and $A$ are first mapped to a common ambient variety and compared.

### `A subset G: ModAbVar, ModAbVarSubGrp -> BoolElt`

Return `true` if the abelian variety $A$ is a subset of the finitely generated subgroup $G$ of a modular abelian variety. This is true only if $A$ is a point, i.e., the $0$ dimensional abelian variety.

### `G1 eq G2: ModAbVarSubGrp, ModAbVarSubGrp -> BoolElt`

Return `true` if the subgroups $G_1$ and $G_2$ of modular abelian varieties are equal.

### `Example: Subgrp Predicates And Comparisons (ex-50d5c0)`

We work with $J_0(389)$, but work in the $+1$ quotient of homology for efficiency. First we let $A$ and $B$ be the first and fifth factors in the decomposition of $J$, and let $G$ and $H$ be the corresponding $5$-torsion subgroups.

```magma
> J := JZero(389,2,+1);
> D := Decomposition(J);
> A := D[1];
> B := D[5];
> G := nTorsionSubgroup(A,5);
> H := nTorsionSubgroup(B,5);

```

Note that the torsion subgroups aren’t as big because we are working in the $+1$ quotient.

```magma
> #G;
5
> #H;
95367431640625

```

We now demonstrate each of the above commands for $A$, $B$, $G$, and $H$.

```magma
> IsFinite(G);
true
> A subset G;
false
> ZeroModularAbelianVariety() subset G;
true
> G subset A;
true
> G subset B;
true
> H subset A;
false

```

Since the ambient varieties of $G$ and $H$ are $A$ and $B$, respectively, the following commands implicitly embed $G$ and $H$ into $J_0(389)$ and make comparisons there.

```magma
> G subset H;
true
> G eq H;
false
> G eq G;
true

```

```magma
> J := JZero(37);
> A, B := Explode(Decomposition(J));
> A2 := Kernel(nIsogeny(A,2));
> B2 := Kernel(nIsogeny(B,2));
> A2 eq B2;
true
> x := A2.1;
> x in B2;   // uses embedding of both into $J_0(37)$.
true

```
