
(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 16 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 (* 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}
Initial program 99.7%
Final simplification99.7%
(FPCore (x y)
:precision binary64
(if (<= y -1.8e+45)
(- 1.0 (/ (/ y 3.0) (sqrt x)))
(if (<= y 7.8e+99)
(+ 1.0 (/ -1.0 (* x 9.0)))
(- 1.0 (* (/ y 3.0) (pow x -0.5))))))
double code(double x, double y) {
double tmp;
if (y <= -1.8e+45) {
tmp = 1.0 - ((y / 3.0) / sqrt(x));
} else if (y <= 7.8e+99) {
tmp = 1.0 + (-1.0 / (x * 9.0));
} else {
tmp = 1.0 - ((y / 3.0) * pow(x, -0.5));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= (-1.8d+45)) then
tmp = 1.0d0 - ((y / 3.0d0) / sqrt(x))
else if (y <= 7.8d+99) then
tmp = 1.0d0 + ((-1.0d0) / (x * 9.0d0))
else
tmp = 1.0d0 - ((y / 3.0d0) * (x ** (-0.5d0)))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= -1.8e+45) {
tmp = 1.0 - ((y / 3.0) / Math.sqrt(x));
} else if (y <= 7.8e+99) {
tmp = 1.0 + (-1.0 / (x * 9.0));
} else {
tmp = 1.0 - ((y / 3.0) * Math.pow(x, -0.5));
}
return tmp;
}
def code(x, y): tmp = 0 if y <= -1.8e+45: tmp = 1.0 - ((y / 3.0) / math.sqrt(x)) elif y <= 7.8e+99: tmp = 1.0 + (-1.0 / (x * 9.0)) else: tmp = 1.0 - ((y / 3.0) * math.pow(x, -0.5)) return tmp
function code(x, y) tmp = 0.0 if (y <= -1.8e+45) tmp = Float64(1.0 - Float64(Float64(y / 3.0) / sqrt(x))); elseif (y <= 7.8e+99) tmp = Float64(1.0 + Float64(-1.0 / Float64(x * 9.0))); else tmp = Float64(1.0 - Float64(Float64(y / 3.0) * (x ^ -0.5))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= -1.8e+45) tmp = 1.0 - ((y / 3.0) / sqrt(x)); elseif (y <= 7.8e+99) tmp = 1.0 + (-1.0 / (x * 9.0)); else tmp = 1.0 - ((y / 3.0) * (x ^ -0.5)); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, -1.8e+45], N[(1.0 - N[(N[(y / 3.0), $MachinePrecision] / N[Sqrt[x], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 7.8e+99], N[(1.0 + N[(-1.0 / N[(x * 9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1.0 - N[(N[(y / 3.0), $MachinePrecision] * N[Power[x, -0.5], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.8 \cdot 10^{+45}:\\
\;\;\;\;1 - \frac{\frac{y}{3}}{\sqrt{x}}\\
\mathbf{elif}\;y \leq 7.8 \cdot 10^{+99}:\\
\;\;\;\;1 + \frac{-1}{x \cdot 9}\\
\mathbf{else}:\\
\;\;\;\;1 - \frac{y}{3} \cdot {x}^{-0.5}\\
\end{array}
\end{array}
if y < -1.8e45Initial program 99.6%
Taylor expanded in x around inf
Simplified94.9%
--lowering--.f64N/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
sqrt-lowering-sqrt.f6494.9%
Applied egg-rr94.9%
if -1.8e45 < y < 7.79999999999999989e99Initial program 99.8%
sub-negN/A
+-lowering-+.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-/r*N/A
distribute-neg-fracN/A
/-lowering-/.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around 0
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f6494.1%
Simplified94.1%
clear-numN/A
associate-/r/N/A
metadata-evalN/A
metadata-evalN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
div-invN/A
clear-numN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f64N/A
associate-/r/N/A
metadata-evalN/A
*-commutativeN/A
*-lowering-*.f6494.1%
Applied egg-rr94.1%
if 7.79999999999999989e99 < y Initial program 99.6%
Taylor expanded in x around inf
Simplified96.4%
*-lft-identityN/A
associate-*r/N/A
*-commutativeN/A
times-fracN/A
*-lowering-*.f64N/A
pow1/2N/A
pow-flipN/A
pow-lowering-pow.f64N/A
metadata-evalN/A
/-lowering-/.f6496.5%
Applied egg-rr96.5%
Final simplification94.7%
(FPCore (x y)
:precision binary64
(if (<= y -4.4e+45)
(- 1.0 (/ (/ y 3.0) (sqrt x)))
(if (<= y 7.8e+99)
(+ 1.0 (/ -1.0 (* x 9.0)))
(- 1.0 (/ y (* 3.0 (sqrt x)))))))
double code(double x, double y) {
double tmp;
if (y <= -4.4e+45) {
tmp = 1.0 - ((y / 3.0) / sqrt(x));
} else if (y <= 7.8e+99) {
tmp = 1.0 + (-1.0 / (x * 9.0));
} else {
tmp = 1.0 - (y / (3.0 * sqrt(x)));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= (-4.4d+45)) then
tmp = 1.0d0 - ((y / 3.0d0) / sqrt(x))
else if (y <= 7.8d+99) then
tmp = 1.0d0 + ((-1.0d0) / (x * 9.0d0))
else
tmp = 1.0d0 - (y / (3.0d0 * sqrt(x)))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= -4.4e+45) {
tmp = 1.0 - ((y / 3.0) / Math.sqrt(x));
} else if (y <= 7.8e+99) {
tmp = 1.0 + (-1.0 / (x * 9.0));
} else {
tmp = 1.0 - (y / (3.0 * Math.sqrt(x)));
}
return tmp;
}
def code(x, y): tmp = 0 if y <= -4.4e+45: tmp = 1.0 - ((y / 3.0) / math.sqrt(x)) elif y <= 7.8e+99: tmp = 1.0 + (-1.0 / (x * 9.0)) else: tmp = 1.0 - (y / (3.0 * math.sqrt(x))) return tmp
function code(x, y) tmp = 0.0 if (y <= -4.4e+45) tmp = Float64(1.0 - Float64(Float64(y / 3.0) / sqrt(x))); elseif (y <= 7.8e+99) tmp = Float64(1.0 + Float64(-1.0 / Float64(x * 9.0))); else tmp = Float64(1.0 - Float64(y / Float64(3.0 * sqrt(x)))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= -4.4e+45) tmp = 1.0 - ((y / 3.0) / sqrt(x)); elseif (y <= 7.8e+99) tmp = 1.0 + (-1.0 / (x * 9.0)); else tmp = 1.0 - (y / (3.0 * sqrt(x))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, -4.4e+45], N[(1.0 - N[(N[(y / 3.0), $MachinePrecision] / N[Sqrt[x], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 7.8e+99], N[(1.0 + N[(-1.0 / N[(x * 9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1.0 - N[(y / N[(3.0 * N[Sqrt[x], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.4 \cdot 10^{+45}:\\
\;\;\;\;1 - \frac{\frac{y}{3}}{\sqrt{x}}\\
\mathbf{elif}\;y \leq 7.8 \cdot 10^{+99}:\\
\;\;\;\;1 + \frac{-1}{x \cdot 9}\\
\mathbf{else}:\\
\;\;\;\;1 - \frac{y}{3 \cdot \sqrt{x}}\\
\end{array}
\end{array}
if y < -4.4000000000000001e45Initial program 99.6%
Taylor expanded in x around inf
Simplified94.9%
--lowering--.f64N/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
sqrt-lowering-sqrt.f6494.9%
Applied egg-rr94.9%
if -4.4000000000000001e45 < y < 7.79999999999999989e99Initial program 99.8%
sub-negN/A
+-lowering-+.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-/r*N/A
distribute-neg-fracN/A
/-lowering-/.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around 0
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f6494.1%
Simplified94.1%
clear-numN/A
associate-/r/N/A
metadata-evalN/A
metadata-evalN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
div-invN/A
clear-numN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f64N/A
associate-/r/N/A
metadata-evalN/A
*-commutativeN/A
*-lowering-*.f6494.1%
Applied egg-rr94.1%
if 7.79999999999999989e99 < y Initial program 99.6%
Taylor expanded in x around inf
Simplified96.4%
(FPCore (x y) :precision binary64 (let* ((t_0 (- 1.0 (/ y (* 3.0 (sqrt x)))))) (if (<= y -1e+46) t_0 (if (<= y 7.8e+99) (+ 1.0 (/ -1.0 (* x 9.0))) t_0))))
double code(double x, double y) {
double t_0 = 1.0 - (y / (3.0 * sqrt(x)));
double tmp;
if (y <= -1e+46) {
tmp = t_0;
} else if (y <= 7.8e+99) {
tmp = 1.0 + (-1.0 / (x * 9.0));
} else {
tmp = t_0;
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: t_0
real(8) :: tmp
t_0 = 1.0d0 - (y / (3.0d0 * sqrt(x)))
if (y <= (-1d+46)) then
tmp = t_0
else if (y <= 7.8d+99) then
tmp = 1.0d0 + ((-1.0d0) / (x * 9.0d0))
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = 1.0 - (y / (3.0 * Math.sqrt(x)));
double tmp;
if (y <= -1e+46) {
tmp = t_0;
} else if (y <= 7.8e+99) {
tmp = 1.0 + (-1.0 / (x * 9.0));
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y): t_0 = 1.0 - (y / (3.0 * math.sqrt(x))) tmp = 0 if y <= -1e+46: tmp = t_0 elif y <= 7.8e+99: tmp = 1.0 + (-1.0 / (x * 9.0)) else: tmp = t_0 return tmp
function code(x, y) t_0 = Float64(1.0 - Float64(y / Float64(3.0 * sqrt(x)))) tmp = 0.0 if (y <= -1e+46) tmp = t_0; elseif (y <= 7.8e+99) tmp = Float64(1.0 + Float64(-1.0 / Float64(x * 9.0))); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y) t_0 = 1.0 - (y / (3.0 * sqrt(x))); tmp = 0.0; if (y <= -1e+46) tmp = t_0; elseif (y <= 7.8e+99) tmp = 1.0 + (-1.0 / (x * 9.0)); else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(1.0 - N[(y / N[(3.0 * N[Sqrt[x], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1e+46], t$95$0, If[LessEqual[y, 7.8e+99], N[(1.0 + N[(-1.0 / N[(x * 9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$0]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 1 - \frac{y}{3 \cdot \sqrt{x}}\\
\mathbf{if}\;y \leq -1 \cdot 10^{+46}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;y \leq 7.8 \cdot 10^{+99}:\\
\;\;\;\;1 + \frac{-1}{x \cdot 9}\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if y < -9.9999999999999999e45 or 7.79999999999999989e99 < y Initial program 99.6%
Taylor expanded in x around inf
Simplified95.5%
if -9.9999999999999999e45 < y < 7.79999999999999989e99Initial program 99.8%
sub-negN/A
+-lowering-+.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-/r*N/A
distribute-neg-fracN/A
/-lowering-/.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around 0
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f6494.1%
Simplified94.1%
clear-numN/A
associate-/r/N/A
metadata-evalN/A
metadata-evalN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
div-invN/A
clear-numN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f64N/A
associate-/r/N/A
metadata-evalN/A
*-commutativeN/A
*-lowering-*.f6494.1%
Applied egg-rr94.1%
(FPCore (x y)
:precision binary64
(if (<= y -4.2e+45)
(+ 1.0 (/ -0.3333333333333333 (/ (sqrt x) y)))
(if (<= y 7.8e+99)
(+ 1.0 (/ -1.0 (* x 9.0)))
(- 1.0 (* (/ y (sqrt x)) 0.3333333333333333)))))
double code(double x, double y) {
double tmp;
if (y <= -4.2e+45) {
tmp = 1.0 + (-0.3333333333333333 / (sqrt(x) / y));
} else if (y <= 7.8e+99) {
tmp = 1.0 + (-1.0 / (x * 9.0));
} else {
tmp = 1.0 - ((y / sqrt(x)) * 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 <= (-4.2d+45)) then
tmp = 1.0d0 + ((-0.3333333333333333d0) / (sqrt(x) / y))
else if (y <= 7.8d+99) then
tmp = 1.0d0 + ((-1.0d0) / (x * 9.0d0))
else
tmp = 1.0d0 - ((y / sqrt(x)) * 0.3333333333333333d0)
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= -4.2e+45) {
tmp = 1.0 + (-0.3333333333333333 / (Math.sqrt(x) / y));
} else if (y <= 7.8e+99) {
tmp = 1.0 + (-1.0 / (x * 9.0));
} else {
tmp = 1.0 - ((y / Math.sqrt(x)) * 0.3333333333333333);
}
return tmp;
}
def code(x, y): tmp = 0 if y <= -4.2e+45: tmp = 1.0 + (-0.3333333333333333 / (math.sqrt(x) / y)) elif y <= 7.8e+99: tmp = 1.0 + (-1.0 / (x * 9.0)) else: tmp = 1.0 - ((y / math.sqrt(x)) * 0.3333333333333333) return tmp
function code(x, y) tmp = 0.0 if (y <= -4.2e+45) tmp = Float64(1.0 + Float64(-0.3333333333333333 / Float64(sqrt(x) / y))); elseif (y <= 7.8e+99) tmp = Float64(1.0 + Float64(-1.0 / Float64(x * 9.0))); else tmp = Float64(1.0 - Float64(Float64(y / sqrt(x)) * 0.3333333333333333)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= -4.2e+45) tmp = 1.0 + (-0.3333333333333333 / (sqrt(x) / y)); elseif (y <= 7.8e+99) tmp = 1.0 + (-1.0 / (x * 9.0)); else tmp = 1.0 - ((y / sqrt(x)) * 0.3333333333333333); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, -4.2e+45], N[(1.0 + N[(-0.3333333333333333 / N[(N[Sqrt[x], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 7.8e+99], N[(1.0 + N[(-1.0 / N[(x * 9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1.0 - N[(N[(y / N[Sqrt[x], $MachinePrecision]), $MachinePrecision] * 0.3333333333333333), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.2 \cdot 10^{+45}:\\
\;\;\;\;1 + \frac{-0.3333333333333333}{\frac{\sqrt{x}}{y}}\\
\mathbf{elif}\;y \leq 7.8 \cdot 10^{+99}:\\
\;\;\;\;1 + \frac{-1}{x \cdot 9}\\
\mathbf{else}:\\
\;\;\;\;1 - \frac{y}{\sqrt{x}} \cdot 0.3333333333333333\\
\end{array}
\end{array}
if y < -4.1999999999999999e45Initial program 99.6%
Taylor expanded in x around inf
Simplified94.9%
sub-negN/A
+-commutativeN/A
+-lowering-+.f64N/A
distribute-neg-fracN/A
neg-mul-1N/A
times-fracN/A
metadata-evalN/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
sqrt-lowering-sqrt.f6494.8%
Applied egg-rr94.8%
if -4.1999999999999999e45 < y < 7.79999999999999989e99Initial program 99.8%
sub-negN/A
+-lowering-+.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-/r*N/A
distribute-neg-fracN/A
/-lowering-/.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around 0
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f6494.1%
Simplified94.1%
clear-numN/A
associate-/r/N/A
metadata-evalN/A
metadata-evalN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
div-invN/A
clear-numN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f64N/A
associate-/r/N/A
metadata-evalN/A
*-commutativeN/A
*-lowering-*.f6494.1%
Applied egg-rr94.1%
if 7.79999999999999989e99 < y Initial program 99.6%
Taylor expanded in x around inf
Simplified96.4%
div-invN/A
associate-*r/N/A
*-commutativeN/A
times-fracN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-eval96.3%
Applied egg-rr96.3%
Final simplification94.6%
(FPCore (x y)
:precision binary64
(if (<= y -1.32e+45)
(+ 1.0 (/ -0.3333333333333333 (/ (sqrt x) y)))
(if (<= y 8.2e+99)
(+ 1.0 (/ -1.0 (* x 9.0)))
(* (sqrt (/ 1.0 x)) (* y -0.3333333333333333)))))
double code(double x, double y) {
double tmp;
if (y <= -1.32e+45) {
tmp = 1.0 + (-0.3333333333333333 / (sqrt(x) / y));
} else if (y <= 8.2e+99) {
tmp = 1.0 + (-1.0 / (x * 9.0));
} else {
tmp = sqrt((1.0 / x)) * (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 <= (-1.32d+45)) then
tmp = 1.0d0 + ((-0.3333333333333333d0) / (sqrt(x) / y))
else if (y <= 8.2d+99) then
tmp = 1.0d0 + ((-1.0d0) / (x * 9.0d0))
else
tmp = sqrt((1.0d0 / x)) * (y * (-0.3333333333333333d0))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= -1.32e+45) {
tmp = 1.0 + (-0.3333333333333333 / (Math.sqrt(x) / y));
} else if (y <= 8.2e+99) {
tmp = 1.0 + (-1.0 / (x * 9.0));
} else {
tmp = Math.sqrt((1.0 / x)) * (y * -0.3333333333333333);
}
return tmp;
}
def code(x, y): tmp = 0 if y <= -1.32e+45: tmp = 1.0 + (-0.3333333333333333 / (math.sqrt(x) / y)) elif y <= 8.2e+99: tmp = 1.0 + (-1.0 / (x * 9.0)) else: tmp = math.sqrt((1.0 / x)) * (y * -0.3333333333333333) return tmp
function code(x, y) tmp = 0.0 if (y <= -1.32e+45) tmp = Float64(1.0 + Float64(-0.3333333333333333 / Float64(sqrt(x) / y))); elseif (y <= 8.2e+99) tmp = Float64(1.0 + Float64(-1.0 / Float64(x * 9.0))); else tmp = Float64(sqrt(Float64(1.0 / x)) * Float64(y * -0.3333333333333333)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= -1.32e+45) tmp = 1.0 + (-0.3333333333333333 / (sqrt(x) / y)); elseif (y <= 8.2e+99) tmp = 1.0 + (-1.0 / (x * 9.0)); else tmp = sqrt((1.0 / x)) * (y * -0.3333333333333333); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, -1.32e+45], N[(1.0 + N[(-0.3333333333333333 / N[(N[Sqrt[x], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 8.2e+99], N[(1.0 + N[(-1.0 / N[(x * 9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[Sqrt[N[(1.0 / x), $MachinePrecision]], $MachinePrecision] * N[(y * -0.3333333333333333), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.32 \cdot 10^{+45}:\\
\;\;\;\;1 + \frac{-0.3333333333333333}{\frac{\sqrt{x}}{y}}\\
\mathbf{elif}\;y \leq 8.2 \cdot 10^{+99}:\\
\;\;\;\;1 + \frac{-1}{x \cdot 9}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\frac{1}{x}} \cdot \left(y \cdot -0.3333333333333333\right)\\
\end{array}
\end{array}
if y < -1.32000000000000005e45Initial program 99.6%
Taylor expanded in x around inf
Simplified94.9%
sub-negN/A
+-commutativeN/A
+-lowering-+.f64N/A
distribute-neg-fracN/A
neg-mul-1N/A
times-fracN/A
metadata-evalN/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
sqrt-lowering-sqrt.f6494.8%
Applied egg-rr94.8%
if -1.32000000000000005e45 < y < 8.19999999999999959e99Initial program 99.8%
sub-negN/A
+-lowering-+.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-/r*N/A
distribute-neg-fracN/A
/-lowering-/.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around 0
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f6494.1%
Simplified94.1%
clear-numN/A
associate-/r/N/A
metadata-evalN/A
metadata-evalN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
div-invN/A
clear-numN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f64N/A
associate-/r/N/A
metadata-evalN/A
*-commutativeN/A
*-lowering-*.f6494.1%
Applied egg-rr94.1%
if 8.19999999999999959e99 < y Initial program 99.6%
sub-negN/A
+-lowering-+.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-/r*N/A
distribute-neg-fracN/A
/-lowering-/.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-eval99.6%
Simplified99.6%
Taylor expanded in y around inf
associate-*r*N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f6496.1%
Simplified96.1%
Final simplification94.6%
(FPCore (x y)
:precision binary64
(let* ((t_0 (* (sqrt (/ 1.0 x)) (* y -0.3333333333333333))))
(if (<= y -1.02e+46)
t_0
(if (<= y 7.8e+99) (+ 1.0 (/ -1.0 (* x 9.0))) t_0))))
double code(double x, double y) {
double t_0 = sqrt((1.0 / x)) * (y * -0.3333333333333333);
double tmp;
if (y <= -1.02e+46) {
tmp = t_0;
} else if (y <= 7.8e+99) {
tmp = 1.0 + (-1.0 / (x * 9.0));
} else {
tmp = t_0;
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: t_0
real(8) :: tmp
t_0 = sqrt((1.0d0 / x)) * (y * (-0.3333333333333333d0))
if (y <= (-1.02d+46)) then
tmp = t_0
else if (y <= 7.8d+99) then
tmp = 1.0d0 + ((-1.0d0) / (x * 9.0d0))
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = Math.sqrt((1.0 / x)) * (y * -0.3333333333333333);
double tmp;
if (y <= -1.02e+46) {
tmp = t_0;
} else if (y <= 7.8e+99) {
tmp = 1.0 + (-1.0 / (x * 9.0));
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y): t_0 = math.sqrt((1.0 / x)) * (y * -0.3333333333333333) tmp = 0 if y <= -1.02e+46: tmp = t_0 elif y <= 7.8e+99: tmp = 1.0 + (-1.0 / (x * 9.0)) else: tmp = t_0 return tmp
function code(x, y) t_0 = Float64(sqrt(Float64(1.0 / x)) * Float64(y * -0.3333333333333333)) tmp = 0.0 if (y <= -1.02e+46) tmp = t_0; elseif (y <= 7.8e+99) tmp = Float64(1.0 + Float64(-1.0 / Float64(x * 9.0))); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y) t_0 = sqrt((1.0 / x)) * (y * -0.3333333333333333); tmp = 0.0; if (y <= -1.02e+46) tmp = t_0; elseif (y <= 7.8e+99) tmp = 1.0 + (-1.0 / (x * 9.0)); else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(N[Sqrt[N[(1.0 / x), $MachinePrecision]], $MachinePrecision] * N[(y * -0.3333333333333333), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.02e+46], t$95$0, If[LessEqual[y, 7.8e+99], N[(1.0 + N[(-1.0 / N[(x * 9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$0]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \sqrt{\frac{1}{x}} \cdot \left(y \cdot -0.3333333333333333\right)\\
\mathbf{if}\;y \leq -1.02 \cdot 10^{+46}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;y \leq 7.8 \cdot 10^{+99}:\\
\;\;\;\;1 + \frac{-1}{x \cdot 9}\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if y < -1.0199999999999999e46 or 7.79999999999999989e99 < y Initial program 99.6%
sub-negN/A
+-lowering-+.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-/r*N/A
distribute-neg-fracN/A
/-lowering-/.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-eval99.6%
Simplified99.6%
Taylor expanded in y around inf
associate-*r*N/A
*-commutativeN/A
associate-*l*N/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f6493.5%
Simplified93.5%
if -1.0199999999999999e46 < y < 7.79999999999999989e99Initial program 99.8%
sub-negN/A
+-lowering-+.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-/r*N/A
distribute-neg-fracN/A
/-lowering-/.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around 0
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f6494.1%
Simplified94.1%
clear-numN/A
associate-/r/N/A
metadata-evalN/A
metadata-evalN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
div-invN/A
clear-numN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f64N/A
associate-/r/N/A
metadata-evalN/A
*-commutativeN/A
*-lowering-*.f6494.1%
Applied egg-rr94.1%
Final simplification93.9%
(FPCore (x y) :precision binary64 (if (<= x 1.12e-14) (- (/ -0.1111111111111111 x) (/ (/ y (sqrt x)) 3.0)) (- 1.0 (/ (/ y 3.0) (sqrt x)))))
double code(double x, double y) {
double tmp;
if (x <= 1.12e-14) {
tmp = (-0.1111111111111111 / x) - ((y / sqrt(x)) / 3.0);
} else {
tmp = 1.0 - ((y / 3.0) / sqrt(x));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 1.12d-14) then
tmp = ((-0.1111111111111111d0) / x) - ((y / sqrt(x)) / 3.0d0)
else
tmp = 1.0d0 - ((y / 3.0d0) / sqrt(x))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 1.12e-14) {
tmp = (-0.1111111111111111 / x) - ((y / Math.sqrt(x)) / 3.0);
} else {
tmp = 1.0 - ((y / 3.0) / Math.sqrt(x));
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 1.12e-14: tmp = (-0.1111111111111111 / x) - ((y / math.sqrt(x)) / 3.0) else: tmp = 1.0 - ((y / 3.0) / math.sqrt(x)) return tmp
function code(x, y) tmp = 0.0 if (x <= 1.12e-14) tmp = Float64(Float64(-0.1111111111111111 / x) - Float64(Float64(y / sqrt(x)) / 3.0)); else tmp = Float64(1.0 - Float64(Float64(y / 3.0) / sqrt(x))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 1.12e-14) tmp = (-0.1111111111111111 / x) - ((y / sqrt(x)) / 3.0); else tmp = 1.0 - ((y / 3.0) / sqrt(x)); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 1.12e-14], N[(N[(-0.1111111111111111 / x), $MachinePrecision] - N[(N[(y / N[Sqrt[x], $MachinePrecision]), $MachinePrecision] / 3.0), $MachinePrecision]), $MachinePrecision], N[(1.0 - N[(N[(y / 3.0), $MachinePrecision] / N[Sqrt[x], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 1.12 \cdot 10^{-14}:\\
\;\;\;\;\frac{-0.1111111111111111}{x} - \frac{\frac{y}{\sqrt{x}}}{3}\\
\mathbf{else}:\\
\;\;\;\;1 - \frac{\frac{y}{3}}{\sqrt{x}}\\
\end{array}
\end{array}
if x < 1.12000000000000006e-14Initial program 99.7%
Taylor expanded in x around 0
/-lowering-/.f6499.5%
Simplified99.5%
*-commutativeN/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
sqrt-lowering-sqrt.f6499.6%
Applied egg-rr99.6%
if 1.12000000000000006e-14 < x Initial program 99.8%
Taylor expanded in x around inf
Simplified99.3%
--lowering--.f64N/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
sqrt-lowering-sqrt.f6499.4%
Applied egg-rr99.4%
(FPCore (x y) :precision binary64 (if (<= x 1.12e-14) (- (/ -0.1111111111111111 x) (/ y (* 3.0 (sqrt x)))) (- 1.0 (/ (/ y 3.0) (sqrt x)))))
double code(double x, double y) {
double tmp;
if (x <= 1.12e-14) {
tmp = (-0.1111111111111111 / x) - (y / (3.0 * sqrt(x)));
} else {
tmp = 1.0 - ((y / 3.0) / sqrt(x));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 1.12d-14) then
tmp = ((-0.1111111111111111d0) / x) - (y / (3.0d0 * sqrt(x)))
else
tmp = 1.0d0 - ((y / 3.0d0) / sqrt(x))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 1.12e-14) {
tmp = (-0.1111111111111111 / x) - (y / (3.0 * Math.sqrt(x)));
} else {
tmp = 1.0 - ((y / 3.0) / Math.sqrt(x));
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 1.12e-14: tmp = (-0.1111111111111111 / x) - (y / (3.0 * math.sqrt(x))) else: tmp = 1.0 - ((y / 3.0) / math.sqrt(x)) return tmp
function code(x, y) tmp = 0.0 if (x <= 1.12e-14) tmp = Float64(Float64(-0.1111111111111111 / x) - Float64(y / Float64(3.0 * sqrt(x)))); else tmp = Float64(1.0 - Float64(Float64(y / 3.0) / sqrt(x))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 1.12e-14) tmp = (-0.1111111111111111 / x) - (y / (3.0 * sqrt(x))); else tmp = 1.0 - ((y / 3.0) / sqrt(x)); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 1.12e-14], N[(N[(-0.1111111111111111 / x), $MachinePrecision] - N[(y / N[(3.0 * N[Sqrt[x], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1.0 - N[(N[(y / 3.0), $MachinePrecision] / N[Sqrt[x], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 1.12 \cdot 10^{-14}:\\
\;\;\;\;\frac{-0.1111111111111111}{x} - \frac{y}{3 \cdot \sqrt{x}}\\
\mathbf{else}:\\
\;\;\;\;1 - \frac{\frac{y}{3}}{\sqrt{x}}\\
\end{array}
\end{array}
if x < 1.12000000000000006e-14Initial program 99.7%
Taylor expanded in x around 0
/-lowering-/.f6499.5%
Simplified99.5%
if 1.12000000000000006e-14 < x Initial program 99.8%
Taylor expanded in x around inf
Simplified99.3%
--lowering--.f64N/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
sqrt-lowering-sqrt.f6499.4%
Applied egg-rr99.4%
(FPCore (x y) :precision binary64 (+ (+ 1.0 (/ -0.1111111111111111 x)) (/ y (* (sqrt x) -3.0))))
double code(double x, double y) {
return (1.0 + (-0.1111111111111111 / x)) + (y / (sqrt(x) * -3.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) * (-3.0d0)))
end function
public static double code(double x, double y) {
return (1.0 + (-0.1111111111111111 / x)) + (y / (Math.sqrt(x) * -3.0));
}
def code(x, y): return (1.0 + (-0.1111111111111111 / x)) + (y / (math.sqrt(x) * -3.0))
function code(x, y) return Float64(Float64(1.0 + Float64(-0.1111111111111111 / x)) + Float64(y / Float64(sqrt(x) * -3.0))) end
function tmp = code(x, y) tmp = (1.0 + (-0.1111111111111111 / x)) + (y / (sqrt(x) * -3.0)); end
code[x_, y_] := N[(N[(1.0 + N[(-0.1111111111111111 / x), $MachinePrecision]), $MachinePrecision] + N[(y / N[(N[Sqrt[x], $MachinePrecision] * -3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(1 + \frac{-0.1111111111111111}{x}\right) + \frac{y}{\sqrt{x} \cdot -3}
\end{array}
Initial program 99.7%
sub-negN/A
+-lowering-+.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-/r*N/A
distribute-neg-fracN/A
/-lowering-/.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-eval99.7%
Simplified99.7%
(FPCore (x y) :precision binary64 (+ (+ 1.0 (/ -0.1111111111111111 x)) (* (/ y (sqrt x)) -0.3333333333333333)))
double code(double x, double y) {
return (1.0 + (-0.1111111111111111 / x)) + ((y / sqrt(x)) * -0.3333333333333333);
}
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)) * (-0.3333333333333333d0))
end function
public static double code(double x, double y) {
return (1.0 + (-0.1111111111111111 / x)) + ((y / Math.sqrt(x)) * -0.3333333333333333);
}
def code(x, y): return (1.0 + (-0.1111111111111111 / x)) + ((y / math.sqrt(x)) * -0.3333333333333333)
function code(x, y) return Float64(Float64(1.0 + Float64(-0.1111111111111111 / x)) + Float64(Float64(y / sqrt(x)) * -0.3333333333333333)) end
function tmp = code(x, y) tmp = (1.0 + (-0.1111111111111111 / x)) + ((y / sqrt(x)) * -0.3333333333333333); end
code[x_, y_] := N[(N[(1.0 + N[(-0.1111111111111111 / x), $MachinePrecision]), $MachinePrecision] + N[(N[(y / N[Sqrt[x], $MachinePrecision]), $MachinePrecision] * -0.3333333333333333), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(1 + \frac{-0.1111111111111111}{x}\right) + \frac{y}{\sqrt{x}} \cdot -0.3333333333333333
\end{array}
Initial program 99.7%
sub-negN/A
+-lowering-+.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-/r*N/A
distribute-neg-fracN/A
/-lowering-/.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-eval99.7%
Simplified99.7%
associate-/r*N/A
div-invN/A
metadata-evalN/A
metadata-evalN/A
metadata-evalN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-evalN/A
metadata-eval99.6%
Applied egg-rr99.6%
(FPCore (x y) :precision binary64 (if (<= y -6.6e+104) (+ 1.0 (/ (+ -0.1111111111111111 (/ 0.024691358024691357 x)) x)) (+ 1.0 (/ -1.0 (* x 9.0)))))
double code(double x, double y) {
double tmp;
if (y <= -6.6e+104) {
tmp = 1.0 + ((-0.1111111111111111 + (0.024691358024691357 / x)) / x);
} else {
tmp = 1.0 + (-1.0 / (x * 9.0));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= (-6.6d+104)) then
tmp = 1.0d0 + (((-0.1111111111111111d0) + (0.024691358024691357d0 / x)) / x)
else
tmp = 1.0d0 + ((-1.0d0) / (x * 9.0d0))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= -6.6e+104) {
tmp = 1.0 + ((-0.1111111111111111 + (0.024691358024691357 / x)) / x);
} else {
tmp = 1.0 + (-1.0 / (x * 9.0));
}
return tmp;
}
def code(x, y): tmp = 0 if y <= -6.6e+104: tmp = 1.0 + ((-0.1111111111111111 + (0.024691358024691357 / x)) / x) else: tmp = 1.0 + (-1.0 / (x * 9.0)) return tmp
function code(x, y) tmp = 0.0 if (y <= -6.6e+104) tmp = Float64(1.0 + Float64(Float64(-0.1111111111111111 + Float64(0.024691358024691357 / x)) / x)); else tmp = Float64(1.0 + Float64(-1.0 / Float64(x * 9.0))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= -6.6e+104) tmp = 1.0 + ((-0.1111111111111111 + (0.024691358024691357 / x)) / x); else tmp = 1.0 + (-1.0 / (x * 9.0)); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, -6.6e+104], N[(1.0 + N[(N[(-0.1111111111111111 + N[(0.024691358024691357 / x), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision], N[(1.0 + N[(-1.0 / N[(x * 9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -6.6 \cdot 10^{+104}:\\
\;\;\;\;1 + \frac{-0.1111111111111111 + \frac{0.024691358024691357}{x}}{x}\\
\mathbf{else}:\\
\;\;\;\;1 + \frac{-1}{x \cdot 9}\\
\end{array}
\end{array}
if y < -6.59999999999999969e104Initial program 99.6%
sub-negN/A
+-lowering-+.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-/r*N/A
distribute-neg-fracN/A
/-lowering-/.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-eval99.6%
Simplified99.6%
Taylor expanded in y around 0
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f642.7%
Simplified2.7%
clear-numN/A
associate-/r/N/A
metadata-evalN/A
metadata-evalN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
div-invN/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
metadata-eval2.7%
Applied egg-rr2.7%
Applied egg-rr3.5%
Taylor expanded in x around inf
associate--l+N/A
+-lowering-+.f64N/A
sub-negN/A
+-commutativeN/A
neg-sub0N/A
associate--r-N/A
associate-*r/N/A
metadata-evalN/A
unpow2N/A
associate-/r*N/A
metadata-evalN/A
associate-*r/N/A
div-subN/A
neg-sub0N/A
mul-1-negN/A
associate-*r/N/A
/-lowering-/.f64N/A
Simplified31.2%
if -6.59999999999999969e104 < y Initial program 99.7%
sub-negN/A
+-lowering-+.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-/r*N/A
distribute-neg-fracN/A
/-lowering-/.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-eval99.7%
Simplified99.7%
Taylor expanded in y around 0
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f6473.2%
Simplified73.2%
clear-numN/A
associate-/r/N/A
metadata-evalN/A
metadata-evalN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
div-invN/A
clear-numN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f64N/A
associate-/r/N/A
metadata-evalN/A
*-commutativeN/A
*-lowering-*.f6473.3%
Applied egg-rr73.3%
(FPCore (x y) :precision binary64 (if (<= x 600.0) (/ -0.1111111111111111 x) 1.0))
double code(double x, double y) {
double tmp;
if (x <= 600.0) {
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 <= 600.0d0) 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 <= 600.0) {
tmp = -0.1111111111111111 / x;
} else {
tmp = 1.0;
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 600.0: tmp = -0.1111111111111111 / x else: tmp = 1.0 return tmp
function code(x, y) tmp = 0.0 if (x <= 600.0) tmp = Float64(-0.1111111111111111 / x); else tmp = 1.0; end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 600.0) tmp = -0.1111111111111111 / x; else tmp = 1.0; end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 600.0], N[(-0.1111111111111111 / x), $MachinePrecision], 1.0]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 600:\\
\;\;\;\;\frac{-0.1111111111111111}{x}\\
\mathbf{else}:\\
\;\;\;\;1\\
\end{array}
\end{array}
if x < 600Initial program 99.7%
sub-negN/A
+-lowering-+.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-/r*N/A
distribute-neg-fracN/A
/-lowering-/.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-eval99.6%
Simplified99.6%
Taylor expanded in y around 0
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f6461.7%
Simplified61.7%
Taylor expanded in x around 0
/-lowering-/.f6461.7%
Simplified61.7%
if 600 < x Initial program 99.8%
sub-negN/A
+-lowering-+.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-/r*N/A
distribute-neg-fracN/A
/-lowering-/.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around 0
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f6459.8%
Simplified59.8%
Taylor expanded in x around inf
Simplified59.6%
(FPCore (x y) :precision binary64 (+ 1.0 (/ -1.0 (* x 9.0))))
double code(double x, double y) {
return 1.0 + (-1.0 / (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))
end function
public static double code(double x, double y) {
return 1.0 + (-1.0 / (x * 9.0));
}
def code(x, y): return 1.0 + (-1.0 / (x * 9.0))
function code(x, y) return Float64(1.0 + Float64(-1.0 / Float64(x * 9.0))) end
function tmp = code(x, y) tmp = 1.0 + (-1.0 / (x * 9.0)); end
code[x_, y_] := N[(1.0 + N[(-1.0 / N[(x * 9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
1 + \frac{-1}{x \cdot 9}
\end{array}
Initial program 99.7%
sub-negN/A
+-lowering-+.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-/r*N/A
distribute-neg-fracN/A
/-lowering-/.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-eval99.7%
Simplified99.7%
Taylor expanded in y around 0
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f6460.8%
Simplified60.8%
clear-numN/A
associate-/r/N/A
metadata-evalN/A
metadata-evalN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
div-invN/A
clear-numN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f64N/A
associate-/r/N/A
metadata-evalN/A
*-commutativeN/A
*-lowering-*.f6460.9%
Applied egg-rr60.9%
(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-negN/A
+-lowering-+.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-/r*N/A
distribute-neg-fracN/A
/-lowering-/.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-eval99.7%
Simplified99.7%
Taylor expanded in y around 0
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f6460.8%
Simplified60.8%
(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-negN/A
+-lowering-+.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-/r*N/A
distribute-neg-fracN/A
/-lowering-/.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
*-commutativeN/A
distribute-rgt-neg-inN/A
*-lowering-*.f64N/A
sqrt-lowering-sqrt.f64N/A
metadata-eval99.7%
Simplified99.7%
Taylor expanded in y around 0
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f6460.8%
Simplified60.8%
Taylor expanded in x around inf
Simplified28.7%
(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 2024152
(FPCore (x y)
:name "Numeric.SpecFunctions:invIncompleteGamma from math-functions-0.1.5.2, D"
:precision binary64
:alt
(! :herbie-platform default (- (- 1 (/ (/ 1 x) 9)) (/ y (* 3 (sqrt x)))))
(- (- 1.0 (/ 1.0 (* x 9.0))) (/ y (* 3.0 (sqrt x)))))