| Alternative 1 | |
|---|---|
| Error | 8.0 |
| Cost | 20304 |
(FPCore (x l t) :precision binary64 (/ (* (sqrt 2.0) t) (sqrt (- (* (/ (+ x 1.0) (- x 1.0)) (+ (* l l) (* 2.0 (* t t)))) (* l l)))))
(FPCore (x l t)
:precision binary64
(let* ((t_1
(*
(sqrt 2.0)
(/
t
(sqrt (* 2.0 (+ (* (* t t) (+ 1.0 (/ 2.0 x))) (/ l (/ x l)))))))))
(if (<= t -9e+149)
-1.0
(if (<= t -7e-139)
t_1
(if (<= t 1.9e-144)
(/ t (hypot t (sqrt (/ (fma 2.0 (* t t) (* l l)) x))))
(if (<= t 2e+134) t_1 (+ 1.0 (/ -1.0 x))))))))double code(double x, double l, double t) {
return (sqrt(2.0) * t) / sqrt(((((x + 1.0) / (x - 1.0)) * ((l * l) + (2.0 * (t * t)))) - (l * l)));
}
double code(double x, double l, double t) {
double t_1 = sqrt(2.0) * (t / sqrt((2.0 * (((t * t) * (1.0 + (2.0 / x))) + (l / (x / l))))));
double tmp;
if (t <= -9e+149) {
tmp = -1.0;
} else if (t <= -7e-139) {
tmp = t_1;
} else if (t <= 1.9e-144) {
tmp = t / hypot(t, sqrt((fma(2.0, (t * t), (l * l)) / x)));
} else if (t <= 2e+134) {
tmp = t_1;
} else {
tmp = 1.0 + (-1.0 / x);
}
return tmp;
}
function code(x, l, t) return Float64(Float64(sqrt(2.0) * t) / sqrt(Float64(Float64(Float64(Float64(x + 1.0) / Float64(x - 1.0)) * Float64(Float64(l * l) + Float64(2.0 * Float64(t * t)))) - Float64(l * l)))) end
function code(x, l, t) t_1 = Float64(sqrt(2.0) * Float64(t / sqrt(Float64(2.0 * Float64(Float64(Float64(t * t) * Float64(1.0 + Float64(2.0 / x))) + Float64(l / Float64(x / l))))))) tmp = 0.0 if (t <= -9e+149) tmp = -1.0; elseif (t <= -7e-139) tmp = t_1; elseif (t <= 1.9e-144) tmp = Float64(t / hypot(t, sqrt(Float64(fma(2.0, Float64(t * t), Float64(l * l)) / x)))); elseif (t <= 2e+134) tmp = t_1; else tmp = Float64(1.0 + Float64(-1.0 / x)); end return tmp end
code[x_, l_, t_] := N[(N[(N[Sqrt[2.0], $MachinePrecision] * t), $MachinePrecision] / N[Sqrt[N[(N[(N[(N[(x + 1.0), $MachinePrecision] / N[(x - 1.0), $MachinePrecision]), $MachinePrecision] * N[(N[(l * l), $MachinePrecision] + N[(2.0 * N[(t * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(l * l), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
code[x_, l_, t_] := Block[{t$95$1 = N[(N[Sqrt[2.0], $MachinePrecision] * N[(t / N[Sqrt[N[(2.0 * N[(N[(N[(t * t), $MachinePrecision] * N[(1.0 + N[(2.0 / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(l / N[(x / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -9e+149], -1.0, If[LessEqual[t, -7e-139], t$95$1, If[LessEqual[t, 1.9e-144], N[(t / N[Sqrt[t ^ 2 + N[Sqrt[N[(N[(2.0 * N[(t * t), $MachinePrecision] + N[(l * l), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision]], $MachinePrecision] ^ 2], $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2e+134], t$95$1, N[(1.0 + N[(-1.0 / x), $MachinePrecision]), $MachinePrecision]]]]]]
\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}
t_1 := \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \left(\left(t \cdot t\right) \cdot \left(1 + \frac{2}{x}\right) + \frac{\ell}{\frac{x}{\ell}}\right)}}\\
\mathbf{if}\;t \leq -9 \cdot 10^{+149}:\\
\;\;\;\;-1\\
\mathbf{elif}\;t \leq -7 \cdot 10^{-139}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq 1.9 \cdot 10^{-144}:\\
\;\;\;\;\frac{t}{\mathsf{hypot}\left(t, \sqrt{\frac{\mathsf{fma}\left(2, t \cdot t, \ell \cdot \ell\right)}{x}}\right)}\\
\mathbf{elif}\;t \leq 2 \cdot 10^{+134}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;1 + \frac{-1}{x}\\
\end{array}
if t < -8.99999999999999965e149Initial program 61.0
Simplified61.0
[Start]61.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}}
\] |
|---|---|
associate-*l/ [<=]61.0 | \[ \color{blue}{\frac{\sqrt{2}}{\sqrt{\frac{x + 1}{x - 1} \cdot \left(\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)\right) - \ell \cdot \ell}} \cdot t}
\] |
+-commutative [=>]61.0 | \[ \frac{\sqrt{2}}{\sqrt{\frac{x + 1}{x - 1} \cdot \color{blue}{\left(2 \cdot \left(t \cdot t\right) + \ell \cdot \ell\right)} - \ell \cdot \ell}} \cdot t
\] |
fma-def [=>]61.0 | \[ \frac{\sqrt{2}}{\sqrt{\frac{x + 1}{x - 1} \cdot \color{blue}{\mathsf{fma}\left(2, t \cdot t, \ell \cdot \ell\right)} - \ell \cdot \ell}} \cdot t
\] |
Taylor expanded in t around inf 63.0
Simplified63.0
[Start]63.0 | \[ \left(\frac{\sqrt{2} \cdot \sqrt{0.5}}{t} \cdot \sqrt{\frac{x - 1}{1 + x}}\right) \cdot t
\] |
|---|---|
*-commutative [=>]63.0 | \[ \color{blue}{\left(\sqrt{\frac{x - 1}{1 + x}} \cdot \frac{\sqrt{2} \cdot \sqrt{0.5}}{t}\right)} \cdot t
\] |
associate-/l* [=>]63.0 | \[ \left(\sqrt{\frac{x - 1}{1 + x}} \cdot \color{blue}{\frac{\sqrt{2}}{\frac{t}{\sqrt{0.5}}}}\right) \cdot t
\] |
associate-*r/ [=>]63.0 | \[ \color{blue}{\frac{\sqrt{\frac{x - 1}{1 + x}} \cdot \sqrt{2}}{\frac{t}{\sqrt{0.5}}}} \cdot t
\] |
sub-neg [=>]63.0 | \[ \frac{\sqrt{\frac{\color{blue}{x + \left(-1\right)}}{1 + x}} \cdot \sqrt{2}}{\frac{t}{\sqrt{0.5}}} \cdot t
\] |
metadata-eval [=>]63.0 | \[ \frac{\sqrt{\frac{x + \color{blue}{-1}}{1 + x}} \cdot \sqrt{2}}{\frac{t}{\sqrt{0.5}}} \cdot t
\] |
+-commutative [=>]63.0 | \[ \frac{\sqrt{\frac{\color{blue}{-1 + x}}{1 + x}} \cdot \sqrt{2}}{\frac{t}{\sqrt{0.5}}} \cdot t
\] |
+-commutative [=>]63.0 | \[ \frac{\sqrt{\frac{-1 + x}{\color{blue}{x + 1}}} \cdot \sqrt{2}}{\frac{t}{\sqrt{0.5}}} \cdot t
\] |
Applied egg-rr61.9
Simplified61.9
[Start]61.9 | \[ \sqrt{\frac{\left(-1 + x\right) \cdot 2}{\frac{t \cdot t}{0.5} \cdot \left(x + 1\right)}} \cdot t
\] |
|---|---|
associate-/l* [=>]61.9 | \[ \sqrt{\color{blue}{\frac{-1 + x}{\frac{\frac{t \cdot t}{0.5} \cdot \left(x + 1\right)}{2}}}} \cdot t
\] |
associate-*l/ [=>]61.9 | \[ \sqrt{\frac{-1 + x}{\frac{\color{blue}{\frac{\left(t \cdot t\right) \cdot \left(x + 1\right)}{0.5}}}{2}}} \cdot t
\] |
associate-/l/ [=>]61.9 | \[ \sqrt{\frac{-1 + x}{\color{blue}{\frac{\left(t \cdot t\right) \cdot \left(x + 1\right)}{2 \cdot 0.5}}}} \cdot t
\] |
associate-*l* [=>]61.9 | \[ \sqrt{\frac{-1 + x}{\frac{\color{blue}{t \cdot \left(t \cdot \left(x + 1\right)\right)}}{2 \cdot 0.5}}} \cdot t
\] |
metadata-eval [=>]61.9 | \[ \sqrt{\frac{-1 + x}{\frac{t \cdot \left(t \cdot \left(x + 1\right)\right)}{\color{blue}{1}}}} \cdot t
\] |
Taylor expanded in x around -inf 64.0
Simplified2.3
[Start]64.0 | \[ {\left(\sqrt{-1}\right)}^{2}
\] |
|---|---|
unpow2 [=>]64.0 | \[ \color{blue}{\sqrt{-1} \cdot \sqrt{-1}}
\] |
rem-square-sqrt [=>]2.3 | \[ \color{blue}{-1}
\] |
if -8.99999999999999965e149 < t < -7.00000000000000002e-139 or 1.89999999999999996e-144 < t < 1.99999999999999984e134Initial program 23.7
Simplified29.4
[Start]23.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}}
\] |
|---|---|
associate-*r/ [<=]23.7 | \[ \color{blue}{\sqrt{2} \cdot \frac{t}{\sqrt{\frac{x + 1}{x - 1} \cdot \left(\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)\right) - \ell \cdot \ell}}}
\] |
associate-*l/ [=>]35.3 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{\color{blue}{\frac{\left(x + 1\right) \cdot \left(\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)\right)}{x - 1}} - \ell \cdot \ell}}
\] |
associate-*r/ [<=]29.9 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{\color{blue}{\left(x + 1\right) \cdot \frac{\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)}{x - 1}} - \ell \cdot \ell}}
\] |
*-lft-identity [<=]29.9 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{\color{blue}{\left(1 \cdot \left(x + 1\right)\right)} \cdot \frac{\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)}{x - 1} - \ell \cdot \ell}}
\] |
associate-*r* [<=]29.9 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{\color{blue}{1 \cdot \left(\left(x + 1\right) \cdot \frac{\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)}{x - 1}\right)} - \ell \cdot \ell}}
\] |
*-commutative [<=]29.9 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{1 \cdot \color{blue}{\left(\frac{\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)}{x - 1} \cdot \left(x + 1\right)\right)} - \ell \cdot \ell}}
\] |
associate-*r* [=>]29.9 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{\color{blue}{\left(1 \cdot \frac{\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)}{x - 1}\right) \cdot \left(x + 1\right)} - \ell \cdot \ell}}
\] |
*-commutative [<=]29.9 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{\color{blue}{\left(x + 1\right) \cdot \left(1 \cdot \frac{\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)}{x - 1}\right)} - \ell \cdot \ell}}
\] |
fma-neg [=>]29.4 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{\color{blue}{\mathsf{fma}\left(x + 1, 1 \cdot \frac{\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)}{x - 1}, -\ell \cdot \ell\right)}}}
\] |
Taylor expanded in x around -inf 10.3
Simplified10.3
[Start]10.3 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \frac{{\ell}^{2} + 2 \cdot {t}^{2}}{x} + 2 \cdot {t}^{2}}}
\] |
|---|---|
distribute-lft-out [=>]10.3 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{\color{blue}{2 \cdot \left(\frac{{\ell}^{2} + 2 \cdot {t}^{2}}{x} + {t}^{2}\right)}}}
\] |
+-commutative [=>]10.3 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \left(\frac{\color{blue}{2 \cdot {t}^{2} + {\ell}^{2}}}{x} + {t}^{2}\right)}}
\] |
unpow2 [=>]10.3 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \left(\frac{2 \cdot {t}^{2} + \color{blue}{\ell \cdot \ell}}{x} + {t}^{2}\right)}}
\] |
fma-udef [<=]10.3 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \left(\frac{\color{blue}{\mathsf{fma}\left(2, {t}^{2}, \ell \cdot \ell\right)}}{x} + {t}^{2}\right)}}
\] |
unpow2 [=>]10.3 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \left(\frac{\mathsf{fma}\left(2, \color{blue}{t \cdot t}, \ell \cdot \ell\right)}{x} + {t}^{2}\right)}}
\] |
unpow2 [=>]10.3 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \left(\frac{\mathsf{fma}\left(2, t \cdot t, \ell \cdot \ell\right)}{x} + \color{blue}{t \cdot t}\right)}}
\] |
Taylor expanded in t around 0 10.3
Simplified4.9
[Start]10.3 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \left(\frac{{\ell}^{2}}{x} + {t}^{2} \cdot \left(1 + 2 \cdot \frac{1}{x}\right)\right)}}
\] |
|---|---|
+-commutative [=>]10.3 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \color{blue}{\left({t}^{2} \cdot \left(1 + 2 \cdot \frac{1}{x}\right) + \frac{{\ell}^{2}}{x}\right)}}}
\] |
unpow2 [=>]10.3 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \left(\color{blue}{\left(t \cdot t\right)} \cdot \left(1 + 2 \cdot \frac{1}{x}\right) + \frac{{\ell}^{2}}{x}\right)}}
\] |
associate-*r/ [=>]10.3 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \left(\left(t \cdot t\right) \cdot \left(1 + \color{blue}{\frac{2 \cdot 1}{x}}\right) + \frac{{\ell}^{2}}{x}\right)}}
\] |
metadata-eval [=>]10.3 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \left(\left(t \cdot t\right) \cdot \left(1 + \frac{\color{blue}{2}}{x}\right) + \frac{{\ell}^{2}}{x}\right)}}
\] |
unpow2 [=>]10.3 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \left(\left(t \cdot t\right) \cdot \left(1 + \frac{2}{x}\right) + \frac{\color{blue}{\ell \cdot \ell}}{x}\right)}}
\] |
associate-/l* [=>]4.9 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \left(\left(t \cdot t\right) \cdot \left(1 + \frac{2}{x}\right) + \color{blue}{\frac{\ell}{\frac{x}{\ell}}}\right)}}
\] |
if -7.00000000000000002e-139 < t < 1.89999999999999996e-144Initial program 60.1
Simplified61.4
[Start]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}}
\] |
|---|---|
associate-*r/ [<=]60.1 | \[ \color{blue}{\sqrt{2} \cdot \frac{t}{\sqrt{\frac{x + 1}{x - 1} \cdot \left(\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)\right) - \ell \cdot \ell}}}
\] |
associate-*l/ [=>]58.9 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{\color{blue}{\frac{\left(x + 1\right) \cdot \left(\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)\right)}{x - 1}} - \ell \cdot \ell}}
\] |
associate-*r/ [<=]62.5 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{\color{blue}{\left(x + 1\right) \cdot \frac{\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)}{x - 1}} - \ell \cdot \ell}}
\] |
*-lft-identity [<=]62.5 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{\color{blue}{\left(1 \cdot \left(x + 1\right)\right)} \cdot \frac{\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)}{x - 1} - \ell \cdot \ell}}
\] |
associate-*r* [<=]62.5 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{\color{blue}{1 \cdot \left(\left(x + 1\right) \cdot \frac{\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)}{x - 1}\right)} - \ell \cdot \ell}}
\] |
*-commutative [<=]62.5 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{1 \cdot \color{blue}{\left(\frac{\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)}{x - 1} \cdot \left(x + 1\right)\right)} - \ell \cdot \ell}}
\] |
associate-*r* [=>]62.5 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{\color{blue}{\left(1 \cdot \frac{\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)}{x - 1}\right) \cdot \left(x + 1\right)} - \ell \cdot \ell}}
\] |
*-commutative [<=]62.5 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{\color{blue}{\left(x + 1\right) \cdot \left(1 \cdot \frac{\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)}{x - 1}\right)} - \ell \cdot \ell}}
\] |
fma-neg [=>]61.4 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{\color{blue}{\mathsf{fma}\left(x + 1, 1 \cdot \frac{\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)}{x - 1}, -\ell \cdot \ell\right)}}}
\] |
Taylor expanded in x around -inf 30.9
Simplified30.9
[Start]30.9 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \frac{{\ell}^{2} + 2 \cdot {t}^{2}}{x} + 2 \cdot {t}^{2}}}
\] |
|---|---|
distribute-lft-out [=>]30.9 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{\color{blue}{2 \cdot \left(\frac{{\ell}^{2} + 2 \cdot {t}^{2}}{x} + {t}^{2}\right)}}}
\] |
+-commutative [=>]30.9 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \left(\frac{\color{blue}{2 \cdot {t}^{2} + {\ell}^{2}}}{x} + {t}^{2}\right)}}
\] |
unpow2 [=>]30.9 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \left(\frac{2 \cdot {t}^{2} + \color{blue}{\ell \cdot \ell}}{x} + {t}^{2}\right)}}
\] |
fma-udef [<=]30.9 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \left(\frac{\color{blue}{\mathsf{fma}\left(2, {t}^{2}, \ell \cdot \ell\right)}}{x} + {t}^{2}\right)}}
\] |
unpow2 [=>]30.9 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \left(\frac{\mathsf{fma}\left(2, \color{blue}{t \cdot t}, \ell \cdot \ell\right)}{x} + {t}^{2}\right)}}
\] |
unpow2 [=>]30.9 | \[ \sqrt{2} \cdot \frac{t}{\sqrt{2 \cdot \left(\frac{\mathsf{fma}\left(2, t \cdot t, \ell \cdot \ell\right)}{x} + \color{blue}{t \cdot t}\right)}}
\] |
Applied egg-rr9.6
Simplified9.6
[Start]9.6 | \[ \frac{\frac{t}{\frac{\sqrt{2}}{\sqrt{2}}}}{\mathsf{hypot}\left(t, \sqrt{\frac{\mathsf{fma}\left(2, t \cdot t, \ell \cdot \ell\right)}{x}}\right)}
\] |
|---|---|
*-inverses [=>]9.6 | \[ \frac{\frac{t}{\color{blue}{1}}}{\mathsf{hypot}\left(t, \sqrt{\frac{\mathsf{fma}\left(2, t \cdot t, \ell \cdot \ell\right)}{x}}\right)}
\] |
if 1.99999999999999984e134 < t Initial program 56.9
Simplified56.9
[Start]56.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}}
\] |
|---|---|
associate-*l/ [<=]56.9 | \[ \color{blue}{\frac{\sqrt{2}}{\sqrt{\frac{x + 1}{x - 1} \cdot \left(\ell \cdot \ell + 2 \cdot \left(t \cdot t\right)\right) - \ell \cdot \ell}} \cdot t}
\] |
+-commutative [=>]56.9 | \[ \frac{\sqrt{2}}{\sqrt{\frac{x + 1}{x - 1} \cdot \color{blue}{\left(2 \cdot \left(t \cdot t\right) + \ell \cdot \ell\right)} - \ell \cdot \ell}} \cdot t
\] |
fma-def [=>]56.9 | \[ \frac{\sqrt{2}}{\sqrt{\frac{x + 1}{x - 1} \cdot \color{blue}{\mathsf{fma}\left(2, t \cdot t, \ell \cdot \ell\right)} - \ell \cdot \ell}} \cdot t
\] |
Taylor expanded in t around inf 2.7
Simplified2.3
[Start]2.7 | \[ \left(\frac{\sqrt{2} \cdot \sqrt{0.5}}{t} \cdot \sqrt{\frac{x - 1}{1 + x}}\right) \cdot t
\] |
|---|---|
*-commutative [=>]2.7 | \[ \color{blue}{\left(\sqrt{\frac{x - 1}{1 + x}} \cdot \frac{\sqrt{2} \cdot \sqrt{0.5}}{t}\right)} \cdot t
\] |
associate-/l* [=>]2.3 | \[ \left(\sqrt{\frac{x - 1}{1 + x}} \cdot \color{blue}{\frac{\sqrt{2}}{\frac{t}{\sqrt{0.5}}}}\right) \cdot t
\] |
associate-*r/ [=>]2.3 | \[ \color{blue}{\frac{\sqrt{\frac{x - 1}{1 + x}} \cdot \sqrt{2}}{\frac{t}{\sqrt{0.5}}}} \cdot t
\] |
sub-neg [=>]2.3 | \[ \frac{\sqrt{\frac{\color{blue}{x + \left(-1\right)}}{1 + x}} \cdot \sqrt{2}}{\frac{t}{\sqrt{0.5}}} \cdot t
\] |
metadata-eval [=>]2.3 | \[ \frac{\sqrt{\frac{x + \color{blue}{-1}}{1 + x}} \cdot \sqrt{2}}{\frac{t}{\sqrt{0.5}}} \cdot t
\] |
+-commutative [=>]2.3 | \[ \frac{\sqrt{\frac{\color{blue}{-1 + x}}{1 + x}} \cdot \sqrt{2}}{\frac{t}{\sqrt{0.5}}} \cdot t
\] |
+-commutative [=>]2.3 | \[ \frac{\sqrt{\frac{-1 + x}{\color{blue}{x + 1}}} \cdot \sqrt{2}}{\frac{t}{\sqrt{0.5}}} \cdot t
\] |
Applied egg-rr61.6
Simplified61.6
[Start]61.6 | \[ \sqrt{\frac{\left(-1 + x\right) \cdot 2}{\frac{t \cdot t}{0.5} \cdot \left(x + 1\right)}} \cdot t
\] |
|---|---|
associate-/l* [=>]61.6 | \[ \sqrt{\color{blue}{\frac{-1 + x}{\frac{\frac{t \cdot t}{0.5} \cdot \left(x + 1\right)}{2}}}} \cdot t
\] |
associate-*l/ [=>]61.6 | \[ \sqrt{\frac{-1 + x}{\frac{\color{blue}{\frac{\left(t \cdot t\right) \cdot \left(x + 1\right)}{0.5}}}{2}}} \cdot t
\] |
associate-/l/ [=>]61.6 | \[ \sqrt{\frac{-1 + x}{\color{blue}{\frac{\left(t \cdot t\right) \cdot \left(x + 1\right)}{2 \cdot 0.5}}}} \cdot t
\] |
associate-*l* [=>]61.6 | \[ \sqrt{\frac{-1 + x}{\frac{\color{blue}{t \cdot \left(t \cdot \left(x + 1\right)\right)}}{2 \cdot 0.5}}} \cdot t
\] |
metadata-eval [=>]61.6 | \[ \sqrt{\frac{-1 + x}{\frac{t \cdot \left(t \cdot \left(x + 1\right)\right)}{\color{blue}{1}}}} \cdot t
\] |
Taylor expanded in x around inf 2.1
Final simplification5.0
| Alternative 1 | |
|---|---|
| Error | 8.0 |
| Cost | 20304 |
| Alternative 2 | |
|---|---|
| Error | 9.2 |
| Cost | 14672 |
| Alternative 3 | |
|---|---|
| Error | 11.5 |
| Cost | 14288 |
| Alternative 4 | |
|---|---|
| Error | 14.5 |
| Cost | 7556 |
| Alternative 5 | |
|---|---|
| Error | 14.2 |
| Cost | 7112 |
| Alternative 6 | |
|---|---|
| Error | 14.5 |
| Cost | 7112 |
| Alternative 7 | |
|---|---|
| Error | 14.4 |
| Cost | 7112 |
| Alternative 8 | |
|---|---|
| Error | 14.5 |
| Cost | 6984 |
| Alternative 9 | |
|---|---|
| Error | 14.4 |
| Cost | 6984 |
| Alternative 10 | |
|---|---|
| Error | 14.8 |
| Cost | 836 |
| Alternative 11 | |
|---|---|
| Error | 14.8 |
| Cost | 836 |
| Alternative 12 | |
|---|---|
| Error | 15.1 |
| Cost | 452 |
| Alternative 13 | |
|---|---|
| Error | 14.9 |
| Cost | 452 |
| Alternative 14 | |
|---|---|
| Error | 15.3 |
| Cost | 196 |
| Alternative 15 | |
|---|---|
| Error | 39.5 |
| Cost | 64 |
herbie shell --seed 2023018
(FPCore (x l t)
:name "Toniolo and Linder, Equation (7)"
:precision binary64
(/ (* (sqrt 2.0) t) (sqrt (- (* (/ (+ x 1.0) (- x 1.0)) (+ (* l l) (* 2.0 (* t t)))) (* l l)))))