\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}
\mathbf{if}\;t \leq -1.0421023210157143 \cdot 10^{-243}:\\
\;\;\;\;\frac{1}{t \cdot \left(\frac{t}{\ell} \cdot \sin k\right)} \cdot \left(\frac{2}{2 + {\left(\frac{k}{t}\right)}^{2}} \cdot \frac{\frac{\ell}{t}}{\tan k}\right)\\
\mathbf{elif}\;t \leq 6.4743981145055726 \cdot 10^{-223}:\\
\;\;\;\;\frac{2}{\frac{\left(k \cdot k\right) \cdot \left(t \cdot {\sin k}^{2}\right)}{\left(\ell \cdot \ell\right) \cdot \cos k} + 2 \cdot \frac{{t}^{3}}{\frac{\ell \cdot \ell}{\frac{{\sin k}^{2}}{\cos k}}}}\\
\mathbf{elif}\;t \leq 2.4659146346821276 \cdot 10^{-207}:\\
\;\;\;\;\frac{\frac{\sqrt[3]{\ell} \cdot \sqrt[3]{\ell}}{\sqrt[3]{t} \cdot \sqrt[3]{t}}}{t \cdot \left(\frac{t}{\ell} \cdot \sin k\right)} \cdot \left(\frac{2}{2 + {\left(\frac{k}{t}\right)}^{2}} \cdot \frac{\frac{\sqrt[3]{\ell}}{\sqrt[3]{t}}}{\tan k}\right)\\
\mathbf{elif}\;t \leq 6.839250237191215 \cdot 10^{-165}:\\
\;\;\;\;\frac{2}{\frac{{\sin k}^{2}}{\cos k} \cdot \left(\frac{t \cdot \left(k \cdot k\right)}{\ell \cdot \ell} + 2 \cdot \frac{{t}^{3}}{\ell \cdot \ell}\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{t \cdot \left(\frac{t}{\ell} \cdot \sin k\right)} \cdot \left(\frac{2}{2 + {\left(\frac{k}{t}\right)}^{2}} \cdot \frac{\frac{\ell}{t}}{\tan k}\right)\\
\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
(if (<= t -1.0421023210157143e-243)
(*
(/ 1.0 (* t (* (/ t l) (sin k))))
(* (/ 2.0 (+ 2.0 (pow (/ k t) 2.0))) (/ (/ l t) (tan k))))
(if (<= t 6.4743981145055726e-223)
(/
2.0
(+
(/ (* (* k k) (* t (pow (sin k) 2.0))) (* (* l l) (cos k)))
(* 2.0 (/ (pow t 3.0) (/ (* l l) (/ (pow (sin k) 2.0) (cos k)))))))
(if (<= t 2.4659146346821276e-207)
(*
(/
(/ (* (cbrt l) (cbrt l)) (* (cbrt t) (cbrt t)))
(* t (* (/ t l) (sin k))))
(*
(/ 2.0 (+ 2.0 (pow (/ k t) 2.0)))
(/ (/ (cbrt l) (cbrt t)) (tan k))))
(if (<= t 6.839250237191215e-165)
(/
2.0
(*
(/ (pow (sin k) 2.0) (cos k))
(+ (/ (* t (* k k)) (* l l)) (* 2.0 (/ (pow t 3.0) (* l l))))))
(*
(/ 1.0 (* t (* (/ t l) (sin k))))
(* (/ 2.0 (+ 2.0 (pow (/ k t) 2.0))) (/ (/ l t) (tan k)))))))))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 tmp;
if (t <= -1.0421023210157143e-243) {
tmp = (1.0 / (t * ((t / l) * sin(k)))) * ((2.0 / (2.0 + pow((k / t), 2.0))) * ((l / t) / tan(k)));
} else if (t <= 6.4743981145055726e-223) {
tmp = 2.0 / ((((k * k) * (t * pow(sin(k), 2.0))) / ((l * l) * cos(k))) + (2.0 * (pow(t, 3.0) / ((l * l) / (pow(sin(k), 2.0) / cos(k))))));
} else if (t <= 2.4659146346821276e-207) {
tmp = (((cbrt(l) * cbrt(l)) / (cbrt(t) * cbrt(t))) / (t * ((t / l) * sin(k)))) * ((2.0 / (2.0 + pow((k / t), 2.0))) * ((cbrt(l) / cbrt(t)) / tan(k)));
} else if (t <= 6.839250237191215e-165) {
tmp = 2.0 / ((pow(sin(k), 2.0) / cos(k)) * (((t * (k * k)) / (l * l)) + (2.0 * (pow(t, 3.0) / (l * l)))));
} else {
tmp = (1.0 / (t * ((t / l) * sin(k)))) * ((2.0 / (2.0 + pow((k / t), 2.0))) * ((l / t) / tan(k)));
}
return tmp;
}



Bits error versus t



Bits error versus l



Bits error versus k
Results
if t < -1.04210232101571429e-243 or 6.83925023719121535e-165 < t Initial program 28.7
Simplified28.7
rmApplied cube-mult_binary64_44928.7
Applied times-frac_binary64_42520.3
Applied associate-*l*_binary64_36018.6
rmApplied *-un-lft-identity_binary64_41918.6
Applied times-frac_binary64_42513.4
Applied associate-*l*_binary64_36012.4
rmApplied *-un-lft-identity_binary64_41912.4
Applied times-frac_binary64_42512.5
Simplified11.0
rmApplied *-un-lft-identity_binary64_41911.0
Applied times-frac_binary64_4259.9
Applied associate-*l*_binary64_3608.3
Simplified8.3
if -1.04210232101571429e-243 < t < 6.47439811450557262e-223Initial program 64.0
Simplified64.0
rmApplied cube-mult_binary64_44964.0
Applied times-frac_binary64_42564.0
Applied associate-*l*_binary64_36064.0
rmApplied *-un-lft-identity_binary64_41964.0
Applied times-frac_binary64_42557.4
Applied associate-*l*_binary64_36057.4
Taylor expanded around inf 44.6
Simplified44.6
if 6.47439811450557262e-223 < t < 2.4659146346821276e-207Initial program 64.0
Simplified64.0
rmApplied cube-mult_binary64_44964.0
Applied times-frac_binary64_42564.0
Applied associate-*l*_binary64_36064.0
rmApplied *-un-lft-identity_binary64_41964.0
Applied times-frac_binary64_42551.2
Applied associate-*l*_binary64_36051.2
rmApplied *-un-lft-identity_binary64_41951.2
Applied times-frac_binary64_42552.6
Simplified53.6
rmApplied add-cube-cbrt_binary64_45453.6
Applied add-cube-cbrt_binary64_45453.6
Applied times-frac_binary64_42553.6
Applied times-frac_binary64_42552.7
Applied associate-*l*_binary64_36049.4
Simplified49.4
if 2.4659146346821276e-207 < t < 6.83925023719121535e-165Initial program 64.0
Simplified64.0
Taylor expanded around inf 37.3
Simplified35.3
Final simplification12.0
herbie shell --seed 2020352
(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))))