Average Error: 42.3 → 8.7
Time: 3.5m
Precision: 64
Internal Precision: 1408
\[\frac{\sqrt{2} \cdot t}{\sqrt{\frac{x + 1}{x - 1} \cdot \left(\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)\right) - \ell \cdot \ell}}\]
\[\begin{array}{l} \mathbf{if}\;t \le -9.551209580007774 \cdot 10^{+135}:\\ \;\;\;\;\frac{t \cdot \sqrt{2}}{\left(\frac{\frac{\frac{t}{x}}{x}}{\sqrt{2}} - t \cdot \sqrt{2}\right) - \frac{\frac{2}{x}}{\sqrt{2}} \cdot \left(\frac{t}{x} + t\right)}\\ \mathbf{if}\;t \le 6.64164782115949 \cdot 10^{+42}:\\ \;\;\;\;\frac{\sqrt{2}}{\sqrt{1}} \cdot \frac{t}{\sqrt{2 \cdot {t}^{2} + \left(2 \cdot \frac{\ell}{\frac{x}{\ell}} + 4 \cdot \frac{{t}^{2}}{x}\right)}}\\ \mathbf{else}:\\ \;\;\;\;\frac{t \cdot \sqrt{2}}{\left(\frac{\frac{2}{x}}{\sqrt{2}} \cdot \left(\frac{t}{x} + t\right) + t \cdot \sqrt{2}\right) - \frac{\frac{\frac{t}{x}}{x}}{\sqrt{2}}}\\ \end{array}\]

Error

Bits error versus x

Bits error versus l

Bits error versus t

Derivation

  1. Split input into 3 regimes
  2. if t < -9.551209580007774e+135

    1. Initial program 57.6

      \[\frac{\sqrt{2} \cdot t}{\sqrt{\frac{x + 1}{x - 1} \cdot \left(\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)\right) - \ell \cdot \ell}}\]
    2. Taylor expanded around -inf 1.8

      \[\leadsto \frac{\sqrt{2} \cdot t}{\color{blue}{2 \cdot \frac{t}{{\left(\sqrt{2}\right)}^{3} \cdot {x}^{2}} - \left(t \cdot \sqrt{2} + \left(2 \cdot \frac{t}{\sqrt{2} \cdot x} + 2 \cdot \frac{t}{\sqrt{2} \cdot {x}^{2}}\right)\right)}}\]
    3. Applied simplify1.8

      \[\leadsto \color{blue}{\frac{t \cdot \sqrt{2}}{\left(\frac{\frac{\frac{t}{x}}{x}}{\sqrt{2}} - t \cdot \sqrt{2}\right) - \frac{\frac{2}{x}}{\sqrt{2}} \cdot \left(\frac{t}{x} + t\right)}}\]

    if -9.551209580007774e+135 < t < 6.64164782115949e+42

    1. Initial program 37.3

      \[\frac{\sqrt{2} \cdot t}{\sqrt{\frac{x + 1}{x - 1} \cdot \left(\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)\right) - \ell \cdot \ell}}\]
    2. Taylor expanded around inf 16.4

      \[\leadsto \frac{\sqrt{2} \cdot t}{\sqrt{\color{blue}{2 \cdot {t}^{2} + \left(2 \cdot \frac{{\ell}^{2}}{x} + 4 \cdot \frac{{t}^{2}}{x}\right)}}}\]
    3. Using strategy rm
    4. Applied unpow216.4

      \[\leadsto \frac{\sqrt{2} \cdot t}{\sqrt{2 \cdot {t}^{2} + \left(2 \cdot \frac{\color{blue}{\ell \cdot \ell}}{x} + 4 \cdot \frac{{t}^{2}}{x}\right)}}\]
    5. Applied associate-/l*12.5

      \[\leadsto \frac{\sqrt{2} \cdot t}{\sqrt{2 \cdot {t}^{2} + \left(2 \cdot \color{blue}{\frac{\ell}{\frac{x}{\ell}}} + 4 \cdot \frac{{t}^{2}}{x}\right)}}\]
    6. Using strategy rm
    7. Applied *-un-lft-identity12.5

      \[\leadsto \frac{\sqrt{2} \cdot t}{\sqrt{\color{blue}{1 \cdot \left(2 \cdot {t}^{2} + \left(2 \cdot \frac{\ell}{\frac{x}{\ell}} + 4 \cdot \frac{{t}^{2}}{x}\right)\right)}}}\]
    8. Applied sqrt-prod12.5

      \[\leadsto \frac{\sqrt{2} \cdot t}{\color{blue}{\sqrt{1} \cdot \sqrt{2 \cdot {t}^{2} + \left(2 \cdot \frac{\ell}{\frac{x}{\ell}} + 4 \cdot \frac{{t}^{2}}{x}\right)}}}\]
    9. Applied times-frac12.6

      \[\leadsto \color{blue}{\frac{\sqrt{2}}{\sqrt{1}} \cdot \frac{t}{\sqrt{2 \cdot {t}^{2} + \left(2 \cdot \frac{\ell}{\frac{x}{\ell}} + 4 \cdot \frac{{t}^{2}}{x}\right)}}}\]

    if 6.64164782115949e+42 < t

    1. Initial program 44.0

      \[\frac{\sqrt{2} \cdot t}{\sqrt{\frac{x + 1}{x - 1} \cdot \left(\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)\right) - \ell \cdot \ell}}\]
    2. Taylor expanded around inf 4.2

      \[\leadsto \frac{\sqrt{2} \cdot t}{\color{blue}{\left(t \cdot \sqrt{2} + \left(2 \cdot \frac{t}{\sqrt{2} \cdot x} + 2 \cdot \frac{t}{\sqrt{2} \cdot {x}^{2}}\right)\right) - 2 \cdot \frac{t}{{\left(\sqrt{2}\right)}^{3} \cdot {x}^{2}}}}\]
    3. Applied simplify4.2

      \[\leadsto \color{blue}{\frac{t \cdot \sqrt{2}}{\left(\frac{\frac{2}{x}}{\sqrt{2}} \cdot \left(\frac{t}{x} + t\right) + t \cdot \sqrt{2}\right) - \frac{\frac{\frac{t}{x}}{x}}{\sqrt{2}}}}\]
  3. Recombined 3 regimes into one program.
  4. Removed slow pow expressions.

Runtime

Time bar (total: 3.5m)Debug logProfile

herbie shell --seed '#(1063282112 2455465480 4141627379 3773598652 1647277307 776739644)' 
(FPCore (x l t)
  :name "Toniolo and Linder, Equation (7)"
  (/ (* (sqrt 2) t) (sqrt (- (* (/ (+ x 1) (- x 1)) (+ (* l l) (* 2 (* t t)))) (* l l)))))