
(FPCore (x y z t) :precision binary64 (/ x (* (- y z) (- t z))))
double code(double x, double y, double z, double t) {
return x / ((y - z) * (t - z));
}
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) * (t - z))
end function
public static double code(double x, double y, double z, double t) {
return x / ((y - z) * (t - z));
}
def code(x, y, z, t): return x / ((y - z) * (t - z))
function code(x, y, z, t) return Float64(x / Float64(Float64(y - z) * Float64(t - z))) end
function tmp = code(x, y, z, t) tmp = x / ((y - z) * (t - z)); end
code[x_, y_, z_, t_] := N[(x / N[(N[(y - z), $MachinePrecision] * N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x}{\left(y - z\right) \cdot \left(t - z\right)}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 20 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t) :precision binary64 (/ x (* (- y z) (- t z))))
double code(double x, double y, double z, double t) {
return x / ((y - z) * (t - z));
}
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) * (t - z))
end function
public static double code(double x, double y, double z, double t) {
return x / ((y - z) * (t - z));
}
def code(x, y, z, t): return x / ((y - z) * (t - z))
function code(x, y, z, t) return Float64(x / Float64(Float64(y - z) * Float64(t - z))) end
function tmp = code(x, y, z, t) tmp = x / ((y - z) * (t - z)); end
code[x_, y_, z_, t_] := N[(x / N[(N[(y - z), $MachinePrecision] * N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x}{\left(y - z\right) \cdot \left(t - z\right)}
\end{array}
(FPCore (x y z t) :precision binary64 (let* ((t_1 (/ x (* (- y z) (- t z))))) (if (<= t_1 0.0) (* (/ 1.0 (- y z)) (/ x (- t z))) t_1)))
double code(double x, double y, double z, double t) {
double t_1 = x / ((y - z) * (t - z));
double tmp;
if (t_1 <= 0.0) {
tmp = (1.0 / (y - z)) * (x / (t - z));
} else {
tmp = t_1;
}
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 = x / ((y - z) * (t - z))
if (t_1 <= 0.0d0) then
tmp = (1.0d0 / (y - z)) * (x / (t - z))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = x / ((y - z) * (t - z));
double tmp;
if (t_1 <= 0.0) {
tmp = (1.0 / (y - z)) * (x / (t - z));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t): t_1 = x / ((y - z) * (t - z)) tmp = 0 if t_1 <= 0.0: tmp = (1.0 / (y - z)) * (x / (t - z)) else: tmp = t_1 return tmp
function code(x, y, z, t) t_1 = Float64(x / Float64(Float64(y - z) * Float64(t - z))) tmp = 0.0 if (t_1 <= 0.0) tmp = Float64(Float64(1.0 / Float64(y - z)) * Float64(x / Float64(t - z))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = x / ((y - z) * (t - z)); tmp = 0.0; if (t_1 <= 0.0) tmp = (1.0 / (y - z)) * (x / (t - z)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x / N[(N[(y - z), $MachinePrecision] * N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, 0.0], N[(N[(1.0 / N[(y - z), $MachinePrecision]), $MachinePrecision] * N[(x / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x}{\left(y - z\right) \cdot \left(t - z\right)}\\
\mathbf{if}\;t_1 \leq 0:\\
\;\;\;\;\frac{1}{y - z} \cdot \frac{x}{t - z}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if (/.f64 x (*.f64 (-.f64 y z) (-.f64 t z))) < -0.0Initial program 86.7%
*-un-lft-identity86.7%
times-frac99.0%
Applied egg-rr99.0%
if -0.0 < (/.f64 x (*.f64 (-.f64 y z) (-.f64 t z))) Initial program 99.7%
Final simplification99.1%
(FPCore (x y z t) :precision binary64 (* (/ (pow (cbrt x) 2.0) (- y z)) (/ (cbrt x) (- t z))))
double code(double x, double y, double z, double t) {
return (pow(cbrt(x), 2.0) / (y - z)) * (cbrt(x) / (t - z));
}
public static double code(double x, double y, double z, double t) {
return (Math.pow(Math.cbrt(x), 2.0) / (y - z)) * (Math.cbrt(x) / (t - z));
}
function code(x, y, z, t) return Float64(Float64((cbrt(x) ^ 2.0) / Float64(y - z)) * Float64(cbrt(x) / Float64(t - z))) end
code[x_, y_, z_, t_] := N[(N[(N[Power[N[Power[x, 1/3], $MachinePrecision], 2.0], $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision] * N[(N[Power[x, 1/3], $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{{\left(\sqrt[3]{x}\right)}^{2}}{y - z} \cdot \frac{\sqrt[3]{x}}{t - z}
\end{array}
Initial program 90.0%
add-cube-cbrt89.3%
times-frac97.8%
pow297.8%
Applied egg-rr97.8%
Final simplification97.8%
(FPCore (x y z t) :precision binary64 (let* ((t_1 (* (- y z) (- t z)))) (if (<= t_1 5e+304) (/ x t_1) (* (/ -1.0 z) (/ x (- y z))))))
double code(double x, double y, double z, double t) {
double t_1 = (y - z) * (t - z);
double tmp;
if (t_1 <= 5e+304) {
tmp = x / t_1;
} else {
tmp = (-1.0 / z) * (x / (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) :: t_1
real(8) :: tmp
t_1 = (y - z) * (t - z)
if (t_1 <= 5d+304) then
tmp = x / t_1
else
tmp = ((-1.0d0) / z) * (x / (y - z))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = (y - z) * (t - z);
double tmp;
if (t_1 <= 5e+304) {
tmp = x / t_1;
} else {
tmp = (-1.0 / z) * (x / (y - z));
}
return tmp;
}
def code(x, y, z, t): t_1 = (y - z) * (t - z) tmp = 0 if t_1 <= 5e+304: tmp = x / t_1 else: tmp = (-1.0 / z) * (x / (y - z)) return tmp
function code(x, y, z, t) t_1 = Float64(Float64(y - z) * Float64(t - z)) tmp = 0.0 if (t_1 <= 5e+304) tmp = Float64(x / t_1); else tmp = Float64(Float64(-1.0 / z) * Float64(x / Float64(y - z))); end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = (y - z) * (t - z); tmp = 0.0; if (t_1 <= 5e+304) tmp = x / t_1; else tmp = (-1.0 / z) * (x / (y - z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(y - z), $MachinePrecision] * N[(t - z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, 5e+304], N[(x / t$95$1), $MachinePrecision], N[(N[(-1.0 / z), $MachinePrecision] * N[(x / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(y - z\right) \cdot \left(t - z\right)\\
\mathbf{if}\;t_1 \leq 5 \cdot 10^{+304}:\\
\;\;\;\;\frac{x}{t_1}\\
\mathbf{else}:\\
\;\;\;\;\frac{-1}{z} \cdot \frac{x}{y - z}\\
\end{array}
\end{array}
if (*.f64 (-.f64 y z) (-.f64 t z)) < 4.9999999999999997e304Initial program 95.5%
if 4.9999999999999997e304 < (*.f64 (-.f64 y z) (-.f64 t z)) Initial program 75.8%
associate-/r*99.9%
div-inv99.8%
Applied egg-rr99.8%
Taylor expanded in t around 0 79.2%
Final simplification90.9%
(FPCore (x y z t) :precision binary64 (let* ((t_1 (* (- y z) (- t z)))) (if (<= t_1 5e+304) (/ x t_1) (/ (/ -1.0 z) (/ (- y z) x)))))
double code(double x, double y, double z, double t) {
double t_1 = (y - z) * (t - z);
double tmp;
if (t_1 <= 5e+304) {
tmp = x / t_1;
} else {
tmp = (-1.0 / z) / ((y - z) / x);
}
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 - z) * (t - z)
if (t_1 <= 5d+304) then
tmp = x / t_1
else
tmp = ((-1.0d0) / z) / ((y - z) / x)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = (y - z) * (t - z);
double tmp;
if (t_1 <= 5e+304) {
tmp = x / t_1;
} else {
tmp = (-1.0 / z) / ((y - z) / x);
}
return tmp;
}
def code(x, y, z, t): t_1 = (y - z) * (t - z) tmp = 0 if t_1 <= 5e+304: tmp = x / t_1 else: tmp = (-1.0 / z) / ((y - z) / x) return tmp
function code(x, y, z, t) t_1 = Float64(Float64(y - z) * Float64(t - z)) tmp = 0.0 if (t_1 <= 5e+304) tmp = Float64(x / t_1); else tmp = Float64(Float64(-1.0 / z) / Float64(Float64(y - z) / x)); end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = (y - z) * (t - z); tmp = 0.0; if (t_1 <= 5e+304) tmp = x / t_1; else tmp = (-1.0 / z) / ((y - z) / x); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(y - z), $MachinePrecision] * N[(t - z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, 5e+304], N[(x / t$95$1), $MachinePrecision], N[(N[(-1.0 / z), $MachinePrecision] / N[(N[(y - z), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(y - z\right) \cdot \left(t - z\right)\\
\mathbf{if}\;t_1 \leq 5 \cdot 10^{+304}:\\
\;\;\;\;\frac{x}{t_1}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{-1}{z}}{\frac{y - z}{x}}\\
\end{array}
\end{array}
if (*.f64 (-.f64 y z) (-.f64 t z)) < 4.9999999999999997e304Initial program 95.5%
if 4.9999999999999997e304 < (*.f64 (-.f64 y z) (-.f64 t z)) Initial program 75.8%
add-cube-cbrt75.8%
times-frac99.5%
pow299.5%
Applied egg-rr99.5%
frac-times75.8%
unpow275.8%
add-cube-cbrt75.8%
associate-/r*99.9%
un-div-inv99.8%
*-commutative99.8%
clear-num99.8%
un-div-inv99.8%
Applied egg-rr99.8%
Taylor expanded in t around 0 81.6%
Final simplification91.6%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (/ (- x) (* y z))))
(if (<= z -1260.0)
t_1
(if (<= z 3.8e-140)
(/ (/ x y) t)
(if (<= z 6.5e+143) t_1 (/ (/ x z) t))))))
double code(double x, double y, double z, double t) {
double t_1 = -x / (y * z);
double tmp;
if (z <= -1260.0) {
tmp = t_1;
} else if (z <= 3.8e-140) {
tmp = (x / y) / t;
} else if (z <= 6.5e+143) {
tmp = t_1;
} else {
tmp = (x / z) / 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 = -x / (y * z)
if (z <= (-1260.0d0)) then
tmp = t_1
else if (z <= 3.8d-140) then
tmp = (x / y) / t
else if (z <= 6.5d+143) then
tmp = t_1
else
tmp = (x / z) / t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = -x / (y * z);
double tmp;
if (z <= -1260.0) {
tmp = t_1;
} else if (z <= 3.8e-140) {
tmp = (x / y) / t;
} else if (z <= 6.5e+143) {
tmp = t_1;
} else {
tmp = (x / z) / t;
}
return tmp;
}
def code(x, y, z, t): t_1 = -x / (y * z) tmp = 0 if z <= -1260.0: tmp = t_1 elif z <= 3.8e-140: tmp = (x / y) / t elif z <= 6.5e+143: tmp = t_1 else: tmp = (x / z) / t return tmp
function code(x, y, z, t) t_1 = Float64(Float64(-x) / Float64(y * z)) tmp = 0.0 if (z <= -1260.0) tmp = t_1; elseif (z <= 3.8e-140) tmp = Float64(Float64(x / y) / t); elseif (z <= 6.5e+143) tmp = t_1; else tmp = Float64(Float64(x / z) / t); end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = -x / (y * z); tmp = 0.0; if (z <= -1260.0) tmp = t_1; elseif (z <= 3.8e-140) tmp = (x / y) / t; elseif (z <= 6.5e+143) tmp = t_1; else tmp = (x / z) / t; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[((-x) / N[(y * z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1260.0], t$95$1, If[LessEqual[z, 3.8e-140], N[(N[(x / y), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[z, 6.5e+143], t$95$1, N[(N[(x / z), $MachinePrecision] / t), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{-x}{y \cdot z}\\
\mathbf{if}\;z \leq -1260:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq 3.8 \cdot 10^{-140}:\\
\;\;\;\;\frac{\frac{x}{y}}{t}\\
\mathbf{elif}\;z \leq 6.5 \cdot 10^{+143}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{x}{z}}{t}\\
\end{array}
\end{array}
if z < -1260 or 3.79999999999999998e-140 < z < 6.4999999999999997e143Initial program 92.9%
Taylor expanded in y around inf 51.3%
*-commutative51.3%
Simplified51.3%
Taylor expanded in t around 0 40.0%
associate-*r/40.0%
neg-mul-140.0%
*-commutative40.0%
Simplified40.0%
if -1260 < z < 3.79999999999999998e-140Initial program 91.5%
add-cube-cbrt90.6%
times-frac96.0%
pow296.0%
Applied egg-rr96.0%
frac-times90.6%
unpow290.6%
add-cube-cbrt91.5%
associate-/r*92.8%
un-div-inv92.7%
*-commutative92.7%
clear-num92.6%
un-div-inv92.7%
Applied egg-rr92.7%
Taylor expanded in z around 0 71.4%
associate-/l/73.6%
Simplified73.6%
if 6.4999999999999997e143 < z Initial program 74.5%
Taylor expanded in y around 0 74.5%
associate-*r/74.5%
neg-mul-174.5%
Simplified74.5%
Taylor expanded in z around 0 42.0%
associate-*r/42.0%
neg-mul-142.0%
Simplified42.0%
clear-num42.1%
associate-/r/42.0%
add-sqr-sqrt16.8%
sqrt-unprod46.7%
sqr-neg46.7%
sqrt-unprod25.3%
add-sqr-sqrt42.2%
Applied egg-rr42.2%
associate-/r/42.3%
associate-/l*50.2%
clear-num50.0%
Applied egg-rr50.0%
Final simplification55.2%
(FPCore (x y z t)
:precision binary64
(if (<= z -55000.0)
(/ (/ x z) (- t))
(if (<= z 3.8e-140)
(/ (/ x y) t)
(if (<= z 8.5e+144) (/ (- x) (* y z)) (/ (/ x z) t)))))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -55000.0) {
tmp = (x / z) / -t;
} else if (z <= 3.8e-140) {
tmp = (x / y) / t;
} else if (z <= 8.5e+144) {
tmp = -x / (y * z);
} else {
tmp = (x / z) / 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 (z <= (-55000.0d0)) then
tmp = (x / z) / -t
else if (z <= 3.8d-140) then
tmp = (x / y) / t
else if (z <= 8.5d+144) then
tmp = -x / (y * z)
else
tmp = (x / z) / t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -55000.0) {
tmp = (x / z) / -t;
} else if (z <= 3.8e-140) {
tmp = (x / y) / t;
} else if (z <= 8.5e+144) {
tmp = -x / (y * z);
} else {
tmp = (x / z) / t;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -55000.0: tmp = (x / z) / -t elif z <= 3.8e-140: tmp = (x / y) / t elif z <= 8.5e+144: tmp = -x / (y * z) else: tmp = (x / z) / t return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -55000.0) tmp = Float64(Float64(x / z) / Float64(-t)); elseif (z <= 3.8e-140) tmp = Float64(Float64(x / y) / t); elseif (z <= 8.5e+144) tmp = Float64(Float64(-x) / Float64(y * z)); else tmp = Float64(Float64(x / z) / t); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -55000.0) tmp = (x / z) / -t; elseif (z <= 3.8e-140) tmp = (x / y) / t; elseif (z <= 8.5e+144) tmp = -x / (y * z); else tmp = (x / z) / t; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -55000.0], N[(N[(x / z), $MachinePrecision] / (-t)), $MachinePrecision], If[LessEqual[z, 3.8e-140], N[(N[(x / y), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[z, 8.5e+144], N[((-x) / N[(y * z), $MachinePrecision]), $MachinePrecision], N[(N[(x / z), $MachinePrecision] / t), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -55000:\\
\;\;\;\;\frac{\frac{x}{z}}{-t}\\
\mathbf{elif}\;z \leq 3.8 \cdot 10^{-140}:\\
\;\;\;\;\frac{\frac{x}{y}}{t}\\
\mathbf{elif}\;z \leq 8.5 \cdot 10^{+144}:\\
\;\;\;\;\frac{-x}{y \cdot z}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{x}{z}}{t}\\
\end{array}
\end{array}
if z < -55000Initial program 88.9%
Taylor expanded in y around 0 78.1%
associate-*r/78.1%
neg-mul-178.1%
Simplified78.1%
Taylor expanded in z around 0 39.1%
associate-*r/39.1%
neg-mul-139.1%
Simplified39.1%
clear-num39.5%
associate-/r/39.1%
add-sqr-sqrt19.6%
sqrt-unprod43.1%
sqr-neg43.1%
sqrt-unprod16.1%
add-sqr-sqrt30.7%
Applied egg-rr30.7%
*-commutative30.7%
add-sqr-sqrt16.1%
sqrt-unprod43.1%
sqr-neg43.1%
sqrt-unprod19.6%
add-sqr-sqrt39.1%
div-inv39.1%
associate-/r*43.0%
div-inv43.0%
div-inv43.0%
distribute-lft-neg-out43.0%
div-inv43.0%
remove-double-neg43.0%
distribute-frac-neg43.0%
distribute-frac-neg43.0%
remove-double-neg43.0%
frac-2neg43.0%
distribute-frac-neg43.0%
remove-double-neg43.0%
associate-*l/53.4%
div-inv53.4%
Applied egg-rr53.4%
if -55000 < z < 3.79999999999999998e-140Initial program 91.6%
add-cube-cbrt90.6%
times-frac96.0%
pow296.0%
Applied egg-rr96.0%
frac-times90.6%
unpow290.6%
add-cube-cbrt91.6%
associate-/r*92.8%
un-div-inv92.7%
*-commutative92.7%
clear-num92.7%
un-div-inv92.7%
Applied egg-rr92.7%
Taylor expanded in z around 0 70.9%
associate-/l/73.0%
Simplified73.0%
if 3.79999999999999998e-140 < z < 8.4999999999999998e144Initial program 96.6%
Taylor expanded in y around inf 54.8%
*-commutative54.8%
Simplified54.8%
Taylor expanded in t around 0 37.6%
associate-*r/37.6%
neg-mul-137.6%
*-commutative37.6%
Simplified37.6%
if 8.4999999999999998e144 < z Initial program 74.5%
Taylor expanded in y around 0 74.5%
associate-*r/74.5%
neg-mul-174.5%
Simplified74.5%
Taylor expanded in z around 0 42.0%
associate-*r/42.0%
neg-mul-142.0%
Simplified42.0%
clear-num42.1%
associate-/r/42.0%
add-sqr-sqrt16.8%
sqrt-unprod46.7%
sqr-neg46.7%
sqrt-unprod25.3%
add-sqr-sqrt42.2%
Applied egg-rr42.2%
associate-/r/42.3%
associate-/l*50.2%
clear-num50.0%
Applied egg-rr50.0%
Final simplification57.4%
(FPCore (x y z t)
:precision binary64
(if (<= z -6600.0)
(/ (/ x z) (- t))
(if (<= z 3.6e-140)
(/ (/ x y) t)
(if (<= z 1.4e+258) (/ (/ (- x) y) z) (/ (/ x z) t)))))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -6600.0) {
tmp = (x / z) / -t;
} else if (z <= 3.6e-140) {
tmp = (x / y) / t;
} else if (z <= 1.4e+258) {
tmp = (-x / y) / z;
} else {
tmp = (x / z) / 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 (z <= (-6600.0d0)) then
tmp = (x / z) / -t
else if (z <= 3.6d-140) then
tmp = (x / y) / t
else if (z <= 1.4d+258) then
tmp = (-x / y) / z
else
tmp = (x / z) / t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -6600.0) {
tmp = (x / z) / -t;
} else if (z <= 3.6e-140) {
tmp = (x / y) / t;
} else if (z <= 1.4e+258) {
tmp = (-x / y) / z;
} else {
tmp = (x / z) / t;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -6600.0: tmp = (x / z) / -t elif z <= 3.6e-140: tmp = (x / y) / t elif z <= 1.4e+258: tmp = (-x / y) / z else: tmp = (x / z) / t return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -6600.0) tmp = Float64(Float64(x / z) / Float64(-t)); elseif (z <= 3.6e-140) tmp = Float64(Float64(x / y) / t); elseif (z <= 1.4e+258) tmp = Float64(Float64(Float64(-x) / y) / z); else tmp = Float64(Float64(x / z) / t); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -6600.0) tmp = (x / z) / -t; elseif (z <= 3.6e-140) tmp = (x / y) / t; elseif (z <= 1.4e+258) tmp = (-x / y) / z; else tmp = (x / z) / t; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -6600.0], N[(N[(x / z), $MachinePrecision] / (-t)), $MachinePrecision], If[LessEqual[z, 3.6e-140], N[(N[(x / y), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[z, 1.4e+258], N[(N[((-x) / y), $MachinePrecision] / z), $MachinePrecision], N[(N[(x / z), $MachinePrecision] / t), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -6600:\\
\;\;\;\;\frac{\frac{x}{z}}{-t}\\
\mathbf{elif}\;z \leq 3.6 \cdot 10^{-140}:\\
\;\;\;\;\frac{\frac{x}{y}}{t}\\
\mathbf{elif}\;z \leq 1.4 \cdot 10^{+258}:\\
\;\;\;\;\frac{\frac{-x}{y}}{z}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{x}{z}}{t}\\
\end{array}
\end{array}
if z < -6600Initial program 88.9%
Taylor expanded in y around 0 78.1%
associate-*r/78.1%
neg-mul-178.1%
Simplified78.1%
Taylor expanded in z around 0 39.1%
associate-*r/39.1%
neg-mul-139.1%
Simplified39.1%
clear-num39.5%
associate-/r/39.1%
add-sqr-sqrt19.6%
sqrt-unprod43.1%
sqr-neg43.1%
sqrt-unprod16.1%
add-sqr-sqrt30.7%
Applied egg-rr30.7%
*-commutative30.7%
add-sqr-sqrt16.1%
sqrt-unprod43.1%
sqr-neg43.1%
sqrt-unprod19.6%
add-sqr-sqrt39.1%
div-inv39.1%
associate-/r*43.0%
div-inv43.0%
div-inv43.0%
distribute-lft-neg-out43.0%
div-inv43.0%
remove-double-neg43.0%
distribute-frac-neg43.0%
distribute-frac-neg43.0%
remove-double-neg43.0%
frac-2neg43.0%
distribute-frac-neg43.0%
remove-double-neg43.0%
associate-*l/53.4%
div-inv53.4%
Applied egg-rr53.4%
if -6600 < z < 3.6e-140Initial program 91.6%
add-cube-cbrt90.6%
times-frac96.0%
pow296.0%
Applied egg-rr96.0%
frac-times90.6%
unpow290.6%
add-cube-cbrt91.6%
associate-/r*92.8%
un-div-inv92.7%
*-commutative92.7%
clear-num92.7%
un-div-inv92.7%
Applied egg-rr92.7%
Taylor expanded in z around 0 70.9%
associate-/l/73.0%
Simplified73.0%
if 3.6e-140 < z < 1.39999999999999991e258Initial program 87.5%
add-cube-cbrt87.0%
times-frac99.1%
pow299.1%
Applied egg-rr99.1%
Taylor expanded in y around inf 46.1%
associate-/r*47.3%
Simplified47.3%
Taylor expanded in t around 0 33.8%
mul-1-neg33.8%
associate-/r*34.7%
distribute-neg-frac34.7%
distribute-neg-frac34.7%
Simplified34.7%
if 1.39999999999999991e258 < z Initial program 100.0%
Taylor expanded in y around 0 100.0%
associate-*r/100.0%
neg-mul-1100.0%
Simplified100.0%
Taylor expanded in z around 0 58.0%
associate-*r/58.0%
neg-mul-158.0%
Simplified58.0%
clear-num58.0%
associate-/r/58.0%
add-sqr-sqrt34.0%
sqrt-unprod68.3%
sqr-neg68.3%
sqrt-unprod24.0%
add-sqr-sqrt58.0%
Applied egg-rr58.0%
associate-/r/58.0%
associate-/l*78.3%
clear-num78.3%
Applied egg-rr78.3%
Final simplification56.3%
(FPCore (x y z t)
:precision binary64
(let* ((t_1 (/ (/ (- x) z) z)))
(if (<= z -1.16e+72)
t_1
(if (<= z 3.8e-140)
(/ (/ x y) t)
(if (<= z 1.5e+143) (/ (- x) (* y z)) t_1)))))
double code(double x, double y, double z, double t) {
double t_1 = (-x / z) / z;
double tmp;
if (z <= -1.16e+72) {
tmp = t_1;
} else if (z <= 3.8e-140) {
tmp = (x / y) / t;
} else if (z <= 1.5e+143) {
tmp = -x / (y * z);
} else {
tmp = t_1;
}
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 = (-x / z) / z
if (z <= (-1.16d+72)) then
tmp = t_1
else if (z <= 3.8d-140) then
tmp = (x / y) / t
else if (z <= 1.5d+143) then
tmp = -x / (y * z)
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = (-x / z) / z;
double tmp;
if (z <= -1.16e+72) {
tmp = t_1;
} else if (z <= 3.8e-140) {
tmp = (x / y) / t;
} else if (z <= 1.5e+143) {
tmp = -x / (y * z);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t): t_1 = (-x / z) / z tmp = 0 if z <= -1.16e+72: tmp = t_1 elif z <= 3.8e-140: tmp = (x / y) / t elif z <= 1.5e+143: tmp = -x / (y * z) else: tmp = t_1 return tmp
function code(x, y, z, t) t_1 = Float64(Float64(Float64(-x) / z) / z) tmp = 0.0 if (z <= -1.16e+72) tmp = t_1; elseif (z <= 3.8e-140) tmp = Float64(Float64(x / y) / t); elseif (z <= 1.5e+143) tmp = Float64(Float64(-x) / Float64(y * z)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = (-x / z) / z; tmp = 0.0; if (z <= -1.16e+72) tmp = t_1; elseif (z <= 3.8e-140) tmp = (x / y) / t; elseif (z <= 1.5e+143) tmp = -x / (y * z); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[((-x) / z), $MachinePrecision] / z), $MachinePrecision]}, If[LessEqual[z, -1.16e+72], t$95$1, If[LessEqual[z, 3.8e-140], N[(N[(x / y), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[z, 1.5e+143], N[((-x) / N[(y * z), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{\frac{-x}{z}}{z}\\
\mathbf{if}\;z \leq -1.16 \cdot 10^{+72}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;z \leq 3.8 \cdot 10^{-140}:\\
\;\;\;\;\frac{\frac{x}{y}}{t}\\
\mathbf{elif}\;z \leq 1.5 \cdot 10^{+143}:\\
\;\;\;\;\frac{-x}{y \cdot z}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if z < -1.16000000000000003e72 or 1.5e143 < z Initial program 80.5%
add-cube-cbrt80.4%
times-frac99.5%
pow299.5%
Applied egg-rr99.5%
Taylor expanded in t around 0 77.9%
associate-/r*90.0%
associate-*r/90.0%
associate-*r/90.0%
neg-mul-190.0%
Simplified90.0%
expm1-log1p-u87.2%
expm1-udef71.6%
associate-/l/71.6%
add-sqr-sqrt31.0%
sqrt-unprod67.5%
sqr-neg67.5%
sqrt-unprod39.3%
add-sqr-sqrt70.4%
*-commutative70.4%
Applied egg-rr70.4%
expm1-def70.3%
expm1-log1p70.3%
*-rgt-identity70.3%
times-frac69.4%
associate-*l/69.4%
associate-*r/69.4%
*-rgt-identity69.4%
Simplified69.4%
Taylor expanded in y around 0 65.9%
associate-*r/65.9%
neg-mul-165.9%
Simplified65.9%
if -1.16000000000000003e72 < z < 3.79999999999999998e-140Initial program 92.6%
add-cube-cbrt91.6%
times-frac96.3%
pow296.3%
Applied egg-rr96.3%
frac-times91.6%
unpow291.6%
add-cube-cbrt92.6%
associate-/r*93.7%
un-div-inv93.6%
*-commutative93.6%
clear-num93.5%
un-div-inv93.6%
Applied egg-rr93.6%
Taylor expanded in z around 0 65.0%
associate-/l/67.6%
Simplified67.6%
if 3.79999999999999998e-140 < z < 1.5e143Initial program 96.5%
Taylor expanded in y around inf 55.7%
*-commutative55.7%
Simplified55.7%
Taylor expanded in t around 0 38.2%
associate-*r/38.2%
neg-mul-138.2%
*-commutative38.2%
Simplified38.2%
Final simplification60.3%
(FPCore (x y z t) :precision binary64 (if (<= y -4e-55) (/ (/ x y) (- t z)) (if (<= y 2.3e-104) (/ (- x) (* z (- t z))) (/ (/ x t) (- y z)))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -4e-55) {
tmp = (x / y) / (t - z);
} else if (y <= 2.3e-104) {
tmp = -x / (z * (t - z));
} else {
tmp = (x / t) / (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 <= (-4d-55)) then
tmp = (x / y) / (t - z)
else if (y <= 2.3d-104) then
tmp = -x / (z * (t - z))
else
tmp = (x / t) / (y - z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -4e-55) {
tmp = (x / y) / (t - z);
} else if (y <= 2.3e-104) {
tmp = -x / (z * (t - z));
} else {
tmp = (x / t) / (y - z);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -4e-55: tmp = (x / y) / (t - z) elif y <= 2.3e-104: tmp = -x / (z * (t - z)) else: tmp = (x / t) / (y - z) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -4e-55) tmp = Float64(Float64(x / y) / Float64(t - z)); elseif (y <= 2.3e-104) tmp = Float64(Float64(-x) / Float64(z * Float64(t - z))); else tmp = Float64(Float64(x / t) / Float64(y - z)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -4e-55) tmp = (x / y) / (t - z); elseif (y <= 2.3e-104) tmp = -x / (z * (t - z)); else tmp = (x / t) / (y - z); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -4e-55], N[(N[(x / y), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.3e-104], N[((-x) / N[(z * N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x / t), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4 \cdot 10^{-55}:\\
\;\;\;\;\frac{\frac{x}{y}}{t - z}\\
\mathbf{elif}\;y \leq 2.3 \cdot 10^{-104}:\\
\;\;\;\;\frac{-x}{z \cdot \left(t - z\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{x}{t}}{y - z}\\
\end{array}
\end{array}
if y < -3.99999999999999998e-55Initial program 90.2%
add-cube-cbrt89.5%
times-frac99.0%
pow299.0%
Applied egg-rr99.0%
Taylor expanded in y around inf 82.9%
associate-/r*85.2%
Simplified85.2%
if -3.99999999999999998e-55 < y < 2.2999999999999999e-104Initial program 88.4%
Taylor expanded in y around 0 71.3%
associate-*r/71.3%
neg-mul-171.3%
Simplified71.3%
if 2.2999999999999999e-104 < y Initial program 91.4%
add-cube-cbrt90.9%
times-frac99.1%
pow299.1%
Applied egg-rr99.1%
Taylor expanded in t around inf 63.9%
associate-/r*70.1%
Simplified70.1%
Final simplification75.1%
(FPCore (x y z t) :precision binary64 (if (<= y -2.45e-26) (/ (/ x y) (- t z)) (if (<= y 1.06e-106) (/ (/ (- x) z) (- t z)) (/ (/ x t) (- y z)))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -2.45e-26) {
tmp = (x / y) / (t - z);
} else if (y <= 1.06e-106) {
tmp = (-x / z) / (t - z);
} else {
tmp = (x / t) / (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 <= (-2.45d-26)) then
tmp = (x / y) / (t - z)
else if (y <= 1.06d-106) then
tmp = (-x / z) / (t - z)
else
tmp = (x / t) / (y - z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -2.45e-26) {
tmp = (x / y) / (t - z);
} else if (y <= 1.06e-106) {
tmp = (-x / z) / (t - z);
} else {
tmp = (x / t) / (y - z);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -2.45e-26: tmp = (x / y) / (t - z) elif y <= 1.06e-106: tmp = (-x / z) / (t - z) else: tmp = (x / t) / (y - z) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -2.45e-26) tmp = Float64(Float64(x / y) / Float64(t - z)); elseif (y <= 1.06e-106) tmp = Float64(Float64(Float64(-x) / z) / Float64(t - z)); else tmp = Float64(Float64(x / t) / Float64(y - z)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -2.45e-26) tmp = (x / y) / (t - z); elseif (y <= 1.06e-106) tmp = (-x / z) / (t - z); else tmp = (x / t) / (y - z); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -2.45e-26], N[(N[(x / y), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.06e-106], N[(N[((-x) / z), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision], N[(N[(x / t), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.45 \cdot 10^{-26}:\\
\;\;\;\;\frac{\frac{x}{y}}{t - z}\\
\mathbf{elif}\;y \leq 1.06 \cdot 10^{-106}:\\
\;\;\;\;\frac{\frac{-x}{z}}{t - z}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{x}{t}}{y - z}\\
\end{array}
\end{array}
if y < -2.45e-26Initial program 91.1%
add-cube-cbrt90.4%
times-frac99.0%
pow299.0%
Applied egg-rr99.0%
Taylor expanded in y around inf 83.5%
associate-/r*85.9%
Simplified85.9%
if -2.45e-26 < y < 1.06e-106Initial program 87.6%
add-cube-cbrt86.7%
times-frac95.6%
pow295.6%
Applied egg-rr95.6%
Taylor expanded in y around 0 69.8%
associate-/r*77.9%
associate-*r/77.9%
associate-*r/77.9%
neg-mul-177.9%
Simplified77.9%
if 1.06e-106 < y Initial program 91.5%
add-cube-cbrt91.0%
times-frac99.1%
pow299.1%
Applied egg-rr99.1%
Taylor expanded in t around inf 64.3%
associate-/r*70.4%
Simplified70.4%
Final simplification77.6%
(FPCore (x y z t) :precision binary64 (if (<= y -2.6e+291) (/ x (* y t)) (if (<= y -2.9e+126) (/ (/ (- x) y) z) (/ x (* (- y z) t)))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -2.6e+291) {
tmp = x / (y * t);
} else if (y <= -2.9e+126) {
tmp = (-x / y) / z;
} else {
tmp = x / ((y - z) * 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 <= (-2.6d+291)) then
tmp = x / (y * t)
else if (y <= (-2.9d+126)) then
tmp = (-x / y) / z
else
tmp = x / ((y - z) * t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -2.6e+291) {
tmp = x / (y * t);
} else if (y <= -2.9e+126) {
tmp = (-x / y) / z;
} else {
tmp = x / ((y - z) * t);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -2.6e+291: tmp = x / (y * t) elif y <= -2.9e+126: tmp = (-x / y) / z else: tmp = x / ((y - z) * t) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -2.6e+291) tmp = Float64(x / Float64(y * t)); elseif (y <= -2.9e+126) tmp = Float64(Float64(Float64(-x) / y) / z); else tmp = Float64(x / Float64(Float64(y - z) * t)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -2.6e+291) tmp = x / (y * t); elseif (y <= -2.9e+126) tmp = (-x / y) / z; else tmp = x / ((y - z) * t); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -2.6e+291], N[(x / N[(y * t), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -2.9e+126], N[(N[((-x) / y), $MachinePrecision] / z), $MachinePrecision], N[(x / N[(N[(y - z), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.6 \cdot 10^{+291}:\\
\;\;\;\;\frac{x}{y \cdot t}\\
\mathbf{elif}\;y \leq -2.9 \cdot 10^{+126}:\\
\;\;\;\;\frac{\frac{-x}{y}}{z}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{\left(y - z\right) \cdot t}\\
\end{array}
\end{array}
if y < -2.60000000000000006e291Initial program 99.7%
Taylor expanded in z around 0 99.7%
if -2.60000000000000006e291 < y < -2.89999999999999986e126Initial program 91.0%
add-cube-cbrt90.5%
times-frac99.3%
pow299.3%
Applied egg-rr99.3%
Taylor expanded in y around inf 91.0%
associate-/r*99.8%
Simplified99.8%
Taylor expanded in t around 0 70.8%
mul-1-neg70.8%
associate-/r*79.3%
distribute-neg-frac79.3%
distribute-neg-frac79.3%
Simplified79.3%
if -2.89999999999999986e126 < y Initial program 89.6%
Taylor expanded in t around inf 61.3%
Final simplification64.3%
(FPCore (x y z t) :precision binary64 (if (or (<= z -1.65e+125) (not (<= z 1.5e+116))) (/ x (* z t)) (/ x (* y t))))
double code(double x, double y, double z, double t) {
double tmp;
if ((z <= -1.65e+125) || !(z <= 1.5e+116)) {
tmp = x / (z * t);
} else {
tmp = x / (y * 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 ((z <= (-1.65d+125)) .or. (.not. (z <= 1.5d+116))) then
tmp = x / (z * t)
else
tmp = x / (y * t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if ((z <= -1.65e+125) || !(z <= 1.5e+116)) {
tmp = x / (z * t);
} else {
tmp = x / (y * t);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (z <= -1.65e+125) or not (z <= 1.5e+116): tmp = x / (z * t) else: tmp = x / (y * t) return tmp
function code(x, y, z, t) tmp = 0.0 if ((z <= -1.65e+125) || !(z <= 1.5e+116)) tmp = Float64(x / Float64(z * t)); else tmp = Float64(x / Float64(y * t)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((z <= -1.65e+125) || ~((z <= 1.5e+116))) tmp = x / (z * t); else tmp = x / (y * t); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[z, -1.65e+125], N[Not[LessEqual[z, 1.5e+116]], $MachinePrecision]], N[(x / N[(z * t), $MachinePrecision]), $MachinePrecision], N[(x / N[(y * t), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.65 \cdot 10^{+125} \lor \neg \left(z \leq 1.5 \cdot 10^{+116}\right):\\
\;\;\;\;\frac{x}{z \cdot t}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{y \cdot t}\\
\end{array}
\end{array}
if z < -1.65000000000000003e125 or 1.4999999999999999e116 < z Initial program 81.5%
Taylor expanded in y around 0 80.3%
associate-*r/80.3%
neg-mul-180.3%
Simplified80.3%
Taylor expanded in z around 0 42.4%
associate-*r/42.4%
neg-mul-142.4%
Simplified42.4%
expm1-log1p-u42.1%
expm1-udef62.5%
add-sqr-sqrt31.0%
sqrt-unprod61.4%
sqr-neg61.4%
sqrt-unprod31.7%
add-sqr-sqrt62.6%
associate-/r*62.6%
Applied egg-rr62.6%
expm1-def41.2%
expm1-log1p41.4%
associate-/l/42.4%
Simplified42.4%
if -1.65000000000000003e125 < z < 1.4999999999999999e116Initial program 93.4%
Taylor expanded in z around 0 54.6%
Final simplification51.1%
(FPCore (x y z t) :precision binary64 (if (or (<= z -4e+53) (not (<= z 2.7e+89))) (/ x (* y z)) (/ x (* y t))))
double code(double x, double y, double z, double t) {
double tmp;
if ((z <= -4e+53) || !(z <= 2.7e+89)) {
tmp = x / (y * z);
} else {
tmp = x / (y * 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 ((z <= (-4d+53)) .or. (.not. (z <= 2.7d+89))) then
tmp = x / (y * z)
else
tmp = x / (y * t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if ((z <= -4e+53) || !(z <= 2.7e+89)) {
tmp = x / (y * z);
} else {
tmp = x / (y * t);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (z <= -4e+53) or not (z <= 2.7e+89): tmp = x / (y * z) else: tmp = x / (y * t) return tmp
function code(x, y, z, t) tmp = 0.0 if ((z <= -4e+53) || !(z <= 2.7e+89)) tmp = Float64(x / Float64(y * z)); else tmp = Float64(x / Float64(y * t)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((z <= -4e+53) || ~((z <= 2.7e+89))) tmp = x / (y * z); else tmp = x / (y * t); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[z, -4e+53], N[Not[LessEqual[z, 2.7e+89]], $MachinePrecision]], N[(x / N[(y * z), $MachinePrecision]), $MachinePrecision], N[(x / N[(y * t), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -4 \cdot 10^{+53} \lor \neg \left(z \leq 2.7 \cdot 10^{+89}\right):\\
\;\;\;\;\frac{x}{y \cdot z}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{y \cdot t}\\
\end{array}
\end{array}
if z < -4e53 or 2.7e89 < z Initial program 84.1%
add-cube-cbrt83.8%
times-frac99.3%
pow299.3%
Applied egg-rr99.3%
Taylor expanded in t around 0 79.2%
associate-/r*88.5%
associate-*r/88.5%
associate-*r/88.5%
neg-mul-188.5%
Simplified88.5%
expm1-log1p-u83.3%
expm1-udef67.9%
associate-/l/67.9%
add-sqr-sqrt28.9%
sqrt-unprod63.2%
sqr-neg63.2%
sqrt-unprod36.5%
add-sqr-sqrt65.5%
*-commutative65.5%
Applied egg-rr65.5%
expm1-def63.4%
expm1-log1p63.5%
*-rgt-identity63.5%
times-frac62.8%
associate-*l/62.8%
associate-*r/62.8%
*-rgt-identity62.8%
Simplified62.8%
Taylor expanded in y around inf 38.2%
*-commutative38.2%
Simplified38.2%
if -4e53 < z < 2.7e89Initial program 93.6%
Taylor expanded in z around 0 59.3%
Final simplification51.2%
(FPCore (x y z t) :precision binary64 (if (or (<= z -3.2e+53) (not (<= z 1.15e+82))) (/ x (* y z)) (/ (/ x t) y)))
double code(double x, double y, double z, double t) {
double tmp;
if ((z <= -3.2e+53) || !(z <= 1.15e+82)) {
tmp = x / (y * z);
} else {
tmp = (x / t) / 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 ((z <= (-3.2d+53)) .or. (.not. (z <= 1.15d+82))) then
tmp = x / (y * z)
else
tmp = (x / t) / y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if ((z <= -3.2e+53) || !(z <= 1.15e+82)) {
tmp = x / (y * z);
} else {
tmp = (x / t) / y;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (z <= -3.2e+53) or not (z <= 1.15e+82): tmp = x / (y * z) else: tmp = (x / t) / y return tmp
function code(x, y, z, t) tmp = 0.0 if ((z <= -3.2e+53) || !(z <= 1.15e+82)) tmp = Float64(x / Float64(y * z)); else tmp = Float64(Float64(x / t) / y); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((z <= -3.2e+53) || ~((z <= 1.15e+82))) tmp = x / (y * z); else tmp = (x / t) / y; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[z, -3.2e+53], N[Not[LessEqual[z, 1.15e+82]], $MachinePrecision]], N[(x / N[(y * z), $MachinePrecision]), $MachinePrecision], N[(N[(x / t), $MachinePrecision] / y), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.2 \cdot 10^{+53} \lor \neg \left(z \leq 1.15 \cdot 10^{+82}\right):\\
\;\;\;\;\frac{x}{y \cdot z}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{x}{t}}{y}\\
\end{array}
\end{array}
if z < -3.2e53 or 1.14999999999999994e82 < z Initial program 84.1%
add-cube-cbrt83.8%
times-frac99.3%
pow299.3%
Applied egg-rr99.3%
Taylor expanded in t around 0 79.2%
associate-/r*88.5%
associate-*r/88.5%
associate-*r/88.5%
neg-mul-188.5%
Simplified88.5%
expm1-log1p-u83.3%
expm1-udef67.9%
associate-/l/67.9%
add-sqr-sqrt28.9%
sqrt-unprod63.2%
sqr-neg63.2%
sqrt-unprod36.5%
add-sqr-sqrt65.5%
*-commutative65.5%
Applied egg-rr65.5%
expm1-def63.4%
expm1-log1p63.5%
*-rgt-identity63.5%
times-frac62.8%
associate-*l/62.8%
associate-*r/62.8%
*-rgt-identity62.8%
Simplified62.8%
Taylor expanded in y around inf 38.2%
*-commutative38.2%
Simplified38.2%
if -3.2e53 < z < 1.14999999999999994e82Initial program 93.6%
Taylor expanded in z around 0 59.3%
associate-/r*63.4%
div-inv63.2%
Applied egg-rr63.2%
un-div-inv63.4%
Applied egg-rr63.4%
Final simplification53.7%
(FPCore (x y z t) :precision binary64 (if (or (<= z -1.8e+67) (not (<= z 1.4e+81))) (/ (/ x z) t) (/ (/ x y) t)))
double code(double x, double y, double z, double t) {
double tmp;
if ((z <= -1.8e+67) || !(z <= 1.4e+81)) {
tmp = (x / z) / t;
} else {
tmp = (x / y) / 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 ((z <= (-1.8d+67)) .or. (.not. (z <= 1.4d+81))) then
tmp = (x / z) / t
else
tmp = (x / y) / t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if ((z <= -1.8e+67) || !(z <= 1.4e+81)) {
tmp = (x / z) / t;
} else {
tmp = (x / y) / t;
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if (z <= -1.8e+67) or not (z <= 1.4e+81): tmp = (x / z) / t else: tmp = (x / y) / t return tmp
function code(x, y, z, t) tmp = 0.0 if ((z <= -1.8e+67) || !(z <= 1.4e+81)) tmp = Float64(Float64(x / z) / t); else tmp = Float64(Float64(x / y) / t); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if ((z <= -1.8e+67) || ~((z <= 1.4e+81))) tmp = (x / z) / t; else tmp = (x / y) / t; end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[Or[LessEqual[z, -1.8e+67], N[Not[LessEqual[z, 1.4e+81]], $MachinePrecision]], N[(N[(x / z), $MachinePrecision] / t), $MachinePrecision], N[(N[(x / y), $MachinePrecision] / t), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.8 \cdot 10^{+67} \lor \neg \left(z \leq 1.4 \cdot 10^{+81}\right):\\
\;\;\;\;\frac{\frac{x}{z}}{t}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{x}{y}}{t}\\
\end{array}
\end{array}
if z < -1.7999999999999999e67 or 1.39999999999999997e81 < z Initial program 83.6%
Taylor expanded in y around 0 79.7%
associate-*r/79.7%
neg-mul-179.7%
Simplified79.7%
Taylor expanded in z around 0 37.0%
associate-*r/37.0%
neg-mul-137.0%
Simplified37.0%
clear-num37.3%
associate-/r/37.0%
add-sqr-sqrt17.6%
sqrt-unprod42.9%
sqr-neg42.9%
sqrt-unprod19.4%
add-sqr-sqrt36.1%
Applied egg-rr36.1%
associate-/r/36.4%
associate-/l*46.5%
clear-num46.3%
Applied egg-rr46.3%
if -1.7999999999999999e67 < z < 1.39999999999999997e81Initial program 93.7%
add-cube-cbrt92.8%
times-frac97.0%
pow297.0%
Applied egg-rr97.0%
frac-times92.8%
unpow292.8%
add-cube-cbrt93.7%
associate-/r*94.6%
un-div-inv94.5%
*-commutative94.5%
clear-num94.4%
un-div-inv94.5%
Applied egg-rr94.5%
Taylor expanded in z around 0 58.3%
associate-/l/60.4%
Simplified60.4%
Final simplification55.2%
(FPCore (x y z t) :precision binary64 (if (<= z -1.5e+125) (/ x (* y z)) (if (<= z 1.65e+143) (/ (/ x y) t) (/ x (* z t)))))
double code(double x, double y, double z, double t) {
double tmp;
if (z <= -1.5e+125) {
tmp = x / (y * z);
} else if (z <= 1.65e+143) {
tmp = (x / y) / t;
} else {
tmp = x / (z * 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 (z <= (-1.5d+125)) then
tmp = x / (y * z)
else if (z <= 1.65d+143) then
tmp = (x / y) / t
else
tmp = x / (z * t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (z <= -1.5e+125) {
tmp = x / (y * z);
} else if (z <= 1.65e+143) {
tmp = (x / y) / t;
} else {
tmp = x / (z * t);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if z <= -1.5e+125: tmp = x / (y * z) elif z <= 1.65e+143: tmp = (x / y) / t else: tmp = x / (z * t) return tmp
function code(x, y, z, t) tmp = 0.0 if (z <= -1.5e+125) tmp = Float64(x / Float64(y * z)); elseif (z <= 1.65e+143) tmp = Float64(Float64(x / y) / t); else tmp = Float64(x / Float64(z * t)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (z <= -1.5e+125) tmp = x / (y * z); elseif (z <= 1.65e+143) tmp = (x / y) / t; else tmp = x / (z * t); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[z, -1.5e+125], N[(x / N[(y * z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.65e+143], N[(N[(x / y), $MachinePrecision] / t), $MachinePrecision], N[(x / N[(z * t), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.5 \cdot 10^{+125}:\\
\;\;\;\;\frac{x}{y \cdot z}\\
\mathbf{elif}\;z \leq 1.65 \cdot 10^{+143}:\\
\;\;\;\;\frac{\frac{x}{y}}{t}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{z \cdot t}\\
\end{array}
\end{array}
if z < -1.50000000000000008e125Initial program 83.6%
add-cube-cbrt83.6%
times-frac99.6%
pow299.6%
Applied egg-rr99.6%
Taylor expanded in t around 0 83.6%
associate-/r*91.3%
associate-*r/91.3%
associate-*r/91.3%
neg-mul-191.3%
Simplified91.3%
expm1-log1p-u91.3%
expm1-udef80.8%
associate-/l/80.8%
add-sqr-sqrt42.5%
sqrt-unprod78.4%
sqr-neg78.4%
sqrt-unprod38.3%
add-sqr-sqrt80.8%
*-commutative80.8%
Applied egg-rr80.8%
expm1-def80.7%
expm1-log1p80.7%
*-rgt-identity80.7%
times-frac79.2%
associate-*l/79.2%
associate-*r/79.2%
*-rgt-identity79.2%
Simplified79.2%
Taylor expanded in y around inf 51.8%
*-commutative51.8%
Simplified51.8%
if -1.50000000000000008e125 < z < 1.65e143Initial program 93.7%
add-cube-cbrt92.7%
times-frac97.2%
pow297.2%
Applied egg-rr97.2%
frac-times92.7%
unpow292.7%
add-cube-cbrt93.7%
associate-/r*95.4%
un-div-inv95.2%
*-commutative95.2%
clear-num95.2%
un-div-inv95.2%
Applied egg-rr95.2%
Taylor expanded in z around 0 53.5%
associate-/l/56.3%
Simplified56.3%
if 1.65e143 < z Initial program 75.2%
Taylor expanded in y around 0 75.2%
associate-*r/75.2%
neg-mul-175.2%
Simplified75.2%
Taylor expanded in z around 0 40.8%
associate-*r/40.8%
neg-mul-140.8%
Simplified40.8%
expm1-log1p-u40.3%
expm1-udef51.2%
add-sqr-sqrt21.4%
sqrt-unprod50.9%
sqr-neg50.9%
sqrt-unprod30.1%
add-sqr-sqrt51.6%
associate-/r*51.5%
Applied egg-rr51.5%
expm1-def40.4%
expm1-log1p40.7%
associate-/l/41.0%
Simplified41.0%
Final simplification53.7%
(FPCore (x y z t) :precision binary64 (if (<= y -1.36e-92) (/ x (* y (- t z))) (/ x (* (- y z) t))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -1.36e-92) {
tmp = x / (y * (t - z));
} else {
tmp = x / ((y - z) * 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.36d-92)) then
tmp = x / (y * (t - z))
else
tmp = x / ((y - z) * t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -1.36e-92) {
tmp = x / (y * (t - z));
} else {
tmp = x / ((y - z) * t);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -1.36e-92: tmp = x / (y * (t - z)) else: tmp = x / ((y - z) * t) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -1.36e-92) tmp = Float64(x / Float64(y * Float64(t - z))); else tmp = Float64(x / Float64(Float64(y - z) * t)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -1.36e-92) tmp = x / (y * (t - z)); else tmp = x / ((y - z) * t); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -1.36e-92], N[(x / N[(y * N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(N[(y - z), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.36 \cdot 10^{-92}:\\
\;\;\;\;\frac{x}{y \cdot \left(t - z\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{\left(y - z\right) \cdot t}\\
\end{array}
\end{array}
if y < -1.36e-92Initial program 91.1%
Taylor expanded in y around inf 78.4%
*-commutative78.4%
Simplified78.4%
if -1.36e-92 < y Initial program 89.4%
Taylor expanded in t around inf 61.4%
Final simplification67.2%
(FPCore (x y z t) :precision binary64 (if (<= y -8.2e-93) (/ x (* y (- t z))) (/ (/ x t) (- y z))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -8.2e-93) {
tmp = x / (y * (t - z));
} else {
tmp = (x / t) / (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 <= (-8.2d-93)) then
tmp = x / (y * (t - z))
else
tmp = (x / t) / (y - z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -8.2e-93) {
tmp = x / (y * (t - z));
} else {
tmp = (x / t) / (y - z);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -8.2e-93: tmp = x / (y * (t - z)) else: tmp = (x / t) / (y - z) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -8.2e-93) tmp = Float64(x / Float64(y * Float64(t - z))); else tmp = Float64(Float64(x / t) / Float64(y - z)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -8.2e-93) tmp = x / (y * (t - z)); else tmp = (x / t) / (y - z); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -8.2e-93], N[(x / N[(y * N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x / t), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -8.2 \cdot 10^{-93}:\\
\;\;\;\;\frac{x}{y \cdot \left(t - z\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{x}{t}}{y - z}\\
\end{array}
\end{array}
if y < -8.1999999999999998e-93Initial program 91.1%
Taylor expanded in y around inf 78.4%
*-commutative78.4%
Simplified78.4%
if -8.1999999999999998e-93 < y Initial program 89.4%
add-cube-cbrt88.7%
times-frac97.3%
pow297.3%
Applied egg-rr97.3%
Taylor expanded in t around inf 61.4%
associate-/r*66.1%
Simplified66.1%
Final simplification70.3%
(FPCore (x y z t) :precision binary64 (if (<= y -3.7e-92) (/ (/ x y) (- t z)) (/ (/ x t) (- y z))))
double code(double x, double y, double z, double t) {
double tmp;
if (y <= -3.7e-92) {
tmp = (x / y) / (t - z);
} else {
tmp = (x / t) / (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 <= (-3.7d-92)) then
tmp = (x / y) / (t - z)
else
tmp = (x / t) / (y - z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double tmp;
if (y <= -3.7e-92) {
tmp = (x / y) / (t - z);
} else {
tmp = (x / t) / (y - z);
}
return tmp;
}
def code(x, y, z, t): tmp = 0 if y <= -3.7e-92: tmp = (x / y) / (t - z) else: tmp = (x / t) / (y - z) return tmp
function code(x, y, z, t) tmp = 0.0 if (y <= -3.7e-92) tmp = Float64(Float64(x / y) / Float64(t - z)); else tmp = Float64(Float64(x / t) / Float64(y - z)); end return tmp end
function tmp_2 = code(x, y, z, t) tmp = 0.0; if (y <= -3.7e-92) tmp = (x / y) / (t - z); else tmp = (x / t) / (y - z); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := If[LessEqual[y, -3.7e-92], N[(N[(x / y), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision], N[(N[(x / t), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.7 \cdot 10^{-92}:\\
\;\;\;\;\frac{\frac{x}{y}}{t - z}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{x}{t}}{y - z}\\
\end{array}
\end{array}
if y < -3.69999999999999977e-92Initial program 91.1%
add-cube-cbrt90.4%
times-frac98.9%
pow298.9%
Applied egg-rr98.9%
Taylor expanded in y around inf 78.4%
associate-/r*80.5%
Simplified80.5%
if -3.69999999999999977e-92 < y Initial program 89.4%
add-cube-cbrt88.7%
times-frac97.3%
pow297.3%
Applied egg-rr97.3%
Taylor expanded in t around inf 61.4%
associate-/r*66.1%
Simplified66.1%
Final simplification71.0%
(FPCore (x y z t) :precision binary64 (/ x (* y t)))
double code(double x, double y, double z, double t) {
return x / (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 * t)
end function
public static double code(double x, double y, double z, double t) {
return x / (y * t);
}
def code(x, y, z, t): return x / (y * t)
function code(x, y, z, t) return Float64(x / Float64(y * t)) end
function tmp = code(x, y, z, t) tmp = x / (y * t); end
code[x_, y_, z_, t_] := N[(x / N[(y * t), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x}{y \cdot t}
\end{array}
Initial program 90.0%
Taylor expanded in z around 0 44.1%
Final simplification44.1%
(FPCore (x y z t) :precision binary64 (let* ((t_1 (* (- y z) (- t z)))) (if (< (/ x t_1) 0.0) (/ (/ x (- y z)) (- t z)) (* x (/ 1.0 t_1)))))
double code(double x, double y, double z, double t) {
double t_1 = (y - z) * (t - z);
double tmp;
if ((x / t_1) < 0.0) {
tmp = (x / (y - z)) / (t - z);
} else {
tmp = x * (1.0 / t_1);
}
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 - z) * (t - z)
if ((x / t_1) < 0.0d0) then
tmp = (x / (y - z)) / (t - z)
else
tmp = x * (1.0d0 / t_1)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t) {
double t_1 = (y - z) * (t - z);
double tmp;
if ((x / t_1) < 0.0) {
tmp = (x / (y - z)) / (t - z);
} else {
tmp = x * (1.0 / t_1);
}
return tmp;
}
def code(x, y, z, t): t_1 = (y - z) * (t - z) tmp = 0 if (x / t_1) < 0.0: tmp = (x / (y - z)) / (t - z) else: tmp = x * (1.0 / t_1) return tmp
function code(x, y, z, t) t_1 = Float64(Float64(y - z) * Float64(t - z)) tmp = 0.0 if (Float64(x / t_1) < 0.0) tmp = Float64(Float64(x / Float64(y - z)) / Float64(t - z)); else tmp = Float64(x * Float64(1.0 / t_1)); end return tmp end
function tmp_2 = code(x, y, z, t) t_1 = (y - z) * (t - z); tmp = 0.0; if ((x / t_1) < 0.0) tmp = (x / (y - z)) / (t - z); else tmp = x * (1.0 / t_1); end tmp_2 = tmp; end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(y - z), $MachinePrecision] * N[(t - z), $MachinePrecision]), $MachinePrecision]}, If[Less[N[(x / t$95$1), $MachinePrecision], 0.0], N[(N[(x / N[(y - z), $MachinePrecision]), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision], N[(x * N[(1.0 / t$95$1), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(y - z\right) \cdot \left(t - z\right)\\
\mathbf{if}\;\frac{x}{t_1} < 0:\\
\;\;\;\;\frac{\frac{x}{y - z}}{t - z}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{1}{t_1}\\
\end{array}
\end{array}
herbie shell --seed 2023336
(FPCore (x y z t)
:name "Data.Random.Distribution.Triangular:triangularCDF from random-fu-0.2.6.2, B"
:precision binary64
:herbie-target
(if (< (/ x (* (- y z) (- t z))) 0.0) (/ (/ x (- y z)) (- t z)) (* x (/ 1.0 (* (- y z) (- t z)))))
(/ x (* (- y z) (- t z))))