
(FPCore (x y) :precision binary64 (- (- 1.0 (/ 1.0 (* x 9.0))) (/ y (* 3.0 (sqrt x)))))
double code(double x, double y) {
return (1.0 - (1.0 / (x * 9.0))) - (y / (3.0 * sqrt(x)));
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = (1.0d0 - (1.0d0 / (x * 9.0d0))) - (y / (3.0d0 * sqrt(x)))
end function
public static double code(double x, double y) {
return (1.0 - (1.0 / (x * 9.0))) - (y / (3.0 * Math.sqrt(x)));
}
def code(x, y): return (1.0 - (1.0 / (x * 9.0))) - (y / (3.0 * math.sqrt(x)))
function code(x, y) return Float64(Float64(1.0 - Float64(1.0 / Float64(x * 9.0))) - Float64(y / Float64(3.0 * sqrt(x)))) end
function tmp = code(x, y) tmp = (1.0 - (1.0 / (x * 9.0))) - (y / (3.0 * sqrt(x))); end
code[x_, y_] := N[(N[(1.0 - N[(1.0 / N[(x * 9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y / N[(3.0 * N[Sqrt[x], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(1 - \frac{1}{x \cdot 9}\right) - \frac{y}{3 \cdot \sqrt{x}}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 17 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y) :precision binary64 (- (- 1.0 (/ 1.0 (* x 9.0))) (/ y (* 3.0 (sqrt x)))))
double code(double x, double y) {
return (1.0 - (1.0 / (x * 9.0))) - (y / (3.0 * sqrt(x)));
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = (1.0d0 - (1.0d0 / (x * 9.0d0))) - (y / (3.0d0 * sqrt(x)))
end function
public static double code(double x, double y) {
return (1.0 - (1.0 / (x * 9.0))) - (y / (3.0 * Math.sqrt(x)));
}
def code(x, y): return (1.0 - (1.0 / (x * 9.0))) - (y / (3.0 * math.sqrt(x)))
function code(x, y) return Float64(Float64(1.0 - Float64(1.0 / Float64(x * 9.0))) - Float64(y / Float64(3.0 * sqrt(x)))) end
function tmp = code(x, y) tmp = (1.0 - (1.0 / (x * 9.0))) - (y / (3.0 * sqrt(x))); end
code[x_, y_] := N[(N[(1.0 - N[(1.0 / N[(x * 9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y / N[(3.0 * N[Sqrt[x], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(1 - \frac{1}{x \cdot 9}\right) - \frac{y}{3 \cdot \sqrt{x}}
\end{array}
(FPCore (x y) :precision binary64 (- (+ 1.0 (/ -1.0 (* x 9.0))) (/ y (sqrt (* x 9.0)))))
double code(double x, double y) {
return (1.0 + (-1.0 / (x * 9.0))) - (y / sqrt((x * 9.0)));
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = (1.0d0 + ((-1.0d0) / (x * 9.0d0))) - (y / sqrt((x * 9.0d0)))
end function
public static double code(double x, double y) {
return (1.0 + (-1.0 / (x * 9.0))) - (y / Math.sqrt((x * 9.0)));
}
def code(x, y): return (1.0 + (-1.0 / (x * 9.0))) - (y / math.sqrt((x * 9.0)))
function code(x, y) return Float64(Float64(1.0 + Float64(-1.0 / Float64(x * 9.0))) - Float64(y / sqrt(Float64(x * 9.0)))) end
function tmp = code(x, y) tmp = (1.0 + (-1.0 / (x * 9.0))) - (y / sqrt((x * 9.0))); end
code[x_, y_] := N[(N[(1.0 + N[(-1.0 / N[(x * 9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y / N[Sqrt[N[(x * 9.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(1 + \frac{-1}{x \cdot 9}\right) - \frac{y}{\sqrt{x \cdot 9}}
\end{array}
Initial program 99.7%
*-commutative99.7%
metadata-eval99.7%
sqrt-prod99.7%
pow1/299.7%
Applied egg-rr99.7%
unpow1/299.7%
Simplified99.7%
Final simplification99.7%
(FPCore (x y)
:precision binary64
(if (<= y -2.35e+52)
(+ 1.0 (/ (* y -0.3333333333333333) (sqrt x)))
(if (<= y 2.7e+46)
(+ 1.0 (/ -0.1111111111111111 x))
(+ 1.0 (* (pow x -0.5) (* y -0.3333333333333333))))))
double code(double x, double y) {
double tmp;
if (y <= -2.35e+52) {
tmp = 1.0 + ((y * -0.3333333333333333) / sqrt(x));
} else if (y <= 2.7e+46) {
tmp = 1.0 + (-0.1111111111111111 / x);
} else {
tmp = 1.0 + (pow(x, -0.5) * (y * -0.3333333333333333));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= (-2.35d+52)) then
tmp = 1.0d0 + ((y * (-0.3333333333333333d0)) / sqrt(x))
else if (y <= 2.7d+46) then
tmp = 1.0d0 + ((-0.1111111111111111d0) / x)
else
tmp = 1.0d0 + ((x ** (-0.5d0)) * (y * (-0.3333333333333333d0)))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= -2.35e+52) {
tmp = 1.0 + ((y * -0.3333333333333333) / Math.sqrt(x));
} else if (y <= 2.7e+46) {
tmp = 1.0 + (-0.1111111111111111 / x);
} else {
tmp = 1.0 + (Math.pow(x, -0.5) * (y * -0.3333333333333333));
}
return tmp;
}
def code(x, y): tmp = 0 if y <= -2.35e+52: tmp = 1.0 + ((y * -0.3333333333333333) / math.sqrt(x)) elif y <= 2.7e+46: tmp = 1.0 + (-0.1111111111111111 / x) else: tmp = 1.0 + (math.pow(x, -0.5) * (y * -0.3333333333333333)) return tmp
function code(x, y) tmp = 0.0 if (y <= -2.35e+52) tmp = Float64(1.0 + Float64(Float64(y * -0.3333333333333333) / sqrt(x))); elseif (y <= 2.7e+46) tmp = Float64(1.0 + Float64(-0.1111111111111111 / x)); else tmp = Float64(1.0 + Float64((x ^ -0.5) * Float64(y * -0.3333333333333333))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= -2.35e+52) tmp = 1.0 + ((y * -0.3333333333333333) / sqrt(x)); elseif (y <= 2.7e+46) tmp = 1.0 + (-0.1111111111111111 / x); else tmp = 1.0 + ((x ^ -0.5) * (y * -0.3333333333333333)); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, -2.35e+52], N[(1.0 + N[(N[(y * -0.3333333333333333), $MachinePrecision] / N[Sqrt[x], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.7e+46], N[(1.0 + N[(-0.1111111111111111 / x), $MachinePrecision]), $MachinePrecision], N[(1.0 + N[(N[Power[x, -0.5], $MachinePrecision] * N[(y * -0.3333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.35 \cdot 10^{+52}:\\
\;\;\;\;1 + \frac{y \cdot -0.3333333333333333}{\sqrt{x}}\\
\mathbf{elif}\;y \leq 2.7 \cdot 10^{+46}:\\
\;\;\;\;1 + \frac{-0.1111111111111111}{x}\\
\mathbf{else}:\\
\;\;\;\;1 + {x}^{-0.5} \cdot \left(y \cdot -0.3333333333333333\right)\\
\end{array}
\end{array}
if y < -2.35e52Initial program 99.5%
sub-neg99.5%
distribute-frac-neg99.5%
+-commutative99.5%
associate-+r-99.5%
+-commutative99.5%
associate-+r-99.5%
neg-mul-199.5%
*-commutative99.5%
associate-*r/99.5%
fma-neg99.5%
associate-/r*99.3%
metadata-eval99.3%
*-commutative99.3%
associate-/r*99.3%
distribute-neg-frac99.3%
metadata-eval99.3%
metadata-eval99.3%
Simplified99.3%
Taylor expanded in y around inf 92.8%
*-commutative92.8%
associate-*l*92.8%
*-commutative92.8%
Simplified92.8%
*-commutative92.8%
sqrt-div92.6%
metadata-eval92.6%
un-div-inv92.8%
*-commutative92.8%
Applied egg-rr92.8%
if -2.35e52 < y < 2.7000000000000002e46Initial program 99.9%
sub-neg99.9%
*-commutative99.9%
associate-/r*99.8%
metadata-eval99.8%
distribute-frac-neg99.8%
neg-mul-199.8%
times-frac99.8%
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around 0 98.6%
cancel-sign-sub-inv98.6%
metadata-eval98.6%
associate-*r/98.7%
metadata-eval98.7%
+-commutative98.7%
Simplified98.7%
if 2.7000000000000002e46 < y Initial program 99.5%
sub-neg99.5%
distribute-frac-neg99.5%
+-commutative99.5%
associate-+r-99.5%
+-commutative99.5%
associate-+r-99.5%
neg-mul-199.5%
*-commutative99.5%
associate-*r/99.4%
fma-neg99.4%
associate-/r*99.4%
metadata-eval99.4%
*-commutative99.4%
associate-/r*99.4%
distribute-neg-frac99.4%
metadata-eval99.4%
metadata-eval99.4%
Simplified99.4%
Taylor expanded in y around inf 97.9%
*-commutative97.9%
associate-*l*98.0%
*-commutative98.0%
Simplified98.0%
inv-pow87.6%
sqrt-pow187.7%
metadata-eval87.7%
expm1-log1p-u85.8%
expm1-udef49.5%
Applied egg-rr57.4%
expm1-def85.8%
expm1-log1p87.7%
Simplified98.0%
Final simplification97.3%
(FPCore (x y)
:precision binary64
(if (<= y -2.4e+52)
(+ 1.0 (* -0.3333333333333333 (* y (sqrt (/ 1.0 x)))))
(if (<= y 5.6e+46)
(+ 1.0 (/ -0.1111111111111111 x))
(+ 1.0 (* (pow x -0.5) (* y -0.3333333333333333))))))
double code(double x, double y) {
double tmp;
if (y <= -2.4e+52) {
tmp = 1.0 + (-0.3333333333333333 * (y * sqrt((1.0 / x))));
} else if (y <= 5.6e+46) {
tmp = 1.0 + (-0.1111111111111111 / x);
} else {
tmp = 1.0 + (pow(x, -0.5) * (y * -0.3333333333333333));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= (-2.4d+52)) then
tmp = 1.0d0 + ((-0.3333333333333333d0) * (y * sqrt((1.0d0 / x))))
else if (y <= 5.6d+46) then
tmp = 1.0d0 + ((-0.1111111111111111d0) / x)
else
tmp = 1.0d0 + ((x ** (-0.5d0)) * (y * (-0.3333333333333333d0)))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= -2.4e+52) {
tmp = 1.0 + (-0.3333333333333333 * (y * Math.sqrt((1.0 / x))));
} else if (y <= 5.6e+46) {
tmp = 1.0 + (-0.1111111111111111 / x);
} else {
tmp = 1.0 + (Math.pow(x, -0.5) * (y * -0.3333333333333333));
}
return tmp;
}
def code(x, y): tmp = 0 if y <= -2.4e+52: tmp = 1.0 + (-0.3333333333333333 * (y * math.sqrt((1.0 / x)))) elif y <= 5.6e+46: tmp = 1.0 + (-0.1111111111111111 / x) else: tmp = 1.0 + (math.pow(x, -0.5) * (y * -0.3333333333333333)) return tmp
function code(x, y) tmp = 0.0 if (y <= -2.4e+52) tmp = Float64(1.0 + Float64(-0.3333333333333333 * Float64(y * sqrt(Float64(1.0 / x))))); elseif (y <= 5.6e+46) tmp = Float64(1.0 + Float64(-0.1111111111111111 / x)); else tmp = Float64(1.0 + Float64((x ^ -0.5) * Float64(y * -0.3333333333333333))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= -2.4e+52) tmp = 1.0 + (-0.3333333333333333 * (y * sqrt((1.0 / x)))); elseif (y <= 5.6e+46) tmp = 1.0 + (-0.1111111111111111 / x); else tmp = 1.0 + ((x ^ -0.5) * (y * -0.3333333333333333)); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, -2.4e+52], N[(1.0 + N[(-0.3333333333333333 * N[(y * N[Sqrt[N[(1.0 / x), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 5.6e+46], N[(1.0 + N[(-0.1111111111111111 / x), $MachinePrecision]), $MachinePrecision], N[(1.0 + N[(N[Power[x, -0.5], $MachinePrecision] * N[(y * -0.3333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.4 \cdot 10^{+52}:\\
\;\;\;\;1 + -0.3333333333333333 \cdot \left(y \cdot \sqrt{\frac{1}{x}}\right)\\
\mathbf{elif}\;y \leq 5.6 \cdot 10^{+46}:\\
\;\;\;\;1 + \frac{-0.1111111111111111}{x}\\
\mathbf{else}:\\
\;\;\;\;1 + {x}^{-0.5} \cdot \left(y \cdot -0.3333333333333333\right)\\
\end{array}
\end{array}
if y < -2.4e52Initial program 99.5%
sub-neg99.5%
distribute-frac-neg99.5%
+-commutative99.5%
associate-+r-99.5%
+-commutative99.5%
associate-+r-99.5%
neg-mul-199.5%
*-commutative99.5%
associate-*r/99.5%
fma-neg99.5%
associate-/r*99.3%
metadata-eval99.3%
*-commutative99.3%
associate-/r*99.3%
distribute-neg-frac99.3%
metadata-eval99.3%
metadata-eval99.3%
Simplified99.3%
Taylor expanded in y around inf 92.8%
if -2.4e52 < y < 5.60000000000000037e46Initial program 99.9%
sub-neg99.9%
*-commutative99.9%
associate-/r*99.8%
metadata-eval99.8%
distribute-frac-neg99.8%
neg-mul-199.8%
times-frac99.8%
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around 0 98.6%
cancel-sign-sub-inv98.6%
metadata-eval98.6%
associate-*r/98.7%
metadata-eval98.7%
+-commutative98.7%
Simplified98.7%
if 5.60000000000000037e46 < y Initial program 99.5%
sub-neg99.5%
distribute-frac-neg99.5%
+-commutative99.5%
associate-+r-99.5%
+-commutative99.5%
associate-+r-99.5%
neg-mul-199.5%
*-commutative99.5%
associate-*r/99.4%
fma-neg99.4%
associate-/r*99.4%
metadata-eval99.4%
*-commutative99.4%
associate-/r*99.4%
distribute-neg-frac99.4%
metadata-eval99.4%
metadata-eval99.4%
Simplified99.4%
Taylor expanded in y around inf 97.9%
*-commutative97.9%
associate-*l*98.0%
*-commutative98.0%
Simplified98.0%
inv-pow87.6%
sqrt-pow187.7%
metadata-eval87.7%
expm1-log1p-u85.8%
expm1-udef49.5%
Applied egg-rr57.4%
expm1-def85.8%
expm1-log1p87.7%
Simplified98.0%
Final simplification97.3%
(FPCore (x y)
:precision binary64
(if (<= y -9e+56)
(+ 1.0 (* y (* -0.3333333333333333 (sqrt (/ 1.0 x)))))
(if (<= y 2.1e+48)
(+ 1.0 (/ -0.1111111111111111 x))
(+ 1.0 (* (pow x -0.5) (* y -0.3333333333333333))))))
double code(double x, double y) {
double tmp;
if (y <= -9e+56) {
tmp = 1.0 + (y * (-0.3333333333333333 * sqrt((1.0 / x))));
} else if (y <= 2.1e+48) {
tmp = 1.0 + (-0.1111111111111111 / x);
} else {
tmp = 1.0 + (pow(x, -0.5) * (y * -0.3333333333333333));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= (-9d+56)) then
tmp = 1.0d0 + (y * ((-0.3333333333333333d0) * sqrt((1.0d0 / x))))
else if (y <= 2.1d+48) then
tmp = 1.0d0 + ((-0.1111111111111111d0) / x)
else
tmp = 1.0d0 + ((x ** (-0.5d0)) * (y * (-0.3333333333333333d0)))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= -9e+56) {
tmp = 1.0 + (y * (-0.3333333333333333 * Math.sqrt((1.0 / x))));
} else if (y <= 2.1e+48) {
tmp = 1.0 + (-0.1111111111111111 / x);
} else {
tmp = 1.0 + (Math.pow(x, -0.5) * (y * -0.3333333333333333));
}
return tmp;
}
def code(x, y): tmp = 0 if y <= -9e+56: tmp = 1.0 + (y * (-0.3333333333333333 * math.sqrt((1.0 / x)))) elif y <= 2.1e+48: tmp = 1.0 + (-0.1111111111111111 / x) else: tmp = 1.0 + (math.pow(x, -0.5) * (y * -0.3333333333333333)) return tmp
function code(x, y) tmp = 0.0 if (y <= -9e+56) tmp = Float64(1.0 + Float64(y * Float64(-0.3333333333333333 * sqrt(Float64(1.0 / x))))); elseif (y <= 2.1e+48) tmp = Float64(1.0 + Float64(-0.1111111111111111 / x)); else tmp = Float64(1.0 + Float64((x ^ -0.5) * Float64(y * -0.3333333333333333))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= -9e+56) tmp = 1.0 + (y * (-0.3333333333333333 * sqrt((1.0 / x)))); elseif (y <= 2.1e+48) tmp = 1.0 + (-0.1111111111111111 / x); else tmp = 1.0 + ((x ^ -0.5) * (y * -0.3333333333333333)); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, -9e+56], N[(1.0 + N[(y * N[(-0.3333333333333333 * N[Sqrt[N[(1.0 / x), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.1e+48], N[(1.0 + N[(-0.1111111111111111 / x), $MachinePrecision]), $MachinePrecision], N[(1.0 + N[(N[Power[x, -0.5], $MachinePrecision] * N[(y * -0.3333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -9 \cdot 10^{+56}:\\
\;\;\;\;1 + y \cdot \left(-0.3333333333333333 \cdot \sqrt{\frac{1}{x}}\right)\\
\mathbf{elif}\;y \leq 2.1 \cdot 10^{+48}:\\
\;\;\;\;1 + \frac{-0.1111111111111111}{x}\\
\mathbf{else}:\\
\;\;\;\;1 + {x}^{-0.5} \cdot \left(y \cdot -0.3333333333333333\right)\\
\end{array}
\end{array}
if y < -9.0000000000000006e56Initial program 99.5%
sub-neg99.5%
distribute-frac-neg99.5%
+-commutative99.5%
associate-+r-99.5%
+-commutative99.5%
associate-+r-99.5%
neg-mul-199.5%
*-commutative99.5%
associate-*r/99.5%
fma-neg99.5%
associate-/r*99.3%
metadata-eval99.3%
*-commutative99.3%
associate-/r*99.3%
distribute-neg-frac99.3%
metadata-eval99.3%
metadata-eval99.3%
Simplified99.3%
Taylor expanded in y around inf 92.8%
associate-*r*92.8%
Simplified92.8%
if -9.0000000000000006e56 < y < 2.0999999999999998e48Initial program 99.9%
sub-neg99.9%
*-commutative99.9%
associate-/r*99.8%
metadata-eval99.8%
distribute-frac-neg99.8%
neg-mul-199.8%
times-frac99.8%
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around 0 98.6%
cancel-sign-sub-inv98.6%
metadata-eval98.6%
associate-*r/98.7%
metadata-eval98.7%
+-commutative98.7%
Simplified98.7%
if 2.0999999999999998e48 < y Initial program 99.5%
sub-neg99.5%
distribute-frac-neg99.5%
+-commutative99.5%
associate-+r-99.5%
+-commutative99.5%
associate-+r-99.5%
neg-mul-199.5%
*-commutative99.5%
associate-*r/99.4%
fma-neg99.4%
associate-/r*99.4%
metadata-eval99.4%
*-commutative99.4%
associate-/r*99.4%
distribute-neg-frac99.4%
metadata-eval99.4%
metadata-eval99.4%
Simplified99.4%
Taylor expanded in y around inf 97.9%
*-commutative97.9%
associate-*l*98.0%
*-commutative98.0%
Simplified98.0%
inv-pow87.6%
sqrt-pow187.7%
metadata-eval87.7%
expm1-log1p-u85.8%
expm1-udef49.5%
Applied egg-rr57.4%
expm1-def85.8%
expm1-log1p87.7%
Simplified98.0%
Final simplification97.3%
(FPCore (x y) :precision binary64 (if (or (<= y -2e+54) (not (<= y 8.8e+46))) (+ 1.0 (* y (/ -0.3333333333333333 (sqrt x)))) (+ 1.0 (/ -0.1111111111111111 x))))
double code(double x, double y) {
double tmp;
if ((y <= -2e+54) || !(y <= 8.8e+46)) {
tmp = 1.0 + (y * (-0.3333333333333333 / sqrt(x)));
} else {
tmp = 1.0 + (-0.1111111111111111 / x);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if ((y <= (-2d+54)) .or. (.not. (y <= 8.8d+46))) then
tmp = 1.0d0 + (y * ((-0.3333333333333333d0) / sqrt(x)))
else
tmp = 1.0d0 + ((-0.1111111111111111d0) / x)
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if ((y <= -2e+54) || !(y <= 8.8e+46)) {
tmp = 1.0 + (y * (-0.3333333333333333 / Math.sqrt(x)));
} else {
tmp = 1.0 + (-0.1111111111111111 / x);
}
return tmp;
}
def code(x, y): tmp = 0 if (y <= -2e+54) or not (y <= 8.8e+46): tmp = 1.0 + (y * (-0.3333333333333333 / math.sqrt(x))) else: tmp = 1.0 + (-0.1111111111111111 / x) return tmp
function code(x, y) tmp = 0.0 if ((y <= -2e+54) || !(y <= 8.8e+46)) tmp = Float64(1.0 + Float64(y * Float64(-0.3333333333333333 / sqrt(x)))); else tmp = Float64(1.0 + Float64(-0.1111111111111111 / x)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if ((y <= -2e+54) || ~((y <= 8.8e+46))) tmp = 1.0 + (y * (-0.3333333333333333 / sqrt(x))); else tmp = 1.0 + (-0.1111111111111111 / x); end tmp_2 = tmp; end
code[x_, y_] := If[Or[LessEqual[y, -2e+54], N[Not[LessEqual[y, 8.8e+46]], $MachinePrecision]], N[(1.0 + N[(y * N[(-0.3333333333333333 / N[Sqrt[x], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1.0 + N[(-0.1111111111111111 / x), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2 \cdot 10^{+54} \lor \neg \left(y \leq 8.8 \cdot 10^{+46}\right):\\
\;\;\;\;1 + y \cdot \frac{-0.3333333333333333}{\sqrt{x}}\\
\mathbf{else}:\\
\;\;\;\;1 + \frac{-0.1111111111111111}{x}\\
\end{array}
\end{array}
if y < -2.0000000000000002e54 or 8.8000000000000001e46 < y Initial program 99.5%
sub-neg99.5%
distribute-frac-neg99.5%
+-commutative99.5%
associate-+r-99.5%
+-commutative99.5%
associate-+r-99.5%
neg-mul-199.5%
*-commutative99.5%
associate-*r/99.5%
fma-neg99.5%
associate-/r*99.4%
metadata-eval99.4%
*-commutative99.4%
associate-/r*99.3%
distribute-neg-frac99.3%
metadata-eval99.3%
metadata-eval99.3%
Simplified99.3%
Taylor expanded in y around inf 95.5%
*-commutative95.5%
associate-*l*95.5%
*-commutative95.5%
Simplified95.5%
associate-*r*86.3%
*-commutative86.3%
inv-pow86.2%
sqrt-pow186.3%
metadata-eval86.3%
expm1-log1p-u36.8%
associate-*r*36.8%
expm1-udef36.8%
Applied egg-rr45.7%
expm1-def36.8%
expm1-log1p86.2%
Simplified95.5%
if -2.0000000000000002e54 < y < 8.8000000000000001e46Initial program 99.9%
sub-neg99.9%
*-commutative99.9%
associate-/r*99.8%
metadata-eval99.8%
distribute-frac-neg99.8%
neg-mul-199.8%
times-frac99.8%
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around 0 98.6%
cancel-sign-sub-inv98.6%
metadata-eval98.6%
associate-*r/98.7%
metadata-eval98.7%
+-commutative98.7%
Simplified98.7%
Final simplification97.2%
(FPCore (x y) :precision binary64 (if (or (<= y -3.6e+53) (not (<= y 2.95e+47))) (+ 1.0 (/ (* y -0.3333333333333333) (sqrt x))) (+ 1.0 (/ -0.1111111111111111 x))))
double code(double x, double y) {
double tmp;
if ((y <= -3.6e+53) || !(y <= 2.95e+47)) {
tmp = 1.0 + ((y * -0.3333333333333333) / sqrt(x));
} else {
tmp = 1.0 + (-0.1111111111111111 / x);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if ((y <= (-3.6d+53)) .or. (.not. (y <= 2.95d+47))) then
tmp = 1.0d0 + ((y * (-0.3333333333333333d0)) / sqrt(x))
else
tmp = 1.0d0 + ((-0.1111111111111111d0) / x)
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if ((y <= -3.6e+53) || !(y <= 2.95e+47)) {
tmp = 1.0 + ((y * -0.3333333333333333) / Math.sqrt(x));
} else {
tmp = 1.0 + (-0.1111111111111111 / x);
}
return tmp;
}
def code(x, y): tmp = 0 if (y <= -3.6e+53) or not (y <= 2.95e+47): tmp = 1.0 + ((y * -0.3333333333333333) / math.sqrt(x)) else: tmp = 1.0 + (-0.1111111111111111 / x) return tmp
function code(x, y) tmp = 0.0 if ((y <= -3.6e+53) || !(y <= 2.95e+47)) tmp = Float64(1.0 + Float64(Float64(y * -0.3333333333333333) / sqrt(x))); else tmp = Float64(1.0 + Float64(-0.1111111111111111 / x)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if ((y <= -3.6e+53) || ~((y <= 2.95e+47))) tmp = 1.0 + ((y * -0.3333333333333333) / sqrt(x)); else tmp = 1.0 + (-0.1111111111111111 / x); end tmp_2 = tmp; end
code[x_, y_] := If[Or[LessEqual[y, -3.6e+53], N[Not[LessEqual[y, 2.95e+47]], $MachinePrecision]], N[(1.0 + N[(N[(y * -0.3333333333333333), $MachinePrecision] / N[Sqrt[x], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1.0 + N[(-0.1111111111111111 / x), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.6 \cdot 10^{+53} \lor \neg \left(y \leq 2.95 \cdot 10^{+47}\right):\\
\;\;\;\;1 + \frac{y \cdot -0.3333333333333333}{\sqrt{x}}\\
\mathbf{else}:\\
\;\;\;\;1 + \frac{-0.1111111111111111}{x}\\
\end{array}
\end{array}
if y < -3.6e53 or 2.95000000000000017e47 < y Initial program 99.5%
sub-neg99.5%
distribute-frac-neg99.5%
+-commutative99.5%
associate-+r-99.5%
+-commutative99.5%
associate-+r-99.5%
neg-mul-199.5%
*-commutative99.5%
associate-*r/99.5%
fma-neg99.5%
associate-/r*99.4%
metadata-eval99.4%
*-commutative99.4%
associate-/r*99.3%
distribute-neg-frac99.3%
metadata-eval99.3%
metadata-eval99.3%
Simplified99.3%
Taylor expanded in y around inf 95.5%
*-commutative95.5%
associate-*l*95.5%
*-commutative95.5%
Simplified95.5%
*-commutative95.5%
sqrt-div95.5%
metadata-eval95.5%
un-div-inv95.5%
*-commutative95.5%
Applied egg-rr95.5%
if -3.6e53 < y < 2.95000000000000017e47Initial program 99.9%
sub-neg99.9%
*-commutative99.9%
associate-/r*99.8%
metadata-eval99.8%
distribute-frac-neg99.8%
neg-mul-199.8%
times-frac99.8%
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around 0 98.6%
cancel-sign-sub-inv98.6%
metadata-eval98.6%
associate-*r/98.7%
metadata-eval98.7%
+-commutative98.7%
Simplified98.7%
Final simplification97.2%
(FPCore (x y) :precision binary64 (if (or (<= y -3e+82) (not (<= y 1.06e+51))) (* y (* -0.3333333333333333 (pow x -0.5))) (+ 1.0 (/ -0.1111111111111111 x))))
double code(double x, double y) {
double tmp;
if ((y <= -3e+82) || !(y <= 1.06e+51)) {
tmp = y * (-0.3333333333333333 * pow(x, -0.5));
} else {
tmp = 1.0 + (-0.1111111111111111 / x);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if ((y <= (-3d+82)) .or. (.not. (y <= 1.06d+51))) then
tmp = y * ((-0.3333333333333333d0) * (x ** (-0.5d0)))
else
tmp = 1.0d0 + ((-0.1111111111111111d0) / x)
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if ((y <= -3e+82) || !(y <= 1.06e+51)) {
tmp = y * (-0.3333333333333333 * Math.pow(x, -0.5));
} else {
tmp = 1.0 + (-0.1111111111111111 / x);
}
return tmp;
}
def code(x, y): tmp = 0 if (y <= -3e+82) or not (y <= 1.06e+51): tmp = y * (-0.3333333333333333 * math.pow(x, -0.5)) else: tmp = 1.0 + (-0.1111111111111111 / x) return tmp
function code(x, y) tmp = 0.0 if ((y <= -3e+82) || !(y <= 1.06e+51)) tmp = Float64(y * Float64(-0.3333333333333333 * (x ^ -0.5))); else tmp = Float64(1.0 + Float64(-0.1111111111111111 / x)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if ((y <= -3e+82) || ~((y <= 1.06e+51))) tmp = y * (-0.3333333333333333 * (x ^ -0.5)); else tmp = 1.0 + (-0.1111111111111111 / x); end tmp_2 = tmp; end
code[x_, y_] := If[Or[LessEqual[y, -3e+82], N[Not[LessEqual[y, 1.06e+51]], $MachinePrecision]], N[(y * N[(-0.3333333333333333 * N[Power[x, -0.5], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1.0 + N[(-0.1111111111111111 / x), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3 \cdot 10^{+82} \lor \neg \left(y \leq 1.06 \cdot 10^{+51}\right):\\
\;\;\;\;y \cdot \left(-0.3333333333333333 \cdot {x}^{-0.5}\right)\\
\mathbf{else}:\\
\;\;\;\;1 + \frac{-0.1111111111111111}{x}\\
\end{array}
\end{array}
if y < -2.99999999999999989e82 or 1.06000000000000004e51 < y Initial program 99.5%
*-commutative99.5%
metadata-eval99.5%
sqrt-prod99.6%
pow1/299.6%
Applied egg-rr99.6%
unpow1/299.6%
Simplified99.6%
Taylor expanded in y around inf 90.5%
associate-*r*90.5%
*-commutative90.5%
rem-exp-log85.7%
exp-neg85.7%
unpow1/285.7%
exp-prod85.7%
distribute-lft-neg-out85.7%
distribute-rgt-neg-in85.7%
metadata-eval85.7%
exp-to-pow90.6%
Simplified90.6%
if -2.99999999999999989e82 < y < 1.06000000000000004e51Initial program 99.9%
sub-neg99.9%
*-commutative99.9%
associate-/r*99.8%
metadata-eval99.8%
distribute-frac-neg99.8%
neg-mul-199.8%
times-frac99.8%
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around 0 98.0%
cancel-sign-sub-inv98.0%
metadata-eval98.0%
associate-*r/98.0%
metadata-eval98.0%
+-commutative98.0%
Simplified98.0%
Final simplification94.8%
(FPCore (x y)
:precision binary64
(if (<= y -3e+82)
(* y (* -0.3333333333333333 (pow x -0.5)))
(if (<= y 8.2e+50)
(+ 1.0 (/ -0.1111111111111111 x))
(* (pow x -0.5) (* y -0.3333333333333333)))))
double code(double x, double y) {
double tmp;
if (y <= -3e+82) {
tmp = y * (-0.3333333333333333 * pow(x, -0.5));
} else if (y <= 8.2e+50) {
tmp = 1.0 + (-0.1111111111111111 / x);
} else {
tmp = pow(x, -0.5) * (y * -0.3333333333333333);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= (-3d+82)) then
tmp = y * ((-0.3333333333333333d0) * (x ** (-0.5d0)))
else if (y <= 8.2d+50) then
tmp = 1.0d0 + ((-0.1111111111111111d0) / x)
else
tmp = (x ** (-0.5d0)) * (y * (-0.3333333333333333d0))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= -3e+82) {
tmp = y * (-0.3333333333333333 * Math.pow(x, -0.5));
} else if (y <= 8.2e+50) {
tmp = 1.0 + (-0.1111111111111111 / x);
} else {
tmp = Math.pow(x, -0.5) * (y * -0.3333333333333333);
}
return tmp;
}
def code(x, y): tmp = 0 if y <= -3e+82: tmp = y * (-0.3333333333333333 * math.pow(x, -0.5)) elif y <= 8.2e+50: tmp = 1.0 + (-0.1111111111111111 / x) else: tmp = math.pow(x, -0.5) * (y * -0.3333333333333333) return tmp
function code(x, y) tmp = 0.0 if (y <= -3e+82) tmp = Float64(y * Float64(-0.3333333333333333 * (x ^ -0.5))); elseif (y <= 8.2e+50) tmp = Float64(1.0 + Float64(-0.1111111111111111 / x)); else tmp = Float64((x ^ -0.5) * Float64(y * -0.3333333333333333)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= -3e+82) tmp = y * (-0.3333333333333333 * (x ^ -0.5)); elseif (y <= 8.2e+50) tmp = 1.0 + (-0.1111111111111111 / x); else tmp = (x ^ -0.5) * (y * -0.3333333333333333); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, -3e+82], N[(y * N[(-0.3333333333333333 * N[Power[x, -0.5], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 8.2e+50], N[(1.0 + N[(-0.1111111111111111 / x), $MachinePrecision]), $MachinePrecision], N[(N[Power[x, -0.5], $MachinePrecision] * N[(y * -0.3333333333333333), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3 \cdot 10^{+82}:\\
\;\;\;\;y \cdot \left(-0.3333333333333333 \cdot {x}^{-0.5}\right)\\
\mathbf{elif}\;y \leq 8.2 \cdot 10^{+50}:\\
\;\;\;\;1 + \frac{-0.1111111111111111}{x}\\
\mathbf{else}:\\
\;\;\;\;{x}^{-0.5} \cdot \left(y \cdot -0.3333333333333333\right)\\
\end{array}
\end{array}
if y < -2.99999999999999989e82Initial program 99.5%
*-commutative99.5%
metadata-eval99.5%
sqrt-prod99.7%
pow1/299.7%
Applied egg-rr99.7%
unpow1/299.7%
Simplified99.7%
Taylor expanded in y around inf 92.3%
associate-*r*92.3%
*-commutative92.3%
rem-exp-log86.9%
exp-neg86.9%
unpow1/286.9%
exp-prod86.9%
distribute-lft-neg-out86.9%
distribute-rgt-neg-in86.9%
metadata-eval86.9%
exp-to-pow92.3%
Simplified92.3%
if -2.99999999999999989e82 < y < 8.2000000000000002e50Initial program 99.9%
sub-neg99.9%
*-commutative99.9%
associate-/r*99.8%
metadata-eval99.8%
distribute-frac-neg99.8%
neg-mul-199.8%
times-frac99.8%
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around 0 98.0%
cancel-sign-sub-inv98.0%
metadata-eval98.0%
associate-*r/98.0%
metadata-eval98.0%
+-commutative98.0%
Simplified98.0%
if 8.2000000000000002e50 < y Initial program 99.5%
*-commutative99.5%
metadata-eval99.5%
sqrt-prod99.5%
pow1/299.5%
Applied egg-rr99.5%
unpow1/299.5%
Simplified99.5%
Taylor expanded in x around 0 99.5%
Taylor expanded in y around inf 88.9%
*-commutative88.9%
associate-*l*89.0%
*-commutative89.0%
Simplified89.0%
inv-pow89.0%
sqrt-pow189.1%
metadata-eval89.1%
expm1-log1p-u87.2%
expm1-udef50.3%
Applied egg-rr50.3%
expm1-def87.2%
expm1-log1p89.1%
Simplified89.1%
Final simplification94.8%
(FPCore (x y)
:precision binary64
(if (<= y -2.85e+82)
(* -0.3333333333333333 (* y (sqrt (/ 1.0 x))))
(if (<= y 1.06e+51)
(+ 1.0 (/ -0.1111111111111111 x))
(* (pow x -0.5) (* y -0.3333333333333333)))))
double code(double x, double y) {
double tmp;
if (y <= -2.85e+82) {
tmp = -0.3333333333333333 * (y * sqrt((1.0 / x)));
} else if (y <= 1.06e+51) {
tmp = 1.0 + (-0.1111111111111111 / x);
} else {
tmp = pow(x, -0.5) * (y * -0.3333333333333333);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= (-2.85d+82)) then
tmp = (-0.3333333333333333d0) * (y * sqrt((1.0d0 / x)))
else if (y <= 1.06d+51) then
tmp = 1.0d0 + ((-0.1111111111111111d0) / x)
else
tmp = (x ** (-0.5d0)) * (y * (-0.3333333333333333d0))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= -2.85e+82) {
tmp = -0.3333333333333333 * (y * Math.sqrt((1.0 / x)));
} else if (y <= 1.06e+51) {
tmp = 1.0 + (-0.1111111111111111 / x);
} else {
tmp = Math.pow(x, -0.5) * (y * -0.3333333333333333);
}
return tmp;
}
def code(x, y): tmp = 0 if y <= -2.85e+82: tmp = -0.3333333333333333 * (y * math.sqrt((1.0 / x))) elif y <= 1.06e+51: tmp = 1.0 + (-0.1111111111111111 / x) else: tmp = math.pow(x, -0.5) * (y * -0.3333333333333333) return tmp
function code(x, y) tmp = 0.0 if (y <= -2.85e+82) tmp = Float64(-0.3333333333333333 * Float64(y * sqrt(Float64(1.0 / x)))); elseif (y <= 1.06e+51) tmp = Float64(1.0 + Float64(-0.1111111111111111 / x)); else tmp = Float64((x ^ -0.5) * Float64(y * -0.3333333333333333)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= -2.85e+82) tmp = -0.3333333333333333 * (y * sqrt((1.0 / x))); elseif (y <= 1.06e+51) tmp = 1.0 + (-0.1111111111111111 / x); else tmp = (x ^ -0.5) * (y * -0.3333333333333333); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, -2.85e+82], N[(-0.3333333333333333 * N[(y * N[Sqrt[N[(1.0 / x), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.06e+51], N[(1.0 + N[(-0.1111111111111111 / x), $MachinePrecision]), $MachinePrecision], N[(N[Power[x, -0.5], $MachinePrecision] * N[(y * -0.3333333333333333), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.85 \cdot 10^{+82}:\\
\;\;\;\;-0.3333333333333333 \cdot \left(y \cdot \sqrt{\frac{1}{x}}\right)\\
\mathbf{elif}\;y \leq 1.06 \cdot 10^{+51}:\\
\;\;\;\;1 + \frac{-0.1111111111111111}{x}\\
\mathbf{else}:\\
\;\;\;\;{x}^{-0.5} \cdot \left(y \cdot -0.3333333333333333\right)\\
\end{array}
\end{array}
if y < -2.85000000000000008e82Initial program 99.5%
*-commutative99.5%
metadata-eval99.5%
sqrt-prod99.7%
pow1/299.7%
Applied egg-rr99.7%
unpow1/299.7%
Simplified99.7%
Taylor expanded in y around inf 92.3%
if -2.85000000000000008e82 < y < 1.06000000000000004e51Initial program 99.9%
sub-neg99.9%
*-commutative99.9%
associate-/r*99.8%
metadata-eval99.8%
distribute-frac-neg99.8%
neg-mul-199.8%
times-frac99.8%
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around 0 98.0%
cancel-sign-sub-inv98.0%
metadata-eval98.0%
associate-*r/98.0%
metadata-eval98.0%
+-commutative98.0%
Simplified98.0%
if 1.06000000000000004e51 < y Initial program 99.5%
*-commutative99.5%
metadata-eval99.5%
sqrt-prod99.5%
pow1/299.5%
Applied egg-rr99.5%
unpow1/299.5%
Simplified99.5%
Taylor expanded in x around 0 99.5%
Taylor expanded in y around inf 88.9%
*-commutative88.9%
associate-*l*89.0%
*-commutative89.0%
Simplified89.0%
inv-pow89.0%
sqrt-pow189.1%
metadata-eval89.1%
expm1-log1p-u87.2%
expm1-udef50.3%
Applied egg-rr50.3%
expm1-def87.2%
expm1-log1p89.1%
Simplified89.1%
Final simplification94.8%
(FPCore (x y) :precision binary64 (if (or (<= y -1.05e+84) (not (<= y 3.1e+50))) (* -0.3333333333333333 (/ y (sqrt x))) (+ 1.0 (/ -0.1111111111111111 x))))
double code(double x, double y) {
double tmp;
if ((y <= -1.05e+84) || !(y <= 3.1e+50)) {
tmp = -0.3333333333333333 * (y / sqrt(x));
} else {
tmp = 1.0 + (-0.1111111111111111 / x);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if ((y <= (-1.05d+84)) .or. (.not. (y <= 3.1d+50))) then
tmp = (-0.3333333333333333d0) * (y / sqrt(x))
else
tmp = 1.0d0 + ((-0.1111111111111111d0) / x)
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if ((y <= -1.05e+84) || !(y <= 3.1e+50)) {
tmp = -0.3333333333333333 * (y / Math.sqrt(x));
} else {
tmp = 1.0 + (-0.1111111111111111 / x);
}
return tmp;
}
def code(x, y): tmp = 0 if (y <= -1.05e+84) or not (y <= 3.1e+50): tmp = -0.3333333333333333 * (y / math.sqrt(x)) else: tmp = 1.0 + (-0.1111111111111111 / x) return tmp
function code(x, y) tmp = 0.0 if ((y <= -1.05e+84) || !(y <= 3.1e+50)) tmp = Float64(-0.3333333333333333 * Float64(y / sqrt(x))); else tmp = Float64(1.0 + Float64(-0.1111111111111111 / x)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if ((y <= -1.05e+84) || ~((y <= 3.1e+50))) tmp = -0.3333333333333333 * (y / sqrt(x)); else tmp = 1.0 + (-0.1111111111111111 / x); end tmp_2 = tmp; end
code[x_, y_] := If[Or[LessEqual[y, -1.05e+84], N[Not[LessEqual[y, 3.1e+50]], $MachinePrecision]], N[(-0.3333333333333333 * N[(y / N[Sqrt[x], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1.0 + N[(-0.1111111111111111 / x), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.05 \cdot 10^{+84} \lor \neg \left(y \leq 3.1 \cdot 10^{+50}\right):\\
\;\;\;\;-0.3333333333333333 \cdot \frac{y}{\sqrt{x}}\\
\mathbf{else}:\\
\;\;\;\;1 + \frac{-0.1111111111111111}{x}\\
\end{array}
\end{array}
if y < -1.05000000000000009e84 or 3.10000000000000003e50 < y Initial program 99.5%
*-commutative99.5%
metadata-eval99.5%
sqrt-prod99.6%
pow1/299.6%
Applied egg-rr99.6%
unpow1/299.6%
Simplified99.6%
Taylor expanded in y around inf 90.5%
*-commutative90.5%
associate-*r*90.5%
inv-pow90.5%
sqrt-pow190.5%
metadata-eval90.5%
expm1-log1p-u38.4%
*-commutative38.4%
expm1-udef38.5%
associate-*r*38.5%
*-commutative38.5%
metadata-eval38.5%
sqrt-pow138.5%
inv-pow38.5%
*-commutative38.5%
sqrt-div38.5%
metadata-eval38.5%
un-div-inv38.5%
Applied egg-rr38.5%
expm1-def38.4%
expm1-log1p90.5%
associate-*r/90.5%
associate-*l/90.4%
*-commutative90.4%
Simplified90.4%
if -1.05000000000000009e84 < y < 3.10000000000000003e50Initial program 99.9%
sub-neg99.9%
*-commutative99.9%
associate-/r*99.8%
metadata-eval99.8%
distribute-frac-neg99.8%
neg-mul-199.8%
times-frac99.8%
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around 0 98.0%
cancel-sign-sub-inv98.0%
metadata-eval98.0%
associate-*r/98.0%
metadata-eval98.0%
+-commutative98.0%
Simplified98.0%
Final simplification94.7%
(FPCore (x y) :precision binary64 (if (or (<= y -3.8e+82) (not (<= y 1.06e+51))) (* y (/ -0.3333333333333333 (sqrt x))) (+ 1.0 (/ -0.1111111111111111 x))))
double code(double x, double y) {
double tmp;
if ((y <= -3.8e+82) || !(y <= 1.06e+51)) {
tmp = y * (-0.3333333333333333 / sqrt(x));
} else {
tmp = 1.0 + (-0.1111111111111111 / x);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if ((y <= (-3.8d+82)) .or. (.not. (y <= 1.06d+51))) then
tmp = y * ((-0.3333333333333333d0) / sqrt(x))
else
tmp = 1.0d0 + ((-0.1111111111111111d0) / x)
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if ((y <= -3.8e+82) || !(y <= 1.06e+51)) {
tmp = y * (-0.3333333333333333 / Math.sqrt(x));
} else {
tmp = 1.0 + (-0.1111111111111111 / x);
}
return tmp;
}
def code(x, y): tmp = 0 if (y <= -3.8e+82) or not (y <= 1.06e+51): tmp = y * (-0.3333333333333333 / math.sqrt(x)) else: tmp = 1.0 + (-0.1111111111111111 / x) return tmp
function code(x, y) tmp = 0.0 if ((y <= -3.8e+82) || !(y <= 1.06e+51)) tmp = Float64(y * Float64(-0.3333333333333333 / sqrt(x))); else tmp = Float64(1.0 + Float64(-0.1111111111111111 / x)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if ((y <= -3.8e+82) || ~((y <= 1.06e+51))) tmp = y * (-0.3333333333333333 / sqrt(x)); else tmp = 1.0 + (-0.1111111111111111 / x); end tmp_2 = tmp; end
code[x_, y_] := If[Or[LessEqual[y, -3.8e+82], N[Not[LessEqual[y, 1.06e+51]], $MachinePrecision]], N[(y * N[(-0.3333333333333333 / N[Sqrt[x], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1.0 + N[(-0.1111111111111111 / x), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.8 \cdot 10^{+82} \lor \neg \left(y \leq 1.06 \cdot 10^{+51}\right):\\
\;\;\;\;y \cdot \frac{-0.3333333333333333}{\sqrt{x}}\\
\mathbf{else}:\\
\;\;\;\;1 + \frac{-0.1111111111111111}{x}\\
\end{array}
\end{array}
if y < -3.80000000000000033e82 or 1.06000000000000004e51 < y Initial program 99.5%
*-commutative99.5%
metadata-eval99.5%
sqrt-prod99.6%
pow1/299.6%
Applied egg-rr99.6%
unpow1/299.6%
Simplified99.6%
Taylor expanded in x around 0 99.6%
Taylor expanded in y around inf 90.5%
*-commutative90.5%
associate-*l*90.5%
*-commutative90.5%
Simplified90.5%
associate-*r*90.5%
*-commutative90.5%
inv-pow90.5%
sqrt-pow190.6%
metadata-eval90.6%
expm1-log1p-u38.4%
associate-*r*38.4%
expm1-udef38.5%
Applied egg-rr38.5%
expm1-def38.4%
expm1-log1p90.5%
Simplified90.5%
if -3.80000000000000033e82 < y < 1.06000000000000004e51Initial program 99.9%
sub-neg99.9%
*-commutative99.9%
associate-/r*99.8%
metadata-eval99.8%
distribute-frac-neg99.8%
neg-mul-199.8%
times-frac99.8%
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around 0 98.0%
cancel-sign-sub-inv98.0%
metadata-eval98.0%
associate-*r/98.0%
metadata-eval98.0%
+-commutative98.0%
Simplified98.0%
Final simplification94.7%
(FPCore (x y) :precision binary64 (if (or (<= y -3.8e+83) (not (<= y 7.5e+50))) (/ (* y -0.3333333333333333) (sqrt x)) (+ 1.0 (/ -0.1111111111111111 x))))
double code(double x, double y) {
double tmp;
if ((y <= -3.8e+83) || !(y <= 7.5e+50)) {
tmp = (y * -0.3333333333333333) / sqrt(x);
} else {
tmp = 1.0 + (-0.1111111111111111 / x);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if ((y <= (-3.8d+83)) .or. (.not. (y <= 7.5d+50))) then
tmp = (y * (-0.3333333333333333d0)) / sqrt(x)
else
tmp = 1.0d0 + ((-0.1111111111111111d0) / x)
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if ((y <= -3.8e+83) || !(y <= 7.5e+50)) {
tmp = (y * -0.3333333333333333) / Math.sqrt(x);
} else {
tmp = 1.0 + (-0.1111111111111111 / x);
}
return tmp;
}
def code(x, y): tmp = 0 if (y <= -3.8e+83) or not (y <= 7.5e+50): tmp = (y * -0.3333333333333333) / math.sqrt(x) else: tmp = 1.0 + (-0.1111111111111111 / x) return tmp
function code(x, y) tmp = 0.0 if ((y <= -3.8e+83) || !(y <= 7.5e+50)) tmp = Float64(Float64(y * -0.3333333333333333) / sqrt(x)); else tmp = Float64(1.0 + Float64(-0.1111111111111111 / x)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if ((y <= -3.8e+83) || ~((y <= 7.5e+50))) tmp = (y * -0.3333333333333333) / sqrt(x); else tmp = 1.0 + (-0.1111111111111111 / x); end tmp_2 = tmp; end
code[x_, y_] := If[Or[LessEqual[y, -3.8e+83], N[Not[LessEqual[y, 7.5e+50]], $MachinePrecision]], N[(N[(y * -0.3333333333333333), $MachinePrecision] / N[Sqrt[x], $MachinePrecision]), $MachinePrecision], N[(1.0 + N[(-0.1111111111111111 / x), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.8 \cdot 10^{+83} \lor \neg \left(y \leq 7.5 \cdot 10^{+50}\right):\\
\;\;\;\;\frac{y \cdot -0.3333333333333333}{\sqrt{x}}\\
\mathbf{else}:\\
\;\;\;\;1 + \frac{-0.1111111111111111}{x}\\
\end{array}
\end{array}
if y < -3.8000000000000002e83 or 7.4999999999999999e50 < y Initial program 99.5%
*-commutative99.5%
metadata-eval99.5%
sqrt-prod99.6%
pow1/299.6%
Applied egg-rr99.6%
unpow1/299.6%
Simplified99.6%
Taylor expanded in y around inf 90.5%
*-commutative90.5%
associate-*r*90.5%
inv-pow90.5%
sqrt-pow190.5%
metadata-eval90.5%
expm1-log1p-u38.4%
*-commutative38.4%
expm1-udef38.5%
associate-*r*38.5%
*-commutative38.5%
metadata-eval38.5%
sqrt-pow138.5%
inv-pow38.5%
*-commutative38.5%
sqrt-div38.5%
metadata-eval38.5%
un-div-inv38.5%
Applied egg-rr38.5%
expm1-def38.4%
expm1-log1p90.5%
associate-*r/90.5%
*-commutative90.5%
Simplified90.5%
if -3.8000000000000002e83 < y < 7.4999999999999999e50Initial program 99.9%
sub-neg99.9%
*-commutative99.9%
associate-/r*99.8%
metadata-eval99.8%
distribute-frac-neg99.8%
neg-mul-199.8%
times-frac99.8%
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around 0 98.0%
cancel-sign-sub-inv98.0%
metadata-eval98.0%
associate-*r/98.0%
metadata-eval98.0%
+-commutative98.0%
Simplified98.0%
Final simplification94.7%
(FPCore (x y) :precision binary64 (+ 1.0 (- (/ -0.1111111111111111 x) (* y (sqrt (/ 0.1111111111111111 x))))))
double code(double x, double y) {
return 1.0 + ((-0.1111111111111111 / x) - (y * sqrt((0.1111111111111111 / x))));
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = 1.0d0 + (((-0.1111111111111111d0) / x) - (y * sqrt((0.1111111111111111d0 / x))))
end function
public static double code(double x, double y) {
return 1.0 + ((-0.1111111111111111 / x) - (y * Math.sqrt((0.1111111111111111 / x))));
}
def code(x, y): return 1.0 + ((-0.1111111111111111 / x) - (y * math.sqrt((0.1111111111111111 / x))))
function code(x, y) return Float64(1.0 + Float64(Float64(-0.1111111111111111 / x) - Float64(y * sqrt(Float64(0.1111111111111111 / x))))) end
function tmp = code(x, y) tmp = 1.0 + ((-0.1111111111111111 / x) - (y * sqrt((0.1111111111111111 / x)))); end
code[x_, y_] := N[(1.0 + N[(N[(-0.1111111111111111 / x), $MachinePrecision] - N[(y * N[Sqrt[N[(0.1111111111111111 / x), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
1 + \left(\frac{-0.1111111111111111}{x} - y \cdot \sqrt{\frac{0.1111111111111111}{x}}\right)
\end{array}
Initial program 99.7%
*-commutative99.7%
metadata-eval99.7%
sqrt-prod99.7%
pow1/299.7%
Applied egg-rr99.7%
unpow1/299.7%
Simplified99.7%
sub-neg99.7%
associate--l+99.7%
*-commutative99.7%
associate-/r*99.7%
metadata-eval99.7%
distribute-neg-frac99.7%
metadata-eval99.7%
div-inv99.6%
metadata-eval99.6%
sqrt-div99.7%
inv-pow99.7%
*-commutative99.7%
unpow-prod-down99.7%
metadata-eval99.7%
inv-pow99.7%
div-inv99.7%
Applied egg-rr99.7%
Final simplification99.7%
(FPCore (x y) :precision binary64 (- (- 1.0 (/ 0.1111111111111111 x)) (/ y (sqrt (* x 9.0)))))
double code(double x, double y) {
return (1.0 - (0.1111111111111111 / x)) - (y / sqrt((x * 9.0)));
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = (1.0d0 - (0.1111111111111111d0 / x)) - (y / sqrt((x * 9.0d0)))
end function
public static double code(double x, double y) {
return (1.0 - (0.1111111111111111 / x)) - (y / Math.sqrt((x * 9.0)));
}
def code(x, y): return (1.0 - (0.1111111111111111 / x)) - (y / math.sqrt((x * 9.0)))
function code(x, y) return Float64(Float64(1.0 - Float64(0.1111111111111111 / x)) - Float64(y / sqrt(Float64(x * 9.0)))) end
function tmp = code(x, y) tmp = (1.0 - (0.1111111111111111 / x)) - (y / sqrt((x * 9.0))); end
code[x_, y_] := N[(N[(1.0 - N[(0.1111111111111111 / x), $MachinePrecision]), $MachinePrecision] - N[(y / N[Sqrt[N[(x * 9.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(1 - \frac{0.1111111111111111}{x}\right) - \frac{y}{\sqrt{x \cdot 9}}
\end{array}
Initial program 99.7%
*-commutative99.7%
metadata-eval99.7%
sqrt-prod99.7%
pow1/299.7%
Applied egg-rr99.7%
unpow1/299.7%
Simplified99.7%
Taylor expanded in x around 0 99.7%
Final simplification99.7%
(FPCore (x y) :precision binary64 (if (<= x 0.11) (/ -0.1111111111111111 x) 1.0))
double code(double x, double y) {
double tmp;
if (x <= 0.11) {
tmp = -0.1111111111111111 / x;
} else {
tmp = 1.0;
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 0.11d0) then
tmp = (-0.1111111111111111d0) / x
else
tmp = 1.0d0
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 0.11) {
tmp = -0.1111111111111111 / x;
} else {
tmp = 1.0;
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 0.11: tmp = -0.1111111111111111 / x else: tmp = 1.0 return tmp
function code(x, y) tmp = 0.0 if (x <= 0.11) tmp = Float64(-0.1111111111111111 / x); else tmp = 1.0; end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 0.11) tmp = -0.1111111111111111 / x; else tmp = 1.0; end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 0.11], N[(-0.1111111111111111 / x), $MachinePrecision], 1.0]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 0.11:\\
\;\;\;\;\frac{-0.1111111111111111}{x}\\
\mathbf{else}:\\
\;\;\;\;1\\
\end{array}
\end{array}
if x < 0.110000000000000001Initial program 99.6%
*-commutative99.6%
metadata-eval99.6%
sqrt-prod99.6%
pow1/299.6%
Applied egg-rr99.6%
unpow1/299.6%
Simplified99.6%
Taylor expanded in x around 0 58.3%
if 0.110000000000000001 < x Initial program 99.8%
sub-neg99.8%
*-commutative99.8%
associate-/r*99.8%
metadata-eval99.8%
distribute-frac-neg99.8%
neg-mul-199.8%
times-frac99.7%
metadata-eval99.7%
Simplified99.7%
Taylor expanded in x around inf 59.2%
Final simplification58.8%
(FPCore (x y) :precision binary64 (+ 1.0 (/ -0.1111111111111111 x)))
double code(double x, double y) {
return 1.0 + (-0.1111111111111111 / x);
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = 1.0d0 + ((-0.1111111111111111d0) / x)
end function
public static double code(double x, double y) {
return 1.0 + (-0.1111111111111111 / x);
}
def code(x, y): return 1.0 + (-0.1111111111111111 / x)
function code(x, y) return Float64(1.0 + Float64(-0.1111111111111111 / x)) end
function tmp = code(x, y) tmp = 1.0 + (-0.1111111111111111 / x); end
code[x_, y_] := N[(1.0 + N[(-0.1111111111111111 / x), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
1 + \frac{-0.1111111111111111}{x}
\end{array}
Initial program 99.7%
sub-neg99.7%
*-commutative99.7%
associate-/r*99.7%
metadata-eval99.7%
distribute-frac-neg99.7%
neg-mul-199.7%
times-frac99.6%
metadata-eval99.6%
Simplified99.6%
Taylor expanded in y around 0 60.0%
cancel-sign-sub-inv60.0%
metadata-eval60.0%
associate-*r/60.0%
metadata-eval60.0%
+-commutative60.0%
Simplified60.0%
Final simplification60.0%
(FPCore (x y) :precision binary64 1.0)
double code(double x, double y) {
return 1.0;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = 1.0d0
end function
public static double code(double x, double y) {
return 1.0;
}
def code(x, y): return 1.0
function code(x, y) return 1.0 end
function tmp = code(x, y) tmp = 1.0; end
code[x_, y_] := 1.0
\begin{array}{l}
\\
1
\end{array}
Initial program 99.7%
sub-neg99.7%
*-commutative99.7%
associate-/r*99.7%
metadata-eval99.7%
distribute-frac-neg99.7%
neg-mul-199.7%
times-frac99.6%
metadata-eval99.6%
Simplified99.6%
Taylor expanded in x around inf 34.1%
Final simplification34.1%
(FPCore (x y) :precision binary64 (- (- 1.0 (/ (/ 1.0 x) 9.0)) (/ y (* 3.0 (sqrt x)))))
double code(double x, double y) {
return (1.0 - ((1.0 / x) / 9.0)) - (y / (3.0 * sqrt(x)));
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = (1.0d0 - ((1.0d0 / x) / 9.0d0)) - (y / (3.0d0 * sqrt(x)))
end function
public static double code(double x, double y) {
return (1.0 - ((1.0 / x) / 9.0)) - (y / (3.0 * Math.sqrt(x)));
}
def code(x, y): return (1.0 - ((1.0 / x) / 9.0)) - (y / (3.0 * math.sqrt(x)))
function code(x, y) return Float64(Float64(1.0 - Float64(Float64(1.0 / x) / 9.0)) - Float64(y / Float64(3.0 * sqrt(x)))) end
function tmp = code(x, y) tmp = (1.0 - ((1.0 / x) / 9.0)) - (y / (3.0 * sqrt(x))); end
code[x_, y_] := N[(N[(1.0 - N[(N[(1.0 / x), $MachinePrecision] / 9.0), $MachinePrecision]), $MachinePrecision] - N[(y / N[(3.0 * N[Sqrt[x], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(1 - \frac{\frac{1}{x}}{9}\right) - \frac{y}{3 \cdot \sqrt{x}}
\end{array}
herbie shell --seed 2024027
(FPCore (x y)
:name "Numeric.SpecFunctions:invIncompleteGamma from math-functions-0.1.5.2, D"
:precision binary64
:herbie-target
(- (- 1.0 (/ (/ 1.0 x) 9.0)) (/ y (* 3.0 (sqrt x))))
(- (- 1.0 (/ 1.0 (* x 9.0))) (/ y (* 3.0 (sqrt x)))))