
(FPCore (x y z)
:precision binary64
(+
(+ (- (* (- x 0.5) (log x)) x) 0.91893853320467)
(/
(+
(* (- (* (+ y 0.0007936500793651) z) 0.0027777777777778) z)
0.083333333333333)
x)))
double code(double x, double y, double z) {
return ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + ((((((y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x);
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = ((((x - 0.5d0) * log(x)) - x) + 0.91893853320467d0) + ((((((y + 0.0007936500793651d0) * z) - 0.0027777777777778d0) * z) + 0.083333333333333d0) / x)
end function
public static double code(double x, double y, double z) {
return ((((x - 0.5) * Math.log(x)) - x) + 0.91893853320467) + ((((((y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x);
}
def code(x, y, z): return ((((x - 0.5) * math.log(x)) - x) + 0.91893853320467) + ((((((y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x)
function code(x, y, z) return Float64(Float64(Float64(Float64(Float64(x - 0.5) * log(x)) - x) + 0.91893853320467) + Float64(Float64(Float64(Float64(Float64(Float64(y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x)) end
function tmp = code(x, y, z) tmp = ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + ((((((y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x); end
code[x_, y_, z_] := N[(N[(N[(N[(N[(x - 0.5), $MachinePrecision] * N[Log[x], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision] + 0.91893853320467), $MachinePrecision] + N[(N[(N[(N[(N[(N[(y + 0.0007936500793651), $MachinePrecision] * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision] * z), $MachinePrecision] + 0.083333333333333), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 16 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z)
:precision binary64
(+
(+ (- (* (- x 0.5) (log x)) x) 0.91893853320467)
(/
(+
(* (- (* (+ y 0.0007936500793651) z) 0.0027777777777778) z)
0.083333333333333)
x)))
double code(double x, double y, double z) {
return ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + ((((((y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x);
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = ((((x - 0.5d0) * log(x)) - x) + 0.91893853320467d0) + ((((((y + 0.0007936500793651d0) * z) - 0.0027777777777778d0) * z) + 0.083333333333333d0) / x)
end function
public static double code(double x, double y, double z) {
return ((((x - 0.5) * Math.log(x)) - x) + 0.91893853320467) + ((((((y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x);
}
def code(x, y, z): return ((((x - 0.5) * math.log(x)) - x) + 0.91893853320467) + ((((((y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x)
function code(x, y, z) return Float64(Float64(Float64(Float64(Float64(x - 0.5) * log(x)) - x) + 0.91893853320467) + Float64(Float64(Float64(Float64(Float64(Float64(y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x)) end
function tmp = code(x, y, z) tmp = ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + ((((((y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x); end
code[x_, y_, z_] := N[(N[(N[(N[(N[(x - 0.5), $MachinePrecision] * N[Log[x], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision] + 0.91893853320467), $MachinePrecision] + N[(N[(N[(N[(N[(N[(y + 0.0007936500793651), $MachinePrecision] * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision] * z), $MachinePrecision] + 0.083333333333333), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}
\end{array}
(FPCore (x y z)
:precision binary64
(let* ((t_0 (+ (- (* (- x 0.5) (log x)) x) 0.91893853320467)))
(if (<= x 1e-28)
(+
t_0
(pow
(/
x
(fma
z
(fma (+ y 0.0007936500793651) z -0.0027777777777778)
0.083333333333333))
-1.0))
(+
t_0
(+
(* -0.0027777777777778 (/ z x))
(+
(* 0.083333333333333 (/ 1.0 x))
(* (+ y 0.0007936500793651) (/ (pow z 2.0) x))))))))
double code(double x, double y, double z) {
double t_0 = (((x - 0.5) * log(x)) - x) + 0.91893853320467;
double tmp;
if (x <= 1e-28) {
tmp = t_0 + pow((x / fma(z, fma((y + 0.0007936500793651), z, -0.0027777777777778), 0.083333333333333)), -1.0);
} else {
tmp = t_0 + ((-0.0027777777777778 * (z / x)) + ((0.083333333333333 * (1.0 / x)) + ((y + 0.0007936500793651) * (pow(z, 2.0) / x))));
}
return tmp;
}
function code(x, y, z) t_0 = Float64(Float64(Float64(Float64(x - 0.5) * log(x)) - x) + 0.91893853320467) tmp = 0.0 if (x <= 1e-28) tmp = Float64(t_0 + (Float64(x / fma(z, fma(Float64(y + 0.0007936500793651), z, -0.0027777777777778), 0.083333333333333)) ^ -1.0)); else tmp = Float64(t_0 + Float64(Float64(-0.0027777777777778 * Float64(z / x)) + Float64(Float64(0.083333333333333 * Float64(1.0 / x)) + Float64(Float64(y + 0.0007936500793651) * Float64((z ^ 2.0) / x))))); end return tmp end
code[x_, y_, z_] := Block[{t$95$0 = N[(N[(N[(N[(x - 0.5), $MachinePrecision] * N[Log[x], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision] + 0.91893853320467), $MachinePrecision]}, If[LessEqual[x, 1e-28], N[(t$95$0 + N[Power[N[(x / N[(z * N[(N[(y + 0.0007936500793651), $MachinePrecision] * z + -0.0027777777777778), $MachinePrecision] + 0.083333333333333), $MachinePrecision]), $MachinePrecision], -1.0], $MachinePrecision]), $MachinePrecision], N[(t$95$0 + N[(N[(-0.0027777777777778 * N[(z / x), $MachinePrecision]), $MachinePrecision] + N[(N[(0.083333333333333 * N[(1.0 / x), $MachinePrecision]), $MachinePrecision] + N[(N[(y + 0.0007936500793651), $MachinePrecision] * N[(N[Power[z, 2.0], $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\\
\mathbf{if}\;x \leq 10^{-28}:\\
\;\;\;\;t_0 + {\left(\frac{x}{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}\right)}^{-1}\\
\mathbf{else}:\\
\;\;\;\;t_0 + \left(-0.0027777777777778 \cdot \frac{z}{x} + \left(0.083333333333333 \cdot \frac{1}{x} + \left(y + 0.0007936500793651\right) \cdot \frac{{z}^{2}}{x}\right)\right)\\
\end{array}
\end{array}
if x < 9.99999999999999971e-29Initial program 99.7%
clear-num99.7%
inv-pow99.7%
*-commutative99.7%
fma-udef99.7%
fma-neg99.7%
metadata-eval99.7%
Applied egg-rr99.7%
if 9.99999999999999971e-29 < x Initial program 84.5%
Taylor expanded in z around inf 84.5%
*-commutative84.5%
*-un-lft-identity84.5%
times-frac95.5%
+-commutative95.5%
Applied egg-rr95.5%
Final simplification97.5%
(FPCore (x y z)
:precision binary64
(if (<= x 3e+27)
(+
(fma (+ x -0.5) (log x) (- x))
(+
0.91893853320467
(/
(fma
(fma (+ y 0.0007936500793651) z -0.0027777777777778)
z
0.083333333333333)
x)))
(+
(+ (- (* (- x 0.5) (log x)) x) 0.91893853320467)
(+
(* -0.0027777777777778 (/ z x))
(+
(* 0.083333333333333 (/ 1.0 x))
(* (+ y 0.0007936500793651) (/ (pow z 2.0) x)))))))
double code(double x, double y, double z) {
double tmp;
if (x <= 3e+27) {
tmp = fma((x + -0.5), log(x), -x) + (0.91893853320467 + (fma(fma((y + 0.0007936500793651), z, -0.0027777777777778), z, 0.083333333333333) / x));
} else {
tmp = ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + ((-0.0027777777777778 * (z / x)) + ((0.083333333333333 * (1.0 / x)) + ((y + 0.0007936500793651) * (pow(z, 2.0) / x))));
}
return tmp;
}
function code(x, y, z) tmp = 0.0 if (x <= 3e+27) tmp = Float64(fma(Float64(x + -0.5), log(x), Float64(-x)) + Float64(0.91893853320467 + Float64(fma(fma(Float64(y + 0.0007936500793651), z, -0.0027777777777778), z, 0.083333333333333) / x))); else tmp = Float64(Float64(Float64(Float64(Float64(x - 0.5) * log(x)) - x) + 0.91893853320467) + Float64(Float64(-0.0027777777777778 * Float64(z / x)) + Float64(Float64(0.083333333333333 * Float64(1.0 / x)) + Float64(Float64(y + 0.0007936500793651) * Float64((z ^ 2.0) / x))))); end return tmp end
code[x_, y_, z_] := If[LessEqual[x, 3e+27], N[(N[(N[(x + -0.5), $MachinePrecision] * N[Log[x], $MachinePrecision] + (-x)), $MachinePrecision] + N[(0.91893853320467 + N[(N[(N[(N[(y + 0.0007936500793651), $MachinePrecision] * z + -0.0027777777777778), $MachinePrecision] * z + 0.083333333333333), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[(N[(x - 0.5), $MachinePrecision] * N[Log[x], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision] + 0.91893853320467), $MachinePrecision] + N[(N[(-0.0027777777777778 * N[(z / x), $MachinePrecision]), $MachinePrecision] + N[(N[(0.083333333333333 * N[(1.0 / x), $MachinePrecision]), $MachinePrecision] + N[(N[(y + 0.0007936500793651), $MachinePrecision] * N[(N[Power[z, 2.0], $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 3 \cdot 10^{+27}:\\
\;\;\;\;\mathsf{fma}\left(x + -0.5, \log x, -x\right) + \left(0.91893853320467 + \frac{\mathsf{fma}\left(\mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), z, 0.083333333333333\right)}{x}\right)\\
\mathbf{else}:\\
\;\;\;\;\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \left(-0.0027777777777778 \cdot \frac{z}{x} + \left(0.083333333333333 \cdot \frac{1}{x} + \left(y + 0.0007936500793651\right) \cdot \frac{{z}^{2}}{x}\right)\right)\\
\end{array}
\end{array}
if x < 2.99999999999999976e27Initial program 99.6%
associate-+l+99.6%
fma-neg99.6%
sub-neg99.6%
metadata-eval99.6%
fma-def99.6%
fma-neg99.6%
metadata-eval99.6%
Simplified99.6%
if 2.99999999999999976e27 < x Initial program 81.5%
Taylor expanded in z around inf 81.5%
*-commutative81.5%
*-un-lft-identity81.5%
times-frac94.7%
+-commutative94.7%
Applied egg-rr94.7%
Final simplification97.4%
(FPCore (x y z)
:precision binary64
(if (<= x 2.9e-9)
(+
(+ 0.91893853320467 (+ x (* (log x) (+ x -0.5))))
(/
(+
0.083333333333333
(* z (- (* z (+ y 0.0007936500793651)) 0.0027777777777778)))
x))
(+
(+ (- (* (- x 0.5) (log x)) x) 0.91893853320467)
(+
(* -0.0027777777777778 (/ z x))
(+
(* 0.083333333333333 (/ 1.0 x))
(* (+ y 0.0007936500793651) (/ (pow z 2.0) x)))))))
double code(double x, double y, double z) {
double tmp;
if (x <= 2.9e-9) {
tmp = (0.91893853320467 + (x + (log(x) * (x + -0.5)))) + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x);
} else {
tmp = ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + ((-0.0027777777777778 * (z / x)) + ((0.083333333333333 * (1.0 / x)) + ((y + 0.0007936500793651) * (pow(z, 2.0) / x))));
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if (x <= 2.9d-9) then
tmp = (0.91893853320467d0 + (x + (log(x) * (x + (-0.5d0))))) + ((0.083333333333333d0 + (z * ((z * (y + 0.0007936500793651d0)) - 0.0027777777777778d0))) / x)
else
tmp = ((((x - 0.5d0) * log(x)) - x) + 0.91893853320467d0) + (((-0.0027777777777778d0) * (z / x)) + ((0.083333333333333d0 * (1.0d0 / x)) + ((y + 0.0007936500793651d0) * ((z ** 2.0d0) / x))))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= 2.9e-9) {
tmp = (0.91893853320467 + (x + (Math.log(x) * (x + -0.5)))) + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x);
} else {
tmp = ((((x - 0.5) * Math.log(x)) - x) + 0.91893853320467) + ((-0.0027777777777778 * (z / x)) + ((0.083333333333333 * (1.0 / x)) + ((y + 0.0007936500793651) * (Math.pow(z, 2.0) / x))));
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= 2.9e-9: tmp = (0.91893853320467 + (x + (math.log(x) * (x + -0.5)))) + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x) else: tmp = ((((x - 0.5) * math.log(x)) - x) + 0.91893853320467) + ((-0.0027777777777778 * (z / x)) + ((0.083333333333333 * (1.0 / x)) + ((y + 0.0007936500793651) * (math.pow(z, 2.0) / x)))) return tmp
function code(x, y, z) tmp = 0.0 if (x <= 2.9e-9) tmp = Float64(Float64(0.91893853320467 + Float64(x + Float64(log(x) * Float64(x + -0.5)))) + Float64(Float64(0.083333333333333 + Float64(z * Float64(Float64(z * Float64(y + 0.0007936500793651)) - 0.0027777777777778))) / x)); else tmp = Float64(Float64(Float64(Float64(Float64(x - 0.5) * log(x)) - x) + 0.91893853320467) + Float64(Float64(-0.0027777777777778 * Float64(z / x)) + Float64(Float64(0.083333333333333 * Float64(1.0 / x)) + Float64(Float64(y + 0.0007936500793651) * Float64((z ^ 2.0) / x))))); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= 2.9e-9) tmp = (0.91893853320467 + (x + (log(x) * (x + -0.5)))) + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x); else tmp = ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + ((-0.0027777777777778 * (z / x)) + ((0.083333333333333 * (1.0 / x)) + ((y + 0.0007936500793651) * ((z ^ 2.0) / x)))); end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, 2.9e-9], N[(N[(0.91893853320467 + N[(x + N[(N[Log[x], $MachinePrecision] * N[(x + -0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(0.083333333333333 + N[(z * N[(N[(z * N[(y + 0.0007936500793651), $MachinePrecision]), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[(N[(x - 0.5), $MachinePrecision] * N[Log[x], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision] + 0.91893853320467), $MachinePrecision] + N[(N[(-0.0027777777777778 * N[(z / x), $MachinePrecision]), $MachinePrecision] + N[(N[(0.083333333333333 * N[(1.0 / x), $MachinePrecision]), $MachinePrecision] + N[(N[(y + 0.0007936500793651), $MachinePrecision] * N[(N[Power[z, 2.0], $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 2.9 \cdot 10^{-9}:\\
\;\;\;\;\left(0.91893853320467 + \left(x + \log x \cdot \left(x + -0.5\right)\right)\right) + \frac{0.083333333333333 + z \cdot \left(z \cdot \left(y + 0.0007936500793651\right) - 0.0027777777777778\right)}{x}\\
\mathbf{else}:\\
\;\;\;\;\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \left(-0.0027777777777778 \cdot \frac{z}{x} + \left(0.083333333333333 \cdot \frac{1}{x} + \left(y + 0.0007936500793651\right) \cdot \frac{{z}^{2}}{x}\right)\right)\\
\end{array}
\end{array}
if x < 2.89999999999999991e-9Initial program 99.7%
sub-neg99.7%
add-sqr-sqrt0.0%
sqrt-unprod99.7%
sqr-neg99.7%
sqrt-unprod99.7%
add-sqr-sqrt99.7%
sub-neg99.7%
metadata-eval99.7%
*-commutative99.7%
Applied egg-rr99.7%
if 2.89999999999999991e-9 < x Initial program 83.7%
Taylor expanded in z around inf 83.7%
*-commutative83.7%
*-un-lft-identity83.7%
times-frac95.3%
+-commutative95.3%
Applied egg-rr95.3%
Final simplification97.4%
(FPCore (x y z)
:precision binary64
(if (<= x 5200000.0)
(+
(/
(+
0.083333333333333
(* z (- (* z (+ y 0.0007936500793651)) 0.0027777777777778)))
x)
(- (* (log x) (+ x -0.5)) (+ x -0.91893853320467)))
(+
(+ (- (* (- x 0.5) (log x)) x) 0.91893853320467)
(/ (+ y 0.0007936500793651) (/ x (pow z 2.0))))))
double code(double x, double y, double z) {
double tmp;
if (x <= 5200000.0) {
tmp = ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x) + ((log(x) * (x + -0.5)) - (x + -0.91893853320467));
} else {
tmp = ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + ((y + 0.0007936500793651) / (x / pow(z, 2.0)));
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if (x <= 5200000.0d0) then
tmp = ((0.083333333333333d0 + (z * ((z * (y + 0.0007936500793651d0)) - 0.0027777777777778d0))) / x) + ((log(x) * (x + (-0.5d0))) - (x + (-0.91893853320467d0)))
else
tmp = ((((x - 0.5d0) * log(x)) - x) + 0.91893853320467d0) + ((y + 0.0007936500793651d0) / (x / (z ** 2.0d0)))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= 5200000.0) {
tmp = ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x) + ((Math.log(x) * (x + -0.5)) - (x + -0.91893853320467));
} else {
tmp = ((((x - 0.5) * Math.log(x)) - x) + 0.91893853320467) + ((y + 0.0007936500793651) / (x / Math.pow(z, 2.0)));
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= 5200000.0: tmp = ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x) + ((math.log(x) * (x + -0.5)) - (x + -0.91893853320467)) else: tmp = ((((x - 0.5) * math.log(x)) - x) + 0.91893853320467) + ((y + 0.0007936500793651) / (x / math.pow(z, 2.0))) return tmp
function code(x, y, z) tmp = 0.0 if (x <= 5200000.0) tmp = Float64(Float64(Float64(0.083333333333333 + Float64(z * Float64(Float64(z * Float64(y + 0.0007936500793651)) - 0.0027777777777778))) / x) + Float64(Float64(log(x) * Float64(x + -0.5)) - Float64(x + -0.91893853320467))); else tmp = Float64(Float64(Float64(Float64(Float64(x - 0.5) * log(x)) - x) + 0.91893853320467) + Float64(Float64(y + 0.0007936500793651) / Float64(x / (z ^ 2.0)))); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= 5200000.0) tmp = ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x) + ((log(x) * (x + -0.5)) - (x + -0.91893853320467)); else tmp = ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + ((y + 0.0007936500793651) / (x / (z ^ 2.0))); end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, 5200000.0], N[(N[(N[(0.083333333333333 + N[(z * N[(N[(z * N[(y + 0.0007936500793651), $MachinePrecision]), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision] + N[(N[(N[Log[x], $MachinePrecision] * N[(x + -0.5), $MachinePrecision]), $MachinePrecision] - N[(x + -0.91893853320467), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[(N[(x - 0.5), $MachinePrecision] * N[Log[x], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision] + 0.91893853320467), $MachinePrecision] + N[(N[(y + 0.0007936500793651), $MachinePrecision] / N[(x / N[Power[z, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 5200000:\\
\;\;\;\;\frac{0.083333333333333 + z \cdot \left(z \cdot \left(y + 0.0007936500793651\right) - 0.0027777777777778\right)}{x} + \left(\log x \cdot \left(x + -0.5\right) - \left(x + -0.91893853320467\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{y + 0.0007936500793651}{\frac{x}{{z}^{2}}}\\
\end{array}
\end{array}
if x < 5.2e6Initial program 99.7%
associate-+l-99.7%
sub-neg99.7%
metadata-eval99.7%
*-commutative99.7%
sub-neg99.7%
metadata-eval99.7%
Applied egg-rr99.7%
if 5.2e6 < x Initial program 82.7%
Taylor expanded in z around inf 82.7%
+-commutative82.7%
*-commutative82.7%
associate-/l*95.0%
+-commutative95.0%
Simplified95.0%
Final simplification97.4%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (+ (- (* (- x 0.5) (log x)) x) 0.91893853320467)))
(if (<= x 1.15e+60)
(+
t_0
(/
(+
0.083333333333333
(* z (- (* z (+ y 0.0007936500793651)) 0.0027777777777778)))
x))
(+ t_0 (* (pow z 2.0) (/ y x))))))
double code(double x, double y, double z) {
double t_0 = (((x - 0.5) * log(x)) - x) + 0.91893853320467;
double tmp;
if (x <= 1.15e+60) {
tmp = t_0 + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x);
} else {
tmp = t_0 + (pow(z, 2.0) * (y / x));
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: t_0
real(8) :: tmp
t_0 = (((x - 0.5d0) * log(x)) - x) + 0.91893853320467d0
if (x <= 1.15d+60) then
tmp = t_0 + ((0.083333333333333d0 + (z * ((z * (y + 0.0007936500793651d0)) - 0.0027777777777778d0))) / x)
else
tmp = t_0 + ((z ** 2.0d0) * (y / x))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = (((x - 0.5) * Math.log(x)) - x) + 0.91893853320467;
double tmp;
if (x <= 1.15e+60) {
tmp = t_0 + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x);
} else {
tmp = t_0 + (Math.pow(z, 2.0) * (y / x));
}
return tmp;
}
def code(x, y, z): t_0 = (((x - 0.5) * math.log(x)) - x) + 0.91893853320467 tmp = 0 if x <= 1.15e+60: tmp = t_0 + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x) else: tmp = t_0 + (math.pow(z, 2.0) * (y / x)) return tmp
function code(x, y, z) t_0 = Float64(Float64(Float64(Float64(x - 0.5) * log(x)) - x) + 0.91893853320467) tmp = 0.0 if (x <= 1.15e+60) tmp = Float64(t_0 + Float64(Float64(0.083333333333333 + Float64(z * Float64(Float64(z * Float64(y + 0.0007936500793651)) - 0.0027777777777778))) / x)); else tmp = Float64(t_0 + Float64((z ^ 2.0) * Float64(y / x))); end return tmp end
function tmp_2 = code(x, y, z) t_0 = (((x - 0.5) * log(x)) - x) + 0.91893853320467; tmp = 0.0; if (x <= 1.15e+60) tmp = t_0 + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x); else tmp = t_0 + ((z ^ 2.0) * (y / x)); end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(N[(N[(N[(x - 0.5), $MachinePrecision] * N[Log[x], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision] + 0.91893853320467), $MachinePrecision]}, If[LessEqual[x, 1.15e+60], N[(t$95$0 + N[(N[(0.083333333333333 + N[(z * N[(N[(z * N[(y + 0.0007936500793651), $MachinePrecision]), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision], N[(t$95$0 + N[(N[Power[z, 2.0], $MachinePrecision] * N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\\
\mathbf{if}\;x \leq 1.15 \cdot 10^{+60}:\\
\;\;\;\;t_0 + \frac{0.083333333333333 + z \cdot \left(z \cdot \left(y + 0.0007936500793651\right) - 0.0027777777777778\right)}{x}\\
\mathbf{else}:\\
\;\;\;\;t_0 + {z}^{2} \cdot \frac{y}{x}\\
\end{array}
\end{array}
if x < 1.15000000000000008e60Initial program 99.6%
if 1.15000000000000008e60 < x Initial program 78.6%
Taylor expanded in y around inf 75.5%
*-commutative75.5%
associate-*r/90.6%
Simplified90.6%
Final simplification96.2%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (+ (- (* (- x 0.5) (log x)) x) 0.91893853320467)))
(if (<= x 1.5e+60)
(+
t_0
(/
(+
0.083333333333333
(* z (- (* z (+ y 0.0007936500793651)) 0.0027777777777778)))
x))
(+ t_0 (/ y (/ x (pow z 2.0)))))))
double code(double x, double y, double z) {
double t_0 = (((x - 0.5) * log(x)) - x) + 0.91893853320467;
double tmp;
if (x <= 1.5e+60) {
tmp = t_0 + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x);
} else {
tmp = t_0 + (y / (x / pow(z, 2.0)));
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: t_0
real(8) :: tmp
t_0 = (((x - 0.5d0) * log(x)) - x) + 0.91893853320467d0
if (x <= 1.5d+60) then
tmp = t_0 + ((0.083333333333333d0 + (z * ((z * (y + 0.0007936500793651d0)) - 0.0027777777777778d0))) / x)
else
tmp = t_0 + (y / (x / (z ** 2.0d0)))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = (((x - 0.5) * Math.log(x)) - x) + 0.91893853320467;
double tmp;
if (x <= 1.5e+60) {
tmp = t_0 + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x);
} else {
tmp = t_0 + (y / (x / Math.pow(z, 2.0)));
}
return tmp;
}
def code(x, y, z): t_0 = (((x - 0.5) * math.log(x)) - x) + 0.91893853320467 tmp = 0 if x <= 1.5e+60: tmp = t_0 + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x) else: tmp = t_0 + (y / (x / math.pow(z, 2.0))) return tmp
function code(x, y, z) t_0 = Float64(Float64(Float64(Float64(x - 0.5) * log(x)) - x) + 0.91893853320467) tmp = 0.0 if (x <= 1.5e+60) tmp = Float64(t_0 + Float64(Float64(0.083333333333333 + Float64(z * Float64(Float64(z * Float64(y + 0.0007936500793651)) - 0.0027777777777778))) / x)); else tmp = Float64(t_0 + Float64(y / Float64(x / (z ^ 2.0)))); end return tmp end
function tmp_2 = code(x, y, z) t_0 = (((x - 0.5) * log(x)) - x) + 0.91893853320467; tmp = 0.0; if (x <= 1.5e+60) tmp = t_0 + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x); else tmp = t_0 + (y / (x / (z ^ 2.0))); end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(N[(N[(N[(x - 0.5), $MachinePrecision] * N[Log[x], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision] + 0.91893853320467), $MachinePrecision]}, If[LessEqual[x, 1.5e+60], N[(t$95$0 + N[(N[(0.083333333333333 + N[(z * N[(N[(z * N[(y + 0.0007936500793651), $MachinePrecision]), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision], N[(t$95$0 + N[(y / N[(x / N[Power[z, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\\
\mathbf{if}\;x \leq 1.5 \cdot 10^{+60}:\\
\;\;\;\;t_0 + \frac{0.083333333333333 + z \cdot \left(z \cdot \left(y + 0.0007936500793651\right) - 0.0027777777777778\right)}{x}\\
\mathbf{else}:\\
\;\;\;\;t_0 + \frac{y}{\frac{x}{{z}^{2}}}\\
\end{array}
\end{array}
if x < 1.4999999999999999e60Initial program 99.6%
if 1.4999999999999999e60 < x Initial program 78.6%
Taylor expanded in y around inf 75.5%
associate-/l*90.7%
Simplified90.7%
Final simplification96.2%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* x (+ (log x) -1.0)))
(t_1
(+
(/
(+
0.083333333333333
(* z (- (* z (+ y 0.0007936500793651)) 0.0027777777777778)))
x)
t_0)))
(if (<= x 6.5e-13)
t_1
(if (<= x 310000.0)
(+
(- (* (log x) (+ x -0.5)) (+ x -0.91893853320467))
(/ 0.083333333333333 x))
(if (<= x 2.1e+168) t_1 t_0)))))
double code(double x, double y, double z) {
double t_0 = x * (log(x) + -1.0);
double t_1 = ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x) + t_0;
double tmp;
if (x <= 6.5e-13) {
tmp = t_1;
} else if (x <= 310000.0) {
tmp = ((log(x) * (x + -0.5)) - (x + -0.91893853320467)) + (0.083333333333333 / x);
} else if (x <= 2.1e+168) {
tmp = t_1;
} else {
tmp = t_0;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = x * (log(x) + (-1.0d0))
t_1 = ((0.083333333333333d0 + (z * ((z * (y + 0.0007936500793651d0)) - 0.0027777777777778d0))) / x) + t_0
if (x <= 6.5d-13) then
tmp = t_1
else if (x <= 310000.0d0) then
tmp = ((log(x) * (x + (-0.5d0))) - (x + (-0.91893853320467d0))) + (0.083333333333333d0 / x)
else if (x <= 2.1d+168) then
tmp = t_1
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = x * (Math.log(x) + -1.0);
double t_1 = ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x) + t_0;
double tmp;
if (x <= 6.5e-13) {
tmp = t_1;
} else if (x <= 310000.0) {
tmp = ((Math.log(x) * (x + -0.5)) - (x + -0.91893853320467)) + (0.083333333333333 / x);
} else if (x <= 2.1e+168) {
tmp = t_1;
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = x * (math.log(x) + -1.0) t_1 = ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x) + t_0 tmp = 0 if x <= 6.5e-13: tmp = t_1 elif x <= 310000.0: tmp = ((math.log(x) * (x + -0.5)) - (x + -0.91893853320467)) + (0.083333333333333 / x) elif x <= 2.1e+168: tmp = t_1 else: tmp = t_0 return tmp
function code(x, y, z) t_0 = Float64(x * Float64(log(x) + -1.0)) t_1 = Float64(Float64(Float64(0.083333333333333 + Float64(z * Float64(Float64(z * Float64(y + 0.0007936500793651)) - 0.0027777777777778))) / x) + t_0) tmp = 0.0 if (x <= 6.5e-13) tmp = t_1; elseif (x <= 310000.0) tmp = Float64(Float64(Float64(log(x) * Float64(x + -0.5)) - Float64(x + -0.91893853320467)) + Float64(0.083333333333333 / x)); elseif (x <= 2.1e+168) tmp = t_1; else tmp = t_0; end return tmp end
function tmp_2 = code(x, y, z) t_0 = x * (log(x) + -1.0); t_1 = ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x) + t_0; tmp = 0.0; if (x <= 6.5e-13) tmp = t_1; elseif (x <= 310000.0) tmp = ((log(x) * (x + -0.5)) - (x + -0.91893853320467)) + (0.083333333333333 / x); elseif (x <= 2.1e+168) tmp = t_1; else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(x * N[(N[Log[x], $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[(N[(0.083333333333333 + N[(z * N[(N[(z * N[(y + 0.0007936500793651), $MachinePrecision]), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision] + t$95$0), $MachinePrecision]}, If[LessEqual[x, 6.5e-13], t$95$1, If[LessEqual[x, 310000.0], N[(N[(N[(N[Log[x], $MachinePrecision] * N[(x + -0.5), $MachinePrecision]), $MachinePrecision] - N[(x + -0.91893853320467), $MachinePrecision]), $MachinePrecision] + N[(0.083333333333333 / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.1e+168], t$95$1, t$95$0]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x \cdot \left(\log x + -1\right)\\
t_1 := \frac{0.083333333333333 + z \cdot \left(z \cdot \left(y + 0.0007936500793651\right) - 0.0027777777777778\right)}{x} + t_0\\
\mathbf{if}\;x \leq 6.5 \cdot 10^{-13}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq 310000:\\
\;\;\;\;\left(\log x \cdot \left(x + -0.5\right) - \left(x + -0.91893853320467\right)\right) + \frac{0.083333333333333}{x}\\
\mathbf{elif}\;x \leq 2.1 \cdot 10^{+168}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t_0\\
\end{array}
\end{array}
if x < 6.49999999999999957e-13 or 3.1e5 < x < 2.10000000000000003e168Initial program 97.7%
Taylor expanded in x around inf 97.6%
sub-neg97.6%
mul-1-neg97.6%
log-rec97.6%
remove-double-neg97.6%
metadata-eval97.6%
Simplified97.6%
if 6.49999999999999957e-13 < x < 3.1e5Initial program 99.6%
Taylor expanded in z around 0 97.7%
associate-+l-99.7%
sub-neg99.7%
metadata-eval99.7%
*-commutative99.7%
sub-neg99.7%
metadata-eval99.7%
Applied egg-rr97.8%
if 2.10000000000000003e168 < x Initial program 71.2%
associate-+l+71.2%
fma-neg71.4%
sub-neg71.4%
metadata-eval71.4%
fma-def71.4%
fma-neg71.4%
metadata-eval71.4%
Simplified71.4%
Taylor expanded in z around 0 85.1%
Taylor expanded in x around inf 85.1%
sub-neg85.1%
mul-1-neg85.1%
log-rec85.1%
remove-double-neg85.1%
metadata-eval85.1%
Simplified85.1%
Final simplification94.6%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* x (+ (log x) -1.0)))
(t_1 (* (log x) (+ x -0.5)))
(t_2
(/
(+
0.083333333333333
(* z (- (* z (+ y 0.0007936500793651)) 0.0027777777777778)))
x)))
(if (<= x 2.8e-7)
(+ (+ 0.91893853320467 (+ x t_1)) t_2)
(if (<= x 270000.0)
(+ (- t_1 (+ x -0.91893853320467)) (/ 0.083333333333333 x))
(if (<= x 1.2e+170) (+ t_2 t_0) t_0)))))
double code(double x, double y, double z) {
double t_0 = x * (log(x) + -1.0);
double t_1 = log(x) * (x + -0.5);
double t_2 = (0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x;
double tmp;
if (x <= 2.8e-7) {
tmp = (0.91893853320467 + (x + t_1)) + t_2;
} else if (x <= 270000.0) {
tmp = (t_1 - (x + -0.91893853320467)) + (0.083333333333333 / x);
} else if (x <= 1.2e+170) {
tmp = t_2 + t_0;
} else {
tmp = t_0;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_0 = x * (log(x) + (-1.0d0))
t_1 = log(x) * (x + (-0.5d0))
t_2 = (0.083333333333333d0 + (z * ((z * (y + 0.0007936500793651d0)) - 0.0027777777777778d0))) / x
if (x <= 2.8d-7) then
tmp = (0.91893853320467d0 + (x + t_1)) + t_2
else if (x <= 270000.0d0) then
tmp = (t_1 - (x + (-0.91893853320467d0))) + (0.083333333333333d0 / x)
else if (x <= 1.2d+170) then
tmp = t_2 + t_0
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = x * (Math.log(x) + -1.0);
double t_1 = Math.log(x) * (x + -0.5);
double t_2 = (0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x;
double tmp;
if (x <= 2.8e-7) {
tmp = (0.91893853320467 + (x + t_1)) + t_2;
} else if (x <= 270000.0) {
tmp = (t_1 - (x + -0.91893853320467)) + (0.083333333333333 / x);
} else if (x <= 1.2e+170) {
tmp = t_2 + t_0;
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = x * (math.log(x) + -1.0) t_1 = math.log(x) * (x + -0.5) t_2 = (0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x tmp = 0 if x <= 2.8e-7: tmp = (0.91893853320467 + (x + t_1)) + t_2 elif x <= 270000.0: tmp = (t_1 - (x + -0.91893853320467)) + (0.083333333333333 / x) elif x <= 1.2e+170: tmp = t_2 + t_0 else: tmp = t_0 return tmp
function code(x, y, z) t_0 = Float64(x * Float64(log(x) + -1.0)) t_1 = Float64(log(x) * Float64(x + -0.5)) t_2 = Float64(Float64(0.083333333333333 + Float64(z * Float64(Float64(z * Float64(y + 0.0007936500793651)) - 0.0027777777777778))) / x) tmp = 0.0 if (x <= 2.8e-7) tmp = Float64(Float64(0.91893853320467 + Float64(x + t_1)) + t_2); elseif (x <= 270000.0) tmp = Float64(Float64(t_1 - Float64(x + -0.91893853320467)) + Float64(0.083333333333333 / x)); elseif (x <= 1.2e+170) tmp = Float64(t_2 + t_0); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y, z) t_0 = x * (log(x) + -1.0); t_1 = log(x) * (x + -0.5); t_2 = (0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x; tmp = 0.0; if (x <= 2.8e-7) tmp = (0.91893853320467 + (x + t_1)) + t_2; elseif (x <= 270000.0) tmp = (t_1 - (x + -0.91893853320467)) + (0.083333333333333 / x); elseif (x <= 1.2e+170) tmp = t_2 + t_0; else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(x * N[(N[Log[x], $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[Log[x], $MachinePrecision] * N[(x + -0.5), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(0.083333333333333 + N[(z * N[(N[(z * N[(y + 0.0007936500793651), $MachinePrecision]), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision]}, If[LessEqual[x, 2.8e-7], N[(N[(0.91893853320467 + N[(x + t$95$1), $MachinePrecision]), $MachinePrecision] + t$95$2), $MachinePrecision], If[LessEqual[x, 270000.0], N[(N[(t$95$1 - N[(x + -0.91893853320467), $MachinePrecision]), $MachinePrecision] + N[(0.083333333333333 / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1.2e+170], N[(t$95$2 + t$95$0), $MachinePrecision], t$95$0]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x \cdot \left(\log x + -1\right)\\
t_1 := \log x \cdot \left(x + -0.5\right)\\
t_2 := \frac{0.083333333333333 + z \cdot \left(z \cdot \left(y + 0.0007936500793651\right) - 0.0027777777777778\right)}{x}\\
\mathbf{if}\;x \leq 2.8 \cdot 10^{-7}:\\
\;\;\;\;\left(0.91893853320467 + \left(x + t_1\right)\right) + t_2\\
\mathbf{elif}\;x \leq 270000:\\
\;\;\;\;\left(t_1 - \left(x + -0.91893853320467\right)\right) + \frac{0.083333333333333}{x}\\
\mathbf{elif}\;x \leq 1.2 \cdot 10^{+170}:\\
\;\;\;\;t_2 + t_0\\
\mathbf{else}:\\
\;\;\;\;t_0\\
\end{array}
\end{array}
if x < 2.80000000000000019e-7Initial program 99.7%
sub-neg99.7%
add-sqr-sqrt0.0%
sqrt-unprod99.7%
sqr-neg99.7%
sqrt-unprod99.7%
add-sqr-sqrt99.7%
sub-neg99.7%
metadata-eval99.7%
*-commutative99.7%
Applied egg-rr99.7%
if 2.80000000000000019e-7 < x < 2.7e5Initial program 99.7%
Taylor expanded in z around 0 97.3%
associate-+l-99.8%
sub-neg99.8%
metadata-eval99.8%
*-commutative99.8%
sub-neg99.8%
metadata-eval99.8%
Applied egg-rr97.4%
if 2.7e5 < x < 1.2e170Initial program 93.8%
Taylor expanded in x around inf 93.4%
sub-neg93.4%
mul-1-neg93.4%
log-rec93.4%
remove-double-neg93.4%
metadata-eval93.4%
Simplified93.4%
if 1.2e170 < x Initial program 71.2%
associate-+l+71.2%
fma-neg71.4%
sub-neg71.4%
metadata-eval71.4%
fma-def71.4%
fma-neg71.4%
metadata-eval71.4%
Simplified71.4%
Taylor expanded in z around 0 85.1%
Taylor expanded in x around inf 85.1%
sub-neg85.1%
mul-1-neg85.1%
log-rec85.1%
remove-double-neg85.1%
metadata-eval85.1%
Simplified85.1%
Final simplification94.7%
(FPCore (x y z)
:precision binary64
(if (<= x 3.3e+168)
(+
(+ (- (* (- x 0.5) (log x)) x) 0.91893853320467)
(/
(+
0.083333333333333
(* z (- (* z (+ y 0.0007936500793651)) 0.0027777777777778)))
x))
(* x (+ (log x) -1.0))))
double code(double x, double y, double z) {
double tmp;
if (x <= 3.3e+168) {
tmp = ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x);
} else {
tmp = x * (log(x) + -1.0);
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if (x <= 3.3d+168) then
tmp = ((((x - 0.5d0) * log(x)) - x) + 0.91893853320467d0) + ((0.083333333333333d0 + (z * ((z * (y + 0.0007936500793651d0)) - 0.0027777777777778d0))) / x)
else
tmp = x * (log(x) + (-1.0d0))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= 3.3e+168) {
tmp = ((((x - 0.5) * Math.log(x)) - x) + 0.91893853320467) + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x);
} else {
tmp = x * (Math.log(x) + -1.0);
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= 3.3e+168: tmp = ((((x - 0.5) * math.log(x)) - x) + 0.91893853320467) + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x) else: tmp = x * (math.log(x) + -1.0) return tmp
function code(x, y, z) tmp = 0.0 if (x <= 3.3e+168) tmp = Float64(Float64(Float64(Float64(Float64(x - 0.5) * log(x)) - x) + 0.91893853320467) + Float64(Float64(0.083333333333333 + Float64(z * Float64(Float64(z * Float64(y + 0.0007936500793651)) - 0.0027777777777778))) / x)); else tmp = Float64(x * Float64(log(x) + -1.0)); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= 3.3e+168) tmp = ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x); else tmp = x * (log(x) + -1.0); end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, 3.3e+168], N[(N[(N[(N[(N[(x - 0.5), $MachinePrecision] * N[Log[x], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision] + 0.91893853320467), $MachinePrecision] + N[(N[(0.083333333333333 + N[(z * N[(N[(z * N[(y + 0.0007936500793651), $MachinePrecision]), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[Log[x], $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 3.3 \cdot 10^{+168}:\\
\;\;\;\;\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{0.083333333333333 + z \cdot \left(z \cdot \left(y + 0.0007936500793651\right) - 0.0027777777777778\right)}{x}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(\log x + -1\right)\\
\end{array}
\end{array}
if x < 3.2999999999999999e168Initial program 97.8%
if 3.2999999999999999e168 < x Initial program 71.2%
associate-+l+71.2%
fma-neg71.4%
sub-neg71.4%
metadata-eval71.4%
fma-def71.4%
fma-neg71.4%
metadata-eval71.4%
Simplified71.4%
Taylor expanded in z around 0 85.1%
Taylor expanded in x around inf 85.1%
sub-neg85.1%
mul-1-neg85.1%
log-rec85.1%
remove-double-neg85.1%
metadata-eval85.1%
Simplified85.1%
Final simplification94.8%
(FPCore (x y z) :precision binary64 (+ (- (* (log x) (+ x -0.5)) (+ x -0.91893853320467)) (/ (+ 0.083333333333333 (* z -0.0027777777777778)) x)))
double code(double x, double y, double z) {
return ((log(x) * (x + -0.5)) - (x + -0.91893853320467)) + ((0.083333333333333 + (z * -0.0027777777777778)) / x);
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = ((log(x) * (x + (-0.5d0))) - (x + (-0.91893853320467d0))) + ((0.083333333333333d0 + (z * (-0.0027777777777778d0))) / x)
end function
public static double code(double x, double y, double z) {
return ((Math.log(x) * (x + -0.5)) - (x + -0.91893853320467)) + ((0.083333333333333 + (z * -0.0027777777777778)) / x);
}
def code(x, y, z): return ((math.log(x) * (x + -0.5)) - (x + -0.91893853320467)) + ((0.083333333333333 + (z * -0.0027777777777778)) / x)
function code(x, y, z) return Float64(Float64(Float64(log(x) * Float64(x + -0.5)) - Float64(x + -0.91893853320467)) + Float64(Float64(0.083333333333333 + Float64(z * -0.0027777777777778)) / x)) end
function tmp = code(x, y, z) tmp = ((log(x) * (x + -0.5)) - (x + -0.91893853320467)) + ((0.083333333333333 + (z * -0.0027777777777778)) / x); end
code[x_, y_, z_] := N[(N[(N[(N[Log[x], $MachinePrecision] * N[(x + -0.5), $MachinePrecision]), $MachinePrecision] - N[(x + -0.91893853320467), $MachinePrecision]), $MachinePrecision] + N[(N[(0.083333333333333 + N[(z * -0.0027777777777778), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\log x \cdot \left(x + -0.5\right) - \left(x + -0.91893853320467\right)\right) + \frac{0.083333333333333 + z \cdot -0.0027777777777778}{x}
\end{array}
Initial program 91.6%
associate-+l-91.6%
sub-neg91.6%
metadata-eval91.6%
*-commutative91.6%
sub-neg91.6%
metadata-eval91.6%
Applied egg-rr91.6%
Taylor expanded in z around 0 66.9%
*-commutative66.9%
Simplified66.9%
Final simplification66.9%
(FPCore (x y z) :precision binary64 (if (<= x 1.05) (+ 0.91893853320467 (+ (* 0.083333333333333 (/ 1.0 x)) (* (log x) -0.5))) (* x (+ (log x) -1.0))))
double code(double x, double y, double z) {
double tmp;
if (x <= 1.05) {
tmp = 0.91893853320467 + ((0.083333333333333 * (1.0 / x)) + (log(x) * -0.5));
} else {
tmp = x * (log(x) + -1.0);
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if (x <= 1.05d0) then
tmp = 0.91893853320467d0 + ((0.083333333333333d0 * (1.0d0 / x)) + (log(x) * (-0.5d0)))
else
tmp = x * (log(x) + (-1.0d0))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= 1.05) {
tmp = 0.91893853320467 + ((0.083333333333333 * (1.0 / x)) + (Math.log(x) * -0.5));
} else {
tmp = x * (Math.log(x) + -1.0);
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= 1.05: tmp = 0.91893853320467 + ((0.083333333333333 * (1.0 / x)) + (math.log(x) * -0.5)) else: tmp = x * (math.log(x) + -1.0) return tmp
function code(x, y, z) tmp = 0.0 if (x <= 1.05) tmp = Float64(0.91893853320467 + Float64(Float64(0.083333333333333 * Float64(1.0 / x)) + Float64(log(x) * -0.5))); else tmp = Float64(x * Float64(log(x) + -1.0)); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= 1.05) tmp = 0.91893853320467 + ((0.083333333333333 * (1.0 / x)) + (log(x) * -0.5)); else tmp = x * (log(x) + -1.0); end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, 1.05], N[(0.91893853320467 + N[(N[(0.083333333333333 * N[(1.0 / x), $MachinePrecision]), $MachinePrecision] + N[(N[Log[x], $MachinePrecision] * -0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[Log[x], $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 1.05:\\
\;\;\;\;0.91893853320467 + \left(0.083333333333333 \cdot \frac{1}{x} + \log x \cdot -0.5\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(\log x + -1\right)\\
\end{array}
\end{array}
if x < 1.05000000000000004Initial program 99.7%
associate-+l+99.6%
fma-neg99.7%
sub-neg99.7%
metadata-eval99.7%
fma-def99.7%
fma-neg99.7%
metadata-eval99.7%
Simplified99.7%
Taylor expanded in z around 0 50.9%
Taylor expanded in x around 0 49.3%
if 1.05000000000000004 < x Initial program 83.1%
associate-+l+83.1%
fma-neg83.2%
sub-neg83.2%
metadata-eval83.2%
fma-def83.2%
fma-neg83.2%
metadata-eval83.2%
Simplified83.2%
Taylor expanded in z around 0 70.2%
Taylor expanded in x around inf 68.5%
sub-neg68.5%
mul-1-neg68.5%
log-rec68.5%
remove-double-neg68.5%
metadata-eval68.5%
Simplified68.5%
Final simplification58.7%
(FPCore (x y z) :precision binary64 (+ (+ (- (* (- x 0.5) (log x)) x) 0.91893853320467) (/ 1.0 (* x 12.000000000000048))))
double code(double x, double y, double z) {
return ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + (1.0 / (x * 12.000000000000048));
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = ((((x - 0.5d0) * log(x)) - x) + 0.91893853320467d0) + (1.0d0 / (x * 12.000000000000048d0))
end function
public static double code(double x, double y, double z) {
return ((((x - 0.5) * Math.log(x)) - x) + 0.91893853320467) + (1.0 / (x * 12.000000000000048));
}
def code(x, y, z): return ((((x - 0.5) * math.log(x)) - x) + 0.91893853320467) + (1.0 / (x * 12.000000000000048))
function code(x, y, z) return Float64(Float64(Float64(Float64(Float64(x - 0.5) * log(x)) - x) + 0.91893853320467) + Float64(1.0 / Float64(x * 12.000000000000048))) end
function tmp = code(x, y, z) tmp = ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + (1.0 / (x * 12.000000000000048)); end
code[x_, y_, z_] := N[(N[(N[(N[(N[(x - 0.5), $MachinePrecision] * N[Log[x], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision] + 0.91893853320467), $MachinePrecision] + N[(1.0 / N[(x * 12.000000000000048), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{1}{x \cdot 12.000000000000048}
\end{array}
Initial program 91.6%
Taylor expanded in z around 0 60.3%
clear-num60.3%
inv-pow60.3%
div-inv60.3%
metadata-eval60.3%
Applied egg-rr60.3%
unpow-160.3%
Simplified60.3%
Final simplification60.3%
(FPCore (x y z) :precision binary64 (if (<= x 1.05) (+ (/ 0.083333333333333 x) (+ 0.91893853320467 (* (log x) -0.5))) (* x (+ (log x) -1.0))))
double code(double x, double y, double z) {
double tmp;
if (x <= 1.05) {
tmp = (0.083333333333333 / x) + (0.91893853320467 + (log(x) * -0.5));
} else {
tmp = x * (log(x) + -1.0);
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if (x <= 1.05d0) then
tmp = (0.083333333333333d0 / x) + (0.91893853320467d0 + (log(x) * (-0.5d0)))
else
tmp = x * (log(x) + (-1.0d0))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= 1.05) {
tmp = (0.083333333333333 / x) + (0.91893853320467 + (Math.log(x) * -0.5));
} else {
tmp = x * (Math.log(x) + -1.0);
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= 1.05: tmp = (0.083333333333333 / x) + (0.91893853320467 + (math.log(x) * -0.5)) else: tmp = x * (math.log(x) + -1.0) return tmp
function code(x, y, z) tmp = 0.0 if (x <= 1.05) tmp = Float64(Float64(0.083333333333333 / x) + Float64(0.91893853320467 + Float64(log(x) * -0.5))); else tmp = Float64(x * Float64(log(x) + -1.0)); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= 1.05) tmp = (0.083333333333333 / x) + (0.91893853320467 + (log(x) * -0.5)); else tmp = x * (log(x) + -1.0); end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, 1.05], N[(N[(0.083333333333333 / x), $MachinePrecision] + N[(0.91893853320467 + N[(N[Log[x], $MachinePrecision] * -0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[Log[x], $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 1.05:\\
\;\;\;\;\frac{0.083333333333333}{x} + \left(0.91893853320467 + \log x \cdot -0.5\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(\log x + -1\right)\\
\end{array}
\end{array}
if x < 1.05000000000000004Initial program 99.7%
Taylor expanded in z around 0 50.9%
Taylor expanded in x around 0 49.3%
+-commutative49.3%
Simplified49.3%
if 1.05000000000000004 < x Initial program 83.1%
associate-+l+83.1%
fma-neg83.2%
sub-neg83.2%
metadata-eval83.2%
fma-def83.2%
fma-neg83.2%
metadata-eval83.2%
Simplified83.2%
Taylor expanded in z around 0 70.2%
Taylor expanded in x around inf 68.5%
sub-neg68.5%
mul-1-neg68.5%
log-rec68.5%
remove-double-neg68.5%
metadata-eval68.5%
Simplified68.5%
Final simplification58.7%
(FPCore (x y z) :precision binary64 (+ (+ (- (* (- x 0.5) (log x)) x) 0.91893853320467) (/ 0.083333333333333 x)))
double code(double x, double y, double z) {
return ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + (0.083333333333333 / x);
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = ((((x - 0.5d0) * log(x)) - x) + 0.91893853320467d0) + (0.083333333333333d0 / x)
end function
public static double code(double x, double y, double z) {
return ((((x - 0.5) * Math.log(x)) - x) + 0.91893853320467) + (0.083333333333333 / x);
}
def code(x, y, z): return ((((x - 0.5) * math.log(x)) - x) + 0.91893853320467) + (0.083333333333333 / x)
function code(x, y, z) return Float64(Float64(Float64(Float64(Float64(x - 0.5) * log(x)) - x) + 0.91893853320467) + Float64(0.083333333333333 / x)) end
function tmp = code(x, y, z) tmp = ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + (0.083333333333333 / x); end
code[x_, y_, z_] := N[(N[(N[(N[(N[(x - 0.5), $MachinePrecision] * N[Log[x], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision] + 0.91893853320467), $MachinePrecision] + N[(0.083333333333333 / x), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{0.083333333333333}{x}
\end{array}
Initial program 91.6%
Taylor expanded in z around 0 60.3%
Final simplification60.3%
(FPCore (x y z) :precision binary64 (+ (/ 0.083333333333333 x) (+ 0.91893853320467 (- (* x (log x)) x))))
double code(double x, double y, double z) {
return (0.083333333333333 / x) + (0.91893853320467 + ((x * log(x)) - x));
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = (0.083333333333333d0 / x) + (0.91893853320467d0 + ((x * log(x)) - x))
end function
public static double code(double x, double y, double z) {
return (0.083333333333333 / x) + (0.91893853320467 + ((x * Math.log(x)) - x));
}
def code(x, y, z): return (0.083333333333333 / x) + (0.91893853320467 + ((x * math.log(x)) - x))
function code(x, y, z) return Float64(Float64(0.083333333333333 / x) + Float64(0.91893853320467 + Float64(Float64(x * log(x)) - x))) end
function tmp = code(x, y, z) tmp = (0.083333333333333 / x) + (0.91893853320467 + ((x * log(x)) - x)); end
code[x_, y_, z_] := N[(N[(0.083333333333333 / x), $MachinePrecision] + N[(0.91893853320467 + N[(N[(x * N[Log[x], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{0.083333333333333}{x} + \left(0.91893853320467 + \left(x \cdot \log x - x\right)\right)
\end{array}
Initial program 91.6%
Taylor expanded in z around 0 60.3%
Taylor expanded in x around inf 57.9%
mul-1-neg57.9%
distribute-rgt-neg-in57.9%
log-rec57.9%
remove-double-neg57.9%
Simplified57.9%
Final simplification57.9%
(FPCore (x y z) :precision binary64 (* x (+ (log x) -1.0)))
double code(double x, double y, double z) {
return x * (log(x) + -1.0);
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = x * (log(x) + (-1.0d0))
end function
public static double code(double x, double y, double z) {
return x * (Math.log(x) + -1.0);
}
def code(x, y, z): return x * (math.log(x) + -1.0)
function code(x, y, z) return Float64(x * Float64(log(x) + -1.0)) end
function tmp = code(x, y, z) tmp = x * (log(x) + -1.0); end
code[x_, y_, z_] := N[(x * N[(N[Log[x], $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x \cdot \left(\log x + -1\right)
\end{array}
Initial program 91.6%
associate-+l+91.6%
fma-neg91.6%
sub-neg91.6%
metadata-eval91.6%
fma-def91.6%
fma-neg91.6%
metadata-eval91.6%
Simplified91.6%
Taylor expanded in z around 0 60.3%
Taylor expanded in x around inf 34.2%
sub-neg34.2%
mul-1-neg34.2%
log-rec34.2%
remove-double-neg34.2%
metadata-eval34.2%
Simplified34.2%
Final simplification34.2%
(FPCore (x y z) :precision binary64 (+ (+ (+ (* (- x 0.5) (log x)) (- 0.91893853320467 x)) (/ 0.083333333333333 x)) (* (/ z x) (- (* z (+ y 0.0007936500793651)) 0.0027777777777778))))
double code(double x, double y, double z) {
return ((((x - 0.5) * log(x)) + (0.91893853320467 - x)) + (0.083333333333333 / x)) + ((z / x) * ((z * (y + 0.0007936500793651)) - 0.0027777777777778));
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = ((((x - 0.5d0) * log(x)) + (0.91893853320467d0 - x)) + (0.083333333333333d0 / x)) + ((z / x) * ((z * (y + 0.0007936500793651d0)) - 0.0027777777777778d0))
end function
public static double code(double x, double y, double z) {
return ((((x - 0.5) * Math.log(x)) + (0.91893853320467 - x)) + (0.083333333333333 / x)) + ((z / x) * ((z * (y + 0.0007936500793651)) - 0.0027777777777778));
}
def code(x, y, z): return ((((x - 0.5) * math.log(x)) + (0.91893853320467 - x)) + (0.083333333333333 / x)) + ((z / x) * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))
function code(x, y, z) return Float64(Float64(Float64(Float64(Float64(x - 0.5) * log(x)) + Float64(0.91893853320467 - x)) + Float64(0.083333333333333 / x)) + Float64(Float64(z / x) * Float64(Float64(z * Float64(y + 0.0007936500793651)) - 0.0027777777777778))) end
function tmp = code(x, y, z) tmp = ((((x - 0.5) * log(x)) + (0.91893853320467 - x)) + (0.083333333333333 / x)) + ((z / x) * ((z * (y + 0.0007936500793651)) - 0.0027777777777778)); end
code[x_, y_, z_] := N[(N[(N[(N[(N[(x - 0.5), $MachinePrecision] * N[Log[x], $MachinePrecision]), $MachinePrecision] + N[(0.91893853320467 - x), $MachinePrecision]), $MachinePrecision] + N[(0.083333333333333 / x), $MachinePrecision]), $MachinePrecision] + N[(N[(z / x), $MachinePrecision] * N[(N[(z * N[(y + 0.0007936500793651), $MachinePrecision]), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(\left(x - 0.5\right) \cdot \log x + \left(0.91893853320467 - x\right)\right) + \frac{0.083333333333333}{x}\right) + \frac{z}{x} \cdot \left(z \cdot \left(y + 0.0007936500793651\right) - 0.0027777777777778\right)
\end{array}
herbie shell --seed 2024020
(FPCore (x y z)
:name "Numeric.SpecFunctions:$slogFactorial from math-functions-0.1.5.2, B"
:precision binary64
:herbie-target
(+ (+ (+ (* (- x 0.5) (log x)) (- 0.91893853320467 x)) (/ 0.083333333333333 x)) (* (/ z x) (- (* z (+ y 0.0007936500793651)) 0.0027777777777778)))
(+ (+ (- (* (- x 0.5) (log x)) x) 0.91893853320467) (/ (+ (* (- (* (+ y 0.0007936500793651) z) 0.0027777777777778) z) 0.083333333333333) x)))