I want to apply the formula for arc length to an ellipse in polar coordinates to find its perimeter $$s=\int_{\theta_1}^{\theta_2}\sqrt{(dr/d\theta)^2 + r^2}$$ I'm looking to numerically integrate this, so the exact answer isn't the goal. However, what I cannot understand is how this function (numerically or exactly) integrated could ever return the perimeter of an ellipse. For example, consider an ellipse with a semi-major axis of $5$, and a semi-minor axis of $3$ ($a=5$, $b=3$) See an image of the polar plot of ellipse
Now, using Ramanujan's approximation for the perimeter of the ellipse, we get $s\approx25.527$
Using a very unrefined method of numerical integration (i.e. reducing the ellipse to a diamond defined by the 4 points where the ellipse crosses $\theta=0, \pi/2, \pi$, and $3\pi/2$) and ignoring the $dr/d\theta$ term in the integral, we would get a result of $s=30$. Of course, a more refined numerical integration method would result in a larger value for $s$ and the addition of the $dr/d\theta$ term will only increase it further.
What is it that I'm missing here? How is it possible that I'm finding a value larger than the best approximation for the perimeter of the ellipse even though I'm using a method which should only under predict this value?