Elliptic Functions, Doughnuts, and a Secret Integration Technique

Either math makes no sense at all, or integration by substitution is much deeper and more profound than we've given it credit for. I hope to convince you of the latter…

Elliptic Functions, Doughnuts, and a Secret Integration Technique

Anil Venkatesh
Adelphi University

Introduction

Let's start with some pictures. What's the area of the blue region shown below? By the way the curve bends, the answer must be slightly more than the area of the triangle inside it. If you've taken calculus before, this is a good time to dust off your integration skills!

The region under the curve sin(x/3) from 0 to pi, and a triangle inside it that closely approximates the region.
The region under the curve $\sin(x/3)$ from 0 to $\pi$, and a triangle inside it.

The standard way we learn to approach such problems is called integration by substitution, in which we algebraically replace the independent variable with something that simplifies the problem. In the case of $\sin(x/3)$, we introduce a new variables $u = x/3$ so that the problem reduces to $\sin(u)$. A funny thing happens when you change variables, though: area is not preserved! Below, we see that the region shrinks by a factor of three when we change from $\sin(x/3)$ to $\sin(u)$. When we change variables like this, we need to remember to correct for the shrinkage factor. Here, that factor can be computed using the somewhat illegal-looking calculation $\frac{du}{dx} = \frac{1}{3} \implies 3 du = dx$, meaning that we have to multiply our result by 3 if we solve the problem in terms of $\sin(u)$.

Graphical effect of changing variables from sin(x/3) to sin(u). The brown stripes in the second, narrower curve
have 1/3 of the area of the blue stripes in the first curve.
Graphical effect of changing variables from $\sin(x/3)$ to $\sin(u)$. The brown stripes
have 1/3 of the area of the blue stripes.

Things get murkier when the change of variables is nonlinear. Consider the blue-striped region below, formed by the function $\sin(x^2/4)$. By setting $u = x^2/4$ we can still equate this function to $\sin(u)$ as we did before. However, $u$ is no longer a linear function of $x$ so the shrinkage/stretch factor is no longer uniform. Instead, some parts of the region are narrower than before, while others are wider. There is no constant multiple we can use to correct our calculation if we solve this problem in terms of $\sin(u)$. In fact, there is no formula in terms of elementary functions for the area of the blue-striped region!

Graphical effect of changing variables from sin(x^2/4) to sin(u). There is no simple way to relate the blue and brown stripes to each other.
Graphical effect of changing variables from $\sin(x^2/4)$ to $\sin(u)$. There is no simple way to relate the blue and brown stripes to each other.

In order for a nonlinear change of variables to be helpful, we need to compute the (nonconstant) shrinkage factor that it implies and incorporate this second piece into the calculation. Consider the function $\frac{2x}{1+x^2}$ whose area from 0 to 1 is shown below in blue stripes. By setting $u = x^2$, we obtain the shrinkage factor like so: $\frac{du}{dx} = 2x \implies \frac{1}{2x} du = dx$. Therefore, the corresponding function of $u$ is $\frac{2x}{1+u} \cdot \frac{1}{2x}$ or simply $\frac{1}{1+u}$. Because the shrinkage factor perfectly cancelled the remaining $x$ in the function, we are left with a simple function of $u$ whose area is exactly the same as that of the original function of $x$.

Amazingly, each brown stripe under the second curve has the same area as the corresponding blue stripe under the first curve, even though the first curve is concave down on this region and the second curve is concave up.
Graphical effect of changing variables from $\frac{2x}{1+x^2}$ to $\frac{1}{
1+u}$ by the substitution
$u = x^2$. Amazingly, each brown stripe has the same area as the corresponding blue stripe.

Trigonometric Substitution

So far, the upshot has been that when we're computing the area enclosed by a function, we can change variables from $x$ to $u$ and as long as we carefully account for the shrinkage factor, the resulting function of $u$ can be used to compute the area instead. If the new function is algebraically simpler than the original one, it may help us compute the area. The topic I want to introduce now throws this very lovely intuition out the window so forcefully that we're left with only two possible explanations: either math makes no sense at all, or integration by substitution is much deeper and more profound than we've given it credit for. I hope to convince you of the latter, obviously!

Let's jump right in. How would you go about integrating the function $\frac{1}{\sqrt{1-x^2}}$ from 0 to 1? You can try things like $u = x^2$, but the problem with that approach is that there's nothing for the shrinkage factor of $\frac{1}{2x}$ to cancel with. Instead, the correct substitution is $x = \sin u$. Before we even entertain this move, let's stop and consider how preposterous it is. First of all, it's not even expressed in terms of $u=\cdots$, completely breaking with all the previous examples. And anyway, where in the world did $\sin$ come from? Who would think of this? That's how I felt when I was first shown this problem, anyway. But we've come this far so let's see it through. We compute the shrinkage factor by differentiating both sides, yielding $dx = \cos(u) du$. This means that we can rewrite the original function as $\frac{1}{\sqrt{1 - \sin^2u}} \cdot \frac{\cos u}{1}$. Using a famous trigonometric identity, this simplifies to $\frac{1}{\sqrt{\cos^2 u}} \cdot \frac{\cos u}{1}$ or… just the number 1? Since $x$ ranges from 0 to 1, $u$ must range from 0 to $\pi/2$ and the area of the blue-striped region is the same as that of the rectangle of height 1 and width $\pi/2$.

Graphical effect of changing variables by the substitution
u = x^2. The second function looks constant, and each brown stripe under the second function has the same area as the corresponding blue stripe under the first function.
Graphical effect of changing variables from $\frac{2x}{1+x^2}$ to $\frac{1}{1+u}$ by the substitution
$u = x^2$. Amazingly, each brown stripe has the same area as the corresponding blue stripe.

At this point, any intuition for shrinkage factors has been lost and what's left is a purely algebraic device that hinged on finding the substitution $x = \sin u$. We need to find another source of intuition for this to start making sense. But first, I have a confession to make: this last example isn't well defined.

Well, Defined?

In ordinary language, we have an intuitive sense for ambiguity. If your friend offered to meet you at "the bar" after work, you'd probably ask which bar they meant. Ordinarily, we only use the definite article "the" when it's absolutely clear that there's only one thing in the world we could be referring to. The distinction between "the" and "a/an" doesn't translate neatly into mathematical notation, so when we write down a calculus problem, the reader is left to infer whether we have a unique answer in mind. For example, the notation $\int_1^2 \frac{1}{x} dx$ is customarily read as "the integral of $\frac{1}{x}$ from 1 to 2," implying that there is a unique answer. Consider though: is there really only one way to get from 1 to 2?

Even when the start and end of an integral are real numbers, it's possible for the path between them to veer off into the complex plane. Some functions have path-independent integrals, making this possibility academic, but $\frac{1}{x}$ does not. Consider the path that first makes a full loop around the unit circle, then proceeds as normal from 1 to 2. Unless the integral of $\frac{1}{x}$ around the unit circle works out to be zero, this path won't yield the same integral as the one that proceeds directly from 1 to 2.

Here is the integral whose path loops around the unit circle.
\[
\oint_{|x| = 1} \frac{1}{x} dx \]
Let $x = e^{i\theta}$. This parameterizes the unit circle as $\theta$ runs from $0$ to $2\pi$.

\begin{align*}
dx &= i e^{i\theta} d\theta \\
\oint_{|x| = 1} \frac{1}{x} dx &= \int_0^{2\pi} \frac{1}{e^{i\theta}} \frac{i e^{i\theta}}{1} d\theta \\
&= \int_0^{2\pi} i d\theta = 2\pi i.
\end{align*}
The integral isn't zero!

What we've shown here is that the integral of $\frac{1}{x}$ picks up a copy of $2\pi i$ for every time the path winds (counterclockwise) around the origin of the complex plane. This means that $\int \frac{1}{x} dx$ is not path-independent: its value can only be determined up to a multiple of $2\pi i$. (This integral ends up living in a corkscrew shape floating above the complex plane. To see why, check out my earlier piece on hyperoperations!)

Generally, we have to be cautious whenever the path of integration loops around a pole of the function, e.g., a place at which the function would divide by zero. These are the places that can cause path dependence. In the case of the function $\frac{1}{\sqrt{1-x^2}}$, there are poles at $x=1$ and $x=-1$. Also, the square root in the function has two possible values (we simply ignore the negative one sometimes). To address these sources of indeterminacy, we start with two copies of the complex plane—one for each branch of the square root—and cut along the lines shown below to block any path from fully looping around a pole.

Two copies of the complex plane are split along the real axis when x is greater than or less than one.
Make a copy of the complex plane for each branch of the square root function.
Then cut from each pole along the axis and spread the cuts apart.

The precise reason why $\int \frac{1}{\sqrt{1-x^2}} dx$ is not path-independent is that the function hops from one branch of the square root to the other as we loop around either pole. This means that the domain of the integral is actually the space that's obtained by gluing the two copies of the plane together along the corresponding cuts. The figure below depicts this process, where we first spread the cut edges apart and then align each cut with its counterpart to form a cylinder.

Two copies of the complex plane are bent into half-cylinders.
Two copies of the complex plane yield a cylinder when glued along the specified
cuts.

The central circle in the diagram is formed by two arcs: the path from $-1$ to 1 in the positive branch followed by the path from 1 back to $-1$ in the negative branch. What's the integral of the function around this circle? The graphical investigation in the introduction showed us that $\int_0^1 \frac{1}{\sqrt{1-x^2}} dx = \pi/2$, so by symmetry we quickly conclude:

\begin{align*}
\int_{-1}^1 \frac{1}{\sqrt{1-x^2}} dx + \int_1^{-1} \frac{-1}{\sqrt{1-x^2}} dx &= (\pi) - (-\pi) = 2\pi.
\end{align*}

This means that $\int \frac{1}{\sqrt{1-x^2}} dx$ is only well defined up to a multiple of $2\pi$ as we have no way of knowing how many times the path of integration loops around the cylinder along the way.

Calculus superfans will have been wondering when $\arcsin(x)$ would come up, as this is the textbook solution to $\int \frac{1}{\sqrt{1-x^2}} dx$. The figure below shows where the indeterminacy of $2\pi$ can be found in this solution. Usually, this is explained by appealing to the fact that $\sin(x)$ is periodic, hence its inverse doesn't pass the vertical line test. However, we arrived at this conclusion the other way around, discovering indeterminacy in an integral purely by constructing a topological space for it to live in. This kind of indeterminacy is called a period of the space, a nod to the underlying periodic function that it corresponds to.

Rotating the sin function 90 degrees offers several possible choices for the arcsin function. The choice with values between -pi/2 and pi/2 is highlighted.
The arcsin function has a hidden indeterminacy of $2\pi$.

Elliptic Integrals

For our last act, let's look at the integral of the form $\int \frac{1}{\sqrt{x(x-1)(x-\lambda)}}dx$ where $\lambda$ is some constant other than 1. If you've taken calculus, now might be a good time to try a few integration techniques and convince yourself that nothing in the standard toolkit can crack this problem. As with the function $\frac{1}{\sqrt{1-x^2}}$, we'll start by looking for possible sources of indeterminacy in the integral. The square root again implies a positive and negative branch, but this time there are three poles rather than two. In order to prevent the path of integration from looping around any of these, we make branch cuts as shown below.

Cutting identical slits in two copies of the complex plane: from -1 to infinity along the real axis as well as a second slit diagonally from 1 to a value lambda
Make a copy of the complex plane for each branch of the square root function. Then make the labeled cuts and spread them apart.

Gluing the two planes together along these cuts results in… what exactly? A cylinder with a hole punched through it? (Practitioners of the dark art of projective space will recognize this shape as a torus, i.e., the surface of a donut.) The presence of this extra hole means that there are two different kinds of loops that can yield indeterminacy, resulting in periods we'll call $\omega_1$ and $\omega_2$ instead of the single period of $2\pi$ that we saw before. This means that $\int \frac{1}{\sqrt{x(x-1)(x-\lambda)}}dx$ is only well defined up to addition of a number of the form $n_1\omega_1 + n_2\omega_2$, where $n_1$ and $n_2$ are whole numbers.

The two copies of the complex plane with slits cut in them are curved into two halves of a donut shape.
Two copies of the complex plane yield a pierced cylinder when glued along the specified cuts.

The integral $\int \frac{1}{\sqrt{1-x^2}} dx$ has an indeterminacy of $2\pi$, which directly corresponds to the period of $\sin(x)$. What holds these two facts together is that the inverse function of $\sin(x)$ is an antiderivative of $\frac{1}{\sqrt{1-x^2}}$. By contrast, the integral $\int \frac{1}{\sqrt{x(x-1)(x-\lambda)}}dx$ has two independent sources of indeterminacy, $\omega_1$ and $\omega_2$. This posits the existence of a function $\wp(x)$ that has period $\omega_1$ in one direction and $\omega_2$ in a different direction: a doubly periodic function of the complex plane.

Here's a comparison of the properties of $\sin(x)$ and $\wp(x)$:

\begin{align*}
\sin(x+2\pi) = \sin(x) \qquad & \wp(x+\omega_1) = \wp(x) = \wp(x+\omega_2) \\
\frac{d}{dx} \sin x = \sqrt{1 - (\sin x)^2} \qquad & \wp'(x) = \sqrt{\wp(x)(\wp(x)-1)(\wp(x)-\lambda)}
\end{align*}

By putting $x = \wp(u)$, we compute the shrinkage factor of $dx = \wp'(u) du$ and write
\begin{align*}
\int \frac{1}{\sqrt{x(x-1)(x-\lambda)}}dx &= \int \frac{1}{\sqrt{\wp(u)(\wp(u)-1)(\wp(u)-\lambda)}} \frac{\wp'(u)}{1} du \\
&= \int \frac{1}{\wp'(u)} \frac{\wp'(u)}{1} du \\
&= \int 1 du = u + C \\
&= \wp^{-1}(x) + C.
\end{align*}

And there you have it: integration by elliptic substitution. If this piqued your interest, I challenge you to work out the elliptic substitution that corresponds to the $\sec^2 u = 1 + \tan^2 u$ identity. You may be surprised by the outcome…

Ends and Beginnings

I'd like to close by pointing out some directions of further study.

  • Elliptic functions: the function $\wp$ is an example of an elliptic function, the umbrella term for special functions like $e^x$, $\sin(x)$, and the hyperbolic trigonometric functions such as $\tanh(x)$. The famous identities such as $e^{x+y} = e^x e^y$ and $\sin(2x) = 2\sin(x)\cos(x)$ are special cases of a fundamental property of all elliptic functions called the algebraic addition theorems. These theorems are a jumping-off point into number theory, famously explored by Srinivasa Ramanujan and his collaborators.
  • Elliptic curves: our topological construction of the punctured cylinder is a rough sketch of the proof that equations of the form $y^2 = x^3 +\cdots$ describe toroidal (i.e., donut-like) surfaces. These surfaces are called elliptic curves because they were first contemplated in the computation of the arc length of ellipses. Elliptic curves are found all over the field of number theory, including cryptography. The Birch and Swinnerton-Dyer conjecture is a major open problem relating to elliptic curves that is among the remaining six unsolved Millennium Prize Problems of the Clay Mathematics Institute.
  • Just as $2\pi$ arises as the period of a cylinder when studying the function $\frac{1}{\sqrt{1-x^2}}$, other functions yield periods involving similarly noteworthy numbers such as $\zeta(2) = \pi^2/6$, $\zeta(4) = \pi^4/90$, and generalizations of these called the multiple zeta values. The question of whether a given pair of periods has an algebraic relation is a major open problem in number theory and the observation that periods have a tendency to be transcendental numbers (like $\pi$) has ties to the Hodge conjecture, another one of the unsolved Millennium Prize Problems.
  • For more on the periods of doughnuts and a surprising connection to particle physics, see the July 2023 Feature Column Putting a period on mathematical physics.

1 Comment

  1. I found your article well written and illuminating. Thank you for preparing and sharing it!

Leave a Reply

Your email address will not be published. Required fields are marked *

HTML tags are not allowed.

59,571 Spambots Blocked by Simple Comments