Polar Arc Length Integrator — Theory
1. Polar curves
A polar curve is written as
\[
r=f(\theta).
\]
For each value of \(\theta\), the curve gives a radius \(r\). The point can also be written in
Cartesian form as
\[
x=r\cos\theta,
\qquad
y=r\sin\theta.
\]
2. Polar arc length formula
The arc length of \(r=f(\theta)\) from \(\theta=a\) to \(\theta=b\) is
\[
L=\int_a^b
\sqrt{r^2+\left(\frac{dr}{d\theta}\right)^2}\,d\theta.
\]
The expression
\[
s(\theta)=\sqrt{r^2+\left(r'(\theta)\right)^2}
\]
is the polar speed integrand. Integrating this speed gives arc length.
3. Where the formula comes from
A polar curve can be converted into a parametric curve:
\[
x(\theta)=r(\theta)\cos\theta,
\qquad
y(\theta)=r(\theta)\sin\theta.
\]
The parametric arc length formula is
\[
L=\int_a^b
\sqrt{\left(\frac{dx}{d\theta}\right)^2+
\left(\frac{dy}{d\theta}\right)^2}\,d\theta.
\]
Differentiate:
\[
\frac{dx}{d\theta}=r'(\theta)\cos\theta-r(\theta)\sin\theta,
\]
\[
\frac{dy}{d\theta}=r'(\theta)\sin\theta+r(\theta)\cos\theta.
\]
Squaring and adding gives
\[
\left(\frac{dx}{d\theta}\right)^2+
\left(\frac{dy}{d\theta}\right)^2
=
r^2+\left(r'\right)^2.
\]
Therefore,
\[
L=\int_a^b\sqrt{r^2+\left(r'\right)^2}\,d\theta.
\]
4. Example: \(r=\theta\)
For the Archimedean spiral
\[
r=\theta,
\qquad
0\le\theta\le2\pi,
\]
we have
\[
\frac{dr}{d\theta}=1.
\]
The speed integrand is
\[
s(\theta)=\sqrt{\theta^2+1}.
\]
So the arc length is
\[
L=\int_0^{2\pi}\sqrt{\theta^2+1}\,d\theta.
\]
An antiderivative is
\[
\int\sqrt{\theta^2+1}\,d\theta
=
\frac12\left(\theta\sqrt{\theta^2+1}
+\operatorname{arsinh}\theta\right).
\]
Therefore,
\[
L=
\left[
\frac12\left(\theta\sqrt{\theta^2+1}
+\operatorname{arsinh}\theta\right)
\right]_0^{2\pi}.
\]
5. General Archimedean spiral
For
\[
r=a\theta,
\]
the derivative is
\[
\frac{dr}{d\theta}=a.
\]
Then
\[
\sqrt{r^2+\left(\frac{dr}{d\theta}\right)^2}
=
\sqrt{a^2\theta^2+a^2}
=
|a|\sqrt{\theta^2+1}.
\]
Thus
\[
L=|a|\int_a^b\sqrt{\theta^2+1}\,d\theta.
\]
6. Circle centered at the pole
If
\[
r=R,
\]
then
\[
\frac{dr}{d\theta}=0.
\]
The arc length is
\[
L=\int_a^b\sqrt{R^2}\,d\theta
=
|R|(b-a).
\]
For a full circle, \(0\le\theta\le2\pi\), this gives
\[
L=2\pi R.
\]
7. Sine and cosine circles
Curves like
\[
r=a\sin\theta
\qquad\text{or}\qquad
r=a\cos\theta
\]
also have simple arc length integrands. For example, if \(r=a\sin\theta\), then
\[
r'=a\cos\theta.
\]
Therefore,
\[
\sqrt{r^2+(r')^2}
=
\sqrt{a^2\sin^2\theta+a^2\cos^2\theta}
=
|a|.
\]
So
\[
L=|a|(b-a).
\]
8. Negative radius values
A negative radius is allowed in polar coordinates:
\[
(r,\theta)\equiv(-r,\theta+\pi).
\]
Arc length remains positive because the formula uses
\[
\sqrt{r^2+(r')^2}.
\]
However, negative \(r\) values can affect how the curve is traced visually.
9. Numerical integration
Many polar arc length integrals cannot be simplified using elementary antiderivatives.
For those cases, numerical integration is used:
- Adaptive Simpson: refines where the speed integrand changes quickly.
- Composite Simpson: applies Simpson’s rule over equal subintervals.
- Composite trapezoid: approximates the speed graph with trapezoids.
- Polyline approximation: adds straight-line distances between sampled plotted points.
11. Common mistakes
- Using the area formula: polar area uses \(\frac12\int r^2\,d\theta\), but polar arc length uses \(\int\sqrt{r^2+(r')^2}\,d\theta\).
- Forgetting \(dr/d\theta\): the derivative term is essential unless \(r\) is constant.
- Using degrees inside calculus: the standard formula assumes radians.
- Ignoring repeated tracing: arc length counts the distance traveled, even if the same curve is traced more than once.
- Misreading negative radius: negative \(r\) is valid and changes the plotted direction.
- Expecting every integral to be exact: many polar arc length integrals require numerical approximation.