
(FPCore (x y z t a b) :precision binary64 :pre TRUE (* x (exp (+ (* y (- (log z) t)) (* a (- (log (- 1.0 z)) b))))))
double code(double x, double y, double z, double t, double a, double b) {
return x * exp(((y * (log(z) - t)) + (a * (log((1.0 - z)) - b))));
}
real(8) function code(x, y, z, t, a, b)
use fmin_fmax_functions
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
code = x * exp(((y * (log(z) - t)) + (a * (log((1.0d0 - z)) - b))))
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x * Math.exp(((y * (Math.log(z) - t)) + (a * (Math.log((1.0 - z)) - b))));
}
def code(x, y, z, t, a, b): return x * math.exp(((y * (math.log(z) - t)) + (a * (math.log((1.0 - z)) - b))))
function code(x, y, z, t, a, b) return Float64(x * exp(Float64(Float64(y * Float64(log(z) - t)) + Float64(a * Float64(log(Float64(1.0 - z)) - b))))) end
function tmp = code(x, y, z, t, a, b) tmp = x * exp(((y * (log(z) - t)) + (a * (log((1.0 - z)) - b)))); end
code[x_, y_, z_, t_, a_, b_] := N[(x * N[Exp[N[(N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] + N[(a * N[(N[Log[N[(1.0 - z), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
f(x, y, z, t, a, b): x in [-inf, +inf], y in [-inf, +inf], z in [-inf, +inf], t in [-inf, +inf], a in [-inf, +inf], b in [-inf, +inf] code: THEORY BEGIN f(x, y, z, t, a, b: real): real = x * (exp(((y * ((ln(z)) - t)) + (a * ((ln(((1) - z))) - b))))) END code
x \cdot e^{y \cdot \left(\log z - t\right) + a \cdot \left(\log \left(1 - z\right) - b\right)}
Herbie found 15 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b) :precision binary64 :pre TRUE (* x (exp (+ (* y (- (log z) t)) (* a (- (log (- 1.0 z)) b))))))
double code(double x, double y, double z, double t, double a, double b) {
return x * exp(((y * (log(z) - t)) + (a * (log((1.0 - z)) - b))));
}
real(8) function code(x, y, z, t, a, b)
use fmin_fmax_functions
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
code = x * exp(((y * (log(z) - t)) + (a * (log((1.0d0 - z)) - b))))
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x * Math.exp(((y * (Math.log(z) - t)) + (a * (Math.log((1.0 - z)) - b))));
}
def code(x, y, z, t, a, b): return x * math.exp(((y * (math.log(z) - t)) + (a * (math.log((1.0 - z)) - b))))
function code(x, y, z, t, a, b) return Float64(x * exp(Float64(Float64(y * Float64(log(z) - t)) + Float64(a * Float64(log(Float64(1.0 - z)) - b))))) end
function tmp = code(x, y, z, t, a, b) tmp = x * exp(((y * (log(z) - t)) + (a * (log((1.0 - z)) - b)))); end
code[x_, y_, z_, t_, a_, b_] := N[(x * N[Exp[N[(N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] + N[(a * N[(N[Log[N[(1.0 - z), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
f(x, y, z, t, a, b): x in [-inf, +inf], y in [-inf, +inf], z in [-inf, +inf], t in [-inf, +inf], a in [-inf, +inf], b in [-inf, +inf] code: THEORY BEGIN f(x, y, z, t, a, b: real): real = x * (exp(((y * ((ln(z)) - t)) + (a * ((ln(((1) - z))) - b))))) END code
x \cdot e^{y \cdot \left(\log z - t\right) + a \cdot \left(\log \left(1 - z\right) - b\right)}
(FPCore (x y z t a b) :precision binary64 :pre TRUE (* x (exp (+ (* y (- (log z) t)) (* a (- (log1p (- z)) b))))))
double code(double x, double y, double z, double t, double a, double b) {
return x * exp(((y * (log(z) - t)) + (a * (log1p(-z) - b))));
}
public static double code(double x, double y, double z, double t, double a, double b) {
return x * Math.exp(((y * (Math.log(z) - t)) + (a * (Math.log1p(-z) - b))));
}
def code(x, y, z, t, a, b): return x * math.exp(((y * (math.log(z) - t)) + (a * (math.log1p(-z) - b))))
function code(x, y, z, t, a, b) return Float64(x * exp(Float64(Float64(y * Float64(log(z) - t)) + Float64(a * Float64(log1p(Float64(-z)) - b))))) end
code[x_, y_, z_, t_, a_, b_] := N[(x * N[Exp[N[(N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] + N[(a * N[(N[Log[1 + (-z)], $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
f(x, y, z, t, a, b): x in [-inf, +inf], y in [-inf, +inf], z in [-inf, +inf], t in [-inf, +inf], a in [-inf, +inf], b in [-inf, +inf] code: THEORY BEGIN f(x, y, z, t, a, b: real): real = x * (exp(((y * ((ln(z)) - t)) + (a * ((ln(((- z) + (1)))) - b))))) END code
x \cdot e^{y \cdot \left(\log z - t\right) + a \cdot \left(\mathsf{log1p}\left(-z\right) - b\right)}
Initial program 96.5%
Applied rewrites99.2%
(FPCore (x y z t a b) :precision binary64 :pre TRUE (* x (exp (+ (* y (- (log z) t)) (* a (- (* z (- (* -0.5 z) 1.0)) b))))))
double code(double x, double y, double z, double t, double a, double b) {
return x * exp(((y * (log(z) - t)) + (a * ((z * ((-0.5 * z) - 1.0)) - b))));
}
real(8) function code(x, y, z, t, a, b)
use fmin_fmax_functions
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
code = x * exp(((y * (log(z) - t)) + (a * ((z * (((-0.5d0) * z) - 1.0d0)) - b))))
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x * Math.exp(((y * (Math.log(z) - t)) + (a * ((z * ((-0.5 * z) - 1.0)) - b))));
}
def code(x, y, z, t, a, b): return x * math.exp(((y * (math.log(z) - t)) + (a * ((z * ((-0.5 * z) - 1.0)) - b))))
function code(x, y, z, t, a, b) return Float64(x * exp(Float64(Float64(y * Float64(log(z) - t)) + Float64(a * Float64(Float64(z * Float64(Float64(-0.5 * z) - 1.0)) - b))))) end
function tmp = code(x, y, z, t, a, b) tmp = x * exp(((y * (log(z) - t)) + (a * ((z * ((-0.5 * z) - 1.0)) - b)))); end
code[x_, y_, z_, t_, a_, b_] := N[(x * N[Exp[N[(N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] + N[(a * N[(N[(z * N[(N[(-0.5 * z), $MachinePrecision] - 1.0), $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
f(x, y, z, t, a, b): x in [-inf, +inf], y in [-inf, +inf], z in [-inf, +inf], t in [-inf, +inf], a in [-inf, +inf], b in [-inf, +inf] code: THEORY BEGIN f(x, y, z, t, a, b: real): real = x * (exp(((y * ((ln(z)) - t)) + (a * ((z * (((-5e-1) * z) - (1))) - b))))) END code
x \cdot e^{y \cdot \left(\log z - t\right) + a \cdot \left(z \cdot \left(-0.5 \cdot z - 1\right) - b\right)}
Initial program 96.5%
Taylor expanded in z around 0
Applied rewrites99.2%
(FPCore (x y z t a b) :precision binary64 :pre TRUE (* x (exp (+ (* y (- (log z) t)) (* a (- (* -1.0 z) b))))))
double code(double x, double y, double z, double t, double a, double b) {
return x * exp(((y * (log(z) - t)) + (a * ((-1.0 * z) - b))));
}
real(8) function code(x, y, z, t, a, b)
use fmin_fmax_functions
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
code = x * exp(((y * (log(z) - t)) + (a * (((-1.0d0) * z) - b))))
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x * Math.exp(((y * (Math.log(z) - t)) + (a * ((-1.0 * z) - b))));
}
def code(x, y, z, t, a, b): return x * math.exp(((y * (math.log(z) - t)) + (a * ((-1.0 * z) - b))))
function code(x, y, z, t, a, b) return Float64(x * exp(Float64(Float64(y * Float64(log(z) - t)) + Float64(a * Float64(Float64(-1.0 * z) - b))))) end
function tmp = code(x, y, z, t, a, b) tmp = x * exp(((y * (log(z) - t)) + (a * ((-1.0 * z) - b)))); end
code[x_, y_, z_, t_, a_, b_] := N[(x * N[Exp[N[(N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] + N[(a * N[(N[(-1.0 * z), $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
f(x, y, z, t, a, b): x in [-inf, +inf], y in [-inf, +inf], z in [-inf, +inf], t in [-inf, +inf], a in [-inf, +inf], b in [-inf, +inf] code: THEORY BEGIN f(x, y, z, t, a, b: real): real = x * (exp(((y * ((ln(z)) - t)) + (a * (((-1) * z) - b))))) END code
x \cdot e^{y \cdot \left(\log z - t\right) + a \cdot \left(-1 \cdot z - b\right)}
Initial program 96.5%
Taylor expanded in z around 0
Applied rewrites99.1%
(FPCore (x y z t a b)
:precision binary64
:pre TRUE
(let* ((t_1 (* x (exp (* y (- (log z) t))))))
(if (<= y -1.3091999464162745e-14)
t_1
(if (<= y 226065464659316450.0)
(* x (exp (* a (- (log1p (- z)) b))))
t_1))))double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x * exp((y * (log(z) - t)));
double tmp;
if (y <= -1.3091999464162745e-14) {
tmp = t_1;
} else if (y <= 226065464659316450.0) {
tmp = x * exp((a * (log1p(-z) - b)));
} else {
tmp = t_1;
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x * Math.exp((y * (Math.log(z) - t)));
double tmp;
if (y <= -1.3091999464162745e-14) {
tmp = t_1;
} else if (y <= 226065464659316450.0) {
tmp = x * Math.exp((a * (Math.log1p(-z) - b)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x * math.exp((y * (math.log(z) - t))) tmp = 0 if y <= -1.3091999464162745e-14: tmp = t_1 elif y <= 226065464659316450.0: tmp = x * math.exp((a * (math.log1p(-z) - b))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x * exp(Float64(y * Float64(log(z) - t)))) tmp = 0.0 if (y <= -1.3091999464162745e-14) tmp = t_1; elseif (y <= 226065464659316450.0) tmp = Float64(x * exp(Float64(a * Float64(log1p(Float64(-z)) - b)))); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x * N[Exp[N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.3091999464162745e-14], t$95$1, If[LessEqual[y, 226065464659316450.0], N[(x * N[Exp[N[(a * N[(N[Log[1 + (-z)], $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], t$95$1]]]
f(x, y, z, t, a, b): x in [-inf, +inf], y in [-inf, +inf], z in [-inf, +inf], t in [-inf, +inf], a in [-inf, +inf], b in [-inf, +inf] code: THEORY BEGIN f(x, y, z, t, a, b: real): real = LET t_1 = (x * (exp((y * ((ln(z)) - t))))) IN LET tmp_1 = IF (y <= (226065464659316448)) THEN (x * (exp((a * ((ln(((- z) + (1)))) - b))))) ELSE t_1 ENDIF IN LET tmp = IF (y <= (-13091999464162745474106964123472663879982368952126225991605679155327379703521728515625e-99)) THEN t_1 ELSE tmp_1 ENDIF IN tmp END code
\begin{array}{l}
t_1 := x \cdot e^{y \cdot \left(\log z - t\right)}\\
\mathbf{if}\;y \leq -1.3091999464162745 \cdot 10^{-14}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 226065464659316450:\\
\;\;\;\;x \cdot e^{a \cdot \left(\mathsf{log1p}\left(-z\right) - b\right)}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
if y < -1.3091999464162745e-14 or 226065464659316450 < y Initial program 96.5%
Taylor expanded in a around 0
Applied rewrites72.0%
if -1.3091999464162745e-14 < y < 226065464659316450Initial program 96.5%
Taylor expanded in y around 0
Applied rewrites59.1%
Applied rewrites62.9%
(FPCore (x y z t a b)
:precision binary64
:pre TRUE
(let* ((t_1 (* x (exp (* y (- (log z) t))))))
(if (<= y -1.3091999464162745e-14)
t_1
(if (<= y 226065464659316450.0)
(* x (exp (* a (- (* z (- (* -0.5 z) 1.0)) b))))
t_1))))double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x * exp((y * (log(z) - t)));
double tmp;
if (y <= -1.3091999464162745e-14) {
tmp = t_1;
} else if (y <= 226065464659316450.0) {
tmp = x * exp((a * ((z * ((-0.5 * z) - 1.0)) - b)));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
use fmin_fmax_functions
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = x * exp((y * (log(z) - t)))
if (y <= (-1.3091999464162745d-14)) then
tmp = t_1
else if (y <= 226065464659316450.0d0) then
tmp = x * exp((a * ((z * (((-0.5d0) * z) - 1.0d0)) - b)))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x * Math.exp((y * (Math.log(z) - t)));
double tmp;
if (y <= -1.3091999464162745e-14) {
tmp = t_1;
} else if (y <= 226065464659316450.0) {
tmp = x * Math.exp((a * ((z * ((-0.5 * z) - 1.0)) - b)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x * math.exp((y * (math.log(z) - t))) tmp = 0 if y <= -1.3091999464162745e-14: tmp = t_1 elif y <= 226065464659316450.0: tmp = x * math.exp((a * ((z * ((-0.5 * z) - 1.0)) - b))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x * exp(Float64(y * Float64(log(z) - t)))) tmp = 0.0 if (y <= -1.3091999464162745e-14) tmp = t_1; elseif (y <= 226065464659316450.0) tmp = Float64(x * exp(Float64(a * Float64(Float64(z * Float64(Float64(-0.5 * z) - 1.0)) - b)))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x * exp((y * (log(z) - t))); tmp = 0.0; if (y <= -1.3091999464162745e-14) tmp = t_1; elseif (y <= 226065464659316450.0) tmp = x * exp((a * ((z * ((-0.5 * z) - 1.0)) - b))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x * N[Exp[N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.3091999464162745e-14], t$95$1, If[LessEqual[y, 226065464659316450.0], N[(x * N[Exp[N[(a * N[(N[(z * N[(N[(-0.5 * z), $MachinePrecision] - 1.0), $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], t$95$1]]]
f(x, y, z, t, a, b): x in [-inf, +inf], y in [-inf, +inf], z in [-inf, +inf], t in [-inf, +inf], a in [-inf, +inf], b in [-inf, +inf] code: THEORY BEGIN f(x, y, z, t, a, b: real): real = LET t_1 = (x * (exp((y * ((ln(z)) - t))))) IN LET tmp_1 = IF (y <= (226065464659316448)) THEN (x * (exp((a * ((z * (((-5e-1) * z) - (1))) - b))))) ELSE t_1 ENDIF IN LET tmp = IF (y <= (-13091999464162745474106964123472663879982368952126225991605679155327379703521728515625e-99)) THEN t_1 ELSE tmp_1 ENDIF IN tmp END code
\begin{array}{l}
t_1 := x \cdot e^{y \cdot \left(\log z - t\right)}\\
\mathbf{if}\;y \leq -1.3091999464162745 \cdot 10^{-14}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 226065464659316450:\\
\;\;\;\;x \cdot e^{a \cdot \left(z \cdot \left(-0.5 \cdot z - 1\right) - b\right)}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
if y < -1.3091999464162745e-14 or 226065464659316450 < y Initial program 96.5%
Taylor expanded in a around 0
Applied rewrites72.0%
if -1.3091999464162745e-14 < y < 226065464659316450Initial program 96.5%
Taylor expanded in y around 0
Applied rewrites59.1%
Taylor expanded in z around 0
Applied rewrites62.9%
(FPCore (x y z t a b)
:precision binary64
:pre TRUE
(let* ((t_1 (* x (exp (* y (- (log z) t))))))
(if (<= y -1.3091999464162745e-14)
t_1
(if (<= y 226065464659316450.0)
(* x (exp (* a (- (* -1.0 z) b))))
t_1))))double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x * exp((y * (log(z) - t)));
double tmp;
if (y <= -1.3091999464162745e-14) {
tmp = t_1;
} else if (y <= 226065464659316450.0) {
tmp = x * exp((a * ((-1.0 * z) - b)));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
use fmin_fmax_functions
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = x * exp((y * (log(z) - t)))
if (y <= (-1.3091999464162745d-14)) then
tmp = t_1
else if (y <= 226065464659316450.0d0) then
tmp = x * exp((a * (((-1.0d0) * z) - b)))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x * Math.exp((y * (Math.log(z) - t)));
double tmp;
if (y <= -1.3091999464162745e-14) {
tmp = t_1;
} else if (y <= 226065464659316450.0) {
tmp = x * Math.exp((a * ((-1.0 * z) - b)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x * math.exp((y * (math.log(z) - t))) tmp = 0 if y <= -1.3091999464162745e-14: tmp = t_1 elif y <= 226065464659316450.0: tmp = x * math.exp((a * ((-1.0 * z) - b))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x * exp(Float64(y * Float64(log(z) - t)))) tmp = 0.0 if (y <= -1.3091999464162745e-14) tmp = t_1; elseif (y <= 226065464659316450.0) tmp = Float64(x * exp(Float64(a * Float64(Float64(-1.0 * z) - b)))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x * exp((y * (log(z) - t))); tmp = 0.0; if (y <= -1.3091999464162745e-14) tmp = t_1; elseif (y <= 226065464659316450.0) tmp = x * exp((a * ((-1.0 * z) - b))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x * N[Exp[N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.3091999464162745e-14], t$95$1, If[LessEqual[y, 226065464659316450.0], N[(x * N[Exp[N[(a * N[(N[(-1.0 * z), $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], t$95$1]]]
f(x, y, z, t, a, b): x in [-inf, +inf], y in [-inf, +inf], z in [-inf, +inf], t in [-inf, +inf], a in [-inf, +inf], b in [-inf, +inf] code: THEORY BEGIN f(x, y, z, t, a, b: real): real = LET t_1 = (x * (exp((y * ((ln(z)) - t))))) IN LET tmp_1 = IF (y <= (226065464659316448)) THEN (x * (exp((a * (((-1) * z) - b))))) ELSE t_1 ENDIF IN LET tmp = IF (y <= (-13091999464162745474106964123472663879982368952126225991605679155327379703521728515625e-99)) THEN t_1 ELSE tmp_1 ENDIF IN tmp END code
\begin{array}{l}
t_1 := x \cdot e^{y \cdot \left(\log z - t\right)}\\
\mathbf{if}\;y \leq -1.3091999464162745 \cdot 10^{-14}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 226065464659316450:\\
\;\;\;\;x \cdot e^{a \cdot \left(-1 \cdot z - b\right)}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
if y < -1.3091999464162745e-14 or 226065464659316450 < y Initial program 96.5%
Taylor expanded in a around 0
Applied rewrites72.0%
if -1.3091999464162745e-14 < y < 226065464659316450Initial program 96.5%
Taylor expanded in y around 0
Applied rewrites59.1%
Taylor expanded in z around 0
Applied rewrites62.8%
(FPCore (x y z t a b) :precision binary64 :pre TRUE (if (<= (+ (* y (- (log z) t)) (* a (- (log (- 1.0 z)) b))) -4e+14) (* 0.0 1.0) (* x (exp (* a (- (* -1.0 z) b))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (((y * (log(z) - t)) + (a * (log((1.0 - z)) - b))) <= -4e+14) {
tmp = 0.0 * 1.0;
} else {
tmp = x * exp((a * ((-1.0 * z) - b)));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
use fmin_fmax_functions
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (((y * (log(z) - t)) + (a * (log((1.0d0 - z)) - b))) <= (-4d+14)) then
tmp = 0.0d0 * 1.0d0
else
tmp = x * exp((a * (((-1.0d0) * z) - b)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (((y * (Math.log(z) - t)) + (a * (Math.log((1.0 - z)) - b))) <= -4e+14) {
tmp = 0.0 * 1.0;
} else {
tmp = x * Math.exp((a * ((-1.0 * z) - b)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if ((y * (math.log(z) - t)) + (a * (math.log((1.0 - z)) - b))) <= -4e+14: tmp = 0.0 * 1.0 else: tmp = x * math.exp((a * ((-1.0 * z) - b))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (Float64(Float64(y * Float64(log(z) - t)) + Float64(a * Float64(log(Float64(1.0 - z)) - b))) <= -4e+14) tmp = Float64(0.0 * 1.0); else tmp = Float64(x * exp(Float64(a * Float64(Float64(-1.0 * z) - b)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (((y * (log(z) - t)) + (a * (log((1.0 - z)) - b))) <= -4e+14) tmp = 0.0 * 1.0; else tmp = x * exp((a * ((-1.0 * z) - b))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[N[(N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] + N[(a * N[(N[Log[N[(1.0 - z), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], -4e+14], N[(0.0 * 1.0), $MachinePrecision], N[(x * N[Exp[N[(a * N[(N[(-1.0 * z), $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
f(x, y, z, t, a, b): x in [-inf, +inf], y in [-inf, +inf], z in [-inf, +inf], t in [-inf, +inf], a in [-inf, +inf], b in [-inf, +inf] code: THEORY BEGIN f(x, y, z, t, a, b: real): real = LET tmp = IF (((y * ((ln(z)) - t)) + (a * ((ln(((1) - z))) - b))) <= (-4e14)) THEN ((0) * (1)) ELSE (x * (exp((a * (((-1) * z) - b))))) ENDIF IN tmp END code
\begin{array}{l}
\mathbf{if}\;y \cdot \left(\log z - t\right) + a \cdot \left(\log \left(1 - z\right) - b\right) \leq -4 \cdot 10^{+14}:\\
\;\;\;\;0 \cdot 1\\
\mathbf{else}:\\
\;\;\;\;x \cdot e^{a \cdot \left(-1 \cdot z - b\right)}\\
\end{array}
if (+.f64 (*.f64 y (-.f64 (log.f64 z) t)) (*.f64 a (-.f64 (log.f64 (-.f64 #s(literal 1 binary64) z)) b))) < -4e14Initial program 96.5%
Taylor expanded in a around 0
Applied rewrites72.0%
Taylor expanded in y around 0
Applied rewrites18.9%
Taylor expanded in undef-var around zero
Applied rewrites43.4%
if -4e14 < (+.f64 (*.f64 y (-.f64 (log.f64 z) t)) (*.f64 a (-.f64 (log.f64 (-.f64 #s(literal 1 binary64) z)) b))) Initial program 96.5%
Taylor expanded in y around 0
Applied rewrites59.1%
Taylor expanded in z around 0
Applied rewrites62.8%
(FPCore (x y z t a b) :precision binary64 :pre TRUE (if (<= (+ (* y (- (log z) t)) (* a (- (log (- 1.0 z)) b))) -4e+14) (* 0.0 1.0) (* x (exp (* (- b) a)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (((y * (log(z) - t)) + (a * (log((1.0 - z)) - b))) <= -4e+14) {
tmp = 0.0 * 1.0;
} else {
tmp = x * exp((-b * a));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
use fmin_fmax_functions
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (((y * (log(z) - t)) + (a * (log((1.0d0 - z)) - b))) <= (-4d+14)) then
tmp = 0.0d0 * 1.0d0
else
tmp = x * exp((-b * a))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (((y * (Math.log(z) - t)) + (a * (Math.log((1.0 - z)) - b))) <= -4e+14) {
tmp = 0.0 * 1.0;
} else {
tmp = x * Math.exp((-b * a));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if ((y * (math.log(z) - t)) + (a * (math.log((1.0 - z)) - b))) <= -4e+14: tmp = 0.0 * 1.0 else: tmp = x * math.exp((-b * a)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (Float64(Float64(y * Float64(log(z) - t)) + Float64(a * Float64(log(Float64(1.0 - z)) - b))) <= -4e+14) tmp = Float64(0.0 * 1.0); else tmp = Float64(x * exp(Float64(Float64(-b) * a))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (((y * (log(z) - t)) + (a * (log((1.0 - z)) - b))) <= -4e+14) tmp = 0.0 * 1.0; else tmp = x * exp((-b * a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[N[(N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] + N[(a * N[(N[Log[N[(1.0 - z), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], -4e+14], N[(0.0 * 1.0), $MachinePrecision], N[(x * N[Exp[N[((-b) * a), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
f(x, y, z, t, a, b): x in [-inf, +inf], y in [-inf, +inf], z in [-inf, +inf], t in [-inf, +inf], a in [-inf, +inf], b in [-inf, +inf] code: THEORY BEGIN f(x, y, z, t, a, b: real): real = LET tmp = IF (((y * ((ln(z)) - t)) + (a * ((ln(((1) - z))) - b))) <= (-4e14)) THEN ((0) * (1)) ELSE (x * (exp(((- b) * a)))) ENDIF IN tmp END code
\begin{array}{l}
\mathbf{if}\;y \cdot \left(\log z - t\right) + a \cdot \left(\log \left(1 - z\right) - b\right) \leq -4 \cdot 10^{+14}:\\
\;\;\;\;0 \cdot 1\\
\mathbf{else}:\\
\;\;\;\;x \cdot e^{\left(-b\right) \cdot a}\\
\end{array}
if (+.f64 (*.f64 y (-.f64 (log.f64 z) t)) (*.f64 a (-.f64 (log.f64 (-.f64 #s(literal 1 binary64) z)) b))) < -4e14Initial program 96.5%
Taylor expanded in a around 0
Applied rewrites72.0%
Taylor expanded in y around 0
Applied rewrites18.9%
Taylor expanded in undef-var around zero
Applied rewrites43.4%
if -4e14 < (+.f64 (*.f64 y (-.f64 (log.f64 z) t)) (*.f64 a (-.f64 (log.f64 (-.f64 #s(literal 1 binary64) z)) b))) Initial program 96.5%
Taylor expanded in y around 0
Applied rewrites59.1%
Taylor expanded in z around 0
Applied rewrites58.5%
Applied rewrites58.5%
(FPCore (x y z t a b) :precision binary64 :pre TRUE (if (<= (+ (* y (- (log z) t)) (* a (- (log (- 1.0 z)) b))) -20000.0) (* 0.0 1.0) (* x (exp (* (- t) y)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (((y * (log(z) - t)) + (a * (log((1.0 - z)) - b))) <= -20000.0) {
tmp = 0.0 * 1.0;
} else {
tmp = x * exp((-t * y));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
use fmin_fmax_functions
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (((y * (log(z) - t)) + (a * (log((1.0d0 - z)) - b))) <= (-20000.0d0)) then
tmp = 0.0d0 * 1.0d0
else
tmp = x * exp((-t * y))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (((y * (Math.log(z) - t)) + (a * (Math.log((1.0 - z)) - b))) <= -20000.0) {
tmp = 0.0 * 1.0;
} else {
tmp = x * Math.exp((-t * y));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if ((y * (math.log(z) - t)) + (a * (math.log((1.0 - z)) - b))) <= -20000.0: tmp = 0.0 * 1.0 else: tmp = x * math.exp((-t * y)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (Float64(Float64(y * Float64(log(z) - t)) + Float64(a * Float64(log(Float64(1.0 - z)) - b))) <= -20000.0) tmp = Float64(0.0 * 1.0); else tmp = Float64(x * exp(Float64(Float64(-t) * y))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (((y * (log(z) - t)) + (a * (log((1.0 - z)) - b))) <= -20000.0) tmp = 0.0 * 1.0; else tmp = x * exp((-t * y)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[N[(N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] + N[(a * N[(N[Log[N[(1.0 - z), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], -20000.0], N[(0.0 * 1.0), $MachinePrecision], N[(x * N[Exp[N[((-t) * y), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
f(x, y, z, t, a, b): x in [-inf, +inf], y in [-inf, +inf], z in [-inf, +inf], t in [-inf, +inf], a in [-inf, +inf], b in [-inf, +inf] code: THEORY BEGIN f(x, y, z, t, a, b: real): real = LET tmp = IF (((y * ((ln(z)) - t)) + (a * ((ln(((1) - z))) - b))) <= (-2e4)) THEN ((0) * (1)) ELSE (x * (exp(((- t) * y)))) ENDIF IN tmp END code
\begin{array}{l}
\mathbf{if}\;y \cdot \left(\log z - t\right) + a \cdot \left(\log \left(1 - z\right) - b\right) \leq -20000:\\
\;\;\;\;0 \cdot 1\\
\mathbf{else}:\\
\;\;\;\;x \cdot e^{\left(-t\right) \cdot y}\\
\end{array}
if (+.f64 (*.f64 y (-.f64 (log.f64 z) t)) (*.f64 a (-.f64 (log.f64 (-.f64 #s(literal 1 binary64) z)) b))) < -2e4Initial program 96.5%
Taylor expanded in a around 0
Applied rewrites72.0%
Taylor expanded in y around 0
Applied rewrites18.9%
Taylor expanded in undef-var around zero
Applied rewrites43.4%
if -2e4 < (+.f64 (*.f64 y (-.f64 (log.f64 z) t)) (*.f64 a (-.f64 (log.f64 (-.f64 #s(literal 1 binary64) z)) b))) Initial program 96.5%
Taylor expanded in a around 0
Applied rewrites72.0%
Taylor expanded in t around inf
Applied rewrites56.8%
Applied rewrites56.8%
(FPCore (x y z t a b)
:precision binary64
:pre TRUE
(let* ((t_1 (* y (- (log z) t))))
(if (<= (+ t_1 (* a (- (log (- 1.0 z)) b))) -20000.0)
(* 0.0 1.0)
(+ x (* x t_1)))))double code(double x, double y, double z, double t, double a, double b) {
double t_1 = y * (log(z) - t);
double tmp;
if ((t_1 + (a * (log((1.0 - z)) - b))) <= -20000.0) {
tmp = 0.0 * 1.0;
} else {
tmp = x + (x * t_1);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
use fmin_fmax_functions
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = y * (log(z) - t)
if ((t_1 + (a * (log((1.0d0 - z)) - b))) <= (-20000.0d0)) then
tmp = 0.0d0 * 1.0d0
else
tmp = x + (x * t_1)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = y * (Math.log(z) - t);
double tmp;
if ((t_1 + (a * (Math.log((1.0 - z)) - b))) <= -20000.0) {
tmp = 0.0 * 1.0;
} else {
tmp = x + (x * t_1);
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = y * (math.log(z) - t) tmp = 0 if (t_1 + (a * (math.log((1.0 - z)) - b))) <= -20000.0: tmp = 0.0 * 1.0 else: tmp = x + (x * t_1) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(y * Float64(log(z) - t)) tmp = 0.0 if (Float64(t_1 + Float64(a * Float64(log(Float64(1.0 - z)) - b))) <= -20000.0) tmp = Float64(0.0 * 1.0); else tmp = Float64(x + Float64(x * t_1)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = y * (log(z) - t); tmp = 0.0; if ((t_1 + (a * (log((1.0 - z)) - b))) <= -20000.0) tmp = 0.0 * 1.0; else tmp = x + (x * t_1); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(t$95$1 + N[(a * N[(N[Log[N[(1.0 - z), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], -20000.0], N[(0.0 * 1.0), $MachinePrecision], N[(x + N[(x * t$95$1), $MachinePrecision]), $MachinePrecision]]]
f(x, y, z, t, a, b): x in [-inf, +inf], y in [-inf, +inf], z in [-inf, +inf], t in [-inf, +inf], a in [-inf, +inf], b in [-inf, +inf] code: THEORY BEGIN f(x, y, z, t, a, b: real): real = LET t_1 = (y * ((ln(z)) - t)) IN LET tmp = IF ((t_1 + (a * ((ln(((1) - z))) - b))) <= (-2e4)) THEN ((0) * (1)) ELSE (x + (x * t_1)) ENDIF IN tmp END code
\begin{array}{l}
t_1 := y \cdot \left(\log z - t\right)\\
\mathbf{if}\;t\_1 + a \cdot \left(\log \left(1 - z\right) - b\right) \leq -20000:\\
\;\;\;\;0 \cdot 1\\
\mathbf{else}:\\
\;\;\;\;x + x \cdot t\_1\\
\end{array}
if (+.f64 (*.f64 y (-.f64 (log.f64 z) t)) (*.f64 a (-.f64 (log.f64 (-.f64 #s(literal 1 binary64) z)) b))) < -2e4Initial program 96.5%
Taylor expanded in a around 0
Applied rewrites72.0%
Taylor expanded in y around 0
Applied rewrites18.9%
Taylor expanded in undef-var around zero
Applied rewrites43.4%
if -2e4 < (+.f64 (*.f64 y (-.f64 (log.f64 z) t)) (*.f64 a (-.f64 (log.f64 (-.f64 #s(literal 1 binary64) z)) b))) Initial program 96.5%
Taylor expanded in y around 0
Applied rewrites57.7%
Taylor expanded in a around 0
Applied rewrites30.2%
(FPCore (x y z t a b)
:precision binary64
:pre TRUE
(let* ((t_1 (* y (- (log z) t))))
(if (<= (+ t_1 (* a (- (log (- 1.0 z)) b))) -20000.0)
(* 0.0 1.0)
(* x (+ 1.0 t_1)))))double code(double x, double y, double z, double t, double a, double b) {
double t_1 = y * (log(z) - t);
double tmp;
if ((t_1 + (a * (log((1.0 - z)) - b))) <= -20000.0) {
tmp = 0.0 * 1.0;
} else {
tmp = x * (1.0 + t_1);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
use fmin_fmax_functions
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = y * (log(z) - t)
if ((t_1 + (a * (log((1.0d0 - z)) - b))) <= (-20000.0d0)) then
tmp = 0.0d0 * 1.0d0
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 a, double b) {
double t_1 = y * (Math.log(z) - t);
double tmp;
if ((t_1 + (a * (Math.log((1.0 - z)) - b))) <= -20000.0) {
tmp = 0.0 * 1.0;
} else {
tmp = x * (1.0 + t_1);
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = y * (math.log(z) - t) tmp = 0 if (t_1 + (a * (math.log((1.0 - z)) - b))) <= -20000.0: tmp = 0.0 * 1.0 else: tmp = x * (1.0 + t_1) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(y * Float64(log(z) - t)) tmp = 0.0 if (Float64(t_1 + Float64(a * Float64(log(Float64(1.0 - z)) - b))) <= -20000.0) tmp = Float64(0.0 * 1.0); else tmp = Float64(x * Float64(1.0 + t_1)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = y * (log(z) - t); tmp = 0.0; if ((t_1 + (a * (log((1.0 - z)) - b))) <= -20000.0) tmp = 0.0 * 1.0; else tmp = x * (1.0 + t_1); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(t$95$1 + N[(a * N[(N[Log[N[(1.0 - z), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], -20000.0], N[(0.0 * 1.0), $MachinePrecision], N[(x * N[(1.0 + t$95$1), $MachinePrecision]), $MachinePrecision]]]
f(x, y, z, t, a, b): x in [-inf, +inf], y in [-inf, +inf], z in [-inf, +inf], t in [-inf, +inf], a in [-inf, +inf], b in [-inf, +inf] code: THEORY BEGIN f(x, y, z, t, a, b: real): real = LET t_1 = (y * ((ln(z)) - t)) IN LET tmp = IF ((t_1 + (a * ((ln(((1) - z))) - b))) <= (-2e4)) THEN ((0) * (1)) ELSE (x * ((1) + t_1)) ENDIF IN tmp END code
\begin{array}{l}
t_1 := y \cdot \left(\log z - t\right)\\
\mathbf{if}\;t\_1 + a \cdot \left(\log \left(1 - z\right) - b\right) \leq -20000:\\
\;\;\;\;0 \cdot 1\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(1 + t\_1\right)\\
\end{array}
if (+.f64 (*.f64 y (-.f64 (log.f64 z) t)) (*.f64 a (-.f64 (log.f64 (-.f64 #s(literal 1 binary64) z)) b))) < -2e4Initial program 96.5%
Taylor expanded in a around 0
Applied rewrites72.0%
Taylor expanded in y around 0
Applied rewrites18.9%
Taylor expanded in undef-var around zero
Applied rewrites43.4%
if -2e4 < (+.f64 (*.f64 y (-.f64 (log.f64 z) t)) (*.f64 a (-.f64 (log.f64 (-.f64 #s(literal 1 binary64) z)) b))) Initial program 96.5%
Taylor expanded in a around 0
Applied rewrites72.0%
Taylor expanded in y around 0
Applied rewrites30.2%
(FPCore (x y z t a b)
:precision binary64
:pre TRUE
(let* ((t_1 (- (log z) t)))
(if (<= (+ (* y t_1) (* a (- (log (- 1.0 z)) b))) -20000.0)
(* 0.0 1.0)
(fma y (* t_1 x) x))))double code(double x, double y, double z, double t, double a, double b) {
double t_1 = log(z) - t;
double tmp;
if (((y * t_1) + (a * (log((1.0 - z)) - b))) <= -20000.0) {
tmp = 0.0 * 1.0;
} else {
tmp = fma(y, (t_1 * x), x);
}
return tmp;
}
function code(x, y, z, t, a, b) t_1 = Float64(log(z) - t) tmp = 0.0 if (Float64(Float64(y * t_1) + Float64(a * Float64(log(Float64(1.0 - z)) - b))) <= -20000.0) tmp = Float64(0.0 * 1.0); else tmp = fma(y, Float64(t_1 * x), x); end return tmp end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]}, If[LessEqual[N[(N[(y * t$95$1), $MachinePrecision] + N[(a * N[(N[Log[N[(1.0 - z), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], -20000.0], N[(0.0 * 1.0), $MachinePrecision], N[(y * N[(t$95$1 * x), $MachinePrecision] + x), $MachinePrecision]]]
f(x, y, z, t, a, b): x in [-inf, +inf], y in [-inf, +inf], z in [-inf, +inf], t in [-inf, +inf], a in [-inf, +inf], b in [-inf, +inf] code: THEORY BEGIN f(x, y, z, t, a, b: real): real = LET t_1 = ((ln(z)) - t) IN LET tmp = IF (((y * t_1) + (a * ((ln(((1) - z))) - b))) <= (-2e4)) THEN ((0) * (1)) ELSE ((y * (t_1 * x)) + x) ENDIF IN tmp END code
\begin{array}{l}
t_1 := \log z - t\\
\mathbf{if}\;y \cdot t\_1 + a \cdot \left(\log \left(1 - z\right) - b\right) \leq -20000:\\
\;\;\;\;0 \cdot 1\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(y, t\_1 \cdot x, x\right)\\
\end{array}
if (+.f64 (*.f64 y (-.f64 (log.f64 z) t)) (*.f64 a (-.f64 (log.f64 (-.f64 #s(literal 1 binary64) z)) b))) < -2e4Initial program 96.5%
Taylor expanded in a around 0
Applied rewrites72.0%
Taylor expanded in y around 0
Applied rewrites18.9%
Taylor expanded in undef-var around zero
Applied rewrites43.4%
if -2e4 < (+.f64 (*.f64 y (-.f64 (log.f64 z) t)) (*.f64 a (-.f64 (log.f64 (-.f64 #s(literal 1 binary64) z)) b))) Initial program 96.5%
Taylor expanded in y around 0
Applied rewrites57.7%
Taylor expanded in a around 0
Applied rewrites30.2%
Applied rewrites28.5%
(FPCore (x y z t a b) :precision binary64 :pre TRUE (if (<= (+ (* y (- (log z) t)) (* a (- (log (- 1.0 z)) b))) -20000.0) (* 0.0 1.0) (fma (- (* t y)) x x)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (((y * (log(z) - t)) + (a * (log((1.0 - z)) - b))) <= -20000.0) {
tmp = 0.0 * 1.0;
} else {
tmp = fma(-(t * y), x, x);
}
return tmp;
}
function code(x, y, z, t, a, b) tmp = 0.0 if (Float64(Float64(y * Float64(log(z) - t)) + Float64(a * Float64(log(Float64(1.0 - z)) - b))) <= -20000.0) tmp = Float64(0.0 * 1.0); else tmp = fma(Float64(-Float64(t * y)), x, x); end return tmp end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[N[(N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] + N[(a * N[(N[Log[N[(1.0 - z), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], -20000.0], N[(0.0 * 1.0), $MachinePrecision], N[((-N[(t * y), $MachinePrecision]) * x + x), $MachinePrecision]]
f(x, y, z, t, a, b): x in [-inf, +inf], y in [-inf, +inf], z in [-inf, +inf], t in [-inf, +inf], a in [-inf, +inf], b in [-inf, +inf] code: THEORY BEGIN f(x, y, z, t, a, b: real): real = LET tmp = IF (((y * ((ln(z)) - t)) + (a * ((ln(((1) - z))) - b))) <= (-2e4)) THEN ((0) * (1)) ELSE (((- (t * y)) * x) + x) ENDIF IN tmp END code
\begin{array}{l}
\mathbf{if}\;y \cdot \left(\log z - t\right) + a \cdot \left(\log \left(1 - z\right) - b\right) \leq -20000:\\
\;\;\;\;0 \cdot 1\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(-t \cdot y, x, x\right)\\
\end{array}
if (+.f64 (*.f64 y (-.f64 (log.f64 z) t)) (*.f64 a (-.f64 (log.f64 (-.f64 #s(literal 1 binary64) z)) b))) < -2e4Initial program 96.5%
Taylor expanded in a around 0
Applied rewrites72.0%
Taylor expanded in y around 0
Applied rewrites18.9%
Taylor expanded in undef-var around zero
Applied rewrites43.4%
if -2e4 < (+.f64 (*.f64 y (-.f64 (log.f64 z) t)) (*.f64 a (-.f64 (log.f64 (-.f64 #s(literal 1 binary64) z)) b))) Initial program 96.5%
Taylor expanded in y around 0
Applied rewrites57.7%
Taylor expanded in a around 0
Applied rewrites30.2%
Taylor expanded in t around inf
Applied rewrites27.7%
Applied rewrites27.7%
(FPCore (x y z t a b)
:precision binary64
:pre TRUE
(if (<=
(+ (* y (- (log z) t)) (* a (- (log (- 1.0 z)) b)))
-25.801916055828222)
(* 0.0 1.0)
(* x 1.0)))double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (((y * (log(z) - t)) + (a * (log((1.0 - z)) - b))) <= -25.801916055828222) {
tmp = 0.0 * 1.0;
} else {
tmp = x * 1.0;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
use fmin_fmax_functions
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (((y * (log(z) - t)) + (a * (log((1.0d0 - z)) - b))) <= (-25.801916055828222d0)) then
tmp = 0.0d0 * 1.0d0
else
tmp = x * 1.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (((y * (Math.log(z) - t)) + (a * (Math.log((1.0 - z)) - b))) <= -25.801916055828222) {
tmp = 0.0 * 1.0;
} else {
tmp = x * 1.0;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if ((y * (math.log(z) - t)) + (a * (math.log((1.0 - z)) - b))) <= -25.801916055828222: tmp = 0.0 * 1.0 else: tmp = x * 1.0 return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (Float64(Float64(y * Float64(log(z) - t)) + Float64(a * Float64(log(Float64(1.0 - z)) - b))) <= -25.801916055828222) tmp = Float64(0.0 * 1.0); else tmp = Float64(x * 1.0); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (((y * (log(z) - t)) + (a * (log((1.0 - z)) - b))) <= -25.801916055828222) tmp = 0.0 * 1.0; else tmp = x * 1.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[N[(N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] + N[(a * N[(N[Log[N[(1.0 - z), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], -25.801916055828222], N[(0.0 * 1.0), $MachinePrecision], N[(x * 1.0), $MachinePrecision]]
f(x, y, z, t, a, b): x in [-inf, +inf], y in [-inf, +inf], z in [-inf, +inf], t in [-inf, +inf], a in [-inf, +inf], b in [-inf, +inf] code: THEORY BEGIN f(x, y, z, t, a, b: real): real = LET tmp = IF (((y * ((ln(z)) - t)) + (a * ((ln(((1) - z))) - b))) <= (-2580191605582822234055129229091107845306396484375e-47)) THEN ((0) * (1)) ELSE (x * (1)) ENDIF IN tmp END code
\begin{array}{l}
\mathbf{if}\;y \cdot \left(\log z - t\right) + a \cdot \left(\log \left(1 - z\right) - b\right) \leq -25.801916055828222:\\
\;\;\;\;0 \cdot 1\\
\mathbf{else}:\\
\;\;\;\;x \cdot 1\\
\end{array}
if (+.f64 (*.f64 y (-.f64 (log.f64 z) t)) (*.f64 a (-.f64 (log.f64 (-.f64 #s(literal 1 binary64) z)) b))) < -25.801916055828222Initial program 96.5%
Taylor expanded in a around 0
Applied rewrites72.0%
Taylor expanded in y around 0
Applied rewrites18.9%
Taylor expanded in undef-var around zero
Applied rewrites43.4%
if -25.801916055828222 < (+.f64 (*.f64 y (-.f64 (log.f64 z) t)) (*.f64 a (-.f64 (log.f64 (-.f64 #s(literal 1 binary64) z)) b))) Initial program 96.5%
Taylor expanded in a around 0
Applied rewrites72.0%
Taylor expanded in y around 0
Applied rewrites18.9%
(FPCore (x y z t a b) :precision binary64 :pre TRUE (* x 1.0))
double code(double x, double y, double z, double t, double a, double b) {
return x * 1.0;
}
real(8) function code(x, y, z, t, a, b)
use fmin_fmax_functions
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
code = x * 1.0d0
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x * 1.0;
}
def code(x, y, z, t, a, b): return x * 1.0
function code(x, y, z, t, a, b) return Float64(x * 1.0) end
function tmp = code(x, y, z, t, a, b) tmp = x * 1.0; end
code[x_, y_, z_, t_, a_, b_] := N[(x * 1.0), $MachinePrecision]
f(x, y, z, t, a, b): x in [-inf, +inf], y in [-inf, +inf], z in [-inf, +inf], t in [-inf, +inf], a in [-inf, +inf], b in [-inf, +inf] code: THEORY BEGIN f(x, y, z, t, a, b: real): real = x * (1) END code
x \cdot 1
Initial program 96.5%
Taylor expanded in a around 0
Applied rewrites72.0%
Taylor expanded in y around 0
Applied rewrites18.9%
herbie shell --seed 2026092
(FPCore (x y z t a b)
:name "Numeric.SpecFunctions:incompleteBetaApprox from math-functions-0.1.5.2, B"
:precision binary64
(* x (exp (+ (* y (- (log z) t)) (* a (- (log (- 1.0 z)) b))))))