# Modular Curves and Quotients (Canonical Embeddings)

## `ModularCurveQuotient(N, A): RngIntElt, [RngIntElt] -> Crv`

```magma
Raw   : BoolElt                    Default: false
Reduce: BoolElt                    Default: false
```

Given a level $N$ and a (possibly empty) set of Atkin-Lehner involutions represented as a sequence of integers $A$, this function computes a model for a quotient of $X_0(N)$ by $A$. When `Raw` is not set to `true`, an initial “semi-reduction” is not performed. If the `Reduce` option is `true`, then a complete `LLL`-reduction is performed on the resulting equations (this is impractical for genus greater than 50 or so). The returned curve can be: $P^1$ for a genus 0 curve, an elliptic or hyperelliptic curve, or the canonical embedding of the curve in $P^{g-1}$ where $g$ is the genus of the quotient curve (in this general case, the coordinates correspond to cusp forms invariant under the specified Atkin-Lehner involutions).

## `X0NQuotient(N, A): RngIntElt, [RngIntElt] -> Crv`

```magma
Raw   : BoolElt                    Default: false
Reduce: BoolElt                    Default: false
```

The same as `ModularCurveQuotient`, and the name used in the example below.

## `X0Nplus(N): RngIntElt -> Crv`

The modular curve $X_0(N)^+$, the quotient of $X_0(N)$ by the Fricke involution $w_N$. This is `X0NQuotient(N, [N])`.

## `X0Nstar(N): RngIntElt -> Crv`

The modular curve $X_0(N)^*$, the quotient of $X_0(N)$ by the group generated by all of its Atkin-Lehner involutions. This is `X0NQuotient(N, A)` for `A` the sequence of prime powers $p^{v_p(N)}$ over the primes $p$ dividing $N$.

## `GenusX0N(N): RngIntElt -> RngIntElt`

The genus of $X_0(N)$, computed from the standard formula rather than by constructing the curve.

## `GenusX1N(N): RngIntElt -> RngIntElt`

The genus of $X_1(N)$, computed from the standard formula rather than by constructing the curve.

## `GenusX0NQuotient(N, As): RngIntElt, [RngIntElt] -> RngIntElt`

The genus of the quotient of $X_0(N)$ by the group of automorphisms generated by the Atkin-Lehner involutions $w_A$ for $A$ in `As`, computed without constructing the quotient. Each $A$ must satisfy $A > 1$, $A \mid N$ and ${\rm GCD}(A, N/A) = 1$.

## `AtkinLehnerNumberOfFixedPoints(N, A): RngIntElt, RngIntElt -> RngIntElt`

The number of fixed points of the Atkin-Lehner involution $w_A$ acting on $X_0(N)$. Both $N$ and $A$ must be greater than $1$, with $A \mid N$ and ${\rm GCD}(A, N/A) = 1$.

## `Example: X0n Quotient (ex-5d6c55)`

We compute a model for $X_0(13\cdot 29)$ quotiented by the Atkin-Lehner involutions $w_{13}$ and $w_{29}$.

```magma
> C := X0NQuotient(13*29,[13,29]); C; // defined by cubics in P^4
Curve over Rational Field defined by
-x[1]*x[2]^2 + x[1]*x[2]*x[3] - x[2]^2*x[3] + x[1]*x[2]*x[4] +
    x[2]^2*x[4] + x[2]*x[4]^2 + x[1]*x[2]*x[5],
x[1]*x[2]^2 - x[2]^3 - x[2]^2*x[3] + x[1]*x[2]*x[5] + x[2]^2*x[5] +
    x[2]*x[4]*x[5],
x[1]*x[2]*x[3] - x[2]^2*x[3] - x[2]*x[3]^2 + x[1]*x[3]*x[5] +
    x[2]*x[3]*x[5] + x[3]*x[4]*x[5],
x[1]*x[2]*x[5] - x[2]^2*x[5] - x[2]*x[3]*x[5] + x[1]*x[5]^2 +
    x[2]*x[5]^2 + x[4]*x[5]^2,
-x[1]^2*x[2] + x[1]*x[2]^2 + x[1]*x[2]*x[3] - x[1]^2*x[5] -
    x[1]*x[2]*x[5] - x[1]*x[4]*x[5],
x[1]*x[2]*x[3] + x[2]^2*x[4] + x[2]*x[3]*x[4] + x[2]*x[4]*x[5] +
    x[3]*x[4]*x[5] + x[2]*x[5]^2 + x[4]*x[5]^2,
x[1]*x[2]*x[3] + x[1]*x[2]*x[4] + x[1]*x[2]*x[5] - x[1]*x[3]*x[5] -
    x[3]^2*x[5] + x[1]*x[4]*x[5] - x[2]*x[4]*x[5] - x[3]*x[4]*x[5] +
    x[1]*x[5]^2 + x[3]*x[5]^2,
-x[1]*x[2]*x[4] + x[1]*x[3]*x[4] - x[2]*x[3]*x[4] + x[1]*x[4]^2 +
    x[2]*x[4]^2 + x[4]^3 + x[1]*x[4]*x[5],
-x[1]*x[2]*x[3] + x[1]*x[3]^2 - x[2]*x[3]^2 + x[1]*x[3]*x[4] +
    x[2]*x[3]*x[4] + x[3]*x[4]^2 + x[1]*x[3]*x[5],
-x[1]*x[2]*x[5] + x[1]*x[3]*x[5] - x[2]*x[3]*x[5] + x[1]*x[4]*x[5] +
    x[2]*x[4]*x[5] + x[4]^2*x[5] + x[1]*x[5]^2,
x[1]*x[2]*x[4] - x[2]^2*x[4] - x[2]*x[3]*x[4] + x[1]*x[2]*x[5] -
    x[1]*x[3]*x[5] + x[2]*x[3]*x[5] - x[1]*x[5]^2,
-x[1]^2*x[3] - x[1]*x[2]*x[3] + x[1]*x[3]^2 - x[2]*x[3]^2 -
    x[1]*x[2]*x[4] - x[3]^2*x[4] - x[2]*x[4]^2 + x[1]*x[3]*x[5] -
    x[2]*x[4]*x[5] - x[4]^2*x[5] - x[1]*x[5]^2,
-x[1]^2*x[2] + x[1]*x[2]^2 + x[2]^2*x[3] + x[1]^2*x[4] -
    x[1]*x[3]*x[4] + x[2]*x[3]*x[4] + x[3]*x[4]^2 + x[1]^2*x[5] -
    x[1]*x[3]*x[5] - x[3]^2*x[5] - x[1]*x[4]*x[5] - x[3]*x[4]*x[5] +
    x[2]*x[5]^2 + x[3]*x[5]^2 + x[4]*x[5]^2,
-x[1]^2*x[2] + x[1]^2*x[3] - x[1]*x[2]*x[3] + x[1]^2*x[4] +
    x[1]*x[2]*x[4] + x[1]*x[4]^2 + x[1]^2*x[5],
x[1]^2*x[2] + x[1]^2*x[3] - x[1]*x[2]*x[3] + x[2]^2*x[3] - x[1]*x[3]^2
    - x[3]^3 - x[1]*x[2]*x[4] + x[1]*x[3]*x[4] - x[2]*x[3]*x[4] -
    x[3]^2*x[4] + x[1]^2*x[5] + x[1]*x[3]*x[5] - x[2]*x[3]*x[5] +
    x[3]^2*x[5] - x[3]*x[4]*x[5] + x[1]*x[5]^2
> Genus(C);
5

```
