Average Error: 48.2 → 13.0
Time: 21.6s
Precision: binary64
\[\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)}\]
\[2 \cdot \frac{\frac{\ell}{\frac{k}{\ell}} \cdot \cos k}{k \cdot \left(t \cdot {\sin k}^{2}\right)}\]
\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)}
2 \cdot \frac{\frac{\ell}{\frac{k}{\ell}} \cdot \cos k}{k \cdot \left(t \cdot {\sin k}^{2}\right)}
(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
 (* 2.0 (/ (* (/ l (/ k l)) (cos k)) (* k (* t (pow (sin k) 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) {
	return 2.0 * (((l / (k / l)) * cos(k)) / (k * (t * pow(sin(k), 2.0))));
}

Error

Bits error versus t

Bits error versus l

Bits error versus k

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 48.2

    \[\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)}\]
  2. Simplified40.5

    \[\leadsto \color{blue}{\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot {\left(\frac{k}{t}\right)}^{2}}}\]
  3. Taylor expanded around inf 22.6

    \[\leadsto \color{blue}{2 \cdot \frac{\cos k \cdot {\ell}^{2}}{{k}^{2} \cdot \left(t \cdot {\sin k}^{2}\right)}}\]
  4. Simplified22.6

    \[\leadsto \color{blue}{2 \cdot \frac{\left(\ell \cdot \ell\right) \cdot \cos k}{\left(k \cdot k\right) \cdot \left(t \cdot {\sin k}^{2}\right)}}\]
  5. Using strategy rm
  6. Applied associate-*l*_binary6420.3

    \[\leadsto 2 \cdot \frac{\left(\ell \cdot \ell\right) \cdot \cos k}{\color{blue}{k \cdot \left(k \cdot \left(t \cdot {\sin k}^{2}\right)\right)}}\]
  7. Using strategy rm
  8. Applied associate-/r*_binary6418.2

    \[\leadsto 2 \cdot \color{blue}{\frac{\frac{\left(\ell \cdot \ell\right) \cdot \cos k}{k}}{k \cdot \left(t \cdot {\sin k}^{2}\right)}}\]
  9. Simplified18.1

    \[\leadsto 2 \cdot \frac{\color{blue}{\frac{\ell \cdot \ell}{k} \cdot \cos k}}{k \cdot \left(t \cdot {\sin k}^{2}\right)}\]
  10. Using strategy rm
  11. Applied associate-/l*_binary6413.0

    \[\leadsto 2 \cdot \frac{\color{blue}{\frac{\ell}{\frac{k}{\ell}}} \cdot \cos k}{k \cdot \left(t \cdot {\sin k}^{2}\right)}\]
  12. Final simplification13.0

    \[\leadsto 2 \cdot \frac{\frac{\ell}{\frac{k}{\ell}} \cdot \cos k}{k \cdot \left(t \cdot {\sin k}^{2}\right)}\]

Reproduce

herbie shell --seed 2020220 
(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))))