\[\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right)
\]
↓
\[\left(\left(-2 \cdot \left(b + a\right)\right) \cdot \left(\left(a - b\right) \cdot \sin \left({\left(\frac{180}{angle \cdot \pi}\right)}^{-1}\right)\right)\right) \cdot \cos \left(\frac{angle \cdot \pi}{180}\right)
\]
(FPCore (a b angle)
:precision binary64
(*
(* (* 2.0 (- (pow b 2.0) (pow a 2.0))) (sin (* PI (/ angle 180.0))))
(cos (* PI (/ angle 180.0)))))
↓
(FPCore (a b angle)
:precision binary64
(*
(* (* -2.0 (+ b a)) (* (- a b) (sin (pow (/ 180.0 (* angle PI)) -1.0))))
(cos (/ (* angle PI) 180.0))))
double code(double a, double b, double angle) {
return ((2.0 * (pow(b, 2.0) - pow(a, 2.0))) * sin((((double) M_PI) * (angle / 180.0)))) * cos((((double) M_PI) * (angle / 180.0)));
}
↓
double code(double a, double b, double angle) {
return ((-2.0 * (b + a)) * ((a - b) * sin(pow((180.0 / (angle * ((double) M_PI))), -1.0)))) * cos(((angle * ((double) M_PI)) / 180.0));
}
public static double code(double a, double b, double angle) {
return ((2.0 * (Math.pow(b, 2.0) - Math.pow(a, 2.0))) * Math.sin((Math.PI * (angle / 180.0)))) * Math.cos((Math.PI * (angle / 180.0)));
}
↓
public static double code(double a, double b, double angle) {
return ((-2.0 * (b + a)) * ((a - b) * Math.sin(Math.pow((180.0 / (angle * Math.PI)), -1.0)))) * Math.cos(((angle * Math.PI) / 180.0));
}
def code(a, b, angle):
return ((2.0 * (math.pow(b, 2.0) - math.pow(a, 2.0))) * math.sin((math.pi * (angle / 180.0)))) * math.cos((math.pi * (angle / 180.0)))
↓
def code(a, b, angle):
return ((-2.0 * (b + a)) * ((a - b) * math.sin(math.pow((180.0 / (angle * math.pi)), -1.0)))) * math.cos(((angle * math.pi) / 180.0))
function code(a, b, angle)
return Float64(Float64(Float64(2.0 * Float64((b ^ 2.0) - (a ^ 2.0))) * sin(Float64(pi * Float64(angle / 180.0)))) * cos(Float64(pi * Float64(angle / 180.0))))
end
↓
function code(a, b, angle)
return Float64(Float64(Float64(-2.0 * Float64(b + a)) * Float64(Float64(a - b) * sin((Float64(180.0 / Float64(angle * pi)) ^ -1.0)))) * cos(Float64(Float64(angle * pi) / 180.0)))
end
function tmp = code(a, b, angle)
tmp = ((2.0 * ((b ^ 2.0) - (a ^ 2.0))) * sin((pi * (angle / 180.0)))) * cos((pi * (angle / 180.0)));
end
↓
function tmp = code(a, b, angle)
tmp = ((-2.0 * (b + a)) * ((a - b) * sin(((180.0 / (angle * pi)) ^ -1.0)))) * cos(((angle * pi) / 180.0));
end
code[a_, b_, angle_] := N[(N[(N[(2.0 * N[(N[Power[b, 2.0], $MachinePrecision] - N[Power[a, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Sin[N[(Pi * N[(angle / 180.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * N[Cos[N[(Pi * N[(angle / 180.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
↓
code[a_, b_, angle_] := N[(N[(N[(-2.0 * N[(b + a), $MachinePrecision]), $MachinePrecision] * N[(N[(a - b), $MachinePrecision] * N[Sin[N[Power[N[(180.0 / N[(angle * Pi), $MachinePrecision]), $MachinePrecision], -1.0], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Cos[N[(N[(angle * Pi), $MachinePrecision] / 180.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\pi \cdot \frac{angle}{180}\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right)
↓
\left(\left(-2 \cdot \left(b + a\right)\right) \cdot \left(\left(a - b\right) \cdot \sin \left({\left(\frac{180}{angle \cdot \pi}\right)}^{-1}\right)\right)\right) \cdot \cos \left(\frac{angle \cdot \pi}{180}\right)
Alternatives
| Alternative 1 |
|---|
| Error | 21.3 |
|---|
| Cost | 53193 |
|---|
\[\begin{array}{l}
t_0 := \pi \cdot \frac{angle}{180}\\
t_1 := {b}^{2} - {a}^{2}\\
\mathbf{if}\;t_1 \leq -1 \cdot 10^{+291} \lor \neg \left(t_1 \leq 5 \cdot 10^{+304}\right):\\
\;\;\;\;\cos t_0 \cdot \left(\left(-2 \cdot \left(b + a\right)\right) \cdot \left(\left(a - b\right) \cdot \left(angle \cdot \left(\pi \cdot 0.005555555555555556\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;2 \cdot \left(\sin t_0 \cdot \left(\left(b \cdot b - a \cdot a\right) \cdot \cos \left(\pi \cdot \left(angle \cdot 0.005555555555555556\right)\right)\right)\right)\\
\end{array}
\]
| Alternative 2 |
|---|
| Error | 21.4 |
|---|
| Cost | 53192 |
|---|
\[\begin{array}{l}
t_0 := -2 \cdot \left(b + a\right)\\
t_1 := {b}^{2} - {a}^{2}\\
t_2 := \pi \cdot \frac{angle}{180}\\
t_3 := \cos t_2\\
\mathbf{if}\;t_1 \leq -1 \cdot 10^{+291}:\\
\;\;\;\;t_3 \cdot \left(t_0 \cdot \left(\left(a - b\right) \cdot \left(angle \cdot \left(\pi \cdot 0.005555555555555556\right)\right)\right)\right)\\
\mathbf{elif}\;t_1 \leq 2 \cdot 10^{+220}:\\
\;\;\;\;2 \cdot \left(\sin t_2 \cdot \left(t_3 \cdot \left(b \cdot b - a \cdot a\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t_0 \cdot \left(\left(a - b\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.005555555555555556\right)\right)\\
\end{array}
\]
| Alternative 3 |
|---|
| Error | 21.4 |
|---|
| Cost | 53192 |
|---|
\[\begin{array}{l}
t_0 := -2 \cdot \left(b + a\right)\\
t_1 := {b}^{2} - {a}^{2}\\
t_2 := \pi \cdot \frac{angle}{180}\\
t_3 := \cos t_2\\
\mathbf{if}\;t_1 \leq -1 \cdot 10^{+291}:\\
\;\;\;\;t_3 \cdot \left(t_0 \cdot \left(\left(a - b\right) \cdot \left(angle \cdot \left(\pi \cdot 0.005555555555555556\right)\right)\right)\right)\\
\mathbf{elif}\;t_1 \leq 2 \cdot 10^{+220}:\\
\;\;\;\;\left(2 \cdot \left(b \cdot b - a \cdot a\right)\right) \cdot \left(t_3 \cdot \sin t_2\right)\\
\mathbf{else}:\\
\;\;\;\;t_0 \cdot \left(\left(a - b\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.005555555555555556\right)\right)\\
\end{array}
\]
| Alternative 4 |
|---|
| Error | 21.5 |
|---|
| Cost | 40072 |
|---|
\[\begin{array}{l}
t_0 := \left(b + a\right) \cdot angle\\
t_1 := {b}^{2} - {a}^{2}\\
\mathbf{if}\;t_1 \leq -5 \cdot 10^{+283}:\\
\;\;\;\;0.011111111111111112 \cdot \left(\pi \cdot \left(b \cdot t_0 - a \cdot t_0\right)\right)\\
\mathbf{elif}\;t_1 \leq 2 \cdot 10^{+220}:\\
\;\;\;\;\left(b \cdot b - a \cdot a\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\\
\mathbf{else}:\\
\;\;\;\;\left(-2 \cdot \left(b + a\right)\right) \cdot \left(\left(a - b\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.005555555555555556\right)\right)\\
\end{array}
\]
| Alternative 5 |
|---|
| Error | 21.4 |
|---|
| Cost | 40072 |
|---|
\[\begin{array}{l}
t_0 := -2 \cdot \left(b + a\right)\\
t_1 := {b}^{2} - {a}^{2}\\
\mathbf{if}\;t_1 \leq -5 \cdot 10^{+283}:\\
\;\;\;\;\cos \left(\pi \cdot \frac{angle}{180}\right) \cdot \left(t_0 \cdot \left(\left(a - b\right) \cdot \left(angle \cdot \left(\pi \cdot 0.005555555555555556\right)\right)\right)\right)\\
\mathbf{elif}\;t_1 \leq 2 \cdot 10^{+220}:\\
\;\;\;\;\left(b \cdot b - a \cdot a\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\\
\mathbf{else}:\\
\;\;\;\;t_0 \cdot \left(\left(a - b\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.005555555555555556\right)\right)\\
\end{array}
\]
| Alternative 6 |
|---|
| Error | 21.5 |
|---|
| Cost | 33280 |
|---|
\[\left(\left(-2 \cdot \left(b + a\right)\right) \cdot \left(\left(a - b\right) \cdot \sin \left({\left(\frac{180}{angle \cdot \pi}\right)}^{-1}\right)\right)\right) \cdot \cos \left(\pi \cdot \frac{angle}{180}\right)
\]
| Alternative 7 |
|---|
| Error | 21.4 |
|---|
| Cost | 26816 |
|---|
\[\cos \left(\pi \cdot \frac{angle}{180}\right) \cdot \left(\left(-2 \cdot \left(b + a\right)\right) \cdot \left(\left(a - b\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.005555555555555556\right)\right)\right)
\]
| Alternative 8 |
|---|
| Error | 21.4 |
|---|
| Cost | 26816 |
|---|
\[\cos \left(\pi \cdot \frac{angle}{180}\right) \cdot \left(\left(-2 \cdot \left(b + a\right)\right) \cdot \left(\left(a - b\right) \cdot \sin \left(\frac{angle \cdot \pi}{180}\right)\right)\right)
\]
| Alternative 9 |
|---|
| Error | 21.4 |
|---|
| Cost | 14089 |
|---|
\[\begin{array}{l}
t_0 := \left(b + a\right) \cdot angle\\
\mathbf{if}\;\frac{angle}{180} \leq -5 \cdot 10^{-22} \lor \neg \left(\frac{angle}{180} \leq 4 \cdot 10^{-24}\right):\\
\;\;\;\;\left(b \cdot b - a \cdot a\right) \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\\
\mathbf{else}:\\
\;\;\;\;0.011111111111111112 \cdot \left(\pi \cdot \left(b \cdot t_0 - a \cdot t_0\right)\right)\\
\end{array}
\]
| Alternative 10 |
|---|
| Error | 22.6 |
|---|
| Cost | 13896 |
|---|
\[\begin{array}{l}
t_0 := \left(b + a\right) \cdot angle\\
t_1 := \sin \left(\pi \cdot \left(angle \cdot 0.011111111111111112\right)\right)\\
\mathbf{if}\;\frac{angle}{180} \leq -5 \cdot 10^{-7}:\\
\;\;\;\;\left(b \cdot b\right) \cdot t_1\\
\mathbf{elif}\;\frac{angle}{180} \leq 5 \cdot 10^{-8}:\\
\;\;\;\;0.011111111111111112 \cdot \left(\pi \cdot \left(b \cdot t_0 - a \cdot t_0\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t_1 \cdot \left(a \cdot \left(-a\right)\right)\\
\end{array}
\]
| Alternative 11 |
|---|
| Error | 22.5 |
|---|
| Cost | 13577 |
|---|
\[\begin{array}{l}
t_0 := \left(b + a\right) \cdot angle\\
\mathbf{if}\;angle \leq -0.00011 \lor \neg \left(angle \leq 6.4 \cdot 10^{-6}\right):\\
\;\;\;\;b \cdot \left(b \cdot \sin \left(\left(angle \cdot \pi\right) \cdot 0.011111111111111112\right)\right)\\
\mathbf{else}:\\
\;\;\;\;0.011111111111111112 \cdot \left(\pi \cdot \left(b \cdot t_0 - a \cdot t_0\right)\right)\\
\end{array}
\]
| Alternative 12 |
|---|
| Error | 22.5 |
|---|
| Cost | 13577 |
|---|
\[\begin{array}{l}
t_0 := \left(b + a\right) \cdot angle\\
\mathbf{if}\;angle \leq -0.00011 \lor \neg \left(angle \leq 6.4 \cdot 10^{-6}\right):\\
\;\;\;\;b \cdot \left(b \cdot \sin \left(\pi \cdot \left(angle \cdot 0.011111111111111112\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;0.011111111111111112 \cdot \left(\pi \cdot \left(b \cdot t_0 - a \cdot t_0\right)\right)\\
\end{array}
\]
| Alternative 13 |
|---|
| Error | 22.5 |
|---|
| Cost | 13576 |
|---|
\[\begin{array}{l}
t_0 := \left(b + a\right) \cdot angle\\
t_1 := \sin \left(\pi \cdot \left(angle \cdot 0.011111111111111112\right)\right)\\
\mathbf{if}\;angle \leq -0.00011:\\
\;\;\;\;\left(b \cdot b\right) \cdot t_1\\
\mathbf{elif}\;angle \leq 6.4 \cdot 10^{-6}:\\
\;\;\;\;0.011111111111111112 \cdot \left(\pi \cdot \left(b \cdot t_0 - a \cdot t_0\right)\right)\\
\mathbf{else}:\\
\;\;\;\;b \cdot \left(b \cdot t_1\right)\\
\end{array}
\]
| Alternative 14 |
|---|
| Error | 25.7 |
|---|
| Cost | 7817 |
|---|
\[\begin{array}{l}
t_0 := \left(b + a\right) \cdot angle\\
\mathbf{if}\;b \leq 1.8 \cdot 10^{-258} \lor \neg \left(b \leq 1.95 \cdot 10^{-165}\right):\\
\;\;\;\;0.011111111111111112 \cdot \left(\pi \cdot \left(b \cdot t_0 - a \cdot t_0\right)\right)\\
\mathbf{else}:\\
\;\;\;\;angle \cdot \left(\left(a \cdot \left(a \cdot \pi\right)\right) \cdot -0.011111111111111112\right)\\
\end{array}
\]
| Alternative 15 |
|---|
| Error | 29.2 |
|---|
| Cost | 7561 |
|---|
\[\begin{array}{l}
\mathbf{if}\;b \leq -2.85 \cdot 10^{+54} \lor \neg \left(b \leq 8 \cdot 10^{+117}\right):\\
\;\;\;\;b \cdot \left(\left(angle \cdot 0.011111111111111112\right) \cdot \left(b \cdot \pi\right)\right)\\
\mathbf{else}:\\
\;\;\;\;2 \cdot \left(\left(angle \cdot 0.005555555555555556\right) \cdot \left(\pi \cdot \left(\left(b + a\right) \cdot \left(b - a\right)\right)\right)\right)\\
\end{array}
\]
| Alternative 16 |
|---|
| Error | 38.8 |
|---|
| Cost | 7441 |
|---|
\[\begin{array}{l}
t_0 := angle \cdot \left(\left(a \cdot \left(a \cdot \pi\right)\right) \cdot -0.011111111111111112\right)\\
\mathbf{if}\;a \leq -1.82 \cdot 10^{+50}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;a \leq -122000000000:\\
\;\;\;\;angle \cdot \left(\pi \cdot \left(b \cdot \left(b \cdot 0.011111111111111112\right)\right)\right)\\
\mathbf{elif}\;a \leq -2.4 \cdot 10^{-129} \lor \neg \left(a \leq 2.6 \cdot 10^{-111}\right):\\
\;\;\;\;t_0\\
\mathbf{else}:\\
\;\;\;\;angle \cdot \left(\pi \cdot \left(\left(b \cdot b\right) \cdot 0.011111111111111112\right)\right)\\
\end{array}
\]
| Alternative 17 |
|---|
| Error | 29.4 |
|---|
| Cost | 7433 |
|---|
\[\begin{array}{l}
\mathbf{if}\;b \leq -2.85 \cdot 10^{+54} \lor \neg \left(b \leq 4 \cdot 10^{+76}\right):\\
\;\;\;\;b \cdot \left(\left(angle \cdot 0.011111111111111112\right) \cdot \left(b \cdot \pi\right)\right)\\
\mathbf{else}:\\
\;\;\;\;0.011111111111111112 \cdot \left(\pi \cdot \left(angle \cdot \left(b \cdot b - a \cdot a\right)\right)\right)\\
\end{array}
\]
| Alternative 18 |
|---|
| Error | 29.3 |
|---|
| Cost | 7433 |
|---|
\[\begin{array}{l}
\mathbf{if}\;b \leq -9.5 \cdot 10^{+60} \lor \neg \left(b \leq 3.9 \cdot 10^{+76}\right):\\
\;\;\;\;b \cdot \left(\left(angle \cdot 0.011111111111111112\right) \cdot \left(b \cdot \pi\right)\right)\\
\mathbf{else}:\\
\;\;\;\;angle \cdot \left(0.011111111111111112 \cdot \left(\pi \cdot \left(b \cdot b - a \cdot a\right)\right)\right)\\
\end{array}
\]
| Alternative 19 |
|---|
| Error | 29.2 |
|---|
| Cost | 7433 |
|---|
\[\begin{array}{l}
\mathbf{if}\;b \leq -9.5 \cdot 10^{+60} \lor \neg \left(b \leq 10^{+79}\right):\\
\;\;\;\;b \cdot \left(\left(angle \cdot 0.011111111111111112\right) \cdot \left(b \cdot \pi\right)\right)\\
\mathbf{else}:\\
\;\;\;\;angle \cdot \left(0.011111111111111112 \cdot \left(\left(b + a\right) \cdot \left(\pi \cdot \left(b - a\right)\right)\right)\right)\\
\end{array}
\]
| Alternative 20 |
|---|
| Error | 29.2 |
|---|
| Cost | 7433 |
|---|
\[\begin{array}{l}
\mathbf{if}\;b \leq -6.8 \cdot 10^{+53} \lor \neg \left(b \leq 4.8 \cdot 10^{+94}\right):\\
\;\;\;\;b \cdot \left(\left(angle \cdot 0.011111111111111112\right) \cdot \left(b \cdot \pi\right)\right)\\
\mathbf{else}:\\
\;\;\;\;angle \cdot \left(\left(b \cdot b - a \cdot a\right) \cdot \left(\pi \cdot 0.011111111111111112\right)\right)\\
\end{array}
\]
| Alternative 21 |
|---|
| Error | 32.2 |
|---|
| Cost | 7177 |
|---|
\[\begin{array}{l}
\mathbf{if}\;b \leq -1.75 \cdot 10^{-15} \lor \neg \left(b \leq 1.9 \cdot 10^{-48}\right):\\
\;\;\;\;b \cdot \left(\left(angle \cdot 0.011111111111111112\right) \cdot \left(b \cdot \pi\right)\right)\\
\mathbf{else}:\\
\;\;\;\;angle \cdot \left(\left(a \cdot \left(a \cdot \pi\right)\right) \cdot -0.011111111111111112\right)\\
\end{array}
\]
| Alternative 22 |
|---|
| Error | 32.2 |
|---|
| Cost | 7177 |
|---|
\[\begin{array}{l}
\mathbf{if}\;b \leq -1.16 \cdot 10^{-14} \lor \neg \left(b \leq 4.5 \cdot 10^{-47}\right):\\
\;\;\;\;b \cdot \left(\left(angle \cdot 0.011111111111111112\right) \cdot \left(b \cdot \pi\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(angle \cdot -0.011111111111111112\right) \cdot \left(\pi \cdot \left(a \cdot a\right)\right)\\
\end{array}
\]
| Alternative 23 |
|---|
| Error | 42.7 |
|---|
| Cost | 6912 |
|---|
\[0.011111111111111112 \cdot \left(angle \cdot \left(b \cdot \left(b \cdot \pi\right)\right)\right)
\]
| Alternative 24 |
|---|
| Error | 42.7 |
|---|
| Cost | 6912 |
|---|
\[0.011111111111111112 \cdot \left(\pi \cdot \left(angle \cdot \left(b \cdot b\right)\right)\right)
\]
| Alternative 25 |
|---|
| Error | 42.7 |
|---|
| Cost | 6912 |
|---|
\[angle \cdot \left(\pi \cdot \left(b \cdot \left(b \cdot 0.011111111111111112\right)\right)\right)
\]
| Alternative 26 |
|---|
| Error | 42.7 |
|---|
| Cost | 6912 |
|---|
\[angle \cdot \left(\pi \cdot \left(\left(b \cdot b\right) \cdot 0.011111111111111112\right)\right)
\]