\sqrt{\left|\frac{a \cdot a - b \cdot b}{a \cdot a}\right|}
\begin{array}{l}
t_0 := \sqrt[3]{\frac{b}{a}}\\
\sqrt{\left|\mathsf{fma}\left(b, \frac{t_0 \cdot t_0}{\sqrt{a}} \cdot \frac{t_0}{\sqrt{a}}, -1\right)\right|}
\end{array}
(FPCore (a b) :precision binary64 (sqrt (fabs (/ (- (* a a) (* b b)) (* a a)))))
(FPCore (a b) :precision binary64 (let* ((t_0 (cbrt (/ b a)))) (sqrt (fabs (fma b (* (/ (* t_0 t_0) (sqrt a)) (/ t_0 (sqrt a))) -1.0)))))
double code(double a, double b) {
return sqrt(fabs(((a * a) - (b * b)) / (a * a)));
}
double code(double a, double b) {
double t_0 = cbrt(b / a);
return sqrt(fabs(fma(b, (((t_0 * t_0) / sqrt(a)) * (t_0 / sqrt(a))), -1.0)));
}



Bits error versus a



Bits error versus b
Initial program 15.1
Simplified15.1
Applied associate-/r*_binary640.0
Applied add-sqr-sqrt_binary640.0
Applied add-cube-cbrt_binary640.0
Applied times-frac_binary640.0
Final simplification0.0
herbie shell --seed 2021275
(FPCore (a b)
:name "Eccentricity of an ellipse"
:precision binary64
:pre (and (and (<= 0.0 b) (<= b a)) (<= a 1.0))
(sqrt (fabs (/ (- (* a a) (* b b)) (* a a)))))