\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 := \frac{\ell}{t} \cdot \cos k\\
t_2 := 2 + {\left(\frac{k}{t}\right)}^{2}\\
\mathbf{if}\;t \leq -4.778976228327041 \cdot 10^{-114}:\\
\;\;\;\;\frac{2}{\left(\left(\sin k \cdot \left(t \cdot \left(\frac{t}{\ell} \cdot \sin k\right)\right)\right) \cdot t_2\right) \cdot \frac{1}{t_1}}\\
\mathbf{elif}\;t \leq 4.742834197369878 \cdot 10^{-140}:\\
\;\;\;\;\frac{2}{\frac{{k}^{2} \cdot \left(t \cdot {\sin k}^{2}\right)}{\cos k \cdot {\ell}^{2}}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\frac{t_2 \cdot \left(\sin k \cdot \left(t \cdot \frac{t \cdot \sin k}{\ell}\right)\right)}{t_1}}\\
\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 (* (/ l t) (cos k))) (t_2 (+ 2.0 (pow (/ k t) 2.0))))
(if (<= t -4.778976228327041e-114)
(/ 2.0 (* (* (* (sin k) (* t (* (/ t l) (sin k)))) t_2) (/ 1.0 t_1)))
(if (<= t 4.742834197369878e-140)
(/
2.0
(/ (* (pow k 2.0) (* t (pow (sin k) 2.0))) (* (cos k) (pow l 2.0))))
(/ 2.0 (/ (* t_2 (* (sin k) (* t (/ (* t (sin k)) l)))) t_1))))))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 = (l / t) * cos(k);
double t_2 = 2.0 + pow((k / t), 2.0);
double tmp;
if (t <= -4.778976228327041e-114) {
tmp = 2.0 / (((sin(k) * (t * ((t / l) * sin(k)))) * t_2) * (1.0 / t_1));
} else if (t <= 4.742834197369878e-140) {
tmp = 2.0 / ((pow(k, 2.0) * (t * pow(sin(k), 2.0))) / (cos(k) * pow(l, 2.0)));
} else {
tmp = 2.0 / ((t_2 * (sin(k) * (t * ((t * sin(k)) / l)))) / t_1);
}
return tmp;
}



Bits error versus t



Bits error versus l



Bits error versus k
Results
if t < -4.77897622832704091e-114Initial program 24.3
Simplified24.3
Applied unpow3_binary6424.3
Applied times-frac_binary6417.6
Applied associate-*l*_binary6415.3
Applied associate-/l*_binary6410.4
Applied tan-quot_binary6410.4
Applied associate-*l/_binary649.2
Applied frac-times_binary647.5
Applied associate-*l/_binary646.6
Applied div-inv_binary646.6
if -4.77897622832704091e-114 < t < 4.74283419736987834e-140Initial program 64.0
Simplified64.0
Taylor expanded in t around 0 25.5
if 4.74283419736987834e-140 < t Initial program 25.6
Simplified25.6
Applied unpow3_binary6425.6
Applied times-frac_binary6417.5
Applied associate-*l*_binary6414.9
Applied associate-/l*_binary6410.6
Applied tan-quot_binary6410.6
Applied associate-*l/_binary649.3
Applied frac-times_binary647.8
Applied associate-*l/_binary646.6
Taylor expanded in t around 0 6.5
Final simplification10.3
herbie shell --seed 2021352
(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))))