
(FPCore (x y z t a) :precision binary64 (- x (/ (- y z) (/ (+ (- t z) 1.0) a))))
double code(double x, double y, double z, double t, double a) {
return x - ((y - z) / (((t - z) + 1.0) / a));
}
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 - z) + 1.0d0) / a))
end function
public static double code(double x, double y, double z, double t, double a) {
return x - ((y - z) / (((t - z) + 1.0) / a));
}
def code(x, y, z, t, a): return x - ((y - z) / (((t - z) + 1.0) / a))
function code(x, y, z, t, a) return Float64(x - Float64(Float64(y - z) / Float64(Float64(Float64(t - z) + 1.0) / a))) end
function tmp = code(x, y, z, t, a) tmp = x - ((y - z) / (((t - z) + 1.0) / a)); end
code[x_, y_, z_, t_, a_] := N[(x - N[(N[(y - z), $MachinePrecision] / N[(N[(N[(t - z), $MachinePrecision] + 1.0), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x - \frac{y - z}{\frac{\left(t - z\right) + 1}{a}}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 12 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a) :precision binary64 (- x (/ (- y z) (/ (+ (- t z) 1.0) a))))
double code(double x, double y, double z, double t, double a) {
return x - ((y - z) / (((t - z) + 1.0) / a));
}
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 - z) + 1.0d0) / a))
end function
public static double code(double x, double y, double z, double t, double a) {
return x - ((y - z) / (((t - z) + 1.0) / a));
}
def code(x, y, z, t, a): return x - ((y - z) / (((t - z) + 1.0) / a))
function code(x, y, z, t, a) return Float64(x - Float64(Float64(y - z) / Float64(Float64(Float64(t - z) + 1.0) / a))) end
function tmp = code(x, y, z, t, a) tmp = x - ((y - z) / (((t - z) + 1.0) / a)); end
code[x_, y_, z_, t_, a_] := N[(x - N[(N[(y - z), $MachinePrecision] / N[(N[(N[(t - z), $MachinePrecision] + 1.0), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x - \frac{y - z}{\frac{\left(t - z\right) + 1}{a}}
\end{array}
(FPCore (x y z t a) :precision binary64 (fma (/ (- z y) (+ (- t z) 1.0)) a x))
double code(double x, double y, double z, double t, double a) {
return fma(((z - y) / ((t - z) + 1.0)), a, x);
}
function code(x, y, z, t, a) return fma(Float64(Float64(z - y) / Float64(Float64(t - z) + 1.0)), a, x) end
code[x_, y_, z_, t_, a_] := N[(N[(N[(z - y), $MachinePrecision] / N[(N[(t - z), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision] * a + x), $MachinePrecision]
\begin{array}{l}
\\
\mathsf{fma}\left(\frac{z - y}{\left(t - z\right) + 1}, a, x\right)
\end{array}
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (/ (- z y) (/ (- z) a)))))
(if (<= z -3.9e+16)
t_1
(if (<= z -1.45e-35)
(- x (/ a (/ t (- y z))))
(if (<= z -1.2e-78)
(* a (/ (- z y) (+ (- t z) 1.0)))
(if (<= z 7.5e+77) (- x (/ a (* (+ t 1.0) (/ 1.0 y)))) t_1))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((z - y) / (-z / a));
double tmp;
if (z <= -3.9e+16) {
tmp = t_1;
} else if (z <= -1.45e-35) {
tmp = x - (a / (t / (y - z)));
} else if (z <= -1.2e-78) {
tmp = a * ((z - y) / ((t - z) + 1.0));
} else if (z <= 7.5e+77) {
tmp = x - (a / ((t + 1.0) * (1.0 / y)));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = x + ((z - y) / (-z / a))
if (z <= (-3.9d+16)) then
tmp = t_1
else if (z <= (-1.45d-35)) then
tmp = x - (a / (t / (y - z)))
else if (z <= (-1.2d-78)) then
tmp = a * ((z - y) / ((t - z) + 1.0d0))
else if (z <= 7.5d+77) then
tmp = x - (a / ((t + 1.0d0) * (1.0d0 / y)))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((z - y) / (-z / a));
double tmp;
if (z <= -3.9e+16) {
tmp = t_1;
} else if (z <= -1.45e-35) {
tmp = x - (a / (t / (y - z)));
} else if (z <= -1.2e-78) {
tmp = a * ((z - y) / ((t - z) + 1.0));
} else if (z <= 7.5e+77) {
tmp = x - (a / ((t + 1.0) * (1.0 / y)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((z - y) / (-z / a)) tmp = 0 if z <= -3.9e+16: tmp = t_1 elif z <= -1.45e-35: tmp = x - (a / (t / (y - z))) elif z <= -1.2e-78: tmp = a * ((z - y) / ((t - z) + 1.0)) elif z <= 7.5e+77: tmp = x - (a / ((t + 1.0) * (1.0 / y))) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(z - y) / Float64(Float64(-z) / a))) tmp = 0.0 if (z <= -3.9e+16) tmp = t_1; elseif (z <= -1.45e-35) tmp = Float64(x - Float64(a / Float64(t / Float64(y - z)))); elseif (z <= -1.2e-78) tmp = Float64(a * Float64(Float64(z - y) / Float64(Float64(t - z) + 1.0))); elseif (z <= 7.5e+77) tmp = Float64(x - Float64(a / Float64(Float64(t + 1.0) * Float64(1.0 / y)))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + ((z - y) / (-z / a)); tmp = 0.0; if (z <= -3.9e+16) tmp = t_1; elseif (z <= -1.45e-35) tmp = x - (a / (t / (y - z))); elseif (z <= -1.2e-78) tmp = a * ((z - y) / ((t - z) + 1.0)); elseif (z <= 7.5e+77) tmp = x - (a / ((t + 1.0) * (1.0 / y))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(z - y), $MachinePrecision] / N[((-z) / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -3.9e+16], t$95$1, If[LessEqual[z, -1.45e-35], N[(x - N[(a / N[(t / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -1.2e-78], N[(a * N[(N[(z - y), $MachinePrecision] / N[(N[(t - z), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 7.5e+77], N[(x - N[(a / N[(N[(t + 1.0), $MachinePrecision] * N[(1.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{z - y}{\frac{-z}{a}}\\
\mathbf{if}\;z \leq -3.9 \cdot 10^{+16}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq -1.45 \cdot 10^{-35}:\\
\;\;\;\;x - \frac{a}{\frac{t}{y - z}}\\
\mathbf{elif}\;z \leq -1.2 \cdot 10^{-78}:\\
\;\;\;\;a \cdot \frac{z - y}{\left(t - z\right) + 1}\\
\mathbf{elif}\;z \leq 7.5 \cdot 10^{+77}:\\
\;\;\;\;x - \frac{a}{\left(t + 1\right) \cdot \frac{1}{y}}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (/ (- z y) (/ (- z) a)))))
(if (<= z -2.4e+16)
t_1
(if (<= z -2.2e-35)
(- x (/ a (/ t (- y z))))
(if (<= z -1.2e-78)
(* a (/ (- z y) (+ (- t z) 1.0)))
(if (<= z 7e+77) (- x (/ a (/ (+ t 1.0) y))) t_1))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((z - y) / (-z / a));
double tmp;
if (z <= -2.4e+16) {
tmp = t_1;
} else if (z <= -2.2e-35) {
tmp = x - (a / (t / (y - z)));
} else if (z <= -1.2e-78) {
tmp = a * ((z - y) / ((t - z) + 1.0));
} else if (z <= 7e+77) {
tmp = x - (a / ((t + 1.0) / y));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = x + ((z - y) / (-z / a))
if (z <= (-2.4d+16)) then
tmp = t_1
else if (z <= (-2.2d-35)) then
tmp = x - (a / (t / (y - z)))
else if (z <= (-1.2d-78)) then
tmp = a * ((z - y) / ((t - z) + 1.0d0))
else if (z <= 7d+77) then
tmp = x - (a / ((t + 1.0d0) / y))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((z - y) / (-z / a));
double tmp;
if (z <= -2.4e+16) {
tmp = t_1;
} else if (z <= -2.2e-35) {
tmp = x - (a / (t / (y - z)));
} else if (z <= -1.2e-78) {
tmp = a * ((z - y) / ((t - z) + 1.0));
} else if (z <= 7e+77) {
tmp = x - (a / ((t + 1.0) / y));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((z - y) / (-z / a)) tmp = 0 if z <= -2.4e+16: tmp = t_1 elif z <= -2.2e-35: tmp = x - (a / (t / (y - z))) elif z <= -1.2e-78: tmp = a * ((z - y) / ((t - z) + 1.0)) elif z <= 7e+77: tmp = x - (a / ((t + 1.0) / y)) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(z - y) / Float64(Float64(-z) / a))) tmp = 0.0 if (z <= -2.4e+16) tmp = t_1; elseif (z <= -2.2e-35) tmp = Float64(x - Float64(a / Float64(t / Float64(y - z)))); elseif (z <= -1.2e-78) tmp = Float64(a * Float64(Float64(z - y) / Float64(Float64(t - z) + 1.0))); elseif (z <= 7e+77) tmp = Float64(x - Float64(a / Float64(Float64(t + 1.0) / y))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + ((z - y) / (-z / a)); tmp = 0.0; if (z <= -2.4e+16) tmp = t_1; elseif (z <= -2.2e-35) tmp = x - (a / (t / (y - z))); elseif (z <= -1.2e-78) tmp = a * ((z - y) / ((t - z) + 1.0)); elseif (z <= 7e+77) tmp = x - (a / ((t + 1.0) / y)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(z - y), $MachinePrecision] / N[((-z) / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2.4e+16], t$95$1, If[LessEqual[z, -2.2e-35], N[(x - N[(a / N[(t / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -1.2e-78], N[(a * N[(N[(z - y), $MachinePrecision] / N[(N[(t - z), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 7e+77], N[(x - N[(a / N[(N[(t + 1.0), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{z - y}{\frac{-z}{a}}\\
\mathbf{if}\;z \leq -2.4 \cdot 10^{+16}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq -2.2 \cdot 10^{-35}:\\
\;\;\;\;x - \frac{a}{\frac{t}{y - z}}\\
\mathbf{elif}\;z \leq -1.2 \cdot 10^{-78}:\\
\;\;\;\;a \cdot \frac{z - y}{\left(t - z\right) + 1}\\
\mathbf{elif}\;z \leq 7 \cdot 10^{+77}:\\
\;\;\;\;x - \frac{a}{\frac{t + 1}{y}}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (- x (/ a (/ t (- y z))))))
(if (<= z -2e+15)
(- x a)
(if (<= z -1.2e-36)
t_1
(if (<= z 4.5e-50) (- x (* y a)) (if (<= z 9e+80) t_1 (- x a)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x - (a / (t / (y - z)));
double tmp;
if (z <= -2e+15) {
tmp = x - a;
} else if (z <= -1.2e-36) {
tmp = t_1;
} else if (z <= 4.5e-50) {
tmp = x - (y * a);
} else if (z <= 9e+80) {
tmp = t_1;
} else {
tmp = 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) :: t_1
real(8) :: tmp
t_1 = x - (a / (t / (y - z)))
if (z <= (-2d+15)) then
tmp = x - a
else if (z <= (-1.2d-36)) then
tmp = t_1
else if (z <= 4.5d-50) then
tmp = x - (y * a)
else if (z <= 9d+80) then
tmp = t_1
else
tmp = x - a
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x - (a / (t / (y - z)));
double tmp;
if (z <= -2e+15) {
tmp = x - a;
} else if (z <= -1.2e-36) {
tmp = t_1;
} else if (z <= 4.5e-50) {
tmp = x - (y * a);
} else if (z <= 9e+80) {
tmp = t_1;
} else {
tmp = x - a;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x - (a / (t / (y - z))) tmp = 0 if z <= -2e+15: tmp = x - a elif z <= -1.2e-36: tmp = t_1 elif z <= 4.5e-50: tmp = x - (y * a) elif z <= 9e+80: tmp = t_1 else: tmp = x - a return tmp
function code(x, y, z, t, a) t_1 = Float64(x - Float64(a / Float64(t / Float64(y - z)))) tmp = 0.0 if (z <= -2e+15) tmp = Float64(x - a); elseif (z <= -1.2e-36) tmp = t_1; elseif (z <= 4.5e-50) tmp = Float64(x - Float64(y * a)); elseif (z <= 9e+80) tmp = t_1; else tmp = Float64(x - a); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x - (a / (t / (y - z))); tmp = 0.0; if (z <= -2e+15) tmp = x - a; elseif (z <= -1.2e-36) tmp = t_1; elseif (z <= 4.5e-50) tmp = x - (y * a); elseif (z <= 9e+80) tmp = t_1; else tmp = x - a; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x - N[(a / N[(t / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2e+15], N[(x - a), $MachinePrecision], If[LessEqual[z, -1.2e-36], t$95$1, If[LessEqual[z, 4.5e-50], N[(x - N[(y * a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 9e+80], t$95$1, N[(x - a), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x - \frac{a}{\frac{t}{y - z}}\\
\mathbf{if}\;z \leq -2 \cdot 10^{+15}:\\
\;\;\;\;x - a\\
\mathbf{elif}\;z \leq -1.2 \cdot 10^{-36}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq 4.5 \cdot 10^{-50}:\\
\;\;\;\;x - y \cdot a\\
\mathbf{elif}\;z \leq 9 \cdot 10^{+80}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;x - a\\
\end{array}
\end{array}
(FPCore (x y z t a) :precision binary64 (if (or (<= z -4.4e-6) (not (<= z 1.4e+78))) (+ x (/ (- z y) (/ (- z) a))) (- x (/ a (/ (+ t 1.0) y)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -4.4e-6) || !(z <= 1.4e+78)) {
tmp = x + ((z - y) / (-z / a));
} else {
tmp = x - (a / ((t + 1.0) / 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 <= (-4.4d-6)) .or. (.not. (z <= 1.4d+78))) then
tmp = x + ((z - y) / (-z / a))
else
tmp = x - (a / ((t + 1.0d0) / 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 <= -4.4e-6) || !(z <= 1.4e+78)) {
tmp = x + ((z - y) / (-z / a));
} else {
tmp = x - (a / ((t + 1.0) / y));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (z <= -4.4e-6) or not (z <= 1.4e+78): tmp = x + ((z - y) / (-z / a)) else: tmp = x - (a / ((t + 1.0) / y)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((z <= -4.4e-6) || !(z <= 1.4e+78)) tmp = Float64(x + Float64(Float64(z - y) / Float64(Float64(-z) / a))); else tmp = Float64(x - Float64(a / Float64(Float64(t + 1.0) / y))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((z <= -4.4e-6) || ~((z <= 1.4e+78))) tmp = x + ((z - y) / (-z / a)); else tmp = x - (a / ((t + 1.0) / y)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[z, -4.4e-6], N[Not[LessEqual[z, 1.4e+78]], $MachinePrecision]], N[(x + N[(N[(z - y), $MachinePrecision] / N[((-z) / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x - N[(a / N[(N[(t + 1.0), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -4.4 \cdot 10^{-6} \lor \neg \left(z \leq 1.4 \cdot 10^{+78}\right):\\
\;\;\;\;x + \frac{z - y}{\frac{-z}{a}}\\
\mathbf{else}:\\
\;\;\;\;x - \frac{a}{\frac{t + 1}{y}}\\
\end{array}
\end{array}
(FPCore (x y z t a) :precision binary64 (if (or (<= z -4.4e-6) (not (<= z 9.5e+77))) (- x a) (- x (/ a (/ (+ t 1.0) y)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -4.4e-6) || !(z <= 9.5e+77)) {
tmp = x - a;
} else {
tmp = x - (a / ((t + 1.0) / 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 <= (-4.4d-6)) .or. (.not. (z <= 9.5d+77))) then
tmp = x - a
else
tmp = x - (a / ((t + 1.0d0) / 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 <= -4.4e-6) || !(z <= 9.5e+77)) {
tmp = x - a;
} else {
tmp = x - (a / ((t + 1.0) / y));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (z <= -4.4e-6) or not (z <= 9.5e+77): tmp = x - a else: tmp = x - (a / ((t + 1.0) / y)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((z <= -4.4e-6) || !(z <= 9.5e+77)) tmp = Float64(x - a); else tmp = Float64(x - Float64(a / Float64(Float64(t + 1.0) / y))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((z <= -4.4e-6) || ~((z <= 9.5e+77))) tmp = x - a; else tmp = x - (a / ((t + 1.0) / y)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[z, -4.4e-6], N[Not[LessEqual[z, 9.5e+77]], $MachinePrecision]], N[(x - a), $MachinePrecision], N[(x - N[(a / N[(N[(t + 1.0), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -4.4 \cdot 10^{-6} \lor \neg \left(z \leq 9.5 \cdot 10^{+77}\right):\\
\;\;\;\;x - a\\
\mathbf{else}:\\
\;\;\;\;x - \frac{a}{\frac{t + 1}{y}}\\
\end{array}
\end{array}
(FPCore (x y z t a) :precision binary64 (+ x (* a (/ (- z y) (+ (- t z) 1.0)))))
double code(double x, double y, double z, double t, double a) {
return x + (a * ((z - y) / ((t - z) + 1.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 = x + (a * ((z - y) / ((t - z) + 1.0d0)))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + (a * ((z - y) / ((t - z) + 1.0)));
}
def code(x, y, z, t, a): return x + (a * ((z - y) / ((t - z) + 1.0)))
function code(x, y, z, t, a) return Float64(x + Float64(a * Float64(Float64(z - y) / Float64(Float64(t - z) + 1.0)))) end
function tmp = code(x, y, z, t, a) tmp = x + (a * ((z - y) / ((t - z) + 1.0))); end
code[x_, y_, z_, t_, a_] := N[(x + N[(a * N[(N[(z - y), $MachinePrecision] / N[(N[(t - z), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + a \cdot \frac{z - y}{\left(t - z\right) + 1}
\end{array}
(FPCore (x y z t a)
:precision binary64
(if (<= z -4.4e-6)
(- x a)
(if (<= z 1.02e-254)
x
(if (<= z 1.3e-210) (* y (- a)) (if (<= z 1.05e+79) x (- x a))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -4.4e-6) {
tmp = x - a;
} else if (z <= 1.02e-254) {
tmp = x;
} else if (z <= 1.3e-210) {
tmp = y * -a;
} else if (z <= 1.05e+79) {
tmp = x;
} else {
tmp = 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 (z <= (-4.4d-6)) then
tmp = x - a
else if (z <= 1.02d-254) then
tmp = x
else if (z <= 1.3d-210) then
tmp = y * -a
else if (z <= 1.05d+79) then
tmp = x
else
tmp = 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 (z <= -4.4e-6) {
tmp = x - a;
} else if (z <= 1.02e-254) {
tmp = x;
} else if (z <= 1.3e-210) {
tmp = y * -a;
} else if (z <= 1.05e+79) {
tmp = x;
} else {
tmp = x - a;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -4.4e-6: tmp = x - a elif z <= 1.02e-254: tmp = x elif z <= 1.3e-210: tmp = y * -a elif z <= 1.05e+79: tmp = x else: tmp = x - a return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -4.4e-6) tmp = Float64(x - a); elseif (z <= 1.02e-254) tmp = x; elseif (z <= 1.3e-210) tmp = Float64(y * Float64(-a)); elseif (z <= 1.05e+79) tmp = x; else tmp = Float64(x - a); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -4.4e-6) tmp = x - a; elseif (z <= 1.02e-254) tmp = x; elseif (z <= 1.3e-210) tmp = y * -a; elseif (z <= 1.05e+79) tmp = x; else tmp = x - a; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -4.4e-6], N[(x - a), $MachinePrecision], If[LessEqual[z, 1.02e-254], x, If[LessEqual[z, 1.3e-210], N[(y * (-a)), $MachinePrecision], If[LessEqual[z, 1.05e+79], x, N[(x - a), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -4.4 \cdot 10^{-6}:\\
\;\;\;\;x - a\\
\mathbf{elif}\;z \leq 1.02 \cdot 10^{-254}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq 1.3 \cdot 10^{-210}:\\
\;\;\;\;y \cdot \left(-a\right)\\
\mathbf{elif}\;z \leq 1.05 \cdot 10^{+79}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;x - a\\
\end{array}
\end{array}
(FPCore (x y z t a)
:precision binary64
(if (<= z -6.5e+14)
(- x a)
(if (<= z -3.8e-29)
(+ x (* z (/ a t)))
(if (<= z 1.86e+71) (- x (* y a)) (- x a)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -6.5e+14) {
tmp = x - a;
} else if (z <= -3.8e-29) {
tmp = x + (z * (a / t));
} else if (z <= 1.86e+71) {
tmp = x - (y * a);
} else {
tmp = 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 (z <= (-6.5d+14)) then
tmp = x - a
else if (z <= (-3.8d-29)) then
tmp = x + (z * (a / t))
else if (z <= 1.86d+71) then
tmp = x - (y * a)
else
tmp = 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 (z <= -6.5e+14) {
tmp = x - a;
} else if (z <= -3.8e-29) {
tmp = x + (z * (a / t));
} else if (z <= 1.86e+71) {
tmp = x - (y * a);
} else {
tmp = x - a;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -6.5e+14: tmp = x - a elif z <= -3.8e-29: tmp = x + (z * (a / t)) elif z <= 1.86e+71: tmp = x - (y * a) else: tmp = x - a return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -6.5e+14) tmp = Float64(x - a); elseif (z <= -3.8e-29) tmp = Float64(x + Float64(z * Float64(a / t))); elseif (z <= 1.86e+71) tmp = Float64(x - Float64(y * a)); else tmp = Float64(x - a); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -6.5e+14) tmp = x - a; elseif (z <= -3.8e-29) tmp = x + (z * (a / t)); elseif (z <= 1.86e+71) tmp = x - (y * a); else tmp = x - a; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -6.5e+14], N[(x - a), $MachinePrecision], If[LessEqual[z, -3.8e-29], N[(x + N[(z * N[(a / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.86e+71], N[(x - N[(y * a), $MachinePrecision]), $MachinePrecision], N[(x - a), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -6.5 \cdot 10^{+14}:\\
\;\;\;\;x - a\\
\mathbf{elif}\;z \leq -3.8 \cdot 10^{-29}:\\
\;\;\;\;x + z \cdot \frac{a}{t}\\
\mathbf{elif}\;z \leq 1.86 \cdot 10^{+71}:\\
\;\;\;\;x - y \cdot a\\
\mathbf{else}:\\
\;\;\;\;x - a\\
\end{array}
\end{array}
(FPCore (x y z t a) :precision binary64 (if (or (<= z -1.6e-28) (not (<= z 2.9e+71))) (- x a) (- x (* y a))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -1.6e-28) || !(z <= 2.9e+71)) {
tmp = x - a;
} else {
tmp = x - (y * 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 <= (-1.6d-28)) .or. (.not. (z <= 2.9d+71))) then
tmp = x - a
else
tmp = x - (y * 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 <= -1.6e-28) || !(z <= 2.9e+71)) {
tmp = x - a;
} else {
tmp = x - (y * a);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (z <= -1.6e-28) or not (z <= 2.9e+71): tmp = x - a else: tmp = x - (y * a) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((z <= -1.6e-28) || !(z <= 2.9e+71)) tmp = Float64(x - a); else tmp = Float64(x - Float64(y * a)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((z <= -1.6e-28) || ~((z <= 2.9e+71))) tmp = x - a; else tmp = x - (y * a); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[z, -1.6e-28], N[Not[LessEqual[z, 2.9e+71]], $MachinePrecision]], N[(x - a), $MachinePrecision], N[(x - N[(y * a), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.6 \cdot 10^{-28} \lor \neg \left(z \leq 2.9 \cdot 10^{+71}\right):\\
\;\;\;\;x - a\\
\mathbf{else}:\\
\;\;\;\;x - y \cdot a\\
\end{array}
\end{array}
(FPCore (x y z t a) :precision binary64 (if (or (<= z -4.4e-6) (not (<= z 1.05e+79))) (- x a) x))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -4.4e-6) || !(z <= 1.05e+79)) {
tmp = x - a;
} 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 ((z <= (-4.4d-6)) .or. (.not. (z <= 1.05d+79))) then
tmp = x - a
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 ((z <= -4.4e-6) || !(z <= 1.05e+79)) {
tmp = x - a;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (z <= -4.4e-6) or not (z <= 1.05e+79): tmp = x - a else: tmp = x return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((z <= -4.4e-6) || !(z <= 1.05e+79)) tmp = Float64(x - a); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((z <= -4.4e-6) || ~((z <= 1.05e+79))) tmp = x - a; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[z, -4.4e-6], N[Not[LessEqual[z, 1.05e+79]], $MachinePrecision]], N[(x - a), $MachinePrecision], x]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -4.4 \cdot 10^{-6} \lor \neg \left(z \leq 1.05 \cdot 10^{+79}\right):\\
\;\;\;\;x - a\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
(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}
(FPCore (x y z t a) :precision binary64 (- x (* (/ (- y z) (+ (- t z) 1.0)) a)))
double code(double x, double y, double z, double t, double a) {
return x - (((y - z) / ((t - z) + 1.0)) * a);
}
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 - z) + 1.0d0)) * a)
end function
public static double code(double x, double y, double z, double t, double a) {
return x - (((y - z) / ((t - z) + 1.0)) * a);
}
def code(x, y, z, t, a): return x - (((y - z) / ((t - z) + 1.0)) * a)
function code(x, y, z, t, a) return Float64(x - Float64(Float64(Float64(y - z) / Float64(Float64(t - z) + 1.0)) * a)) end
function tmp = code(x, y, z, t, a) tmp = x - (((y - z) / ((t - z) + 1.0)) * a); end
code[x_, y_, z_, t_, a_] := N[(x - N[(N[(N[(y - z), $MachinePrecision] / N[(N[(t - z), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x - \frac{y - z}{\left(t - z\right) + 1} \cdot a
\end{array}
herbie shell --seed 2023350
(FPCore (x y z t a)
:name "Graphics.Rendering.Chart.SparkLine:renderSparkLine from Chart-1.5.3"
:precision binary64
:herbie-target
(- x (* (/ (- y z) (+ (- t z) 1.0)) a))
(- x (/ (- y z) (/ (+ (- t z) 1.0) a))))