
(FPCore (a b) :precision binary64 (- (+ (pow (+ (* a a) (* b b)) 2.0) (* 4.0 (+ (* (* a a) (+ 1.0 a)) (* (* b b) (- 1.0 (* 3.0 a)))))) 1.0))
double code(double a, double b) {
return (pow(((a * a) + (b * b)), 2.0) + (4.0 * (((a * a) * (1.0 + a)) + ((b * b) * (1.0 - (3.0 * a)))))) - 1.0;
}
real(8) function code(a, b)
real(8), intent (in) :: a
real(8), intent (in) :: b
code = ((((a * a) + (b * b)) ** 2.0d0) + (4.0d0 * (((a * a) * (1.0d0 + a)) + ((b * b) * (1.0d0 - (3.0d0 * a)))))) - 1.0d0
end function
public static double code(double a, double b) {
return (Math.pow(((a * a) + (b * b)), 2.0) + (4.0 * (((a * a) * (1.0 + a)) + ((b * b) * (1.0 - (3.0 * a)))))) - 1.0;
}
def code(a, b): return (math.pow(((a * a) + (b * b)), 2.0) + (4.0 * (((a * a) * (1.0 + a)) + ((b * b) * (1.0 - (3.0 * a)))))) - 1.0
function code(a, b) return Float64(Float64((Float64(Float64(a * a) + Float64(b * b)) ^ 2.0) + Float64(4.0 * Float64(Float64(Float64(a * a) * Float64(1.0 + a)) + Float64(Float64(b * b) * Float64(1.0 - Float64(3.0 * a)))))) - 1.0) end
function tmp = code(a, b) tmp = ((((a * a) + (b * b)) ^ 2.0) + (4.0 * (((a * a) * (1.0 + a)) + ((b * b) * (1.0 - (3.0 * a)))))) - 1.0; end
code[a_, b_] := N[(N[(N[Power[N[(N[(a * a), $MachinePrecision] + N[(b * b), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] + N[(4.0 * N[(N[(N[(a * a), $MachinePrecision] * N[(1.0 + a), $MachinePrecision]), $MachinePrecision] + N[(N[(b * b), $MachinePrecision] * N[(1.0 - N[(3.0 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - 1.0), $MachinePrecision]
\begin{array}{l}
\\
\left({\left(a \cdot a + b \cdot b\right)}^{2} + 4 \cdot \left(\left(a \cdot a\right) \cdot \left(1 + a\right) + \left(b \cdot b\right) \cdot \left(1 - 3 \cdot a\right)\right)\right) - 1
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 6 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (a b) :precision binary64 (- (+ (pow (+ (* a a) (* b b)) 2.0) (* 4.0 (+ (* (* a a) (+ 1.0 a)) (* (* b b) (- 1.0 (* 3.0 a)))))) 1.0))
double code(double a, double b) {
return (pow(((a * a) + (b * b)), 2.0) + (4.0 * (((a * a) * (1.0 + a)) + ((b * b) * (1.0 - (3.0 * a)))))) - 1.0;
}
real(8) function code(a, b)
real(8), intent (in) :: a
real(8), intent (in) :: b
code = ((((a * a) + (b * b)) ** 2.0d0) + (4.0d0 * (((a * a) * (1.0d0 + a)) + ((b * b) * (1.0d0 - (3.0d0 * a)))))) - 1.0d0
end function
public static double code(double a, double b) {
return (Math.pow(((a * a) + (b * b)), 2.0) + (4.0 * (((a * a) * (1.0 + a)) + ((b * b) * (1.0 - (3.0 * a)))))) - 1.0;
}
def code(a, b): return (math.pow(((a * a) + (b * b)), 2.0) + (4.0 * (((a * a) * (1.0 + a)) + ((b * b) * (1.0 - (3.0 * a)))))) - 1.0
function code(a, b) return Float64(Float64((Float64(Float64(a * a) + Float64(b * b)) ^ 2.0) + Float64(4.0 * Float64(Float64(Float64(a * a) * Float64(1.0 + a)) + Float64(Float64(b * b) * Float64(1.0 - Float64(3.0 * a)))))) - 1.0) end
function tmp = code(a, b) tmp = ((((a * a) + (b * b)) ^ 2.0) + (4.0 * (((a * a) * (1.0 + a)) + ((b * b) * (1.0 - (3.0 * a)))))) - 1.0; end
code[a_, b_] := N[(N[(N[Power[N[(N[(a * a), $MachinePrecision] + N[(b * b), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] + N[(4.0 * N[(N[(N[(a * a), $MachinePrecision] * N[(1.0 + a), $MachinePrecision]), $MachinePrecision] + N[(N[(b * b), $MachinePrecision] * N[(1.0 - N[(3.0 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - 1.0), $MachinePrecision]
\begin{array}{l}
\\
\left({\left(a \cdot a + b \cdot b\right)}^{2} + 4 \cdot \left(\left(a \cdot a\right) \cdot \left(1 + a\right) + \left(b \cdot b\right) \cdot \left(1 - 3 \cdot a\right)\right)\right) - 1
\end{array}
(FPCore (a b) :precision binary64 (if (<= a -5e+102) (+ (pow a 4.0) -1.0) (+ -1.0 (+ (* 4.0 (pow a 3.0)) (pow (hypot a b) 4.0)))))
double code(double a, double b) {
double tmp;
if (a <= -5e+102) {
tmp = pow(a, 4.0) + -1.0;
} else {
tmp = -1.0 + ((4.0 * pow(a, 3.0)) + pow(hypot(a, b), 4.0));
}
return tmp;
}
public static double code(double a, double b) {
double tmp;
if (a <= -5e+102) {
tmp = Math.pow(a, 4.0) + -1.0;
} else {
tmp = -1.0 + ((4.0 * Math.pow(a, 3.0)) + Math.pow(Math.hypot(a, b), 4.0));
}
return tmp;
}
def code(a, b): tmp = 0 if a <= -5e+102: tmp = math.pow(a, 4.0) + -1.0 else: tmp = -1.0 + ((4.0 * math.pow(a, 3.0)) + math.pow(math.hypot(a, b), 4.0)) return tmp
function code(a, b) tmp = 0.0 if (a <= -5e+102) tmp = Float64((a ^ 4.0) + -1.0); else tmp = Float64(-1.0 + Float64(Float64(4.0 * (a ^ 3.0)) + (hypot(a, b) ^ 4.0))); end return tmp end
function tmp_2 = code(a, b) tmp = 0.0; if (a <= -5e+102) tmp = (a ^ 4.0) + -1.0; else tmp = -1.0 + ((4.0 * (a ^ 3.0)) + (hypot(a, b) ^ 4.0)); end tmp_2 = tmp; end
code[a_, b_] := If[LessEqual[a, -5e+102], N[(N[Power[a, 4.0], $MachinePrecision] + -1.0), $MachinePrecision], N[(-1.0 + N[(N[(4.0 * N[Power[a, 3.0], $MachinePrecision]), $MachinePrecision] + N[Power[N[Sqrt[a ^ 2 + b ^ 2], $MachinePrecision], 4.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -5 \cdot 10^{+102}:\\
\;\;\;\;{a}^{4} + -1\\
\mathbf{else}:\\
\;\;\;\;-1 + \left(4 \cdot {a}^{3} + {\left(\mathsf{hypot}\left(a, b\right)\right)}^{4}\right)\\
\end{array}
\end{array}
if a < -5e102Initial program 0.0%
sub-neg0.0%
Simplified16.2%
Taylor expanded in a around inf 100.0%
if -5e102 < a Initial program 86.7%
sub-neg86.7%
Simplified86.7%
Taylor expanded in a around inf 99.2%
fma-def99.2%
expm1-log1p-u97.8%
expm1-udef97.8%
fma-def97.8%
add-sqr-sqrt97.8%
pow297.8%
fma-def97.8%
hypot-def97.8%
Applied egg-rr97.8%
expm1-def97.8%
expm1-log1p99.2%
unpow299.2%
pow-sqr99.3%
metadata-eval99.3%
Simplified99.3%
Final simplification99.4%
(FPCore (a b)
:precision binary64
(let* ((t_0
(+
(pow (+ (* a a) (* b b)) 2.0)
(* 4.0 (+ (* (* a a) (+ a 1.0)) (* (* b b) (- 1.0 (* a 3.0))))))))
(if (<= t_0 INFINITY) (+ -1.0 t_0) (+ (pow a 4.0) -1.0))))
double code(double a, double b) {
double t_0 = pow(((a * a) + (b * b)), 2.0) + (4.0 * (((a * a) * (a + 1.0)) + ((b * b) * (1.0 - (a * 3.0)))));
double tmp;
if (t_0 <= ((double) INFINITY)) {
tmp = -1.0 + t_0;
} else {
tmp = pow(a, 4.0) + -1.0;
}
return tmp;
}
public static double code(double a, double b) {
double t_0 = Math.pow(((a * a) + (b * b)), 2.0) + (4.0 * (((a * a) * (a + 1.0)) + ((b * b) * (1.0 - (a * 3.0)))));
double tmp;
if (t_0 <= Double.POSITIVE_INFINITY) {
tmp = -1.0 + t_0;
} else {
tmp = Math.pow(a, 4.0) + -1.0;
}
return tmp;
}
def code(a, b): t_0 = math.pow(((a * a) + (b * b)), 2.0) + (4.0 * (((a * a) * (a + 1.0)) + ((b * b) * (1.0 - (a * 3.0))))) tmp = 0 if t_0 <= math.inf: tmp = -1.0 + t_0 else: tmp = math.pow(a, 4.0) + -1.0 return tmp
function code(a, b) t_0 = Float64((Float64(Float64(a * a) + Float64(b * b)) ^ 2.0) + Float64(4.0 * Float64(Float64(Float64(a * a) * Float64(a + 1.0)) + Float64(Float64(b * b) * Float64(1.0 - Float64(a * 3.0)))))) tmp = 0.0 if (t_0 <= Inf) tmp = Float64(-1.0 + t_0); else tmp = Float64((a ^ 4.0) + -1.0); end return tmp end
function tmp_2 = code(a, b) t_0 = (((a * a) + (b * b)) ^ 2.0) + (4.0 * (((a * a) * (a + 1.0)) + ((b * b) * (1.0 - (a * 3.0))))); tmp = 0.0; if (t_0 <= Inf) tmp = -1.0 + t_0; else tmp = (a ^ 4.0) + -1.0; end tmp_2 = tmp; end
code[a_, b_] := Block[{t$95$0 = N[(N[Power[N[(N[(a * a), $MachinePrecision] + N[(b * b), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] + N[(4.0 * N[(N[(N[(a * a), $MachinePrecision] * N[(a + 1.0), $MachinePrecision]), $MachinePrecision] + N[(N[(b * b), $MachinePrecision] * N[(1.0 - N[(a * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$0, Infinity], N[(-1.0 + t$95$0), $MachinePrecision], N[(N[Power[a, 4.0], $MachinePrecision] + -1.0), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := {\left(a \cdot a + b \cdot b\right)}^{2} + 4 \cdot \left(\left(a \cdot a\right) \cdot \left(a + 1\right) + \left(b \cdot b\right) \cdot \left(1 - a \cdot 3\right)\right)\\
\mathbf{if}\;t_0 \leq \infty:\\
\;\;\;\;-1 + t_0\\
\mathbf{else}:\\
\;\;\;\;{a}^{4} + -1\\
\end{array}
\end{array}
if (+.f64 (pow.f64 (+.f64 (*.f64 a a) (*.f64 b b)) 2) (*.f64 4 (+.f64 (*.f64 (*.f64 a a) (+.f64 1 a)) (*.f64 (*.f64 b b) (-.f64 1 (*.f64 3 a)))))) < +inf.0Initial program 99.9%
if +inf.0 < (+.f64 (pow.f64 (+.f64 (*.f64 a a) (*.f64 b b)) 2) (*.f64 4 (+.f64 (*.f64 (*.f64 a a) (+.f64 1 a)) (*.f64 (*.f64 b b) (-.f64 1 (*.f64 3 a)))))) Initial program 0.0%
sub-neg0.0%
Simplified9.1%
Taylor expanded in a around inf 90.0%
Final simplification97.3%
(FPCore (a b) :precision binary64 (if (<= b 17.0) (+ (pow a 4.0) -1.0) (+ -1.0 (* b (* b (fma b b 4.0))))))
double code(double a, double b) {
double tmp;
if (b <= 17.0) {
tmp = pow(a, 4.0) + -1.0;
} else {
tmp = -1.0 + (b * (b * fma(b, b, 4.0)));
}
return tmp;
}
function code(a, b) tmp = 0.0 if (b <= 17.0) tmp = Float64((a ^ 4.0) + -1.0); else tmp = Float64(-1.0 + Float64(b * Float64(b * fma(b, b, 4.0)))); end return tmp end
code[a_, b_] := If[LessEqual[b, 17.0], N[(N[Power[a, 4.0], $MachinePrecision] + -1.0), $MachinePrecision], N[(-1.0 + N[(b * N[(b * N[(b * b + 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq 17:\\
\;\;\;\;{a}^{4} + -1\\
\mathbf{else}:\\
\;\;\;\;-1 + b \cdot \left(b \cdot \mathsf{fma}\left(b, b, 4\right)\right)\\
\end{array}
\end{array}
if b < 17Initial program 78.7%
sub-neg78.7%
Simplified79.3%
Taylor expanded in a around inf 80.7%
if 17 < b Initial program 61.1%
associate--l+61.1%
+-commutative61.1%
+-commutative61.1%
sub-neg61.1%
associate-+l+61.1%
+-commutative61.1%
fma-def62.6%
Simplified65.6%
Taylor expanded in a around 0 88.7%
flip-+15.4%
frac-2neg15.4%
pow215.4%
*-commutative15.4%
pow215.4%
*-commutative15.4%
swap-sqr15.4%
pow215.4%
pow-prod-down15.4%
pow-prod-up15.4%
metadata-eval15.4%
metadata-eval15.4%
pow-prod-up15.3%
metadata-eval15.3%
Applied egg-rr15.3%
neg-sub015.3%
associate--r-15.3%
neg-sub015.3%
+-commutative15.3%
sub-neg15.3%
neg-sub015.3%
associate--r-15.3%
neg-sub015.3%
+-commutative15.3%
sub-neg15.3%
*-commutative15.3%
unpow215.3%
metadata-eval15.3%
swap-sqr15.3%
unpow215.3%
Simplified15.3%
metadata-eval15.3%
pow-sqr15.3%
metadata-eval15.3%
swap-sqr15.3%
metadata-eval15.3%
unpow-prod-down15.3%
metadata-eval15.3%
unpow-prod-down15.3%
metadata-eval15.3%
pow-sqr15.4%
flip-+88.7%
metadata-eval88.7%
pow-sqr88.6%
unpow-prod-down88.6%
metadata-eval88.6%
distribute-lft-in88.6%
*-commutative88.6%
unpow288.6%
associate-*r*88.6%
Applied egg-rr88.6%
Final simplification82.8%
(FPCore (a b) :precision binary64 (if (<= b 1.36e+144) (+ (pow a 4.0) -1.0) (+ -1.0 (* b (* 4.0 b)))))
double code(double a, double b) {
double tmp;
if (b <= 1.36e+144) {
tmp = pow(a, 4.0) + -1.0;
} else {
tmp = -1.0 + (b * (4.0 * b));
}
return tmp;
}
real(8) function code(a, b)
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (b <= 1.36d+144) then
tmp = (a ** 4.0d0) + (-1.0d0)
else
tmp = (-1.0d0) + (b * (4.0d0 * b))
end if
code = tmp
end function
public static double code(double a, double b) {
double tmp;
if (b <= 1.36e+144) {
tmp = Math.pow(a, 4.0) + -1.0;
} else {
tmp = -1.0 + (b * (4.0 * b));
}
return tmp;
}
def code(a, b): tmp = 0 if b <= 1.36e+144: tmp = math.pow(a, 4.0) + -1.0 else: tmp = -1.0 + (b * (4.0 * b)) return tmp
function code(a, b) tmp = 0.0 if (b <= 1.36e+144) tmp = Float64((a ^ 4.0) + -1.0); else tmp = Float64(-1.0 + Float64(b * Float64(4.0 * b))); end return tmp end
function tmp_2 = code(a, b) tmp = 0.0; if (b <= 1.36e+144) tmp = (a ^ 4.0) + -1.0; else tmp = -1.0 + (b * (4.0 * b)); end tmp_2 = tmp; end
code[a_, b_] := If[LessEqual[b, 1.36e+144], N[(N[Power[a, 4.0], $MachinePrecision] + -1.0), $MachinePrecision], N[(-1.0 + N[(b * N[(4.0 * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq 1.36 \cdot 10^{+144}:\\
\;\;\;\;{a}^{4} + -1\\
\mathbf{else}:\\
\;\;\;\;-1 + b \cdot \left(4 \cdot b\right)\\
\end{array}
\end{array}
if b < 1.35999999999999993e144Initial program 76.2%
sub-neg76.2%
Simplified77.5%
Taylor expanded in a around inf 75.3%
if 1.35999999999999993e144 < b Initial program 62.2%
associate--l+62.2%
+-commutative62.2%
+-commutative62.2%
sub-neg62.2%
associate-+l+62.2%
+-commutative62.2%
fma-def62.2%
Simplified62.2%
Taylor expanded in a around 0 100.0%
flip-+0.0%
frac-2neg0.0%
pow20.0%
*-commutative0.0%
pow20.0%
*-commutative0.0%
swap-sqr0.0%
pow20.0%
pow-prod-down0.0%
pow-prod-up0.0%
metadata-eval0.0%
metadata-eval0.0%
pow-prod-up0.0%
metadata-eval0.0%
Applied egg-rr0.0%
neg-sub00.0%
associate--r-0.0%
neg-sub00.0%
+-commutative0.0%
sub-neg0.0%
neg-sub00.0%
associate--r-0.0%
neg-sub00.0%
+-commutative0.0%
sub-neg0.0%
*-commutative0.0%
unpow20.0%
metadata-eval0.0%
swap-sqr0.0%
unpow20.0%
Simplified0.0%
metadata-eval0.0%
pow-sqr0.0%
metadata-eval0.0%
swap-sqr0.0%
metadata-eval0.0%
unpow-prod-down0.0%
metadata-eval0.0%
unpow-prod-down0.0%
metadata-eval0.0%
pow-sqr0.0%
flip-+100.0%
metadata-eval100.0%
pow-sqr100.0%
unpow-prod-down100.0%
metadata-eval100.0%
distribute-lft-in100.0%
*-commutative100.0%
unpow2100.0%
associate-*r*100.0%
Applied egg-rr100.0%
Taylor expanded in b around 0 97.6%
Final simplification78.5%
(FPCore (a b) :precision binary64 (if (<= b 3100.0) (+ (pow a 4.0) -1.0) (+ -1.0 (pow b 4.0))))
double code(double a, double b) {
double tmp;
if (b <= 3100.0) {
tmp = pow(a, 4.0) + -1.0;
} else {
tmp = -1.0 + pow(b, 4.0);
}
return tmp;
}
real(8) function code(a, b)
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (b <= 3100.0d0) then
tmp = (a ** 4.0d0) + (-1.0d0)
else
tmp = (-1.0d0) + (b ** 4.0d0)
end if
code = tmp
end function
public static double code(double a, double b) {
double tmp;
if (b <= 3100.0) {
tmp = Math.pow(a, 4.0) + -1.0;
} else {
tmp = -1.0 + Math.pow(b, 4.0);
}
return tmp;
}
def code(a, b): tmp = 0 if b <= 3100.0: tmp = math.pow(a, 4.0) + -1.0 else: tmp = -1.0 + math.pow(b, 4.0) return tmp
function code(a, b) tmp = 0.0 if (b <= 3100.0) tmp = Float64((a ^ 4.0) + -1.0); else tmp = Float64(-1.0 + (b ^ 4.0)); end return tmp end
function tmp_2 = code(a, b) tmp = 0.0; if (b <= 3100.0) tmp = (a ^ 4.0) + -1.0; else tmp = -1.0 + (b ^ 4.0); end tmp_2 = tmp; end
code[a_, b_] := If[LessEqual[b, 3100.0], N[(N[Power[a, 4.0], $MachinePrecision] + -1.0), $MachinePrecision], N[(-1.0 + N[Power[b, 4.0], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq 3100:\\
\;\;\;\;{a}^{4} + -1\\
\mathbf{else}:\\
\;\;\;\;-1 + {b}^{4}\\
\end{array}
\end{array}
if b < 3100Initial program 78.7%
sub-neg78.7%
Simplified79.3%
Taylor expanded in a around inf 80.7%
if 3100 < b Initial program 61.1%
sub-neg61.1%
Simplified68.6%
Taylor expanded in b around inf 87.9%
Final simplification82.6%
(FPCore (a b) :precision binary64 (+ -1.0 (* b (* 4.0 b))))
double code(double a, double b) {
return -1.0 + (b * (4.0 * b));
}
real(8) function code(a, b)
real(8), intent (in) :: a
real(8), intent (in) :: b
code = (-1.0d0) + (b * (4.0d0 * b))
end function
public static double code(double a, double b) {
return -1.0 + (b * (4.0 * b));
}
def code(a, b): return -1.0 + (b * (4.0 * b))
function code(a, b) return Float64(-1.0 + Float64(b * Float64(4.0 * b))) end
function tmp = code(a, b) tmp = -1.0 + (b * (4.0 * b)); end
code[a_, b_] := N[(-1.0 + N[(b * N[(4.0 * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
-1 + b \cdot \left(4 \cdot b\right)
\end{array}
Initial program 74.1%
associate--l+74.1%
+-commutative74.1%
+-commutative74.1%
sub-neg74.1%
associate-+l+74.1%
+-commutative74.1%
fma-def74.5%
Simplified76.9%
Taylor expanded in a around 0 72.3%
flip-+22.6%
frac-2neg22.6%
pow222.6%
*-commutative22.6%
pow222.6%
*-commutative22.6%
swap-sqr22.6%
pow222.6%
pow-prod-down22.6%
pow-prod-up22.6%
metadata-eval22.6%
metadata-eval22.6%
pow-prod-up22.6%
metadata-eval22.6%
Applied egg-rr22.6%
neg-sub022.6%
associate--r-22.6%
neg-sub022.6%
+-commutative22.6%
sub-neg22.6%
neg-sub022.6%
associate--r-22.6%
neg-sub022.6%
+-commutative22.6%
sub-neg22.6%
*-commutative22.6%
unpow222.6%
metadata-eval22.6%
swap-sqr22.6%
unpow222.6%
Simplified22.6%
metadata-eval22.6%
pow-sqr22.6%
metadata-eval22.6%
swap-sqr22.6%
metadata-eval22.6%
unpow-prod-down22.6%
metadata-eval22.6%
unpow-prod-down22.6%
metadata-eval22.6%
pow-sqr22.6%
flip-+72.3%
metadata-eval72.3%
pow-sqr72.3%
unpow-prod-down72.3%
metadata-eval72.3%
distribute-lft-in72.3%
*-commutative72.3%
unpow272.3%
associate-*r*72.3%
Applied egg-rr72.3%
Taylor expanded in b around 0 55.2%
Final simplification55.2%
herbie shell --seed 2024016
(FPCore (a b)
:name "Bouland and Aaronson, Equation (25)"
:precision binary64
(- (+ (pow (+ (* a a) (* b b)) 2.0) (* 4.0 (+ (* (* a a) (+ 1.0 a)) (* (* b b) (- 1.0 (* 3.0 a)))))) 1.0))