
(FPCore (x y z t) :precision binary64 (* (/ (- x y) (- z y)) t))
double code(double x, double y, double z, double t) {
return ((x - y) / (z - y)) * t;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = ((x - y) / (z - y)) * t
end function
public static double code(double x, double y, double z, double t) {
return ((x - y) / (z - y)) * t;
}
def code(x, y, z, t): return ((x - y) / (z - y)) * t
function code(x, y, z, t) return Float64(Float64(Float64(x - y) / Float64(z - y)) * t) end
function tmp = code(x, y, z, t) tmp = ((x - y) / (z - y)) * t; end
code[x_, y_, z_, t_] := N[(N[(N[(x - y), $MachinePrecision] / N[(z - y), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision]
\begin{array}{l}
\\
\frac{x - y}{z - y} \cdot t
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 13 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t) :precision binary64 (* (/ (- x y) (- z y)) t))
double code(double x, double y, double z, double t) {
return ((x - y) / (z - y)) * t;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = ((x - y) / (z - y)) * t
end function
public static double code(double x, double y, double z, double t) {
return ((x - y) / (z - y)) * t;
}
def code(x, y, z, t): return ((x - y) / (z - y)) * t
function code(x, y, z, t) return Float64(Float64(Float64(x - y) / Float64(z - y)) * t) end
function tmp = code(x, y, z, t) tmp = ((x - y) / (z - y)) * t; end
code[x_, y_, z_, t_] := N[(N[(N[(x - y), $MachinePrecision] / N[(z - y), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision]
\begin{array}{l}
\\
\frac{x - y}{z - y} \cdot t
\end{array}
(FPCore (x y z t) :precision binary64 (* (/ (- x y) (- z y)) t))
double code(double x, double y, double z, double t) {
return ((x - y) / (z - y)) * t;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = ((x - y) / (z - y)) * t
end function
public static double code(double x, double y, double z, double t) {
return ((x - y) / (z - y)) * t;
}
def code(x, y, z, t): return ((x - y) / (z - y)) * t
function code(x, y, z, t) return Float64(Float64(Float64(x - y) / Float64(z - y)) * t) end
function tmp = code(x, y, z, t) tmp = ((x - y) / (z - y)) * t; end
code[x_, y_, z_, t_] := N[(N[(N[(x - y), $MachinePrecision] / N[(z - y), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision]
\begin{array}{l}
\\
\frac{x - y}{z - y} \cdot t
\end{array}
Initial program 97.3%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (* y (/ t (- y z)))))
(if (<= y -6.5e+174)
t
(if (<= y -1.9e-96)
t_1
(if (<= y 2.75e-11) (* x (/ t (- z y))) (if (<= y 4.9e+92) t_1 t))))))
double code(double x, double y, double z, double t) {
double t_1 = y * (t / (y - z));
double tmp;
if (y <= -6.5e+174) {
tmp = t;
} else if (y <= -1.9e-96) {
tmp = t_1;
} else if (y <= 2.75e-11) {
tmp = x * (t / (z - y));
} else if (y <= 4.9e+92) {
tmp = t_1;
} else {
tmp = t;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: t_1
real(8) :: tmp
t_1 = y * (t / (y - z))
if (y <= (-6.5d+174)) then
tmp = t
else if (y <= (-1.9d-96)) then
tmp = t_1
else if (y <= 2.75d-11) then
tmp = x * (t / (z - y))
else if (y <= 4.9d+92) then
tmp = t_1
else
tmp = t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = y * (t / (y - z));
double tmp;
if (y <= -6.5e+174) {
tmp = t;
} else if (y <= -1.9e-96) {
tmp = t_1;
} else if (y <= 2.75e-11) {
tmp = x * (t / (z - y));
} else if (y <= 4.9e+92) {
tmp = t_1;
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t): t_1 = y * (t / (y - z)) tmp = 0 if y <= -6.5e+174: tmp = t elif y <= -1.9e-96: tmp = t_1 elif y <= 2.75e-11: tmp = x * (t / (z - y)) elif y <= 4.9e+92: tmp = t_1 else: tmp = t return tmp
function code(x, y, z, t) t_1 = Float64(y * Float64(t / Float64(y - z))) tmp = 0.0 if (y <= -6.5e+174) tmp = t; elseif (y <= -1.9e-96) tmp = t_1; elseif (y <= 2.75e-11) tmp = Float64(x * Float64(t / Float64(z - y))); elseif (y <= 4.9e+92) tmp = t_1; else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = y * (t / (y - z)); tmp = 0.0; if (y <= -6.5e+174) tmp = t; elseif (y <= -1.9e-96) tmp = t_1; elseif (y <= 2.75e-11) tmp = x * (t / (z - y)); elseif (y <= 4.9e+92) tmp = t_1; else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(y * N[(t / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -6.5e+174], t, If[LessEqual[y, -1.9e-96], t$95$1, If[LessEqual[y, 2.75e-11], N[(x * N[(t / N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 4.9e+92], t$95$1, t]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \frac{t}{y - z}\\
\mathbf{if}\;y \leq -6.5 \cdot 10^{+174}:\\
\;\;\;\;t\\
\mathbf{elif}\;y \leq -1.9 \cdot 10^{-96}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 2.75 \cdot 10^{-11}:\\
\;\;\;\;x \cdot \frac{t}{z - y}\\
\mathbf{elif}\;y \leq 4.9 \cdot 10^{+92}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if y < -6.5000000000000001e174 or 4.9000000000000002e92 < y Initial program 100.0%
associate-*l/67.4%
associate-/l*59.7%
Simplified59.7%
Taylor expanded in y around inf 84.1%
if -6.5000000000000001e174 < y < -1.9e-96 or 2.74999999999999987e-11 < y < 4.9000000000000002e92Initial program 98.6%
associate-*l/92.0%
associate-/l*91.9%
Simplified91.9%
Taylor expanded in x around 0 60.5%
associate-*r/60.5%
mul-1-neg60.5%
distribute-rgt-neg-out60.5%
associate-*l/62.5%
*-commutative62.5%
distribute-lft-neg-out62.5%
distribute-rgt-neg-in62.5%
distribute-frac-neg262.5%
neg-sub062.5%
sub-neg62.5%
+-commutative62.5%
associate--r+62.5%
neg-sub062.5%
remove-double-neg62.5%
Simplified62.5%
if -1.9e-96 < y < 2.74999999999999987e-11Initial program 94.7%
associate-*l/93.7%
associate-/l*92.8%
Simplified92.8%
Taylor expanded in x around inf 80.4%
(FPCore (x y z t)
:precision binary64
(if (<= y -5.6e+84)
t
(if (<= y -1.65e-45)
(* t (/ (- x) y))
(if (<= y -5.8e-138)
(* (/ t z) (- y))
(if (<= y 6.2e-32) (* x (/ t z)) t)))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -5.6e+84) {
tmp = t;
} else if (y <= -1.65e-45) {
tmp = t * (-x / y);
} else if (y <= -5.8e-138) {
tmp = (t / z) * -y;
} else if (y <= 6.2e-32) {
tmp = x * (t / z);
} else {
tmp = t;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (y <= (-5.6d+84)) then
tmp = t
else if (y <= (-1.65d-45)) then
tmp = t * (-x / y)
else if (y <= (-5.8d-138)) then
tmp = (t / z) * -y
else if (y <= 6.2d-32) then
tmp = x * (t / z)
else
tmp = t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -5.6e+84) {
tmp = t;
} else if (y <= -1.65e-45) {
tmp = t * (-x / y);
} else if (y <= -5.8e-138) {
tmp = (t / z) * -y;
} else if (y <= 6.2e-32) {
tmp = x * (t / z);
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -5.6e+84: tmp = t elif y <= -1.65e-45: tmp = t * (-x / y) elif y <= -5.8e-138: tmp = (t / z) * -y elif y <= 6.2e-32: tmp = x * (t / z) else: tmp = t return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -5.6e+84) tmp = t; elseif (y <= -1.65e-45) tmp = Float64(t * Float64(Float64(-x) / y)); elseif (y <= -5.8e-138) tmp = Float64(Float64(t / z) * Float64(-y)); elseif (y <= 6.2e-32) tmp = Float64(x * Float64(t / z)); else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -5.6e+84) tmp = t; elseif (y <= -1.65e-45) tmp = t * (-x / y); elseif (y <= -5.8e-138) tmp = (t / z) * -y; elseif (y <= 6.2e-32) tmp = x * (t / z); else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -5.6e+84], t, If[LessEqual[y, -1.65e-45], N[(t * N[((-x) / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -5.8e-138], N[(N[(t / z), $MachinePrecision] * (-y)), $MachinePrecision], If[LessEqual[y, 6.2e-32], N[(x * N[(t / z), $MachinePrecision]), $MachinePrecision], t]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -5.6 \cdot 10^{+84}:\\
\;\;\;\;t\\
\mathbf{elif}\;y \leq -1.65 \cdot 10^{-45}:\\
\;\;\;\;t \cdot \frac{-x}{y}\\
\mathbf{elif}\;y \leq -5.8 \cdot 10^{-138}:\\
\;\;\;\;\frac{t}{z} \cdot \left(-y\right)\\
\mathbf{elif}\;y \leq 6.2 \cdot 10^{-32}:\\
\;\;\;\;x \cdot \frac{t}{z}\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if y < -5.59999999999999963e84 or 6.20000000000000021e-32 < y Initial program 99.9%
associate-*l/75.3%
associate-/l*71.8%
Simplified71.8%
Taylor expanded in y around inf 67.4%
if -5.59999999999999963e84 < y < -1.65e-45Initial program 99.7%
Taylor expanded in x around inf 56.8%
Taylor expanded in z around 0 45.8%
associate-*r/45.8%
neg-mul-145.8%
Simplified45.8%
if -1.65e-45 < y < -5.79999999999999946e-138Initial program 94.6%
associate-*l/99.4%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in x around 0 74.4%
associate-*r/74.4%
mul-1-neg74.4%
distribute-rgt-neg-out74.4%
associate-*l/74.6%
*-commutative74.6%
distribute-lft-neg-out74.6%
distribute-rgt-neg-in74.6%
distribute-frac-neg274.6%
neg-sub074.6%
sub-neg74.6%
+-commutative74.6%
associate--r+74.6%
neg-sub074.6%
remove-double-neg74.6%
Simplified74.6%
Taylor expanded in y around 0 77.8%
associate-*r/77.8%
neg-mul-177.8%
Simplified77.8%
if -5.79999999999999946e-138 < y < 6.20000000000000021e-32Initial program 94.0%
associate-*l/93.0%
associate-/l*91.9%
Simplified91.9%
Taylor expanded in x around inf 80.8%
Taylor expanded in z around inf 69.7%
Final simplification66.0%
(FPCore (x y z t)
:precision binary64
(if (<= y -1.5e+85)
t
(if (<= y -3.1e-46)
(* (- x) (/ t y))
(if (<= y -5.8e-138)
(* (/ t z) (- y))
(if (<= y 4.3e-32) (* x (/ t z)) t)))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -1.5e+85) {
tmp = t;
} else if (y <= -3.1e-46) {
tmp = -x * (t / y);
} else if (y <= -5.8e-138) {
tmp = (t / z) * -y;
} else if (y <= 4.3e-32) {
tmp = x * (t / z);
} else {
tmp = t;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (y <= (-1.5d+85)) then
tmp = t
else if (y <= (-3.1d-46)) then
tmp = -x * (t / y)
else if (y <= (-5.8d-138)) then
tmp = (t / z) * -y
else if (y <= 4.3d-32) then
tmp = x * (t / z)
else
tmp = t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -1.5e+85) {
tmp = t;
} else if (y <= -3.1e-46) {
tmp = -x * (t / y);
} else if (y <= -5.8e-138) {
tmp = (t / z) * -y;
} else if (y <= 4.3e-32) {
tmp = x * (t / z);
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -1.5e+85: tmp = t elif y <= -3.1e-46: tmp = -x * (t / y) elif y <= -5.8e-138: tmp = (t / z) * -y elif y <= 4.3e-32: tmp = x * (t / z) else: tmp = t return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -1.5e+85) tmp = t; elseif (y <= -3.1e-46) tmp = Float64(Float64(-x) * Float64(t / y)); elseif (y <= -5.8e-138) tmp = Float64(Float64(t / z) * Float64(-y)); elseif (y <= 4.3e-32) tmp = Float64(x * Float64(t / z)); else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -1.5e+85) tmp = t; elseif (y <= -3.1e-46) tmp = -x * (t / y); elseif (y <= -5.8e-138) tmp = (t / z) * -y; elseif (y <= 4.3e-32) tmp = x * (t / z); else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -1.5e+85], t, If[LessEqual[y, -3.1e-46], N[((-x) * N[(t / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -5.8e-138], N[(N[(t / z), $MachinePrecision] * (-y)), $MachinePrecision], If[LessEqual[y, 4.3e-32], N[(x * N[(t / z), $MachinePrecision]), $MachinePrecision], t]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.5 \cdot 10^{+85}:\\
\;\;\;\;t\\
\mathbf{elif}\;y \leq -3.1 \cdot 10^{-46}:\\
\;\;\;\;\left(-x\right) \cdot \frac{t}{y}\\
\mathbf{elif}\;y \leq -5.8 \cdot 10^{-138}:\\
\;\;\;\;\frac{t}{z} \cdot \left(-y\right)\\
\mathbf{elif}\;y \leq 4.3 \cdot 10^{-32}:\\
\;\;\;\;x \cdot \frac{t}{z}\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if y < -1.5e85 or 4.2999999999999999e-32 < y Initial program 99.9%
associate-*l/75.3%
associate-/l*71.8%
Simplified71.8%
Taylor expanded in y around inf 67.4%
if -1.5e85 < y < -3.1000000000000001e-46Initial program 99.7%
associate-*l/97.1%
associate-/l*94.0%
Simplified94.0%
Taylor expanded in x around inf 54.0%
Taylor expanded in z around 0 45.3%
associate-*r/45.3%
neg-mul-145.3%
Simplified45.3%
if -3.1000000000000001e-46 < y < -5.79999999999999946e-138Initial program 94.6%
associate-*l/99.4%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in x around 0 74.4%
associate-*r/74.4%
mul-1-neg74.4%
distribute-rgt-neg-out74.4%
associate-*l/74.6%
*-commutative74.6%
distribute-lft-neg-out74.6%
distribute-rgt-neg-in74.6%
distribute-frac-neg274.6%
neg-sub074.6%
sub-neg74.6%
+-commutative74.6%
associate--r+74.6%
neg-sub074.6%
remove-double-neg74.6%
Simplified74.6%
Taylor expanded in y around 0 77.8%
associate-*r/77.8%
neg-mul-177.8%
Simplified77.8%
if -5.79999999999999946e-138 < y < 4.2999999999999999e-32Initial program 94.0%
associate-*l/93.0%
associate-/l*91.9%
Simplified91.9%
Taylor expanded in x around inf 80.8%
Taylor expanded in z around inf 69.7%
Final simplification65.9%
(FPCore (x y z t)
:precision binary64
(if (<= y -4.8e-45)
(* t (/ (- y x) y))
(if (<= y -1.9e-238)
(* (- x y) (/ t z))
(if (<= y 1.18e-11) (/ (* x t) (- z y)) (* t (/ y (- y z)))))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -4.8e-45) {
tmp = t * ((y - x) / y);
} else if (y <= -1.9e-238) {
tmp = (x - y) * (t / z);
} else if (y <= 1.18e-11) {
tmp = (x * t) / (z - y);
} else {
tmp = t * (y / (y - z));
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (y <= (-4.8d-45)) then
tmp = t * ((y - x) / y)
else if (y <= (-1.9d-238)) then
tmp = (x - y) * (t / z)
else if (y <= 1.18d-11) then
tmp = (x * t) / (z - y)
else
tmp = t * (y / (y - z))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -4.8e-45) {
tmp = t * ((y - x) / y);
} else if (y <= -1.9e-238) {
tmp = (x - y) * (t / z);
} else if (y <= 1.18e-11) {
tmp = (x * t) / (z - y);
} else {
tmp = t * (y / (y - z));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -4.8e-45: tmp = t * ((y - x) / y) elif y <= -1.9e-238: tmp = (x - y) * (t / z) elif y <= 1.18e-11: tmp = (x * t) / (z - y) else: tmp = t * (y / (y - z)) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -4.8e-45) tmp = Float64(t * Float64(Float64(y - x) / y)); elseif (y <= -1.9e-238) tmp = Float64(Float64(x - y) * Float64(t / z)); elseif (y <= 1.18e-11) tmp = Float64(Float64(x * t) / Float64(z - y)); else tmp = Float64(t * Float64(y / Float64(y - z))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -4.8e-45) tmp = t * ((y - x) / y); elseif (y <= -1.9e-238) tmp = (x - y) * (t / z); elseif (y <= 1.18e-11) tmp = (x * t) / (z - y); else tmp = t * (y / (y - z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -4.8e-45], N[(t * N[(N[(y - x), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -1.9e-238], N[(N[(x - y), $MachinePrecision] * N[(t / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.18e-11], N[(N[(x * t), $MachinePrecision] / N[(z - y), $MachinePrecision]), $MachinePrecision], N[(t * N[(y / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.8 \cdot 10^{-45}:\\
\;\;\;\;t \cdot \frac{y - x}{y}\\
\mathbf{elif}\;y \leq -1.9 \cdot 10^{-238}:\\
\;\;\;\;\left(x - y\right) \cdot \frac{t}{z}\\
\mathbf{elif}\;y \leq 1.18 \cdot 10^{-11}:\\
\;\;\;\;\frac{x \cdot t}{z - y}\\
\mathbf{else}:\\
\;\;\;\;t \cdot \frac{y}{y - z}\\
\end{array}
\end{array}
if y < -4.7999999999999998e-45Initial program 99.8%
Taylor expanded in z around 0 78.3%
associate-*r/78.3%
neg-mul-178.3%
neg-sub078.3%
sub-neg78.3%
+-commutative78.3%
associate--r+78.3%
neg-sub078.3%
remove-double-neg78.3%
Simplified78.3%
if -4.7999999999999998e-45 < y < -1.8999999999999998e-238Initial program 95.1%
associate-*l/90.6%
associate-/l*95.1%
Simplified95.1%
Taylor expanded in z around inf 84.8%
if -1.8999999999999998e-238 < y < 1.18e-11Initial program 93.9%
associate-*l/96.0%
associate-/l*92.5%
Simplified92.5%
Taylor expanded in x around inf 85.2%
if 1.18e-11 < y Initial program 99.9%
Taylor expanded in x around 0 86.2%
neg-mul-186.2%
distribute-neg-frac286.2%
neg-sub086.2%
sub-neg86.2%
+-commutative86.2%
associate--r+86.2%
neg-sub086.2%
remove-double-neg86.2%
Simplified86.2%
Final simplification83.2%
(FPCore (x y z t)
:precision binary64
(if (<= y -6e-43)
(* t (/ (- y x) y))
(if (<= y -7.4e-240)
(* (- x y) (/ t z))
(if (<= y 1.22e-9) (/ t (/ (- z y) x)) (* t (/ y (- y z)))))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -6e-43) {
tmp = t * ((y - x) / y);
} else if (y <= -7.4e-240) {
tmp = (x - y) * (t / z);
} else if (y <= 1.22e-9) {
tmp = t / ((z - y) / x);
} else {
tmp = t * (y / (y - z));
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (y <= (-6d-43)) then
tmp = t * ((y - x) / y)
else if (y <= (-7.4d-240)) then
tmp = (x - y) * (t / z)
else if (y <= 1.22d-9) then
tmp = t / ((z - y) / x)
else
tmp = t * (y / (y - z))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -6e-43) {
tmp = t * ((y - x) / y);
} else if (y <= -7.4e-240) {
tmp = (x - y) * (t / z);
} else if (y <= 1.22e-9) {
tmp = t / ((z - y) / x);
} else {
tmp = t * (y / (y - z));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -6e-43: tmp = t * ((y - x) / y) elif y <= -7.4e-240: tmp = (x - y) * (t / z) elif y <= 1.22e-9: tmp = t / ((z - y) / x) else: tmp = t * (y / (y - z)) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -6e-43) tmp = Float64(t * Float64(Float64(y - x) / y)); elseif (y <= -7.4e-240) tmp = Float64(Float64(x - y) * Float64(t / z)); elseif (y <= 1.22e-9) tmp = Float64(t / Float64(Float64(z - y) / x)); else tmp = Float64(t * Float64(y / Float64(y - z))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -6e-43) tmp = t * ((y - x) / y); elseif (y <= -7.4e-240) tmp = (x - y) * (t / z); elseif (y <= 1.22e-9) tmp = t / ((z - y) / x); else tmp = t * (y / (y - z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -6e-43], N[(t * N[(N[(y - x), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -7.4e-240], N[(N[(x - y), $MachinePrecision] * N[(t / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.22e-9], N[(t / N[(N[(z - y), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision], N[(t * N[(y / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -6 \cdot 10^{-43}:\\
\;\;\;\;t \cdot \frac{y - x}{y}\\
\mathbf{elif}\;y \leq -7.4 \cdot 10^{-240}:\\
\;\;\;\;\left(x - y\right) \cdot \frac{t}{z}\\
\mathbf{elif}\;y \leq 1.22 \cdot 10^{-9}:\\
\;\;\;\;\frac{t}{\frac{z - y}{x}}\\
\mathbf{else}:\\
\;\;\;\;t \cdot \frac{y}{y - z}\\
\end{array}
\end{array}
if y < -6.00000000000000007e-43Initial program 99.8%
Taylor expanded in z around 0 78.3%
associate-*r/78.3%
neg-mul-178.3%
neg-sub078.3%
sub-neg78.3%
+-commutative78.3%
associate--r+78.3%
neg-sub078.3%
remove-double-neg78.3%
Simplified78.3%
if -6.00000000000000007e-43 < y < -7.4000000000000003e-240Initial program 95.1%
associate-*l/90.6%
associate-/l*95.1%
Simplified95.1%
Taylor expanded in z around inf 84.8%
if -7.4000000000000003e-240 < y < 1.2199999999999999e-9Initial program 93.9%
Taylor expanded in x around inf 83.0%
*-commutative83.0%
clear-num82.9%
un-div-inv83.9%
Applied egg-rr83.9%
if 1.2199999999999999e-9 < y Initial program 99.9%
Taylor expanded in x around 0 86.2%
neg-mul-186.2%
distribute-neg-frac286.2%
neg-sub086.2%
sub-neg86.2%
+-commutative86.2%
associate--r+86.2%
neg-sub086.2%
remove-double-neg86.2%
Simplified86.2%
Final simplification82.8%
(FPCore (x y z t)
:precision binary64
(if (<= y -1.6e-45)
(* t (/ (- y x) y))
(if (<= y -2.9e-241)
(* (- x y) (/ t z))
(if (<= y 8.5e-15) (* x (/ t (- z y))) (* t (/ y (- y z)))))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -1.6e-45) {
tmp = t * ((y - x) / y);
} else if (y <= -2.9e-241) {
tmp = (x - y) * (t / z);
} else if (y <= 8.5e-15) {
tmp = x * (t / (z - y));
} else {
tmp = t * (y / (y - z));
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (y <= (-1.6d-45)) then
tmp = t * ((y - x) / y)
else if (y <= (-2.9d-241)) then
tmp = (x - y) * (t / z)
else if (y <= 8.5d-15) then
tmp = x * (t / (z - y))
else
tmp = t * (y / (y - z))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -1.6e-45) {
tmp = t * ((y - x) / y);
} else if (y <= -2.9e-241) {
tmp = (x - y) * (t / z);
} else if (y <= 8.5e-15) {
tmp = x * (t / (z - y));
} else {
tmp = t * (y / (y - z));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -1.6e-45: tmp = t * ((y - x) / y) elif y <= -2.9e-241: tmp = (x - y) * (t / z) elif y <= 8.5e-15: tmp = x * (t / (z - y)) else: tmp = t * (y / (y - z)) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -1.6e-45) tmp = Float64(t * Float64(Float64(y - x) / y)); elseif (y <= -2.9e-241) tmp = Float64(Float64(x - y) * Float64(t / z)); elseif (y <= 8.5e-15) tmp = Float64(x * Float64(t / Float64(z - y))); else tmp = Float64(t * Float64(y / Float64(y - z))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -1.6e-45) tmp = t * ((y - x) / y); elseif (y <= -2.9e-241) tmp = (x - y) * (t / z); elseif (y <= 8.5e-15) tmp = x * (t / (z - y)); else tmp = t * (y / (y - z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -1.6e-45], N[(t * N[(N[(y - x), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -2.9e-241], N[(N[(x - y), $MachinePrecision] * N[(t / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 8.5e-15], N[(x * N[(t / N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t * N[(y / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.6 \cdot 10^{-45}:\\
\;\;\;\;t \cdot \frac{y - x}{y}\\
\mathbf{elif}\;y \leq -2.9 \cdot 10^{-241}:\\
\;\;\;\;\left(x - y\right) \cdot \frac{t}{z}\\
\mathbf{elif}\;y \leq 8.5 \cdot 10^{-15}:\\
\;\;\;\;x \cdot \frac{t}{z - y}\\
\mathbf{else}:\\
\;\;\;\;t \cdot \frac{y}{y - z}\\
\end{array}
\end{array}
if y < -1.60000000000000004e-45Initial program 99.8%
Taylor expanded in z around 0 78.3%
associate-*r/78.3%
neg-mul-178.3%
neg-sub078.3%
sub-neg78.3%
+-commutative78.3%
associate--r+78.3%
neg-sub078.3%
remove-double-neg78.3%
Simplified78.3%
if -1.60000000000000004e-45 < y < -2.8999999999999999e-241Initial program 95.1%
associate-*l/90.6%
associate-/l*95.1%
Simplified95.1%
Taylor expanded in z around inf 84.8%
if -2.8999999999999999e-241 < y < 8.50000000000000007e-15Initial program 93.9%
associate-*l/96.0%
associate-/l*92.5%
Simplified92.5%
Taylor expanded in x around inf 83.8%
if 8.50000000000000007e-15 < y Initial program 99.9%
Taylor expanded in x around 0 86.2%
neg-mul-186.2%
distribute-neg-frac286.2%
neg-sub086.2%
sub-neg86.2%
+-commutative86.2%
associate--r+86.2%
neg-sub086.2%
remove-double-neg86.2%
Simplified86.2%
Final simplification82.8%
(FPCore (x y z t) :precision binary64 (if (<= y -5.5e+84) t (if (<= y -3.2e-52) (* (- x) (/ t y)) (if (<= y 5.6e-36) (* x (/ t z)) t))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -5.5e+84) {
tmp = t;
} else if (y <= -3.2e-52) {
tmp = -x * (t / y);
} else if (y <= 5.6e-36) {
tmp = x * (t / z);
} else {
tmp = t;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (y <= (-5.5d+84)) then
tmp = t
else if (y <= (-3.2d-52)) then
tmp = -x * (t / y)
else if (y <= 5.6d-36) then
tmp = x * (t / z)
else
tmp = t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -5.5e+84) {
tmp = t;
} else if (y <= -3.2e-52) {
tmp = -x * (t / y);
} else if (y <= 5.6e-36) {
tmp = x * (t / z);
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -5.5e+84: tmp = t elif y <= -3.2e-52: tmp = -x * (t / y) elif y <= 5.6e-36: tmp = x * (t / z) else: tmp = t return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -5.5e+84) tmp = t; elseif (y <= -3.2e-52) tmp = Float64(Float64(-x) * Float64(t / y)); elseif (y <= 5.6e-36) tmp = Float64(x * Float64(t / z)); else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -5.5e+84) tmp = t; elseif (y <= -3.2e-52) tmp = -x * (t / y); elseif (y <= 5.6e-36) tmp = x * (t / z); else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -5.5e+84], t, If[LessEqual[y, -3.2e-52], N[((-x) * N[(t / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 5.6e-36], N[(x * N[(t / z), $MachinePrecision]), $MachinePrecision], t]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -5.5 \cdot 10^{+84}:\\
\;\;\;\;t\\
\mathbf{elif}\;y \leq -3.2 \cdot 10^{-52}:\\
\;\;\;\;\left(-x\right) \cdot \frac{t}{y}\\
\mathbf{elif}\;y \leq 5.6 \cdot 10^{-36}:\\
\;\;\;\;x \cdot \frac{t}{z}\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if y < -5.5000000000000004e84 or 5.6000000000000002e-36 < y Initial program 99.9%
associate-*l/75.3%
associate-/l*71.8%
Simplified71.8%
Taylor expanded in y around inf 67.4%
if -5.5000000000000004e84 < y < -3.2000000000000001e-52Initial program 99.7%
associate-*l/97.1%
associate-/l*94.2%
Simplified94.2%
Taylor expanded in x around inf 52.6%
Taylor expanded in z around 0 44.2%
associate-*r/44.2%
neg-mul-144.2%
Simplified44.2%
if -3.2000000000000001e-52 < y < 5.6000000000000002e-36Initial program 94.1%
associate-*l/94.0%
associate-/l*93.1%
Simplified93.1%
Taylor expanded in x around inf 76.4%
Taylor expanded in z around inf 65.4%
Final simplification63.1%
(FPCore (x y z t) :precision binary64 (if (<= y -6.8e+156) (- t (* t (/ x y))) (if (<= y 2.4e+129) (* (- x y) (/ t (- z y))) (* t (/ (- y x) y)))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -6.8e+156) {
tmp = t - (t * (x / y));
} else if (y <= 2.4e+129) {
tmp = (x - y) * (t / (z - y));
} else {
tmp = t * ((y - x) / y);
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (y <= (-6.8d+156)) then
tmp = t - (t * (x / y))
else if (y <= 2.4d+129) then
tmp = (x - y) * (t / (z - y))
else
tmp = t * ((y - x) / y)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -6.8e+156) {
tmp = t - (t * (x / y));
} else if (y <= 2.4e+129) {
tmp = (x - y) * (t / (z - y));
} else {
tmp = t * ((y - x) / y);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -6.8e+156: tmp = t - (t * (x / y)) elif y <= 2.4e+129: tmp = (x - y) * (t / (z - y)) else: tmp = t * ((y - x) / y) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -6.8e+156) tmp = Float64(t - Float64(t * Float64(x / y))); elseif (y <= 2.4e+129) tmp = Float64(Float64(x - y) * Float64(t / Float64(z - y))); else tmp = Float64(t * Float64(Float64(y - x) / y)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -6.8e+156) tmp = t - (t * (x / y)); elseif (y <= 2.4e+129) tmp = (x - y) * (t / (z - y)); else tmp = t * ((y - x) / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -6.8e+156], N[(t - N[(t * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.4e+129], N[(N[(x - y), $MachinePrecision] * N[(t / N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t * N[(N[(y - x), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -6.8 \cdot 10^{+156}:\\
\;\;\;\;t - t \cdot \frac{x}{y}\\
\mathbf{elif}\;y \leq 2.4 \cdot 10^{+129}:\\
\;\;\;\;\left(x - y\right) \cdot \frac{t}{z - y}\\
\mathbf{else}:\\
\;\;\;\;t \cdot \frac{y - x}{y}\\
\end{array}
\end{array}
if y < -6.8000000000000002e156Initial program 99.9%
associate-*l/70.0%
associate-/l*50.3%
Simplified50.3%
Taylor expanded in y around inf 84.2%
associate--l+84.2%
distribute-lft-out--84.2%
div-sub84.2%
mul-1-neg84.2%
unsub-neg84.2%
div-sub84.2%
associate-/l*84.2%
associate-/l*92.2%
distribute-lft-out--92.2%
div-sub92.2%
Simplified92.2%
Taylor expanded in x around inf 92.2%
if -6.8000000000000002e156 < y < 2.3999999999999999e129Initial program 96.5%
associate-*l/92.6%
associate-/l*93.5%
Simplified93.5%
if 2.3999999999999999e129 < y Initial program 100.0%
Taylor expanded in z around 0 96.8%
associate-*r/96.8%
neg-mul-196.8%
neg-sub096.8%
sub-neg96.8%
+-commutative96.8%
associate--r+96.8%
neg-sub096.8%
remove-double-neg96.8%
Simplified96.8%
Final simplification93.8%
(FPCore (x y z t) :precision binary64 (if (or (<= x -1.6e+27) (not (<= x 3.2e+143))) (* t (/ x (- z y))) (* t (/ y (- y z)))))
double code(double x, double y, double z, double t) {
double tmp;
if ((x <= -1.6e+27) || !(x <= 3.2e+143)) {
tmp = t * (x / (z - y));
} else {
tmp = t * (y / (y - z));
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if ((x <= (-1.6d+27)) .or. (.not. (x <= 3.2d+143))) then
tmp = t * (x / (z - y))
else
tmp = t * (y / (y - z))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if ((x <= -1.6e+27) || !(x <= 3.2e+143)) {
tmp = t * (x / (z - y));
} else {
tmp = t * (y / (y - z));
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (x <= -1.6e+27) or not (x <= 3.2e+143): tmp = t * (x / (z - y)) else: tmp = t * (y / (y - z)) return tmp
function code(x, y, z, t) tmp = 0.0 if ((x <= -1.6e+27) || !(x <= 3.2e+143)) tmp = Float64(t * Float64(x / Float64(z - y))); else tmp = Float64(t * Float64(y / Float64(y - z))); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((x <= -1.6e+27) || ~((x <= 3.2e+143))) tmp = t * (x / (z - y)); else tmp = t * (y / (y - z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[x, -1.6e+27], N[Not[LessEqual[x, 3.2e+143]], $MachinePrecision]], N[(t * N[(x / N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t * N[(y / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.6 \cdot 10^{+27} \lor \neg \left(x \leq 3.2 \cdot 10^{+143}\right):\\
\;\;\;\;t \cdot \frac{x}{z - y}\\
\mathbf{else}:\\
\;\;\;\;t \cdot \frac{y}{y - z}\\
\end{array}
\end{array}
if x < -1.60000000000000008e27 or 3.20000000000000016e143 < x Initial program 94.8%
Taylor expanded in x around inf 77.5%
if -1.60000000000000008e27 < x < 3.20000000000000016e143Initial program 98.7%
Taylor expanded in x around 0 76.7%
neg-mul-176.7%
distribute-neg-frac276.7%
neg-sub076.7%
sub-neg76.7%
+-commutative76.7%
associate--r+76.7%
neg-sub076.7%
remove-double-neg76.7%
Simplified76.7%
Final simplification77.0%
(FPCore (x y z t) :precision binary64 (if (<= y -4e+85) t (if (<= y 0.075) (* x (/ t (- z y))) t)))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -4e+85) {
tmp = t;
} else if (y <= 0.075) {
tmp = x * (t / (z - y));
} else {
tmp = t;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (y <= (-4d+85)) then
tmp = t
else if (y <= 0.075d0) then
tmp = x * (t / (z - y))
else
tmp = t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -4e+85) {
tmp = t;
} else if (y <= 0.075) {
tmp = x * (t / (z - y));
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -4e+85: tmp = t elif y <= 0.075: tmp = x * (t / (z - y)) else: tmp = t return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -4e+85) tmp = t; elseif (y <= 0.075) tmp = Float64(x * Float64(t / Float64(z - y))); else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -4e+85) tmp = t; elseif (y <= 0.075) tmp = x * (t / (z - y)); else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -4e+85], t, If[LessEqual[y, 0.075], N[(x * N[(t / N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4 \cdot 10^{+85}:\\
\;\;\;\;t\\
\mathbf{elif}\;y \leq 0.075:\\
\;\;\;\;x \cdot \frac{t}{z - y}\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if y < -4.0000000000000001e85 or 0.0749999999999999972 < y Initial program 99.9%
associate-*l/74.6%
associate-/l*70.9%
Simplified70.9%
Taylor expanded in y around inf 68.3%
if -4.0000000000000001e85 < y < 0.0749999999999999972Initial program 95.5%
associate-*l/94.8%
associate-/l*93.5%
Simplified93.5%
Taylor expanded in x around inf 70.6%
(FPCore (x y z t) :precision binary64 (if (<= y -4.6e-43) t (if (<= y 3.2e-32) (* x (/ t z)) t)))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -4.6e-43) {
tmp = t;
} else if (y <= 3.2e-32) {
tmp = x * (t / z);
} else {
tmp = t;
}
return tmp;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8) :: tmp
if (y <= (-4.6d-43)) then
tmp = t
else if (y <= 3.2d-32) then
tmp = x * (t / z)
else
tmp = t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -4.6e-43) {
tmp = t;
} else if (y <= 3.2e-32) {
tmp = x * (t / z);
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -4.6e-43: tmp = t elif y <= 3.2e-32: tmp = x * (t / z) else: tmp = t return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -4.6e-43) tmp = t; elseif (y <= 3.2e-32) tmp = Float64(x * Float64(t / z)); else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -4.6e-43) tmp = t; elseif (y <= 3.2e-32) tmp = x * (t / z); else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -4.6e-43], t, If[LessEqual[y, 3.2e-32], N[(x * N[(t / z), $MachinePrecision]), $MachinePrecision], t]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.6 \cdot 10^{-43}:\\
\;\;\;\;t\\
\mathbf{elif}\;y \leq 3.2 \cdot 10^{-32}:\\
\;\;\;\;x \cdot \frac{t}{z}\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if y < -4.5999999999999998e-43 or 3.2000000000000002e-32 < y Initial program 99.9%
associate-*l/80.9%
associate-/l*77.5%
Simplified77.5%
Taylor expanded in y around inf 57.4%
if -4.5999999999999998e-43 < y < 3.2000000000000002e-32Initial program 94.1%
associate-*l/94.0%
associate-/l*93.2%
Simplified93.2%
Taylor expanded in x around inf 75.8%
Taylor expanded in z around inf 64.8%
(FPCore (x y z t) :precision binary64 t)
double code(double x, double y, double z, double t) {
return t;
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = t
end function
public static double code(double x, double y, double z, double t) {
return t;
}
def code(x, y, z, t): return t
function code(x, y, z, t) return t end
function tmp = code(x, y, z, t) tmp = t; end
code[x_, y_, z_, t_] := t
\begin{array}{l}
\\
t
\end{array}
Initial program 97.3%
associate-*l/86.9%
associate-/l*84.6%
Simplified84.6%
Taylor expanded in y around inf 34.4%
(FPCore (x y z t) :precision binary64 (/ t (/ (- z y) (- x y))))
double code(double x, double y, double z, double t) {
return t / ((z - y) / (x - y));
}
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = t / ((z - y) / (x - y))
end function
public static double code(double x, double y, double z, double t) {
return t / ((z - y) / (x - y));
}
def code(x, y, z, t): return t / ((z - y) / (x - y))
function code(x, y, z, t) return Float64(t / Float64(Float64(z - y) / Float64(x - y))) end
function tmp = code(x, y, z, t) tmp = t / ((z - y) / (x - y)); end
code[x_, y_, z_, t_] := N[(t / N[(N[(z - y), $MachinePrecision] / N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{t}{\frac{z - y}{x - y}}
\end{array}
herbie shell --seed 2024146
(FPCore (x y z t)
:name "Numeric.Signal.Multichannel:$cput from hsignal-0.2.7.1"
:precision binary64
:alt
(! :herbie-platform default (/ t (/ (- z y) (- x y))))
(* (/ (- x y) (- z y)) t))