Math FPCore C Java Python Julia Wolfram TeX \[\left|\left(ew \cdot \cos t\right) \cdot \cos \tan^{-1} \left(\frac{\left(-eh\right) \cdot \tan t}{ew}\right) - \left(eh \cdot \sin t\right) \cdot \sin \tan^{-1} \left(\frac{\left(-eh\right) \cdot \tan t}{ew}\right)\right|
\]
↓
\[\left|\left(ew \cdot \cos t\right) \cdot \mathsf{expm1}\left(\mathsf{log1p}\left(\cos \tan^{-1} \left(\frac{eh}{ew} \cdot \tan t\right)\right)\right) - \left(eh \cdot \sin t\right) \cdot \sin \tan^{-1} \left(\frac{eh \cdot \left(-\tan t\right)}{ew}\right)\right|
\]
(FPCore (eh ew t)
:precision binary64
(fabs
(-
(* (* ew (cos t)) (cos (atan (/ (* (- eh) (tan t)) ew))))
(* (* eh (sin t)) (sin (atan (/ (* (- eh) (tan t)) ew))))))) ↓
(FPCore (eh ew t)
:precision binary64
(fabs
(-
(* (* ew (cos t)) (expm1 (log1p (cos (atan (* (/ eh ew) (tan t)))))))
(* (* eh (sin t)) (sin (atan (/ (* eh (- (tan t))) ew))))))) double code(double eh, double ew, double t) {
return fabs((((ew * cos(t)) * cos(atan(((-eh * tan(t)) / ew)))) - ((eh * sin(t)) * sin(atan(((-eh * tan(t)) / ew))))));
}
↓
double code(double eh, double ew, double t) {
return fabs((((ew * cos(t)) * expm1(log1p(cos(atan(((eh / ew) * tan(t))))))) - ((eh * sin(t)) * sin(atan(((eh * -tan(t)) / ew))))));
}
public static double code(double eh, double ew, double t) {
return Math.abs((((ew * Math.cos(t)) * Math.cos(Math.atan(((-eh * Math.tan(t)) / ew)))) - ((eh * Math.sin(t)) * Math.sin(Math.atan(((-eh * Math.tan(t)) / ew))))));
}
↓
public static double code(double eh, double ew, double t) {
return Math.abs((((ew * Math.cos(t)) * Math.expm1(Math.log1p(Math.cos(Math.atan(((eh / ew) * Math.tan(t))))))) - ((eh * Math.sin(t)) * Math.sin(Math.atan(((eh * -Math.tan(t)) / ew))))));
}
def code(eh, ew, t):
return math.fabs((((ew * math.cos(t)) * math.cos(math.atan(((-eh * math.tan(t)) / ew)))) - ((eh * math.sin(t)) * math.sin(math.atan(((-eh * math.tan(t)) / ew))))))
↓
def code(eh, ew, t):
return math.fabs((((ew * math.cos(t)) * math.expm1(math.log1p(math.cos(math.atan(((eh / ew) * math.tan(t))))))) - ((eh * math.sin(t)) * math.sin(math.atan(((eh * -math.tan(t)) / ew))))))
function code(eh, ew, t)
return abs(Float64(Float64(Float64(ew * cos(t)) * cos(atan(Float64(Float64(Float64(-eh) * tan(t)) / ew)))) - Float64(Float64(eh * sin(t)) * sin(atan(Float64(Float64(Float64(-eh) * tan(t)) / ew))))))
end
↓
function code(eh, ew, t)
return abs(Float64(Float64(Float64(ew * cos(t)) * expm1(log1p(cos(atan(Float64(Float64(eh / ew) * tan(t))))))) - Float64(Float64(eh * sin(t)) * sin(atan(Float64(Float64(eh * Float64(-tan(t))) / ew))))))
end
code[eh_, ew_, t_] := N[Abs[N[(N[(N[(ew * N[Cos[t], $MachinePrecision]), $MachinePrecision] * N[Cos[N[ArcTan[N[(N[((-eh) * N[Tan[t], $MachinePrecision]), $MachinePrecision] / ew), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - N[(N[(eh * N[Sin[t], $MachinePrecision]), $MachinePrecision] * N[Sin[N[ArcTan[N[(N[((-eh) * N[Tan[t], $MachinePrecision]), $MachinePrecision] / ew), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
↓
code[eh_, ew_, t_] := N[Abs[N[(N[(N[(ew * N[Cos[t], $MachinePrecision]), $MachinePrecision] * N[(Exp[N[Log[1 + N[Cos[N[ArcTan[N[(N[(eh / ew), $MachinePrecision] * N[Tan[t], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]], $MachinePrecision]] - 1), $MachinePrecision]), $MachinePrecision] - N[(N[(eh * N[Sin[t], $MachinePrecision]), $MachinePrecision] * N[Sin[N[ArcTan[N[(N[(eh * (-N[Tan[t], $MachinePrecision])), $MachinePrecision] / ew), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\left|\left(ew \cdot \cos t\right) \cdot \cos \tan^{-1} \left(\frac{\left(-eh\right) \cdot \tan t}{ew}\right) - \left(eh \cdot \sin t\right) \cdot \sin \tan^{-1} \left(\frac{\left(-eh\right) \cdot \tan t}{ew}\right)\right|
↓
\left|\left(ew \cdot \cos t\right) \cdot \mathsf{expm1}\left(\mathsf{log1p}\left(\cos \tan^{-1} \left(\frac{eh}{ew} \cdot \tan t\right)\right)\right) - \left(eh \cdot \sin t\right) \cdot \sin \tan^{-1} \left(\frac{eh \cdot \left(-\tan t\right)}{ew}\right)\right|
Alternatives Alternative 1 Accuracy 99.8% Cost 71680
\[\left|\left(ew \cdot \cos t\right) \cdot \mathsf{expm1}\left(\mathsf{log1p}\left(\cos \tan^{-1} \left(\frac{eh}{ew} \cdot \tan t\right)\right)\right) - \left(eh \cdot \sin t\right) \cdot \sin \tan^{-1} \left(\frac{eh \cdot \left(-\tan t\right)}{ew}\right)\right|
\]
Alternative 2 Accuracy 99.8% Cost 58944
\[\begin{array}{l}
t_1 := \tan^{-1} \left(\frac{eh \cdot \left(-\tan t\right)}{ew}\right)\\
\left|\left(ew \cdot \cos t\right) \cdot \cos t_1 - \left(eh \cdot \sin t\right) \cdot \sin t_1\right|
\end{array}
\]
Alternative 3 Accuracy 99.8% Cost 52672
\[\left|\left(ew \cdot \cos t\right) \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{eh \cdot \tan t}{ew}\right)} - \left(eh \cdot \sin t\right) \cdot \sin \tan^{-1} \left(\frac{eh \cdot \left(-\tan t\right)}{ew}\right)\right|
\]
Alternative 4 Accuracy 99.0% Cost 52544
\[\left|\left(eh \cdot \sin t\right) \cdot \sin \tan^{-1} \left(\frac{t \cdot \left(-eh\right)}{ew}\right) - \left(ew \cdot \cos t\right) \cdot \cos \tan^{-1} \left(\frac{eh \cdot \left(-\tan t\right)}{ew}\right)\right|
\]
Alternative 5 Accuracy 99.0% Cost 46272
\[\left|\left(ew \cdot \cos t\right) \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{eh \cdot \tan t}{ew}\right)} - \left(eh \cdot \sin t\right) \cdot \sin \tan^{-1} \left(\frac{t \cdot \left(-eh\right)}{ew}\right)\right|
\]
Alternative 6 Accuracy 98.6% Cost 46208
\[\left|\left(ew \cdot \cos t\right) \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{eh \cdot \tan t}{ew}\right)} - \left(eh \cdot \sin t\right) \cdot \sin \tan^{-1} \left(eh \cdot \frac{t}{ew}\right)\right|
\]
Alternative 7 Accuracy 82.0% Cost 46148
\[\begin{array}{l}
t_1 := \sin \tan^{-1} \left(\frac{t \cdot \left(-eh\right)}{ew}\right)\\
\mathbf{if}\;ew \leq 3.8 \cdot 10^{+84}:\\
\;\;\;\;\left|ew \cdot \cos \tan^{-1} \left(\frac{eh \cdot \left(-\tan t\right)}{ew}\right) - \left(eh \cdot \sin t\right) \cdot t_1\right|\\
\mathbf{else}:\\
\;\;\;\;\left|\left(t \cdot eh\right) \cdot t_1 + \left(ew \cdot \cos t\right) \cdot \frac{-1}{\mathsf{hypot}\left(1, \frac{eh \cdot \tan t}{ew}\right)}\right|\\
\end{array}
\]
Alternative 8 Accuracy 82.0% Cost 40004
\[\begin{array}{l}
t_1 := \mathsf{hypot}\left(1, \frac{eh \cdot \tan t}{ew}\right)\\
t_2 := \sin \tan^{-1} \left(\frac{t \cdot \left(-eh\right)}{ew}\right)\\
\mathbf{if}\;ew \leq 1.25 \cdot 10^{+84}:\\
\;\;\;\;\left|\left(eh \cdot \sin t\right) \cdot t_2 - ew \cdot \frac{1}{t_1}\right|\\
\mathbf{else}:\\
\;\;\;\;\left|\left(t \cdot eh\right) \cdot t_2 + \left(ew \cdot \cos t\right) \cdot \frac{-1}{t_1}\right|\\
\end{array}
\]
Alternative 9 Accuracy 79.8% Cost 39744
\[\left|\left(eh \cdot \sin t\right) \cdot \sin \tan^{-1} \left(\frac{t \cdot \left(-eh\right)}{ew}\right) - ew \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{eh \cdot \tan t}{ew}\right)}\right|
\]
Alternative 10 Accuracy 78.7% Cost 39552
\[\left|ew \cdot \cos \tan^{-1} \left(eh \cdot \frac{t}{ew}\right) - \left(eh \cdot \sin t\right) \cdot \sin \tan^{-1} \left(\frac{t \cdot \left(-eh\right)}{ew}\right)\right|
\]
Alternative 11 Accuracy 78.5% Cost 33344
\[\left|ew \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\frac{ew}{eh}}\right)} - \left(eh \cdot \sin t\right) \cdot \sin \tan^{-1} \left(\frac{t \cdot \left(-eh\right)}{ew}\right)\right|
\]
Alternative 12 Accuracy 55.3% Cost 33216
\[\begin{array}{l}
t_1 := \tan^{-1} \left(\frac{t \cdot \left(-eh\right)}{ew}\right)\\
\left|ew \cdot \cos t_1 - \left(t \cdot eh\right) \cdot \sin t_1\right|
\end{array}
\]