share
MathematicsHow to determine the arc length of ellipse?
[+42] [4] Mohammad Fakhrey
[2013-06-30 17:49:25]
[ geometry differential-geometry circles conic-sections ]
[ https://math.stackexchange.com/questions/433094/how-to-determine-the-arc-length-of-ellipse ]

I want to determine the length of an arc from the ellipse in the picture below:

enter image description here

How can I determine the length of $d$?

(1) This seems (essentially) like a duplicate of the question you asked before. Please remember that you can edit your questions to add information or ask for more clarification - you don't have to post again. - Zev Chonoles
(2) You'll need to use an elliptic integral. See mathworld.wolfram.com/Ellipse.html - icurays1
@ZevChonoles Unfortunately did not get something from the previous question. what should I do :( - Mohammad Fakhrey
@DavidMitra- broken link - user297514
[+52] [2013-06-30 22:49:12] coffeemath [ACCEPTED]

Let $a=3.05,\ b=2.23.$ Then a parametric equation for the ellipse is $x=a\cos t,\ y=b \sin t.$ When $t=0$ the point is at $(a,0)=(3.05,0)$, the starting point of the arc on the ellipse whose length you seek. Now it's important to realize that the parameter $t$ is not the central angle, so you need to get the value of $t$ which corresponds to the top end of your arc. At that end you have $y/x=\tan 50$ (degrees). And in terms of $t$ you have $y/x=(b/a)\tan t$. Solving for $t$ then gives $$t=t_1=\arctan \left( \frac{a}{b}\tan 50 \right).$$

[note I'd suggest using radians here, replacing the $50$ by $5\pi/18.$]

For the arclength use the general formula of integrating $\sqrt{x'^2+y'^2}$ for $t$ in the desired range. In your case $x'=-a \sin t,\ y'=b \cos t$, so that you are integrating $$\sqrt{a^2 \sin^2t+b^2 \cos^2t}$$ with respect to $t$ from $0$ to the above $t_1$. There not being a simple closed form for the antiderivative (it's an "elliptic integral), the simplest approach now would be to do the integral numerically. This seems the more appropriate in your problem as you only know $a,b$ to two decimals, apparently.

* When I did this numerically on maple I got about $2.531419$ for the arclength.


(7) Plus 1 for being frank about the superiority of the numerical approach. - Lubin
Thank you coffeemath but I'm having problem with finding t - Mohammad Fakhrey
@MohammadFakhrey I don't know what more to explain. If you could say exactly what is confusing you in my answer, or in the last comment, it might help. - coffeemath
I did like you said but the result = 2.23042 not 2.531419 ??? - Mohammad Fakhrey
@MohammadFakhrey I just checked it again using 20 digit accuracy for the calculations on maple, and still got $2.5314195...$. Given your answer is so close, maybe maple encountered some numerical error because of the default way it evaluates integrals numerically (I did not use any sophisticated routine like Runge Kutta). On the other hand what software gave your $2.23042$ result? How reliable is it? Anyway there is no independent check beyond using elliptic functions. - coffeemath
coffeemath Please take a look at this picture (s13.postimg.org/co6n64oo7/0000607972816.png) and see if my solution is true or not. - Mohammad Fakhrey
(2) @MohammadFakhrey, $t$ is an independent parameter going from $0$ to some value $t_1$ such that the a point on the ellipse has coordinates $(a \cos t, b \sin t)$. And no, your solution is incorrect. The angle for each $t$ is $\arctan \left( \frac{b}{a} \tan t \right)$. The solution presented by coffeemath is 100% correct. - John Alexiou
@ja72 how to solve integral ? - Mohammad Fakhrey
@MohammadFakhrey, numerically. Google numerical integration and try it. - John Alexiou
@ja72 I want to know if there a software to solve it ? - Mohammad Fakhrey
(1) Look at related post math.stackexchange.com/questions/350369/… - John Alexiou
(1) You can use Wolfram Alpha - John Alexiou
@coffeemath: The solution becomes negative for angles larger than 90 degrees. Can you help me on this? - SKPS
@SathishKrishnan It should not become negative, because one is integrating the squareroot expression of my answer right after "you are integrating". The thing under that radical is a sum of two squares, so it is nonnegative, and the squareroot of a nonnegative is again nonnegtive. - coffeemath
@SatishKrishnan On second thought maybe your question in previous comment was about what I called $t_1$ in the answer being negative, which of course one does not want. In the four quadrants it is important to choose the appropriate value for $t_1$ in that quadrant. So first we need to worry about $a/b \tan \theta$ which may need to be adjusted according to quadrant, and then use the appropriate choice for the $t_1$ so it comes out in that quadrant. - coffeemath
@ja72 --> The angle for each t is arctan(tan t * a / b), you got the a / b inverted. - GarciadelCastillo
@GarciadelCastillo $$\theta = \tan^{-1} \left( \frac{y}{x} \right) = \tan^{-1} \left( \frac{b \sin(t)}{a \cos(t)} \right) = \tan^{-1} \left( \frac{b}{a} \tan(t) \right)$$ - John Alexiou
@Lubin What approaches could there be other than the numerical approach? - user56202
Sorry, @user56202 , the theoretical approach to this is not my meat. - Lubin
1
[+14] [2015-01-28 17:29:45] MvG

You can compute this as

$$d=b\,E\bigl(\tan^{-1}(a/b\,\tan(\theta))\,\big|\,1-(a/b)^2\bigr)$$

using the incomplete elliptic integral of the second kind [1] $E(\varphi\,|\,m)$. In Mathematica-Syntax (and suitable for Wolfram Alpha [2]) this can be written as

2.23*EllipticE[ArcTan[3.05/2.23*Tan[50°]],1-(3.05/2.23)^2]

I adapted this from this post [3] which investigates the converse problem (given arc length, find angle) but along the way treats this direction of the problem as well. As noted there, this angle conversion will only work for the first and last quadrant. Otherwise, either adjust the angle or look at that post for an alternative formula to use in its place.

With a few more digits of precision, the answer is returned as $2.5314195265536624417$ which essentially matches both the other answers here. Of course, printing that many digits in the answer is very bad style if the input is only given to two decimals. It does show that the numerical integration by Jyrki is a bit less precise than what coffeemath did, but even he should theoretically have rounded in the other direction.

Note that the formula above only works for $-\frac\pi2<\theta<\frac\pi2$. For $\frac\pi2<\theta<\pi$ the result of $\tan^{-1}$ will represent $\theta-\pi$ so to correct for that you can add $\pi$ to that result. Similar for $-\pi<\theta<-\frac\pi2$ where you need to subtract $\pi$ from the $\tan^{-1}$ result. Generally speaking you want the first input to the $E$ function to be an angle in the same quadrant as $\theta$, adding integer multiples of $\pi$ as necessary.

[1] https://en.wikipedia.org/wiki/Elliptic_integral#Incomplete_elliptic_integral_of_the_second_kind
[2] http://www.wolframalpha.com/input/?i=2.23*EllipticE%5BArcTan%5B3.05%2F2.23*Tan%5B50%C2%B0%5D%5D%2C1-%283.05%2F2.23%29%5E2%5D
[3] https://math.stackexchange.com/a/436125/35416

when angle belongs to $[\pi/2,\pi]$, $d$ becomes negative.. - chloe
You are right @chloehj, I've updated my answer to discuss the required quadrant adjustments. - MvG
Thank you very much. - chloe
2
[+4] [2013-07-01 19:25:55] Jyrki Lahtonen

Giving a Mathematica calculation. Same result as coffeemath (+1)

In[1]:= ArcTan[3.05*Tan[5Pi/18]/2.23]
Out[1]= 1.02051
In[2]:= x=3.05 Cos[t];
In[3]:= y=2.23 Sin[t];
In[4]:= NIntegrate[Sqrt[D[x,t]^2+D[y,t]^2],{t,0,1.02051}]
Out[4]= 2.53143

Can you give me the full explain from the begin ? - Mohammad Fakhrey
The first command calculates the value of the parameter $t$ (see Coffeemath's answer) that gives you the point on the ellipse at 50 degree angle. Then I define the functions $x$ and $y$. Then my fourth command (In[4]) tells Mathematica to calculate the value of the integral that gives the arc length (numerically as that is the only way). It spews out $2.5314$. See this Wikipedia-article for the theory - the paragraph titled "Finding arc lengths by integrating" has this formula. - Jyrki Lahtonen
By formula I mean $$L=\int_{t=0}^{1.02051}\sqrt{x'(t)^2+y'(t)^2}\,dt.$$ - Jyrki Lahtonen
(1) Finally I understood it.Thank you very very very much JyrkiLahtonen also Thanks to coffeemath but first of all Thanks to <3 Allah <3 . - Mohammad Fakhrey
Glad to hear that you understand, @Mohammad. Well done. - Jyrki Lahtonen
@JyrkiLahtonen: The solution becomes negative for angles larger than 90 degrees. Can you help me on this? - SKPS
3
[0] [2023-02-07 23:02:02] Christopher Emery

I believe I found this asymptotic approximation from Jacobi's elliptical integral of the second kind some time ago. It's not precise, but converges exactly for degenerate cases of $b=0$ (lines) and $b=a$ (circles). The infinite series methods are ideal where precision is desired. I offer this only as a curiosity. The last term, recently added, contributes little, but ensures convergence for circles. Assume $0\le b\le a$. Then $$ s\approx 2 \pi \sqrt{a b}+(4 a)^{\frac{a-b}{a+b}} -a^{b-a}. $$


4