\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 -3.5362665831654716 \cdot 10^{-09}:\\
\;\;\;\;\ell \cdot \left(\ell \cdot \frac{\frac{2}{2 + {\left(\frac{k}{t}\right)}^{2}}}{t \cdot \left(\sin k \cdot \left(\tan k \cdot \left(t \cdot t\right)\right)\right)}\right)\\
\mathbf{elif}\;t \leq 8.924049272980926 \cdot 10^{-83}:\\
\;\;\;\;\frac{\ell \cdot 2}{\sqrt[3]{k} \cdot \sqrt[3]{k}} \cdot \frac{\frac{\frac{\cos k}{k} \cdot \frac{\ell}{{\sin k}^{2}}}{t}}{\sqrt[3]{k}}\\
\mathbf{elif}\;t \leq 6.439006299831887 \cdot 10^{+67}:\\
\;\;\;\;\ell \cdot \left(\frac{\sqrt[3]{\frac{2}{2 + {\left(\frac{k}{t}\right)}^{2}}} \cdot \sqrt[3]{\frac{2}{2 + {\left(\frac{k}{t}\right)}^{2}}}}{{t}^{3}} \cdot \left(\frac{\sqrt[3]{\frac{2}{2 + {\left(\frac{k}{t}\right)}^{2}}}}{\sin k} \cdot \frac{\ell}{\tan k}\right)\right)\\
\mathbf{elif}\;t \leq 1.0275830431192084 \cdot 10^{+73}:\\
\;\;\;\;\ell \cdot \left(2 \cdot \frac{\frac{\frac{\cos k}{\sqrt[3]{\frac{k}{\frac{\ell}{k}}} \cdot \left(\sqrt[3]{\frac{k}{\frac{\ell}{k}}} \cdot \sqrt[3]{\frac{k}{\frac{\ell}{k}}}\right)}}{{\sin k}^{2}}}{t}\right)\\
\mathbf{else}:\\
\;\;\;\;\ell \cdot \left(\ell \cdot \frac{\frac{2}{2 + {\left(\frac{k}{t}\right)}^{2}}}{{t}^{\left(\frac{3}{2}\right)} \cdot \left(\tan k \cdot \left(\sin k \cdot {t}^{\left(\frac{3}{2}\right)}\right)\right)}\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 -3.5362665831654716e-09)
(*
l
(*
l
(/
(/ 2.0 (+ 2.0 (pow (/ k t) 2.0)))
(* t (* (sin k) (* (tan k) (* t t)))))))
(if (<= t 8.924049272980926e-83)
(*
(/ (* l 2.0) (* (cbrt k) (cbrt k)))
(/ (/ (* (/ (cos k) k) (/ l (pow (sin k) 2.0))) t) (cbrt k)))
(if (<= t 6.439006299831887e+67)
(*
l
(*
(/
(*
(cbrt (/ 2.0 (+ 2.0 (pow (/ k t) 2.0))))
(cbrt (/ 2.0 (+ 2.0 (pow (/ k t) 2.0)))))
(pow t 3.0))
(*
(/ (cbrt (/ 2.0 (+ 2.0 (pow (/ k t) 2.0)))) (sin k))
(/ l (tan k)))))
(if (<= t 1.0275830431192084e+73)
(*
l
(*
2.0
(/
(/
(/
(cos k)
(*
(cbrt (/ k (/ l k)))
(* (cbrt (/ k (/ l k))) (cbrt (/ k (/ l k))))))
(pow (sin k) 2.0))
t)))
(*
l
(*
l
(/
(/ 2.0 (+ 2.0 (pow (/ k t) 2.0)))
(*
(pow t (/ 3.0 2.0))
(* (tan k) (* (sin k) (pow t (/ 3.0 2.0)))))))))))))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 <= -3.5362665831654716e-09) {
tmp = l * (l * ((2.0 / (2.0 + pow((k / t), 2.0))) / (t * (sin(k) * (tan(k) * (t * t))))));
} else if (t <= 8.924049272980926e-83) {
tmp = ((l * 2.0) / (cbrt(k) * cbrt(k))) * ((((cos(k) / k) * (l / pow(sin(k), 2.0))) / t) / cbrt(k));
} else if (t <= 6.439006299831887e+67) {
tmp = l * (((cbrt(2.0 / (2.0 + pow((k / t), 2.0))) * cbrt(2.0 / (2.0 + pow((k / t), 2.0)))) / pow(t, 3.0)) * ((cbrt(2.0 / (2.0 + pow((k / t), 2.0))) / sin(k)) * (l / tan(k))));
} else if (t <= 1.0275830431192084e+73) {
tmp = l * (2.0 * (((cos(k) / (cbrt(k / (l / k)) * (cbrt(k / (l / k)) * cbrt(k / (l / k))))) / pow(sin(k), 2.0)) / t));
} else {
tmp = l * (l * ((2.0 / (2.0 + pow((k / t), 2.0))) / (pow(t, (3.0 / 2.0)) * (tan(k) * (sin(k) * pow(t, (3.0 / 2.0)))))));
}
return tmp;
}



Bits error versus t



Bits error versus l



Bits error versus k
Results
if t < -3.5362665831654716e-9Initial program 22.4
Simplified22.8
rmApplied cube-mult_binary64_79022.8
Applied associate-*l*_binary64_70121.6
Simplified15.8
if -3.5362665831654716e-9 < t < 8.9240492729809263e-83Initial program 53.9
Simplified53.5
Taylor expanded around inf 23.7
Simplified22.7
rmApplied *-un-lft-identity_binary64_76022.7
Applied *-un-lft-identity_binary64_76022.7
Applied unpow-prod-down_binary64_83922.7
Applied *-un-lft-identity_binary64_76022.7
Applied times-frac_binary64_76616.8
Applied *-un-lft-identity_binary64_76016.8
Applied times-frac_binary64_76616.0
Applied times-frac_binary64_76616.0
Applied times-frac_binary64_7667.8
Simplified7.8
rmApplied associate-*l/_binary64_7037.8
Applied associate-*r/_binary64_7027.8
Applied associate-*r/_binary64_70211.3
Simplified11.3
rmApplied add-cube-cbrt_binary64_79511.7
Applied times-frac_binary64_7666.1
if 8.9240492729809263e-83 < t < 6.4390062998318865e67Initial program 22.3
Simplified19.9
rmApplied add-cube-cbrt_binary64_79520.0
Applied times-frac_binary64_76620.1
Applied associate-*l*_binary64_70118.1
Simplified13.6
if 6.4390062998318865e67 < t < 1.02758304311920835e73Initial program 17.1
Simplified16.3
Taylor expanded around inf 35.5
Simplified30.8
rmApplied add-cube-cbrt_binary64_79530.9
Simplified30.9
Simplified24.6
if 1.02758304311920835e73 < t Initial program 24.2
Simplified26.3
rmApplied sqr-pow_binary64_73226.3
Applied associate-*l*_binary64_70124.1
Simplified15.6
Final simplification12.6
herbie shell --seed 2021176
(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))))