
(FPCore (x y z t a) :precision binary64 (- x (/ (* y (- z t)) a)))
double code(double x, double y, double z, double t, double a) {
return x - ((y * (z - t)) / a);
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = x - ((y * (z - t)) / a)
end function
public static double code(double x, double y, double z, double t, double a) {
return x - ((y * (z - t)) / a);
}
def code(x, y, z, t, a): return x - ((y * (z - t)) / a)
function code(x, y, z, t, a) return Float64(x - Float64(Float64(y * Float64(z - t)) / a)) end
function tmp = code(x, y, z, t, a) tmp = x - ((y * (z - t)) / a); end
code[x_, y_, z_, t_, a_] := N[(x - N[(N[(y * N[(z - t), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x - \frac{y \cdot \left(z - t\right)}{a}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 10 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a) :precision binary64 (- x (/ (* y (- z t)) a)))
double code(double x, double y, double z, double t, double a) {
return x - ((y * (z - t)) / a);
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = x - ((y * (z - t)) / a)
end function
public static double code(double x, double y, double z, double t, double a) {
return x - ((y * (z - t)) / a);
}
def code(x, y, z, t, a): return x - ((y * (z - t)) / a)
function code(x, y, z, t, a) return Float64(x - Float64(Float64(y * Float64(z - t)) / a)) end
function tmp = code(x, y, z, t, a) tmp = x - ((y * (z - t)) / a); end
code[x_, y_, z_, t_, a_] := N[(x - N[(N[(y * N[(z - t), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x - \frac{y \cdot \left(z - t\right)}{a}
\end{array}
(FPCore (x y z t a) :precision binary64 (+ x (* (/ y a) (- t z))))
double code(double x, double y, double z, double t, double a) {
return x + ((y / a) * (t - z));
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = x + ((y / a) * (t - z))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + ((y / a) * (t - z));
}
def code(x, y, z, t, a): return x + ((y / a) * (t - z))
function code(x, y, z, t, a) return Float64(x + Float64(Float64(y / a) * Float64(t - z))) end
function tmp = code(x, y, z, t, a) tmp = x + ((y / a) * (t - z)); end
code[x_, y_, z_, t_, a_] := N[(x + N[(N[(y / a), $MachinePrecision] * N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \frac{y}{a} \cdot \left(t - z\right)
\end{array}
Initial program 93.3%
*-commutative93.3%
associate-/l*98.0%
Applied egg-rr98.0%
Final simplification98.0%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* y (/ t a))) (t_2 (* y (/ z (- a)))) (t_3 (* z (/ y (- a)))))
(if (<= y -1.1e+164)
t_3
(if (<= y -9.5e+52)
(* t (/ y a))
(if (<= y -3.2e-42)
t_2
(if (<= y 2.05e-44)
x
(if (<= y 7.7e+65)
t_1
(if (<= y 1.88e+130) t_2 (if (<= y 6.6e+273) t_1 t_3)))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = y * (t / a);
double t_2 = y * (z / -a);
double t_3 = z * (y / -a);
double tmp;
if (y <= -1.1e+164) {
tmp = t_3;
} else if (y <= -9.5e+52) {
tmp = t * (y / a);
} else if (y <= -3.2e-42) {
tmp = t_2;
} else if (y <= 2.05e-44) {
tmp = x;
} else if (y <= 7.7e+65) {
tmp = t_1;
} else if (y <= 1.88e+130) {
tmp = t_2;
} else if (y <= 6.6e+273) {
tmp = t_1;
} else {
tmp = t_3;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: tmp
t_1 = y * (t / a)
t_2 = y * (z / -a)
t_3 = z * (y / -a)
if (y <= (-1.1d+164)) then
tmp = t_3
else if (y <= (-9.5d+52)) then
tmp = t * (y / a)
else if (y <= (-3.2d-42)) then
tmp = t_2
else if (y <= 2.05d-44) then
tmp = x
else if (y <= 7.7d+65) then
tmp = t_1
else if (y <= 1.88d+130) then
tmp = t_2
else if (y <= 6.6d+273) then
tmp = t_1
else
tmp = t_3
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = y * (t / a);
double t_2 = y * (z / -a);
double t_3 = z * (y / -a);
double tmp;
if (y <= -1.1e+164) {
tmp = t_3;
} else if (y <= -9.5e+52) {
tmp = t * (y / a);
} else if (y <= -3.2e-42) {
tmp = t_2;
} else if (y <= 2.05e-44) {
tmp = x;
} else if (y <= 7.7e+65) {
tmp = t_1;
} else if (y <= 1.88e+130) {
tmp = t_2;
} else if (y <= 6.6e+273) {
tmp = t_1;
} else {
tmp = t_3;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = y * (t / a) t_2 = y * (z / -a) t_3 = z * (y / -a) tmp = 0 if y <= -1.1e+164: tmp = t_3 elif y <= -9.5e+52: tmp = t * (y / a) elif y <= -3.2e-42: tmp = t_2 elif y <= 2.05e-44: tmp = x elif y <= 7.7e+65: tmp = t_1 elif y <= 1.88e+130: tmp = t_2 elif y <= 6.6e+273: tmp = t_1 else: tmp = t_3 return tmp
function code(x, y, z, t, a) t_1 = Float64(y * Float64(t / a)) t_2 = Float64(y * Float64(z / Float64(-a))) t_3 = Float64(z * Float64(y / Float64(-a))) tmp = 0.0 if (y <= -1.1e+164) tmp = t_3; elseif (y <= -9.5e+52) tmp = Float64(t * Float64(y / a)); elseif (y <= -3.2e-42) tmp = t_2; elseif (y <= 2.05e-44) tmp = x; elseif (y <= 7.7e+65) tmp = t_1; elseif (y <= 1.88e+130) tmp = t_2; elseif (y <= 6.6e+273) tmp = t_1; else tmp = t_3; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = y * (t / a); t_2 = y * (z / -a); t_3 = z * (y / -a); tmp = 0.0; if (y <= -1.1e+164) tmp = t_3; elseif (y <= -9.5e+52) tmp = t * (y / a); elseif (y <= -3.2e-42) tmp = t_2; elseif (y <= 2.05e-44) tmp = x; elseif (y <= 7.7e+65) tmp = t_1; elseif (y <= 1.88e+130) tmp = t_2; elseif (y <= 6.6e+273) tmp = t_1; else tmp = t_3; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y * N[(t / a), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y * N[(z / (-a)), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(z * N[(y / (-a)), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.1e+164], t$95$3, If[LessEqual[y, -9.5e+52], N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -3.2e-42], t$95$2, If[LessEqual[y, 2.05e-44], x, If[LessEqual[y, 7.7e+65], t$95$1, If[LessEqual[y, 1.88e+130], t$95$2, If[LessEqual[y, 6.6e+273], t$95$1, t$95$3]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \frac{t}{a}\\
t_2 := y \cdot \frac{z}{-a}\\
t_3 := z \cdot \frac{y}{-a}\\
\mathbf{if}\;y \leq -1.1 \cdot 10^{+164}:\\
\;\;\;\;t\_3\\
\mathbf{elif}\;y \leq -9.5 \cdot 10^{+52}:\\
\;\;\;\;t \cdot \frac{y}{a}\\
\mathbf{elif}\;y \leq -3.2 \cdot 10^{-42}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y \leq 2.05 \cdot 10^{-44}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 7.7 \cdot 10^{+65}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 1.88 \cdot 10^{+130}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y \leq 6.6 \cdot 10^{+273}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_3\\
\end{array}
\end{array}
if y < -1.10000000000000003e164 or 6.59999999999999971e273 < y Initial program 83.6%
*-commutative83.6%
associate-/l*100.0%
Applied egg-rr100.0%
Taylor expanded in z around inf 66.7%
mul-1-neg66.7%
associate-*l/69.1%
distribute-rgt-neg-in69.1%
Simplified69.1%
if -1.10000000000000003e164 < y < -9.49999999999999994e52Initial program 85.5%
*-commutative85.5%
associate-/l*99.8%
Applied egg-rr99.8%
Taylor expanded in t around inf 62.7%
associate-*r/77.0%
Simplified77.0%
if -9.49999999999999994e52 < y < -3.20000000000000025e-42 or 7.70000000000000038e65 < y < 1.88000000000000003e130Initial program 89.5%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 63.3%
mul-1-neg63.3%
associate-/l*68.3%
distribute-rgt-neg-in68.3%
distribute-neg-frac268.3%
Simplified68.3%
if -3.20000000000000025e-42 < y < 2.04999999999999996e-44Initial program 99.9%
associate-/l*86.9%
Simplified86.9%
Taylor expanded in x around inf 67.7%
if 2.04999999999999996e-44 < y < 7.70000000000000038e65 or 1.88000000000000003e130 < y < 6.59999999999999971e273Initial program 92.5%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in t around inf 51.3%
*-commutative51.3%
associate-/l*55.5%
Simplified55.5%
Final simplification65.5%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* y (/ t a))) (t_2 (* z (/ y (- a)))))
(if (<= y -7.2e+157)
t_2
(if (<= y -5.5e+52)
(* t (/ y a))
(if (<= y -1.75e-36)
(* y (/ z (- a)))
(if (<= y 3.2e-44)
x
(if (<= y 9e+65)
t_1
(if (<= y 1.9e+130)
(/ y (/ a (- z)))
(if (<= y 4.25e+273) t_1 t_2)))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = y * (t / a);
double t_2 = z * (y / -a);
double tmp;
if (y <= -7.2e+157) {
tmp = t_2;
} else if (y <= -5.5e+52) {
tmp = t * (y / a);
} else if (y <= -1.75e-36) {
tmp = y * (z / -a);
} else if (y <= 3.2e-44) {
tmp = x;
} else if (y <= 9e+65) {
tmp = t_1;
} else if (y <= 1.9e+130) {
tmp = y / (a / -z);
} else if (y <= 4.25e+273) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = y * (t / a)
t_2 = z * (y / -a)
if (y <= (-7.2d+157)) then
tmp = t_2
else if (y <= (-5.5d+52)) then
tmp = t * (y / a)
else if (y <= (-1.75d-36)) then
tmp = y * (z / -a)
else if (y <= 3.2d-44) then
tmp = x
else if (y <= 9d+65) then
tmp = t_1
else if (y <= 1.9d+130) then
tmp = y / (a / -z)
else if (y <= 4.25d+273) then
tmp = t_1
else
tmp = t_2
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = y * (t / a);
double t_2 = z * (y / -a);
double tmp;
if (y <= -7.2e+157) {
tmp = t_2;
} else if (y <= -5.5e+52) {
tmp = t * (y / a);
} else if (y <= -1.75e-36) {
tmp = y * (z / -a);
} else if (y <= 3.2e-44) {
tmp = x;
} else if (y <= 9e+65) {
tmp = t_1;
} else if (y <= 1.9e+130) {
tmp = y / (a / -z);
} else if (y <= 4.25e+273) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = y * (t / a) t_2 = z * (y / -a) tmp = 0 if y <= -7.2e+157: tmp = t_2 elif y <= -5.5e+52: tmp = t * (y / a) elif y <= -1.75e-36: tmp = y * (z / -a) elif y <= 3.2e-44: tmp = x elif y <= 9e+65: tmp = t_1 elif y <= 1.9e+130: tmp = y / (a / -z) elif y <= 4.25e+273: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a) t_1 = Float64(y * Float64(t / a)) t_2 = Float64(z * Float64(y / Float64(-a))) tmp = 0.0 if (y <= -7.2e+157) tmp = t_2; elseif (y <= -5.5e+52) tmp = Float64(t * Float64(y / a)); elseif (y <= -1.75e-36) tmp = Float64(y * Float64(z / Float64(-a))); elseif (y <= 3.2e-44) tmp = x; elseif (y <= 9e+65) tmp = t_1; elseif (y <= 1.9e+130) tmp = Float64(y / Float64(a / Float64(-z))); elseif (y <= 4.25e+273) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = y * (t / a); t_2 = z * (y / -a); tmp = 0.0; if (y <= -7.2e+157) tmp = t_2; elseif (y <= -5.5e+52) tmp = t * (y / a); elseif (y <= -1.75e-36) tmp = y * (z / -a); elseif (y <= 3.2e-44) tmp = x; elseif (y <= 9e+65) tmp = t_1; elseif (y <= 1.9e+130) tmp = y / (a / -z); elseif (y <= 4.25e+273) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y * N[(t / a), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(z * N[(y / (-a)), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -7.2e+157], t$95$2, If[LessEqual[y, -5.5e+52], N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -1.75e-36], N[(y * N[(z / (-a)), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3.2e-44], x, If[LessEqual[y, 9e+65], t$95$1, If[LessEqual[y, 1.9e+130], N[(y / N[(a / (-z)), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 4.25e+273], t$95$1, t$95$2]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \frac{t}{a}\\
t_2 := z \cdot \frac{y}{-a}\\
\mathbf{if}\;y \leq -7.2 \cdot 10^{+157}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y \leq -5.5 \cdot 10^{+52}:\\
\;\;\;\;t \cdot \frac{y}{a}\\
\mathbf{elif}\;y \leq -1.75 \cdot 10^{-36}:\\
\;\;\;\;y \cdot \frac{z}{-a}\\
\mathbf{elif}\;y \leq 3.2 \cdot 10^{-44}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 9 \cdot 10^{+65}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 1.9 \cdot 10^{+130}:\\
\;\;\;\;\frac{y}{\frac{a}{-z}}\\
\mathbf{elif}\;y \leq 4.25 \cdot 10^{+273}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if y < -7.20000000000000049e157 or 4.2500000000000001e273 < y Initial program 83.6%
*-commutative83.6%
associate-/l*100.0%
Applied egg-rr100.0%
Taylor expanded in z around inf 66.7%
mul-1-neg66.7%
associate-*l/69.1%
distribute-rgt-neg-in69.1%
Simplified69.1%
if -7.20000000000000049e157 < y < -5.49999999999999996e52Initial program 85.5%
*-commutative85.5%
associate-/l*99.8%
Applied egg-rr99.8%
Taylor expanded in t around inf 62.7%
associate-*r/77.0%
Simplified77.0%
if -5.49999999999999996e52 < y < -1.75e-36Initial program 95.1%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 70.8%
mul-1-neg70.8%
associate-/l*70.9%
distribute-rgt-neg-in70.9%
distribute-neg-frac270.9%
Simplified70.9%
if -1.75e-36 < y < 3.19999999999999995e-44Initial program 99.9%
associate-/l*86.9%
Simplified86.9%
Taylor expanded in x around inf 67.7%
if 3.19999999999999995e-44 < y < 9e65 or 1.9000000000000001e130 < y < 4.2500000000000001e273Initial program 92.5%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in t around inf 51.3%
*-commutative51.3%
associate-/l*55.5%
Simplified55.5%
if 9e65 < y < 1.9000000000000001e130Initial program 82.8%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 54.6%
mul-1-neg54.6%
associate-/l*65.3%
distribute-rgt-neg-in65.3%
distribute-neg-frac265.3%
Simplified65.3%
associate-*r/54.6%
add-sqr-sqrt30.0%
sqrt-unprod30.1%
sqr-neg30.1%
sqrt-unprod0.7%
add-sqr-sqrt1.2%
associate-*l/6.7%
associate-/r/1.1%
frac-2neg1.1%
distribute-neg-frac21.1%
add-sqr-sqrt1.0%
sqrt-unprod36.3%
sqr-neg36.3%
sqrt-unprod35.4%
add-sqr-sqrt65.4%
Applied egg-rr65.4%
Final simplification65.5%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* y (/ t a))))
(if (<= y -7.8e+157)
(/ (* z (- y)) a)
(if (<= y -9.2e+51)
(* t (/ y a))
(if (<= y -1.72e-40)
(* y (/ z (- a)))
(if (<= y 2.1e-44)
x
(if (<= y 6.7e+65)
t_1
(if (<= y 1.9e+130)
(/ y (/ a (- z)))
(if (<= y 8.5e+273) t_1 (* z (/ y (- a))))))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = y * (t / a);
double tmp;
if (y <= -7.8e+157) {
tmp = (z * -y) / a;
} else if (y <= -9.2e+51) {
tmp = t * (y / a);
} else if (y <= -1.72e-40) {
tmp = y * (z / -a);
} else if (y <= 2.1e-44) {
tmp = x;
} else if (y <= 6.7e+65) {
tmp = t_1;
} else if (y <= 1.9e+130) {
tmp = y / (a / -z);
} else if (y <= 8.5e+273) {
tmp = t_1;
} else {
tmp = z * (y / -a);
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = y * (t / a)
if (y <= (-7.8d+157)) then
tmp = (z * -y) / a
else if (y <= (-9.2d+51)) then
tmp = t * (y / a)
else if (y <= (-1.72d-40)) then
tmp = y * (z / -a)
else if (y <= 2.1d-44) then
tmp = x
else if (y <= 6.7d+65) then
tmp = t_1
else if (y <= 1.9d+130) then
tmp = y / (a / -z)
else if (y <= 8.5d+273) then
tmp = t_1
else
tmp = z * (y / -a)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = y * (t / a);
double tmp;
if (y <= -7.8e+157) {
tmp = (z * -y) / a;
} else if (y <= -9.2e+51) {
tmp = t * (y / a);
} else if (y <= -1.72e-40) {
tmp = y * (z / -a);
} else if (y <= 2.1e-44) {
tmp = x;
} else if (y <= 6.7e+65) {
tmp = t_1;
} else if (y <= 1.9e+130) {
tmp = y / (a / -z);
} else if (y <= 8.5e+273) {
tmp = t_1;
} else {
tmp = z * (y / -a);
}
return tmp;
}
def code(x, y, z, t, a): t_1 = y * (t / a) tmp = 0 if y <= -7.8e+157: tmp = (z * -y) / a elif y <= -9.2e+51: tmp = t * (y / a) elif y <= -1.72e-40: tmp = y * (z / -a) elif y <= 2.1e-44: tmp = x elif y <= 6.7e+65: tmp = t_1 elif y <= 1.9e+130: tmp = y / (a / -z) elif y <= 8.5e+273: tmp = t_1 else: tmp = z * (y / -a) return tmp
function code(x, y, z, t, a) t_1 = Float64(y * Float64(t / a)) tmp = 0.0 if (y <= -7.8e+157) tmp = Float64(Float64(z * Float64(-y)) / a); elseif (y <= -9.2e+51) tmp = Float64(t * Float64(y / a)); elseif (y <= -1.72e-40) tmp = Float64(y * Float64(z / Float64(-a))); elseif (y <= 2.1e-44) tmp = x; elseif (y <= 6.7e+65) tmp = t_1; elseif (y <= 1.9e+130) tmp = Float64(y / Float64(a / Float64(-z))); elseif (y <= 8.5e+273) tmp = t_1; else tmp = Float64(z * Float64(y / Float64(-a))); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = y * (t / a); tmp = 0.0; if (y <= -7.8e+157) tmp = (z * -y) / a; elseif (y <= -9.2e+51) tmp = t * (y / a); elseif (y <= -1.72e-40) tmp = y * (z / -a); elseif (y <= 2.1e-44) tmp = x; elseif (y <= 6.7e+65) tmp = t_1; elseif (y <= 1.9e+130) tmp = y / (a / -z); elseif (y <= 8.5e+273) tmp = t_1; else tmp = z * (y / -a); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y * N[(t / a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -7.8e+157], N[(N[(z * (-y)), $MachinePrecision] / a), $MachinePrecision], If[LessEqual[y, -9.2e+51], N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -1.72e-40], N[(y * N[(z / (-a)), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.1e-44], x, If[LessEqual[y, 6.7e+65], t$95$1, If[LessEqual[y, 1.9e+130], N[(y / N[(a / (-z)), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 8.5e+273], t$95$1, N[(z * N[(y / (-a)), $MachinePrecision]), $MachinePrecision]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \frac{t}{a}\\
\mathbf{if}\;y \leq -7.8 \cdot 10^{+157}:\\
\;\;\;\;\frac{z \cdot \left(-y\right)}{a}\\
\mathbf{elif}\;y \leq -9.2 \cdot 10^{+51}:\\
\;\;\;\;t \cdot \frac{y}{a}\\
\mathbf{elif}\;y \leq -1.72 \cdot 10^{-40}:\\
\;\;\;\;y \cdot \frac{z}{-a}\\
\mathbf{elif}\;y \leq 2.1 \cdot 10^{-44}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 6.7 \cdot 10^{+65}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 1.9 \cdot 10^{+130}:\\
\;\;\;\;\frac{y}{\frac{a}{-z}}\\
\mathbf{elif}\;y \leq 8.5 \cdot 10^{+273}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;z \cdot \frac{y}{-a}\\
\end{array}
\end{array}
if y < -7.79999999999999941e157Initial program 87.8%
*-commutative87.8%
associate-/l*100.0%
Applied egg-rr100.0%
Taylor expanded in z around inf 72.3%
associate-*r/72.3%
*-commutative72.3%
neg-mul-172.3%
distribute-lft-neg-in72.3%
*-commutative72.3%
Simplified72.3%
if -7.79999999999999941e157 < y < -9.2000000000000002e51Initial program 85.5%
*-commutative85.5%
associate-/l*99.8%
Applied egg-rr99.8%
Taylor expanded in t around inf 62.7%
associate-*r/77.0%
Simplified77.0%
if -9.2000000000000002e51 < y < -1.7199999999999999e-40Initial program 95.1%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 70.8%
mul-1-neg70.8%
associate-/l*70.9%
distribute-rgt-neg-in70.9%
distribute-neg-frac270.9%
Simplified70.9%
if -1.7199999999999999e-40 < y < 2.10000000000000001e-44Initial program 99.9%
associate-/l*86.9%
Simplified86.9%
Taylor expanded in x around inf 67.7%
if 2.10000000000000001e-44 < y < 6.6999999999999997e65 or 1.9000000000000001e130 < y < 8.5000000000000002e273Initial program 92.5%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in t around inf 51.3%
*-commutative51.3%
associate-/l*55.5%
Simplified55.5%
if 6.6999999999999997e65 < y < 1.9000000000000001e130Initial program 82.8%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 54.6%
mul-1-neg54.6%
associate-/l*65.3%
distribute-rgt-neg-in65.3%
distribute-neg-frac265.3%
Simplified65.3%
associate-*r/54.6%
add-sqr-sqrt30.0%
sqrt-unprod30.1%
sqr-neg30.1%
sqrt-unprod0.7%
add-sqr-sqrt1.2%
associate-*l/6.7%
associate-/r/1.1%
frac-2neg1.1%
distribute-neg-frac21.1%
add-sqr-sqrt1.0%
sqrt-unprod36.3%
sqr-neg36.3%
sqrt-unprod35.4%
add-sqr-sqrt65.4%
Applied egg-rr65.4%
if 8.5000000000000002e273 < y Initial program 68.6%
*-commutative68.6%
associate-/l*100.0%
Applied egg-rr100.0%
Taylor expanded in z around inf 46.6%
mul-1-neg46.6%
associate-*l/77.9%
distribute-rgt-neg-in77.9%
Simplified77.9%
Final simplification66.2%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* y (/ z (- a)))))
(if (<= y -1.4e+158)
t_1
(if (<= y -1.55e+53)
(* t (/ y a))
(if (<= y -8.5e-39)
t_1
(if (<= y 2.9e-44)
x
(if (or (<= y 7.7e+65) (not (<= y 1.8e+130)))
(* y (/ t a))
t_1)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = y * (z / -a);
double tmp;
if (y <= -1.4e+158) {
tmp = t_1;
} else if (y <= -1.55e+53) {
tmp = t * (y / a);
} else if (y <= -8.5e-39) {
tmp = t_1;
} else if (y <= 2.9e-44) {
tmp = x;
} else if ((y <= 7.7e+65) || !(y <= 1.8e+130)) {
tmp = y * (t / a);
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = y * (z / -a)
if (y <= (-1.4d+158)) then
tmp = t_1
else if (y <= (-1.55d+53)) then
tmp = t * (y / a)
else if (y <= (-8.5d-39)) then
tmp = t_1
else if (y <= 2.9d-44) then
tmp = x
else if ((y <= 7.7d+65) .or. (.not. (y <= 1.8d+130))) then
tmp = y * (t / a)
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = y * (z / -a);
double tmp;
if (y <= -1.4e+158) {
tmp = t_1;
} else if (y <= -1.55e+53) {
tmp = t * (y / a);
} else if (y <= -8.5e-39) {
tmp = t_1;
} else if (y <= 2.9e-44) {
tmp = x;
} else if ((y <= 7.7e+65) || !(y <= 1.8e+130)) {
tmp = y * (t / a);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = y * (z / -a) tmp = 0 if y <= -1.4e+158: tmp = t_1 elif y <= -1.55e+53: tmp = t * (y / a) elif y <= -8.5e-39: tmp = t_1 elif y <= 2.9e-44: tmp = x elif (y <= 7.7e+65) or not (y <= 1.8e+130): tmp = y * (t / a) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(y * Float64(z / Float64(-a))) tmp = 0.0 if (y <= -1.4e+158) tmp = t_1; elseif (y <= -1.55e+53) tmp = Float64(t * Float64(y / a)); elseif (y <= -8.5e-39) tmp = t_1; elseif (y <= 2.9e-44) tmp = x; elseif ((y <= 7.7e+65) || !(y <= 1.8e+130)) tmp = Float64(y * Float64(t / a)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = y * (z / -a); tmp = 0.0; if (y <= -1.4e+158) tmp = t_1; elseif (y <= -1.55e+53) tmp = t * (y / a); elseif (y <= -8.5e-39) tmp = t_1; elseif (y <= 2.9e-44) tmp = x; elseif ((y <= 7.7e+65) || ~((y <= 1.8e+130))) tmp = y * (t / a); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y * N[(z / (-a)), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.4e+158], t$95$1, If[LessEqual[y, -1.55e+53], N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -8.5e-39], t$95$1, If[LessEqual[y, 2.9e-44], x, If[Or[LessEqual[y, 7.7e+65], N[Not[LessEqual[y, 1.8e+130]], $MachinePrecision]], N[(y * N[(t / a), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \frac{z}{-a}\\
\mathbf{if}\;y \leq -1.4 \cdot 10^{+158}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq -1.55 \cdot 10^{+53}:\\
\;\;\;\;t \cdot \frac{y}{a}\\
\mathbf{elif}\;y \leq -8.5 \cdot 10^{-39}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 2.9 \cdot 10^{-44}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 7.7 \cdot 10^{+65} \lor \neg \left(y \leq 1.8 \cdot 10^{+130}\right):\\
\;\;\;\;y \cdot \frac{t}{a}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -1.40000000000000001e158 or -1.5500000000000001e53 < y < -8.5000000000000005e-39 or 7.70000000000000038e65 < y < 1.8000000000000001e130Initial program 88.7%
associate-/l*98.5%
Simplified98.5%
Taylor expanded in z around inf 67.5%
mul-1-neg67.5%
associate-/l*66.2%
distribute-rgt-neg-in66.2%
distribute-neg-frac266.2%
Simplified66.2%
if -1.40000000000000001e158 < y < -1.5500000000000001e53Initial program 85.5%
*-commutative85.5%
associate-/l*99.8%
Applied egg-rr99.8%
Taylor expanded in t around inf 62.7%
associate-*r/77.0%
Simplified77.0%
if -8.5000000000000005e-39 < y < 2.9000000000000001e-44Initial program 99.9%
associate-/l*86.9%
Simplified86.9%
Taylor expanded in x around inf 67.7%
if 2.9000000000000001e-44 < y < 7.70000000000000038e65 or 1.8000000000000001e130 < y Initial program 89.5%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in t around inf 49.3%
*-commutative49.3%
associate-/l*54.3%
Simplified54.3%
Final simplification64.0%
(FPCore (x y z t a) :precision binary64 (if (or (<= y -2.9e-45) (not (<= y 1.35e-139))) (* y (/ (- t z) a)) x))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -2.9e-45) || !(y <= 1.35e-139)) {
tmp = y * ((t - z) / a);
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((y <= (-2.9d-45)) .or. (.not. (y <= 1.35d-139))) then
tmp = y * ((t - z) / a)
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -2.9e-45) || !(y <= 1.35e-139)) {
tmp = y * ((t - z) / a);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (y <= -2.9e-45) or not (y <= 1.35e-139): tmp = y * ((t - z) / a) else: tmp = x return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((y <= -2.9e-45) || !(y <= 1.35e-139)) tmp = Float64(y * Float64(Float64(t - z) / a)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((y <= -2.9e-45) || ~((y <= 1.35e-139))) tmp = y * ((t - z) / a); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[y, -2.9e-45], N[Not[LessEqual[y, 1.35e-139]], $MachinePrecision]], N[(y * N[(N[(t - z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], x]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.9 \cdot 10^{-45} \lor \neg \left(y \leq 1.35 \cdot 10^{-139}\right):\\
\;\;\;\;y \cdot \frac{t - z}{a}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -2.9e-45 or 1.3499999999999999e-139 < y Initial program 90.0%
associate-/l*98.7%
Simplified98.7%
Taylor expanded in x around 0 73.6%
mul-1-neg73.6%
distribute-frac-neg273.6%
sub-neg73.6%
+-commutative73.6%
neg-sub073.6%
associate--r-73.6%
neg-sub073.6%
associate-*r/80.7%
distribute-neg-frac80.7%
distribute-neg-frac280.7%
remove-double-neg80.7%
Simplified80.7%
if -2.9e-45 < y < 1.3499999999999999e-139Initial program 99.9%
associate-/l*85.1%
Simplified85.1%
Taylor expanded in x around inf 74.2%
Final simplification78.6%
(FPCore (x y z t a) :precision binary64 (if (or (<= y -2.8e-36) (not (<= y 1.35e+29))) (* y (/ (- t z) a)) (+ x (/ (* t y) a))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -2.8e-36) || !(y <= 1.35e+29)) {
tmp = y * ((t - z) / a);
} else {
tmp = x + ((t * y) / a);
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((y <= (-2.8d-36)) .or. (.not. (y <= 1.35d+29))) then
tmp = y * ((t - z) / a)
else
tmp = x + ((t * y) / a)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -2.8e-36) || !(y <= 1.35e+29)) {
tmp = y * ((t - z) / a);
} else {
tmp = x + ((t * y) / a);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (y <= -2.8e-36) or not (y <= 1.35e+29): tmp = y * ((t - z) / a) else: tmp = x + ((t * y) / a) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((y <= -2.8e-36) || !(y <= 1.35e+29)) tmp = Float64(y * Float64(Float64(t - z) / a)); else tmp = Float64(x + Float64(Float64(t * y) / a)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((y <= -2.8e-36) || ~((y <= 1.35e+29))) tmp = y * ((t - z) / a); else tmp = x + ((t * y) / a); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[y, -2.8e-36], N[Not[LessEqual[y, 1.35e+29]], $MachinePrecision]], N[(y * N[(N[(t - z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(t * y), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.8 \cdot 10^{-36} \lor \neg \left(y \leq 1.35 \cdot 10^{+29}\right):\\
\;\;\;\;y \cdot \frac{t - z}{a}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{t \cdot y}{a}\\
\end{array}
\end{array}
if y < -2.8000000000000001e-36 or 1.35e29 < y Initial program 87.4%
associate-/l*99.1%
Simplified99.1%
Taylor expanded in x around 0 76.4%
mul-1-neg76.4%
distribute-frac-neg276.4%
sub-neg76.4%
+-commutative76.4%
neg-sub076.4%
associate--r-76.4%
neg-sub076.4%
associate-*r/85.8%
distribute-neg-frac85.8%
distribute-neg-frac285.8%
remove-double-neg85.8%
Simplified85.8%
if -2.8000000000000001e-36 < y < 1.35e29Initial program 99.9%
sub-neg99.9%
distribute-frac-neg299.9%
+-commutative99.9%
associate-/l*88.9%
fma-define88.9%
distribute-frac-neg288.9%
distribute-neg-frac88.9%
sub-neg88.9%
distribute-neg-in88.9%
remove-double-neg88.9%
+-commutative88.9%
sub-neg88.9%
Simplified88.9%
Taylor expanded in z around 0 82.1%
Final simplification84.1%
(FPCore (x y z t a) :precision binary64 (if (or (<= y -3.1e-37) (not (<= y 2.3e-44))) (* t (/ y a)) x))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -3.1e-37) || !(y <= 2.3e-44)) {
tmp = t * (y / a);
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((y <= (-3.1d-37)) .or. (.not. (y <= 2.3d-44))) then
tmp = t * (y / a)
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -3.1e-37) || !(y <= 2.3e-44)) {
tmp = t * (y / a);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (y <= -3.1e-37) or not (y <= 2.3e-44): tmp = t * (y / a) else: tmp = x return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((y <= -3.1e-37) || !(y <= 2.3e-44)) tmp = Float64(t * Float64(y / a)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((y <= -3.1e-37) || ~((y <= 2.3e-44))) tmp = t * (y / a); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[y, -3.1e-37], N[Not[LessEqual[y, 2.3e-44]], $MachinePrecision]], N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision], x]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.1 \cdot 10^{-37} \lor \neg \left(y \leq 2.3 \cdot 10^{-44}\right):\\
\;\;\;\;t \cdot \frac{y}{a}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -3.09999999999999993e-37 or 2.29999999999999998e-44 < y Initial program 88.8%
*-commutative88.8%
associate-/l*98.0%
Applied egg-rr98.0%
Taylor expanded in t around inf 38.8%
associate-*r/45.4%
Simplified45.4%
if -3.09999999999999993e-37 < y < 2.29999999999999998e-44Initial program 99.9%
associate-/l*86.9%
Simplified86.9%
Taylor expanded in x around inf 67.7%
Final simplification54.3%
(FPCore (x y z t a) :precision binary64 (+ x (* y (/ (- t z) a))))
double code(double x, double y, double z, double t, double a) {
return x + (y * ((t - z) / a));
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = x + (y * ((t - z) / a))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + (y * ((t - z) / a));
}
def code(x, y, z, t, a): return x + (y * ((t - z) / a))
function code(x, y, z, t, a) return Float64(x + Float64(y * Float64(Float64(t - z) / a))) end
function tmp = code(x, y, z, t, a) tmp = x + (y * ((t - z) / a)); end
code[x_, y_, z_, t_, a_] := N[(x + N[(y * N[(N[(t - z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + y \cdot \frac{t - z}{a}
\end{array}
Initial program 93.3%
associate-/l*94.3%
Simplified94.3%
Final simplification94.3%
(FPCore (x y z t a) :precision binary64 x)
double code(double x, double y, double z, double t, double a) {
return x;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = x
end function
public static double code(double x, double y, double z, double t, double a) {
return x;
}
def code(x, y, z, t, a): return x
function code(x, y, z, t, a) return x end
function tmp = code(x, y, z, t, a) tmp = x; end
code[x_, y_, z_, t_, a_] := x
\begin{array}{l}
\\
x
\end{array}
Initial program 93.3%
associate-/l*94.3%
Simplified94.3%
Taylor expanded in x around inf 36.5%
Final simplification36.5%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (/ a (- z t))))
(if (< y -1.0761266216389975e-10)
(- x (/ 1.0 (/ t_1 y)))
(if (< y 2.894426862792089e-49)
(- x (/ (* y (- z t)) a))
(- x (/ y t_1))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = a / (z - t);
double tmp;
if (y < -1.0761266216389975e-10) {
tmp = x - (1.0 / (t_1 / y));
} else if (y < 2.894426862792089e-49) {
tmp = x - ((y * (z - t)) / a);
} else {
tmp = x - (y / t_1);
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = a / (z - t)
if (y < (-1.0761266216389975d-10)) then
tmp = x - (1.0d0 / (t_1 / y))
else if (y < 2.894426862792089d-49) then
tmp = x - ((y * (z - t)) / a)
else
tmp = x - (y / t_1)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = a / (z - t);
double tmp;
if (y < -1.0761266216389975e-10) {
tmp = x - (1.0 / (t_1 / y));
} else if (y < 2.894426862792089e-49) {
tmp = x - ((y * (z - t)) / a);
} else {
tmp = x - (y / t_1);
}
return tmp;
}
def code(x, y, z, t, a): t_1 = a / (z - t) tmp = 0 if y < -1.0761266216389975e-10: tmp = x - (1.0 / (t_1 / y)) elif y < 2.894426862792089e-49: tmp = x - ((y * (z - t)) / a) else: tmp = x - (y / t_1) return tmp
function code(x, y, z, t, a) t_1 = Float64(a / Float64(z - t)) tmp = 0.0 if (y < -1.0761266216389975e-10) tmp = Float64(x - Float64(1.0 / Float64(t_1 / y))); elseif (y < 2.894426862792089e-49) tmp = Float64(x - Float64(Float64(y * Float64(z - t)) / a)); else tmp = Float64(x - Float64(y / t_1)); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = a / (z - t); tmp = 0.0; if (y < -1.0761266216389975e-10) tmp = x - (1.0 / (t_1 / y)); elseif (y < 2.894426862792089e-49) tmp = x - ((y * (z - t)) / a); else tmp = x - (y / t_1); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(a / N[(z - t), $MachinePrecision]), $MachinePrecision]}, If[Less[y, -1.0761266216389975e-10], N[(x - N[(1.0 / N[(t$95$1 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Less[y, 2.894426862792089e-49], N[(x - N[(N[(y * N[(z - t), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], N[(x - N[(y / t$95$1), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{a}{z - t}\\
\mathbf{if}\;y < -1.0761266216389975 \cdot 10^{-10}:\\
\;\;\;\;x - \frac{1}{\frac{t\_1}{y}}\\
\mathbf{elif}\;y < 2.894426862792089 \cdot 10^{-49}:\\
\;\;\;\;x - \frac{y \cdot \left(z - t\right)}{a}\\
\mathbf{else}:\\
\;\;\;\;x - \frac{y}{t\_1}\\
\end{array}
\end{array}
herbie shell --seed 2024096
(FPCore (x y z t a)
:name "Optimisation.CirclePacking:place from circle-packing-0.1.0.4, F"
:precision binary64
:alt
(if (< y -1.0761266216389975e-10) (- x (/ 1.0 (/ (/ a (- z t)) y))) (if (< y 2.894426862792089e-49) (- x (/ (* y (- z t)) a)) (- x (/ y (/ a (- z t))))))
(- x (/ (* y (- z t)) a)))