# Deriving a formula for the genus of the modular curve X(N)

Hi all! In this post, we’ll show how we can use the Riemann-Hurwitz formula to derive the genus of the modular curve $X(N)$. But what is $X(N)$?

The group $\mathrm{SL}_2(\mathbf{Z})$ acts on the complex upper half-plane, denoted $\mathfrak{H}$. Let $\Gamma$ be a congruence subgroup of this group, i.e., a group containing the principal congruence subgroup of level N, $\Gamma(N)$, defined as $\Gamma(N)=\left\{ \begin{pmatrix} a & b\\ c & d\\ \end{pmatrix} : \ a \equiv d \equiv \pm 1 \mod N \text{ and } b, c \equiv0 \mod N \right\}.$ The quotient $\Gamma\backslash \mathfrak{H}$ is a noncompact Riemann surface, denoted $Y(\Gamma)$. Its compactification, denoted $X(\Gamma)$, is the quotient $\Gamma\backslash (\mathfrak{H}\cup\mathbf{Q}\cup\{\infty\})$. We remark that $\mathfrak{H}\cup\mathbf{Q}\cup\{\infty\}$ is called the extended complex upper half-plane, and is given a topology by choosing a particular basis. The cusps of $\Gamma$ are elements of the orbit of the action of $\Gamma$ on $\mathbf{Q}\cup\{\infty\}$.

If $\Gamma=\Gamma(N)$, the principal congruence subgroup of level N, then $X(\Gamma)$ is denoted $X(N)$. If $\Gamma=\mathrm{SL}_2(\mathbf{Z})$, $X(\Gamma)$ is isomorphic as a Riemann surface to $\mathbf{C}\cup\{\infty\}\cong\mathbf{P}^1\mathbf{C}\cong S^2$. Now, $\Gamma(1)\simeq \mathrm{SL}_2(\mathbf{Z})$, so $X(1)\cong S^2$. It therefore has genus $0$. Now, we have a map $X(\Gamma)\to X(\mathrm{SL}_2(\mathbf{Z}))$ coming from the inclusion $\mathrm{P}\Gamma\subset\mathrm{PSL}_2(\mathbf{Z})$. We will prove, using the Riemann-Hurwitz formula, the following equation for $N>2$:

$g(X(N))=g(X(N))=1+\dfrac{N^2(N-6)}{12}\prod_{p|N}\left(1-\dfrac{1}{p^2}\right)$

Where $e_i$ is the number of elliptic points of order $i$, and $c$ is the number of cusps.

How do we go about proving this? First recall the Riemann-Hurwitz formula: if $X\to Y$ is a surjective morphism of Riemann surfaces of degree $d$, let $e_x$ denote the ramification degree at $x$. Then

$2g(X)-2 = d(2g(Y) - 2) + \sum_{x\in X}(e_x - 1).$

There’s a statement in the following proof which I don’t understand, and would like to.  If $X\to Y$ is Galois, the $e_x$ in the fibers of each $y\in Y$ is equal, this becomes

$2g(X)-2 = d\left(2g(Y) - 2 + \sum_{y\in Y}\left(1-\dfrac{1}{e_y}\right)\right).$

The map $X(N)\to X(1)$ is Galois, so the indices $e_x$ are the same for $x$ over a $y\in X(1)$. The degree of this map is $[\mathrm{PSL}_2(\mathbf{Z}):\mathrm{P}\Gamma]$ (the number of preimages of generic points of $X(\mathrm{SL}_2(\mathbf{Z}))$). If $N>2$, this is explicitly $\dfrac{1}{2}N^2\prod_{p|N}\left(1-\dfrac{1}{p^2}\right)$.

We need to compute the ramification degree $e_\infty$. The fiber of $X(N)\to X(1)$ over $\infty$ is the $\Gamma(N)$-equivalence class of cusps, which, by the orbit stabilizer theorem, number $\#(\mathrm{SL}_2(\mathbf{Z})/\Gamma(N))/\# R$ where $R$ is the stabilizer of $\Gamma(N)\infty$ (a coset) in $\mathrm{SL}_2(\mathbf{Z})/\Gamma(N)$ (which is isomorphic to $\mathrm{SL}_2(\mathbf{Z})/N\mathbf{Z})$). Thus $R$ is the subgroup consisting of matrices $\begin{smallmatrix} 1&k\\ 0&1 \end{smallmatrix}$ such that $0\leq k\leq N-2$, and $\# R=2N$. Consequently, $e_\infty=N$.

Cool. Now, the ramfications of $X(N)\to X(1)$ are over $\infty$, $0$, and $12^3=1728$. For the map in consideration, $e_0=3$ and $e_{1728}=3$ (I don’t think I understand why, perhaps it’s a simple error on my part). Thus, because $X(N)\to X(1)$ is Galois, using the Riemann-Hurwitz formula, we get:

$2g(X(N)) - 2 = \dfrac{1}{2}N^2\prod_{p|N}\left(1-\dfrac{1}{p^2}\right)\left(0-2+\left(1-\dfrac{1}{e_0}+1-\dfrac{1}{e_{1728}}+1-\dfrac{1}{N}\right)\right)=\dfrac{1}{2}N^2\prod_{p|N}\left(1-\dfrac{1}{p^2}\right)\left(\dfrac{1}{N}-\dfrac{1}{6}\right)$

Solving for $g(X(N))$ gives us the required formula. QED.

Here are the first few values of $g(X(N))$: $g(X(1))=g(X(2))=g(X(3))=g(X(4))=g(X(5))=0$, $g(X(6))=1$, $g(X(7))=3$, $g(X(8))=5$. It’s some fun stuff, and I hope to continue to learn more of it! If anyone can tell me why $e_0=3$ and $e_{1728}=3$, it would be greatly appreciated!

Have fun!
SKD