\[\left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right|
\]
↓
\[\begin{array}{l}
t_1 := \frac{eh}{ew \cdot \tan t}\\
\left|\mathsf{fma}\left(ew \cdot \sin t, \frac{1}{\mathsf{hypot}\left(1, t_1\right)}, eh \cdot \left(\cos t \cdot \sin \tan^{-1} t_1\right)\right)\right|
\end{array}
\]
(FPCore (eh ew t)
:precision binary64
(fabs
(+
(* (* ew (sin t)) (cos (atan (/ (/ eh ew) (tan t)))))
(* (* eh (cos t)) (sin (atan (/ (/ eh ew) (tan t))))))))
↓
(FPCore (eh ew t)
:precision binary64
(let* ((t_1 (/ eh (* ew (tan t)))))
(fabs
(fma
(* ew (sin t))
(/ 1.0 (hypot 1.0 t_1))
(* eh (* (cos t) (sin (atan t_1))))))))double code(double eh, double ew, double t) {
return fabs((((ew * sin(t)) * cos(atan(((eh / ew) / tan(t))))) + ((eh * cos(t)) * sin(atan(((eh / ew) / tan(t)))))));
}
↓
double code(double eh, double ew, double t) {
double t_1 = eh / (ew * tan(t));
return fabs(fma((ew * sin(t)), (1.0 / hypot(1.0, t_1)), (eh * (cos(t) * sin(atan(t_1))))));
}
function code(eh, ew, t)
return abs(Float64(Float64(Float64(ew * sin(t)) * cos(atan(Float64(Float64(eh / ew) / tan(t))))) + Float64(Float64(eh * cos(t)) * sin(atan(Float64(Float64(eh / ew) / tan(t)))))))
end
↓
function code(eh, ew, t)
t_1 = Float64(eh / Float64(ew * tan(t)))
return abs(fma(Float64(ew * sin(t)), Float64(1.0 / hypot(1.0, t_1)), Float64(eh * Float64(cos(t) * sin(atan(t_1))))))
end
code[eh_, ew_, t_] := N[Abs[N[(N[(N[(ew * N[Sin[t], $MachinePrecision]), $MachinePrecision] * N[Cos[N[ArcTan[N[(N[(eh / ew), $MachinePrecision] / N[Tan[t], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] + N[(N[(eh * N[Cos[t], $MachinePrecision]), $MachinePrecision] * N[Sin[N[ArcTan[N[(N[(eh / ew), $MachinePrecision] / N[Tan[t], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
↓
code[eh_, ew_, t_] := Block[{t$95$1 = N[(eh / N[(ew * N[Tan[t], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, N[Abs[N[(N[(ew * N[Sin[t], $MachinePrecision]), $MachinePrecision] * N[(1.0 / N[Sqrt[1.0 ^ 2 + t$95$1 ^ 2], $MachinePrecision]), $MachinePrecision] + N[(eh * N[(N[Cos[t], $MachinePrecision] * N[Sin[N[ArcTan[t$95$1], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right|
↓
\begin{array}{l}
t_1 := \frac{eh}{ew \cdot \tan t}\\
\left|\mathsf{fma}\left(ew \cdot \sin t, \frac{1}{\mathsf{hypot}\left(1, t_1\right)}, eh \cdot \left(\cos t \cdot \sin \tan^{-1} t_1\right)\right)\right|
\end{array}
Alternatives
| Alternative 1 |
|---|
| Accuracy | 99.8% |
|---|
| Cost | 58816 |
|---|
\[\begin{array}{l}
t_1 := \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\\
\left|\cos t_1 \cdot \left(ew \cdot \sin t\right) + \left(eh \cdot \cos t\right) \cdot \sin t_1\right|
\end{array}
\]
| Alternative 2 |
|---|
| Accuracy | 99.7% |
|---|
| Cost | 52480 |
|---|
\[\left|\left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \frac{ew}{\frac{\mathsf{hypot}\left(1, \frac{eh}{ew \cdot \tan t}\right)}{\sin t}}\right|
\]
| Alternative 3 |
|---|
| Accuracy | 99.7% |
|---|
| Cost | 52480 |
|---|
\[\left|\left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \frac{\sin t}{\frac{\mathsf{hypot}\left(1, \frac{\frac{eh}{\tan t}}{ew}\right)}{ew}}\right|
\]
| Alternative 4 |
|---|
| Accuracy | 99.1% |
|---|
| Cost | 52416 |
|---|
\[\left|\left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \cos \tan^{-1} \left(\frac{eh}{ew \cdot t}\right) \cdot \left(ew \cdot \sin t\right)\right|
\]
| Alternative 5 |
|---|
| Accuracy | 99.0% |
|---|
| Cost | 46080 |
|---|
\[\left|\left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \frac{ew}{\frac{\mathsf{hypot}\left(1, \frac{eh}{ew \cdot t}\right)}{\sin t}}\right|
\]
| Alternative 6 |
|---|
| Accuracy | 99.0% |
|---|
| Cost | 46080 |
|---|
\[\left|\left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \frac{\sin t}{\frac{\mathsf{hypot}\left(1, \frac{eh}{ew \cdot t}\right)}{ew}}\right|
\]
| Alternative 7 |
|---|
| Accuracy | 98.6% |
|---|
| Cost | 39232 |
|---|
\[\left|\left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + ew \cdot \sin t\right|
\]
| Alternative 8 |
|---|
| Accuracy | 96.7% |
|---|
| Cost | 33737 |
|---|
\[\begin{array}{l}
t_1 := eh \cdot \cos t\\
\mathbf{if}\;ew \leq -1.36 \cdot 10^{-159} \lor \neg \left(ew \leq 4.8 \cdot 10^{-159}\right):\\
\;\;\;\;\left|ew \cdot \sin t + t_1 \cdot \sin \tan^{-1} \left(\frac{eh}{ew \cdot t} + -0.3333333333333333 \cdot \frac{t \cdot eh}{ew}\right)\right|\\
\mathbf{else}:\\
\;\;\;\;\left|t_1 \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \frac{1}{0.16666666666666666 \cdot \frac{t}{ew} + \frac{1}{ew \cdot t}}\right|\\
\end{array}
\]
| Alternative 9 |
|---|
| Accuracy | 96.5% |
|---|
| Cost | 33609 |
|---|
\[\begin{array}{l}
t_1 := eh \cdot \cos t\\
\mathbf{if}\;ew \leq -3.6 \cdot 10^{-160} \lor \neg \left(ew \leq 1.56 \cdot 10^{-161}\right):\\
\;\;\;\;\left|ew \cdot \sin t + t_1 \cdot \sin \tan^{-1} \left(\frac{eh}{ew \cdot t} + -0.3333333333333333 \cdot \frac{t \cdot eh}{ew}\right)\right|\\
\mathbf{else}:\\
\;\;\;\;\left|t_1 \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + t \cdot \frac{t \cdot \left(ew \cdot ew\right)}{eh}\right|\\
\end{array}
\]
| Alternative 10 |
|---|
| Accuracy | 90.4% |
|---|
| Cost | 33481 |
|---|
\[\begin{array}{l}
t_1 := eh \cdot \cos t\\
\mathbf{if}\;ew \leq -3.6 \cdot 10^{-160} \lor \neg \left(ew \leq 10^{-250}\right):\\
\;\;\;\;\left|ew \cdot \sin t + t_1 \cdot \sin \tan^{-1} \left(\frac{eh}{ew \cdot t}\right)\right|\\
\mathbf{else}:\\
\;\;\;\;\left|t_1 \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + t \cdot \frac{t \cdot \left(ew \cdot ew\right)}{eh}\right|\\
\end{array}
\]
| Alternative 11 |
|---|
| Accuracy | 83.5% |
|---|
| Cost | 33097 |
|---|
\[\begin{array}{l}
\mathbf{if}\;ew \leq -2.05 \cdot 10^{-91} \lor \neg \left(ew \leq 4.9 \cdot 10^{-118}\right):\\
\;\;\;\;\left|ew \cdot \sin t + eh \cdot \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right)\right|\\
\mathbf{else}:\\
\;\;\;\;\left|\left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + ew \cdot t\right|\\
\end{array}
\]
| Alternative 12 |
|---|
| Accuracy | 83.0% |
|---|
| Cost | 32969 |
|---|
\[\begin{array}{l}
\mathbf{if}\;ew \leq -3.4 \cdot 10^{-92} \lor \neg \left(ew \leq 3.75 \cdot 10^{-118}\right):\\
\;\;\;\;\left|ew \cdot \sin t + eh \cdot \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right)\right|\\
\mathbf{else}:\\
\;\;\;\;\left|t \cdot \frac{t \cdot \left(ew \cdot ew\right)}{eh} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{eh}{ew \cdot t}\right)\right|\\
\end{array}
\]
| Alternative 13 |
|---|
| Accuracy | 89.3% |
|---|
| Cost | 32832 |
|---|
\[\left|ew \cdot \sin t + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{eh}{ew \cdot t}\right)\right|
\]
| Alternative 14 |
|---|
| Accuracy | 50.6% |
|---|
| Cost | 27460 |
|---|
\[\begin{array}{l}
t_1 := \frac{eh}{ew \cdot t}\\
t_2 := t \cdot \frac{t \cdot \left(ew \cdot ew\right)}{eh}\\
t_3 := eh \cdot \cos t\\
\mathbf{if}\;t \leq -6.5 \cdot 10^{-6}:\\
\;\;\;\;\left|t_3 \cdot \sin \tan^{-1} \left(t_1 + -0.3333333333333333 \cdot \frac{t \cdot eh}{ew}\right) + t_2\right|\\
\mathbf{elif}\;t \leq 0.0116:\\
\;\;\;\;\left|\left(ew \cdot t\right) \cdot \frac{ew}{\frac{eh}{t}} + eh \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right|\\
\mathbf{else}:\\
\;\;\;\;\left|t_2 + t_3 \cdot \sin \tan^{-1} t_1\right|\\
\end{array}
\]
| Alternative 15 |
|---|
| Accuracy | 50.2% |
|---|
| Cost | 27081 |
|---|
\[\begin{array}{l}
\mathbf{if}\;t \leq -0.0005 \lor \neg \left(t \leq 0.0116\right):\\
\;\;\;\;\left|t \cdot \frac{t \cdot \left(ew \cdot ew\right)}{eh} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{eh}{ew \cdot t}\right)\right|\\
\mathbf{else}:\\
\;\;\;\;\left|\left(ew \cdot t\right) \cdot \frac{ew}{\frac{eh}{t}} + eh \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right|\\
\end{array}
\]
| Alternative 16 |
|---|
| Accuracy | 38.6% |
|---|
| Cost | 26688 |
|---|
\[\left|eh \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + ew \cdot \left(ew \cdot \left(t \cdot \frac{t}{eh}\right)\right)\right|
\]
| Alternative 17 |
|---|
| Accuracy | 39.2% |
|---|
| Cost | 26688 |
|---|
\[\left|\left(ew \cdot t\right) \cdot \frac{ew}{\frac{eh}{t}} + eh \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right|
\]
| Alternative 18 |
|---|
| Accuracy | 33.8% |
|---|
| Cost | 20288 |
|---|
\[\left|\frac{ew \cdot ew}{\frac{\frac{eh}{t}}{t}} + eh \cdot \sin \tan^{-1} \left(\frac{eh}{ew \cdot t}\right)\right|
\]