Average Error: 51.9 → 18.5
Time: 1.8m
Precision: 64
Internal precision: 128
\[\frac{\sqrt{2} \cdot t}{\sqrt{\frac{x + 1}{x - 1} \cdot \left({\ell}^2 + 2 \cdot {t}^2\right) - {\ell}^2}}\]
\[\begin{array}{l} \mathbf{if}\;t \le -1.2730590619964553 \cdot 10^{+132}:\\ \;\;\;\;\frac{t \cdot \sqrt{2}}{\frac{t}{\left(x \cdot x\right) \cdot \sqrt{2}} - \left(t \cdot \sqrt{2} + \frac{\frac{t}{x} + t}{\frac{\sqrt{2}}{\frac{2}{x}}}\right)}\\ \mathbf{if}\;t \le 1.5136350586525492 \cdot 10^{-195}:\\ \;\;\;\;\frac{\sqrt{2}}{\sqrt{1}} \cdot \frac{t}{\sqrt{4 \cdot \frac{{t}^2}{x} + \left(2 \cdot \frac{\ell}{\frac{x}{\ell}} + 2 \cdot {t}^2\right)}}\\ \mathbf{if}\;t \le 4.470739305871678 \cdot 10^{-159}:\\ \;\;\;\;\frac{t \cdot \sqrt{2}}{\left(\frac{t}{\sqrt{2}} \cdot \frac{\frac{2}{x}}{x} + t \cdot \sqrt{2}\right) + \frac{\frac{2}{x}}{\sqrt{2}} \cdot \left(t - \frac{t}{x + x}\right)}\\ \mathbf{if}\;t \le 4.486255046473517 \cdot 10^{+98}:\\ \;\;\;\;{\left(\sqrt{\frac{\sqrt{2} \cdot t}{\sqrt{4 \cdot \frac{{t}^2}{x} + \left(2 \cdot \frac{\ell}{\frac{x}{\ell}} + 2 \cdot {t}^2\right)}}}\right)}^2\\ \mathbf{else}:\\ \;\;\;\;\frac{t \cdot \sqrt{2}}{\left(\frac{t}{\sqrt{2}} \cdot \frac{\frac{2}{x}}{x} + t \cdot \sqrt{2}\right) + \frac{\frac{2}{x}}{\sqrt{2}} \cdot \left(t - \frac{t}{x + x}\right)}\\ \end{array}\]

Error

Bits error versus x

Bits error versus l

Bits error versus t

Derivation

  1. Split input into 4 regimes.
  2. if t < -1.2730590619964553e+132

    1. Initial program 60.3

      \[\frac{\sqrt{2} \cdot t}{\sqrt{\frac{x + 1}{x - 1} \cdot \left({\ell}^2 + 2 \cdot {t}^2\right) - {\ell}^2}}\]
    2. Applied taylor 28.4

      \[\leadsto \frac{\sqrt{2} \cdot t}{2 \cdot \frac{t}{{\left(\sqrt{2}\right)}^{3} \cdot {x}^2} - \left(2 \cdot \frac{t}{\sqrt{2} \cdot {x}^2} + \left(t \cdot \sqrt{2} + 2 \cdot \frac{t}{x \cdot \sqrt{2}}\right)\right)}\]
    3. Taylor expanded around -inf 28.4

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

      \[\leadsto \color{blue}{\frac{t \cdot \sqrt{2}}{\frac{\frac{\frac{t}{1}}{\sqrt{2}}}{x \cdot x} - \left(\frac{\frac{2}{x}}{\sqrt{2}} \cdot \left(t + \frac{t}{x}\right) + t \cdot \sqrt{2}\right)}}\]
    5. Applied simplify 28.4

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

    if -1.2730590619964553e+132 < t < 1.5136350586525492e-195

    1. Initial program 49.8

      \[\frac{\sqrt{2} \cdot t}{\sqrt{\frac{x + 1}{x - 1} \cdot \left({\ell}^2 + 2 \cdot {t}^2\right) - {\ell}^2}}\]
    2. Applied taylor 19.1

      \[\leadsto \frac{\sqrt{2} \cdot t}{\sqrt{4 \cdot \frac{{t}^2}{x} + \left(2 \cdot \frac{{\ell}^2}{x} + 2 \cdot {t}^2\right)}}\]
    3. Taylor expanded around inf 19.1

      \[\leadsto \frac{\sqrt{2} \cdot t}{\sqrt{\color{blue}{4 \cdot \frac{{t}^2}{x} + \left(2 \cdot \frac{{\ell}^2}{x} + 2 \cdot {t}^2\right)}}}\]
    4. Using strategy rm
    5. Applied square-mult 19.1

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

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

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

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

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

    if 1.5136350586525492e-195 < t < 4.470739305871678e-159 or 4.486255046473517e+98 < t

    1. Initial program 57.3

      \[\frac{\sqrt{2} \cdot t}{\sqrt{\frac{x + 1}{x - 1} \cdot \left({\ell}^2 + 2 \cdot {t}^2\right) - {\ell}^2}}\]
    2. Applied taylor 23.7

      \[\leadsto \frac{\sqrt{2} \cdot t}{\left(2 \cdot \frac{t}{{x}^2 \cdot \sqrt{2}} + \left(t \cdot \sqrt{2} + 2 \cdot \frac{t}{x \cdot \sqrt{2}}\right)\right) - 2 \cdot \frac{t}{{x}^2 \cdot {\left(\sqrt{2}\right)}^{3}}}\]
    3. Taylor expanded around inf 23.7

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

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

    if 4.470739305871678e-159 < t < 4.486255046473517e+98

    1. Initial program 38.8

      \[\frac{\sqrt{2} \cdot t}{\sqrt{\frac{x + 1}{x - 1} \cdot \left({\ell}^2 + 2 \cdot {t}^2\right) - {\ell}^2}}\]
    2. Applied taylor 11.2

      \[\leadsto \frac{\sqrt{2} \cdot t}{\sqrt{4 \cdot \frac{{t}^2}{x} + \left(2 \cdot \frac{{\ell}^2}{x} + 2 \cdot {t}^2\right)}}\]
    3. Taylor expanded around inf 11.2

      \[\leadsto \frac{\sqrt{2} \cdot t}{\sqrt{\color{blue}{4 \cdot \frac{{t}^2}{x} + \left(2 \cdot \frac{{\ell}^2}{x} + 2 \cdot {t}^2\right)}}}\]
    4. Using strategy rm
    5. Applied square-mult 11.2

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

      \[\leadsto \frac{\sqrt{2} \cdot t}{\sqrt{4 \cdot \frac{{t}^2}{x} + \left(2 \cdot \color{blue}{\frac{\ell}{\frac{x}{\ell}}} + 2 \cdot {t}^2\right)}}\]
    7. Using strategy rm
    8. Applied add-sqr-sqrt 8.5

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

Runtime

Time bar (total: 1.8m) Debug log

Please include this information when filing a bug report:

herbie --seed '#(1143215297 3307825491 708046951 280961135 1434974233 703142890)'
(FPCore (x l t)
  :name "Toniolo and Linder, Equation (7)"
  (/ (* (sqrt 2) t) (sqrt (- (* (/ (+ x 1) (- x 1)) (+ (sqr l) (* 2 (sqr t)))) (sqr l)))))