Average Error: 41.9 → 7.0
Time: 1.4m
Precision: 64
Internal Precision: 1344
\[\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 -7.247181590380752 \cdot 10^{+152}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\left(1 - 2\right) \cdot \frac{t}{\left(x \cdot x\right) \cdot \sqrt{2}} - \left(\sqrt{2} + \frac{\frac{2}{x}}{\sqrt{2}}\right) \cdot t}\\ \mathbf{elif}\;t \le -3.1035697556023197 \cdot 10^{-161}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\sqrt{\ell \cdot \left(\left(\ell \cdot 2\right) \cdot \frac{1}{x}\right) + \left(t \cdot t\right) \cdot \left(\frac{4}{x} + 2\right)}}\\ \mathbf{elif}\;t \le 2.7471558191736114 \cdot 10^{-147}:\\ \;\;\;\;\frac{\left(\sqrt[3]{\sqrt{2}} \cdot t\right) \cdot \left(\sqrt[3]{\sqrt{2}} \cdot \sqrt[3]{\sqrt{2}}\right)}{\frac{\sqrt{\left(2 - \frac{4}{x}\right) \cdot \left(\left(\ell \cdot 2\right) \cdot \ell + \left(\frac{4}{x} + 2\right) \cdot \left(t \cdot \left(t \cdot x\right)\right)\right)}}{\sqrt{\left(2 - \frac{4}{x}\right) \cdot x}}}\\ \mathbf{elif}\;t \le 1.7806192624872625 \cdot 10^{+108}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\sqrt{\ell \cdot \left(\left(\ell \cdot 2\right) \cdot \frac{1}{x}\right) + \left(t \cdot t\right) \cdot \left(\frac{4}{x} + 2\right)}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\left(\sqrt{2} + \frac{\frac{2}{x}}{\sqrt{2}}\right) \cdot t + \left(2 - 1\right) \cdot \frac{\frac{t}{\sqrt{2}}}{x \cdot x}}\\ \end{array}\]

Error

Bits error versus x

Bits error versus l

Bits error versus t

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Split input into 4 regimes
  2. if t < -7.247181590380752e+152

    1. Initial program 62.2

      \[\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(2 \cdot \frac{t}{\sqrt{2} \cdot {x}^{2}} + \left(t \cdot \sqrt{2} + 2 \cdot \frac{t}{\sqrt{2} \cdot x}\right)\right)}}\]
    3. Simplified1.8

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

    if -7.247181590380752e+152 < t < -3.1035697556023197e-161 or 2.7471558191736114e-147 < t < 1.7806192624872625e+108

    1. Initial program 24.4

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

      \[\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. Simplified4.9

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

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

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

    if -3.1035697556023197e-161 < t < 2.7471558191736114e-147

    1. Initial program 60.1

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

      \[\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. Simplified28.9

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

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

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

      \[\leadsto \frac{\color{blue}{\left(\left(\sqrt[3]{\sqrt{2}} \cdot \sqrt[3]{\sqrt{2}}\right) \cdot \sqrt[3]{\sqrt{2}}\right)} \cdot t}{\sqrt{\ell \cdot \left(\frac{1}{x} \cdot \left(\ell \cdot 2\right)\right) + \left(2 + \frac{4}{x}\right) \cdot \left(t \cdot t\right)}}\]
    9. Applied associate-*l*28.9

      \[\leadsto \frac{\color{blue}{\left(\sqrt[3]{\sqrt{2}} \cdot \sqrt[3]{\sqrt{2}}\right) \cdot \left(\sqrt[3]{\sqrt{2}} \cdot t\right)}}{\sqrt{\ell \cdot \left(\frac{1}{x} \cdot \left(\ell \cdot 2\right)\right) + \left(2 + \frac{4}{x}\right) \cdot \left(t \cdot t\right)}}\]
    10. Using strategy rm
    11. Applied flip-+28.9

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

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

      \[\leadsto \frac{\left(\sqrt[3]{\sqrt{2}} \cdot \sqrt[3]{\sqrt{2}}\right) \cdot \left(\sqrt[3]{\sqrt{2}} \cdot t\right)}{\sqrt{\ell \cdot \color{blue}{\frac{1 \cdot \left(\ell \cdot 2\right)}{x}} + \frac{\left(2 \cdot 2 - \frac{4}{x} \cdot \frac{4}{x}\right) \cdot \left(t \cdot t\right)}{2 - \frac{4}{x}}}}\]
    14. Applied associate-*r/31.0

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

      \[\leadsto \frac{\left(\sqrt[3]{\sqrt{2}} \cdot \sqrt[3]{\sqrt{2}}\right) \cdot \left(\sqrt[3]{\sqrt{2}} \cdot t\right)}{\sqrt{\color{blue}{\frac{\left(\ell \cdot \left(1 \cdot \left(\ell \cdot 2\right)\right)\right) \cdot \left(2 - \frac{4}{x}\right) + x \cdot \left(\left(2 \cdot 2 - \frac{4}{x} \cdot \frac{4}{x}\right) \cdot \left(t \cdot t\right)\right)}{x \cdot \left(2 - \frac{4}{x}\right)}}}}\]
    16. Applied sqrt-div27.6

      \[\leadsto \frac{\left(\sqrt[3]{\sqrt{2}} \cdot \sqrt[3]{\sqrt{2}}\right) \cdot \left(\sqrt[3]{\sqrt{2}} \cdot t\right)}{\color{blue}{\frac{\sqrt{\left(\ell \cdot \left(1 \cdot \left(\ell \cdot 2\right)\right)\right) \cdot \left(2 - \frac{4}{x}\right) + x \cdot \left(\left(2 \cdot 2 - \frac{4}{x} \cdot \frac{4}{x}\right) \cdot \left(t \cdot t\right)\right)}}{\sqrt{x \cdot \left(2 - \frac{4}{x}\right)}}}}\]
    17. Simplified20.9

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

    if 1.7806192624872625e+108 < t

    1. Initial program 52.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 2.7

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \le -7.247181590380752 \cdot 10^{+152}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\left(1 - 2\right) \cdot \frac{t}{\left(x \cdot x\right) \cdot \sqrt{2}} - \left(\sqrt{2} + \frac{\frac{2}{x}}{\sqrt{2}}\right) \cdot t}\\ \mathbf{elif}\;t \le -3.1035697556023197 \cdot 10^{-161}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\sqrt{\ell \cdot \left(\left(\ell \cdot 2\right) \cdot \frac{1}{x}\right) + \left(t \cdot t\right) \cdot \left(\frac{4}{x} + 2\right)}}\\ \mathbf{elif}\;t \le 2.7471558191736114 \cdot 10^{-147}:\\ \;\;\;\;\frac{\left(\sqrt[3]{\sqrt{2}} \cdot t\right) \cdot \left(\sqrt[3]{\sqrt{2}} \cdot \sqrt[3]{\sqrt{2}}\right)}{\frac{\sqrt{\left(2 - \frac{4}{x}\right) \cdot \left(\left(\ell \cdot 2\right) \cdot \ell + \left(\frac{4}{x} + 2\right) \cdot \left(t \cdot \left(t \cdot x\right)\right)\right)}}{\sqrt{\left(2 - \frac{4}{x}\right) \cdot x}}}\\ \mathbf{elif}\;t \le 1.7806192624872625 \cdot 10^{+108}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\sqrt{\ell \cdot \left(\left(\ell \cdot 2\right) \cdot \frac{1}{x}\right) + \left(t \cdot t\right) \cdot \left(\frac{4}{x} + 2\right)}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\left(\sqrt{2} + \frac{\frac{2}{x}}{\sqrt{2}}\right) \cdot t + \left(2 - 1\right) \cdot \frac{\frac{t}{\sqrt{2}}}{x \cdot x}}\\ \end{array}\]

Runtime

Time bar (total: 1.4m)Debug logProfile

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