
(FPCore (x y) :precision binary64 (+ (- (* x (- y 1.0)) (* y 0.5)) 0.918938533204673))
double code(double x, double y) {
return ((x * (y - 1.0)) - (y * 0.5)) + 0.918938533204673;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = ((x * (y - 1.0d0)) - (y * 0.5d0)) + 0.918938533204673d0
end function
public static double code(double x, double y) {
return ((x * (y - 1.0)) - (y * 0.5)) + 0.918938533204673;
}
def code(x, y): return ((x * (y - 1.0)) - (y * 0.5)) + 0.918938533204673
function code(x, y) return Float64(Float64(Float64(x * Float64(y - 1.0)) - Float64(y * 0.5)) + 0.918938533204673) end
function tmp = code(x, y) tmp = ((x * (y - 1.0)) - (y * 0.5)) + 0.918938533204673; end
code[x_, y_] := N[(N[(N[(x * N[(y - 1.0), $MachinePrecision]), $MachinePrecision] - N[(y * 0.5), $MachinePrecision]), $MachinePrecision] + 0.918938533204673), $MachinePrecision]
\begin{array}{l}
\\
\left(x \cdot \left(y - 1\right) - y \cdot 0.5\right) + 0.918938533204673
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 10 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y) :precision binary64 (+ (- (* x (- y 1.0)) (* y 0.5)) 0.918938533204673))
double code(double x, double y) {
return ((x * (y - 1.0)) - (y * 0.5)) + 0.918938533204673;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = ((x * (y - 1.0d0)) - (y * 0.5d0)) + 0.918938533204673d0
end function
public static double code(double x, double y) {
return ((x * (y - 1.0)) - (y * 0.5)) + 0.918938533204673;
}
def code(x, y): return ((x * (y - 1.0)) - (y * 0.5)) + 0.918938533204673
function code(x, y) return Float64(Float64(Float64(x * Float64(y - 1.0)) - Float64(y * 0.5)) + 0.918938533204673) end
function tmp = code(x, y) tmp = ((x * (y - 1.0)) - (y * 0.5)) + 0.918938533204673; end
code[x_, y_] := N[(N[(N[(x * N[(y - 1.0), $MachinePrecision]), $MachinePrecision] - N[(y * 0.5), $MachinePrecision]), $MachinePrecision] + 0.918938533204673), $MachinePrecision]
\begin{array}{l}
\\
\left(x \cdot \left(y - 1\right) - y \cdot 0.5\right) + 0.918938533204673
\end{array}
(FPCore (x y) :precision binary64 (- 0.918938533204673 (fma y (- 0.5 x) x)))
double code(double x, double y) {
return 0.918938533204673 - fma(y, (0.5 - x), x);
}
function code(x, y) return Float64(0.918938533204673 - fma(y, Float64(0.5 - x), x)) end
code[x_, y_] := N[(0.918938533204673 - N[(y * N[(0.5 - x), $MachinePrecision] + x), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
0.918938533204673 - \mathsf{fma}\left(y, 0.5 - x, x\right)
\end{array}
Initial program 100.0%
Taylor expanded in x around 0
Applied rewrites100.0%
(FPCore (x y) :precision binary64 (let* ((t_0 (- (* x (+ y -1.0)) (* y 0.5)))) (if (<= t_0 -2e+28) (- x) (if (<= t_0 200.0) 0.918938533204673 (- x)))))
double code(double x, double y) {
double t_0 = (x * (y + -1.0)) - (y * 0.5);
double tmp;
if (t_0 <= -2e+28) {
tmp = -x;
} else if (t_0 <= 200.0) {
tmp = 0.918938533204673;
} else {
tmp = -x;
}
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 = (x * (y + (-1.0d0))) - (y * 0.5d0)
if (t_0 <= (-2d+28)) then
tmp = -x
else if (t_0 <= 200.0d0) then
tmp = 0.918938533204673d0
else
tmp = -x
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = (x * (y + -1.0)) - (y * 0.5);
double tmp;
if (t_0 <= -2e+28) {
tmp = -x;
} else if (t_0 <= 200.0) {
tmp = 0.918938533204673;
} else {
tmp = -x;
}
return tmp;
}
def code(x, y): t_0 = (x * (y + -1.0)) - (y * 0.5) tmp = 0 if t_0 <= -2e+28: tmp = -x elif t_0 <= 200.0: tmp = 0.918938533204673 else: tmp = -x return tmp
function code(x, y) t_0 = Float64(Float64(x * Float64(y + -1.0)) - Float64(y * 0.5)) tmp = 0.0 if (t_0 <= -2e+28) tmp = Float64(-x); elseif (t_0 <= 200.0) tmp = 0.918938533204673; else tmp = Float64(-x); end return tmp end
function tmp_2 = code(x, y) t_0 = (x * (y + -1.0)) - (y * 0.5); tmp = 0.0; if (t_0 <= -2e+28) tmp = -x; elseif (t_0 <= 200.0) tmp = 0.918938533204673; else tmp = -x; end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(N[(x * N[(y + -1.0), $MachinePrecision]), $MachinePrecision] - N[(y * 0.5), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$0, -2e+28], (-x), If[LessEqual[t$95$0, 200.0], 0.918938533204673, (-x)]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x \cdot \left(y + -1\right) - y \cdot 0.5\\
\mathbf{if}\;t\_0 \leq -2 \cdot 10^{+28}:\\
\;\;\;\;-x\\
\mathbf{elif}\;t\_0 \leq 200:\\
\;\;\;\;0.918938533204673\\
\mathbf{else}:\\
\;\;\;\;-x\\
\end{array}
\end{array}
if (-.f64 (*.f64 x (-.f64 y #s(literal 1 binary64))) (*.f64 y #s(literal 1/2 binary64))) < -1.99999999999999992e28 or 200 < (-.f64 (*.f64 x (-.f64 y #s(literal 1 binary64))) (*.f64 y #s(literal 1/2 binary64))) Initial program 100.0%
Taylor expanded in x around inf
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
*-commutativeN/A
mul-1-negN/A
unsub-negN/A
lower--.f64N/A
*-commutativeN/A
lower-*.f6463.8
Applied rewrites63.8%
Taylor expanded in y around 0
Applied rewrites34.9%
if -1.99999999999999992e28 < (-.f64 (*.f64 x (-.f64 y #s(literal 1 binary64))) (*.f64 y #s(literal 1/2 binary64))) < 200Initial program 100.0%
Taylor expanded in y around 0
mul-1-negN/A
unsub-negN/A
lower--.f6493.7
Applied rewrites93.7%
Taylor expanded in x around 0
Applied rewrites92.4%
Final simplification49.5%
(FPCore (x y)
:precision binary64
(if (<= y -4e+92)
(* x y)
(if (<= y -5.7e-9)
(fma -0.5 y 0.918938533204673)
(if (<= y 6.8e-7)
(- 0.918938533204673 x)
(fma -0.5 y 0.918938533204673)))))
double code(double x, double y) {
double tmp;
if (y <= -4e+92) {
tmp = x * y;
} else if (y <= -5.7e-9) {
tmp = fma(-0.5, y, 0.918938533204673);
} else if (y <= 6.8e-7) {
tmp = 0.918938533204673 - x;
} else {
tmp = fma(-0.5, y, 0.918938533204673);
}
return tmp;
}
function code(x, y) tmp = 0.0 if (y <= -4e+92) tmp = Float64(x * y); elseif (y <= -5.7e-9) tmp = fma(-0.5, y, 0.918938533204673); elseif (y <= 6.8e-7) tmp = Float64(0.918938533204673 - x); else tmp = fma(-0.5, y, 0.918938533204673); end return tmp end
code[x_, y_] := If[LessEqual[y, -4e+92], N[(x * y), $MachinePrecision], If[LessEqual[y, -5.7e-9], N[(-0.5 * y + 0.918938533204673), $MachinePrecision], If[LessEqual[y, 6.8e-7], N[(0.918938533204673 - x), $MachinePrecision], N[(-0.5 * y + 0.918938533204673), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4 \cdot 10^{+92}:\\
\;\;\;\;x \cdot y\\
\mathbf{elif}\;y \leq -5.7 \cdot 10^{-9}:\\
\;\;\;\;\mathsf{fma}\left(-0.5, y, 0.918938533204673\right)\\
\mathbf{elif}\;y \leq 6.8 \cdot 10^{-7}:\\
\;\;\;\;0.918938533204673 - x\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(-0.5, y, 0.918938533204673\right)\\
\end{array}
\end{array}
if y < -4.0000000000000002e92Initial program 100.0%
Taylor expanded in x around inf
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
*-commutativeN/A
mul-1-negN/A
unsub-negN/A
lower--.f64N/A
*-commutativeN/A
lower-*.f6459.4
Applied rewrites59.4%
Taylor expanded in y around inf
Applied rewrites59.4%
if -4.0000000000000002e92 < y < -5.6999999999999998e-9 or 6.79999999999999948e-7 < y Initial program 100.0%
Taylor expanded in x around 0
sub-negN/A
+-commutativeN/A
distribute-lft-neg-inN/A
metadata-evalN/A
lower-fma.f6466.5
Applied rewrites66.5%
if -5.6999999999999998e-9 < y < 6.79999999999999948e-7Initial program 100.0%
Taylor expanded in y around 0
mul-1-negN/A
unsub-negN/A
lower--.f6499.1
Applied rewrites99.1%
Final simplification80.8%
(FPCore (x y) :precision binary64 (if (<= x -0.76) (- (* x y) x) (if (<= x 0.85) (fma -0.5 y 0.918938533204673) (fma y x (- x)))))
double code(double x, double y) {
double tmp;
if (x <= -0.76) {
tmp = (x * y) - x;
} else if (x <= 0.85) {
tmp = fma(-0.5, y, 0.918938533204673);
} else {
tmp = fma(y, x, -x);
}
return tmp;
}
function code(x, y) tmp = 0.0 if (x <= -0.76) tmp = Float64(Float64(x * y) - x); elseif (x <= 0.85) tmp = fma(-0.5, y, 0.918938533204673); else tmp = fma(y, x, Float64(-x)); end return tmp end
code[x_, y_] := If[LessEqual[x, -0.76], N[(N[(x * y), $MachinePrecision] - x), $MachinePrecision], If[LessEqual[x, 0.85], N[(-0.5 * y + 0.918938533204673), $MachinePrecision], N[(y * x + (-x)), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -0.76:\\
\;\;\;\;x \cdot y - x\\
\mathbf{elif}\;x \leq 0.85:\\
\;\;\;\;\mathsf{fma}\left(-0.5, y, 0.918938533204673\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(y, x, -x\right)\\
\end{array}
\end{array}
if x < -0.76000000000000001Initial program 100.0%
Taylor expanded in x around inf
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
*-commutativeN/A
mul-1-negN/A
unsub-negN/A
lower--.f64N/A
*-commutativeN/A
lower-*.f6499.5
Applied rewrites99.5%
if -0.76000000000000001 < x < 0.849999999999999978Initial program 100.0%
Taylor expanded in x around 0
sub-negN/A
+-commutativeN/A
distribute-lft-neg-inN/A
metadata-evalN/A
lower-fma.f6498.1
Applied rewrites98.1%
if 0.849999999999999978 < x Initial program 100.0%
Taylor expanded in x around inf
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
*-commutativeN/A
mul-1-negN/A
unsub-negN/A
lower--.f64N/A
*-commutativeN/A
lower-*.f6498.9
Applied rewrites98.9%
Applied rewrites98.9%
Final simplification98.6%
(FPCore (x y) :precision binary64 (let* ((t_0 (- (* x y) x))) (if (<= x -0.76) t_0 (if (<= x 0.85) (fma -0.5 y 0.918938533204673) t_0))))
double code(double x, double y) {
double t_0 = (x * y) - x;
double tmp;
if (x <= -0.76) {
tmp = t_0;
} else if (x <= 0.85) {
tmp = fma(-0.5, y, 0.918938533204673);
} else {
tmp = t_0;
}
return tmp;
}
function code(x, y) t_0 = Float64(Float64(x * y) - x) tmp = 0.0 if (x <= -0.76) tmp = t_0; elseif (x <= 0.85) tmp = fma(-0.5, y, 0.918938533204673); else tmp = t_0; end return tmp end
code[x_, y_] := Block[{t$95$0 = N[(N[(x * y), $MachinePrecision] - x), $MachinePrecision]}, If[LessEqual[x, -0.76], t$95$0, If[LessEqual[x, 0.85], N[(-0.5 * y + 0.918938533204673), $MachinePrecision], t$95$0]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x \cdot y - x\\
\mathbf{if}\;x \leq -0.76:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;x \leq 0.85:\\
\;\;\;\;\mathsf{fma}\left(-0.5, y, 0.918938533204673\right)\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if x < -0.76000000000000001 or 0.849999999999999978 < x Initial program 100.0%
Taylor expanded in x around inf
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
*-commutativeN/A
mul-1-negN/A
unsub-negN/A
lower--.f64N/A
*-commutativeN/A
lower-*.f6499.2
Applied rewrites99.2%
if -0.76000000000000001 < x < 0.849999999999999978Initial program 100.0%
Taylor expanded in x around 0
sub-negN/A
+-commutativeN/A
distribute-lft-neg-inN/A
metadata-evalN/A
lower-fma.f6498.1
Applied rewrites98.1%
Final simplification98.6%
(FPCore (x y) :precision binary64 (let* ((t_0 (* y (+ x -0.5)))) (if (<= y -1.5) t_0 (if (<= y 1.4) (- 0.918938533204673 x) t_0))))
double code(double x, double y) {
double t_0 = y * (x + -0.5);
double tmp;
if (y <= -1.5) {
tmp = t_0;
} else if (y <= 1.4) {
tmp = 0.918938533204673 - x;
} 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 = y * (x + (-0.5d0))
if (y <= (-1.5d0)) then
tmp = t_0
else if (y <= 1.4d0) then
tmp = 0.918938533204673d0 - x
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = y * (x + -0.5);
double tmp;
if (y <= -1.5) {
tmp = t_0;
} else if (y <= 1.4) {
tmp = 0.918938533204673 - x;
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y): t_0 = y * (x + -0.5) tmp = 0 if y <= -1.5: tmp = t_0 elif y <= 1.4: tmp = 0.918938533204673 - x else: tmp = t_0 return tmp
function code(x, y) t_0 = Float64(y * Float64(x + -0.5)) tmp = 0.0 if (y <= -1.5) tmp = t_0; elseif (y <= 1.4) tmp = Float64(0.918938533204673 - x); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y) t_0 = y * (x + -0.5); tmp = 0.0; if (y <= -1.5) tmp = t_0; elseif (y <= 1.4) tmp = 0.918938533204673 - x; else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(y * N[(x + -0.5), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.5], t$95$0, If[LessEqual[y, 1.4], N[(0.918938533204673 - x), $MachinePrecision], t$95$0]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := y \cdot \left(x + -0.5\right)\\
\mathbf{if}\;y \leq -1.5:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;y \leq 1.4:\\
\;\;\;\;0.918938533204673 - x\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if y < -1.5 or 1.3999999999999999 < y Initial program 100.0%
Taylor expanded in y around inf
sub-negN/A
remove-double-negN/A
mul-1-negN/A
distribute-neg-inN/A
+-commutativeN/A
lower-*.f64N/A
distribute-neg-inN/A
metadata-evalN/A
mul-1-negN/A
remove-double-negN/A
lower-+.f6499.0
Applied rewrites99.0%
if -1.5 < y < 1.3999999999999999Initial program 100.0%
Taylor expanded in y around 0
mul-1-negN/A
unsub-negN/A
lower--.f6496.6
Applied rewrites96.6%
Final simplification97.8%
(FPCore (x y) :precision binary64 (if (<= y -700.0) (* x y) (if (<= y 1.82) (- 0.918938533204673 x) (* y -0.5))))
double code(double x, double y) {
double tmp;
if (y <= -700.0) {
tmp = x * y;
} else if (y <= 1.82) {
tmp = 0.918938533204673 - x;
} else {
tmp = y * -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 <= (-700.0d0)) then
tmp = x * y
else if (y <= 1.82d0) then
tmp = 0.918938533204673d0 - x
else
tmp = y * (-0.5d0)
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= -700.0) {
tmp = x * y;
} else if (y <= 1.82) {
tmp = 0.918938533204673 - x;
} else {
tmp = y * -0.5;
}
return tmp;
}
def code(x, y): tmp = 0 if y <= -700.0: tmp = x * y elif y <= 1.82: tmp = 0.918938533204673 - x else: tmp = y * -0.5 return tmp
function code(x, y) tmp = 0.0 if (y <= -700.0) tmp = Float64(x * y); elseif (y <= 1.82) tmp = Float64(0.918938533204673 - x); else tmp = Float64(y * -0.5); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= -700.0) tmp = x * y; elseif (y <= 1.82) tmp = 0.918938533204673 - x; else tmp = y * -0.5; end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, -700.0], N[(x * y), $MachinePrecision], If[LessEqual[y, 1.82], N[(0.918938533204673 - x), $MachinePrecision], N[(y * -0.5), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -700:\\
\;\;\;\;x \cdot y\\
\mathbf{elif}\;y \leq 1.82:\\
\;\;\;\;0.918938533204673 - x\\
\mathbf{else}:\\
\;\;\;\;y \cdot -0.5\\
\end{array}
\end{array}
if y < -700Initial program 100.0%
Taylor expanded in x around inf
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
*-commutativeN/A
mul-1-negN/A
unsub-negN/A
lower--.f64N/A
*-commutativeN/A
lower-*.f6455.5
Applied rewrites55.5%
Taylor expanded in y around inf
Applied rewrites55.5%
if -700 < y < 1.82000000000000006Initial program 100.0%
Taylor expanded in y around 0
mul-1-negN/A
unsub-negN/A
lower--.f6496.0
Applied rewrites96.0%
if 1.82000000000000006 < y Initial program 100.0%
Taylor expanded in y around inf
sub-negN/A
remove-double-negN/A
mul-1-negN/A
distribute-neg-inN/A
+-commutativeN/A
lower-*.f64N/A
distribute-neg-inN/A
metadata-evalN/A
mul-1-negN/A
remove-double-negN/A
lower-+.f6499.1
Applied rewrites99.1%
Taylor expanded in x around 0
Applied rewrites65.2%
Final simplification78.5%
(FPCore (x y) :precision binary64 (if (<= y -700.0) (* x y) (if (<= y 1.4) (- 0.918938533204673 x) (* x y))))
double code(double x, double y) {
double tmp;
if (y <= -700.0) {
tmp = x * y;
} else if (y <= 1.4) {
tmp = 0.918938533204673 - x;
} else {
tmp = x * y;
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= (-700.0d0)) then
tmp = x * y
else if (y <= 1.4d0) then
tmp = 0.918938533204673d0 - x
else
tmp = x * y
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= -700.0) {
tmp = x * y;
} else if (y <= 1.4) {
tmp = 0.918938533204673 - x;
} else {
tmp = x * y;
}
return tmp;
}
def code(x, y): tmp = 0 if y <= -700.0: tmp = x * y elif y <= 1.4: tmp = 0.918938533204673 - x else: tmp = x * y return tmp
function code(x, y) tmp = 0.0 if (y <= -700.0) tmp = Float64(x * y); elseif (y <= 1.4) tmp = Float64(0.918938533204673 - x); else tmp = Float64(x * y); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= -700.0) tmp = x * y; elseif (y <= 1.4) tmp = 0.918938533204673 - x; else tmp = x * y; end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, -700.0], N[(x * y), $MachinePrecision], If[LessEqual[y, 1.4], N[(0.918938533204673 - x), $MachinePrecision], N[(x * y), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -700:\\
\;\;\;\;x \cdot y\\
\mathbf{elif}\;y \leq 1.4:\\
\;\;\;\;0.918938533204673 - x\\
\mathbf{else}:\\
\;\;\;\;x \cdot y\\
\end{array}
\end{array}
if y < -700 or 1.3999999999999999 < y Initial program 100.0%
Taylor expanded in x around inf
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
*-commutativeN/A
mul-1-negN/A
unsub-negN/A
lower--.f64N/A
*-commutativeN/A
lower-*.f6445.5
Applied rewrites45.5%
Taylor expanded in y around inf
Applied rewrites45.0%
if -700 < y < 1.3999999999999999Initial program 100.0%
Taylor expanded in y around 0
mul-1-negN/A
unsub-negN/A
lower--.f6496.0
Applied rewrites96.0%
Final simplification70.7%
(FPCore (x y) :precision binary64 (- 0.918938533204673 x))
double code(double x, double y) {
return 0.918938533204673 - x;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = 0.918938533204673d0 - x
end function
public static double code(double x, double y) {
return 0.918938533204673 - x;
}
def code(x, y): return 0.918938533204673 - x
function code(x, y) return Float64(0.918938533204673 - x) end
function tmp = code(x, y) tmp = 0.918938533204673 - x; end
code[x_, y_] := N[(0.918938533204673 - x), $MachinePrecision]
\begin{array}{l}
\\
0.918938533204673 - x
\end{array}
Initial program 100.0%
Taylor expanded in y around 0
mul-1-negN/A
unsub-negN/A
lower--.f6449.8
Applied rewrites49.8%
(FPCore (x y) :precision binary64 0.918938533204673)
double code(double x, double y) {
return 0.918938533204673;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = 0.918938533204673d0
end function
public static double code(double x, double y) {
return 0.918938533204673;
}
def code(x, y): return 0.918938533204673
function code(x, y) return 0.918938533204673 end
function tmp = code(x, y) tmp = 0.918938533204673; end
code[x_, y_] := 0.918938533204673
\begin{array}{l}
\\
0.918938533204673
\end{array}
Initial program 100.0%
Taylor expanded in y around 0
mul-1-negN/A
unsub-negN/A
lower--.f6449.8
Applied rewrites49.8%
Taylor expanded in x around 0
Applied rewrites25.5%
herbie shell --seed 2024238
(FPCore (x y)
:name "Numeric.SpecFunctions:logGamma from math-functions-0.1.5.2, A"
:precision binary64
(+ (- (* x (- y 1.0)) (* y 0.5)) 0.918938533204673))