# When is an elliptic integral expressible in terms of elementary functions?

After seeing this recent question asking how to calculate the following integral

$$\int \frac{1 + x^2}{(1 - x^2) \sqrt{1 + x^4}} \, dx$$

and some of the comments that suggested that it was an elliptic integral, I tried reading a little bit on the Wikipedia article about elliptic integrals. It seems that the point is that most elliptic integrals cannot be expressed in terms of elementary functions. The Wikipedia article defines an elliptic integral as an integral of the form

$$\int R \left( x, \sqrt{ P(x) } \right ) \, dx$$

where $R(x, y)$ is a rational function and $P(x)$ is a polynomial of degree $3$ or $4$ with no repeated roots.

Now, the article does mention in its introductory section that two exceptions in which the elliptic integrals can be expressed in terms of elementary functions are when the polynomial $P(x)$ has repeated roots or when the rational function $R(x, y)$ does not contain odd powers of $y$.

In the example in question we have $P(x) = 1 + x^4$ and

$$R(x, y) = \frac{1 + x^2}{(1 - x^2)y}$$

so certainly it does not correspond to the two exceptions mentioned before. Thus I have a couple of questions about this:

1) What are the conditions for an elliptic integral (as defined in the Wikipedia article) to be expressible in terms of elementary functions? More specifically, are the two above cited conditions the only exceptions or are there any others which may explain why the above integral is expressible in terms of elementary functions?

2) Depending on the answer to my first question, why is it that the above "elliptic integral" can be expressed in terms of elementary functions?

Note: I'm not sure but I suppose that some conditions must be put on the rational function $R(x, y)$ so to avoid trivial cases, but I don't want to speculate.

Thank you very much in advance.

• As far as I can tell, "elliptic integral" refers to a definite integral depending on a parameter, whereas you seem to be interested in the indefinite integral. Dec 28, 2010 at 18:31
• @Qiaochu Well yes, I wasn't sure about what to make of it since the mathworld entry for elliptic integral talks about the indefinite integral. And besides in the question I linked to the people who answered there seemed to talk about elliptic integrals when the integral was indefinite so I'm not sure... Dec 28, 2010 at 18:37
• The example in en.wikipedia.org/wiki/Risch_algorithm suggests that the answer involves the Galois group of P, but I don't know a general statement. Dec 28, 2010 at 18:57
• Apparently, beasts such as those in the linked question are known as "pseudoelliptic integrals" in that they resemble elliptic integrals, but degenerate to elementary functions. Apparently, if the quartic within the square root has no odd powers, the "elliptic integral" degenerates to elementary functions. I found this and this, for instance. Dec 29, 2010 at 2:12
• Just as a terminological comment: there are three "kinds" of elliptic integral, following the notation of Legendre and Jacobi. "Incomplete" integrals take two parameters (for the first two kinds; the third kind takes an additional third parameter): the amplitude $\phi$ and the modulus $k$. "Complete" integrals result when the amplitude is set to $\pi/2$. Any integral involving a rational function multiplied by the square root (or its reciprocal) of a cubic or quartic polynomial can be expressed in terms of elliptic integrals and logarithms. Dec 29, 2010 at 13:40

A consideration of Aryabhata's answer to the linked question shows that there is a map from the elliptic curve $y^2 = P(x)$ to the conic $v^2 = u^2 + 2$ given by $$(x,y) \mapsto \left(x - \dfrac{1}{x}, \dfrac{y}{x}\right),$$ and the differential $$\dfrac{1+x^2}{(1-x^2)\sqrt{1 + x^4}} \,\mathrm dx$$ on the elliptic curve is the pull-back of the differential $$\dfrac{1}{u v}\,\mathrm du$$ on the conic.

Since a conic has genus zero (i.e. it can be parameterized by a single variable, using a classical "$t$-substitution"), the integral of a differential on a conic can always be expressed via elementary functions. Thus the same is true of the integral of the original differential on the elliptic curve.

The answer to the general question is the same: if the differential in question can be pulled back from a map to a rational curve (i.e. a genus zero curve), then the "elliptic integral" in question can be in fact integrated via elementary functions.

For example, any elliptic curve $y^2 = P(x)$ has a map to the the $x$-line given by $(x,y) \mapsto x$. So if the integral only involves rational functions of $x$ (which will be the case when $y$ appears to even powers, since we can always substitute $P(x)$ for $y^2$) then it can be computed in elementary terms. Also, if $P(x)$ has repeated roots, then the curve $y^2 = P(x)$ itself is actually rational (it can be parameterized by a variation of the classical $t$-substitution for conics), and so any "elliptic integral" is actually elementarily integrable.

P.S. I have used some geometric terminology here (pull-back, differential, elliptic curve, rational curve) because the modern point of view on this material is via algebraic geometry. If some of this is unfamiliar, leave a comment and I (or someone else) can elaborate.

Added: If we have a curve $C$ (which could be our elliptic curve $y^2 = P(x)$, or our rational curve $v^2 = u^2 + 2$, or just the $x$-line, or ...) and if $\omega$ is a differential on $C$, then finding the indefinite integral of $\omega$ means finding some function $f$ on $C$ such that $\omega = df$.

Now if $\varphi: C' \to C$ is a map of curves, then $\varphi^* \omega = \varphi^* d f = d (f\circ \varphi).$ So $f\circ \varphi$ is an indefinite integral of the pulled back differential $\varphi^*\omega$.

In particular, if $f$ is an elementary function of the coordinates on $C$, and $\varphi$ is given by expressions which are elementary functions of the coordinates, than the composite $f\circ \varphi$ will again be given by elementary functions of the coordinates.

This is what is happening in your example. Explicitly, on our curve $v^2 = u^2 + u,$ we had for example the differential $$\dfrac{1}{u v} \,\mathrm du = \frac{1}{2 u^2 v}\,\mathrm d (u^2 + 2) = \frac{1}{2(v^2-2)v}\,\mathrm d(v^2) = \dfrac{1}{v^2-2}\,\mathrm dv = \dfrac{1}{2\sqrt{2}}\mathrm d\log\bigl( \frac{v-\sqrt{2}}{v+\sqrt{2}}\bigr).$$ Now pulling back this differential via our map $\varphi:(x,y)\mapsto \left(x-\dfrac{1}{x}, \dfrac{y}{x}\right)$ we obtain $$\dfrac{1 + x^2}{(1-x^2)y}\,\mathrm dx = \dfrac{1}{2\sqrt{2}}\mathrm d\log\bigl(\frac{y-\sqrt{2}x}{y+\sqrt{2}x} \bigr).$$

As this example shows, pulling back is just the theoretical terminology for making a substitution, just as a map of curves is just theoretical terminology for a change of variables.

If memory serves, Miles Reid's wonderful book Undergraduate algebraic geometry discusses some of this, and in particular gives some of the history of how the analytic theory of elliptic integrals turned into the algebro-geometric theory of elliptic curves. (If you don't know this book, don't be fooled by the title --- it is a great introduction to the subject for someone at any level, not just undergraduates!) A much more detailed history can be found in Dieudonne's book on the history of algebraic geometry, but that book is probably not very readable unless you already have some feeling for algebraic geometry as a subject.

• Dear Matt, thank you very much for this answer. I really like the fact that my question is related to elliptic curves. I knew about the connection between elliptic integrals and elliptic curves but never thought it would have something to do with this integration problem. I would very much appreciate if you could please elaborate some more in the part of the differentials and the pullback, and how this implies that the integral corresponding to the elliptic curve can be done in terms of elementary functions. Maybe you can point me to some references where I can read about this. Thanks. Dec 28, 2010 at 21:25
• Wonderful answer. In fact, all your answers have been uniformly excellent and I have learnt a lot from them. Dec 30, 2010 at 7:50
• Where does the elementarily come in? Suppose that we want to integrate $\int F(x)dx/y$ over the curve $y^2=P(x)$. Do we need to require that $F(x)$ is a rational function of $x$? Jan 6, 2019 at 16:38

(This was intended to be yet another comment, but it got too big for the comment box.)

I finally got a chance to look at the venerable Handbook of Elliptic Integrals for Engineers and Scientists by Byrd and Friedman, and there is indeed a short discussion there on pseudoelliptic integrals, which I shall quote in part:

One frequently encounters integrals that have all the appearances of being elliptic but which can ultimately be expressed solely in terms of elementary functions. These ... are called pseudoelliptic integrals, and can always be evaluated as

$$v_0(t)+\sum_{j=1}^m b_j\ln\;v_j(t)$$

where the $$b_j$$ are constants and the $$v_j(t)$$ are algebraic functions. One need not, however, be too concerned at the outset about whether or not his integral at hand is genuinely elliptic, because the substitutions given in this book for the reduction and evaluation of elliptic integrals will lead to the right results (without additional labor) even though the integral might turn out to be elementary. We give several important examples.

...

...the more general integral

$$\int\frac{t\cdot R(t^2)}{\sqrt{at^4+bt^2+c}}\mathrm dt$$

($$R(u)$$ a rational function in $$u$$) ... reduces to integrals involving odd powers of Jacobi elliptic functions, and can thus always be ultimately evaluated in terms of elementary functions.

A general case of a less obvious pseudoelliptic integral is

$$\int \frac{R(t^2)}{\sqrt{(1-t^2)(1-k^2 t^2)}}\mathrm dt=\int \frac{R(\sin^2\theta)}{\sqrt{1-k^2\sin^2\theta}}\mathrm d\theta=\int R(\mathrm{sn}^2(u,k))\mathrm du$$

when... for all values of $$t$$ any one of the following relations holds:

$$\begin{cases}R(t^2)+R\left(\frac1{k^2 t^2}\right)&=0\\R(t^2)+R\left(\frac{1-k^2 t^2}{k^2(1-t^2)}\right)&=0\\R(t^2)+R\left(\frac{1-t^2}{1-k^2 t^2}\right)&=0\end{cases}$$

...

(emphasis mine)

Since it's a handbook intended for use by nonspecialists, there's not much discussion of the conditions where an "elliptic integral" is in fact pseudoelliptic; I'd imagine advanced textbooks on the elliptic integrals would discuss the matter, but I have not been able to find any.

• Thank you very much for this answer. So it appears that by following the procedure that the book develops one will eventually either express the integral in terms of Jacobi elliptic functions (or elliptic integrals in Legendre canonical form I presume) or finally integrate it in terms of elementary functions. Am I right? Dec 30, 2010 at 10:12
• Well, @Adrián, the thing with the Jacobi elliptic functions in integral substitutions is that they play the same role as trigonometric/hyperbolic functions for integrals involving the square root of a quadratic. After performing the integration, one can undo the initial Jacobi substitutions; for "true" elliptic integrals, the inverse Jacobi functions stay and can then subsequently be converted to the canonical Legendre-Jacobi integrals. For pseudoelliptic integrals, attempting to undo the substitution will cause the appearance of logarithmic or algebraic terms. Dec 30, 2010 at 10:33

I might be coming at this too late to interest anyone, but let me build on Matt E's answer. Suppose that we have a elliptic curve $E$ given as $y^2 = P(x)$ and a differential form $\eta = f(x, \sqrt{P(x)}) dx/\sqrt{P(x)}$ on $E$. We would like to know whether or not there is a map $\phi: \eta \to \mathbb{P}^1$, and a differential form $\omega$ on $\mathbb{P}^1$, such that $\eta = \phi^* \omega$. I'll explain how to solve this, using the current problem as an example.

Recall that $dx/\sqrt{P(x)}$ has no zeroes or poles on $E$. So the poles of $\eta$ are precisely those of $f(x, \sqrt{P(x)}$. In our case, $f$ has poles at the points where $1-x^2 =0$, namely the four points $(x,y) = (\pm 1, \pm \sqrt{2})$. If $\eta = \phi^* \omega$, then the poles of $\eta$ will occur at precisely the preimages of the poles of $\omega$. Moreover, if $\phi(a) = b$, with $\phi$ ramified of order $e$ at $a$, then the residue of $\phi^* \omega$ at $a$ is going to be $e$ times the residue of $\omega$ at $b$. So we can guess which poles of $\eta$ come from the same pole of $\omega$ by seeing which ones have residues which are in positive rational ratios.

In this case, the residue is $1/ \sqrt{2}$ at $(1, \sqrt{2})$ and $(-1, - \sqrt{2})$, and is $- 1/ \sqrt{2}$ at $(1, -\sqrt{2})$ and $(1, - \sqrt{2})$. So the most obvious guess is that $\phi(1, \sqrt{2}) = \phi(-1, -\sqrt{2})$ and $\phi(-1, \sqrt{2}) = \phi(-1, \sqrt{2})$, with branching of equal orders at these points. If I were going to write a careful algorithm, I'd have to consider other possibilities, but I'll just try this possibility.

So, we would like to know whether or not there is a rational function $\phi$ on $E$, of degree $2$, with $\phi(1, \sqrt{2}) = \phi(-1, -\sqrt{2})$ and $\phi(-1, \sqrt{2}) = \phi(-1, \sqrt{2})$, and with branching of some order $e$ at all these points? In other words, does $e (1, \sqrt{2}) + e (-1, -\sqrt{2}) = e (-1, \sqrt{2}) + e (-1, \sqrt{2})$ in the group law of $E$? Note that if you just chose $4$ random points on an elliptic curve, there would be no relations between them in the group law, consistent with the fact that there are usually no elementary solutions to elliptic integrals.

In this case, we win! Notice that the line $y= \sqrt{2} x$ is tangent to $E$ at the points $(1, \sqrt{2})$ and $(-1, -\sqrt{2})$. Similarly, $y = -\sqrt{2} x$ is tangent to $E$ at the other two points. So $2 \cdot (1, \sqrt{2}) + 2 \cdot (-1, -\sqrt{2}) = 2 \cdot (-1, \sqrt{2}) + 2 \cdot (-1, \sqrt{2}).$

Explicitly, the map $\phi$ should be $x \mapsto (\sqrt{x^4+1} - \sqrt{2} \cdot x)/(\sqrt{x^4+1} + \sqrt{2} \cdot x)$. We know that $\omega$ should be a form which has poles of residue $1/2 \sqrt{2}$ at $0$ and $\infty$, so it should be $du/2 \sqrt{2} u$.

Ask your favorite computer algebra system to pullback $du/2 \sqrt{2} u$ along $x \mapsto (\sqrt{x^4+1} - \sqrt{2} \cdot x)/(\sqrt{x^4+1} + \sqrt{2} \cdot x)$. It will whine a lot but, if you make it keep expanding and factoring, you will get the original integrand.

I think Hardy's monograph The Integration of Functions of a Single Variable discusses this but I'm not sure.

• I looked at the table of contents and it has a section on elliptic integrals. I'll try to find a copy of the book online. Thanks. Dec 28, 2010 at 17:52