\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)}
\begin{array}{l}
t_1 := 0 \cdot \tan k\\
t_2 := \frac{t}{{\left(\sqrt[3]{\ell}\right)}^{2}} \cdot \sqrt[3]{\sin k}\\
t_3 := \frac{2}{\left(\mathsf{fma}\left(t_2, \tan k \cdot {t_2}^{2}, -t_1\right) + \mathsf{fma}\left(0, \tan k, t_1\right)\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\\
\mathbf{if}\;t \leq -5.24857608547832 \cdot 10^{-110}:\\
\;\;\;\;t_3\\
\mathbf{elif}\;t \leq 8.893990945635184 \cdot 10^{-99}:\\
\;\;\;\;\frac{2}{\frac{{k}^{2} \cdot \left(t \cdot {\sin k}^{2}\right)}{\cos k \cdot {\ell}^{2}}}\\
\mathbf{else}:\\
\;\;\;\;t_3\\
\end{array}
(FPCore (t l k) :precision binary64 (/ 2.0 (* (* (* (/ (pow t 3.0) (* l l)) (sin k)) (tan k)) (+ (+ 1.0 (pow (/ k t) 2.0)) 1.0))))
(FPCore (t l k)
:precision binary64
(let* ((t_1 (* 0.0 (tan k)))
(t_2 (* (/ t (pow (cbrt l) 2.0)) (cbrt (sin k))))
(t_3
(/
2.0
(*
(+
(fma t_2 (* (tan k) (pow t_2 2.0)) (- t_1))
(fma 0.0 (tan k) t_1))
(+ 2.0 (pow (/ k t) 2.0))))))
(if (<= t -5.24857608547832e-110)
t_3
(if (<= t 8.893990945635184e-99)
(/
2.0
(/ (* (pow k 2.0) (* t (pow (sin k) 2.0))) (* (cos k) (pow l 2.0))))
t_3))))double code(double t, double l, double k) {
return 2.0 / ((((pow(t, 3.0) / (l * l)) * sin(k)) * tan(k)) * ((1.0 + pow((k / t), 2.0)) + 1.0));
}
double code(double t, double l, double k) {
double t_1 = 0.0 * tan(k);
double t_2 = (t / pow(cbrt(l), 2.0)) * cbrt(sin(k));
double t_3 = 2.0 / ((fma(t_2, (tan(k) * pow(t_2, 2.0)), -t_1) + fma(0.0, tan(k), t_1)) * (2.0 + pow((k / t), 2.0)));
double tmp;
if (t <= -5.24857608547832e-110) {
tmp = t_3;
} else if (t <= 8.893990945635184e-99) {
tmp = 2.0 / ((pow(k, 2.0) * (t * pow(sin(k), 2.0))) / (cos(k) * pow(l, 2.0)));
} else {
tmp = t_3;
}
return tmp;
}



Bits error versus t



Bits error versus l



Bits error versus k
if t < -5.2485760854783201e-110 or 8.8939909456351842e-99 < t Initial program 23.6
Simplified23.6
Applied egg-rr6.5
if -5.2485760854783201e-110 < t < 8.8939909456351842e-99Initial program 63.2
Simplified63.2
Taylor expanded in t around 0 27.0
Final simplification11.2
herbie shell --seed 2022127
(FPCore (t l k)
:name "Toniolo and Linder, Equation (10+)"
:precision binary64
(/ 2.0 (* (* (* (/ (pow t 3.0) (* l l)) (sin k)) (tan k)) (+ (+ 1.0 (pow (/ k t) 2.0)) 1.0))))