
(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(Float64(y * 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[(N[(y * N[(z - t), $MachinePrecision]), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \frac{y \cdot \left(z - t\right)}{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(Float64(y * 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[(N[(y * N[(z - t), $MachinePrecision]), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \frac{y \cdot \left(z - t\right)}{a - t}
\end{array}
(FPCore (x y z t a) :precision binary64 (+ x (/ y (/ (- a t) (- z t)))))
double code(double x, double y, double z, double t, double a) {
return x + (y / ((a - t) / (z - 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 / ((a - t) / (z - t)))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + (y / ((a - t) / (z - t)));
}
def code(x, y, z, t, a): return x + (y / ((a - t) / (z - t)))
function code(x, y, z, t, a) return Float64(x + Float64(y / Float64(Float64(a - t) / Float64(z - t)))) end
function tmp = code(x, y, z, t, a) tmp = x + (y / ((a - t) / (z - t))); end
code[x_, y_, z_, t_, a_] := N[(x + N[(y / N[(N[(a - t), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \frac{y}{\frac{a - t}{z - t}}
\end{array}
Initial program 86.7%
associate-/l*N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
--lowering--.f6499.1%
Applied egg-rr99.1%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* y (/ z (- a t)))))
(if (<= t -1.05e-21)
(+ x y)
(if (<= t 3.3e-195)
t_1
(if (<= t 2.8e-153) x (if (<= t 3.2e-71) t_1 (+ x y)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = y * (z / (a - t));
double tmp;
if (t <= -1.05e-21) {
tmp = x + y;
} else if (t <= 3.3e-195) {
tmp = t_1;
} else if (t <= 2.8e-153) {
tmp = x;
} else if (t <= 3.2e-71) {
tmp = t_1;
} else {
tmp = x + y;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = y * (z / (a - t))
if (t <= (-1.05d-21)) then
tmp = x + y
else if (t <= 3.3d-195) then
tmp = t_1
else if (t <= 2.8d-153) then
tmp = x
else if (t <= 3.2d-71) then
tmp = t_1
else
tmp = x + y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = y * (z / (a - t));
double tmp;
if (t <= -1.05e-21) {
tmp = x + y;
} else if (t <= 3.3e-195) {
tmp = t_1;
} else if (t <= 2.8e-153) {
tmp = x;
} else if (t <= 3.2e-71) {
tmp = t_1;
} else {
tmp = x + y;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = y * (z / (a - t)) tmp = 0 if t <= -1.05e-21: tmp = x + y elif t <= 3.3e-195: tmp = t_1 elif t <= 2.8e-153: tmp = x elif t <= 3.2e-71: tmp = t_1 else: tmp = x + y return tmp
function code(x, y, z, t, a) t_1 = Float64(y * Float64(z / Float64(a - t))) tmp = 0.0 if (t <= -1.05e-21) tmp = Float64(x + y); elseif (t <= 3.3e-195) tmp = t_1; elseif (t <= 2.8e-153) tmp = x; elseif (t <= 3.2e-71) tmp = t_1; else tmp = Float64(x + y); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = y * (z / (a - t)); tmp = 0.0; if (t <= -1.05e-21) tmp = x + y; elseif (t <= 3.3e-195) tmp = t_1; elseif (t <= 2.8e-153) tmp = x; elseif (t <= 3.2e-71) tmp = t_1; else tmp = x + y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y * N[(z / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1.05e-21], N[(x + y), $MachinePrecision], If[LessEqual[t, 3.3e-195], t$95$1, If[LessEqual[t, 2.8e-153], x, If[LessEqual[t, 3.2e-71], t$95$1, N[(x + y), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \frac{z}{a - t}\\
\mathbf{if}\;t \leq -1.05 \cdot 10^{-21}:\\
\;\;\;\;x + y\\
\mathbf{elif}\;t \leq 3.3 \cdot 10^{-195}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 2.8 \cdot 10^{-153}:\\
\;\;\;\;x\\
\mathbf{elif}\;t \leq 3.2 \cdot 10^{-71}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;x + y\\
\end{array}
\end{array}
if t < -1.05000000000000006e-21 or 3.1999999999999999e-71 < t Initial program 80.5%
Taylor expanded in t around inf
+-commutativeN/A
+-lowering-+.f6474.6%
Simplified74.6%
if -1.05000000000000006e-21 < t < 3.3e-195 or 2.8000000000000001e-153 < t < 3.1999999999999999e-71Initial program 93.4%
Taylor expanded in z around inf
associate-/l*N/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f6461.5%
Simplified61.5%
if 3.3e-195 < t < 2.8000000000000001e-153Initial program 99.9%
Taylor expanded in x around inf
Simplified85.1%
Final simplification69.8%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* y (/ z a))))
(if (<= t -2.5e-101)
(+ x y)
(if (<= t 4.8e-196)
t_1
(if (<= t 2.05e-120) x (if (<= t 3.2e-73) t_1 (+ x y)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = y * (z / a);
double tmp;
if (t <= -2.5e-101) {
tmp = x + y;
} else if (t <= 4.8e-196) {
tmp = t_1;
} else if (t <= 2.05e-120) {
tmp = x;
} else if (t <= 3.2e-73) {
tmp = t_1;
} else {
tmp = x + y;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = y * (z / a)
if (t <= (-2.5d-101)) then
tmp = x + y
else if (t <= 4.8d-196) then
tmp = t_1
else if (t <= 2.05d-120) then
tmp = x
else if (t <= 3.2d-73) then
tmp = t_1
else
tmp = x + y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = y * (z / a);
double tmp;
if (t <= -2.5e-101) {
tmp = x + y;
} else if (t <= 4.8e-196) {
tmp = t_1;
} else if (t <= 2.05e-120) {
tmp = x;
} else if (t <= 3.2e-73) {
tmp = t_1;
} else {
tmp = x + y;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = y * (z / a) tmp = 0 if t <= -2.5e-101: tmp = x + y elif t <= 4.8e-196: tmp = t_1 elif t <= 2.05e-120: tmp = x elif t <= 3.2e-73: tmp = t_1 else: tmp = x + y return tmp
function code(x, y, z, t, a) t_1 = Float64(y * Float64(z / a)) tmp = 0.0 if (t <= -2.5e-101) tmp = Float64(x + y); elseif (t <= 4.8e-196) tmp = t_1; elseif (t <= 2.05e-120) tmp = x; elseif (t <= 3.2e-73) tmp = t_1; else tmp = Float64(x + y); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = y * (z / a); tmp = 0.0; if (t <= -2.5e-101) tmp = x + y; elseif (t <= 4.8e-196) tmp = t_1; elseif (t <= 2.05e-120) tmp = x; elseif (t <= 3.2e-73) tmp = t_1; else tmp = x + y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y * N[(z / a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -2.5e-101], N[(x + y), $MachinePrecision], If[LessEqual[t, 4.8e-196], t$95$1, If[LessEqual[t, 2.05e-120], x, If[LessEqual[t, 3.2e-73], t$95$1, N[(x + y), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \frac{z}{a}\\
\mathbf{if}\;t \leq -2.5 \cdot 10^{-101}:\\
\;\;\;\;x + y\\
\mathbf{elif}\;t \leq 4.8 \cdot 10^{-196}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 2.05 \cdot 10^{-120}:\\
\;\;\;\;x\\
\mathbf{elif}\;t \leq 3.2 \cdot 10^{-73}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;x + y\\
\end{array}
\end{array}
if t < -2.5e-101 or 3.19999999999999986e-73 < t Initial program 81.8%
Taylor expanded in t around inf
+-commutativeN/A
+-lowering-+.f6470.9%
Simplified70.9%
if -2.5e-101 < t < 4.80000000000000041e-196 or 2.05000000000000017e-120 < t < 3.19999999999999986e-73Initial program 92.9%
Taylor expanded in z around inf
associate-/l*N/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f6463.4%
Simplified63.4%
Taylor expanded in a around inf
Simplified55.5%
if 4.80000000000000041e-196 < t < 2.05000000000000017e-120Initial program 99.8%
Taylor expanded in x around inf
Simplified66.1%
Final simplification65.6%
(FPCore (x y z t a) :precision binary64 (if (<= z -1.7e+202) (* z (/ y a)) (if (<= z 1060000000.0) (+ x y) (if (<= z 3.4e+102) x (/ y (/ a z))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.7e+202) {
tmp = z * (y / a);
} else if (z <= 1060000000.0) {
tmp = x + y;
} else if (z <= 3.4e+102) {
tmp = x;
} else {
tmp = y / (a / z);
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (z <= (-1.7d+202)) then
tmp = z * (y / a)
else if (z <= 1060000000.0d0) then
tmp = x + y
else if (z <= 3.4d+102) then
tmp = x
else
tmp = y / (a / z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.7e+202) {
tmp = z * (y / a);
} else if (z <= 1060000000.0) {
tmp = x + y;
} else if (z <= 3.4e+102) {
tmp = x;
} else {
tmp = y / (a / z);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -1.7e+202: tmp = z * (y / a) elif z <= 1060000000.0: tmp = x + y elif z <= 3.4e+102: tmp = x else: tmp = y / (a / z) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.7e+202) tmp = Float64(z * Float64(y / a)); elseif (z <= 1060000000.0) tmp = Float64(x + y); elseif (z <= 3.4e+102) tmp = x; else tmp = Float64(y / Float64(a / z)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -1.7e+202) tmp = z * (y / a); elseif (z <= 1060000000.0) tmp = x + y; elseif (z <= 3.4e+102) tmp = x; else tmp = y / (a / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.7e+202], N[(z * N[(y / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1060000000.0], N[(x + y), $MachinePrecision], If[LessEqual[z, 3.4e+102], x, N[(y / N[(a / z), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.7 \cdot 10^{+202}:\\
\;\;\;\;z \cdot \frac{y}{a}\\
\mathbf{elif}\;z \leq 1060000000:\\
\;\;\;\;x + y\\
\mathbf{elif}\;z \leq 3.4 \cdot 10^{+102}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;\frac{y}{\frac{a}{z}}\\
\end{array}
\end{array}
if z < -1.7e202Initial program 89.9%
Taylor expanded in a around inf
+-lowering-+.f64N/A
associate-/l*N/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f6474.2%
Simplified74.2%
Taylor expanded in x around 0
/-lowering-/.f64N/A
*-lowering-*.f64N/A
--lowering--.f6457.9%
Simplified57.9%
*-commutativeN/A
associate-/l*N/A
*-lowering-*.f64N/A
--lowering--.f64N/A
/-lowering-/.f6467.9%
Applied egg-rr67.9%
Taylor expanded in z around inf
Simplified67.9%
if -1.7e202 < z < 1.06e9Initial program 87.8%
Taylor expanded in t around inf
+-commutativeN/A
+-lowering-+.f6467.5%
Simplified67.5%
if 1.06e9 < z < 3.4e102Initial program 96.2%
Taylor expanded in x around inf
Simplified61.3%
if 3.4e102 < z Initial program 75.0%
Taylor expanded in z around inf
associate-/l*N/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f6470.0%
Simplified70.0%
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
--lowering--.f6470.0%
Applied egg-rr70.0%
Taylor expanded in a around inf
Simplified51.6%
Final simplification64.3%
(FPCore (x y z t a) :precision binary64 (if (<= z -4.2e+201) (* z (/ y a)) (if (<= z 1080000000.0) (+ x y) (if (<= z 1.85e+102) x (* y (/ z a))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -4.2e+201) {
tmp = z * (y / a);
} else if (z <= 1080000000.0) {
tmp = x + y;
} else if (z <= 1.85e+102) {
tmp = x;
} else {
tmp = y * (z / a);
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (z <= (-4.2d+201)) then
tmp = z * (y / a)
else if (z <= 1080000000.0d0) then
tmp = x + y
else if (z <= 1.85d+102) then
tmp = x
else
tmp = y * (z / a)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -4.2e+201) {
tmp = z * (y / a);
} else if (z <= 1080000000.0) {
tmp = x + y;
} else if (z <= 1.85e+102) {
tmp = x;
} else {
tmp = y * (z / a);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -4.2e+201: tmp = z * (y / a) elif z <= 1080000000.0: tmp = x + y elif z <= 1.85e+102: tmp = x else: tmp = y * (z / a) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -4.2e+201) tmp = Float64(z * Float64(y / a)); elseif (z <= 1080000000.0) tmp = Float64(x + y); elseif (z <= 1.85e+102) tmp = x; else tmp = Float64(y * Float64(z / a)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -4.2e+201) tmp = z * (y / a); elseif (z <= 1080000000.0) tmp = x + y; elseif (z <= 1.85e+102) tmp = x; else tmp = y * (z / a); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -4.2e+201], N[(z * N[(y / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1080000000.0], N[(x + y), $MachinePrecision], If[LessEqual[z, 1.85e+102], x, N[(y * N[(z / a), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -4.2 \cdot 10^{+201}:\\
\;\;\;\;z \cdot \frac{y}{a}\\
\mathbf{elif}\;z \leq 1080000000:\\
\;\;\;\;x + y\\
\mathbf{elif}\;z \leq 1.85 \cdot 10^{+102}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;y \cdot \frac{z}{a}\\
\end{array}
\end{array}
if z < -4.1999999999999998e201Initial program 89.9%
Taylor expanded in a around inf
+-lowering-+.f64N/A
associate-/l*N/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f6474.2%
Simplified74.2%
Taylor expanded in x around 0
/-lowering-/.f64N/A
*-lowering-*.f64N/A
--lowering--.f6457.9%
Simplified57.9%
*-commutativeN/A
associate-/l*N/A
*-lowering-*.f64N/A
--lowering--.f64N/A
/-lowering-/.f6467.9%
Applied egg-rr67.9%
Taylor expanded in z around inf
Simplified67.9%
if -4.1999999999999998e201 < z < 1.08e9Initial program 87.8%
Taylor expanded in t around inf
+-commutativeN/A
+-lowering-+.f6467.5%
Simplified67.5%
if 1.08e9 < z < 1.85000000000000011e102Initial program 96.2%
Taylor expanded in x around inf
Simplified61.3%
if 1.85000000000000011e102 < z Initial program 75.0%
Taylor expanded in z around inf
associate-/l*N/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f6470.0%
Simplified70.0%
Taylor expanded in a around inf
Simplified51.6%
Final simplification64.3%
(FPCore (x y z t a) :precision binary64 (if (<= t -3.3e+190) (+ x (* y (/ t (- t a)))) (if (<= t 9.2e-49) (+ x (* z (/ y (- a t)))) (+ x (- y (/ y (/ t z)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -3.3e+190) {
tmp = x + (y * (t / (t - a)));
} else if (t <= 9.2e-49) {
tmp = x + (z * (y / (a - t)));
} else {
tmp = x + (y - (y / (t / 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 <= (-3.3d+190)) then
tmp = x + (y * (t / (t - a)))
else if (t <= 9.2d-49) then
tmp = x + (z * (y / (a - t)))
else
tmp = x + (y - (y / (t / 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 <= -3.3e+190) {
tmp = x + (y * (t / (t - a)));
} else if (t <= 9.2e-49) {
tmp = x + (z * (y / (a - t)));
} else {
tmp = x + (y - (y / (t / z)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -3.3e+190: tmp = x + (y * (t / (t - a))) elif t <= 9.2e-49: tmp = x + (z * (y / (a - t))) else: tmp = x + (y - (y / (t / z))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -3.3e+190) tmp = Float64(x + Float64(y * Float64(t / Float64(t - a)))); elseif (t <= 9.2e-49) tmp = Float64(x + Float64(z * Float64(y / Float64(a - t)))); else tmp = Float64(x + Float64(y - Float64(y / Float64(t / z)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -3.3e+190) tmp = x + (y * (t / (t - a))); elseif (t <= 9.2e-49) tmp = x + (z * (y / (a - t))); else tmp = x + (y - (y / (t / z))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -3.3e+190], N[(x + N[(y * N[(t / N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 9.2e-49], N[(x + N[(z * N[(y / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y - N[(y / N[(t / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.3 \cdot 10^{+190}:\\
\;\;\;\;x + y \cdot \frac{t}{t - a}\\
\mathbf{elif}\;t \leq 9.2 \cdot 10^{-49}:\\
\;\;\;\;x + z \cdot \frac{y}{a - t}\\
\mathbf{else}:\\
\;\;\;\;x + \left(y - \frac{y}{\frac{t}{z}}\right)\\
\end{array}
\end{array}
if t < -3.3e190Initial program 64.3%
Taylor expanded in z around 0
mul-1-negN/A
unsub-negN/A
--lowering--.f64N/A
*-commutativeN/A
associate-/l*N/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f6497.1%
Simplified97.1%
if -3.3e190 < t < 9.1999999999999996e-49Initial program 92.2%
associate-/l*N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
--lowering--.f6498.7%
Applied egg-rr98.7%
+-commutativeN/A
+-lowering-+.f64N/A
associate-/r/N/A
*-commutativeN/A
*-lowering-*.f64N/A
--lowering--.f64N/A
/-lowering-/.f64N/A
--lowering--.f6495.8%
Applied egg-rr95.8%
Taylor expanded in z around inf
Simplified91.3%
if 9.1999999999999996e-49 < t Initial program 82.5%
associate-/l*N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
--lowering--.f6499.9%
Applied egg-rr99.9%
Taylor expanded in a around 0
mul-1-negN/A
unsub-negN/A
--lowering--.f64N/A
associate-/l*N/A
*-lowering-*.f64N/A
div-subN/A
*-inversesN/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
/-lowering-/.f6493.2%
Simplified93.2%
distribute-rgt-inN/A
fma-defineN/A
neg-mul-1N/A
fmm-undefN/A
--lowering--.f64N/A
*-commutativeN/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f6493.2%
Applied egg-rr93.2%
Final simplification92.4%
(FPCore (x y z t a) :precision binary64 (if (<= t -3.3e+190) (+ x (* y (/ t (- t a)))) (if (<= t 9.2e-49) (+ x (* z (/ y (- a t)))) (- x (* y (+ -1.0 (/ z t)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -3.3e+190) {
tmp = x + (y * (t / (t - a)));
} else if (t <= 9.2e-49) {
tmp = x + (z * (y / (a - t)));
} else {
tmp = x - (y * (-1.0 + (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 <= (-3.3d+190)) then
tmp = x + (y * (t / (t - a)))
else if (t <= 9.2d-49) then
tmp = x + (z * (y / (a - t)))
else
tmp = x - (y * ((-1.0d0) + (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 <= -3.3e+190) {
tmp = x + (y * (t / (t - a)));
} else if (t <= 9.2e-49) {
tmp = x + (z * (y / (a - t)));
} else {
tmp = x - (y * (-1.0 + (z / t)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -3.3e+190: tmp = x + (y * (t / (t - a))) elif t <= 9.2e-49: tmp = x + (z * (y / (a - t))) else: tmp = x - (y * (-1.0 + (z / t))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -3.3e+190) tmp = Float64(x + Float64(y * Float64(t / Float64(t - a)))); elseif (t <= 9.2e-49) tmp = Float64(x + Float64(z * Float64(y / Float64(a - t)))); else tmp = Float64(x - Float64(y * Float64(-1.0 + Float64(z / t)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -3.3e+190) tmp = x + (y * (t / (t - a))); elseif (t <= 9.2e-49) tmp = x + (z * (y / (a - t))); else tmp = x - (y * (-1.0 + (z / t))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -3.3e+190], N[(x + N[(y * N[(t / N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 9.2e-49], N[(x + N[(z * N[(y / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x - N[(y * N[(-1.0 + N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.3 \cdot 10^{+190}:\\
\;\;\;\;x + y \cdot \frac{t}{t - a}\\
\mathbf{elif}\;t \leq 9.2 \cdot 10^{-49}:\\
\;\;\;\;x + z \cdot \frac{y}{a - t}\\
\mathbf{else}:\\
\;\;\;\;x - y \cdot \left(-1 + \frac{z}{t}\right)\\
\end{array}
\end{array}
if t < -3.3e190Initial program 64.3%
Taylor expanded in z around 0
mul-1-negN/A
unsub-negN/A
--lowering--.f64N/A
*-commutativeN/A
associate-/l*N/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f6497.1%
Simplified97.1%
if -3.3e190 < t < 9.1999999999999996e-49Initial program 92.2%
associate-/l*N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
--lowering--.f6498.7%
Applied egg-rr98.7%
+-commutativeN/A
+-lowering-+.f64N/A
associate-/r/N/A
*-commutativeN/A
*-lowering-*.f64N/A
--lowering--.f64N/A
/-lowering-/.f64N/A
--lowering--.f6495.8%
Applied egg-rr95.8%
Taylor expanded in z around inf
Simplified91.3%
if 9.1999999999999996e-49 < t Initial program 82.5%
Taylor expanded in a around 0
mul-1-negN/A
unsub-negN/A
--lowering--.f64N/A
associate-/l*N/A
*-lowering-*.f64N/A
div-subN/A
sub-negN/A
*-inversesN/A
metadata-evalN/A
+-commutativeN/A
+-lowering-+.f64N/A
/-lowering-/.f6493.2%
Simplified93.2%
Final simplification92.4%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (- x (* y (+ -1.0 (/ z t))))))
(if (<= t -3.3e+190)
t_1
(if (<= t 4.6e-49) (+ x (* z (/ y (- a t)))) t_1))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x - (y * (-1.0 + (z / t)));
double tmp;
if (t <= -3.3e+190) {
tmp = t_1;
} else if (t <= 4.6e-49) {
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 = x - (y * ((-1.0d0) + (z / t)))
if (t <= (-3.3d+190)) then
tmp = t_1
else if (t <= 4.6d-49) 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 = x - (y * (-1.0 + (z / t)));
double tmp;
if (t <= -3.3e+190) {
tmp = t_1;
} else if (t <= 4.6e-49) {
tmp = x + (z * (y / (a - t)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x - (y * (-1.0 + (z / t))) tmp = 0 if t <= -3.3e+190: tmp = t_1 elif t <= 4.6e-49: tmp = x + (z * (y / (a - t))) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x - Float64(y * Float64(-1.0 + Float64(z / t)))) tmp = 0.0 if (t <= -3.3e+190) tmp = t_1; elseif (t <= 4.6e-49) 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 = x - (y * (-1.0 + (z / t))); tmp = 0.0; if (t <= -3.3e+190) tmp = t_1; elseif (t <= 4.6e-49) 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[(x - N[(y * N[(-1.0 + N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -3.3e+190], t$95$1, If[LessEqual[t, 4.6e-49], N[(x + N[(z * N[(y / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x - y \cdot \left(-1 + \frac{z}{t}\right)\\
\mathbf{if}\;t \leq -3.3 \cdot 10^{+190}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 4.6 \cdot 10^{-49}:\\
\;\;\;\;x + z \cdot \frac{y}{a - t}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if t < -3.3e190 or 4.5999999999999998e-49 < t Initial program 77.6%
Taylor expanded in a around 0
mul-1-negN/A
unsub-negN/A
--lowering--.f64N/A
associate-/l*N/A
*-lowering-*.f64N/A
div-subN/A
sub-negN/A
*-inversesN/A
metadata-evalN/A
+-commutativeN/A
+-lowering-+.f64N/A
/-lowering-/.f6493.7%
Simplified93.7%
if -3.3e190 < t < 4.5999999999999998e-49Initial program 92.2%
associate-/l*N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
--lowering--.f6498.7%
Applied egg-rr98.7%
+-commutativeN/A
+-lowering-+.f64N/A
associate-/r/N/A
*-commutativeN/A
*-lowering-*.f64N/A
--lowering--.f64N/A
/-lowering-/.f64N/A
--lowering--.f6495.8%
Applied egg-rr95.8%
Taylor expanded in z around inf
Simplified91.3%
Final simplification92.2%
(FPCore (x y z t a) :precision binary64 (if (<= t -5.2e+190) (+ x y) (if (<= t 3.45e+236) (+ x (* z (/ y (- a t)))) (+ x y))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -5.2e+190) {
tmp = x + y;
} else if (t <= 3.45e+236) {
tmp = x + (z * (y / (a - t)));
} else {
tmp = x + y;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (t <= (-5.2d+190)) then
tmp = x + y
else if (t <= 3.45d+236) then
tmp = x + (z * (y / (a - t)))
else
tmp = x + y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -5.2e+190) {
tmp = x + y;
} else if (t <= 3.45e+236) {
tmp = x + (z * (y / (a - t)));
} else {
tmp = x + y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -5.2e+190: tmp = x + y elif t <= 3.45e+236: tmp = x + (z * (y / (a - t))) else: tmp = x + y return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -5.2e+190) tmp = Float64(x + y); elseif (t <= 3.45e+236) tmp = Float64(x + Float64(z * Float64(y / Float64(a - t)))); else tmp = Float64(x + y); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -5.2e+190) tmp = x + y; elseif (t <= 3.45e+236) tmp = x + (z * (y / (a - t))); else tmp = x + y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -5.2e+190], N[(x + y), $MachinePrecision], If[LessEqual[t, 3.45e+236], N[(x + N[(z * N[(y / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + y), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -5.2 \cdot 10^{+190}:\\
\;\;\;\;x + y\\
\mathbf{elif}\;t \leq 3.45 \cdot 10^{+236}:\\
\;\;\;\;x + z \cdot \frac{y}{a - t}\\
\mathbf{else}:\\
\;\;\;\;x + y\\
\end{array}
\end{array}
if t < -5.20000000000000022e190 or 3.4499999999999999e236 < t Initial program 65.2%
Taylor expanded in t around inf
+-commutativeN/A
+-lowering-+.f6495.0%
Simplified95.0%
if -5.20000000000000022e190 < t < 3.4499999999999999e236Initial program 90.7%
associate-/l*N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
--lowering--.f6499.0%
Applied egg-rr99.0%
+-commutativeN/A
+-lowering-+.f64N/A
associate-/r/N/A
*-commutativeN/A
*-lowering-*.f64N/A
--lowering--.f64N/A
/-lowering-/.f64N/A
--lowering--.f6496.2%
Applied egg-rr96.2%
Taylor expanded in z around inf
Simplified88.5%
Final simplification89.5%
(FPCore (x y z t a) :precision binary64 (if (<= t -1.35e+61) (+ x y) (if (<= t 1.9e-27) (+ x (* y (/ (- z t) a))) (+ x y))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -1.35e+61) {
tmp = x + y;
} else if (t <= 1.9e-27) {
tmp = x + (y * ((z - t) / a));
} else {
tmp = x + y;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (t <= (-1.35d+61)) then
tmp = x + y
else if (t <= 1.9d-27) then
tmp = x + (y * ((z - t) / a))
else
tmp = x + y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -1.35e+61) {
tmp = x + y;
} else if (t <= 1.9e-27) {
tmp = x + (y * ((z - t) / a));
} else {
tmp = x + y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -1.35e+61: tmp = x + y elif t <= 1.9e-27: tmp = x + (y * ((z - t) / a)) else: tmp = x + y return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -1.35e+61) tmp = Float64(x + y); elseif (t <= 1.9e-27) tmp = Float64(x + Float64(y * Float64(Float64(z - t) / a))); else tmp = Float64(x + y); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -1.35e+61) tmp = x + y; elseif (t <= 1.9e-27) tmp = x + (y * ((z - t) / a)); else tmp = x + y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -1.35e+61], N[(x + y), $MachinePrecision], If[LessEqual[t, 1.9e-27], N[(x + N[(y * N[(N[(z - t), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + y), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.35 \cdot 10^{+61}:\\
\;\;\;\;x + y\\
\mathbf{elif}\;t \leq 1.9 \cdot 10^{-27}:\\
\;\;\;\;x + y \cdot \frac{z - t}{a}\\
\mathbf{else}:\\
\;\;\;\;x + y\\
\end{array}
\end{array}
if t < -1.3500000000000001e61 or 1.9e-27 < t Initial program 76.3%
Taylor expanded in t around inf
+-commutativeN/A
+-lowering-+.f6479.7%
Simplified79.7%
if -1.3500000000000001e61 < t < 1.9e-27Initial program 95.1%
Taylor expanded in a around inf
+-lowering-+.f64N/A
associate-/l*N/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f6482.9%
Simplified82.9%
Final simplification81.4%
(FPCore (x y z t a) :precision binary64 (if (<= t -7.8e+157) (+ x y) (if (<= t 5.6e-30) (+ x (/ y (/ a z))) (+ x y))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -7.8e+157) {
tmp = x + y;
} else if (t <= 5.6e-30) {
tmp = x + (y / (a / z));
} else {
tmp = x + y;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (t <= (-7.8d+157)) then
tmp = x + y
else if (t <= 5.6d-30) then
tmp = x + (y / (a / z))
else
tmp = x + y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -7.8e+157) {
tmp = x + y;
} else if (t <= 5.6e-30) {
tmp = x + (y / (a / z));
} else {
tmp = x + y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -7.8e+157: tmp = x + y elif t <= 5.6e-30: tmp = x + (y / (a / z)) else: tmp = x + y return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -7.8e+157) tmp = Float64(x + y); elseif (t <= 5.6e-30) tmp = Float64(x + Float64(y / Float64(a / z))); else tmp = Float64(x + y); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -7.8e+157) tmp = x + y; elseif (t <= 5.6e-30) tmp = x + (y / (a / z)); else tmp = x + y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -7.8e+157], N[(x + y), $MachinePrecision], If[LessEqual[t, 5.6e-30], N[(x + N[(y / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + y), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -7.8 \cdot 10^{+157}:\\
\;\;\;\;x + y\\
\mathbf{elif}\;t \leq 5.6 \cdot 10^{-30}:\\
\;\;\;\;x + \frac{y}{\frac{a}{z}}\\
\mathbf{else}:\\
\;\;\;\;x + y\\
\end{array}
\end{array}
if t < -7.79999999999999941e157 or 5.59999999999999977e-30 < t Initial program 75.9%
Taylor expanded in t around inf
+-commutativeN/A
+-lowering-+.f6481.8%
Simplified81.8%
if -7.79999999999999941e157 < t < 5.59999999999999977e-30Initial program 93.3%
associate-/l*N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
--lowering--.f6498.7%
Applied egg-rr98.7%
Taylor expanded in t around 0
/-lowering-/.f6479.8%
Simplified79.8%
Final simplification80.6%
(FPCore (x y z t a) :precision binary64 (if (<= t -3.3e+190) (+ x y) (if (<= t 5.6e-27) (+ x (* y (/ z a))) (+ x y))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -3.3e+190) {
tmp = x + y;
} else if (t <= 5.6e-27) {
tmp = x + (y * (z / a));
} else {
tmp = x + y;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (t <= (-3.3d+190)) then
tmp = x + y
else if (t <= 5.6d-27) then
tmp = x + (y * (z / a))
else
tmp = x + y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -3.3e+190) {
tmp = x + y;
} else if (t <= 5.6e-27) {
tmp = x + (y * (z / a));
} else {
tmp = x + y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -3.3e+190: tmp = x + y elif t <= 5.6e-27: tmp = x + (y * (z / a)) else: tmp = x + y return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -3.3e+190) tmp = Float64(x + y); elseif (t <= 5.6e-27) tmp = Float64(x + Float64(y * Float64(z / a))); else tmp = Float64(x + y); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -3.3e+190) tmp = x + y; elseif (t <= 5.6e-27) tmp = x + (y * (z / a)); else tmp = x + y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -3.3e+190], N[(x + y), $MachinePrecision], If[LessEqual[t, 5.6e-27], N[(x + N[(y * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + y), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.3 \cdot 10^{+190}:\\
\;\;\;\;x + y\\
\mathbf{elif}\;t \leq 5.6 \cdot 10^{-27}:\\
\;\;\;\;x + y \cdot \frac{z}{a}\\
\mathbf{else}:\\
\;\;\;\;x + y\\
\end{array}
\end{array}
if t < -3.3e190 or 5.5999999999999999e-27 < t Initial program 76.1%
Taylor expanded in t around inf
+-commutativeN/A
+-lowering-+.f6482.5%
Simplified82.5%
if -3.3e190 < t < 5.5999999999999999e-27Initial program 92.4%
Taylor expanded in a around inf
+-lowering-+.f64N/A
associate-/l*N/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f6480.2%
Simplified80.2%
Taylor expanded in z around inf
/-lowering-/.f6479.5%
Simplified79.5%
Final simplification80.6%
(FPCore (x y z t a) :precision binary64 (if (<= t -1.2e-37) (+ x y) (if (<= t 6.1e-49) x (+ x y))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -1.2e-37) {
tmp = x + y;
} else if (t <= 6.1e-49) {
tmp = x;
} else {
tmp = x + y;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (t <= (-1.2d-37)) then
tmp = x + y
else if (t <= 6.1d-49) then
tmp = x
else
tmp = x + y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -1.2e-37) {
tmp = x + y;
} else if (t <= 6.1e-49) {
tmp = x;
} else {
tmp = x + y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -1.2e-37: tmp = x + y elif t <= 6.1e-49: tmp = x else: tmp = x + y return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -1.2e-37) tmp = Float64(x + y); elseif (t <= 6.1e-49) tmp = x; else tmp = Float64(x + y); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -1.2e-37) tmp = x + y; elseif (t <= 6.1e-49) tmp = x; else tmp = x + y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -1.2e-37], N[(x + y), $MachinePrecision], If[LessEqual[t, 6.1e-49], x, N[(x + y), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.2 \cdot 10^{-37}:\\
\;\;\;\;x + y\\
\mathbf{elif}\;t \leq 6.1 \cdot 10^{-49}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;x + y\\
\end{array}
\end{array}
if t < -1.19999999999999995e-37 or 6.09999999999999963e-49 < t Initial program 79.3%
Taylor expanded in t around inf
+-commutativeN/A
+-lowering-+.f6475.2%
Simplified75.2%
if -1.19999999999999995e-37 < t < 6.09999999999999963e-49Initial program 95.1%
Taylor expanded in x around inf
Simplified43.3%
Final simplification60.2%
(FPCore (x y z t a) :precision binary64 (if (<= x -1.52e-232) x (if (<= x 1.05e-213) y x)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (x <= -1.52e-232) {
tmp = x;
} else if (x <= 1.05e-213) {
tmp = y;
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (x <= (-1.52d-232)) then
tmp = x
else if (x <= 1.05d-213) then
tmp = y
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (x <= -1.52e-232) {
tmp = x;
} else if (x <= 1.05e-213) {
tmp = y;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if x <= -1.52e-232: tmp = x elif x <= 1.05e-213: tmp = y else: tmp = x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (x <= -1.52e-232) tmp = x; elseif (x <= 1.05e-213) tmp = y; else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (x <= -1.52e-232) tmp = x; elseif (x <= 1.05e-213) tmp = y; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[x, -1.52e-232], x, If[LessEqual[x, 1.05e-213], y, x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.52 \cdot 10^{-232}:\\
\;\;\;\;x\\
\mathbf{elif}\;x \leq 1.05 \cdot 10^{-213}:\\
\;\;\;\;y\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if x < -1.52e-232 or 1.0499999999999999e-213 < x Initial program 86.8%
Taylor expanded in x around inf
Simplified55.6%
if -1.52e-232 < x < 1.0499999999999999e-213Initial program 86.3%
Taylor expanded in t around inf
+-commutativeN/A
+-lowering-+.f6438.5%
Simplified38.5%
Taylor expanded in y around inf
Simplified37.4%
(FPCore (x y z t a) :precision binary64 (+ x (* (- z t) (/ y (- a t)))))
double code(double x, double y, double z, double t, double a) {
return x + ((z - t) * (y / (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 + ((z - t) * (y / (a - t)))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + ((z - t) * (y / (a - t)));
}
def code(x, y, z, t, a): return x + ((z - t) * (y / (a - t)))
function code(x, y, z, t, a) return Float64(x + Float64(Float64(z - t) * Float64(y / Float64(a - t)))) end
function tmp = code(x, y, z, t, a) tmp = x + ((z - t) * (y / (a - t))); end
code[x_, y_, z_, t_, a_] := N[(x + N[(N[(z - t), $MachinePrecision] * N[(y / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(z - t\right) \cdot \frac{y}{a - t}
\end{array}
Initial program 86.7%
*-commutativeN/A
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
--lowering--.f6494.9%
Applied egg-rr94.9%
Final simplification94.9%
(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 86.7%
Taylor expanded in x around inf
Simplified49.0%
(FPCore (x y z t a) :precision binary64 (+ x (/ y (/ (- a t) (- z t)))))
double code(double x, double y, double z, double t, double a) {
return x + (y / ((a - t) / (z - 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 / ((a - t) / (z - t)))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + (y / ((a - t) / (z - t)));
}
def code(x, y, z, t, a): return x + (y / ((a - t) / (z - t)))
function code(x, y, z, t, a) return Float64(x + Float64(y / Float64(Float64(a - t) / Float64(z - t)))) end
function tmp = code(x, y, z, t, a) tmp = x + (y / ((a - t) / (z - t))); end
code[x_, y_, z_, t_, a_] := N[(x + N[(y / N[(N[(a - t), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \frac{y}{\frac{a - t}{z - t}}
\end{array}
herbie shell --seed 2024158
(FPCore (x y z t a)
:name "Graphics.Rendering.Plot.Render.Plot.Axis:renderAxisTicks from plot-0.2.3.4, B"
:precision binary64
:alt
(! :herbie-platform default (+ x (/ y (/ (- a t) (- z t)))))
(+ x (/ (* y (- z t)) (- a t))))