
(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 21 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 (<= t -6.5e+135) (not (<= t 1.65e+80))) (+ y (/ (- x y) (/ t (- z a)))) (+ x (/ (- y x) (/ (- a t) (- z t))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -6.5e+135) || !(t <= 1.65e+80)) {
tmp = y + ((x - y) / (t / (z - a)));
} else {
tmp = x + ((y - x) / ((a - t) / (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 ((t <= (-6.5d+135)) .or. (.not. (t <= 1.65d+80))) then
tmp = y + ((x - y) / (t / (z - a)))
else
tmp = x + ((y - x) / ((a - t) / (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 ((t <= -6.5e+135) || !(t <= 1.65e+80)) {
tmp = y + ((x - y) / (t / (z - a)));
} else {
tmp = x + ((y - x) / ((a - t) / (z - t)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -6.5e+135) or not (t <= 1.65e+80): tmp = y + ((x - y) / (t / (z - a))) else: tmp = x + ((y - x) / ((a - t) / (z - t))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -6.5e+135) || !(t <= 1.65e+80)) tmp = Float64(y + Float64(Float64(x - y) / Float64(t / Float64(z - a)))); else tmp = Float64(x + Float64(Float64(y - x) / Float64(Float64(a - t) / Float64(z - t)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -6.5e+135) || ~((t <= 1.65e+80))) tmp = y + ((x - y) / (t / (z - a))); else tmp = x + ((y - x) / ((a - t) / (z - t))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -6.5e+135], N[Not[LessEqual[t, 1.65e+80]], $MachinePrecision]], N[(y + N[(N[(x - y), $MachinePrecision] / N[(t / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(y - x), $MachinePrecision] / N[(N[(a - t), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -6.5 \cdot 10^{+135} \lor \neg \left(t \leq 1.65 \cdot 10^{+80}\right):\\
\;\;\;\;y + \frac{x - y}{\frac{t}{z - a}}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y - x}{\frac{a - t}{z - t}}\\
\end{array}
\end{array}
if t < -6.5000000000000003e135 or 1.64999999999999995e80 < t Initial program 21.5%
associate-/l*51.5%
clear-num51.3%
associate-/r/51.4%
clear-num51.4%
Applied egg-rr51.4%
Taylor expanded in t around -inf 73.1%
mul-1-neg73.1%
unsub-neg73.1%
div-sub73.1%
*-commutative73.1%
div-sub73.1%
distribute-rgt-out--73.4%
associate-/l*88.5%
Simplified88.5%
if -6.5000000000000003e135 < t < 1.64999999999999995e80Initial program 83.6%
associate-/l*90.7%
Simplified90.7%
Final simplification90.1%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* y (/ (- z t) (- a t)))))
(if (<= t -1.3e+134)
t_1
(if (<= t -7.5e+49)
(- x (/ y (+ (/ a t) -1.0)))
(if (<= t -4e+21)
t_1
(if (<= t 1.45e-89)
(+ x (/ (- y x) (/ a z)))
(if (<= t 1e-23)
(* z (/ (- y x) (- a t)))
(if (<= t 1.3e+80) (+ x (* (- y x) (/ z a))) t_1))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = y * ((z - t) / (a - t));
double tmp;
if (t <= -1.3e+134) {
tmp = t_1;
} else if (t <= -7.5e+49) {
tmp = x - (y / ((a / t) + -1.0));
} else if (t <= -4e+21) {
tmp = t_1;
} else if (t <= 1.45e-89) {
tmp = x + ((y - x) / (a / z));
} else if (t <= 1e-23) {
tmp = z * ((y - x) / (a - t));
} else if (t <= 1.3e+80) {
tmp = x + ((y - x) * (z / a));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = y * ((z - t) / (a - t))
if (t <= (-1.3d+134)) then
tmp = t_1
else if (t <= (-7.5d+49)) then
tmp = x - (y / ((a / t) + (-1.0d0)))
else if (t <= (-4d+21)) then
tmp = t_1
else if (t <= 1.45d-89) then
tmp = x + ((y - x) / (a / z))
else if (t <= 1d-23) then
tmp = z * ((y - x) / (a - t))
else if (t <= 1.3d+80) then
tmp = x + ((y - x) * (z / a))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = y * ((z - t) / (a - t));
double tmp;
if (t <= -1.3e+134) {
tmp = t_1;
} else if (t <= -7.5e+49) {
tmp = x - (y / ((a / t) + -1.0));
} else if (t <= -4e+21) {
tmp = t_1;
} else if (t <= 1.45e-89) {
tmp = x + ((y - x) / (a / z));
} else if (t <= 1e-23) {
tmp = z * ((y - x) / (a - t));
} else if (t <= 1.3e+80) {
tmp = x + ((y - x) * (z / a));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = y * ((z - t) / (a - t)) tmp = 0 if t <= -1.3e+134: tmp = t_1 elif t <= -7.5e+49: tmp = x - (y / ((a / t) + -1.0)) elif t <= -4e+21: tmp = t_1 elif t <= 1.45e-89: tmp = x + ((y - x) / (a / z)) elif t <= 1e-23: tmp = z * ((y - x) / (a - t)) elif t <= 1.3e+80: tmp = x + ((y - x) * (z / a)) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(y * Float64(Float64(z - t) / Float64(a - t))) tmp = 0.0 if (t <= -1.3e+134) tmp = t_1; elseif (t <= -7.5e+49) tmp = Float64(x - Float64(y / Float64(Float64(a / t) + -1.0))); elseif (t <= -4e+21) tmp = t_1; elseif (t <= 1.45e-89) tmp = Float64(x + Float64(Float64(y - x) / Float64(a / z))); elseif (t <= 1e-23) tmp = Float64(z * Float64(Float64(y - x) / Float64(a - t))); elseif (t <= 1.3e+80) tmp = Float64(x + Float64(Float64(y - x) * Float64(z / a))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = y * ((z - t) / (a - t)); tmp = 0.0; if (t <= -1.3e+134) tmp = t_1; elseif (t <= -7.5e+49) tmp = x - (y / ((a / t) + -1.0)); elseif (t <= -4e+21) tmp = t_1; elseif (t <= 1.45e-89) tmp = x + ((y - x) / (a / z)); elseif (t <= 1e-23) tmp = z * ((y - x) / (a - t)); elseif (t <= 1.3e+80) tmp = x + ((y - x) * (z / a)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1.3e+134], t$95$1, If[LessEqual[t, -7.5e+49], N[(x - N[(y / N[(N[(a / t), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, -4e+21], t$95$1, If[LessEqual[t, 1.45e-89], N[(x + N[(N[(y - x), $MachinePrecision] / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1e-23], N[(z * N[(N[(y - x), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.3e+80], N[(x + N[(N[(y - x), $MachinePrecision] * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \frac{z - t}{a - t}\\
\mathbf{if}\;t \leq -1.3 \cdot 10^{+134}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq -7.5 \cdot 10^{+49}:\\
\;\;\;\;x - \frac{y}{\frac{a}{t} + -1}\\
\mathbf{elif}\;t \leq -4 \cdot 10^{+21}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq 1.45 \cdot 10^{-89}:\\
\;\;\;\;x + \frac{y - x}{\frac{a}{z}}\\
\mathbf{elif}\;t \leq 10^{-23}:\\
\;\;\;\;z \cdot \frac{y - x}{a - t}\\
\mathbf{elif}\;t \leq 1.3 \cdot 10^{+80}:\\
\;\;\;\;x + \left(y - x\right) \cdot \frac{z}{a}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if t < -1.3000000000000001e134 or -7.4999999999999995e49 < t < -4e21 or 1.29999999999999991e80 < t Initial program 26.3%
associate-*l/51.3%
Simplified51.3%
Taylor expanded in x around 0 38.4%
associate-*r/69.9%
Simplified69.9%
if -1.3000000000000001e134 < t < -7.4999999999999995e49Initial program 64.2%
associate-*l/82.3%
Simplified82.3%
Taylor expanded in y around inf 68.6%
Taylor expanded in z around 0 61.0%
+-commutative61.0%
mul-1-neg61.0%
unsub-neg61.0%
associate-/l*64.7%
div-sub64.7%
*-inverses64.7%
Simplified64.7%
if -4e21 < t < 1.44999999999999996e-89Initial program 87.4%
associate-*l/91.9%
Simplified91.9%
Taylor expanded in t around 0 72.4%
+-commutative72.4%
associate-/l*79.2%
Simplified79.2%
if 1.44999999999999996e-89 < t < 9.9999999999999996e-24Initial program 84.2%
associate-*l/91.4%
Simplified91.4%
Taylor expanded in z around inf 68.0%
div-sub68.0%
Simplified68.0%
if 9.9999999999999996e-24 < t < 1.29999999999999991e80Initial program 86.6%
associate-/l*90.3%
clear-num90.3%
associate-/r/90.4%
clear-num90.8%
Applied egg-rr90.8%
Taylor expanded in t around 0 61.6%
Final simplification72.8%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* y (/ (- z t) (- a t)))))
(if (<= t -2.7e+132)
t_1
(if (<= t -6.6e+49)
(- x (/ y (+ (/ a t) -1.0)))
(if (<= t -7.2e+23)
t_1
(if (<= t 6e-90)
(+ x (/ (- y x) (/ a z)))
(if (<= t 3.3e-23)
(/ z (/ (- a t) (- y x)))
(if (<= t 1.2e+80) (+ x (* (- y x) (/ z a))) t_1))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = y * ((z - t) / (a - t));
double tmp;
if (t <= -2.7e+132) {
tmp = t_1;
} else if (t <= -6.6e+49) {
tmp = x - (y / ((a / t) + -1.0));
} else if (t <= -7.2e+23) {
tmp = t_1;
} else if (t <= 6e-90) {
tmp = x + ((y - x) / (a / z));
} else if (t <= 3.3e-23) {
tmp = z / ((a - t) / (y - x));
} else if (t <= 1.2e+80) {
tmp = x + ((y - x) * (z / a));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = y * ((z - t) / (a - t))
if (t <= (-2.7d+132)) then
tmp = t_1
else if (t <= (-6.6d+49)) then
tmp = x - (y / ((a / t) + (-1.0d0)))
else if (t <= (-7.2d+23)) then
tmp = t_1
else if (t <= 6d-90) then
tmp = x + ((y - x) / (a / z))
else if (t <= 3.3d-23) then
tmp = z / ((a - t) / (y - x))
else if (t <= 1.2d+80) then
tmp = x + ((y - x) * (z / a))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = y * ((z - t) / (a - t));
double tmp;
if (t <= -2.7e+132) {
tmp = t_1;
} else if (t <= -6.6e+49) {
tmp = x - (y / ((a / t) + -1.0));
} else if (t <= -7.2e+23) {
tmp = t_1;
} else if (t <= 6e-90) {
tmp = x + ((y - x) / (a / z));
} else if (t <= 3.3e-23) {
tmp = z / ((a - t) / (y - x));
} else if (t <= 1.2e+80) {
tmp = x + ((y - x) * (z / a));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = y * ((z - t) / (a - t)) tmp = 0 if t <= -2.7e+132: tmp = t_1 elif t <= -6.6e+49: tmp = x - (y / ((a / t) + -1.0)) elif t <= -7.2e+23: tmp = t_1 elif t <= 6e-90: tmp = x + ((y - x) / (a / z)) elif t <= 3.3e-23: tmp = z / ((a - t) / (y - x)) elif t <= 1.2e+80: tmp = x + ((y - x) * (z / a)) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(y * Float64(Float64(z - t) / Float64(a - t))) tmp = 0.0 if (t <= -2.7e+132) tmp = t_1; elseif (t <= -6.6e+49) tmp = Float64(x - Float64(y / Float64(Float64(a / t) + -1.0))); elseif (t <= -7.2e+23) tmp = t_1; elseif (t <= 6e-90) tmp = Float64(x + Float64(Float64(y - x) / Float64(a / z))); elseif (t <= 3.3e-23) tmp = Float64(z / Float64(Float64(a - t) / Float64(y - x))); elseif (t <= 1.2e+80) tmp = Float64(x + Float64(Float64(y - x) * Float64(z / a))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = y * ((z - t) / (a - t)); tmp = 0.0; if (t <= -2.7e+132) tmp = t_1; elseif (t <= -6.6e+49) tmp = x - (y / ((a / t) + -1.0)); elseif (t <= -7.2e+23) tmp = t_1; elseif (t <= 6e-90) tmp = x + ((y - x) / (a / z)); elseif (t <= 3.3e-23) tmp = z / ((a - t) / (y - x)); elseif (t <= 1.2e+80) tmp = x + ((y - x) * (z / a)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -2.7e+132], t$95$1, If[LessEqual[t, -6.6e+49], N[(x - N[(y / N[(N[(a / t), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, -7.2e+23], t$95$1, If[LessEqual[t, 6e-90], N[(x + N[(N[(y - x), $MachinePrecision] / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 3.3e-23], N[(z / N[(N[(a - t), $MachinePrecision] / N[(y - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.2e+80], N[(x + N[(N[(y - x), $MachinePrecision] * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \frac{z - t}{a - t}\\
\mathbf{if}\;t \leq -2.7 \cdot 10^{+132}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq -6.6 \cdot 10^{+49}:\\
\;\;\;\;x - \frac{y}{\frac{a}{t} + -1}\\
\mathbf{elif}\;t \leq -7.2 \cdot 10^{+23}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq 6 \cdot 10^{-90}:\\
\;\;\;\;x + \frac{y - x}{\frac{a}{z}}\\
\mathbf{elif}\;t \leq 3.3 \cdot 10^{-23}:\\
\;\;\;\;\frac{z}{\frac{a - t}{y - x}}\\
\mathbf{elif}\;t \leq 1.2 \cdot 10^{+80}:\\
\;\;\;\;x + \left(y - x\right) \cdot \frac{z}{a}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if t < -2.7e132 or -6.5999999999999997e49 < t < -7.1999999999999997e23 or 1.1999999999999999e80 < t Initial program 26.3%
associate-*l/51.3%
Simplified51.3%
Taylor expanded in x around 0 38.4%
associate-*r/69.9%
Simplified69.9%
if -2.7e132 < t < -6.5999999999999997e49Initial program 64.2%
associate-*l/82.3%
Simplified82.3%
Taylor expanded in y around inf 68.6%
Taylor expanded in z around 0 61.0%
+-commutative61.0%
mul-1-neg61.0%
unsub-neg61.0%
associate-/l*64.7%
div-sub64.7%
*-inverses64.7%
Simplified64.7%
if -7.1999999999999997e23 < t < 6.00000000000000041e-90Initial program 87.4%
associate-*l/91.9%
Simplified91.9%
Taylor expanded in t around 0 72.4%
+-commutative72.4%
associate-/l*79.2%
Simplified79.2%
if 6.00000000000000041e-90 < t < 3.30000000000000021e-23Initial program 84.2%
associate-/l*91.6%
clear-num91.6%
associate-/r/91.4%
clear-num91.4%
Applied egg-rr91.4%
div-inv91.6%
Applied egg-rr91.6%
Taylor expanded in z around -inf 76.1%
associate-/l*68.2%
Simplified68.2%
if 3.30000000000000021e-23 < t < 1.1999999999999999e80Initial program 86.6%
associate-/l*90.3%
clear-num90.3%
associate-/r/90.4%
clear-num90.8%
Applied egg-rr90.8%
Taylor expanded in t around 0 61.6%
Final simplification72.8%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* x (- 1.0 (/ z a)))))
(if (<= t -1.45e+133)
y
(if (<= t -5.5e+23)
(+ y x)
(if (<= t -4.8e-18)
t_1
(if (<= t -2.15e-36)
(/ y (/ (- a t) z))
(if (<= t -3.7e-51)
t_1
(if (<= t 2e+80) (+ x (/ y (/ a z))) y))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x * (1.0 - (z / a));
double tmp;
if (t <= -1.45e+133) {
tmp = y;
} else if (t <= -5.5e+23) {
tmp = y + x;
} else if (t <= -4.8e-18) {
tmp = t_1;
} else if (t <= -2.15e-36) {
tmp = y / ((a - t) / z);
} else if (t <= -3.7e-51) {
tmp = t_1;
} else if (t <= 2e+80) {
tmp = x + (y / (a / z));
} 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) :: t_1
real(8) :: tmp
t_1 = x * (1.0d0 - (z / a))
if (t <= (-1.45d+133)) then
tmp = y
else if (t <= (-5.5d+23)) then
tmp = y + x
else if (t <= (-4.8d-18)) then
tmp = t_1
else if (t <= (-2.15d-36)) then
tmp = y / ((a - t) / z)
else if (t <= (-3.7d-51)) then
tmp = t_1
else if (t <= 2d+80) then
tmp = x + (y / (a / z))
else
tmp = y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x * (1.0 - (z / a));
double tmp;
if (t <= -1.45e+133) {
tmp = y;
} else if (t <= -5.5e+23) {
tmp = y + x;
} else if (t <= -4.8e-18) {
tmp = t_1;
} else if (t <= -2.15e-36) {
tmp = y / ((a - t) / z);
} else if (t <= -3.7e-51) {
tmp = t_1;
} else if (t <= 2e+80) {
tmp = x + (y / (a / z));
} else {
tmp = y;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x * (1.0 - (z / a)) tmp = 0 if t <= -1.45e+133: tmp = y elif t <= -5.5e+23: tmp = y + x elif t <= -4.8e-18: tmp = t_1 elif t <= -2.15e-36: tmp = y / ((a - t) / z) elif t <= -3.7e-51: tmp = t_1 elif t <= 2e+80: tmp = x + (y / (a / z)) else: tmp = y return tmp
function code(x, y, z, t, a) t_1 = Float64(x * Float64(1.0 - Float64(z / a))) tmp = 0.0 if (t <= -1.45e+133) tmp = y; elseif (t <= -5.5e+23) tmp = Float64(y + x); elseif (t <= -4.8e-18) tmp = t_1; elseif (t <= -2.15e-36) tmp = Float64(y / Float64(Float64(a - t) / z)); elseif (t <= -3.7e-51) tmp = t_1; elseif (t <= 2e+80) tmp = Float64(x + Float64(y / Float64(a / z))); else tmp = y; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x * (1.0 - (z / a)); tmp = 0.0; if (t <= -1.45e+133) tmp = y; elseif (t <= -5.5e+23) tmp = y + x; elseif (t <= -4.8e-18) tmp = t_1; elseif (t <= -2.15e-36) tmp = y / ((a - t) / z); elseif (t <= -3.7e-51) tmp = t_1; elseif (t <= 2e+80) tmp = x + (y / (a / z)); else tmp = y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x * N[(1.0 - N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1.45e+133], y, If[LessEqual[t, -5.5e+23], N[(y + x), $MachinePrecision], If[LessEqual[t, -4.8e-18], t$95$1, If[LessEqual[t, -2.15e-36], N[(y / N[(N[(a - t), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, -3.7e-51], t$95$1, If[LessEqual[t, 2e+80], N[(x + N[(y / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], y]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \left(1 - \frac{z}{a}\right)\\
\mathbf{if}\;t \leq -1.45 \cdot 10^{+133}:\\
\;\;\;\;y\\
\mathbf{elif}\;t \leq -5.5 \cdot 10^{+23}:\\
\;\;\;\;y + x\\
\mathbf{elif}\;t \leq -4.8 \cdot 10^{-18}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq -2.15 \cdot 10^{-36}:\\
\;\;\;\;\frac{y}{\frac{a - t}{z}}\\
\mathbf{elif}\;t \leq -3.7 \cdot 10^{-51}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq 2 \cdot 10^{+80}:\\
\;\;\;\;x + \frac{y}{\frac{a}{z}}\\
\mathbf{else}:\\
\;\;\;\;y\\
\end{array}
\end{array}
if t < -1.4500000000000001e133 or 2e80 < t Initial program 21.5%
associate-*l/48.6%
Simplified48.6%
Taylor expanded in t around inf 59.7%
if -1.4500000000000001e133 < t < -5.50000000000000004e23Initial program 67.8%
associate-*l/82.4%
Simplified82.4%
Taylor expanded in y around inf 68.4%
Taylor expanded in t around inf 43.5%
if -5.50000000000000004e23 < t < -4.79999999999999988e-18 or -2.1500000000000001e-36 < t < -3.69999999999999973e-51Initial program 61.8%
associate-*l/75.8%
Simplified75.8%
Taylor expanded in t around 0 46.2%
Taylor expanded in x around inf 59.8%
*-commutative59.8%
mul-1-neg59.8%
unsub-neg59.8%
Simplified59.8%
if -4.79999999999999988e-18 < t < -2.1500000000000001e-36Initial program 100.0%
associate-*l/99.6%
Simplified99.6%
Taylor expanded in x around 0 100.0%
Taylor expanded in z around inf 76.2%
associate-/l*76.2%
Simplified76.2%
if -3.69999999999999973e-51 < t < 2e80Initial program 89.7%
associate-*l/93.5%
Simplified93.5%
Taylor expanded in t around 0 69.2%
Taylor expanded in y around inf 58.9%
associate-/l*64.3%
Simplified64.3%
Final simplification60.2%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* y (/ (- z t) (- a t)))))
(if (<= t -7.5e+133)
t_1
(if (<= t -3.9e+49)
(- x (/ y (+ (/ a t) -1.0)))
(if (<= t -4.4e+21)
t_1
(if (<= t 1.6e-89)
(+ x (/ (- y x) (/ a z)))
(if (<= t 1.15e+33) (/ (* (- y x) z) (- a t)) t_1)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = y * ((z - t) / (a - t));
double tmp;
if (t <= -7.5e+133) {
tmp = t_1;
} else if (t <= -3.9e+49) {
tmp = x - (y / ((a / t) + -1.0));
} else if (t <= -4.4e+21) {
tmp = t_1;
} else if (t <= 1.6e-89) {
tmp = x + ((y - x) / (a / z));
} else if (t <= 1.15e+33) {
tmp = ((y - x) * z) / (a - t);
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = y * ((z - t) / (a - t))
if (t <= (-7.5d+133)) then
tmp = t_1
else if (t <= (-3.9d+49)) then
tmp = x - (y / ((a / t) + (-1.0d0)))
else if (t <= (-4.4d+21)) then
tmp = t_1
else if (t <= 1.6d-89) then
tmp = x + ((y - x) / (a / z))
else if (t <= 1.15d+33) then
tmp = ((y - x) * z) / (a - t)
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = y * ((z - t) / (a - t));
double tmp;
if (t <= -7.5e+133) {
tmp = t_1;
} else if (t <= -3.9e+49) {
tmp = x - (y / ((a / t) + -1.0));
} else if (t <= -4.4e+21) {
tmp = t_1;
} else if (t <= 1.6e-89) {
tmp = x + ((y - x) / (a / z));
} else if (t <= 1.15e+33) {
tmp = ((y - x) * z) / (a - t);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = y * ((z - t) / (a - t)) tmp = 0 if t <= -7.5e+133: tmp = t_1 elif t <= -3.9e+49: tmp = x - (y / ((a / t) + -1.0)) elif t <= -4.4e+21: tmp = t_1 elif t <= 1.6e-89: tmp = x + ((y - x) / (a / z)) elif t <= 1.15e+33: tmp = ((y - x) * z) / (a - t) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(y * Float64(Float64(z - t) / Float64(a - t))) tmp = 0.0 if (t <= -7.5e+133) tmp = t_1; elseif (t <= -3.9e+49) tmp = Float64(x - Float64(y / Float64(Float64(a / t) + -1.0))); elseif (t <= -4.4e+21) tmp = t_1; elseif (t <= 1.6e-89) tmp = Float64(x + Float64(Float64(y - x) / Float64(a / z))); elseif (t <= 1.15e+33) tmp = Float64(Float64(Float64(y - x) * z) / Float64(a - t)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = y * ((z - t) / (a - t)); tmp = 0.0; if (t <= -7.5e+133) tmp = t_1; elseif (t <= -3.9e+49) tmp = x - (y / ((a / t) + -1.0)); elseif (t <= -4.4e+21) tmp = t_1; elseif (t <= 1.6e-89) tmp = x + ((y - x) / (a / z)); elseif (t <= 1.15e+33) tmp = ((y - x) * z) / (a - t); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -7.5e+133], t$95$1, If[LessEqual[t, -3.9e+49], N[(x - N[(y / N[(N[(a / t), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, -4.4e+21], t$95$1, If[LessEqual[t, 1.6e-89], N[(x + N[(N[(y - x), $MachinePrecision] / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.15e+33], N[(N[(N[(y - x), $MachinePrecision] * z), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \frac{z - t}{a - t}\\
\mathbf{if}\;t \leq -7.5 \cdot 10^{+133}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq -3.9 \cdot 10^{+49}:\\
\;\;\;\;x - \frac{y}{\frac{a}{t} + -1}\\
\mathbf{elif}\;t \leq -4.4 \cdot 10^{+21}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq 1.6 \cdot 10^{-89}:\\
\;\;\;\;x + \frac{y - x}{\frac{a}{z}}\\
\mathbf{elif}\;t \leq 1.15 \cdot 10^{+33}:\\
\;\;\;\;\frac{\left(y - x\right) \cdot z}{a - t}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if t < -7.49999999999999992e133 or -3.9000000000000001e49 < t < -4.4e21 or 1.15000000000000005e33 < t Initial program 31.0%
associate-*l/54.7%
Simplified54.7%
Taylor expanded in x around 0 39.6%
associate-*r/68.2%
Simplified68.2%
if -7.49999999999999992e133 < t < -3.9000000000000001e49Initial program 64.2%
associate-*l/82.3%
Simplified82.3%
Taylor expanded in y around inf 68.6%
Taylor expanded in z around 0 61.0%
+-commutative61.0%
mul-1-neg61.0%
unsub-neg61.0%
associate-/l*64.7%
div-sub64.7%
*-inverses64.7%
Simplified64.7%
if -4.4e21 < t < 1.59999999999999999e-89Initial program 87.4%
associate-*l/91.9%
Simplified91.9%
Taylor expanded in t around 0 72.4%
+-commutative72.4%
associate-/l*79.2%
Simplified79.2%
if 1.59999999999999999e-89 < t < 1.15000000000000005e33Initial program 88.6%
associate-*l/92.2%
Simplified92.2%
Taylor expanded in z around -inf 64.7%
Final simplification72.5%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* (- z t) (/ y (- a t))))) (t_2 (* y (/ (- z t) (- a t)))))
(if (<= t -1.15e+135)
t_2
(if (<= t -3.5e+24)
t_1
(if (<= t 5.7e-111)
(+ x (/ (- y x) (/ a z)))
(if (<= t 2.2e+80) t_1 t_2))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((z - t) * (y / (a - t)));
double t_2 = y * ((z - t) / (a - t));
double tmp;
if (t <= -1.15e+135) {
tmp = t_2;
} else if (t <= -3.5e+24) {
tmp = t_1;
} else if (t <= 5.7e-111) {
tmp = x + ((y - x) / (a / z));
} else if (t <= 2.2e+80) {
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 + ((z - t) * (y / (a - t)))
t_2 = y * ((z - t) / (a - t))
if (t <= (-1.15d+135)) then
tmp = t_2
else if (t <= (-3.5d+24)) then
tmp = t_1
else if (t <= 5.7d-111) then
tmp = x + ((y - x) / (a / z))
else if (t <= 2.2d+80) 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 + ((z - t) * (y / (a - t)));
double t_2 = y * ((z - t) / (a - t));
double tmp;
if (t <= -1.15e+135) {
tmp = t_2;
} else if (t <= -3.5e+24) {
tmp = t_1;
} else if (t <= 5.7e-111) {
tmp = x + ((y - x) / (a / z));
} else if (t <= 2.2e+80) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((z - t) * (y / (a - t))) t_2 = y * ((z - t) / (a - t)) tmp = 0 if t <= -1.15e+135: tmp = t_2 elif t <= -3.5e+24: tmp = t_1 elif t <= 5.7e-111: tmp = x + ((y - x) / (a / z)) elif t <= 2.2e+80: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(z - t) * Float64(y / Float64(a - t)))) t_2 = Float64(y * Float64(Float64(z - t) / Float64(a - t))) tmp = 0.0 if (t <= -1.15e+135) tmp = t_2; elseif (t <= -3.5e+24) tmp = t_1; elseif (t <= 5.7e-111) tmp = Float64(x + Float64(Float64(y - x) / Float64(a / z))); elseif (t <= 2.2e+80) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + ((z - t) * (y / (a - t))); t_2 = y * ((z - t) / (a - t)); tmp = 0.0; if (t <= -1.15e+135) tmp = t_2; elseif (t <= -3.5e+24) tmp = t_1; elseif (t <= 5.7e-111) tmp = x + ((y - x) / (a / z)); elseif (t <= 2.2e+80) 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[(z - t), $MachinePrecision] * N[(y / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1.15e+135], t$95$2, If[LessEqual[t, -3.5e+24], t$95$1, If[LessEqual[t, 5.7e-111], N[(x + N[(N[(y - x), $MachinePrecision] / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.2e+80], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \left(z - t\right) \cdot \frac{y}{a - t}\\
t_2 := y \cdot \frac{z - t}{a - t}\\
\mathbf{if}\;t \leq -1.15 \cdot 10^{+135}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;t \leq -3.5 \cdot 10^{+24}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq 5.7 \cdot 10^{-111}:\\
\;\;\;\;x + \frac{y - x}{\frac{a}{z}}\\
\mathbf{elif}\;t \leq 2.2 \cdot 10^{+80}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
if t < -1.1500000000000001e135 or 2.20000000000000003e80 < t Initial program 21.5%
associate-*l/48.6%
Simplified48.6%
Taylor expanded in x around 0 34.6%
associate-*r/68.7%
Simplified68.7%
if -1.1500000000000001e135 < t < -3.5000000000000002e24 or 5.7e-111 < t < 2.20000000000000003e80Initial program 77.6%
associate-*l/86.4%
Simplified86.4%
Taylor expanded in y around inf 67.4%
if -3.5000000000000002e24 < t < 5.7e-111Initial program 87.9%
associate-*l/92.8%
Simplified92.8%
Taylor expanded in t around 0 73.3%
+-commutative73.3%
associate-/l*80.7%
Simplified80.7%
Final simplification73.3%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* x (- 1.0 (/ z a)))))
(if (<= t -1.55e+135)
y
(if (<= t -2.9e+24)
(+ y x)
(if (<= t -3.2e-20)
t_1
(if (<= t -9e-37) (* y (/ z a)) (if (<= t 1.2e+80) t_1 y)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x * (1.0 - (z / a));
double tmp;
if (t <= -1.55e+135) {
tmp = y;
} else if (t <= -2.9e+24) {
tmp = y + x;
} else if (t <= -3.2e-20) {
tmp = t_1;
} else if (t <= -9e-37) {
tmp = y * (z / a);
} else if (t <= 1.2e+80) {
tmp = t_1;
} 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) :: t_1
real(8) :: tmp
t_1 = x * (1.0d0 - (z / a))
if (t <= (-1.55d+135)) then
tmp = y
else if (t <= (-2.9d+24)) then
tmp = y + x
else if (t <= (-3.2d-20)) then
tmp = t_1
else if (t <= (-9d-37)) then
tmp = y * (z / a)
else if (t <= 1.2d+80) then
tmp = t_1
else
tmp = y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x * (1.0 - (z / a));
double tmp;
if (t <= -1.55e+135) {
tmp = y;
} else if (t <= -2.9e+24) {
tmp = y + x;
} else if (t <= -3.2e-20) {
tmp = t_1;
} else if (t <= -9e-37) {
tmp = y * (z / a);
} else if (t <= 1.2e+80) {
tmp = t_1;
} else {
tmp = y;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x * (1.0 - (z / a)) tmp = 0 if t <= -1.55e+135: tmp = y elif t <= -2.9e+24: tmp = y + x elif t <= -3.2e-20: tmp = t_1 elif t <= -9e-37: tmp = y * (z / a) elif t <= 1.2e+80: tmp = t_1 else: tmp = y return tmp
function code(x, y, z, t, a) t_1 = Float64(x * Float64(1.0 - Float64(z / a))) tmp = 0.0 if (t <= -1.55e+135) tmp = y; elseif (t <= -2.9e+24) tmp = Float64(y + x); elseif (t <= -3.2e-20) tmp = t_1; elseif (t <= -9e-37) tmp = Float64(y * Float64(z / a)); elseif (t <= 1.2e+80) tmp = t_1; else tmp = y; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x * (1.0 - (z / a)); tmp = 0.0; if (t <= -1.55e+135) tmp = y; elseif (t <= -2.9e+24) tmp = y + x; elseif (t <= -3.2e-20) tmp = t_1; elseif (t <= -9e-37) tmp = y * (z / a); elseif (t <= 1.2e+80) tmp = t_1; else tmp = y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x * N[(1.0 - N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1.55e+135], y, If[LessEqual[t, -2.9e+24], N[(y + x), $MachinePrecision], If[LessEqual[t, -3.2e-20], t$95$1, If[LessEqual[t, -9e-37], N[(y * N[(z / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.2e+80], t$95$1, y]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \left(1 - \frac{z}{a}\right)\\
\mathbf{if}\;t \leq -1.55 \cdot 10^{+135}:\\
\;\;\;\;y\\
\mathbf{elif}\;t \leq -2.9 \cdot 10^{+24}:\\
\;\;\;\;y + x\\
\mathbf{elif}\;t \leq -3.2 \cdot 10^{-20}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq -9 \cdot 10^{-37}:\\
\;\;\;\;y \cdot \frac{z}{a}\\
\mathbf{elif}\;t \leq 1.2 \cdot 10^{+80}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;y\\
\end{array}
\end{array}
if t < -1.55000000000000011e135 or 1.1999999999999999e80 < t Initial program 21.5%
associate-*l/48.6%
Simplified48.6%
Taylor expanded in t around inf 59.7%
if -1.55000000000000011e135 < t < -2.89999999999999979e24Initial program 67.8%
associate-*l/82.4%
Simplified82.4%
Taylor expanded in y around inf 68.4%
Taylor expanded in t around inf 43.5%
if -2.89999999999999979e24 < t < -3.1999999999999997e-20 or -9.00000000000000081e-37 < t < 1.1999999999999999e80Initial program 86.7%
associate-*l/91.6%
Simplified91.6%
Taylor expanded in t around 0 66.7%
Taylor expanded in x around inf 55.6%
*-commutative55.6%
mul-1-neg55.6%
unsub-neg55.6%
Simplified55.6%
if -3.1999999999999997e-20 < t < -9.00000000000000081e-37Initial program 100.0%
associate-*l/99.6%
Simplified99.6%
Taylor expanded in x around 0 100.0%
Taylor expanded in t around 0 51.6%
associate-/l*51.6%
Simplified51.6%
div-inv51.6%
clear-num51.6%
Applied egg-rr51.6%
Final simplification55.1%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* x (- 1.0 (/ z a)))))
(if (<= t -1.35e+136)
y
(if (<= t -1.05e+22)
(+ y x)
(if (<= t -3.2e-20)
t_1
(if (<= t -3.85e-84)
(* z (/ (- y x) a))
(if (<= t 1.7e+80) t_1 y)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x * (1.0 - (z / a));
double tmp;
if (t <= -1.35e+136) {
tmp = y;
} else if (t <= -1.05e+22) {
tmp = y + x;
} else if (t <= -3.2e-20) {
tmp = t_1;
} else if (t <= -3.85e-84) {
tmp = z * ((y - x) / a);
} else if (t <= 1.7e+80) {
tmp = t_1;
} 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) :: t_1
real(8) :: tmp
t_1 = x * (1.0d0 - (z / a))
if (t <= (-1.35d+136)) then
tmp = y
else if (t <= (-1.05d+22)) then
tmp = y + x
else if (t <= (-3.2d-20)) then
tmp = t_1
else if (t <= (-3.85d-84)) then
tmp = z * ((y - x) / a)
else if (t <= 1.7d+80) then
tmp = t_1
else
tmp = y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x * (1.0 - (z / a));
double tmp;
if (t <= -1.35e+136) {
tmp = y;
} else if (t <= -1.05e+22) {
tmp = y + x;
} else if (t <= -3.2e-20) {
tmp = t_1;
} else if (t <= -3.85e-84) {
tmp = z * ((y - x) / a);
} else if (t <= 1.7e+80) {
tmp = t_1;
} else {
tmp = y;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x * (1.0 - (z / a)) tmp = 0 if t <= -1.35e+136: tmp = y elif t <= -1.05e+22: tmp = y + x elif t <= -3.2e-20: tmp = t_1 elif t <= -3.85e-84: tmp = z * ((y - x) / a) elif t <= 1.7e+80: tmp = t_1 else: tmp = y return tmp
function code(x, y, z, t, a) t_1 = Float64(x * Float64(1.0 - Float64(z / a))) tmp = 0.0 if (t <= -1.35e+136) tmp = y; elseif (t <= -1.05e+22) tmp = Float64(y + x); elseif (t <= -3.2e-20) tmp = t_1; elseif (t <= -3.85e-84) tmp = Float64(z * Float64(Float64(y - x) / a)); elseif (t <= 1.7e+80) tmp = t_1; else tmp = y; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x * (1.0 - (z / a)); tmp = 0.0; if (t <= -1.35e+136) tmp = y; elseif (t <= -1.05e+22) tmp = y + x; elseif (t <= -3.2e-20) tmp = t_1; elseif (t <= -3.85e-84) tmp = z * ((y - x) / a); elseif (t <= 1.7e+80) tmp = t_1; else tmp = y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x * N[(1.0 - N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1.35e+136], y, If[LessEqual[t, -1.05e+22], N[(y + x), $MachinePrecision], If[LessEqual[t, -3.2e-20], t$95$1, If[LessEqual[t, -3.85e-84], N[(z * N[(N[(y - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.7e+80], t$95$1, y]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \left(1 - \frac{z}{a}\right)\\
\mathbf{if}\;t \leq -1.35 \cdot 10^{+136}:\\
\;\;\;\;y\\
\mathbf{elif}\;t \leq -1.05 \cdot 10^{+22}:\\
\;\;\;\;y + x\\
\mathbf{elif}\;t \leq -3.2 \cdot 10^{-20}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq -3.85 \cdot 10^{-84}:\\
\;\;\;\;z \cdot \frac{y - x}{a}\\
\mathbf{elif}\;t \leq 1.7 \cdot 10^{+80}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;y\\
\end{array}
\end{array}
if t < -1.3500000000000001e136 or 1.69999999999999996e80 < t Initial program 21.5%
associate-*l/48.6%
Simplified48.6%
Taylor expanded in t around inf 59.7%
if -1.3500000000000001e136 < t < -1.0499999999999999e22Initial program 67.8%
associate-*l/82.4%
Simplified82.4%
Taylor expanded in y around inf 68.4%
Taylor expanded in t around inf 43.5%
if -1.0499999999999999e22 < t < -3.1999999999999997e-20 or -3.85e-84 < t < 1.69999999999999996e80Initial program 87.0%
associate-*l/90.9%
Simplified90.9%
Taylor expanded in t around 0 68.0%
Taylor expanded in x around inf 56.0%
*-commutative56.0%
mul-1-neg56.0%
unsub-neg56.0%
Simplified56.0%
if -3.1999999999999997e-20 < t < -3.85e-84Initial program 87.1%
associate-*l/99.9%
Simplified99.9%
Taylor expanded in t around 0 50.9%
Taylor expanded in z around inf 54.9%
div-sub54.9%
Simplified54.9%
Final simplification55.4%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* (- y x) (/ z a)))) (t_2 (* y (/ (- z t) (- a t)))))
(if (<= t -3.2e+23)
t_2
(if (<= t 1.4e-89)
t_1
(if (<= t 2.4e-24)
(* z (/ (- y x) (- a t)))
(if (<= t 1.16e+80) t_1 t_2))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((y - x) * (z / a));
double t_2 = y * ((z - t) / (a - t));
double tmp;
if (t <= -3.2e+23) {
tmp = t_2;
} else if (t <= 1.4e-89) {
tmp = t_1;
} else if (t <= 2.4e-24) {
tmp = z * ((y - x) / (a - t));
} else if (t <= 1.16e+80) {
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 + ((y - x) * (z / a))
t_2 = y * ((z - t) / (a - t))
if (t <= (-3.2d+23)) then
tmp = t_2
else if (t <= 1.4d-89) then
tmp = t_1
else if (t <= 2.4d-24) then
tmp = z * ((y - x) / (a - t))
else if (t <= 1.16d+80) 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 + ((y - x) * (z / a));
double t_2 = y * ((z - t) / (a - t));
double tmp;
if (t <= -3.2e+23) {
tmp = t_2;
} else if (t <= 1.4e-89) {
tmp = t_1;
} else if (t <= 2.4e-24) {
tmp = z * ((y - x) / (a - t));
} else if (t <= 1.16e+80) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((y - x) * (z / a)) t_2 = y * ((z - t) / (a - t)) tmp = 0 if t <= -3.2e+23: tmp = t_2 elif t <= 1.4e-89: tmp = t_1 elif t <= 2.4e-24: tmp = z * ((y - x) / (a - t)) elif t <= 1.16e+80: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(y - x) * Float64(z / a))) t_2 = Float64(y * Float64(Float64(z - t) / Float64(a - t))) tmp = 0.0 if (t <= -3.2e+23) tmp = t_2; elseif (t <= 1.4e-89) tmp = t_1; elseif (t <= 2.4e-24) tmp = Float64(z * Float64(Float64(y - x) / Float64(a - t))); elseif (t <= 1.16e+80) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + ((y - x) * (z / a)); t_2 = y * ((z - t) / (a - t)); tmp = 0.0; if (t <= -3.2e+23) tmp = t_2; elseif (t <= 1.4e-89) tmp = t_1; elseif (t <= 2.4e-24) tmp = z * ((y - x) / (a - t)); elseif (t <= 1.16e+80) 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[(y - x), $MachinePrecision] * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -3.2e+23], t$95$2, If[LessEqual[t, 1.4e-89], t$95$1, If[LessEqual[t, 2.4e-24], N[(z * N[(N[(y - x), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.16e+80], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \left(y - x\right) \cdot \frac{z}{a}\\
t_2 := y \cdot \frac{z - t}{a - t}\\
\mathbf{if}\;t \leq -3.2 \cdot 10^{+23}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;t \leq 1.4 \cdot 10^{-89}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq 2.4 \cdot 10^{-24}:\\
\;\;\;\;z \cdot \frac{y - x}{a - t}\\
\mathbf{elif}\;t \leq 1.16 \cdot 10^{+80}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t_2\\
\end{array}
\end{array}
if t < -3.2e23 or 1.15999999999999997e80 < t Initial program 36.1%
associate-*l/59.3%
Simplified59.3%
Taylor expanded in x around 0 40.3%
associate-*r/63.9%
Simplified63.9%
if -3.2e23 < t < 1.3999999999999999e-89 or 2.3999999999999998e-24 < t < 1.15999999999999997e80Initial program 87.3%
associate-/l*91.8%
clear-num91.9%
associate-/r/91.3%
clear-num91.4%
Applied egg-rr91.4%
Taylor expanded in t around 0 75.8%
if 1.3999999999999999e-89 < t < 2.3999999999999998e-24Initial program 84.2%
associate-*l/91.4%
Simplified91.4%
Taylor expanded in z around inf 68.0%
div-sub68.0%
Simplified68.0%
Final simplification70.6%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* y (/ (- z t) (- a t)))))
(if (<= t -1.3e+22)
t_1
(if (<= t 1.05e-89)
(+ x (/ (- y x) (/ a z)))
(if (<= t 1.7e-24)
(* z (/ (- y x) (- a t)))
(if (<= t 1.16e+80) (+ x (* (- y x) (/ z a))) t_1))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = y * ((z - t) / (a - t));
double tmp;
if (t <= -1.3e+22) {
tmp = t_1;
} else if (t <= 1.05e-89) {
tmp = x + ((y - x) / (a / z));
} else if (t <= 1.7e-24) {
tmp = z * ((y - x) / (a - t));
} else if (t <= 1.16e+80) {
tmp = x + ((y - x) * (z / a));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = y * ((z - t) / (a - t))
if (t <= (-1.3d+22)) then
tmp = t_1
else if (t <= 1.05d-89) then
tmp = x + ((y - x) / (a / z))
else if (t <= 1.7d-24) then
tmp = z * ((y - x) / (a - t))
else if (t <= 1.16d+80) then
tmp = x + ((y - x) * (z / a))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = y * ((z - t) / (a - t));
double tmp;
if (t <= -1.3e+22) {
tmp = t_1;
} else if (t <= 1.05e-89) {
tmp = x + ((y - x) / (a / z));
} else if (t <= 1.7e-24) {
tmp = z * ((y - x) / (a - t));
} else if (t <= 1.16e+80) {
tmp = x + ((y - x) * (z / a));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = y * ((z - t) / (a - t)) tmp = 0 if t <= -1.3e+22: tmp = t_1 elif t <= 1.05e-89: tmp = x + ((y - x) / (a / z)) elif t <= 1.7e-24: tmp = z * ((y - x) / (a - t)) elif t <= 1.16e+80: tmp = x + ((y - x) * (z / a)) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(y * Float64(Float64(z - t) / Float64(a - t))) tmp = 0.0 if (t <= -1.3e+22) tmp = t_1; elseif (t <= 1.05e-89) tmp = Float64(x + Float64(Float64(y - x) / Float64(a / z))); elseif (t <= 1.7e-24) tmp = Float64(z * Float64(Float64(y - x) / Float64(a - t))); elseif (t <= 1.16e+80) tmp = Float64(x + Float64(Float64(y - x) * Float64(z / a))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = y * ((z - t) / (a - t)); tmp = 0.0; if (t <= -1.3e+22) tmp = t_1; elseif (t <= 1.05e-89) tmp = x + ((y - x) / (a / z)); elseif (t <= 1.7e-24) tmp = z * ((y - x) / (a - t)); elseif (t <= 1.16e+80) tmp = x + ((y - x) * (z / a)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1.3e+22], t$95$1, If[LessEqual[t, 1.05e-89], N[(x + N[(N[(y - x), $MachinePrecision] / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.7e-24], N[(z * N[(N[(y - x), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.16e+80], N[(x + N[(N[(y - x), $MachinePrecision] * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \frac{z - t}{a - t}\\
\mathbf{if}\;t \leq -1.3 \cdot 10^{+22}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq 1.05 \cdot 10^{-89}:\\
\;\;\;\;x + \frac{y - x}{\frac{a}{z}}\\
\mathbf{elif}\;t \leq 1.7 \cdot 10^{-24}:\\
\;\;\;\;z \cdot \frac{y - x}{a - t}\\
\mathbf{elif}\;t \leq 1.16 \cdot 10^{+80}:\\
\;\;\;\;x + \left(y - x\right) \cdot \frac{z}{a}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if t < -1.3e22 or 1.15999999999999997e80 < t Initial program 36.1%
associate-*l/59.3%
Simplified59.3%
Taylor expanded in x around 0 40.3%
associate-*r/63.9%
Simplified63.9%
if -1.3e22 < t < 1.05e-89Initial program 87.4%
associate-*l/91.9%
Simplified91.9%
Taylor expanded in t around 0 72.4%
+-commutative72.4%
associate-/l*79.2%
Simplified79.2%
if 1.05e-89 < t < 1.69999999999999996e-24Initial program 84.2%
associate-*l/91.4%
Simplified91.4%
Taylor expanded in z around inf 68.0%
div-sub68.0%
Simplified68.0%
if 1.69999999999999996e-24 < t < 1.15999999999999997e80Initial program 86.6%
associate-/l*90.3%
clear-num90.3%
associate-/r/90.4%
clear-num90.8%
Applied egg-rr90.8%
Taylor expanded in t around 0 61.6%
Final simplification70.8%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -6.5e+135) (not (<= t 2.2e+80))) (+ y (/ (- x y) (/ t (- z a)))) (+ x (* (- z t) (/ (- y x) (- a t))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -6.5e+135) || !(t <= 2.2e+80)) {
tmp = y + ((x - y) / (t / (z - a)));
} else {
tmp = x + ((z - t) * ((y - x) / (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 ((t <= (-6.5d+135)) .or. (.not. (t <= 2.2d+80))) then
tmp = y + ((x - y) / (t / (z - a)))
else
tmp = x + ((z - t) * ((y - x) / (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 ((t <= -6.5e+135) || !(t <= 2.2e+80)) {
tmp = y + ((x - y) / (t / (z - a)));
} else {
tmp = x + ((z - t) * ((y - x) / (a - t)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -6.5e+135) or not (t <= 2.2e+80): tmp = y + ((x - y) / (t / (z - a))) else: tmp = x + ((z - t) * ((y - x) / (a - t))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -6.5e+135) || !(t <= 2.2e+80)) tmp = Float64(y + Float64(Float64(x - y) / Float64(t / Float64(z - a)))); else tmp = Float64(x + Float64(Float64(z - t) * Float64(Float64(y - x) / Float64(a - t)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -6.5e+135) || ~((t <= 2.2e+80))) tmp = y + ((x - y) / (t / (z - a))); else tmp = x + ((z - t) * ((y - x) / (a - t))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -6.5e+135], N[Not[LessEqual[t, 2.2e+80]], $MachinePrecision]], N[(y + N[(N[(x - y), $MachinePrecision] / N[(t / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(z - t), $MachinePrecision] * N[(N[(y - x), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -6.5 \cdot 10^{+135} \lor \neg \left(t \leq 2.2 \cdot 10^{+80}\right):\\
\;\;\;\;y + \frac{x - y}{\frac{t}{z - a}}\\
\mathbf{else}:\\
\;\;\;\;x + \left(z - t\right) \cdot \frac{y - x}{a - t}\\
\end{array}
\end{array}
if t < -6.5000000000000003e135 or 2.20000000000000003e80 < t Initial program 21.5%
associate-/l*51.5%
clear-num51.3%
associate-/r/51.4%
clear-num51.4%
Applied egg-rr51.4%
Taylor expanded in t around -inf 73.1%
mul-1-neg73.1%
unsub-neg73.1%
div-sub73.1%
*-commutative73.1%
div-sub73.1%
distribute-rgt-out--73.4%
associate-/l*88.5%
Simplified88.5%
if -6.5000000000000003e135 < t < 2.20000000000000003e80Initial program 83.6%
associate-*l/90.1%
Simplified90.1%
Final simplification89.7%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -4.5e+132) (not (<= t 2.2e+80))) (+ y (/ (- x y) (/ t (- z a)))) (+ x (* (- y x) (/ (- z t) (- a t))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -4.5e+132) || !(t <= 2.2e+80)) {
tmp = y + ((x - y) / (t / (z - a)));
} else {
tmp = x + ((y - x) * ((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 ((t <= (-4.5d+132)) .or. (.not. (t <= 2.2d+80))) then
tmp = y + ((x - y) / (t / (z - a)))
else
tmp = x + ((y - x) * ((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 ((t <= -4.5e+132) || !(t <= 2.2e+80)) {
tmp = y + ((x - y) / (t / (z - a)));
} else {
tmp = x + ((y - x) * ((z - t) / (a - t)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -4.5e+132) or not (t <= 2.2e+80): tmp = y + ((x - y) / (t / (z - a))) else: tmp = x + ((y - x) * ((z - t) / (a - t))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -4.5e+132) || !(t <= 2.2e+80)) tmp = Float64(y + Float64(Float64(x - y) / Float64(t / Float64(z - a)))); else tmp = Float64(x + Float64(Float64(y - x) * Float64(Float64(z - t) / Float64(a - t)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -4.5e+132) || ~((t <= 2.2e+80))) tmp = y + ((x - y) / (t / (z - a))); else tmp = x + ((y - x) * ((z - t) / (a - t))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -4.5e+132], N[Not[LessEqual[t, 2.2e+80]], $MachinePrecision]], N[(y + N[(N[(x - y), $MachinePrecision] / N[(t / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(y - x), $MachinePrecision] * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.5 \cdot 10^{+132} \lor \neg \left(t \leq 2.2 \cdot 10^{+80}\right):\\
\;\;\;\;y + \frac{x - y}{\frac{t}{z - a}}\\
\mathbf{else}:\\
\;\;\;\;x + \left(y - x\right) \cdot \frac{z - t}{a - t}\\
\end{array}
\end{array}
if t < -4.49999999999999972e132 or 2.20000000000000003e80 < t Initial program 21.5%
associate-/l*51.5%
clear-num51.3%
associate-/r/51.4%
clear-num51.4%
Applied egg-rr51.4%
Taylor expanded in t around -inf 73.1%
mul-1-neg73.1%
unsub-neg73.1%
div-sub73.1%
*-commutative73.1%
div-sub73.1%
distribute-rgt-out--73.4%
associate-/l*88.5%
Simplified88.5%
if -4.49999999999999972e132 < t < 2.20000000000000003e80Initial program 83.6%
associate-/l*90.7%
clear-num90.6%
associate-/r/90.3%
clear-num90.4%
Applied egg-rr90.4%
Final simplification89.8%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* y (/ (- z t) (- a t)))))
(if (<= t -5e-97)
t_1
(if (<= t 1.05e-89)
(+ x (/ y (/ a z)))
(if (<= t 1.9e+36) (* z (/ (- y x) (- a t))) t_1)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = y * ((z - t) / (a - t));
double tmp;
if (t <= -5e-97) {
tmp = t_1;
} else if (t <= 1.05e-89) {
tmp = x + (y / (a / z));
} else if (t <= 1.9e+36) {
tmp = z * ((y - x) / (a - t));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = y * ((z - t) / (a - t))
if (t <= (-5d-97)) then
tmp = t_1
else if (t <= 1.05d-89) then
tmp = x + (y / (a / z))
else if (t <= 1.9d+36) then
tmp = z * ((y - x) / (a - t))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = y * ((z - t) / (a - t));
double tmp;
if (t <= -5e-97) {
tmp = t_1;
} else if (t <= 1.05e-89) {
tmp = x + (y / (a / z));
} else if (t <= 1.9e+36) {
tmp = z * ((y - x) / (a - t));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = y * ((z - t) / (a - t)) tmp = 0 if t <= -5e-97: tmp = t_1 elif t <= 1.05e-89: tmp = x + (y / (a / z)) elif t <= 1.9e+36: tmp = z * ((y - x) / (a - t)) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(y * Float64(Float64(z - t) / Float64(a - t))) tmp = 0.0 if (t <= -5e-97) tmp = t_1; elseif (t <= 1.05e-89) tmp = Float64(x + Float64(y / Float64(a / z))); elseif (t <= 1.9e+36) tmp = Float64(z * Float64(Float64(y - x) / Float64(a - t))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = y * ((z - t) / (a - t)); tmp = 0.0; if (t <= -5e-97) tmp = t_1; elseif (t <= 1.05e-89) tmp = x + (y / (a / z)); elseif (t <= 1.9e+36) tmp = z * ((y - x) / (a - t)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -5e-97], t$95$1, If[LessEqual[t, 1.05e-89], N[(x + N[(y / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.9e+36], N[(z * N[(N[(y - x), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \frac{z - t}{a - t}\\
\mathbf{if}\;t \leq -5 \cdot 10^{-97}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq 1.05 \cdot 10^{-89}:\\
\;\;\;\;x + \frac{y}{\frac{a}{z}}\\
\mathbf{elif}\;t \leq 1.9 \cdot 10^{+36}:\\
\;\;\;\;z \cdot \frac{y - x}{a - t}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if t < -4.9999999999999995e-97 or 1.90000000000000012e36 < t Initial program 47.0%
associate-*l/65.8%
Simplified65.8%
Taylor expanded in x around 0 42.5%
associate-*r/59.9%
Simplified59.9%
if -4.9999999999999995e-97 < t < 1.05e-89Initial program 90.3%
associate-*l/94.8%
Simplified94.8%
Taylor expanded in t around 0 79.3%
Taylor expanded in y around inf 66.3%
associate-/l*74.4%
Simplified74.4%
if 1.05e-89 < t < 1.90000000000000012e36Initial program 88.6%
associate-*l/92.2%
Simplified92.2%
Taylor expanded in z around inf 61.0%
div-sub61.0%
Simplified61.0%
Final simplification65.0%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -4.4e-18) (not (<= a 4e-51))) (+ 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 <= -4.4e-18) || !(a <= 4e-51)) {
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 <= (-4.4d-18)) .or. (.not. (a <= 4d-51))) 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 <= -4.4e-18) || !(a <= 4e-51)) {
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 <= -4.4e-18) or not (a <= 4e-51): 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 <= -4.4e-18) || !(a <= 4e-51)) 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 <= -4.4e-18) || ~((a <= 4e-51))) 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, -4.4e-18], N[Not[LessEqual[a, 4e-51]], $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 -4.4 \cdot 10^{-18} \lor \neg \left(a \leq 4 \cdot 10^{-51}\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 < -4.3999999999999997e-18 or 4e-51 < a Initial program 70.3%
associate-*l/87.2%
Simplified87.2%
Taylor expanded in y around inf 76.5%
if -4.3999999999999997e-18 < a < 4e-51Initial program 60.6%
associate-*l/66.8%
Simplified66.8%
Taylor expanded in t around -inf 82.1%
mul-1-neg82.1%
unsub-neg82.1%
div-sub81.2%
*-commutative81.2%
div-sub82.1%
distribute-rgt-out--82.1%
Simplified82.1%
Final simplification78.9%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -2.15e+22) (not (<= a 1.05e-50))) (+ x (* (- z t) (/ y (- a t)))) (+ y (/ (- x y) (/ t (- z a))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -2.15e+22) || !(a <= 1.05e-50)) {
tmp = x + ((z - t) * (y / (a - t)));
} else {
tmp = y + ((x - y) / (t / (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 ((a <= (-2.15d+22)) .or. (.not. (a <= 1.05d-50))) then
tmp = x + ((z - t) * (y / (a - t)))
else
tmp = y + ((x - y) / (t / (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 ((a <= -2.15e+22) || !(a <= 1.05e-50)) {
tmp = x + ((z - t) * (y / (a - t)));
} else {
tmp = y + ((x - y) / (t / (z - a)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -2.15e+22) or not (a <= 1.05e-50): tmp = x + ((z - t) * (y / (a - t))) else: tmp = y + ((x - y) / (t / (z - a))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -2.15e+22) || !(a <= 1.05e-50)) tmp = Float64(x + Float64(Float64(z - t) * Float64(y / Float64(a - t)))); else tmp = Float64(y + Float64(Float64(x - y) / Float64(t / Float64(z - a)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a <= -2.15e+22) || ~((a <= 1.05e-50))) tmp = x + ((z - t) * (y / (a - t))); else tmp = y + ((x - y) / (t / (z - a))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -2.15e+22], N[Not[LessEqual[a, 1.05e-50]], $MachinePrecision]], N[(x + N[(N[(z - t), $MachinePrecision] * N[(y / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y + N[(N[(x - y), $MachinePrecision] / N[(t / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -2.15 \cdot 10^{+22} \lor \neg \left(a \leq 1.05 \cdot 10^{-50}\right):\\
\;\;\;\;x + \left(z - t\right) \cdot \frac{y}{a - t}\\
\mathbf{else}:\\
\;\;\;\;y + \frac{x - y}{\frac{t}{z - a}}\\
\end{array}
\end{array}
if a < -2.1500000000000001e22 or 1.05e-50 < a Initial program 70.6%
associate-*l/88.6%
Simplified88.6%
Taylor expanded in y around inf 78.0%
if -2.1500000000000001e22 < a < 1.05e-50Initial program 60.8%
associate-/l*67.9%
clear-num67.8%
associate-/r/67.3%
clear-num67.4%
Applied egg-rr67.4%
Taylor expanded in t around -inf 79.3%
mul-1-neg79.3%
unsub-neg79.3%
div-sub78.4%
*-commutative78.4%
div-sub79.3%
distribute-rgt-out--79.3%
associate-/l*82.6%
Simplified82.6%
Final simplification80.1%
(FPCore (x y z t a)
:precision binary64
(if (<= a -9.2e+20)
(+ x (* (- y x) (* (- t z) (/ -1.0 a))))
(if (<= a 8e-51)
(+ y (/ (- x y) (/ t (- z a))))
(+ x (* (- z t) (/ y (- a t)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -9.2e+20) {
tmp = x + ((y - x) * ((t - z) * (-1.0 / a)));
} else if (a <= 8e-51) {
tmp = y + ((x - y) / (t / (z - a)));
} 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 <= (-9.2d+20)) then
tmp = x + ((y - x) * ((t - z) * ((-1.0d0) / a)))
else if (a <= 8d-51) then
tmp = y + ((x - y) / (t / (z - a)))
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 <= -9.2e+20) {
tmp = x + ((y - x) * ((t - z) * (-1.0 / a)));
} else if (a <= 8e-51) {
tmp = y + ((x - y) / (t / (z - a)));
} else {
tmp = x + ((z - t) * (y / (a - t)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -9.2e+20: tmp = x + ((y - x) * ((t - z) * (-1.0 / a))) elif a <= 8e-51: tmp = y + ((x - y) / (t / (z - a))) else: tmp = x + ((z - t) * (y / (a - t))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -9.2e+20) tmp = Float64(x + Float64(Float64(y - x) * Float64(Float64(t - z) * Float64(-1.0 / a)))); elseif (a <= 8e-51) tmp = Float64(y + Float64(Float64(x - y) / Float64(t / Float64(z - a)))); 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 <= -9.2e+20) tmp = x + ((y - x) * ((t - z) * (-1.0 / a))); elseif (a <= 8e-51) tmp = y + ((x - y) / (t / (z - a))); else tmp = x + ((z - t) * (y / (a - t))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -9.2e+20], N[(x + N[(N[(y - x), $MachinePrecision] * N[(N[(t - z), $MachinePrecision] * N[(-1.0 / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 8e-51], N[(y + N[(N[(x - y), $MachinePrecision] / N[(t / N[(z - a), $MachinePrecision]), $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 -9.2 \cdot 10^{+20}:\\
\;\;\;\;x + \left(y - x\right) \cdot \left(\left(t - z\right) \cdot \frac{-1}{a}\right)\\
\mathbf{elif}\;a \leq 8 \cdot 10^{-51}:\\
\;\;\;\;y + \frac{x - y}{\frac{t}{z - a}}\\
\mathbf{else}:\\
\;\;\;\;x + \left(z - t\right) \cdot \frac{y}{a - t}\\
\end{array}
\end{array}
if a < -9.2e20Initial program 73.4%
associate-/l*90.1%
clear-num90.0%
associate-/r/90.1%
clear-num90.1%
Applied egg-rr90.1%
div-inv90.1%
Applied egg-rr90.1%
Taylor expanded in a around inf 81.3%
if -9.2e20 < a < 8.0000000000000001e-51Initial program 60.8%
associate-/l*67.9%
clear-num67.8%
associate-/r/67.3%
clear-num67.4%
Applied egg-rr67.4%
Taylor expanded in t around -inf 79.3%
mul-1-neg79.3%
unsub-neg79.3%
div-sub78.4%
*-commutative78.4%
div-sub79.3%
distribute-rgt-out--79.3%
associate-/l*82.6%
Simplified82.6%
if 8.0000000000000001e-51 < a Initial program 68.0%
associate-*l/89.4%
Simplified89.4%
Taylor expanded in y around inf 75.9%
Final simplification80.4%
(FPCore (x y z t a) :precision binary64 (if (<= t -4.1e+132) y (if (<= t -3.3e+24) (+ y x) (if (<= t 2.1e+80) (+ x (/ y (/ a z))) y))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -4.1e+132) {
tmp = y;
} else if (t <= -3.3e+24) {
tmp = y + x;
} else if (t <= 2.1e+80) {
tmp = x + (y / (a / z));
} 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 <= (-4.1d+132)) then
tmp = y
else if (t <= (-3.3d+24)) then
tmp = y + x
else if (t <= 2.1d+80) then
tmp = x + (y / (a / z))
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 <= -4.1e+132) {
tmp = y;
} else if (t <= -3.3e+24) {
tmp = y + x;
} else if (t <= 2.1e+80) {
tmp = x + (y / (a / z));
} else {
tmp = y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -4.1e+132: tmp = y elif t <= -3.3e+24: tmp = y + x elif t <= 2.1e+80: tmp = x + (y / (a / z)) else: tmp = y return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -4.1e+132) tmp = y; elseif (t <= -3.3e+24) tmp = Float64(y + x); elseif (t <= 2.1e+80) tmp = Float64(x + Float64(y / Float64(a / z))); else tmp = y; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -4.1e+132) tmp = y; elseif (t <= -3.3e+24) tmp = y + x; elseif (t <= 2.1e+80) tmp = x + (y / (a / z)); else tmp = y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -4.1e+132], y, If[LessEqual[t, -3.3e+24], N[(y + x), $MachinePrecision], If[LessEqual[t, 2.1e+80], N[(x + N[(y / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], y]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.1 \cdot 10^{+132}:\\
\;\;\;\;y\\
\mathbf{elif}\;t \leq -3.3 \cdot 10^{+24}:\\
\;\;\;\;y + x\\
\mathbf{elif}\;t \leq 2.1 \cdot 10^{+80}:\\
\;\;\;\;x + \frac{y}{\frac{a}{z}}\\
\mathbf{else}:\\
\;\;\;\;y\\
\end{array}
\end{array}
if t < -4.09999999999999992e132 or 2.10000000000000001e80 < t Initial program 21.5%
associate-*l/48.6%
Simplified48.6%
Taylor expanded in t around inf 59.7%
if -4.09999999999999992e132 < t < -3.2999999999999999e24Initial program 67.8%
associate-*l/82.4%
Simplified82.4%
Taylor expanded in y around inf 68.4%
Taylor expanded in t around inf 43.5%
if -3.2999999999999999e24 < t < 2.10000000000000001e80Initial program 87.0%
associate-*l/91.8%
Simplified91.8%
Taylor expanded in t around 0 66.3%
Taylor expanded in y around inf 56.2%
associate-/l*60.8%
Simplified60.8%
Final simplification58.3%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (/ y (/ a z)))))
(if (<= a -5.2e+47)
t_1
(if (<= a -2.8e-38)
(- x (/ z (/ a x)))
(if (<= a 4.8e-41) (/ (- t z) (/ t y)) t_1)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (y / (a / z));
double tmp;
if (a <= -5.2e+47) {
tmp = t_1;
} else if (a <= -2.8e-38) {
tmp = x - (z / (a / x));
} else if (a <= 4.8e-41) {
tmp = (t - z) / (t / 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 + (y / (a / z))
if (a <= (-5.2d+47)) then
tmp = t_1
else if (a <= (-2.8d-38)) then
tmp = x - (z / (a / x))
else if (a <= 4.8d-41) then
tmp = (t - z) / (t / 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 + (y / (a / z));
double tmp;
if (a <= -5.2e+47) {
tmp = t_1;
} else if (a <= -2.8e-38) {
tmp = x - (z / (a / x));
} else if (a <= 4.8e-41) {
tmp = (t - z) / (t / y);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + (y / (a / z)) tmp = 0 if a <= -5.2e+47: tmp = t_1 elif a <= -2.8e-38: tmp = x - (z / (a / x)) elif a <= 4.8e-41: tmp = (t - z) / (t / y) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(y / Float64(a / z))) tmp = 0.0 if (a <= -5.2e+47) tmp = t_1; elseif (a <= -2.8e-38) tmp = Float64(x - Float64(z / Float64(a / x))); elseif (a <= 4.8e-41) tmp = Float64(Float64(t - z) / Float64(t / y)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + (y / (a / z)); tmp = 0.0; if (a <= -5.2e+47) tmp = t_1; elseif (a <= -2.8e-38) tmp = x - (z / (a / x)); elseif (a <= 4.8e-41) tmp = (t - z) / (t / y); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(y / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -5.2e+47], t$95$1, If[LessEqual[a, -2.8e-38], N[(x - N[(z / N[(a / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 4.8e-41], N[(N[(t - z), $MachinePrecision] / N[(t / y), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{y}{\frac{a}{z}}\\
\mathbf{if}\;a \leq -5.2 \cdot 10^{+47}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;a \leq -2.8 \cdot 10^{-38}:\\
\;\;\;\;x - \frac{z}{\frac{a}{x}}\\
\mathbf{elif}\;a \leq 4.8 \cdot 10^{-41}:\\
\;\;\;\;\frac{t - z}{\frac{t}{y}}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if a < -5.20000000000000007e47 or 4.80000000000000044e-41 < a Initial program 69.6%
associate-*l/88.6%
Simplified88.6%
Taylor expanded in t around 0 58.9%
Taylor expanded in y around inf 57.6%
associate-/l*61.4%
Simplified61.4%
if -5.20000000000000007e47 < a < -2.8e-38Initial program 79.5%
associate-*l/74.3%
Simplified74.3%
Taylor expanded in t around 0 64.6%
Taylor expanded in y around 0 64.6%
+-commutative64.6%
mul-1-neg64.6%
unsub-neg64.6%
associate-/l*64.5%
Simplified64.5%
if -2.8e-38 < a < 4.80000000000000044e-41Initial program 59.5%
associate-*l/66.8%
Simplified66.8%
Taylor expanded in x around 0 46.7%
Taylor expanded in a around 0 43.1%
mul-1-neg43.1%
associate-/l*58.1%
Simplified58.1%
Final simplification60.2%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -5.2e-97) (not (<= t 0.012))) (* y (/ (- z t) (- a t))) (+ x (/ y (/ a z)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -5.2e-97) || !(t <= 0.012)) {
tmp = y * ((z - t) / (a - t));
} else {
tmp = x + (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 ((t <= (-5.2d-97)) .or. (.not. (t <= 0.012d0))) then
tmp = y * ((z - t) / (a - t))
else
tmp = x + (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 ((t <= -5.2e-97) || !(t <= 0.012)) {
tmp = y * ((z - t) / (a - t));
} else {
tmp = x + (y / (a / z));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -5.2e-97) or not (t <= 0.012): tmp = y * ((z - t) / (a - t)) else: tmp = x + (y / (a / z)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -5.2e-97) || !(t <= 0.012)) tmp = Float64(y * Float64(Float64(z - t) / Float64(a - t))); else tmp = Float64(x + Float64(y / Float64(a / z))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -5.2e-97) || ~((t <= 0.012))) tmp = y * ((z - t) / (a - t)); else tmp = x + (y / (a / z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -5.2e-97], N[Not[LessEqual[t, 0.012]], $MachinePrecision]], N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -5.2 \cdot 10^{-97} \lor \neg \left(t \leq 0.012\right):\\
\;\;\;\;y \cdot \frac{z - t}{a - t}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y}{\frac{a}{z}}\\
\end{array}
\end{array}
if t < -5.20000000000000014e-97 or 0.012 < t Initial program 49.2%
associate-*l/67.0%
Simplified67.0%
Taylor expanded in x around 0 42.7%
associate-*r/59.2%
Simplified59.2%
if -5.20000000000000014e-97 < t < 0.012Initial program 90.1%
associate-*l/94.6%
Simplified94.6%
Taylor expanded in t around 0 71.7%
Taylor expanded in y around inf 62.2%
associate-/l*68.8%
Simplified68.8%
Final simplification63.2%
(FPCore (x y z t a) :precision binary64 (if (<= a -2.4e+21) x (if (<= a 0.55) y x)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -2.4e+21) {
tmp = x;
} else if (a <= 0.55) {
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 <= (-2.4d+21)) then
tmp = x
else if (a <= 0.55d0) 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 <= -2.4e+21) {
tmp = x;
} else if (a <= 0.55) {
tmp = y;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -2.4e+21: tmp = x elif a <= 0.55: tmp = y else: tmp = x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -2.4e+21) tmp = x; elseif (a <= 0.55) tmp = y; else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -2.4e+21) tmp = x; elseif (a <= 0.55) tmp = y; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -2.4e+21], x, If[LessEqual[a, 0.55], y, x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -2.4 \cdot 10^{+21}:\\
\;\;\;\;x\\
\mathbf{elif}\;a \leq 0.55:\\
\;\;\;\;y\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if a < -2.4e21 or 0.55000000000000004 < a Initial program 70.3%
associate-*l/88.6%
Simplified88.6%
Taylor expanded in a around inf 47.3%
if -2.4e21 < a < 0.55000000000000004Initial program 61.8%
associate-*l/67.9%
Simplified67.9%
Taylor expanded in t around inf 42.7%
Final simplification45.0%
(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 66.1%
associate-*l/78.4%
Simplified78.4%
Taylor expanded in a around inf 27.8%
Final simplification27.8%
(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 2023279
(FPCore (x y z t a)
:name "Graphics.Rendering.Chart.Axis.Types:linMap from Chart-1.5.3"
:precision binary64
:herbie-target
(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))))