
(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 19 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
(let* ((t_1 (+ x (* (- z t) (* (- y x) (/ -1.0 (- t a))))))
(t_2 (+ x (/ (* (- z t) (- x y)) (- t a)))))
(if (<= t_2 (- INFINITY))
t_1
(if (<= t_2 -5e-254)
t_2
(if (<= t_2 0.0)
(+ y (/ (* (- y x) (- a z)) t))
(if (<= t_2 2e+265) t_2 t_1))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((z - t) * ((y - x) * (-1.0 / (t - a))));
double t_2 = x + (((z - t) * (x - y)) / (t - a));
double tmp;
if (t_2 <= -((double) INFINITY)) {
tmp = t_1;
} else if (t_2 <= -5e-254) {
tmp = t_2;
} else if (t_2 <= 0.0) {
tmp = y + (((y - x) * (a - z)) / t);
} else if (t_2 <= 2e+265) {
tmp = t_2;
} else {
tmp = t_1;
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((z - t) * ((y - x) * (-1.0 / (t - a))));
double t_2 = x + (((z - t) * (x - y)) / (t - a));
double tmp;
if (t_2 <= -Double.POSITIVE_INFINITY) {
tmp = t_1;
} else if (t_2 <= -5e-254) {
tmp = t_2;
} else if (t_2 <= 0.0) {
tmp = y + (((y - x) * (a - z)) / t);
} else if (t_2 <= 2e+265) {
tmp = t_2;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((z - t) * ((y - x) * (-1.0 / (t - a)))) t_2 = x + (((z - t) * (x - y)) / (t - a)) tmp = 0 if t_2 <= -math.inf: tmp = t_1 elif t_2 <= -5e-254: tmp = t_2 elif t_2 <= 0.0: tmp = y + (((y - x) * (a - z)) / t) elif t_2 <= 2e+265: tmp = t_2 else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(z - t) * Float64(Float64(y - x) * Float64(-1.0 / Float64(t - a))))) t_2 = Float64(x + Float64(Float64(Float64(z - t) * Float64(x - y)) / Float64(t - a))) tmp = 0.0 if (t_2 <= Float64(-Inf)) tmp = t_1; elseif (t_2 <= -5e-254) tmp = t_2; elseif (t_2 <= 0.0) tmp = Float64(y + Float64(Float64(Float64(y - x) * Float64(a - z)) / t)); elseif (t_2 <= 2e+265) tmp = t_2; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + ((z - t) * ((y - x) * (-1.0 / (t - a)))); t_2 = x + (((z - t) * (x - y)) / (t - a)); tmp = 0.0; if (t_2 <= -Inf) tmp = t_1; elseif (t_2 <= -5e-254) tmp = t_2; elseif (t_2 <= 0.0) tmp = y + (((y - x) * (a - z)) / t); elseif (t_2 <= 2e+265) tmp = t_2; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(z - t), $MachinePrecision] * N[(N[(y - x), $MachinePrecision] * N[(-1.0 / N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(N[(N[(z - t), $MachinePrecision] * N[(x - y), $MachinePrecision]), $MachinePrecision] / N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, (-Infinity)], t$95$1, If[LessEqual[t$95$2, -5e-254], t$95$2, If[LessEqual[t$95$2, 0.0], N[(y + N[(N[(N[(y - x), $MachinePrecision] * N[(a - z), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, 2e+265], t$95$2, t$95$1]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \left(z - t\right) \cdot \left(\left(y - x\right) \cdot \frac{-1}{t - a}\right)\\
t_2 := x + \frac{\left(z - t\right) \cdot \left(x - y\right)}{t - a}\\
\mathbf{if}\;t\_2 \leq -\infty:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t\_2 \leq -5 \cdot 10^{-254}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t\_2 \leq 0:\\
\;\;\;\;y + \frac{\left(y - x\right) \cdot \left(a - z\right)}{t}\\
\mathbf{elif}\;t\_2 \leq 2 \cdot 10^{+265}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < -inf.0 or 2.00000000000000013e265 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) Initial program 40.3%
div-inv40.3%
*-commutative40.3%
associate-*l*80.0%
Applied egg-rr80.0%
if -inf.0 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < -5.0000000000000003e-254 or 0.0 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < 2.00000000000000013e265Initial program 96.0%
if -5.0000000000000003e-254 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < 0.0Initial program 4.6%
+-commutative4.6%
associate-/l*4.6%
fma-define4.6%
Simplified4.6%
Taylor expanded in t around inf 99.9%
associate--l+99.9%
associate-*r/99.9%
associate-*r/99.9%
mul-1-neg99.9%
div-sub99.9%
mul-1-neg99.9%
distribute-lft-out--99.9%
associate-*r/99.9%
mul-1-neg99.9%
unsub-neg99.9%
distribute-rgt-out--99.9%
Simplified99.9%
Final simplification89.8%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (/ (* (- z t) (- x y)) (- t a)))))
(if (or (<= t_1 -5e-254) (not (<= t_1 0.0)))
(fma (- y x) (/ (- z t) (- a t)) x)
(+ y (/ (* (- y x) (- a z)) t)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (((z - t) * (x - y)) / (t - a));
double tmp;
if ((t_1 <= -5e-254) || !(t_1 <= 0.0)) {
tmp = fma((y - x), ((z - t) / (a - t)), x);
} else {
tmp = y + (((y - x) * (a - z)) / t);
}
return tmp;
}
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(Float64(z - t) * Float64(x - y)) / Float64(t - a))) tmp = 0.0 if ((t_1 <= -5e-254) || !(t_1 <= 0.0)) tmp = fma(Float64(y - x), Float64(Float64(z - t) / Float64(a - t)), x); else tmp = Float64(y + Float64(Float64(Float64(y - x) * Float64(a - z)) / t)); end return tmp end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(N[(z - t), $MachinePrecision] * N[(x - y), $MachinePrecision]), $MachinePrecision] / N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$1, -5e-254], N[Not[LessEqual[t$95$1, 0.0]], $MachinePrecision]], N[(N[(y - x), $MachinePrecision] * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision], N[(y + N[(N[(N[(y - x), $MachinePrecision] * N[(a - z), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{\left(z - t\right) \cdot \left(x - y\right)}{t - a}\\
\mathbf{if}\;t\_1 \leq -5 \cdot 10^{-254} \lor \neg \left(t\_1 \leq 0\right):\\
\;\;\;\;\mathsf{fma}\left(y - x, \frac{z - t}{a - t}, x\right)\\
\mathbf{else}:\\
\;\;\;\;y + \frac{\left(y - x\right) \cdot \left(a - z\right)}{t}\\
\end{array}
\end{array}
if (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < -5.0000000000000003e-254 or 0.0 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) Initial program 72.3%
+-commutative72.3%
associate-/l*88.8%
fma-define88.8%
Simplified88.8%
if -5.0000000000000003e-254 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < 0.0Initial program 4.6%
+-commutative4.6%
associate-/l*4.6%
fma-define4.6%
Simplified4.6%
Taylor expanded in t around inf 99.9%
associate--l+99.9%
associate-*r/99.9%
associate-*r/99.9%
mul-1-neg99.9%
div-sub99.9%
mul-1-neg99.9%
distribute-lft-out--99.9%
associate-*r/99.9%
mul-1-neg99.9%
unsub-neg99.9%
distribute-rgt-out--99.9%
Simplified99.9%
Final simplification89.5%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (- y (* z (/ (- y x) t))))
(t_2 (+ x (/ (* (- z t) (- x y)) (- t a)))))
(if (<= t_2 (- INFINITY))
t_1
(if (<= t_2 -5e-254)
t_2
(if (<= t_2 0.0)
(+ y (/ (* (- y x) (- a z)) t))
(if (<= t_2 2e+289) t_2 t_1))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = y - (z * ((y - x) / t));
double t_2 = x + (((z - t) * (x - y)) / (t - a));
double tmp;
if (t_2 <= -((double) INFINITY)) {
tmp = t_1;
} else if (t_2 <= -5e-254) {
tmp = t_2;
} else if (t_2 <= 0.0) {
tmp = y + (((y - x) * (a - z)) / t);
} else if (t_2 <= 2e+289) {
tmp = t_2;
} else {
tmp = t_1;
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a) {
double t_1 = y - (z * ((y - x) / t));
double t_2 = x + (((z - t) * (x - y)) / (t - a));
double tmp;
if (t_2 <= -Double.POSITIVE_INFINITY) {
tmp = t_1;
} else if (t_2 <= -5e-254) {
tmp = t_2;
} else if (t_2 <= 0.0) {
tmp = y + (((y - x) * (a - z)) / t);
} else if (t_2 <= 2e+289) {
tmp = t_2;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = y - (z * ((y - x) / t)) t_2 = x + (((z - t) * (x - y)) / (t - a)) tmp = 0 if t_2 <= -math.inf: tmp = t_1 elif t_2 <= -5e-254: tmp = t_2 elif t_2 <= 0.0: tmp = y + (((y - x) * (a - z)) / t) elif t_2 <= 2e+289: tmp = t_2 else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(y - Float64(z * Float64(Float64(y - x) / t))) t_2 = Float64(x + Float64(Float64(Float64(z - t) * Float64(x - y)) / Float64(t - a))) tmp = 0.0 if (t_2 <= Float64(-Inf)) tmp = t_1; elseif (t_2 <= -5e-254) tmp = t_2; elseif (t_2 <= 0.0) tmp = Float64(y + Float64(Float64(Float64(y - x) * Float64(a - z)) / t)); elseif (t_2 <= 2e+289) tmp = t_2; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = y - (z * ((y - x) / t)); t_2 = x + (((z - t) * (x - y)) / (t - a)); tmp = 0.0; if (t_2 <= -Inf) tmp = t_1; elseif (t_2 <= -5e-254) tmp = t_2; elseif (t_2 <= 0.0) tmp = y + (((y - x) * (a - z)) / t); elseif (t_2 <= 2e+289) tmp = t_2; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y - N[(z * N[(N[(y - x), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(N[(N[(z - t), $MachinePrecision] * N[(x - y), $MachinePrecision]), $MachinePrecision] / N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, (-Infinity)], t$95$1, If[LessEqual[t$95$2, -5e-254], t$95$2, If[LessEqual[t$95$2, 0.0], N[(y + N[(N[(N[(y - x), $MachinePrecision] * N[(a - z), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, 2e+289], t$95$2, t$95$1]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y - z \cdot \frac{y - x}{t}\\
t_2 := x + \frac{\left(z - t\right) \cdot \left(x - y\right)}{t - a}\\
\mathbf{if}\;t\_2 \leq -\infty:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t\_2 \leq -5 \cdot 10^{-254}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t\_2 \leq 0:\\
\;\;\;\;y + \frac{\left(y - x\right) \cdot \left(a - z\right)}{t}\\
\mathbf{elif}\;t\_2 \leq 2 \cdot 10^{+289}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < -inf.0 or 2.0000000000000001e289 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) Initial program 39.7%
+-commutative39.7%
associate-/l*79.8%
fma-define79.8%
Simplified79.8%
Taylor expanded in y around 0 56.6%
+-commutative56.6%
div-sub56.6%
mul-1-neg56.6%
associate-/l*68.9%
distribute-lft-neg-in68.9%
distribute-rgt-in79.8%
sub-neg79.8%
associate-*l/39.7%
associate-*r/79.8%
+-commutative79.8%
fma-define79.8%
Simplified79.8%
clear-num79.7%
associate-/r/79.9%
Applied egg-rr79.9%
Taylor expanded in a around 0 53.8%
Taylor expanded in z around 0 63.2%
div-sub67.3%
associate-/l*53.7%
mul-1-neg53.7%
unsub-neg53.7%
associate-/l*67.3%
Simplified67.3%
if -inf.0 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < -5.0000000000000003e-254 or 0.0 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < 2.0000000000000001e289Initial program 96.0%
if -5.0000000000000003e-254 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < 0.0Initial program 4.6%
+-commutative4.6%
associate-/l*4.6%
fma-define4.6%
Simplified4.6%
Taylor expanded in t around inf 99.9%
associate--l+99.9%
associate-*r/99.9%
associate-*r/99.9%
mul-1-neg99.9%
div-sub99.9%
mul-1-neg99.9%
distribute-lft-out--99.9%
associate-*r/99.9%
mul-1-neg99.9%
unsub-neg99.9%
distribute-rgt-out--99.9%
Simplified99.9%
Final simplification84.9%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* (- y x) (/ z (- a t)))) (t_2 (* y (/ (- z t) (- a t)))))
(if (<= y -40000.0)
t_2
(if (<= y -3.2e-169)
t_1
(if (<= y 1.22e-138)
(- x (/ (* x z) a))
(if (<= y 5.8e+101) t_1 t_2))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = (y - x) * (z / (a - t));
double t_2 = y * ((z - t) / (a - t));
double tmp;
if (y <= -40000.0) {
tmp = t_2;
} else if (y <= -3.2e-169) {
tmp = t_1;
} else if (y <= 1.22e-138) {
tmp = x - ((x * z) / a);
} else if (y <= 5.8e+101) {
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 - x) * (z / (a - t))
t_2 = y * ((z - t) / (a - t))
if (y <= (-40000.0d0)) then
tmp = t_2
else if (y <= (-3.2d-169)) then
tmp = t_1
else if (y <= 1.22d-138) then
tmp = x - ((x * z) / a)
else if (y <= 5.8d+101) 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 - x) * (z / (a - t));
double t_2 = y * ((z - t) / (a - t));
double tmp;
if (y <= -40000.0) {
tmp = t_2;
} else if (y <= -3.2e-169) {
tmp = t_1;
} else if (y <= 1.22e-138) {
tmp = x - ((x * z) / a);
} else if (y <= 5.8e+101) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = (y - x) * (z / (a - t)) t_2 = y * ((z - t) / (a - t)) tmp = 0 if y <= -40000.0: tmp = t_2 elif y <= -3.2e-169: tmp = t_1 elif y <= 1.22e-138: tmp = x - ((x * z) / a) elif y <= 5.8e+101: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a) t_1 = Float64(Float64(y - x) * Float64(z / Float64(a - t))) t_2 = Float64(y * Float64(Float64(z - t) / Float64(a - t))) tmp = 0.0 if (y <= -40000.0) tmp = t_2; elseif (y <= -3.2e-169) tmp = t_1; elseif (y <= 1.22e-138) tmp = Float64(x - Float64(Float64(x * z) / a)); elseif (y <= 5.8e+101) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = (y - x) * (z / (a - t)); t_2 = y * ((z - t) / (a - t)); tmp = 0.0; if (y <= -40000.0) tmp = t_2; elseif (y <= -3.2e-169) tmp = t_1; elseif (y <= 1.22e-138) tmp = x - ((x * z) / a); elseif (y <= 5.8e+101) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(y - x), $MachinePrecision] * N[(z / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -40000.0], t$95$2, If[LessEqual[y, -3.2e-169], t$95$1, If[LessEqual[y, 1.22e-138], N[(x - N[(N[(x * z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 5.8e+101], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(y - x\right) \cdot \frac{z}{a - t}\\
t_2 := y \cdot \frac{z - t}{a - t}\\
\mathbf{if}\;y \leq -40000:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y \leq -3.2 \cdot 10^{-169}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 1.22 \cdot 10^{-138}:\\
\;\;\;\;x - \frac{x \cdot z}{a}\\
\mathbf{elif}\;y \leq 5.8 \cdot 10^{+101}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if y < -4e4 or 5.79999999999999974e101 < y Initial program 66.9%
+-commutative66.9%
associate-/l*89.7%
fma-define89.7%
Simplified89.7%
Taylor expanded in y around 0 82.1%
+-commutative82.1%
div-sub82.1%
mul-1-neg82.1%
associate-/l*84.5%
distribute-lft-neg-in84.5%
distribute-rgt-in89.7%
sub-neg89.7%
associate-*l/66.9%
associate-*r/85.5%
+-commutative85.5%
fma-define85.6%
Simplified85.6%
Taylor expanded in y around inf 77.6%
div-sub77.5%
Simplified77.5%
if -4e4 < y < -3.19999999999999995e-169 or 1.22e-138 < y < 5.79999999999999974e101Initial program 63.9%
+-commutative63.9%
associate-/l*78.7%
fma-define78.7%
Simplified78.7%
Taylor expanded in z around inf 48.0%
sub-div48.0%
clear-num46.5%
un-div-inv46.5%
Applied egg-rr46.5%
associate-/r/53.8%
Simplified53.8%
if -3.19999999999999995e-169 < y < 1.22e-138Initial program 75.5%
+-commutative75.5%
associate-/l*78.0%
fma-define78.0%
Simplified78.0%
Taylor expanded in y around 0 70.7%
+-commutative70.7%
div-sub70.7%
mul-1-neg70.7%
associate-/l*74.7%
distribute-lft-neg-in74.7%
distribute-rgt-in78.0%
sub-neg78.0%
associate-*l/75.5%
associate-*r/68.5%
+-commutative68.5%
fma-define68.6%
Simplified68.6%
Taylor expanded in y around 0 68.6%
mul-1-neg68.6%
unsub-neg68.6%
associate-/l*71.8%
Simplified71.8%
Taylor expanded in t around 0 56.9%
Final simplification65.3%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -1.4e-121) (not (<= a 3.4e+30))) (+ x (* (- z t) (/ y (- a t)))) (+ y (/ (* (- y x) (- a z)) t))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -1.4e-121) || !(a <= 3.4e+30)) {
tmp = x + ((z - t) * (y / (a - t)));
} else {
tmp = y + (((y - x) * (a - z)) / 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.4d-121)) .or. (.not. (a <= 3.4d+30))) then
tmp = x + ((z - t) * (y / (a - t)))
else
tmp = y + (((y - x) * (a - z)) / 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.4e-121) || !(a <= 3.4e+30)) {
tmp = x + ((z - t) * (y / (a - t)));
} else {
tmp = y + (((y - x) * (a - z)) / t);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -1.4e-121) or not (a <= 3.4e+30): tmp = x + ((z - t) * (y / (a - t))) else: tmp = y + (((y - x) * (a - z)) / t) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -1.4e-121) || !(a <= 3.4e+30)) tmp = Float64(x + Float64(Float64(z - t) * Float64(y / Float64(a - t)))); else tmp = Float64(y + Float64(Float64(Float64(y - x) * Float64(a - z)) / t)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a <= -1.4e-121) || ~((a <= 3.4e+30))) tmp = x + ((z - t) * (y / (a - t))); else tmp = y + (((y - x) * (a - z)) / t); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -1.4e-121], N[Not[LessEqual[a, 3.4e+30]], $MachinePrecision]], N[(x + N[(N[(z - t), $MachinePrecision] * N[(y / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y + N[(N[(N[(y - x), $MachinePrecision] * N[(a - z), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.4 \cdot 10^{-121} \lor \neg \left(a \leq 3.4 \cdot 10^{+30}\right):\\
\;\;\;\;x + \left(z - t\right) \cdot \frac{y}{a - t}\\
\mathbf{else}:\\
\;\;\;\;y + \frac{\left(y - x\right) \cdot \left(a - z\right)}{t}\\
\end{array}
\end{array}
if a < -1.4000000000000001e-121 or 3.4000000000000002e30 < a Initial program 71.8%
Taylor expanded in y around inf 66.1%
*-commutative66.1%
*-lft-identity66.1%
times-frac76.1%
/-rgt-identity76.1%
Simplified76.1%
if -1.4000000000000001e-121 < a < 3.4000000000000002e30Initial program 62.4%
+-commutative62.4%
associate-/l*70.4%
fma-define70.4%
Simplified70.4%
Taylor expanded in t around inf 75.1%
associate--l+75.1%
associate-*r/75.1%
associate-*r/75.1%
mul-1-neg75.1%
div-sub76.1%
mul-1-neg76.1%
distribute-lft-out--76.1%
associate-*r/76.1%
mul-1-neg76.1%
unsub-neg76.1%
distribute-rgt-out--76.1%
Simplified76.1%
Final simplification76.1%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -4.8e-70) (not (<= a 6.5e+51))) (+ x (* (- y x) (/ (- z t) a))) (- y (* z (/ (- y x) t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -4.8e-70) || !(a <= 6.5e+51)) {
tmp = x + ((y - x) * ((z - t) / a));
} else {
tmp = y - (z * ((y - x) / 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 <= (-4.8d-70)) .or. (.not. (a <= 6.5d+51))) then
tmp = x + ((y - x) * ((z - t) / a))
else
tmp = y - (z * ((y - x) / 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 <= -4.8e-70) || !(a <= 6.5e+51)) {
tmp = x + ((y - x) * ((z - t) / a));
} else {
tmp = y - (z * ((y - x) / t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -4.8e-70) or not (a <= 6.5e+51): tmp = x + ((y - x) * ((z - t) / a)) else: tmp = y - (z * ((y - x) / t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -4.8e-70) || !(a <= 6.5e+51)) tmp = Float64(x + Float64(Float64(y - x) * Float64(Float64(z - t) / a))); else tmp = Float64(y - Float64(z * Float64(Float64(y - x) / t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a <= -4.8e-70) || ~((a <= 6.5e+51))) tmp = x + ((y - x) * ((z - t) / a)); else tmp = y - (z * ((y - x) / t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -4.8e-70], N[Not[LessEqual[a, 6.5e+51]], $MachinePrecision]], N[(x + N[(N[(y - x), $MachinePrecision] * N[(N[(z - t), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y - N[(z * N[(N[(y - x), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -4.8 \cdot 10^{-70} \lor \neg \left(a \leq 6.5 \cdot 10^{+51}\right):\\
\;\;\;\;x + \left(y - x\right) \cdot \frac{z - t}{a}\\
\mathbf{else}:\\
\;\;\;\;y - z \cdot \frac{y - x}{t}\\
\end{array}
\end{array}
if a < -4.8000000000000002e-70 or 6.5e51 < a Initial program 72.7%
Taylor expanded in a around inf 65.0%
associate-/l*75.9%
Simplified75.9%
if -4.8000000000000002e-70 < a < 6.5e51Initial program 62.1%
+-commutative62.1%
associate-/l*72.6%
fma-define72.6%
Simplified72.6%
Taylor expanded in y around 0 63.0%
+-commutative63.0%
div-sub63.0%
mul-1-neg63.0%
associate-/l*62.9%
distribute-lft-neg-in62.9%
distribute-rgt-in72.6%
sub-neg72.6%
associate-*l/62.1%
associate-*r/66.9%
+-commutative66.9%
fma-define67.0%
Simplified67.0%
clear-num66.7%
associate-/r/66.9%
Applied egg-rr66.9%
Taylor expanded in a around 0 49.5%
Taylor expanded in z around 0 70.4%
div-sub74.0%
associate-/l*72.2%
mul-1-neg72.2%
unsub-neg72.2%
associate-/l*74.0%
Simplified74.0%
Final simplification75.0%
(FPCore (x y z t a)
:precision binary64
(if (<= a -5.2e-71)
(+ x (* (- y x) (/ (- z t) a)))
(if (<= a 6.4e+19)
(- y (* z (/ (- y x) t)))
(+ x (* (- z t) (/ y (- a t)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -5.2e-71) {
tmp = x + ((y - x) * ((z - t) / a));
} else if (a <= 6.4e+19) {
tmp = y - (z * ((y - x) / t));
} else {
tmp = x + ((z - t) * (y / (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 <= (-5.2d-71)) then
tmp = x + ((y - x) * ((z - t) / a))
else if (a <= 6.4d+19) then
tmp = y - (z * ((y - x) / t))
else
tmp = x + ((z - t) * (y / (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 <= -5.2e-71) {
tmp = x + ((y - x) * ((z - t) / a));
} else if (a <= 6.4e+19) {
tmp = y - (z * ((y - x) / t));
} else {
tmp = x + ((z - t) * (y / (a - t)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -5.2e-71: tmp = x + ((y - x) * ((z - t) / a)) elif a <= 6.4e+19: tmp = y - (z * ((y - x) / t)) else: tmp = x + ((z - t) * (y / (a - t))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -5.2e-71) tmp = Float64(x + Float64(Float64(y - x) * Float64(Float64(z - t) / a))); elseif (a <= 6.4e+19) tmp = Float64(y - Float64(z * Float64(Float64(y - x) / t))); else tmp = Float64(x + Float64(Float64(z - t) * Float64(y / Float64(a - t)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -5.2e-71) tmp = x + ((y - x) * ((z - t) / a)); elseif (a <= 6.4e+19) tmp = y - (z * ((y - x) / t)); else tmp = x + ((z - t) * (y / (a - t))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -5.2e-71], N[(x + N[(N[(y - x), $MachinePrecision] * N[(N[(z - t), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 6.4e+19], N[(y - N[(z * N[(N[(y - x), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(z - t), $MachinePrecision] * N[(y / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -5.2 \cdot 10^{-71}:\\
\;\;\;\;x + \left(y - x\right) \cdot \frac{z - t}{a}\\
\mathbf{elif}\;a \leq 6.4 \cdot 10^{+19}:\\
\;\;\;\;y - z \cdot \frac{y - x}{t}\\
\mathbf{else}:\\
\;\;\;\;x + \left(z - t\right) \cdot \frac{y}{a - t}\\
\end{array}
\end{array}
if a < -5.1999999999999997e-71Initial program 69.5%
Taylor expanded in a around inf 62.1%
associate-/l*72.7%
Simplified72.7%
if -5.1999999999999997e-71 < a < 6.4e19Initial program 63.5%
+-commutative63.5%
associate-/l*72.0%
fma-define71.9%
Simplified71.9%
Taylor expanded in y around 0 61.8%
+-commutative61.8%
div-sub61.8%
mul-1-neg61.8%
associate-/l*61.6%
distribute-lft-neg-in61.6%
distribute-rgt-in72.0%
sub-neg72.0%
associate-*l/63.5%
associate-*r/66.8%
+-commutative66.8%
fma-define67.0%
Simplified67.0%
clear-num66.7%
associate-/r/66.8%
Applied egg-rr66.8%
Taylor expanded in a around 0 49.3%
Taylor expanded in z around 0 70.5%
div-sub74.3%
associate-/l*72.5%
mul-1-neg72.5%
unsub-neg72.5%
associate-/l*74.3%
Simplified74.3%
if 6.4e19 < a Initial program 73.5%
Taylor expanded in y around inf 70.4%
*-commutative70.4%
*-lft-identity70.4%
times-frac79.3%
/-rgt-identity79.3%
Simplified79.3%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -5.7e-67) (not (<= a 9.2e+51))) (+ x (* (- z t) (/ y a))) (- y (* z (/ (- y x) t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -5.7e-67) || !(a <= 9.2e+51)) {
tmp = x + ((z - t) * (y / a));
} else {
tmp = y - (z * ((y - x) / 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 <= (-5.7d-67)) .or. (.not. (a <= 9.2d+51))) then
tmp = x + ((z - t) * (y / a))
else
tmp = y - (z * ((y - x) / 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 <= -5.7e-67) || !(a <= 9.2e+51)) {
tmp = x + ((z - t) * (y / a));
} else {
tmp = y - (z * ((y - x) / t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -5.7e-67) or not (a <= 9.2e+51): tmp = x + ((z - t) * (y / a)) else: tmp = y - (z * ((y - x) / t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -5.7e-67) || !(a <= 9.2e+51)) tmp = Float64(x + Float64(Float64(z - t) * Float64(y / a))); else tmp = Float64(y - Float64(z * Float64(Float64(y - x) / t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a <= -5.7e-67) || ~((a <= 9.2e+51))) tmp = x + ((z - t) * (y / a)); else tmp = y - (z * ((y - x) / t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -5.7e-67], N[Not[LessEqual[a, 9.2e+51]], $MachinePrecision]], N[(x + N[(N[(z - t), $MachinePrecision] * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y - N[(z * N[(N[(y - x), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -5.7 \cdot 10^{-67} \lor \neg \left(a \leq 9.2 \cdot 10^{+51}\right):\\
\;\;\;\;x + \left(z - t\right) \cdot \frac{y}{a}\\
\mathbf{else}:\\
\;\;\;\;y - z \cdot \frac{y - x}{t}\\
\end{array}
\end{array}
if a < -5.7000000000000002e-67 or 9.2000000000000002e51 < a Initial program 72.6%
Taylor expanded in y around inf 66.6%
*-commutative66.6%
*-lft-identity66.6%
times-frac75.4%
/-rgt-identity75.4%
Simplified75.4%
Taylor expanded in a around inf 65.5%
if -5.7000000000000002e-67 < a < 9.2000000000000002e51Initial program 62.4%
+-commutative62.4%
associate-/l*72.9%
fma-define72.9%
Simplified72.9%
Taylor expanded in y around 0 63.3%
+-commutative63.3%
div-sub63.3%
mul-1-neg63.3%
associate-/l*63.2%
distribute-lft-neg-in63.2%
distribute-rgt-in72.9%
sub-neg72.9%
associate-*l/62.4%
associate-*r/66.4%
+-commutative66.4%
fma-define66.5%
Simplified66.5%
clear-num66.2%
associate-/r/66.4%
Applied egg-rr66.4%
Taylor expanded in a around 0 49.0%
Taylor expanded in z around 0 69.8%
div-sub73.4%
associate-/l*71.6%
mul-1-neg71.6%
unsub-neg71.6%
associate-/l*73.4%
Simplified73.4%
Final simplification69.0%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -3.75e-121) (not (<= t 3.3e+55))) (* y (/ (- z t) (- a t))) (+ x (* z (/ (- y x) a)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -3.75e-121) || !(t <= 3.3e+55)) {
tmp = y * ((z - t) / (a - t));
} else {
tmp = x + (z * ((y - x) / 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 ((t <= (-3.75d-121)) .or. (.not. (t <= 3.3d+55))) then
tmp = y * ((z - t) / (a - t))
else
tmp = x + (z * ((y - x) / a))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -3.75e-121) || !(t <= 3.3e+55)) {
tmp = y * ((z - t) / (a - t));
} else {
tmp = x + (z * ((y - x) / a));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -3.75e-121) or not (t <= 3.3e+55): tmp = y * ((z - t) / (a - t)) else: tmp = x + (z * ((y - x) / a)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -3.75e-121) || !(t <= 3.3e+55)) tmp = Float64(y * Float64(Float64(z - t) / Float64(a - t))); else tmp = Float64(x + Float64(z * Float64(Float64(y - x) / a))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -3.75e-121) || ~((t <= 3.3e+55))) tmp = y * ((z - t) / (a - t)); else tmp = x + (z * ((y - x) / a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -3.75e-121], N[Not[LessEqual[t, 3.3e+55]], $MachinePrecision]], N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(z * N[(N[(y - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.75 \cdot 10^{-121} \lor \neg \left(t \leq 3.3 \cdot 10^{+55}\right):\\
\;\;\;\;y \cdot \frac{z - t}{a - t}\\
\mathbf{else}:\\
\;\;\;\;x + z \cdot \frac{y - x}{a}\\
\end{array}
\end{array}
if t < -3.75000000000000013e-121 or 3.3e55 < t Initial program 50.8%
+-commutative50.8%
associate-/l*74.1%
fma-define74.1%
Simplified74.1%
Taylor expanded in y around 0 63.4%
+-commutative63.4%
div-sub63.4%
mul-1-neg63.4%
associate-/l*73.3%
distribute-lft-neg-in73.3%
distribute-rgt-in74.1%
sub-neg74.1%
associate-*l/50.8%
associate-*r/66.9%
+-commutative66.9%
fma-define67.0%
Simplified67.0%
Taylor expanded in y around inf 58.2%
div-sub58.2%
Simplified58.2%
if -3.75000000000000013e-121 < t < 3.3e55Initial program 88.3%
Taylor expanded in t around 0 71.6%
associate-/l*76.5%
Simplified76.5%
Final simplification66.6%
(FPCore (x y z t a) :precision binary64 (if (or (<= x -1.9e+41) (not (<= x 2.35e+39))) (- x (/ (* x z) a)) (* y (/ (- z t) (- a t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((x <= -1.9e+41) || !(x <= 2.35e+39)) {
tmp = x - ((x * z) / a);
} else {
tmp = y * ((z - t) / (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 ((x <= (-1.9d+41)) .or. (.not. (x <= 2.35d+39))) then
tmp = x - ((x * z) / a)
else
tmp = y * ((z - t) / (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 ((x <= -1.9e+41) || !(x <= 2.35e+39)) {
tmp = x - ((x * z) / a);
} else {
tmp = y * ((z - t) / (a - t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (x <= -1.9e+41) or not (x <= 2.35e+39): tmp = x - ((x * z) / a) else: tmp = y * ((z - t) / (a - t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((x <= -1.9e+41) || !(x <= 2.35e+39)) tmp = Float64(x - Float64(Float64(x * z) / a)); else tmp = Float64(y * Float64(Float64(z - t) / Float64(a - t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((x <= -1.9e+41) || ~((x <= 2.35e+39))) tmp = x - ((x * z) / a); else tmp = y * ((z - t) / (a - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[x, -1.9e+41], N[Not[LessEqual[x, 2.35e+39]], $MachinePrecision]], N[(x - N[(N[(x * z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.9 \cdot 10^{+41} \lor \neg \left(x \leq 2.35 \cdot 10^{+39}\right):\\
\;\;\;\;x - \frac{x \cdot z}{a}\\
\mathbf{else}:\\
\;\;\;\;y \cdot \frac{z - t}{a - t}\\
\end{array}
\end{array}
if x < -1.9000000000000001e41 or 2.35e39 < x Initial program 59.8%
+-commutative59.8%
associate-/l*74.6%
fma-define74.6%
Simplified74.6%
Taylor expanded in y around 0 55.2%
+-commutative55.2%
div-sub55.2%
mul-1-neg55.2%
associate-/l*68.6%
distribute-lft-neg-in68.6%
distribute-rgt-in74.6%
sub-neg74.6%
associate-*l/59.8%
associate-*r/72.3%
+-commutative72.3%
fma-define72.4%
Simplified72.4%
Taylor expanded in y around 0 55.8%
mul-1-neg55.8%
unsub-neg55.8%
associate-/l*65.3%
Simplified65.3%
Taylor expanded in t around 0 50.9%
if -1.9000000000000001e41 < x < 2.35e39Initial program 74.9%
+-commutative74.9%
associate-/l*90.9%
fma-define90.9%
Simplified90.9%
Taylor expanded in y around 0 89.5%
+-commutative89.5%
div-sub89.5%
mul-1-neg89.5%
associate-/l*88.0%
distribute-lft-neg-in88.0%
distribute-rgt-in90.9%
sub-neg90.9%
associate-*l/74.9%
associate-*r/81.6%
+-commutative81.6%
fma-define81.7%
Simplified81.7%
Taylor expanded in y around inf 70.3%
div-sub70.3%
Simplified70.3%
Final simplification61.5%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -9e-20) (not (<= t 1.95e+75))) (* y (/ t (- t a))) (+ x (/ (* y z) a))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -9e-20) || !(t <= 1.95e+75)) {
tmp = y * (t / (t - a));
} else {
tmp = x + ((y * z) / 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 ((t <= (-9d-20)) .or. (.not. (t <= 1.95d+75))) then
tmp = y * (t / (t - a))
else
tmp = x + ((y * z) / a)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -9e-20) || !(t <= 1.95e+75)) {
tmp = y * (t / (t - a));
} else {
tmp = x + ((y * z) / a);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -9e-20) or not (t <= 1.95e+75): tmp = y * (t / (t - a)) else: tmp = x + ((y * z) / a) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -9e-20) || !(t <= 1.95e+75)) tmp = Float64(y * Float64(t / Float64(t - a))); else tmp = Float64(x + Float64(Float64(y * z) / a)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -9e-20) || ~((t <= 1.95e+75))) tmp = y * (t / (t - a)); else tmp = x + ((y * z) / a); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -9e-20], N[Not[LessEqual[t, 1.95e+75]], $MachinePrecision]], N[(y * N[(t / N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(y * z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -9 \cdot 10^{-20} \lor \neg \left(t \leq 1.95 \cdot 10^{+75}\right):\\
\;\;\;\;y \cdot \frac{t}{t - a}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y \cdot z}{a}\\
\end{array}
\end{array}
if t < -9.0000000000000003e-20 or 1.95000000000000019e75 < t Initial program 44.3%
+-commutative44.3%
associate-/l*71.0%
fma-define71.0%
Simplified71.0%
Taylor expanded in y around 0 59.7%
+-commutative59.7%
div-sub59.7%
mul-1-neg59.7%
associate-/l*70.1%
distribute-lft-neg-in70.1%
distribute-rgt-in71.0%
sub-neg71.0%
associate-*l/44.3%
associate-*r/64.1%
+-commutative64.1%
fma-define64.2%
Simplified64.2%
Taylor expanded in y around inf 58.1%
div-sub58.1%
Simplified58.1%
Taylor expanded in z around 0 49.4%
neg-mul-149.4%
Simplified49.4%
if -9.0000000000000003e-20 < t < 1.95000000000000019e75Initial program 86.9%
Taylor expanded in y around inf 67.8%
*-commutative67.8%
*-lft-identity67.8%
times-frac68.1%
/-rgt-identity68.1%
Simplified68.1%
Taylor expanded in t around 0 56.1%
Final simplification53.1%
(FPCore (x y z t a) :precision binary64 (if (or (<= z -8.6e+121) (not (<= z 2.9e+69))) (* z (/ (- y x) a)) (+ x y)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -8.6e+121) || !(z <= 2.9e+69)) {
tmp = z * ((y - x) / a);
} else {
tmp = 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 ((z <= (-8.6d+121)) .or. (.not. (z <= 2.9d+69))) then
tmp = z * ((y - x) / a)
else
tmp = 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 ((z <= -8.6e+121) || !(z <= 2.9e+69)) {
tmp = z * ((y - x) / a);
} else {
tmp = x + y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (z <= -8.6e+121) or not (z <= 2.9e+69): tmp = z * ((y - x) / a) else: tmp = x + y return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((z <= -8.6e+121) || !(z <= 2.9e+69)) tmp = Float64(z * Float64(Float64(y - x) / a)); else tmp = Float64(x + y); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((z <= -8.6e+121) || ~((z <= 2.9e+69))) tmp = z * ((y - x) / a); else tmp = x + y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[z, -8.6e+121], N[Not[LessEqual[z, 2.9e+69]], $MachinePrecision]], N[(z * N[(N[(y - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], N[(x + y), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -8.6 \cdot 10^{+121} \lor \neg \left(z \leq 2.9 \cdot 10^{+69}\right):\\
\;\;\;\;z \cdot \frac{y - x}{a}\\
\mathbf{else}:\\
\;\;\;\;x + y\\
\end{array}
\end{array}
if z < -8.5999999999999994e121 or 2.8999999999999998e69 < z Initial program 66.7%
+-commutative66.7%
associate-/l*90.9%
fma-define90.9%
Simplified90.9%
Taylor expanded in z around inf 74.5%
Taylor expanded in a around inf 49.4%
associate-/l*53.4%
Simplified53.4%
if -8.5999999999999994e121 < z < 2.8999999999999998e69Initial program 68.8%
Taylor expanded in y around inf 61.0%
*-commutative61.0%
*-lft-identity61.0%
times-frac65.3%
/-rgt-identity65.3%
Simplified65.3%
Taylor expanded in t around inf 42.0%
Final simplification46.0%
(FPCore (x y z t a) :precision binary64 (if (<= t -1.85e+122) y (if (<= t 6.5e+75) (+ x (/ (* y z) a)) y)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -1.85e+122) {
tmp = y;
} else if (t <= 6.5e+75) {
tmp = x + ((y * z) / a);
} else {
tmp = 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 (t <= (-1.85d+122)) then
tmp = y
else if (t <= 6.5d+75) then
tmp = x + ((y * z) / a)
else
tmp = y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -1.85e+122) {
tmp = y;
} else if (t <= 6.5e+75) {
tmp = x + ((y * z) / a);
} else {
tmp = y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -1.85e+122: tmp = y elif t <= 6.5e+75: tmp = x + ((y * z) / a) else: tmp = y return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -1.85e+122) tmp = y; elseif (t <= 6.5e+75) tmp = Float64(x + Float64(Float64(y * z) / a)); else tmp = y; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -1.85e+122) tmp = y; elseif (t <= 6.5e+75) tmp = x + ((y * z) / a); else tmp = y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -1.85e+122], y, If[LessEqual[t, 6.5e+75], N[(x + N[(N[(y * z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], y]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.85 \cdot 10^{+122}:\\
\;\;\;\;y\\
\mathbf{elif}\;t \leq 6.5 \cdot 10^{+75}:\\
\;\;\;\;x + \frac{y \cdot z}{a}\\
\mathbf{else}:\\
\;\;\;\;y\\
\end{array}
\end{array}
if t < -1.8499999999999998e122 or 6.4999999999999998e75 < t Initial program 36.8%
+-commutative36.8%
associate-/l*67.5%
fma-define67.6%
Simplified67.6%
Taylor expanded in y around 0 56.1%
+-commutative56.1%
div-sub56.1%
mul-1-neg56.1%
associate-/l*67.5%
distribute-lft-neg-in67.5%
distribute-rgt-in67.5%
sub-neg67.5%
associate-*l/36.8%
associate-*r/59.5%
+-commutative59.5%
fma-define59.6%
Simplified59.6%
Taylor expanded in t around inf 47.3%
if -1.8499999999999998e122 < t < 6.4999999999999998e75Initial program 83.9%
Taylor expanded in y around inf 65.4%
*-commutative65.4%
*-lft-identity65.4%
times-frac66.2%
/-rgt-identity66.2%
Simplified66.2%
Taylor expanded in t around 0 51.6%
(FPCore (x y z t a) :precision binary64 (if (<= z -2.05e+127) (* x (/ z t)) (if (<= z 1.45e+72) (+ x y) (* y (/ z (- a t))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -2.05e+127) {
tmp = x * (z / t);
} else if (z <= 1.45e+72) {
tmp = x + y;
} else {
tmp = y * (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 (z <= (-2.05d+127)) then
tmp = x * (z / t)
else if (z <= 1.45d+72) then
tmp = x + y
else
tmp = y * (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 (z <= -2.05e+127) {
tmp = x * (z / t);
} else if (z <= 1.45e+72) {
tmp = x + y;
} else {
tmp = y * (z / (a - t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -2.05e+127: tmp = x * (z / t) elif z <= 1.45e+72: tmp = x + y else: tmp = y * (z / (a - t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -2.05e+127) tmp = Float64(x * Float64(z / t)); elseif (z <= 1.45e+72) tmp = Float64(x + y); else tmp = Float64(y * Float64(z / Float64(a - t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -2.05e+127) tmp = x * (z / t); elseif (z <= 1.45e+72) tmp = x + y; else tmp = y * (z / (a - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -2.05e+127], N[(x * N[(z / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.45e+72], N[(x + y), $MachinePrecision], N[(y * N[(z / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.05 \cdot 10^{+127}:\\
\;\;\;\;x \cdot \frac{z}{t}\\
\mathbf{elif}\;z \leq 1.45 \cdot 10^{+72}:\\
\;\;\;\;x + y\\
\mathbf{else}:\\
\;\;\;\;y \cdot \frac{z}{a - t}\\
\end{array}
\end{array}
if z < -2.04999999999999991e127Initial program 80.1%
+-commutative80.1%
associate-/l*91.4%
fma-define91.4%
Simplified91.4%
Taylor expanded in y around 0 79.5%
+-commutative79.5%
div-sub79.5%
mul-1-neg79.5%
associate-/l*76.5%
distribute-lft-neg-in76.5%
distribute-rgt-in91.4%
sub-neg91.4%
associate-*l/80.1%
associate-*r/82.7%
+-commutative82.7%
fma-define82.6%
Simplified82.6%
clear-num80.0%
associate-/r/82.7%
Applied egg-rr82.7%
Taylor expanded in a around 0 60.1%
Taylor expanded in x around inf 40.9%
associate-/l*48.9%
Simplified48.9%
if -2.04999999999999991e127 < z < 1.45000000000000009e72Initial program 68.6%
Taylor expanded in y around inf 60.3%
*-commutative60.3%
*-lft-identity60.3%
times-frac65.2%
/-rgt-identity65.2%
Simplified65.2%
Taylor expanded in t around inf 41.5%
if 1.45000000000000009e72 < z Initial program 58.8%
+-commutative58.8%
associate-/l*90.3%
fma-define90.3%
Simplified90.3%
Taylor expanded in y around 0 70.0%
+-commutative70.0%
div-sub70.0%
mul-1-neg70.0%
associate-/l*83.0%
distribute-lft-neg-in83.0%
distribute-rgt-in90.3%
sub-neg90.3%
associate-*l/58.8%
associate-*r/82.9%
+-commutative82.9%
fma-define83.1%
Simplified83.1%
Taylor expanded in y around inf 51.3%
div-sub51.3%
Simplified51.3%
Taylor expanded in z around inf 44.4%
(FPCore (x y z t a) :precision binary64 (if (or (<= z -1.15e+128) (not (<= z 8e+44))) (* x (/ z t)) (+ x y)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -1.15e+128) || !(z <= 8e+44)) {
tmp = x * (z / t);
} else {
tmp = 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 ((z <= (-1.15d+128)) .or. (.not. (z <= 8d+44))) then
tmp = x * (z / t)
else
tmp = 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 ((z <= -1.15e+128) || !(z <= 8e+44)) {
tmp = x * (z / t);
} else {
tmp = x + y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (z <= -1.15e+128) or not (z <= 8e+44): tmp = x * (z / t) else: tmp = x + y return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((z <= -1.15e+128) || !(z <= 8e+44)) tmp = Float64(x * Float64(z / t)); else tmp = Float64(x + y); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((z <= -1.15e+128) || ~((z <= 8e+44))) tmp = x * (z / t); else tmp = x + y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[z, -1.15e+128], N[Not[LessEqual[z, 8e+44]], $MachinePrecision]], N[(x * N[(z / t), $MachinePrecision]), $MachinePrecision], N[(x + y), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.15 \cdot 10^{+128} \lor \neg \left(z \leq 8 \cdot 10^{+44}\right):\\
\;\;\;\;x \cdot \frac{z}{t}\\
\mathbf{else}:\\
\;\;\;\;x + y\\
\end{array}
\end{array}
if z < -1.14999999999999999e128 or 8.0000000000000007e44 < z Initial program 67.2%
+-commutative67.2%
associate-/l*90.2%
fma-define90.3%
Simplified90.3%
Taylor expanded in y around 0 72.4%
+-commutative72.4%
div-sub72.4%
mul-1-neg72.4%
associate-/l*79.6%
distribute-lft-neg-in79.6%
distribute-rgt-in90.2%
sub-neg90.2%
associate-*l/67.2%
associate-*r/82.8%
+-commutative82.8%
fma-define82.8%
Simplified82.8%
clear-num80.9%
associate-/r/82.8%
Applied egg-rr82.8%
Taylor expanded in a around 0 49.1%
Taylor expanded in x around inf 32.9%
associate-/l*39.7%
Simplified39.7%
if -1.14999999999999999e128 < z < 8.0000000000000007e44Initial program 68.5%
Taylor expanded in y around inf 60.9%
*-commutative60.9%
*-lft-identity60.9%
times-frac65.9%
/-rgt-identity65.9%
Simplified65.9%
Taylor expanded in t around inf 42.1%
Final simplification41.3%
(FPCore (x y z t a) :precision binary64 (if (<= z -1.3e+128) (* x (/ z t)) (if (<= z 6.6e+74) (+ x y) (/ y (/ a z)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.3e+128) {
tmp = x * (z / t);
} else if (z <= 6.6e+74) {
tmp = x + y;
} else {
tmp = y / (a / z);
}
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 (z <= (-1.3d+128)) then
tmp = x * (z / t)
else if (z <= 6.6d+74) then
tmp = x + y
else
tmp = y / (a / z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.3e+128) {
tmp = x * (z / t);
} else if (z <= 6.6e+74) {
tmp = x + y;
} else {
tmp = y / (a / z);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -1.3e+128: tmp = x * (z / t) elif z <= 6.6e+74: tmp = x + y else: tmp = y / (a / z) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.3e+128) tmp = Float64(x * Float64(z / t)); elseif (z <= 6.6e+74) tmp = Float64(x + y); else tmp = Float64(y / Float64(a / z)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -1.3e+128) tmp = x * (z / t); elseif (z <= 6.6e+74) tmp = x + y; else tmp = y / (a / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.3e+128], N[(x * N[(z / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 6.6e+74], N[(x + y), $MachinePrecision], N[(y / N[(a / z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.3 \cdot 10^{+128}:\\
\;\;\;\;x \cdot \frac{z}{t}\\
\mathbf{elif}\;z \leq 6.6 \cdot 10^{+74}:\\
\;\;\;\;x + y\\
\mathbf{else}:\\
\;\;\;\;\frac{y}{\frac{a}{z}}\\
\end{array}
\end{array}
if z < -1.3e128Initial program 80.1%
+-commutative80.1%
associate-/l*91.4%
fma-define91.4%
Simplified91.4%
Taylor expanded in y around 0 79.5%
+-commutative79.5%
div-sub79.5%
mul-1-neg79.5%
associate-/l*76.5%
distribute-lft-neg-in76.5%
distribute-rgt-in91.4%
sub-neg91.4%
associate-*l/80.1%
associate-*r/82.7%
+-commutative82.7%
fma-define82.6%
Simplified82.6%
clear-num80.0%
associate-/r/82.7%
Applied egg-rr82.7%
Taylor expanded in a around 0 60.1%
Taylor expanded in x around inf 40.9%
associate-/l*48.9%
Simplified48.9%
if -1.3e128 < z < 6.6000000000000004e74Initial program 68.6%
Taylor expanded in y around inf 60.3%
*-commutative60.3%
*-lft-identity60.3%
times-frac65.2%
/-rgt-identity65.2%
Simplified65.2%
Taylor expanded in t around inf 41.5%
if 6.6000000000000004e74 < z Initial program 58.8%
+-commutative58.8%
associate-/l*90.3%
fma-define90.3%
Simplified90.3%
Taylor expanded in y around 0 70.0%
+-commutative70.0%
div-sub70.0%
mul-1-neg70.0%
associate-/l*83.0%
distribute-lft-neg-in83.0%
distribute-rgt-in90.3%
sub-neg90.3%
associate-*l/58.8%
associate-*r/82.9%
+-commutative82.9%
fma-define83.1%
Simplified83.1%
Taylor expanded in y around inf 51.3%
div-sub51.3%
Simplified51.3%
clear-num51.2%
un-div-inv51.3%
Applied egg-rr51.3%
Taylor expanded in t around 0 36.7%
(FPCore (x y z t a) :precision binary64 (if (<= z -5.2e+129) (* x (/ z t)) (if (<= z 2.05e+71) (+ x y) (* y (/ z a)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -5.2e+129) {
tmp = x * (z / t);
} else if (z <= 2.05e+71) {
tmp = x + y;
} else {
tmp = y * (z / 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 (z <= (-5.2d+129)) then
tmp = x * (z / t)
else if (z <= 2.05d+71) then
tmp = x + y
else
tmp = y * (z / a)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -5.2e+129) {
tmp = x * (z / t);
} else if (z <= 2.05e+71) {
tmp = x + y;
} else {
tmp = y * (z / a);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -5.2e+129: tmp = x * (z / t) elif z <= 2.05e+71: tmp = x + y else: tmp = y * (z / a) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -5.2e+129) tmp = Float64(x * Float64(z / t)); elseif (z <= 2.05e+71) tmp = Float64(x + y); else tmp = Float64(y * Float64(z / a)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -5.2e+129) tmp = x * (z / t); elseif (z <= 2.05e+71) tmp = x + y; else tmp = y * (z / a); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -5.2e+129], N[(x * N[(z / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.05e+71], N[(x + y), $MachinePrecision], N[(y * N[(z / a), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -5.2 \cdot 10^{+129}:\\
\;\;\;\;x \cdot \frac{z}{t}\\
\mathbf{elif}\;z \leq 2.05 \cdot 10^{+71}:\\
\;\;\;\;x + y\\
\mathbf{else}:\\
\;\;\;\;y \cdot \frac{z}{a}\\
\end{array}
\end{array}
if z < -5.20000000000000024e129Initial program 80.1%
+-commutative80.1%
associate-/l*91.4%
fma-define91.4%
Simplified91.4%
Taylor expanded in y around 0 79.5%
+-commutative79.5%
div-sub79.5%
mul-1-neg79.5%
associate-/l*76.5%
distribute-lft-neg-in76.5%
distribute-rgt-in91.4%
sub-neg91.4%
associate-*l/80.1%
associate-*r/82.7%
+-commutative82.7%
fma-define82.6%
Simplified82.6%
clear-num80.0%
associate-/r/82.7%
Applied egg-rr82.7%
Taylor expanded in a around 0 60.1%
Taylor expanded in x around inf 40.9%
associate-/l*48.9%
Simplified48.9%
if -5.20000000000000024e129 < z < 2.0500000000000001e71Initial program 68.6%
Taylor expanded in y around inf 60.3%
*-commutative60.3%
*-lft-identity60.3%
times-frac65.2%
/-rgt-identity65.2%
Simplified65.2%
Taylor expanded in t around inf 41.5%
if 2.0500000000000001e71 < z Initial program 58.8%
+-commutative58.8%
associate-/l*90.3%
fma-define90.3%
Simplified90.3%
Taylor expanded in y around 0 70.0%
+-commutative70.0%
div-sub70.0%
mul-1-neg70.0%
associate-/l*83.0%
distribute-lft-neg-in83.0%
distribute-rgt-in90.3%
sub-neg90.3%
associate-*l/58.8%
associate-*r/82.9%
+-commutative82.9%
fma-define83.1%
Simplified83.1%
Taylor expanded in y around inf 51.3%
div-sub51.3%
Simplified51.3%
Taylor expanded in t around 0 31.7%
associate-/l*36.6%
Simplified36.6%
(FPCore (x y z t a) :precision binary64 (if (<= t -7.2e+103) y (if (<= t 3.9e+76) x y)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -7.2e+103) {
tmp = y;
} else if (t <= 3.9e+76) {
tmp = x;
} else {
tmp = 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 (t <= (-7.2d+103)) then
tmp = y
else if (t <= 3.9d+76) then
tmp = x
else
tmp = y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -7.2e+103) {
tmp = y;
} else if (t <= 3.9e+76) {
tmp = x;
} else {
tmp = y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -7.2e+103: tmp = y elif t <= 3.9e+76: tmp = x else: tmp = y return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -7.2e+103) tmp = y; elseif (t <= 3.9e+76) tmp = x; else tmp = y; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -7.2e+103) tmp = y; elseif (t <= 3.9e+76) tmp = x; else tmp = y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -7.2e+103], y, If[LessEqual[t, 3.9e+76], x, y]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -7.2 \cdot 10^{+103}:\\
\;\;\;\;y\\
\mathbf{elif}\;t \leq 3.9 \cdot 10^{+76}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;y\\
\end{array}
\end{array}
if t < -7.20000000000000033e103 or 3.89999999999999989e76 < t Initial program 37.4%
+-commutative37.4%
associate-/l*67.9%
fma-define67.9%
Simplified67.9%
Taylor expanded in y around 0 57.0%
+-commutative57.0%
div-sub57.0%
mul-1-neg57.0%
associate-/l*67.9%
distribute-lft-neg-in67.9%
distribute-rgt-in67.9%
sub-neg67.9%
associate-*l/37.4%
associate-*r/59.2%
+-commutative59.2%
fma-define59.3%
Simplified59.3%
Taylor expanded in t around inf 46.5%
if -7.20000000000000033e103 < t < 3.89999999999999989e76Initial program 84.7%
+-commutative84.7%
associate-/l*92.0%
fma-define92.0%
Simplified92.0%
Taylor expanded in a around inf 31.7%
(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 68.1%
+-commutative68.1%
associate-/l*83.5%
fma-define83.5%
Simplified83.5%
Taylor expanded in a around inf 24.0%
(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 2024186
(FPCore (x y z t a)
:name "Graphics.Rendering.Chart.Axis.Types:linMap from Chart-1.5.3"
:precision binary64
:alt
(! :herbie-platform default (if (< a -646122513817703/4000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (+ x (* (/ (- y x) 1) (/ (- z t) (- a t)))) (if (< a 1887201585041587/50000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (- y (* (/ z t) (- y x))) (+ x (* (/ (- y x) 1) (/ (- z t) (- a t)))))))
(+ x (/ (* (- y x) (- z t)) (- a t))))