
(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}
\\
\frac{x}{\left(y - z\right) \cdot \left(t - z\right)}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 17 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(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}
\\
\frac{x}{\left(y - z\right) \cdot \left(t - z\right)}
\end{array}
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. (FPCore (x y z t) :precision binary64 (let* ((t_1 (* (- t z) (- y z)))) (if (<= t_1 2e+284) (/ x t_1) (/ (/ x (- t z)) (- y z)))))
assert(x < y && y < z && z < t);
double code(double x, double y, double z, double t) {
double t_1 = (t - z) * (y - z);
double tmp;
if (t_1 <= 2e+284) {
tmp = x / t_1;
} else {
tmp = (x / (t - z)) / (y - z);
}
return tmp;
}
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
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 = (t - z) * (y - z)
if (t_1 <= 2d+284) then
tmp = x / t_1
else
tmp = (x / (t - z)) / (y - z)
end if
code = tmp
end function
assert x < y && y < z && z < t;
public static double code(double x, double y, double z, double t) {
double t_1 = (t - z) * (y - z);
double tmp;
if (t_1 <= 2e+284) {
tmp = x / t_1;
} else {
tmp = (x / (t - z)) / (y - z);
}
return tmp;
}
[x, y, z, t] = sort([x, y, z, t]) def code(x, y, z, t): t_1 = (t - z) * (y - z) tmp = 0 if t_1 <= 2e+284: tmp = x / t_1 else: tmp = (x / (t - z)) / (y - z) return tmp
x, y, z, t = sort([x, y, z, t]) function code(x, y, z, t) t_1 = Float64(Float64(t - z) * Float64(y - z)) tmp = 0.0 if (t_1 <= 2e+284) tmp = Float64(x / t_1); else tmp = Float64(Float64(x / Float64(t - z)) / Float64(y - z)); end return tmp end
x, y, z, t = num2cell(sort([x, y, z, t])){:}
function tmp_2 = code(x, y, z, t)
t_1 = (t - z) * (y - z);
tmp = 0.0;
if (t_1 <= 2e+284)
tmp = x / t_1;
else
tmp = (x / (t - z)) / (y - z);
end
tmp_2 = tmp;
end
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(t - z), $MachinePrecision] * N[(y - z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, 2e+284], N[(x / t$95$1), $MachinePrecision], N[(N[(x / N[(t - z), $MachinePrecision]), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t] = \mathsf{sort}([x, y, z, t])\\
\\
\begin{array}{l}
t_1 := \left(t - z\right) \cdot \left(y - z\right)\\
\mathbf{if}\;t\_1 \leq 2 \cdot 10^{+284}:\\
\;\;\;\;\frac{x}{t\_1}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{x}{t - z}}{y - z}\\
\end{array}
\end{array}
if (*.f64 (-.f64 y z) (-.f64 t z)) < 2.00000000000000016e284Initial program 97.4%
if 2.00000000000000016e284 < (*.f64 (-.f64 y z) (-.f64 t z)) Initial program 73.7%
associate-/l/N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
--lowering--.f6499.9%
Applied egg-rr99.9%
Final simplification98.3%
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
:precision binary64
(if (<= z -2.5e+46)
(/ (/ x (- z t)) z)
(if (<= z -8.2e-113)
(/ (/ x y) (- t z))
(if (<= z 4.2e-36) (/ x (* t (- y z))) (/ (/ x z) (- z y))))))assert(x < y && y < z && z < t);
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -2.5e+46) {
tmp = (x / (z - t)) / z;
} else if (z <= -8.2e-113) {
tmp = (x / y) / (t - z);
} else if (z <= 4.2e-36) {
tmp = x / (t * (y - z));
} else {
tmp = (x / z) / (z - y);
}
return tmp;
}
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
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.5d+46)) then
tmp = (x / (z - t)) / z
else if (z <= (-8.2d-113)) then
tmp = (x / y) / (t - z)
else if (z <= 4.2d-36) then
tmp = x / (t * (y - z))
else
tmp = (x / z) / (z - y)
end if
code = tmp
end function
assert x < y && y < z && z < t;
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -2.5e+46) {
tmp = (x / (z - t)) / z;
} else if (z <= -8.2e-113) {
tmp = (x / y) / (t - z);
} else if (z <= 4.2e-36) {
tmp = x / (t * (y - z));
} else {
tmp = (x / z) / (z - y);
}
return tmp;
}
[x, y, z, t] = sort([x, y, z, t]) def code(x, y, z, t): tmp = 0 if z <= -2.5e+46: tmp = (x / (z - t)) / z elif z <= -8.2e-113: tmp = (x / y) / (t - z) elif z <= 4.2e-36: tmp = x / (t * (y - z)) else: tmp = (x / z) / (z - y) return tmp
x, y, z, t = sort([x, y, z, t]) function code(x, y, z, t) tmp = 0.0 if (z <= -2.5e+46) tmp = Float64(Float64(x / Float64(z - t)) / z); elseif (z <= -8.2e-113) tmp = Float64(Float64(x / y) / Float64(t - z)); elseif (z <= 4.2e-36) tmp = Float64(x / Float64(t * Float64(y - z))); else tmp = Float64(Float64(x / z) / Float64(z - y)); end return tmp end
x, y, z, t = num2cell(sort([x, y, z, t])){:}
function tmp_2 = code(x, y, z, t)
tmp = 0.0;
if (z <= -2.5e+46)
tmp = (x / (z - t)) / z;
elseif (z <= -8.2e-113)
tmp = (x / y) / (t - z);
elseif (z <= 4.2e-36)
tmp = x / (t * (y - z));
else
tmp = (x / z) / (z - y);
end
tmp_2 = tmp;
end
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. code[x_, y_, z_, t_] := If[LessEqual[z, -2.5e+46], N[(N[(x / N[(z - t), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision], If[LessEqual[z, -8.2e-113], N[(N[(x / y), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.2e-36], N[(x / N[(t * N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x / z), $MachinePrecision] / N[(z - y), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t] = \mathsf{sort}([x, y, z, t])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.5 \cdot 10^{+46}:\\
\;\;\;\;\frac{\frac{x}{z - t}}{z}\\
\mathbf{elif}\;z \leq -8.2 \cdot 10^{-113}:\\
\;\;\;\;\frac{\frac{x}{y}}{t - z}\\
\mathbf{elif}\;z \leq 4.2 \cdot 10^{-36}:\\
\;\;\;\;\frac{x}{t \cdot \left(y - z\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{x}{z}}{z - y}\\
\end{array}
\end{array}
if z < -2.5000000000000001e46Initial program 76.1%
clear-numN/A
*-commutativeN/A
associate-/l*N/A
associate-/r*N/A
flip3--N/A
clear-numN/A
/-lowering-/.f64N/A
clear-numN/A
flip3--N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
/-lowering-/.f64N/A
--lowering--.f6499.8%
Applied egg-rr99.8%
Taylor expanded in y around 0
mul-1-negN/A
associate-/r*N/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
neg-lowering-neg.f64N/A
--lowering--.f6491.1%
Simplified91.1%
clear-numN/A
inv-powN/A
associate-/r/N/A
neg-sub0N/A
associate--r-N/A
neg-sub0N/A
+-commutativeN/A
sub-negN/A
unpow-prod-downN/A
inv-powN/A
clear-numN/A
inv-powN/A
div-invN/A
/-lowering-/.f64N/A
sub-negN/A
+-commutativeN/A
neg-sub0N/A
associate--r-N/A
neg-sub0N/A
/-lowering-/.f64N/A
neg-sub0N/A
associate--r-N/A
neg-sub0N/A
+-commutativeN/A
sub-negN/A
--lowering--.f6491.2%
Applied egg-rr91.2%
if -2.5000000000000001e46 < z < -8.1999999999999999e-113Initial program 93.0%
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
--lowering--.f6496.1%
Applied egg-rr96.1%
Taylor expanded in y around inf
Simplified69.6%
if -8.1999999999999999e-113 < z < 4.19999999999999982e-36Initial program 96.0%
Taylor expanded in t around inf
Simplified78.0%
if 4.19999999999999982e-36 < z Initial program 87.8%
clear-numN/A
*-commutativeN/A
associate-/l*N/A
associate-/r*N/A
flip3--N/A
clear-numN/A
/-lowering-/.f64N/A
clear-numN/A
flip3--N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
/-lowering-/.f64N/A
--lowering--.f6499.8%
Applied egg-rr99.8%
associate-/r/N/A
*-commutativeN/A
associate-*r/N/A
div-invN/A
frac-2negN/A
/-lowering-/.f64N/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
neg-sub0N/A
sub-negN/A
+-commutativeN/A
associate--r+N/A
neg-sub0N/A
remove-double-negN/A
--lowering--.f64N/A
neg-sub0N/A
sub-negN/A
+-commutativeN/A
associate--r+N/A
neg-sub0N/A
remove-double-negN/A
--lowering--.f6499.8%
Applied egg-rr99.8%
Taylor expanded in z around inf
/-lowering-/.f6483.0%
Simplified83.0%
Final simplification81.2%
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (/ (/ x z) (- z y))))
(if (<= z -5.2e-77)
t_1
(if (<= z -3.8e-113)
(/ (/ x y) (- t z))
(if (<= z 1.02e-38) (/ x (* t (- y z))) t_1)))))assert(x < y && y < z && z < t);
double code(double x, double y, double z, double t) {
double t_1 = (x / z) / (z - y);
double tmp;
if (z <= -5.2e-77) {
tmp = t_1;
} else if (z <= -3.8e-113) {
tmp = (x / y) / (t - z);
} else if (z <= 1.02e-38) {
tmp = x / (t * (y - z));
} else {
tmp = t_1;
}
return tmp;
}
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
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 - y)
if (z <= (-5.2d-77)) then
tmp = t_1
else if (z <= (-3.8d-113)) then
tmp = (x / y) / (t - z)
else if (z <= 1.02d-38) then
tmp = x / (t * (y - z))
else
tmp = t_1
end if
code = tmp
end function
assert x < y && y < z && z < t;
public static double code(double x, double y, double z, double t) {
double t_1 = (x / z) / (z - y);
double tmp;
if (z <= -5.2e-77) {
tmp = t_1;
} else if (z <= -3.8e-113) {
tmp = (x / y) / (t - z);
} else if (z <= 1.02e-38) {
tmp = x / (t * (y - z));
} else {
tmp = t_1;
}
return tmp;
}
[x, y, z, t] = sort([x, y, z, t]) def code(x, y, z, t): t_1 = (x / z) / (z - y) tmp = 0 if z <= -5.2e-77: tmp = t_1 elif z <= -3.8e-113: tmp = (x / y) / (t - z) elif z <= 1.02e-38: tmp = x / (t * (y - z)) else: tmp = t_1 return tmp
x, y, z, t = sort([x, y, z, t]) function code(x, y, z, t) t_1 = Float64(Float64(x / z) / Float64(z - y)) tmp = 0.0 if (z <= -5.2e-77) tmp = t_1; elseif (z <= -3.8e-113) tmp = Float64(Float64(x / y) / Float64(t - z)); elseif (z <= 1.02e-38) tmp = Float64(x / Float64(t * Float64(y - z))); else tmp = t_1; end return tmp end
x, y, z, t = num2cell(sort([x, y, z, t])){:}
function tmp_2 = code(x, y, z, t)
t_1 = (x / z) / (z - y);
tmp = 0.0;
if (z <= -5.2e-77)
tmp = t_1;
elseif (z <= -3.8e-113)
tmp = (x / y) / (t - z);
elseif (z <= 1.02e-38)
tmp = x / (t * (y - z));
else
tmp = t_1;
end
tmp_2 = tmp;
end
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x / z), $MachinePrecision] / N[(z - y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -5.2e-77], t$95$1, If[LessEqual[z, -3.8e-113], N[(N[(x / y), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.02e-38], N[(x / N[(t * N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
[x, y, z, t] = \mathsf{sort}([x, y, z, t])\\
\\
\begin{array}{l}
t_1 := \frac{\frac{x}{z}}{z - y}\\
\mathbf{if}\;z \leq -5.2 \cdot 10^{-77}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -3.8 \cdot 10^{-113}:\\
\;\;\;\;\frac{\frac{x}{y}}{t - z}\\
\mathbf{elif}\;z \leq 1.02 \cdot 10^{-38}:\\
\;\;\;\;\frac{x}{t \cdot \left(y - z\right)}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -5.2000000000000002e-77 or 1.01999999999999998e-38 < z Initial program 83.4%
clear-numN/A
*-commutativeN/A
associate-/l*N/A
associate-/r*N/A
flip3--N/A
clear-numN/A
/-lowering-/.f64N/A
clear-numN/A
flip3--N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
/-lowering-/.f64N/A
--lowering--.f6499.1%
Applied egg-rr99.1%
associate-/r/N/A
*-commutativeN/A
associate-*r/N/A
div-invN/A
frac-2negN/A
/-lowering-/.f64N/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
neg-sub0N/A
sub-negN/A
+-commutativeN/A
associate--r+N/A
neg-sub0N/A
remove-double-negN/A
--lowering--.f64N/A
neg-sub0N/A
sub-negN/A
+-commutativeN/A
associate--r+N/A
neg-sub0N/A
remove-double-negN/A
--lowering--.f6499.8%
Applied egg-rr99.8%
Taylor expanded in z around inf
/-lowering-/.f6486.4%
Simplified86.4%
if -5.2000000000000002e-77 < z < -3.79999999999999983e-113Initial program 99.1%
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
--lowering--.f6489.3%
Applied egg-rr89.3%
Taylor expanded in y around inf
Simplified81.7%
if -3.79999999999999983e-113 < z < 1.01999999999999998e-38Initial program 96.0%
Taylor expanded in t around inf
Simplified78.0%
Final simplification82.9%
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
:precision binary64
(if (<= z -2.7e+160)
(/ 1.0 (/ z (/ x z)))
(if (<= z -6.5e-113)
(/ x (* z (- z y)))
(if (<= z 8e+42) (/ x (* t (- y z))) (* (/ x z) (/ 1.0 z))))))assert(x < y && y < z && z < t);
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -2.7e+160) {
tmp = 1.0 / (z / (x / z));
} else if (z <= -6.5e-113) {
tmp = x / (z * (z - y));
} else if (z <= 8e+42) {
tmp = x / (t * (y - z));
} else {
tmp = (x / z) * (1.0 / z);
}
return tmp;
}
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
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+160)) then
tmp = 1.0d0 / (z / (x / z))
else if (z <= (-6.5d-113)) then
tmp = x / (z * (z - y))
else if (z <= 8d+42) then
tmp = x / (t * (y - z))
else
tmp = (x / z) * (1.0d0 / z)
end if
code = tmp
end function
assert x < y && y < z && z < t;
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -2.7e+160) {
tmp = 1.0 / (z / (x / z));
} else if (z <= -6.5e-113) {
tmp = x / (z * (z - y));
} else if (z <= 8e+42) {
tmp = x / (t * (y - z));
} else {
tmp = (x / z) * (1.0 / z);
}
return tmp;
}
[x, y, z, t] = sort([x, y, z, t]) def code(x, y, z, t): tmp = 0 if z <= -2.7e+160: tmp = 1.0 / (z / (x / z)) elif z <= -6.5e-113: tmp = x / (z * (z - y)) elif z <= 8e+42: tmp = x / (t * (y - z)) else: tmp = (x / z) * (1.0 / z) return tmp
x, y, z, t = sort([x, y, z, t]) function code(x, y, z, t) tmp = 0.0 if (z <= -2.7e+160) tmp = Float64(1.0 / Float64(z / Float64(x / z))); elseif (z <= -6.5e-113) tmp = Float64(x / Float64(z * Float64(z - y))); elseif (z <= 8e+42) tmp = Float64(x / Float64(t * Float64(y - z))); else tmp = Float64(Float64(x / z) * Float64(1.0 / z)); end return tmp end
x, y, z, t = num2cell(sort([x, y, z, t])){:}
function tmp_2 = code(x, y, z, t)
tmp = 0.0;
if (z <= -2.7e+160)
tmp = 1.0 / (z / (x / z));
elseif (z <= -6.5e-113)
tmp = x / (z * (z - y));
elseif (z <= 8e+42)
tmp = x / (t * (y - z));
else
tmp = (x / z) * (1.0 / z);
end
tmp_2 = tmp;
end
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. code[x_, y_, z_, t_] := If[LessEqual[z, -2.7e+160], N[(1.0 / N[(z / N[(x / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -6.5e-113], N[(x / N[(z * N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 8e+42], N[(x / N[(t * N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x / z), $MachinePrecision] * N[(1.0 / z), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t] = \mathsf{sort}([x, y, z, t])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.7 \cdot 10^{+160}:\\
\;\;\;\;\frac{1}{\frac{z}{\frac{x}{z}}}\\
\mathbf{elif}\;z \leq -6.5 \cdot 10^{-113}:\\
\;\;\;\;\frac{x}{z \cdot \left(z - y\right)}\\
\mathbf{elif}\;z \leq 8 \cdot 10^{+42}:\\
\;\;\;\;\frac{x}{t \cdot \left(y - z\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{z} \cdot \frac{1}{z}\\
\end{array}
\end{array}
if z < -2.7e160Initial program 64.7%
Taylor expanded in z around inf
/-lowering-/.f64N/A
unpow2N/A
*-lowering-*.f6464.7%
Simplified64.7%
clear-numN/A
metadata-evalN/A
/-lowering-/.f64N/A
metadata-evalN/A
clear-numN/A
associate-/r*N/A
clear-numN/A
/-lowering-/.f64N/A
/-lowering-/.f6490.4%
Applied egg-rr90.4%
if -2.7e160 < z < -6.49999999999999979e-113Initial program 92.8%
clear-numN/A
*-commutativeN/A
associate-/l*N/A
associate-/r*N/A
flip3--N/A
clear-numN/A
/-lowering-/.f64N/A
clear-numN/A
flip3--N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
/-lowering-/.f64N/A
--lowering--.f6496.5%
Applied egg-rr96.5%
associate-/l/N/A
associate-/r*N/A
clear-numN/A
frac-2negN/A
distribute-frac-neg2N/A
div-invN/A
distribute-rgt-neg-outN/A
*-lowering-*.f64N/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
neg-sub0N/A
sub-negN/A
+-commutativeN/A
associate--r+N/A
neg-sub0N/A
remove-double-negN/A
--lowering--.f64N/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f64N/A
--lowering--.f6497.7%
Applied egg-rr97.7%
Taylor expanded in t around 0
/-lowering-/.f64N/A
*-lowering-*.f64N/A
--lowering--.f6475.5%
Simplified75.5%
if -6.49999999999999979e-113 < z < 8.00000000000000036e42Initial program 96.4%
Taylor expanded in t around inf
Simplified76.2%
if 8.00000000000000036e42 < z Initial program 84.5%
Taylor expanded in z around inf
/-lowering-/.f64N/A
unpow2N/A
*-lowering-*.f6478.5%
Simplified78.5%
associate-/r*N/A
div-invN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
metadata-evalN/A
/-lowering-/.f64N/A
metadata-eval86.1%
Applied egg-rr86.1%
Final simplification79.9%
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
:precision binary64
(if (<= z -2.4e+160)
(/ 1.0 (/ z (/ x z)))
(if (<= z -1.15e-76)
(/ x (* z (- z y)))
(if (<= z 2.5e+21) (/ x (* (- t z) y)) (* (/ x z) (/ 1.0 z))))))assert(x < y && y < z && z < t);
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -2.4e+160) {
tmp = 1.0 / (z / (x / z));
} else if (z <= -1.15e-76) {
tmp = x / (z * (z - y));
} else if (z <= 2.5e+21) {
tmp = x / ((t - z) * y);
} else {
tmp = (x / z) * (1.0 / z);
}
return tmp;
}
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
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.4d+160)) then
tmp = 1.0d0 / (z / (x / z))
else if (z <= (-1.15d-76)) then
tmp = x / (z * (z - y))
else if (z <= 2.5d+21) then
tmp = x / ((t - z) * y)
else
tmp = (x / z) * (1.0d0 / z)
end if
code = tmp
end function
assert x < y && y < z && z < t;
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -2.4e+160) {
tmp = 1.0 / (z / (x / z));
} else if (z <= -1.15e-76) {
tmp = x / (z * (z - y));
} else if (z <= 2.5e+21) {
tmp = x / ((t - z) * y);
} else {
tmp = (x / z) * (1.0 / z);
}
return tmp;
}
[x, y, z, t] = sort([x, y, z, t]) def code(x, y, z, t): tmp = 0 if z <= -2.4e+160: tmp = 1.0 / (z / (x / z)) elif z <= -1.15e-76: tmp = x / (z * (z - y)) elif z <= 2.5e+21: tmp = x / ((t - z) * y) else: tmp = (x / z) * (1.0 / z) return tmp
x, y, z, t = sort([x, y, z, t]) function code(x, y, z, t) tmp = 0.0 if (z <= -2.4e+160) tmp = Float64(1.0 / Float64(z / Float64(x / z))); elseif (z <= -1.15e-76) tmp = Float64(x / Float64(z * Float64(z - y))); elseif (z <= 2.5e+21) tmp = Float64(x / Float64(Float64(t - z) * y)); else tmp = Float64(Float64(x / z) * Float64(1.0 / z)); end return tmp end
x, y, z, t = num2cell(sort([x, y, z, t])){:}
function tmp_2 = code(x, y, z, t)
tmp = 0.0;
if (z <= -2.4e+160)
tmp = 1.0 / (z / (x / z));
elseif (z <= -1.15e-76)
tmp = x / (z * (z - y));
elseif (z <= 2.5e+21)
tmp = x / ((t - z) * y);
else
tmp = (x / z) * (1.0 / z);
end
tmp_2 = tmp;
end
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. code[x_, y_, z_, t_] := If[LessEqual[z, -2.4e+160], N[(1.0 / N[(z / N[(x / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -1.15e-76], N[(x / N[(z * N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.5e+21], N[(x / N[(N[(t - z), $MachinePrecision] * y), $MachinePrecision]), $MachinePrecision], N[(N[(x / z), $MachinePrecision] * N[(1.0 / z), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t] = \mathsf{sort}([x, y, z, t])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.4 \cdot 10^{+160}:\\
\;\;\;\;\frac{1}{\frac{z}{\frac{x}{z}}}\\
\mathbf{elif}\;z \leq -1.15 \cdot 10^{-76}:\\
\;\;\;\;\frac{x}{z \cdot \left(z - y\right)}\\
\mathbf{elif}\;z \leq 2.5 \cdot 10^{+21}:\\
\;\;\;\;\frac{x}{\left(t - z\right) \cdot y}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{z} \cdot \frac{1}{z}\\
\end{array}
\end{array}
if z < -2.4000000000000001e160Initial program 64.7%
Taylor expanded in z around inf
/-lowering-/.f64N/A
unpow2N/A
*-lowering-*.f6464.7%
Simplified64.7%
clear-numN/A
metadata-evalN/A
/-lowering-/.f64N/A
metadata-evalN/A
clear-numN/A
associate-/r*N/A
clear-numN/A
/-lowering-/.f64N/A
/-lowering-/.f6490.4%
Applied egg-rr90.4%
if -2.4000000000000001e160 < z < -1.15000000000000003e-76Initial program 91.7%
clear-numN/A
*-commutativeN/A
associate-/l*N/A
associate-/r*N/A
flip3--N/A
clear-numN/A
/-lowering-/.f64N/A
clear-numN/A
flip3--N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
/-lowering-/.f64N/A
--lowering--.f6497.8%
Applied egg-rr97.8%
associate-/l/N/A
associate-/r*N/A
clear-numN/A
frac-2negN/A
distribute-frac-neg2N/A
div-invN/A
distribute-rgt-neg-outN/A
*-lowering-*.f64N/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
neg-sub0N/A
sub-negN/A
+-commutativeN/A
associate--r+N/A
neg-sub0N/A
remove-double-negN/A
--lowering--.f64N/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f64N/A
--lowering--.f6499.1%
Applied egg-rr99.1%
Taylor expanded in t around 0
/-lowering-/.f64N/A
*-lowering-*.f64N/A
--lowering--.f6480.9%
Simplified80.9%
if -1.15000000000000003e-76 < z < 2.5e21Initial program 96.5%
Taylor expanded in y around inf
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
--lowering--.f6478.8%
Simplified78.8%
if 2.5e21 < z Initial program 85.3%
Taylor expanded in z around inf
/-lowering-/.f64N/A
unpow2N/A
*-lowering-*.f6476.1%
Simplified76.1%
associate-/r*N/A
div-invN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
metadata-evalN/A
/-lowering-/.f64N/A
metadata-eval83.3%
Applied egg-rr83.3%
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (/ x (* z (- z y)))))
(if (<= z -2.4e+160)
(/ 1.0 (/ z (/ x z)))
(if (<= z -2.35e-116) t_1 (if (<= z 3.7e-60) (/ (/ x t) y) t_1)))))assert(x < y && y < z && z < t);
double code(double x, double y, double z, double t) {
double t_1 = x / (z * (z - y));
double tmp;
if (z <= -2.4e+160) {
tmp = 1.0 / (z / (x / z));
} else if (z <= -2.35e-116) {
tmp = t_1;
} else if (z <= 3.7e-60) {
tmp = (x / t) / y;
} else {
tmp = t_1;
}
return tmp;
}
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
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 - y))
if (z <= (-2.4d+160)) then
tmp = 1.0d0 / (z / (x / z))
else if (z <= (-2.35d-116)) then
tmp = t_1
else if (z <= 3.7d-60) then
tmp = (x / t) / y
else
tmp = t_1
end if
code = tmp
end function
assert x < y && y < z && z < t;
public static double code(double x, double y, double z, double t) {
double t_1 = x / (z * (z - y));
double tmp;
if (z <= -2.4e+160) {
tmp = 1.0 / (z / (x / z));
} else if (z <= -2.35e-116) {
tmp = t_1;
} else if (z <= 3.7e-60) {
tmp = (x / t) / y;
} else {
tmp = t_1;
}
return tmp;
}
[x, y, z, t] = sort([x, y, z, t]) def code(x, y, z, t): t_1 = x / (z * (z - y)) tmp = 0 if z <= -2.4e+160: tmp = 1.0 / (z / (x / z)) elif z <= -2.35e-116: tmp = t_1 elif z <= 3.7e-60: tmp = (x / t) / y else: tmp = t_1 return tmp
x, y, z, t = sort([x, y, z, t]) function code(x, y, z, t) t_1 = Float64(x / Float64(z * Float64(z - y))) tmp = 0.0 if (z <= -2.4e+160) tmp = Float64(1.0 / Float64(z / Float64(x / z))); elseif (z <= -2.35e-116) tmp = t_1; elseif (z <= 3.7e-60) tmp = Float64(Float64(x / t) / y); else tmp = t_1; end return tmp end
x, y, z, t = num2cell(sort([x, y, z, t])){:}
function tmp_2 = code(x, y, z, t)
t_1 = x / (z * (z - y));
tmp = 0.0;
if (z <= -2.4e+160)
tmp = 1.0 / (z / (x / z));
elseif (z <= -2.35e-116)
tmp = t_1;
elseif (z <= 3.7e-60)
tmp = (x / t) / y;
else
tmp = t_1;
end
tmp_2 = tmp;
end
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x / N[(z * N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2.4e+160], N[(1.0 / N[(z / N[(x / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -2.35e-116], t$95$1, If[LessEqual[z, 3.7e-60], N[(N[(x / t), $MachinePrecision] / y), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
[x, y, z, t] = \mathsf{sort}([x, y, z, t])\\
\\
\begin{array}{l}
t_1 := \frac{x}{z \cdot \left(z - y\right)}\\
\mathbf{if}\;z \leq -2.4 \cdot 10^{+160}:\\
\;\;\;\;\frac{1}{\frac{z}{\frac{x}{z}}}\\
\mathbf{elif}\;z \leq -2.35 \cdot 10^{-116}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq 3.7 \cdot 10^{-60}:\\
\;\;\;\;\frac{\frac{x}{t}}{y}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -2.4000000000000001e160Initial program 64.7%
Taylor expanded in z around inf
/-lowering-/.f64N/A
unpow2N/A
*-lowering-*.f6464.7%
Simplified64.7%
clear-numN/A
metadata-evalN/A
/-lowering-/.f64N/A
metadata-evalN/A
clear-numN/A
associate-/r*N/A
clear-numN/A
/-lowering-/.f64N/A
/-lowering-/.f6490.4%
Applied egg-rr90.4%
if -2.4000000000000001e160 < z < -2.34999999999999997e-116 or 3.70000000000000025e-60 < z Initial program 90.7%
clear-numN/A
*-commutativeN/A
associate-/l*N/A
associate-/r*N/A
flip3--N/A
clear-numN/A
/-lowering-/.f64N/A
clear-numN/A
flip3--N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
/-lowering-/.f64N/A
--lowering--.f6498.3%
Applied egg-rr98.3%
associate-/l/N/A
associate-/r*N/A
clear-numN/A
frac-2negN/A
distribute-frac-neg2N/A
div-invN/A
distribute-rgt-neg-outN/A
*-lowering-*.f64N/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
neg-sub0N/A
sub-negN/A
+-commutativeN/A
associate--r+N/A
neg-sub0N/A
remove-double-negN/A
--lowering--.f64N/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f64N/A
--lowering--.f6498.8%
Applied egg-rr98.8%
Taylor expanded in t around 0
/-lowering-/.f64N/A
*-lowering-*.f64N/A
--lowering--.f6472.1%
Simplified72.1%
if -2.34999999999999997e-116 < z < 3.70000000000000025e-60Initial program 95.7%
Taylor expanded in z around 0
/-lowering-/.f64N/A
*-lowering-*.f6471.5%
Simplified71.5%
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f6474.2%
Applied egg-rr74.2%
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. (FPCore (x y z t) :precision binary64 (if (<= z -4e+105) (/ (/ x (- z t)) z) (if (<= z 2.8e+134) (/ x (* (- t z) (- y z))) (/ (/ x z) (- z y)))))
assert(x < y && y < z && z < t);
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -4e+105) {
tmp = (x / (z - t)) / z;
} else if (z <= 2.8e+134) {
tmp = x / ((t - z) * (y - z));
} else {
tmp = (x / z) / (z - y);
}
return tmp;
}
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
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 <= (-4d+105)) then
tmp = (x / (z - t)) / z
else if (z <= 2.8d+134) then
tmp = x / ((t - z) * (y - z))
else
tmp = (x / z) / (z - y)
end if
code = tmp
end function
assert x < y && y < z && z < t;
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -4e+105) {
tmp = (x / (z - t)) / z;
} else if (z <= 2.8e+134) {
tmp = x / ((t - z) * (y - z));
} else {
tmp = (x / z) / (z - y);
}
return tmp;
}
[x, y, z, t] = sort([x, y, z, t]) def code(x, y, z, t): tmp = 0 if z <= -4e+105: tmp = (x / (z - t)) / z elif z <= 2.8e+134: tmp = x / ((t - z) * (y - z)) else: tmp = (x / z) / (z - y) return tmp
x, y, z, t = sort([x, y, z, t]) function code(x, y, z, t) tmp = 0.0 if (z <= -4e+105) tmp = Float64(Float64(x / Float64(z - t)) / z); elseif (z <= 2.8e+134) tmp = Float64(x / Float64(Float64(t - z) * Float64(y - z))); else tmp = Float64(Float64(x / z) / Float64(z - y)); end return tmp end
x, y, z, t = num2cell(sort([x, y, z, t])){:}
function tmp_2 = code(x, y, z, t)
tmp = 0.0;
if (z <= -4e+105)
tmp = (x / (z - t)) / z;
elseif (z <= 2.8e+134)
tmp = x / ((t - z) * (y - z));
else
tmp = (x / z) / (z - y);
end
tmp_2 = tmp;
end
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. code[x_, y_, z_, t_] := If[LessEqual[z, -4e+105], N[(N[(x / N[(z - t), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision], If[LessEqual[z, 2.8e+134], N[(x / N[(N[(t - z), $MachinePrecision] * N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x / z), $MachinePrecision] / N[(z - y), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t] = \mathsf{sort}([x, y, z, t])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -4 \cdot 10^{+105}:\\
\;\;\;\;\frac{\frac{x}{z - t}}{z}\\
\mathbf{elif}\;z \leq 2.8 \cdot 10^{+134}:\\
\;\;\;\;\frac{x}{\left(t - z\right) \cdot \left(y - z\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{x}{z}}{z - y}\\
\end{array}
\end{array}
if z < -3.9999999999999998e105Initial program 70.9%
clear-numN/A
*-commutativeN/A
associate-/l*N/A
associate-/r*N/A
flip3--N/A
clear-numN/A
/-lowering-/.f64N/A
clear-numN/A
flip3--N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
/-lowering-/.f64N/A
--lowering--.f6499.8%
Applied egg-rr99.8%
Taylor expanded in y around 0
mul-1-negN/A
associate-/r*N/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
neg-lowering-neg.f64N/A
--lowering--.f6494.9%
Simplified94.9%
clear-numN/A
inv-powN/A
associate-/r/N/A
neg-sub0N/A
associate--r-N/A
neg-sub0N/A
+-commutativeN/A
sub-negN/A
unpow-prod-downN/A
inv-powN/A
clear-numN/A
inv-powN/A
div-invN/A
/-lowering-/.f64N/A
sub-negN/A
+-commutativeN/A
neg-sub0N/A
associate--r-N/A
neg-sub0N/A
/-lowering-/.f64N/A
neg-sub0N/A
associate--r-N/A
neg-sub0N/A
+-commutativeN/A
sub-negN/A
--lowering--.f6494.9%
Applied egg-rr94.9%
if -3.9999999999999998e105 < z < 2.7999999999999999e134Initial program 95.0%
if 2.7999999999999999e134 < z Initial program 85.4%
clear-numN/A
*-commutativeN/A
associate-/l*N/A
associate-/r*N/A
flip3--N/A
clear-numN/A
/-lowering-/.f64N/A
clear-numN/A
flip3--N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
/-lowering-/.f64N/A
--lowering--.f6499.8%
Applied egg-rr99.8%
associate-/r/N/A
*-commutativeN/A
associate-*r/N/A
div-invN/A
frac-2negN/A
/-lowering-/.f64N/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
neg-sub0N/A
sub-negN/A
+-commutativeN/A
associate--r+N/A
neg-sub0N/A
remove-double-negN/A
--lowering--.f64N/A
neg-sub0N/A
sub-negN/A
+-commutativeN/A
associate--r+N/A
neg-sub0N/A
remove-double-negN/A
--lowering--.f6499.9%
Applied egg-rr99.9%
Taylor expanded in z around inf
/-lowering-/.f6495.2%
Simplified95.2%
Final simplification95.0%
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. (FPCore (x y z t) :precision binary64 (if (<= t -1.2e-157) (/ (/ x y) (- t z)) (if (<= t 980.0) (/ x (* z (- z y))) (/ (/ x t) (- y z)))))
assert(x < y && y < z && z < t);
double code(double x, double y, double z, double t) {
double tmp;
if (t <= -1.2e-157) {
tmp = (x / y) / (t - z);
} else if (t <= 980.0) {
tmp = x / (z * (z - y));
} else {
tmp = (x / t) / (y - z);
}
return tmp;
}
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
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 (t <= (-1.2d-157)) then
tmp = (x / y) / (t - z)
else if (t <= 980.0d0) then
tmp = x / (z * (z - y))
else
tmp = (x / t) / (y - z)
end if
code = tmp
end function
assert x < y && y < z && z < t;
public static double code(double x, double y, double z, double t) {
double tmp;
if (t <= -1.2e-157) {
tmp = (x / y) / (t - z);
} else if (t <= 980.0) {
tmp = x / (z * (z - y));
} else {
tmp = (x / t) / (y - z);
}
return tmp;
}
[x, y, z, t] = sort([x, y, z, t]) def code(x, y, z, t): tmp = 0 if t <= -1.2e-157: tmp = (x / y) / (t - z) elif t <= 980.0: tmp = x / (z * (z - y)) else: tmp = (x / t) / (y - z) return tmp
x, y, z, t = sort([x, y, z, t]) function code(x, y, z, t) tmp = 0.0 if (t <= -1.2e-157) tmp = Float64(Float64(x / y) / Float64(t - z)); elseif (t <= 980.0) tmp = Float64(x / Float64(z * Float64(z - y))); else tmp = Float64(Float64(x / t) / Float64(y - z)); end return tmp end
x, y, z, t = num2cell(sort([x, y, z, t])){:}
function tmp_2 = code(x, y, z, t)
tmp = 0.0;
if (t <= -1.2e-157)
tmp = (x / y) / (t - z);
elseif (t <= 980.0)
tmp = x / (z * (z - y));
else
tmp = (x / t) / (y - z);
end
tmp_2 = tmp;
end
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. code[x_, y_, z_, t_] := If[LessEqual[t, -1.2e-157], N[(N[(x / y), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 980.0], N[(x / N[(z * N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x / t), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t] = \mathsf{sort}([x, y, z, t])\\
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.2 \cdot 10^{-157}:\\
\;\;\;\;\frac{\frac{x}{y}}{t - z}\\
\mathbf{elif}\;t \leq 980:\\
\;\;\;\;\frac{x}{z \cdot \left(z - y\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{x}{t}}{y - z}\\
\end{array}
\end{array}
if t < -1.2e-157Initial program 92.5%
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
--lowering--.f6496.1%
Applied egg-rr96.1%
Taylor expanded in y around inf
Simplified62.3%
if -1.2e-157 < t < 980Initial program 88.7%
clear-numN/A
*-commutativeN/A
associate-/l*N/A
associate-/r*N/A
flip3--N/A
clear-numN/A
/-lowering-/.f64N/A
clear-numN/A
flip3--N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
/-lowering-/.f64N/A
--lowering--.f6494.9%
Applied egg-rr94.9%
associate-/l/N/A
associate-/r*N/A
clear-numN/A
frac-2negN/A
distribute-frac-neg2N/A
div-invN/A
distribute-rgt-neg-outN/A
*-lowering-*.f64N/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
neg-sub0N/A
sub-negN/A
+-commutativeN/A
associate--r+N/A
neg-sub0N/A
remove-double-negN/A
--lowering--.f64N/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f64N/A
--lowering--.f6495.6%
Applied egg-rr95.6%
Taylor expanded in t around 0
/-lowering-/.f64N/A
*-lowering-*.f64N/A
--lowering--.f6470.8%
Simplified70.8%
if 980 < t Initial program 82.4%
Taylor expanded in t around inf
Simplified79.0%
*-commutativeN/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
--lowering--.f6488.0%
Applied egg-rr88.0%
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. (FPCore (x y z t) :precision binary64 (if (<= t -3.5e-161) (/ x (* (- t z) y)) (if (<= t 980.0) (/ x (* z (- z y))) (/ (/ x t) (- y z)))))
assert(x < y && y < z && z < t);
double code(double x, double y, double z, double t) {
double tmp;
if (t <= -3.5e-161) {
tmp = x / ((t - z) * y);
} else if (t <= 980.0) {
tmp = x / (z * (z - y));
} else {
tmp = (x / t) / (y - z);
}
return tmp;
}
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
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 (t <= (-3.5d-161)) then
tmp = x / ((t - z) * y)
else if (t <= 980.0d0) then
tmp = x / (z * (z - y))
else
tmp = (x / t) / (y - z)
end if
code = tmp
end function
assert x < y && y < z && z < t;
public static double code(double x, double y, double z, double t) {
double tmp;
if (t <= -3.5e-161) {
tmp = x / ((t - z) * y);
} else if (t <= 980.0) {
tmp = x / (z * (z - y));
} else {
tmp = (x / t) / (y - z);
}
return tmp;
}
[x, y, z, t] = sort([x, y, z, t]) def code(x, y, z, t): tmp = 0 if t <= -3.5e-161: tmp = x / ((t - z) * y) elif t <= 980.0: tmp = x / (z * (z - y)) else: tmp = (x / t) / (y - z) return tmp
x, y, z, t = sort([x, y, z, t]) function code(x, y, z, t) tmp = 0.0 if (t <= -3.5e-161) tmp = Float64(x / Float64(Float64(t - z) * y)); elseif (t <= 980.0) tmp = Float64(x / Float64(z * Float64(z - y))); else tmp = Float64(Float64(x / t) / Float64(y - z)); end return tmp end
x, y, z, t = num2cell(sort([x, y, z, t])){:}
function tmp_2 = code(x, y, z, t)
tmp = 0.0;
if (t <= -3.5e-161)
tmp = x / ((t - z) * y);
elseif (t <= 980.0)
tmp = x / (z * (z - y));
else
tmp = (x / t) / (y - z);
end
tmp_2 = tmp;
end
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. code[x_, y_, z_, t_] := If[LessEqual[t, -3.5e-161], N[(x / N[(N[(t - z), $MachinePrecision] * y), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 980.0], N[(x / N[(z * N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x / t), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t] = \mathsf{sort}([x, y, z, t])\\
\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.5 \cdot 10^{-161}:\\
\;\;\;\;\frac{x}{\left(t - z\right) \cdot y}\\
\mathbf{elif}\;t \leq 980:\\
\;\;\;\;\frac{x}{z \cdot \left(z - y\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{x}{t}}{y - z}\\
\end{array}
\end{array}
if t < -3.5000000000000002e-161Initial program 92.5%
Taylor expanded in y around inf
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
--lowering--.f6462.5%
Simplified62.5%
if -3.5000000000000002e-161 < t < 980Initial program 88.7%
clear-numN/A
*-commutativeN/A
associate-/l*N/A
associate-/r*N/A
flip3--N/A
clear-numN/A
/-lowering-/.f64N/A
clear-numN/A
flip3--N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
/-lowering-/.f64N/A
--lowering--.f6494.9%
Applied egg-rr94.9%
associate-/l/N/A
associate-/r*N/A
clear-numN/A
frac-2negN/A
distribute-frac-neg2N/A
div-invN/A
distribute-rgt-neg-outN/A
*-lowering-*.f64N/A
distribute-neg-frac2N/A
/-lowering-/.f64N/A
neg-sub0N/A
sub-negN/A
+-commutativeN/A
associate--r+N/A
neg-sub0N/A
remove-double-negN/A
--lowering--.f64N/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f64N/A
--lowering--.f6495.6%
Applied egg-rr95.6%
Taylor expanded in t around 0
/-lowering-/.f64N/A
*-lowering-*.f64N/A
--lowering--.f6470.8%
Simplified70.8%
if 980 < t Initial program 82.4%
Taylor expanded in t around inf
Simplified79.0%
*-commutativeN/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
--lowering--.f6488.0%
Applied egg-rr88.0%
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. (FPCore (x y z t) :precision binary64 (if (<= z -2.9e+46) (/ (/ x z) z) (if (<= z 11000000.0) (/ (/ x y) t) (* (/ x z) (/ 1.0 z)))))
assert(x < y && y < z && z < t);
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -2.9e+46) {
tmp = (x / z) / z;
} else if (z <= 11000000.0) {
tmp = (x / y) / t;
} else {
tmp = (x / z) * (1.0 / z);
}
return tmp;
}
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
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.9d+46)) then
tmp = (x / z) / z
else if (z <= 11000000.0d0) then
tmp = (x / y) / t
else
tmp = (x / z) * (1.0d0 / z)
end if
code = tmp
end function
assert x < y && y < z && z < t;
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -2.9e+46) {
tmp = (x / z) / z;
} else if (z <= 11000000.0) {
tmp = (x / y) / t;
} else {
tmp = (x / z) * (1.0 / z);
}
return tmp;
}
[x, y, z, t] = sort([x, y, z, t]) def code(x, y, z, t): tmp = 0 if z <= -2.9e+46: tmp = (x / z) / z elif z <= 11000000.0: tmp = (x / y) / t else: tmp = (x / z) * (1.0 / z) return tmp
x, y, z, t = sort([x, y, z, t]) function code(x, y, z, t) tmp = 0.0 if (z <= -2.9e+46) tmp = Float64(Float64(x / z) / z); elseif (z <= 11000000.0) tmp = Float64(Float64(x / y) / t); else tmp = Float64(Float64(x / z) * Float64(1.0 / z)); end return tmp end
x, y, z, t = num2cell(sort([x, y, z, t])){:}
function tmp_2 = code(x, y, z, t)
tmp = 0.0;
if (z <= -2.9e+46)
tmp = (x / z) / z;
elseif (z <= 11000000.0)
tmp = (x / y) / t;
else
tmp = (x / z) * (1.0 / z);
end
tmp_2 = tmp;
end
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. code[x_, y_, z_, t_] := If[LessEqual[z, -2.9e+46], N[(N[(x / z), $MachinePrecision] / z), $MachinePrecision], If[LessEqual[z, 11000000.0], N[(N[(x / y), $MachinePrecision] / t), $MachinePrecision], N[(N[(x / z), $MachinePrecision] * N[(1.0 / z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t] = \mathsf{sort}([x, y, z, t])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.9 \cdot 10^{+46}:\\
\;\;\;\;\frac{\frac{x}{z}}{z}\\
\mathbf{elif}\;z \leq 11000000:\\
\;\;\;\;\frac{\frac{x}{y}}{t}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{z} \cdot \frac{1}{z}\\
\end{array}
\end{array}
if z < -2.9000000000000002e46Initial program 76.1%
Taylor expanded in z around inf
/-lowering-/.f64N/A
unpow2N/A
*-lowering-*.f6470.0%
Simplified70.0%
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f6485.1%
Applied egg-rr85.1%
if -2.9000000000000002e46 < z < 1.1e7Initial program 95.5%
Taylor expanded in z around 0
/-lowering-/.f64N/A
*-lowering-*.f6457.5%
Simplified57.5%
*-commutativeN/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f6459.9%
Applied egg-rr59.9%
if 1.1e7 < z Initial program 85.6%
Taylor expanded in z around inf
/-lowering-/.f64N/A
unpow2N/A
*-lowering-*.f6474.8%
Simplified74.8%
associate-/r*N/A
div-invN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
metadata-evalN/A
/-lowering-/.f64N/A
metadata-eval81.9%
Applied egg-rr81.9%
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. (FPCore (x y z t) :precision binary64 (let* ((t_1 (/ (/ x z) z))) (if (<= z -3.3e+46) t_1 (if (<= z 46000000.0) (/ (/ x y) t) t_1))))
assert(x < y && y < z && z < t);
double code(double x, double y, double z, double t) {
double t_1 = (x / z) / z;
double tmp;
if (z <= -3.3e+46) {
tmp = t_1;
} else if (z <= 46000000.0) {
tmp = (x / y) / t;
} else {
tmp = t_1;
}
return tmp;
}
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
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
if (z <= (-3.3d+46)) then
tmp = t_1
else if (z <= 46000000.0d0) then
tmp = (x / y) / t
else
tmp = t_1
end if
code = tmp
end function
assert x < y && y < z && z < t;
public static double code(double x, double y, double z, double t) {
double t_1 = (x / z) / z;
double tmp;
if (z <= -3.3e+46) {
tmp = t_1;
} else if (z <= 46000000.0) {
tmp = (x / y) / t;
} else {
tmp = t_1;
}
return tmp;
}
[x, y, z, t] = sort([x, y, z, t]) def code(x, y, z, t): t_1 = (x / z) / z tmp = 0 if z <= -3.3e+46: tmp = t_1 elif z <= 46000000.0: tmp = (x / y) / t else: tmp = t_1 return tmp
x, y, z, t = sort([x, y, z, t]) function code(x, y, z, t) t_1 = Float64(Float64(x / z) / z) tmp = 0.0 if (z <= -3.3e+46) tmp = t_1; elseif (z <= 46000000.0) tmp = Float64(Float64(x / y) / t); else tmp = t_1; end return tmp end
x, y, z, t = num2cell(sort([x, y, z, t])){:}
function tmp_2 = code(x, y, z, t)
t_1 = (x / z) / z;
tmp = 0.0;
if (z <= -3.3e+46)
tmp = t_1;
elseif (z <= 46000000.0)
tmp = (x / y) / t;
else
tmp = t_1;
end
tmp_2 = tmp;
end
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x / z), $MachinePrecision] / z), $MachinePrecision]}, If[LessEqual[z, -3.3e+46], t$95$1, If[LessEqual[z, 46000000.0], N[(N[(x / y), $MachinePrecision] / t), $MachinePrecision], t$95$1]]]
\begin{array}{l}
[x, y, z, t] = \mathsf{sort}([x, y, z, t])\\
\\
\begin{array}{l}
t_1 := \frac{\frac{x}{z}}{z}\\
\mathbf{if}\;z \leq -3.3 \cdot 10^{+46}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq 46000000:\\
\;\;\;\;\frac{\frac{x}{y}}{t}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -3.2999999999999998e46 or 4.6e7 < z Initial program 80.5%
Taylor expanded in z around inf
/-lowering-/.f64N/A
unpow2N/A
*-lowering-*.f6472.2%
Simplified72.2%
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f6483.6%
Applied egg-rr83.6%
if -3.2999999999999998e46 < z < 4.6e7Initial program 95.5%
Taylor expanded in z around 0
/-lowering-/.f64N/A
*-lowering-*.f6457.5%
Simplified57.5%
*-commutativeN/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f6459.9%
Applied egg-rr59.9%
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. (FPCore (x y z t) :precision binary64 (let* ((t_1 (/ x (* z z)))) (if (<= z -2.5e+46) t_1 (if (<= z 165.0) (/ (/ x y) t) t_1))))
assert(x < y && y < z && z < t);
double code(double x, double y, double z, double t) {
double t_1 = x / (z * z);
double tmp;
if (z <= -2.5e+46) {
tmp = t_1;
} else if (z <= 165.0) {
tmp = (x / y) / t;
} else {
tmp = t_1;
}
return tmp;
}
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
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)
if (z <= (-2.5d+46)) then
tmp = t_1
else if (z <= 165.0d0) then
tmp = (x / y) / t
else
tmp = t_1
end if
code = tmp
end function
assert x < y && y < z && z < t;
public static double code(double x, double y, double z, double t) {
double t_1 = x / (z * z);
double tmp;
if (z <= -2.5e+46) {
tmp = t_1;
} else if (z <= 165.0) {
tmp = (x / y) / t;
} else {
tmp = t_1;
}
return tmp;
}
[x, y, z, t] = sort([x, y, z, t]) def code(x, y, z, t): t_1 = x / (z * z) tmp = 0 if z <= -2.5e+46: tmp = t_1 elif z <= 165.0: tmp = (x / y) / t else: tmp = t_1 return tmp
x, y, z, t = sort([x, y, z, t]) function code(x, y, z, t) t_1 = Float64(x / Float64(z * z)) tmp = 0.0 if (z <= -2.5e+46) tmp = t_1; elseif (z <= 165.0) tmp = Float64(Float64(x / y) / t); else tmp = t_1; end return tmp end
x, y, z, t = num2cell(sort([x, y, z, t])){:}
function tmp_2 = code(x, y, z, t)
t_1 = x / (z * z);
tmp = 0.0;
if (z <= -2.5e+46)
tmp = t_1;
elseif (z <= 165.0)
tmp = (x / y) / t;
else
tmp = t_1;
end
tmp_2 = tmp;
end
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x / N[(z * z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2.5e+46], t$95$1, If[LessEqual[z, 165.0], N[(N[(x / y), $MachinePrecision] / t), $MachinePrecision], t$95$1]]]
\begin{array}{l}
[x, y, z, t] = \mathsf{sort}([x, y, z, t])\\
\\
\begin{array}{l}
t_1 := \frac{x}{z \cdot z}\\
\mathbf{if}\;z \leq -2.5 \cdot 10^{+46}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq 165:\\
\;\;\;\;\frac{\frac{x}{y}}{t}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -2.5000000000000001e46 or 165 < z Initial program 80.5%
Taylor expanded in z around inf
/-lowering-/.f64N/A
unpow2N/A
*-lowering-*.f6472.2%
Simplified72.2%
if -2.5000000000000001e46 < z < 165Initial program 95.5%
Taylor expanded in z around 0
/-lowering-/.f64N/A
*-lowering-*.f6457.5%
Simplified57.5%
*-commutativeN/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f6459.9%
Applied egg-rr59.9%
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. (FPCore (x y z t) :precision binary64 (let* ((t_1 (/ x (* z z)))) (if (<= z -2.5e+46) t_1 (if (<= z 260000.0) (/ (/ x t) y) t_1))))
assert(x < y && y < z && z < t);
double code(double x, double y, double z, double t) {
double t_1 = x / (z * z);
double tmp;
if (z <= -2.5e+46) {
tmp = t_1;
} else if (z <= 260000.0) {
tmp = (x / t) / y;
} else {
tmp = t_1;
}
return tmp;
}
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
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)
if (z <= (-2.5d+46)) then
tmp = t_1
else if (z <= 260000.0d0) then
tmp = (x / t) / y
else
tmp = t_1
end if
code = tmp
end function
assert x < y && y < z && z < t;
public static double code(double x, double y, double z, double t) {
double t_1 = x / (z * z);
double tmp;
if (z <= -2.5e+46) {
tmp = t_1;
} else if (z <= 260000.0) {
tmp = (x / t) / y;
} else {
tmp = t_1;
}
return tmp;
}
[x, y, z, t] = sort([x, y, z, t]) def code(x, y, z, t): t_1 = x / (z * z) tmp = 0 if z <= -2.5e+46: tmp = t_1 elif z <= 260000.0: tmp = (x / t) / y else: tmp = t_1 return tmp
x, y, z, t = sort([x, y, z, t]) function code(x, y, z, t) t_1 = Float64(x / Float64(z * z)) tmp = 0.0 if (z <= -2.5e+46) tmp = t_1; elseif (z <= 260000.0) tmp = Float64(Float64(x / t) / y); else tmp = t_1; end return tmp end
x, y, z, t = num2cell(sort([x, y, z, t])){:}
function tmp_2 = code(x, y, z, t)
t_1 = x / (z * z);
tmp = 0.0;
if (z <= -2.5e+46)
tmp = t_1;
elseif (z <= 260000.0)
tmp = (x / t) / y;
else
tmp = t_1;
end
tmp_2 = tmp;
end
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x / N[(z * z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2.5e+46], t$95$1, If[LessEqual[z, 260000.0], N[(N[(x / t), $MachinePrecision] / y), $MachinePrecision], t$95$1]]]
\begin{array}{l}
[x, y, z, t] = \mathsf{sort}([x, y, z, t])\\
\\
\begin{array}{l}
t_1 := \frac{x}{z \cdot z}\\
\mathbf{if}\;z \leq -2.5 \cdot 10^{+46}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq 260000:\\
\;\;\;\;\frac{\frac{x}{t}}{y}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -2.5000000000000001e46 or 2.6e5 < z Initial program 80.5%
Taylor expanded in z around inf
/-lowering-/.f64N/A
unpow2N/A
*-lowering-*.f6472.2%
Simplified72.2%
if -2.5000000000000001e46 < z < 2.6e5Initial program 95.5%
Taylor expanded in z around 0
/-lowering-/.f64N/A
*-lowering-*.f6457.5%
Simplified57.5%
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f6460.3%
Applied egg-rr60.3%
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. (FPCore (x y z t) :precision binary64 (let* ((t_1 (/ x (* z z)))) (if (<= z -2.6e-76) t_1 (if (<= z 4000000.0) (/ x (* t y)) t_1))))
assert(x < y && y < z && z < t);
double code(double x, double y, double z, double t) {
double t_1 = x / (z * z);
double tmp;
if (z <= -2.6e-76) {
tmp = t_1;
} else if (z <= 4000000.0) {
tmp = x / (t * y);
} else {
tmp = t_1;
}
return tmp;
}
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
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)
if (z <= (-2.6d-76)) then
tmp = t_1
else if (z <= 4000000.0d0) then
tmp = x / (t * y)
else
tmp = t_1
end if
code = tmp
end function
assert x < y && y < z && z < t;
public static double code(double x, double y, double z, double t) {
double t_1 = x / (z * z);
double tmp;
if (z <= -2.6e-76) {
tmp = t_1;
} else if (z <= 4000000.0) {
tmp = x / (t * y);
} else {
tmp = t_1;
}
return tmp;
}
[x, y, z, t] = sort([x, y, z, t]) def code(x, y, z, t): t_1 = x / (z * z) tmp = 0 if z <= -2.6e-76: tmp = t_1 elif z <= 4000000.0: tmp = x / (t * y) else: tmp = t_1 return tmp
x, y, z, t = sort([x, y, z, t]) function code(x, y, z, t) t_1 = Float64(x / Float64(z * z)) tmp = 0.0 if (z <= -2.6e-76) tmp = t_1; elseif (z <= 4000000.0) tmp = Float64(x / Float64(t * y)); else tmp = t_1; end return tmp end
x, y, z, t = num2cell(sort([x, y, z, t])){:}
function tmp_2 = code(x, y, z, t)
t_1 = x / (z * z);
tmp = 0.0;
if (z <= -2.6e-76)
tmp = t_1;
elseif (z <= 4000000.0)
tmp = x / (t * y);
else
tmp = t_1;
end
tmp_2 = tmp;
end
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x / N[(z * z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2.6e-76], t$95$1, If[LessEqual[z, 4000000.0], N[(x / N[(t * y), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
[x, y, z, t] = \mathsf{sort}([x, y, z, t])\\
\\
\begin{array}{l}
t_1 := \frac{x}{z \cdot z}\\
\mathbf{if}\;z \leq -2.6 \cdot 10^{-76}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq 4000000:\\
\;\;\;\;\frac{x}{t \cdot y}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -2.6e-76 or 4e6 < z Initial program 82.4%
Taylor expanded in z around inf
/-lowering-/.f64N/A
unpow2N/A
*-lowering-*.f6463.7%
Simplified63.7%
if -2.6e-76 < z < 4e6Initial program 96.5%
Taylor expanded in z around 0
/-lowering-/.f64N/A
*-lowering-*.f6464.4%
Simplified64.4%
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. (FPCore (x y z t) :precision binary64 (/ (/ 1.0 (- t z)) (/ (- y z) x)))
assert(x < y && y < z && z < t);
double code(double x, double y, double z, double t) {
return (1.0 / (t - z)) / ((y - z) / x);
}
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
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 = (1.0d0 / (t - z)) / ((y - z) / x)
end function
assert x < y && y < z && z < t;
public static double code(double x, double y, double z, double t) {
return (1.0 / (t - z)) / ((y - z) / x);
}
[x, y, z, t] = sort([x, y, z, t]) def code(x, y, z, t): return (1.0 / (t - z)) / ((y - z) / x)
x, y, z, t = sort([x, y, z, t]) function code(x, y, z, t) return Float64(Float64(1.0 / Float64(t - z)) / Float64(Float64(y - z) / x)) end
x, y, z, t = num2cell(sort([x, y, z, t])){:}
function tmp = code(x, y, z, t)
tmp = (1.0 / (t - z)) / ((y - z) / x);
end
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. code[x_, y_, z_, t_] := N[(N[(1.0 / N[(t - z), $MachinePrecision]), $MachinePrecision] / N[(N[(y - z), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[x, y, z, t] = \mathsf{sort}([x, y, z, t])\\
\\
\frac{\frac{1}{t - z}}{\frac{y - z}{x}}
\end{array}
Initial program 88.9%
clear-numN/A
*-commutativeN/A
associate-/l*N/A
associate-/r*N/A
flip3--N/A
clear-numN/A
/-lowering-/.f64N/A
clear-numN/A
flip3--N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
/-lowering-/.f64N/A
--lowering--.f6495.9%
Applied egg-rr95.9%
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. (FPCore (x y z t) :precision binary64 (/ (/ x (- y z)) (- t z)))
assert(x < y && y < z && z < t);
double code(double x, double y, double z, double t) {
return (x / (y - z)) / (t - z);
}
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
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
assert x < y && y < z && z < t;
public static double code(double x, double y, double z, double t) {
return (x / (y - z)) / (t - z);
}
[x, y, z, t] = sort([x, y, z, t]) def code(x, y, z, t): return (x / (y - z)) / (t - z)
x, y, z, t = sort([x, y, z, t]) function code(x, y, z, t) return Float64(Float64(x / Float64(y - z)) / Float64(t - z)) end
x, y, z, t = num2cell(sort([x, y, z, t])){:}
function tmp = code(x, y, z, t)
tmp = (x / (y - z)) / (t - z);
end
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. code[x_, y_, z_, t_] := N[(N[(x / N[(y - z), $MachinePrecision]), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[x, y, z, t] = \mathsf{sort}([x, y, z, t])\\
\\
\frac{\frac{x}{y - z}}{t - z}
\end{array}
Initial program 88.9%
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
--lowering--.f6496.0%
Applied egg-rr96.0%
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. (FPCore (x y z t) :precision binary64 (/ x (* t y)))
assert(x < y && y < z && z < t);
double code(double x, double y, double z, double t) {
return x / (t * y);
}
NOTE: x, y, z, and t should be sorted in increasing order before calling this function.
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 * y)
end function
assert x < y && y < z && z < t;
public static double code(double x, double y, double z, double t) {
return x / (t * y);
}
[x, y, z, t] = sort([x, y, z, t]) def code(x, y, z, t): return x / (t * y)
x, y, z, t = sort([x, y, z, t]) function code(x, y, z, t) return Float64(x / Float64(t * y)) end
x, y, z, t = num2cell(sort([x, y, z, t])){:}
function tmp = code(x, y, z, t)
tmp = x / (t * y);
end
NOTE: x, y, z, and t should be sorted in increasing order before calling this function. code[x_, y_, z_, t_] := N[(x / N[(t * y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[x, y, z, t] = \mathsf{sort}([x, y, z, t])\\
\\
\frac{x}{t \cdot y}
\end{array}
Initial program 88.9%
Taylor expanded in z around 0
/-lowering-/.f64N/A
*-lowering-*.f6441.4%
Simplified41.4%
(FPCore (x y z t) :precision binary64 (let* ((t_1 (* (- y z) (- t z)))) (if (< (/ x t_1) 0.0) (/ (/ x (- y z)) (- t z)) (* x (/ 1.0 t_1)))))
double code(double x, double y, double z, double t) {
double t_1 = (y - z) * (t - z);
double tmp;
if ((x / t_1) < 0.0) {
tmp = (x / (y - z)) / (t - z);
} else {
tmp = x * (1.0 / 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 = (y - z) * (t - z)
if ((x / t_1) < 0.0d0) then
tmp = (x / (y - z)) / (t - z)
else
tmp = x * (1.0d0 / t_1)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = (y - z) * (t - z);
double tmp;
if ((x / t_1) < 0.0) {
tmp = (x / (y - z)) / (t - z);
} else {
tmp = x * (1.0 / t_1);
}
return tmp;
}
def code(x, y, z, t): t_1 = (y - z) * (t - z) tmp = 0 if (x / t_1) < 0.0: tmp = (x / (y - z)) / (t - z) else: tmp = x * (1.0 / t_1) return tmp
function code(x, y, z, t) t_1 = Float64(Float64(y - z) * Float64(t - z)) tmp = 0.0 if (Float64(x / t_1) < 0.0) tmp = Float64(Float64(x / Float64(y - z)) / Float64(t - z)); else tmp = Float64(x * Float64(1.0 / t_1)); end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = (y - z) * (t - z); tmp = 0.0; if ((x / t_1) < 0.0) tmp = (x / (y - z)) / (t - z); else tmp = x * (1.0 / t_1); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(y - z), $MachinePrecision] * N[(t - z), $MachinePrecision]), $MachinePrecision]}, If[Less[N[(x / t$95$1), $MachinePrecision], 0.0], N[(N[(x / N[(y - z), $MachinePrecision]), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision], N[(x * N[(1.0 / t$95$1), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(y - z\right) \cdot \left(t - z\right)\\
\mathbf{if}\;\frac{x}{t\_1} < 0:\\
\;\;\;\;\frac{\frac{x}{y - z}}{t - z}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{1}{t\_1}\\
\end{array}
\end{array}
herbie shell --seed 2024158
(FPCore (x y z t)
:name "Data.Random.Distribution.Triangular:triangularCDF from random-fu-0.2.6.2, B"
:precision binary64
:alt
(! :herbie-platform default (if (< (/ x (* (- y z) (- t z))) 0) (/ (/ x (- y z)) (- t z)) (* x (/ 1 (* (- y z) (- t z))))))
(/ x (* (- y z) (- t z))))