
(FPCore (x y z t) :precision binary64 (/ (* x 2.0) (- (* y z) (* t z))))
double code(double x, double y, double z, double t) {
return (x * 2.0) / ((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 * 2.0d0) / ((y * z) - (t * z))
end function
public static double code(double x, double y, double z, double t) {
return (x * 2.0) / ((y * z) - (t * z));
}
def code(x, y, z, t): return (x * 2.0) / ((y * z) - (t * z))
function code(x, y, z, t) return Float64(Float64(x * 2.0) / Float64(Float64(y * z) - Float64(t * z))) end
function tmp = code(x, y, z, t) tmp = (x * 2.0) / ((y * z) - (t * z)); end
code[x_, y_, z_, t_] := N[(N[(x * 2.0), $MachinePrecision] / N[(N[(y * z), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x \cdot 2}{y \cdot z - t \cdot z}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 15 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t) :precision binary64 (/ (* x 2.0) (- (* y z) (* t z))))
double code(double x, double y, double z, double t) {
return (x * 2.0) / ((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 * 2.0d0) / ((y * z) - (t * z))
end function
public static double code(double x, double y, double z, double t) {
return (x * 2.0) / ((y * z) - (t * z));
}
def code(x, y, z, t): return (x * 2.0) / ((y * z) - (t * z))
function code(x, y, z, t) return Float64(Float64(x * 2.0) / Float64(Float64(y * z) - Float64(t * z))) end
function tmp = code(x, y, z, t) tmp = (x * 2.0) / ((y * z) - (t * z)); end
code[x_, y_, z_, t_] := N[(N[(x * 2.0), $MachinePrecision] / N[(N[(y * z), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x \cdot 2}{y \cdot z - t \cdot z}
\end{array}
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (- (* y z) (* z t))))
(if (or (<= t_1 (- INFINITY)) (not (<= t_1 5e+223)))
(* 2.0 (/ (/ x z) (- y t)))
(/ (* 2.0 x) (* z (- y t))))))
double code(double x, double y, double z, double t) {
double t_1 = (y * z) - (z * t);
double tmp;
if ((t_1 <= -((double) INFINITY)) || !(t_1 <= 5e+223)) {
tmp = 2.0 * ((x / z) / (y - t));
} else {
tmp = (2.0 * x) / (z * (y - t));
}
return tmp;
}
public static double code(double x, double y, double z, double t) {
double t_1 = (y * z) - (z * t);
double tmp;
if ((t_1 <= -Double.POSITIVE_INFINITY) || !(t_1 <= 5e+223)) {
tmp = 2.0 * ((x / z) / (y - t));
} else {
tmp = (2.0 * x) / (z * (y - t));
}
return tmp;
}
def code(x, y, z, t): t_1 = (y * z) - (z * t) tmp = 0 if (t_1 <= -math.inf) or not (t_1 <= 5e+223): tmp = 2.0 * ((x / z) / (y - t)) else: tmp = (2.0 * x) / (z * (y - t)) return tmp
function code(x, y, z, t) t_1 = Float64(Float64(y * z) - Float64(z * t)) tmp = 0.0 if ((t_1 <= Float64(-Inf)) || !(t_1 <= 5e+223)) tmp = Float64(2.0 * Float64(Float64(x / z) / Float64(y - t))); else tmp = Float64(Float64(2.0 * x) / Float64(z * Float64(y - t))); end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = (y * z) - (z * t); tmp = 0.0; if ((t_1 <= -Inf) || ~((t_1 <= 5e+223))) tmp = 2.0 * ((x / z) / (y - t)); else tmp = (2.0 * x) / (z * (y - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(y * z), $MachinePrecision] - N[(z * t), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$1, (-Infinity)], N[Not[LessEqual[t$95$1, 5e+223]], $MachinePrecision]], N[(2.0 * N[(N[(x / z), $MachinePrecision] / N[(y - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(2.0 * x), $MachinePrecision] / N[(z * N[(y - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot z - z \cdot t\\
\mathbf{if}\;t_1 \leq -\infty \lor \neg \left(t_1 \leq 5 \cdot 10^{+223}\right):\\
\;\;\;\;2 \cdot \frac{\frac{x}{z}}{y - t}\\
\mathbf{else}:\\
\;\;\;\;\frac{2 \cdot x}{z \cdot \left(y - t\right)}\\
\end{array}
\end{array}
if (-.f64 (*.f64 y z) (*.f64 t z)) < -inf.0 or 4.99999999999999985e223 < (-.f64 (*.f64 y z) (*.f64 t z)) Initial program 56.9%
*-commutative56.9%
associate-*r/56.9%
distribute-rgt-out--62.0%
associate-/r*99.8%
Simplified99.8%
if -inf.0 < (-.f64 (*.f64 y z) (*.f64 t z)) < 4.99999999999999985e223Initial program 97.6%
distribute-rgt-out--97.7%
Simplified97.7%
Final simplification98.3%
(FPCore (x y z t) :precision binary64 (if (or (<= (* 2.0 x) -1e-133) (not (<= (* 2.0 x) 5e+16))) (* (/ x (- y t)) (/ 2.0 z)) (* 2.0 (/ (/ x z) (- y t)))))
double code(double x, double y, double z, double t) {
double tmp;
if (((2.0 * x) <= -1e-133) || !((2.0 * x) <= 5e+16)) {
tmp = (x / (y - t)) * (2.0 / z);
} else {
tmp = 2.0 * ((x / z) / (y - 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 (((2.0d0 * x) <= (-1d-133)) .or. (.not. ((2.0d0 * x) <= 5d+16))) then
tmp = (x / (y - t)) * (2.0d0 / z)
else
tmp = 2.0d0 * ((x / z) / (y - t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (((2.0 * x) <= -1e-133) || !((2.0 * x) <= 5e+16)) {
tmp = (x / (y - t)) * (2.0 / z);
} else {
tmp = 2.0 * ((x / z) / (y - t));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if ((2.0 * x) <= -1e-133) or not ((2.0 * x) <= 5e+16): tmp = (x / (y - t)) * (2.0 / z) else: tmp = 2.0 * ((x / z) / (y - t)) return tmp
function code(x, y, z, t) tmp = 0.0 if ((Float64(2.0 * x) <= -1e-133) || !(Float64(2.0 * x) <= 5e+16)) tmp = Float64(Float64(x / Float64(y - t)) * Float64(2.0 / z)); else tmp = Float64(2.0 * Float64(Float64(x / z) / Float64(y - t))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (((2.0 * x) <= -1e-133) || ~(((2.0 * x) <= 5e+16))) tmp = (x / (y - t)) * (2.0 / z); else tmp = 2.0 * ((x / z) / (y - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[N[(2.0 * x), $MachinePrecision], -1e-133], N[Not[LessEqual[N[(2.0 * x), $MachinePrecision], 5e+16]], $MachinePrecision]], N[(N[(x / N[(y - t), $MachinePrecision]), $MachinePrecision] * N[(2.0 / z), $MachinePrecision]), $MachinePrecision], N[(2.0 * N[(N[(x / z), $MachinePrecision] / N[(y - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;2 \cdot x \leq -1 \cdot 10^{-133} \lor \neg \left(2 \cdot x \leq 5 \cdot 10^{+16}\right):\\
\;\;\;\;\frac{x}{y - t} \cdot \frac{2}{z}\\
\mathbf{else}:\\
\;\;\;\;2 \cdot \frac{\frac{x}{z}}{y - t}\\
\end{array}
\end{array}
if (*.f64 x 2) < -1.0000000000000001e-133 or 5e16 < (*.f64 x 2) Initial program 79.1%
*-commutative79.1%
distribute-rgt-out--81.1%
times-frac96.4%
Simplified96.4%
if -1.0000000000000001e-133 < (*.f64 x 2) < 5e16Initial program 94.7%
*-commutative94.7%
associate-*r/94.7%
distribute-rgt-out--95.9%
associate-/r*97.4%
Simplified97.4%
Final simplification96.8%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* (/ 2.0 z) (/ x y))))
(if (<= y -9.6)
t_1
(if (<= y -4.7e-120)
(/ (/ -2.0 t) (/ z x))
(if (<= y -5e-154)
(/ (* 2.0 x) (* y z))
(if (<= y 3.15e-80) (* (/ (/ x t) z) (- 2.0)) t_1))))))
double code(double x, double y, double z, double t) {
double t_1 = (2.0 / z) * (x / y);
double tmp;
if (y <= -9.6) {
tmp = t_1;
} else if (y <= -4.7e-120) {
tmp = (-2.0 / t) / (z / x);
} else if (y <= -5e-154) {
tmp = (2.0 * x) / (y * z);
} else if (y <= 3.15e-80) {
tmp = ((x / t) / z) * -2.0;
} 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 = (2.0d0 / z) * (x / y)
if (y <= (-9.6d0)) then
tmp = t_1
else if (y <= (-4.7d-120)) then
tmp = ((-2.0d0) / t) / (z / x)
else if (y <= (-5d-154)) then
tmp = (2.0d0 * x) / (y * z)
else if (y <= 3.15d-80) then
tmp = ((x / t) / z) * -2.0d0
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 = (2.0 / z) * (x / y);
double tmp;
if (y <= -9.6) {
tmp = t_1;
} else if (y <= -4.7e-120) {
tmp = (-2.0 / t) / (z / x);
} else if (y <= -5e-154) {
tmp = (2.0 * x) / (y * z);
} else if (y <= 3.15e-80) {
tmp = ((x / t) / z) * -2.0;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t): t_1 = (2.0 / z) * (x / y) tmp = 0 if y <= -9.6: tmp = t_1 elif y <= -4.7e-120: tmp = (-2.0 / t) / (z / x) elif y <= -5e-154: tmp = (2.0 * x) / (y * z) elif y <= 3.15e-80: tmp = ((x / t) / z) * -2.0 else: tmp = t_1 return tmp
function code(x, y, z, t) t_1 = Float64(Float64(2.0 / z) * Float64(x / y)) tmp = 0.0 if (y <= -9.6) tmp = t_1; elseif (y <= -4.7e-120) tmp = Float64(Float64(-2.0 / t) / Float64(z / x)); elseif (y <= -5e-154) tmp = Float64(Float64(2.0 * x) / Float64(y * z)); elseif (y <= 3.15e-80) tmp = Float64(Float64(Float64(x / t) / z) * Float64(-2.0)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = (2.0 / z) * (x / y); tmp = 0.0; if (y <= -9.6) tmp = t_1; elseif (y <= -4.7e-120) tmp = (-2.0 / t) / (z / x); elseif (y <= -5e-154) tmp = (2.0 * x) / (y * z); elseif (y <= 3.15e-80) tmp = ((x / t) / z) * -2.0; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(2.0 / z), $MachinePrecision] * N[(x / y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -9.6], t$95$1, If[LessEqual[y, -4.7e-120], N[(N[(-2.0 / t), $MachinePrecision] / N[(z / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -5e-154], N[(N[(2.0 * x), $MachinePrecision] / N[(y * z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3.15e-80], N[(N[(N[(x / t), $MachinePrecision] / z), $MachinePrecision] * (-2.0)), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{2}{z} \cdot \frac{x}{y}\\
\mathbf{if}\;y \leq -9.6:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq -4.7 \cdot 10^{-120}:\\
\;\;\;\;\frac{\frac{-2}{t}}{\frac{z}{x}}\\
\mathbf{elif}\;y \leq -5 \cdot 10^{-154}:\\
\;\;\;\;\frac{2 \cdot x}{y \cdot z}\\
\mathbf{elif}\;y \leq 3.15 \cdot 10^{-80}:\\
\;\;\;\;\frac{\frac{x}{t}}{z} \cdot \left(-2\right)\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if y < -9.59999999999999964 or 3.14999999999999983e-80 < y Initial program 80.7%
*-commutative80.7%
distribute-rgt-out--83.6%
times-frac93.2%
Simplified93.2%
Taylor expanded in y around inf 72.7%
associate-*r/72.7%
*-commutative72.7%
times-frac79.2%
Simplified79.2%
if -9.59999999999999964 < y < -4.70000000000000016e-120Initial program 85.5%
*-commutative85.5%
distribute-rgt-out--85.5%
times-frac96.4%
Simplified96.4%
frac-times85.5%
*-commutative85.5%
times-frac92.2%
clear-num92.1%
associate-*l/93.4%
*-un-lft-identity93.4%
Applied egg-rr93.4%
Taylor expanded in y around 0 71.3%
if -4.70000000000000016e-120 < y < -5.0000000000000002e-154Initial program 99.8%
distribute-rgt-out--99.8%
Simplified99.8%
Taylor expanded in y around inf 67.2%
*-commutative67.2%
Simplified67.2%
if -5.0000000000000002e-154 < y < 3.14999999999999983e-80Initial program 90.0%
*-commutative90.0%
associate-*r/90.0%
distribute-rgt-out--90.1%
associate-/r*91.3%
Simplified91.3%
Taylor expanded in y around 0 80.5%
mul-1-neg80.5%
distribute-frac-neg80.5%
associate-/r*80.8%
Simplified80.8%
Final simplification78.4%
(FPCore (x y z t)
:precision binary64
(if (or (<= y -25.0)
(and (not (<= y 7.2e-78)) (or (<= y 3450000.0) (not (<= y 7.8e+90)))))
(* (/ x z) (/ 2.0 y))
(* -2.0 (/ (/ x z) t))))
double code(double x, double y, double z, double t) {
double tmp;
if ((y <= -25.0) || (!(y <= 7.2e-78) && ((y <= 3450000.0) || !(y <= 7.8e+90)))) {
tmp = (x / z) * (2.0 / y);
} else {
tmp = -2.0 * ((x / 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 ((y <= (-25.0d0)) .or. (.not. (y <= 7.2d-78)) .and. (y <= 3450000.0d0) .or. (.not. (y <= 7.8d+90))) then
tmp = (x / z) * (2.0d0 / y)
else
tmp = (-2.0d0) * ((x / z) / t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if ((y <= -25.0) || (!(y <= 7.2e-78) && ((y <= 3450000.0) || !(y <= 7.8e+90)))) {
tmp = (x / z) * (2.0 / y);
} else {
tmp = -2.0 * ((x / z) / t);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (y <= -25.0) or (not (y <= 7.2e-78) and ((y <= 3450000.0) or not (y <= 7.8e+90))): tmp = (x / z) * (2.0 / y) else: tmp = -2.0 * ((x / z) / t) return tmp
function code(x, y, z, t) tmp = 0.0 if ((y <= -25.0) || (!(y <= 7.2e-78) && ((y <= 3450000.0) || !(y <= 7.8e+90)))) tmp = Float64(Float64(x / z) * Float64(2.0 / y)); else tmp = Float64(-2.0 * Float64(Float64(x / z) / t)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((y <= -25.0) || (~((y <= 7.2e-78)) && ((y <= 3450000.0) || ~((y <= 7.8e+90))))) tmp = (x / z) * (2.0 / y); else tmp = -2.0 * ((x / z) / t); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[y, -25.0], And[N[Not[LessEqual[y, 7.2e-78]], $MachinePrecision], Or[LessEqual[y, 3450000.0], N[Not[LessEqual[y, 7.8e+90]], $MachinePrecision]]]], N[(N[(x / z), $MachinePrecision] * N[(2.0 / y), $MachinePrecision]), $MachinePrecision], N[(-2.0 * N[(N[(x / z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -25 \lor \neg \left(y \leq 7.2 \cdot 10^{-78}\right) \land \left(y \leq 3450000 \lor \neg \left(y \leq 7.8 \cdot 10^{+90}\right)\right):\\
\;\;\;\;\frac{x}{z} \cdot \frac{2}{y}\\
\mathbf{else}:\\
\;\;\;\;-2 \cdot \frac{\frac{x}{z}}{t}\\
\end{array}
\end{array}
if y < -25 or 7.2000000000000005e-78 < y < 3.45e6 or 7.8000000000000004e90 < y Initial program 82.0%
*-commutative82.0%
distribute-rgt-out--83.8%
times-frac93.2%
Simplified93.2%
Taylor expanded in y around inf 76.0%
associate-*r/76.0%
*-commutative76.0%
times-frac83.7%
Simplified83.7%
clear-num83.1%
frac-times82.7%
metadata-eval82.7%
Applied egg-rr82.7%
associate-/l/83.2%
div-inv83.2%
div-inv83.1%
times-frac79.2%
associate-/r*79.2%
div-inv79.3%
clear-num79.3%
Applied egg-rr79.3%
if -25 < y < 7.2000000000000005e-78 or 3.45e6 < y < 7.8000000000000004e90Initial program 87.2%
*-commutative87.2%
distribute-rgt-out--88.8%
times-frac93.6%
Simplified93.6%
frac-times88.8%
*-commutative88.8%
times-frac91.7%
clear-num90.6%
associate-*l/91.1%
*-un-lft-identity91.1%
Applied egg-rr91.1%
Taylor expanded in y around 0 66.5%
*-commutative66.5%
associate-/r*71.4%
Simplified71.4%
Final simplification75.2%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* (/ x z) (/ 2.0 y))))
(if (<= y -0.88)
t_1
(if (<= y 3e-78)
(* (/ x t) (/ -2.0 z))
(if (or (<= y 1.82) (not (<= y 7e+90))) t_1 (* -2.0 (/ (/ x z) t)))))))
double code(double x, double y, double z, double t) {
double t_1 = (x / z) * (2.0 / y);
double tmp;
if (y <= -0.88) {
tmp = t_1;
} else if (y <= 3e-78) {
tmp = (x / t) * (-2.0 / z);
} else if ((y <= 1.82) || !(y <= 7e+90)) {
tmp = t_1;
} else {
tmp = -2.0 * ((x / 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) * (2.0d0 / y)
if (y <= (-0.88d0)) then
tmp = t_1
else if (y <= 3d-78) then
tmp = (x / t) * ((-2.0d0) / z)
else if ((y <= 1.82d0) .or. (.not. (y <= 7d+90))) then
tmp = t_1
else
tmp = (-2.0d0) * ((x / 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) * (2.0 / y);
double tmp;
if (y <= -0.88) {
tmp = t_1;
} else if (y <= 3e-78) {
tmp = (x / t) * (-2.0 / z);
} else if ((y <= 1.82) || !(y <= 7e+90)) {
tmp = t_1;
} else {
tmp = -2.0 * ((x / z) / t);
}
return tmp;
}
def code(x, y, z, t): t_1 = (x / z) * (2.0 / y) tmp = 0 if y <= -0.88: tmp = t_1 elif y <= 3e-78: tmp = (x / t) * (-2.0 / z) elif (y <= 1.82) or not (y <= 7e+90): tmp = t_1 else: tmp = -2.0 * ((x / z) / t) return tmp
function code(x, y, z, t) t_1 = Float64(Float64(x / z) * Float64(2.0 / y)) tmp = 0.0 if (y <= -0.88) tmp = t_1; elseif (y <= 3e-78) tmp = Float64(Float64(x / t) * Float64(-2.0 / z)); elseif ((y <= 1.82) || !(y <= 7e+90)) tmp = t_1; else tmp = Float64(-2.0 * Float64(Float64(x / z) / t)); end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = (x / z) * (2.0 / y); tmp = 0.0; if (y <= -0.88) tmp = t_1; elseif (y <= 3e-78) tmp = (x / t) * (-2.0 / z); elseif ((y <= 1.82) || ~((y <= 7e+90))) tmp = t_1; else tmp = -2.0 * ((x / z) / t); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x / z), $MachinePrecision] * N[(2.0 / y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -0.88], t$95$1, If[LessEqual[y, 3e-78], N[(N[(x / t), $MachinePrecision] * N[(-2.0 / z), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[y, 1.82], N[Not[LessEqual[y, 7e+90]], $MachinePrecision]], t$95$1, N[(-2.0 * N[(N[(x / z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x}{z} \cdot \frac{2}{y}\\
\mathbf{if}\;y \leq -0.88:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq 3 \cdot 10^{-78}:\\
\;\;\;\;\frac{x}{t} \cdot \frac{-2}{z}\\
\mathbf{elif}\;y \leq 1.82 \lor \neg \left(y \leq 7 \cdot 10^{+90}\right):\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;-2 \cdot \frac{\frac{x}{z}}{t}\\
\end{array}
\end{array}
if y < -0.880000000000000004 or 2.99999999999999988e-78 < y < 1.82000000000000006 or 6.9999999999999997e90 < y Initial program 82.0%
*-commutative82.0%
distribute-rgt-out--83.8%
times-frac93.2%
Simplified93.2%
Taylor expanded in y around inf 76.0%
associate-*r/76.0%
*-commutative76.0%
times-frac83.7%
Simplified83.7%
clear-num83.1%
frac-times82.7%
metadata-eval82.7%
Applied egg-rr82.7%
associate-/l/83.2%
div-inv83.2%
div-inv83.1%
times-frac79.2%
associate-/r*79.2%
div-inv79.3%
clear-num79.3%
Applied egg-rr79.3%
if -0.880000000000000004 < y < 2.99999999999999988e-78Initial program 89.8%
*-commutative89.8%
distribute-rgt-out--89.9%
times-frac93.7%
Simplified93.7%
Taylor expanded in y around 0 69.8%
associate-*r/69.8%
*-commutative69.8%
*-commutative69.8%
Simplified69.8%
*-commutative69.8%
times-frac73.2%
Applied egg-rr73.2%
if 1.82000000000000006 < y < 6.9999999999999997e90Initial program 73.3%
*-commutative73.3%
distribute-rgt-out--82.7%
times-frac93.2%
Simplified93.2%
frac-times82.7%
*-commutative82.7%
times-frac95.7%
clear-num95.6%
associate-*l/95.8%
*-un-lft-identity95.8%
Applied egg-rr95.8%
Taylor expanded in y around 0 49.6%
*-commutative49.6%
associate-/r*66.6%
Simplified66.6%
Final simplification75.5%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* (/ 2.0 z) (/ x y))))
(if (<= y -2.1)
t_1
(if (<= y -4.7e-120)
(* -2.0 (/ (/ x z) t))
(if (or (<= y -5e-154) (not (<= y 6.5e-78)))
t_1
(* (/ x t) (/ -2.0 z)))))))
double code(double x, double y, double z, double t) {
double t_1 = (2.0 / z) * (x / y);
double tmp;
if (y <= -2.1) {
tmp = t_1;
} else if (y <= -4.7e-120) {
tmp = -2.0 * ((x / z) / t);
} else if ((y <= -5e-154) || !(y <= 6.5e-78)) {
tmp = t_1;
} else {
tmp = (x / t) * (-2.0 / 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) :: t_1
real(8) :: tmp
t_1 = (2.0d0 / z) * (x / y)
if (y <= (-2.1d0)) then
tmp = t_1
else if (y <= (-4.7d-120)) then
tmp = (-2.0d0) * ((x / z) / t)
else if ((y <= (-5d-154)) .or. (.not. (y <= 6.5d-78))) then
tmp = t_1
else
tmp = (x / t) * ((-2.0d0) / z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = (2.0 / z) * (x / y);
double tmp;
if (y <= -2.1) {
tmp = t_1;
} else if (y <= -4.7e-120) {
tmp = -2.0 * ((x / z) / t);
} else if ((y <= -5e-154) || !(y <= 6.5e-78)) {
tmp = t_1;
} else {
tmp = (x / t) * (-2.0 / z);
}
return tmp;
}
def code(x, y, z, t): t_1 = (2.0 / z) * (x / y) tmp = 0 if y <= -2.1: tmp = t_1 elif y <= -4.7e-120: tmp = -2.0 * ((x / z) / t) elif (y <= -5e-154) or not (y <= 6.5e-78): tmp = t_1 else: tmp = (x / t) * (-2.0 / z) return tmp
function code(x, y, z, t) t_1 = Float64(Float64(2.0 / z) * Float64(x / y)) tmp = 0.0 if (y <= -2.1) tmp = t_1; elseif (y <= -4.7e-120) tmp = Float64(-2.0 * Float64(Float64(x / z) / t)); elseif ((y <= -5e-154) || !(y <= 6.5e-78)) tmp = t_1; else tmp = Float64(Float64(x / t) * Float64(-2.0 / z)); end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = (2.0 / z) * (x / y); tmp = 0.0; if (y <= -2.1) tmp = t_1; elseif (y <= -4.7e-120) tmp = -2.0 * ((x / z) / t); elseif ((y <= -5e-154) || ~((y <= 6.5e-78))) tmp = t_1; else tmp = (x / t) * (-2.0 / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(2.0 / z), $MachinePrecision] * N[(x / y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -2.1], t$95$1, If[LessEqual[y, -4.7e-120], N[(-2.0 * N[(N[(x / z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[y, -5e-154], N[Not[LessEqual[y, 6.5e-78]], $MachinePrecision]], t$95$1, N[(N[(x / t), $MachinePrecision] * N[(-2.0 / z), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{2}{z} \cdot \frac{x}{y}\\
\mathbf{if}\;y \leq -2.1:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq -4.7 \cdot 10^{-120}:\\
\;\;\;\;-2 \cdot \frac{\frac{x}{z}}{t}\\
\mathbf{elif}\;y \leq -5 \cdot 10^{-154} \lor \neg \left(y \leq 6.5 \cdot 10^{-78}\right):\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{t} \cdot \frac{-2}{z}\\
\end{array}
\end{array}
if y < -2.10000000000000009 or -4.70000000000000016e-120 < y < -5.0000000000000002e-154 or 6.5000000000000003e-78 < y Initial program 81.9%
*-commutative81.9%
distribute-rgt-out--84.7%
times-frac93.6%
Simplified93.6%
Taylor expanded in y around inf 72.4%
associate-*r/72.4%
*-commutative72.4%
times-frac78.4%
Simplified78.4%
if -2.10000000000000009 < y < -4.70000000000000016e-120Initial program 85.5%
*-commutative85.5%
distribute-rgt-out--85.5%
times-frac96.4%
Simplified96.4%
frac-times85.5%
*-commutative85.5%
times-frac92.2%
clear-num92.1%
associate-*l/93.4%
*-un-lft-identity93.4%
Applied egg-rr93.4%
Taylor expanded in y around 0 56.0%
*-commutative56.0%
associate-/r*70.3%
Simplified70.3%
if -5.0000000000000002e-154 < y < 6.5000000000000003e-78Initial program 90.0%
*-commutative90.0%
distribute-rgt-out--90.1%
times-frac92.1%
Simplified92.1%
Taylor expanded in y around 0 80.5%
associate-*r/80.5%
*-commutative80.5%
*-commutative80.5%
Simplified80.5%
*-commutative80.5%
times-frac80.7%
Applied egg-rr80.7%
Final simplification78.3%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* (/ 2.0 z) (/ x y))))
(if (<= y -0.62)
t_1
(if (<= y -4.7e-120)
(* -2.0 (/ (/ x z) t))
(if (<= y -5e-154)
(/ 2.0 (* z (/ y x)))
(if (<= y 4.5e-78) (* (/ x t) (/ -2.0 z)) t_1))))))
double code(double x, double y, double z, double t) {
double t_1 = (2.0 / z) * (x / y);
double tmp;
if (y <= -0.62) {
tmp = t_1;
} else if (y <= -4.7e-120) {
tmp = -2.0 * ((x / z) / t);
} else if (y <= -5e-154) {
tmp = 2.0 / (z * (y / x));
} else if (y <= 4.5e-78) {
tmp = (x / t) * (-2.0 / z);
} 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 = (2.0d0 / z) * (x / y)
if (y <= (-0.62d0)) then
tmp = t_1
else if (y <= (-4.7d-120)) then
tmp = (-2.0d0) * ((x / z) / t)
else if (y <= (-5d-154)) then
tmp = 2.0d0 / (z * (y / x))
else if (y <= 4.5d-78) then
tmp = (x / t) * ((-2.0d0) / z)
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 = (2.0 / z) * (x / y);
double tmp;
if (y <= -0.62) {
tmp = t_1;
} else if (y <= -4.7e-120) {
tmp = -2.0 * ((x / z) / t);
} else if (y <= -5e-154) {
tmp = 2.0 / (z * (y / x));
} else if (y <= 4.5e-78) {
tmp = (x / t) * (-2.0 / z);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t): t_1 = (2.0 / z) * (x / y) tmp = 0 if y <= -0.62: tmp = t_1 elif y <= -4.7e-120: tmp = -2.0 * ((x / z) / t) elif y <= -5e-154: tmp = 2.0 / (z * (y / x)) elif y <= 4.5e-78: tmp = (x / t) * (-2.0 / z) else: tmp = t_1 return tmp
function code(x, y, z, t) t_1 = Float64(Float64(2.0 / z) * Float64(x / y)) tmp = 0.0 if (y <= -0.62) tmp = t_1; elseif (y <= -4.7e-120) tmp = Float64(-2.0 * Float64(Float64(x / z) / t)); elseif (y <= -5e-154) tmp = Float64(2.0 / Float64(z * Float64(y / x))); elseif (y <= 4.5e-78) tmp = Float64(Float64(x / t) * Float64(-2.0 / z)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = (2.0 / z) * (x / y); tmp = 0.0; if (y <= -0.62) tmp = t_1; elseif (y <= -4.7e-120) tmp = -2.0 * ((x / z) / t); elseif (y <= -5e-154) tmp = 2.0 / (z * (y / x)); elseif (y <= 4.5e-78) tmp = (x / t) * (-2.0 / z); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(2.0 / z), $MachinePrecision] * N[(x / y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -0.62], t$95$1, If[LessEqual[y, -4.7e-120], N[(-2.0 * N[(N[(x / z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -5e-154], N[(2.0 / N[(z * N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 4.5e-78], N[(N[(x / t), $MachinePrecision] * N[(-2.0 / z), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{2}{z} \cdot \frac{x}{y}\\
\mathbf{if}\;y \leq -0.62:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq -4.7 \cdot 10^{-120}:\\
\;\;\;\;-2 \cdot \frac{\frac{x}{z}}{t}\\
\mathbf{elif}\;y \leq -5 \cdot 10^{-154}:\\
\;\;\;\;\frac{2}{z \cdot \frac{y}{x}}\\
\mathbf{elif}\;y \leq 4.5 \cdot 10^{-78}:\\
\;\;\;\;\frac{x}{t} \cdot \frac{-2}{z}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if y < -0.619999999999999996 or 4.5e-78 < y Initial program 80.7%
*-commutative80.7%
distribute-rgt-out--83.6%
times-frac93.2%
Simplified93.2%
Taylor expanded in y around inf 72.7%
associate-*r/72.7%
*-commutative72.7%
times-frac79.2%
Simplified79.2%
if -0.619999999999999996 < y < -4.70000000000000016e-120Initial program 85.5%
*-commutative85.5%
distribute-rgt-out--85.5%
times-frac96.4%
Simplified96.4%
frac-times85.5%
*-commutative85.5%
times-frac92.2%
clear-num92.1%
associate-*l/93.4%
*-un-lft-identity93.4%
Applied egg-rr93.4%
Taylor expanded in y around 0 56.0%
*-commutative56.0%
associate-/r*70.3%
Simplified70.3%
if -4.70000000000000016e-120 < y < -5.0000000000000002e-154Initial program 99.8%
*-commutative99.8%
distribute-rgt-out--99.8%
times-frac99.0%
Simplified99.0%
Taylor expanded in y around inf 67.2%
associate-*r/67.2%
*-commutative67.2%
times-frac66.6%
Simplified66.6%
clear-num66.8%
frac-times66.9%
metadata-eval66.9%
Applied egg-rr66.9%
if -5.0000000000000002e-154 < y < 4.5e-78Initial program 90.0%
*-commutative90.0%
distribute-rgt-out--90.1%
times-frac92.1%
Simplified92.1%
Taylor expanded in y around 0 80.5%
associate-*r/80.5%
*-commutative80.5%
*-commutative80.5%
Simplified80.5%
*-commutative80.5%
times-frac80.7%
Applied egg-rr80.7%
Final simplification78.3%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* (/ 2.0 z) (/ x y))))
(if (<= y -1.15)
t_1
(if (<= y -4.9e-120)
(* -2.0 (/ (/ x z) t))
(if (<= y -5e-154)
(/ (* 2.0 x) (* y z))
(if (<= y 7.2e-78) (* (/ x t) (/ -2.0 z)) t_1))))))
double code(double x, double y, double z, double t) {
double t_1 = (2.0 / z) * (x / y);
double tmp;
if (y <= -1.15) {
tmp = t_1;
} else if (y <= -4.9e-120) {
tmp = -2.0 * ((x / z) / t);
} else if (y <= -5e-154) {
tmp = (2.0 * x) / (y * z);
} else if (y <= 7.2e-78) {
tmp = (x / t) * (-2.0 / z);
} 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 = (2.0d0 / z) * (x / y)
if (y <= (-1.15d0)) then
tmp = t_1
else if (y <= (-4.9d-120)) then
tmp = (-2.0d0) * ((x / z) / t)
else if (y <= (-5d-154)) then
tmp = (2.0d0 * x) / (y * z)
else if (y <= 7.2d-78) then
tmp = (x / t) * ((-2.0d0) / z)
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 = (2.0 / z) * (x / y);
double tmp;
if (y <= -1.15) {
tmp = t_1;
} else if (y <= -4.9e-120) {
tmp = -2.0 * ((x / z) / t);
} else if (y <= -5e-154) {
tmp = (2.0 * x) / (y * z);
} else if (y <= 7.2e-78) {
tmp = (x / t) * (-2.0 / z);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t): t_1 = (2.0 / z) * (x / y) tmp = 0 if y <= -1.15: tmp = t_1 elif y <= -4.9e-120: tmp = -2.0 * ((x / z) / t) elif y <= -5e-154: tmp = (2.0 * x) / (y * z) elif y <= 7.2e-78: tmp = (x / t) * (-2.0 / z) else: tmp = t_1 return tmp
function code(x, y, z, t) t_1 = Float64(Float64(2.0 / z) * Float64(x / y)) tmp = 0.0 if (y <= -1.15) tmp = t_1; elseif (y <= -4.9e-120) tmp = Float64(-2.0 * Float64(Float64(x / z) / t)); elseif (y <= -5e-154) tmp = Float64(Float64(2.0 * x) / Float64(y * z)); elseif (y <= 7.2e-78) tmp = Float64(Float64(x / t) * Float64(-2.0 / z)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = (2.0 / z) * (x / y); tmp = 0.0; if (y <= -1.15) tmp = t_1; elseif (y <= -4.9e-120) tmp = -2.0 * ((x / z) / t); elseif (y <= -5e-154) tmp = (2.0 * x) / (y * z); elseif (y <= 7.2e-78) tmp = (x / t) * (-2.0 / z); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(2.0 / z), $MachinePrecision] * N[(x / y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.15], t$95$1, If[LessEqual[y, -4.9e-120], N[(-2.0 * N[(N[(x / z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -5e-154], N[(N[(2.0 * x), $MachinePrecision] / N[(y * z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 7.2e-78], N[(N[(x / t), $MachinePrecision] * N[(-2.0 / z), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{2}{z} \cdot \frac{x}{y}\\
\mathbf{if}\;y \leq -1.15:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq -4.9 \cdot 10^{-120}:\\
\;\;\;\;-2 \cdot \frac{\frac{x}{z}}{t}\\
\mathbf{elif}\;y \leq -5 \cdot 10^{-154}:\\
\;\;\;\;\frac{2 \cdot x}{y \cdot z}\\
\mathbf{elif}\;y \leq 7.2 \cdot 10^{-78}:\\
\;\;\;\;\frac{x}{t} \cdot \frac{-2}{z}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if y < -1.1499999999999999 or 7.2000000000000005e-78 < y Initial program 80.7%
*-commutative80.7%
distribute-rgt-out--83.6%
times-frac93.2%
Simplified93.2%
Taylor expanded in y around inf 72.7%
associate-*r/72.7%
*-commutative72.7%
times-frac79.2%
Simplified79.2%
if -1.1499999999999999 < y < -4.9000000000000003e-120Initial program 85.5%
*-commutative85.5%
distribute-rgt-out--85.5%
times-frac96.4%
Simplified96.4%
frac-times85.5%
*-commutative85.5%
times-frac92.2%
clear-num92.1%
associate-*l/93.4%
*-un-lft-identity93.4%
Applied egg-rr93.4%
Taylor expanded in y around 0 56.0%
*-commutative56.0%
associate-/r*70.3%
Simplified70.3%
if -4.9000000000000003e-120 < y < -5.0000000000000002e-154Initial program 99.8%
distribute-rgt-out--99.8%
Simplified99.8%
Taylor expanded in y around inf 67.2%
*-commutative67.2%
Simplified67.2%
if -5.0000000000000002e-154 < y < 7.2000000000000005e-78Initial program 90.0%
*-commutative90.0%
distribute-rgt-out--90.1%
times-frac92.1%
Simplified92.1%
Taylor expanded in y around 0 80.5%
associate-*r/80.5%
*-commutative80.5%
*-commutative80.5%
Simplified80.5%
*-commutative80.5%
times-frac80.7%
Applied egg-rr80.7%
Final simplification78.3%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* (/ 2.0 z) (/ x y))))
(if (<= y -3.6)
t_1
(if (<= y -4.7e-120)
(/ (/ -2.0 t) (/ z x))
(if (<= y -5e-154)
(/ (* 2.0 x) (* y z))
(if (<= y 7.2e-78) (* (/ x t) (/ -2.0 z)) t_1))))))
double code(double x, double y, double z, double t) {
double t_1 = (2.0 / z) * (x / y);
double tmp;
if (y <= -3.6) {
tmp = t_1;
} else if (y <= -4.7e-120) {
tmp = (-2.0 / t) / (z / x);
} else if (y <= -5e-154) {
tmp = (2.0 * x) / (y * z);
} else if (y <= 7.2e-78) {
tmp = (x / t) * (-2.0 / z);
} 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 = (2.0d0 / z) * (x / y)
if (y <= (-3.6d0)) then
tmp = t_1
else if (y <= (-4.7d-120)) then
tmp = ((-2.0d0) / t) / (z / x)
else if (y <= (-5d-154)) then
tmp = (2.0d0 * x) / (y * z)
else if (y <= 7.2d-78) then
tmp = (x / t) * ((-2.0d0) / z)
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 = (2.0 / z) * (x / y);
double tmp;
if (y <= -3.6) {
tmp = t_1;
} else if (y <= -4.7e-120) {
tmp = (-2.0 / t) / (z / x);
} else if (y <= -5e-154) {
tmp = (2.0 * x) / (y * z);
} else if (y <= 7.2e-78) {
tmp = (x / t) * (-2.0 / z);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t): t_1 = (2.0 / z) * (x / y) tmp = 0 if y <= -3.6: tmp = t_1 elif y <= -4.7e-120: tmp = (-2.0 / t) / (z / x) elif y <= -5e-154: tmp = (2.0 * x) / (y * z) elif y <= 7.2e-78: tmp = (x / t) * (-2.0 / z) else: tmp = t_1 return tmp
function code(x, y, z, t) t_1 = Float64(Float64(2.0 / z) * Float64(x / y)) tmp = 0.0 if (y <= -3.6) tmp = t_1; elseif (y <= -4.7e-120) tmp = Float64(Float64(-2.0 / t) / Float64(z / x)); elseif (y <= -5e-154) tmp = Float64(Float64(2.0 * x) / Float64(y * z)); elseif (y <= 7.2e-78) tmp = Float64(Float64(x / t) * Float64(-2.0 / z)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = (2.0 / z) * (x / y); tmp = 0.0; if (y <= -3.6) tmp = t_1; elseif (y <= -4.7e-120) tmp = (-2.0 / t) / (z / x); elseif (y <= -5e-154) tmp = (2.0 * x) / (y * z); elseif (y <= 7.2e-78) tmp = (x / t) * (-2.0 / z); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(2.0 / z), $MachinePrecision] * N[(x / y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -3.6], t$95$1, If[LessEqual[y, -4.7e-120], N[(N[(-2.0 / t), $MachinePrecision] / N[(z / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -5e-154], N[(N[(2.0 * x), $MachinePrecision] / N[(y * z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 7.2e-78], N[(N[(x / t), $MachinePrecision] * N[(-2.0 / z), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{2}{z} \cdot \frac{x}{y}\\
\mathbf{if}\;y \leq -3.6:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq -4.7 \cdot 10^{-120}:\\
\;\;\;\;\frac{\frac{-2}{t}}{\frac{z}{x}}\\
\mathbf{elif}\;y \leq -5 \cdot 10^{-154}:\\
\;\;\;\;\frac{2 \cdot x}{y \cdot z}\\
\mathbf{elif}\;y \leq 7.2 \cdot 10^{-78}:\\
\;\;\;\;\frac{x}{t} \cdot \frac{-2}{z}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if y < -3.60000000000000009 or 7.2000000000000005e-78 < y Initial program 80.7%
*-commutative80.7%
distribute-rgt-out--83.6%
times-frac93.2%
Simplified93.2%
Taylor expanded in y around inf 72.7%
associate-*r/72.7%
*-commutative72.7%
times-frac79.2%
Simplified79.2%
if -3.60000000000000009 < y < -4.70000000000000016e-120Initial program 85.5%
*-commutative85.5%
distribute-rgt-out--85.5%
times-frac96.4%
Simplified96.4%
frac-times85.5%
*-commutative85.5%
times-frac92.2%
clear-num92.1%
associate-*l/93.4%
*-un-lft-identity93.4%
Applied egg-rr93.4%
Taylor expanded in y around 0 71.3%
if -4.70000000000000016e-120 < y < -5.0000000000000002e-154Initial program 99.8%
distribute-rgt-out--99.8%
Simplified99.8%
Taylor expanded in y around inf 67.2%
*-commutative67.2%
Simplified67.2%
if -5.0000000000000002e-154 < y < 7.2000000000000005e-78Initial program 90.0%
*-commutative90.0%
distribute-rgt-out--90.1%
times-frac92.1%
Simplified92.1%
Taylor expanded in y around 0 80.5%
associate-*r/80.5%
*-commutative80.5%
*-commutative80.5%
Simplified80.5%
*-commutative80.5%
times-frac80.7%
Applied egg-rr80.7%
Final simplification78.4%
(FPCore (x y z t)
:precision binary64
(if (<= z -1.75e+59)
(* (/ x (- y t)) (/ 2.0 z))
(if (<= z 6.1e-47)
(* x (/ 2.0 (* z (- y t))))
(* 2.0 (/ (/ x z) (- y t))))))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -1.75e+59) {
tmp = (x / (y - t)) * (2.0 / z);
} else if (z <= 6.1e-47) {
tmp = x * (2.0 / (z * (y - t)));
} else {
tmp = 2.0 * ((x / z) / (y - 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 <= (-1.75d+59)) then
tmp = (x / (y - t)) * (2.0d0 / z)
else if (z <= 6.1d-47) then
tmp = x * (2.0d0 / (z * (y - t)))
else
tmp = 2.0d0 * ((x / z) / (y - t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -1.75e+59) {
tmp = (x / (y - t)) * (2.0 / z);
} else if (z <= 6.1e-47) {
tmp = x * (2.0 / (z * (y - t)));
} else {
tmp = 2.0 * ((x / z) / (y - t));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -1.75e+59: tmp = (x / (y - t)) * (2.0 / z) elif z <= 6.1e-47: tmp = x * (2.0 / (z * (y - t))) else: tmp = 2.0 * ((x / z) / (y - t)) return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -1.75e+59) tmp = Float64(Float64(x / Float64(y - t)) * Float64(2.0 / z)); elseif (z <= 6.1e-47) tmp = Float64(x * Float64(2.0 / Float64(z * Float64(y - t)))); else tmp = Float64(2.0 * Float64(Float64(x / z) / Float64(y - t))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -1.75e+59) tmp = (x / (y - t)) * (2.0 / z); elseif (z <= 6.1e-47) tmp = x * (2.0 / (z * (y - t))); else tmp = 2.0 * ((x / z) / (y - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -1.75e+59], N[(N[(x / N[(y - t), $MachinePrecision]), $MachinePrecision] * N[(2.0 / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 6.1e-47], N[(x * N[(2.0 / N[(z * N[(y - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 * N[(N[(x / z), $MachinePrecision] / N[(y - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.75 \cdot 10^{+59}:\\
\;\;\;\;\frac{x}{y - t} \cdot \frac{2}{z}\\
\mathbf{elif}\;z \leq 6.1 \cdot 10^{-47}:\\
\;\;\;\;x \cdot \frac{2}{z \cdot \left(y - t\right)}\\
\mathbf{else}:\\
\;\;\;\;2 \cdot \frac{\frac{x}{z}}{y - t}\\
\end{array}
\end{array}
if z < -1.75e59Initial program 72.9%
*-commutative72.9%
distribute-rgt-out--78.5%
times-frac96.0%
Simplified96.0%
if -1.75e59 < z < 6.1e-47Initial program 96.6%
*-commutative96.6%
distribute-rgt-out--96.7%
times-frac90.3%
Simplified90.3%
associate-*l/90.5%
associate-/l*89.6%
Applied egg-rr89.6%
associate-/l*95.8%
associate-/r/96.6%
Applied egg-rr96.6%
if 6.1e-47 < z Initial program 75.1%
*-commutative75.1%
associate-*r/75.1%
distribute-rgt-out--76.5%
associate-/r*98.6%
Simplified98.6%
Final simplification97.1%
(FPCore (x y z t)
:precision binary64
(if (<= z -7e+65)
(/ 2.0 (* z (/ (- y t) x)))
(if (<= z 2.5e-53)
(* x (/ 2.0 (* z (- y t))))
(* 2.0 (/ (/ x z) (- y t))))))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -7e+65) {
tmp = 2.0 / (z * ((y - t) / x));
} else if (z <= 2.5e-53) {
tmp = x * (2.0 / (z * (y - t)));
} else {
tmp = 2.0 * ((x / z) / (y - 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 <= (-7d+65)) then
tmp = 2.0d0 / (z * ((y - t) / x))
else if (z <= 2.5d-53) then
tmp = x * (2.0d0 / (z * (y - t)))
else
tmp = 2.0d0 * ((x / z) / (y - t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -7e+65) {
tmp = 2.0 / (z * ((y - t) / x));
} else if (z <= 2.5e-53) {
tmp = x * (2.0 / (z * (y - t)));
} else {
tmp = 2.0 * ((x / z) / (y - t));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -7e+65: tmp = 2.0 / (z * ((y - t) / x)) elif z <= 2.5e-53: tmp = x * (2.0 / (z * (y - t))) else: tmp = 2.0 * ((x / z) / (y - t)) return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -7e+65) tmp = Float64(2.0 / Float64(z * Float64(Float64(y - t) / x))); elseif (z <= 2.5e-53) tmp = Float64(x * Float64(2.0 / Float64(z * Float64(y - t)))); else tmp = Float64(2.0 * Float64(Float64(x / z) / Float64(y - t))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -7e+65) tmp = 2.0 / (z * ((y - t) / x)); elseif (z <= 2.5e-53) tmp = x * (2.0 / (z * (y - t))); else tmp = 2.0 * ((x / z) / (y - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -7e+65], N[(2.0 / N[(z * N[(N[(y - t), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.5e-53], N[(x * N[(2.0 / N[(z * N[(y - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 * N[(N[(x / z), $MachinePrecision] / N[(y - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -7 \cdot 10^{+65}:\\
\;\;\;\;\frac{2}{z \cdot \frac{y - t}{x}}\\
\mathbf{elif}\;z \leq 2.5 \cdot 10^{-53}:\\
\;\;\;\;x \cdot \frac{2}{z \cdot \left(y - t\right)}\\
\mathbf{else}:\\
\;\;\;\;2 \cdot \frac{\frac{x}{z}}{y - t}\\
\end{array}
\end{array}
if z < -7.0000000000000002e65Initial program 72.9%
*-commutative72.9%
distribute-rgt-out--78.5%
times-frac96.0%
Simplified96.0%
clear-num96.0%
frac-times96.1%
metadata-eval96.1%
Applied egg-rr96.1%
if -7.0000000000000002e65 < z < 2.5e-53Initial program 96.6%
*-commutative96.6%
distribute-rgt-out--96.7%
times-frac90.3%
Simplified90.3%
associate-*l/90.5%
associate-/l*89.6%
Applied egg-rr89.6%
associate-/l*95.8%
associate-/r/96.6%
Applied egg-rr96.6%
if 2.5e-53 < z Initial program 75.1%
*-commutative75.1%
associate-*r/75.1%
distribute-rgt-out--76.5%
associate-/r*98.6%
Simplified98.6%
Final simplification97.2%
(FPCore (x y z t) :precision binary64 (if (<= z -1e+66) (/ 2.0 (/ z (/ x (- y t)))) (if (<= z 9e-48) (* x (/ 2.0 (* z (- y t)))) (* 2.0 (/ (/ x z) (- y t))))))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -1e+66) {
tmp = 2.0 / (z / (x / (y - t)));
} else if (z <= 9e-48) {
tmp = x * (2.0 / (z * (y - t)));
} else {
tmp = 2.0 * ((x / z) / (y - 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 <= (-1d+66)) then
tmp = 2.0d0 / (z / (x / (y - t)))
else if (z <= 9d-48) then
tmp = x * (2.0d0 / (z * (y - t)))
else
tmp = 2.0d0 * ((x / z) / (y - t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -1e+66) {
tmp = 2.0 / (z / (x / (y - t)));
} else if (z <= 9e-48) {
tmp = x * (2.0 / (z * (y - t)));
} else {
tmp = 2.0 * ((x / z) / (y - t));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -1e+66: tmp = 2.0 / (z / (x / (y - t))) elif z <= 9e-48: tmp = x * (2.0 / (z * (y - t))) else: tmp = 2.0 * ((x / z) / (y - t)) return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -1e+66) tmp = Float64(2.0 / Float64(z / Float64(x / Float64(y - t)))); elseif (z <= 9e-48) tmp = Float64(x * Float64(2.0 / Float64(z * Float64(y - t)))); else tmp = Float64(2.0 * Float64(Float64(x / z) / Float64(y - t))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -1e+66) tmp = 2.0 / (z / (x / (y - t))); elseif (z <= 9e-48) tmp = x * (2.0 / (z * (y - t))); else tmp = 2.0 * ((x / z) / (y - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -1e+66], N[(2.0 / N[(z / N[(x / N[(y - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 9e-48], N[(x * N[(2.0 / N[(z * N[(y - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 * N[(N[(x / z), $MachinePrecision] / N[(y - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1 \cdot 10^{+66}:\\
\;\;\;\;\frac{2}{\frac{z}{\frac{x}{y - t}}}\\
\mathbf{elif}\;z \leq 9 \cdot 10^{-48}:\\
\;\;\;\;x \cdot \frac{2}{z \cdot \left(y - t\right)}\\
\mathbf{else}:\\
\;\;\;\;2 \cdot \frac{\frac{x}{z}}{y - t}\\
\end{array}
\end{array}
if z < -9.99999999999999945e65Initial program 72.9%
*-commutative72.9%
distribute-rgt-out--78.5%
times-frac96.0%
Simplified96.0%
associate-*l/96.2%
associate-/l*96.1%
Applied egg-rr96.1%
if -9.99999999999999945e65 < z < 8.99999999999999977e-48Initial program 96.6%
*-commutative96.6%
distribute-rgt-out--96.7%
times-frac90.3%
Simplified90.3%
associate-*l/90.5%
associate-/l*89.6%
Applied egg-rr89.6%
associate-/l*95.8%
associate-/r/96.6%
Applied egg-rr96.6%
if 8.99999999999999977e-48 < z Initial program 75.1%
*-commutative75.1%
associate-*r/75.1%
distribute-rgt-out--76.5%
associate-/r*98.6%
Simplified98.6%
Final simplification97.2%
(FPCore (x y z t) :precision binary64 (if (or (<= z -1.56e+116) (not (<= z 1e+84))) (* -2.0 (/ (/ x z) t)) (* x (/ -2.0 (* z t)))))
double code(double x, double y, double z, double t) {
double tmp;
if ((z <= -1.56e+116) || !(z <= 1e+84)) {
tmp = -2.0 * ((x / z) / t);
} else {
tmp = x * (-2.0 / (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 <= (-1.56d+116)) .or. (.not. (z <= 1d+84))) then
tmp = (-2.0d0) * ((x / z) / t)
else
tmp = x * ((-2.0d0) / (z * t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if ((z <= -1.56e+116) || !(z <= 1e+84)) {
tmp = -2.0 * ((x / z) / t);
} else {
tmp = x * (-2.0 / (z * t));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (z <= -1.56e+116) or not (z <= 1e+84): tmp = -2.0 * ((x / z) / t) else: tmp = x * (-2.0 / (z * t)) return tmp
function code(x, y, z, t) tmp = 0.0 if ((z <= -1.56e+116) || !(z <= 1e+84)) tmp = Float64(-2.0 * Float64(Float64(x / z) / t)); else tmp = Float64(x * Float64(-2.0 / Float64(z * t))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((z <= -1.56e+116) || ~((z <= 1e+84))) tmp = -2.0 * ((x / z) / t); else tmp = x * (-2.0 / (z * t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[z, -1.56e+116], N[Not[LessEqual[z, 1e+84]], $MachinePrecision]], N[(-2.0 * N[(N[(x / z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], N[(x * N[(-2.0 / N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.56 \cdot 10^{+116} \lor \neg \left(z \leq 10^{+84}\right):\\
\;\;\;\;-2 \cdot \frac{\frac{x}{z}}{t}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{-2}{z \cdot t}\\
\end{array}
\end{array}
if z < -1.56000000000000002e116 or 1.00000000000000006e84 < z Initial program 69.8%
*-commutative69.8%
distribute-rgt-out--73.8%
times-frac95.9%
Simplified95.9%
frac-times73.8%
*-commutative73.8%
times-frac95.7%
clear-num94.2%
associate-*l/94.3%
*-un-lft-identity94.3%
Applied egg-rr94.3%
Taylor expanded in y around 0 49.0%
*-commutative49.0%
associate-/r*66.1%
Simplified66.1%
if -1.56000000000000002e116 < z < 1.00000000000000006e84Initial program 94.8%
*-commutative94.8%
distribute-rgt-out--94.9%
times-frac91.7%
Simplified91.7%
associate-*l/91.9%
associate-/l*91.2%
Applied egg-rr91.2%
associate-/l*94.2%
associate-/r/94.8%
Applied egg-rr94.8%
Taylor expanded in y around 0 46.6%
*-commutative46.6%
Simplified46.6%
Final simplification54.4%
(FPCore (x y z t) :precision binary64 (* 2.0 (/ (/ x z) (- y t))))
double code(double x, double y, double z, double t) {
return 2.0 * ((x / z) / (y - t));
}
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 = 2.0d0 * ((x / z) / (y - t))
end function
public static double code(double x, double y, double z, double t) {
return 2.0 * ((x / z) / (y - t));
}
def code(x, y, z, t): return 2.0 * ((x / z) / (y - t))
function code(x, y, z, t) return Float64(2.0 * Float64(Float64(x / z) / Float64(y - t))) end
function tmp = code(x, y, z, t) tmp = 2.0 * ((x / z) / (y - t)); end
code[x_, y_, z_, t_] := N[(2.0 * N[(N[(x / z), $MachinePrecision] / N[(y - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
2 \cdot \frac{\frac{x}{z}}{y - t}
\end{array}
Initial program 84.7%
*-commutative84.7%
associate-*r/84.7%
distribute-rgt-out--86.4%
associate-/r*90.1%
Simplified90.1%
Final simplification90.1%
(FPCore (x y z t) :precision binary64 (* -2.0 (/ (/ x z) t)))
double code(double x, double y, double z, double t) {
return -2.0 * ((x / z) / t);
}
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 = (-2.0d0) * ((x / z) / t)
end function
public static double code(double x, double y, double z, double t) {
return -2.0 * ((x / z) / t);
}
def code(x, y, z, t): return -2.0 * ((x / z) / t)
function code(x, y, z, t) return Float64(-2.0 * Float64(Float64(x / z) / t)) end
function tmp = code(x, y, z, t) tmp = -2.0 * ((x / z) / t); end
code[x_, y_, z_, t_] := N[(-2.0 * N[(N[(x / z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
-2 \cdot \frac{\frac{x}{z}}{t}
\end{array}
Initial program 84.7%
*-commutative84.7%
distribute-rgt-out--86.4%
times-frac93.4%
Simplified93.4%
frac-times86.4%
*-commutative86.4%
times-frac90.0%
clear-num89.3%
associate-*l/90.2%
*-un-lft-identity90.2%
Applied egg-rr90.2%
Taylor expanded in y around 0 47.6%
*-commutative47.6%
associate-/r*51.1%
Simplified51.1%
Final simplification51.1%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* (/ x (* (- y t) z)) 2.0))
(t_2 (/ (* x 2.0) (- (* y z) (* t z)))))
(if (< t_2 -2.559141628295061e-13)
t_1
(if (< t_2 1.045027827330126e-269) (/ (* (/ x z) 2.0) (- y t)) t_1))))
double code(double x, double y, double z, double t) {
double t_1 = (x / ((y - t) * z)) * 2.0;
double t_2 = (x * 2.0) / ((y * z) - (t * z));
double tmp;
if (t_2 < -2.559141628295061e-13) {
tmp = t_1;
} else if (t_2 < 1.045027827330126e-269) {
tmp = ((x / z) * 2.0) / (y - 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) :: t_2
real(8) :: tmp
t_1 = (x / ((y - t) * z)) * 2.0d0
t_2 = (x * 2.0d0) / ((y * z) - (t * z))
if (t_2 < (-2.559141628295061d-13)) then
tmp = t_1
else if (t_2 < 1.045027827330126d-269) then
tmp = ((x / z) * 2.0d0) / (y - 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 / ((y - t) * z)) * 2.0;
double t_2 = (x * 2.0) / ((y * z) - (t * z));
double tmp;
if (t_2 < -2.559141628295061e-13) {
tmp = t_1;
} else if (t_2 < 1.045027827330126e-269) {
tmp = ((x / z) * 2.0) / (y - t);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t): t_1 = (x / ((y - t) * z)) * 2.0 t_2 = (x * 2.0) / ((y * z) - (t * z)) tmp = 0 if t_2 < -2.559141628295061e-13: tmp = t_1 elif t_2 < 1.045027827330126e-269: tmp = ((x / z) * 2.0) / (y - t) else: tmp = t_1 return tmp
function code(x, y, z, t) t_1 = Float64(Float64(x / Float64(Float64(y - t) * z)) * 2.0) t_2 = Float64(Float64(x * 2.0) / Float64(Float64(y * z) - Float64(t * z))) tmp = 0.0 if (t_2 < -2.559141628295061e-13) tmp = t_1; elseif (t_2 < 1.045027827330126e-269) tmp = Float64(Float64(Float64(x / z) * 2.0) / Float64(y - t)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = (x / ((y - t) * z)) * 2.0; t_2 = (x * 2.0) / ((y * z) - (t * z)); tmp = 0.0; if (t_2 < -2.559141628295061e-13) tmp = t_1; elseif (t_2 < 1.045027827330126e-269) tmp = ((x / z) * 2.0) / (y - t); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x / N[(N[(y - t), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x * 2.0), $MachinePrecision] / N[(N[(y * z), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Less[t$95$2, -2.559141628295061e-13], t$95$1, If[Less[t$95$2, 1.045027827330126e-269], N[(N[(N[(x / z), $MachinePrecision] * 2.0), $MachinePrecision] / N[(y - t), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x}{\left(y - t\right) \cdot z} \cdot 2\\
t_2 := \frac{x \cdot 2}{y \cdot z - t \cdot z}\\
\mathbf{if}\;t_2 < -2.559141628295061 \cdot 10^{-13}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t_2 < 1.045027827330126 \cdot 10^{-269}:\\
\;\;\;\;\frac{\frac{x}{z} \cdot 2}{y - t}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
herbie shell --seed 2023308
(FPCore (x y z t)
:name "Linear.Projection:infinitePerspective from linear-1.19.1.3, A"
:precision binary64
:herbie-target
(if (< (/ (* x 2.0) (- (* y z) (* t z))) -2.559141628295061e-13) (* (/ x (* (- y t) z)) 2.0) (if (< (/ (* x 2.0) (- (* y z) (* t z))) 1.045027827330126e-269) (/ (* (/ x z) 2.0) (- y t)) (* (/ x (* (- y t) z)) 2.0)))
(/ (* x 2.0) (- (* y z) (* t z))))