
(FPCore (x y z t a) :precision binary64 (+ x (/ (* (- y x) (- z t)) (- a t))))
double code(double x, double y, double z, double t, double a) {
return x + (((y - x) * (z - t)) / (a - t));
}
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 - x) * (z - t)) / (a - t))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + (((y - x) * (z - t)) / (a - t));
}
def code(x, y, z, t, a): return x + (((y - x) * (z - t)) / (a - t))
function code(x, y, z, t, a) return Float64(x + Float64(Float64(Float64(y - x) * Float64(z - t)) / Float64(a - t))) end
function tmp = code(x, y, z, t, a) tmp = x + (((y - x) * (z - t)) / (a - t)); end
code[x_, y_, z_, t_, a_] := N[(x + N[(N[(N[(y - x), $MachinePrecision] * N[(z - t), $MachinePrecision]), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 18 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a) :precision binary64 (+ x (/ (* (- y x) (- z t)) (- a t))))
double code(double x, double y, double z, double t, double a) {
return x + (((y - x) * (z - t)) / (a - t));
}
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 - x) * (z - t)) / (a - t))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + (((y - x) * (z - t)) / (a - t));
}
def code(x, y, z, t, a): return x + (((y - x) * (z - t)) / (a - t))
function code(x, y, z, t, a) return Float64(x + Float64(Float64(Float64(y - x) * Float64(z - t)) / Float64(a - t))) end
function tmp = code(x, y, z, t, a) tmp = x + (((y - x) * (z - t)) / (a - t)); end
code[x_, y_, z_, t_, a_] := N[(x + N[(N[(N[(y - x), $MachinePrecision] * N[(z - t), $MachinePrecision]), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}
\end{array}
(FPCore (x y z t a) :precision binary64 (if (or (<= a -5.8e-84) (not (<= a 1.1e-100))) (fma (- y x) (/ (- t z) (- t a)) x) (+ y (* (/ (- z a) t) (- x y)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -5.8e-84) || !(a <= 1.1e-100)) {
tmp = fma((y - x), ((t - z) / (t - a)), x);
} else {
tmp = y + (((z - a) / t) * (x - y));
}
return tmp;
}
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -5.8e-84) || !(a <= 1.1e-100)) tmp = fma(Float64(y - x), Float64(Float64(t - z) / Float64(t - a)), x); else tmp = Float64(y + Float64(Float64(Float64(z - a) / t) * Float64(x - y))); end return tmp end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -5.8e-84], N[Not[LessEqual[a, 1.1e-100]], $MachinePrecision]], N[(N[(y - x), $MachinePrecision] * N[(N[(t - z), $MachinePrecision] / N[(t - a), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision], N[(y + N[(N[(N[(z - a), $MachinePrecision] / t), $MachinePrecision] * N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -5.8 \cdot 10^{-84} \lor \neg \left(a \leq 1.1 \cdot 10^{-100}\right):\\
\;\;\;\;\mathsf{fma}\left(y - x, \frac{t - z}{t - a}, x\right)\\
\mathbf{else}:\\
\;\;\;\;y + \frac{z - a}{t} \cdot \left(x - y\right)\\
\end{array}
\end{array}
if a < -5.80000000000000038e-84 or 1.09999999999999995e-100 < a Initial program 72.4%
+-commutative72.4%
associate-/l*89.6%
fma-define89.6%
Simplified89.6%
if -5.80000000000000038e-84 < a < 1.09999999999999995e-100Initial program 54.1%
clear-num54.0%
inv-pow54.0%
*-commutative54.0%
associate-/r*62.4%
Applied egg-rr62.4%
unpow-162.4%
associate-/l/54.0%
*-commutative54.0%
Simplified54.0%
Taylor expanded in t around inf 84.0%
associate--l+84.0%
associate-*r/84.0%
associate-*r/84.0%
mul-1-neg84.0%
div-sub85.3%
mul-1-neg85.3%
distribute-lft-out--85.3%
associate-*r/85.3%
mul-1-neg85.3%
distribute-rgt-out--85.3%
Simplified85.3%
Taylor expanded in t around inf 85.3%
mul-1-neg85.3%
associate-*r/88.4%
sub-neg88.4%
Simplified88.4%
Final simplification89.2%
(FPCore (x y z t a)
:precision binary64
(if (or (<= y -3.2e+130) (not (<= y 180.0)))
(+ x (* y (/ (- t z) (- t a))))
(*
x
(+
(+ 1.0 (/ t (- a t)))
(+ (/ (* y (- t z)) (* x (- t a))) (/ z (- t a)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -3.2e+130) || !(y <= 180.0)) {
tmp = x + (y * ((t - z) / (t - a)));
} else {
tmp = x * ((1.0 + (t / (a - t))) + (((y * (t - z)) / (x * (t - a))) + (z / (t - 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 <= (-3.2d+130)) .or. (.not. (y <= 180.0d0))) then
tmp = x + (y * ((t - z) / (t - a)))
else
tmp = x * ((1.0d0 + (t / (a - t))) + (((y * (t - z)) / (x * (t - a))) + (z / (t - 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 <= -3.2e+130) || !(y <= 180.0)) {
tmp = x + (y * ((t - z) / (t - a)));
} else {
tmp = x * ((1.0 + (t / (a - t))) + (((y * (t - z)) / (x * (t - a))) + (z / (t - a))));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (y <= -3.2e+130) or not (y <= 180.0): tmp = x + (y * ((t - z) / (t - a))) else: tmp = x * ((1.0 + (t / (a - t))) + (((y * (t - z)) / (x * (t - a))) + (z / (t - a)))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((y <= -3.2e+130) || !(y <= 180.0)) tmp = Float64(x + Float64(y * Float64(Float64(t - z) / Float64(t - a)))); else tmp = Float64(x * Float64(Float64(1.0 + Float64(t / Float64(a - t))) + Float64(Float64(Float64(y * Float64(t - z)) / Float64(x * Float64(t - a))) + Float64(z / Float64(t - a))))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((y <= -3.2e+130) || ~((y <= 180.0))) tmp = x + (y * ((t - z) / (t - a))); else tmp = x * ((1.0 + (t / (a - t))) + (((y * (t - z)) / (x * (t - a))) + (z / (t - a)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[y, -3.2e+130], N[Not[LessEqual[y, 180.0]], $MachinePrecision]], N[(x + N[(y * N[(N[(t - z), $MachinePrecision] / N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[(1.0 + N[(t / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(y * N[(t - z), $MachinePrecision]), $MachinePrecision] / N[(x * N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(z / N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.2 \cdot 10^{+130} \lor \neg \left(y \leq 180\right):\\
\;\;\;\;x + y \cdot \frac{t - z}{t - a}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(\left(1 + \frac{t}{a - t}\right) + \left(\frac{y \cdot \left(t - z\right)}{x \cdot \left(t - a\right)} + \frac{z}{t - a}\right)\right)\\
\end{array}
\end{array}
if y < -3.2e130 or 180 < y Initial program 61.6%
Taylor expanded in y around inf 59.4%
associate-/l*85.8%
Simplified85.8%
if -3.2e130 < y < 180Initial program 68.5%
Taylor expanded in x around -inf 82.5%
Final simplification83.7%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (/ (* (- x y) (- t z)) (- a t))))
(t_2 (+ x (* y (/ (- t z) (- t a))))))
(if (<= a -1.15e+115)
t_2
(if (<= a -4.8e-64)
t_1
(if (<= a 8.5e-100)
(+ y (* (/ (- z a) t) (- x y)))
(if (<= a 2.5e+177) t_1 t_2))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (((x - y) * (t - z)) / (a - t));
double t_2 = x + (y * ((t - z) / (t - a)));
double tmp;
if (a <= -1.15e+115) {
tmp = t_2;
} else if (a <= -4.8e-64) {
tmp = t_1;
} else if (a <= 8.5e-100) {
tmp = y + (((z - a) / t) * (x - y));
} else if (a <= 2.5e+177) {
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 = x + (((x - y) * (t - z)) / (a - t))
t_2 = x + (y * ((t - z) / (t - a)))
if (a <= (-1.15d+115)) then
tmp = t_2
else if (a <= (-4.8d-64)) then
tmp = t_1
else if (a <= 8.5d-100) then
tmp = y + (((z - a) / t) * (x - y))
else if (a <= 2.5d+177) 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 = x + (((x - y) * (t - z)) / (a - t));
double t_2 = x + (y * ((t - z) / (t - a)));
double tmp;
if (a <= -1.15e+115) {
tmp = t_2;
} else if (a <= -4.8e-64) {
tmp = t_1;
} else if (a <= 8.5e-100) {
tmp = y + (((z - a) / t) * (x - y));
} else if (a <= 2.5e+177) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + (((x - y) * (t - z)) / (a - t)) t_2 = x + (y * ((t - z) / (t - a))) tmp = 0 if a <= -1.15e+115: tmp = t_2 elif a <= -4.8e-64: tmp = t_1 elif a <= 8.5e-100: tmp = y + (((z - a) / t) * (x - y)) elif a <= 2.5e+177: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(Float64(x - y) * Float64(t - z)) / Float64(a - t))) t_2 = Float64(x + Float64(y * Float64(Float64(t - z) / Float64(t - a)))) tmp = 0.0 if (a <= -1.15e+115) tmp = t_2; elseif (a <= -4.8e-64) tmp = t_1; elseif (a <= 8.5e-100) tmp = Float64(y + Float64(Float64(Float64(z - a) / t) * Float64(x - y))); elseif (a <= 2.5e+177) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + (((x - y) * (t - z)) / (a - t)); t_2 = x + (y * ((t - z) / (t - a))); tmp = 0.0; if (a <= -1.15e+115) tmp = t_2; elseif (a <= -4.8e-64) tmp = t_1; elseif (a <= 8.5e-100) tmp = y + (((z - a) / t) * (x - y)); elseif (a <= 2.5e+177) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(N[(x - y), $MachinePrecision] * N[(t - z), $MachinePrecision]), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(y * N[(N[(t - z), $MachinePrecision] / N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -1.15e+115], t$95$2, If[LessEqual[a, -4.8e-64], t$95$1, If[LessEqual[a, 8.5e-100], N[(y + N[(N[(N[(z - a), $MachinePrecision] / t), $MachinePrecision] * N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 2.5e+177], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{\left(x - y\right) \cdot \left(t - z\right)}{a - t}\\
t_2 := x + y \cdot \frac{t - z}{t - a}\\
\mathbf{if}\;a \leq -1.15 \cdot 10^{+115}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;a \leq -4.8 \cdot 10^{-64}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq 8.5 \cdot 10^{-100}:\\
\;\;\;\;y + \frac{z - a}{t} \cdot \left(x - y\right)\\
\mathbf{elif}\;a \leq 2.5 \cdot 10^{+177}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if a < -1.15000000000000002e115 or 2.5000000000000001e177 < a Initial program 64.9%
Taylor expanded in y around inf 73.0%
associate-/l*91.8%
Simplified91.8%
if -1.15000000000000002e115 < a < -4.79999999999999997e-64 or 8.50000000000000017e-100 < a < 2.5000000000000001e177Initial program 79.9%
if -4.79999999999999997e-64 < a < 8.50000000000000017e-100Initial program 53.5%
clear-num53.4%
inv-pow53.4%
*-commutative53.4%
associate-/r*62.4%
Applied egg-rr62.4%
unpow-162.4%
associate-/l/53.4%
*-commutative53.4%
Simplified53.4%
Taylor expanded in t around inf 82.8%
associate--l+82.8%
associate-*r/82.8%
associate-*r/82.8%
mul-1-neg82.8%
div-sub84.0%
mul-1-neg84.0%
distribute-lft-out--84.0%
associate-*r/84.0%
mul-1-neg84.0%
distribute-rgt-out--84.0%
Simplified84.0%
Taylor expanded in t around inf 84.0%
mul-1-neg84.0%
associate-*r/87.0%
sub-neg87.0%
Simplified87.0%
Final simplification85.8%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* x (/ (- z a) t))) (t_2 (+ x (* y (/ z a)))))
(if (<= a -5.6e-63)
t_2
(if (<= a -6.5e-124)
t_1
(if (<= a -3.4e-165)
y
(if (<= a 4.3e-298) t_1 (if (<= a 7e-99) y t_2)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x * ((z - a) / t);
double t_2 = x + (y * (z / a));
double tmp;
if (a <= -5.6e-63) {
tmp = t_2;
} else if (a <= -6.5e-124) {
tmp = t_1;
} else if (a <= -3.4e-165) {
tmp = y;
} else if (a <= 4.3e-298) {
tmp = t_1;
} else if (a <= 7e-99) {
tmp = y;
} 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 = x * ((z - a) / t)
t_2 = x + (y * (z / a))
if (a <= (-5.6d-63)) then
tmp = t_2
else if (a <= (-6.5d-124)) then
tmp = t_1
else if (a <= (-3.4d-165)) then
tmp = y
else if (a <= 4.3d-298) then
tmp = t_1
else if (a <= 7d-99) then
tmp = y
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 = x * ((z - a) / t);
double t_2 = x + (y * (z / a));
double tmp;
if (a <= -5.6e-63) {
tmp = t_2;
} else if (a <= -6.5e-124) {
tmp = t_1;
} else if (a <= -3.4e-165) {
tmp = y;
} else if (a <= 4.3e-298) {
tmp = t_1;
} else if (a <= 7e-99) {
tmp = y;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x * ((z - a) / t) t_2 = x + (y * (z / a)) tmp = 0 if a <= -5.6e-63: tmp = t_2 elif a <= -6.5e-124: tmp = t_1 elif a <= -3.4e-165: tmp = y elif a <= 4.3e-298: tmp = t_1 elif a <= 7e-99: tmp = y else: tmp = t_2 return tmp
function code(x, y, z, t, a) t_1 = Float64(x * Float64(Float64(z - a) / t)) t_2 = Float64(x + Float64(y * Float64(z / a))) tmp = 0.0 if (a <= -5.6e-63) tmp = t_2; elseif (a <= -6.5e-124) tmp = t_1; elseif (a <= -3.4e-165) tmp = y; elseif (a <= 4.3e-298) tmp = t_1; elseif (a <= 7e-99) tmp = y; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x * ((z - a) / t); t_2 = x + (y * (z / a)); tmp = 0.0; if (a <= -5.6e-63) tmp = t_2; elseif (a <= -6.5e-124) tmp = t_1; elseif (a <= -3.4e-165) tmp = y; elseif (a <= 4.3e-298) tmp = t_1; elseif (a <= 7e-99) tmp = y; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x * N[(N[(z - a), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(y * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -5.6e-63], t$95$2, If[LessEqual[a, -6.5e-124], t$95$1, If[LessEqual[a, -3.4e-165], y, If[LessEqual[a, 4.3e-298], t$95$1, If[LessEqual[a, 7e-99], y, t$95$2]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \frac{z - a}{t}\\
t_2 := x + y \cdot \frac{z}{a}\\
\mathbf{if}\;a \leq -5.6 \cdot 10^{-63}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;a \leq -6.5 \cdot 10^{-124}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq -3.4 \cdot 10^{-165}:\\
\;\;\;\;y\\
\mathbf{elif}\;a \leq 4.3 \cdot 10^{-298}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq 7 \cdot 10^{-99}:\\
\;\;\;\;y\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if a < -5.6000000000000005e-63 or 6.9999999999999997e-99 < a Initial program 73.3%
Taylor expanded in y around inf 67.4%
associate-/l*76.8%
Simplified76.8%
Taylor expanded in t around 0 60.0%
if -5.6000000000000005e-63 < a < -6.49999999999999988e-124 or -3.4e-165 < a < 4.3e-298Initial program 48.3%
clear-num48.2%
inv-pow48.2%
*-commutative48.2%
associate-/r*53.1%
Applied egg-rr53.1%
unpow-153.1%
associate-/l/48.2%
*-commutative48.2%
Simplified48.2%
Taylor expanded in t around inf 81.1%
associate--l+81.1%
associate-*r/81.1%
associate-*r/81.1%
mul-1-neg81.1%
div-sub83.5%
mul-1-neg83.5%
distribute-lft-out--83.5%
associate-*r/83.5%
mul-1-neg83.5%
distribute-rgt-out--83.5%
Simplified83.5%
Taylor expanded in y around 0 53.4%
associate-/l*53.3%
Simplified53.3%
if -6.49999999999999988e-124 < a < -3.4e-165 or 4.3e-298 < a < 6.9999999999999997e-99Initial program 57.3%
Taylor expanded in t around inf 50.1%
Final simplification56.8%
(FPCore (x y z t a)
:precision binary64
(if (<= a -6e-64)
x
(if (<= a 5.3e-298)
(* x (/ (- z a) t))
(if (<= a 1.35e-97) y (if (<= a 6.2e+46) (* z (/ (- y x) a)) x)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -6e-64) {
tmp = x;
} else if (a <= 5.3e-298) {
tmp = x * ((z - a) / t);
} else if (a <= 1.35e-97) {
tmp = y;
} else if (a <= 6.2e+46) {
tmp = z * ((y - x) / 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 (a <= (-6d-64)) then
tmp = x
else if (a <= 5.3d-298) then
tmp = x * ((z - a) / t)
else if (a <= 1.35d-97) then
tmp = y
else if (a <= 6.2d+46) then
tmp = z * ((y - x) / 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 (a <= -6e-64) {
tmp = x;
} else if (a <= 5.3e-298) {
tmp = x * ((z - a) / t);
} else if (a <= 1.35e-97) {
tmp = y;
} else if (a <= 6.2e+46) {
tmp = z * ((y - x) / a);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -6e-64: tmp = x elif a <= 5.3e-298: tmp = x * ((z - a) / t) elif a <= 1.35e-97: tmp = y elif a <= 6.2e+46: tmp = z * ((y - x) / a) else: tmp = x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -6e-64) tmp = x; elseif (a <= 5.3e-298) tmp = Float64(x * Float64(Float64(z - a) / t)); elseif (a <= 1.35e-97) tmp = y; elseif (a <= 6.2e+46) tmp = Float64(z * Float64(Float64(y - x) / a)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -6e-64) tmp = x; elseif (a <= 5.3e-298) tmp = x * ((z - a) / t); elseif (a <= 1.35e-97) tmp = y; elseif (a <= 6.2e+46) tmp = z * ((y - x) / a); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -6e-64], x, If[LessEqual[a, 5.3e-298], N[(x * N[(N[(z - a), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.35e-97], y, If[LessEqual[a, 6.2e+46], N[(z * N[(N[(y - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], x]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -6 \cdot 10^{-64}:\\
\;\;\;\;x\\
\mathbf{elif}\;a \leq 5.3 \cdot 10^{-298}:\\
\;\;\;\;x \cdot \frac{z - a}{t}\\
\mathbf{elif}\;a \leq 1.35 \cdot 10^{-97}:\\
\;\;\;\;y\\
\mathbf{elif}\;a \leq 6.2 \cdot 10^{+46}:\\
\;\;\;\;z \cdot \frac{y - x}{a}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if a < -6.0000000000000001e-64 or 6.1999999999999995e46 < a Initial program 70.9%
Taylor expanded in a around inf 49.3%
if -6.0000000000000001e-64 < a < 5.30000000000000002e-298Initial program 51.9%
clear-num51.8%
inv-pow51.8%
*-commutative51.8%
associate-/r*57.8%
Applied egg-rr57.8%
unpow-157.8%
associate-/l/51.8%
*-commutative51.8%
Simplified51.8%
Taylor expanded in t around inf 80.2%
associate--l+80.2%
associate-*r/80.2%
associate-*r/80.2%
mul-1-neg80.2%
div-sub82.5%
mul-1-neg82.5%
distribute-lft-out--82.5%
associate-*r/82.5%
mul-1-neg82.5%
distribute-rgt-out--82.5%
Simplified82.5%
Taylor expanded in y around 0 45.1%
associate-/l*45.0%
Simplified45.0%
if 5.30000000000000002e-298 < a < 1.34999999999999993e-97Initial program 55.1%
Taylor expanded in t around inf 48.1%
if 1.34999999999999993e-97 < a < 6.1999999999999995e46Initial program 83.9%
clear-num83.8%
inv-pow83.8%
*-commutative83.8%
associate-/r*86.8%
Applied egg-rr86.8%
unpow-186.8%
associate-/l/83.8%
*-commutative83.8%
Simplified83.8%
Taylor expanded in z around -inf 49.6%
Taylor expanded in a around inf 42.9%
associate-/l*43.0%
Simplified43.0%
Final simplification47.5%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* z (/ y a)))))
(if (<= a -2.4e-61)
t_1
(if (<= a 1.15e-293) (* x (/ (- z a) t)) (if (<= a 4.1e-97) y t_1)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (z * (y / a));
double tmp;
if (a <= -2.4e-61) {
tmp = t_1;
} else if (a <= 1.15e-293) {
tmp = x * ((z - a) / t);
} else if (a <= 4.1e-97) {
tmp = y;
} 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 = x + (z * (y / a))
if (a <= (-2.4d-61)) then
tmp = t_1
else if (a <= 1.15d-293) then
tmp = x * ((z - a) / t)
else if (a <= 4.1d-97) then
tmp = y
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 = x + (z * (y / a));
double tmp;
if (a <= -2.4e-61) {
tmp = t_1;
} else if (a <= 1.15e-293) {
tmp = x * ((z - a) / t);
} else if (a <= 4.1e-97) {
tmp = y;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + (z * (y / a)) tmp = 0 if a <= -2.4e-61: tmp = t_1 elif a <= 1.15e-293: tmp = x * ((z - a) / t) elif a <= 4.1e-97: tmp = y else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(z * Float64(y / a))) tmp = 0.0 if (a <= -2.4e-61) tmp = t_1; elseif (a <= 1.15e-293) tmp = Float64(x * Float64(Float64(z - a) / t)); elseif (a <= 4.1e-97) tmp = y; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + (z * (y / a)); tmp = 0.0; if (a <= -2.4e-61) tmp = t_1; elseif (a <= 1.15e-293) tmp = x * ((z - a) / t); elseif (a <= 4.1e-97) tmp = y; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(z * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -2.4e-61], t$95$1, If[LessEqual[a, 1.15e-293], N[(x * N[(N[(z - a), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 4.1e-97], y, t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + z \cdot \frac{y}{a}\\
\mathbf{if}\;a \leq -2.4 \cdot 10^{-61}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq 1.15 \cdot 10^{-293}:\\
\;\;\;\;x \cdot \frac{z - a}{t}\\
\mathbf{elif}\;a \leq 4.1 \cdot 10^{-97}:\\
\;\;\;\;y\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if a < -2.4000000000000001e-61 or 4.09999999999999993e-97 < a Initial program 73.3%
Taylor expanded in t around 0 60.3%
associate-/l*68.0%
Simplified68.0%
Taylor expanded in y around inf 60.6%
if -2.4000000000000001e-61 < a < 1.14999999999999998e-293Initial program 51.9%
clear-num51.8%
inv-pow51.8%
*-commutative51.8%
associate-/r*57.8%
Applied egg-rr57.8%
unpow-157.8%
associate-/l/51.8%
*-commutative51.8%
Simplified51.8%
Taylor expanded in t around inf 80.2%
associate--l+80.2%
associate-*r/80.2%
associate-*r/80.2%
mul-1-neg80.2%
div-sub82.5%
mul-1-neg82.5%
distribute-lft-out--82.5%
associate-*r/82.5%
mul-1-neg82.5%
distribute-rgt-out--82.5%
Simplified82.5%
Taylor expanded in y around 0 45.1%
associate-/l*45.0%
Simplified45.0%
if 1.14999999999999998e-293 < a < 4.09999999999999993e-97Initial program 55.1%
Taylor expanded in t around inf 48.1%
Final simplification55.3%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* z (/ y a)))))
(if (<= a -4e-64)
t_1
(if (<= a 3.1e-295) (/ (* x (- z a)) t) (if (<= a 5.8e-101) y t_1)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (z * (y / a));
double tmp;
if (a <= -4e-64) {
tmp = t_1;
} else if (a <= 3.1e-295) {
tmp = (x * (z - a)) / t;
} else if (a <= 5.8e-101) {
tmp = y;
} 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 = x + (z * (y / a))
if (a <= (-4d-64)) then
tmp = t_1
else if (a <= 3.1d-295) then
tmp = (x * (z - a)) / t
else if (a <= 5.8d-101) then
tmp = y
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 = x + (z * (y / a));
double tmp;
if (a <= -4e-64) {
tmp = t_1;
} else if (a <= 3.1e-295) {
tmp = (x * (z - a)) / t;
} else if (a <= 5.8e-101) {
tmp = y;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + (z * (y / a)) tmp = 0 if a <= -4e-64: tmp = t_1 elif a <= 3.1e-295: tmp = (x * (z - a)) / t elif a <= 5.8e-101: tmp = y else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(z * Float64(y / a))) tmp = 0.0 if (a <= -4e-64) tmp = t_1; elseif (a <= 3.1e-295) tmp = Float64(Float64(x * Float64(z - a)) / t); elseif (a <= 5.8e-101) tmp = y; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + (z * (y / a)); tmp = 0.0; if (a <= -4e-64) tmp = t_1; elseif (a <= 3.1e-295) tmp = (x * (z - a)) / t; elseif (a <= 5.8e-101) tmp = y; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(z * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -4e-64], t$95$1, If[LessEqual[a, 3.1e-295], N[(N[(x * N[(z - a), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[a, 5.8e-101], y, t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + z \cdot \frac{y}{a}\\
\mathbf{if}\;a \leq -4 \cdot 10^{-64}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq 3.1 \cdot 10^{-295}:\\
\;\;\;\;\frac{x \cdot \left(z - a\right)}{t}\\
\mathbf{elif}\;a \leq 5.8 \cdot 10^{-101}:\\
\;\;\;\;y\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if a < -3.99999999999999986e-64 or 5.800000000000001e-101 < a Initial program 73.3%
Taylor expanded in t around 0 60.3%
associate-/l*68.0%
Simplified68.0%
Taylor expanded in y around inf 60.6%
if -3.99999999999999986e-64 < a < 3.1000000000000002e-295Initial program 51.9%
clear-num51.8%
inv-pow51.8%
*-commutative51.8%
associate-/r*57.8%
Applied egg-rr57.8%
unpow-157.8%
associate-/l/51.8%
*-commutative51.8%
Simplified51.8%
Taylor expanded in t around inf 80.2%
associate--l+80.2%
associate-*r/80.2%
associate-*r/80.2%
mul-1-neg80.2%
div-sub82.5%
mul-1-neg82.5%
distribute-lft-out--82.5%
associate-*r/82.5%
mul-1-neg82.5%
distribute-rgt-out--82.5%
Simplified82.5%
Taylor expanded in y around 0 45.1%
if 3.1000000000000002e-295 < a < 5.800000000000001e-101Initial program 55.1%
Taylor expanded in t around inf 48.1%
Final simplification55.4%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* z (/ y a)))))
(if (<= a -2.3e-80)
t_1
(if (<= a 9e-221) (* z (/ (- x y) t)) (if (<= a 3.1e-103) y t_1)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (z * (y / a));
double tmp;
if (a <= -2.3e-80) {
tmp = t_1;
} else if (a <= 9e-221) {
tmp = z * ((x - y) / t);
} else if (a <= 3.1e-103) {
tmp = y;
} 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 = x + (z * (y / a))
if (a <= (-2.3d-80)) then
tmp = t_1
else if (a <= 9d-221) then
tmp = z * ((x - y) / t)
else if (a <= 3.1d-103) then
tmp = y
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 = x + (z * (y / a));
double tmp;
if (a <= -2.3e-80) {
tmp = t_1;
} else if (a <= 9e-221) {
tmp = z * ((x - y) / t);
} else if (a <= 3.1e-103) {
tmp = y;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + (z * (y / a)) tmp = 0 if a <= -2.3e-80: tmp = t_1 elif a <= 9e-221: tmp = z * ((x - y) / t) elif a <= 3.1e-103: tmp = y else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(z * Float64(y / a))) tmp = 0.0 if (a <= -2.3e-80) tmp = t_1; elseif (a <= 9e-221) tmp = Float64(z * Float64(Float64(x - y) / t)); elseif (a <= 3.1e-103) tmp = y; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + (z * (y / a)); tmp = 0.0; if (a <= -2.3e-80) tmp = t_1; elseif (a <= 9e-221) tmp = z * ((x - y) / t); elseif (a <= 3.1e-103) tmp = y; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(z * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -2.3e-80], t$95$1, If[LessEqual[a, 9e-221], N[(z * N[(N[(x - y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 3.1e-103], y, t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + z \cdot \frac{y}{a}\\
\mathbf{if}\;a \leq -2.3 \cdot 10^{-80}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq 9 \cdot 10^{-221}:\\
\;\;\;\;z \cdot \frac{x - y}{t}\\
\mathbf{elif}\;a \leq 3.1 \cdot 10^{-103}:\\
\;\;\;\;y\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if a < -2.2999999999999998e-80 or 3.1000000000000001e-103 < a Initial program 72.4%
Taylor expanded in t around 0 59.7%
associate-/l*67.2%
Simplified67.2%
Taylor expanded in y around inf 59.5%
if -2.2999999999999998e-80 < a < 9.00000000000000052e-221Initial program 55.7%
clear-num55.6%
inv-pow55.6%
*-commutative55.6%
associate-/r*61.6%
Applied egg-rr61.6%
unpow-161.6%
associate-/l/55.6%
*-commutative55.6%
Simplified55.6%
Taylor expanded in z around -inf 57.8%
Taylor expanded in a around 0 53.4%
mul-1-neg53.4%
associate-/l*54.2%
distribute-lft-neg-in54.2%
Simplified54.2%
if 9.00000000000000052e-221 < a < 3.1000000000000001e-103Initial program 50.3%
Taylor expanded in t around inf 57.5%
Final simplification57.9%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -1.35e-80) (not (<= a 4.5e-101))) (+ x (* y (/ (- t z) (- t a)))) (+ y (* z (/ (- x y) t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -1.35e-80) || !(a <= 4.5e-101)) {
tmp = x + (y * ((t - z) / (t - a)));
} else {
tmp = y + (z * ((x - y) / t));
}
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 ((a <= (-1.35d-80)) .or. (.not. (a <= 4.5d-101))) then
tmp = x + (y * ((t - z) / (t - a)))
else
tmp = y + (z * ((x - y) / t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -1.35e-80) || !(a <= 4.5e-101)) {
tmp = x + (y * ((t - z) / (t - a)));
} else {
tmp = y + (z * ((x - y) / t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -1.35e-80) or not (a <= 4.5e-101): tmp = x + (y * ((t - z) / (t - a))) else: tmp = y + (z * ((x - y) / t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -1.35e-80) || !(a <= 4.5e-101)) tmp = Float64(x + Float64(y * Float64(Float64(t - z) / Float64(t - a)))); else tmp = Float64(y + Float64(z * Float64(Float64(x - y) / t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a <= -1.35e-80) || ~((a <= 4.5e-101))) tmp = x + (y * ((t - z) / (t - a))); else tmp = y + (z * ((x - y) / t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -1.35e-80], N[Not[LessEqual[a, 4.5e-101]], $MachinePrecision]], N[(x + N[(y * N[(N[(t - z), $MachinePrecision] / N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y + N[(z * N[(N[(x - y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.35 \cdot 10^{-80} \lor \neg \left(a \leq 4.5 \cdot 10^{-101}\right):\\
\;\;\;\;x + y \cdot \frac{t - z}{t - a}\\
\mathbf{else}:\\
\;\;\;\;y + z \cdot \frac{x - y}{t}\\
\end{array}
\end{array}
if a < -1.3500000000000001e-80 or 4.4999999999999998e-101 < a Initial program 72.4%
Taylor expanded in y around inf 66.1%
associate-/l*75.8%
Simplified75.8%
if -1.3500000000000001e-80 < a < 4.4999999999999998e-101Initial program 54.1%
clear-num54.0%
inv-pow54.0%
*-commutative54.0%
associate-/r*62.4%
Applied egg-rr62.4%
unpow-162.4%
associate-/l/54.0%
*-commutative54.0%
Simplified54.0%
Taylor expanded in t around inf 84.0%
associate--l+84.0%
associate-*r/84.0%
associate-*r/84.0%
mul-1-neg84.0%
div-sub85.3%
mul-1-neg85.3%
distribute-lft-out--85.3%
associate-*r/85.3%
mul-1-neg85.3%
distribute-rgt-out--85.3%
Simplified85.3%
Taylor expanded in a around 0 81.4%
associate-/l*85.2%
Simplified85.2%
Final simplification79.2%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -7.8e-62) (not (<= a 1.55e-95))) (+ x (* y (/ (- t z) (- t a)))) (+ y (* (/ (- z a) t) (- x y)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -7.8e-62) || !(a <= 1.55e-95)) {
tmp = x + (y * ((t - z) / (t - a)));
} else {
tmp = y + (((z - a) / t) * (x - y));
}
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 ((a <= (-7.8d-62)) .or. (.not. (a <= 1.55d-95))) then
tmp = x + (y * ((t - z) / (t - a)))
else
tmp = y + (((z - a) / t) * (x - y))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -7.8e-62) || !(a <= 1.55e-95)) {
tmp = x + (y * ((t - z) / (t - a)));
} else {
tmp = y + (((z - a) / t) * (x - y));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -7.8e-62) or not (a <= 1.55e-95): tmp = x + (y * ((t - z) / (t - a))) else: tmp = y + (((z - a) / t) * (x - y)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -7.8e-62) || !(a <= 1.55e-95)) tmp = Float64(x + Float64(y * Float64(Float64(t - z) / Float64(t - a)))); else tmp = Float64(y + Float64(Float64(Float64(z - a) / t) * Float64(x - y))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a <= -7.8e-62) || ~((a <= 1.55e-95))) tmp = x + (y * ((t - z) / (t - a))); else tmp = y + (((z - a) / t) * (x - y)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -7.8e-62], N[Not[LessEqual[a, 1.55e-95]], $MachinePrecision]], N[(x + N[(y * N[(N[(t - z), $MachinePrecision] / N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y + N[(N[(N[(z - a), $MachinePrecision] / t), $MachinePrecision] * N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -7.8 \cdot 10^{-62} \lor \neg \left(a \leq 1.55 \cdot 10^{-95}\right):\\
\;\;\;\;x + y \cdot \frac{t - z}{t - a}\\
\mathbf{else}:\\
\;\;\;\;y + \frac{z - a}{t} \cdot \left(x - y\right)\\
\end{array}
\end{array}
if a < -7.8000000000000007e-62 or 1.54999999999999996e-95 < a Initial program 73.3%
Taylor expanded in y around inf 67.4%
associate-/l*76.8%
Simplified76.8%
if -7.8000000000000007e-62 < a < 1.54999999999999996e-95Initial program 53.5%
clear-num53.4%
inv-pow53.4%
*-commutative53.4%
associate-/r*62.4%
Applied egg-rr62.4%
unpow-162.4%
associate-/l/53.4%
*-commutative53.4%
Simplified53.4%
Taylor expanded in t around inf 82.8%
associate--l+82.8%
associate-*r/82.8%
associate-*r/82.8%
mul-1-neg82.8%
div-sub84.0%
mul-1-neg84.0%
distribute-lft-out--84.0%
associate-*r/84.0%
mul-1-neg84.0%
distribute-rgt-out--84.0%
Simplified84.0%
Taylor expanded in t around inf 84.0%
mul-1-neg84.0%
associate-*r/87.0%
sub-neg87.0%
Simplified87.0%
Final simplification80.6%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -2.5e-61) (not (<= a 2.6e-57))) (+ x (* z (/ y a))) (* y (- 1.0 (/ (- z a) t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -2.5e-61) || !(a <= 2.6e-57)) {
tmp = x + (z * (y / a));
} else {
tmp = y * (1.0 - ((z - a) / t));
}
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 ((a <= (-2.5d-61)) .or. (.not. (a <= 2.6d-57))) then
tmp = x + (z * (y / a))
else
tmp = y * (1.0d0 - ((z - a) / t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -2.5e-61) || !(a <= 2.6e-57)) {
tmp = x + (z * (y / a));
} else {
tmp = y * (1.0 - ((z - a) / t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -2.5e-61) or not (a <= 2.6e-57): tmp = x + (z * (y / a)) else: tmp = y * (1.0 - ((z - a) / t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -2.5e-61) || !(a <= 2.6e-57)) tmp = Float64(x + Float64(z * Float64(y / a))); else tmp = Float64(y * Float64(1.0 - Float64(Float64(z - a) / t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a <= -2.5e-61) || ~((a <= 2.6e-57))) tmp = x + (z * (y / a)); else tmp = y * (1.0 - ((z - a) / t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -2.5e-61], N[Not[LessEqual[a, 2.6e-57]], $MachinePrecision]], N[(x + N[(z * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y * N[(1.0 - N[(N[(z - a), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -2.5 \cdot 10^{-61} \lor \neg \left(a \leq 2.6 \cdot 10^{-57}\right):\\
\;\;\;\;x + z \cdot \frac{y}{a}\\
\mathbf{else}:\\
\;\;\;\;y \cdot \left(1 - \frac{z - a}{t}\right)\\
\end{array}
\end{array}
if a < -2.4999999999999999e-61 or 2.59999999999999985e-57 < a Initial program 73.1%
Taylor expanded in t around 0 60.1%
associate-/l*68.1%
Simplified68.1%
Taylor expanded in y around inf 61.2%
if -2.4999999999999999e-61 < a < 2.59999999999999985e-57Initial program 54.9%
clear-num54.8%
inv-pow54.8%
*-commutative54.8%
associate-/r*64.3%
Applied egg-rr64.3%
unpow-164.3%
associate-/l/54.8%
*-commutative54.8%
Simplified54.8%
Taylor expanded in t around inf 79.9%
associate--l+79.9%
associate-*r/79.9%
associate-*r/79.9%
mul-1-neg79.9%
div-sub81.0%
mul-1-neg81.0%
distribute-lft-out--81.0%
associate-*r/81.0%
mul-1-neg81.0%
distribute-rgt-out--81.0%
Simplified81.0%
Taylor expanded in y around -inf 60.0%
mul-1-neg60.0%
unsub-neg60.0%
Simplified60.0%
Final simplification60.7%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -9e-61) (not (<= a 2.6e-57))) (+ x (* y (/ (- z t) a))) (* y (- 1.0 (/ (- z a) t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -9e-61) || !(a <= 2.6e-57)) {
tmp = x + (y * ((z - t) / a));
} else {
tmp = y * (1.0 - ((z - a) / t));
}
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 ((a <= (-9d-61)) .or. (.not. (a <= 2.6d-57))) then
tmp = x + (y * ((z - t) / a))
else
tmp = y * (1.0d0 - ((z - a) / t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -9e-61) || !(a <= 2.6e-57)) {
tmp = x + (y * ((z - t) / a));
} else {
tmp = y * (1.0 - ((z - a) / t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -9e-61) or not (a <= 2.6e-57): tmp = x + (y * ((z - t) / a)) else: tmp = y * (1.0 - ((z - a) / t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -9e-61) || !(a <= 2.6e-57)) tmp = Float64(x + Float64(y * Float64(Float64(z - t) / a))); else tmp = Float64(y * Float64(1.0 - Float64(Float64(z - a) / t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a <= -9e-61) || ~((a <= 2.6e-57))) tmp = x + (y * ((z - t) / a)); else tmp = y * (1.0 - ((z - a) / t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -9e-61], N[Not[LessEqual[a, 2.6e-57]], $MachinePrecision]], N[(x + N[(y * N[(N[(z - t), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y * N[(1.0 - N[(N[(z - a), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -9 \cdot 10^{-61} \lor \neg \left(a \leq 2.6 \cdot 10^{-57}\right):\\
\;\;\;\;x + y \cdot \frac{z - t}{a}\\
\mathbf{else}:\\
\;\;\;\;y \cdot \left(1 - \frac{z - a}{t}\right)\\
\end{array}
\end{array}
if a < -9e-61 or 2.59999999999999985e-57 < a Initial program 73.1%
Taylor expanded in y around inf 67.6%
associate-/l*76.7%
Simplified76.7%
Taylor expanded in a around inf 61.1%
associate-/l*66.9%
Simplified66.9%
if -9e-61 < a < 2.59999999999999985e-57Initial program 54.9%
clear-num54.8%
inv-pow54.8%
*-commutative54.8%
associate-/r*64.3%
Applied egg-rr64.3%
unpow-164.3%
associate-/l/54.8%
*-commutative54.8%
Simplified54.8%
Taylor expanded in t around inf 79.9%
associate--l+79.9%
associate-*r/79.9%
associate-*r/79.9%
mul-1-neg79.9%
div-sub81.0%
mul-1-neg81.0%
distribute-lft-out--81.0%
associate-*r/81.0%
mul-1-neg81.0%
distribute-rgt-out--81.0%
Simplified81.0%
Taylor expanded in y around -inf 60.0%
mul-1-neg60.0%
unsub-neg60.0%
Simplified60.0%
Final simplification64.2%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -1.16e-86) (not (<= a 8.5e-96))) (+ x (* z (/ (- y x) a))) (* y (- 1.0 (/ (- z a) t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -1.16e-86) || !(a <= 8.5e-96)) {
tmp = x + (z * ((y - x) / a));
} else {
tmp = y * (1.0 - ((z - a) / t));
}
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 ((a <= (-1.16d-86)) .or. (.not. (a <= 8.5d-96))) then
tmp = x + (z * ((y - x) / a))
else
tmp = y * (1.0d0 - ((z - a) / t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -1.16e-86) || !(a <= 8.5e-96)) {
tmp = x + (z * ((y - x) / a));
} else {
tmp = y * (1.0 - ((z - a) / t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -1.16e-86) or not (a <= 8.5e-96): tmp = x + (z * ((y - x) / a)) else: tmp = y * (1.0 - ((z - a) / t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -1.16e-86) || !(a <= 8.5e-96)) tmp = Float64(x + Float64(z * Float64(Float64(y - x) / a))); else tmp = Float64(y * Float64(1.0 - Float64(Float64(z - a) / t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a <= -1.16e-86) || ~((a <= 8.5e-96))) tmp = x + (z * ((y - x) / a)); else tmp = y * (1.0 - ((z - a) / t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -1.16e-86], N[Not[LessEqual[a, 8.5e-96]], $MachinePrecision]], N[(x + N[(z * N[(N[(y - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y * N[(1.0 - N[(N[(z - a), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.16 \cdot 10^{-86} \lor \neg \left(a \leq 8.5 \cdot 10^{-96}\right):\\
\;\;\;\;x + z \cdot \frac{y - x}{a}\\
\mathbf{else}:\\
\;\;\;\;y \cdot \left(1 - \frac{z - a}{t}\right)\\
\end{array}
\end{array}
if a < -1.16e-86 or 8.49999999999999983e-96 < a Initial program 72.7%
Taylor expanded in t around 0 59.6%
associate-/l*67.0%
Simplified67.0%
if -1.16e-86 < a < 8.49999999999999983e-96Initial program 53.0%
clear-num53.0%
inv-pow52.9%
*-commutative52.9%
associate-/r*61.6%
Applied egg-rr61.6%
unpow-161.6%
associate-/l/53.0%
*-commutative53.0%
Simplified53.0%
Taylor expanded in t around inf 84.8%
associate--l+84.8%
associate-*r/84.8%
associate-*r/84.8%
mul-1-neg84.8%
div-sub85.0%
mul-1-neg85.0%
distribute-lft-out--85.0%
associate-*r/85.0%
mul-1-neg85.0%
distribute-rgt-out--85.0%
Simplified85.0%
Taylor expanded in y around -inf 61.1%
mul-1-neg61.1%
unsub-neg61.1%
Simplified61.1%
Final simplification64.9%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -2.7e-61) (not (<= a 1.55e-95))) (+ x (* z (/ (- y x) a))) (+ y (* z (/ (- x y) t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -2.7e-61) || !(a <= 1.55e-95)) {
tmp = x + (z * ((y - x) / a));
} else {
tmp = y + (z * ((x - y) / t));
}
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 ((a <= (-2.7d-61)) .or. (.not. (a <= 1.55d-95))) then
tmp = x + (z * ((y - x) / a))
else
tmp = y + (z * ((x - y) / t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -2.7e-61) || !(a <= 1.55e-95)) {
tmp = x + (z * ((y - x) / a));
} else {
tmp = y + (z * ((x - y) / t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -2.7e-61) or not (a <= 1.55e-95): tmp = x + (z * ((y - x) / a)) else: tmp = y + (z * ((x - y) / t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -2.7e-61) || !(a <= 1.55e-95)) tmp = Float64(x + Float64(z * Float64(Float64(y - x) / a))); else tmp = Float64(y + Float64(z * Float64(Float64(x - y) / t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a <= -2.7e-61) || ~((a <= 1.55e-95))) tmp = x + (z * ((y - x) / a)); else tmp = y + (z * ((x - y) / t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -2.7e-61], N[Not[LessEqual[a, 1.55e-95]], $MachinePrecision]], N[(x + N[(z * N[(N[(y - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y + N[(z * N[(N[(x - y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -2.7 \cdot 10^{-61} \lor \neg \left(a \leq 1.55 \cdot 10^{-95}\right):\\
\;\;\;\;x + z \cdot \frac{y - x}{a}\\
\mathbf{else}:\\
\;\;\;\;y + z \cdot \frac{x - y}{t}\\
\end{array}
\end{array}
if a < -2.69999999999999993e-61 or 1.54999999999999996e-95 < a Initial program 73.3%
Taylor expanded in t around 0 60.3%
associate-/l*68.0%
Simplified68.0%
if -2.69999999999999993e-61 < a < 1.54999999999999996e-95Initial program 53.5%
clear-num53.4%
inv-pow53.4%
*-commutative53.4%
associate-/r*62.4%
Applied egg-rr62.4%
unpow-162.4%
associate-/l/53.4%
*-commutative53.4%
Simplified53.4%
Taylor expanded in t around inf 82.8%
associate--l+82.8%
associate-*r/82.8%
associate-*r/82.8%
mul-1-neg82.8%
div-sub84.0%
mul-1-neg84.0%
distribute-lft-out--84.0%
associate-*r/84.0%
mul-1-neg84.0%
distribute-rgt-out--84.0%
Simplified84.0%
Taylor expanded in a around 0 79.4%
associate-/l*83.0%
Simplified83.0%
Final simplification73.6%
(FPCore (x y z t a) :precision binary64 (if (<= a -5e-63) (+ x (* y (/ z (- a t)))) (if (<= a 2.1e-57) (* y (- 1.0 (/ (- z a) t))) (+ x (* z (/ y a))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -5e-63) {
tmp = x + (y * (z / (a - t)));
} else if (a <= 2.1e-57) {
tmp = y * (1.0 - ((z - a) / t));
} else {
tmp = x + (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) :: tmp
if (a <= (-5d-63)) then
tmp = x + (y * (z / (a - t)))
else if (a <= 2.1d-57) then
tmp = y * (1.0d0 - ((z - a) / t))
else
tmp = x + (z * (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 (a <= -5e-63) {
tmp = x + (y * (z / (a - t)));
} else if (a <= 2.1e-57) {
tmp = y * (1.0 - ((z - a) / t));
} else {
tmp = x + (z * (y / a));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -5e-63: tmp = x + (y * (z / (a - t))) elif a <= 2.1e-57: tmp = y * (1.0 - ((z - a) / t)) else: tmp = x + (z * (y / a)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -5e-63) tmp = Float64(x + Float64(y * Float64(z / Float64(a - t)))); elseif (a <= 2.1e-57) tmp = Float64(y * Float64(1.0 - Float64(Float64(z - a) / t))); else tmp = Float64(x + Float64(z * Float64(y / a))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -5e-63) tmp = x + (y * (z / (a - t))); elseif (a <= 2.1e-57) tmp = y * (1.0 - ((z - a) / t)); else tmp = x + (z * (y / a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -5e-63], N[(x + N[(y * N[(z / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 2.1e-57], N[(y * N[(1.0 - N[(N[(z - a), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(z * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -5 \cdot 10^{-63}:\\
\;\;\;\;x + y \cdot \frac{z}{a - t}\\
\mathbf{elif}\;a \leq 2.1 \cdot 10^{-57}:\\
\;\;\;\;y \cdot \left(1 - \frac{z - a}{t}\right)\\
\mathbf{else}:\\
\;\;\;\;x + z \cdot \frac{y}{a}\\
\end{array}
\end{array}
if a < -5.0000000000000002e-63Initial program 69.9%
Taylor expanded in y around inf 70.6%
associate-/l*78.4%
Simplified78.4%
Taylor expanded in z around inf 62.7%
if -5.0000000000000002e-63 < a < 2.0999999999999999e-57Initial program 54.9%
clear-num54.8%
inv-pow54.8%
*-commutative54.8%
associate-/r*64.3%
Applied egg-rr64.3%
unpow-164.3%
associate-/l/54.8%
*-commutative54.8%
Simplified54.8%
Taylor expanded in t around inf 79.9%
associate--l+79.9%
associate-*r/79.9%
associate-*r/79.9%
mul-1-neg79.9%
div-sub81.0%
mul-1-neg81.0%
distribute-lft-out--81.0%
associate-*r/81.0%
mul-1-neg81.0%
distribute-rgt-out--81.0%
Simplified81.0%
Taylor expanded in y around -inf 60.0%
mul-1-neg60.0%
unsub-neg60.0%
Simplified60.0%
if 2.0999999999999999e-57 < a Initial program 75.7%
Taylor expanded in t around 0 59.5%
associate-/l*67.7%
Simplified67.7%
Taylor expanded in y around inf 60.4%
Final simplification60.8%
(FPCore (x y z t a) :precision binary64 (if (<= a -8.5e-61) x (if (<= a 3.2e-296) (* x (/ (- z a) t)) (if (<= a 1.4e+49) y x))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -8.5e-61) {
tmp = x;
} else if (a <= 3.2e-296) {
tmp = x * ((z - a) / t);
} else if (a <= 1.4e+49) {
tmp = y;
} 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 (a <= (-8.5d-61)) then
tmp = x
else if (a <= 3.2d-296) then
tmp = x * ((z - a) / t)
else if (a <= 1.4d+49) then
tmp = y
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 (a <= -8.5e-61) {
tmp = x;
} else if (a <= 3.2e-296) {
tmp = x * ((z - a) / t);
} else if (a <= 1.4e+49) {
tmp = y;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -8.5e-61: tmp = x elif a <= 3.2e-296: tmp = x * ((z - a) / t) elif a <= 1.4e+49: tmp = y else: tmp = x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -8.5e-61) tmp = x; elseif (a <= 3.2e-296) tmp = Float64(x * Float64(Float64(z - a) / t)); elseif (a <= 1.4e+49) tmp = y; else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -8.5e-61) tmp = x; elseif (a <= 3.2e-296) tmp = x * ((z - a) / t); elseif (a <= 1.4e+49) tmp = y; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -8.5e-61], x, If[LessEqual[a, 3.2e-296], N[(x * N[(N[(z - a), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.4e+49], y, x]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -8.5 \cdot 10^{-61}:\\
\;\;\;\;x\\
\mathbf{elif}\;a \leq 3.2 \cdot 10^{-296}:\\
\;\;\;\;x \cdot \frac{z - a}{t}\\
\mathbf{elif}\;a \leq 1.4 \cdot 10^{+49}:\\
\;\;\;\;y\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if a < -8.50000000000000016e-61 or 1.3999999999999999e49 < a Initial program 70.5%
Taylor expanded in a around inf 49.9%
if -8.50000000000000016e-61 < a < 3.20000000000000013e-296Initial program 51.9%
clear-num51.8%
inv-pow51.8%
*-commutative51.8%
associate-/r*57.8%
Applied egg-rr57.8%
unpow-157.8%
associate-/l/51.8%
*-commutative51.8%
Simplified51.8%
Taylor expanded in t around inf 80.2%
associate--l+80.2%
associate-*r/80.2%
associate-*r/80.2%
mul-1-neg80.2%
div-sub82.5%
mul-1-neg82.5%
distribute-lft-out--82.5%
associate-*r/82.5%
mul-1-neg82.5%
distribute-rgt-out--82.5%
Simplified82.5%
Taylor expanded in y around 0 45.1%
associate-/l*45.0%
Simplified45.0%
if 3.20000000000000013e-296 < a < 1.3999999999999999e49Initial program 67.1%
Taylor expanded in t around inf 38.0%
Final simplification45.3%
(FPCore (x y z t a) :precision binary64 (if (<= a -8.6e-61) x (if (<= a 1.4e+49) y x)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -8.6e-61) {
tmp = x;
} else if (a <= 1.4e+49) {
tmp = y;
} 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 (a <= (-8.6d-61)) then
tmp = x
else if (a <= 1.4d+49) then
tmp = y
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 (a <= -8.6e-61) {
tmp = x;
} else if (a <= 1.4e+49) {
tmp = y;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -8.6e-61: tmp = x elif a <= 1.4e+49: tmp = y else: tmp = x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -8.6e-61) tmp = x; elseif (a <= 1.4e+49) tmp = y; else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -8.6e-61) tmp = x; elseif (a <= 1.4e+49) tmp = y; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -8.6e-61], x, If[LessEqual[a, 1.4e+49], y, x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -8.6 \cdot 10^{-61}:\\
\;\;\;\;x\\
\mathbf{elif}\;a \leq 1.4 \cdot 10^{+49}:\\
\;\;\;\;y\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if a < -8.6000000000000007e-61 or 1.3999999999999999e49 < a Initial program 70.5%
Taylor expanded in a around inf 49.9%
if -8.6000000000000007e-61 < a < 1.3999999999999999e49Initial program 61.3%
Taylor expanded in t around inf 36.9%
Final simplification43.4%
(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 65.9%
Taylor expanded in a around inf 28.5%
Final simplification28.5%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* (/ (- y x) 1.0) (/ (- z t) (- a t))))))
(if (< a -1.6153062845442575e-142)
t_1
(if (< a 3.774403170083174e-182) (- y (* (/ z t) (- y x))) t_1))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (((y - x) / 1.0) * ((z - t) / (a - t)));
double tmp;
if (a < -1.6153062845442575e-142) {
tmp = t_1;
} else if (a < 3.774403170083174e-182) {
tmp = y - ((z / t) * (y - x));
} 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 = x + (((y - x) / 1.0d0) * ((z - t) / (a - t)))
if (a < (-1.6153062845442575d-142)) then
tmp = t_1
else if (a < 3.774403170083174d-182) then
tmp = y - ((z / t) * (y - x))
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 = x + (((y - x) / 1.0) * ((z - t) / (a - t)));
double tmp;
if (a < -1.6153062845442575e-142) {
tmp = t_1;
} else if (a < 3.774403170083174e-182) {
tmp = y - ((z / t) * (y - x));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + (((y - x) / 1.0) * ((z - t) / (a - t))) tmp = 0 if a < -1.6153062845442575e-142: tmp = t_1 elif a < 3.774403170083174e-182: tmp = y - ((z / t) * (y - x)) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(Float64(y - x) / 1.0) * Float64(Float64(z - t) / Float64(a - t)))) tmp = 0.0 if (a < -1.6153062845442575e-142) tmp = t_1; elseif (a < 3.774403170083174e-182) tmp = Float64(y - Float64(Float64(z / t) * Float64(y - x))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + (((y - x) / 1.0) * ((z - t) / (a - t))); tmp = 0.0; if (a < -1.6153062845442575e-142) tmp = t_1; elseif (a < 3.774403170083174e-182) tmp = y - ((z / t) * (y - x)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(N[(y - x), $MachinePrecision] / 1.0), $MachinePrecision] * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Less[a, -1.6153062845442575e-142], t$95$1, If[Less[a, 3.774403170083174e-182], N[(y - N[(N[(z / t), $MachinePrecision] * N[(y - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{y - x}{1} \cdot \frac{z - t}{a - t}\\
\mathbf{if}\;a < -1.6153062845442575 \cdot 10^{-142}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a < 3.774403170083174 \cdot 10^{-182}:\\
\;\;\;\;y - \frac{z}{t} \cdot \left(y - x\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
herbie shell --seed 2024059
(FPCore (x y z t a)
:name "Graphics.Rendering.Chart.Axis.Types:linMap from Chart-1.5.3"
:precision binary64
:alt
(if (< a -1.6153062845442575e-142) (+ x (* (/ (- y x) 1.0) (/ (- z t) (- a t)))) (if (< a 3.774403170083174e-182) (- y (* (/ z t) (- y x))) (+ x (* (/ (- y x) 1.0) (/ (- z t) (- a t))))))
(+ x (/ (* (- y x) (- z t)) (- a t))))