
(FPCore (x y z) :precision binary64 (+ 1.0 (/ (* 4.0 (- (+ x (* y 0.75)) z)) y)))
double code(double x, double y, double z) {
return 1.0 + ((4.0 * ((x + (y * 0.75)) - z)) / y);
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = 1.0d0 + ((4.0d0 * ((x + (y * 0.75d0)) - z)) / y)
end function
public static double code(double x, double y, double z) {
return 1.0 + ((4.0 * ((x + (y * 0.75)) - z)) / y);
}
def code(x, y, z): return 1.0 + ((4.0 * ((x + (y * 0.75)) - z)) / y)
function code(x, y, z) return Float64(1.0 + Float64(Float64(4.0 * Float64(Float64(x + Float64(y * 0.75)) - z)) / y)) end
function tmp = code(x, y, z) tmp = 1.0 + ((4.0 * ((x + (y * 0.75)) - z)) / y); end
code[x_, y_, z_] := N[(1.0 + N[(N[(4.0 * N[(N[(x + N[(y * 0.75), $MachinePrecision]), $MachinePrecision] - z), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
1 + \frac{4 \cdot \left(\left(x + y \cdot 0.75\right) - z\right)}{y}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 13 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z) :precision binary64 (+ 1.0 (/ (* 4.0 (- (+ x (* y 0.75)) z)) y)))
double code(double x, double y, double z) {
return 1.0 + ((4.0 * ((x + (y * 0.75)) - z)) / y);
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = 1.0d0 + ((4.0d0 * ((x + (y * 0.75d0)) - z)) / y)
end function
public static double code(double x, double y, double z) {
return 1.0 + ((4.0 * ((x + (y * 0.75)) - z)) / y);
}
def code(x, y, z): return 1.0 + ((4.0 * ((x + (y * 0.75)) - z)) / y)
function code(x, y, z) return Float64(1.0 + Float64(Float64(4.0 * Float64(Float64(x + Float64(y * 0.75)) - z)) / y)) end
function tmp = code(x, y, z) tmp = 1.0 + ((4.0 * ((x + (y * 0.75)) - z)) / y); end
code[x_, y_, z_] := N[(1.0 + N[(N[(4.0 * N[(N[(x + N[(y * 0.75), $MachinePrecision]), $MachinePrecision] - z), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
1 + \frac{4 \cdot \left(\left(x + y \cdot 0.75\right) - z\right)}{y}
\end{array}
(FPCore (x y z) :precision binary64 (+ 1.0 (+ (/ (* 4.0 (- x z)) y) 3.0)))
double code(double x, double y, double z) {
return 1.0 + (((4.0 * (x - z)) / y) + 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 = 1.0d0 + (((4.0d0 * (x - z)) / y) + 3.0d0)
end function
public static double code(double x, double y, double z) {
return 1.0 + (((4.0 * (x - z)) / y) + 3.0);
}
def code(x, y, z): return 1.0 + (((4.0 * (x - z)) / y) + 3.0)
function code(x, y, z) return Float64(1.0 + Float64(Float64(Float64(4.0 * Float64(x - z)) / y) + 3.0)) end
function tmp = code(x, y, z) tmp = 1.0 + (((4.0 * (x - z)) / y) + 3.0); end
code[x_, y_, z_] := N[(1.0 + N[(N[(N[(4.0 * N[(x - z), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision] + 3.0), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
1 + \left(\frac{4 \cdot \left(x - z\right)}{y} + 3\right)
\end{array}
Initial program 99.9%
Taylor expanded in y around inf 100.0%
+-commutative100.0%
associate-*r/100.0%
Simplified100.0%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (+ 1.0 (* (- x z) (/ 4.0 y))))
(t_1 (+ 4.0 (* -4.0 (/ z y))))
(t_2 (+ 4.0 (* 4.0 (/ x y)))))
(if (<= z -1.2e+175)
t_1
(if (<= z -3.5e-13)
t_0
(if (<= z -2.55e-77)
t_2
(if (<= z -2.1e-94)
t_0
(if (<= z 3.7e+37) t_2 (if (<= z 3.5e+129) t_0 t_1))))))))
double code(double x, double y, double z) {
double t_0 = 1.0 + ((x - z) * (4.0 / y));
double t_1 = 4.0 + (-4.0 * (z / y));
double t_2 = 4.0 + (4.0 * (x / y));
double tmp;
if (z <= -1.2e+175) {
tmp = t_1;
} else if (z <= -3.5e-13) {
tmp = t_0;
} else if (z <= -2.55e-77) {
tmp = t_2;
} else if (z <= -2.1e-94) {
tmp = t_0;
} else if (z <= 3.7e+37) {
tmp = t_2;
} else if (z <= 3.5e+129) {
tmp = t_0;
} else {
tmp = t_1;
}
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 = 1.0d0 + ((x - z) * (4.0d0 / y))
t_1 = 4.0d0 + ((-4.0d0) * (z / y))
t_2 = 4.0d0 + (4.0d0 * (x / y))
if (z <= (-1.2d+175)) then
tmp = t_1
else if (z <= (-3.5d-13)) then
tmp = t_0
else if (z <= (-2.55d-77)) then
tmp = t_2
else if (z <= (-2.1d-94)) then
tmp = t_0
else if (z <= 3.7d+37) then
tmp = t_2
else if (z <= 3.5d+129) then
tmp = t_0
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = 1.0 + ((x - z) * (4.0 / y));
double t_1 = 4.0 + (-4.0 * (z / y));
double t_2 = 4.0 + (4.0 * (x / y));
double tmp;
if (z <= -1.2e+175) {
tmp = t_1;
} else if (z <= -3.5e-13) {
tmp = t_0;
} else if (z <= -2.55e-77) {
tmp = t_2;
} else if (z <= -2.1e-94) {
tmp = t_0;
} else if (z <= 3.7e+37) {
tmp = t_2;
} else if (z <= 3.5e+129) {
tmp = t_0;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z): t_0 = 1.0 + ((x - z) * (4.0 / y)) t_1 = 4.0 + (-4.0 * (z / y)) t_2 = 4.0 + (4.0 * (x / y)) tmp = 0 if z <= -1.2e+175: tmp = t_1 elif z <= -3.5e-13: tmp = t_0 elif z <= -2.55e-77: tmp = t_2 elif z <= -2.1e-94: tmp = t_0 elif z <= 3.7e+37: tmp = t_2 elif z <= 3.5e+129: tmp = t_0 else: tmp = t_1 return tmp
function code(x, y, z) t_0 = Float64(1.0 + Float64(Float64(x - z) * Float64(4.0 / y))) t_1 = Float64(4.0 + Float64(-4.0 * Float64(z / y))) t_2 = Float64(4.0 + Float64(4.0 * Float64(x / y))) tmp = 0.0 if (z <= -1.2e+175) tmp = t_1; elseif (z <= -3.5e-13) tmp = t_0; elseif (z <= -2.55e-77) tmp = t_2; elseif (z <= -2.1e-94) tmp = t_0; elseif (z <= 3.7e+37) tmp = t_2; elseif (z <= 3.5e+129) tmp = t_0; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z) t_0 = 1.0 + ((x - z) * (4.0 / y)); t_1 = 4.0 + (-4.0 * (z / y)); t_2 = 4.0 + (4.0 * (x / y)); tmp = 0.0; if (z <= -1.2e+175) tmp = t_1; elseif (z <= -3.5e-13) tmp = t_0; elseif (z <= -2.55e-77) tmp = t_2; elseif (z <= -2.1e-94) tmp = t_0; elseif (z <= 3.7e+37) tmp = t_2; elseif (z <= 3.5e+129) tmp = t_0; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(1.0 + N[(N[(x - z), $MachinePrecision] * N[(4.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(4.0 + N[(-4.0 * N[(z / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(4.0 + N[(4.0 * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.2e+175], t$95$1, If[LessEqual[z, -3.5e-13], t$95$0, If[LessEqual[z, -2.55e-77], t$95$2, If[LessEqual[z, -2.1e-94], t$95$0, If[LessEqual[z, 3.7e+37], t$95$2, If[LessEqual[z, 3.5e+129], t$95$0, t$95$1]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 1 + \left(x - z\right) \cdot \frac{4}{y}\\
t_1 := 4 + -4 \cdot \frac{z}{y}\\
t_2 := 4 + 4 \cdot \frac{x}{y}\\
\mathbf{if}\;z \leq -1.2 \cdot 10^{+175}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -3.5 \cdot 10^{-13}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -2.55 \cdot 10^{-77}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;z \leq -2.1 \cdot 10^{-94}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq 3.7 \cdot 10^{+37}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;z \leq 3.5 \cdot 10^{+129}:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -1.2e175 or 3.4999999999999998e129 < z Initial program 99.9%
Taylor expanded in y around inf 100.0%
+-commutative100.0%
associate-*r/100.0%
Simplified100.0%
Taylor expanded in x around 0 93.0%
Taylor expanded in z around 0 93.0%
if -1.2e175 < z < -3.5000000000000002e-13 or -2.55000000000000016e-77 < z < -2.1000000000000001e-94 or 3.6999999999999999e37 < z < 3.4999999999999998e129Initial program 100.0%
Taylor expanded in y around 0 85.6%
*-lft-identity85.6%
associate-*l/85.3%
associate-*r*85.3%
associate-*r/85.3%
metadata-eval85.3%
Simplified85.3%
if -3.5000000000000002e-13 < z < -2.55000000000000016e-77 or -2.1000000000000001e-94 < z < 3.6999999999999999e37Initial program 99.9%
Taylor expanded in y around inf 100.0%
+-commutative100.0%
associate-*r/100.0%
Simplified100.0%
Taylor expanded in x around inf 92.1%
associate-*r/92.1%
associate-*l/91.9%
associate-/r/92.0%
Simplified92.0%
Taylor expanded in y around inf 92.1%
Final simplification90.5%
(FPCore (x y z)
:precision binary64
(if (<= x -2.7e+134)
(+ 4.0 (* 4.0 (/ x y)))
(if (or (<= x -3.4e-66)
(and (not (<= x 1.16e+27))
(or (<= x 1.4e+60) (not (<= x 1.5e+77)))))
(+ 1.0 (/ (* 4.0 (- x z)) y))
(+ 4.0 (* -4.0 (/ z y))))))
double code(double x, double y, double z) {
double tmp;
if (x <= -2.7e+134) {
tmp = 4.0 + (4.0 * (x / y));
} else if ((x <= -3.4e-66) || (!(x <= 1.16e+27) && ((x <= 1.4e+60) || !(x <= 1.5e+77)))) {
tmp = 1.0 + ((4.0 * (x - z)) / y);
} else {
tmp = 4.0 + (-4.0 * (z / y));
}
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.7d+134)) then
tmp = 4.0d0 + (4.0d0 * (x / y))
else if ((x <= (-3.4d-66)) .or. (.not. (x <= 1.16d+27)) .and. (x <= 1.4d+60) .or. (.not. (x <= 1.5d+77))) then
tmp = 1.0d0 + ((4.0d0 * (x - z)) / y)
else
tmp = 4.0d0 + ((-4.0d0) * (z / y))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= -2.7e+134) {
tmp = 4.0 + (4.0 * (x / y));
} else if ((x <= -3.4e-66) || (!(x <= 1.16e+27) && ((x <= 1.4e+60) || !(x <= 1.5e+77)))) {
tmp = 1.0 + ((4.0 * (x - z)) / y);
} else {
tmp = 4.0 + (-4.0 * (z / y));
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= -2.7e+134: tmp = 4.0 + (4.0 * (x / y)) elif (x <= -3.4e-66) or (not (x <= 1.16e+27) and ((x <= 1.4e+60) or not (x <= 1.5e+77))): tmp = 1.0 + ((4.0 * (x - z)) / y) else: tmp = 4.0 + (-4.0 * (z / y)) return tmp
function code(x, y, z) tmp = 0.0 if (x <= -2.7e+134) tmp = Float64(4.0 + Float64(4.0 * Float64(x / y))); elseif ((x <= -3.4e-66) || (!(x <= 1.16e+27) && ((x <= 1.4e+60) || !(x <= 1.5e+77)))) tmp = Float64(1.0 + Float64(Float64(4.0 * Float64(x - z)) / y)); else tmp = Float64(4.0 + Float64(-4.0 * Float64(z / y))); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= -2.7e+134) tmp = 4.0 + (4.0 * (x / y)); elseif ((x <= -3.4e-66) || (~((x <= 1.16e+27)) && ((x <= 1.4e+60) || ~((x <= 1.5e+77))))) tmp = 1.0 + ((4.0 * (x - z)) / y); else tmp = 4.0 + (-4.0 * (z / y)); end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, -2.7e+134], N[(4.0 + N[(4.0 * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[x, -3.4e-66], And[N[Not[LessEqual[x, 1.16e+27]], $MachinePrecision], Or[LessEqual[x, 1.4e+60], N[Not[LessEqual[x, 1.5e+77]], $MachinePrecision]]]], N[(1.0 + N[(N[(4.0 * N[(x - z), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(4.0 + N[(-4.0 * N[(z / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -2.7 \cdot 10^{+134}:\\
\;\;\;\;4 + 4 \cdot \frac{x}{y}\\
\mathbf{elif}\;x \leq -3.4 \cdot 10^{-66} \lor \neg \left(x \leq 1.16 \cdot 10^{+27}\right) \land \left(x \leq 1.4 \cdot 10^{+60} \lor \neg \left(x \leq 1.5 \cdot 10^{+77}\right)\right):\\
\;\;\;\;1 + \frac{4 \cdot \left(x - z\right)}{y}\\
\mathbf{else}:\\
\;\;\;\;4 + -4 \cdot \frac{z}{y}\\
\end{array}
\end{array}
if x < -2.7e134Initial program 100.0%
Taylor expanded in y around inf 100.0%
+-commutative100.0%
associate-*r/100.0%
Simplified100.0%
Taylor expanded in x around inf 93.0%
associate-*r/93.0%
associate-*l/92.8%
associate-/r/92.9%
Simplified92.9%
Taylor expanded in y around inf 93.0%
if -2.7e134 < x < -3.39999999999999997e-66 or 1.16e27 < x < 1.4e60 or 1.4999999999999999e77 < x Initial program 99.9%
Taylor expanded in x around inf 83.8%
if -3.39999999999999997e-66 < x < 1.16e27 or 1.4e60 < x < 1.4999999999999999e77Initial program 99.9%
Taylor expanded in y around inf 100.0%
+-commutative100.0%
associate-*r/100.0%
Simplified100.0%
Taylor expanded in x around 0 92.1%
Taylor expanded in z around 0 92.1%
Final simplification88.8%
(FPCore (x y z)
:precision binary64
(if (or (<= z -3.5e+68)
(not
(or (<= z -4.8e-6) (and (not (<= z -2.85e-15)) (<= z 1.35e+29)))))
(+ 4.0 (* -4.0 (/ z y)))
(+ 4.0 (* 4.0 (/ x y)))))
double code(double x, double y, double z) {
double tmp;
if ((z <= -3.5e+68) || !((z <= -4.8e-6) || (!(z <= -2.85e-15) && (z <= 1.35e+29)))) {
tmp = 4.0 + (-4.0 * (z / y));
} else {
tmp = 4.0 + (4.0 * (x / y));
}
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 <= (-3.5d+68)) .or. (.not. (z <= (-4.8d-6)) .or. (.not. (z <= (-2.85d-15))) .and. (z <= 1.35d+29))) then
tmp = 4.0d0 + ((-4.0d0) * (z / y))
else
tmp = 4.0d0 + (4.0d0 * (x / y))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((z <= -3.5e+68) || !((z <= -4.8e-6) || (!(z <= -2.85e-15) && (z <= 1.35e+29)))) {
tmp = 4.0 + (-4.0 * (z / y));
} else {
tmp = 4.0 + (4.0 * (x / y));
}
return tmp;
}
def code(x, y, z): tmp = 0 if (z <= -3.5e+68) or not ((z <= -4.8e-6) or (not (z <= -2.85e-15) and (z <= 1.35e+29))): tmp = 4.0 + (-4.0 * (z / y)) else: tmp = 4.0 + (4.0 * (x / y)) return tmp
function code(x, y, z) tmp = 0.0 if ((z <= -3.5e+68) || !((z <= -4.8e-6) || (!(z <= -2.85e-15) && (z <= 1.35e+29)))) tmp = Float64(4.0 + Float64(-4.0 * Float64(z / y))); else tmp = Float64(4.0 + Float64(4.0 * Float64(x / y))); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((z <= -3.5e+68) || ~(((z <= -4.8e-6) || (~((z <= -2.85e-15)) && (z <= 1.35e+29))))) tmp = 4.0 + (-4.0 * (z / y)); else tmp = 4.0 + (4.0 * (x / y)); end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[z, -3.5e+68], N[Not[Or[LessEqual[z, -4.8e-6], And[N[Not[LessEqual[z, -2.85e-15]], $MachinePrecision], LessEqual[z, 1.35e+29]]]], $MachinePrecision]], N[(4.0 + N[(-4.0 * N[(z / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(4.0 + N[(4.0 * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.5 \cdot 10^{+68} \lor \neg \left(z \leq -4.8 \cdot 10^{-6} \lor \neg \left(z \leq -2.85 \cdot 10^{-15}\right) \land z \leq 1.35 \cdot 10^{+29}\right):\\
\;\;\;\;4 + -4 \cdot \frac{z}{y}\\
\mathbf{else}:\\
\;\;\;\;4 + 4 \cdot \frac{x}{y}\\
\end{array}
\end{array}
if z < -3.49999999999999977e68 or -4.7999999999999998e-6 < z < -2.8500000000000002e-15 or 1.35e29 < z Initial program 99.9%
Taylor expanded in y around inf 100.0%
+-commutative100.0%
associate-*r/100.0%
Simplified100.0%
Taylor expanded in x around 0 85.5%
Taylor expanded in z around 0 85.5%
if -3.49999999999999977e68 < z < -4.7999999999999998e-6 or -2.8500000000000002e-15 < z < 1.35e29Initial program 99.9%
Taylor expanded in y around inf 100.0%
+-commutative100.0%
associate-*r/100.0%
Simplified100.0%
Taylor expanded in x around inf 88.7%
associate-*r/88.7%
associate-*l/88.6%
associate-/r/88.6%
Simplified88.6%
Taylor expanded in y around inf 88.7%
Final simplification87.3%
(FPCore (x y z)
:precision binary64
(if (or (<= z -1.42e-9)
(not
(or (<= z -2.15e-77) (and (not (<= z -2.4e-111)) (<= z 3.5e+15)))))
(+ 1.0 (* z (/ -4.0 y)))
4.0))
double code(double x, double y, double z) {
double tmp;
if ((z <= -1.42e-9) || !((z <= -2.15e-77) || (!(z <= -2.4e-111) && (z <= 3.5e+15)))) {
tmp = 1.0 + (z * (-4.0 / y));
} else {
tmp = 4.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 ((z <= (-1.42d-9)) .or. (.not. (z <= (-2.15d-77)) .or. (.not. (z <= (-2.4d-111))) .and. (z <= 3.5d+15))) then
tmp = 1.0d0 + (z * ((-4.0d0) / y))
else
tmp = 4.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((z <= -1.42e-9) || !((z <= -2.15e-77) || (!(z <= -2.4e-111) && (z <= 3.5e+15)))) {
tmp = 1.0 + (z * (-4.0 / y));
} else {
tmp = 4.0;
}
return tmp;
}
def code(x, y, z): tmp = 0 if (z <= -1.42e-9) or not ((z <= -2.15e-77) or (not (z <= -2.4e-111) and (z <= 3.5e+15))): tmp = 1.0 + (z * (-4.0 / y)) else: tmp = 4.0 return tmp
function code(x, y, z) tmp = 0.0 if ((z <= -1.42e-9) || !((z <= -2.15e-77) || (!(z <= -2.4e-111) && (z <= 3.5e+15)))) tmp = Float64(1.0 + Float64(z * Float64(-4.0 / y))); else tmp = 4.0; end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((z <= -1.42e-9) || ~(((z <= -2.15e-77) || (~((z <= -2.4e-111)) && (z <= 3.5e+15))))) tmp = 1.0 + (z * (-4.0 / y)); else tmp = 4.0; end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[z, -1.42e-9], N[Not[Or[LessEqual[z, -2.15e-77], And[N[Not[LessEqual[z, -2.4e-111]], $MachinePrecision], LessEqual[z, 3.5e+15]]]], $MachinePrecision]], N[(1.0 + N[(z * N[(-4.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 4.0]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.42 \cdot 10^{-9} \lor \neg \left(z \leq -2.15 \cdot 10^{-77} \lor \neg \left(z \leq -2.4 \cdot 10^{-111}\right) \land z \leq 3.5 \cdot 10^{+15}\right):\\
\;\;\;\;1 + z \cdot \frac{-4}{y}\\
\mathbf{else}:\\
\;\;\;\;4\\
\end{array}
\end{array}
if z < -1.4200000000000001e-9 or -2.1500000000000001e-77 < z < -2.4000000000000001e-111 or 3.5e15 < z Initial program 100.0%
Taylor expanded in z around inf 62.9%
metadata-eval62.9%
distribute-lft-neg-in62.9%
*-lft-identity62.9%
associate-*l/62.7%
associate-*l*62.7%
*-commutative62.7%
distribute-rgt-neg-in62.7%
associate-*r/62.7%
metadata-eval62.7%
distribute-neg-frac62.7%
metadata-eval62.7%
Simplified62.7%
if -1.4200000000000001e-9 < z < -2.1500000000000001e-77 or -2.4000000000000001e-111 < z < 3.5e15Initial program 99.9%
Taylor expanded in y around inf 100.0%
+-commutative100.0%
associate-*r/100.0%
Simplified100.0%
Taylor expanded in x around 0 53.2%
Taylor expanded in z around 0 46.5%
Final simplification55.6%
(FPCore (x y z)
:precision binary64
(if (or (<= z -7.2e-14)
(not
(or (<= z -2.25e-76) (and (not (<= z -2.45e-113)) (<= z 4.7e+16)))))
(/ (* z -4.0) y)
4.0))
double code(double x, double y, double z) {
double tmp;
if ((z <= -7.2e-14) || !((z <= -2.25e-76) || (!(z <= -2.45e-113) && (z <= 4.7e+16)))) {
tmp = (z * -4.0) / y;
} else {
tmp = 4.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 ((z <= (-7.2d-14)) .or. (.not. (z <= (-2.25d-76)) .or. (.not. (z <= (-2.45d-113))) .and. (z <= 4.7d+16))) then
tmp = (z * (-4.0d0)) / y
else
tmp = 4.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((z <= -7.2e-14) || !((z <= -2.25e-76) || (!(z <= -2.45e-113) && (z <= 4.7e+16)))) {
tmp = (z * -4.0) / y;
} else {
tmp = 4.0;
}
return tmp;
}
def code(x, y, z): tmp = 0 if (z <= -7.2e-14) or not ((z <= -2.25e-76) or (not (z <= -2.45e-113) and (z <= 4.7e+16))): tmp = (z * -4.0) / y else: tmp = 4.0 return tmp
function code(x, y, z) tmp = 0.0 if ((z <= -7.2e-14) || !((z <= -2.25e-76) || (!(z <= -2.45e-113) && (z <= 4.7e+16)))) tmp = Float64(Float64(z * -4.0) / y); else tmp = 4.0; end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((z <= -7.2e-14) || ~(((z <= -2.25e-76) || (~((z <= -2.45e-113)) && (z <= 4.7e+16))))) tmp = (z * -4.0) / y; else tmp = 4.0; end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[z, -7.2e-14], N[Not[Or[LessEqual[z, -2.25e-76], And[N[Not[LessEqual[z, -2.45e-113]], $MachinePrecision], LessEqual[z, 4.7e+16]]]], $MachinePrecision]], N[(N[(z * -4.0), $MachinePrecision] / y), $MachinePrecision], 4.0]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -7.2 \cdot 10^{-14} \lor \neg \left(z \leq -2.25 \cdot 10^{-76} \lor \neg \left(z \leq -2.45 \cdot 10^{-113}\right) \land z \leq 4.7 \cdot 10^{+16}\right):\\
\;\;\;\;\frac{z \cdot -4}{y}\\
\mathbf{else}:\\
\;\;\;\;4\\
\end{array}
\end{array}
if z < -7.1999999999999996e-14 or -2.25e-76 < z < -2.4500000000000001e-113 or 4.7e16 < z Initial program 100.0%
Taylor expanded in y around inf 100.0%
+-commutative100.0%
associate-*r/100.0%
Simplified100.0%
Taylor expanded in x around 0 78.8%
Taylor expanded in z around inf 60.0%
associate-*r/60.0%
Simplified60.0%
if -7.1999999999999996e-14 < z < -2.25e-76 or -2.4500000000000001e-113 < z < 4.7e16Initial program 99.9%
Taylor expanded in y around inf 100.0%
+-commutative100.0%
associate-*r/100.0%
Simplified100.0%
Taylor expanded in x around 0 52.8%
Taylor expanded in z around 0 46.0%
Final simplification53.9%
(FPCore (x y z)
:precision binary64
(if (or (<= z -2.2e-8)
(and (not (<= z -1.7e-76))
(or (<= z -6.9e-110) (not (<= z 26000000000000.0)))))
(* z (/ -4.0 y))
4.0))
double code(double x, double y, double z) {
double tmp;
if ((z <= -2.2e-8) || (!(z <= -1.7e-76) && ((z <= -6.9e-110) || !(z <= 26000000000000.0)))) {
tmp = z * (-4.0 / y);
} else {
tmp = 4.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 ((z <= (-2.2d-8)) .or. (.not. (z <= (-1.7d-76))) .and. (z <= (-6.9d-110)) .or. (.not. (z <= 26000000000000.0d0))) then
tmp = z * ((-4.0d0) / y)
else
tmp = 4.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((z <= -2.2e-8) || (!(z <= -1.7e-76) && ((z <= -6.9e-110) || !(z <= 26000000000000.0)))) {
tmp = z * (-4.0 / y);
} else {
tmp = 4.0;
}
return tmp;
}
def code(x, y, z): tmp = 0 if (z <= -2.2e-8) or (not (z <= -1.7e-76) and ((z <= -6.9e-110) or not (z <= 26000000000000.0))): tmp = z * (-4.0 / y) else: tmp = 4.0 return tmp
function code(x, y, z) tmp = 0.0 if ((z <= -2.2e-8) || (!(z <= -1.7e-76) && ((z <= -6.9e-110) || !(z <= 26000000000000.0)))) tmp = Float64(z * Float64(-4.0 / y)); else tmp = 4.0; end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((z <= -2.2e-8) || (~((z <= -1.7e-76)) && ((z <= -6.9e-110) || ~((z <= 26000000000000.0))))) tmp = z * (-4.0 / y); else tmp = 4.0; end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[z, -2.2e-8], And[N[Not[LessEqual[z, -1.7e-76]], $MachinePrecision], Or[LessEqual[z, -6.9e-110], N[Not[LessEqual[z, 26000000000000.0]], $MachinePrecision]]]], N[(z * N[(-4.0 / y), $MachinePrecision]), $MachinePrecision], 4.0]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.2 \cdot 10^{-8} \lor \neg \left(z \leq -1.7 \cdot 10^{-76}\right) \land \left(z \leq -6.9 \cdot 10^{-110} \lor \neg \left(z \leq 26000000000000\right)\right):\\
\;\;\;\;z \cdot \frac{-4}{y}\\
\mathbf{else}:\\
\;\;\;\;4\\
\end{array}
\end{array}
if z < -2.1999999999999998e-8 or -1.7e-76 < z < -6.9000000000000004e-110 or 2.6e13 < z Initial program 100.0%
Taylor expanded in y around inf 100.0%
+-commutative100.0%
associate-*r/100.0%
Simplified100.0%
Taylor expanded in x around 0 79.0%
Taylor expanded in z around inf 59.6%
*-commutative59.6%
associate-*l/59.6%
associate-*r/59.4%
Simplified59.4%
if -2.1999999999999998e-8 < z < -1.7e-76 or -6.9000000000000004e-110 < z < 2.6e13Initial program 99.9%
Taylor expanded in y around inf 100.0%
+-commutative100.0%
associate-*r/100.0%
Simplified100.0%
Taylor expanded in x around 0 52.4%
Taylor expanded in z around 0 45.5%
Final simplification53.4%
(FPCore (x y z)
:precision binary64
(if (<= z -7.6e-9)
(* z (/ -4.0 y))
(if (<= z -1.55e-75)
4.0
(if (or (<= z -5.5e-110) (not (<= z 9e+14))) (/ -4.0 (/ y z)) 4.0))))
double code(double x, double y, double z) {
double tmp;
if (z <= -7.6e-9) {
tmp = z * (-4.0 / y);
} else if (z <= -1.55e-75) {
tmp = 4.0;
} else if ((z <= -5.5e-110) || !(z <= 9e+14)) {
tmp = -4.0 / (y / z);
} else {
tmp = 4.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 (z <= (-7.6d-9)) then
tmp = z * ((-4.0d0) / y)
else if (z <= (-1.55d-75)) then
tmp = 4.0d0
else if ((z <= (-5.5d-110)) .or. (.not. (z <= 9d+14))) then
tmp = (-4.0d0) / (y / z)
else
tmp = 4.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (z <= -7.6e-9) {
tmp = z * (-4.0 / y);
} else if (z <= -1.55e-75) {
tmp = 4.0;
} else if ((z <= -5.5e-110) || !(z <= 9e+14)) {
tmp = -4.0 / (y / z);
} else {
tmp = 4.0;
}
return tmp;
}
def code(x, y, z): tmp = 0 if z <= -7.6e-9: tmp = z * (-4.0 / y) elif z <= -1.55e-75: tmp = 4.0 elif (z <= -5.5e-110) or not (z <= 9e+14): tmp = -4.0 / (y / z) else: tmp = 4.0 return tmp
function code(x, y, z) tmp = 0.0 if (z <= -7.6e-9) tmp = Float64(z * Float64(-4.0 / y)); elseif (z <= -1.55e-75) tmp = 4.0; elseif ((z <= -5.5e-110) || !(z <= 9e+14)) tmp = Float64(-4.0 / Float64(y / z)); else tmp = 4.0; end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (z <= -7.6e-9) tmp = z * (-4.0 / y); elseif (z <= -1.55e-75) tmp = 4.0; elseif ((z <= -5.5e-110) || ~((z <= 9e+14))) tmp = -4.0 / (y / z); else tmp = 4.0; end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[z, -7.6e-9], N[(z * N[(-4.0 / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -1.55e-75], 4.0, If[Or[LessEqual[z, -5.5e-110], N[Not[LessEqual[z, 9e+14]], $MachinePrecision]], N[(-4.0 / N[(y / z), $MachinePrecision]), $MachinePrecision], 4.0]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -7.6 \cdot 10^{-9}:\\
\;\;\;\;z \cdot \frac{-4}{y}\\
\mathbf{elif}\;z \leq -1.55 \cdot 10^{-75}:\\
\;\;\;\;4\\
\mathbf{elif}\;z \leq -5.5 \cdot 10^{-110} \lor \neg \left(z \leq 9 \cdot 10^{+14}\right):\\
\;\;\;\;\frac{-4}{\frac{y}{z}}\\
\mathbf{else}:\\
\;\;\;\;4\\
\end{array}
\end{array}
if z < -7.60000000000000023e-9Initial program 100.0%
Taylor expanded in y around inf 100.0%
+-commutative100.0%
associate-*r/100.0%
Simplified100.0%
Taylor expanded in x around 0 81.9%
Taylor expanded in z around inf 63.5%
*-commutative63.5%
associate-*l/63.5%
associate-*r/63.3%
Simplified63.3%
if -7.60000000000000023e-9 < z < -1.55000000000000003e-75 or -5.4999999999999998e-110 < z < 9e14Initial program 99.9%
Taylor expanded in y around inf 100.0%
+-commutative100.0%
associate-*r/100.0%
Simplified100.0%
Taylor expanded in x around 0 52.4%
Taylor expanded in z around 0 45.5%
if -1.55000000000000003e-75 < z < -5.4999999999999998e-110 or 9e14 < z Initial program 100.0%
Taylor expanded in y around inf 100.0%
+-commutative100.0%
associate-*r/100.0%
Simplified100.0%
Taylor expanded in x around 0 76.4%
Taylor expanded in z around inf 56.0%
*-commutative56.0%
associate-*l/56.0%
associate-*r/55.9%
Simplified55.9%
associate-*r/56.0%
*-commutative56.0%
associate-*r/56.0%
clear-num55.9%
un-div-inv55.9%
Applied egg-rr55.9%
Final simplification53.4%
(FPCore (x y z) :precision binary64 (if (or (<= x -1.02e+234) (not (<= x 3e+87))) (+ 1.0 (* 4.0 (/ x y))) (+ 4.0 (* -4.0 (/ z y)))))
double code(double x, double y, double z) {
double tmp;
if ((x <= -1.02e+234) || !(x <= 3e+87)) {
tmp = 1.0 + (4.0 * (x / y));
} else {
tmp = 4.0 + (-4.0 * (z / y));
}
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.02d+234)) .or. (.not. (x <= 3d+87))) then
tmp = 1.0d0 + (4.0d0 * (x / y))
else
tmp = 4.0d0 + ((-4.0d0) * (z / y))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((x <= -1.02e+234) || !(x <= 3e+87)) {
tmp = 1.0 + (4.0 * (x / y));
} else {
tmp = 4.0 + (-4.0 * (z / y));
}
return tmp;
}
def code(x, y, z): tmp = 0 if (x <= -1.02e+234) or not (x <= 3e+87): tmp = 1.0 + (4.0 * (x / y)) else: tmp = 4.0 + (-4.0 * (z / y)) return tmp
function code(x, y, z) tmp = 0.0 if ((x <= -1.02e+234) || !(x <= 3e+87)) tmp = Float64(1.0 + Float64(4.0 * Float64(x / y))); else tmp = Float64(4.0 + Float64(-4.0 * Float64(z / y))); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((x <= -1.02e+234) || ~((x <= 3e+87))) tmp = 1.0 + (4.0 * (x / y)); else tmp = 4.0 + (-4.0 * (z / y)); end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[x, -1.02e+234], N[Not[LessEqual[x, 3e+87]], $MachinePrecision]], N[(1.0 + N[(4.0 * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(4.0 + N[(-4.0 * N[(z / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.02 \cdot 10^{+234} \lor \neg \left(x \leq 3 \cdot 10^{+87}\right):\\
\;\;\;\;1 + 4 \cdot \frac{x}{y}\\
\mathbf{else}:\\
\;\;\;\;4 + -4 \cdot \frac{z}{y}\\
\end{array}
\end{array}
if x < -1.02000000000000002e234 or 2.9999999999999999e87 < x Initial program 99.9%
Taylor expanded in x around inf 82.7%
*-commutative82.7%
Simplified82.7%
if -1.02000000000000002e234 < x < 2.9999999999999999e87Initial program 99.9%
Taylor expanded in y around inf 100.0%
+-commutative100.0%
associate-*r/100.0%
Simplified100.0%
Taylor expanded in x around 0 80.7%
Taylor expanded in z around 0 80.7%
Final simplification81.2%
(FPCore (x y z) :precision binary64 (if (or (<= x -1700000000000.0) (not (<= x 5.7e-22))) (+ 1.0 (* 4.0 (/ x y))) (+ 1.0 (/ (* z -4.0) y))))
double code(double x, double y, double z) {
double tmp;
if ((x <= -1700000000000.0) || !(x <= 5.7e-22)) {
tmp = 1.0 + (4.0 * (x / y));
} else {
tmp = 1.0 + ((z * -4.0) / y);
}
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 <= (-1700000000000.0d0)) .or. (.not. (x <= 5.7d-22))) then
tmp = 1.0d0 + (4.0d0 * (x / y))
else
tmp = 1.0d0 + ((z * (-4.0d0)) / y)
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((x <= -1700000000000.0) || !(x <= 5.7e-22)) {
tmp = 1.0 + (4.0 * (x / y));
} else {
tmp = 1.0 + ((z * -4.0) / y);
}
return tmp;
}
def code(x, y, z): tmp = 0 if (x <= -1700000000000.0) or not (x <= 5.7e-22): tmp = 1.0 + (4.0 * (x / y)) else: tmp = 1.0 + ((z * -4.0) / y) return tmp
function code(x, y, z) tmp = 0.0 if ((x <= -1700000000000.0) || !(x <= 5.7e-22)) tmp = Float64(1.0 + Float64(4.0 * Float64(x / y))); else tmp = Float64(1.0 + Float64(Float64(z * -4.0) / y)); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((x <= -1700000000000.0) || ~((x <= 5.7e-22))) tmp = 1.0 + (4.0 * (x / y)); else tmp = 1.0 + ((z * -4.0) / y); end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[x, -1700000000000.0], N[Not[LessEqual[x, 5.7e-22]], $MachinePrecision]], N[(1.0 + N[(4.0 * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1.0 + N[(N[(z * -4.0), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1700000000000 \lor \neg \left(x \leq 5.7 \cdot 10^{-22}\right):\\
\;\;\;\;1 + 4 \cdot \frac{x}{y}\\
\mathbf{else}:\\
\;\;\;\;1 + \frac{z \cdot -4}{y}\\
\end{array}
\end{array}
if x < -1.7e12 or 5.6999999999999996e-22 < x Initial program 100.0%
Taylor expanded in x around inf 61.8%
*-commutative61.8%
Simplified61.8%
if -1.7e12 < x < 5.6999999999999996e-22Initial program 99.9%
Taylor expanded in z around inf 58.7%
*-commutative58.7%
associate-*l/58.7%
Simplified58.7%
Final simplification60.3%
(FPCore (x y z) :precision binary64 (if (or (<= x -1900000000000.0) (not (<= x 1.12e-27))) (+ 1.0 (* 4.0 (/ x y))) (+ 1.0 (* z (/ -4.0 y)))))
double code(double x, double y, double z) {
double tmp;
if ((x <= -1900000000000.0) || !(x <= 1.12e-27)) {
tmp = 1.0 + (4.0 * (x / y));
} else {
tmp = 1.0 + (z * (-4.0 / y));
}
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 <= (-1900000000000.0d0)) .or. (.not. (x <= 1.12d-27))) then
tmp = 1.0d0 + (4.0d0 * (x / y))
else
tmp = 1.0d0 + (z * ((-4.0d0) / y))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((x <= -1900000000000.0) || !(x <= 1.12e-27)) {
tmp = 1.0 + (4.0 * (x / y));
} else {
tmp = 1.0 + (z * (-4.0 / y));
}
return tmp;
}
def code(x, y, z): tmp = 0 if (x <= -1900000000000.0) or not (x <= 1.12e-27): tmp = 1.0 + (4.0 * (x / y)) else: tmp = 1.0 + (z * (-4.0 / y)) return tmp
function code(x, y, z) tmp = 0.0 if ((x <= -1900000000000.0) || !(x <= 1.12e-27)) tmp = Float64(1.0 + Float64(4.0 * Float64(x / y))); else tmp = Float64(1.0 + Float64(z * Float64(-4.0 / y))); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((x <= -1900000000000.0) || ~((x <= 1.12e-27))) tmp = 1.0 + (4.0 * (x / y)); else tmp = 1.0 + (z * (-4.0 / y)); end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[x, -1900000000000.0], N[Not[LessEqual[x, 1.12e-27]], $MachinePrecision]], N[(1.0 + N[(4.0 * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1.0 + N[(z * N[(-4.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1900000000000 \lor \neg \left(x \leq 1.12 \cdot 10^{-27}\right):\\
\;\;\;\;1 + 4 \cdot \frac{x}{y}\\
\mathbf{else}:\\
\;\;\;\;1 + z \cdot \frac{-4}{y}\\
\end{array}
\end{array}
if x < -1.9e12 or 1.1199999999999999e-27 < x Initial program 100.0%
Taylor expanded in x around inf 61.4%
*-commutative61.4%
Simplified61.4%
if -1.9e12 < x < 1.1199999999999999e-27Initial program 99.9%
Taylor expanded in z around inf 58.4%
metadata-eval58.4%
distribute-lft-neg-in58.4%
*-lft-identity58.4%
associate-*l/58.2%
associate-*l*58.2%
*-commutative58.2%
distribute-rgt-neg-in58.2%
associate-*r/58.2%
metadata-eval58.2%
distribute-neg-frac58.2%
metadata-eval58.2%
Simplified58.2%
Final simplification59.8%
(FPCore (x y z) :precision binary64 4.0)
double code(double x, double y, double z) {
return 4.0;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = 4.0d0
end function
public static double code(double x, double y, double z) {
return 4.0;
}
def code(x, y, z): return 4.0
function code(x, y, z) return 4.0 end
function tmp = code(x, y, z) tmp = 4.0; end
code[x_, y_, z_] := 4.0
\begin{array}{l}
\\
4
\end{array}
Initial program 99.9%
Taylor expanded in y around inf 100.0%
+-commutative100.0%
associate-*r/100.0%
Simplified100.0%
Taylor expanded in x around 0 67.5%
Taylor expanded in z around 0 31.5%
(FPCore (x y z) :precision binary64 1.0)
double code(double x, double y, double z) {
return 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 = 1.0d0
end function
public static double code(double x, double y, double z) {
return 1.0;
}
def code(x, y, z): return 1.0
function code(x, y, z) return 1.0 end
function tmp = code(x, y, z) tmp = 1.0; end
code[x_, y_, z_] := 1.0
\begin{array}{l}
\\
1
\end{array}
Initial program 99.9%
Taylor expanded in x around inf 39.3%
*-commutative39.3%
Simplified39.3%
Taylor expanded in x around 0 7.7%
herbie shell --seed 2024107
(FPCore (x y z)
:name "Data.Array.Repa.Algorithms.ColorRamp:rampColorHotToCold from repa-algorithms-3.4.0.1, A"
:precision binary64
(+ 1.0 (/ (* 4.0 (- (+ x (* y 0.75)) z)) y)))