\[{\left(a \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}
\]
↓
\[{\left(\sin \left(\pi \cdot \left(0.005555555555555556 \cdot angle\right)\right) \cdot a\right)}^{2} + {b}^{2}
\]
(FPCore (a b angle)
:precision binary64
(+
(pow (* a (sin (* (/ angle 180.0) PI))) 2.0)
(pow (* b (cos (* (/ angle 180.0) PI))) 2.0)))
↓
(FPCore (a b angle)
:precision binary64
(+ (pow (* (sin (* PI (* 0.005555555555555556 angle))) a) 2.0) (pow b 2.0)))
double code(double a, double b, double angle) {
return pow((a * sin(((angle / 180.0) * ((double) M_PI)))), 2.0) + pow((b * cos(((angle / 180.0) * ((double) M_PI)))), 2.0);
}
↓
double code(double a, double b, double angle) {
return pow((sin((((double) M_PI) * (0.005555555555555556 * angle))) * a), 2.0) + pow(b, 2.0);
}
public static double code(double a, double b, double angle) {
return Math.pow((a * Math.sin(((angle / 180.0) * Math.PI))), 2.0) + Math.pow((b * Math.cos(((angle / 180.0) * Math.PI))), 2.0);
}
↓
public static double code(double a, double b, double angle) {
return Math.pow((Math.sin((Math.PI * (0.005555555555555556 * angle))) * a), 2.0) + Math.pow(b, 2.0);
}
def code(a, b, angle):
return math.pow((a * math.sin(((angle / 180.0) * math.pi))), 2.0) + math.pow((b * math.cos(((angle / 180.0) * math.pi))), 2.0)
↓
def code(a, b, angle):
return math.pow((math.sin((math.pi * (0.005555555555555556 * angle))) * a), 2.0) + math.pow(b, 2.0)
function code(a, b, angle)
return Float64((Float64(a * sin(Float64(Float64(angle / 180.0) * pi))) ^ 2.0) + (Float64(b * cos(Float64(Float64(angle / 180.0) * pi))) ^ 2.0))
end
↓
function code(a, b, angle)
return Float64((Float64(sin(Float64(pi * Float64(0.005555555555555556 * angle))) * a) ^ 2.0) + (b ^ 2.0))
end
function tmp = code(a, b, angle)
tmp = ((a * sin(((angle / 180.0) * pi))) ^ 2.0) + ((b * cos(((angle / 180.0) * pi))) ^ 2.0);
end
↓
function tmp = code(a, b, angle)
tmp = ((sin((pi * (0.005555555555555556 * angle))) * a) ^ 2.0) + (b ^ 2.0);
end
code[a_, b_, angle_] := N[(N[Power[N[(a * N[Sin[N[(N[(angle / 180.0), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[N[(b * N[Cos[N[(N[(angle / 180.0), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]
↓
code[a_, b_, angle_] := N[(N[Power[N[(N[Sin[N[(Pi * N[(0.005555555555555556 * angle), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * a), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[b, 2.0], $MachinePrecision]), $MachinePrecision]
{\left(a \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}
↓
{\left(\sin \left(\pi \cdot \left(0.005555555555555556 \cdot angle\right)\right) \cdot a\right)}^{2} + {b}^{2}
Alternatives
| Alternative 1 |
|---|
| Error | 26.2 |
|---|
| Cost | 20360 |
|---|
\[\begin{array}{l}
\mathbf{if}\;b \leq 2.065436357235566 \cdot 10^{-278}:\\
\;\;\;\;{b}^{2} + 3.08641975308642 \cdot 10^{-5} \cdot {\left(angle \cdot \left(\pi \cdot a\right)\right)}^{2}\\
\mathbf{elif}\;b \leq 6.0546078552434845 \cdot 10^{-115}:\\
\;\;\;\;{b}^{2} + 3.08641975308642 \cdot 10^{-5} \cdot \left({\pi}^{2} \cdot \left(angle \cdot \left(a \cdot \left(angle \cdot a\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;{b}^{2} + {\left(0.005555555555555556 \cdot \left(\pi \cdot \left(angle \cdot a\right)\right)\right)}^{2}\\
\end{array}
\]
| Alternative 2 |
|---|
| Error | 26.2 |
|---|
| Cost | 20360 |
|---|
\[\begin{array}{l}
t_0 := \pi \cdot \left(angle \cdot a\right)\\
\mathbf{if}\;b \leq 2.065436357235566 \cdot 10^{-278}:\\
\;\;\;\;{b}^{2} + \left(\left(angle \cdot a\right) \cdot \left(\pi \cdot t_0\right)\right) \cdot 3.08641975308642 \cdot 10^{-5}\\
\mathbf{elif}\;b \leq 6.0546078552434845 \cdot 10^{-115}:\\
\;\;\;\;{b}^{2} + 3.08641975308642 \cdot 10^{-5} \cdot \left({\pi}^{2} \cdot \left(angle \cdot \left(a \cdot \left(angle \cdot a\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;{b}^{2} + {\left(0.005555555555555556 \cdot t_0\right)}^{2}\\
\end{array}
\]
| Alternative 3 |
|---|
| Error | 23.7 |
|---|
| Cost | 20360 |
|---|
\[\begin{array}{l}
\mathbf{if}\;a \leq -1 \cdot 10^{+155}:\\
\;\;\;\;{b}^{2} + {\left(a \cdot \left(angle \cdot \left(\pi \cdot 0.005555555555555556\right)\right)\right)}^{2}\\
\mathbf{elif}\;a \leq 1.3178122390825705 \cdot 10^{+141}:\\
\;\;\;\;{b}^{2} + 3.08641975308642 \cdot 10^{-5} \cdot \left(angle \cdot \left(\left(a \cdot a\right) \cdot \left(angle \cdot {\pi}^{2}\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;{b}^{2} + 3.08641975308642 \cdot 10^{-5} \cdot {\left(angle \cdot \left(\pi \cdot a\right)\right)}^{2}\\
\end{array}
\]
| Alternative 4 |
|---|
| Error | 23.1 |
|---|
| Cost | 20360 |
|---|
\[\begin{array}{l}
t_0 := {b}^{2} + {\left(0.005555555555555556 \cdot \left(angle \cdot \left(\left(1 + \pi \cdot a\right) + -1\right)\right)\right)}^{2}\\
\mathbf{if}\;angle \leq -5 \cdot 10^{+72}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;angle \leq 10^{+20}:\\
\;\;\;\;{b}^{2} + \left(\left(angle \cdot a\right) \cdot \left(\pi \cdot \left(\pi \cdot \left(angle \cdot a\right)\right)\right)\right) \cdot 3.08641975308642 \cdot 10^{-5}\\
\mathbf{else}:\\
\;\;\;\;t_0\\
\end{array}
\]
| Alternative 5 |
|---|
| Error | 25.9 |
|---|
| Cost | 19840 |
|---|
\[{b}^{2} + {\left(0.005555555555555556 \cdot \left(\pi \cdot \left(angle \cdot a\right)\right)\right)}^{2}
\]
| Alternative 6 |
|---|
| Error | 26.0 |
|---|
| Cost | 19840 |
|---|
\[{b}^{2} + 3.08641975308642 \cdot 10^{-5} \cdot {\left(angle \cdot \left(\pi \cdot a\right)\right)}^{2}
\]
| Alternative 7 |
|---|
| Error | 26.0 |
|---|
| Cost | 19840 |
|---|
\[{b}^{2} + 3.08641975308642 \cdot 10^{-5} \cdot {\left(\pi \cdot \left(angle \cdot a\right)\right)}^{2}
\]