
(FPCore (x y z t a) :precision binary64 (+ x (* y (/ (- z t) (- a t)))))
double code(double x, double y, double z, double t, double a) {
return x + (y * ((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 * ((z - t) / (a - t)))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + (y * ((z - t) / (a - t)));
}
def code(x, y, z, t, a): return x + (y * ((z - t) / (a - t)))
function code(x, y, z, t, a) return Float64(x + Float64(y * Float64(Float64(z - t) / Float64(a - t)))) end
function tmp = code(x, y, z, t, a) tmp = x + (y * ((z - t) / (a - t))); end
code[x_, y_, z_, t_, a_] := N[(x + N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + y \cdot \frac{z - t}{a - t}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 16 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a) :precision binary64 (+ x (* y (/ (- z t) (- a t)))))
double code(double x, double y, double z, double t, double a) {
return x + (y * ((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 * ((z - t) / (a - t)))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + (y * ((z - t) / (a - t)));
}
def code(x, y, z, t, a): return x + (y * ((z - t) / (a - t)))
function code(x, y, z, t, a) return Float64(x + Float64(y * Float64(Float64(z - t) / Float64(a - t)))) end
function tmp = code(x, y, z, t, a) tmp = x + (y * ((z - t) / (a - t))); end
code[x_, y_, z_, t_, a_] := N[(x + N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + y \cdot \frac{z - t}{a - t}
\end{array}
(FPCore (x y z t a) :precision binary64 (let* ((t_1 (/ (- z t) (- a t)))) (if (<= t_1 2e+119) (+ x (* y t_1)) (+ x (/ z (/ (- a t) y))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = (z - t) / (a - t);
double tmp;
if (t_1 <= 2e+119) {
tmp = x + (y * t_1);
} else {
tmp = x + (z / ((a - t) / 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 = (z - t) / (a - t)
if (t_1 <= 2d+119) then
tmp = x + (y * t_1)
else
tmp = x + (z / ((a - t) / y))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = (z - t) / (a - t);
double tmp;
if (t_1 <= 2e+119) {
tmp = x + (y * t_1);
} else {
tmp = x + (z / ((a - t) / y));
}
return tmp;
}
def code(x, y, z, t, a): t_1 = (z - t) / (a - t) tmp = 0 if t_1 <= 2e+119: tmp = x + (y * t_1) else: tmp = x + (z / ((a - t) / y)) return tmp
function code(x, y, z, t, a) t_1 = Float64(Float64(z - t) / Float64(a - t)) tmp = 0.0 if (t_1 <= 2e+119) tmp = Float64(x + Float64(y * t_1)); else tmp = Float64(x + Float64(z / Float64(Float64(a - t) / y))); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = (z - t) / (a - t); tmp = 0.0; if (t_1 <= 2e+119) tmp = x + (y * t_1); else tmp = x + (z / ((a - t) / y)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, 2e+119], N[(x + N[(y * t$95$1), $MachinePrecision]), $MachinePrecision], N[(x + N[(z / N[(N[(a - t), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{z - t}{a - t}\\
\mathbf{if}\;t\_1 \leq 2 \cdot 10^{+119}:\\
\;\;\;\;x + y \cdot t\_1\\
\mathbf{else}:\\
\;\;\;\;x + \frac{z}{\frac{a - t}{y}}\\
\end{array}
\end{array}
if (/.f64 (-.f64 z t) (-.f64 a t)) < 1.99999999999999989e119Initial program 97.8%
if 1.99999999999999989e119 < (/.f64 (-.f64 z t) (-.f64 a t)) Initial program 77.3%
Simplified0
Taylor expanded in z around inf 0
Simplified0
Applied egg-rr0
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* y (/ z a)))))
(if (<= t -1.05e-40)
(+ y x)
(if (<= t -1.2e-156)
t_1
(if (<= t -1.12e-219)
(* z (/ y (- a t)))
(if (<= t 4e+31) t_1 (+ y x)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (y * (z / a));
double tmp;
if (t <= -1.05e-40) {
tmp = y + x;
} else if (t <= -1.2e-156) {
tmp = t_1;
} else if (t <= -1.12e-219) {
tmp = z * (y / (a - t));
} else if (t <= 4e+31) {
tmp = t_1;
} else {
tmp = y + 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) :: t_1
real(8) :: tmp
t_1 = x + (y * (z / a))
if (t <= (-1.05d-40)) then
tmp = y + x
else if (t <= (-1.2d-156)) then
tmp = t_1
else if (t <= (-1.12d-219)) then
tmp = z * (y / (a - t))
else if (t <= 4d+31) then
tmp = t_1
else
tmp = y + x
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 * (z / a));
double tmp;
if (t <= -1.05e-40) {
tmp = y + x;
} else if (t <= -1.2e-156) {
tmp = t_1;
} else if (t <= -1.12e-219) {
tmp = z * (y / (a - t));
} else if (t <= 4e+31) {
tmp = t_1;
} else {
tmp = y + x;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + (y * (z / a)) tmp = 0 if t <= -1.05e-40: tmp = y + x elif t <= -1.2e-156: tmp = t_1 elif t <= -1.12e-219: tmp = z * (y / (a - t)) elif t <= 4e+31: tmp = t_1 else: tmp = y + x return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(y * Float64(z / a))) tmp = 0.0 if (t <= -1.05e-40) tmp = Float64(y + x); elseif (t <= -1.2e-156) tmp = t_1; elseif (t <= -1.12e-219) tmp = Float64(z * Float64(y / Float64(a - t))); elseif (t <= 4e+31) tmp = t_1; else tmp = Float64(y + x); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + (y * (z / a)); tmp = 0.0; if (t <= -1.05e-40) tmp = y + x; elseif (t <= -1.2e-156) tmp = t_1; elseif (t <= -1.12e-219) tmp = z * (y / (a - t)); elseif (t <= 4e+31) tmp = t_1; else tmp = y + x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(y * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1.05e-40], N[(y + x), $MachinePrecision], If[LessEqual[t, -1.2e-156], t$95$1, If[LessEqual[t, -1.12e-219], N[(z * N[(y / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 4e+31], t$95$1, N[(y + x), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + y \cdot \frac{z}{a}\\
\mathbf{if}\;t \leq -1.05 \cdot 10^{-40}:\\
\;\;\;\;y + x\\
\mathbf{elif}\;t \leq -1.2 \cdot 10^{-156}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq -1.12 \cdot 10^{-219}:\\
\;\;\;\;z \cdot \frac{y}{a - t}\\
\mathbf{elif}\;t \leq 4 \cdot 10^{+31}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;y + x\\
\end{array}
\end{array}
if t < -1.05000000000000009e-40 or 3.9999999999999999e31 < t Initial program 99.9%
Taylor expanded in t around inf 0
Simplified0
if -1.05000000000000009e-40 < t < -1.2e-156 or -1.12e-219 < t < 3.9999999999999999e31Initial program 93.6%
Taylor expanded in t around 0 0
Simplified0
if -1.2e-156 < t < -1.12e-219Initial program 76.1%
Applied egg-rr0
Taylor expanded in x around 0 0
Simplified0
Taylor expanded in z around inf 0
Simplified0
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* z (/ y (- a t)))))
(if (<= t -4.1e-135)
(+ y x)
(if (<= t -2.45e-290)
t_1
(if (<= t 1.66e-246) x (if (<= t 1.76e+45) t_1 (+ y x)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = z * (y / (a - t));
double tmp;
if (t <= -4.1e-135) {
tmp = y + x;
} else if (t <= -2.45e-290) {
tmp = t_1;
} else if (t <= 1.66e-246) {
tmp = x;
} else if (t <= 1.76e+45) {
tmp = t_1;
} else {
tmp = y + 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) :: t_1
real(8) :: tmp
t_1 = z * (y / (a - t))
if (t <= (-4.1d-135)) then
tmp = y + x
else if (t <= (-2.45d-290)) then
tmp = t_1
else if (t <= 1.66d-246) then
tmp = x
else if (t <= 1.76d+45) then
tmp = t_1
else
tmp = y + x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = z * (y / (a - t));
double tmp;
if (t <= -4.1e-135) {
tmp = y + x;
} else if (t <= -2.45e-290) {
tmp = t_1;
} else if (t <= 1.66e-246) {
tmp = x;
} else if (t <= 1.76e+45) {
tmp = t_1;
} else {
tmp = y + x;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = z * (y / (a - t)) tmp = 0 if t <= -4.1e-135: tmp = y + x elif t <= -2.45e-290: tmp = t_1 elif t <= 1.66e-246: tmp = x elif t <= 1.76e+45: tmp = t_1 else: tmp = y + x return tmp
function code(x, y, z, t, a) t_1 = Float64(z * Float64(y / Float64(a - t))) tmp = 0.0 if (t <= -4.1e-135) tmp = Float64(y + x); elseif (t <= -2.45e-290) tmp = t_1; elseif (t <= 1.66e-246) tmp = x; elseif (t <= 1.76e+45) tmp = t_1; else tmp = Float64(y + x); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = z * (y / (a - t)); tmp = 0.0; if (t <= -4.1e-135) tmp = y + x; elseif (t <= -2.45e-290) tmp = t_1; elseif (t <= 1.66e-246) tmp = x; elseif (t <= 1.76e+45) tmp = t_1; else tmp = y + x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(z * N[(y / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -4.1e-135], N[(y + x), $MachinePrecision], If[LessEqual[t, -2.45e-290], t$95$1, If[LessEqual[t, 1.66e-246], x, If[LessEqual[t, 1.76e+45], t$95$1, N[(y + x), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := z \cdot \frac{y}{a - t}\\
\mathbf{if}\;t \leq -4.1 \cdot 10^{-135}:\\
\;\;\;\;y + x\\
\mathbf{elif}\;t \leq -2.45 \cdot 10^{-290}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 1.66 \cdot 10^{-246}:\\
\;\;\;\;x\\
\mathbf{elif}\;t \leq 1.76 \cdot 10^{+45}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;y + x\\
\end{array}
\end{array}
if t < -4.1000000000000001e-135 or 1.75999999999999997e45 < t Initial program 98.6%
Taylor expanded in t around inf 0
Simplified0
if -4.1000000000000001e-135 < t < -2.45e-290 or 1.6599999999999999e-246 < t < 1.75999999999999997e45Initial program 90.2%
Applied egg-rr0
Taylor expanded in x around 0 0
Simplified0
Taylor expanded in z around inf 0
Simplified0
if -2.45e-290 < t < 1.6599999999999999e-246Initial program 99.9%
Taylor expanded in x around inf 0
Simplified0
(FPCore (x y z t a)
:precision binary64
(if (<= t -2.1e-41)
(+ y x)
(if (<= t 5e-98)
(+ (/ (* y z) a) x)
(if (<= t 1.45e+69) (- x (/ (* y z) t)) (+ y x)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -2.1e-41) {
tmp = y + x;
} else if (t <= 5e-98) {
tmp = ((y * z) / a) + x;
} else if (t <= 1.45e+69) {
tmp = x - ((y * z) / t);
} else {
tmp = y + 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 (t <= (-2.1d-41)) then
tmp = y + x
else if (t <= 5d-98) then
tmp = ((y * z) / a) + x
else if (t <= 1.45d+69) then
tmp = x - ((y * z) / t)
else
tmp = y + x
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.1e-41) {
tmp = y + x;
} else if (t <= 5e-98) {
tmp = ((y * z) / a) + x;
} else if (t <= 1.45e+69) {
tmp = x - ((y * z) / t);
} else {
tmp = y + x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -2.1e-41: tmp = y + x elif t <= 5e-98: tmp = ((y * z) / a) + x elif t <= 1.45e+69: tmp = x - ((y * z) / t) else: tmp = y + x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -2.1e-41) tmp = Float64(y + x); elseif (t <= 5e-98) tmp = Float64(Float64(Float64(y * z) / a) + x); elseif (t <= 1.45e+69) tmp = Float64(x - Float64(Float64(y * z) / t)); else tmp = Float64(y + x); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -2.1e-41) tmp = y + x; elseif (t <= 5e-98) tmp = ((y * z) / a) + x; elseif (t <= 1.45e+69) tmp = x - ((y * z) / t); else tmp = y + x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -2.1e-41], N[(y + x), $MachinePrecision], If[LessEqual[t, 5e-98], N[(N[(N[(y * z), $MachinePrecision] / a), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[t, 1.45e+69], N[(x - N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], N[(y + x), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.1 \cdot 10^{-41}:\\
\;\;\;\;y + x\\
\mathbf{elif}\;t \leq 5 \cdot 10^{-98}:\\
\;\;\;\;\frac{y \cdot z}{a} + x\\
\mathbf{elif}\;t \leq 1.45 \cdot 10^{+69}:\\
\;\;\;\;x - \frac{y \cdot z}{t}\\
\mathbf{else}:\\
\;\;\;\;y + x\\
\end{array}
\end{array}
if t < -2.10000000000000013e-41 or 1.4499999999999999e69 < t Initial program 99.9%
Taylor expanded in t around inf 0
Simplified0
if -2.10000000000000013e-41 < t < 5.00000000000000018e-98Initial program 92.2%
Taylor expanded in t around 0 0
Simplified0
if 5.00000000000000018e-98 < t < 1.4499999999999999e69Initial program 90.5%
Simplified0
Taylor expanded in z around inf 0
Simplified0
Taylor expanded in a around 0 0
Simplified0
(FPCore (x y z t a)
:precision binary64
(if (<= t -9.2e-41)
(+ y x)
(if (<= t 4e-98)
(+ (/ (* y z) a) x)
(if (<= t 1.1e+55) (- x (* z (/ y t))) (+ y x)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -9.2e-41) {
tmp = y + x;
} else if (t <= 4e-98) {
tmp = ((y * z) / a) + x;
} else if (t <= 1.1e+55) {
tmp = x - (z * (y / t));
} else {
tmp = y + 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 (t <= (-9.2d-41)) then
tmp = y + x
else if (t <= 4d-98) then
tmp = ((y * z) / a) + x
else if (t <= 1.1d+55) then
tmp = x - (z * (y / t))
else
tmp = y + x
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-41) {
tmp = y + x;
} else if (t <= 4e-98) {
tmp = ((y * z) / a) + x;
} else if (t <= 1.1e+55) {
tmp = x - (z * (y / t));
} else {
tmp = y + x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -9.2e-41: tmp = y + x elif t <= 4e-98: tmp = ((y * z) / a) + x elif t <= 1.1e+55: tmp = x - (z * (y / t)) else: tmp = y + x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -9.2e-41) tmp = Float64(y + x); elseif (t <= 4e-98) tmp = Float64(Float64(Float64(y * z) / a) + x); elseif (t <= 1.1e+55) tmp = Float64(x - Float64(z * Float64(y / t))); else tmp = Float64(y + x); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -9.2e-41) tmp = y + x; elseif (t <= 4e-98) tmp = ((y * z) / a) + x; elseif (t <= 1.1e+55) tmp = x - (z * (y / t)); else tmp = y + x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -9.2e-41], N[(y + x), $MachinePrecision], If[LessEqual[t, 4e-98], N[(N[(N[(y * z), $MachinePrecision] / a), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[t, 1.1e+55], N[(x - N[(z * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y + x), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -9.2 \cdot 10^{-41}:\\
\;\;\;\;y + x\\
\mathbf{elif}\;t \leq 4 \cdot 10^{-98}:\\
\;\;\;\;\frac{y \cdot z}{a} + x\\
\mathbf{elif}\;t \leq 1.1 \cdot 10^{+55}:\\
\;\;\;\;x - z \cdot \frac{y}{t}\\
\mathbf{else}:\\
\;\;\;\;y + x\\
\end{array}
\end{array}
if t < -9.20000000000000041e-41 or 1.10000000000000005e55 < t Initial program 99.9%
Taylor expanded in t around inf 0
Simplified0
if -9.20000000000000041e-41 < t < 3.99999999999999976e-98Initial program 92.2%
Taylor expanded in t around 0 0
Simplified0
if 3.99999999999999976e-98 < t < 1.10000000000000005e55Initial program 89.2%
Simplified0
Taylor expanded in z around inf 0
Simplified0
Taylor expanded in a around 0 0
Simplified0
Applied egg-rr0
(FPCore (x y z t a) :precision binary64 (if (<= t -5.5e-82) (+ y x) (if (<= t 8.5e-247) x (if (<= t 8e-15) (/ (* y z) a) (+ y x)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -5.5e-82) {
tmp = y + x;
} else if (t <= 8.5e-247) {
tmp = x;
} else if (t <= 8e-15) {
tmp = (y * z) / a;
} else {
tmp = y + 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 (t <= (-5.5d-82)) then
tmp = y + x
else if (t <= 8.5d-247) then
tmp = x
else if (t <= 8d-15) then
tmp = (y * z) / a
else
tmp = y + x
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.5e-82) {
tmp = y + x;
} else if (t <= 8.5e-247) {
tmp = x;
} else if (t <= 8e-15) {
tmp = (y * z) / a;
} else {
tmp = y + x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -5.5e-82: tmp = y + x elif t <= 8.5e-247: tmp = x elif t <= 8e-15: tmp = (y * z) / a else: tmp = y + x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -5.5e-82) tmp = Float64(y + x); elseif (t <= 8.5e-247) tmp = x; elseif (t <= 8e-15) tmp = Float64(Float64(y * z) / a); else tmp = Float64(y + x); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -5.5e-82) tmp = y + x; elseif (t <= 8.5e-247) tmp = x; elseif (t <= 8e-15) tmp = (y * z) / a; else tmp = y + x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -5.5e-82], N[(y + x), $MachinePrecision], If[LessEqual[t, 8.5e-247], x, If[LessEqual[t, 8e-15], N[(N[(y * z), $MachinePrecision] / a), $MachinePrecision], N[(y + x), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -5.5 \cdot 10^{-82}:\\
\;\;\;\;y + x\\
\mathbf{elif}\;t \leq 8.5 \cdot 10^{-247}:\\
\;\;\;\;x\\
\mathbf{elif}\;t \leq 8 \cdot 10^{-15}:\\
\;\;\;\;\frac{y \cdot z}{a}\\
\mathbf{else}:\\
\;\;\;\;y + x\\
\end{array}
\end{array}
if t < -5.4999999999999998e-82 or 8.0000000000000006e-15 < t Initial program 98.6%
Taylor expanded in t around inf 0
Simplified0
if -5.4999999999999998e-82 < t < 8.5000000000000003e-247Initial program 92.0%
Taylor expanded in x around inf 0
Simplified0
if 8.5000000000000003e-247 < t < 8.0000000000000006e-15Initial program 90.9%
Taylor expanded in t around 0 0
Simplified0
Taylor expanded in y around inf 0
Simplified0
(FPCore (x y z t a) :precision binary64 (if (<= t -5.8e-58) (+ (* y (- 1.0 (/ z t))) x) (if (<= t 4.8e+50) (+ x (* z (/ y (- a t)))) (- x (* (- z t) (/ y t))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -5.8e-58) {
tmp = (y * (1.0 - (z / t))) + x;
} else if (t <= 4.8e+50) {
tmp = x + (z * (y / (a - t)));
} else {
tmp = x - ((z - t) * (y / t));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (t <= (-5.8d-58)) then
tmp = (y * (1.0d0 - (z / t))) + x
else if (t <= 4.8d+50) then
tmp = x + (z * (y / (a - t)))
else
tmp = x - ((z - t) * (y / t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -5.8e-58) {
tmp = (y * (1.0 - (z / t))) + x;
} else if (t <= 4.8e+50) {
tmp = x + (z * (y / (a - t)));
} else {
tmp = x - ((z - t) * (y / t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -5.8e-58: tmp = (y * (1.0 - (z / t))) + x elif t <= 4.8e+50: tmp = x + (z * (y / (a - t))) else: tmp = x - ((z - t) * (y / t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -5.8e-58) tmp = Float64(Float64(y * Float64(1.0 - Float64(z / t))) + x); elseif (t <= 4.8e+50) tmp = Float64(x + Float64(z * Float64(y / Float64(a - t)))); else tmp = Float64(x - Float64(Float64(z - t) * Float64(y / t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -5.8e-58) tmp = (y * (1.0 - (z / t))) + x; elseif (t <= 4.8e+50) tmp = x + (z * (y / (a - t))); else tmp = x - ((z - t) * (y / t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -5.8e-58], N[(N[(y * N[(1.0 - N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[t, 4.8e+50], N[(x + N[(z * N[(y / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x - N[(N[(z - t), $MachinePrecision] * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -5.8 \cdot 10^{-58}:\\
\;\;\;\;y \cdot \left(1 - \frac{z}{t}\right) + x\\
\mathbf{elif}\;t \leq 4.8 \cdot 10^{+50}:\\
\;\;\;\;x + z \cdot \frac{y}{a - t}\\
\mathbf{else}:\\
\;\;\;\;x - \left(z - t\right) \cdot \frac{y}{t}\\
\end{array}
\end{array}
if t < -5.7999999999999998e-58Initial program 99.9%
Taylor expanded in a around 0 0
Simplified0
if -5.7999999999999998e-58 < t < 4.8000000000000004e50Initial program 91.4%
Simplified0
Taylor expanded in z around inf 0
Simplified0
if 4.8000000000000004e50 < t Initial program 99.9%
Applied egg-rr0
Taylor expanded in a around 0 0
Simplified0
(FPCore (x y z t a) :precision binary64 (let* ((t_1 (+ (* y (- 1.0 (/ z t))) x))) (if (<= t -5.4e-58) t_1 (if (<= t 6.4e+46) (+ x (* z (/ y (- a t)))) t_1))))
double code(double x, double y, double z, double t, double a) {
double t_1 = (y * (1.0 - (z / t))) + x;
double tmp;
if (t <= -5.4e-58) {
tmp = t_1;
} else if (t <= 6.4e+46) {
tmp = x + (z * (y / (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 * (1.0d0 - (z / t))) + x
if (t <= (-5.4d-58)) then
tmp = t_1
else if (t <= 6.4d+46) then
tmp = x + (z * (y / (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 * (1.0 - (z / t))) + x;
double tmp;
if (t <= -5.4e-58) {
tmp = t_1;
} else if (t <= 6.4e+46) {
tmp = x + (z * (y / (a - t)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = (y * (1.0 - (z / t))) + x tmp = 0 if t <= -5.4e-58: tmp = t_1 elif t <= 6.4e+46: tmp = x + (z * (y / (a - t))) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(Float64(y * Float64(1.0 - Float64(z / t))) + x) tmp = 0.0 if (t <= -5.4e-58) tmp = t_1; elseif (t <= 6.4e+46) tmp = Float64(x + Float64(z * Float64(y / Float64(a - t)))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = (y * (1.0 - (z / t))) + x; tmp = 0.0; if (t <= -5.4e-58) tmp = t_1; elseif (t <= 6.4e+46) tmp = x + (z * (y / (a - t))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(y * N[(1.0 - N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision]}, If[LessEqual[t, -5.4e-58], t$95$1, If[LessEqual[t, 6.4e+46], N[(x + N[(z * N[(y / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \left(1 - \frac{z}{t}\right) + x\\
\mathbf{if}\;t \leq -5.4 \cdot 10^{-58}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 6.4 \cdot 10^{+46}:\\
\;\;\;\;x + z \cdot \frac{y}{a - t}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if t < -5.3999999999999998e-58 or 6.3999999999999996e46 < t Initial program 99.9%
Taylor expanded in a around 0 0
Simplified0
if -5.3999999999999998e-58 < t < 6.3999999999999996e46Initial program 91.4%
Simplified0
Taylor expanded in z around inf 0
Simplified0
(FPCore (x y z t a) :precision binary64 (if (<= t -3.5e+99) (+ y x) (if (<= t 3.2e+53) (+ x (* z (/ y (- a t)))) (+ y x))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -3.5e+99) {
tmp = y + x;
} else if (t <= 3.2e+53) {
tmp = x + (z * (y / (a - t)));
} else {
tmp = y + 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 (t <= (-3.5d+99)) then
tmp = y + x
else if (t <= 3.2d+53) then
tmp = x + (z * (y / (a - t)))
else
tmp = y + x
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.5e+99) {
tmp = y + x;
} else if (t <= 3.2e+53) {
tmp = x + (z * (y / (a - t)));
} else {
tmp = y + x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -3.5e+99: tmp = y + x elif t <= 3.2e+53: tmp = x + (z * (y / (a - t))) else: tmp = y + x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -3.5e+99) tmp = Float64(y + x); elseif (t <= 3.2e+53) tmp = Float64(x + Float64(z * Float64(y / Float64(a - t)))); else tmp = Float64(y + x); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -3.5e+99) tmp = y + x; elseif (t <= 3.2e+53) tmp = x + (z * (y / (a - t))); else tmp = y + x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -3.5e+99], N[(y + x), $MachinePrecision], If[LessEqual[t, 3.2e+53], N[(x + N[(z * N[(y / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y + x), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.5 \cdot 10^{+99}:\\
\;\;\;\;y + x\\
\mathbf{elif}\;t \leq 3.2 \cdot 10^{+53}:\\
\;\;\;\;x + z \cdot \frac{y}{a - t}\\
\mathbf{else}:\\
\;\;\;\;y + x\\
\end{array}
\end{array}
if t < -3.4999999999999998e99 or 3.2e53 < t Initial program 99.9%
Taylor expanded in t around inf 0
Simplified0
if -3.4999999999999998e99 < t < 3.2e53Initial program 92.8%
Simplified0
Taylor expanded in z around inf 0
Simplified0
(FPCore (x y z t a) :precision binary64 (if (<= t -6e-42) (+ y x) (if (<= t 1.6e+35) (+ (/ (* y z) a) x) (+ y x))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -6e-42) {
tmp = y + x;
} else if (t <= 1.6e+35) {
tmp = ((y * z) / a) + x;
} else {
tmp = y + 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 (t <= (-6d-42)) then
tmp = y + x
else if (t <= 1.6d+35) then
tmp = ((y * z) / a) + x
else
tmp = y + x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -6e-42) {
tmp = y + x;
} else if (t <= 1.6e+35) {
tmp = ((y * z) / a) + x;
} else {
tmp = y + x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -6e-42: tmp = y + x elif t <= 1.6e+35: tmp = ((y * z) / a) + x else: tmp = y + x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -6e-42) tmp = Float64(y + x); elseif (t <= 1.6e+35) tmp = Float64(Float64(Float64(y * z) / a) + x); else tmp = Float64(y + x); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -6e-42) tmp = y + x; elseif (t <= 1.6e+35) tmp = ((y * z) / a) + x; else tmp = y + x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -6e-42], N[(y + x), $MachinePrecision], If[LessEqual[t, 1.6e+35], N[(N[(N[(y * z), $MachinePrecision] / a), $MachinePrecision] + x), $MachinePrecision], N[(y + x), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -6 \cdot 10^{-42}:\\
\;\;\;\;y + x\\
\mathbf{elif}\;t \leq 1.6 \cdot 10^{+35}:\\
\;\;\;\;\frac{y \cdot z}{a} + x\\
\mathbf{else}:\\
\;\;\;\;y + x\\
\end{array}
\end{array}
if t < -6.00000000000000054e-42 or 1.59999999999999991e35 < t Initial program 99.9%
Taylor expanded in t around inf 0
Simplified0
if -6.00000000000000054e-42 < t < 1.59999999999999991e35Initial program 91.6%
Taylor expanded in t around 0 0
Simplified0
(FPCore (x y z t a) :precision binary64 (if (<= t -9.2e-41) (+ y x) (if (<= t 2.8e+31) (+ x (/ z (/ a y))) (+ y x))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -9.2e-41) {
tmp = y + x;
} else if (t <= 2.8e+31) {
tmp = x + (z / (a / y));
} else {
tmp = y + 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 (t <= (-9.2d-41)) then
tmp = y + x
else if (t <= 2.8d+31) then
tmp = x + (z / (a / y))
else
tmp = y + x
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-41) {
tmp = y + x;
} else if (t <= 2.8e+31) {
tmp = x + (z / (a / y));
} else {
tmp = y + x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -9.2e-41: tmp = y + x elif t <= 2.8e+31: tmp = x + (z / (a / y)) else: tmp = y + x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -9.2e-41) tmp = Float64(y + x); elseif (t <= 2.8e+31) tmp = Float64(x + Float64(z / Float64(a / y))); else tmp = Float64(y + x); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -9.2e-41) tmp = y + x; elseif (t <= 2.8e+31) tmp = x + (z / (a / y)); else tmp = y + x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -9.2e-41], N[(y + x), $MachinePrecision], If[LessEqual[t, 2.8e+31], N[(x + N[(z / N[(a / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y + x), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -9.2 \cdot 10^{-41}:\\
\;\;\;\;y + x\\
\mathbf{elif}\;t \leq 2.8 \cdot 10^{+31}:\\
\;\;\;\;x + \frac{z}{\frac{a}{y}}\\
\mathbf{else}:\\
\;\;\;\;y + x\\
\end{array}
\end{array}
if t < -9.20000000000000041e-41 or 2.80000000000000017e31 < t Initial program 99.9%
Taylor expanded in t around inf 0
Simplified0
if -9.20000000000000041e-41 < t < 2.80000000000000017e31Initial program 91.6%
Simplified0
Taylor expanded in z around inf 0
Simplified0
Applied egg-rr0
Taylor expanded in a around inf 0
Simplified0
(FPCore (x y z t a) :precision binary64 (if (<= a -3.3e+137) x (if (<= a 5.2e+155) (+ y x) x)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -3.3e+137) {
tmp = x;
} else if (a <= 5.2e+155) {
tmp = y + x;
} 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 <= (-3.3d+137)) then
tmp = x
else if (a <= 5.2d+155) then
tmp = y + x
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 <= -3.3e+137) {
tmp = x;
} else if (a <= 5.2e+155) {
tmp = y + x;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -3.3e+137: tmp = x elif a <= 5.2e+155: tmp = y + x else: tmp = x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -3.3e+137) tmp = x; elseif (a <= 5.2e+155) tmp = Float64(y + x); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -3.3e+137) tmp = x; elseif (a <= 5.2e+155) tmp = y + x; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -3.3e+137], x, If[LessEqual[a, 5.2e+155], N[(y + x), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -3.3 \cdot 10^{+137}:\\
\;\;\;\;x\\
\mathbf{elif}\;a \leq 5.2 \cdot 10^{+155}:\\
\;\;\;\;y + x\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if a < -3.30000000000000003e137 or 5.2000000000000004e155 < a Initial program 97.2%
Taylor expanded in x around inf 0
Simplified0
if -3.30000000000000003e137 < a < 5.2000000000000004e155Initial program 94.9%
Taylor expanded in t around inf 0
Simplified0
(FPCore (x y z t a) :precision binary64 (if (<= y -1.2e+63) y (if (<= y 2.3e+183) x y)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (y <= -1.2e+63) {
tmp = y;
} else if (y <= 2.3e+183) {
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 (y <= (-1.2d+63)) then
tmp = y
else if (y <= 2.3d+183) 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 (y <= -1.2e+63) {
tmp = y;
} else if (y <= 2.3e+183) {
tmp = x;
} else {
tmp = y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if y <= -1.2e+63: tmp = y elif y <= 2.3e+183: tmp = x else: tmp = y return tmp
function code(x, y, z, t, a) tmp = 0.0 if (y <= -1.2e+63) tmp = y; elseif (y <= 2.3e+183) tmp = x; else tmp = y; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (y <= -1.2e+63) tmp = y; elseif (y <= 2.3e+183) tmp = x; else tmp = y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[y, -1.2e+63], y, If[LessEqual[y, 2.3e+183], x, y]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.2 \cdot 10^{+63}:\\
\;\;\;\;y\\
\mathbf{elif}\;y \leq 2.3 \cdot 10^{+183}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;y\\
\end{array}
\end{array}
if y < -1.2e63 or 2.2999999999999998e183 < y Initial program 97.7%
Taylor expanded in t around inf 0
Simplified0
Taylor expanded in y around inf 0
Simplified0
if -1.2e63 < y < 2.2999999999999998e183Initial program 94.4%
Taylor expanded in x around inf 0
Simplified0
(FPCore (x y z t a) :precision binary64 (if (<= z 4.1e+144) (+ y x) (/ (* z (- y)) t)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= 4.1e+144) {
tmp = y + x;
} else {
tmp = (z * -y) / t;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (z <= 4.1d+144) then
tmp = y + x
else
tmp = (z * -y) / t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= 4.1e+144) {
tmp = y + x;
} else {
tmp = (z * -y) / t;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= 4.1e+144: tmp = y + x else: tmp = (z * -y) / t return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= 4.1e+144) tmp = Float64(y + x); else tmp = Float64(Float64(z * Float64(-y)) / t); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= 4.1e+144) tmp = y + x; else tmp = (z * -y) / t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, 4.1e+144], N[(y + x), $MachinePrecision], N[(N[(z * (-y)), $MachinePrecision] / t), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq 4.1 \cdot 10^{+144}:\\
\;\;\;\;y + x\\
\mathbf{else}:\\
\;\;\;\;\frac{z \cdot \left(-y\right)}{t}\\
\end{array}
\end{array}
if z < 4.10000000000000001e144Initial program 96.6%
Taylor expanded in t around inf 0
Simplified0
if 4.10000000000000001e144 < z Initial program 87.4%
Taylor expanded in t around inf 0
Simplified0
Taylor expanded in t around 0 0
Simplified0
Taylor expanded in a around 0 0
Simplified0
(FPCore (x y z t a) :precision binary64 (if (<= z 3.2e+144) (+ y x) (- (/ z (/ t y)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= 3.2e+144) {
tmp = y + x;
} else {
tmp = -(z / (t / y));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (z <= 3.2d+144) then
tmp = y + x
else
tmp = -(z / (t / y))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= 3.2e+144) {
tmp = y + x;
} else {
tmp = -(z / (t / y));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= 3.2e+144: tmp = y + x else: tmp = -(z / (t / y)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= 3.2e+144) tmp = Float64(y + x); else tmp = Float64(-Float64(z / Float64(t / y))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= 3.2e+144) tmp = y + x; else tmp = -(z / (t / y)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, 3.2e+144], N[(y + x), $MachinePrecision], (-N[(z / N[(t / y), $MachinePrecision]), $MachinePrecision])]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq 3.2 \cdot 10^{+144}:\\
\;\;\;\;y + x\\
\mathbf{else}:\\
\;\;\;\;-\frac{z}{\frac{t}{y}}\\
\end{array}
\end{array}
if z < 3.2000000000000001e144Initial program 96.6%
Taylor expanded in t around inf 0
Simplified0
if 3.2000000000000001e144 < z Initial program 87.4%
Taylor expanded in t around inf 0
Simplified0
Taylor expanded in t around 0 0
Simplified0
Taylor expanded in a around 0 0
Simplified0
Applied egg-rr0
(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 95.5%
Taylor expanded in x around inf 0
Simplified0
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* y (/ (- z t) (- a t))))))
(if (< y -8.508084860551241e-17)
t_1
(if (< y 2.894426862792089e-49)
(+ x (* (* y (- z t)) (/ 1.0 (- a t))))
t_1))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (y * ((z - t) / (a - t)));
double tmp;
if (y < -8.508084860551241e-17) {
tmp = t_1;
} else if (y < 2.894426862792089e-49) {
tmp = x + ((y * (z - t)) * (1.0 / (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 = x + (y * ((z - t) / (a - t)))
if (y < (-8.508084860551241d-17)) then
tmp = t_1
else if (y < 2.894426862792089d-49) then
tmp = x + ((y * (z - t)) * (1.0d0 / (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 = x + (y * ((z - t) / (a - t)));
double tmp;
if (y < -8.508084860551241e-17) {
tmp = t_1;
} else if (y < 2.894426862792089e-49) {
tmp = x + ((y * (z - t)) * (1.0 / (a - t)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + (y * ((z - t) / (a - t))) tmp = 0 if y < -8.508084860551241e-17: tmp = t_1 elif y < 2.894426862792089e-49: tmp = x + ((y * (z - t)) * (1.0 / (a - t))) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(y * Float64(Float64(z - t) / Float64(a - t)))) tmp = 0.0 if (y < -8.508084860551241e-17) tmp = t_1; elseif (y < 2.894426862792089e-49) tmp = Float64(x + Float64(Float64(y * Float64(z - t)) * Float64(1.0 / Float64(a - t)))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + (y * ((z - t) / (a - t))); tmp = 0.0; if (y < -8.508084860551241e-17) tmp = t_1; elseif (y < 2.894426862792089e-49) tmp = x + ((y * (z - t)) * (1.0 / (a - t))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Less[y, -8.508084860551241e-17], t$95$1, If[Less[y, 2.894426862792089e-49], N[(x + N[(N[(y * N[(z - t), $MachinePrecision]), $MachinePrecision] * N[(1.0 / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + y \cdot \frac{z - t}{a - t}\\
\mathbf{if}\;y < -8.508084860551241 \cdot 10^{-17}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y < 2.894426862792089 \cdot 10^{-49}:\\
\;\;\;\;x + \left(y \cdot \left(z - t\right)\right) \cdot \frac{1}{a - t}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
herbie shell --seed 2024110
(FPCore (x y z t a)
:name "Graphics.Rendering.Plot.Render.Plot.Axis:renderAxisLine from plot-0.2.3.4, B"
:precision binary64
:alt
(if (< y -8.508084860551241e-17) (+ x (* y (/ (- z t) (- a t)))) (if (< y 2.894426862792089e-49) (+ x (* (* y (- z t)) (/ 1.0 (- a t)))) (+ x (* y (/ (- z t) (- a t))))))
(+ x (* y (/ (- z t) (- a t)))))