TITLE: Find the length of the curve $x^{2k}+y^{2k} =1$
QUESTION [7 upvotes]: I want to find an expression for length and find the limit $k\rightarrow \infty$
The answer is obviously 8, if we look at the graphs.

REPLY [8 votes]: First of all
$$
x^{2n}+y^{2n}=1\implies y'=-\frac{x^{2n-1}}{y^{2n-1}}\tag{1}
$$
Thus,
$$
\begin{align}
\frac L4
&=\int_0^1(1+y'^2)^{1/2}\,\mathrm{d}x\\
&=\int_0^1\left(1+\left(\frac{x^{2n}}{1-x^{2n}}\right)^{2-1/n}\right)^{1/2}\mathrm{d}x\\
&=\frac1{2n}\int_0^1\left(1+\left(\frac{x}{1-x}\right)^{2-1/n}\right)^{1/2}x^{\frac1{2n}}\frac{\mathrm{d}x}{x}\\
&=\frac1{2n}\int_0^1\color{#00A000}{\left((1-x)^{2-1/n}+x^{2-1/n}\right)^{1/2}}x^{\frac1{2n}-1}(1-x)^{\frac1{2n}-1}\mathrm{d}x\tag{2}
\end{align}
$$
For $n\ge1$, we have
$$
\color{#C00000}{1}
\ge\color{#00A000}{\left((1-x)^{2-1/n}+x^{2-1/n}\right)^{1/2}}
\ge\sqrt{1-2x(1-x)}
\ge\color{#C00000}{1}-\color{#0000FF}{2x(1-x)}\tag{3}
$$
To combine $(2)$ and $(3)$ we will use
$$
\begin{align}
\frac1{2n}\int_0^1\color{#C00000}{1}\,x^{\frac1{2n}-1}(1-x)^{\frac1{2n}-1}\mathrm{d}x
&=\frac1{2n}\mathrm{B}\left(\frac1{2n},\frac1{2n}\right)\\
&=\frac1{2n}\frac{\Gamma\left(\frac1{2n}\right)\Gamma\left(\frac1{2n}\right)}{\Gamma\left(\frac1{n}\right)}\\
&=\frac1{2n}\frac{2n\Gamma\left(1+\frac1{2n}\right)2n\Gamma\left(1+\frac1{2n}\right)}{n\Gamma\left(1+\frac1{n}\right)}\\
&=2\frac{\Gamma\left(1+\frac1{2n}\right)\Gamma\left(1+\frac1{2n}\right)}{\Gamma\left(1+\frac1{n}\right)}\\
&=2\left(1+\frac1n\right)\frac{\Gamma\left(1+\frac1{2n}\right)\Gamma\left(1+\frac1{2n}\right)}{\Gamma\left(2+\frac1{n}\right)}\tag{4}
\end{align}
$$
and
$$
\begin{align}
\frac1{2n}\int_0^1\color{#0000FF}{2x(1-x)}x^{\frac1{2n}-1}(1-x)^{\frac1{2n}-1}\mathrm{d}x
&=\frac1n\mathrm{B}\left(1+\frac1{2n},1+\frac1{2n}\right)\\
&=\frac1n\frac{\Gamma\left(1+\frac1{2n}\right)\Gamma\left(1+\frac1{2n}\right)}{\Gamma\left(2+\frac1{n}\right)}\tag{5}
\end{align}
$$
Combining $(2)$, $(3)$, $(4)$, and $(5)$, we get
$$
\hspace{-1cm}\left(2+\frac1n\right)\frac{\Gamma\left(1+\frac1{2n}\right)\Gamma\left(1+\frac1{2n}\right)}{\Gamma\left(2+\frac1{n}\right)}
\le\frac L4
\le\left(2+\frac2n\right)\frac{\Gamma\left(1+\frac1{2n}\right)\Gamma\left(1+\frac1{2n}\right)}{\Gamma\left(2+\frac1{n}\right)}\tag{6}
$$
Since $\Gamma(1)=\Gamma(2)=1$, the squeeze theorem says that as $n\to\infty$, $L\to8$.

Computation of the Length for Large $\boldsymbol{n}$
As $n\to\infty$, the integrand tends to $\left((1-x)^2+x^2\right)^{1/2}x^{-1}(1-x)^{-1}$, which is not integrable on $[0,1]$. This causes convergence problems when trying to evaluate $(2)$ for large $n$. We can use the Beta function to bypass this difficulty.
Break up $(2)$ as
$$
\begin{align}
\frac L4
&=\frac1{2n}\int_0^1\left((1-x)^{2-\frac1n}+x^{2-\frac1n}\right)^{1/2}x^{\frac1{2n}-1}(1-x)^{\frac1{2n}-1}\mathrm{d}x\\
&=\frac1{2n}\int_0^1\color{#00A000}{\left[\left((1-x)^{2-\frac1n}+x^{2-\frac1n}\right)^{1/2}-1\right]x^{\frac1{2n}-1}(1-x)^{\frac1{2n}-1}}\mathrm{d}x\\
&+\frac1{2n}\mathrm{B}\left(\frac1{2n},\frac1{2n}\right)\tag{7}
\end{align}
$$
The green integrand in $(7)$ is bounded on $[0,1]$, so $(7)$ behaves much better with computer integration.
Formula $(7)$ can be implemented in Mathematica as
f[n_] := NIntegrate[(Sqrt[x^(2-1/n) + (1-x)^(2-1/n)] - 1) x^(1/2/n-1)(1-x)^(1/2/n-1), {x,0,1}, WorkingPrecision->20]/2/n + Beta[1/2/n, 1/2/n]/2/n

This gives $f[1]=\frac\pi2$ and $f[1000000]=1.99999944669682658902684568$

Asymptotic Approximation
Consider the integral
$$
I(\alpha,\beta)=\frac1{2n}\int_0^1\left((1-x)^{2-\beta}+x^{2-\beta}\right)^{1/2}x^{\alpha-1}(1-x)^{\alpha-1}\mathrm{d}x\tag{8}
$$
For $(2)$, we wish to set $\alpha=\frac1{2n}$ and $\beta=\frac1n$.
$$
\begin{align}
\hspace{-1cm}\frac{\partial}{\partial\beta}I\left(\frac1{2n},0\right)
&=-\frac1{4n}\int_0^1\frac{\log(1-x)(1-x)^2+\log(x)x^2}{\left((1-x)^2+x^2\right)^{1/2}}x^{\frac1{2n}-1}(1-x)^{\frac1{2n}-1}\mathrm{d}x\\
&=-\frac1{4n}\int_0^1\frac{\log(1-x)(1-x)^2+\log(x)x^2}{\left((1-x)^2+x^2\right)^{1/2}}x^{-1}(1-x)^{-1}\mathrm{d}x\\
&+O\left(\frac1{n^2}\right)\tag{9}
\end{align}
$$
Evaluating the integral in $(9)$, we get that
$$
I\left(\frac1{2n},\frac1n\right)-I\left(\frac1{2n},0\right)\sim\frac{0.514}{n^2}\tag{10}
$$
Thus, we can set $\beta=0$ and only incur a $O\left(\frac1{n^2}\right)$ error.
$$
\begin{align}
I\left(\frac1{2n},0\right)
&=\frac1{2n}\int_0^1\left[\left((1-x)^2+x^2\right)^{1/2}-1\right]x^{\frac1{2n}-1}(1-x)^{\frac1{2n}-1}\mathrm{d}x\\
&+\frac1{2n}\mathrm{B}\left(\frac1{2n},\frac1{2n}\right)\\
&=\frac1{2n}\int_0^1\left[\left((1-x)^2+x^2\right)^{1/2}-1\right]x^{-1}(1-x)^{-1}\mathrm{d}x\\
&+2+O\left(\frac1{n^2}\right)\\
&=2+\frac{\log(2)+\sqrt2\log(\sqrt2-1)}{n}+O\left(\frac1{n^2}\right)\tag{11}
\end{align}
$$
Putting together $(10)$ and $(11)$, we get
$$
\frac L4=2-\frac{\sqrt2\log(\sqrt2+1)-\log(2)}{n}+O\left(\frac1{n^2}\right)\tag{12}
$$
where $\sqrt2\log(\sqrt2+1)-\log(2)\approx0.55330329972051571737$