
(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 24 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 (/ (* (- y x) (- z t)) (- a t)))))
(if (<= t_1 -5e-250)
(+ x (/ (- y x) (/ (- a t) (- z t))))
(if (<= t_1 2e-246)
(+ y (/ (+ (* (- y x) a) (* z (- x y))) t))
(fma (/ (- y x) (- a t)) (- z t) x)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (((y - x) * (z - t)) / (a - t));
double tmp;
if (t_1 <= -5e-250) {
tmp = x + ((y - x) / ((a - t) / (z - t)));
} else if (t_1 <= 2e-246) {
tmp = y + ((((y - x) * a) + (z * (x - y))) / t);
} else {
tmp = fma(((y - x) / (a - t)), (z - t), x);
}
return tmp;
}
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(Float64(y - x) * Float64(z - t)) / Float64(a - t))) tmp = 0.0 if (t_1 <= -5e-250) tmp = Float64(x + Float64(Float64(y - x) / Float64(Float64(a - t) / Float64(z - t)))); elseif (t_1 <= 2e-246) tmp = Float64(y + Float64(Float64(Float64(Float64(y - x) * a) + Float64(z * Float64(x - y))) / t)); else tmp = fma(Float64(Float64(y - x) / Float64(a - t)), Float64(z - t), x); end return tmp end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(N[(y - x), $MachinePrecision] * N[(z - t), $MachinePrecision]), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, -5e-250], N[(x + N[(N[(y - x), $MachinePrecision] / N[(N[(a - t), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 2e-246], N[(y + N[(N[(N[(N[(y - x), $MachinePrecision] * a), $MachinePrecision] + N[(z * N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], N[(N[(N[(y - x), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision] * N[(z - t), $MachinePrecision] + x), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}\\
\mathbf{if}\;t_1 \leq -5 \cdot 10^{-250}:\\
\;\;\;\;x + \frac{y - x}{\frac{a - t}{z - t}}\\
\mathbf{elif}\;t_1 \leq 2 \cdot 10^{-246}:\\
\;\;\;\;y + \frac{\left(y - x\right) \cdot a + z \cdot \left(x - y\right)}{t}\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(\frac{y - x}{a - t}, z - t, x\right)\\
\end{array}
\end{array}
if (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < -5.00000000000000027e-250Initial program 78.5%
associate-/l*93.1%
Simplified93.1%
if -5.00000000000000027e-250 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < 1.99999999999999991e-246Initial program 5.5%
associate-/l*5.5%
Simplified5.5%
Taylor expanded in t around -inf 99.6%
if 1.99999999999999991e-246 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) Initial program 69.6%
+-commutative69.6%
associate-*l/93.4%
fma-def93.5%
Simplified93.5%
Final simplification93.9%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* (- z t) (/ (- y x) (- a t)))))
(t_2 (+ x (/ (* (- y x) (- z t)) (- a t)))))
(if (<= t_2 (- INFINITY))
t_1
(if (<= t_2 -5e-250)
t_2
(if (<= t_2 2e-246) (+ y (/ (- x y) (/ t (- z a)))) t_1)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((z - t) * ((y - x) / (a - t)));
double t_2 = x + (((y - x) * (z - t)) / (a - t));
double tmp;
if (t_2 <= -((double) INFINITY)) {
tmp = t_1;
} else if (t_2 <= -5e-250) {
tmp = t_2;
} else if (t_2 <= 2e-246) {
tmp = y + ((x - y) / (t / (z - a)));
} 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) / (a - t)));
double t_2 = x + (((y - x) * (z - t)) / (a - t));
double tmp;
if (t_2 <= -Double.POSITIVE_INFINITY) {
tmp = t_1;
} else if (t_2 <= -5e-250) {
tmp = t_2;
} else if (t_2 <= 2e-246) {
tmp = y + ((x - y) / (t / (z - a)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((z - t) * ((y - x) / (a - t))) t_2 = x + (((y - x) * (z - t)) / (a - t)) tmp = 0 if t_2 <= -math.inf: tmp = t_1 elif t_2 <= -5e-250: tmp = t_2 elif t_2 <= 2e-246: tmp = y + ((x - y) / (t / (z - a))) 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(a - t)))) t_2 = Float64(x + Float64(Float64(Float64(y - x) * Float64(z - t)) / Float64(a - t))) tmp = 0.0 if (t_2 <= Float64(-Inf)) tmp = t_1; elseif (t_2 <= -5e-250) tmp = t_2; elseif (t_2 <= 2e-246) tmp = Float64(y + Float64(Float64(x - y) / Float64(t / Float64(z - a)))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + ((z - t) * ((y - x) / (a - t))); t_2 = x + (((y - x) * (z - t)) / (a - t)); tmp = 0.0; if (t_2 <= -Inf) tmp = t_1; elseif (t_2 <= -5e-250) tmp = t_2; elseif (t_2 <= 2e-246) tmp = y + ((x - y) / (t / (z - a))); 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[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(N[(N[(y - x), $MachinePrecision] * N[(z - t), $MachinePrecision]), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, (-Infinity)], t$95$1, If[LessEqual[t$95$2, -5e-250], t$95$2, If[LessEqual[t$95$2, 2e-246], N[(y + N[(N[(x - y), $MachinePrecision] / N[(t / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \left(z - t\right) \cdot \frac{y - x}{a - t}\\
t_2 := x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}\\
\mathbf{if}\;t_2 \leq -\infty:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t_2 \leq -5 \cdot 10^{-250}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;t_2 \leq 2 \cdot 10^{-246}:\\
\;\;\;\;y + \frac{x - y}{\frac{t}{z - a}}\\
\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 1.99999999999999991e-246 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) Initial program 62.3%
associate-*l/91.0%
Simplified91.0%
if -inf.0 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < -5.00000000000000027e-250Initial program 98.0%
if -5.00000000000000027e-250 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < 1.99999999999999991e-246Initial program 5.5%
associate-/l*5.5%
Simplified5.5%
Taylor expanded in t around inf 99.6%
associate--l+99.6%
associate-*r/99.6%
associate-*r/99.6%
div-sub99.6%
distribute-lft-out--99.6%
associate-*r/99.6%
mul-1-neg99.6%
unsub-neg99.6%
distribute-rgt-out--99.5%
associate-/l*99.5%
Simplified99.5%
Final simplification93.9%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (/ (* (- y x) (- z t)) (- a t)))))
(if (<= t_1 -5e-250)
(+ x (/ (- y x) (/ (- a t) (- z t))))
(if (<= t_1 2e-246)
(+ y (/ (+ (* (- y x) a) (* z (- x y))) t))
(+ x (* (- z t) (/ (- y x) (- a t))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (((y - x) * (z - t)) / (a - t));
double tmp;
if (t_1 <= -5e-250) {
tmp = x + ((y - x) / ((a - t) / (z - t)));
} else if (t_1 <= 2e-246) {
tmp = y + ((((y - x) * a) + (z * (x - y))) / t);
} 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) :: t_1
real(8) :: tmp
t_1 = x + (((y - x) * (z - t)) / (a - t))
if (t_1 <= (-5d-250)) then
tmp = x + ((y - x) / ((a - t) / (z - t)))
else if (t_1 <= 2d-246) then
tmp = y + ((((y - x) * a) + (z * (x - y))) / t)
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 t_1 = x + (((y - x) * (z - t)) / (a - t));
double tmp;
if (t_1 <= -5e-250) {
tmp = x + ((y - x) / ((a - t) / (z - t)));
} else if (t_1 <= 2e-246) {
tmp = y + ((((y - x) * a) + (z * (x - y))) / t);
} else {
tmp = x + ((z - t) * ((y - x) / (a - t)));
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + (((y - x) * (z - t)) / (a - t)) tmp = 0 if t_1 <= -5e-250: tmp = x + ((y - x) / ((a - t) / (z - t))) elif t_1 <= 2e-246: tmp = y + ((((y - x) * a) + (z * (x - y))) / t) else: tmp = x + ((z - t) * ((y - x) / (a - t))) return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(Float64(y - x) * Float64(z - t)) / Float64(a - t))) tmp = 0.0 if (t_1 <= -5e-250) tmp = Float64(x + Float64(Float64(y - x) / Float64(Float64(a - t) / Float64(z - t)))); elseif (t_1 <= 2e-246) tmp = Float64(y + Float64(Float64(Float64(Float64(y - x) * a) + Float64(z * Float64(x - y))) / t)); 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) t_1 = x + (((y - x) * (z - t)) / (a - t)); tmp = 0.0; if (t_1 <= -5e-250) tmp = x + ((y - x) / ((a - t) / (z - t))); elseif (t_1 <= 2e-246) tmp = y + ((((y - x) * a) + (z * (x - y))) / t); else tmp = x + ((z - t) * ((y - x) / (a - t))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(N[(y - x), $MachinePrecision] * N[(z - t), $MachinePrecision]), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, -5e-250], N[(x + N[(N[(y - x), $MachinePrecision] / N[(N[(a - t), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 2e-246], N[(y + N[(N[(N[(N[(y - x), $MachinePrecision] * a), $MachinePrecision] + N[(z * N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / t), $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}
t_1 := x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}\\
\mathbf{if}\;t_1 \leq -5 \cdot 10^{-250}:\\
\;\;\;\;x + \frac{y - x}{\frac{a - t}{z - t}}\\
\mathbf{elif}\;t_1 \leq 2 \cdot 10^{-246}:\\
\;\;\;\;y + \frac{\left(y - x\right) \cdot a + z \cdot \left(x - y\right)}{t}\\
\mathbf{else}:\\
\;\;\;\;x + \left(z - t\right) \cdot \frac{y - x}{a - t}\\
\end{array}
\end{array}
if (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < -5.00000000000000027e-250Initial program 78.5%
associate-/l*93.1%
Simplified93.1%
if -5.00000000000000027e-250 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < 1.99999999999999991e-246Initial program 5.5%
associate-/l*5.5%
Simplified5.5%
Taylor expanded in t around -inf 99.6%
if 1.99999999999999991e-246 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) Initial program 69.6%
associate-*l/93.4%
Simplified93.4%
Final simplification93.9%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (/ (* (- y x) (- z t)) (- a t)))))
(if (<= t_1 -5e-250)
(+ x (/ (- y x) (/ (- a t) (- z t))))
(if (<= t_1 2e-246)
(+ 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 t_1 = x + (((y - x) * (z - t)) / (a - t));
double tmp;
if (t_1 <= -5e-250) {
tmp = x + ((y - x) / ((a - t) / (z - t)));
} else if (t_1 <= 2e-246) {
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) :: t_1
real(8) :: tmp
t_1 = x + (((y - x) * (z - t)) / (a - t))
if (t_1 <= (-5d-250)) then
tmp = x + ((y - x) / ((a - t) / (z - t)))
else if (t_1 <= 2d-246) 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 t_1 = x + (((y - x) * (z - t)) / (a - t));
double tmp;
if (t_1 <= -5e-250) {
tmp = x + ((y - x) / ((a - t) / (z - t)));
} else if (t_1 <= 2e-246) {
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): t_1 = x + (((y - x) * (z - t)) / (a - t)) tmp = 0 if t_1 <= -5e-250: tmp = x + ((y - x) / ((a - t) / (z - t))) elif t_1 <= 2e-246: 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) t_1 = Float64(x + Float64(Float64(Float64(y - x) * Float64(z - t)) / Float64(a - t))) tmp = 0.0 if (t_1 <= -5e-250) tmp = Float64(x + Float64(Float64(y - x) / Float64(Float64(a - t) / Float64(z - t)))); elseif (t_1 <= 2e-246) 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) t_1 = x + (((y - x) * (z - t)) / (a - t)); tmp = 0.0; if (t_1 <= -5e-250) tmp = x + ((y - x) / ((a - t) / (z - t))); elseif (t_1 <= 2e-246) 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_] := Block[{t$95$1 = N[(x + N[(N[(N[(y - x), $MachinePrecision] * N[(z - t), $MachinePrecision]), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, -5e-250], N[(x + N[(N[(y - x), $MachinePrecision] / N[(N[(a - t), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 2e-246], 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}
t_1 := x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}\\
\mathbf{if}\;t_1 \leq -5 \cdot 10^{-250}:\\
\;\;\;\;x + \frac{y - x}{\frac{a - t}{z - t}}\\
\mathbf{elif}\;t_1 \leq 2 \cdot 10^{-246}:\\
\;\;\;\;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 (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < -5.00000000000000027e-250Initial program 78.5%
associate-/l*93.1%
Simplified93.1%
if -5.00000000000000027e-250 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < 1.99999999999999991e-246Initial program 5.5%
associate-/l*5.5%
Simplified5.5%
Taylor expanded in t around inf 99.6%
associate--l+99.6%
associate-*r/99.6%
associate-*r/99.6%
div-sub99.6%
distribute-lft-out--99.6%
associate-*r/99.6%
mul-1-neg99.6%
unsub-neg99.6%
distribute-rgt-out--99.5%
associate-/l*99.5%
Simplified99.5%
if 1.99999999999999991e-246 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) Initial program 69.6%
associate-*l/93.4%
Simplified93.4%
Final simplification93.9%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* x (/ (- z a) t)))
(t_2 (* x (- 1.0 (/ z a))))
(t_3 (* y (/ (- z t) (- a t)))))
(if (<= x -3.6e+218)
t_2
(if (<= x -9.8e+182)
t_1
(if (<= x -3.15e+63)
t_2
(if (<= x -7.8e+24)
t_3
(if (<= x -1.2e-49)
(- x (/ x (/ a z)))
(if (<= x 1.3e+90)
t_3
(if (or (<= x 2.2e+128)
(not
(or (<= x 1.3e+189)
(and (not (<= x 3.2e+232)) (<= x 2.2e+264)))))
t_2
t_1)))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x * ((z - a) / t);
double t_2 = x * (1.0 - (z / a));
double t_3 = y * ((z - t) / (a - t));
double tmp;
if (x <= -3.6e+218) {
tmp = t_2;
} else if (x <= -9.8e+182) {
tmp = t_1;
} else if (x <= -3.15e+63) {
tmp = t_2;
} else if (x <= -7.8e+24) {
tmp = t_3;
} else if (x <= -1.2e-49) {
tmp = x - (x / (a / z));
} else if (x <= 1.3e+90) {
tmp = t_3;
} else if ((x <= 2.2e+128) || !((x <= 1.3e+189) || (!(x <= 3.2e+232) && (x <= 2.2e+264)))) {
tmp = t_2;
} 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) :: t_2
real(8) :: t_3
real(8) :: tmp
t_1 = x * ((z - a) / t)
t_2 = x * (1.0d0 - (z / a))
t_3 = y * ((z - t) / (a - t))
if (x <= (-3.6d+218)) then
tmp = t_2
else if (x <= (-9.8d+182)) then
tmp = t_1
else if (x <= (-3.15d+63)) then
tmp = t_2
else if (x <= (-7.8d+24)) then
tmp = t_3
else if (x <= (-1.2d-49)) then
tmp = x - (x / (a / z))
else if (x <= 1.3d+90) then
tmp = t_3
else if ((x <= 2.2d+128) .or. (.not. (x <= 1.3d+189) .or. (.not. (x <= 3.2d+232)) .and. (x <= 2.2d+264))) then
tmp = t_2
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x * ((z - a) / t);
double t_2 = x * (1.0 - (z / a));
double t_3 = y * ((z - t) / (a - t));
double tmp;
if (x <= -3.6e+218) {
tmp = t_2;
} else if (x <= -9.8e+182) {
tmp = t_1;
} else if (x <= -3.15e+63) {
tmp = t_2;
} else if (x <= -7.8e+24) {
tmp = t_3;
} else if (x <= -1.2e-49) {
tmp = x - (x / (a / z));
} else if (x <= 1.3e+90) {
tmp = t_3;
} else if ((x <= 2.2e+128) || !((x <= 1.3e+189) || (!(x <= 3.2e+232) && (x <= 2.2e+264)))) {
tmp = t_2;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x * ((z - a) / t) t_2 = x * (1.0 - (z / a)) t_3 = y * ((z - t) / (a - t)) tmp = 0 if x <= -3.6e+218: tmp = t_2 elif x <= -9.8e+182: tmp = t_1 elif x <= -3.15e+63: tmp = t_2 elif x <= -7.8e+24: tmp = t_3 elif x <= -1.2e-49: tmp = x - (x / (a / z)) elif x <= 1.3e+90: tmp = t_3 elif (x <= 2.2e+128) or not ((x <= 1.3e+189) or (not (x <= 3.2e+232) and (x <= 2.2e+264))): tmp = t_2 else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x * Float64(Float64(z - a) / t)) t_2 = Float64(x * Float64(1.0 - Float64(z / a))) t_3 = Float64(y * Float64(Float64(z - t) / Float64(a - t))) tmp = 0.0 if (x <= -3.6e+218) tmp = t_2; elseif (x <= -9.8e+182) tmp = t_1; elseif (x <= -3.15e+63) tmp = t_2; elseif (x <= -7.8e+24) tmp = t_3; elseif (x <= -1.2e-49) tmp = Float64(x - Float64(x / Float64(a / z))); elseif (x <= 1.3e+90) tmp = t_3; elseif ((x <= 2.2e+128) || !((x <= 1.3e+189) || (!(x <= 3.2e+232) && (x <= 2.2e+264)))) tmp = t_2; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x * ((z - a) / t); t_2 = x * (1.0 - (z / a)); t_3 = y * ((z - t) / (a - t)); tmp = 0.0; if (x <= -3.6e+218) tmp = t_2; elseif (x <= -9.8e+182) tmp = t_1; elseif (x <= -3.15e+63) tmp = t_2; elseif (x <= -7.8e+24) tmp = t_3; elseif (x <= -1.2e-49) tmp = x - (x / (a / z)); elseif (x <= 1.3e+90) tmp = t_3; elseif ((x <= 2.2e+128) || ~(((x <= 1.3e+189) || (~((x <= 3.2e+232)) && (x <= 2.2e+264))))) 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 - a), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x * N[(1.0 - N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -3.6e+218], t$95$2, If[LessEqual[x, -9.8e+182], t$95$1, If[LessEqual[x, -3.15e+63], t$95$2, If[LessEqual[x, -7.8e+24], t$95$3, If[LessEqual[x, -1.2e-49], N[(x - N[(x / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1.3e+90], t$95$3, If[Or[LessEqual[x, 2.2e+128], N[Not[Or[LessEqual[x, 1.3e+189], And[N[Not[LessEqual[x, 3.2e+232]], $MachinePrecision], LessEqual[x, 2.2e+264]]]], $MachinePrecision]], t$95$2, t$95$1]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \frac{z - a}{t}\\
t_2 := x \cdot \left(1 - \frac{z}{a}\right)\\
t_3 := y \cdot \frac{z - t}{a - t}\\
\mathbf{if}\;x \leq -3.6 \cdot 10^{+218}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \leq -9.8 \cdot 10^{+182}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq -3.15 \cdot 10^{+63}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \leq -7.8 \cdot 10^{+24}:\\
\;\;\;\;t_3\\
\mathbf{elif}\;x \leq -1.2 \cdot 10^{-49}:\\
\;\;\;\;x - \frac{x}{\frac{a}{z}}\\
\mathbf{elif}\;x \leq 1.3 \cdot 10^{+90}:\\
\;\;\;\;t_3\\
\mathbf{elif}\;x \leq 2.2 \cdot 10^{+128} \lor \neg \left(x \leq 1.3 \cdot 10^{+189} \lor \neg \left(x \leq 3.2 \cdot 10^{+232}\right) \land x \leq 2.2 \cdot 10^{+264}\right):\\
\;\;\;\;t_2\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if x < -3.59999999999999991e218 or -9.7999999999999999e182 < x < -3.1499999999999999e63 or 1.2999999999999999e90 < x < 2.20000000000000017e128 or 1.29999999999999991e189 < x < 3.2000000000000002e232 or 2.2e264 < x Initial program 68.7%
associate-/l*89.2%
Simplified89.2%
Taylor expanded in x around inf 82.1%
mul-1-neg82.1%
unsub-neg82.1%
Simplified82.1%
Taylor expanded in t around 0 78.9%
if -3.59999999999999991e218 < x < -9.7999999999999999e182 or 2.20000000000000017e128 < x < 1.29999999999999991e189 or 3.2000000000000002e232 < x < 2.2e264Initial program 44.6%
associate-/l*59.5%
Simplified59.5%
Taylor expanded in t around inf 63.0%
associate--l+63.0%
associate-*r/63.0%
associate-*r/63.0%
div-sub63.0%
distribute-lft-out--63.0%
associate-*r/63.0%
mul-1-neg63.0%
unsub-neg63.0%
distribute-rgt-out--65.9%
associate-/l*82.6%
Simplified82.6%
Taylor expanded in y around 0 54.9%
associate-*r/63.5%
Simplified63.5%
if -3.1499999999999999e63 < x < -7.7999999999999995e24 or -1.19999999999999996e-49 < x < 1.2999999999999999e90Initial program 69.9%
associate-/l*86.9%
Simplified86.9%
Taylor expanded in x around 0 56.9%
associate-*r/73.9%
Simplified73.9%
if -7.7999999999999995e24 < x < -1.19999999999999996e-49Initial program 85.2%
+-commutative85.2%
associate-*l/92.4%
fma-def92.5%
Simplified92.5%
Taylor expanded in y around 0 69.9%
neg-mul-169.9%
distribute-neg-frac69.9%
Simplified69.9%
Taylor expanded in t around 0 70.1%
mul-1-neg70.1%
unsub-neg70.1%
associate-/l*66.5%
Simplified66.5%
Final simplification73.3%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* y (/ (- z t) (- a t)))))
(if (<= t -4.6e+37)
t_1
(if (<= t -3.3e-19)
(* z (/ (- y x) (- a t)))
(if (<= t -1.6e-24)
(+ y (/ (* (- y x) a) t))
(if (<= t -9e-111)
(- x (/ (* z (- x y)) a))
(if (<= t 4.4e+18) (+ x (/ z (/ a (- y x)))) 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 <= -4.6e+37) {
tmp = t_1;
} else if (t <= -3.3e-19) {
tmp = z * ((y - x) / (a - t));
} else if (t <= -1.6e-24) {
tmp = y + (((y - x) * a) / t);
} else if (t <= -9e-111) {
tmp = x - ((z * (x - y)) / a);
} else if (t <= 4.4e+18) {
tmp = x + (z / (a / (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 = y * ((z - t) / (a - t))
if (t <= (-4.6d+37)) then
tmp = t_1
else if (t <= (-3.3d-19)) then
tmp = z * ((y - x) / (a - t))
else if (t <= (-1.6d-24)) then
tmp = y + (((y - x) * a) / t)
else if (t <= (-9d-111)) then
tmp = x - ((z * (x - y)) / a)
else if (t <= 4.4d+18) then
tmp = x + (z / (a / (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 = y * ((z - t) / (a - t));
double tmp;
if (t <= -4.6e+37) {
tmp = t_1;
} else if (t <= -3.3e-19) {
tmp = z * ((y - x) / (a - t));
} else if (t <= -1.6e-24) {
tmp = y + (((y - x) * a) / t);
} else if (t <= -9e-111) {
tmp = x - ((z * (x - y)) / a);
} else if (t <= 4.4e+18) {
tmp = x + (z / (a / (y - x)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = y * ((z - t) / (a - t)) tmp = 0 if t <= -4.6e+37: tmp = t_1 elif t <= -3.3e-19: tmp = z * ((y - x) / (a - t)) elif t <= -1.6e-24: tmp = y + (((y - x) * a) / t) elif t <= -9e-111: tmp = x - ((z * (x - y)) / a) elif t <= 4.4e+18: tmp = x + (z / (a / (y - x))) 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 <= -4.6e+37) tmp = t_1; elseif (t <= -3.3e-19) tmp = Float64(z * Float64(Float64(y - x) / Float64(a - t))); elseif (t <= -1.6e-24) tmp = Float64(y + Float64(Float64(Float64(y - x) * a) / t)); elseif (t <= -9e-111) tmp = Float64(x - Float64(Float64(z * Float64(x - y)) / a)); elseif (t <= 4.4e+18) tmp = Float64(x + Float64(z / Float64(a / Float64(y - x)))); 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 <= -4.6e+37) tmp = t_1; elseif (t <= -3.3e-19) tmp = z * ((y - x) / (a - t)); elseif (t <= -1.6e-24) tmp = y + (((y - x) * a) / t); elseif (t <= -9e-111) tmp = x - ((z * (x - y)) / a); elseif (t <= 4.4e+18) tmp = x + (z / (a / (y - x))); 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, -4.6e+37], t$95$1, If[LessEqual[t, -3.3e-19], N[(z * N[(N[(y - x), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, -1.6e-24], N[(y + N[(N[(N[(y - x), $MachinePrecision] * a), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, -9e-111], N[(x - N[(N[(z * N[(x - y), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 4.4e+18], N[(x + N[(z / N[(a / N[(y - x), $MachinePrecision]), $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 -4.6 \cdot 10^{+37}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq -3.3 \cdot 10^{-19}:\\
\;\;\;\;z \cdot \frac{y - x}{a - t}\\
\mathbf{elif}\;t \leq -1.6 \cdot 10^{-24}:\\
\;\;\;\;y + \frac{\left(y - x\right) \cdot a}{t}\\
\mathbf{elif}\;t \leq -9 \cdot 10^{-111}:\\
\;\;\;\;x - \frac{z \cdot \left(x - y\right)}{a}\\
\mathbf{elif}\;t \leq 4.4 \cdot 10^{+18}:\\
\;\;\;\;x + \frac{z}{\frac{a}{y - x}}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if t < -4.60000000000000005e37 or 4.4e18 < t Initial program 41.1%
associate-/l*72.9%
Simplified72.9%
Taylor expanded in x around 0 35.5%
associate-*r/62.6%
Simplified62.6%
if -4.60000000000000005e37 < t < -3.2999999999999998e-19Initial program 73.4%
add-cube-cbrt73.3%
pow373.2%
Applied egg-rr73.2%
Taylor expanded in z around inf 87.0%
div-sub87.0%
Simplified87.0%
if -3.2999999999999998e-19 < t < -1.60000000000000006e-24Initial program 51.2%
associate-/l*51.2%
Simplified51.2%
Taylor expanded in t around inf 100.0%
associate--l+100.0%
associate-*r/100.0%
associate-*r/100.0%
div-sub100.0%
distribute-lft-out--100.0%
associate-*r/100.0%
mul-1-neg100.0%
unsub-neg100.0%
distribute-rgt-out--100.0%
associate-/l*99.2%
Simplified99.2%
Taylor expanded in z around 0 100.0%
sub-neg100.0%
mul-1-neg100.0%
remove-double-neg100.0%
Simplified100.0%
if -1.60000000000000006e-24 < t < -8.99999999999999987e-111Initial program 87.0%
add-cube-cbrt86.3%
pow386.3%
Applied egg-rr86.3%
Taylor expanded in t around 0 67.5%
if -8.99999999999999987e-111 < t < 4.4e18Initial program 92.0%
associate-*l/94.5%
Simplified94.5%
clear-num94.5%
associate-/r/94.4%
Applied egg-rr94.4%
Taylor expanded in t around 0 73.7%
associate-/l*78.7%
Simplified78.7%
Final simplification70.9%
(FPCore (x y z t a)
:precision binary64
(if (<= t -7.5e+37)
y
(if (<= t -8.6e-189)
(- x (/ x (/ a z)))
(if (<= t 3.5e-171)
(/ z (/ a (- y x)))
(if (<= t 1.7e+98)
(* x (- 1.0 (/ z a)))
(if (<= t 1.9e+170) (/ z (/ t (- x y))) y))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -7.5e+37) {
tmp = y;
} else if (t <= -8.6e-189) {
tmp = x - (x / (a / z));
} else if (t <= 3.5e-171) {
tmp = z / (a / (y - x));
} else if (t <= 1.7e+98) {
tmp = x * (1.0 - (z / a));
} else if (t <= 1.9e+170) {
tmp = z / (t / (x - y));
} 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.5d+37)) then
tmp = y
else if (t <= (-8.6d-189)) then
tmp = x - (x / (a / z))
else if (t <= 3.5d-171) then
tmp = z / (a / (y - x))
else if (t <= 1.7d+98) then
tmp = x * (1.0d0 - (z / a))
else if (t <= 1.9d+170) then
tmp = z / (t / (x - y))
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.5e+37) {
tmp = y;
} else if (t <= -8.6e-189) {
tmp = x - (x / (a / z));
} else if (t <= 3.5e-171) {
tmp = z / (a / (y - x));
} else if (t <= 1.7e+98) {
tmp = x * (1.0 - (z / a));
} else if (t <= 1.9e+170) {
tmp = z / (t / (x - y));
} else {
tmp = y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -7.5e+37: tmp = y elif t <= -8.6e-189: tmp = x - (x / (a / z)) elif t <= 3.5e-171: tmp = z / (a / (y - x)) elif t <= 1.7e+98: tmp = x * (1.0 - (z / a)) elif t <= 1.9e+170: tmp = z / (t / (x - y)) else: tmp = y return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -7.5e+37) tmp = y; elseif (t <= -8.6e-189) tmp = Float64(x - Float64(x / Float64(a / z))); elseif (t <= 3.5e-171) tmp = Float64(z / Float64(a / Float64(y - x))); elseif (t <= 1.7e+98) tmp = Float64(x * Float64(1.0 - Float64(z / a))); elseif (t <= 1.9e+170) tmp = Float64(z / Float64(t / Float64(x - y))); else tmp = y; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -7.5e+37) tmp = y; elseif (t <= -8.6e-189) tmp = x - (x / (a / z)); elseif (t <= 3.5e-171) tmp = z / (a / (y - x)); elseif (t <= 1.7e+98) tmp = x * (1.0 - (z / a)); elseif (t <= 1.9e+170) tmp = z / (t / (x - y)); else tmp = y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -7.5e+37], y, If[LessEqual[t, -8.6e-189], N[(x - N[(x / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 3.5e-171], N[(z / N[(a / N[(y - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.7e+98], N[(x * N[(1.0 - N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.9e+170], N[(z / N[(t / N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], y]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -7.5 \cdot 10^{+37}:\\
\;\;\;\;y\\
\mathbf{elif}\;t \leq -8.6 \cdot 10^{-189}:\\
\;\;\;\;x - \frac{x}{\frac{a}{z}}\\
\mathbf{elif}\;t \leq 3.5 \cdot 10^{-171}:\\
\;\;\;\;\frac{z}{\frac{a}{y - x}}\\
\mathbf{elif}\;t \leq 1.7 \cdot 10^{+98}:\\
\;\;\;\;x \cdot \left(1 - \frac{z}{a}\right)\\
\mathbf{elif}\;t \leq 1.9 \cdot 10^{+170}:\\
\;\;\;\;\frac{z}{\frac{t}{x - y}}\\
\mathbf{else}:\\
\;\;\;\;y\\
\end{array}
\end{array}
if t < -7.5000000000000003e37 or 1.8999999999999999e170 < t Initial program 33.2%
associate-/l*68.1%
Simplified68.1%
Taylor expanded in t around inf 58.7%
if -7.5000000000000003e37 < t < -8.60000000000000071e-189Initial program 86.0%
+-commutative86.0%
associate-*l/88.4%
fma-def88.3%
Simplified88.3%
Taylor expanded in y around 0 59.3%
neg-mul-159.3%
distribute-neg-frac59.3%
Simplified59.3%
Taylor expanded in t around 0 42.8%
mul-1-neg42.8%
unsub-neg42.8%
associate-/l*49.6%
Simplified49.6%
if -8.60000000000000071e-189 < t < 3.49999999999999994e-171Initial program 92.5%
associate-/l*98.8%
Simplified98.8%
Taylor expanded in z around inf 79.7%
div-sub79.7%
associate-*r/74.4%
associate-/l*79.7%
Simplified79.7%
Taylor expanded in a around inf 70.8%
if 3.49999999999999994e-171 < t < 1.69999999999999986e98Initial program 83.2%
associate-/l*89.5%
Simplified89.5%
Taylor expanded in x around inf 52.9%
mul-1-neg52.9%
unsub-neg52.9%
Simplified52.9%
Taylor expanded in t around 0 49.5%
if 1.69999999999999986e98 < t < 1.8999999999999999e170Initial program 61.2%
associate-/l*84.2%
Simplified84.2%
Taylor expanded in t around inf 46.0%
associate--l+46.0%
associate-*r/46.0%
associate-*r/46.0%
div-sub46.0%
distribute-lft-out--46.0%
associate-*r/46.0%
mul-1-neg46.0%
unsub-neg46.0%
distribute-rgt-out--52.3%
associate-/l*69.5%
Simplified69.5%
frac-2neg69.5%
div-inv69.0%
sub-neg69.0%
distribute-neg-in69.0%
remove-double-neg69.0%
distribute-neg-frac69.0%
Applied egg-rr69.0%
Taylor expanded in z around inf 34.8%
associate-/l*42.8%
Simplified42.8%
Final simplification56.6%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -9.2e+185) (not (<= t 1.32e+129))) (+ 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 <= -9.2e+185) || !(t <= 1.32e+129)) {
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 <= (-9.2d+185)) .or. (.not. (t <= 1.32d+129))) 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 <= -9.2e+185) || !(t <= 1.32e+129)) {
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 <= -9.2e+185) or not (t <= 1.32e+129): 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 <= -9.2e+185) || !(t <= 1.32e+129)) 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 <= -9.2e+185) || ~((t <= 1.32e+129))) 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, -9.2e+185], N[Not[LessEqual[t, 1.32e+129]], $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 -9.2 \cdot 10^{+185} \lor \neg \left(t \leq 1.32 \cdot 10^{+129}\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 < -9.2000000000000005e185 or 1.32e129 < t Initial program 25.1%
associate-/l*62.1%
Simplified62.1%
Taylor expanded in t around inf 68.6%
associate--l+68.6%
associate-*r/68.6%
associate-*r/68.6%
div-sub68.6%
distribute-lft-out--68.6%
associate-*r/68.6%
mul-1-neg68.6%
unsub-neg68.6%
distribute-rgt-out--70.3%
associate-/l*90.0%
Simplified90.0%
if -9.2000000000000005e185 < t < 1.32e129Initial program 82.2%
associate-*l/89.4%
Simplified89.4%
Final simplification89.6%
(FPCore (x y z t a)
:precision binary64
(if (<= t -7.5e+37)
y
(if (<= t -8.6e-189)
(- x (/ x (/ a z)))
(if (<= t 5.6e-170)
(/ z (/ a (- y x)))
(if (<= t 1.4e+158) (* x (- 1.0 (/ z a))) y)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -7.5e+37) {
tmp = y;
} else if (t <= -8.6e-189) {
tmp = x - (x / (a / z));
} else if (t <= 5.6e-170) {
tmp = z / (a / (y - x));
} else if (t <= 1.4e+158) {
tmp = x * (1.0 - (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 <= (-7.5d+37)) then
tmp = y
else if (t <= (-8.6d-189)) then
tmp = x - (x / (a / z))
else if (t <= 5.6d-170) then
tmp = z / (a / (y - x))
else if (t <= 1.4d+158) then
tmp = x * (1.0d0 - (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 <= -7.5e+37) {
tmp = y;
} else if (t <= -8.6e-189) {
tmp = x - (x / (a / z));
} else if (t <= 5.6e-170) {
tmp = z / (a / (y - x));
} else if (t <= 1.4e+158) {
tmp = x * (1.0 - (z / a));
} else {
tmp = y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -7.5e+37: tmp = y elif t <= -8.6e-189: tmp = x - (x / (a / z)) elif t <= 5.6e-170: tmp = z / (a / (y - x)) elif t <= 1.4e+158: tmp = x * (1.0 - (z / a)) else: tmp = y return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -7.5e+37) tmp = y; elseif (t <= -8.6e-189) tmp = Float64(x - Float64(x / Float64(a / z))); elseif (t <= 5.6e-170) tmp = Float64(z / Float64(a / Float64(y - x))); elseif (t <= 1.4e+158) tmp = Float64(x * Float64(1.0 - Float64(z / a))); else tmp = y; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -7.5e+37) tmp = y; elseif (t <= -8.6e-189) tmp = x - (x / (a / z)); elseif (t <= 5.6e-170) tmp = z / (a / (y - x)); elseif (t <= 1.4e+158) tmp = x * (1.0 - (z / a)); else tmp = y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -7.5e+37], y, If[LessEqual[t, -8.6e-189], N[(x - N[(x / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 5.6e-170], N[(z / N[(a / N[(y - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.4e+158], N[(x * N[(1.0 - N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], y]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -7.5 \cdot 10^{+37}:\\
\;\;\;\;y\\
\mathbf{elif}\;t \leq -8.6 \cdot 10^{-189}:\\
\;\;\;\;x - \frac{x}{\frac{a}{z}}\\
\mathbf{elif}\;t \leq 5.6 \cdot 10^{-170}:\\
\;\;\;\;\frac{z}{\frac{a}{y - x}}\\
\mathbf{elif}\;t \leq 1.4 \cdot 10^{+158}:\\
\;\;\;\;x \cdot \left(1 - \frac{z}{a}\right)\\
\mathbf{else}:\\
\;\;\;\;y\\
\end{array}
\end{array}
if t < -7.5000000000000003e37 or 1.40000000000000001e158 < t Initial program 34.6%
associate-/l*68.8%
Simplified68.8%
Taylor expanded in t around inf 57.5%
if -7.5000000000000003e37 < t < -8.60000000000000071e-189Initial program 86.0%
+-commutative86.0%
associate-*l/88.4%
fma-def88.3%
Simplified88.3%
Taylor expanded in y around 0 59.3%
neg-mul-159.3%
distribute-neg-frac59.3%
Simplified59.3%
Taylor expanded in t around 0 42.8%
mul-1-neg42.8%
unsub-neg42.8%
associate-/l*49.6%
Simplified49.6%
if -8.60000000000000071e-189 < t < 5.59999999999999991e-170Initial program 92.5%
associate-/l*98.8%
Simplified98.8%
Taylor expanded in z around inf 79.7%
div-sub79.7%
associate-*r/74.4%
associate-/l*79.7%
Simplified79.7%
Taylor expanded in a around inf 70.8%
if 5.59999999999999991e-170 < t < 1.40000000000000001e158Initial program 77.9%
associate-/l*88.0%
Simplified88.0%
Taylor expanded in x around inf 47.9%
mul-1-neg47.9%
unsub-neg47.9%
Simplified47.9%
Taylor expanded in t around 0 43.3%
Final simplification55.0%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* y (/ (- z t) (- a t)))))
(if (<= t -1.75e+37)
t_1
(if (<= t 2e-168)
(* z (/ (- y x) (- a t)))
(if (<= t 6.2e+17) (* x (- 1.0 (/ 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.75e+37) {
tmp = t_1;
} else if (t <= 2e-168) {
tmp = z * ((y - x) / (a - t));
} else if (t <= 6.2e+17) {
tmp = x * (1.0 - (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.75d+37)) then
tmp = t_1
else if (t <= 2d-168) then
tmp = z * ((y - x) / (a - t))
else if (t <= 6.2d+17) then
tmp = x * (1.0d0 - (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.75e+37) {
tmp = t_1;
} else if (t <= 2e-168) {
tmp = z * ((y - x) / (a - t));
} else if (t <= 6.2e+17) {
tmp = x * (1.0 - (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.75e+37: tmp = t_1 elif t <= 2e-168: tmp = z * ((y - x) / (a - t)) elif t <= 6.2e+17: tmp = x * (1.0 - (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.75e+37) tmp = t_1; elseif (t <= 2e-168) tmp = Float64(z * Float64(Float64(y - x) / Float64(a - t))); elseif (t <= 6.2e+17) tmp = Float64(x * Float64(1.0 - 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.75e+37) tmp = t_1; elseif (t <= 2e-168) tmp = z * ((y - x) / (a - t)); elseif (t <= 6.2e+17) tmp = x * (1.0 - (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.75e+37], t$95$1, If[LessEqual[t, 2e-168], N[(z * N[(N[(y - x), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 6.2e+17], N[(x * N[(1.0 - 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.75 \cdot 10^{+37}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq 2 \cdot 10^{-168}:\\
\;\;\;\;z \cdot \frac{y - x}{a - t}\\
\mathbf{elif}\;t \leq 6.2 \cdot 10^{+17}:\\
\;\;\;\;x \cdot \left(1 - \frac{z}{a}\right)\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if t < -1.75e37 or 6.2e17 < t Initial program 41.1%
associate-/l*72.9%
Simplified72.9%
Taylor expanded in x around 0 35.5%
associate-*r/62.6%
Simplified62.6%
if -1.75e37 < t < 2.0000000000000001e-168Initial program 89.8%
add-cube-cbrt89.3%
pow389.3%
Applied egg-rr89.3%
Taylor expanded in z around inf 68.8%
div-sub68.8%
Simplified68.8%
if 2.0000000000000001e-168 < t < 6.2e17Initial program 90.1%
associate-/l*90.0%
Simplified90.0%
Taylor expanded in x around inf 59.4%
mul-1-neg59.4%
unsub-neg59.4%
Simplified59.4%
Taylor expanded in t around 0 54.9%
Final simplification63.7%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* y (/ (- z t) (- a t)))))
(if (<= t -3.5e+37)
t_1
(if (<= t -5.2e-58)
(* z (/ (- y x) (- a t)))
(if (<= t 9.5e+16) (+ x (/ z (/ a (- y x)))) 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 <= -3.5e+37) {
tmp = t_1;
} else if (t <= -5.2e-58) {
tmp = z * ((y - x) / (a - t));
} else if (t <= 9.5e+16) {
tmp = x + (z / (a / (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 = y * ((z - t) / (a - t))
if (t <= (-3.5d+37)) then
tmp = t_1
else if (t <= (-5.2d-58)) then
tmp = z * ((y - x) / (a - t))
else if (t <= 9.5d+16) then
tmp = x + (z / (a / (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 = y * ((z - t) / (a - t));
double tmp;
if (t <= -3.5e+37) {
tmp = t_1;
} else if (t <= -5.2e-58) {
tmp = z * ((y - x) / (a - t));
} else if (t <= 9.5e+16) {
tmp = x + (z / (a / (y - x)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = y * ((z - t) / (a - t)) tmp = 0 if t <= -3.5e+37: tmp = t_1 elif t <= -5.2e-58: tmp = z * ((y - x) / (a - t)) elif t <= 9.5e+16: tmp = x + (z / (a / (y - x))) 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 <= -3.5e+37) tmp = t_1; elseif (t <= -5.2e-58) tmp = Float64(z * Float64(Float64(y - x) / Float64(a - t))); elseif (t <= 9.5e+16) tmp = Float64(x + Float64(z / Float64(a / Float64(y - x)))); 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 <= -3.5e+37) tmp = t_1; elseif (t <= -5.2e-58) tmp = z * ((y - x) / (a - t)); elseif (t <= 9.5e+16) tmp = x + (z / (a / (y - x))); 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, -3.5e+37], t$95$1, If[LessEqual[t, -5.2e-58], N[(z * N[(N[(y - x), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 9.5e+16], N[(x + N[(z / N[(a / N[(y - x), $MachinePrecision]), $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 -3.5 \cdot 10^{+37}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t \leq -5.2 \cdot 10^{-58}:\\
\;\;\;\;z \cdot \frac{y - x}{a - t}\\
\mathbf{elif}\;t \leq 9.5 \cdot 10^{+16}:\\
\;\;\;\;x + \frac{z}{\frac{a}{y - x}}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if t < -3.5e37 or 9.5e16 < t Initial program 41.1%
associate-/l*72.9%
Simplified72.9%
Taylor expanded in x around 0 35.5%
associate-*r/62.6%
Simplified62.6%
if -3.5e37 < t < -5.20000000000000013e-58Initial program 77.6%
add-cube-cbrt77.3%
pow377.2%
Applied egg-rr77.2%
Taylor expanded in z around inf 67.0%
div-sub67.0%
Simplified67.0%
if -5.20000000000000013e-58 < t < 9.5e16Initial program 91.6%
associate-*l/94.1%
Simplified94.1%
clear-num94.0%
associate-/r/94.0%
Applied egg-rr94.0%
Taylor expanded in t around 0 74.4%
associate-/l*79.1%
Simplified79.1%
Final simplification70.5%
(FPCore (x y z t a)
:precision binary64
(if (<= t -1.9e+60)
(- y (/ a (/ t (- x y))))
(if (<= t -1.2e-58)
(* z (/ (- y x) (- a t)))
(if (<= t 2.15e+18)
(+ x (/ z (/ a (- y x))))
(* y (/ (- z t) (- a t)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -1.9e+60) {
tmp = y - (a / (t / (x - y)));
} else if (t <= -1.2e-58) {
tmp = z * ((y - x) / (a - t));
} else if (t <= 2.15e+18) {
tmp = x + (z / (a / (y - x)));
} 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 (t <= (-1.9d+60)) then
tmp = y - (a / (t / (x - y)))
else if (t <= (-1.2d-58)) then
tmp = z * ((y - x) / (a - t))
else if (t <= 2.15d+18) then
tmp = x + (z / (a / (y - x)))
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 (t <= -1.9e+60) {
tmp = y - (a / (t / (x - y)));
} else if (t <= -1.2e-58) {
tmp = z * ((y - x) / (a - t));
} else if (t <= 2.15e+18) {
tmp = x + (z / (a / (y - x)));
} else {
tmp = y * ((z - t) / (a - t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -1.9e+60: tmp = y - (a / (t / (x - y))) elif t <= -1.2e-58: tmp = z * ((y - x) / (a - t)) elif t <= 2.15e+18: tmp = x + (z / (a / (y - x))) else: tmp = y * ((z - t) / (a - t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -1.9e+60) tmp = Float64(y - Float64(a / Float64(t / Float64(x - y)))); elseif (t <= -1.2e-58) tmp = Float64(z * Float64(Float64(y - x) / Float64(a - t))); elseif (t <= 2.15e+18) tmp = Float64(x + Float64(z / Float64(a / Float64(y - x)))); 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 (t <= -1.9e+60) tmp = y - (a / (t / (x - y))); elseif (t <= -1.2e-58) tmp = z * ((y - x) / (a - t)); elseif (t <= 2.15e+18) tmp = x + (z / (a / (y - x))); else tmp = y * ((z - t) / (a - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -1.9e+60], N[(y - N[(a / N[(t / N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, -1.2e-58], N[(z * N[(N[(y - x), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.15e+18], N[(x + N[(z / N[(a / N[(y - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.9 \cdot 10^{+60}:\\
\;\;\;\;y - \frac{a}{\frac{t}{x - y}}\\
\mathbf{elif}\;t \leq -1.2 \cdot 10^{-58}:\\
\;\;\;\;z \cdot \frac{y - x}{a - t}\\
\mathbf{elif}\;t \leq 2.15 \cdot 10^{+18}:\\
\;\;\;\;x + \frac{z}{\frac{a}{y - x}}\\
\mathbf{else}:\\
\;\;\;\;y \cdot \frac{z - t}{a - t}\\
\end{array}
\end{array}
if t < -1.90000000000000005e60Initial program 37.4%
associate-/l*70.4%
Simplified70.4%
Taylor expanded in t around inf 66.1%
associate--l+66.1%
associate-*r/66.1%
associate-*r/66.1%
div-sub66.1%
distribute-lft-out--66.1%
associate-*r/66.1%
mul-1-neg66.1%
unsub-neg66.1%
distribute-rgt-out--66.4%
associate-/l*81.5%
Simplified81.5%
frac-2neg81.5%
div-inv81.5%
sub-neg81.5%
distribute-neg-in81.5%
remove-double-neg81.5%
distribute-neg-frac81.5%
Applied egg-rr81.5%
Taylor expanded in z around 0 58.6%
associate-/l*66.3%
Simplified66.3%
if -1.90000000000000005e60 < t < -1.2e-58Initial program 80.9%
add-cube-cbrt80.4%
pow380.4%
Applied egg-rr80.4%
Taylor expanded in z around inf 66.2%
div-sub66.2%
Simplified66.2%
if -1.2e-58 < t < 2.15e18Initial program 91.6%
associate-*l/94.1%
Simplified94.1%
clear-num94.0%
associate-/r/94.0%
Applied egg-rr94.0%
Taylor expanded in t around 0 74.4%
associate-/l*79.1%
Simplified79.1%
if 2.15e18 < t Initial program 41.2%
associate-/l*73.5%
Simplified73.5%
Taylor expanded in x around 0 33.0%
associate-*r/61.0%
Simplified61.0%
Final simplification70.8%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -3.4e-27) (not (<= t 4.2e+96))) (+ y (/ (- x y) (/ t z))) (+ x (* (- z t) (/ (- y x) a)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -3.4e-27) || !(t <= 4.2e+96)) {
tmp = y + ((x - y) / (t / z));
} else {
tmp = x + ((z - t) * ((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.4d-27)) .or. (.not. (t <= 4.2d+96))) then
tmp = y + ((x - y) / (t / z))
else
tmp = x + ((z - t) * ((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.4e-27) || !(t <= 4.2e+96)) {
tmp = y + ((x - y) / (t / z));
} else {
tmp = x + ((z - t) * ((y - x) / a));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -3.4e-27) or not (t <= 4.2e+96): tmp = y + ((x - y) / (t / z)) else: tmp = x + ((z - t) * ((y - x) / a)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -3.4e-27) || !(t <= 4.2e+96)) tmp = Float64(y + Float64(Float64(x - y) / Float64(t / z))); else tmp = Float64(x + Float64(Float64(z - t) * Float64(Float64(y - x) / a))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -3.4e-27) || ~((t <= 4.2e+96))) tmp = y + ((x - y) / (t / z)); else tmp = x + ((z - t) * ((y - x) / a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -3.4e-27], N[Not[LessEqual[t, 4.2e+96]], $MachinePrecision]], N[(y + N[(N[(x - y), $MachinePrecision] / N[(t / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(z - t), $MachinePrecision] * N[(N[(y - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.4 \cdot 10^{-27} \lor \neg \left(t \leq 4.2 \cdot 10^{+96}\right):\\
\;\;\;\;y + \frac{x - y}{\frac{t}{z}}\\
\mathbf{else}:\\
\;\;\;\;x + \left(z - t\right) \cdot \frac{y - x}{a}\\
\end{array}
\end{array}
if t < -3.3999999999999997e-27 or 4.2000000000000002e96 < t Initial program 40.5%
associate-/l*71.5%
Simplified71.5%
Taylor expanded in t around inf 63.9%
associate--l+63.9%
associate-*r/63.9%
associate-*r/63.9%
div-sub63.9%
distribute-lft-out--63.9%
associate-*r/63.9%
mul-1-neg63.9%
unsub-neg63.9%
distribute-rgt-out--64.9%
associate-/l*80.7%
Simplified80.7%
Taylor expanded in z around inf 70.4%
if -3.3999999999999997e-27 < t < 4.2000000000000002e96Initial program 88.3%
associate-*l/92.3%
Simplified92.3%
Taylor expanded in a around inf 76.4%
Final simplification73.7%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -1.05e-27) (not (<= t 4.2e+97))) (+ y (/ (- x y) (/ t z))) (+ x (/ (- y x) (/ a (- z t))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -1.05e-27) || !(t <= 4.2e+97)) {
tmp = y + ((x - y) / (t / z));
} else {
tmp = x + ((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 ((t <= (-1.05d-27)) .or. (.not. (t <= 4.2d+97))) then
tmp = y + ((x - y) / (t / z))
else
tmp = x + ((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 ((t <= -1.05e-27) || !(t <= 4.2e+97)) {
tmp = y + ((x - y) / (t / z));
} else {
tmp = x + ((y - x) / (a / (z - t)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -1.05e-27) or not (t <= 4.2e+97): tmp = y + ((x - y) / (t / z)) else: tmp = x + ((y - x) / (a / (z - t))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -1.05e-27) || !(t <= 4.2e+97)) tmp = Float64(y + Float64(Float64(x - y) / Float64(t / z))); else tmp = Float64(x + Float64(Float64(y - x) / Float64(a / Float64(z - t)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -1.05e-27) || ~((t <= 4.2e+97))) tmp = y + ((x - y) / (t / z)); else tmp = x + ((y - x) / (a / (z - t))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -1.05e-27], N[Not[LessEqual[t, 4.2e+97]], $MachinePrecision]], N[(y + N[(N[(x - y), $MachinePrecision] / N[(t / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(y - x), $MachinePrecision] / N[(a / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.05 \cdot 10^{-27} \lor \neg \left(t \leq 4.2 \cdot 10^{+97}\right):\\
\;\;\;\;y + \frac{x - y}{\frac{t}{z}}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y - x}{\frac{a}{z - t}}\\
\end{array}
\end{array}
if t < -1.05000000000000008e-27 or 4.20000000000000023e97 < t Initial program 40.5%
associate-/l*71.5%
Simplified71.5%
Taylor expanded in t around inf 63.9%
associate--l+63.9%
associate-*r/63.9%
associate-*r/63.9%
div-sub63.9%
distribute-lft-out--63.9%
associate-*r/63.9%
mul-1-neg63.9%
unsub-neg63.9%
distribute-rgt-out--64.9%
associate-/l*80.7%
Simplified80.7%
Taylor expanded in z around inf 70.4%
if -1.05000000000000008e-27 < t < 4.20000000000000023e97Initial program 88.3%
associate-/l*93.9%
Simplified93.9%
Taylor expanded in a around inf 73.1%
associate-/l*78.0%
Simplified78.0%
Final simplification74.6%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -4.6e-27) (not (<= t 1.25e+97))) (+ y (/ (- x y) (/ t (- z a)))) (+ x (/ (- y x) (/ a (- z t))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -4.6e-27) || !(t <= 1.25e+97)) {
tmp = y + ((x - y) / (t / (z - a)));
} else {
tmp = x + ((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 ((t <= (-4.6d-27)) .or. (.not. (t <= 1.25d+97))) then
tmp = y + ((x - y) / (t / (z - a)))
else
tmp = x + ((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 ((t <= -4.6e-27) || !(t <= 1.25e+97)) {
tmp = y + ((x - y) / (t / (z - a)));
} else {
tmp = x + ((y - x) / (a / (z - t)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -4.6e-27) or not (t <= 1.25e+97): tmp = y + ((x - y) / (t / (z - a))) else: tmp = x + ((y - x) / (a / (z - t))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -4.6e-27) || !(t <= 1.25e+97)) tmp = Float64(y + Float64(Float64(x - y) / Float64(t / Float64(z - a)))); else tmp = Float64(x + Float64(Float64(y - x) / Float64(a / Float64(z - t)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -4.6e-27) || ~((t <= 1.25e+97))) tmp = y + ((x - y) / (t / (z - a))); else tmp = x + ((y - x) / (a / (z - t))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -4.6e-27], N[Not[LessEqual[t, 1.25e+97]], $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[(a / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.6 \cdot 10^{-27} \lor \neg \left(t \leq 1.25 \cdot 10^{+97}\right):\\
\;\;\;\;y + \frac{x - y}{\frac{t}{z - a}}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y - x}{\frac{a}{z - t}}\\
\end{array}
\end{array}
if t < -4.5999999999999999e-27 or 1.25e97 < t Initial program 40.5%
associate-/l*71.5%
Simplified71.5%
Taylor expanded in t around inf 63.9%
associate--l+63.9%
associate-*r/63.9%
associate-*r/63.9%
div-sub63.9%
distribute-lft-out--63.9%
associate-*r/63.9%
mul-1-neg63.9%
unsub-neg63.9%
distribute-rgt-out--64.9%
associate-/l*80.7%
Simplified80.7%
if -4.5999999999999999e-27 < t < 1.25e97Initial program 88.3%
associate-/l*93.9%
Simplified93.9%
Taylor expanded in a around inf 73.1%
associate-/l*78.0%
Simplified78.0%
Final simplification79.2%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -2.7e+37) (not (<= t 2.4e+17))) (* y (/ (- z t) (- a t))) (+ x (/ (- y x) (/ a z)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -2.7e+37) || !(t <= 2.4e+17)) {
tmp = y * ((z - t) / (a - t));
} else {
tmp = x + ((y - x) / (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 <= (-2.7d+37)) .or. (.not. (t <= 2.4d+17))) then
tmp = y * ((z - t) / (a - t))
else
tmp = x + ((y - x) / (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 <= -2.7e+37) || !(t <= 2.4e+17)) {
tmp = y * ((z - t) / (a - t));
} else {
tmp = x + ((y - x) / (a / z));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -2.7e+37) or not (t <= 2.4e+17): tmp = y * ((z - t) / (a - t)) else: tmp = x + ((y - x) / (a / z)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -2.7e+37) || !(t <= 2.4e+17)) tmp = Float64(y * Float64(Float64(z - t) / Float64(a - t))); else tmp = Float64(x + Float64(Float64(y - x) / Float64(a / z))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -2.7e+37) || ~((t <= 2.4e+17))) tmp = y * ((z - t) / (a - t)); else tmp = x + ((y - x) / (a / z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -2.7e+37], N[Not[LessEqual[t, 2.4e+17]], $MachinePrecision]], N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(y - x), $MachinePrecision] / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.7 \cdot 10^{+37} \lor \neg \left(t \leq 2.4 \cdot 10^{+17}\right):\\
\;\;\;\;y \cdot \frac{z - t}{a - t}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y - x}{\frac{a}{z}}\\
\end{array}
\end{array}
if t < -2.69999999999999986e37 or 2.4e17 < t Initial program 41.1%
associate-/l*72.9%
Simplified72.9%
Taylor expanded in x around 0 35.5%
associate-*r/62.6%
Simplified62.6%
if -2.69999999999999986e37 < t < 2.4e17Initial program 89.9%
associate-/l*93.6%
Simplified93.6%
Taylor expanded in t around 0 74.9%
Final simplification69.1%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -2.8e-27) (not (<= t 28000000.0))) (+ y (/ (- x y) (/ t z))) (+ x (/ (- y x) (/ a z)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -2.8e-27) || !(t <= 28000000.0)) {
tmp = y + ((x - y) / (t / z));
} else {
tmp = x + ((y - x) / (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 <= (-2.8d-27)) .or. (.not. (t <= 28000000.0d0))) then
tmp = y + ((x - y) / (t / z))
else
tmp = x + ((y - x) / (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 <= -2.8e-27) || !(t <= 28000000.0)) {
tmp = y + ((x - y) / (t / z));
} else {
tmp = x + ((y - x) / (a / z));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -2.8e-27) or not (t <= 28000000.0): tmp = y + ((x - y) / (t / z)) else: tmp = x + ((y - x) / (a / z)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -2.8e-27) || !(t <= 28000000.0)) tmp = Float64(y + Float64(Float64(x - y) / Float64(t / z))); else tmp = Float64(x + Float64(Float64(y - x) / Float64(a / z))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -2.8e-27) || ~((t <= 28000000.0))) tmp = y + ((x - y) / (t / z)); else tmp = x + ((y - x) / (a / z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -2.8e-27], N[Not[LessEqual[t, 28000000.0]], $MachinePrecision]], N[(y + N[(N[(x - y), $MachinePrecision] / N[(t / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(y - x), $MachinePrecision] / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.8 \cdot 10^{-27} \lor \neg \left(t \leq 28000000\right):\\
\;\;\;\;y + \frac{x - y}{\frac{t}{z}}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y - x}{\frac{a}{z}}\\
\end{array}
\end{array}
if t < -2.8e-27 or 2.8e7 < t Initial program 43.6%
associate-/l*73.1%
Simplified73.1%
Taylor expanded in t around inf 62.2%
associate--l+62.2%
associate-*r/62.2%
associate-*r/62.2%
div-sub62.2%
distribute-lft-out--62.2%
associate-*r/62.2%
mul-1-neg62.2%
unsub-neg62.2%
distribute-rgt-out--63.0%
associate-/l*76.7%
Simplified76.7%
Taylor expanded in z around inf 67.2%
if -2.8e-27 < t < 2.8e7Initial program 92.0%
associate-/l*95.4%
Simplified95.4%
Taylor expanded in t around 0 78.0%
Final simplification72.5%
(FPCore (x y z t a)
:precision binary64
(if (<= t -5.3e-27)
y
(if (<= t -1.75e-224)
x
(if (<= t 7.2e-178) (* x (/ z t)) (if (<= t 2.6e+154) x y)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -5.3e-27) {
tmp = y;
} else if (t <= -1.75e-224) {
tmp = x;
} else if (t <= 7.2e-178) {
tmp = x * (z / t);
} else if (t <= 2.6e+154) {
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 <= (-5.3d-27)) then
tmp = y
else if (t <= (-1.75d-224)) then
tmp = x
else if (t <= 7.2d-178) then
tmp = x * (z / t)
else if (t <= 2.6d+154) 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 <= -5.3e-27) {
tmp = y;
} else if (t <= -1.75e-224) {
tmp = x;
} else if (t <= 7.2e-178) {
tmp = x * (z / t);
} else if (t <= 2.6e+154) {
tmp = x;
} else {
tmp = y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -5.3e-27: tmp = y elif t <= -1.75e-224: tmp = x elif t <= 7.2e-178: tmp = x * (z / t) elif t <= 2.6e+154: tmp = x else: tmp = y return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -5.3e-27) tmp = y; elseif (t <= -1.75e-224) tmp = x; elseif (t <= 7.2e-178) tmp = Float64(x * Float64(z / t)); elseif (t <= 2.6e+154) tmp = x; else tmp = y; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -5.3e-27) tmp = y; elseif (t <= -1.75e-224) tmp = x; elseif (t <= 7.2e-178) tmp = x * (z / t); elseif (t <= 2.6e+154) tmp = x; else tmp = y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -5.3e-27], y, If[LessEqual[t, -1.75e-224], x, If[LessEqual[t, 7.2e-178], N[(x * N[(z / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.6e+154], x, y]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -5.3 \cdot 10^{-27}:\\
\;\;\;\;y\\
\mathbf{elif}\;t \leq -1.75 \cdot 10^{-224}:\\
\;\;\;\;x\\
\mathbf{elif}\;t \leq 7.2 \cdot 10^{-178}:\\
\;\;\;\;x \cdot \frac{z}{t}\\
\mathbf{elif}\;t \leq 2.6 \cdot 10^{+154}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;y\\
\end{array}
\end{array}
if t < -5.30000000000000006e-27 or 2.59999999999999989e154 < t Initial program 38.3%
associate-/l*70.0%
Simplified70.0%
Taylor expanded in t around inf 53.1%
if -5.30000000000000006e-27 < t < -1.75000000000000009e-224 or 7.19999999999999987e-178 < t < 2.59999999999999989e154Initial program 82.3%
associate-/l*90.5%
Simplified90.5%
Taylor expanded in a around inf 36.1%
if -1.75000000000000009e-224 < t < 7.19999999999999987e-178Initial program 93.2%
associate-/l*98.7%
Simplified98.7%
Taylor expanded in x around inf 64.8%
mul-1-neg64.8%
unsub-neg64.8%
Simplified64.8%
Taylor expanded in a around 0 29.2%
Final simplification41.5%
(FPCore (x y z t a)
:precision binary64
(if (<= t -5.3e-27)
y
(if (<= t -2.02e-224)
x
(if (<= t 4.4e-180) (/ x (/ t z)) (if (<= t 2.6e+154) x y)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -5.3e-27) {
tmp = y;
} else if (t <= -2.02e-224) {
tmp = x;
} else if (t <= 4.4e-180) {
tmp = x / (t / z);
} else if (t <= 2.6e+154) {
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 <= (-5.3d-27)) then
tmp = y
else if (t <= (-2.02d-224)) then
tmp = x
else if (t <= 4.4d-180) then
tmp = x / (t / z)
else if (t <= 2.6d+154) 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 <= -5.3e-27) {
tmp = y;
} else if (t <= -2.02e-224) {
tmp = x;
} else if (t <= 4.4e-180) {
tmp = x / (t / z);
} else if (t <= 2.6e+154) {
tmp = x;
} else {
tmp = y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -5.3e-27: tmp = y elif t <= -2.02e-224: tmp = x elif t <= 4.4e-180: tmp = x / (t / z) elif t <= 2.6e+154: tmp = x else: tmp = y return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -5.3e-27) tmp = y; elseif (t <= -2.02e-224) tmp = x; elseif (t <= 4.4e-180) tmp = Float64(x / Float64(t / z)); elseif (t <= 2.6e+154) tmp = x; else tmp = y; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -5.3e-27) tmp = y; elseif (t <= -2.02e-224) tmp = x; elseif (t <= 4.4e-180) tmp = x / (t / z); elseif (t <= 2.6e+154) tmp = x; else tmp = y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -5.3e-27], y, If[LessEqual[t, -2.02e-224], x, If[LessEqual[t, 4.4e-180], N[(x / N[(t / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.6e+154], x, y]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -5.3 \cdot 10^{-27}:\\
\;\;\;\;y\\
\mathbf{elif}\;t \leq -2.02 \cdot 10^{-224}:\\
\;\;\;\;x\\
\mathbf{elif}\;t \leq 4.4 \cdot 10^{-180}:\\
\;\;\;\;\frac{x}{\frac{t}{z}}\\
\mathbf{elif}\;t \leq 2.6 \cdot 10^{+154}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;y\\
\end{array}
\end{array}
if t < -5.30000000000000006e-27 or 2.59999999999999989e154 < t Initial program 38.3%
associate-/l*70.0%
Simplified70.0%
Taylor expanded in t around inf 53.1%
if -5.30000000000000006e-27 < t < -2.02e-224 or 4.40000000000000026e-180 < t < 2.59999999999999989e154Initial program 82.3%
associate-/l*90.5%
Simplified90.5%
Taylor expanded in a around inf 36.1%
if -2.02e-224 < t < 4.40000000000000026e-180Initial program 93.2%
associate-/l*98.7%
Simplified98.7%
Taylor expanded in z around -inf 77.9%
Taylor expanded in a around 0 37.7%
associate-*r/37.7%
associate-*r*37.7%
neg-mul-137.7%
Simplified37.7%
Taylor expanded in y around 0 27.1%
associate-/l*29.2%
Simplified29.2%
Final simplification41.5%
(FPCore (x y z t a) :precision binary64 (if (<= t -7.2e+37) y (if (<= t 2.6e+154) (* x (- 1.0 (/ z a))) y)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -7.2e+37) {
tmp = y;
} else if (t <= 2.6e+154) {
tmp = x * (1.0 - (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 <= (-7.2d+37)) then
tmp = y
else if (t <= 2.6d+154) then
tmp = x * (1.0d0 - (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 <= -7.2e+37) {
tmp = y;
} else if (t <= 2.6e+154) {
tmp = x * (1.0 - (z / a));
} else {
tmp = y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -7.2e+37: tmp = y elif t <= 2.6e+154: tmp = x * (1.0 - (z / a)) else: tmp = y return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -7.2e+37) tmp = y; elseif (t <= 2.6e+154) tmp = Float64(x * Float64(1.0 - Float64(z / a))); else tmp = y; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -7.2e+37) tmp = y; elseif (t <= 2.6e+154) tmp = x * (1.0 - (z / a)); else tmp = y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -7.2e+37], y, If[LessEqual[t, 2.6e+154], N[(x * N[(1.0 - N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], y]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -7.2 \cdot 10^{+37}:\\
\;\;\;\;y\\
\mathbf{elif}\;t \leq 2.6 \cdot 10^{+154}:\\
\;\;\;\;x \cdot \left(1 - \frac{z}{a}\right)\\
\mathbf{else}:\\
\;\;\;\;y\\
\end{array}
\end{array}
if t < -7.19999999999999995e37 or 2.59999999999999989e154 < t Initial program 34.6%
associate-/l*68.8%
Simplified68.8%
Taylor expanded in t around inf 57.5%
if -7.19999999999999995e37 < t < 2.59999999999999989e154Initial program 84.6%
associate-/l*92.1%
Simplified92.1%
Taylor expanded in x around inf 55.0%
mul-1-neg55.0%
unsub-neg55.0%
Simplified55.0%
Taylor expanded in t around 0 48.9%
Final simplification51.9%
(FPCore (x y z t a) :precision binary64 (if (<= t -4.8e+29) y (if (<= t 4.3e-169) (/ y (/ a z)) (if (<= t 4.6e+154) x y))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -4.8e+29) {
tmp = y;
} else if (t <= 4.3e-169) {
tmp = y / (a / z);
} else if (t <= 4.6e+154) {
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 <= (-4.8d+29)) then
tmp = y
else if (t <= 4.3d-169) then
tmp = y / (a / z)
else if (t <= 4.6d+154) 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 <= -4.8e+29) {
tmp = y;
} else if (t <= 4.3e-169) {
tmp = y / (a / z);
} else if (t <= 4.6e+154) {
tmp = x;
} else {
tmp = y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -4.8e+29: tmp = y elif t <= 4.3e-169: tmp = y / (a / z) elif t <= 4.6e+154: tmp = x else: tmp = y return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -4.8e+29) tmp = y; elseif (t <= 4.3e-169) tmp = Float64(y / Float64(a / z)); elseif (t <= 4.6e+154) tmp = x; else tmp = y; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -4.8e+29) tmp = y; elseif (t <= 4.3e-169) tmp = y / (a / z); elseif (t <= 4.6e+154) tmp = x; else tmp = y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -4.8e+29], y, If[LessEqual[t, 4.3e-169], N[(y / N[(a / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 4.6e+154], x, y]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.8 \cdot 10^{+29}:\\
\;\;\;\;y\\
\mathbf{elif}\;t \leq 4.3 \cdot 10^{-169}:\\
\;\;\;\;\frac{y}{\frac{a}{z}}\\
\mathbf{elif}\;t \leq 4.6 \cdot 10^{+154}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;y\\
\end{array}
\end{array}
if t < -4.8000000000000002e29 or 4.6e154 < t Initial program 35.4%
associate-/l*69.1%
Simplified69.1%
Taylor expanded in t around inf 56.9%
if -4.8000000000000002e29 < t < 4.29999999999999984e-169Initial program 89.6%
associate-/l*95.1%
Simplified95.1%
Taylor expanded in z around -inf 66.1%
Taylor expanded in y around inf 39.5%
associate-/l*42.4%
Simplified42.4%
Taylor expanded in a around inf 35.7%
associate-/l*40.6%
Simplified40.6%
if 4.29999999999999984e-169 < t < 4.6e154Initial program 77.9%
associate-/l*88.0%
Simplified88.0%
Taylor expanded in a around inf 34.3%
Final simplification44.6%
(FPCore (x y z t a) :precision binary64 (if (<= t -5.3e-27) y (if (<= t 8e+154) x y)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -5.3e-27) {
tmp = y;
} else if (t <= 8e+154) {
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 <= (-5.3d-27)) then
tmp = y
else if (t <= 8d+154) 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 <= -5.3e-27) {
tmp = y;
} else if (t <= 8e+154) {
tmp = x;
} else {
tmp = y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -5.3e-27: tmp = y elif t <= 8e+154: tmp = x else: tmp = y return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -5.3e-27) tmp = y; elseif (t <= 8e+154) tmp = x; else tmp = y; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -5.3e-27) tmp = y; elseif (t <= 8e+154) tmp = x; else tmp = y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -5.3e-27], y, If[LessEqual[t, 8e+154], x, y]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -5.3 \cdot 10^{-27}:\\
\;\;\;\;y\\
\mathbf{elif}\;t \leq 8 \cdot 10^{+154}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;y\\
\end{array}
\end{array}
if t < -5.30000000000000006e-27 or 8.0000000000000003e154 < t Initial program 38.3%
associate-/l*70.0%
Simplified70.0%
Taylor expanded in t around inf 53.1%
if -5.30000000000000006e-27 < t < 8.0000000000000003e154Initial program 85.4%
associate-/l*92.8%
Simplified92.8%
Taylor expanded in a around inf 30.9%
Final simplification39.6%
(FPCore (x y z t a) :precision binary64 0.0)
double code(double x, double y, double z, double t, double a) {
return 0.0;
}
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 = 0.0d0
end function
public static double code(double x, double y, double z, double t, double a) {
return 0.0;
}
def code(x, y, z, t, a): return 0.0
function code(x, y, z, t, a) return 0.0 end
function tmp = code(x, y, z, t, a) tmp = 0.0; end
code[x_, y_, z_, t_, a_] := 0.0
\begin{array}{l}
\\
0
\end{array}
Initial program 67.0%
+-commutative67.0%
associate-*l/81.7%
fma-def81.8%
Simplified81.8%
Taylor expanded in y around 0 42.3%
neg-mul-142.3%
distribute-neg-frac42.3%
Simplified42.3%
Taylor expanded in t around inf 2.6%
mul-1-neg2.6%
sub-neg2.6%
+-inverses2.6%
Simplified2.6%
Final simplification2.6%
(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 67.0%
associate-/l*83.9%
Simplified83.9%
Taylor expanded in a around inf 23.8%
Final simplification23.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 2023311
(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))))