Average Error: 42.8 → 9.8
Time: 1.9m
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 -2.985468283655096 \cdot 10^{+110}:\\ \;\;\;\;\frac{t}{\frac{\frac{t}{x}}{x + x} - \left(\frac{t}{1} + \frac{t}{\frac{x}{1}}\right)}\\ \mathbf{if}\;t \le -1.5333499902358367 \cdot 10^{-133}:\\ \;\;\;\;\frac{t \cdot \sqrt{2}}{\sqrt{\frac{4 \cdot t}{\frac{x}{t}} + \left(\left(t \cdot t + t \cdot t\right) + \left(\ell + \ell\right) \cdot \frac{\ell}{x}\right)}}\\ \mathbf{if}\;t \le -1.1597735907264873 \cdot 10^{-224}:\\ \;\;\;\;\frac{t}{\frac{\frac{t}{x}}{x + x} - \left(\frac{t}{1} + \frac{t}{\frac{x}{1}}\right)}\\ \mathbf{if}\;t \le 4.06565598290016 \cdot 10^{+141}:\\ \;\;\;\;\frac{t \cdot \sqrt{2}}{\sqrt{\frac{4 \cdot t}{\frac{x}{t}} + \left(\left(t \cdot t + t \cdot t\right) + \left(\ell + \ell\right) \cdot \frac{\ell}{x}\right)}}\\ \mathbf{else}:\\ \;\;\;\;\frac{t \cdot \sqrt{2}}{t \cdot \left(\sqrt{2} + \frac{\frac{2}{x}}{\sqrt{2}}\right) + \frac{\frac{t}{x}}{x} \cdot \left(\frac{2}{\sqrt{2}} - \frac{1}{\sqrt{2}}\right)}\\ \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 < -2.985468283655096e+110 or -1.5333499902358367e-133 < t < -1.1597735907264873e-224

    1. Initial program 53.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 46.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. Taylor expanded around -inf 63.5

      \[\leadsto \frac{\sqrt{2} \cdot t}{\sqrt{2 \cdot {t}^{2} + \left(2 \cdot \frac{{\ell}^{2}}{x} + 4 \cdot \color{blue}{\frac{e^{2 \cdot \left(\log -1 - \log \left(\frac{-1}{t}\right)\right)}}{x}}\right)}}\]
    4. Applied simplify44.3

      \[\leadsto \color{blue}{\frac{t \cdot \sqrt{2}}{\sqrt{\frac{4 \cdot t}{\frac{x}{t}} + \left(\left(t \cdot t + t \cdot t\right) + \left(\ell + \ell\right) \cdot \frac{\ell}{x}\right)}}}\]
    5. Taylor expanded around -inf 9.5

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

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

    if -2.985468283655096e+110 < t < -1.5333499902358367e-133 or -1.1597735907264873e-224 < t < 4.06565598290016e+141

    1. Initial program 33.9

      \[\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 15.9

      \[\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. Taylor expanded around -inf 62.7

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

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

    if 4.06565598290016e+141 < t

    1. Initial program 58.7

      \[\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 2.7

      \[\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 simplify2.7

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

Runtime

Time bar (total: 1.9m)Debug logProfile

herbie shell --seed '#(1070227846 1561819246 480764335 4016816270 2602869839 2117310382)' 
(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)))))