
(FPCore (x y z t a) :precision binary64 (+ x (/ (* (- y z) t) (- a z))))
double code(double x, double y, double z, double t, double a) {
return x + (((y - z) * t) / (a - z));
}
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 - z))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + (((y - z) * t) / (a - z));
}
def code(x, y, z, t, a): return x + (((y - z) * t) / (a - z))
function code(x, y, z, t, a) return Float64(x + Float64(Float64(Float64(y - z) * t) / Float64(a - z))) end
function tmp = code(x, y, z, t, a) tmp = x + (((y - z) * t) / (a - z)); end
code[x_, y_, z_, t_, a_] := N[(x + N[(N[(N[(y - z), $MachinePrecision] * t), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \frac{\left(y - z\right) \cdot t}{a - z}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 14 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a) :precision binary64 (+ x (/ (* (- y z) t) (- a z))))
double code(double x, double y, double z, double t, double a) {
return x + (((y - z) * t) / (a - z));
}
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 - z))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + (((y - z) * t) / (a - z));
}
def code(x, y, z, t, a): return x + (((y - z) * t) / (a - z))
function code(x, y, z, t, a) return Float64(x + Float64(Float64(Float64(y - z) * t) / Float64(a - z))) end
function tmp = code(x, y, z, t, a) tmp = x + (((y - z) * t) / (a - z)); end
code[x_, y_, z_, t_, a_] := N[(x + N[(N[(N[(y - z), $MachinePrecision] * t), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \frac{\left(y - z\right) \cdot t}{a - z}
\end{array}
(FPCore (x y z t a) :precision binary64 (+ (* (/ (- y z) (- a z)) t) x))
double code(double x, double y, double z, double t, double a) {
return (((y - z) / (a - z)) * t) + 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 = (((y - z) / (a - z)) * t) + x
end function
public static double code(double x, double y, double z, double t, double a) {
return (((y - z) / (a - z)) * t) + x;
}
def code(x, y, z, t, a): return (((y - z) / (a - z)) * t) + x
function code(x, y, z, t, a) return Float64(Float64(Float64(Float64(y - z) / Float64(a - z)) * t) + x) end
function tmp = code(x, y, z, t, a) tmp = (((y - z) / (a - z)) * t) + x; end
code[x_, y_, z_, t_, a_] := N[(N[(N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision] + x), $MachinePrecision]
\begin{array}{l}
\\
\frac{y - z}{a - z} \cdot t + x
\end{array}
Initial program 83.9%
+-commutativeN/A
+-lowering-+.f64N/A
associate-/l*N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
--lowering--.f64N/A
/-lowering-/.f64N/A
--lowering--.f6497.6%
Applied egg-rr97.6%
associate-/r/N/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
--lowering--.f6498.4%
Applied egg-rr98.4%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* t (/ y (- a z)))))
(if (<= z -4.6e-193)
(+ t x)
(if (<= z -4.5e-274)
t_1
(if (<= z 1.16e-169) x (if (<= z 7.2e-79) t_1 (+ t x)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = t * (y / (a - z));
double tmp;
if (z <= -4.6e-193) {
tmp = t + x;
} else if (z <= -4.5e-274) {
tmp = t_1;
} else if (z <= 1.16e-169) {
tmp = x;
} else if (z <= 7.2e-79) {
tmp = t_1;
} else {
tmp = t + x;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = t * (y / (a - z))
if (z <= (-4.6d-193)) then
tmp = t + x
else if (z <= (-4.5d-274)) then
tmp = t_1
else if (z <= 1.16d-169) then
tmp = x
else if (z <= 7.2d-79) then
tmp = t_1
else
tmp = t + x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = t * (y / (a - z));
double tmp;
if (z <= -4.6e-193) {
tmp = t + x;
} else if (z <= -4.5e-274) {
tmp = t_1;
} else if (z <= 1.16e-169) {
tmp = x;
} else if (z <= 7.2e-79) {
tmp = t_1;
} else {
tmp = t + x;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = t * (y / (a - z)) tmp = 0 if z <= -4.6e-193: tmp = t + x elif z <= -4.5e-274: tmp = t_1 elif z <= 1.16e-169: tmp = x elif z <= 7.2e-79: tmp = t_1 else: tmp = t + x return tmp
function code(x, y, z, t, a) t_1 = Float64(t * Float64(y / Float64(a - z))) tmp = 0.0 if (z <= -4.6e-193) tmp = Float64(t + x); elseif (z <= -4.5e-274) tmp = t_1; elseif (z <= 1.16e-169) tmp = x; elseif (z <= 7.2e-79) tmp = t_1; else tmp = Float64(t + x); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = t * (y / (a - z)); tmp = 0.0; if (z <= -4.6e-193) tmp = t + x; elseif (z <= -4.5e-274) tmp = t_1; elseif (z <= 1.16e-169) tmp = x; elseif (z <= 7.2e-79) tmp = t_1; else tmp = t + x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -4.6e-193], N[(t + x), $MachinePrecision], If[LessEqual[z, -4.5e-274], t$95$1, If[LessEqual[z, 1.16e-169], x, If[LessEqual[z, 7.2e-79], t$95$1, N[(t + x), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := t \cdot \frac{y}{a - z}\\
\mathbf{if}\;z \leq -4.6 \cdot 10^{-193}:\\
\;\;\;\;t + x\\
\mathbf{elif}\;z \leq -4.5 \cdot 10^{-274}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq 1.16 \cdot 10^{-169}:\\
\;\;\;\;x\\
\mathbf{elif}\;z \leq 7.2 \cdot 10^{-79}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t + x\\
\end{array}
\end{array}
if z < -4.60000000000000017e-193 or 7.2000000000000005e-79 < z Initial program 79.3%
Taylor expanded in z around inf
Simplified68.9%
if -4.60000000000000017e-193 < z < -4.49999999999999991e-274 or 1.16e-169 < z < 7.2000000000000005e-79Initial program 97.2%
Taylor expanded in y around inf
associate-/l*N/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f6477.9%
Simplified77.9%
if -4.49999999999999991e-274 < z < 1.16e-169Initial program 96.8%
Taylor expanded in x around inf
Simplified75.8%
Final simplification71.0%
(FPCore (x y z t a)
:precision binary64
(if (<= z -1.45e+161)
(+ t x)
(if (<= z -4.2e+55)
(* (/ (- y z) (- a z)) t)
(if (<= z 2.4e+112) (+ x (/ y (/ (- a z) t))) (+ t x)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.45e+161) {
tmp = t + x;
} else if (z <= -4.2e+55) {
tmp = ((y - z) / (a - z)) * t;
} else if (z <= 2.4e+112) {
tmp = x + (y / ((a - z) / t));
} else {
tmp = t + 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 <= (-1.45d+161)) then
tmp = t + x
else if (z <= (-4.2d+55)) then
tmp = ((y - z) / (a - z)) * t
else if (z <= 2.4d+112) then
tmp = x + (y / ((a - z) / t))
else
tmp = t + 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 <= -1.45e+161) {
tmp = t + x;
} else if (z <= -4.2e+55) {
tmp = ((y - z) / (a - z)) * t;
} else if (z <= 2.4e+112) {
tmp = x + (y / ((a - z) / t));
} else {
tmp = t + x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -1.45e+161: tmp = t + x elif z <= -4.2e+55: tmp = ((y - z) / (a - z)) * t elif z <= 2.4e+112: tmp = x + (y / ((a - z) / t)) else: tmp = t + x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.45e+161) tmp = Float64(t + x); elseif (z <= -4.2e+55) tmp = Float64(Float64(Float64(y - z) / Float64(a - z)) * t); elseif (z <= 2.4e+112) tmp = Float64(x + Float64(y / Float64(Float64(a - z) / t))); else tmp = Float64(t + x); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -1.45e+161) tmp = t + x; elseif (z <= -4.2e+55) tmp = ((y - z) / (a - z)) * t; elseif (z <= 2.4e+112) tmp = x + (y / ((a - z) / t)); else tmp = t + x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.45e+161], N[(t + x), $MachinePrecision], If[LessEqual[z, -4.2e+55], N[(N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision], If[LessEqual[z, 2.4e+112], N[(x + N[(y / N[(N[(a - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t + x), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.45 \cdot 10^{+161}:\\
\;\;\;\;t + x\\
\mathbf{elif}\;z \leq -4.2 \cdot 10^{+55}:\\
\;\;\;\;\frac{y - z}{a - z} \cdot t\\
\mathbf{elif}\;z \leq 2.4 \cdot 10^{+112}:\\
\;\;\;\;x + \frac{y}{\frac{a - z}{t}}\\
\mathbf{else}:\\
\;\;\;\;t + x\\
\end{array}
\end{array}
if z < -1.45000000000000008e161 or 2.4e112 < z Initial program 62.8%
Taylor expanded in z around inf
Simplified90.1%
if -1.45000000000000008e161 < z < -4.2000000000000001e55Initial program 75.4%
Taylor expanded in x around 0
/-lowering-/.f64N/A
*-lowering-*.f64N/A
--lowering--.f64N/A
--lowering--.f6458.6%
Simplified58.6%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
--lowering--.f6483.2%
Applied egg-rr83.2%
if -4.2000000000000001e55 < z < 2.4e112Initial program 95.6%
+-commutativeN/A
+-lowering-+.f64N/A
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 y around inf
Simplified92.6%
Final simplification91.0%
(FPCore (x y z t a)
:precision binary64
(if (<= z -1.35e+161)
(+ t x)
(if (<= z -4.2e+55)
(* (/ (- y z) (- a z)) t)
(if (<= z 1.8e+112) (+ x (* t (/ y (- a z)))) (+ t x)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.35e+161) {
tmp = t + x;
} else if (z <= -4.2e+55) {
tmp = ((y - z) / (a - z)) * t;
} else if (z <= 1.8e+112) {
tmp = x + (t * (y / (a - z)));
} else {
tmp = t + 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 <= (-1.35d+161)) then
tmp = t + x
else if (z <= (-4.2d+55)) then
tmp = ((y - z) / (a - z)) * t
else if (z <= 1.8d+112) then
tmp = x + (t * (y / (a - z)))
else
tmp = t + 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 <= -1.35e+161) {
tmp = t + x;
} else if (z <= -4.2e+55) {
tmp = ((y - z) / (a - z)) * t;
} else if (z <= 1.8e+112) {
tmp = x + (t * (y / (a - z)));
} else {
tmp = t + x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -1.35e+161: tmp = t + x elif z <= -4.2e+55: tmp = ((y - z) / (a - z)) * t elif z <= 1.8e+112: tmp = x + (t * (y / (a - z))) else: tmp = t + x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.35e+161) tmp = Float64(t + x); elseif (z <= -4.2e+55) tmp = Float64(Float64(Float64(y - z) / Float64(a - z)) * t); elseif (z <= 1.8e+112) tmp = Float64(x + Float64(t * Float64(y / Float64(a - z)))); else tmp = Float64(t + x); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -1.35e+161) tmp = t + x; elseif (z <= -4.2e+55) tmp = ((y - z) / (a - z)) * t; elseif (z <= 1.8e+112) tmp = x + (t * (y / (a - z))); else tmp = t + x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.35e+161], N[(t + x), $MachinePrecision], If[LessEqual[z, -4.2e+55], N[(N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision], If[LessEqual[z, 1.8e+112], N[(x + N[(t * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t + x), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.35 \cdot 10^{+161}:\\
\;\;\;\;t + x\\
\mathbf{elif}\;z \leq -4.2 \cdot 10^{+55}:\\
\;\;\;\;\frac{y - z}{a - z} \cdot t\\
\mathbf{elif}\;z \leq 1.8 \cdot 10^{+112}:\\
\;\;\;\;x + t \cdot \frac{y}{a - z}\\
\mathbf{else}:\\
\;\;\;\;t + x\\
\end{array}
\end{array}
if z < -1.3499999999999999e161 or 1.8e112 < z Initial program 62.8%
Taylor expanded in z around inf
Simplified90.1%
if -1.3499999999999999e161 < z < -4.2000000000000001e55Initial program 75.4%
Taylor expanded in x around 0
/-lowering-/.f64N/A
*-lowering-*.f64N/A
--lowering--.f64N/A
--lowering--.f6458.6%
Simplified58.6%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
--lowering--.f6483.2%
Applied egg-rr83.2%
if -4.2000000000000001e55 < z < 1.8e112Initial program 95.6%
Taylor expanded in y around inf
associate-/l*N/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f6491.3%
Simplified91.3%
Final simplification90.2%
(FPCore (x y z t a)
:precision binary64
(if (<= z -1.35e+161)
(+ t x)
(if (<= z -1.2e+48)
(* (/ (- y z) (- a z)) t)
(if (<= z 2.4e-14) (+ x (/ y (/ a t))) (+ t x)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.35e+161) {
tmp = t + x;
} else if (z <= -1.2e+48) {
tmp = ((y - z) / (a - z)) * t;
} else if (z <= 2.4e-14) {
tmp = x + (y / (a / t));
} else {
tmp = t + 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 <= (-1.35d+161)) then
tmp = t + x
else if (z <= (-1.2d+48)) then
tmp = ((y - z) / (a - z)) * t
else if (z <= 2.4d-14) then
tmp = x + (y / (a / t))
else
tmp = t + 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 <= -1.35e+161) {
tmp = t + x;
} else if (z <= -1.2e+48) {
tmp = ((y - z) / (a - z)) * t;
} else if (z <= 2.4e-14) {
tmp = x + (y / (a / t));
} else {
tmp = t + x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -1.35e+161: tmp = t + x elif z <= -1.2e+48: tmp = ((y - z) / (a - z)) * t elif z <= 2.4e-14: tmp = x + (y / (a / t)) else: tmp = t + x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.35e+161) tmp = Float64(t + x); elseif (z <= -1.2e+48) tmp = Float64(Float64(Float64(y - z) / Float64(a - z)) * t); elseif (z <= 2.4e-14) tmp = Float64(x + Float64(y / Float64(a / t))); else tmp = Float64(t + x); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -1.35e+161) tmp = t + x; elseif (z <= -1.2e+48) tmp = ((y - z) / (a - z)) * t; elseif (z <= 2.4e-14) tmp = x + (y / (a / t)); else tmp = t + x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.35e+161], N[(t + x), $MachinePrecision], If[LessEqual[z, -1.2e+48], N[(N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision], If[LessEqual[z, 2.4e-14], N[(x + N[(y / N[(a / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t + x), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.35 \cdot 10^{+161}:\\
\;\;\;\;t + x\\
\mathbf{elif}\;z \leq -1.2 \cdot 10^{+48}:\\
\;\;\;\;\frac{y - z}{a - z} \cdot t\\
\mathbf{elif}\;z \leq 2.4 \cdot 10^{-14}:\\
\;\;\;\;x + \frac{y}{\frac{a}{t}}\\
\mathbf{else}:\\
\;\;\;\;t + x\\
\end{array}
\end{array}
if z < -1.3499999999999999e161 or 2.4e-14 < z Initial program 70.9%
Taylor expanded in z around inf
Simplified83.5%
if -1.3499999999999999e161 < z < -1.2000000000000001e48Initial program 78.1%
Taylor expanded in x around 0
/-lowering-/.f64N/A
*-lowering-*.f64N/A
--lowering--.f64N/A
--lowering--.f6459.8%
Simplified59.8%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
--lowering--.f6481.6%
Applied egg-rr81.6%
if -1.2000000000000001e48 < z < 2.4e-14Initial program 96.1%
Taylor expanded in z around 0
+-lowering-+.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f6477.3%
Simplified77.3%
*-commutativeN/A
associate-/l*N/A
*-lowering-*.f64N/A
/-lowering-/.f6479.6%
Applied egg-rr79.6%
+-commutativeN/A
+-lowering-+.f64N/A
clear-numN/A
div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f6480.4%
Applied egg-rr80.4%
Final simplification81.8%
(FPCore (x y z t a) :precision binary64 (let* ((t_1 (+ x (/ y (/ (- a z) t))))) (if (<= y -1.25e-13) t_1 (if (<= y 5e+39) (+ x (* t (/ z (- z a)))) t_1))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (y / ((a - z) / t));
double tmp;
if (y <= -1.25e-13) {
tmp = t_1;
} else if (y <= 5e+39) {
tmp = x + (t * (z / (z - a)));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = x + (y / ((a - z) / t))
if (y <= (-1.25d-13)) then
tmp = t_1
else if (y <= 5d+39) then
tmp = x + (t * (z / (z - a)))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x + (y / ((a - z) / t));
double tmp;
if (y <= -1.25e-13) {
tmp = t_1;
} else if (y <= 5e+39) {
tmp = x + (t * (z / (z - a)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + (y / ((a - z) / t)) tmp = 0 if y <= -1.25e-13: tmp = t_1 elif y <= 5e+39: tmp = x + (t * (z / (z - a))) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(y / Float64(Float64(a - z) / t))) tmp = 0.0 if (y <= -1.25e-13) tmp = t_1; elseif (y <= 5e+39) tmp = Float64(x + Float64(t * Float64(z / Float64(z - a)))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + (y / ((a - z) / t)); tmp = 0.0; if (y <= -1.25e-13) tmp = t_1; elseif (y <= 5e+39) tmp = x + (t * (z / (z - a))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(y / N[(N[(a - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.25e-13], t$95$1, If[LessEqual[y, 5e+39], N[(x + N[(t * N[(z / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{y}{\frac{a - z}{t}}\\
\mathbf{if}\;y \leq -1.25 \cdot 10^{-13}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 5 \cdot 10^{+39}:\\
\;\;\;\;x + t \cdot \frac{z}{z - a}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -1.24999999999999997e-13 or 5.00000000000000015e39 < y Initial program 85.8%
+-commutativeN/A
+-lowering-+.f64N/A
associate-/l*N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
--lowering--.f64N/A
/-lowering-/.f64N/A
--lowering--.f6498.4%
Applied egg-rr98.4%
Taylor expanded in y around inf
Simplified90.7%
if -1.24999999999999997e-13 < y < 5.00000000000000015e39Initial program 81.8%
Taylor expanded in y around 0
mul-1-negN/A
unsub-negN/A
--lowering--.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
--lowering--.f6475.8%
Simplified75.8%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f6493.9%
Applied egg-rr93.9%
Final simplification92.3%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* t (- 1.0 (/ y z))))))
(if (<= z -1.02e+69)
t_1
(if (<= z 1.25e-8) (+ x (/ y (/ (- a z) t))) t_1))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (t * (1.0 - (y / z)));
double tmp;
if (z <= -1.02e+69) {
tmp = t_1;
} else if (z <= 1.25e-8) {
tmp = x + (y / ((a - z) / 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 + (t * (1.0d0 - (y / z)))
if (z <= (-1.02d+69)) then
tmp = t_1
else if (z <= 1.25d-8) then
tmp = x + (y / ((a - z) / 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 + (t * (1.0 - (y / z)));
double tmp;
if (z <= -1.02e+69) {
tmp = t_1;
} else if (z <= 1.25e-8) {
tmp = x + (y / ((a - z) / t));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + (t * (1.0 - (y / z))) tmp = 0 if z <= -1.02e+69: tmp = t_1 elif z <= 1.25e-8: tmp = x + (y / ((a - z) / t)) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(t * Float64(1.0 - Float64(y / z)))) tmp = 0.0 if (z <= -1.02e+69) tmp = t_1; elseif (z <= 1.25e-8) tmp = Float64(x + Float64(y / Float64(Float64(a - z) / t))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + (t * (1.0 - (y / z))); tmp = 0.0; if (z <= -1.02e+69) tmp = t_1; elseif (z <= 1.25e-8) tmp = x + (y / ((a - z) / t)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(t * N[(1.0 - N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.02e+69], t$95$1, If[LessEqual[z, 1.25e-8], N[(x + N[(y / N[(N[(a - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + t \cdot \left(1 - \frac{y}{z}\right)\\
\mathbf{if}\;z \leq -1.02 \cdot 10^{+69}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq 1.25 \cdot 10^{-8}:\\
\;\;\;\;x + \frac{y}{\frac{a - z}{t}}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -1.02e69 or 1.2499999999999999e-8 < z Initial program 72.3%
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-/.f6486.5%
Simplified86.5%
if -1.02e69 < z < 1.2499999999999999e-8Initial program 94.9%
+-commutativeN/A
+-lowering-+.f64N/A
associate-/l*N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
--lowering--.f64N/A
/-lowering-/.f64N/A
--lowering--.f6498.5%
Applied egg-rr98.5%
Taylor expanded in y around inf
Simplified94.9%
Final simplification90.8%
(FPCore (x y z t a) :precision binary64 (if (<= z -8.2e+77) (+ t x) (if (<= z 1.5e-14) (+ x (/ y (/ a t))) (+ t x))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -8.2e+77) {
tmp = t + x;
} else if (z <= 1.5e-14) {
tmp = x + (y / (a / t));
} else {
tmp = t + 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 <= (-8.2d+77)) then
tmp = t + x
else if (z <= 1.5d-14) then
tmp = x + (y / (a / t))
else
tmp = t + 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 <= -8.2e+77) {
tmp = t + x;
} else if (z <= 1.5e-14) {
tmp = x + (y / (a / t));
} else {
tmp = t + x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -8.2e+77: tmp = t + x elif z <= 1.5e-14: tmp = x + (y / (a / t)) else: tmp = t + x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -8.2e+77) tmp = Float64(t + x); elseif (z <= 1.5e-14) tmp = Float64(x + Float64(y / Float64(a / t))); else tmp = Float64(t + x); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -8.2e+77) tmp = t + x; elseif (z <= 1.5e-14) tmp = x + (y / (a / t)); else tmp = t + x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -8.2e+77], N[(t + x), $MachinePrecision], If[LessEqual[z, 1.5e-14], N[(x + N[(y / N[(a / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t + x), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -8.2 \cdot 10^{+77}:\\
\;\;\;\;t + x\\
\mathbf{elif}\;z \leq 1.5 \cdot 10^{-14}:\\
\;\;\;\;x + \frac{y}{\frac{a}{t}}\\
\mathbf{else}:\\
\;\;\;\;t + x\\
\end{array}
\end{array}
if z < -8.2000000000000002e77 or 1.4999999999999999e-14 < z Initial program 70.9%
Taylor expanded in z around inf
Simplified80.3%
if -8.2000000000000002e77 < z < 1.4999999999999999e-14Initial program 95.6%
Taylor expanded in z around 0
+-lowering-+.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f6474.7%
Simplified74.7%
*-commutativeN/A
associate-/l*N/A
*-lowering-*.f64N/A
/-lowering-/.f6477.5%
Applied egg-rr77.5%
+-commutativeN/A
+-lowering-+.f64N/A
clear-numN/A
div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f6478.2%
Applied egg-rr78.2%
Final simplification79.2%
(FPCore (x y z t a) :precision binary64 (if (<= z -1.45e+84) (+ t x) (if (<= z 6.5e-14) (+ x (* y (/ t a))) (+ t x))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.45e+84) {
tmp = t + x;
} else if (z <= 6.5e-14) {
tmp = x + (y * (t / a));
} else {
tmp = t + 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 <= (-1.45d+84)) then
tmp = t + x
else if (z <= 6.5d-14) then
tmp = x + (y * (t / a))
else
tmp = t + 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 <= -1.45e+84) {
tmp = t + x;
} else if (z <= 6.5e-14) {
tmp = x + (y * (t / a));
} else {
tmp = t + x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -1.45e+84: tmp = t + x elif z <= 6.5e-14: tmp = x + (y * (t / a)) else: tmp = t + x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.45e+84) tmp = Float64(t + x); elseif (z <= 6.5e-14) tmp = Float64(x + Float64(y * Float64(t / a))); else tmp = Float64(t + x); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -1.45e+84) tmp = t + x; elseif (z <= 6.5e-14) tmp = x + (y * (t / a)); else tmp = t + x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.45e+84], N[(t + x), $MachinePrecision], If[LessEqual[z, 6.5e-14], N[(x + N[(y * N[(t / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t + x), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.45 \cdot 10^{+84}:\\
\;\;\;\;t + x\\
\mathbf{elif}\;z \leq 6.5 \cdot 10^{-14}:\\
\;\;\;\;x + y \cdot \frac{t}{a}\\
\mathbf{else}:\\
\;\;\;\;t + x\\
\end{array}
\end{array}
if z < -1.44999999999999994e84 or 6.5000000000000001e-14 < z Initial program 70.9%
Taylor expanded in z around inf
Simplified80.3%
if -1.44999999999999994e84 < z < 6.5000000000000001e-14Initial program 95.6%
Taylor expanded in z around 0
+-lowering-+.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f6474.7%
Simplified74.7%
*-commutativeN/A
associate-/l*N/A
*-lowering-*.f64N/A
/-lowering-/.f6477.5%
Applied egg-rr77.5%
Final simplification78.8%
(FPCore (x y z t a) :precision binary64 (let* ((t_1 (* t (- 1.0 (/ y z))))) (if (<= t -1.4e+141) t_1 (if (<= t 1.45e+199) (+ t x) t_1))))
double code(double x, double y, double z, double t, double a) {
double t_1 = t * (1.0 - (y / z));
double tmp;
if (t <= -1.4e+141) {
tmp = t_1;
} else if (t <= 1.45e+199) {
tmp = t + 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 = t * (1.0d0 - (y / z))
if (t <= (-1.4d+141)) then
tmp = t_1
else if (t <= 1.45d+199) then
tmp = t + 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 = t * (1.0 - (y / z));
double tmp;
if (t <= -1.4e+141) {
tmp = t_1;
} else if (t <= 1.45e+199) {
tmp = t + x;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = t * (1.0 - (y / z)) tmp = 0 if t <= -1.4e+141: tmp = t_1 elif t <= 1.45e+199: tmp = t + x else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(t * Float64(1.0 - Float64(y / z))) tmp = 0.0 if (t <= -1.4e+141) tmp = t_1; elseif (t <= 1.45e+199) tmp = Float64(t + x); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = t * (1.0 - (y / z)); tmp = 0.0; if (t <= -1.4e+141) tmp = t_1; elseif (t <= 1.45e+199) tmp = t + x; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t * N[(1.0 - N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1.4e+141], t$95$1, If[LessEqual[t, 1.45e+199], N[(t + x), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := t \cdot \left(1 - \frac{y}{z}\right)\\
\mathbf{if}\;t \leq -1.4 \cdot 10^{+141}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 1.45 \cdot 10^{+199}:\\
\;\;\;\;t + x\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if t < -1.39999999999999996e141 or 1.4499999999999999e199 < t Initial program 57.4%
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-/.f6462.7%
Simplified62.7%
Taylor expanded in x around 0
mul-1-negN/A
distribute-rgt-neg-inN/A
mul-1-negN/A
*-lowering-*.f64N/A
mul-1-negN/A
sub-negN/A
metadata-evalN/A
distribute-neg-inN/A
metadata-evalN/A
+-commutativeN/A
sub-negN/A
--lowering--.f64N/A
/-lowering-/.f6462.7%
Simplified62.7%
if -1.39999999999999996e141 < t < 1.4499999999999999e199Initial program 91.2%
Taylor expanded in z around inf
Simplified68.4%
Final simplification67.2%
(FPCore (x y z t a) :precision binary64 (if (<= z -3.7e+60) (+ t x) (if (<= z 8.5e-15) x (+ t x))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -3.7e+60) {
tmp = t + x;
} else if (z <= 8.5e-15) {
tmp = x;
} else {
tmp = t + 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 <= (-3.7d+60)) then
tmp = t + x
else if (z <= 8.5d-15) then
tmp = x
else
tmp = t + 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 <= -3.7e+60) {
tmp = t + x;
} else if (z <= 8.5e-15) {
tmp = x;
} else {
tmp = t + x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -3.7e+60: tmp = t + x elif z <= 8.5e-15: tmp = x else: tmp = t + x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -3.7e+60) tmp = Float64(t + x); elseif (z <= 8.5e-15) tmp = x; else tmp = Float64(t + x); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -3.7e+60) tmp = t + x; elseif (z <= 8.5e-15) tmp = x; else tmp = t + x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -3.7e+60], N[(t + x), $MachinePrecision], If[LessEqual[z, 8.5e-15], x, N[(t + x), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.7 \cdot 10^{+60}:\\
\;\;\;\;t + x\\
\mathbf{elif}\;z \leq 8.5 \cdot 10^{-15}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;t + x\\
\end{array}
\end{array}
if z < -3.69999999999999988e60 or 8.50000000000000007e-15 < z Initial program 71.3%
Taylor expanded in z around inf
Simplified78.8%
if -3.69999999999999988e60 < z < 8.50000000000000007e-15Initial program 96.2%
Taylor expanded in x around inf
Simplified53.7%
Final simplification66.0%
(FPCore (x y z t a) :precision binary64 (if (<= t -2.55e+141) t (if (<= t 4.1e+159) x t)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -2.55e+141) {
tmp = t;
} else if (t <= 4.1e+159) {
tmp = x;
} else {
tmp = 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 <= (-2.55d+141)) then
tmp = t
else if (t <= 4.1d+159) then
tmp = x
else
tmp = 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 <= -2.55e+141) {
tmp = t;
} else if (t <= 4.1e+159) {
tmp = x;
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -2.55e+141: tmp = t elif t <= 4.1e+159: tmp = x else: tmp = t return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -2.55e+141) tmp = t; elseif (t <= 4.1e+159) tmp = x; else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -2.55e+141) tmp = t; elseif (t <= 4.1e+159) tmp = x; else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -2.55e+141], t, If[LessEqual[t, 4.1e+159], x, t]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.55 \cdot 10^{+141}:\\
\;\;\;\;t\\
\mathbf{elif}\;t \leq 4.1 \cdot 10^{+159}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if t < -2.5499999999999999e141 or 4.10000000000000014e159 < t Initial program 55.8%
Taylor expanded in z around inf
Simplified41.8%
Taylor expanded in x around 0
Simplified33.0%
if -2.5499999999999999e141 < t < 4.10000000000000014e159Initial program 93.7%
Taylor expanded in x around inf
Simplified64.3%
(FPCore (x y z t a) :precision binary64 (+ x (* (- y z) (/ t (- a z)))))
double code(double x, double y, double z, double t, double a) {
return x + ((y - z) * (t / (a - z)));
}
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 - z)))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + ((y - z) * (t / (a - z)));
}
def code(x, y, z, t, a): return x + ((y - z) * (t / (a - z)))
function code(x, y, z, t, a) return Float64(x + Float64(Float64(y - z) * Float64(t / Float64(a - z)))) end
function tmp = code(x, y, z, t, a) tmp = x + ((y - z) * (t / (a - z))); end
code[x_, y_, z_, t_, a_] := N[(x + N[(N[(y - z), $MachinePrecision] * N[(t / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(y - z\right) \cdot \frac{t}{a - z}
\end{array}
Initial program 83.9%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
--lowering--.f64N/A
--lowering--.f6497.9%
Applied egg-rr97.9%
Final simplification97.9%
(FPCore (x y z t a) :precision binary64 t)
double code(double x, double y, double z, double t, double a) {
return 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 = t
end function
public static double code(double x, double y, double z, double t, double a) {
return t;
}
def code(x, y, z, t, a): return t
function code(x, y, z, t, a) return t end
function tmp = code(x, y, z, t, a) tmp = t; end
code[x_, y_, z_, t_, a_] := t
\begin{array}{l}
\\
t
\end{array}
Initial program 83.9%
Taylor expanded in z around inf
Simplified61.3%
Taylor expanded in x around 0
Simplified18.0%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* (/ (- y z) (- a z)) t))))
(if (< t -1.0682974490174067e-39)
t_1
(if (< t 3.9110949887586375e-141) (+ x (/ (* (- y z) t) (- a z))) t_1))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (((y - z) / (a - z)) * t);
double tmp;
if (t < -1.0682974490174067e-39) {
tmp = t_1;
} else if (t < 3.9110949887586375e-141) {
tmp = x + (((y - z) * t) / (a - z));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = x + (((y - z) / (a - z)) * t)
if (t < (-1.0682974490174067d-39)) then
tmp = t_1
else if (t < 3.9110949887586375d-141) then
tmp = x + (((y - z) * t) / (a - z))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x + (((y - z) / (a - z)) * t);
double tmp;
if (t < -1.0682974490174067e-39) {
tmp = t_1;
} else if (t < 3.9110949887586375e-141) {
tmp = x + (((y - z) * t) / (a - z));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + (((y - z) / (a - z)) * t) tmp = 0 if t < -1.0682974490174067e-39: tmp = t_1 elif t < 3.9110949887586375e-141: tmp = x + (((y - z) * t) / (a - z)) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(Float64(y - z) / Float64(a - z)) * t)) tmp = 0.0 if (t < -1.0682974490174067e-39) tmp = t_1; elseif (t < 3.9110949887586375e-141) tmp = Float64(x + Float64(Float64(Float64(y - z) * t) / Float64(a - z))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + (((y - z) / (a - z)) * t); tmp = 0.0; if (t < -1.0682974490174067e-39) tmp = t_1; elseif (t < 3.9110949887586375e-141) tmp = x + (((y - z) * t) / (a - z)); 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 - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision]}, If[Less[t, -1.0682974490174067e-39], t$95$1, If[Less[t, 3.9110949887586375e-141], N[(x + N[(N[(N[(y - z), $MachinePrecision] * t), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{y - z}{a - z} \cdot t\\
\mathbf{if}\;t < -1.0682974490174067 \cdot 10^{-39}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t < 3.9110949887586375 \cdot 10^{-141}:\\
\;\;\;\;x + \frac{\left(y - z\right) \cdot t}{a - z}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
herbie shell --seed 2024138
(FPCore (x y z t a)
:name "Graphics.Rendering.Plot.Render.Plot.Axis:renderAxisTick from plot-0.2.3.4, A"
:precision binary64
:alt
(! :herbie-platform default (if (< t -10682974490174067/10000000000000000000000000000000000000000000000000000000) (+ x (* (/ (- y z) (- a z)) t)) (if (< t 312887599100691/80000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (+ x (/ (* (- y z) t) (- a z))) (+ x (* (/ (- y z) (- a z)) t)))))
(+ x (/ (* (- y z) t) (- a z))))