# Arc length

Arc length is the distance between two points along a section of a curve. Development of a formulation of arc length suitable for applications to mathematics and the sciences is a focus of calculus. In the most basic formulation of arc length for a parametric curve (thought of as the trajectory of a particle), the arc length is obtained by integrating the speed of the particle over the path. Thus the length of a continuously differentiable curve $(x(t),y(t))$, for $a\leq t\leq b$, in the Euclidean plane is given as the integral $L=\int _{a}^{b}{\sqrt {x'(t)^{2}+y'(t)^{2}}}\,dt,$ (because ${\sqrt {x'(t)^{2}+y'(t)^{2}}}$ is the magnitude of the velocity vector $(x'(t),y'(t))$, i.e., the particle's speed).
The defining integral of arc length does not always have a closed-form expression, and numerical integration may be used instead to obtain numerical values of arc length.
Determining the length of an irregular arc segment by approximating the arc segment as connected (straight) line segments is also called curve rectification. For a rectifiable curve these approximations don't get arbitrarily large (so the curve has a finite length).

## General approach

A curve in the plane can be approximated by connecting a finite number of points on the curve using (straight) line segments to create a polygonal path. Since it is straightforward to calculate the length of each linear segment (using the Pythagorean theorem in Euclidean space, for example), the total length of the approximation can be found by summation of the lengths of each linear segment; that approximation is known as the (cumulative) chordal distance.
If the curve is not already a polygonal path, then using a progressively larger number of line segments of smaller lengths will result in better curve length approximations. Such a curve length determination by approximating the curve as connected (straight) line segments is called rectification of a curve. The lengths of the successive approximations will not decrease and may keep increasing indefinitely, but for smooth curves they will tend to a finite limit as the lengths of the segments get arbitrarily small.
For some curves, there is a smallest number $L$ that is an upper bound on the length of all polygonal approximations (rectification). These curves are called rectifiable and the arc length is defined as the number $L$.
A signed arc length can be defined to convey a sense of orientation or "direction" with respect to a reference point taken as origin in the curve (see also: curve orientation and signed distance).

## Formula for a smooth curve

Let $f\colon [a,b]\to \mathbb {R} ^{n}$ be continuously differentiable (i.e., the derivative is a continuous function) function. The length of the curve is given by the formula $L(f)=\int _{a}^{b}|f'(t)|\,dt$ where $|f'(t)|$ is the Euclidean norm of the tangent vector $f'(t)$ to the curve.
To justify this formula, define the arc length as limit of the sum of linear segment lengths for a regular partition of $[a,b]$ as the number of segments approaches infinity. This means
$L(f)=\lim _{N\to \infty }\sum _{i=1}^{N}{\bigg |}f(t_{i})-f(t_{i-1}){\bigg |}$
where $t_{i}=a+i(b-a)/N=a+i\Delta t$ with $\Delta t={\frac {b-a}{N}}=t_{i}-t_{i-1}$ for $i=0,1,\dotsc ,N.$ This definition is equivalent to the standard definition of arc length as an integral:
$L(f)=\lim _{N\to \infty }\sum _{i=1}^{N}{\bigg |}f(t_{i})-f(t_{i-1}){\bigg |}=\lim _{N\to \infty }\sum _{i=1}^{N}\left|{\frac {f(t_{i})-f(t_{i-1})}{\Delta t}}\right|\Delta t=\int _{a}^{b}{\Big |}f'(t){\Big |}\ dt.$
The last equality is proved by the following steps:
* The second fundamental theorem of calculus shows $f(t_{i})-f(t_{i-1})=\int _{t_{i-1}}^{t_{i}}f'(t)\ dt=\Delta t\int _{0}^{1}f'(t_{i-1}+\theta (t_{i}-t_{i-1}))\ d\theta$ where $t=t_{i-1}+\theta (t_{i}-t_{i-1})$ over $\theta \in [0,1]$ maps to $[t_{i-1},t_{i}]$ and $dt=(t_{i}-t_{i-1})\,d\theta =\Delta t\,d\theta$. In the below step, the following equivalent expression is used.${\frac {f(t_{i})-f(t_{i-1})}{\Delta t}}=\int _{0}^{1}f'(t_{i-1}+\theta (t_{i}-t_{i-1}))\ d\theta .$
* The function $\left|f'\right|$ is a continuous function from a closed interval $[a,b]$ to the set of real numbers, thus it is uniformly continuous according to the Heine–Cantor theorem, so there is a positive real and monotonically non-decreasing function $\delta (\varepsilon )$ of positive real numbers $\varepsilon$ such that $\Delta t<\delta (\varepsilon )$ implies $\left|\left|f'(t_{i-1}+\theta (t_{i}-t_{i-1}))\right|-\left|f'(t_{i})\right|\right|<\varepsilon$ where $\Delta t=t_{i}-t_{i-1}$ and $\theta \in [0,1]$. Let's consider the limit ${\ce {N\to \infty }}$ of the following formula,$\sum _{i=1}^{N}\left|{\frac {f(t_{i})-f(t_{i-1})}{\Delta t}}\right|\Delta t-\sum _{i=1}^{N}\left|f'(t_{i})\right|\Delta t.$
With the above step result, it becomes
$\sum _{i=1}^{N}\left|\int _{0}^{1}f'(t_{i-1}+\theta (t_{i}-t_{i-1}))\ d\theta \right|\Delta t-\sum _{i=1}^{N}\left|f'(t_{i})\right|\Delta t.$
Terms are rearranged so that it becomes
${\begin{aligned}&\Delta t\sum _{i=1}^{N}\left(\left|\int _{0}^{1}f'(t_{i-1}+\theta (t_{i}-t_{i-1}))\ d\theta \right|-\int _{0}^{1}\left|f'(t_{i})\right|d\theta \right)\\&\qquad \leqq \Delta t\sum _{i=1}^{N}\left(\int _{0}^{1}\left|f'(t_{i-1}+\theta (t_{i}-t_{i-1}))\right|\ d\theta -\int _{0}^{1}\left|f'(t_{i})\right|d\theta \right)\\&\qquad =\Delta t\sum _{i=1}^{N}\int _{0}^{1}\left|f'(t_{i-1}+\theta (t_{i}-t_{i-1}))\right|-\left|f'(t_{i})\right|\ d\theta \end{aligned}}$
where in the leftmost side |f$^′$(t$_i$)|=∫$_0$$^1$|f$^′$(t$_i$)|dθ{\textstyle \left|f'(t_{i})\right|=\int _{0}^{1}\left|f'(t_{i})\right|d\theta } is used. By ||f$^′$(t$_{i−1}$+θ(t$_i$−t$_{i−1}$))|−|f$^′$(t$_i$)||<ε{\textstyle \left|\left|f'(t_{i-1}+\theta (t_{i}-t_{i-1}))\right|-\left|f'(t_{i})\right|\right|<\varepsilon } for N>(b−a)/δ(ε){\textstyle N>(b-a)/\delta (\varepsilon )} so that $\Delta t<\delta (\varepsilon )$, it becomes
$\Delta t\sum _{i=1}^{N}\left(\left|\int _{0}^{1}f'(t_{i-1}+\theta (t_{i}-t_{i-1}))\ d\theta \right|-\left|f'(t_{i})\right|\right)<\varepsilon N\Delta t$
with $\left|f'(t_{i})\right|=\int _{0}^{1}\left|f'(t_{i})\right|d\theta$, $\varepsilon N\Delta t=\varepsilon (b-a)$, and $N>(b-a)/\delta (\varepsilon )$. In the limit $N\to \infty ,$ $\delta (\varepsilon )\to 0$ so $\varepsilon \to 0$ thus the left side of $<$ approaches $0$. In other words, $\sum _{i=1}^{N}\left|{\frac {f(t_{i})-f(t_{i-1})}{\Delta t}}\right|\Delta t=\sum _{i=1}^{N}\left|f'(t_{i})\right|\Delta t$ in this limit, and the right side of this equality is just the Riemann integral of $\left|f'(t)\right|$ on $[a,b].$ This definition of arc length shows that the length of a curve represented by a continuously differentiable function $f:[a,b]\to \mathbb {R} ^{n}$ on $[a,b]$ is always finite, i.e., rectifiable.
The definition of arc length of a smooth curve as the integral of the norm of the derivative is equivalent to the definition
$L(f)=\sup \sum _{i=1}^{N}{\bigg |}f(t_{i})-f(t_{i-1}){\bigg |}$
where the supremum is taken over all possible partitions $a=t_{0}<t_{1}<\dots <t_{N-1}<t_{N}=b$ of $[a,b].$ This definition as the supremum of the all possible partition sums is also valid if $f$ is merely continuous, not differentiable.
A curve can be parameterized in infinitely many ways. Let $\varphi :[a,b]\to [c,d]$ be any continuously differentiable bijection. Then $g=f\circ \varphi ^{-1}:[c,d]\to \mathbb {R} ^{n}$ is another continuously differentiable parameterization of the curve originally defined by $f.$ The arc length of the curve is the same regardless of the parameterization used to define the curve:
${\begin{aligned}L(f)&=\int _{a}^{b}{\Big |}f'(t){\Big |}\ dt=\int _{a}^{b}{\Big |}g'(\varphi (t))\varphi '(t){\Big |}\ dt\\&=\int _{a}^{b}{\Big |}g'(\varphi (t)){\Big |}\varphi '(t)\ dt\quad {\text{in the case }}\varphi {\text{ is non-decreasing}}\\&=\int _{c}^{d}{\Big |}g'(u){\Big |}\ du\quad {\text{using integration by substitution}}\\&=L(g).\end{aligned}}$

## Finding arc lengths by integration

If a planar curve in $\mathbb {R} ^{2}$ is defined by the equation $y=f(x),$ where $f$ is continuously differentiable, then it is simply a special case of a parametric equation where $x=t$ and $y=f(t).$ The Euclidean distance of each infinitesimal segment of the arc can be given by:
${\sqrt {dx^{2}+dy^{2}}}={\sqrt {1+\left({\frac {dy}{dx}}\right)^{2}\,}}dx.$
The arc length is then given by:
$s=\int _{a}^{b}{\sqrt {1+\left({\frac {dy}{dx}}\right)^{2}\,}}dx.$
Curves with closed-form solutions for arc length include the catenary, circle, cycloid, logarithmic spiral, parabola, semicubical parabola and straight line. The lack of a closed form solution for the arc length of an elliptic and hyperbolic arc led to the development of the elliptic integrals.

### Numerical integration

In most cases, including even simple curves, there are no closed-form solutions for arc length and numerical integration is necessary. Numerical integration of the arc length integral is usually very efficient. For example, consider the problem of finding the length of a quarter of the unit circle by numerically integrating the arc length integral. The upper half of the unit circle can be parameterized as $y={\sqrt {1-x^{2}}}.$ The interval $x\in \left[-{\sqrt {2}}/2,{\sqrt {2}}/2\right]$ corresponds to a quarter of the circle. Since dy/dx=−x/√(1−x$^2$){\textstyle dy/dx=-x{\big /}{\sqrt {1-x^{2}}}} and $1+(dy/dx)^{2}=1{\big /}\left(1-x^{2}\right),$ the length of a quarter of the unit circle is
$\int _{-{\sqrt {2}}/2}^{{\sqrt {2}}/2}{\frac {dx}{\sqrt {1-x^{2}}}}\,.$
The 15-point Gauss–Kronrod rule estimate for this integral of 1.570796326808177 differs from the true length of
$\arcsin x{\bigg |}_{-{\sqrt {2}}/2}^{{\sqrt {2}}/2}={\frac {\pi }{2}}$
by 1.3×10$^{−11}$ and the 16-point Gaussian quadrature rule estimate of 1.570796326794727 differs from the true length by only 1.7×10$^{−13}$. This means it is possible to evaluate this integral to almost machine precision with only 16 integrand evaluations.

### Curve on a surface

Let $\mathbf {x} (u,v)$ be a surface mapping and let $\mathbf {C} (t)=(u(t),v(t))$ be a curve on this surface. The integrand of the arc length integral is $\left|\left(\mathbf {x} \circ \mathbf {C} \right)'(t)\right|.$ Evaluating the derivative requires the chain rule for vector fields:
$D(\mathbf {x} \circ \mathbf {C} )=(\mathbf {x} _{u}\ \mathbf {x} _{v}){\binom {u'}{v'}}=\mathbf {x} _{u}u'+\mathbf {x} _{v}v'.$
The squared norm of this vector is
$\left(\mathbf {x} _{u}u'+\mathbf {x} _{v}v'\right)\cdot (\mathbf {x} _{u}u'+\mathbf {x} _{v}v')=g_{11}\left(u'\right)^{2}+2g_{12}u'v'+g_{22}\left(v'\right)^{2}$
(where $g_{ij}$ is the first fundamental form coefficient), so the integrand of the arc length integral can be written as ${\sqrt {g_{ab}\left(u^{a}\right)'\left(u^{b}\right)'\,}}$ (where $u^{1}=u$ and $u^{2}=v$).

### Other coordinate systems

Let $\mathbf {C} (t)=(r(t),\theta (t))$ be a curve expressed in polar coordinates. The mapping that transforms from polar coordinates to rectangular coordinates is
$\mathbf {x} (r,\theta )=(r\cos \theta ,r\sin \theta ).$
The integrand of the arc length integral is $\left|\left(\mathbf {x} \circ \mathbf {C} \right)'(t)\right|.$ The chain rule for vector fields shows that $D(\mathbf {x} \circ \mathbf {C} )=\mathbf {x} _{r}r'+\mathbf {x} _{\theta }\theta '.$ So the squared integrand of the arc length integral is
$\left(\mathbf {x_{r}} \cdot \mathbf {x_{r}} \right)\left(r'\right)^{2}+2\left(\mathbf {x} _{r}\cdot \mathbf {x} _{\theta }\right)r'\theta '+\left(\mathbf {x} _{\theta }\cdot \mathbf {x} _{\theta }\right)\left(\theta '\right)^{2}=\left(r'\right)^{2}+r^{2}\left(\theta '\right)^{2}.$
So for a curve expressed in polar coordinates, the arc length is: $\int _{t_{1}}^{t_{2}}{\sqrt {\left({\frac {dr}{dt}}\right)^{2}+r^{2}\left({\frac {d\theta }{dt}}\right)^{2}\,}}dt=\int _{\theta (t_{1})}^{\theta (t_{2})}{\sqrt {\left({\frac {dr}{d\theta }}\right)^{2}+r^{2}\,}}d\theta .$
The second expression is for a polar graph $r=r(\theta )$ parameterized by $t=\theta$.
Now let $\mathbf {C} (t)=(r(t),\theta (t),\phi (t))$ be a curve expressed in spherical coordinates where $\theta$ is the polar angle measured from the positive $z$-axis and $\phi$ is the azimuthal angle. The mapping that transforms from spherical coordinates to rectangular coordinates is $\mathbf {x} (r,\theta ,\phi )=(r\sin \theta \cos \phi ,r\sin \theta \sin \phi ,r\cos \theta ).$
Using the chain rule again shows that $D(\mathbf {x} \circ \mathbf {C} )=\mathbf {x} _{r}r'+\mathbf {x} _{\theta }\theta '+\mathbf {x} _{\phi }\phi '.$ All dot products $\mathbf {x} _{i}\cdot \mathbf {x} _{j}$ where $i$ and $j$ differ are zero, so the squared norm of this vector is $\left(\mathbf {x} _{r}\cdot \mathbf {x} _{r}\right)\left(r'^{2}\right)+\left(\mathbf {x} _{\theta }\cdot \mathbf {x} _{\theta }\right)\left(\theta '\right)^{2}+\left(\mathbf {x} _{\phi }\cdot \mathbf {x} _{\phi }\right)\left(\phi '\right)^{2}=\left(r'\right)^{2}+r^{2}\left(\theta '\right)^{2}+r^{2}\sin ^{2}\theta \left(\phi '\right)^{2}.$
So for a curve expressed in spherical coordinates, the arc length is $\int _{t_{1}}^{t_{2}}{\sqrt {\left({\frac {dr}{dt}}\right)^{2}+r^{2}\left({\frac {d\theta }{dt}}\right)^{2}+r^{2}\sin ^{2}\theta \left({\frac {d\phi }{dt}}\right)^{2}\,}}dt.$
A very similar calculation shows that the arc length of a curve expressed in cylindrical coordinates is $\int _{t_{1}}^{t_{2}}{\sqrt {\left({\frac {dr}{dt}}\right)^{2}+r^{2}\left({\frac {d\theta }{dt}}\right)^{2}+\left({\frac {dz}{dt}}\right)^{2}\,}}dt.$

## Simple cases
### Arcs of circles

Arc lengths are denoted by s, since the Latin word for length (or size) is spatium.
In the following lines, $r$ represents the radius of a circle, $d$ is its diameter, $C$ is its circumference, $s$ is the length of an arc of the circle, and $\theta$ is the angle which the arc subtends at the centre of the circle. The distances $r,d,C,$ and $s$ are expressed in the same units.
* $C=2\pi r,$ which is the same as $C=\pi d.$ This equation is a definition of $\pi .$
* If the arc is a semicircle, then $s=\pi r.$
* For an arbitrary circular arc:
** If $\theta$ is in radians then $s=r\theta .$ This is a definition of the radian.
** If $\theta$ is in degrees, then $s={\frac {\pi r\theta }{180^{\circ }}},$ which is the same as $s={\frac {C\theta }{360^{\circ }}}.$
** If $\theta$ is in grads (100 grads, or grades, or gradians are one right-angle), then $s={\frac {\pi r\theta }{200{\text{ grad}}}},$ which is the same as $s={\frac {C\theta }{400{\text{ grad}}}}.$
** If $\theta$ is in turns (one turn is a complete rotation, or 360°, or 400 grads, or $2\pi$ radians), then $s=C\theta /1{\text{ turn}}$.

#### Great circles on Earth

Two units of length, the nautical mile and the metre (or kilometre), were originally defined so the lengths of arcs of great circles on the Earth's surface would be simply numerically related to the angles they subtend at its centre. The simple equation $s=\theta$ applies in the following circumstances:
* if $s$ is in nautical miles, and $\theta$ is in arcminutes (1⁄60 degree), or
* if $s$ is in kilometres, and $\theta$ is in gradians.
The lengths of the distance units were chosen to make the circumference of the Earth equal 40000 kilometres, or 21600 nautical miles. Those are the numbers of the corresponding angle units in one complete turn.
Those definitions of the metre and the nautical mile have been superseded by more precise ones, but the original definitions are still accurate enough for conceptual purposes and some calculations. For example, they imply that one kilometre is exactly 0.54 nautical miles. Using official modern definitions, one nautical mile is exactly 1.852 kilometres, which implies that 1 kilometre is about 0.53995680 nautical miles. This modern ratio differs from the one calculated from the original definitions by less than one part in 10,000.

### Other simple cases

* Archimedean spiral § Arc length
* Cycloid § Arc length
* Ellipse § Arc length
* Helix § Arc length
* Parabola § Arc length
* Sine and cosine § Arc length
* Triangle wave § Arc length

## Historical methods
### Antiquity

For much of the history of mathematics, even the greatest thinkers considered it impossible to compute the length of an irregular arc. Although Archimedes had pioneered a way of finding the area beneath a curve with his "method of exhaustion", few believed it was even possible for curves to have definite lengths, as do straight lines. The first ground was broken in this field, as it often has been in calculus, by approximation. People began to inscribe polygons within the curves and compute the length of the sides for a somewhat accurate measurement of the length. By using more segments, and by decreasing the length of each segment, they were able to obtain a more and more accurate approximation. In particular, by inscribing a polygon of many sides in a circle, they were able to find approximate values of π.

### 17th century

In the 17th century, the method of exhaustion led to the rectification by geometrical methods of several transcendental curves: the logarithmic spiral by Evangelista Torricelli in 1645 (some sources say John Wallis in the 1650s), the cycloid by Christopher Wren in 1658, and the catenary by Gottfried Leibniz in 1691.
In 1659, Wallis credited William Neile's discovery of the first rectification of a nontrivial algebraic curve, the semicubical parabola. The accompanying figures appear on page 145. On page 91, William Neile is mentioned as Gulielmus Nelius.

### Integral form

Before the full formal development of calculus, the basis for the modern integral form for arc length was independently discovered by Hendrik van Heuraet and Pierre de Fermat.
In 1659 van Heuraet published a construction showing that the problem of determining arc length could be transformed into the problem of determining the area under a curve (i.e., an integral). As an example of his method, he determined the arc length of a semicubical parabola, which required finding the area under a parabola. In 1660, Fermat published a more general theory containing the same result in his De linearum curvarum cum lineis rectis comparatione dissertatio geometrica (Geometric dissertation on curved lines in comparison with straight lines).
Building on his previous work with tangents, Fermat used the curve
    $y=x^{\frac {3}{2}}\,$
whose tangent at x = a had a slope of
    ${3 \over 2}a^{\frac {1}{2}}$
so the tangent line would have the equation
    $y={3 \over 2}a^{\frac {1}{2}}(x-a)+f(a).$
Next, he increased a by a small amount to a + ε, making segment AC a relatively good approximation for the length of the curve from A to D. To find the length of the segment AC, he used the Pythagorean theorem:
    ${\begin{aligned}AC^{2}&=AB^{2}+BC^{2}\\&=\varepsilon ^{2}+{9 \over 4}a\varepsilon ^{2}\\&=\varepsilon ^{2}\left(1+{9 \over 4}a\right)\end{aligned}}$
which, when solved, yields
    $AC=\varepsilon {\sqrt {1+{9 \over 4}a\,}}.$
In order to approximate the length, Fermat would sum up a sequence of short segments.

## Curves with infinite length

As mentioned above, some curves are non-rectifiable. That is, there is no upper bound on the lengths of polygonal approximations; the length can be made arbitrarily large. Informally, such curves are said to have infinite length. There are continuous curves on which every arc (other than a single-point arc) has infinite length. An example of such a curve is the Koch curve. Another example of a curve with infinite length is the graph of the function defined by f(x) = x sin(1/x) for any open set with 0 as one of its delimiters and f(0) = 0. Sometimes the Hausdorff dimension and Hausdorff measure are used to quantify the size of such curves.

## Generalization to (pseudo-)Riemannian manifolds

Let $M$ be a (pseudo-)Riemannian manifold, $g$ the (pseudo-) metric tensor, $\gamma :[0,1]\rightarrow M$ a curve in $M$ defined by $n$ parametric equations
       $\gamma (t)=[\gamma ^{1}(t),\dots ,\gamma ^{n}(t)],\quad t\in [0,1]$
and
       $\gamma (0)=\mathbf {x} ,\,\,\gamma (1)=\mathbf {y}$
The length of $\gamma$, is defined to be
    $\ell (\gamma )=\int \limits _{0}^{1}||\gamma '(t)||_{\gamma (t)}dt$,
or, choosing local coordinates $x$,
    $\ell (\gamma )=\int \limits _{0}^{1}{\sqrt {\pm \sum _{i,j=1}^{n}g_{ij}(x(\gamma (t))){\frac {dx^{i}(\gamma (t))}{dt}}{\frac {dx^{j}(\gamma (t))}{dt}}}}dt$,
where
    $\gamma '(t)\in T_{\gamma (t)}M$
is the tangent vector of $\gamma$ at $t.$ The sign in the square root is chosen once for a given curve, to ensure that the square root is a real number. The positive sign is chosen for spacelike curves; in a pseudo-Riemannian manifold, the negative sign may be chosen for timelike curves. Thus the length of a curve is a non-negative real number. Usually no curves are considered which are partly spacelike and partly timelike.
In theory of relativity, arc length of timelike curves (world lines) is the proper time elapsed along the world line, and arc length of a spacelike curve the proper distance along the curve.