\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 := 2 + {\left(\frac{k}{t}\right)}^{2}\\
t_2 := \frac{2}{\left(\left(t \cdot \left(\frac{t}{\ell} \cdot \left(\frac{t}{\ell} \cdot \sin k\right)\right)\right) \cdot \tan k\right) \cdot t_1}\\
\mathbf{if}\;t \leq -6.838119426725515 \cdot 10^{-180}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;t \leq 5.144889772886934 \cdot 10^{-73}:\\
\;\;\;\;\frac{2}{\frac{{k}^{2} \cdot \left(t \cdot {\sin k}^{2}\right)}{\cos k \cdot {\ell}^{2}}}\\
\mathbf{elif}\;t \leq 5.349222940678248 \cdot 10^{+89}:\\
\;\;\;\;\frac{2}{\frac{t_1 \cdot \left(\tan k \cdot \frac{\sin k \cdot {t}^{3}}{\ell}\right)}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\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 (+ 2.0 (pow (/ k t) 2.0)))
(t_2
(/ 2.0 (* (* (* t (* (/ t l) (* (/ t l) (sin k)))) (tan k)) t_1))))
(if (<= t -6.838119426725515e-180)
t_2
(if (<= t 5.144889772886934e-73)
(/
2.0
(/ (* (pow k 2.0) (* t (pow (sin k) 2.0))) (* (cos k) (pow l 2.0))))
(if (<= t 5.349222940678248e+89)
(/ 2.0 (/ (* t_1 (* (tan k) (/ (* (sin k) (pow t 3.0)) l))) l))
t_2)))))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 = 2.0 + pow((k / t), 2.0);
double t_2 = 2.0 / (((t * ((t / l) * ((t / l) * sin(k)))) * tan(k)) * t_1);
double tmp;
if (t <= -6.838119426725515e-180) {
tmp = t_2;
} else if (t <= 5.144889772886934e-73) {
tmp = 2.0 / ((pow(k, 2.0) * (t * pow(sin(k), 2.0))) / (cos(k) * pow(l, 2.0)));
} else if (t <= 5.349222940678248e+89) {
tmp = 2.0 / ((t_1 * (tan(k) * ((sin(k) * pow(t, 3.0)) / l))) / l);
} else {
tmp = t_2;
}
return tmp;
}



Bits error versus t



Bits error versus l



Bits error versus k
Results
if t < -6.8381194267255151e-180 or 5.34922294067824813e89 < t Initial program 25.9
Simplified25.9
Applied unpow3_binary6425.9
Applied times-frac_binary6418.0
Applied associate-*l*_binary6416.1
Applied *-un-lft-identity_binary6416.1
Applied times-frac_binary6410.3
Simplified10.3
Applied associate-*l*_binary649.7
if -6.8381194267255151e-180 < t < 5.14488977288693401e-73Initial program 60.4
Simplified60.4
Taylor expanded in t around 0 27.6
if 5.14488977288693401e-73 < t < 5.34922294067824813e89Initial program 21.6
Simplified21.6
Applied unpow3_binary6421.7
Applied times-frac_binary6418.1
Applied associate-*l*_binary6413.5
Applied associate-*l/_binary6413.5
Applied associate-*l/_binary6414.0
Applied associate-*l/_binary6412.1
Simplified11.3
Final simplification13.5
herbie shell --seed 2022068
(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))))