
(FPCore (x y z t) :precision binary64 (/ (* x (- y z)) (- t z)))
double code(double x, double y, double z, double t) {
return (x * (y - z)) / (t - z);
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = (x * (y - z)) / (t - z)
end function
public static double code(double x, double y, double z, double t) {
return (x * (y - z)) / (t - z);
}
def code(x, y, z, t): return (x * (y - z)) / (t - z)
function code(x, y, z, t) return Float64(Float64(x * Float64(y - z)) / Float64(t - z)) end
function tmp = code(x, y, z, t) tmp = (x * (y - z)) / (t - z); end
code[x_, y_, z_, t_] := N[(N[(x * N[(y - z), $MachinePrecision]), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x \cdot \left(y - z\right)}{t - z}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 16 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t) :precision binary64 (/ (* x (- y z)) (- t z)))
double code(double x, double y, double z, double t) {
return (x * (y - z)) / (t - z);
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = (x * (y - z)) / (t - z)
end function
public static double code(double x, double y, double z, double t) {
return (x * (y - z)) / (t - z);
}
def code(x, y, z, t): return (x * (y - z)) / (t - z)
function code(x, y, z, t) return Float64(Float64(x * Float64(y - z)) / Float64(t - z)) end
function tmp = code(x, y, z, t) tmp = (x * (y - z)) / (t - z); end
code[x_, y_, z_, t_] := N[(N[(x * N[(y - z), $MachinePrecision]), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x \cdot \left(y - z\right)}{t - z}
\end{array}
(FPCore (x y z t) :precision binary64 (/ x (/ (- t z) (- y z))))
double code(double x, double y, double z, double t) {
return x / ((t - z) / (y - z));
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = x / ((t - z) / (y - z))
end function
public static double code(double x, double y, double z, double t) {
return x / ((t - z) / (y - z));
}
def code(x, y, z, t): return x / ((t - z) / (y - z))
function code(x, y, z, t) return Float64(x / Float64(Float64(t - z) / Float64(y - z))) end
function tmp = code(x, y, z, t) tmp = x / ((t - z) / (y - z)); end
code[x_, y_, z_, t_] := N[(x / N[(N[(t - z), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x}{\frac{t - z}{y - z}}
\end{array}
Initial program 83.8%
associate-/l*97.2%
Simplified97.2%
clear-num96.8%
un-div-inv97.3%
Applied egg-rr97.3%
Final simplification97.3%
(FPCore (x y z t)
:precision binary64
(if (or (<= z -1.6e+96)
(and (not (<= z -1.15e+43)) (or (<= z -3.1e-124) (not (<= z 0.75)))))
(* x (/ z (- z t)))
(* x (/ y (- t z)))))
double code(double x, double y, double z, double t) {
double tmp;
if ((z <= -1.6e+96) || (!(z <= -1.15e+43) && ((z <= -3.1e-124) || !(z <= 0.75)))) {
tmp = x * (z / (z - t));
} else {
tmp = x * (y / (t - z));
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if ((z <= (-1.6d+96)) .or. (.not. (z <= (-1.15d+43))) .and. (z <= (-3.1d-124)) .or. (.not. (z <= 0.75d0))) then
tmp = x * (z / (z - t))
else
tmp = x * (y / (t - z))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if ((z <= -1.6e+96) || (!(z <= -1.15e+43) && ((z <= -3.1e-124) || !(z <= 0.75)))) {
tmp = x * (z / (z - t));
} else {
tmp = x * (y / (t - z));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (z <= -1.6e+96) or (not (z <= -1.15e+43) and ((z <= -3.1e-124) or not (z <= 0.75))): tmp = x * (z / (z - t)) else: tmp = x * (y / (t - z)) return tmp
function code(x, y, z, t) tmp = 0.0 if ((z <= -1.6e+96) || (!(z <= -1.15e+43) && ((z <= -3.1e-124) || !(z <= 0.75)))) tmp = Float64(x * Float64(z / Float64(z - t))); else tmp = Float64(x * Float64(y / Float64(t - z))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((z <= -1.6e+96) || (~((z <= -1.15e+43)) && ((z <= -3.1e-124) || ~((z <= 0.75))))) tmp = x * (z / (z - t)); else tmp = x * (y / (t - z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[z, -1.6e+96], And[N[Not[LessEqual[z, -1.15e+43]], $MachinePrecision], Or[LessEqual[z, -3.1e-124], N[Not[LessEqual[z, 0.75]], $MachinePrecision]]]], N[(x * N[(z / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(y / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.6 \cdot 10^{+96} \lor \neg \left(z \leq -1.15 \cdot 10^{+43}\right) \land \left(z \leq -3.1 \cdot 10^{-124} \lor \neg \left(z \leq 0.75\right)\right):\\
\;\;\;\;x \cdot \frac{z}{z - t}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{y}{t - z}\\
\end{array}
\end{array}
if z < -1.60000000000000003e96 or -1.1500000000000001e43 < z < -3.0999999999999998e-124 or 0.75 < z Initial program 78.3%
associate-/l*99.1%
Simplified99.1%
Taylor expanded in y around 0 65.3%
mul-1-neg65.3%
associate-/l*83.4%
distribute-rgt-neg-in83.4%
distribute-neg-frac283.4%
Simplified83.4%
Taylor expanded in x around 0 65.3%
associate-/l*83.4%
Simplified83.4%
if -1.60000000000000003e96 < z < -1.1500000000000001e43 or -3.0999999999999998e-124 < z < 0.75Initial program 90.1%
associate-/l*94.9%
Simplified94.9%
Taylor expanded in y around inf 77.2%
associate-/l*80.0%
Simplified80.0%
Final simplification81.8%
(FPCore (x y z t)
:precision binary64
(if (<= z -1.9e+96)
x
(if (or (<= z -4.7e+42) (and (not (<= z -4.1e-10)) (<= z 2.15e+52)))
(* x (/ y (- t z)))
x)))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -1.9e+96) {
tmp = x;
} else if ((z <= -4.7e+42) || (!(z <= -4.1e-10) && (z <= 2.15e+52))) {
tmp = x * (y / (t - z));
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (z <= (-1.9d+96)) then
tmp = x
else if ((z <= (-4.7d+42)) .or. (.not. (z <= (-4.1d-10))) .and. (z <= 2.15d+52)) then
tmp = x * (y / (t - z))
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -1.9e+96) {
tmp = x;
} else if ((z <= -4.7e+42) || (!(z <= -4.1e-10) && (z <= 2.15e+52))) {
tmp = x * (y / (t - z));
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -1.9e+96: tmp = x elif (z <= -4.7e+42) or (not (z <= -4.1e-10) and (z <= 2.15e+52)): tmp = x * (y / (t - z)) else: tmp = x return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -1.9e+96) tmp = x; elseif ((z <= -4.7e+42) || (!(z <= -4.1e-10) && (z <= 2.15e+52))) tmp = Float64(x * Float64(y / Float64(t - z))); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -1.9e+96) tmp = x; elseif ((z <= -4.7e+42) || (~((z <= -4.1e-10)) && (z <= 2.15e+52))) tmp = x * (y / (t - z)); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -1.9e+96], x, If[Or[LessEqual[z, -4.7e+42], And[N[Not[LessEqual[z, -4.1e-10]], $MachinePrecision], LessEqual[z, 2.15e+52]]], N[(x * N[(y / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.9 \cdot 10^{+96}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq -4.7 \cdot 10^{+42} \lor \neg \left(z \leq -4.1 \cdot 10^{-10}\right) \land z \leq 2.15 \cdot 10^{+52}:\\
\;\;\;\;x \cdot \frac{y}{t - z}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if z < -1.9000000000000001e96 or -4.69999999999999986e42 < z < -4.0999999999999998e-10 or 2.15e52 < z Initial program 76.4%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 75.5%
if -1.9000000000000001e96 < z < -4.69999999999999986e42 or -4.0999999999999998e-10 < z < 2.15e52Initial program 89.7%
associate-/l*95.0%
Simplified95.0%
Taylor expanded in y around inf 70.8%
associate-/l*73.7%
Simplified73.7%
Final simplification74.5%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* x (/ z (- z t)))))
(if (<= z -1.6e+96)
t_1
(if (<= z -7.8e+43)
(* x (/ y (- t z)))
(if (or (<= z -1.55e-11) (not (<= z 3.7e+48)))
t_1
(* x (/ (- y z) t)))))))
double code(double x, double y, double z, double t) {
double t_1 = x * (z / (z - t));
double tmp;
if (z <= -1.6e+96) {
tmp = t_1;
} else if (z <= -7.8e+43) {
tmp = x * (y / (t - z));
} else if ((z <= -1.55e-11) || !(z <= 3.7e+48)) {
tmp = t_1;
} else {
tmp = x * ((y - z) / t);
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: t_1
real(8) :: tmp
t_1 = x * (z / (z - t))
if (z <= (-1.6d+96)) then
tmp = t_1
else if (z <= (-7.8d+43)) then
tmp = x * (y / (t - z))
else if ((z <= (-1.55d-11)) .or. (.not. (z <= 3.7d+48))) then
tmp = t_1
else
tmp = x * ((y - z) / t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = x * (z / (z - t));
double tmp;
if (z <= -1.6e+96) {
tmp = t_1;
} else if (z <= -7.8e+43) {
tmp = x * (y / (t - z));
} else if ((z <= -1.55e-11) || !(z <= 3.7e+48)) {
tmp = t_1;
} else {
tmp = x * ((y - z) / t);
}
return tmp;
}
def code(x, y, z, t): t_1 = x * (z / (z - t)) tmp = 0 if z <= -1.6e+96: tmp = t_1 elif z <= -7.8e+43: tmp = x * (y / (t - z)) elif (z <= -1.55e-11) or not (z <= 3.7e+48): tmp = t_1 else: tmp = x * ((y - z) / t) return tmp
function code(x, y, z, t) t_1 = Float64(x * Float64(z / Float64(z - t))) tmp = 0.0 if (z <= -1.6e+96) tmp = t_1; elseif (z <= -7.8e+43) tmp = Float64(x * Float64(y / Float64(t - z))); elseif ((z <= -1.55e-11) || !(z <= 3.7e+48)) tmp = t_1; else tmp = Float64(x * Float64(Float64(y - z) / t)); end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = x * (z / (z - t)); tmp = 0.0; if (z <= -1.6e+96) tmp = t_1; elseif (z <= -7.8e+43) tmp = x * (y / (t - z)); elseif ((z <= -1.55e-11) || ~((z <= 3.7e+48))) tmp = t_1; else tmp = x * ((y - z) / t); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x * N[(z / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.6e+96], t$95$1, If[LessEqual[z, -7.8e+43], N[(x * N[(y / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[z, -1.55e-11], N[Not[LessEqual[z, 3.7e+48]], $MachinePrecision]], t$95$1, N[(x * N[(N[(y - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \frac{z}{z - t}\\
\mathbf{if}\;z \leq -1.6 \cdot 10^{+96}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -7.8 \cdot 10^{+43}:\\
\;\;\;\;x \cdot \frac{y}{t - z}\\
\mathbf{elif}\;z \leq -1.55 \cdot 10^{-11} \lor \neg \left(z \leq 3.7 \cdot 10^{+48}\right):\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{y - z}{t}\\
\end{array}
\end{array}
if z < -1.60000000000000003e96 or -7.8000000000000001e43 < z < -1.55000000000000014e-11 or 3.6999999999999999e48 < z Initial program 76.2%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in y around 0 66.8%
mul-1-neg66.8%
associate-/l*87.3%
distribute-rgt-neg-in87.3%
distribute-neg-frac287.3%
Simplified87.3%
Taylor expanded in x around 0 66.8%
associate-/l*87.3%
Simplified87.3%
if -1.60000000000000003e96 < z < -7.8000000000000001e43Initial program 81.8%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in y around inf 61.9%
associate-/l*68.2%
Simplified68.2%
if -1.55000000000000014e-11 < z < 3.6999999999999999e48Initial program 91.1%
associate-/l*94.3%
Simplified94.3%
Taylor expanded in t around inf 80.0%
associate-/l*80.3%
Simplified80.3%
Final simplification82.8%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* x (/ z (- z t)))))
(if (<= z -1.6e+96)
t_1
(if (<= z -3.75e+43)
(* x (/ y (- t z)))
(if (or (<= z -2.75e-14) (not (<= z 3.7e+48)))
t_1
(* (- y z) (/ x t)))))))
double code(double x, double y, double z, double t) {
double t_1 = x * (z / (z - t));
double tmp;
if (z <= -1.6e+96) {
tmp = t_1;
} else if (z <= -3.75e+43) {
tmp = x * (y / (t - z));
} else if ((z <= -2.75e-14) || !(z <= 3.7e+48)) {
tmp = t_1;
} else {
tmp = (y - z) * (x / t);
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: t_1
real(8) :: tmp
t_1 = x * (z / (z - t))
if (z <= (-1.6d+96)) then
tmp = t_1
else if (z <= (-3.75d+43)) then
tmp = x * (y / (t - z))
else if ((z <= (-2.75d-14)) .or. (.not. (z <= 3.7d+48))) then
tmp = t_1
else
tmp = (y - z) * (x / t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = x * (z / (z - t));
double tmp;
if (z <= -1.6e+96) {
tmp = t_1;
} else if (z <= -3.75e+43) {
tmp = x * (y / (t - z));
} else if ((z <= -2.75e-14) || !(z <= 3.7e+48)) {
tmp = t_1;
} else {
tmp = (y - z) * (x / t);
}
return tmp;
}
def code(x, y, z, t): t_1 = x * (z / (z - t)) tmp = 0 if z <= -1.6e+96: tmp = t_1 elif z <= -3.75e+43: tmp = x * (y / (t - z)) elif (z <= -2.75e-14) or not (z <= 3.7e+48): tmp = t_1 else: tmp = (y - z) * (x / t) return tmp
function code(x, y, z, t) t_1 = Float64(x * Float64(z / Float64(z - t))) tmp = 0.0 if (z <= -1.6e+96) tmp = t_1; elseif (z <= -3.75e+43) tmp = Float64(x * Float64(y / Float64(t - z))); elseif ((z <= -2.75e-14) || !(z <= 3.7e+48)) tmp = t_1; else tmp = Float64(Float64(y - z) * Float64(x / t)); end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = x * (z / (z - t)); tmp = 0.0; if (z <= -1.6e+96) tmp = t_1; elseif (z <= -3.75e+43) tmp = x * (y / (t - z)); elseif ((z <= -2.75e-14) || ~((z <= 3.7e+48))) tmp = t_1; else tmp = (y - z) * (x / t); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x * N[(z / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.6e+96], t$95$1, If[LessEqual[z, -3.75e+43], N[(x * N[(y / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[z, -2.75e-14], N[Not[LessEqual[z, 3.7e+48]], $MachinePrecision]], t$95$1, N[(N[(y - z), $MachinePrecision] * N[(x / t), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \frac{z}{z - t}\\
\mathbf{if}\;z \leq -1.6 \cdot 10^{+96}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -3.75 \cdot 10^{+43}:\\
\;\;\;\;x \cdot \frac{y}{t - z}\\
\mathbf{elif}\;z \leq -2.75 \cdot 10^{-14} \lor \neg \left(z \leq 3.7 \cdot 10^{+48}\right):\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\
\end{array}
\end{array}
if z < -1.60000000000000003e96 or -3.74999999999999984e43 < z < -2.74999999999999996e-14 or 3.6999999999999999e48 < z Initial program 76.2%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in y around 0 66.8%
mul-1-neg66.8%
associate-/l*87.3%
distribute-rgt-neg-in87.3%
distribute-neg-frac287.3%
Simplified87.3%
Taylor expanded in x around 0 66.8%
associate-/l*87.3%
Simplified87.3%
if -1.60000000000000003e96 < z < -3.74999999999999984e43Initial program 81.8%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in y around inf 61.9%
associate-/l*68.2%
Simplified68.2%
if -2.74999999999999996e-14 < z < 3.6999999999999999e48Initial program 91.1%
*-commutative91.1%
associate-/l*94.4%
Simplified94.4%
Taylor expanded in t around inf 80.4%
Final simplification82.8%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* x (/ z (- z t)))))
(if (<= z -1.6e+96)
t_1
(if (<= z -6.3e+43)
(* x (/ y (- t z)))
(if (<= z -4.6e-16)
(- x (/ (* x y) z))
(if (<= z 3.7e+48) (* (- y z) (/ x t)) t_1))))))
double code(double x, double y, double z, double t) {
double t_1 = x * (z / (z - t));
double tmp;
if (z <= -1.6e+96) {
tmp = t_1;
} else if (z <= -6.3e+43) {
tmp = x * (y / (t - z));
} else if (z <= -4.6e-16) {
tmp = x - ((x * y) / z);
} else if (z <= 3.7e+48) {
tmp = (y - z) * (x / t);
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: t_1
real(8) :: tmp
t_1 = x * (z / (z - t))
if (z <= (-1.6d+96)) then
tmp = t_1
else if (z <= (-6.3d+43)) then
tmp = x * (y / (t - z))
else if (z <= (-4.6d-16)) then
tmp = x - ((x * y) / z)
else if (z <= 3.7d+48) then
tmp = (y - z) * (x / t)
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = x * (z / (z - t));
double tmp;
if (z <= -1.6e+96) {
tmp = t_1;
} else if (z <= -6.3e+43) {
tmp = x * (y / (t - z));
} else if (z <= -4.6e-16) {
tmp = x - ((x * y) / z);
} else if (z <= 3.7e+48) {
tmp = (y - z) * (x / t);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t): t_1 = x * (z / (z - t)) tmp = 0 if z <= -1.6e+96: tmp = t_1 elif z <= -6.3e+43: tmp = x * (y / (t - z)) elif z <= -4.6e-16: tmp = x - ((x * y) / z) elif z <= 3.7e+48: tmp = (y - z) * (x / t) else: tmp = t_1 return tmp
function code(x, y, z, t) t_1 = Float64(x * Float64(z / Float64(z - t))) tmp = 0.0 if (z <= -1.6e+96) tmp = t_1; elseif (z <= -6.3e+43) tmp = Float64(x * Float64(y / Float64(t - z))); elseif (z <= -4.6e-16) tmp = Float64(x - Float64(Float64(x * y) / z)); elseif (z <= 3.7e+48) tmp = Float64(Float64(y - z) * Float64(x / t)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = x * (z / (z - t)); tmp = 0.0; if (z <= -1.6e+96) tmp = t_1; elseif (z <= -6.3e+43) tmp = x * (y / (t - z)); elseif (z <= -4.6e-16) tmp = x - ((x * y) / z); elseif (z <= 3.7e+48) tmp = (y - z) * (x / t); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x * N[(z / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.6e+96], t$95$1, If[LessEqual[z, -6.3e+43], N[(x * N[(y / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -4.6e-16], N[(x - N[(N[(x * y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 3.7e+48], N[(N[(y - z), $MachinePrecision] * N[(x / t), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \frac{z}{z - t}\\
\mathbf{if}\;z \leq -1.6 \cdot 10^{+96}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -6.3 \cdot 10^{+43}:\\
\;\;\;\;x \cdot \frac{y}{t - z}\\
\mathbf{elif}\;z \leq -4.6 \cdot 10^{-16}:\\
\;\;\;\;x - \frac{x \cdot y}{z}\\
\mathbf{elif}\;z \leq 3.7 \cdot 10^{+48}:\\
\;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -1.60000000000000003e96 or 3.6999999999999999e48 < z Initial program 74.5%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in y around 0 65.2%
mul-1-neg65.2%
associate-/l*87.2%
distribute-rgt-neg-in87.2%
distribute-neg-frac287.2%
Simplified87.2%
Taylor expanded in x around 0 65.2%
associate-/l*87.2%
Simplified87.2%
if -1.60000000000000003e96 < z < -6.2999999999999998e43Initial program 81.8%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in y around inf 61.9%
associate-/l*68.2%
Simplified68.2%
if -6.2999999999999998e43 < z < -4.5999999999999998e-16Initial program 99.6%
*-commutative99.6%
associate-/l*90.9%
Simplified90.9%
Taylor expanded in t around 0 90.6%
associate-*r/90.6%
neg-mul-190.6%
Simplified90.6%
Taylor expanded in y around 0 99.5%
mul-1-neg99.5%
unsub-neg99.5%
Simplified99.5%
if -4.5999999999999998e-16 < z < 3.6999999999999999e48Initial program 91.1%
*-commutative91.1%
associate-/l*94.4%
Simplified94.4%
Taylor expanded in t around inf 80.4%
Final simplification83.1%
(FPCore (x y z t)
:precision binary64
(if (<= z -1.08e-11)
(/ x (- 1.0 (/ t z)))
(if (<= z -3.5e-272)
(/ (* x (- y z)) t)
(if (<= z 5.2e+48) (* x (/ (- y z) t)) (* x (- (/ y (- z)) -1.0))))))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -1.08e-11) {
tmp = x / (1.0 - (t / z));
} else if (z <= -3.5e-272) {
tmp = (x * (y - z)) / t;
} else if (z <= 5.2e+48) {
tmp = x * ((y - z) / t);
} else {
tmp = x * ((y / -z) - -1.0);
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (z <= (-1.08d-11)) then
tmp = x / (1.0d0 - (t / z))
else if (z <= (-3.5d-272)) then
tmp = (x * (y - z)) / t
else if (z <= 5.2d+48) then
tmp = x * ((y - z) / t)
else
tmp = x * ((y / -z) - (-1.0d0))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -1.08e-11) {
tmp = x / (1.0 - (t / z));
} else if (z <= -3.5e-272) {
tmp = (x * (y - z)) / t;
} else if (z <= 5.2e+48) {
tmp = x * ((y - z) / t);
} else {
tmp = x * ((y / -z) - -1.0);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -1.08e-11: tmp = x / (1.0 - (t / z)) elif z <= -3.5e-272: tmp = (x * (y - z)) / t elif z <= 5.2e+48: tmp = x * ((y - z) / t) else: tmp = x * ((y / -z) - -1.0) return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -1.08e-11) tmp = Float64(x / Float64(1.0 - Float64(t / z))); elseif (z <= -3.5e-272) tmp = Float64(Float64(x * Float64(y - z)) / t); elseif (z <= 5.2e+48) tmp = Float64(x * Float64(Float64(y - z) / t)); else tmp = Float64(x * Float64(Float64(y / Float64(-z)) - -1.0)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -1.08e-11) tmp = x / (1.0 - (t / z)); elseif (z <= -3.5e-272) tmp = (x * (y - z)) / t; elseif (z <= 5.2e+48) tmp = x * ((y - z) / t); else tmp = x * ((y / -z) - -1.0); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -1.08e-11], N[(x / N[(1.0 - N[(t / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -3.5e-272], N[(N[(x * N[(y - z), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[z, 5.2e+48], N[(x * N[(N[(y - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[(y / (-z)), $MachinePrecision] - -1.0), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.08 \cdot 10^{-11}:\\
\;\;\;\;\frac{x}{1 - \frac{t}{z}}\\
\mathbf{elif}\;z \leq -3.5 \cdot 10^{-272}:\\
\;\;\;\;\frac{x \cdot \left(y - z\right)}{t}\\
\mathbf{elif}\;z \leq 5.2 \cdot 10^{+48}:\\
\;\;\;\;x \cdot \frac{y - z}{t}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(\frac{y}{-z} - -1\right)\\
\end{array}
\end{array}
if z < -1.07999999999999992e-11Initial program 84.2%
associate-/l*99.8%
Simplified99.8%
clear-num99.7%
un-div-inv99.8%
Applied egg-rr99.8%
Taylor expanded in y around 0 65.4%
mul-1-neg65.4%
*-commutative65.4%
associate-*r/59.6%
*-commutative59.6%
associate-/r/79.7%
distribute-neg-frac79.7%
div-sub79.8%
sub-neg79.8%
*-inverses79.8%
metadata-eval79.8%
Simplified79.8%
Taylor expanded in x around 0 79.8%
mul-1-neg79.8%
sub-neg79.8%
metadata-eval79.8%
distribute-neg-frac279.8%
+-commutative79.8%
distribute-neg-in79.8%
metadata-eval79.8%
unsub-neg79.8%
Simplified79.8%
if -1.07999999999999992e-11 < z < -3.4999999999999997e-272Initial program 97.4%
associate-/l*86.6%
Simplified86.6%
Taylor expanded in t around inf 81.2%
if -3.4999999999999997e-272 < z < 5.1999999999999999e48Initial program 88.0%
associate-/l*98.4%
Simplified98.4%
Taylor expanded in t around inf 79.7%
associate-/l*86.7%
Simplified86.7%
if 5.1999999999999999e48 < z Initial program 67.4%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in t around 0 56.7%
mul-1-neg56.7%
associate-/l*86.5%
distribute-lft-neg-in86.5%
div-sub86.5%
sub-neg86.5%
*-inverses86.5%
metadata-eval86.5%
Simplified86.5%
Final simplification83.8%
(FPCore (x y z t)
:precision binary64
(if (<= z -5.5e-126)
(/ x (- 1.0 (/ t z)))
(if (<= z -4.1e-280)
(/ (* x y) (- t z))
(if (<= z 3.8e+48) (* x (/ (- y z) t)) (* x (/ z (- z t)))))))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -5.5e-126) {
tmp = x / (1.0 - (t / z));
} else if (z <= -4.1e-280) {
tmp = (x * y) / (t - z);
} else if (z <= 3.8e+48) {
tmp = x * ((y - z) / t);
} else {
tmp = x * (z / (z - t));
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (z <= (-5.5d-126)) then
tmp = x / (1.0d0 - (t / z))
else if (z <= (-4.1d-280)) then
tmp = (x * y) / (t - z)
else if (z <= 3.8d+48) then
tmp = x * ((y - z) / t)
else
tmp = x * (z / (z - t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -5.5e-126) {
tmp = x / (1.0 - (t / z));
} else if (z <= -4.1e-280) {
tmp = (x * y) / (t - z);
} else if (z <= 3.8e+48) {
tmp = x * ((y - z) / t);
} else {
tmp = x * (z / (z - t));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -5.5e-126: tmp = x / (1.0 - (t / z)) elif z <= -4.1e-280: tmp = (x * y) / (t - z) elif z <= 3.8e+48: tmp = x * ((y - z) / t) else: tmp = x * (z / (z - t)) return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -5.5e-126) tmp = Float64(x / Float64(1.0 - Float64(t / z))); elseif (z <= -4.1e-280) tmp = Float64(Float64(x * y) / Float64(t - z)); elseif (z <= 3.8e+48) tmp = Float64(x * Float64(Float64(y - z) / t)); else tmp = Float64(x * Float64(z / Float64(z - t))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -5.5e-126) tmp = x / (1.0 - (t / z)); elseif (z <= -4.1e-280) tmp = (x * y) / (t - z); elseif (z <= 3.8e+48) tmp = x * ((y - z) / t); else tmp = x * (z / (z - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -5.5e-126], N[(x / N[(1.0 - N[(t / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -4.1e-280], N[(N[(x * y), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 3.8e+48], N[(x * N[(N[(y - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], N[(x * N[(z / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -5.5 \cdot 10^{-126}:\\
\;\;\;\;\frac{x}{1 - \frac{t}{z}}\\
\mathbf{elif}\;z \leq -4.1 \cdot 10^{-280}:\\
\;\;\;\;\frac{x \cdot y}{t - z}\\
\mathbf{elif}\;z \leq 3.8 \cdot 10^{+48}:\\
\;\;\;\;x \cdot \frac{y - z}{t}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{z}{z - t}\\
\end{array}
\end{array}
if z < -5.49999999999999987e-126Initial program 86.1%
associate-/l*98.6%
Simplified98.6%
clear-num98.6%
un-div-inv98.6%
Applied egg-rr98.6%
Taylor expanded in y around 0 64.9%
mul-1-neg64.9%
*-commutative64.9%
associate-*r/59.8%
*-commutative59.8%
associate-/r/77.5%
distribute-neg-frac77.5%
div-sub77.5%
sub-neg77.5%
*-inverses77.5%
metadata-eval77.5%
Simplified77.5%
Taylor expanded in x around 0 77.5%
mul-1-neg77.5%
sub-neg77.5%
metadata-eval77.5%
distribute-neg-frac277.5%
+-commutative77.5%
distribute-neg-in77.5%
metadata-eval77.5%
unsub-neg77.5%
Simplified77.5%
if -5.49999999999999987e-126 < z < -4.1000000000000002e-280Initial program 96.7%
associate-/l*85.5%
Simplified85.5%
Taylor expanded in y around inf 86.6%
if -4.1000000000000002e-280 < z < 3.8e48Initial program 87.8%
associate-/l*98.4%
Simplified98.4%
Taylor expanded in t around inf 79.4%
associate-/l*86.5%
Simplified86.5%
if 3.8e48 < z Initial program 68.0%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in y around 0 59.1%
mul-1-neg59.1%
associate-/l*84.9%
distribute-rgt-neg-in84.9%
distribute-neg-frac284.9%
Simplified84.9%
Taylor expanded in x around 0 59.1%
associate-/l*84.9%
Simplified84.9%
Final simplification83.3%
(FPCore (x y z t)
:precision binary64
(if (<= z -7.6e-17)
(/ x (- 1.0 (/ t z)))
(if (<= z -5e-276)
(/ (* x (- y z)) t)
(if (<= z 4.5e+48) (* x (/ (- y z) t)) (* x (/ z (- z t)))))))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -7.6e-17) {
tmp = x / (1.0 - (t / z));
} else if (z <= -5e-276) {
tmp = (x * (y - z)) / t;
} else if (z <= 4.5e+48) {
tmp = x * ((y - z) / t);
} else {
tmp = x * (z / (z - t));
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (z <= (-7.6d-17)) then
tmp = x / (1.0d0 - (t / z))
else if (z <= (-5d-276)) then
tmp = (x * (y - z)) / t
else if (z <= 4.5d+48) then
tmp = x * ((y - z) / t)
else
tmp = x * (z / (z - t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -7.6e-17) {
tmp = x / (1.0 - (t / z));
} else if (z <= -5e-276) {
tmp = (x * (y - z)) / t;
} else if (z <= 4.5e+48) {
tmp = x * ((y - z) / t);
} else {
tmp = x * (z / (z - t));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -7.6e-17: tmp = x / (1.0 - (t / z)) elif z <= -5e-276: tmp = (x * (y - z)) / t elif z <= 4.5e+48: tmp = x * ((y - z) / t) else: tmp = x * (z / (z - t)) return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -7.6e-17) tmp = Float64(x / Float64(1.0 - Float64(t / z))); elseif (z <= -5e-276) tmp = Float64(Float64(x * Float64(y - z)) / t); elseif (z <= 4.5e+48) tmp = Float64(x * Float64(Float64(y - z) / t)); else tmp = Float64(x * Float64(z / Float64(z - t))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -7.6e-17) tmp = x / (1.0 - (t / z)); elseif (z <= -5e-276) tmp = (x * (y - z)) / t; elseif (z <= 4.5e+48) tmp = x * ((y - z) / t); else tmp = x * (z / (z - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -7.6e-17], N[(x / N[(1.0 - N[(t / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -5e-276], N[(N[(x * N[(y - z), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[z, 4.5e+48], N[(x * N[(N[(y - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], N[(x * N[(z / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -7.6 \cdot 10^{-17}:\\
\;\;\;\;\frac{x}{1 - \frac{t}{z}}\\
\mathbf{elif}\;z \leq -5 \cdot 10^{-276}:\\
\;\;\;\;\frac{x \cdot \left(y - z\right)}{t}\\
\mathbf{elif}\;z \leq 4.5 \cdot 10^{+48}:\\
\;\;\;\;x \cdot \frac{y - z}{t}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{z}{z - t}\\
\end{array}
\end{array}
if z < -7.6000000000000002e-17Initial program 84.2%
associate-/l*99.8%
Simplified99.8%
clear-num99.7%
un-div-inv99.8%
Applied egg-rr99.8%
Taylor expanded in y around 0 65.4%
mul-1-neg65.4%
*-commutative65.4%
associate-*r/59.6%
*-commutative59.6%
associate-/r/79.7%
distribute-neg-frac79.7%
div-sub79.8%
sub-neg79.8%
*-inverses79.8%
metadata-eval79.8%
Simplified79.8%
Taylor expanded in x around 0 79.8%
mul-1-neg79.8%
sub-neg79.8%
metadata-eval79.8%
distribute-neg-frac279.8%
+-commutative79.8%
distribute-neg-in79.8%
metadata-eval79.8%
unsub-neg79.8%
Simplified79.8%
if -7.6000000000000002e-17 < z < -4.99999999999999967e-276Initial program 97.4%
associate-/l*86.6%
Simplified86.6%
Taylor expanded in t around inf 81.2%
if -4.99999999999999967e-276 < z < 4.49999999999999995e48Initial program 87.8%
associate-/l*98.4%
Simplified98.4%
Taylor expanded in t around inf 79.4%
associate-/l*86.5%
Simplified86.5%
if 4.49999999999999995e48 < z Initial program 68.0%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in y around 0 59.1%
mul-1-neg59.1%
associate-/l*84.9%
distribute-rgt-neg-in84.9%
distribute-neg-frac284.9%
Simplified84.9%
Taylor expanded in x around 0 59.1%
associate-/l*84.9%
Simplified84.9%
Final simplification83.4%
(FPCore (x y z t) :precision binary64 (if (<= z -2.65e-14) x (if (<= z -2e-271) (/ (* x y) t) (if (<= z 4.8e+48) (* x (/ y t)) x))))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -2.65e-14) {
tmp = x;
} else if (z <= -2e-271) {
tmp = (x * y) / t;
} else if (z <= 4.8e+48) {
tmp = x * (y / t);
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (z <= (-2.65d-14)) then
tmp = x
else if (z <= (-2d-271)) then
tmp = (x * y) / t
else if (z <= 4.8d+48) then
tmp = x * (y / t)
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -2.65e-14) {
tmp = x;
} else if (z <= -2e-271) {
tmp = (x * y) / t;
} else if (z <= 4.8e+48) {
tmp = x * (y / t);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -2.65e-14: tmp = x elif z <= -2e-271: tmp = (x * y) / t elif z <= 4.8e+48: tmp = x * (y / t) else: tmp = x return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -2.65e-14) tmp = x; elseif (z <= -2e-271) tmp = Float64(Float64(x * y) / t); elseif (z <= 4.8e+48) tmp = Float64(x * Float64(y / t)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -2.65e-14) tmp = x; elseif (z <= -2e-271) tmp = (x * y) / t; elseif (z <= 4.8e+48) tmp = x * (y / t); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -2.65e-14], x, If[LessEqual[z, -2e-271], N[(N[(x * y), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[z, 4.8e+48], N[(x * N[(y / t), $MachinePrecision]), $MachinePrecision], x]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.65 \cdot 10^{-14}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq -2 \cdot 10^{-271}:\\
\;\;\;\;\frac{x \cdot y}{t}\\
\mathbf{elif}\;z \leq 4.8 \cdot 10^{+48}:\\
\;\;\;\;x \cdot \frac{y}{t}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if z < -2.6500000000000001e-14 or 4.8000000000000002e48 < z Initial program 76.9%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 68.2%
if -2.6500000000000001e-14 < z < -1.99999999999999993e-271Initial program 97.4%
associate-/l*86.6%
Simplified86.6%
Taylor expanded in z around 0 69.2%
if -1.99999999999999993e-271 < z < 4.8000000000000002e48Initial program 87.8%
associate-/l*98.4%
Simplified98.4%
Taylor expanded in z around 0 63.8%
associate-/l*72.0%
Simplified72.0%
Final simplification69.6%
(FPCore (x y z t) :precision binary64 (if (<= z -2.7e-15) (/ x (- 1.0 (/ t z))) (if (<= z 3.7e+48) (* (- y z) (/ x t)) (* x (/ z (- z t))))))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -2.7e-15) {
tmp = x / (1.0 - (t / z));
} else if (z <= 3.7e+48) {
tmp = (y - z) * (x / t);
} else {
tmp = x * (z / (z - t));
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (z <= (-2.7d-15)) then
tmp = x / (1.0d0 - (t / z))
else if (z <= 3.7d+48) then
tmp = (y - z) * (x / t)
else
tmp = x * (z / (z - t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -2.7e-15) {
tmp = x / (1.0 - (t / z));
} else if (z <= 3.7e+48) {
tmp = (y - z) * (x / t);
} else {
tmp = x * (z / (z - t));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -2.7e-15: tmp = x / (1.0 - (t / z)) elif z <= 3.7e+48: tmp = (y - z) * (x / t) else: tmp = x * (z / (z - t)) return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -2.7e-15) tmp = Float64(x / Float64(1.0 - Float64(t / z))); elseif (z <= 3.7e+48) tmp = Float64(Float64(y - z) * Float64(x / t)); else tmp = Float64(x * Float64(z / Float64(z - t))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -2.7e-15) tmp = x / (1.0 - (t / z)); elseif (z <= 3.7e+48) tmp = (y - z) * (x / t); else tmp = x * (z / (z - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -2.7e-15], N[(x / N[(1.0 - N[(t / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 3.7e+48], N[(N[(y - z), $MachinePrecision] * N[(x / t), $MachinePrecision]), $MachinePrecision], N[(x * N[(z / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.7 \cdot 10^{-15}:\\
\;\;\;\;\frac{x}{1 - \frac{t}{z}}\\
\mathbf{elif}\;z \leq 3.7 \cdot 10^{+48}:\\
\;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{z}{z - t}\\
\end{array}
\end{array}
if z < -2.70000000000000009e-15Initial program 84.2%
associate-/l*99.8%
Simplified99.8%
clear-num99.7%
un-div-inv99.8%
Applied egg-rr99.8%
Taylor expanded in y around 0 65.4%
mul-1-neg65.4%
*-commutative65.4%
associate-*r/59.6%
*-commutative59.6%
associate-/r/79.7%
distribute-neg-frac79.7%
div-sub79.8%
sub-neg79.8%
*-inverses79.8%
metadata-eval79.8%
Simplified79.8%
Taylor expanded in x around 0 79.8%
mul-1-neg79.8%
sub-neg79.8%
metadata-eval79.8%
distribute-neg-frac279.8%
+-commutative79.8%
distribute-neg-in79.8%
metadata-eval79.8%
unsub-neg79.8%
Simplified79.8%
if -2.70000000000000009e-15 < z < 3.6999999999999999e48Initial program 91.1%
*-commutative91.1%
associate-/l*94.4%
Simplified94.4%
Taylor expanded in t around inf 80.4%
if 3.6999999999999999e48 < z Initial program 68.0%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in y around 0 59.1%
mul-1-neg59.1%
associate-/l*84.9%
distribute-rgt-neg-in84.9%
distribute-neg-frac284.9%
Simplified84.9%
Taylor expanded in x around 0 59.1%
associate-/l*84.9%
Simplified84.9%
Final simplification81.2%
(FPCore (x y z t) :precision binary64 (if (<= z -9.5e-18) (/ x (- 1.0 (/ t z))) (if (<= z 3.7e+48) (/ x (/ t (- y z))) (* x (/ z (- z t))))))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -9.5e-18) {
tmp = x / (1.0 - (t / z));
} else if (z <= 3.7e+48) {
tmp = x / (t / (y - z));
} else {
tmp = x * (z / (z - t));
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (z <= (-9.5d-18)) then
tmp = x / (1.0d0 - (t / z))
else if (z <= 3.7d+48) then
tmp = x / (t / (y - z))
else
tmp = x * (z / (z - t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -9.5e-18) {
tmp = x / (1.0 - (t / z));
} else if (z <= 3.7e+48) {
tmp = x / (t / (y - z));
} else {
tmp = x * (z / (z - t));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -9.5e-18: tmp = x / (1.0 - (t / z)) elif z <= 3.7e+48: tmp = x / (t / (y - z)) else: tmp = x * (z / (z - t)) return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -9.5e-18) tmp = Float64(x / Float64(1.0 - Float64(t / z))); elseif (z <= 3.7e+48) tmp = Float64(x / Float64(t / Float64(y - z))); else tmp = Float64(x * Float64(z / Float64(z - t))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -9.5e-18) tmp = x / (1.0 - (t / z)); elseif (z <= 3.7e+48) tmp = x / (t / (y - z)); else tmp = x * (z / (z - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -9.5e-18], N[(x / N[(1.0 - N[(t / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 3.7e+48], N[(x / N[(t / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(z / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -9.5 \cdot 10^{-18}:\\
\;\;\;\;\frac{x}{1 - \frac{t}{z}}\\
\mathbf{elif}\;z \leq 3.7 \cdot 10^{+48}:\\
\;\;\;\;\frac{x}{\frac{t}{y - z}}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{z}{z - t}\\
\end{array}
\end{array}
if z < -9.5000000000000003e-18Initial program 84.2%
associate-/l*99.8%
Simplified99.8%
clear-num99.7%
un-div-inv99.8%
Applied egg-rr99.8%
Taylor expanded in y around 0 65.4%
mul-1-neg65.4%
*-commutative65.4%
associate-*r/59.6%
*-commutative59.6%
associate-/r/79.7%
distribute-neg-frac79.7%
div-sub79.8%
sub-neg79.8%
*-inverses79.8%
metadata-eval79.8%
Simplified79.8%
Taylor expanded in x around 0 79.8%
mul-1-neg79.8%
sub-neg79.8%
metadata-eval79.8%
distribute-neg-frac279.8%
+-commutative79.8%
distribute-neg-in79.8%
metadata-eval79.8%
unsub-neg79.8%
Simplified79.8%
if -9.5000000000000003e-18 < z < 3.6999999999999999e48Initial program 91.1%
associate-/l*94.3%
Simplified94.3%
clear-num93.7%
un-div-inv94.7%
Applied egg-rr94.7%
Taylor expanded in t around inf 80.7%
if 3.6999999999999999e48 < z Initial program 68.0%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in y around 0 59.1%
mul-1-neg59.1%
associate-/l*84.9%
distribute-rgt-neg-in84.9%
distribute-neg-frac284.9%
Simplified84.9%
Taylor expanded in x around 0 59.1%
associate-/l*84.9%
Simplified84.9%
Final simplification81.4%
(FPCore (x y z t) :precision binary64 (if (<= z -2.65e-14) x (if (<= z 4.4e+48) (* x (/ y t)) x)))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -2.65e-14) {
tmp = x;
} else if (z <= 4.4e+48) {
tmp = x * (y / t);
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (z <= (-2.65d-14)) then
tmp = x
else if (z <= 4.4d+48) then
tmp = x * (y / t)
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -2.65e-14) {
tmp = x;
} else if (z <= 4.4e+48) {
tmp = x * (y / t);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -2.65e-14: tmp = x elif z <= 4.4e+48: tmp = x * (y / t) else: tmp = x return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -2.65e-14) tmp = x; elseif (z <= 4.4e+48) tmp = Float64(x * Float64(y / t)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -2.65e-14) tmp = x; elseif (z <= 4.4e+48) tmp = x * (y / t); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -2.65e-14], x, If[LessEqual[z, 4.4e+48], N[(x * N[(y / t), $MachinePrecision]), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.65 \cdot 10^{-14}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq 4.4 \cdot 10^{+48}:\\
\;\;\;\;x \cdot \frac{y}{t}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if z < -2.6500000000000001e-14 or 4.3999999999999999e48 < z Initial program 76.9%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 68.2%
if -2.6500000000000001e-14 < z < 4.3999999999999999e48Initial program 91.1%
associate-/l*94.3%
Simplified94.3%
Taylor expanded in z around 0 65.7%
associate-/l*67.4%
Simplified67.4%
Final simplification67.8%
(FPCore (x y z t) :precision binary64 (if (<= z -4.5e-11) x (if (<= z 4.4e+48) (/ x (/ t y)) x)))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -4.5e-11) {
tmp = x;
} else if (z <= 4.4e+48) {
tmp = x / (t / y);
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (z <= (-4.5d-11)) then
tmp = x
else if (z <= 4.4d+48) then
tmp = x / (t / y)
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -4.5e-11) {
tmp = x;
} else if (z <= 4.4e+48) {
tmp = x / (t / y);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -4.5e-11: tmp = x elif z <= 4.4e+48: tmp = x / (t / y) else: tmp = x return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -4.5e-11) tmp = x; elseif (z <= 4.4e+48) tmp = Float64(x / Float64(t / y)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -4.5e-11) tmp = x; elseif (z <= 4.4e+48) tmp = x / (t / y); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -4.5e-11], x, If[LessEqual[z, 4.4e+48], N[(x / N[(t / y), $MachinePrecision]), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -4.5 \cdot 10^{-11}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq 4.4 \cdot 10^{+48}:\\
\;\;\;\;\frac{x}{\frac{t}{y}}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if z < -4.5e-11 or 4.3999999999999999e48 < z Initial program 76.9%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 68.2%
if -4.5e-11 < z < 4.3999999999999999e48Initial program 91.1%
associate-/l*94.3%
Simplified94.3%
clear-num93.7%
un-div-inv94.7%
Applied egg-rr94.7%
Taylor expanded in z around 0 67.7%
Final simplification68.0%
(FPCore (x y z t) :precision binary64 (* x (/ (- y z) (- t z))))
double code(double x, double y, double z, double t) {
return x * ((y - z) / (t - z));
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = x * ((y - z) / (t - z))
end function
public static double code(double x, double y, double z, double t) {
return x * ((y - z) / (t - z));
}
def code(x, y, z, t): return x * ((y - z) / (t - z))
function code(x, y, z, t) return Float64(x * Float64(Float64(y - z) / Float64(t - z))) end
function tmp = code(x, y, z, t) tmp = x * ((y - z) / (t - z)); end
code[x_, y_, z_, t_] := N[(x * N[(N[(y - z), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x \cdot \frac{y - z}{t - z}
\end{array}
Initial program 83.8%
associate-/l*97.2%
Simplified97.2%
Final simplification97.2%
(FPCore (x y z t) :precision binary64 x)
double code(double x, double y, double z, double t) {
return x;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = x
end function
public static double code(double x, double y, double z, double t) {
return x;
}
def code(x, y, z, t): return x
function code(x, y, z, t) return x end
function tmp = code(x, y, z, t) tmp = x; end
code[x_, y_, z_, t_] := x
\begin{array}{l}
\\
x
\end{array}
Initial program 83.8%
associate-/l*97.2%
Simplified97.2%
Taylor expanded in z around inf 39.2%
Final simplification39.2%
(FPCore (x y z t) :precision binary64 (/ x (/ (- t z) (- y z))))
double code(double x, double y, double z, double t) {
return x / ((t - z) / (y - z));
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = x / ((t - z) / (y - z))
end function
public static double code(double x, double y, double z, double t) {
return x / ((t - z) / (y - z));
}
def code(x, y, z, t): return x / ((t - z) / (y - z))
function code(x, y, z, t) return Float64(x / Float64(Float64(t - z) / Float64(y - z))) end
function tmp = code(x, y, z, t) tmp = x / ((t - z) / (y - z)); end
code[x_, y_, z_, t_] := N[(x / N[(N[(t - z), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x}{\frac{t - z}{y - z}}
\end{array}
herbie shell --seed 2024046
(FPCore (x y z t)
:name "Graphics.Rendering.Chart.Plot.AreaSpots:renderAreaSpots4D from Chart-1.5.3"
:precision binary64
:alt
(/ x (/ (- t z) (- y z)))
(/ (* x (- y z)) (- t z)))