Numerical calculation about curve length

AI Thread Summary
The discussion focuses on numerical methods for calculating curve length, with an emphasis on comparing techniques for area calculation as a reference. The user seeks a more effective numerical method for curve length than the basic distance formula. Suggestions include using integral representations of curve length and applying numerical integration methods like Simpson's rule or the trapezoidal rule. The conversation highlights that while Simpson's rule is often more efficient, the trapezoidal rule is simpler and sufficient for many cases. Overall, the thread explores the need for improved numerical methods in curve length calculations.
xyz3003
Messages
5
Reaction score
0
I think I have returned all my math back to teachers without any refund.

y=f(x);
h=xb-xa, which is very small.

My Q is to calculate curve length rather than area numerically.
But let me use area as example to show you what i want.

to calculate area between xa to xb, we have 2 ways:
1) area=(f(xa)+f(xb))*h/2; (trapezoid?)
2) area=(f(xa)+4*f(xm)+f(xb))*h/6; here xm=(xa+xb)/2; (parabola?)
As my test, second one is much better than first.

for curve length:
1) len=square root( (f(xb)-f(xa))*(f(xb)-f(xa)) + h*h);
actually, it is distance from (xa, f(xa)) to (xb, f(xb)).

do you know second way to calculate curve length as in area sample above, simple, easy-to-use and better?

any links or explanations are highly appreciated.

thanks.


.
.
 
Mathematics news on Phys.org
Well, in regions where the curvature is slowly varying, you might interpolate with circular arc segments instead.

Just a suggestion..
 
Start from an integral representing the length of the curve

\int_{x_1}^{x_2} \sqrt{1 + \left(\frac{dy}{dx}\right)^2}\,dx

or \int_{t_1}^{t_2} \sqrt{\left(\frac{dx}{dt}\right)^2 + \left(\frac{dy}{dt}\right)^2\right)}\,dt for a curve defined by parametric equations.

Evaluate the integrals with your favorite numerical formula.
 
AlephZero said:
Evaluate the integrals with your favorite numerical formula.

I just want to know the "favorite numerical formula", if which is better than summing line distances from one point to another.
 
xyz3003 said:
I just want to know the "favorite numerical formula", if which is better than summing line distances from one point to another.
As I said before, in most cases, Simpson's rule is most efficient.
 
I like the trapezoidal rule because it does a good enough job for most things and is much less tedious than simpons.
 
Seemingly by some mathematical coincidence, a hexagon of sides 2,2,7,7, 11, and 11 can be inscribed in a circle of radius 7. The other day I saw a math problem on line, which they said came from a Polish Olympiad, where you compute the length x of the 3rd side which is the same as the radius, so that the sides of length 2,x, and 11 are inscribed on the arc of a semi-circle. The law of cosines applied twice gives the answer for x of exactly 7, but the arithmetic is so complex that the...
Thread 'Imaginary Pythagoras'
I posted this in the Lame Math thread, but it's got me thinking. Is there any validity to this? Or is it really just a mathematical trick? Naively, I see that i2 + plus 12 does equal zero2. But does this have a meaning? I know one can treat the imaginary number line as just another axis like the reals, but does that mean this does represent a triangle in the complex plane with a hypotenuse of length zero? Ibix offered a rendering of the diagram using what I assume is matrix* notation...
Fermat's Last Theorem has long been one of the most famous mathematical problems, and is now one of the most famous theorems. It simply states that the equation $$ a^n+b^n=c^n $$ has no solutions with positive integers if ##n>2.## It was named after Pierre de Fermat (1607-1665). The problem itself stems from the book Arithmetica by Diophantus of Alexandria. It gained popularity because Fermat noted in his copy "Cubum autem in duos cubos, aut quadratoquadratum in duos quadratoquadratos, et...
Back
Top