
(FPCore (x y z) :precision binary64 (+ (* x y) (* (- 1.0 x) z)))
double code(double x, double y, double z) {
return (x * y) + ((1.0 - x) * z);
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = (x * y) + ((1.0d0 - x) * z)
end function
public static double code(double x, double y, double z) {
return (x * y) + ((1.0 - x) * z);
}
def code(x, y, z): return (x * y) + ((1.0 - x) * z)
function code(x, y, z) return Float64(Float64(x * y) + Float64(Float64(1.0 - x) * z)) end
function tmp = code(x, y, z) tmp = (x * y) + ((1.0 - x) * z); end
code[x_, y_, z_] := N[(N[(x * y), $MachinePrecision] + N[(N[(1.0 - x), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x \cdot y + \left(1 - x\right) \cdot z
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 7 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z) :precision binary64 (+ (* x y) (* (- 1.0 x) z)))
double code(double x, double y, double z) {
return (x * y) + ((1.0 - x) * z);
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = (x * y) + ((1.0d0 - x) * z)
end function
public static double code(double x, double y, double z) {
return (x * y) + ((1.0 - x) * z);
}
def code(x, y, z): return (x * y) + ((1.0 - x) * z)
function code(x, y, z) return Float64(Float64(x * y) + Float64(Float64(1.0 - x) * z)) end
function tmp = code(x, y, z) tmp = (x * y) + ((1.0 - x) * z); end
code[x_, y_, z_] := N[(N[(x * y), $MachinePrecision] + N[(N[(1.0 - x), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x \cdot y + \left(1 - x\right) \cdot z
\end{array}
(FPCore (x y z) :precision binary64 (+ z (* (- y z) x)))
double code(double x, double y, double z) {
return z + ((y - z) * x);
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = z + ((y - z) * x)
end function
public static double code(double x, double y, double z) {
return z + ((y - z) * x);
}
def code(x, y, z): return z + ((y - z) * x)
function code(x, y, z) return Float64(z + Float64(Float64(y - z) * x)) end
function tmp = code(x, y, z) tmp = z + ((y - z) * x); end
code[x_, y_, z_] := N[(z + N[(N[(y - z), $MachinePrecision] * x), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
z + \left(y - z\right) \cdot x
\end{array}
Initial program 96.1%
sub-neg96.1%
+-commutative96.1%
distribute-lft1-in96.1%
associate-+r+96.1%
+-commutative96.1%
*-commutative96.1%
neg-mul-196.1%
associate-*r*96.1%
*-commutative96.1%
distribute-rgt-out100.0%
fma-def100.0%
+-commutative100.0%
*-commutative100.0%
neg-mul-1100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in x around 0 100.0%
Final simplification100.0%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* z (- x))))
(if (<= x -4.2e+155)
(* y x)
(if (<= x -250.0)
t_0
(if (<= x -1.55e-114)
z
(if (<= x -6e-128)
(* y x)
(if (<= x 2.7e-44)
z
(if (or (<= x 4.1e+111)
(and (not (<= x 1.22e+219)) (<= x 4e+254)))
(* y x)
t_0))))))))
double code(double x, double y, double z) {
double t_0 = z * -x;
double tmp;
if (x <= -4.2e+155) {
tmp = y * x;
} else if (x <= -250.0) {
tmp = t_0;
} else if (x <= -1.55e-114) {
tmp = z;
} else if (x <= -6e-128) {
tmp = y * x;
} else if (x <= 2.7e-44) {
tmp = z;
} else if ((x <= 4.1e+111) || (!(x <= 1.22e+219) && (x <= 4e+254))) {
tmp = y * x;
} 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) :: tmp
t_0 = z * -x
if (x <= (-4.2d+155)) then
tmp = y * x
else if (x <= (-250.0d0)) then
tmp = t_0
else if (x <= (-1.55d-114)) then
tmp = z
else if (x <= (-6d-128)) then
tmp = y * x
else if (x <= 2.7d-44) then
tmp = z
else if ((x <= 4.1d+111) .or. (.not. (x <= 1.22d+219)) .and. (x <= 4d+254)) then
tmp = y * x
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = z * -x;
double tmp;
if (x <= -4.2e+155) {
tmp = y * x;
} else if (x <= -250.0) {
tmp = t_0;
} else if (x <= -1.55e-114) {
tmp = z;
} else if (x <= -6e-128) {
tmp = y * x;
} else if (x <= 2.7e-44) {
tmp = z;
} else if ((x <= 4.1e+111) || (!(x <= 1.22e+219) && (x <= 4e+254))) {
tmp = y * x;
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = z * -x tmp = 0 if x <= -4.2e+155: tmp = y * x elif x <= -250.0: tmp = t_0 elif x <= -1.55e-114: tmp = z elif x <= -6e-128: tmp = y * x elif x <= 2.7e-44: tmp = z elif (x <= 4.1e+111) or (not (x <= 1.22e+219) and (x <= 4e+254)): tmp = y * x else: tmp = t_0 return tmp
function code(x, y, z) t_0 = Float64(z * Float64(-x)) tmp = 0.0 if (x <= -4.2e+155) tmp = Float64(y * x); elseif (x <= -250.0) tmp = t_0; elseif (x <= -1.55e-114) tmp = z; elseif (x <= -6e-128) tmp = Float64(y * x); elseif (x <= 2.7e-44) tmp = z; elseif ((x <= 4.1e+111) || (!(x <= 1.22e+219) && (x <= 4e+254))) tmp = Float64(y * x); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y, z) t_0 = z * -x; tmp = 0.0; if (x <= -4.2e+155) tmp = y * x; elseif (x <= -250.0) tmp = t_0; elseif (x <= -1.55e-114) tmp = z; elseif (x <= -6e-128) tmp = y * x; elseif (x <= 2.7e-44) tmp = z; elseif ((x <= 4.1e+111) || (~((x <= 1.22e+219)) && (x <= 4e+254))) tmp = y * x; else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(z * (-x)), $MachinePrecision]}, If[LessEqual[x, -4.2e+155], N[(y * x), $MachinePrecision], If[LessEqual[x, -250.0], t$95$0, If[LessEqual[x, -1.55e-114], z, If[LessEqual[x, -6e-128], N[(y * x), $MachinePrecision], If[LessEqual[x, 2.7e-44], z, If[Or[LessEqual[x, 4.1e+111], And[N[Not[LessEqual[x, 1.22e+219]], $MachinePrecision], LessEqual[x, 4e+254]]], N[(y * x), $MachinePrecision], t$95$0]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := z \cdot \left(-x\right)\\
\mathbf{if}\;x \leq -4.2 \cdot 10^{+155}:\\
\;\;\;\;y \cdot x\\
\mathbf{elif}\;x \leq -250:\\
\;\;\;\;t_0\\
\mathbf{elif}\;x \leq -1.55 \cdot 10^{-114}:\\
\;\;\;\;z\\
\mathbf{elif}\;x \leq -6 \cdot 10^{-128}:\\
\;\;\;\;y \cdot x\\
\mathbf{elif}\;x \leq 2.7 \cdot 10^{-44}:\\
\;\;\;\;z\\
\mathbf{elif}\;x \leq 4.1 \cdot 10^{+111} \lor \neg \left(x \leq 1.22 \cdot 10^{+219}\right) \land x \leq 4 \cdot 10^{+254}:\\
\;\;\;\;y \cdot x\\
\mathbf{else}:\\
\;\;\;\;t_0\\
\end{array}
\end{array}
if x < -4.2e155 or -1.55e-114 < x < -5.99999999999999956e-128 or 2.6999999999999999e-44 < x < 4.09999999999999986e111 or 1.22000000000000004e219 < x < 3.9999999999999997e254Initial program 89.6%
Taylor expanded in y around inf 73.7%
if -4.2e155 < x < -250 or 4.09999999999999986e111 < x < 1.22000000000000004e219 or 3.9999999999999997e254 < x Initial program 95.3%
sub-neg95.3%
+-commutative95.3%
distribute-lft1-in95.3%
associate-+r+95.3%
+-commutative95.3%
*-commutative95.3%
neg-mul-195.3%
associate-*r*95.3%
*-commutative95.3%
distribute-rgt-out100.0%
fma-def100.0%
+-commutative100.0%
*-commutative100.0%
neg-mul-1100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in x around inf 99.1%
Taylor expanded in y around 0 67.3%
mul-1-neg67.3%
distribute-rgt-neg-in67.3%
Simplified67.3%
if -250 < x < -1.55e-114 or -5.99999999999999956e-128 < x < 2.6999999999999999e-44Initial program 100.0%
Taylor expanded in x around 0 80.5%
Final simplification75.4%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* (- y z) x)))
(if (<= x -2.3e-45)
t_0
(if (<= x -1.85e-115)
z
(if (<= x -6e-128) (* y x) (if (<= x 3e-44) (* z (- 1.0 x)) t_0))))))
double code(double x, double y, double z) {
double t_0 = (y - z) * x;
double tmp;
if (x <= -2.3e-45) {
tmp = t_0;
} else if (x <= -1.85e-115) {
tmp = z;
} else if (x <= -6e-128) {
tmp = y * x;
} else if (x <= 3e-44) {
tmp = z * (1.0 - x);
} 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) :: tmp
t_0 = (y - z) * x
if (x <= (-2.3d-45)) then
tmp = t_0
else if (x <= (-1.85d-115)) then
tmp = z
else if (x <= (-6d-128)) then
tmp = y * x
else if (x <= 3d-44) then
tmp = z * (1.0d0 - x)
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = (y - z) * x;
double tmp;
if (x <= -2.3e-45) {
tmp = t_0;
} else if (x <= -1.85e-115) {
tmp = z;
} else if (x <= -6e-128) {
tmp = y * x;
} else if (x <= 3e-44) {
tmp = z * (1.0 - x);
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = (y - z) * x tmp = 0 if x <= -2.3e-45: tmp = t_0 elif x <= -1.85e-115: tmp = z elif x <= -6e-128: tmp = y * x elif x <= 3e-44: tmp = z * (1.0 - x) else: tmp = t_0 return tmp
function code(x, y, z) t_0 = Float64(Float64(y - z) * x) tmp = 0.0 if (x <= -2.3e-45) tmp = t_0; elseif (x <= -1.85e-115) tmp = z; elseif (x <= -6e-128) tmp = Float64(y * x); elseif (x <= 3e-44) tmp = Float64(z * Float64(1.0 - x)); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y, z) t_0 = (y - z) * x; tmp = 0.0; if (x <= -2.3e-45) tmp = t_0; elseif (x <= -1.85e-115) tmp = z; elseif (x <= -6e-128) tmp = y * x; elseif (x <= 3e-44) tmp = z * (1.0 - x); else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(N[(y - z), $MachinePrecision] * x), $MachinePrecision]}, If[LessEqual[x, -2.3e-45], t$95$0, If[LessEqual[x, -1.85e-115], z, If[LessEqual[x, -6e-128], N[(y * x), $MachinePrecision], If[LessEqual[x, 3e-44], N[(z * N[(1.0 - x), $MachinePrecision]), $MachinePrecision], t$95$0]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \left(y - z\right) \cdot x\\
\mathbf{if}\;x \leq -2.3 \cdot 10^{-45}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;x \leq -1.85 \cdot 10^{-115}:\\
\;\;\;\;z\\
\mathbf{elif}\;x \leq -6 \cdot 10^{-128}:\\
\;\;\;\;y \cdot x\\
\mathbf{elif}\;x \leq 3 \cdot 10^{-44}:\\
\;\;\;\;z \cdot \left(1 - x\right)\\
\mathbf{else}:\\
\;\;\;\;t_0\\
\end{array}
\end{array}
if x < -2.29999999999999992e-45 or 3.0000000000000002e-44 < x Initial program 92.5%
sub-neg92.5%
+-commutative92.5%
distribute-lft1-in92.5%
associate-+r+92.5%
+-commutative92.5%
*-commutative92.5%
neg-mul-192.5%
associate-*r*92.5%
*-commutative92.5%
distribute-rgt-out100.0%
fma-def100.0%
+-commutative100.0%
*-commutative100.0%
neg-mul-1100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in x around inf 96.8%
if -2.29999999999999992e-45 < x < -1.85e-115Initial program 100.0%
Taylor expanded in x around 0 91.6%
if -1.85e-115 < x < -5.99999999999999956e-128Initial program 100.0%
Taylor expanded in y around inf 100.0%
if -5.99999999999999956e-128 < x < 3.0000000000000002e-44Initial program 100.0%
Taylor expanded in y around 0 82.8%
Final simplification90.8%
(FPCore (x y z)
:precision binary64
(if (<= x -1.25e-19)
(* y x)
(if (<= x -1.85e-115)
z
(if (<= x -6e-128) (* y x) (if (<= x 8.5e-43) z (* y x))))))
double code(double x, double y, double z) {
double tmp;
if (x <= -1.25e-19) {
tmp = y * x;
} else if (x <= -1.85e-115) {
tmp = z;
} else if (x <= -6e-128) {
tmp = y * x;
} else if (x <= 8.5e-43) {
tmp = z;
} else {
tmp = 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) :: tmp
if (x <= (-1.25d-19)) then
tmp = y * x
else if (x <= (-1.85d-115)) then
tmp = z
else if (x <= (-6d-128)) then
tmp = y * x
else if (x <= 8.5d-43) then
tmp = z
else
tmp = y * x
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= -1.25e-19) {
tmp = y * x;
} else if (x <= -1.85e-115) {
tmp = z;
} else if (x <= -6e-128) {
tmp = y * x;
} else if (x <= 8.5e-43) {
tmp = z;
} else {
tmp = y * x;
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= -1.25e-19: tmp = y * x elif x <= -1.85e-115: tmp = z elif x <= -6e-128: tmp = y * x elif x <= 8.5e-43: tmp = z else: tmp = y * x return tmp
function code(x, y, z) tmp = 0.0 if (x <= -1.25e-19) tmp = Float64(y * x); elseif (x <= -1.85e-115) tmp = z; elseif (x <= -6e-128) tmp = Float64(y * x); elseif (x <= 8.5e-43) tmp = z; else tmp = Float64(y * x); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= -1.25e-19) tmp = y * x; elseif (x <= -1.85e-115) tmp = z; elseif (x <= -6e-128) tmp = y * x; elseif (x <= 8.5e-43) tmp = z; else tmp = y * x; end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, -1.25e-19], N[(y * x), $MachinePrecision], If[LessEqual[x, -1.85e-115], z, If[LessEqual[x, -6e-128], N[(y * x), $MachinePrecision], If[LessEqual[x, 8.5e-43], z, N[(y * x), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.25 \cdot 10^{-19}:\\
\;\;\;\;y \cdot x\\
\mathbf{elif}\;x \leq -1.85 \cdot 10^{-115}:\\
\;\;\;\;z\\
\mathbf{elif}\;x \leq -6 \cdot 10^{-128}:\\
\;\;\;\;y \cdot x\\
\mathbf{elif}\;x \leq 8.5 \cdot 10^{-43}:\\
\;\;\;\;z\\
\mathbf{else}:\\
\;\;\;\;y \cdot x\\
\end{array}
\end{array}
if x < -1.2500000000000001e-19 or -1.85e-115 < x < -5.99999999999999956e-128 or 8.50000000000000056e-43 < x Initial program 92.6%
Taylor expanded in y around inf 57.4%
if -1.2500000000000001e-19 < x < -1.85e-115 or -5.99999999999999956e-128 < x < 8.50000000000000056e-43Initial program 100.0%
Taylor expanded in x around 0 83.2%
Final simplification69.5%
(FPCore (x y z) :precision binary64 (if (or (<= z -1.3e-140) (not (<= z 1.05e-101))) (* z (- 1.0 x)) (* y x)))
double code(double x, double y, double z) {
double tmp;
if ((z <= -1.3e-140) || !(z <= 1.05e-101)) {
tmp = z * (1.0 - x);
} else {
tmp = 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) :: tmp
if ((z <= (-1.3d-140)) .or. (.not. (z <= 1.05d-101))) then
tmp = z * (1.0d0 - x)
else
tmp = y * x
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((z <= -1.3e-140) || !(z <= 1.05e-101)) {
tmp = z * (1.0 - x);
} else {
tmp = y * x;
}
return tmp;
}
def code(x, y, z): tmp = 0 if (z <= -1.3e-140) or not (z <= 1.05e-101): tmp = z * (1.0 - x) else: tmp = y * x return tmp
function code(x, y, z) tmp = 0.0 if ((z <= -1.3e-140) || !(z <= 1.05e-101)) tmp = Float64(z * Float64(1.0 - x)); else tmp = Float64(y * x); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((z <= -1.3e-140) || ~((z <= 1.05e-101))) tmp = z * (1.0 - x); else tmp = y * x; end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[z, -1.3e-140], N[Not[LessEqual[z, 1.05e-101]], $MachinePrecision]], N[(z * N[(1.0 - x), $MachinePrecision]), $MachinePrecision], N[(y * x), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.3 \cdot 10^{-140} \lor \neg \left(z \leq 1.05 \cdot 10^{-101}\right):\\
\;\;\;\;z \cdot \left(1 - x\right)\\
\mathbf{else}:\\
\;\;\;\;y \cdot x\\
\end{array}
\end{array}
if z < -1.2999999999999999e-140 or 1.05000000000000008e-101 < z Initial program 94.7%
Taylor expanded in y around 0 79.9%
if -1.2999999999999999e-140 < z < 1.05000000000000008e-101Initial program 100.0%
Taylor expanded in y around inf 74.1%
Final simplification78.3%
(FPCore (x y z) :precision binary64 (if (or (<= x -250.0) (not (<= x 4.2e-11))) (* (- y z) x) (+ z (* y x))))
double code(double x, double y, double z) {
double tmp;
if ((x <= -250.0) || !(x <= 4.2e-11)) {
tmp = (y - z) * x;
} else {
tmp = z + (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) :: tmp
if ((x <= (-250.0d0)) .or. (.not. (x <= 4.2d-11))) then
tmp = (y - z) * x
else
tmp = z + (y * x)
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((x <= -250.0) || !(x <= 4.2e-11)) {
tmp = (y - z) * x;
} else {
tmp = z + (y * x);
}
return tmp;
}
def code(x, y, z): tmp = 0 if (x <= -250.0) or not (x <= 4.2e-11): tmp = (y - z) * x else: tmp = z + (y * x) return tmp
function code(x, y, z) tmp = 0.0 if ((x <= -250.0) || !(x <= 4.2e-11)) tmp = Float64(Float64(y - z) * x); else tmp = Float64(z + Float64(y * x)); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((x <= -250.0) || ~((x <= 4.2e-11))) tmp = (y - z) * x; else tmp = z + (y * x); end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[x, -250.0], N[Not[LessEqual[x, 4.2e-11]], $MachinePrecision]], N[(N[(y - z), $MachinePrecision] * x), $MachinePrecision], N[(z + N[(y * x), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -250 \lor \neg \left(x \leq 4.2 \cdot 10^{-11}\right):\\
\;\;\;\;\left(y - z\right) \cdot x\\
\mathbf{else}:\\
\;\;\;\;z + y \cdot x\\
\end{array}
\end{array}
if x < -250 or 4.1999999999999997e-11 < x Initial program 91.6%
sub-neg91.6%
+-commutative91.6%
distribute-lft1-in91.6%
associate-+r+91.6%
+-commutative91.6%
*-commutative91.6%
neg-mul-191.6%
associate-*r*91.6%
*-commutative91.6%
distribute-rgt-out100.0%
fma-def100.0%
+-commutative100.0%
*-commutative100.0%
neg-mul-1100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in x around inf 99.5%
if -250 < x < 4.1999999999999997e-11Initial program 100.0%
sub-neg100.0%
+-commutative100.0%
distribute-lft1-in100.0%
associate-+r+100.0%
+-commutative100.0%
*-commutative100.0%
neg-mul-1100.0%
associate-*r*100.0%
*-commutative100.0%
distribute-rgt-out100.0%
fma-def100.0%
+-commutative100.0%
*-commutative100.0%
neg-mul-1100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in x around 0 100.0%
Taylor expanded in y around inf 99.1%
Final simplification99.3%
(FPCore (x y z) :precision binary64 z)
double code(double x, double y, double z) {
return z;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = z
end function
public static double code(double x, double y, double z) {
return z;
}
def code(x, y, z): return z
function code(x, y, z) return z end
function tmp = code(x, y, z) tmp = z; end
code[x_, y_, z_] := z
\begin{array}{l}
\\
z
\end{array}
Initial program 96.1%
Taylor expanded in x around 0 41.5%
Final simplification41.5%
herbie shell --seed 2023215
(FPCore (x y z)
:name "Diagrams.Backend.Rasterific:$crender from diagrams-rasterific-1.3.1.3"
:precision binary64
(+ (* x y) (* (- 1.0 x) z)))