\[e^{re} \cdot \sin im
\]
↓
\[e^{re} \cdot \sin im
\]
(FPCore (re im) :precision binary64 (* (exp re) (sin im)))
↓
(FPCore (re im) :precision binary64 (* (exp re) (sin im)))
double code(double re, double im) {
return exp(re) * sin(im);
}
↓
double code(double re, double im) {
return exp(re) * sin(im);
}
real(8) function code(re, im)
real(8), intent (in) :: re
real(8), intent (in) :: im
code = exp(re) * sin(im)
end function
↓
real(8) function code(re, im)
real(8), intent (in) :: re
real(8), intent (in) :: im
code = exp(re) * sin(im)
end function
public static double code(double re, double im) {
return Math.exp(re) * Math.sin(im);
}
↓
public static double code(double re, double im) {
return Math.exp(re) * Math.sin(im);
}
def code(re, im):
return math.exp(re) * math.sin(im)
↓
def code(re, im):
return math.exp(re) * math.sin(im)
function code(re, im)
return Float64(exp(re) * sin(im))
end
↓
function code(re, im)
return Float64(exp(re) * sin(im))
end
function tmp = code(re, im)
tmp = exp(re) * sin(im);
end
↓
function tmp = code(re, im)
tmp = exp(re) * sin(im);
end
code[re_, im_] := N[(N[Exp[re], $MachinePrecision] * N[Sin[im], $MachinePrecision]), $MachinePrecision]
↓
code[re_, im_] := N[(N[Exp[re], $MachinePrecision] * N[Sin[im], $MachinePrecision]), $MachinePrecision]
e^{re} \cdot \sin im
↓
e^{re} \cdot \sin im
Alternatives
| Alternative 1 |
|---|
| Error | 0.6 |
|---|
| Cost | 13892 |
|---|
\[\begin{array}{l}
\mathbf{if}\;e^{re} \leq 0:\\
\;\;\;\;0\\
\mathbf{else}:\\
\;\;\;\;\sin im \cdot \left(\left(re + 1\right) + \left(re \cdot re\right) \cdot \left(0.5 + re \cdot 0.16666666666666666\right)\right)\\
\end{array}
\]
| Alternative 2 |
|---|
| Error | 0.7 |
|---|
| Cost | 13636 |
|---|
\[\begin{array}{l}
\mathbf{if}\;e^{re} \leq 0:\\
\;\;\;\;0\\
\mathbf{else}:\\
\;\;\;\;\sin im \cdot \left(\left(re + 1\right) + \left(re \cdot re\right) \cdot 0.5\right)\\
\end{array}
\]
| Alternative 3 |
|---|
| Error | 0.9 |
|---|
| Cost | 13316 |
|---|
\[\begin{array}{l}
\mathbf{if}\;e^{re} \leq 0:\\
\;\;\;\;0\\
\mathbf{else}:\\
\;\;\;\;-\frac{\sin im}{re + -1}\\
\end{array}
\]
| Alternative 4 |
|---|
| Error | 0.8 |
|---|
| Cost | 13252 |
|---|
\[\begin{array}{l}
\mathbf{if}\;e^{re} \leq 0:\\
\;\;\;\;0\\
\mathbf{else}:\\
\;\;\;\;\sin im \cdot \left(re + 1\right)\\
\end{array}
\]
| Alternative 5 |
|---|
| Error | 1.3 |
|---|
| Cost | 12996 |
|---|
\[\begin{array}{l}
\mathbf{if}\;e^{re} \leq 0:\\
\;\;\;\;0\\
\mathbf{else}:\\
\;\;\;\;\sin im\\
\end{array}
\]
| Alternative 6 |
|---|
| Error | 21.3 |
|---|
| Cost | 196 |
|---|
\[\begin{array}{l}
\mathbf{if}\;re \leq -0.003420779315360097:\\
\;\;\;\;0\\
\mathbf{else}:\\
\;\;\;\;im\\
\end{array}
\]
| Alternative 7 |
|---|
| Error | 41.8 |
|---|
| Cost | 64 |
|---|
\[im
\]