
(FPCore (x y z t a) :precision binary64 (+ x (/ (* (- y x) (- z t)) (- a t))))
double code(double x, double y, double z, double t, double a) {
return x + (((y - x) * (z - t)) / (a - t));
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = x + (((y - x) * (z - t)) / (a - t))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + (((y - x) * (z - t)) / (a - t));
}
def code(x, y, z, t, a): return x + (((y - x) * (z - t)) / (a - t))
function code(x, y, z, t, a) return Float64(x + Float64(Float64(Float64(y - x) * Float64(z - t)) / Float64(a - t))) end
function tmp = code(x, y, z, t, a) tmp = x + (((y - x) * (z - t)) / (a - t)); end
code[x_, y_, z_, t_, a_] := N[(x + N[(N[(N[(y - x), $MachinePrecision] * N[(z - t), $MachinePrecision]), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 18 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a) :precision binary64 (+ x (/ (* (- y x) (- z t)) (- a t))))
double code(double x, double y, double z, double t, double a) {
return x + (((y - x) * (z - t)) / (a - t));
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = x + (((y - x) * (z - t)) / (a - t))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + (((y - x) * (z - t)) / (a - t));
}
def code(x, y, z, t, a): return x + (((y - x) * (z - t)) / (a - t))
function code(x, y, z, t, a) return Float64(x + Float64(Float64(Float64(y - x) * Float64(z - t)) / Float64(a - t))) end
function tmp = code(x, y, z, t, a) tmp = x + (((y - x) * (z - t)) / (a - t)); end
code[x_, y_, z_, t_, a_] := N[(x + N[(N[(N[(y - x), $MachinePrecision] * N[(z - t), $MachinePrecision]), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}
\end{array}
(FPCore (x y z t a) :precision binary64 (if (or (<= t -4.9e+119) (not (<= t 3.8e+264))) (+ y (/ -1.0 (/ (/ t (- y x)) (- z a)))) (fma (- y x) (/ (- z t) (- a t)) x)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -4.9e+119) || !(t <= 3.8e+264)) {
tmp = y + (-1.0 / ((t / (y - x)) / (z - a)));
} else {
tmp = fma((y - x), ((z - t) / (a - t)), x);
}
return tmp;
}
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -4.9e+119) || !(t <= 3.8e+264)) tmp = Float64(y + Float64(-1.0 / Float64(Float64(t / Float64(y - x)) / Float64(z - a)))); else tmp = fma(Float64(y - x), Float64(Float64(z - t) / Float64(a - t)), x); end return tmp end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -4.9e+119], N[Not[LessEqual[t, 3.8e+264]], $MachinePrecision]], N[(y + N[(-1.0 / N[(N[(t / N[(y - x), $MachinePrecision]), $MachinePrecision] / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y - x), $MachinePrecision] * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.9 \cdot 10^{+119} \lor \neg \left(t \leq 3.8 \cdot 10^{+264}\right):\\
\;\;\;\;y + \frac{-1}{\frac{\frac{t}{y - x}}{z - a}}\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(y - x, \frac{z - t}{a - t}, x\right)\\
\end{array}
\end{array}
if t < -4.89999999999999996e119 or 3.8000000000000001e264 < t Initial program 37.0%
+-commutative37.0%
associate-/l*62.4%
fma-define62.3%
Simplified62.3%
Taylor expanded in t around inf 75.8%
associate--l+75.8%
associate-*r/75.8%
associate-*r/75.8%
mul-1-neg75.8%
div-sub75.8%
mul-1-neg75.8%
distribute-lft-out--75.8%
associate-*r/75.8%
mul-1-neg75.8%
unsub-neg75.8%
distribute-rgt-out--75.8%
Simplified75.8%
clear-num75.7%
inv-pow75.7%
Applied egg-rr75.7%
unpow-175.7%
associate-/r*92.4%
Simplified92.4%
if -4.89999999999999996e119 < t < 3.8000000000000001e264Initial program 82.7%
+-commutative82.7%
associate-/l*93.1%
fma-define93.1%
Simplified93.1%
Final simplification93.0%
(FPCore (x y z t a)
:precision binary64
(if (<= t -1.16e+107)
(* y (- 1.0 (/ z t)))
(if (<= t 2.4e-30)
(+ x (* y (/ (- z t) a)))
(if (<= t 7.1e+83) (* z (/ (- y x) (- a t))) (* y (/ t (- t a)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -1.16e+107) {
tmp = y * (1.0 - (z / t));
} else if (t <= 2.4e-30) {
tmp = x + (y * ((z - t) / a));
} else if (t <= 7.1e+83) {
tmp = z * ((y - x) / (a - t));
} else {
tmp = y * (t / (t - a));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (t <= (-1.16d+107)) then
tmp = y * (1.0d0 - (z / t))
else if (t <= 2.4d-30) then
tmp = x + (y * ((z - t) / a))
else if (t <= 7.1d+83) then
tmp = z * ((y - x) / (a - t))
else
tmp = y * (t / (t - a))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -1.16e+107) {
tmp = y * (1.0 - (z / t));
} else if (t <= 2.4e-30) {
tmp = x + (y * ((z - t) / a));
} else if (t <= 7.1e+83) {
tmp = z * ((y - x) / (a - t));
} else {
tmp = y * (t / (t - a));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -1.16e+107: tmp = y * (1.0 - (z / t)) elif t <= 2.4e-30: tmp = x + (y * ((z - t) / a)) elif t <= 7.1e+83: tmp = z * ((y - x) / (a - t)) else: tmp = y * (t / (t - a)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -1.16e+107) tmp = Float64(y * Float64(1.0 - Float64(z / t))); elseif (t <= 2.4e-30) tmp = Float64(x + Float64(y * Float64(Float64(z - t) / a))); elseif (t <= 7.1e+83) tmp = Float64(z * Float64(Float64(y - x) / Float64(a - t))); else tmp = Float64(y * Float64(t / Float64(t - a))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -1.16e+107) tmp = y * (1.0 - (z / t)); elseif (t <= 2.4e-30) tmp = x + (y * ((z - t) / a)); elseif (t <= 7.1e+83) tmp = z * ((y - x) / (a - t)); else tmp = y * (t / (t - a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -1.16e+107], N[(y * N[(1.0 - N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.4e-30], N[(x + N[(y * N[(N[(z - t), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 7.1e+83], N[(z * N[(N[(y - x), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y * N[(t / N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.16 \cdot 10^{+107}:\\
\;\;\;\;y \cdot \left(1 - \frac{z}{t}\right)\\
\mathbf{elif}\;t \leq 2.4 \cdot 10^{-30}:\\
\;\;\;\;x + y \cdot \frac{z - t}{a}\\
\mathbf{elif}\;t \leq 7.1 \cdot 10^{+83}:\\
\;\;\;\;z \cdot \frac{y - x}{a - t}\\
\mathbf{else}:\\
\;\;\;\;y \cdot \frac{t}{t - a}\\
\end{array}
\end{array}
if t < -1.1600000000000001e107Initial program 45.2%
+-commutative45.2%
associate-/l*64.2%
fma-define64.1%
Simplified64.1%
Taylor expanded in y around inf 71.3%
Taylor expanded in a around 0 66.7%
associate-*r/66.7%
neg-mul-166.7%
Simplified66.7%
if -1.1600000000000001e107 < t < 2.39999999999999985e-30Initial program 91.2%
Taylor expanded in a around inf 73.2%
associate-/l*78.2%
Simplified78.2%
Taylor expanded in y around inf 64.5%
associate-/l*69.3%
Simplified69.3%
if 2.39999999999999985e-30 < t < 7.10000000000000004e83Initial program 80.1%
+-commutative80.1%
associate-/l*84.4%
fma-define84.4%
Simplified84.4%
clear-num84.3%
associate-/r/84.4%
Applied egg-rr84.4%
Taylor expanded in z around inf 66.6%
div-sub66.6%
Simplified66.6%
if 7.10000000000000004e83 < t Initial program 36.4%
+-commutative36.4%
associate-/l*74.9%
fma-define74.9%
Simplified74.9%
Taylor expanded in y around inf 75.4%
sub-div75.4%
*-un-lft-identity75.4%
associate-*l/75.2%
Applied egg-rr75.2%
Taylor expanded in z around 0 63.8%
neg-mul-163.8%
distribute-neg-frac63.8%
Simplified63.8%
Final simplification67.7%
(FPCore (x y z t a)
:precision binary64
(if (<= t -1.05e+52)
(* y (- 1.0 (/ z t)))
(if (<= t 3.7e-31)
(+ x (* y (/ z a)))
(if (<= t 7.8e+83) (* z (/ (- y x) (- a t))) (* y (/ t (- t a)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -1.05e+52) {
tmp = y * (1.0 - (z / t));
} else if (t <= 3.7e-31) {
tmp = x + (y * (z / a));
} else if (t <= 7.8e+83) {
tmp = z * ((y - x) / (a - t));
} else {
tmp = y * (t / (t - a));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (t <= (-1.05d+52)) then
tmp = y * (1.0d0 - (z / t))
else if (t <= 3.7d-31) then
tmp = x + (y * (z / a))
else if (t <= 7.8d+83) then
tmp = z * ((y - x) / (a - t))
else
tmp = y * (t / (t - a))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -1.05e+52) {
tmp = y * (1.0 - (z / t));
} else if (t <= 3.7e-31) {
tmp = x + (y * (z / a));
} else if (t <= 7.8e+83) {
tmp = z * ((y - x) / (a - t));
} else {
tmp = y * (t / (t - a));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -1.05e+52: tmp = y * (1.0 - (z / t)) elif t <= 3.7e-31: tmp = x + (y * (z / a)) elif t <= 7.8e+83: tmp = z * ((y - x) / (a - t)) else: tmp = y * (t / (t - a)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -1.05e+52) tmp = Float64(y * Float64(1.0 - Float64(z / t))); elseif (t <= 3.7e-31) tmp = Float64(x + Float64(y * Float64(z / a))); elseif (t <= 7.8e+83) tmp = Float64(z * Float64(Float64(y - x) / Float64(a - t))); else tmp = Float64(y * Float64(t / Float64(t - a))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -1.05e+52) tmp = y * (1.0 - (z / t)); elseif (t <= 3.7e-31) tmp = x + (y * (z / a)); elseif (t <= 7.8e+83) tmp = z * ((y - x) / (a - t)); else tmp = y * (t / (t - a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -1.05e+52], N[(y * N[(1.0 - N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 3.7e-31], N[(x + N[(y * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 7.8e+83], N[(z * N[(N[(y - x), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y * N[(t / N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.05 \cdot 10^{+52}:\\
\;\;\;\;y \cdot \left(1 - \frac{z}{t}\right)\\
\mathbf{elif}\;t \leq 3.7 \cdot 10^{-31}:\\
\;\;\;\;x + y \cdot \frac{z}{a}\\
\mathbf{elif}\;t \leq 7.8 \cdot 10^{+83}:\\
\;\;\;\;z \cdot \frac{y - x}{a - t}\\
\mathbf{else}:\\
\;\;\;\;y \cdot \frac{t}{t - a}\\
\end{array}
\end{array}
if t < -1.05e52Initial program 50.8%
+-commutative50.8%
associate-/l*69.7%
fma-define69.7%
Simplified69.7%
Taylor expanded in y around inf 68.4%
Taylor expanded in a around 0 61.3%
associate-*r/61.3%
neg-mul-161.3%
Simplified61.3%
if -1.05e52 < t < 3.6999999999999998e-31Initial program 92.6%
Taylor expanded in a around inf 76.1%
associate-/l*80.7%
Simplified80.7%
Taylor expanded in y around inf 66.8%
associate-/l*71.2%
Simplified71.2%
Taylor expanded in t around 0 64.2%
associate-/l*68.0%
Simplified68.0%
if 3.6999999999999998e-31 < t < 7.8000000000000003e83Initial program 80.1%
+-commutative80.1%
associate-/l*84.4%
fma-define84.4%
Simplified84.4%
clear-num84.3%
associate-/r/84.4%
Applied egg-rr84.4%
Taylor expanded in z around inf 66.6%
div-sub66.6%
Simplified66.6%
if 7.8000000000000003e83 < t Initial program 36.4%
+-commutative36.4%
associate-/l*74.9%
fma-define74.9%
Simplified74.9%
Taylor expanded in y around inf 75.4%
sub-div75.4%
*-un-lft-identity75.4%
associate-*l/75.2%
Applied egg-rr75.2%
Taylor expanded in z around 0 63.8%
neg-mul-163.8%
distribute-neg-frac63.8%
Simplified63.8%
Final simplification65.9%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -5.1e+103) (not (<= t 1.35e+117))) (+ y (/ -1.0 (/ (/ t (- y x)) (- z a)))) (+ x (/ (* (- y x) (- z t)) (- a t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -5.1e+103) || !(t <= 1.35e+117)) {
tmp = y + (-1.0 / ((t / (y - x)) / (z - a)));
} else {
tmp = x + (((y - x) * (z - t)) / (a - t));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((t <= (-5.1d+103)) .or. (.not. (t <= 1.35d+117))) then
tmp = y + ((-1.0d0) / ((t / (y - x)) / (z - a)))
else
tmp = x + (((y - x) * (z - t)) / (a - t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -5.1e+103) || !(t <= 1.35e+117)) {
tmp = y + (-1.0 / ((t / (y - x)) / (z - a)));
} else {
tmp = x + (((y - x) * (z - t)) / (a - t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -5.1e+103) or not (t <= 1.35e+117): tmp = y + (-1.0 / ((t / (y - x)) / (z - a))) else: tmp = x + (((y - x) * (z - t)) / (a - t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -5.1e+103) || !(t <= 1.35e+117)) tmp = Float64(y + Float64(-1.0 / Float64(Float64(t / Float64(y - x)) / Float64(z - a)))); else tmp = Float64(x + Float64(Float64(Float64(y - x) * Float64(z - t)) / Float64(a - t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -5.1e+103) || ~((t <= 1.35e+117))) tmp = y + (-1.0 / ((t / (y - x)) / (z - a))); else tmp = x + (((y - x) * (z - t)) / (a - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -5.1e+103], N[Not[LessEqual[t, 1.35e+117]], $MachinePrecision]], N[(y + N[(-1.0 / N[(N[(t / N[(y - x), $MachinePrecision]), $MachinePrecision] / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(N[(y - x), $MachinePrecision] * N[(z - t), $MachinePrecision]), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -5.1 \cdot 10^{+103} \lor \neg \left(t \leq 1.35 \cdot 10^{+117}\right):\\
\;\;\;\;y + \frac{-1}{\frac{\frac{t}{y - x}}{z - a}}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}\\
\end{array}
\end{array}
if t < -5.1000000000000002e103 or 1.3500000000000001e117 < t Initial program 38.3%
+-commutative38.3%
associate-/l*69.2%
fma-define69.2%
Simplified69.2%
Taylor expanded in t around inf 67.9%
associate--l+67.9%
associate-*r/67.9%
associate-*r/67.9%
mul-1-neg67.9%
div-sub67.9%
mul-1-neg67.9%
distribute-lft-out--67.9%
associate-*r/67.9%
mul-1-neg67.9%
unsub-neg67.9%
distribute-rgt-out--67.9%
Simplified67.9%
clear-num67.9%
inv-pow67.9%
Applied egg-rr67.9%
unpow-167.9%
associate-/r*83.9%
Simplified83.9%
if -5.1000000000000002e103 < t < 1.3500000000000001e117Initial program 89.9%
Final simplification88.0%
(FPCore (x y z t a)
:precision binary64
(if (<= t -3.2e+145)
(- y (/ (* x (- a z)) t))
(if (<= t 3e+82)
(+ x (/ (* (- y x) (- z t)) (- a t)))
(* y (/ -1.0 (/ (- a t) (- t z)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -3.2e+145) {
tmp = y - ((x * (a - z)) / t);
} else if (t <= 3e+82) {
tmp = x + (((y - x) * (z - t)) / (a - t));
} else {
tmp = y * (-1.0 / ((a - t) / (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.2d+145)) then
tmp = y - ((x * (a - z)) / t)
else if (t <= 3d+82) then
tmp = x + (((y - x) * (z - t)) / (a - t))
else
tmp = y * ((-1.0d0) / ((a - t) / (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.2e+145) {
tmp = y - ((x * (a - z)) / t);
} else if (t <= 3e+82) {
tmp = x + (((y - x) * (z - t)) / (a - t));
} else {
tmp = y * (-1.0 / ((a - t) / (t - z)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -3.2e+145: tmp = y - ((x * (a - z)) / t) elif t <= 3e+82: tmp = x + (((y - x) * (z - t)) / (a - t)) else: tmp = y * (-1.0 / ((a - t) / (t - z))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -3.2e+145) tmp = Float64(y - Float64(Float64(x * Float64(a - z)) / t)); elseif (t <= 3e+82) tmp = Float64(x + Float64(Float64(Float64(y - x) * Float64(z - t)) / Float64(a - t))); else tmp = Float64(y * Float64(-1.0 / Float64(Float64(a - t) / Float64(t - z)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -3.2e+145) tmp = y - ((x * (a - z)) / t); elseif (t <= 3e+82) tmp = x + (((y - x) * (z - t)) / (a - t)); else tmp = y * (-1.0 / ((a - t) / (t - z))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -3.2e+145], N[(y - N[(N[(x * N[(a - z), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 3e+82], N[(x + N[(N[(N[(y - x), $MachinePrecision] * N[(z - t), $MachinePrecision]), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y * N[(-1.0 / N[(N[(a - t), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.2 \cdot 10^{+145}:\\
\;\;\;\;y - \frac{x \cdot \left(a - z\right)}{t}\\
\mathbf{elif}\;t \leq 3 \cdot 10^{+82}:\\
\;\;\;\;x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}\\
\mathbf{else}:\\
\;\;\;\;y \cdot \frac{-1}{\frac{a - t}{t - z}}\\
\end{array}
\end{array}
if t < -3.20000000000000008e145Initial program 43.8%
+-commutative43.8%
associate-/l*66.5%
fma-define66.5%
Simplified66.5%
Taylor expanded in t around inf 79.4%
associate--l+79.4%
associate-*r/79.4%
associate-*r/79.4%
mul-1-neg79.4%
div-sub79.4%
mul-1-neg79.4%
distribute-lft-out--79.4%
associate-*r/79.4%
mul-1-neg79.4%
unsub-neg79.4%
distribute-rgt-out--79.4%
Simplified79.4%
Taylor expanded in y around 0 84.8%
mul-1-neg84.8%
*-commutative84.8%
distribute-rgt-neg-in84.8%
Simplified84.8%
if -3.20000000000000008e145 < t < 2.99999999999999989e82Initial program 88.5%
if 2.99999999999999989e82 < t Initial program 37.7%
+-commutative37.7%
associate-/l*75.5%
fma-define75.5%
Simplified75.5%
Taylor expanded in y around inf 75.9%
sub-div75.9%
*-un-lft-identity75.9%
associate-*l/75.7%
Applied egg-rr75.7%
associate-*l/75.9%
*-un-lft-identity75.9%
clear-num75.9%
Applied egg-rr75.9%
Final simplification85.8%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -3.8e-104) (not (<= a 8.2e-19))) (+ x (* (- y x) (/ (- z t) a))) (+ y (* z (/ (- x y) t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -3.8e-104) || !(a <= 8.2e-19)) {
tmp = x + ((y - x) * ((z - t) / a));
} else {
tmp = y + (z * ((x - 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 ((a <= (-3.8d-104)) .or. (.not. (a <= 8.2d-19))) then
tmp = x + ((y - x) * ((z - t) / a))
else
tmp = y + (z * ((x - 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 ((a <= -3.8e-104) || !(a <= 8.2e-19)) {
tmp = x + ((y - x) * ((z - t) / a));
} else {
tmp = y + (z * ((x - y) / t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -3.8e-104) or not (a <= 8.2e-19): tmp = x + ((y - x) * ((z - t) / a)) else: tmp = y + (z * ((x - y) / t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -3.8e-104) || !(a <= 8.2e-19)) tmp = Float64(x + Float64(Float64(y - x) * Float64(Float64(z - t) / a))); else tmp = Float64(y + Float64(z * Float64(Float64(x - y) / t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a <= -3.8e-104) || ~((a <= 8.2e-19))) tmp = x + ((y - x) * ((z - t) / a)); else tmp = y + (z * ((x - y) / t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -3.8e-104], N[Not[LessEqual[a, 8.2e-19]], $MachinePrecision]], N[(x + N[(N[(y - x), $MachinePrecision] * N[(N[(z - t), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y + N[(z * N[(N[(x - y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -3.8 \cdot 10^{-104} \lor \neg \left(a \leq 8.2 \cdot 10^{-19}\right):\\
\;\;\;\;x + \left(y - x\right) \cdot \frac{z - t}{a}\\
\mathbf{else}:\\
\;\;\;\;y + z \cdot \frac{x - y}{t}\\
\end{array}
\end{array}
if a < -3.8000000000000001e-104 or 8.1999999999999997e-19 < a Initial program 77.5%
Taylor expanded in a around inf 67.4%
associate-/l*75.2%
Simplified75.2%
if -3.8000000000000001e-104 < a < 8.1999999999999997e-19Initial program 68.2%
+-commutative68.2%
associate-/l*80.0%
fma-define80.1%
Simplified80.1%
Taylor expanded in t around inf 79.0%
associate--l+79.0%
associate-*r/79.0%
associate-*r/79.0%
mul-1-neg79.0%
div-sub80.9%
mul-1-neg80.9%
distribute-lft-out--80.9%
associate-*r/80.9%
mul-1-neg80.9%
unsub-neg80.9%
distribute-rgt-out--80.9%
Simplified80.9%
Taylor expanded in z around inf 78.2%
associate-/l*79.4%
Simplified79.4%
Final simplification76.9%
(FPCore (x y z t a)
:precision binary64
(if (<= a -1.55e-103)
(+ x (* (- y x) (/ (- z t) a)))
(if (<= a 1.35e-25)
(- y (/ (* (- y x) (- z a)) t))
(+ x (* (- z t) (/ y (- a t)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -1.55e-103) {
tmp = x + ((y - x) * ((z - t) / a));
} else if (a <= 1.35e-25) {
tmp = y - (((y - x) * (z - a)) / t);
} else {
tmp = x + ((z - t) * (y / (a - t)));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (a <= (-1.55d-103)) then
tmp = x + ((y - x) * ((z - t) / a))
else if (a <= 1.35d-25) then
tmp = y - (((y - x) * (z - a)) / t)
else
tmp = x + ((z - t) * (y / (a - t)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -1.55e-103) {
tmp = x + ((y - x) * ((z - t) / a));
} else if (a <= 1.35e-25) {
tmp = y - (((y - x) * (z - a)) / t);
} else {
tmp = x + ((z - t) * (y / (a - t)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -1.55e-103: tmp = x + ((y - x) * ((z - t) / a)) elif a <= 1.35e-25: tmp = y - (((y - x) * (z - a)) / t) else: tmp = x + ((z - t) * (y / (a - t))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -1.55e-103) tmp = Float64(x + Float64(Float64(y - x) * Float64(Float64(z - t) / a))); elseif (a <= 1.35e-25) tmp = Float64(y - Float64(Float64(Float64(y - x) * Float64(z - a)) / t)); else tmp = Float64(x + Float64(Float64(z - t) * Float64(y / Float64(a - t)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -1.55e-103) tmp = x + ((y - x) * ((z - t) / a)); elseif (a <= 1.35e-25) tmp = y - (((y - x) * (z - a)) / t); else tmp = x + ((z - t) * (y / (a - t))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -1.55e-103], N[(x + N[(N[(y - x), $MachinePrecision] * N[(N[(z - t), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.35e-25], N[(y - N[(N[(N[(y - x), $MachinePrecision] * N[(z - a), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(z - t), $MachinePrecision] * N[(y / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.55 \cdot 10^{-103}:\\
\;\;\;\;x + \left(y - x\right) \cdot \frac{z - t}{a}\\
\mathbf{elif}\;a \leq 1.35 \cdot 10^{-25}:\\
\;\;\;\;y - \frac{\left(y - x\right) \cdot \left(z - a\right)}{t}\\
\mathbf{else}:\\
\;\;\;\;x + \left(z - t\right) \cdot \frac{y}{a - t}\\
\end{array}
\end{array}
if a < -1.5500000000000001e-103Initial program 81.6%
Taylor expanded in a around inf 72.3%
associate-/l*78.2%
Simplified78.2%
if -1.5500000000000001e-103 < a < 1.35000000000000008e-25Initial program 67.9%
+-commutative67.9%
associate-/l*79.8%
fma-define79.9%
Simplified79.9%
Taylor expanded in t around inf 78.8%
associate--l+78.8%
associate-*r/78.8%
associate-*r/78.8%
mul-1-neg78.8%
div-sub80.7%
mul-1-neg80.7%
distribute-lft-out--80.7%
associate-*r/80.7%
mul-1-neg80.7%
unsub-neg80.7%
distribute-rgt-out--80.7%
Simplified80.7%
if 1.35000000000000008e-25 < a Initial program 72.0%
Taylor expanded in y around inf 67.5%
*-commutative67.5%
*-lft-identity67.5%
times-frac79.9%
/-rgt-identity79.9%
Simplified79.9%
(FPCore (x y z t a)
:precision binary64
(if (<= a -3.15e-105)
(+ x (* (- y x) (/ (- z t) a)))
(if (<= a 3.5e-26)
(+ y (* z (/ (- x y) t)))
(+ x (* (- z t) (/ y (- a t)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -3.15e-105) {
tmp = x + ((y - x) * ((z - t) / a));
} else if (a <= 3.5e-26) {
tmp = y + (z * ((x - y) / t));
} else {
tmp = x + ((z - t) * (y / (a - t)));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (a <= (-3.15d-105)) then
tmp = x + ((y - x) * ((z - t) / a))
else if (a <= 3.5d-26) then
tmp = y + (z * ((x - y) / t))
else
tmp = x + ((z - t) * (y / (a - t)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -3.15e-105) {
tmp = x + ((y - x) * ((z - t) / a));
} else if (a <= 3.5e-26) {
tmp = y + (z * ((x - y) / t));
} else {
tmp = x + ((z - t) * (y / (a - t)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -3.15e-105: tmp = x + ((y - x) * ((z - t) / a)) elif a <= 3.5e-26: tmp = y + (z * ((x - y) / t)) else: tmp = x + ((z - t) * (y / (a - t))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -3.15e-105) tmp = Float64(x + Float64(Float64(y - x) * Float64(Float64(z - t) / a))); elseif (a <= 3.5e-26) tmp = Float64(y + Float64(z * Float64(Float64(x - y) / t))); else tmp = Float64(x + Float64(Float64(z - t) * Float64(y / Float64(a - t)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -3.15e-105) tmp = x + ((y - x) * ((z - t) / a)); elseif (a <= 3.5e-26) tmp = y + (z * ((x - y) / t)); else tmp = x + ((z - t) * (y / (a - t))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -3.15e-105], N[(x + N[(N[(y - x), $MachinePrecision] * N[(N[(z - t), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 3.5e-26], N[(y + N[(z * N[(N[(x - y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(z - t), $MachinePrecision] * N[(y / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -3.15 \cdot 10^{-105}:\\
\;\;\;\;x + \left(y - x\right) \cdot \frac{z - t}{a}\\
\mathbf{elif}\;a \leq 3.5 \cdot 10^{-26}:\\
\;\;\;\;y + z \cdot \frac{x - y}{t}\\
\mathbf{else}:\\
\;\;\;\;x + \left(z - t\right) \cdot \frac{y}{a - t}\\
\end{array}
\end{array}
if a < -3.15e-105Initial program 81.6%
Taylor expanded in a around inf 72.3%
associate-/l*78.2%
Simplified78.2%
if -3.15e-105 < a < 3.49999999999999985e-26Initial program 67.9%
+-commutative67.9%
associate-/l*79.8%
fma-define79.9%
Simplified79.9%
Taylor expanded in t around inf 78.8%
associate--l+78.8%
associate-*r/78.8%
associate-*r/78.8%
mul-1-neg78.8%
div-sub80.7%
mul-1-neg80.7%
distribute-lft-out--80.7%
associate-*r/80.7%
mul-1-neg80.7%
unsub-neg80.7%
distribute-rgt-out--80.7%
Simplified80.7%
Taylor expanded in z around inf 78.0%
associate-/l*79.2%
Simplified79.2%
if 3.49999999999999985e-26 < a Initial program 72.0%
Taylor expanded in y around inf 67.5%
*-commutative67.5%
*-lft-identity67.5%
times-frac79.9%
/-rgt-identity79.9%
Simplified79.9%
Final simplification79.0%
(FPCore (x y z t a)
:precision binary64
(if (<= t -1500000.0)
(+ y (* z (/ (- x y) t)))
(if (<= t 4e+45)
(+ x (* (- y x) (/ z a)))
(* y (/ -1.0 (/ (- a t) (- t z)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -1500000.0) {
tmp = y + (z * ((x - y) / t));
} else if (t <= 4e+45) {
tmp = x + ((y - x) * (z / a));
} else {
tmp = y * (-1.0 / ((a - t) / (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 <= (-1500000.0d0)) then
tmp = y + (z * ((x - y) / t))
else if (t <= 4d+45) then
tmp = x + ((y - x) * (z / a))
else
tmp = y * ((-1.0d0) / ((a - t) / (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 <= -1500000.0) {
tmp = y + (z * ((x - y) / t));
} else if (t <= 4e+45) {
tmp = x + ((y - x) * (z / a));
} else {
tmp = y * (-1.0 / ((a - t) / (t - z)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -1500000.0: tmp = y + (z * ((x - y) / t)) elif t <= 4e+45: tmp = x + ((y - x) * (z / a)) else: tmp = y * (-1.0 / ((a - t) / (t - z))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -1500000.0) tmp = Float64(y + Float64(z * Float64(Float64(x - y) / t))); elseif (t <= 4e+45) tmp = Float64(x + Float64(Float64(y - x) * Float64(z / a))); else tmp = Float64(y * Float64(-1.0 / Float64(Float64(a - t) / Float64(t - z)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -1500000.0) tmp = y + (z * ((x - y) / t)); elseif (t <= 4e+45) tmp = x + ((y - x) * (z / a)); else tmp = y * (-1.0 / ((a - t) / (t - z))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -1500000.0], N[(y + N[(z * N[(N[(x - y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 4e+45], N[(x + N[(N[(y - x), $MachinePrecision] * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y * N[(-1.0 / N[(N[(a - t), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1500000:\\
\;\;\;\;y + z \cdot \frac{x - y}{t}\\
\mathbf{elif}\;t \leq 4 \cdot 10^{+45}:\\
\;\;\;\;x + \left(y - x\right) \cdot \frac{z}{a}\\
\mathbf{else}:\\
\;\;\;\;y \cdot \frac{-1}{\frac{a - t}{t - z}}\\
\end{array}
\end{array}
if t < -1.5e6Initial program 50.0%
+-commutative50.0%
associate-/l*70.8%
fma-define70.8%
Simplified70.8%
Taylor expanded in t around inf 68.8%
associate--l+68.8%
associate-*r/68.8%
associate-*r/68.8%
mul-1-neg68.8%
div-sub68.8%
mul-1-neg68.8%
distribute-lft-out--68.8%
associate-*r/68.8%
mul-1-neg68.8%
unsub-neg68.8%
distribute-rgt-out--68.9%
Simplified68.9%
Taylor expanded in z around inf 65.3%
associate-/l*70.3%
Simplified70.3%
if -1.5e6 < t < 3.9999999999999997e45Initial program 92.8%
Taylor expanded in a around inf 75.4%
associate-/l*79.1%
Simplified79.1%
Taylor expanded in z around inf 77.0%
if 3.9999999999999997e45 < t Initial program 44.0%
+-commutative44.0%
associate-/l*76.8%
fma-define76.8%
Simplified76.8%
Taylor expanded in y around inf 73.9%
sub-div73.9%
*-un-lft-identity73.9%
associate-*l/73.8%
Applied egg-rr73.8%
associate-*l/73.9%
*-un-lft-identity73.9%
clear-num73.9%
Applied egg-rr73.9%
Final simplification75.0%
(FPCore (x y z t a)
:precision binary64
(if (<= t -80000000000000.0)
(+ y (* z (/ (- x y) t)))
(if (<= t 2.3e+43)
(+ x (* (- y x) (/ z a)))
(* y (* (- z t) (/ -1.0 (- t a)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -80000000000000.0) {
tmp = y + (z * ((x - y) / t));
} else if (t <= 2.3e+43) {
tmp = x + ((y - x) * (z / a));
} else {
tmp = y * ((z - t) * (-1.0 / (t - a)));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (t <= (-80000000000000.0d0)) then
tmp = y + (z * ((x - y) / t))
else if (t <= 2.3d+43) then
tmp = x + ((y - x) * (z / a))
else
tmp = y * ((z - t) * ((-1.0d0) / (t - a)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -80000000000000.0) {
tmp = y + (z * ((x - y) / t));
} else if (t <= 2.3e+43) {
tmp = x + ((y - x) * (z / a));
} else {
tmp = y * ((z - t) * (-1.0 / (t - a)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -80000000000000.0: tmp = y + (z * ((x - y) / t)) elif t <= 2.3e+43: tmp = x + ((y - x) * (z / a)) else: tmp = y * ((z - t) * (-1.0 / (t - a))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -80000000000000.0) tmp = Float64(y + Float64(z * Float64(Float64(x - y) / t))); elseif (t <= 2.3e+43) tmp = Float64(x + Float64(Float64(y - x) * Float64(z / a))); else tmp = Float64(y * Float64(Float64(z - t) * Float64(-1.0 / Float64(t - a)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -80000000000000.0) tmp = y + (z * ((x - y) / t)); elseif (t <= 2.3e+43) tmp = x + ((y - x) * (z / a)); else tmp = y * ((z - t) * (-1.0 / (t - a))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -80000000000000.0], N[(y + N[(z * N[(N[(x - y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.3e+43], N[(x + N[(N[(y - x), $MachinePrecision] * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y * N[(N[(z - t), $MachinePrecision] * N[(-1.0 / N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -80000000000000:\\
\;\;\;\;y + z \cdot \frac{x - y}{t}\\
\mathbf{elif}\;t \leq 2.3 \cdot 10^{+43}:\\
\;\;\;\;x + \left(y - x\right) \cdot \frac{z}{a}\\
\mathbf{else}:\\
\;\;\;\;y \cdot \left(\left(z - t\right) \cdot \frac{-1}{t - a}\right)\\
\end{array}
\end{array}
if t < -8e13Initial program 50.0%
+-commutative50.0%
associate-/l*70.8%
fma-define70.8%
Simplified70.8%
Taylor expanded in t around inf 68.8%
associate--l+68.8%
associate-*r/68.8%
associate-*r/68.8%
mul-1-neg68.8%
div-sub68.8%
mul-1-neg68.8%
distribute-lft-out--68.8%
associate-*r/68.8%
mul-1-neg68.8%
unsub-neg68.8%
distribute-rgt-out--68.9%
Simplified68.9%
Taylor expanded in z around inf 65.3%
associate-/l*70.3%
Simplified70.3%
if -8e13 < t < 2.3000000000000002e43Initial program 92.8%
Taylor expanded in a around inf 75.4%
associate-/l*79.1%
Simplified79.1%
Taylor expanded in z around inf 77.0%
if 2.3000000000000002e43 < t Initial program 44.0%
+-commutative44.0%
associate-/l*76.8%
fma-define76.8%
Simplified76.8%
Taylor expanded in y around inf 73.9%
sub-div73.9%
*-un-lft-identity73.9%
associate-*l/73.8%
Applied egg-rr73.8%
Final simplification75.0%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -100000000000.0) (not (<= t 4.5e-17))) (+ y (* z (/ (- x y) t))) (+ x (* (- y x) (/ z a)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -100000000000.0) || !(t <= 4.5e-17)) {
tmp = y + (z * ((x - y) / t));
} else {
tmp = x + ((y - x) * (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 ((t <= (-100000000000.0d0)) .or. (.not. (t <= 4.5d-17))) then
tmp = y + (z * ((x - y) / t))
else
tmp = x + ((y - x) * (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 ((t <= -100000000000.0) || !(t <= 4.5e-17)) {
tmp = y + (z * ((x - y) / t));
} else {
tmp = x + ((y - x) * (z / a));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -100000000000.0) or not (t <= 4.5e-17): tmp = y + (z * ((x - y) / t)) else: tmp = x + ((y - x) * (z / a)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -100000000000.0) || !(t <= 4.5e-17)) tmp = Float64(y + Float64(z * Float64(Float64(x - y) / t))); else tmp = Float64(x + Float64(Float64(y - x) * Float64(z / a))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -100000000000.0) || ~((t <= 4.5e-17))) tmp = y + (z * ((x - y) / t)); else tmp = x + ((y - x) * (z / a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -100000000000.0], N[Not[LessEqual[t, 4.5e-17]], $MachinePrecision]], N[(y + N[(z * N[(N[(x - y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(y - x), $MachinePrecision] * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -100000000000 \lor \neg \left(t \leq 4.5 \cdot 10^{-17}\right):\\
\;\;\;\;y + z \cdot \frac{x - y}{t}\\
\mathbf{else}:\\
\;\;\;\;x + \left(y - x\right) \cdot \frac{z}{a}\\
\end{array}
\end{array}
if t < -1e11 or 4.49999999999999978e-17 < t Initial program 49.6%
+-commutative49.6%
associate-/l*74.6%
fma-define74.6%
Simplified74.6%
Taylor expanded in t around inf 64.8%
associate--l+64.8%
associate-*r/64.8%
associate-*r/64.8%
mul-1-neg64.8%
div-sub64.8%
mul-1-neg64.8%
distribute-lft-out--64.8%
associate-*r/64.8%
mul-1-neg64.8%
unsub-neg64.8%
distribute-rgt-out--64.9%
Simplified64.9%
Taylor expanded in z around inf 61.9%
associate-/l*68.9%
Simplified68.9%
if -1e11 < t < 4.49999999999999978e-17Initial program 94.4%
Taylor expanded in a around inf 78.2%
associate-/l*81.6%
Simplified81.6%
Taylor expanded in z around inf 79.1%
Final simplification74.4%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -6e+54) (not (<= t 2.75e+82))) (* y (- 1.0 (/ z t))) (+ x (* (- y x) (/ z a)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -6e+54) || !(t <= 2.75e+82)) {
tmp = y * (1.0 - (z / t));
} else {
tmp = x + ((y - x) * (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 ((t <= (-6d+54)) .or. (.not. (t <= 2.75d+82))) then
tmp = y * (1.0d0 - (z / t))
else
tmp = x + ((y - x) * (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 ((t <= -6e+54) || !(t <= 2.75e+82)) {
tmp = y * (1.0 - (z / t));
} else {
tmp = x + ((y - x) * (z / a));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -6e+54) or not (t <= 2.75e+82): tmp = y * (1.0 - (z / t)) else: tmp = x + ((y - x) * (z / a)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -6e+54) || !(t <= 2.75e+82)) tmp = Float64(y * Float64(1.0 - Float64(z / t))); else tmp = Float64(x + Float64(Float64(y - x) * Float64(z / a))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -6e+54) || ~((t <= 2.75e+82))) tmp = y * (1.0 - (z / t)); else tmp = x + ((y - x) * (z / a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -6e+54], N[Not[LessEqual[t, 2.75e+82]], $MachinePrecision]], N[(y * N[(1.0 - N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(y - x), $MachinePrecision] * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -6 \cdot 10^{+54} \lor \neg \left(t \leq 2.75 \cdot 10^{+82}\right):\\
\;\;\;\;y \cdot \left(1 - \frac{z}{t}\right)\\
\mathbf{else}:\\
\;\;\;\;x + \left(y - x\right) \cdot \frac{z}{a}\\
\end{array}
\end{array}
if t < -5.9999999999999998e54 or 2.74999999999999998e82 < t Initial program 44.3%
+-commutative44.3%
associate-/l*72.6%
fma-define72.6%
Simplified72.6%
Taylor expanded in y around inf 72.1%
Taylor expanded in a around 0 62.2%
associate-*r/62.2%
neg-mul-162.2%
Simplified62.2%
if -5.9999999999999998e54 < t < 2.74999999999999998e82Initial program 90.9%
Taylor expanded in a around inf 72.3%
associate-/l*77.0%
Simplified77.0%
Taylor expanded in z around inf 74.6%
Final simplification70.0%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -3.2e+57) (not (<= t 2.3e+82))) (* y (- 1.0 (/ z t))) (+ x (* z (/ (- y x) a)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -3.2e+57) || !(t <= 2.3e+82)) {
tmp = y * (1.0 - (z / t));
} else {
tmp = x + (z * ((y - x) / a));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((t <= (-3.2d+57)) .or. (.not. (t <= 2.3d+82))) then
tmp = y * (1.0d0 - (z / t))
else
tmp = x + (z * ((y - x) / a))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -3.2e+57) || !(t <= 2.3e+82)) {
tmp = y * (1.0 - (z / t));
} else {
tmp = x + (z * ((y - x) / a));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -3.2e+57) or not (t <= 2.3e+82): tmp = y * (1.0 - (z / t)) else: tmp = x + (z * ((y - x) / a)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -3.2e+57) || !(t <= 2.3e+82)) tmp = Float64(y * Float64(1.0 - Float64(z / t))); else tmp = Float64(x + Float64(z * Float64(Float64(y - x) / a))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -3.2e+57) || ~((t <= 2.3e+82))) tmp = y * (1.0 - (z / t)); else tmp = x + (z * ((y - x) / a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -3.2e+57], N[Not[LessEqual[t, 2.3e+82]], $MachinePrecision]], N[(y * N[(1.0 - N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(z * N[(N[(y - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.2 \cdot 10^{+57} \lor \neg \left(t \leq 2.3 \cdot 10^{+82}\right):\\
\;\;\;\;y \cdot \left(1 - \frac{z}{t}\right)\\
\mathbf{else}:\\
\;\;\;\;x + z \cdot \frac{y - x}{a}\\
\end{array}
\end{array}
if t < -3.20000000000000029e57 or 2.29999999999999988e82 < t Initial program 44.3%
+-commutative44.3%
associate-/l*72.6%
fma-define72.6%
Simplified72.6%
Taylor expanded in y around inf 72.1%
Taylor expanded in a around 0 62.2%
associate-*r/62.2%
neg-mul-162.2%
Simplified62.2%
if -3.20000000000000029e57 < t < 2.29999999999999988e82Initial program 90.9%
Taylor expanded in t around 0 70.5%
associate-/l*70.4%
Simplified70.4%
Final simplification67.4%
(FPCore (x y z t a) :precision binary64 (if (<= t -8.6e+80) (- y (* a (/ (- x y) t))) (if (<= t 2.45e+82) (+ x (* (- y x) (/ z a))) (* y (- 1.0 (/ z t))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -8.6e+80) {
tmp = y - (a * ((x - y) / t));
} else if (t <= 2.45e+82) {
tmp = x + ((y - x) * (z / a));
} else {
tmp = 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 <= (-8.6d+80)) then
tmp = y - (a * ((x - y) / t))
else if (t <= 2.45d+82) then
tmp = x + ((y - x) * (z / a))
else
tmp = 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 <= -8.6e+80) {
tmp = y - (a * ((x - y) / t));
} else if (t <= 2.45e+82) {
tmp = x + ((y - x) * (z / a));
} else {
tmp = y * (1.0 - (z / t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -8.6e+80: tmp = y - (a * ((x - y) / t)) elif t <= 2.45e+82: tmp = x + ((y - x) * (z / a)) else: tmp = y * (1.0 - (z / t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -8.6e+80) tmp = Float64(y - Float64(a * Float64(Float64(x - y) / t))); elseif (t <= 2.45e+82) tmp = Float64(x + Float64(Float64(y - x) * Float64(z / a))); else tmp = 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 <= -8.6e+80) tmp = y - (a * ((x - y) / t)); elseif (t <= 2.45e+82) tmp = x + ((y - x) * (z / a)); else tmp = y * (1.0 - (z / t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -8.6e+80], N[(y - N[(a * N[(N[(x - y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.45e+82], N[(x + N[(N[(y - x), $MachinePrecision] * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y * N[(1.0 - N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -8.6 \cdot 10^{+80}:\\
\;\;\;\;y - a \cdot \frac{x - y}{t}\\
\mathbf{elif}\;t \leq 2.45 \cdot 10^{+82}:\\
\;\;\;\;x + \left(y - x\right) \cdot \frac{z}{a}\\
\mathbf{else}:\\
\;\;\;\;y \cdot \left(1 - \frac{z}{t}\right)\\
\end{array}
\end{array}
if t < -8.60000000000000008e80Initial program 48.6%
+-commutative48.6%
associate-/l*68.4%
fma-define68.4%
Simplified68.4%
Taylor expanded in t around inf 72.8%
associate--l+72.8%
associate-*r/72.8%
associate-*r/72.8%
mul-1-neg72.8%
div-sub72.8%
mul-1-neg72.8%
distribute-lft-out--72.8%
associate-*r/72.8%
mul-1-neg72.8%
unsub-neg72.8%
distribute-rgt-out--72.9%
Simplified72.9%
Taylor expanded in z around 0 63.5%
sub-neg63.5%
mul-1-neg63.5%
remove-double-neg63.5%
associate-/l*70.1%
Simplified70.1%
if -8.60000000000000008e80 < t < 2.45e82Initial program 91.0%
Taylor expanded in a around inf 72.1%
associate-/l*76.7%
Simplified76.7%
Taylor expanded in z around inf 73.7%
if 2.45e82 < t Initial program 37.7%
+-commutative37.7%
associate-/l*75.5%
fma-define75.5%
Simplified75.5%
Taylor expanded in y around inf 75.9%
Taylor expanded in a around 0 63.1%
associate-*r/63.1%
neg-mul-163.1%
Simplified63.1%
Final simplification71.1%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -1.5e+58) (not (<= t 2.1e+82))) (* y (- 1.0 (/ z t))) (+ x (* y (/ z a)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -1.5e+58) || !(t <= 2.1e+82)) {
tmp = y * (1.0 - (z / t));
} else {
tmp = x + (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 ((t <= (-1.5d+58)) .or. (.not. (t <= 2.1d+82))) then
tmp = y * (1.0d0 - (z / t))
else
tmp = x + (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 ((t <= -1.5e+58) || !(t <= 2.1e+82)) {
tmp = y * (1.0 - (z / t));
} else {
tmp = x + (y * (z / a));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -1.5e+58) or not (t <= 2.1e+82): tmp = y * (1.0 - (z / t)) else: tmp = x + (y * (z / a)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -1.5e+58) || !(t <= 2.1e+82)) tmp = Float64(y * Float64(1.0 - Float64(z / t))); else tmp = Float64(x + Float64(y * Float64(z / a))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -1.5e+58) || ~((t <= 2.1e+82))) tmp = y * (1.0 - (z / t)); else tmp = x + (y * (z / a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -1.5e+58], N[Not[LessEqual[t, 2.1e+82]], $MachinePrecision]], N[(y * N[(1.0 - N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.5 \cdot 10^{+58} \lor \neg \left(t \leq 2.1 \cdot 10^{+82}\right):\\
\;\;\;\;y \cdot \left(1 - \frac{z}{t}\right)\\
\mathbf{else}:\\
\;\;\;\;x + y \cdot \frac{z}{a}\\
\end{array}
\end{array}
if t < -1.5000000000000001e58 or 2.1e82 < t Initial program 44.3%
+-commutative44.3%
associate-/l*72.6%
fma-define72.6%
Simplified72.6%
Taylor expanded in y around inf 72.1%
Taylor expanded in a around 0 62.2%
associate-*r/62.2%
neg-mul-162.2%
Simplified62.2%
if -1.5000000000000001e58 < t < 2.1e82Initial program 90.9%
Taylor expanded in a around inf 72.3%
associate-/l*77.0%
Simplified77.0%
Taylor expanded in y around inf 63.7%
associate-/l*68.2%
Simplified68.2%
Taylor expanded in t around 0 61.6%
associate-/l*65.5%
Simplified65.5%
Final simplification64.3%
(FPCore (x y z t a) :precision binary64 (if (<= t -6.8e+113) y (if (<= t 2.6e+82) (+ x (* y (/ z a))) y)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -6.8e+113) {
tmp = y;
} else if (t <= 2.6e+82) {
tmp = x + (y * (z / a));
} else {
tmp = y;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (t <= (-6.8d+113)) then
tmp = y
else if (t <= 2.6d+82) then
tmp = x + (y * (z / a))
else
tmp = y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -6.8e+113) {
tmp = y;
} else if (t <= 2.6e+82) {
tmp = x + (y * (z / a));
} else {
tmp = y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -6.8e+113: tmp = y elif t <= 2.6e+82: tmp = x + (y * (z / a)) else: tmp = y return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -6.8e+113) tmp = y; elseif (t <= 2.6e+82) tmp = Float64(x + Float64(y * Float64(z / a))); else tmp = y; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -6.8e+113) tmp = y; elseif (t <= 2.6e+82) tmp = x + (y * (z / a)); else tmp = y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -6.8e+113], y, If[LessEqual[t, 2.6e+82], N[(x + N[(y * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], y]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -6.8 \cdot 10^{+113}:\\
\;\;\;\;y\\
\mathbf{elif}\;t \leq 2.6 \cdot 10^{+82}:\\
\;\;\;\;x + y \cdot \frac{z}{a}\\
\mathbf{else}:\\
\;\;\;\;y\\
\end{array}
\end{array}
if t < -6.80000000000000038e113 or 2.5999999999999998e82 < t Initial program 41.0%
+-commutative41.0%
associate-/l*70.5%
fma-define70.5%
Simplified70.5%
clear-num70.4%
associate-/r/70.5%
Applied egg-rr70.5%
Taylor expanded in t around inf 58.1%
if -6.80000000000000038e113 < t < 2.5999999999999998e82Initial program 89.8%
Taylor expanded in a around inf 70.0%
associate-/l*75.0%
Simplified75.0%
Taylor expanded in y around inf 61.9%
associate-/l*66.7%
Simplified66.7%
Taylor expanded in t around 0 59.4%
associate-/l*63.6%
Simplified63.6%
(FPCore (x y z t a) :precision binary64 (if (<= t -6.8e+72) y (if (<= t 4.2e+59) x y)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -6.8e+72) {
tmp = y;
} else if (t <= 4.2e+59) {
tmp = x;
} else {
tmp = y;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (t <= (-6.8d+72)) then
tmp = y
else if (t <= 4.2d+59) then
tmp = x
else
tmp = y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -6.8e+72) {
tmp = y;
} else if (t <= 4.2e+59) {
tmp = x;
} else {
tmp = y;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -6.8e+72: tmp = y elif t <= 4.2e+59: tmp = x else: tmp = y return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -6.8e+72) tmp = y; elseif (t <= 4.2e+59) tmp = x; else tmp = y; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -6.8e+72) tmp = y; elseif (t <= 4.2e+59) tmp = x; else tmp = y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -6.8e+72], y, If[LessEqual[t, 4.2e+59], x, y]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -6.8 \cdot 10^{+72}:\\
\;\;\;\;y\\
\mathbf{elif}\;t \leq 4.2 \cdot 10^{+59}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;y\\
\end{array}
\end{array}
if t < -6.7999999999999997e72 or 4.19999999999999968e59 < t Initial program 45.0%
+-commutative45.0%
associate-/l*72.4%
fma-define72.4%
Simplified72.4%
clear-num72.4%
associate-/r/72.4%
Applied egg-rr72.4%
Taylor expanded in t around inf 54.7%
if -6.7999999999999997e72 < t < 4.19999999999999968e59Initial program 91.4%
+-commutative91.4%
associate-/l*96.1%
fma-define96.1%
Simplified96.1%
Taylor expanded in a around inf 41.2%
(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 73.8%
+-commutative73.8%
associate-/l*87.1%
fma-define87.1%
Simplified87.1%
Taylor expanded in a around inf 29.3%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* (/ (- y x) 1.0) (/ (- z t) (- a t))))))
(if (< a -1.6153062845442575e-142)
t_1
(if (< a 3.774403170083174e-182) (- y (* (/ z t) (- y x))) t_1))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (((y - x) / 1.0) * ((z - t) / (a - t)));
double tmp;
if (a < -1.6153062845442575e-142) {
tmp = t_1;
} else if (a < 3.774403170083174e-182) {
tmp = y - ((z / t) * (y - x));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = x + (((y - x) / 1.0d0) * ((z - t) / (a - t)))
if (a < (-1.6153062845442575d-142)) then
tmp = t_1
else if (a < 3.774403170083174d-182) then
tmp = y - ((z / t) * (y - x))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x + (((y - x) / 1.0) * ((z - t) / (a - t)));
double tmp;
if (a < -1.6153062845442575e-142) {
tmp = t_1;
} else if (a < 3.774403170083174e-182) {
tmp = y - ((z / t) * (y - x));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + (((y - x) / 1.0) * ((z - t) / (a - t))) tmp = 0 if a < -1.6153062845442575e-142: tmp = t_1 elif a < 3.774403170083174e-182: tmp = y - ((z / t) * (y - x)) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(Float64(y - x) / 1.0) * Float64(Float64(z - t) / Float64(a - t)))) tmp = 0.0 if (a < -1.6153062845442575e-142) tmp = t_1; elseif (a < 3.774403170083174e-182) tmp = Float64(y - Float64(Float64(z / t) * Float64(y - x))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + (((y - x) / 1.0) * ((z - t) / (a - t))); tmp = 0.0; if (a < -1.6153062845442575e-142) tmp = t_1; elseif (a < 3.774403170083174e-182) tmp = y - ((z / t) * (y - x)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(N[(y - x), $MachinePrecision] / 1.0), $MachinePrecision] * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Less[a, -1.6153062845442575e-142], t$95$1, If[Less[a, 3.774403170083174e-182], N[(y - N[(N[(z / t), $MachinePrecision] * N[(y - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{y - x}{1} \cdot \frac{z - t}{a - t}\\
\mathbf{if}\;a < -1.6153062845442575 \cdot 10^{-142}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a < 3.774403170083174 \cdot 10^{-182}:\\
\;\;\;\;y - \frac{z}{t} \cdot \left(y - x\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
herbie shell --seed 2024157
(FPCore (x y z t a)
:name "Graphics.Rendering.Chart.Axis.Types:linMap from Chart-1.5.3"
:precision binary64
:alt
(! :herbie-platform default (if (< a -646122513817703/4000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (+ x (* (/ (- y x) 1) (/ (- z t) (- a t)))) (if (< a 1887201585041587/50000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (- y (* (/ z t) (- y x))) (+ x (* (/ (- y x) 1) (/ (- z t) (- a t)))))))
(+ x (/ (* (- y x) (- z t)) (- a t))))