Average Error: 42.9 → 8.7
Time: 8.4s
Precision: 64
\[\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 -8.703772595808916454667436984685994375446 \cdot 10^{141}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\left(2 \cdot \left(\frac{t}{{\left(\sqrt{2}\right)}^{3} \cdot {x}^{2}} - \frac{t}{\sqrt{2} \cdot {x}^{2}}\right) - \sqrt{2} \cdot t\right) - 2 \cdot \frac{t}{\sqrt{2} \cdot x}}\\ \mathbf{elif}\;t \le 2.555685633755422263184735039093424552333 \cdot 10^{-264}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\sqrt{4 \cdot \frac{{t}^{2}}{x} + 2 \cdot \left({t}^{2} + \ell \cdot \frac{\ell}{x}\right)}}\\ \mathbf{elif}\;t \le 5.748160003020186103470224388296769238726 \cdot 10^{-158}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{2 \cdot \left(\frac{t}{\sqrt{2} \cdot {x}^{2}} + \frac{t}{\sqrt{2} \cdot x}\right) + \left(\sqrt{2} \cdot t - 2 \cdot \frac{t}{{\left(\sqrt{2}\right)}^{3} \cdot {x}^{2}}\right)}\\ \mathbf{elif}\;t \le 4.837673144276178631404051943017687346215 \cdot 10^{123}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\sqrt{4 \cdot \frac{{t}^{2}}{x} + 2 \cdot \left(\sqrt{{t}^{2} + \frac{\ell}{\frac{x}{\ell}}} \cdot \left(\sqrt{\sqrt{{t}^{2} + \frac{\ell}{\frac{x}{\ell}}}} \cdot \sqrt{\sqrt{{t}^{2} + \frac{\ell}{\frac{x}{\ell}}}}\right)\right)}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{2 \cdot \left(\frac{t}{\sqrt{2} \cdot {x}^{2}} + \frac{t}{\sqrt{2} \cdot x}\right) + \left(\sqrt{2} \cdot t - 2 \cdot \frac{t}{{\left(\sqrt{2}\right)}^{3} \cdot {x}^{2}}\right)}\\ \end{array}\]
\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 -8.703772595808916454667436984685994375446 \cdot 10^{141}:\\
\;\;\;\;\frac{\sqrt{2} \cdot t}{\left(2 \cdot \left(\frac{t}{{\left(\sqrt{2}\right)}^{3} \cdot {x}^{2}} - \frac{t}{\sqrt{2} \cdot {x}^{2}}\right) - \sqrt{2} \cdot t\right) - 2 \cdot \frac{t}{\sqrt{2} \cdot x}}\\

\mathbf{elif}\;t \le 2.555685633755422263184735039093424552333 \cdot 10^{-264}:\\
\;\;\;\;\frac{\sqrt{2} \cdot t}{\sqrt{4 \cdot \frac{{t}^{2}}{x} + 2 \cdot \left({t}^{2} + \ell \cdot \frac{\ell}{x}\right)}}\\

\mathbf{elif}\;t \le 5.748160003020186103470224388296769238726 \cdot 10^{-158}:\\
\;\;\;\;\frac{\sqrt{2} \cdot t}{2 \cdot \left(\frac{t}{\sqrt{2} \cdot {x}^{2}} + \frac{t}{\sqrt{2} \cdot x}\right) + \left(\sqrt{2} \cdot t - 2 \cdot \frac{t}{{\left(\sqrt{2}\right)}^{3} \cdot {x}^{2}}\right)}\\

\mathbf{elif}\;t \le 4.837673144276178631404051943017687346215 \cdot 10^{123}:\\
\;\;\;\;\frac{\sqrt{2} \cdot t}{\sqrt{4 \cdot \frac{{t}^{2}}{x} + 2 \cdot \left(\sqrt{{t}^{2} + \frac{\ell}{\frac{x}{\ell}}} \cdot \left(\sqrt{\sqrt{{t}^{2} + \frac{\ell}{\frac{x}{\ell}}}} \cdot \sqrt{\sqrt{{t}^{2} + \frac{\ell}{\frac{x}{\ell}}}}\right)\right)}}\\

\mathbf{else}:\\
\;\;\;\;\frac{\sqrt{2} \cdot t}{2 \cdot \left(\frac{t}{\sqrt{2} \cdot {x}^{2}} + \frac{t}{\sqrt{2} \cdot x}\right) + \left(\sqrt{2} \cdot t - 2 \cdot \frac{t}{{\left(\sqrt{2}\right)}^{3} \cdot {x}^{2}}\right)}\\

\end{array}
double f(double x, double l, double t) {
        double r34716 = 2.0;
        double r34717 = sqrt(r34716);
        double r34718 = t;
        double r34719 = r34717 * r34718;
        double r34720 = x;
        double r34721 = 1.0;
        double r34722 = r34720 + r34721;
        double r34723 = r34720 - r34721;
        double r34724 = r34722 / r34723;
        double r34725 = l;
        double r34726 = r34725 * r34725;
        double r34727 = r34718 * r34718;
        double r34728 = r34716 * r34727;
        double r34729 = r34726 + r34728;
        double r34730 = r34724 * r34729;
        double r34731 = r34730 - r34726;
        double r34732 = sqrt(r34731);
        double r34733 = r34719 / r34732;
        return r34733;
}

double f(double x, double l, double t) {
        double r34734 = t;
        double r34735 = -8.703772595808916e+141;
        bool r34736 = r34734 <= r34735;
        double r34737 = 2.0;
        double r34738 = sqrt(r34737);
        double r34739 = r34738 * r34734;
        double r34740 = 3.0;
        double r34741 = pow(r34738, r34740);
        double r34742 = x;
        double r34743 = 2.0;
        double r34744 = pow(r34742, r34743);
        double r34745 = r34741 * r34744;
        double r34746 = r34734 / r34745;
        double r34747 = r34738 * r34744;
        double r34748 = r34734 / r34747;
        double r34749 = r34746 - r34748;
        double r34750 = r34737 * r34749;
        double r34751 = r34750 - r34739;
        double r34752 = r34738 * r34742;
        double r34753 = r34734 / r34752;
        double r34754 = r34737 * r34753;
        double r34755 = r34751 - r34754;
        double r34756 = r34739 / r34755;
        double r34757 = 2.5556856337554223e-264;
        bool r34758 = r34734 <= r34757;
        double r34759 = 4.0;
        double r34760 = pow(r34734, r34743);
        double r34761 = r34760 / r34742;
        double r34762 = r34759 * r34761;
        double r34763 = l;
        double r34764 = r34763 / r34742;
        double r34765 = r34763 * r34764;
        double r34766 = r34760 + r34765;
        double r34767 = r34737 * r34766;
        double r34768 = r34762 + r34767;
        double r34769 = sqrt(r34768);
        double r34770 = r34739 / r34769;
        double r34771 = 5.748160003020186e-158;
        bool r34772 = r34734 <= r34771;
        double r34773 = r34748 + r34753;
        double r34774 = r34737 * r34773;
        double r34775 = r34737 * r34746;
        double r34776 = r34739 - r34775;
        double r34777 = r34774 + r34776;
        double r34778 = r34739 / r34777;
        double r34779 = 4.8376731442761786e+123;
        bool r34780 = r34734 <= r34779;
        double r34781 = r34742 / r34763;
        double r34782 = r34763 / r34781;
        double r34783 = r34760 + r34782;
        double r34784 = sqrt(r34783);
        double r34785 = sqrt(r34784);
        double r34786 = r34785 * r34785;
        double r34787 = r34784 * r34786;
        double r34788 = r34737 * r34787;
        double r34789 = r34762 + r34788;
        double r34790 = sqrt(r34789);
        double r34791 = r34739 / r34790;
        double r34792 = r34780 ? r34791 : r34778;
        double r34793 = r34772 ? r34778 : r34792;
        double r34794 = r34758 ? r34770 : r34793;
        double r34795 = r34736 ? r34756 : r34794;
        return r34795;
}

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 < -8.703772595808916e+141

    1. Initial program 58.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 2.1

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

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

    if -8.703772595808916e+141 < t < 2.5556856337554223e-264

    1. Initial program 37.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 17.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. Simplified17.0

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

      \[\leadsto \frac{\sqrt{2} \cdot t}{\sqrt{4 \cdot \frac{{t}^{2}}{x} + 2 \cdot \left({t}^{2} + \frac{{\ell}^{2}}{\color{blue}{1 \cdot x}}\right)}}\]
    6. Applied add-sqr-sqrt41.0

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

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

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

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

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

    if 2.5556856337554223e-264 < t < 5.748160003020186e-158 or 4.8376731442761786e+123 < t

    1. Initial program 57.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.8

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

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

    if 5.748160003020186e-158 < t < 4.8376731442761786e+123

    1. Initial program 25.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 9.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. Simplified9.9

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \le -8.703772595808916454667436984685994375446 \cdot 10^{141}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\left(2 \cdot \left(\frac{t}{{\left(\sqrt{2}\right)}^{3} \cdot {x}^{2}} - \frac{t}{\sqrt{2} \cdot {x}^{2}}\right) - \sqrt{2} \cdot t\right) - 2 \cdot \frac{t}{\sqrt{2} \cdot x}}\\ \mathbf{elif}\;t \le 2.555685633755422263184735039093424552333 \cdot 10^{-264}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\sqrt{4 \cdot \frac{{t}^{2}}{x} + 2 \cdot \left({t}^{2} + \ell \cdot \frac{\ell}{x}\right)}}\\ \mathbf{elif}\;t \le 5.748160003020186103470224388296769238726 \cdot 10^{-158}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{2 \cdot \left(\frac{t}{\sqrt{2} \cdot {x}^{2}} + \frac{t}{\sqrt{2} \cdot x}\right) + \left(\sqrt{2} \cdot t - 2 \cdot \frac{t}{{\left(\sqrt{2}\right)}^{3} \cdot {x}^{2}}\right)}\\ \mathbf{elif}\;t \le 4.837673144276178631404051943017687346215 \cdot 10^{123}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{\sqrt{4 \cdot \frac{{t}^{2}}{x} + 2 \cdot \left(\sqrt{{t}^{2} + \frac{\ell}{\frac{x}{\ell}}} \cdot \left(\sqrt{\sqrt{{t}^{2} + \frac{\ell}{\frac{x}{\ell}}}} \cdot \sqrt{\sqrt{{t}^{2} + \frac{\ell}{\frac{x}{\ell}}}}\right)\right)}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{2} \cdot t}{2 \cdot \left(\frac{t}{\sqrt{2} \cdot {x}^{2}} + \frac{t}{\sqrt{2} \cdot x}\right) + \left(\sqrt{2} \cdot t - 2 \cdot \frac{t}{{\left(\sqrt{2}\right)}^{3} \cdot {x}^{2}}\right)}\\ \end{array}\]

Reproduce

herbie shell --seed 2020001 
(FPCore (x l t)
  :name "Toniolo and Linder, Equation (7)"
  :precision binary64
  (/ (* (sqrt 2) t) (sqrt (- (* (/ (+ x 1) (- x 1)) (+ (* l l) (* 2 (* t t)))) (* l l)))))