>There are five elementary arithmetical operations: addition, subtraction, multiplication, division, and… modular forms.
>$\qquad$-[Martin Eichler](https://en.wikipedia.org/wiki/Martin_Eichler), apocryphal
## Significance
The notion of modularity is fundamental in modern mathematics, and especially in number theory. For example, it is no accident that the celebrated Fermat's Last Theorem --- also called the Shimura-Taniyama conjecture --- is known in modern parlance as the [Modularity Theorem](https://mathworld.wolfram.com/Taniyama-ShimuraConjecture.html), proven by [Andrew Wiles](https://www.britannica.com/biography/Andrew-Wiles) by showing the $L$-functions of semistable elliptic curves correspond to modular forms. In another striking example, modularity was also key to the recent [Fields-medal winning proof determining optimal sphere packing in 8 and 24 dimensions](https://www.ams.org/publications/journals/notices/201702/rnoti-p102.pdf) by [Maryna Viazovska](https://people.epfl.ch/maryna.viazovska?lang=en). Even the celebrated [Riemann Hypothesis](https://www.claymath.org/millennium/riemann-hypothesis/), perhaps the most well known open problem in mathematics with a million dollar prize for its solution, is a statement about modular forms. This is because the Riemann $\zeta$ (zeta) function comes from a modular form.
Ultimately, it seems that modular forms know more than they should. Their coefficients encode a wealth of knowledge about various arithmetic and combinatorial structures, while the modular forms themselves are important tools in a large array of mathematical disciplines. What's more, since modular forms generally live in explicit finite-dimensional spaces, finding a modular connection to a problem you're working on gives you access to powerful computational techniques.
## Functions and Transformations: The Sine Function
Recall that a function is a "machine" that takes an "input" and produces a unique "output." The sine function is the function which takes an angle $x$ and outputs the ratio $\frac{\text{opposite}}{\text{hypotenuse}}$.
![[image-1.png|350]]
If you go all the way around a circle, you return to the same angle. Measuring in radians instead of degrees (so $2\pi$ radians = $360^\circ$), this means $\sin(x+2\pi)=\sin x$ for all $x$.
We call a transformation sending $x$ to $x+b$ for some $b$ a *translation.* Hence, we can say $\sin$ respects translations by $2\pi$. This means that we understand the $\sin$ function completely if we understand it on the interval $[0,2\pi)$.
![[image-2.png|350]]
We're going to write the translation by $2\pi$ by $T$, and write $T.x = x+2\pi$. Then another way to express the periodicity of $\sin$ is to write $\sin(T.x)=\sin x.$
In fact, we can write $\sin(T.(T.x))=\sin x,$ or nest any number of $T$ operations inside the $\sin$ functions. And, we can undo the $T$ translation. Let $T^{-1}.x = x-2\pi$, then $T.(T^{-1}.x) = x$ and $\sin(T^{-1}.x)=\sin x.$ Let $\mathbb{T}$ be the set of all powers of $T$. Mathematically, we write this as $\mathbb{T} := \{T^a: a\text{ an integer}\}.$ Hence, we can say: $\sin$ is invariant under $\mathbb T$.
## Modular Transformations
So far it may seem that we're overcomplicating a simple idea, and that our definitions amount to sophistry. It is useful to define everything very pedantically, however, because now we can apply our definitions to a more complicated case.
Instead of working with the familiar real numbers (denoted $\mathbb R$), we will now be working over the complex numbers. Much could be done to motivate the utility of complex numbers; for brevity we will simply say that they underpin the most important computations in math, science, and engineering.
We simply introduce the symbol $i$, with the rule that $i^2 = -1$. For now you'll have to take it on faith that introducing this unit is useful and self-consistent. Complex numbers are numbers of the form $x+iy$, where $x$ and $y$ are real numbers, and we denote the set of complex numbers by $\mathbb C:= \{x+iy:x,y\text{ in }\mathbb R\}.$ We can plot the complex number $z=x+iy$ by going over $x$ units and up $y$ units; we call $x$ the real part and $y$ the imaginary part.
![[image-3.png|350]]
There is a family of transformations we can do to the complex plane: one of these transformations is the translation (re-purposing our symbol $T$) $T z := z+1.$ Another is the transformation $Sz := -\frac{1}{z}.$ Together these transformations (together with all powers of these transformations) generate a special set called the Special Linear Group $\operatorname{Sl}_2(\mathbb Z):=\{\text{ all combinations of powers of }T,S\}.$ The transformations of $\operatorname{Sl}_2(\mathbb Z)$ on $\mathbb C$ are also called modular transformations.
But why are these modular transformations interesting? Well, they correspond essentially to "rotations" of the complex numbers. And just like it's useful to understand the sine function, which is invariant under translations, it is incredibly productive to understand functions which respect the transformations in $\operatorname{Sl}_2(\mathbb Z)$. These are the modular functions, and are a special case of modular forms.
**Definition** A *modular function* $f$ is a suitably "smooth" function of the complex numbers[^1] such that
$f(Tz)=f(z)$ and $f(Sz)=f(z)$ for all $z$.
## Application of Modular Functions
Already the notion of modular functions is incredibly useful and powerful. Here's an example.
Though you likely don't know it, the theory of elliptic curves is vitally important to your everyday life. [Elliptic Curve Cryptography](https://nordvpn.com/blog/elliptic-curve-cryptography/#:~:text=Communication%20protocols.,digital%20certificates%20for%20server%20authentication.) is one of the more pervasive forms of modern key-sharing encryption protocols on the internet, without which we wouldn't be able to use VPNs, do online banking, or securely access remote servers.
With this in mind, it would be useful to understand the structure of these elliptic curves. It turns out that a very elegant modular function has a deep and surprising connection to elliptic curves. First, we must note that elliptic curves are the sets of solutions to equations of the form $E: y^2 = x^3+bx+c$, where we consider $x$ and $y$ as variables, and that elliptic curves with different $b$ and $c$ values sometimes have the same structure. When this happens we say the elliptic curves are *isomorphic.*
Now, there is a natural way to assign a point in $\mathbb{C}$ to an elliptic curve; using this we have the following theorem.
**Theorem** There exists a modular function $j$ such that two elliptic curves $E,E'$ are isomorphic if and only if $j(E)=j(E').$
So already, without even introducing modular forms in their full generality, we have an application of the theory modular forms to the multi-billion dollar industry of internet commerce.
## Modular Forms
This is all well and good, but if modular functions are a special case of modular forms, then what are modular forms? Well, there are some technical details we swept under the rug. The pertinent detail in this case is that the set $\operatorname{Sl}_2(\mathbb Z)$ is actually an example of a *matrix group.* We don't need to worry too much about what "group" here means, though it is very important. For now we must content ourselves with the fact that matrices are simply rectangular arrays of numbers, and that you can multiply matrices together. So, for example, we can apply these operations to the $2\times 2$ matrices $\left(\begin{smallmatrix}1&1\\0&1\end{smallmatrix}\right)$ and $\left(\begin{smallmatrix}0&-1\\1&0\end{smallmatrix}\right)$ to get[^2] $\left(\begin{smallmatrix}1&1\\0&1\end{smallmatrix}\right)\left(\begin{smallmatrix}0&-1\\1&0\end{smallmatrix}\right)=\left(\begin{smallmatrix}1&-1\\1&0\end{smallmatrix}\right).$ We can now consider a the way these matrices "act" on complex numbers. For a matrix $\left(\begin{smallmatrix}a&b\\c&d\end{smallmatrix}\right)$ and a complex number $z$ we have the transformation $\left(\begin{smallmatrix}a&b\\c&d\end{smallmatrix}\right)z = \frac{az+b}{cz+d}.$ This seems like a random rule to pick, but it turns out that transformations of this form constitute essentially all of the well-behaved transformations of the complex numbers. And, even better, if we compute the transformations corresponding to the matrices $\left(\begin{smallmatrix}1&1\\0&1\end{smallmatrix}\right)$ and $\left(\begin{smallmatrix}0&-1\\1&0\end{smallmatrix}\right)$ we picked earlier, we have
$\left(\begin{smallmatrix}1&1\\0&1\end{smallmatrix}\right)z = z+1$ and $\left(\begin{smallmatrix}0&-1\\1&0\end{smallmatrix}\right)z = \frac{-1}{z},$
from our generators of the special linear group $\operatorname{Sl}_2(\mathbb{Z})$! In fact, a more accurate definition of $\operatorname{Sl}_2(\mathbb Z)$ is in terms of matrices, which we will do from now on. With this notation in mind, we can define modular forms.
**Definition** A modular form of weight $k$ is a suitably "smooth" function such that, for all $\left(\begin{smallmatrix}a&b\\c&d\end{smallmatrix}\right)$ in $\operatorname{Sl}_2(\mathbb Z)$, we have $f\left(\left(\begin{smallmatrix}a&b\\c&d\end{smallmatrix}\right)z\right) = (cz+d)^k f(z)$ for all $z$.
## Application of Modular Forms
It is a small miracle that modular forms are, somehow, exceptionally good at counting things. A classic example of the type of thing they can count is the partition function. Let $p(n)$ be the number of ways you can write $n$ as a sum of positive integers; for example, $4 = 3+1 = 2+1+1 = 2+2 = 1+1+1+1$ so $p(4)=5$.
Now, one consequence of being a modular form is that you have what's called a "$q$-series expansion". That is, if $f$ is modular you can write $f$ as $f(z) = a_0+a_1 q+a_2 q^2+...,$ where $q = e^{2\pi i z}$ and the $a_j$ are constants. If you don't understand what this means, don't fret. Just know that for every modular form this a unique string of data $a_0,a_1,a_2,...$ corresponding to that modular form, and that these numbers $a_0,a_1,a_2,...$ are like a fingerprint identifying that modular form.
Well, it turns out that the function which counts all of the $p(n)$, which we call its *generating function,* $P = p(0)+p(1)q+p(2)q^2+...,$is modular. And being modular is very convenient! One consequence of the modularity of the partition function is the celebrated Rademacher formula, which can be used to give very accurate approximations to $p(n)$ even when $n$ is very large (imagine trying to compute $p(100000)$.) And knowing about partitions, and $p(n)$, is quite useful, since these types of functions come up whenever you want to count things (for example, in quantum systems[^3].)
***
If you want a more in-depth introduction to the subject, you can read the notes I've written for my students.
>[!note]- Draft Notes --- Modular Curves PDF
>![[IGL Draft 2.pdf]]
***
[^1]: There is some hand-waving here.
[^2]: Note that matrix multiplication is *not* simply multiplying each part component-wise, but instead has its own special rules corresponding to "geometric" operations which we won't worry about for now.
[^3]: I'm fond of the account in [Chapter 5, The Boson-Fermion Correspondence: An Invitation to q-Series](https://mathscinet.ams.org/mathscinet-getitem?mr=2797376).