
(FPCore (x y) :precision binary64 (- 1.0 (/ (* (- 1.0 x) y) (+ y 1.0))))
double code(double x, double y) {
return 1.0 - (((1.0 - x) * y) / (y + 1.0));
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = 1.0d0 - (((1.0d0 - x) * y) / (y + 1.0d0))
end function
public static double code(double x, double y) {
return 1.0 - (((1.0 - x) * y) / (y + 1.0));
}
def code(x, y): return 1.0 - (((1.0 - x) * y) / (y + 1.0))
function code(x, y) return Float64(1.0 - Float64(Float64(Float64(1.0 - x) * y) / Float64(y + 1.0))) end
function tmp = code(x, y) tmp = 1.0 - (((1.0 - x) * y) / (y + 1.0)); end
code[x_, y_] := N[(1.0 - N[(N[(N[(1.0 - x), $MachinePrecision] * y), $MachinePrecision] / N[(y + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
1 - \frac{\left(1 - x\right) \cdot y}{y + 1}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 12 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y) :precision binary64 (- 1.0 (/ (* (- 1.0 x) y) (+ y 1.0))))
double code(double x, double y) {
return 1.0 - (((1.0 - x) * y) / (y + 1.0));
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = 1.0d0 - (((1.0d0 - x) * y) / (y + 1.0d0))
end function
public static double code(double x, double y) {
return 1.0 - (((1.0 - x) * y) / (y + 1.0));
}
def code(x, y): return 1.0 - (((1.0 - x) * y) / (y + 1.0))
function code(x, y) return Float64(1.0 - Float64(Float64(Float64(1.0 - x) * y) / Float64(y + 1.0))) end
function tmp = code(x, y) tmp = 1.0 - (((1.0 - x) * y) / (y + 1.0)); end
code[x_, y_] := N[(1.0 - N[(N[(N[(1.0 - x), $MachinePrecision] * y), $MachinePrecision] / N[(y + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
1 - \frac{\left(1 - x\right) \cdot y}{y + 1}
\end{array}
(FPCore (x y)
:precision binary64
(let* ((t_0 (/ (* (- 1.0 x) y) (+ 1.0 y))))
(if (or (<= t_0 0.9) (not (<= t_0 1.1)))
(- 1.0 (* (- 1.0 x) (/ y (+ 1.0 y))))
(+
(+ x (/ (- 1.0 x) y))
(+ (/ (+ x -1.0) (pow y 2.0)) (/ (- 1.0 x) (pow y 3.0)))))))
double code(double x, double y) {
double t_0 = ((1.0 - x) * y) / (1.0 + y);
double tmp;
if ((t_0 <= 0.9) || !(t_0 <= 1.1)) {
tmp = 1.0 - ((1.0 - x) * (y / (1.0 + y)));
} else {
tmp = (x + ((1.0 - x) / y)) + (((x + -1.0) / pow(y, 2.0)) + ((1.0 - x) / pow(y, 3.0)));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: t_0
real(8) :: tmp
t_0 = ((1.0d0 - x) * y) / (1.0d0 + y)
if ((t_0 <= 0.9d0) .or. (.not. (t_0 <= 1.1d0))) then
tmp = 1.0d0 - ((1.0d0 - x) * (y / (1.0d0 + y)))
else
tmp = (x + ((1.0d0 - x) / y)) + (((x + (-1.0d0)) / (y ** 2.0d0)) + ((1.0d0 - x) / (y ** 3.0d0)))
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = ((1.0 - x) * y) / (1.0 + y);
double tmp;
if ((t_0 <= 0.9) || !(t_0 <= 1.1)) {
tmp = 1.0 - ((1.0 - x) * (y / (1.0 + y)));
} else {
tmp = (x + ((1.0 - x) / y)) + (((x + -1.0) / Math.pow(y, 2.0)) + ((1.0 - x) / Math.pow(y, 3.0)));
}
return tmp;
}
def code(x, y): t_0 = ((1.0 - x) * y) / (1.0 + y) tmp = 0 if (t_0 <= 0.9) or not (t_0 <= 1.1): tmp = 1.0 - ((1.0 - x) * (y / (1.0 + y))) else: tmp = (x + ((1.0 - x) / y)) + (((x + -1.0) / math.pow(y, 2.0)) + ((1.0 - x) / math.pow(y, 3.0))) return tmp
function code(x, y) t_0 = Float64(Float64(Float64(1.0 - x) * y) / Float64(1.0 + y)) tmp = 0.0 if ((t_0 <= 0.9) || !(t_0 <= 1.1)) tmp = Float64(1.0 - Float64(Float64(1.0 - x) * Float64(y / Float64(1.0 + y)))); else tmp = Float64(Float64(x + Float64(Float64(1.0 - x) / y)) + Float64(Float64(Float64(x + -1.0) / (y ^ 2.0)) + Float64(Float64(1.0 - x) / (y ^ 3.0)))); end return tmp end
function tmp_2 = code(x, y) t_0 = ((1.0 - x) * y) / (1.0 + y); tmp = 0.0; if ((t_0 <= 0.9) || ~((t_0 <= 1.1))) tmp = 1.0 - ((1.0 - x) * (y / (1.0 + y))); else tmp = (x + ((1.0 - x) / y)) + (((x + -1.0) / (y ^ 2.0)) + ((1.0 - x) / (y ^ 3.0))); end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(N[(N[(1.0 - x), $MachinePrecision] * y), $MachinePrecision] / N[(1.0 + y), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$0, 0.9], N[Not[LessEqual[t$95$0, 1.1]], $MachinePrecision]], N[(1.0 - N[(N[(1.0 - x), $MachinePrecision] * N[(y / N[(1.0 + y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x + N[(N[(1.0 - x), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(x + -1.0), $MachinePrecision] / N[Power[y, 2.0], $MachinePrecision]), $MachinePrecision] + N[(N[(1.0 - x), $MachinePrecision] / N[Power[y, 3.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{\left(1 - x\right) \cdot y}{1 + y}\\
\mathbf{if}\;t\_0 \leq 0.9 \lor \neg \left(t\_0 \leq 1.1\right):\\
\;\;\;\;1 - \left(1 - x\right) \cdot \frac{y}{1 + y}\\
\mathbf{else}:\\
\;\;\;\;\left(x + \frac{1 - x}{y}\right) + \left(\frac{x + -1}{{y}^{2}} + \frac{1 - x}{{y}^{3}}\right)\\
\end{array}
\end{array}
if (/.f64 (*.f64 (-.f64 1 x) y) (+.f64 y 1)) < 0.900000000000000022 or 1.1000000000000001 < (/.f64 (*.f64 (-.f64 1 x) y) (+.f64 y 1)) Initial program 84.5%
associate-/l*100.0%
remove-double-neg100.0%
remove-double-neg100.0%
+-commutative100.0%
Simplified100.0%
if 0.900000000000000022 < (/.f64 (*.f64 (-.f64 1 x) y) (+.f64 y 1)) < 1.1000000000000001Initial program 9.4%
associate-/l*9.5%
remove-double-neg9.5%
remove-double-neg9.5%
+-commutative9.5%
Simplified9.5%
Taylor expanded in y around -inf 100.0%
associate-+r+100.0%
associate--l+100.0%
mul-1-neg100.0%
unsub-neg100.0%
sub-neg100.0%
metadata-eval100.0%
Simplified100.0%
Final simplification100.0%
(FPCore (x y)
:precision binary64
(let* ((t_0 (/ (* (- 1.0 x) y) (+ 1.0 y))))
(if (or (<= t_0 0.999998) (not (<= t_0 1.1)))
(- 1.0 (* (- 1.0 x) (/ y (+ 1.0 y))))
(+ x (/ (* (- 1.0 x) (- (/ -1.0 y) -1.0)) y)))))
double code(double x, double y) {
double t_0 = ((1.0 - x) * y) / (1.0 + y);
double tmp;
if ((t_0 <= 0.999998) || !(t_0 <= 1.1)) {
tmp = 1.0 - ((1.0 - x) * (y / (1.0 + y)));
} else {
tmp = x + (((1.0 - x) * ((-1.0 / y) - -1.0)) / y);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: t_0
real(8) :: tmp
t_0 = ((1.0d0 - x) * y) / (1.0d0 + y)
if ((t_0 <= 0.999998d0) .or. (.not. (t_0 <= 1.1d0))) then
tmp = 1.0d0 - ((1.0d0 - x) * (y / (1.0d0 + y)))
else
tmp = x + (((1.0d0 - x) * (((-1.0d0) / y) - (-1.0d0))) / y)
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = ((1.0 - x) * y) / (1.0 + y);
double tmp;
if ((t_0 <= 0.999998) || !(t_0 <= 1.1)) {
tmp = 1.0 - ((1.0 - x) * (y / (1.0 + y)));
} else {
tmp = x + (((1.0 - x) * ((-1.0 / y) - -1.0)) / y);
}
return tmp;
}
def code(x, y): t_0 = ((1.0 - x) * y) / (1.0 + y) tmp = 0 if (t_0 <= 0.999998) or not (t_0 <= 1.1): tmp = 1.0 - ((1.0 - x) * (y / (1.0 + y))) else: tmp = x + (((1.0 - x) * ((-1.0 / y) - -1.0)) / y) return tmp
function code(x, y) t_0 = Float64(Float64(Float64(1.0 - x) * y) / Float64(1.0 + y)) tmp = 0.0 if ((t_0 <= 0.999998) || !(t_0 <= 1.1)) tmp = Float64(1.0 - Float64(Float64(1.0 - x) * Float64(y / Float64(1.0 + y)))); else tmp = Float64(x + Float64(Float64(Float64(1.0 - x) * Float64(Float64(-1.0 / y) - -1.0)) / y)); end return tmp end
function tmp_2 = code(x, y) t_0 = ((1.0 - x) * y) / (1.0 + y); tmp = 0.0; if ((t_0 <= 0.999998) || ~((t_0 <= 1.1))) tmp = 1.0 - ((1.0 - x) * (y / (1.0 + y))); else tmp = x + (((1.0 - x) * ((-1.0 / y) - -1.0)) / y); end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(N[(N[(1.0 - x), $MachinePrecision] * y), $MachinePrecision] / N[(1.0 + y), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$0, 0.999998], N[Not[LessEqual[t$95$0, 1.1]], $MachinePrecision]], N[(1.0 - N[(N[(1.0 - x), $MachinePrecision] * N[(y / N[(1.0 + y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(N[(1.0 - x), $MachinePrecision] * N[(N[(-1.0 / y), $MachinePrecision] - -1.0), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{\left(1 - x\right) \cdot y}{1 + y}\\
\mathbf{if}\;t\_0 \leq 0.999998 \lor \neg \left(t\_0 \leq 1.1\right):\\
\;\;\;\;1 - \left(1 - x\right) \cdot \frac{y}{1 + y}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{\left(1 - x\right) \cdot \left(\frac{-1}{y} - -1\right)}{y}\\
\end{array}
\end{array}
if (/.f64 (*.f64 (-.f64 1 x) y) (+.f64 y 1)) < 0.999998000000000054 or 1.1000000000000001 < (/.f64 (*.f64 (-.f64 1 x) y) (+.f64 y 1)) Initial program 84.5%
associate-/l*99.9%
remove-double-neg99.9%
remove-double-neg99.9%
+-commutative99.9%
Simplified99.9%
if 0.999998000000000054 < (/.f64 (*.f64 (-.f64 1 x) y) (+.f64 y 1)) < 1.1000000000000001Initial program 8.4%
associate-/l*8.5%
remove-double-neg8.5%
remove-double-neg8.5%
+-commutative8.5%
Simplified8.5%
Taylor expanded in y around inf 100.0%
associate--l+100.0%
neg-mul-1100.0%
sub-neg100.0%
associate--l+100.0%
div-sub100.0%
sub-neg100.0%
+-commutative100.0%
neg-mul-1100.0%
metadata-eval100.0%
distribute-lft-in100.0%
metadata-eval100.0%
sub-neg100.0%
associate-*r/100.0%
mul-1-neg100.0%
Simplified100.0%
*-un-lft-identity100.0%
unpow2100.0%
times-frac100.0%
Applied egg-rr100.0%
Taylor expanded in y around -inf 100.0%
associate--l+100.0%
div-sub100.0%
sub-neg100.0%
metadata-eval100.0%
+-commutative100.0%
metadata-eval100.0%
associate--r-100.0%
neg-sub0100.0%
neg-mul-1100.0%
associate-*r/100.0%
+-commutative100.0%
distribute-lft-in100.0%
mul-1-neg100.0%
unpow2100.0%
associate-/l/100.0%
*-rgt-identity100.0%
associate-*r/100.0%
sub-neg100.0%
metadata-eval100.0%
Simplified100.0%
Final simplification99.9%
(FPCore (x y)
:precision binary64
(let* ((t_0 (/ (* (- 1.0 x) y) (+ 1.0 y))))
(if (or (<= t_0 0.999998) (not (<= t_0 1.1)))
(- 1.0 (* (- 1.0 x) (/ y (+ 1.0 y))))
(+ x (/ 1.0 y)))))
double code(double x, double y) {
double t_0 = ((1.0 - x) * y) / (1.0 + y);
double tmp;
if ((t_0 <= 0.999998) || !(t_0 <= 1.1)) {
tmp = 1.0 - ((1.0 - x) * (y / (1.0 + y)));
} else {
tmp = x + (1.0 / y);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: t_0
real(8) :: tmp
t_0 = ((1.0d0 - x) * y) / (1.0d0 + y)
if ((t_0 <= 0.999998d0) .or. (.not. (t_0 <= 1.1d0))) then
tmp = 1.0d0 - ((1.0d0 - x) * (y / (1.0d0 + y)))
else
tmp = x + (1.0d0 / y)
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = ((1.0 - x) * y) / (1.0 + y);
double tmp;
if ((t_0 <= 0.999998) || !(t_0 <= 1.1)) {
tmp = 1.0 - ((1.0 - x) * (y / (1.0 + y)));
} else {
tmp = x + (1.0 / y);
}
return tmp;
}
def code(x, y): t_0 = ((1.0 - x) * y) / (1.0 + y) tmp = 0 if (t_0 <= 0.999998) or not (t_0 <= 1.1): tmp = 1.0 - ((1.0 - x) * (y / (1.0 + y))) else: tmp = x + (1.0 / y) return tmp
function code(x, y) t_0 = Float64(Float64(Float64(1.0 - x) * y) / Float64(1.0 + y)) tmp = 0.0 if ((t_0 <= 0.999998) || !(t_0 <= 1.1)) tmp = Float64(1.0 - Float64(Float64(1.0 - x) * Float64(y / Float64(1.0 + y)))); else tmp = Float64(x + Float64(1.0 / y)); end return tmp end
function tmp_2 = code(x, y) t_0 = ((1.0 - x) * y) / (1.0 + y); tmp = 0.0; if ((t_0 <= 0.999998) || ~((t_0 <= 1.1))) tmp = 1.0 - ((1.0 - x) * (y / (1.0 + y))); else tmp = x + (1.0 / y); end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(N[(N[(1.0 - x), $MachinePrecision] * y), $MachinePrecision] / N[(1.0 + y), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$0, 0.999998], N[Not[LessEqual[t$95$0, 1.1]], $MachinePrecision]], N[(1.0 - N[(N[(1.0 - x), $MachinePrecision] * N[(y / N[(1.0 + y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(1.0 / y), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{\left(1 - x\right) \cdot y}{1 + y}\\
\mathbf{if}\;t\_0 \leq 0.999998 \lor \neg \left(t\_0 \leq 1.1\right):\\
\;\;\;\;1 - \left(1 - x\right) \cdot \frac{y}{1 + y}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{1}{y}\\
\end{array}
\end{array}
if (/.f64 (*.f64 (-.f64 1 x) y) (+.f64 y 1)) < 0.999998000000000054 or 1.1000000000000001 < (/.f64 (*.f64 (-.f64 1 x) y) (+.f64 y 1)) Initial program 84.5%
associate-/l*99.9%
remove-double-neg99.9%
remove-double-neg99.9%
+-commutative99.9%
Simplified99.9%
if 0.999998000000000054 < (/.f64 (*.f64 (-.f64 1 x) y) (+.f64 y 1)) < 1.1000000000000001Initial program 8.4%
associate-/l*8.5%
remove-double-neg8.5%
remove-double-neg8.5%
+-commutative8.5%
Simplified8.5%
Taylor expanded in y around inf 99.5%
associate--l+99.5%
div-sub99.5%
sub-neg99.5%
+-commutative99.5%
neg-mul-199.5%
metadata-eval99.5%
distribute-lft-in99.5%
metadata-eval99.5%
sub-neg99.5%
associate-*r/99.5%
mul-1-neg99.5%
unsub-neg99.5%
sub-neg99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in x around 0 99.5%
Final simplification99.8%
(FPCore (x y) :precision binary64 (if (<= y -200000.0) (+ x (/ 1.0 y)) (if (<= y 75000.0) (+ 1.0 (* x (/ y (+ 1.0 y)))) (+ x (/ (- 1.0 x) y)))))
double code(double x, double y) {
double tmp;
if (y <= -200000.0) {
tmp = x + (1.0 / y);
} else if (y <= 75000.0) {
tmp = 1.0 + (x * (y / (1.0 + y)));
} else {
tmp = x + ((1.0 - x) / y);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= (-200000.0d0)) then
tmp = x + (1.0d0 / y)
else if (y <= 75000.0d0) then
tmp = 1.0d0 + (x * (y / (1.0d0 + y)))
else
tmp = x + ((1.0d0 - x) / y)
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= -200000.0) {
tmp = x + (1.0 / y);
} else if (y <= 75000.0) {
tmp = 1.0 + (x * (y / (1.0 + y)));
} else {
tmp = x + ((1.0 - x) / y);
}
return tmp;
}
def code(x, y): tmp = 0 if y <= -200000.0: tmp = x + (1.0 / y) elif y <= 75000.0: tmp = 1.0 + (x * (y / (1.0 + y))) else: tmp = x + ((1.0 - x) / y) return tmp
function code(x, y) tmp = 0.0 if (y <= -200000.0) tmp = Float64(x + Float64(1.0 / y)); elseif (y <= 75000.0) tmp = Float64(1.0 + Float64(x * Float64(y / Float64(1.0 + y)))); else tmp = Float64(x + Float64(Float64(1.0 - x) / y)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= -200000.0) tmp = x + (1.0 / y); elseif (y <= 75000.0) tmp = 1.0 + (x * (y / (1.0 + y))); else tmp = x + ((1.0 - x) / y); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, -200000.0], N[(x + N[(1.0 / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 75000.0], N[(1.0 + N[(x * N[(y / N[(1.0 + y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(1.0 - x), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -200000:\\
\;\;\;\;x + \frac{1}{y}\\
\mathbf{elif}\;y \leq 75000:\\
\;\;\;\;1 + x \cdot \frac{y}{1 + y}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{1 - x}{y}\\
\end{array}
\end{array}
if y < -2e5Initial program 21.9%
associate-/l*42.8%
remove-double-neg42.8%
remove-double-neg42.8%
+-commutative42.8%
Simplified42.8%
Taylor expanded in y around inf 99.5%
associate--l+99.5%
div-sub99.5%
sub-neg99.5%
+-commutative99.5%
neg-mul-199.5%
metadata-eval99.5%
distribute-lft-in99.5%
metadata-eval99.5%
sub-neg99.5%
associate-*r/99.5%
mul-1-neg99.5%
unsub-neg99.5%
sub-neg99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in x around 0 99.5%
if -2e5 < y < 75000Initial program 100.0%
associate-/l*100.0%
remove-double-neg100.0%
remove-double-neg100.0%
+-commutative100.0%
Simplified100.0%
Taylor expanded in x around inf 98.6%
*-commutative98.6%
associate-/l*98.6%
associate-*l*98.6%
*-commutative98.6%
mul-1-neg98.6%
distribute-neg-frac298.6%
distribute-neg-in98.6%
metadata-eval98.6%
sub-neg98.6%
Simplified98.6%
if 75000 < y Initial program 35.5%
associate-/l*61.9%
remove-double-neg61.9%
remove-double-neg61.9%
+-commutative61.9%
Simplified61.9%
Taylor expanded in y around inf 99.1%
associate--l+99.1%
div-sub99.1%
sub-neg99.1%
+-commutative99.1%
neg-mul-199.1%
metadata-eval99.1%
distribute-lft-in99.1%
metadata-eval99.1%
sub-neg99.1%
associate-*r/99.1%
mul-1-neg99.1%
unsub-neg99.1%
sub-neg99.1%
metadata-eval99.1%
Simplified99.1%
Final simplification98.9%
(FPCore (x y) :precision binary64 (if (<= y -9e+95) x (if (<= y -1.0) (/ 1.0 y) (if (<= y 0.42) (- 1.0 y) x))))
double code(double x, double y) {
double tmp;
if (y <= -9e+95) {
tmp = x;
} else if (y <= -1.0) {
tmp = 1.0 / y;
} else if (y <= 0.42) {
tmp = 1.0 - y;
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= (-9d+95)) then
tmp = x
else if (y <= (-1.0d0)) then
tmp = 1.0d0 / y
else if (y <= 0.42d0) then
tmp = 1.0d0 - y
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= -9e+95) {
tmp = x;
} else if (y <= -1.0) {
tmp = 1.0 / y;
} else if (y <= 0.42) {
tmp = 1.0 - y;
} else {
tmp = x;
}
return tmp;
}
def code(x, y): tmp = 0 if y <= -9e+95: tmp = x elif y <= -1.0: tmp = 1.0 / y elif y <= 0.42: tmp = 1.0 - y else: tmp = x return tmp
function code(x, y) tmp = 0.0 if (y <= -9e+95) tmp = x; elseif (y <= -1.0) tmp = Float64(1.0 / y); elseif (y <= 0.42) tmp = Float64(1.0 - y); else tmp = x; end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= -9e+95) tmp = x; elseif (y <= -1.0) tmp = 1.0 / y; elseif (y <= 0.42) tmp = 1.0 - y; else tmp = x; end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, -9e+95], x, If[LessEqual[y, -1.0], N[(1.0 / y), $MachinePrecision], If[LessEqual[y, 0.42], N[(1.0 - y), $MachinePrecision], x]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -9 \cdot 10^{+95}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq -1:\\
\;\;\;\;\frac{1}{y}\\
\mathbf{elif}\;y \leq 0.42:\\
\;\;\;\;1 - y\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -9.00000000000000033e95 or 0.419999999999999984 < y Initial program 29.0%
associate-/l*55.4%
remove-double-neg55.4%
remove-double-neg55.4%
+-commutative55.4%
Simplified55.4%
Taylor expanded in y around inf 81.7%
if -9.00000000000000033e95 < y < -1Initial program 36.8%
associate-/l*41.0%
remove-double-neg41.0%
remove-double-neg41.0%
+-commutative41.0%
Simplified41.0%
Taylor expanded in y around inf 92.9%
associate--l+92.9%
div-sub92.9%
sub-neg92.9%
+-commutative92.9%
neg-mul-192.9%
metadata-eval92.9%
distribute-lft-in92.9%
metadata-eval92.9%
sub-neg92.9%
associate-*r/92.9%
mul-1-neg92.9%
unsub-neg92.9%
sub-neg92.9%
metadata-eval92.9%
Simplified92.9%
Taylor expanded in x around 0 64.3%
if -1 < y < 0.419999999999999984Initial program 100.0%
associate-/l*100.0%
remove-double-neg100.0%
remove-double-neg100.0%
+-commutative100.0%
Simplified100.0%
Taylor expanded in x around 0 72.9%
Taylor expanded in y around 0 72.9%
neg-mul-172.9%
unsub-neg72.9%
Simplified72.9%
Final simplification75.8%
(FPCore (x y) :precision binary64 (if (or (<= y -1.0) (not (<= y 0.82))) (+ x (/ 1.0 y)) (+ 1.0 (* y (+ x -1.0)))))
double code(double x, double y) {
double tmp;
if ((y <= -1.0) || !(y <= 0.82)) {
tmp = x + (1.0 / y);
} else {
tmp = 1.0 + (y * (x + -1.0));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if ((y <= (-1.0d0)) .or. (.not. (y <= 0.82d0))) then
tmp = x + (1.0d0 / y)
else
tmp = 1.0d0 + (y * (x + (-1.0d0)))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if ((y <= -1.0) || !(y <= 0.82)) {
tmp = x + (1.0 / y);
} else {
tmp = 1.0 + (y * (x + -1.0));
}
return tmp;
}
def code(x, y): tmp = 0 if (y <= -1.0) or not (y <= 0.82): tmp = x + (1.0 / y) else: tmp = 1.0 + (y * (x + -1.0)) return tmp
function code(x, y) tmp = 0.0 if ((y <= -1.0) || !(y <= 0.82)) tmp = Float64(x + Float64(1.0 / y)); else tmp = Float64(1.0 + Float64(y * Float64(x + -1.0))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if ((y <= -1.0) || ~((y <= 0.82))) tmp = x + (1.0 / y); else tmp = 1.0 + (y * (x + -1.0)); end tmp_2 = tmp; end
code[x_, y_] := If[Or[LessEqual[y, -1.0], N[Not[LessEqual[y, 0.82]], $MachinePrecision]], N[(x + N[(1.0 / y), $MachinePrecision]), $MachinePrecision], N[(1.0 + N[(y * N[(x + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1 \lor \neg \left(y \leq 0.82\right):\\
\;\;\;\;x + \frac{1}{y}\\
\mathbf{else}:\\
\;\;\;\;1 + y \cdot \left(x + -1\right)\\
\end{array}
\end{array}
if y < -1 or 0.819999999999999951 < y Initial program 29.8%
associate-/l*52.6%
remove-double-neg52.6%
remove-double-neg52.6%
+-commutative52.6%
Simplified52.6%
Taylor expanded in y around inf 98.1%
associate--l+98.1%
div-sub98.1%
sub-neg98.1%
+-commutative98.1%
neg-mul-198.1%
metadata-eval98.1%
distribute-lft-in98.1%
metadata-eval98.1%
sub-neg98.1%
associate-*r/98.1%
mul-1-neg98.1%
unsub-neg98.1%
sub-neg98.1%
metadata-eval98.1%
Simplified98.1%
Taylor expanded in x around 0 97.5%
if -1 < y < 0.819999999999999951Initial program 100.0%
associate-/l*100.0%
remove-double-neg100.0%
remove-double-neg100.0%
+-commutative100.0%
Simplified100.0%
Taylor expanded in y around 0 99.1%
Final simplification98.3%
(FPCore (x y) :precision binary64 (if (or (<= y -1.0) (not (<= y 1.0))) (+ x (/ (- 1.0 x) y)) (+ 1.0 (* y (+ x -1.0)))))
double code(double x, double y) {
double tmp;
if ((y <= -1.0) || !(y <= 1.0)) {
tmp = x + ((1.0 - x) / y);
} else {
tmp = 1.0 + (y * (x + -1.0));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if ((y <= (-1.0d0)) .or. (.not. (y <= 1.0d0))) then
tmp = x + ((1.0d0 - x) / y)
else
tmp = 1.0d0 + (y * (x + (-1.0d0)))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if ((y <= -1.0) || !(y <= 1.0)) {
tmp = x + ((1.0 - x) / y);
} else {
tmp = 1.0 + (y * (x + -1.0));
}
return tmp;
}
def code(x, y): tmp = 0 if (y <= -1.0) or not (y <= 1.0): tmp = x + ((1.0 - x) / y) else: tmp = 1.0 + (y * (x + -1.0)) return tmp
function code(x, y) tmp = 0.0 if ((y <= -1.0) || !(y <= 1.0)) tmp = Float64(x + Float64(Float64(1.0 - x) / y)); else tmp = Float64(1.0 + Float64(y * Float64(x + -1.0))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if ((y <= -1.0) || ~((y <= 1.0))) tmp = x + ((1.0 - x) / y); else tmp = 1.0 + (y * (x + -1.0)); end tmp_2 = tmp; end
code[x_, y_] := If[Or[LessEqual[y, -1.0], N[Not[LessEqual[y, 1.0]], $MachinePrecision]], N[(x + N[(N[(1.0 - x), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(1.0 + N[(y * N[(x + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1 \lor \neg \left(y \leq 1\right):\\
\;\;\;\;x + \frac{1 - x}{y}\\
\mathbf{else}:\\
\;\;\;\;1 + y \cdot \left(x + -1\right)\\
\end{array}
\end{array}
if y < -1 or 1 < y Initial program 29.8%
associate-/l*52.6%
remove-double-neg52.6%
remove-double-neg52.6%
+-commutative52.6%
Simplified52.6%
Taylor expanded in y around inf 98.1%
associate--l+98.1%
div-sub98.1%
sub-neg98.1%
+-commutative98.1%
neg-mul-198.1%
metadata-eval98.1%
distribute-lft-in98.1%
metadata-eval98.1%
sub-neg98.1%
associate-*r/98.1%
mul-1-neg98.1%
unsub-neg98.1%
sub-neg98.1%
metadata-eval98.1%
Simplified98.1%
if -1 < y < 1Initial program 100.0%
associate-/l*100.0%
remove-double-neg100.0%
remove-double-neg100.0%
+-commutative100.0%
Simplified100.0%
Taylor expanded in y around 0 99.1%
Final simplification98.6%
(FPCore (x y) :precision binary64 (if (or (<= y -1.0) (not (<= y 0.045))) (+ x (/ 1.0 y)) (- 1.0 y)))
double code(double x, double y) {
double tmp;
if ((y <= -1.0) || !(y <= 0.045)) {
tmp = x + (1.0 / y);
} else {
tmp = 1.0 - y;
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if ((y <= (-1.0d0)) .or. (.not. (y <= 0.045d0))) then
tmp = x + (1.0d0 / y)
else
tmp = 1.0d0 - y
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if ((y <= -1.0) || !(y <= 0.045)) {
tmp = x + (1.0 / y);
} else {
tmp = 1.0 - y;
}
return tmp;
}
def code(x, y): tmp = 0 if (y <= -1.0) or not (y <= 0.045): tmp = x + (1.0 / y) else: tmp = 1.0 - y return tmp
function code(x, y) tmp = 0.0 if ((y <= -1.0) || !(y <= 0.045)) tmp = Float64(x + Float64(1.0 / y)); else tmp = Float64(1.0 - y); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if ((y <= -1.0) || ~((y <= 0.045))) tmp = x + (1.0 / y); else tmp = 1.0 - y; end tmp_2 = tmp; end
code[x_, y_] := If[Or[LessEqual[y, -1.0], N[Not[LessEqual[y, 0.045]], $MachinePrecision]], N[(x + N[(1.0 / y), $MachinePrecision]), $MachinePrecision], N[(1.0 - y), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1 \lor \neg \left(y \leq 0.045\right):\\
\;\;\;\;x + \frac{1}{y}\\
\mathbf{else}:\\
\;\;\;\;1 - y\\
\end{array}
\end{array}
if y < -1 or 0.044999999999999998 < y Initial program 30.3%
associate-/l*53.0%
remove-double-neg53.0%
remove-double-neg53.0%
+-commutative53.0%
Simplified53.0%
Taylor expanded in y around inf 97.4%
associate--l+97.4%
div-sub97.4%
sub-neg97.4%
+-commutative97.4%
neg-mul-197.4%
metadata-eval97.4%
distribute-lft-in97.4%
metadata-eval97.4%
sub-neg97.4%
associate-*r/97.4%
mul-1-neg97.4%
unsub-neg97.4%
sub-neg97.4%
metadata-eval97.4%
Simplified97.4%
Taylor expanded in x around 0 96.8%
if -1 < y < 0.044999999999999998Initial program 100.0%
associate-/l*100.0%
remove-double-neg100.0%
remove-double-neg100.0%
+-commutative100.0%
Simplified100.0%
Taylor expanded in x around 0 72.9%
Taylor expanded in y around 0 72.9%
neg-mul-172.9%
unsub-neg72.9%
Simplified72.9%
Final simplification85.0%
(FPCore (x y) :precision binary64 (if (or (<= y -1.0) (not (<= y 1.0))) (+ x (/ 1.0 y)) (+ 1.0 (* x y))))
double code(double x, double y) {
double tmp;
if ((y <= -1.0) || !(y <= 1.0)) {
tmp = x + (1.0 / y);
} else {
tmp = 1.0 + (x * y);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if ((y <= (-1.0d0)) .or. (.not. (y <= 1.0d0))) then
tmp = x + (1.0d0 / y)
else
tmp = 1.0d0 + (x * y)
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if ((y <= -1.0) || !(y <= 1.0)) {
tmp = x + (1.0 / y);
} else {
tmp = 1.0 + (x * y);
}
return tmp;
}
def code(x, y): tmp = 0 if (y <= -1.0) or not (y <= 1.0): tmp = x + (1.0 / y) else: tmp = 1.0 + (x * y) return tmp
function code(x, y) tmp = 0.0 if ((y <= -1.0) || !(y <= 1.0)) tmp = Float64(x + Float64(1.0 / y)); else tmp = Float64(1.0 + Float64(x * y)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if ((y <= -1.0) || ~((y <= 1.0))) tmp = x + (1.0 / y); else tmp = 1.0 + (x * y); end tmp_2 = tmp; end
code[x_, y_] := If[Or[LessEqual[y, -1.0], N[Not[LessEqual[y, 1.0]], $MachinePrecision]], N[(x + N[(1.0 / y), $MachinePrecision]), $MachinePrecision], N[(1.0 + N[(x * y), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1 \lor \neg \left(y \leq 1\right):\\
\;\;\;\;x + \frac{1}{y}\\
\mathbf{else}:\\
\;\;\;\;1 + x \cdot y\\
\end{array}
\end{array}
if y < -1 or 1 < y Initial program 29.8%
associate-/l*52.6%
remove-double-neg52.6%
remove-double-neg52.6%
+-commutative52.6%
Simplified52.6%
Taylor expanded in y around inf 98.1%
associate--l+98.1%
div-sub98.1%
sub-neg98.1%
+-commutative98.1%
neg-mul-198.1%
metadata-eval98.1%
distribute-lft-in98.1%
metadata-eval98.1%
sub-neg98.1%
associate-*r/98.1%
mul-1-neg98.1%
unsub-neg98.1%
sub-neg98.1%
metadata-eval98.1%
Simplified98.1%
Taylor expanded in x around 0 97.5%
if -1 < y < 1Initial program 100.0%
associate-/l*100.0%
remove-double-neg100.0%
remove-double-neg100.0%
+-commutative100.0%
Simplified100.0%
Taylor expanded in x around inf 99.3%
*-commutative99.3%
associate-/l*99.3%
associate-*l*99.3%
*-commutative99.3%
mul-1-neg99.3%
distribute-neg-frac299.3%
distribute-neg-in99.3%
metadata-eval99.3%
sub-neg99.3%
Simplified99.3%
Taylor expanded in y around 0 98.4%
neg-mul-198.4%
distribute-lft-neg-in98.4%
Simplified98.4%
Final simplification97.9%
(FPCore (x y) :precision binary64 (if (<= y -1.0) x (if (<= y 0.24) (- 1.0 y) x)))
double code(double x, double y) {
double tmp;
if (y <= -1.0) {
tmp = x;
} else if (y <= 0.24) {
tmp = 1.0 - y;
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= (-1.0d0)) then
tmp = x
else if (y <= 0.24d0) then
tmp = 1.0d0 - y
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= -1.0) {
tmp = x;
} else if (y <= 0.24) {
tmp = 1.0 - y;
} else {
tmp = x;
}
return tmp;
}
def code(x, y): tmp = 0 if y <= -1.0: tmp = x elif y <= 0.24: tmp = 1.0 - y else: tmp = x return tmp
function code(x, y) tmp = 0.0 if (y <= -1.0) tmp = x; elseif (y <= 0.24) tmp = Float64(1.0 - y); else tmp = x; end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= -1.0) tmp = x; elseif (y <= 0.24) tmp = 1.0 - y; else tmp = x; end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, -1.0], x, If[LessEqual[y, 0.24], N[(1.0 - y), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 0.24:\\
\;\;\;\;1 - y\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -1 or 0.23999999999999999 < y Initial program 30.3%
associate-/l*53.0%
remove-double-neg53.0%
remove-double-neg53.0%
+-commutative53.0%
Simplified53.0%
Taylor expanded in y around inf 73.1%
if -1 < y < 0.23999999999999999Initial program 100.0%
associate-/l*100.0%
remove-double-neg100.0%
remove-double-neg100.0%
+-commutative100.0%
Simplified100.0%
Taylor expanded in x around 0 72.9%
Taylor expanded in y around 0 72.9%
neg-mul-172.9%
unsub-neg72.9%
Simplified72.9%
Final simplification73.0%
(FPCore (x y) :precision binary64 (if (<= y -1.0) x (if (<= y 0.035) 1.0 x)))
double code(double x, double y) {
double tmp;
if (y <= -1.0) {
tmp = x;
} else if (y <= 0.035) {
tmp = 1.0;
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= (-1.0d0)) then
tmp = x
else if (y <= 0.035d0) then
tmp = 1.0d0
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= -1.0) {
tmp = x;
} else if (y <= 0.035) {
tmp = 1.0;
} else {
tmp = x;
}
return tmp;
}
def code(x, y): tmp = 0 if y <= -1.0: tmp = x elif y <= 0.035: tmp = 1.0 else: tmp = x return tmp
function code(x, y) tmp = 0.0 if (y <= -1.0) tmp = x; elseif (y <= 0.035) tmp = 1.0; else tmp = x; end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= -1.0) tmp = x; elseif (y <= 0.035) tmp = 1.0; else tmp = x; end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, -1.0], x, If[LessEqual[y, 0.035], 1.0, x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 0.035:\\
\;\;\;\;1\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -1 or 0.035000000000000003 < y Initial program 30.3%
associate-/l*53.0%
remove-double-neg53.0%
remove-double-neg53.0%
+-commutative53.0%
Simplified53.0%
Taylor expanded in y around inf 73.1%
if -1 < y < 0.035000000000000003Initial program 100.0%
associate-/l*100.0%
remove-double-neg100.0%
remove-double-neg100.0%
+-commutative100.0%
Simplified100.0%
Taylor expanded in y around 0 72.2%
Final simplification72.7%
(FPCore (x y) :precision binary64 1.0)
double code(double x, double y) {
return 1.0;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = 1.0d0
end function
public static double code(double x, double y) {
return 1.0;
}
def code(x, y): return 1.0
function code(x, y) return 1.0 end
function tmp = code(x, y) tmp = 1.0; end
code[x_, y_] := 1.0
\begin{array}{l}
\\
1
\end{array}
Initial program 64.9%
associate-/l*76.3%
remove-double-neg76.3%
remove-double-neg76.3%
+-commutative76.3%
Simplified76.3%
Taylor expanded in y around 0 37.6%
Final simplification37.6%
(FPCore (x y)
:precision binary64
(let* ((t_0 (- (/ 1.0 y) (- (/ x y) x))))
(if (< y -3693.8482788297247)
t_0
(if (< y 6799310503.41891) (- 1.0 (/ (* (- 1.0 x) y) (+ y 1.0))) t_0))))
double code(double x, double y) {
double t_0 = (1.0 / y) - ((x / y) - x);
double tmp;
if (y < -3693.8482788297247) {
tmp = t_0;
} else if (y < 6799310503.41891) {
tmp = 1.0 - (((1.0 - x) * y) / (y + 1.0));
} else {
tmp = t_0;
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: t_0
real(8) :: tmp
t_0 = (1.0d0 / y) - ((x / y) - x)
if (y < (-3693.8482788297247d0)) then
tmp = t_0
else if (y < 6799310503.41891d0) then
tmp = 1.0d0 - (((1.0d0 - x) * y) / (y + 1.0d0))
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = (1.0 / y) - ((x / y) - x);
double tmp;
if (y < -3693.8482788297247) {
tmp = t_0;
} else if (y < 6799310503.41891) {
tmp = 1.0 - (((1.0 - x) * y) / (y + 1.0));
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y): t_0 = (1.0 / y) - ((x / y) - x) tmp = 0 if y < -3693.8482788297247: tmp = t_0 elif y < 6799310503.41891: tmp = 1.0 - (((1.0 - x) * y) / (y + 1.0)) else: tmp = t_0 return tmp
function code(x, y) t_0 = Float64(Float64(1.0 / y) - Float64(Float64(x / y) - x)) tmp = 0.0 if (y < -3693.8482788297247) tmp = t_0; elseif (y < 6799310503.41891) tmp = Float64(1.0 - Float64(Float64(Float64(1.0 - x) * y) / Float64(y + 1.0))); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y) t_0 = (1.0 / y) - ((x / y) - x); tmp = 0.0; if (y < -3693.8482788297247) tmp = t_0; elseif (y < 6799310503.41891) tmp = 1.0 - (((1.0 - x) * y) / (y + 1.0)); else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(N[(1.0 / y), $MachinePrecision] - N[(N[(x / y), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]}, If[Less[y, -3693.8482788297247], t$95$0, If[Less[y, 6799310503.41891], N[(1.0 - N[(N[(N[(1.0 - x), $MachinePrecision] * y), $MachinePrecision] / N[(y + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$0]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{1}{y} - \left(\frac{x}{y} - x\right)\\
\mathbf{if}\;y < -3693.8482788297247:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;y < 6799310503.41891:\\
\;\;\;\;1 - \frac{\left(1 - x\right) \cdot y}{y + 1}\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
herbie shell --seed 2024043
(FPCore (x y)
:name "Diagrams.Trail:splitAtParam from diagrams-lib-1.3.0.3, D"
:precision binary64
:herbie-target
(if (< y -3693.8482788297247) (- (/ 1.0 y) (- (/ x y) x)) (if (< y 6799310503.41891) (- 1.0 (/ (* (- 1.0 x) y) (+ y 1.0))) (- (/ 1.0 y) (- (/ x y) x))))
(- 1.0 (/ (* (- 1.0 x) y) (+ y 1.0))))