
(FPCore (r a b) :precision binary64 (/ (* r (sin b)) (cos (+ a b))))
double code(double r, double a, double b) {
return (r * sin(b)) / cos((a + b));
}
real(8) function code(r, a, b)
real(8), intent (in) :: r
real(8), intent (in) :: a
real(8), intent (in) :: b
code = (r * sin(b)) / cos((a + b))
end function
public static double code(double r, double a, double b) {
return (r * Math.sin(b)) / Math.cos((a + b));
}
def code(r, a, b): return (r * math.sin(b)) / math.cos((a + b))
function code(r, a, b) return Float64(Float64(r * sin(b)) / cos(Float64(a + b))) end
function tmp = code(r, a, b) tmp = (r * sin(b)) / cos((a + b)); end
code[r_, a_, b_] := N[(N[(r * N[Sin[b], $MachinePrecision]), $MachinePrecision] / N[Cos[N[(a + b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{r \cdot \sin b}{\cos \left(a + b\right)}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 10 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (r a b) :precision binary64 (/ (* r (sin b)) (cos (+ a b))))
double code(double r, double a, double b) {
return (r * sin(b)) / cos((a + b));
}
real(8) function code(r, a, b)
real(8), intent (in) :: r
real(8), intent (in) :: a
real(8), intent (in) :: b
code = (r * sin(b)) / cos((a + b))
end function
public static double code(double r, double a, double b) {
return (r * Math.sin(b)) / Math.cos((a + b));
}
def code(r, a, b): return (r * math.sin(b)) / math.cos((a + b))
function code(r, a, b) return Float64(Float64(r * sin(b)) / cos(Float64(a + b))) end
function tmp = code(r, a, b) tmp = (r * sin(b)) / cos((a + b)); end
code[r_, a_, b_] := N[(N[(r * N[Sin[b], $MachinePrecision]), $MachinePrecision] / N[Cos[N[(a + b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{r \cdot \sin b}{\cos \left(a + b\right)}
\end{array}
(FPCore (r a b) :precision binary64 (* r (/ (sin b) (- (* (cos b) (cos a)) (* (sin b) (sin a))))))
double code(double r, double a, double b) {
return r * (sin(b) / ((cos(b) * cos(a)) - (sin(b) * sin(a))));
}
real(8) function code(r, a, b)
real(8), intent (in) :: r
real(8), intent (in) :: a
real(8), intent (in) :: b
code = r * (sin(b) / ((cos(b) * cos(a)) - (sin(b) * sin(a))))
end function
public static double code(double r, double a, double b) {
return r * (Math.sin(b) / ((Math.cos(b) * Math.cos(a)) - (Math.sin(b) * Math.sin(a))));
}
def code(r, a, b): return r * (math.sin(b) / ((math.cos(b) * math.cos(a)) - (math.sin(b) * math.sin(a))))
function code(r, a, b) return Float64(r * Float64(sin(b) / Float64(Float64(cos(b) * cos(a)) - Float64(sin(b) * sin(a))))) end
function tmp = code(r, a, b) tmp = r * (sin(b) / ((cos(b) * cos(a)) - (sin(b) * sin(a)))); end
code[r_, a_, b_] := N[(r * N[(N[Sin[b], $MachinePrecision] / N[(N[(N[Cos[b], $MachinePrecision] * N[Cos[a], $MachinePrecision]), $MachinePrecision] - N[(N[Sin[b], $MachinePrecision] * N[Sin[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
r \cdot \frac{\sin b}{\cos b \cdot \cos a - \sin b \cdot \sin a}
\end{array}
Initial program 80.3%
associate-/l*80.4%
remove-double-neg80.4%
remove-double-neg80.4%
+-commutative80.4%
Simplified80.4%
cos-sum99.5%
Applied egg-rr99.5%
(FPCore (r a b) :precision binary64 (if (or (<= b -0.00054) (not (<= b 0.0085))) (* r (/ (sin b) (cos b))) (* b (/ r (cos a)))))
double code(double r, double a, double b) {
double tmp;
if ((b <= -0.00054) || !(b <= 0.0085)) {
tmp = r * (sin(b) / cos(b));
} else {
tmp = b * (r / cos(a));
}
return tmp;
}
real(8) function code(r, a, b)
real(8), intent (in) :: r
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if ((b <= (-0.00054d0)) .or. (.not. (b <= 0.0085d0))) then
tmp = r * (sin(b) / cos(b))
else
tmp = b * (r / cos(a))
end if
code = tmp
end function
public static double code(double r, double a, double b) {
double tmp;
if ((b <= -0.00054) || !(b <= 0.0085)) {
tmp = r * (Math.sin(b) / Math.cos(b));
} else {
tmp = b * (r / Math.cos(a));
}
return tmp;
}
def code(r, a, b): tmp = 0 if (b <= -0.00054) or not (b <= 0.0085): tmp = r * (math.sin(b) / math.cos(b)) else: tmp = b * (r / math.cos(a)) return tmp
function code(r, a, b) tmp = 0.0 if ((b <= -0.00054) || !(b <= 0.0085)) tmp = Float64(r * Float64(sin(b) / cos(b))); else tmp = Float64(b * Float64(r / cos(a))); end return tmp end
function tmp_2 = code(r, a, b) tmp = 0.0; if ((b <= -0.00054) || ~((b <= 0.0085))) tmp = r * (sin(b) / cos(b)); else tmp = b * (r / cos(a)); end tmp_2 = tmp; end
code[r_, a_, b_] := If[Or[LessEqual[b, -0.00054], N[Not[LessEqual[b, 0.0085]], $MachinePrecision]], N[(r * N[(N[Sin[b], $MachinePrecision] / N[Cos[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(b * N[(r / N[Cos[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -0.00054 \lor \neg \left(b \leq 0.0085\right):\\
\;\;\;\;r \cdot \frac{\sin b}{\cos b}\\
\mathbf{else}:\\
\;\;\;\;b \cdot \frac{r}{\cos a}\\
\end{array}
\end{array}
if b < -5.40000000000000007e-4 or 0.0085000000000000006 < b Initial program 59.7%
associate-/l*59.7%
remove-double-neg59.7%
remove-double-neg59.7%
+-commutative59.7%
Simplified59.7%
Taylor expanded in a around 0 59.9%
if -5.40000000000000007e-4 < b < 0.0085000000000000006Initial program 98.2%
associate-/l*98.3%
remove-double-neg98.3%
remove-double-neg98.3%
+-commutative98.3%
Simplified98.3%
Taylor expanded in b around 0 98.2%
clear-num98.1%
un-div-inv98.1%
Applied egg-rr98.1%
associate-/r/98.2%
Simplified98.2%
Final simplification80.4%
(FPCore (r a b)
:precision binary64
(let* ((t_0 (/ (cos b) (sin b))))
(if (<= b -0.00054)
(* r (/ 1.0 t_0))
(if (<= b 0.0085) (* b (/ r (cos a))) (/ r t_0)))))
double code(double r, double a, double b) {
double t_0 = cos(b) / sin(b);
double tmp;
if (b <= -0.00054) {
tmp = r * (1.0 / t_0);
} else if (b <= 0.0085) {
tmp = b * (r / cos(a));
} else {
tmp = r / t_0;
}
return tmp;
}
real(8) function code(r, a, b)
real(8), intent (in) :: r
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_0
real(8) :: tmp
t_0 = cos(b) / sin(b)
if (b <= (-0.00054d0)) then
tmp = r * (1.0d0 / t_0)
else if (b <= 0.0085d0) then
tmp = b * (r / cos(a))
else
tmp = r / t_0
end if
code = tmp
end function
public static double code(double r, double a, double b) {
double t_0 = Math.cos(b) / Math.sin(b);
double tmp;
if (b <= -0.00054) {
tmp = r * (1.0 / t_0);
} else if (b <= 0.0085) {
tmp = b * (r / Math.cos(a));
} else {
tmp = r / t_0;
}
return tmp;
}
def code(r, a, b): t_0 = math.cos(b) / math.sin(b) tmp = 0 if b <= -0.00054: tmp = r * (1.0 / t_0) elif b <= 0.0085: tmp = b * (r / math.cos(a)) else: tmp = r / t_0 return tmp
function code(r, a, b) t_0 = Float64(cos(b) / sin(b)) tmp = 0.0 if (b <= -0.00054) tmp = Float64(r * Float64(1.0 / t_0)); elseif (b <= 0.0085) tmp = Float64(b * Float64(r / cos(a))); else tmp = Float64(r / t_0); end return tmp end
function tmp_2 = code(r, a, b) t_0 = cos(b) / sin(b); tmp = 0.0; if (b <= -0.00054) tmp = r * (1.0 / t_0); elseif (b <= 0.0085) tmp = b * (r / cos(a)); else tmp = r / t_0; end tmp_2 = tmp; end
code[r_, a_, b_] := Block[{t$95$0 = N[(N[Cos[b], $MachinePrecision] / N[Sin[b], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -0.00054], N[(r * N[(1.0 / t$95$0), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 0.0085], N[(b * N[(r / N[Cos[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(r / t$95$0), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{\cos b}{\sin b}\\
\mathbf{if}\;b \leq -0.00054:\\
\;\;\;\;r \cdot \frac{1}{t\_0}\\
\mathbf{elif}\;b \leq 0.0085:\\
\;\;\;\;b \cdot \frac{r}{\cos a}\\
\mathbf{else}:\\
\;\;\;\;\frac{r}{t\_0}\\
\end{array}
\end{array}
if b < -5.40000000000000007e-4Initial program 56.8%
associate-/l*56.9%
remove-double-neg56.9%
remove-double-neg56.9%
+-commutative56.9%
Simplified56.9%
cos-sum99.3%
Applied egg-rr99.3%
cos-sum56.9%
clear-num56.9%
inv-pow56.9%
Applied egg-rr56.9%
unpow-156.9%
Simplified56.9%
Taylor expanded in a around 0 57.3%
if -5.40000000000000007e-4 < b < 0.0085000000000000006Initial program 98.2%
associate-/l*98.3%
remove-double-neg98.3%
remove-double-neg98.3%
+-commutative98.3%
Simplified98.3%
Taylor expanded in b around 0 98.2%
clear-num98.1%
un-div-inv98.1%
Applied egg-rr98.1%
associate-/r/98.2%
Simplified98.2%
if 0.0085000000000000006 < b Initial program 62.5%
associate-/l*62.4%
remove-double-neg62.4%
remove-double-neg62.4%
+-commutative62.4%
Simplified62.4%
clear-num62.5%
un-div-inv62.7%
Applied egg-rr62.7%
Taylor expanded in a around 0 62.6%
Final simplification80.5%
(FPCore (r a b) :precision binary64 (if (<= b -0.00058) (* r (/ (sin b) (cos b))) (if (<= b 0.0085) (* b (/ r (cos a))) (/ r (/ (cos b) (sin b))))))
double code(double r, double a, double b) {
double tmp;
if (b <= -0.00058) {
tmp = r * (sin(b) / cos(b));
} else if (b <= 0.0085) {
tmp = b * (r / cos(a));
} else {
tmp = r / (cos(b) / sin(b));
}
return tmp;
}
real(8) function code(r, a, b)
real(8), intent (in) :: r
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (b <= (-0.00058d0)) then
tmp = r * (sin(b) / cos(b))
else if (b <= 0.0085d0) then
tmp = b * (r / cos(a))
else
tmp = r / (cos(b) / sin(b))
end if
code = tmp
end function
public static double code(double r, double a, double b) {
double tmp;
if (b <= -0.00058) {
tmp = r * (Math.sin(b) / Math.cos(b));
} else if (b <= 0.0085) {
tmp = b * (r / Math.cos(a));
} else {
tmp = r / (Math.cos(b) / Math.sin(b));
}
return tmp;
}
def code(r, a, b): tmp = 0 if b <= -0.00058: tmp = r * (math.sin(b) / math.cos(b)) elif b <= 0.0085: tmp = b * (r / math.cos(a)) else: tmp = r / (math.cos(b) / math.sin(b)) return tmp
function code(r, a, b) tmp = 0.0 if (b <= -0.00058) tmp = Float64(r * Float64(sin(b) / cos(b))); elseif (b <= 0.0085) tmp = Float64(b * Float64(r / cos(a))); else tmp = Float64(r / Float64(cos(b) / sin(b))); end return tmp end
function tmp_2 = code(r, a, b) tmp = 0.0; if (b <= -0.00058) tmp = r * (sin(b) / cos(b)); elseif (b <= 0.0085) tmp = b * (r / cos(a)); else tmp = r / (cos(b) / sin(b)); end tmp_2 = tmp; end
code[r_, a_, b_] := If[LessEqual[b, -0.00058], N[(r * N[(N[Sin[b], $MachinePrecision] / N[Cos[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 0.0085], N[(b * N[(r / N[Cos[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(r / N[(N[Cos[b], $MachinePrecision] / N[Sin[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -0.00058:\\
\;\;\;\;r \cdot \frac{\sin b}{\cos b}\\
\mathbf{elif}\;b \leq 0.0085:\\
\;\;\;\;b \cdot \frac{r}{\cos a}\\
\mathbf{else}:\\
\;\;\;\;\frac{r}{\frac{\cos b}{\sin b}}\\
\end{array}
\end{array}
if b < -5.8e-4Initial program 56.8%
associate-/l*56.9%
remove-double-neg56.9%
remove-double-neg56.9%
+-commutative56.9%
Simplified56.9%
Taylor expanded in a around 0 57.3%
if -5.8e-4 < b < 0.0085000000000000006Initial program 98.2%
associate-/l*98.3%
remove-double-neg98.3%
remove-double-neg98.3%
+-commutative98.3%
Simplified98.3%
Taylor expanded in b around 0 98.2%
clear-num98.1%
un-div-inv98.1%
Applied egg-rr98.1%
associate-/r/98.2%
Simplified98.2%
if 0.0085000000000000006 < b Initial program 62.5%
associate-/l*62.4%
remove-double-neg62.4%
remove-double-neg62.4%
+-commutative62.4%
Simplified62.4%
clear-num62.5%
un-div-inv62.7%
Applied egg-rr62.7%
Taylor expanded in a around 0 62.6%
Final simplification80.5%
(FPCore (r a b) :precision binary64 (if (<= b -0.00054) (* r (/ (sin b) (cos b))) (if (<= b 0.0085) (* b (/ r (cos a))) (* (sin b) (/ r (cos b))))))
double code(double r, double a, double b) {
double tmp;
if (b <= -0.00054) {
tmp = r * (sin(b) / cos(b));
} else if (b <= 0.0085) {
tmp = b * (r / cos(a));
} else {
tmp = sin(b) * (r / cos(b));
}
return tmp;
}
real(8) function code(r, a, b)
real(8), intent (in) :: r
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (b <= (-0.00054d0)) then
tmp = r * (sin(b) / cos(b))
else if (b <= 0.0085d0) then
tmp = b * (r / cos(a))
else
tmp = sin(b) * (r / cos(b))
end if
code = tmp
end function
public static double code(double r, double a, double b) {
double tmp;
if (b <= -0.00054) {
tmp = r * (Math.sin(b) / Math.cos(b));
} else if (b <= 0.0085) {
tmp = b * (r / Math.cos(a));
} else {
tmp = Math.sin(b) * (r / Math.cos(b));
}
return tmp;
}
def code(r, a, b): tmp = 0 if b <= -0.00054: tmp = r * (math.sin(b) / math.cos(b)) elif b <= 0.0085: tmp = b * (r / math.cos(a)) else: tmp = math.sin(b) * (r / math.cos(b)) return tmp
function code(r, a, b) tmp = 0.0 if (b <= -0.00054) tmp = Float64(r * Float64(sin(b) / cos(b))); elseif (b <= 0.0085) tmp = Float64(b * Float64(r / cos(a))); else tmp = Float64(sin(b) * Float64(r / cos(b))); end return tmp end
function tmp_2 = code(r, a, b) tmp = 0.0; if (b <= -0.00054) tmp = r * (sin(b) / cos(b)); elseif (b <= 0.0085) tmp = b * (r / cos(a)); else tmp = sin(b) * (r / cos(b)); end tmp_2 = tmp; end
code[r_, a_, b_] := If[LessEqual[b, -0.00054], N[(r * N[(N[Sin[b], $MachinePrecision] / N[Cos[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 0.0085], N[(b * N[(r / N[Cos[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[Sin[b], $MachinePrecision] * N[(r / N[Cos[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -0.00054:\\
\;\;\;\;r \cdot \frac{\sin b}{\cos b}\\
\mathbf{elif}\;b \leq 0.0085:\\
\;\;\;\;b \cdot \frac{r}{\cos a}\\
\mathbf{else}:\\
\;\;\;\;\sin b \cdot \frac{r}{\cos b}\\
\end{array}
\end{array}
if b < -5.40000000000000007e-4Initial program 56.8%
associate-/l*56.9%
remove-double-neg56.9%
remove-double-neg56.9%
+-commutative56.9%
Simplified56.9%
Taylor expanded in a around 0 57.3%
if -5.40000000000000007e-4 < b < 0.0085000000000000006Initial program 98.2%
associate-/l*98.3%
remove-double-neg98.3%
remove-double-neg98.3%
+-commutative98.3%
Simplified98.3%
Taylor expanded in b around 0 98.2%
clear-num98.1%
un-div-inv98.1%
Applied egg-rr98.1%
associate-/r/98.2%
Simplified98.2%
if 0.0085000000000000006 < b Initial program 62.5%
associate-/l*62.4%
remove-double-neg62.4%
remove-double-neg62.4%
+-commutative62.4%
Simplified62.4%
Taylor expanded in a around 0 62.5%
*-commutative62.5%
associate-/l*62.4%
Simplified62.4%
Final simplification80.4%
(FPCore (r a b) :precision binary64 (* r (/ (sin b) (cos (+ b a)))))
double code(double r, double a, double b) {
return r * (sin(b) / cos((b + a)));
}
real(8) function code(r, a, b)
real(8), intent (in) :: r
real(8), intent (in) :: a
real(8), intent (in) :: b
code = r * (sin(b) / cos((b + a)))
end function
public static double code(double r, double a, double b) {
return r * (Math.sin(b) / Math.cos((b + a)));
}
def code(r, a, b): return r * (math.sin(b) / math.cos((b + a)))
function code(r, a, b) return Float64(r * Float64(sin(b) / cos(Float64(b + a)))) end
function tmp = code(r, a, b) tmp = r * (sin(b) / cos((b + a))); end
code[r_, a_, b_] := N[(r * N[(N[Sin[b], $MachinePrecision] / N[Cos[N[(b + a), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
r \cdot \frac{\sin b}{\cos \left(b + a\right)}
\end{array}
Initial program 80.3%
associate-/l*80.4%
remove-double-neg80.4%
remove-double-neg80.4%
+-commutative80.4%
Simplified80.4%
(FPCore (r a b) :precision binary64 (* r (/ (sin b) (cos a))))
double code(double r, double a, double b) {
return r * (sin(b) / cos(a));
}
real(8) function code(r, a, b)
real(8), intent (in) :: r
real(8), intent (in) :: a
real(8), intent (in) :: b
code = r * (sin(b) / cos(a))
end function
public static double code(double r, double a, double b) {
return r * (Math.sin(b) / Math.cos(a));
}
def code(r, a, b): return r * (math.sin(b) / math.cos(a))
function code(r, a, b) return Float64(r * Float64(sin(b) / cos(a))) end
function tmp = code(r, a, b) tmp = r * (sin(b) / cos(a)); end
code[r_, a_, b_] := N[(r * N[(N[Sin[b], $MachinePrecision] / N[Cos[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
r \cdot \frac{\sin b}{\cos a}
\end{array}
Initial program 80.3%
associate-/l*80.4%
remove-double-neg80.4%
remove-double-neg80.4%
+-commutative80.4%
Simplified80.4%
Taylor expanded in b around 0 58.0%
(FPCore (r a b) :precision binary64 (* b (/ r (cos a))))
double code(double r, double a, double b) {
return b * (r / cos(a));
}
real(8) function code(r, a, b)
real(8), intent (in) :: r
real(8), intent (in) :: a
real(8), intent (in) :: b
code = b * (r / cos(a))
end function
public static double code(double r, double a, double b) {
return b * (r / Math.cos(a));
}
def code(r, a, b): return b * (r / math.cos(a))
function code(r, a, b) return Float64(b * Float64(r / cos(a))) end
function tmp = code(r, a, b) tmp = b * (r / cos(a)); end
code[r_, a_, b_] := N[(b * N[(r / N[Cos[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
b \cdot \frac{r}{\cos a}
\end{array}
Initial program 80.3%
associate-/l*80.4%
remove-double-neg80.4%
remove-double-neg80.4%
+-commutative80.4%
Simplified80.4%
Taylor expanded in b around 0 54.4%
clear-num54.3%
un-div-inv54.3%
Applied egg-rr54.3%
associate-/r/54.4%
Simplified54.4%
Final simplification54.4%
(FPCore (r a b) :precision binary64 (* r (/ b (cos a))))
double code(double r, double a, double b) {
return r * (b / cos(a));
}
real(8) function code(r, a, b)
real(8), intent (in) :: r
real(8), intent (in) :: a
real(8), intent (in) :: b
code = r * (b / cos(a))
end function
public static double code(double r, double a, double b) {
return r * (b / Math.cos(a));
}
def code(r, a, b): return r * (b / math.cos(a))
function code(r, a, b) return Float64(r * Float64(b / cos(a))) end
function tmp = code(r, a, b) tmp = r * (b / cos(a)); end
code[r_, a_, b_] := N[(r * N[(b / N[Cos[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
r \cdot \frac{b}{\cos a}
\end{array}
Initial program 80.3%
associate-/l*80.4%
remove-double-neg80.4%
remove-double-neg80.4%
+-commutative80.4%
Simplified80.4%
Taylor expanded in b around 0 54.4%
(FPCore (r a b) :precision binary64 (* r b))
double code(double r, double a, double b) {
return r * b;
}
real(8) function code(r, a, b)
real(8), intent (in) :: r
real(8), intent (in) :: a
real(8), intent (in) :: b
code = r * b
end function
public static double code(double r, double a, double b) {
return r * b;
}
def code(r, a, b): return r * b
function code(r, a, b) return Float64(r * b) end
function tmp = code(r, a, b) tmp = r * b; end
code[r_, a_, b_] := N[(r * b), $MachinePrecision]
\begin{array}{l}
\\
r \cdot b
\end{array}
Initial program 80.3%
associate-/l*80.4%
remove-double-neg80.4%
remove-double-neg80.4%
+-commutative80.4%
Simplified80.4%
Taylor expanded in b around 0 54.4%
Taylor expanded in a around 0 34.5%
herbie shell --seed 2024097
(FPCore (r a b)
:name "rsin A (should all be same)"
:precision binary64
(/ (* r (sin b)) (cos (+ a b))))