
(FPCore (x y z) :precision binary64 (+ x (* (* (- y x) 6.0) (- (/ 2.0 3.0) z))))
double code(double x, double y, double z) {
return x + (((y - x) * 6.0) * ((2.0 / 3.0) - 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 - x) * 6.0d0) * ((2.0d0 / 3.0d0) - z))
end function
public static double code(double x, double y, double z) {
return x + (((y - x) * 6.0) * ((2.0 / 3.0) - z));
}
def code(x, y, z): return x + (((y - x) * 6.0) * ((2.0 / 3.0) - z))
function code(x, y, z) return Float64(x + Float64(Float64(Float64(y - x) * 6.0) * Float64(Float64(2.0 / 3.0) - z))) end
function tmp = code(x, y, z) tmp = x + (((y - x) * 6.0) * ((2.0 / 3.0) - z)); end
code[x_, y_, z_] := N[(x + N[(N[(N[(y - x), $MachinePrecision] * 6.0), $MachinePrecision] * N[(N[(2.0 / 3.0), $MachinePrecision] - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(\left(y - x\right) \cdot 6\right) \cdot \left(\frac{2}{3} - z\right)
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 14 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z) :precision binary64 (+ x (* (* (- y x) 6.0) (- (/ 2.0 3.0) z))))
double code(double x, double y, double z) {
return x + (((y - x) * 6.0) * ((2.0 / 3.0) - 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 - x) * 6.0d0) * ((2.0d0 / 3.0d0) - z))
end function
public static double code(double x, double y, double z) {
return x + (((y - x) * 6.0) * ((2.0 / 3.0) - z));
}
def code(x, y, z): return x + (((y - x) * 6.0) * ((2.0 / 3.0) - z))
function code(x, y, z) return Float64(x + Float64(Float64(Float64(y - x) * 6.0) * Float64(Float64(2.0 / 3.0) - z))) end
function tmp = code(x, y, z) tmp = x + (((y - x) * 6.0) * ((2.0 / 3.0) - z)); end
code[x_, y_, z_] := N[(x + N[(N[(N[(y - x), $MachinePrecision] * 6.0), $MachinePrecision] * N[(N[(2.0 / 3.0), $MachinePrecision] - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(\left(y - x\right) \cdot 6\right) \cdot \left(\frac{2}{3} - z\right)
\end{array}
(FPCore (x y z) :precision binary64 (+ x (* (- y x) (+ 4.0 (* z -6.0)))))
double code(double x, double y, double z) {
return x + ((y - x) * (4.0 + (z * -6.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 + ((y - x) * (4.0d0 + (z * (-6.0d0))))
end function
public static double code(double x, double y, double z) {
return x + ((y - x) * (4.0 + (z * -6.0)));
}
def code(x, y, z): return x + ((y - x) * (4.0 + (z * -6.0)))
function code(x, y, z) return Float64(x + Float64(Float64(y - x) * Float64(4.0 + Float64(z * -6.0)))) end
function tmp = code(x, y, z) tmp = x + ((y - x) * (4.0 + (z * -6.0))); end
code[x_, y_, z_] := N[(x + N[(N[(y - x), $MachinePrecision] * N[(4.0 + N[(z * -6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(y - x\right) \cdot \left(4 + z \cdot -6\right)
\end{array}
Initial program 99.6%
+-lowering-+.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
--lowering--.f64N/A
sub-negN/A
distribute-lft-inN/A
*-commutativeN/A
+-lowering-+.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-lft-neg-outN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
*-lowering-*.f64N/A
metadata-eval99.8%
Simplified99.8%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* z (* (- y x) -6.0))))
(if (<= z -210000000000.0)
t_0
(if (<= z -1e-65)
(* x (+ (* z 6.0) -3.0))
(if (<= z 350000.0) (* y (+ 4.0 (* z -6.0))) t_0)))))
double code(double x, double y, double z) {
double t_0 = z * ((y - x) * -6.0);
double tmp;
if (z <= -210000000000.0) {
tmp = t_0;
} else if (z <= -1e-65) {
tmp = x * ((z * 6.0) + -3.0);
} else if (z <= 350000.0) {
tmp = y * (4.0 + (z * -6.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) :: tmp
t_0 = z * ((y - x) * (-6.0d0))
if (z <= (-210000000000.0d0)) then
tmp = t_0
else if (z <= (-1d-65)) then
tmp = x * ((z * 6.0d0) + (-3.0d0))
else if (z <= 350000.0d0) then
tmp = y * (4.0d0 + (z * (-6.0d0)))
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = z * ((y - x) * -6.0);
double tmp;
if (z <= -210000000000.0) {
tmp = t_0;
} else if (z <= -1e-65) {
tmp = x * ((z * 6.0) + -3.0);
} else if (z <= 350000.0) {
tmp = y * (4.0 + (z * -6.0));
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = z * ((y - x) * -6.0) tmp = 0 if z <= -210000000000.0: tmp = t_0 elif z <= -1e-65: tmp = x * ((z * 6.0) + -3.0) elif z <= 350000.0: tmp = y * (4.0 + (z * -6.0)) else: tmp = t_0 return tmp
function code(x, y, z) t_0 = Float64(z * Float64(Float64(y - x) * -6.0)) tmp = 0.0 if (z <= -210000000000.0) tmp = t_0; elseif (z <= -1e-65) tmp = Float64(x * Float64(Float64(z * 6.0) + -3.0)); elseif (z <= 350000.0) tmp = Float64(y * Float64(4.0 + Float64(z * -6.0))); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y, z) t_0 = z * ((y - x) * -6.0); tmp = 0.0; if (z <= -210000000000.0) tmp = t_0; elseif (z <= -1e-65) tmp = x * ((z * 6.0) + -3.0); elseif (z <= 350000.0) tmp = y * (4.0 + (z * -6.0)); else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(z * N[(N[(y - x), $MachinePrecision] * -6.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -210000000000.0], t$95$0, If[LessEqual[z, -1e-65], N[(x * N[(N[(z * 6.0), $MachinePrecision] + -3.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 350000.0], N[(y * N[(4.0 + N[(z * -6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$0]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := z \cdot \left(\left(y - x\right) \cdot -6\right)\\
\mathbf{if}\;z \leq -210000000000:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -1 \cdot 10^{-65}:\\
\;\;\;\;x \cdot \left(z \cdot 6 + -3\right)\\
\mathbf{elif}\;z \leq 350000:\\
\;\;\;\;y \cdot \left(4 + z \cdot -6\right)\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if z < -2.1e11 or 3.5e5 < z Initial program 99.8%
Taylor expanded in z around inf
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
--lowering--.f6499.2%
Simplified99.2%
if -2.1e11 < z < -9.99999999999999923e-66Initial program 99.4%
Taylor expanded in x around inf
*-lowering-*.f64N/A
+-commutativeN/A
sub-negN/A
mul-1-negN/A
+-commutativeN/A
distribute-lft-inN/A
*-commutativeN/A
associate-*l*N/A
metadata-evalN/A
associate-+l+N/A
metadata-evalN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-*r*N/A
metadata-evalN/A
*-lowering-*.f64N/A
metadata-eval87.6%
Simplified87.6%
if -9.99999999999999923e-66 < z < 3.5e5Initial program 99.4%
+-lowering-+.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
--lowering--.f64N/A
sub-negN/A
distribute-lft-inN/A
*-commutativeN/A
+-lowering-+.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-lft-neg-outN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
*-lowering-*.f64N/A
metadata-eval99.8%
Simplified99.8%
flip3-+N/A
clear-numN/A
/-lowering-/.f64N/A
clear-numN/A
flip3-+N/A
/-lowering-/.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
Applied egg-rr99.7%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f6463.3%
Simplified63.3%
Final simplification82.6%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* x (* z 6.0))))
(if (<= z -0.5)
t_0
(if (<= z -8.5e-66) (* x -3.0) (if (<= z 0.54) (* y 4.0) t_0)))))
double code(double x, double y, double z) {
double t_0 = x * (z * 6.0);
double tmp;
if (z <= -0.5) {
tmp = t_0;
} else if (z <= -8.5e-66) {
tmp = x * -3.0;
} else if (z <= 0.54) {
tmp = y * 4.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) :: tmp
t_0 = x * (z * 6.0d0)
if (z <= (-0.5d0)) then
tmp = t_0
else if (z <= (-8.5d-66)) then
tmp = x * (-3.0d0)
else if (z <= 0.54d0) then
tmp = y * 4.0d0
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = x * (z * 6.0);
double tmp;
if (z <= -0.5) {
tmp = t_0;
} else if (z <= -8.5e-66) {
tmp = x * -3.0;
} else if (z <= 0.54) {
tmp = y * 4.0;
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = x * (z * 6.0) tmp = 0 if z <= -0.5: tmp = t_0 elif z <= -8.5e-66: tmp = x * -3.0 elif z <= 0.54: tmp = y * 4.0 else: tmp = t_0 return tmp
function code(x, y, z) t_0 = Float64(x * Float64(z * 6.0)) tmp = 0.0 if (z <= -0.5) tmp = t_0; elseif (z <= -8.5e-66) tmp = Float64(x * -3.0); elseif (z <= 0.54) tmp = Float64(y * 4.0); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y, z) t_0 = x * (z * 6.0); tmp = 0.0; if (z <= -0.5) tmp = t_0; elseif (z <= -8.5e-66) tmp = x * -3.0; elseif (z <= 0.54) tmp = y * 4.0; else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(x * N[(z * 6.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -0.5], t$95$0, If[LessEqual[z, -8.5e-66], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 0.54], N[(y * 4.0), $MachinePrecision], t$95$0]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x \cdot \left(z \cdot 6\right)\\
\mathbf{if}\;z \leq -0.5:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -8.5 \cdot 10^{-66}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 0.54:\\
\;\;\;\;y \cdot 4\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if z < -0.5 or 0.54000000000000004 < z Initial program 99.8%
Taylor expanded in z around inf
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
--lowering--.f6497.3%
Simplified97.3%
Taylor expanded in y around 0
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6457.9%
Simplified57.9%
if -0.5 < z < -8.49999999999999966e-66Initial program 99.4%
+-lowering-+.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
--lowering--.f64N/A
sub-negN/A
distribute-lft-inN/A
*-commutativeN/A
+-lowering-+.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-lft-neg-outN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
*-lowering-*.f64N/A
metadata-eval99.7%
Simplified99.7%
Taylor expanded in z around 0
Simplified94.3%
Taylor expanded in x around inf
*-commutativeN/A
*-lowering-*.f6482.1%
Simplified82.1%
if -8.49999999999999966e-66 < z < 0.54000000000000004Initial program 99.4%
Taylor expanded in x around 0
*-lowering-*.f64N/A
*-lowering-*.f64N/A
--lowering--.f6463.1%
Simplified63.1%
Taylor expanded in z around 0
*-commutativeN/A
*-lowering-*.f6462.0%
Simplified62.0%
(FPCore (x y z)
:precision binary64
(if (<= z -0.66)
(+ x (* (- y x) (* z -6.0)))
(if (<= z 0.66)
(+ x (* (- y x) 4.0))
(/ (- y x) (/ -0.16666666666666666 z)))))
double code(double x, double y, double z) {
double tmp;
if (z <= -0.66) {
tmp = x + ((y - x) * (z * -6.0));
} else if (z <= 0.66) {
tmp = x + ((y - x) * 4.0);
} else {
tmp = (y - x) / (-0.16666666666666666 / z);
}
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 <= (-0.66d0)) then
tmp = x + ((y - x) * (z * (-6.0d0)))
else if (z <= 0.66d0) then
tmp = x + ((y - x) * 4.0d0)
else
tmp = (y - x) / ((-0.16666666666666666d0) / z)
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (z <= -0.66) {
tmp = x + ((y - x) * (z * -6.0));
} else if (z <= 0.66) {
tmp = x + ((y - x) * 4.0);
} else {
tmp = (y - x) / (-0.16666666666666666 / z);
}
return tmp;
}
def code(x, y, z): tmp = 0 if z <= -0.66: tmp = x + ((y - x) * (z * -6.0)) elif z <= 0.66: tmp = x + ((y - x) * 4.0) else: tmp = (y - x) / (-0.16666666666666666 / z) return tmp
function code(x, y, z) tmp = 0.0 if (z <= -0.66) tmp = Float64(x + Float64(Float64(y - x) * Float64(z * -6.0))); elseif (z <= 0.66) tmp = Float64(x + Float64(Float64(y - x) * 4.0)); else tmp = Float64(Float64(y - x) / Float64(-0.16666666666666666 / z)); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (z <= -0.66) tmp = x + ((y - x) * (z * -6.0)); elseif (z <= 0.66) tmp = x + ((y - x) * 4.0); else tmp = (y - x) / (-0.16666666666666666 / z); end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[z, -0.66], N[(x + N[(N[(y - x), $MachinePrecision] * N[(z * -6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 0.66], N[(x + N[(N[(y - x), $MachinePrecision] * 4.0), $MachinePrecision]), $MachinePrecision], N[(N[(y - x), $MachinePrecision] / N[(-0.16666666666666666 / z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -0.66:\\
\;\;\;\;x + \left(y - x\right) \cdot \left(z \cdot -6\right)\\
\mathbf{elif}\;z \leq 0.66:\\
\;\;\;\;x + \left(y - x\right) \cdot 4\\
\mathbf{else}:\\
\;\;\;\;\frac{y - x}{\frac{-0.16666666666666666}{z}}\\
\end{array}
\end{array}
if z < -0.660000000000000031Initial program 99.8%
+-lowering-+.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
--lowering--.f64N/A
sub-negN/A
distribute-lft-inN/A
*-commutativeN/A
+-lowering-+.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-lft-neg-outN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
*-lowering-*.f64N/A
metadata-eval99.9%
Simplified99.9%
Taylor expanded in z around inf
*-commutativeN/A
*-lowering-*.f6497.8%
Simplified97.8%
if -0.660000000000000031 < z < 0.660000000000000031Initial program 99.4%
+-lowering-+.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
--lowering--.f64N/A
sub-negN/A
distribute-lft-inN/A
*-commutativeN/A
+-lowering-+.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-lft-neg-outN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
*-lowering-*.f64N/A
metadata-eval99.8%
Simplified99.8%
Taylor expanded in z around 0
Simplified97.2%
if 0.660000000000000031 < z Initial program 99.8%
Taylor expanded in z around inf
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
--lowering--.f6496.8%
Simplified96.8%
associate-*r*N/A
metadata-evalN/A
div-invN/A
clear-numN/A
associate-/r/N/A
clear-numN/A
/-lowering-/.f64N/A
*-rgt-identityN/A
rgt-mult-inverseN/A
associate-*l*N/A
*-commutativeN/A
--lowering--.f64N/A
*-commutativeN/A
associate-*l*N/A
rgt-mult-inverseN/A
*-rgt-identityN/A
/-lowering-/.f6496.8%
Applied egg-rr96.8%
(FPCore (x y z)
:precision binary64
(if (<= z -0.55)
(* z (* (- y x) -6.0))
(if (<= z 0.66)
(+ x (* (- y x) 4.0))
(/ (- y x) (/ -0.16666666666666666 z)))))
double code(double x, double y, double z) {
double tmp;
if (z <= -0.55) {
tmp = z * ((y - x) * -6.0);
} else if (z <= 0.66) {
tmp = x + ((y - x) * 4.0);
} else {
tmp = (y - x) / (-0.16666666666666666 / z);
}
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 <= (-0.55d0)) then
tmp = z * ((y - x) * (-6.0d0))
else if (z <= 0.66d0) then
tmp = x + ((y - x) * 4.0d0)
else
tmp = (y - x) / ((-0.16666666666666666d0) / z)
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (z <= -0.55) {
tmp = z * ((y - x) * -6.0);
} else if (z <= 0.66) {
tmp = x + ((y - x) * 4.0);
} else {
tmp = (y - x) / (-0.16666666666666666 / z);
}
return tmp;
}
def code(x, y, z): tmp = 0 if z <= -0.55: tmp = z * ((y - x) * -6.0) elif z <= 0.66: tmp = x + ((y - x) * 4.0) else: tmp = (y - x) / (-0.16666666666666666 / z) return tmp
function code(x, y, z) tmp = 0.0 if (z <= -0.55) tmp = Float64(z * Float64(Float64(y - x) * -6.0)); elseif (z <= 0.66) tmp = Float64(x + Float64(Float64(y - x) * 4.0)); else tmp = Float64(Float64(y - x) / Float64(-0.16666666666666666 / z)); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (z <= -0.55) tmp = z * ((y - x) * -6.0); elseif (z <= 0.66) tmp = x + ((y - x) * 4.0); else tmp = (y - x) / (-0.16666666666666666 / z); end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[z, -0.55], N[(z * N[(N[(y - x), $MachinePrecision] * -6.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 0.66], N[(x + N[(N[(y - x), $MachinePrecision] * 4.0), $MachinePrecision]), $MachinePrecision], N[(N[(y - x), $MachinePrecision] / N[(-0.16666666666666666 / z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -0.55:\\
\;\;\;\;z \cdot \left(\left(y - x\right) \cdot -6\right)\\
\mathbf{elif}\;z \leq 0.66:\\
\;\;\;\;x + \left(y - x\right) \cdot 4\\
\mathbf{else}:\\
\;\;\;\;\frac{y - x}{\frac{-0.16666666666666666}{z}}\\
\end{array}
\end{array}
if z < -0.55000000000000004Initial program 99.8%
Taylor expanded in z around inf
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
--lowering--.f6497.7%
Simplified97.7%
if -0.55000000000000004 < z < 0.660000000000000031Initial program 99.4%
+-lowering-+.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
--lowering--.f64N/A
sub-negN/A
distribute-lft-inN/A
*-commutativeN/A
+-lowering-+.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-lft-neg-outN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
*-lowering-*.f64N/A
metadata-eval99.8%
Simplified99.8%
Taylor expanded in z around 0
Simplified97.2%
if 0.660000000000000031 < z Initial program 99.8%
Taylor expanded in z around inf
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
--lowering--.f6496.8%
Simplified96.8%
associate-*r*N/A
metadata-evalN/A
div-invN/A
clear-numN/A
associate-/r/N/A
clear-numN/A
/-lowering-/.f64N/A
*-rgt-identityN/A
rgt-mult-inverseN/A
associate-*l*N/A
*-commutativeN/A
--lowering--.f64N/A
*-commutativeN/A
associate-*l*N/A
rgt-mult-inverseN/A
*-rgt-identityN/A
/-lowering-/.f6496.8%
Applied egg-rr96.8%
Final simplification97.2%
(FPCore (x y z) :precision binary64 (let* ((t_0 (* z (* (- y x) -6.0)))) (if (<= z -0.58) t_0 (if (<= z 0.66) (+ x (* (- y x) 4.0)) t_0))))
double code(double x, double y, double z) {
double t_0 = z * ((y - x) * -6.0);
double tmp;
if (z <= -0.58) {
tmp = t_0;
} else if (z <= 0.66) {
tmp = x + ((y - x) * 4.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) :: tmp
t_0 = z * ((y - x) * (-6.0d0))
if (z <= (-0.58d0)) then
tmp = t_0
else if (z <= 0.66d0) then
tmp = x + ((y - x) * 4.0d0)
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = z * ((y - x) * -6.0);
double tmp;
if (z <= -0.58) {
tmp = t_0;
} else if (z <= 0.66) {
tmp = x + ((y - x) * 4.0);
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = z * ((y - x) * -6.0) tmp = 0 if z <= -0.58: tmp = t_0 elif z <= 0.66: tmp = x + ((y - x) * 4.0) else: tmp = t_0 return tmp
function code(x, y, z) t_0 = Float64(z * Float64(Float64(y - x) * -6.0)) tmp = 0.0 if (z <= -0.58) tmp = t_0; elseif (z <= 0.66) tmp = Float64(x + Float64(Float64(y - x) * 4.0)); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y, z) t_0 = z * ((y - x) * -6.0); tmp = 0.0; if (z <= -0.58) tmp = t_0; elseif (z <= 0.66) tmp = x + ((y - x) * 4.0); else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(z * N[(N[(y - x), $MachinePrecision] * -6.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -0.58], t$95$0, If[LessEqual[z, 0.66], N[(x + N[(N[(y - x), $MachinePrecision] * 4.0), $MachinePrecision]), $MachinePrecision], t$95$0]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := z \cdot \left(\left(y - x\right) \cdot -6\right)\\
\mathbf{if}\;z \leq -0.58:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq 0.66:\\
\;\;\;\;x + \left(y - x\right) \cdot 4\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if z < -0.57999999999999996 or 0.660000000000000031 < z Initial program 99.8%
Taylor expanded in z around inf
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
--lowering--.f6497.3%
Simplified97.3%
if -0.57999999999999996 < z < 0.660000000000000031Initial program 99.4%
+-lowering-+.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
--lowering--.f64N/A
sub-negN/A
distribute-lft-inN/A
*-commutativeN/A
+-lowering-+.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-lft-neg-outN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
*-lowering-*.f64N/A
metadata-eval99.8%
Simplified99.8%
Taylor expanded in z around 0
Simplified97.2%
Final simplification97.2%
(FPCore (x y z) :precision binary64 (let* ((t_0 (* x (+ (* z 6.0) -3.0)))) (if (<= x -1.25e-73) t_0 (if (<= x 4.8e+39) (* y (+ 4.0 (* z -6.0))) t_0))))
double code(double x, double y, double z) {
double t_0 = x * ((z * 6.0) + -3.0);
double tmp;
if (x <= -1.25e-73) {
tmp = t_0;
} else if (x <= 4.8e+39) {
tmp = y * (4.0 + (z * -6.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) :: tmp
t_0 = x * ((z * 6.0d0) + (-3.0d0))
if (x <= (-1.25d-73)) then
tmp = t_0
else if (x <= 4.8d+39) then
tmp = y * (4.0d0 + (z * (-6.0d0)))
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = x * ((z * 6.0) + -3.0);
double tmp;
if (x <= -1.25e-73) {
tmp = t_0;
} else if (x <= 4.8e+39) {
tmp = y * (4.0 + (z * -6.0));
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = x * ((z * 6.0) + -3.0) tmp = 0 if x <= -1.25e-73: tmp = t_0 elif x <= 4.8e+39: tmp = y * (4.0 + (z * -6.0)) else: tmp = t_0 return tmp
function code(x, y, z) t_0 = Float64(x * Float64(Float64(z * 6.0) + -3.0)) tmp = 0.0 if (x <= -1.25e-73) tmp = t_0; elseif (x <= 4.8e+39) tmp = Float64(y * Float64(4.0 + Float64(z * -6.0))); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y, z) t_0 = x * ((z * 6.0) + -3.0); tmp = 0.0; if (x <= -1.25e-73) tmp = t_0; elseif (x <= 4.8e+39) tmp = y * (4.0 + (z * -6.0)); else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(x * N[(N[(z * 6.0), $MachinePrecision] + -3.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -1.25e-73], t$95$0, If[LessEqual[x, 4.8e+39], N[(y * N[(4.0 + N[(z * -6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$0]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x \cdot \left(z \cdot 6 + -3\right)\\
\mathbf{if}\;x \leq -1.25 \cdot 10^{-73}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;x \leq 4.8 \cdot 10^{+39}:\\
\;\;\;\;y \cdot \left(4 + z \cdot -6\right)\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if x < -1.25e-73 or 4.8000000000000002e39 < x Initial program 99.6%
Taylor expanded in x around inf
*-lowering-*.f64N/A
+-commutativeN/A
sub-negN/A
mul-1-negN/A
+-commutativeN/A
distribute-lft-inN/A
*-commutativeN/A
associate-*l*N/A
metadata-evalN/A
associate-+l+N/A
metadata-evalN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-*r*N/A
metadata-evalN/A
*-lowering-*.f64N/A
metadata-eval83.2%
Simplified83.2%
if -1.25e-73 < x < 4.8000000000000002e39Initial program 99.6%
+-lowering-+.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
--lowering--.f64N/A
sub-negN/A
distribute-lft-inN/A
*-commutativeN/A
+-lowering-+.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-lft-neg-outN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
*-lowering-*.f64N/A
metadata-eval99.8%
Simplified99.8%
flip3-+N/A
clear-numN/A
/-lowering-/.f64N/A
clear-numN/A
flip3-+N/A
/-lowering-/.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
Applied egg-rr99.7%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f6478.9%
Simplified78.9%
Final simplification81.0%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* x (+ (* z 6.0) -3.0))))
(if (<= x -9.6e-74)
t_0
(if (<= x 2.2e+40) (* 6.0 (* y (- 0.6666666666666666 z))) t_0))))
double code(double x, double y, double z) {
double t_0 = x * ((z * 6.0) + -3.0);
double tmp;
if (x <= -9.6e-74) {
tmp = t_0;
} else if (x <= 2.2e+40) {
tmp = 6.0 * (y * (0.6666666666666666 - z));
} 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 = x * ((z * 6.0d0) + (-3.0d0))
if (x <= (-9.6d-74)) then
tmp = t_0
else if (x <= 2.2d+40) then
tmp = 6.0d0 * (y * (0.6666666666666666d0 - z))
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = x * ((z * 6.0) + -3.0);
double tmp;
if (x <= -9.6e-74) {
tmp = t_0;
} else if (x <= 2.2e+40) {
tmp = 6.0 * (y * (0.6666666666666666 - z));
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = x * ((z * 6.0) + -3.0) tmp = 0 if x <= -9.6e-74: tmp = t_0 elif x <= 2.2e+40: tmp = 6.0 * (y * (0.6666666666666666 - z)) else: tmp = t_0 return tmp
function code(x, y, z) t_0 = Float64(x * Float64(Float64(z * 6.0) + -3.0)) tmp = 0.0 if (x <= -9.6e-74) tmp = t_0; elseif (x <= 2.2e+40) tmp = Float64(6.0 * Float64(y * Float64(0.6666666666666666 - z))); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y, z) t_0 = x * ((z * 6.0) + -3.0); tmp = 0.0; if (x <= -9.6e-74) tmp = t_0; elseif (x <= 2.2e+40) tmp = 6.0 * (y * (0.6666666666666666 - z)); else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(x * N[(N[(z * 6.0), $MachinePrecision] + -3.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -9.6e-74], t$95$0, If[LessEqual[x, 2.2e+40], N[(6.0 * N[(y * N[(0.6666666666666666 - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$0]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x \cdot \left(z \cdot 6 + -3\right)\\
\mathbf{if}\;x \leq -9.6 \cdot 10^{-74}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;x \leq 2.2 \cdot 10^{+40}:\\
\;\;\;\;6 \cdot \left(y \cdot \left(0.6666666666666666 - z\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if x < -9.5999999999999996e-74 or 2.1999999999999999e40 < x Initial program 99.6%
Taylor expanded in x around inf
*-lowering-*.f64N/A
+-commutativeN/A
sub-negN/A
mul-1-negN/A
+-commutativeN/A
distribute-lft-inN/A
*-commutativeN/A
associate-*l*N/A
metadata-evalN/A
associate-+l+N/A
metadata-evalN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
associate-*r*N/A
metadata-evalN/A
*-lowering-*.f64N/A
metadata-eval83.2%
Simplified83.2%
if -9.5999999999999996e-74 < x < 2.1999999999999999e40Initial program 99.6%
Taylor expanded in x around 0
*-lowering-*.f64N/A
*-lowering-*.f64N/A
--lowering--.f6478.5%
Simplified78.5%
Final simplification80.8%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* x (* z 6.0))))
(if (<= x -1.25e-73)
t_0
(if (<= x 8.4e+40) (* 6.0 (* y (- 0.6666666666666666 z))) t_0))))
double code(double x, double y, double z) {
double t_0 = x * (z * 6.0);
double tmp;
if (x <= -1.25e-73) {
tmp = t_0;
} else if (x <= 8.4e+40) {
tmp = 6.0 * (y * (0.6666666666666666 - z));
} 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 = x * (z * 6.0d0)
if (x <= (-1.25d-73)) then
tmp = t_0
else if (x <= 8.4d+40) then
tmp = 6.0d0 * (y * (0.6666666666666666d0 - z))
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = x * (z * 6.0);
double tmp;
if (x <= -1.25e-73) {
tmp = t_0;
} else if (x <= 8.4e+40) {
tmp = 6.0 * (y * (0.6666666666666666 - z));
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = x * (z * 6.0) tmp = 0 if x <= -1.25e-73: tmp = t_0 elif x <= 8.4e+40: tmp = 6.0 * (y * (0.6666666666666666 - z)) else: tmp = t_0 return tmp
function code(x, y, z) t_0 = Float64(x * Float64(z * 6.0)) tmp = 0.0 if (x <= -1.25e-73) tmp = t_0; elseif (x <= 8.4e+40) tmp = Float64(6.0 * Float64(y * Float64(0.6666666666666666 - z))); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y, z) t_0 = x * (z * 6.0); tmp = 0.0; if (x <= -1.25e-73) tmp = t_0; elseif (x <= 8.4e+40) tmp = 6.0 * (y * (0.6666666666666666 - z)); else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(x * N[(z * 6.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -1.25e-73], t$95$0, If[LessEqual[x, 8.4e+40], N[(6.0 * N[(y * N[(0.6666666666666666 - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$0]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x \cdot \left(z \cdot 6\right)\\
\mathbf{if}\;x \leq -1.25 \cdot 10^{-73}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;x \leq 8.4 \cdot 10^{+40}:\\
\;\;\;\;6 \cdot \left(y \cdot \left(0.6666666666666666 - z\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if x < -1.25e-73 or 8.4000000000000004e40 < x Initial program 99.6%
Taylor expanded in z around inf
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
--lowering--.f6461.7%
Simplified61.7%
Taylor expanded in y around 0
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6452.4%
Simplified52.4%
if -1.25e-73 < x < 8.4000000000000004e40Initial program 99.6%
Taylor expanded in x around 0
*-lowering-*.f64N/A
*-lowering-*.f64N/A
--lowering--.f6478.5%
Simplified78.5%
(FPCore (x y z) :precision binary64 (if (<= x -1.4e-82) (* x -3.0) (if (<= x 1.25e+17) (* y 4.0) (* x -3.0))))
double code(double x, double y, double z) {
double tmp;
if (x <= -1.4e-82) {
tmp = x * -3.0;
} else if (x <= 1.25e+17) {
tmp = y * 4.0;
} else {
tmp = x * -3.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.4d-82)) then
tmp = x * (-3.0d0)
else if (x <= 1.25d+17) then
tmp = y * 4.0d0
else
tmp = x * (-3.0d0)
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= -1.4e-82) {
tmp = x * -3.0;
} else if (x <= 1.25e+17) {
tmp = y * 4.0;
} else {
tmp = x * -3.0;
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= -1.4e-82: tmp = x * -3.0 elif x <= 1.25e+17: tmp = y * 4.0 else: tmp = x * -3.0 return tmp
function code(x, y, z) tmp = 0.0 if (x <= -1.4e-82) tmp = Float64(x * -3.0); elseif (x <= 1.25e+17) tmp = Float64(y * 4.0); else tmp = Float64(x * -3.0); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= -1.4e-82) tmp = x * -3.0; elseif (x <= 1.25e+17) tmp = y * 4.0; else tmp = x * -3.0; end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, -1.4e-82], N[(x * -3.0), $MachinePrecision], If[LessEqual[x, 1.25e+17], N[(y * 4.0), $MachinePrecision], N[(x * -3.0), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.4 \cdot 10^{-82}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;x \leq 1.25 \cdot 10^{+17}:\\
\;\;\;\;y \cdot 4\\
\mathbf{else}:\\
\;\;\;\;x \cdot -3\\
\end{array}
\end{array}
if x < -1.40000000000000012e-82 or 1.25e17 < x Initial program 99.6%
+-lowering-+.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
--lowering--.f64N/A
sub-negN/A
distribute-lft-inN/A
*-commutativeN/A
+-lowering-+.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-lft-neg-outN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
*-lowering-*.f64N/A
metadata-eval99.8%
Simplified99.8%
Taylor expanded in z around 0
Simplified39.0%
Taylor expanded in x around inf
*-commutativeN/A
*-lowering-*.f6431.7%
Simplified31.7%
if -1.40000000000000012e-82 < x < 1.25e17Initial program 99.5%
Taylor expanded in x around 0
*-lowering-*.f64N/A
*-lowering-*.f64N/A
--lowering--.f6479.6%
Simplified79.6%
Taylor expanded in z around 0
*-commutativeN/A
*-lowering-*.f6449.9%
Simplified49.9%
(FPCore (x y z) :precision binary64 (+ x (* (- 0.6666666666666666 z) (* (- y x) 6.0))))
double code(double x, double y, double z) {
return x + ((0.6666666666666666 - z) * ((y - x) * 6.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 + ((0.6666666666666666d0 - z) * ((y - x) * 6.0d0))
end function
public static double code(double x, double y, double z) {
return x + ((0.6666666666666666 - z) * ((y - x) * 6.0));
}
def code(x, y, z): return x + ((0.6666666666666666 - z) * ((y - x) * 6.0))
function code(x, y, z) return Float64(x + Float64(Float64(0.6666666666666666 - z) * Float64(Float64(y - x) * 6.0))) end
function tmp = code(x, y, z) tmp = x + ((0.6666666666666666 - z) * ((y - x) * 6.0)); end
code[x_, y_, z_] := N[(x + N[(N[(0.6666666666666666 - z), $MachinePrecision] * N[(N[(y - x), $MachinePrecision] * 6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(0.6666666666666666 - z\right) \cdot \left(\left(y - x\right) \cdot 6\right)
\end{array}
Initial program 99.6%
*-commutativeN/A
*-lowering-*.f64N/A
--lowering--.f64N/A
metadata-evalN/A
*-lowering-*.f64N/A
--lowering--.f6499.6%
Applied egg-rr99.6%
(FPCore (x y z) :precision binary64 (+ x (* 6.0 (* (- y x) (- 0.6666666666666666 z)))))
double code(double x, double y, double z) {
return x + (6.0 * ((y - x) * (0.6666666666666666 - 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 + (6.0d0 * ((y - x) * (0.6666666666666666d0 - z)))
end function
public static double code(double x, double y, double z) {
return x + (6.0 * ((y - x) * (0.6666666666666666 - z)));
}
def code(x, y, z): return x + (6.0 * ((y - x) * (0.6666666666666666 - z)))
function code(x, y, z) return Float64(x + Float64(6.0 * Float64(Float64(y - x) * Float64(0.6666666666666666 - z)))) end
function tmp = code(x, y, z) tmp = x + (6.0 * ((y - x) * (0.6666666666666666 - z))); end
code[x_, y_, z_] := N[(x + N[(6.0 * N[(N[(y - x), $MachinePrecision] * N[(0.6666666666666666 - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + 6 \cdot \left(\left(y - x\right) \cdot \left(0.6666666666666666 - z\right)\right)
\end{array}
Initial program 99.6%
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
--lowering--.f64N/A
metadata-evalN/A
--lowering--.f6499.4%
Applied egg-rr99.4%
Final simplification99.4%
(FPCore (x y z) :precision binary64 (* x -3.0))
double code(double x, double y, double z) {
return x * -3.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 * (-3.0d0)
end function
public static double code(double x, double y, double z) {
return x * -3.0;
}
def code(x, y, z): return x * -3.0
function code(x, y, z) return Float64(x * -3.0) end
function tmp = code(x, y, z) tmp = x * -3.0; end
code[x_, y_, z_] := N[(x * -3.0), $MachinePrecision]
\begin{array}{l}
\\
x \cdot -3
\end{array}
Initial program 99.6%
+-lowering-+.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
--lowering--.f64N/A
sub-negN/A
distribute-lft-inN/A
*-commutativeN/A
+-lowering-+.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-lft-neg-outN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
*-lowering-*.f64N/A
metadata-eval99.8%
Simplified99.8%
Taylor expanded in z around 0
Simplified49.6%
Taylor expanded in x around inf
*-commutativeN/A
*-lowering-*.f6422.9%
Simplified22.9%
(FPCore (x y z) :precision binary64 x)
double code(double x, double y, double z) {
return 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
end function
public static double code(double x, double y, double z) {
return x;
}
def code(x, y, z): return x
function code(x, y, z) return x end
function tmp = code(x, y, z) tmp = x; end
code[x_, y_, z_] := x
\begin{array}{l}
\\
x
\end{array}
Initial program 99.6%
+-lowering-+.f64N/A
associate-*l*N/A
*-lowering-*.f64N/A
--lowering--.f64N/A
sub-negN/A
distribute-lft-inN/A
*-commutativeN/A
+-lowering-+.f64N/A
metadata-evalN/A
metadata-evalN/A
distribute-lft-neg-outN/A
distribute-rgt-neg-inN/A
metadata-evalN/A
metadata-evalN/A
*-lowering-*.f64N/A
metadata-eval99.8%
Simplified99.8%
Taylor expanded in z around inf
*-commutativeN/A
*-lowering-*.f6450.6%
Simplified50.6%
Taylor expanded in z around 0
Simplified2.8%
herbie shell --seed 2024145
(FPCore (x y z)
:name "Data.Colour.RGBSpace.HSL:hsl from colour-2.3.3, D"
:precision binary64
(+ x (* (* (- y x) 6.0) (- (/ 2.0 3.0) z))))