Solve the elliptic integral $\int \frac1{\sqrt{C-x^2+\frac{x^4}2}}$ as the solution to $\ddot x + x - x^3 = 0.$ It is said that the elliptic integral $\int \frac1{\sqrt{C-x^2+\frac{x^4}2}}$ (whose solution is in terms of cnoidal and snoidal functions) is the solution to $\ddot x + x - x^3 = 0.$ (Multiply the left side by $\dot x$ and get the first integral.)
How to calc the integral? Why such a function is called an elliptic integral, and is important for solving non-linear ode's?

First we have to express the radicand as a product of its roots:
The roots of the polynomial are
$$x_{1}= \pm \sqrt{1-\sqrt{2C+1}} \quad C>-\frac{1}{2}$$
$$x_{2}= \pm \sqrt{1+\sqrt{2C+1}} \quad C>-\frac{1}{2}$$
For simplicity denote $a=x_{1}^2, b=x_{2}^2$. Then
$$I= \int \frac1{\sqrt{C-x^2+\frac{x^4}2}}dx = \int \frac1{\sqrt{(x^2-a)(x^2-b)}}dx = \frac{1}{\sqrt{ab}}\int \frac1{\sqrt{\left(\frac{x^2}{a}-1\right)\left(\frac{x^2}{b}-1\right)}}dx$$
If we make the substitution $\displaystyle w^2=\frac{x^2}{a}$ then
$$I= \frac{1}{\sqrt{b}}\int \frac1{\sqrt{\left(w^2-1\right)\left(\frac{a}{b}w^2-1\right)}}dx$$
Denote $$ k^2 = \frac{a}{b}$$
and make the change of variable $$ w = \frac{1}{k\sin^2\theta} \Longrightarrow dw = -\frac{\cos\theta}{k\sin^2 \theta} = -\frac{\sqrt{1-\sin^2\theta}}{k\sin^2 \theta} $$
$$I = \frac{1}{\sqrt{b}}\int \frac1{\sqrt{\left(w^2-1\right)\left(k^2w^2-1\right)}}dx = -\frac{1}{\sqrt{b}} \underbrace{\int \frac{1}{\sqrt{1-k^2\sin^2\phi}}d\phi}_{J}$$
this integral $J$ of the right hand side is the Elliptic integral of the first kind expressed in Legendre notation
The integral is taken from $\theta =0$ up to an arbitraty value $\theta = \phi$
$$F(\phi,k) = \int_{0}^{\phi} \frac{1}{\sqrt{1-k^2\sin^2\phi}}d\phi$$
The parameter $k$ is assumed $|k|<1$ and is called the modulus while the parameter $k'=\sqrt{1-k^2}$ is called the complementary modulus.
The theory of elliptic integrals is important because there is no closed form for this kind integrals in terms of elementary functions (there are numerical solutions to them), so a new theory had to be developed to study them. If $k=0$ or $k=1$ the Elliptic integrals are just normal functions,  but the power of this functions appears when $0<k<1$.You can find applications in the theory of numbers, differential equations, geometry, etc.
