Average Error: 42.5 → 9.3
Time: 1.1m
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 -2.69700858135169 \cdot 10^{+101}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\left(\frac{\frac{t}{x}}{2 \cdot x} - \frac{t}{x}\right) \cdot \frac{2}{\sqrt{2}} - \left(\sqrt{2} \cdot t + \frac{\frac{t}{x}}{x} \cdot \frac{2}{\sqrt{2}}\right)}\\ \mathbf{elif}\;t \le -9.13412116569702 \cdot 10^{-171}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\sqrt{\left(t \cdot t\right) \cdot \left(2 + \frac{4}{x}\right) + \frac{\ell}{x} \cdot \left(\ell \cdot 2\right)}}\\ \mathbf{elif}\;t \le -1.746335371346005 \cdot 10^{-240}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\left(\frac{\frac{t}{x}}{2 \cdot x} - \frac{t}{x}\right) \cdot \frac{2}{\sqrt{2}} - \left(\sqrt{2} \cdot t + \frac{\frac{t}{x}}{x} \cdot \frac{2}{\sqrt{2}}\right)}\\ \mathbf{elif}\;t \le 5.842328878909656 \cdot 10^{-296}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\frac{\sqrt{\left(2 - \frac{4}{x}\right) \cdot \left(\left(\ell \cdot 2\right) \cdot \ell + \left(x \cdot \left(t \cdot t\right)\right) \cdot \left(2 + \frac{4}{x}\right)\right)}}{\sqrt{\left(2 - \frac{4}{x}\right) \cdot x}}}\\ \mathbf{elif}\;t \le 1.05457477885466 \cdot 10^{-254}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{t \cdot \left(\frac{\frac{2}{x}}{\sqrt{2}} + \sqrt{2}\right) + \frac{\frac{\frac{2}{x}}{x}}{\sqrt{2}} \cdot \left(t - \frac{t}{2}\right)}\\ \mathbf{elif}\;t \le 4.8098290652177705 \cdot 10^{-213}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\frac{\sqrt{\left(2 - \frac{4}{x}\right) \cdot \left(\left(\ell \cdot 2\right) \cdot \ell + \left(x \cdot \left(t \cdot t\right)\right) \cdot \left(2 + \frac{4}{x}\right)\right)}}{\sqrt{\left(2 - \frac{4}{x}\right) \cdot x}}}\\ \mathbf{elif}\;t \le 4.4209825982852586 \cdot 10^{-166} \lor \neg \left(t \le 3.0075205597479413 \cdot 10^{+125}\right):\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{t \cdot \left(\frac{\frac{2}{x}}{\sqrt{2}} + \sqrt{2}\right) + \frac{\frac{\frac{2}{x}}{x}}{\sqrt{2}} \cdot \left(t - \frac{t}{2}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\sqrt{\left(t \cdot t\right) \cdot \left(2 + \frac{4}{x}\right) + \frac{\ell}{x} \cdot \left(\ell \cdot 2\right)}}\\ \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 < -2.69700858135169e+101 or -9.13412116569702e-171 < t < -1.746335371346005e-240

    1. Initial program 53.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 9.9

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

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

    if -2.69700858135169e+101 < t < -9.13412116569702e-171 or 4.4209825982852586e-166 < t < 3.0075205597479413e+125

    1. Initial program 26.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 10.7

      \[\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. Simplified5.6

      \[\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)}}}\]

    if -1.746335371346005e-240 < t < 5.842328878909656e-296 or 1.05457477885466e-254 < t < 4.8098290652177705e-213

    1. Initial program 61.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 28.8

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

      \[\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 flip-+28.3

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

      \[\leadsto \frac{\sqrt{2} \cdot t}{\sqrt{\frac{\ell}{x} \cdot \left(\ell \cdot 2\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}}}}}\]
    7. Applied associate-*l/28.7

      \[\leadsto \frac{\sqrt{2} \cdot t}{\sqrt{\color{blue}{\frac{\ell \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}}}}\]
    8. Applied frac-add29.1

      \[\leadsto \frac{\sqrt{2} \cdot t}{\sqrt{\color{blue}{\frac{\left(\ell \cdot \left(\ell \cdot 2\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)}}}}\]
    9. Applied sqrt-div24.1

      \[\leadsto \frac{\sqrt{2} \cdot t}{\color{blue}{\frac{\sqrt{\left(\ell \cdot \left(\ell \cdot 2\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)}}}}\]
    10. Simplified24.1

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

    if 5.842328878909656e-296 < t < 1.05457477885466e-254 or 4.8098290652177705e-213 < t < 4.4209825982852586e-166 or 3.0075205597479413e+125 < t

    1. Initial program 56.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 11.0

      \[\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. Simplified11.0

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \le -2.69700858135169 \cdot 10^{+101}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\left(\frac{\frac{t}{x}}{2 \cdot x} - \frac{t}{x}\right) \cdot \frac{2}{\sqrt{2}} - \left(\sqrt{2} \cdot t + \frac{\frac{t}{x}}{x} \cdot \frac{2}{\sqrt{2}}\right)}\\ \mathbf{elif}\;t \le -9.13412116569702 \cdot 10^{-171}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\sqrt{\left(t \cdot t\right) \cdot \left(2 + \frac{4}{x}\right) + \frac{\ell}{x} \cdot \left(\ell \cdot 2\right)}}\\ \mathbf{elif}\;t \le -1.746335371346005 \cdot 10^{-240}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\left(\frac{\frac{t}{x}}{2 \cdot x} - \frac{t}{x}\right) \cdot \frac{2}{\sqrt{2}} - \left(\sqrt{2} \cdot t + \frac{\frac{t}{x}}{x} \cdot \frac{2}{\sqrt{2}}\right)}\\ \mathbf{elif}\;t \le 5.842328878909656 \cdot 10^{-296}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\frac{\sqrt{\left(2 - \frac{4}{x}\right) \cdot \left(\left(\ell \cdot 2\right) \cdot \ell + \left(x \cdot \left(t \cdot t\right)\right) \cdot \left(2 + \frac{4}{x}\right)\right)}}{\sqrt{\left(2 - \frac{4}{x}\right) \cdot x}}}\\ \mathbf{elif}\;t \le 1.05457477885466 \cdot 10^{-254}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{t \cdot \left(\frac{\frac{2}{x}}{\sqrt{2}} + \sqrt{2}\right) + \frac{\frac{\frac{2}{x}}{x}}{\sqrt{2}} \cdot \left(t - \frac{t}{2}\right)}\\ \mathbf{elif}\;t \le 4.8098290652177705 \cdot 10^{-213}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\frac{\sqrt{\left(2 - \frac{4}{x}\right) \cdot \left(\left(\ell \cdot 2\right) \cdot \ell + \left(x \cdot \left(t \cdot t\right)\right) \cdot \left(2 + \frac{4}{x}\right)\right)}}{\sqrt{\left(2 - \frac{4}{x}\right) \cdot x}}}\\ \mathbf{elif}\;t \le 4.4209825982852586 \cdot 10^{-166} \lor \neg \left(t \le 3.0075205597479413 \cdot 10^{+125}\right):\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{t \cdot \left(\frac{\frac{2}{x}}{\sqrt{2}} + \sqrt{2}\right) + \frac{\frac{\frac{2}{x}}{x}}{\sqrt{2}} \cdot \left(t - \frac{t}{2}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\sqrt{\left(t \cdot t\right) \cdot \left(2 + \frac{4}{x}\right) + \frac{\ell}{x} \cdot \left(\ell \cdot 2\right)}}\\ \end{array}\]

Runtime

Time bar (total: 1.1m)Debug logProfile

BaselineHerbieOracleSpan%
Regimes26.79.32.923.873.1%
herbie shell --seed 2018340 
(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)))))