
(FPCore (F B x) :precision binary64 (+ (- (* x (/ 1.0 (tan B)))) (* (/ F (sin B)) (pow (+ (+ (* F F) 2.0) (* 2.0 x)) (- (/ 1.0 2.0))))))
double code(double F, double B, double x) {
return -(x * (1.0 / tan(B))) + ((F / sin(B)) * pow((((F * F) + 2.0) + (2.0 * x)), -(1.0 / 2.0)));
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
code = -(x * (1.0d0 / tan(b))) + ((f / sin(b)) * ((((f * f) + 2.0d0) + (2.0d0 * x)) ** -(1.0d0 / 2.0d0)))
end function
public static double code(double F, double B, double x) {
return -(x * (1.0 / Math.tan(B))) + ((F / Math.sin(B)) * Math.pow((((F * F) + 2.0) + (2.0 * x)), -(1.0 / 2.0)));
}
def code(F, B, x): return -(x * (1.0 / math.tan(B))) + ((F / math.sin(B)) * math.pow((((F * F) + 2.0) + (2.0 * x)), -(1.0 / 2.0)))
function code(F, B, x) return Float64(Float64(-Float64(x * Float64(1.0 / tan(B)))) + Float64(Float64(F / sin(B)) * (Float64(Float64(Float64(F * F) + 2.0) + Float64(2.0 * x)) ^ Float64(-Float64(1.0 / 2.0))))) end
function tmp = code(F, B, x) tmp = -(x * (1.0 / tan(B))) + ((F / sin(B)) * ((((F * F) + 2.0) + (2.0 * x)) ^ -(1.0 / 2.0))); end
code[F_, B_, x_] := N[((-N[(x * N[(1.0 / N[Tan[B], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]) + N[(N[(F / N[Sin[B], $MachinePrecision]), $MachinePrecision] * N[Power[N[(N[(N[(F * F), $MachinePrecision] + 2.0), $MachinePrecision] + N[(2.0 * x), $MachinePrecision]), $MachinePrecision], (-N[(1.0 / 2.0), $MachinePrecision])], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(-x \cdot \frac{1}{\tan B}\right) + \frac{F}{\sin B} \cdot {\left(\left(F \cdot F + 2\right) + 2 \cdot x\right)}^{\left(-\frac{1}{2}\right)}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 31 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (F B x) :precision binary64 (+ (- (* x (/ 1.0 (tan B)))) (* (/ F (sin B)) (pow (+ (+ (* F F) 2.0) (* 2.0 x)) (- (/ 1.0 2.0))))))
double code(double F, double B, double x) {
return -(x * (1.0 / tan(B))) + ((F / sin(B)) * pow((((F * F) + 2.0) + (2.0 * x)), -(1.0 / 2.0)));
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
code = -(x * (1.0d0 / tan(b))) + ((f / sin(b)) * ((((f * f) + 2.0d0) + (2.0d0 * x)) ** -(1.0d0 / 2.0d0)))
end function
public static double code(double F, double B, double x) {
return -(x * (1.0 / Math.tan(B))) + ((F / Math.sin(B)) * Math.pow((((F * F) + 2.0) + (2.0 * x)), -(1.0 / 2.0)));
}
def code(F, B, x): return -(x * (1.0 / math.tan(B))) + ((F / math.sin(B)) * math.pow((((F * F) + 2.0) + (2.0 * x)), -(1.0 / 2.0)))
function code(F, B, x) return Float64(Float64(-Float64(x * Float64(1.0 / tan(B)))) + Float64(Float64(F / sin(B)) * (Float64(Float64(Float64(F * F) + 2.0) + Float64(2.0 * x)) ^ Float64(-Float64(1.0 / 2.0))))) end
function tmp = code(F, B, x) tmp = -(x * (1.0 / tan(B))) + ((F / sin(B)) * ((((F * F) + 2.0) + (2.0 * x)) ^ -(1.0 / 2.0))); end
code[F_, B_, x_] := N[((-N[(x * N[(1.0 / N[Tan[B], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]) + N[(N[(F / N[Sin[B], $MachinePrecision]), $MachinePrecision] * N[Power[N[(N[(N[(F * F), $MachinePrecision] + 2.0), $MachinePrecision] + N[(2.0 * x), $MachinePrecision]), $MachinePrecision], (-N[(1.0 / 2.0), $MachinePrecision])], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(-x \cdot \frac{1}{\tan B}\right) + \frac{F}{\sin B} \cdot {\left(\left(F \cdot F + 2\right) + 2 \cdot x\right)}^{\left(-\frac{1}{2}\right)}
\end{array}
(FPCore (F B x)
:precision binary64
(let* ((t_0 (/ x (tan B))))
(if (<= F -1e+55)
(- (/ -1.0 (sin B)) t_0)
(if (<= F 4e-6)
(- (* F (/ (pow (fma x 2.0 (fma F F 2.0)) -0.5) (sin B))) t_0)
(- (/ 1.0 (sin B)) t_0)))))
double code(double F, double B, double x) {
double t_0 = x / tan(B);
double tmp;
if (F <= -1e+55) {
tmp = (-1.0 / sin(B)) - t_0;
} else if (F <= 4e-6) {
tmp = (F * (pow(fma(x, 2.0, fma(F, F, 2.0)), -0.5) / sin(B))) - t_0;
} else {
tmp = (1.0 / sin(B)) - t_0;
}
return tmp;
}
function code(F, B, x) t_0 = Float64(x / tan(B)) tmp = 0.0 if (F <= -1e+55) tmp = Float64(Float64(-1.0 / sin(B)) - t_0); elseif (F <= 4e-6) tmp = Float64(Float64(F * Float64((fma(x, 2.0, fma(F, F, 2.0)) ^ -0.5) / sin(B))) - t_0); else tmp = Float64(Float64(1.0 / sin(B)) - t_0); end return tmp end
code[F_, B_, x_] := Block[{t$95$0 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -1e+55], N[(N[(-1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision], If[LessEqual[F, 4e-6], N[(N[(F * N[(N[Power[N[(x * 2.0 + N[(F * F + 2.0), $MachinePrecision]), $MachinePrecision], -0.5], $MachinePrecision] / N[Sin[B], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision], N[(N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -1 \cdot 10^{+55}:\\
\;\;\;\;\frac{-1}{\sin B} - t\_0\\
\mathbf{elif}\;F \leq 4 \cdot 10^{-6}:\\
\;\;\;\;F \cdot \frac{{\left(\mathsf{fma}\left(x, 2, \mathsf{fma}\left(F, F, 2\right)\right)\right)}^{-0.5}}{\sin B} - t\_0\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{\sin B} - t\_0\\
\end{array}
\end{array}
if F < -1.00000000000000001e55Initial program 54.3%
distribute-lft-neg-in54.3%
+-commutative54.3%
associate-*l/67.9%
associate-/l*67.8%
fma-define67.8%
/-rgt-identity67.8%
remove-double-neg67.8%
fma-neg67.8%
Simplified67.9%
clear-num67.9%
inv-pow67.9%
fma-define67.9%
fma-undefine67.9%
*-commutative67.9%
fma-define67.9%
fma-define67.9%
Applied egg-rr67.9%
unpow-167.9%
Simplified67.9%
Taylor expanded in F around -inf 99.7%
if -1.00000000000000001e55 < F < 3.99999999999999982e-6Initial program 99.4%
distribute-lft-neg-in99.4%
+-commutative99.4%
associate-*l/99.4%
associate-/l*99.5%
fma-define99.5%
/-rgt-identity99.5%
remove-double-neg99.5%
fma-neg99.5%
Simplified99.6%
if 3.99999999999999982e-6 < F Initial program 59.7%
distribute-lft-neg-in59.7%
+-commutative59.7%
associate-*l/67.7%
associate-/l*67.6%
fma-define67.6%
/-rgt-identity67.6%
remove-double-neg67.6%
fma-neg67.6%
Simplified67.6%
clear-num67.6%
inv-pow67.6%
fma-define67.6%
fma-undefine67.6%
*-commutative67.6%
fma-define67.6%
fma-define67.6%
Applied egg-rr67.6%
unpow-167.6%
Simplified67.6%
Taylor expanded in F around inf 99.8%
Final simplification99.7%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (/ x (tan B))))
(if (<= F -13000000000.0)
(- (/ -1.0 (sin B)) t_0)
(if (<= F 4e-6)
(+
(* x (/ -1.0 (tan B)))
(* (/ F (sin B)) (pow (+ (+ 2.0 (* F F)) (* x 2.0)) -0.5)))
(- (/ 1.0 (sin B)) t_0)))))
double code(double F, double B, double x) {
double t_0 = x / tan(B);
double tmp;
if (F <= -13000000000.0) {
tmp = (-1.0 / sin(B)) - t_0;
} else if (F <= 4e-6) {
tmp = (x * (-1.0 / tan(B))) + ((F / sin(B)) * pow(((2.0 + (F * F)) + (x * 2.0)), -0.5));
} else {
tmp = (1.0 / sin(B)) - t_0;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: tmp
t_0 = x / tan(b)
if (f <= (-13000000000.0d0)) then
tmp = ((-1.0d0) / sin(b)) - t_0
else if (f <= 4d-6) then
tmp = (x * ((-1.0d0) / tan(b))) + ((f / sin(b)) * (((2.0d0 + (f * f)) + (x * 2.0d0)) ** (-0.5d0)))
else
tmp = (1.0d0 / sin(b)) - t_0
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = x / Math.tan(B);
double tmp;
if (F <= -13000000000.0) {
tmp = (-1.0 / Math.sin(B)) - t_0;
} else if (F <= 4e-6) {
tmp = (x * (-1.0 / Math.tan(B))) + ((F / Math.sin(B)) * Math.pow(((2.0 + (F * F)) + (x * 2.0)), -0.5));
} else {
tmp = (1.0 / Math.sin(B)) - t_0;
}
return tmp;
}
def code(F, B, x): t_0 = x / math.tan(B) tmp = 0 if F <= -13000000000.0: tmp = (-1.0 / math.sin(B)) - t_0 elif F <= 4e-6: tmp = (x * (-1.0 / math.tan(B))) + ((F / math.sin(B)) * math.pow(((2.0 + (F * F)) + (x * 2.0)), -0.5)) else: tmp = (1.0 / math.sin(B)) - t_0 return tmp
function code(F, B, x) t_0 = Float64(x / tan(B)) tmp = 0.0 if (F <= -13000000000.0) tmp = Float64(Float64(-1.0 / sin(B)) - t_0); elseif (F <= 4e-6) tmp = Float64(Float64(x * Float64(-1.0 / tan(B))) + Float64(Float64(F / sin(B)) * (Float64(Float64(2.0 + Float64(F * F)) + Float64(x * 2.0)) ^ -0.5))); else tmp = Float64(Float64(1.0 / sin(B)) - t_0); end return tmp end
function tmp_2 = code(F, B, x) t_0 = x / tan(B); tmp = 0.0; if (F <= -13000000000.0) tmp = (-1.0 / sin(B)) - t_0; elseif (F <= 4e-6) tmp = (x * (-1.0 / tan(B))) + ((F / sin(B)) * (((2.0 + (F * F)) + (x * 2.0)) ^ -0.5)); else tmp = (1.0 / sin(B)) - t_0; end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -13000000000.0], N[(N[(-1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision], If[LessEqual[F, 4e-6], N[(N[(x * N[(-1.0 / N[Tan[B], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(F / N[Sin[B], $MachinePrecision]), $MachinePrecision] * N[Power[N[(N[(2.0 + N[(F * F), $MachinePrecision]), $MachinePrecision] + N[(x * 2.0), $MachinePrecision]), $MachinePrecision], -0.5], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -13000000000:\\
\;\;\;\;\frac{-1}{\sin B} - t\_0\\
\mathbf{elif}\;F \leq 4 \cdot 10^{-6}:\\
\;\;\;\;x \cdot \frac{-1}{\tan B} + \frac{F}{\sin B} \cdot {\left(\left(2 + F \cdot F\right) + x \cdot 2\right)}^{-0.5}\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{\sin B} - t\_0\\
\end{array}
\end{array}
if F < -1.3e10Initial program 59.2%
distribute-lft-neg-in59.2%
+-commutative59.2%
associate-*l/71.3%
associate-/l*71.3%
fma-define71.3%
/-rgt-identity71.3%
remove-double-neg71.3%
fma-neg71.3%
Simplified71.3%
clear-num71.3%
inv-pow71.3%
fma-define71.3%
fma-undefine71.3%
*-commutative71.3%
fma-define71.3%
fma-define71.3%
Applied egg-rr71.3%
unpow-171.3%
Simplified71.3%
Taylor expanded in F around -inf 99.7%
if -1.3e10 < F < 3.99999999999999982e-6Initial program 99.4%
if 3.99999999999999982e-6 < F Initial program 59.7%
distribute-lft-neg-in59.7%
+-commutative59.7%
associate-*l/67.7%
associate-/l*67.6%
fma-define67.6%
/-rgt-identity67.6%
remove-double-neg67.6%
fma-neg67.6%
Simplified67.6%
clear-num67.6%
inv-pow67.6%
fma-define67.6%
fma-undefine67.6%
*-commutative67.6%
fma-define67.6%
fma-define67.6%
Applied egg-rr67.6%
unpow-167.6%
Simplified67.6%
Taylor expanded in F around inf 99.8%
Final simplification99.6%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (/ x (tan B))))
(if (<= F -1.45)
(- (/ -1.0 (sin B)) t_0)
(if (<= F 4e-6)
(- (* F (/ 1.0 (* (sin B) (sqrt (+ 2.0 (* x 2.0)))))) t_0)
(- (/ 1.0 (sin B)) t_0)))))
double code(double F, double B, double x) {
double t_0 = x / tan(B);
double tmp;
if (F <= -1.45) {
tmp = (-1.0 / sin(B)) - t_0;
} else if (F <= 4e-6) {
tmp = (F * (1.0 / (sin(B) * sqrt((2.0 + (x * 2.0)))))) - t_0;
} else {
tmp = (1.0 / sin(B)) - t_0;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: tmp
t_0 = x / tan(b)
if (f <= (-1.45d0)) then
tmp = ((-1.0d0) / sin(b)) - t_0
else if (f <= 4d-6) then
tmp = (f * (1.0d0 / (sin(b) * sqrt((2.0d0 + (x * 2.0d0)))))) - t_0
else
tmp = (1.0d0 / sin(b)) - t_0
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = x / Math.tan(B);
double tmp;
if (F <= -1.45) {
tmp = (-1.0 / Math.sin(B)) - t_0;
} else if (F <= 4e-6) {
tmp = (F * (1.0 / (Math.sin(B) * Math.sqrt((2.0 + (x * 2.0)))))) - t_0;
} else {
tmp = (1.0 / Math.sin(B)) - t_0;
}
return tmp;
}
def code(F, B, x): t_0 = x / math.tan(B) tmp = 0 if F <= -1.45: tmp = (-1.0 / math.sin(B)) - t_0 elif F <= 4e-6: tmp = (F * (1.0 / (math.sin(B) * math.sqrt((2.0 + (x * 2.0)))))) - t_0 else: tmp = (1.0 / math.sin(B)) - t_0 return tmp
function code(F, B, x) t_0 = Float64(x / tan(B)) tmp = 0.0 if (F <= -1.45) tmp = Float64(Float64(-1.0 / sin(B)) - t_0); elseif (F <= 4e-6) tmp = Float64(Float64(F * Float64(1.0 / Float64(sin(B) * sqrt(Float64(2.0 + Float64(x * 2.0)))))) - t_0); else tmp = Float64(Float64(1.0 / sin(B)) - t_0); end return tmp end
function tmp_2 = code(F, B, x) t_0 = x / tan(B); tmp = 0.0; if (F <= -1.45) tmp = (-1.0 / sin(B)) - t_0; elseif (F <= 4e-6) tmp = (F * (1.0 / (sin(B) * sqrt((2.0 + (x * 2.0)))))) - t_0; else tmp = (1.0 / sin(B)) - t_0; end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -1.45], N[(N[(-1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision], If[LessEqual[F, 4e-6], N[(N[(F * N[(1.0 / N[(N[Sin[B], $MachinePrecision] * N[Sqrt[N[(2.0 + N[(x * 2.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision], N[(N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -1.45:\\
\;\;\;\;\frac{-1}{\sin B} - t\_0\\
\mathbf{elif}\;F \leq 4 \cdot 10^{-6}:\\
\;\;\;\;F \cdot \frac{1}{\sin B \cdot \sqrt{2 + x \cdot 2}} - t\_0\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{\sin B} - t\_0\\
\end{array}
\end{array}
if F < -1.44999999999999996Initial program 60.2%
distribute-lft-neg-in60.2%
+-commutative60.2%
associate-*l/72.0%
associate-/l*72.0%
fma-define72.0%
/-rgt-identity72.0%
remove-double-neg72.0%
fma-neg72.0%
Simplified72.0%
clear-num72.0%
inv-pow72.0%
fma-define72.0%
fma-undefine72.0%
*-commutative72.0%
fma-define72.0%
fma-define72.0%
Applied egg-rr72.0%
unpow-172.0%
Simplified72.0%
Taylor expanded in F around -inf 99.3%
if -1.44999999999999996 < F < 3.99999999999999982e-6Initial program 99.4%
distribute-lft-neg-in99.4%
+-commutative99.4%
associate-*l/99.4%
associate-/l*99.4%
fma-define99.4%
/-rgt-identity99.4%
remove-double-neg99.4%
fma-neg99.4%
Simplified99.6%
clear-num99.5%
inv-pow99.5%
fma-define99.5%
fma-undefine99.5%
*-commutative99.5%
fma-define99.5%
fma-define99.5%
Applied egg-rr99.5%
unpow-199.5%
Simplified99.5%
Taylor expanded in F around 0 99.4%
if 3.99999999999999982e-6 < F Initial program 59.7%
distribute-lft-neg-in59.7%
+-commutative59.7%
associate-*l/67.7%
associate-/l*67.6%
fma-define67.6%
/-rgt-identity67.6%
remove-double-neg67.6%
fma-neg67.6%
Simplified67.6%
clear-num67.6%
inv-pow67.6%
fma-define67.6%
fma-undefine67.6%
*-commutative67.6%
fma-define67.6%
fma-define67.6%
Applied egg-rr67.6%
unpow-167.6%
Simplified67.6%
Taylor expanded in F around inf 99.8%
Final simplification99.5%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (/ x (tan B))))
(if (<= F -8.6e-7)
(- (/ -1.0 (sin B)) t_0)
(if (<= F -2.4e-216)
(- (/ F (* (sin B) (sqrt 2.0))) (/ x B))
(if (<= F 1.35e-128)
(- t_0)
(if (<= F 4e-6)
(-
(* (/ F (sin B)) (pow (+ (+ 2.0 (* F F)) (* x 2.0)) -0.5))
(/ x B))
(- (/ 1.0 (sin B)) t_0)))))))
double code(double F, double B, double x) {
double t_0 = x / tan(B);
double tmp;
if (F <= -8.6e-7) {
tmp = (-1.0 / sin(B)) - t_0;
} else if (F <= -2.4e-216) {
tmp = (F / (sin(B) * sqrt(2.0))) - (x / B);
} else if (F <= 1.35e-128) {
tmp = -t_0;
} else if (F <= 4e-6) {
tmp = ((F / sin(B)) * pow(((2.0 + (F * F)) + (x * 2.0)), -0.5)) - (x / B);
} else {
tmp = (1.0 / sin(B)) - t_0;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: tmp
t_0 = x / tan(b)
if (f <= (-8.6d-7)) then
tmp = ((-1.0d0) / sin(b)) - t_0
else if (f <= (-2.4d-216)) then
tmp = (f / (sin(b) * sqrt(2.0d0))) - (x / b)
else if (f <= 1.35d-128) then
tmp = -t_0
else if (f <= 4d-6) then
tmp = ((f / sin(b)) * (((2.0d0 + (f * f)) + (x * 2.0d0)) ** (-0.5d0))) - (x / b)
else
tmp = (1.0d0 / sin(b)) - t_0
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = x / Math.tan(B);
double tmp;
if (F <= -8.6e-7) {
tmp = (-1.0 / Math.sin(B)) - t_0;
} else if (F <= -2.4e-216) {
tmp = (F / (Math.sin(B) * Math.sqrt(2.0))) - (x / B);
} else if (F <= 1.35e-128) {
tmp = -t_0;
} else if (F <= 4e-6) {
tmp = ((F / Math.sin(B)) * Math.pow(((2.0 + (F * F)) + (x * 2.0)), -0.5)) - (x / B);
} else {
tmp = (1.0 / Math.sin(B)) - t_0;
}
return tmp;
}
def code(F, B, x): t_0 = x / math.tan(B) tmp = 0 if F <= -8.6e-7: tmp = (-1.0 / math.sin(B)) - t_0 elif F <= -2.4e-216: tmp = (F / (math.sin(B) * math.sqrt(2.0))) - (x / B) elif F <= 1.35e-128: tmp = -t_0 elif F <= 4e-6: tmp = ((F / math.sin(B)) * math.pow(((2.0 + (F * F)) + (x * 2.0)), -0.5)) - (x / B) else: tmp = (1.0 / math.sin(B)) - t_0 return tmp
function code(F, B, x) t_0 = Float64(x / tan(B)) tmp = 0.0 if (F <= -8.6e-7) tmp = Float64(Float64(-1.0 / sin(B)) - t_0); elseif (F <= -2.4e-216) tmp = Float64(Float64(F / Float64(sin(B) * sqrt(2.0))) - Float64(x / B)); elseif (F <= 1.35e-128) tmp = Float64(-t_0); elseif (F <= 4e-6) tmp = Float64(Float64(Float64(F / sin(B)) * (Float64(Float64(2.0 + Float64(F * F)) + Float64(x * 2.0)) ^ -0.5)) - Float64(x / B)); else tmp = Float64(Float64(1.0 / sin(B)) - t_0); end return tmp end
function tmp_2 = code(F, B, x) t_0 = x / tan(B); tmp = 0.0; if (F <= -8.6e-7) tmp = (-1.0 / sin(B)) - t_0; elseif (F <= -2.4e-216) tmp = (F / (sin(B) * sqrt(2.0))) - (x / B); elseif (F <= 1.35e-128) tmp = -t_0; elseif (F <= 4e-6) tmp = ((F / sin(B)) * (((2.0 + (F * F)) + (x * 2.0)) ^ -0.5)) - (x / B); else tmp = (1.0 / sin(B)) - t_0; end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -8.6e-7], N[(N[(-1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision], If[LessEqual[F, -2.4e-216], N[(N[(F / N[(N[Sin[B], $MachinePrecision] * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, 1.35e-128], (-t$95$0), If[LessEqual[F, 4e-6], N[(N[(N[(F / N[Sin[B], $MachinePrecision]), $MachinePrecision] * N[Power[N[(N[(2.0 + N[(F * F), $MachinePrecision]), $MachinePrecision] + N[(x * 2.0), $MachinePrecision]), $MachinePrecision], -0.5], $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], N[(N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -8.6 \cdot 10^{-7}:\\
\;\;\;\;\frac{-1}{\sin B} - t\_0\\
\mathbf{elif}\;F \leq -2.4 \cdot 10^{-216}:\\
\;\;\;\;\frac{F}{\sin B \cdot \sqrt{2}} - \frac{x}{B}\\
\mathbf{elif}\;F \leq 1.35 \cdot 10^{-128}:\\
\;\;\;\;-t\_0\\
\mathbf{elif}\;F \leq 4 \cdot 10^{-6}:\\
\;\;\;\;\frac{F}{\sin B} \cdot {\left(\left(2 + F \cdot F\right) + x \cdot 2\right)}^{-0.5} - \frac{x}{B}\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{\sin B} - t\_0\\
\end{array}
\end{array}
if F < -8.6000000000000002e-7Initial program 61.1%
distribute-lft-neg-in61.1%
+-commutative61.1%
associate-*l/72.6%
associate-/l*72.6%
fma-define72.6%
/-rgt-identity72.6%
remove-double-neg72.6%
fma-neg72.6%
Simplified72.7%
clear-num72.6%
inv-pow72.6%
fma-define72.6%
fma-undefine72.6%
*-commutative72.6%
fma-define72.6%
fma-define72.6%
Applied egg-rr72.6%
unpow-172.6%
Simplified72.6%
Taylor expanded in F around -inf 99.3%
if -8.6000000000000002e-7 < F < -2.40000000000000004e-216Initial program 99.3%
Taylor expanded in B around 0 81.9%
+-commutative81.9%
unsub-neg81.9%
Applied egg-rr82.0%
Taylor expanded in F around 0 82.0%
*-commutative82.0%
Simplified82.0%
Taylor expanded in x around 0 82.0%
if -2.40000000000000004e-216 < F < 1.35000000000000003e-128Initial program 99.5%
distribute-lft-neg-in99.5%
+-commutative99.5%
fma-define99.5%
+-commutative99.5%
*-commutative99.5%
fma-define99.5%
fma-define99.5%
metadata-eval99.5%
metadata-eval99.5%
associate-*r/99.7%
*-rgt-identity99.7%
Simplified99.7%
Taylor expanded in F around 0 77.7%
mul-1-neg77.7%
associate-/l*77.6%
Simplified77.6%
clear-num77.6%
un-div-inv77.7%
quot-tan77.8%
Applied egg-rr77.8%
if 1.35000000000000003e-128 < F < 3.99999999999999982e-6Initial program 99.4%
Taylor expanded in B around 0 88.7%
if 3.99999999999999982e-6 < F Initial program 59.7%
distribute-lft-neg-in59.7%
+-commutative59.7%
associate-*l/67.7%
associate-/l*67.6%
fma-define67.6%
/-rgt-identity67.6%
remove-double-neg67.6%
fma-neg67.6%
Simplified67.6%
clear-num67.6%
inv-pow67.6%
fma-define67.6%
fma-undefine67.6%
*-commutative67.6%
fma-define67.6%
fma-define67.6%
Applied egg-rr67.6%
unpow-167.6%
Simplified67.6%
Taylor expanded in F around inf 99.8%
Final simplification91.7%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (pow (+ (+ 2.0 (* F F)) (* x 2.0)) -0.5)) (t_1 (/ x (tan B))))
(if (<= F -8.6e-7)
(- (/ -1.0 (sin B)) t_1)
(if (<= F -1.3e-217)
(- (* t_0 (/ 1.0 (/ (sin B) F))) (/ x B))
(if (<= F 1.62e-133)
(- t_1)
(if (<= F 4e-6)
(- (* (/ F (sin B)) t_0) (/ x B))
(- (/ 1.0 (sin B)) t_1)))))))
double code(double F, double B, double x) {
double t_0 = pow(((2.0 + (F * F)) + (x * 2.0)), -0.5);
double t_1 = x / tan(B);
double tmp;
if (F <= -8.6e-7) {
tmp = (-1.0 / sin(B)) - t_1;
} else if (F <= -1.3e-217) {
tmp = (t_0 * (1.0 / (sin(B) / F))) - (x / B);
} else if (F <= 1.62e-133) {
tmp = -t_1;
} else if (F <= 4e-6) {
tmp = ((F / sin(B)) * t_0) - (x / B);
} else {
tmp = (1.0 / sin(B)) - t_1;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = ((2.0d0 + (f * f)) + (x * 2.0d0)) ** (-0.5d0)
t_1 = x / tan(b)
if (f <= (-8.6d-7)) then
tmp = ((-1.0d0) / sin(b)) - t_1
else if (f <= (-1.3d-217)) then
tmp = (t_0 * (1.0d0 / (sin(b) / f))) - (x / b)
else if (f <= 1.62d-133) then
tmp = -t_1
else if (f <= 4d-6) then
tmp = ((f / sin(b)) * t_0) - (x / b)
else
tmp = (1.0d0 / sin(b)) - t_1
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = Math.pow(((2.0 + (F * F)) + (x * 2.0)), -0.5);
double t_1 = x / Math.tan(B);
double tmp;
if (F <= -8.6e-7) {
tmp = (-1.0 / Math.sin(B)) - t_1;
} else if (F <= -1.3e-217) {
tmp = (t_0 * (1.0 / (Math.sin(B) / F))) - (x / B);
} else if (F <= 1.62e-133) {
tmp = -t_1;
} else if (F <= 4e-6) {
tmp = ((F / Math.sin(B)) * t_0) - (x / B);
} else {
tmp = (1.0 / Math.sin(B)) - t_1;
}
return tmp;
}
def code(F, B, x): t_0 = math.pow(((2.0 + (F * F)) + (x * 2.0)), -0.5) t_1 = x / math.tan(B) tmp = 0 if F <= -8.6e-7: tmp = (-1.0 / math.sin(B)) - t_1 elif F <= -1.3e-217: tmp = (t_0 * (1.0 / (math.sin(B) / F))) - (x / B) elif F <= 1.62e-133: tmp = -t_1 elif F <= 4e-6: tmp = ((F / math.sin(B)) * t_0) - (x / B) else: tmp = (1.0 / math.sin(B)) - t_1 return tmp
function code(F, B, x) t_0 = Float64(Float64(2.0 + Float64(F * F)) + Float64(x * 2.0)) ^ -0.5 t_1 = Float64(x / tan(B)) tmp = 0.0 if (F <= -8.6e-7) tmp = Float64(Float64(-1.0 / sin(B)) - t_1); elseif (F <= -1.3e-217) tmp = Float64(Float64(t_0 * Float64(1.0 / Float64(sin(B) / F))) - Float64(x / B)); elseif (F <= 1.62e-133) tmp = Float64(-t_1); elseif (F <= 4e-6) tmp = Float64(Float64(Float64(F / sin(B)) * t_0) - Float64(x / B)); else tmp = Float64(Float64(1.0 / sin(B)) - t_1); end return tmp end
function tmp_2 = code(F, B, x) t_0 = ((2.0 + (F * F)) + (x * 2.0)) ^ -0.5; t_1 = x / tan(B); tmp = 0.0; if (F <= -8.6e-7) tmp = (-1.0 / sin(B)) - t_1; elseif (F <= -1.3e-217) tmp = (t_0 * (1.0 / (sin(B) / F))) - (x / B); elseif (F <= 1.62e-133) tmp = -t_1; elseif (F <= 4e-6) tmp = ((F / sin(B)) * t_0) - (x / B); else tmp = (1.0 / sin(B)) - t_1; end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[Power[N[(N[(2.0 + N[(F * F), $MachinePrecision]), $MachinePrecision] + N[(x * 2.0), $MachinePrecision]), $MachinePrecision], -0.5], $MachinePrecision]}, Block[{t$95$1 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -8.6e-7], N[(N[(-1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision], If[LessEqual[F, -1.3e-217], N[(N[(t$95$0 * N[(1.0 / N[(N[Sin[B], $MachinePrecision] / F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, 1.62e-133], (-t$95$1), If[LessEqual[F, 4e-6], N[(N[(N[(F / N[Sin[B], $MachinePrecision]), $MachinePrecision] * t$95$0), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], N[(N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := {\left(\left(2 + F \cdot F\right) + x \cdot 2\right)}^{-0.5}\\
t_1 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -8.6 \cdot 10^{-7}:\\
\;\;\;\;\frac{-1}{\sin B} - t\_1\\
\mathbf{elif}\;F \leq -1.3 \cdot 10^{-217}:\\
\;\;\;\;t\_0 \cdot \frac{1}{\frac{\sin B}{F}} - \frac{x}{B}\\
\mathbf{elif}\;F \leq 1.62 \cdot 10^{-133}:\\
\;\;\;\;-t\_1\\
\mathbf{elif}\;F \leq 4 \cdot 10^{-6}:\\
\;\;\;\;\frac{F}{\sin B} \cdot t\_0 - \frac{x}{B}\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{\sin B} - t\_1\\
\end{array}
\end{array}
if F < -8.6000000000000002e-7Initial program 61.1%
distribute-lft-neg-in61.1%
+-commutative61.1%
associate-*l/72.6%
associate-/l*72.6%
fma-define72.6%
/-rgt-identity72.6%
remove-double-neg72.6%
fma-neg72.6%
Simplified72.7%
clear-num72.6%
inv-pow72.6%
fma-define72.6%
fma-undefine72.6%
*-commutative72.6%
fma-define72.6%
fma-define72.6%
Applied egg-rr72.6%
unpow-172.6%
Simplified72.6%
Taylor expanded in F around -inf 99.3%
if -8.6000000000000002e-7 < F < -1.29999999999999997e-217Initial program 99.3%
Taylor expanded in B around 0 81.9%
clear-num82.0%
inv-pow82.0%
Applied egg-rr82.0%
unpow-182.0%
Simplified82.0%
if -1.29999999999999997e-217 < F < 1.61999999999999998e-133Initial program 99.5%
distribute-lft-neg-in99.5%
+-commutative99.5%
fma-define99.5%
+-commutative99.5%
*-commutative99.5%
fma-define99.5%
fma-define99.5%
metadata-eval99.5%
metadata-eval99.5%
associate-*r/99.7%
*-rgt-identity99.7%
Simplified99.7%
Taylor expanded in F around 0 77.7%
mul-1-neg77.7%
associate-/l*77.6%
Simplified77.6%
clear-num77.6%
un-div-inv77.7%
quot-tan77.8%
Applied egg-rr77.8%
if 1.61999999999999998e-133 < F < 3.99999999999999982e-6Initial program 99.4%
Taylor expanded in B around 0 88.7%
if 3.99999999999999982e-6 < F Initial program 59.7%
distribute-lft-neg-in59.7%
+-commutative59.7%
associate-*l/67.7%
associate-/l*67.6%
fma-define67.6%
/-rgt-identity67.6%
remove-double-neg67.6%
fma-neg67.6%
Simplified67.6%
clear-num67.6%
inv-pow67.6%
fma-define67.6%
fma-undefine67.6%
*-commutative67.6%
fma-define67.6%
fma-define67.6%
Applied egg-rr67.6%
unpow-167.6%
Simplified67.6%
Taylor expanded in F around inf 99.8%
Final simplification91.7%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (* F (/ (sqrt 0.5) (sin B)))) (t_1 (/ x (tan B))))
(if (<= F -5.8e+84)
(- (/ -1.0 B) t_1)
(if (<= F -4.4e-5)
(- (/ F (* (sin B) (- (* -0.5 (/ (+ 2.0 (* x 2.0)) F)) F))) (/ x B))
(if (<= F -3.5e-140)
t_0
(if (<= F 2.55e-84)
(- t_1)
(if (<= F 4e-6)
t_0
(if (<= F 5.5e+272)
(- (/ 1.0 (sin B)) (/ x B))
(- (* F (/ 1.0 (* F B))) t_1)))))))))
double code(double F, double B, double x) {
double t_0 = F * (sqrt(0.5) / sin(B));
double t_1 = x / tan(B);
double tmp;
if (F <= -5.8e+84) {
tmp = (-1.0 / B) - t_1;
} else if (F <= -4.4e-5) {
tmp = (F / (sin(B) * ((-0.5 * ((2.0 + (x * 2.0)) / F)) - F))) - (x / B);
} else if (F <= -3.5e-140) {
tmp = t_0;
} else if (F <= 2.55e-84) {
tmp = -t_1;
} else if (F <= 4e-6) {
tmp = t_0;
} else if (F <= 5.5e+272) {
tmp = (1.0 / sin(B)) - (x / B);
} else {
tmp = (F * (1.0 / (F * B))) - t_1;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = f * (sqrt(0.5d0) / sin(b))
t_1 = x / tan(b)
if (f <= (-5.8d+84)) then
tmp = ((-1.0d0) / b) - t_1
else if (f <= (-4.4d-5)) then
tmp = (f / (sin(b) * (((-0.5d0) * ((2.0d0 + (x * 2.0d0)) / f)) - f))) - (x / b)
else if (f <= (-3.5d-140)) then
tmp = t_0
else if (f <= 2.55d-84) then
tmp = -t_1
else if (f <= 4d-6) then
tmp = t_0
else if (f <= 5.5d+272) then
tmp = (1.0d0 / sin(b)) - (x / b)
else
tmp = (f * (1.0d0 / (f * b))) - t_1
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = F * (Math.sqrt(0.5) / Math.sin(B));
double t_1 = x / Math.tan(B);
double tmp;
if (F <= -5.8e+84) {
tmp = (-1.0 / B) - t_1;
} else if (F <= -4.4e-5) {
tmp = (F / (Math.sin(B) * ((-0.5 * ((2.0 + (x * 2.0)) / F)) - F))) - (x / B);
} else if (F <= -3.5e-140) {
tmp = t_0;
} else if (F <= 2.55e-84) {
tmp = -t_1;
} else if (F <= 4e-6) {
tmp = t_0;
} else if (F <= 5.5e+272) {
tmp = (1.0 / Math.sin(B)) - (x / B);
} else {
tmp = (F * (1.0 / (F * B))) - t_1;
}
return tmp;
}
def code(F, B, x): t_0 = F * (math.sqrt(0.5) / math.sin(B)) t_1 = x / math.tan(B) tmp = 0 if F <= -5.8e+84: tmp = (-1.0 / B) - t_1 elif F <= -4.4e-5: tmp = (F / (math.sin(B) * ((-0.5 * ((2.0 + (x * 2.0)) / F)) - F))) - (x / B) elif F <= -3.5e-140: tmp = t_0 elif F <= 2.55e-84: tmp = -t_1 elif F <= 4e-6: tmp = t_0 elif F <= 5.5e+272: tmp = (1.0 / math.sin(B)) - (x / B) else: tmp = (F * (1.0 / (F * B))) - t_1 return tmp
function code(F, B, x) t_0 = Float64(F * Float64(sqrt(0.5) / sin(B))) t_1 = Float64(x / tan(B)) tmp = 0.0 if (F <= -5.8e+84) tmp = Float64(Float64(-1.0 / B) - t_1); elseif (F <= -4.4e-5) tmp = Float64(Float64(F / Float64(sin(B) * Float64(Float64(-0.5 * Float64(Float64(2.0 + Float64(x * 2.0)) / F)) - F))) - Float64(x / B)); elseif (F <= -3.5e-140) tmp = t_0; elseif (F <= 2.55e-84) tmp = Float64(-t_1); elseif (F <= 4e-6) tmp = t_0; elseif (F <= 5.5e+272) tmp = Float64(Float64(1.0 / sin(B)) - Float64(x / B)); else tmp = Float64(Float64(F * Float64(1.0 / Float64(F * B))) - t_1); end return tmp end
function tmp_2 = code(F, B, x) t_0 = F * (sqrt(0.5) / sin(B)); t_1 = x / tan(B); tmp = 0.0; if (F <= -5.8e+84) tmp = (-1.0 / B) - t_1; elseif (F <= -4.4e-5) tmp = (F / (sin(B) * ((-0.5 * ((2.0 + (x * 2.0)) / F)) - F))) - (x / B); elseif (F <= -3.5e-140) tmp = t_0; elseif (F <= 2.55e-84) tmp = -t_1; elseif (F <= 4e-6) tmp = t_0; elseif (F <= 5.5e+272) tmp = (1.0 / sin(B)) - (x / B); else tmp = (F * (1.0 / (F * B))) - t_1; end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(F * N[(N[Sqrt[0.5], $MachinePrecision] / N[Sin[B], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -5.8e+84], N[(N[(-1.0 / B), $MachinePrecision] - t$95$1), $MachinePrecision], If[LessEqual[F, -4.4e-5], N[(N[(F / N[(N[Sin[B], $MachinePrecision] * N[(N[(-0.5 * N[(N[(2.0 + N[(x * 2.0), $MachinePrecision]), $MachinePrecision] / F), $MachinePrecision]), $MachinePrecision] - F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, -3.5e-140], t$95$0, If[LessEqual[F, 2.55e-84], (-t$95$1), If[LessEqual[F, 4e-6], t$95$0, If[LessEqual[F, 5.5e+272], N[(N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], N[(N[(F * N[(1.0 / N[(F * B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := F \cdot \frac{\sqrt{0.5}}{\sin B}\\
t_1 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -5.8 \cdot 10^{+84}:\\
\;\;\;\;\frac{-1}{B} - t\_1\\
\mathbf{elif}\;F \leq -4.4 \cdot 10^{-5}:\\
\;\;\;\;\frac{F}{\sin B \cdot \left(-0.5 \cdot \frac{2 + x \cdot 2}{F} - F\right)} - \frac{x}{B}\\
\mathbf{elif}\;F \leq -3.5 \cdot 10^{-140}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;F \leq 2.55 \cdot 10^{-84}:\\
\;\;\;\;-t\_1\\
\mathbf{elif}\;F \leq 4 \cdot 10^{-6}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;F \leq 5.5 \cdot 10^{+272}:\\
\;\;\;\;\frac{1}{\sin B} - \frac{x}{B}\\
\mathbf{else}:\\
\;\;\;\;F \cdot \frac{1}{F \cdot B} - t\_1\\
\end{array}
\end{array}
if F < -5.79999999999999977e84Initial program 50.9%
distribute-lft-neg-in50.9%
+-commutative50.9%
associate-*l/64.5%
associate-/l*64.5%
fma-define64.5%
/-rgt-identity64.5%
remove-double-neg64.5%
fma-neg64.5%
Simplified64.5%
clear-num64.6%
inv-pow64.6%
fma-define64.6%
fma-undefine64.6%
*-commutative64.6%
fma-define64.6%
fma-define64.6%
Applied egg-rr64.6%
unpow-164.6%
Simplified64.6%
Taylor expanded in F around -inf 99.7%
Taylor expanded in B around 0 80.9%
if -5.79999999999999977e84 < F < -4.3999999999999999e-5Initial program 95.0%
Taylor expanded in B around 0 85.7%
+-commutative85.7%
unsub-neg85.7%
Applied egg-rr90.3%
Taylor expanded in F around -inf 90.3%
if -4.3999999999999999e-5 < F < -3.4999999999999998e-140 or 2.5499999999999998e-84 < F < 3.99999999999999982e-6Initial program 99.3%
Taylor expanded in B around 0 83.0%
+-commutative83.0%
unsub-neg83.0%
Applied egg-rr83.1%
Taylor expanded in F around 0 82.8%
*-commutative82.8%
Simplified82.8%
Taylor expanded in x around 0 70.6%
associate-/l*70.8%
Simplified70.8%
if -3.4999999999999998e-140 < F < 2.5499999999999998e-84Initial program 99.4%
distribute-lft-neg-in99.4%
+-commutative99.4%
fma-define99.4%
+-commutative99.4%
*-commutative99.4%
fma-define99.4%
fma-define99.4%
metadata-eval99.4%
metadata-eval99.4%
associate-*r/99.7%
*-rgt-identity99.7%
Simplified99.7%
Taylor expanded in F around 0 75.0%
mul-1-neg75.0%
associate-/l*74.9%
Simplified74.9%
clear-num74.8%
un-div-inv75.0%
quot-tan75.1%
Applied egg-rr75.1%
if 3.99999999999999982e-6 < F < 5.4999999999999998e272Initial program 61.7%
Taylor expanded in B around 0 44.7%
Taylor expanded in F around inf 82.8%
if 5.4999999999999998e272 < F Initial program 50.7%
distribute-lft-neg-in50.7%
+-commutative50.7%
associate-*l/64.0%
associate-/l*64.0%
fma-define64.0%
/-rgt-identity64.0%
remove-double-neg64.0%
fma-neg64.0%
Simplified64.0%
Taylor expanded in F around inf 99.7%
Taylor expanded in B around 0 90.7%
*-commutative90.7%
Simplified90.7%
Final simplification79.0%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (- (/ F (* (sin B) (sqrt 2.0))) (/ x B))) (t_1 (/ x (tan B))))
(if (<= F -8.6e-7)
(- (/ -1.0 (sin B)) t_1)
(if (<= F -3e-221)
t_0
(if (<= F 3.4e-133)
(- t_1)
(if (<= F 4e-6) t_0 (- (/ 1.0 (sin B)) t_1)))))))
double code(double F, double B, double x) {
double t_0 = (F / (sin(B) * sqrt(2.0))) - (x / B);
double t_1 = x / tan(B);
double tmp;
if (F <= -8.6e-7) {
tmp = (-1.0 / sin(B)) - t_1;
} else if (F <= -3e-221) {
tmp = t_0;
} else if (F <= 3.4e-133) {
tmp = -t_1;
} else if (F <= 4e-6) {
tmp = t_0;
} else {
tmp = (1.0 / sin(B)) - t_1;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = (f / (sin(b) * sqrt(2.0d0))) - (x / b)
t_1 = x / tan(b)
if (f <= (-8.6d-7)) then
tmp = ((-1.0d0) / sin(b)) - t_1
else if (f <= (-3d-221)) then
tmp = t_0
else if (f <= 3.4d-133) then
tmp = -t_1
else if (f <= 4d-6) then
tmp = t_0
else
tmp = (1.0d0 / sin(b)) - t_1
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = (F / (Math.sin(B) * Math.sqrt(2.0))) - (x / B);
double t_1 = x / Math.tan(B);
double tmp;
if (F <= -8.6e-7) {
tmp = (-1.0 / Math.sin(B)) - t_1;
} else if (F <= -3e-221) {
tmp = t_0;
} else if (F <= 3.4e-133) {
tmp = -t_1;
} else if (F <= 4e-6) {
tmp = t_0;
} else {
tmp = (1.0 / Math.sin(B)) - t_1;
}
return tmp;
}
def code(F, B, x): t_0 = (F / (math.sin(B) * math.sqrt(2.0))) - (x / B) t_1 = x / math.tan(B) tmp = 0 if F <= -8.6e-7: tmp = (-1.0 / math.sin(B)) - t_1 elif F <= -3e-221: tmp = t_0 elif F <= 3.4e-133: tmp = -t_1 elif F <= 4e-6: tmp = t_0 else: tmp = (1.0 / math.sin(B)) - t_1 return tmp
function code(F, B, x) t_0 = Float64(Float64(F / Float64(sin(B) * sqrt(2.0))) - Float64(x / B)) t_1 = Float64(x / tan(B)) tmp = 0.0 if (F <= -8.6e-7) tmp = Float64(Float64(-1.0 / sin(B)) - t_1); elseif (F <= -3e-221) tmp = t_0; elseif (F <= 3.4e-133) tmp = Float64(-t_1); elseif (F <= 4e-6) tmp = t_0; else tmp = Float64(Float64(1.0 / sin(B)) - t_1); end return tmp end
function tmp_2 = code(F, B, x) t_0 = (F / (sin(B) * sqrt(2.0))) - (x / B); t_1 = x / tan(B); tmp = 0.0; if (F <= -8.6e-7) tmp = (-1.0 / sin(B)) - t_1; elseif (F <= -3e-221) tmp = t_0; elseif (F <= 3.4e-133) tmp = -t_1; elseif (F <= 4e-6) tmp = t_0; else tmp = (1.0 / sin(B)) - t_1; end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(N[(F / N[(N[Sin[B], $MachinePrecision] * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -8.6e-7], N[(N[(-1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision], If[LessEqual[F, -3e-221], t$95$0, If[LessEqual[F, 3.4e-133], (-t$95$1), If[LessEqual[F, 4e-6], t$95$0, N[(N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{F}{\sin B \cdot \sqrt{2}} - \frac{x}{B}\\
t_1 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -8.6 \cdot 10^{-7}:\\
\;\;\;\;\frac{-1}{\sin B} - t\_1\\
\mathbf{elif}\;F \leq -3 \cdot 10^{-221}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;F \leq 3.4 \cdot 10^{-133}:\\
\;\;\;\;-t\_1\\
\mathbf{elif}\;F \leq 4 \cdot 10^{-6}:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{\sin B} - t\_1\\
\end{array}
\end{array}
if F < -8.6000000000000002e-7Initial program 61.1%
distribute-lft-neg-in61.1%
+-commutative61.1%
associate-*l/72.6%
associate-/l*72.6%
fma-define72.6%
/-rgt-identity72.6%
remove-double-neg72.6%
fma-neg72.6%
Simplified72.7%
clear-num72.6%
inv-pow72.6%
fma-define72.6%
fma-undefine72.6%
*-commutative72.6%
fma-define72.6%
fma-define72.6%
Applied egg-rr72.6%
unpow-172.6%
Simplified72.6%
Taylor expanded in F around -inf 99.3%
if -8.6000000000000002e-7 < F < -3.0000000000000002e-221 or 3.40000000000000006e-133 < F < 3.99999999999999982e-6Initial program 99.3%
Taylor expanded in B around 0 84.5%
+-commutative84.5%
unsub-neg84.5%
Applied egg-rr84.6%
Taylor expanded in F around 0 84.4%
*-commutative84.4%
Simplified84.4%
Taylor expanded in x around 0 84.4%
if -3.0000000000000002e-221 < F < 3.40000000000000006e-133Initial program 99.5%
distribute-lft-neg-in99.5%
+-commutative99.5%
fma-define99.5%
+-commutative99.5%
*-commutative99.5%
fma-define99.5%
fma-define99.5%
metadata-eval99.5%
metadata-eval99.5%
associate-*r/99.7%
*-rgt-identity99.7%
Simplified99.7%
Taylor expanded in F around 0 77.7%
mul-1-neg77.7%
associate-/l*77.6%
Simplified77.6%
clear-num77.6%
un-div-inv77.7%
quot-tan77.8%
Applied egg-rr77.8%
if 3.99999999999999982e-6 < F Initial program 59.7%
distribute-lft-neg-in59.7%
+-commutative59.7%
associate-*l/67.7%
associate-/l*67.6%
fma-define67.6%
/-rgt-identity67.6%
remove-double-neg67.6%
fma-neg67.6%
Simplified67.6%
clear-num67.6%
inv-pow67.6%
fma-define67.6%
fma-undefine67.6%
*-commutative67.6%
fma-define67.6%
fma-define67.6%
Applied egg-rr67.6%
unpow-167.6%
Simplified67.6%
Taylor expanded in F around inf 99.8%
Final simplification91.7%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (* F (/ (sqrt 0.5) (sin B)))) (t_1 (/ x (tan B))))
(if (<= F -2.5e-7)
(- (/ -1.0 (sin B)) t_1)
(if (<= F -3.5e-140)
t_0
(if (<= F 3.2e-82)
(- t_1)
(if (<= F 4e-6) t_0 (- (/ 1.0 (sin B)) t_1)))))))
double code(double F, double B, double x) {
double t_0 = F * (sqrt(0.5) / sin(B));
double t_1 = x / tan(B);
double tmp;
if (F <= -2.5e-7) {
tmp = (-1.0 / sin(B)) - t_1;
} else if (F <= -3.5e-140) {
tmp = t_0;
} else if (F <= 3.2e-82) {
tmp = -t_1;
} else if (F <= 4e-6) {
tmp = t_0;
} else {
tmp = (1.0 / sin(B)) - t_1;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = f * (sqrt(0.5d0) / sin(b))
t_1 = x / tan(b)
if (f <= (-2.5d-7)) then
tmp = ((-1.0d0) / sin(b)) - t_1
else if (f <= (-3.5d-140)) then
tmp = t_0
else if (f <= 3.2d-82) then
tmp = -t_1
else if (f <= 4d-6) then
tmp = t_0
else
tmp = (1.0d0 / sin(b)) - t_1
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = F * (Math.sqrt(0.5) / Math.sin(B));
double t_1 = x / Math.tan(B);
double tmp;
if (F <= -2.5e-7) {
tmp = (-1.0 / Math.sin(B)) - t_1;
} else if (F <= -3.5e-140) {
tmp = t_0;
} else if (F <= 3.2e-82) {
tmp = -t_1;
} else if (F <= 4e-6) {
tmp = t_0;
} else {
tmp = (1.0 / Math.sin(B)) - t_1;
}
return tmp;
}
def code(F, B, x): t_0 = F * (math.sqrt(0.5) / math.sin(B)) t_1 = x / math.tan(B) tmp = 0 if F <= -2.5e-7: tmp = (-1.0 / math.sin(B)) - t_1 elif F <= -3.5e-140: tmp = t_0 elif F <= 3.2e-82: tmp = -t_1 elif F <= 4e-6: tmp = t_0 else: tmp = (1.0 / math.sin(B)) - t_1 return tmp
function code(F, B, x) t_0 = Float64(F * Float64(sqrt(0.5) / sin(B))) t_1 = Float64(x / tan(B)) tmp = 0.0 if (F <= -2.5e-7) tmp = Float64(Float64(-1.0 / sin(B)) - t_1); elseif (F <= -3.5e-140) tmp = t_0; elseif (F <= 3.2e-82) tmp = Float64(-t_1); elseif (F <= 4e-6) tmp = t_0; else tmp = Float64(Float64(1.0 / sin(B)) - t_1); end return tmp end
function tmp_2 = code(F, B, x) t_0 = F * (sqrt(0.5) / sin(B)); t_1 = x / tan(B); tmp = 0.0; if (F <= -2.5e-7) tmp = (-1.0 / sin(B)) - t_1; elseif (F <= -3.5e-140) tmp = t_0; elseif (F <= 3.2e-82) tmp = -t_1; elseif (F <= 4e-6) tmp = t_0; else tmp = (1.0 / sin(B)) - t_1; end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(F * N[(N[Sqrt[0.5], $MachinePrecision] / N[Sin[B], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -2.5e-7], N[(N[(-1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision], If[LessEqual[F, -3.5e-140], t$95$0, If[LessEqual[F, 3.2e-82], (-t$95$1), If[LessEqual[F, 4e-6], t$95$0, N[(N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := F \cdot \frac{\sqrt{0.5}}{\sin B}\\
t_1 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -2.5 \cdot 10^{-7}:\\
\;\;\;\;\frac{-1}{\sin B} - t\_1\\
\mathbf{elif}\;F \leq -3.5 \cdot 10^{-140}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;F \leq 3.2 \cdot 10^{-82}:\\
\;\;\;\;-t\_1\\
\mathbf{elif}\;F \leq 4 \cdot 10^{-6}:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{\sin B} - t\_1\\
\end{array}
\end{array}
if F < -2.49999999999999989e-7Initial program 61.1%
distribute-lft-neg-in61.1%
+-commutative61.1%
associate-*l/72.6%
associate-/l*72.6%
fma-define72.6%
/-rgt-identity72.6%
remove-double-neg72.6%
fma-neg72.6%
Simplified72.7%
clear-num72.6%
inv-pow72.6%
fma-define72.6%
fma-undefine72.6%
*-commutative72.6%
fma-define72.6%
fma-define72.6%
Applied egg-rr72.6%
unpow-172.6%
Simplified72.6%
Taylor expanded in F around -inf 99.3%
if -2.49999999999999989e-7 < F < -3.4999999999999998e-140 or 3.2000000000000001e-82 < F < 3.99999999999999982e-6Initial program 99.3%
Taylor expanded in B around 0 85.0%
+-commutative85.0%
unsub-neg85.0%
Applied egg-rr85.2%
Taylor expanded in F around 0 84.8%
*-commutative84.8%
Simplified84.8%
Taylor expanded in x around 0 72.2%
associate-/l*72.4%
Simplified72.4%
if -3.4999999999999998e-140 < F < 3.2000000000000001e-82Initial program 99.4%
distribute-lft-neg-in99.4%
+-commutative99.4%
fma-define99.4%
+-commutative99.4%
*-commutative99.4%
fma-define99.4%
fma-define99.4%
metadata-eval99.4%
metadata-eval99.4%
associate-*r/99.7%
*-rgt-identity99.7%
Simplified99.7%
Taylor expanded in F around 0 75.0%
mul-1-neg75.0%
associate-/l*74.9%
Simplified74.9%
clear-num74.8%
un-div-inv75.0%
quot-tan75.1%
Applied egg-rr75.1%
if 3.99999999999999982e-6 < F Initial program 59.7%
distribute-lft-neg-in59.7%
+-commutative59.7%
associate-*l/67.7%
associate-/l*67.6%
fma-define67.6%
/-rgt-identity67.6%
remove-double-neg67.6%
fma-neg67.6%
Simplified67.6%
clear-num67.6%
inv-pow67.6%
fma-define67.6%
fma-undefine67.6%
*-commutative67.6%
fma-define67.6%
fma-define67.6%
Applied egg-rr67.6%
unpow-167.6%
Simplified67.6%
Taylor expanded in F around inf 99.8%
Final simplification88.3%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (* F (/ (sqrt 0.5) (sin B)))) (t_1 (/ x (tan B))))
(if (<= F -5e-7)
(- (/ -1.0 (sin B)) t_1)
(if (<= F -6.8e-140)
t_0
(if (<= F 6e-87)
(- t_1)
(if (<= F 4e-6)
t_0
(if (<= F 9.4e+272)
(- (/ 1.0 (sin B)) (/ x B))
(- (* F (/ 1.0 (* F B))) t_1))))))))
double code(double F, double B, double x) {
double t_0 = F * (sqrt(0.5) / sin(B));
double t_1 = x / tan(B);
double tmp;
if (F <= -5e-7) {
tmp = (-1.0 / sin(B)) - t_1;
} else if (F <= -6.8e-140) {
tmp = t_0;
} else if (F <= 6e-87) {
tmp = -t_1;
} else if (F <= 4e-6) {
tmp = t_0;
} else if (F <= 9.4e+272) {
tmp = (1.0 / sin(B)) - (x / B);
} else {
tmp = (F * (1.0 / (F * B))) - t_1;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = f * (sqrt(0.5d0) / sin(b))
t_1 = x / tan(b)
if (f <= (-5d-7)) then
tmp = ((-1.0d0) / sin(b)) - t_1
else if (f <= (-6.8d-140)) then
tmp = t_0
else if (f <= 6d-87) then
tmp = -t_1
else if (f <= 4d-6) then
tmp = t_0
else if (f <= 9.4d+272) then
tmp = (1.0d0 / sin(b)) - (x / b)
else
tmp = (f * (1.0d0 / (f * b))) - t_1
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = F * (Math.sqrt(0.5) / Math.sin(B));
double t_1 = x / Math.tan(B);
double tmp;
if (F <= -5e-7) {
tmp = (-1.0 / Math.sin(B)) - t_1;
} else if (F <= -6.8e-140) {
tmp = t_0;
} else if (F <= 6e-87) {
tmp = -t_1;
} else if (F <= 4e-6) {
tmp = t_0;
} else if (F <= 9.4e+272) {
tmp = (1.0 / Math.sin(B)) - (x / B);
} else {
tmp = (F * (1.0 / (F * B))) - t_1;
}
return tmp;
}
def code(F, B, x): t_0 = F * (math.sqrt(0.5) / math.sin(B)) t_1 = x / math.tan(B) tmp = 0 if F <= -5e-7: tmp = (-1.0 / math.sin(B)) - t_1 elif F <= -6.8e-140: tmp = t_0 elif F <= 6e-87: tmp = -t_1 elif F <= 4e-6: tmp = t_0 elif F <= 9.4e+272: tmp = (1.0 / math.sin(B)) - (x / B) else: tmp = (F * (1.0 / (F * B))) - t_1 return tmp
function code(F, B, x) t_0 = Float64(F * Float64(sqrt(0.5) / sin(B))) t_1 = Float64(x / tan(B)) tmp = 0.0 if (F <= -5e-7) tmp = Float64(Float64(-1.0 / sin(B)) - t_1); elseif (F <= -6.8e-140) tmp = t_0; elseif (F <= 6e-87) tmp = Float64(-t_1); elseif (F <= 4e-6) tmp = t_0; elseif (F <= 9.4e+272) tmp = Float64(Float64(1.0 / sin(B)) - Float64(x / B)); else tmp = Float64(Float64(F * Float64(1.0 / Float64(F * B))) - t_1); end return tmp end
function tmp_2 = code(F, B, x) t_0 = F * (sqrt(0.5) / sin(B)); t_1 = x / tan(B); tmp = 0.0; if (F <= -5e-7) tmp = (-1.0 / sin(B)) - t_1; elseif (F <= -6.8e-140) tmp = t_0; elseif (F <= 6e-87) tmp = -t_1; elseif (F <= 4e-6) tmp = t_0; elseif (F <= 9.4e+272) tmp = (1.0 / sin(B)) - (x / B); else tmp = (F * (1.0 / (F * B))) - t_1; end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(F * N[(N[Sqrt[0.5], $MachinePrecision] / N[Sin[B], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -5e-7], N[(N[(-1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision], If[LessEqual[F, -6.8e-140], t$95$0, If[LessEqual[F, 6e-87], (-t$95$1), If[LessEqual[F, 4e-6], t$95$0, If[LessEqual[F, 9.4e+272], N[(N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], N[(N[(F * N[(1.0 / N[(F * B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := F \cdot \frac{\sqrt{0.5}}{\sin B}\\
t_1 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -5 \cdot 10^{-7}:\\
\;\;\;\;\frac{-1}{\sin B} - t\_1\\
\mathbf{elif}\;F \leq -6.8 \cdot 10^{-140}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;F \leq 6 \cdot 10^{-87}:\\
\;\;\;\;-t\_1\\
\mathbf{elif}\;F \leq 4 \cdot 10^{-6}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;F \leq 9.4 \cdot 10^{+272}:\\
\;\;\;\;\frac{1}{\sin B} - \frac{x}{B}\\
\mathbf{else}:\\
\;\;\;\;F \cdot \frac{1}{F \cdot B} - t\_1\\
\end{array}
\end{array}
if F < -4.99999999999999977e-7Initial program 61.1%
distribute-lft-neg-in61.1%
+-commutative61.1%
associate-*l/72.6%
associate-/l*72.6%
fma-define72.6%
/-rgt-identity72.6%
remove-double-neg72.6%
fma-neg72.6%
Simplified72.7%
clear-num72.6%
inv-pow72.6%
fma-define72.6%
fma-undefine72.6%
*-commutative72.6%
fma-define72.6%
fma-define72.6%
Applied egg-rr72.6%
unpow-172.6%
Simplified72.6%
Taylor expanded in F around -inf 99.3%
if -4.99999999999999977e-7 < F < -6.80000000000000017e-140 or 6.00000000000000033e-87 < F < 3.99999999999999982e-6Initial program 99.3%
Taylor expanded in B around 0 85.0%
+-commutative85.0%
unsub-neg85.0%
Applied egg-rr85.2%
Taylor expanded in F around 0 84.8%
*-commutative84.8%
Simplified84.8%
Taylor expanded in x around 0 72.2%
associate-/l*72.4%
Simplified72.4%
if -6.80000000000000017e-140 < F < 6.00000000000000033e-87Initial program 99.4%
distribute-lft-neg-in99.4%
+-commutative99.4%
fma-define99.4%
+-commutative99.4%
*-commutative99.4%
fma-define99.4%
fma-define99.4%
metadata-eval99.4%
metadata-eval99.4%
associate-*r/99.7%
*-rgt-identity99.7%
Simplified99.7%
Taylor expanded in F around 0 75.0%
mul-1-neg75.0%
associate-/l*74.9%
Simplified74.9%
clear-num74.8%
un-div-inv75.0%
quot-tan75.1%
Applied egg-rr75.1%
if 3.99999999999999982e-6 < F < 9.3999999999999999e272Initial program 61.7%
Taylor expanded in B around 0 44.7%
Taylor expanded in F around inf 82.8%
if 9.3999999999999999e272 < F Initial program 50.7%
distribute-lft-neg-in50.7%
+-commutative50.7%
associate-*l/64.0%
associate-/l*64.0%
fma-define64.0%
/-rgt-identity64.0%
remove-double-neg64.0%
fma-neg64.0%
Simplified64.0%
Taylor expanded in F around inf 99.7%
Taylor expanded in B around 0 90.7%
*-commutative90.7%
Simplified90.7%
Final simplification84.9%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (- (/ F (* B (sqrt (+ 2.0 (* x 2.0))))) (/ x B)))
(t_1 (/ x (tan B))))
(if (<= F -9.6e+84)
(- (/ -1.0 B) t_1)
(if (<= F -3.1e-17)
(- (/ -1.0 (sin B)) (/ x B))
(if (<= F -3.7e-199)
t_0
(if (<= F 9.8e-113)
(- t_1)
(if (<= F 5.8e-65)
t_0
(if (<= F 2.05e-42)
(* x (/ -1.0 (tan B)))
(if (<= F 8.5e+272)
(- (/ 1.0 (sin B)) (/ x B))
(- (* F (/ 1.0 (* F B))) t_1))))))))))
double code(double F, double B, double x) {
double t_0 = (F / (B * sqrt((2.0 + (x * 2.0))))) - (x / B);
double t_1 = x / tan(B);
double tmp;
if (F <= -9.6e+84) {
tmp = (-1.0 / B) - t_1;
} else if (F <= -3.1e-17) {
tmp = (-1.0 / sin(B)) - (x / B);
} else if (F <= -3.7e-199) {
tmp = t_0;
} else if (F <= 9.8e-113) {
tmp = -t_1;
} else if (F <= 5.8e-65) {
tmp = t_0;
} else if (F <= 2.05e-42) {
tmp = x * (-1.0 / tan(B));
} else if (F <= 8.5e+272) {
tmp = (1.0 / sin(B)) - (x / B);
} else {
tmp = (F * (1.0 / (F * B))) - t_1;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = (f / (b * sqrt((2.0d0 + (x * 2.0d0))))) - (x / b)
t_1 = x / tan(b)
if (f <= (-9.6d+84)) then
tmp = ((-1.0d0) / b) - t_1
else if (f <= (-3.1d-17)) then
tmp = ((-1.0d0) / sin(b)) - (x / b)
else if (f <= (-3.7d-199)) then
tmp = t_0
else if (f <= 9.8d-113) then
tmp = -t_1
else if (f <= 5.8d-65) then
tmp = t_0
else if (f <= 2.05d-42) then
tmp = x * ((-1.0d0) / tan(b))
else if (f <= 8.5d+272) then
tmp = (1.0d0 / sin(b)) - (x / b)
else
tmp = (f * (1.0d0 / (f * b))) - t_1
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = (F / (B * Math.sqrt((2.0 + (x * 2.0))))) - (x / B);
double t_1 = x / Math.tan(B);
double tmp;
if (F <= -9.6e+84) {
tmp = (-1.0 / B) - t_1;
} else if (F <= -3.1e-17) {
tmp = (-1.0 / Math.sin(B)) - (x / B);
} else if (F <= -3.7e-199) {
tmp = t_0;
} else if (F <= 9.8e-113) {
tmp = -t_1;
} else if (F <= 5.8e-65) {
tmp = t_0;
} else if (F <= 2.05e-42) {
tmp = x * (-1.0 / Math.tan(B));
} else if (F <= 8.5e+272) {
tmp = (1.0 / Math.sin(B)) - (x / B);
} else {
tmp = (F * (1.0 / (F * B))) - t_1;
}
return tmp;
}
def code(F, B, x): t_0 = (F / (B * math.sqrt((2.0 + (x * 2.0))))) - (x / B) t_1 = x / math.tan(B) tmp = 0 if F <= -9.6e+84: tmp = (-1.0 / B) - t_1 elif F <= -3.1e-17: tmp = (-1.0 / math.sin(B)) - (x / B) elif F <= -3.7e-199: tmp = t_0 elif F <= 9.8e-113: tmp = -t_1 elif F <= 5.8e-65: tmp = t_0 elif F <= 2.05e-42: tmp = x * (-1.0 / math.tan(B)) elif F <= 8.5e+272: tmp = (1.0 / math.sin(B)) - (x / B) else: tmp = (F * (1.0 / (F * B))) - t_1 return tmp
function code(F, B, x) t_0 = Float64(Float64(F / Float64(B * sqrt(Float64(2.0 + Float64(x * 2.0))))) - Float64(x / B)) t_1 = Float64(x / tan(B)) tmp = 0.0 if (F <= -9.6e+84) tmp = Float64(Float64(-1.0 / B) - t_1); elseif (F <= -3.1e-17) tmp = Float64(Float64(-1.0 / sin(B)) - Float64(x / B)); elseif (F <= -3.7e-199) tmp = t_0; elseif (F <= 9.8e-113) tmp = Float64(-t_1); elseif (F <= 5.8e-65) tmp = t_0; elseif (F <= 2.05e-42) tmp = Float64(x * Float64(-1.0 / tan(B))); elseif (F <= 8.5e+272) tmp = Float64(Float64(1.0 / sin(B)) - Float64(x / B)); else tmp = Float64(Float64(F * Float64(1.0 / Float64(F * B))) - t_1); end return tmp end
function tmp_2 = code(F, B, x) t_0 = (F / (B * sqrt((2.0 + (x * 2.0))))) - (x / B); t_1 = x / tan(B); tmp = 0.0; if (F <= -9.6e+84) tmp = (-1.0 / B) - t_1; elseif (F <= -3.1e-17) tmp = (-1.0 / sin(B)) - (x / B); elseif (F <= -3.7e-199) tmp = t_0; elseif (F <= 9.8e-113) tmp = -t_1; elseif (F <= 5.8e-65) tmp = t_0; elseif (F <= 2.05e-42) tmp = x * (-1.0 / tan(B)); elseif (F <= 8.5e+272) tmp = (1.0 / sin(B)) - (x / B); else tmp = (F * (1.0 / (F * B))) - t_1; end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(N[(F / N[(B * N[Sqrt[N[(2.0 + N[(x * 2.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -9.6e+84], N[(N[(-1.0 / B), $MachinePrecision] - t$95$1), $MachinePrecision], If[LessEqual[F, -3.1e-17], N[(N[(-1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, -3.7e-199], t$95$0, If[LessEqual[F, 9.8e-113], (-t$95$1), If[LessEqual[F, 5.8e-65], t$95$0, If[LessEqual[F, 2.05e-42], N[(x * N[(-1.0 / N[Tan[B], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, 8.5e+272], N[(N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], N[(N[(F * N[(1.0 / N[(F * B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{F}{B \cdot \sqrt{2 + x \cdot 2}} - \frac{x}{B}\\
t_1 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -9.6 \cdot 10^{+84}:\\
\;\;\;\;\frac{-1}{B} - t\_1\\
\mathbf{elif}\;F \leq -3.1 \cdot 10^{-17}:\\
\;\;\;\;\frac{-1}{\sin B} - \frac{x}{B}\\
\mathbf{elif}\;F \leq -3.7 \cdot 10^{-199}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;F \leq 9.8 \cdot 10^{-113}:\\
\;\;\;\;-t\_1\\
\mathbf{elif}\;F \leq 5.8 \cdot 10^{-65}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;F \leq 2.05 \cdot 10^{-42}:\\
\;\;\;\;x \cdot \frac{-1}{\tan B}\\
\mathbf{elif}\;F \leq 8.5 \cdot 10^{+272}:\\
\;\;\;\;\frac{1}{\sin B} - \frac{x}{B}\\
\mathbf{else}:\\
\;\;\;\;F \cdot \frac{1}{F \cdot B} - t\_1\\
\end{array}
\end{array}
if F < -9.5999999999999999e84Initial program 50.9%
distribute-lft-neg-in50.9%
+-commutative50.9%
associate-*l/64.5%
associate-/l*64.5%
fma-define64.5%
/-rgt-identity64.5%
remove-double-neg64.5%
fma-neg64.5%
Simplified64.5%
clear-num64.6%
inv-pow64.6%
fma-define64.6%
fma-undefine64.6%
*-commutative64.6%
fma-define64.6%
fma-define64.6%
Applied egg-rr64.6%
unpow-164.6%
Simplified64.6%
Taylor expanded in F around -inf 99.7%
Taylor expanded in B around 0 80.9%
if -9.5999999999999999e84 < F < -3.0999999999999998e-17Initial program 95.5%
Taylor expanded in B around 0 83.0%
Taylor expanded in F around -inf 77.5%
distribute-lft-in77.5%
mul-1-neg77.5%
unsub-neg77.5%
neg-mul-177.5%
distribute-neg-frac77.5%
metadata-eval77.5%
Simplified77.5%
if -3.0999999999999998e-17 < F < -3.69999999999999999e-199 or 9.8000000000000006e-113 < F < 5.7999999999999996e-65Initial program 99.4%
Taylor expanded in B around 0 87.2%
+-commutative87.2%
unsub-neg87.2%
Applied egg-rr87.2%
Taylor expanded in F around 0 87.2%
*-commutative87.2%
Simplified87.2%
Taylor expanded in B around 0 73.2%
if -3.69999999999999999e-199 < F < 9.8000000000000006e-113Initial program 99.4%
distribute-lft-neg-in99.4%
+-commutative99.4%
fma-define99.4%
+-commutative99.4%
*-commutative99.4%
fma-define99.4%
fma-define99.4%
metadata-eval99.4%
metadata-eval99.4%
associate-*r/99.6%
*-rgt-identity99.6%
Simplified99.6%
Taylor expanded in F around 0 74.3%
mul-1-neg74.3%
associate-/l*74.2%
Simplified74.2%
clear-num74.2%
un-div-inv74.3%
quot-tan74.4%
Applied egg-rr74.4%
if 5.7999999999999996e-65 < F < 2.0500000000000001e-42Initial program 99.7%
distribute-lft-neg-in99.7%
+-commutative99.7%
fma-define99.7%
+-commutative99.7%
*-commutative99.7%
fma-define99.7%
fma-define99.7%
metadata-eval99.7%
metadata-eval99.7%
associate-*r/99.1%
*-rgt-identity99.1%
Simplified99.1%
Taylor expanded in F around 0 60.9%
mul-1-neg60.9%
associate-/l*61.5%
Simplified61.5%
*-un-lft-identity61.5%
clear-num60.9%
quot-tan61.5%
Applied egg-rr61.5%
*-lft-identity61.5%
Simplified61.5%
if 2.0500000000000001e-42 < F < 8.49999999999999996e272Initial program 67.8%
Taylor expanded in B around 0 53.6%
Taylor expanded in F around inf 74.1%
if 8.49999999999999996e272 < F Initial program 50.7%
distribute-lft-neg-in50.7%
+-commutative50.7%
associate-*l/64.0%
associate-/l*64.0%
fma-define64.0%
/-rgt-identity64.0%
remove-double-neg64.0%
fma-neg64.0%
Simplified64.0%
Taylor expanded in F around inf 99.7%
Taylor expanded in B around 0 90.7%
*-commutative90.7%
Simplified90.7%
Final simplification76.5%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (/ (- (* F (sqrt (/ 1.0 (+ 2.0 (* x 2.0))))) x) B))
(t_1 (/ x (tan B))))
(if (<= F -1.05e+85)
(- (/ -1.0 B) t_1)
(if (<= F -3.1e-17)
(- (/ -1.0 (sin B)) (/ x B))
(if (<= F -2.2e-198)
t_0
(if (<= F 1.45e-112)
(- t_1)
(if (<= F 1.5e-63)
t_0
(if (<= F 2.05e-42)
(* x (/ -1.0 (tan B)))
(if (<= F 1.75e+273)
(- (/ 1.0 (sin B)) (/ x B))
(- (* F (/ 1.0 (* F B))) t_1))))))))))
double code(double F, double B, double x) {
double t_0 = ((F * sqrt((1.0 / (2.0 + (x * 2.0))))) - x) / B;
double t_1 = x / tan(B);
double tmp;
if (F <= -1.05e+85) {
tmp = (-1.0 / B) - t_1;
} else if (F <= -3.1e-17) {
tmp = (-1.0 / sin(B)) - (x / B);
} else if (F <= -2.2e-198) {
tmp = t_0;
} else if (F <= 1.45e-112) {
tmp = -t_1;
} else if (F <= 1.5e-63) {
tmp = t_0;
} else if (F <= 2.05e-42) {
tmp = x * (-1.0 / tan(B));
} else if (F <= 1.75e+273) {
tmp = (1.0 / sin(B)) - (x / B);
} else {
tmp = (F * (1.0 / (F * B))) - t_1;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = ((f * sqrt((1.0d0 / (2.0d0 + (x * 2.0d0))))) - x) / b
t_1 = x / tan(b)
if (f <= (-1.05d+85)) then
tmp = ((-1.0d0) / b) - t_1
else if (f <= (-3.1d-17)) then
tmp = ((-1.0d0) / sin(b)) - (x / b)
else if (f <= (-2.2d-198)) then
tmp = t_0
else if (f <= 1.45d-112) then
tmp = -t_1
else if (f <= 1.5d-63) then
tmp = t_0
else if (f <= 2.05d-42) then
tmp = x * ((-1.0d0) / tan(b))
else if (f <= 1.75d+273) then
tmp = (1.0d0 / sin(b)) - (x / b)
else
tmp = (f * (1.0d0 / (f * b))) - t_1
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = ((F * Math.sqrt((1.0 / (2.0 + (x * 2.0))))) - x) / B;
double t_1 = x / Math.tan(B);
double tmp;
if (F <= -1.05e+85) {
tmp = (-1.0 / B) - t_1;
} else if (F <= -3.1e-17) {
tmp = (-1.0 / Math.sin(B)) - (x / B);
} else if (F <= -2.2e-198) {
tmp = t_0;
} else if (F <= 1.45e-112) {
tmp = -t_1;
} else if (F <= 1.5e-63) {
tmp = t_0;
} else if (F <= 2.05e-42) {
tmp = x * (-1.0 / Math.tan(B));
} else if (F <= 1.75e+273) {
tmp = (1.0 / Math.sin(B)) - (x / B);
} else {
tmp = (F * (1.0 / (F * B))) - t_1;
}
return tmp;
}
def code(F, B, x): t_0 = ((F * math.sqrt((1.0 / (2.0 + (x * 2.0))))) - x) / B t_1 = x / math.tan(B) tmp = 0 if F <= -1.05e+85: tmp = (-1.0 / B) - t_1 elif F <= -3.1e-17: tmp = (-1.0 / math.sin(B)) - (x / B) elif F <= -2.2e-198: tmp = t_0 elif F <= 1.45e-112: tmp = -t_1 elif F <= 1.5e-63: tmp = t_0 elif F <= 2.05e-42: tmp = x * (-1.0 / math.tan(B)) elif F <= 1.75e+273: tmp = (1.0 / math.sin(B)) - (x / B) else: tmp = (F * (1.0 / (F * B))) - t_1 return tmp
function code(F, B, x) t_0 = Float64(Float64(Float64(F * sqrt(Float64(1.0 / Float64(2.0 + Float64(x * 2.0))))) - x) / B) t_1 = Float64(x / tan(B)) tmp = 0.0 if (F <= -1.05e+85) tmp = Float64(Float64(-1.0 / B) - t_1); elseif (F <= -3.1e-17) tmp = Float64(Float64(-1.0 / sin(B)) - Float64(x / B)); elseif (F <= -2.2e-198) tmp = t_0; elseif (F <= 1.45e-112) tmp = Float64(-t_1); elseif (F <= 1.5e-63) tmp = t_0; elseif (F <= 2.05e-42) tmp = Float64(x * Float64(-1.0 / tan(B))); elseif (F <= 1.75e+273) tmp = Float64(Float64(1.0 / sin(B)) - Float64(x / B)); else tmp = Float64(Float64(F * Float64(1.0 / Float64(F * B))) - t_1); end return tmp end
function tmp_2 = code(F, B, x) t_0 = ((F * sqrt((1.0 / (2.0 + (x * 2.0))))) - x) / B; t_1 = x / tan(B); tmp = 0.0; if (F <= -1.05e+85) tmp = (-1.0 / B) - t_1; elseif (F <= -3.1e-17) tmp = (-1.0 / sin(B)) - (x / B); elseif (F <= -2.2e-198) tmp = t_0; elseif (F <= 1.45e-112) tmp = -t_1; elseif (F <= 1.5e-63) tmp = t_0; elseif (F <= 2.05e-42) tmp = x * (-1.0 / tan(B)); elseif (F <= 1.75e+273) tmp = (1.0 / sin(B)) - (x / B); else tmp = (F * (1.0 / (F * B))) - t_1; end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(N[(N[(F * N[Sqrt[N[(1.0 / N[(2.0 + N[(x * 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision] / B), $MachinePrecision]}, Block[{t$95$1 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -1.05e+85], N[(N[(-1.0 / B), $MachinePrecision] - t$95$1), $MachinePrecision], If[LessEqual[F, -3.1e-17], N[(N[(-1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, -2.2e-198], t$95$0, If[LessEqual[F, 1.45e-112], (-t$95$1), If[LessEqual[F, 1.5e-63], t$95$0, If[LessEqual[F, 2.05e-42], N[(x * N[(-1.0 / N[Tan[B], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, 1.75e+273], N[(N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], N[(N[(F * N[(1.0 / N[(F * B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{F \cdot \sqrt{\frac{1}{2 + x \cdot 2}} - x}{B}\\
t_1 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -1.05 \cdot 10^{+85}:\\
\;\;\;\;\frac{-1}{B} - t\_1\\
\mathbf{elif}\;F \leq -3.1 \cdot 10^{-17}:\\
\;\;\;\;\frac{-1}{\sin B} - \frac{x}{B}\\
\mathbf{elif}\;F \leq -2.2 \cdot 10^{-198}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;F \leq 1.45 \cdot 10^{-112}:\\
\;\;\;\;-t\_1\\
\mathbf{elif}\;F \leq 1.5 \cdot 10^{-63}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;F \leq 2.05 \cdot 10^{-42}:\\
\;\;\;\;x \cdot \frac{-1}{\tan B}\\
\mathbf{elif}\;F \leq 1.75 \cdot 10^{+273}:\\
\;\;\;\;\frac{1}{\sin B} - \frac{x}{B}\\
\mathbf{else}:\\
\;\;\;\;F \cdot \frac{1}{F \cdot B} - t\_1\\
\end{array}
\end{array}
if F < -1.05000000000000005e85Initial program 50.9%
distribute-lft-neg-in50.9%
+-commutative50.9%
associate-*l/64.5%
associate-/l*64.5%
fma-define64.5%
/-rgt-identity64.5%
remove-double-neg64.5%
fma-neg64.5%
Simplified64.5%
clear-num64.6%
inv-pow64.6%
fma-define64.6%
fma-undefine64.6%
*-commutative64.6%
fma-define64.6%
fma-define64.6%
Applied egg-rr64.6%
unpow-164.6%
Simplified64.6%
Taylor expanded in F around -inf 99.7%
Taylor expanded in B around 0 80.9%
if -1.05000000000000005e85 < F < -3.0999999999999998e-17Initial program 95.5%
Taylor expanded in B around 0 83.0%
Taylor expanded in F around -inf 77.5%
distribute-lft-in77.5%
mul-1-neg77.5%
unsub-neg77.5%
neg-mul-177.5%
distribute-neg-frac77.5%
metadata-eval77.5%
Simplified77.5%
if -3.0999999999999998e-17 < F < -2.2e-198 or 1.44999999999999996e-112 < F < 1.4999999999999999e-63Initial program 99.4%
Taylor expanded in B around 0 87.2%
+-commutative87.2%
unsub-neg87.2%
Applied egg-rr87.2%
Taylor expanded in F around 0 87.2%
*-commutative87.2%
Simplified87.2%
Taylor expanded in B around 0 73.3%
if -2.2e-198 < F < 1.44999999999999996e-112Initial program 99.4%
distribute-lft-neg-in99.4%
+-commutative99.4%
fma-define99.4%
+-commutative99.4%
*-commutative99.4%
fma-define99.4%
fma-define99.4%
metadata-eval99.4%
metadata-eval99.4%
associate-*r/99.6%
*-rgt-identity99.6%
Simplified99.6%
Taylor expanded in F around 0 74.3%
mul-1-neg74.3%
associate-/l*74.2%
Simplified74.2%
clear-num74.2%
un-div-inv74.3%
quot-tan74.4%
Applied egg-rr74.4%
if 1.4999999999999999e-63 < F < 2.0500000000000001e-42Initial program 99.7%
distribute-lft-neg-in99.7%
+-commutative99.7%
fma-define99.7%
+-commutative99.7%
*-commutative99.7%
fma-define99.7%
fma-define99.7%
metadata-eval99.7%
metadata-eval99.7%
associate-*r/99.1%
*-rgt-identity99.1%
Simplified99.1%
Taylor expanded in F around 0 60.9%
mul-1-neg60.9%
associate-/l*61.5%
Simplified61.5%
*-un-lft-identity61.5%
clear-num60.9%
quot-tan61.5%
Applied egg-rr61.5%
*-lft-identity61.5%
Simplified61.5%
if 2.0500000000000001e-42 < F < 1.75000000000000005e273Initial program 67.8%
Taylor expanded in B around 0 53.6%
Taylor expanded in F around inf 74.1%
if 1.75000000000000005e273 < F Initial program 50.7%
distribute-lft-neg-in50.7%
+-commutative50.7%
associate-*l/64.0%
associate-/l*64.0%
fma-define64.0%
/-rgt-identity64.0%
remove-double-neg64.0%
fma-neg64.0%
Simplified64.0%
Taylor expanded in F around inf 99.7%
Taylor expanded in B around 0 90.7%
*-commutative90.7%
Simplified90.7%
Final simplification76.5%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (sqrt (/ 1.0 (+ 2.0 (* x 2.0))))) (t_1 (/ x (tan B))))
(if (<= F -1.05e+85)
(- (/ -1.0 B) t_1)
(if (<= F -3.1e-17)
(- (/ -1.0 (sin B)) (/ x B))
(if (<= F -3.5e-200)
(- (* t_0 (/ F B)) (/ x B))
(if (<= F 1.3e-112)
(- t_1)
(if (<= F 2.8e-64)
(/ (- (* F t_0) x) B)
(if (<= F 2.05e-42)
(* x (/ -1.0 (tan B)))
(if (<= F 1.04e+273)
(- (/ 1.0 (sin B)) (/ x B))
(- (* F (/ 1.0 (* F B))) t_1))))))))))
double code(double F, double B, double x) {
double t_0 = sqrt((1.0 / (2.0 + (x * 2.0))));
double t_1 = x / tan(B);
double tmp;
if (F <= -1.05e+85) {
tmp = (-1.0 / B) - t_1;
} else if (F <= -3.1e-17) {
tmp = (-1.0 / sin(B)) - (x / B);
} else if (F <= -3.5e-200) {
tmp = (t_0 * (F / B)) - (x / B);
} else if (F <= 1.3e-112) {
tmp = -t_1;
} else if (F <= 2.8e-64) {
tmp = ((F * t_0) - x) / B;
} else if (F <= 2.05e-42) {
tmp = x * (-1.0 / tan(B));
} else if (F <= 1.04e+273) {
tmp = (1.0 / sin(B)) - (x / B);
} else {
tmp = (F * (1.0 / (F * B))) - t_1;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = sqrt((1.0d0 / (2.0d0 + (x * 2.0d0))))
t_1 = x / tan(b)
if (f <= (-1.05d+85)) then
tmp = ((-1.0d0) / b) - t_1
else if (f <= (-3.1d-17)) then
tmp = ((-1.0d0) / sin(b)) - (x / b)
else if (f <= (-3.5d-200)) then
tmp = (t_0 * (f / b)) - (x / b)
else if (f <= 1.3d-112) then
tmp = -t_1
else if (f <= 2.8d-64) then
tmp = ((f * t_0) - x) / b
else if (f <= 2.05d-42) then
tmp = x * ((-1.0d0) / tan(b))
else if (f <= 1.04d+273) then
tmp = (1.0d0 / sin(b)) - (x / b)
else
tmp = (f * (1.0d0 / (f * b))) - t_1
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = Math.sqrt((1.0 / (2.0 + (x * 2.0))));
double t_1 = x / Math.tan(B);
double tmp;
if (F <= -1.05e+85) {
tmp = (-1.0 / B) - t_1;
} else if (F <= -3.1e-17) {
tmp = (-1.0 / Math.sin(B)) - (x / B);
} else if (F <= -3.5e-200) {
tmp = (t_0 * (F / B)) - (x / B);
} else if (F <= 1.3e-112) {
tmp = -t_1;
} else if (F <= 2.8e-64) {
tmp = ((F * t_0) - x) / B;
} else if (F <= 2.05e-42) {
tmp = x * (-1.0 / Math.tan(B));
} else if (F <= 1.04e+273) {
tmp = (1.0 / Math.sin(B)) - (x / B);
} else {
tmp = (F * (1.0 / (F * B))) - t_1;
}
return tmp;
}
def code(F, B, x): t_0 = math.sqrt((1.0 / (2.0 + (x * 2.0)))) t_1 = x / math.tan(B) tmp = 0 if F <= -1.05e+85: tmp = (-1.0 / B) - t_1 elif F <= -3.1e-17: tmp = (-1.0 / math.sin(B)) - (x / B) elif F <= -3.5e-200: tmp = (t_0 * (F / B)) - (x / B) elif F <= 1.3e-112: tmp = -t_1 elif F <= 2.8e-64: tmp = ((F * t_0) - x) / B elif F <= 2.05e-42: tmp = x * (-1.0 / math.tan(B)) elif F <= 1.04e+273: tmp = (1.0 / math.sin(B)) - (x / B) else: tmp = (F * (1.0 / (F * B))) - t_1 return tmp
function code(F, B, x) t_0 = sqrt(Float64(1.0 / Float64(2.0 + Float64(x * 2.0)))) t_1 = Float64(x / tan(B)) tmp = 0.0 if (F <= -1.05e+85) tmp = Float64(Float64(-1.0 / B) - t_1); elseif (F <= -3.1e-17) tmp = Float64(Float64(-1.0 / sin(B)) - Float64(x / B)); elseif (F <= -3.5e-200) tmp = Float64(Float64(t_0 * Float64(F / B)) - Float64(x / B)); elseif (F <= 1.3e-112) tmp = Float64(-t_1); elseif (F <= 2.8e-64) tmp = Float64(Float64(Float64(F * t_0) - x) / B); elseif (F <= 2.05e-42) tmp = Float64(x * Float64(-1.0 / tan(B))); elseif (F <= 1.04e+273) tmp = Float64(Float64(1.0 / sin(B)) - Float64(x / B)); else tmp = Float64(Float64(F * Float64(1.0 / Float64(F * B))) - t_1); end return tmp end
function tmp_2 = code(F, B, x) t_0 = sqrt((1.0 / (2.0 + (x * 2.0)))); t_1 = x / tan(B); tmp = 0.0; if (F <= -1.05e+85) tmp = (-1.0 / B) - t_1; elseif (F <= -3.1e-17) tmp = (-1.0 / sin(B)) - (x / B); elseif (F <= -3.5e-200) tmp = (t_0 * (F / B)) - (x / B); elseif (F <= 1.3e-112) tmp = -t_1; elseif (F <= 2.8e-64) tmp = ((F * t_0) - x) / B; elseif (F <= 2.05e-42) tmp = x * (-1.0 / tan(B)); elseif (F <= 1.04e+273) tmp = (1.0 / sin(B)) - (x / B); else tmp = (F * (1.0 / (F * B))) - t_1; end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[Sqrt[N[(1.0 / N[(2.0 + N[(x * 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$1 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -1.05e+85], N[(N[(-1.0 / B), $MachinePrecision] - t$95$1), $MachinePrecision], If[LessEqual[F, -3.1e-17], N[(N[(-1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, -3.5e-200], N[(N[(t$95$0 * N[(F / B), $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, 1.3e-112], (-t$95$1), If[LessEqual[F, 2.8e-64], N[(N[(N[(F * t$95$0), $MachinePrecision] - x), $MachinePrecision] / B), $MachinePrecision], If[LessEqual[F, 2.05e-42], N[(x * N[(-1.0 / N[Tan[B], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, 1.04e+273], N[(N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], N[(N[(F * N[(1.0 / N[(F * B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \sqrt{\frac{1}{2 + x \cdot 2}}\\
t_1 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -1.05 \cdot 10^{+85}:\\
\;\;\;\;\frac{-1}{B} - t\_1\\
\mathbf{elif}\;F \leq -3.1 \cdot 10^{-17}:\\
\;\;\;\;\frac{-1}{\sin B} - \frac{x}{B}\\
\mathbf{elif}\;F \leq -3.5 \cdot 10^{-200}:\\
\;\;\;\;t\_0 \cdot \frac{F}{B} - \frac{x}{B}\\
\mathbf{elif}\;F \leq 1.3 \cdot 10^{-112}:\\
\;\;\;\;-t\_1\\
\mathbf{elif}\;F \leq 2.8 \cdot 10^{-64}:\\
\;\;\;\;\frac{F \cdot t\_0 - x}{B}\\
\mathbf{elif}\;F \leq 2.05 \cdot 10^{-42}:\\
\;\;\;\;x \cdot \frac{-1}{\tan B}\\
\mathbf{elif}\;F \leq 1.04 \cdot 10^{+273}:\\
\;\;\;\;\frac{1}{\sin B} - \frac{x}{B}\\
\mathbf{else}:\\
\;\;\;\;F \cdot \frac{1}{F \cdot B} - t\_1\\
\end{array}
\end{array}
if F < -1.05000000000000005e85Initial program 50.9%
distribute-lft-neg-in50.9%
+-commutative50.9%
associate-*l/64.5%
associate-/l*64.5%
fma-define64.5%
/-rgt-identity64.5%
remove-double-neg64.5%
fma-neg64.5%
Simplified64.5%
clear-num64.6%
inv-pow64.6%
fma-define64.6%
fma-undefine64.6%
*-commutative64.6%
fma-define64.6%
fma-define64.6%
Applied egg-rr64.6%
unpow-164.6%
Simplified64.6%
Taylor expanded in F around -inf 99.7%
Taylor expanded in B around 0 80.9%
if -1.05000000000000005e85 < F < -3.0999999999999998e-17Initial program 95.5%
Taylor expanded in B around 0 83.0%
Taylor expanded in F around -inf 77.5%
distribute-lft-in77.5%
mul-1-neg77.5%
unsub-neg77.5%
neg-mul-177.5%
distribute-neg-frac77.5%
metadata-eval77.5%
Simplified77.5%
if -3.0999999999999998e-17 < F < -3.50000000000000023e-200Initial program 99.4%
Taylor expanded in B around 0 83.5%
+-commutative83.5%
unsub-neg83.5%
Applied egg-rr83.4%
Taylor expanded in F around 0 83.4%
*-commutative83.4%
Simplified83.4%
Taylor expanded in B around 0 65.3%
if -3.50000000000000023e-200 < F < 1.29999999999999996e-112Initial program 99.4%
distribute-lft-neg-in99.4%
+-commutative99.4%
fma-define99.4%
+-commutative99.4%
*-commutative99.4%
fma-define99.4%
fma-define99.4%
metadata-eval99.4%
metadata-eval99.4%
associate-*r/99.6%
*-rgt-identity99.6%
Simplified99.6%
Taylor expanded in F around 0 74.3%
mul-1-neg74.3%
associate-/l*74.2%
Simplified74.2%
clear-num74.2%
un-div-inv74.3%
quot-tan74.4%
Applied egg-rr74.4%
if 1.29999999999999996e-112 < F < 2.80000000000000004e-64Initial program 99.3%
Taylor expanded in B around 0 99.6%
+-commutative99.6%
unsub-neg99.6%
Applied egg-rr99.6%
Taylor expanded in F around 0 99.6%
*-commutative99.6%
Simplified99.6%
Taylor expanded in B around 0 99.7%
if 2.80000000000000004e-64 < F < 2.0500000000000001e-42Initial program 99.7%
distribute-lft-neg-in99.7%
+-commutative99.7%
fma-define99.7%
+-commutative99.7%
*-commutative99.7%
fma-define99.7%
fma-define99.7%
metadata-eval99.7%
metadata-eval99.7%
associate-*r/99.1%
*-rgt-identity99.1%
Simplified99.1%
Taylor expanded in F around 0 60.9%
mul-1-neg60.9%
associate-/l*61.5%
Simplified61.5%
*-un-lft-identity61.5%
clear-num60.9%
quot-tan61.5%
Applied egg-rr61.5%
*-lft-identity61.5%
Simplified61.5%
if 2.0500000000000001e-42 < F < 1.04e273Initial program 67.8%
Taylor expanded in B around 0 53.6%
Taylor expanded in F around inf 74.1%
if 1.04e273 < F Initial program 50.7%
distribute-lft-neg-in50.7%
+-commutative50.7%
associate-*l/64.0%
associate-/l*64.0%
fma-define64.0%
/-rgt-identity64.0%
remove-double-neg64.0%
fma-neg64.0%
Simplified64.0%
Taylor expanded in F around inf 99.7%
Taylor expanded in B around 0 90.7%
*-commutative90.7%
Simplified90.7%
Final simplification76.5%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (+ 2.0 (* x 2.0))) (t_1 (sqrt (/ 1.0 t_0))) (t_2 (/ x (tan B))))
(if (<= F -6.2e+84)
(- (/ -1.0 B) t_2)
(if (<= F -3.1e-17)
(- (/ F (* (sin B) (- (* -0.5 (/ t_0 F)) F))) (/ x B))
(if (<= F -7e-198)
(- (* t_1 (/ F B)) (/ x B))
(if (<= F 1.02e-112)
(- t_2)
(if (<= F 1.65e-63)
(/ (- (* F t_1) x) B)
(if (<= F 2.05e-42)
(* x (/ -1.0 (tan B)))
(if (<= F 1.3e+273)
(- (/ 1.0 (sin B)) (/ x B))
(- (* F (/ 1.0 (* F B))) t_2))))))))))
double code(double F, double B, double x) {
double t_0 = 2.0 + (x * 2.0);
double t_1 = sqrt((1.0 / t_0));
double t_2 = x / tan(B);
double tmp;
if (F <= -6.2e+84) {
tmp = (-1.0 / B) - t_2;
} else if (F <= -3.1e-17) {
tmp = (F / (sin(B) * ((-0.5 * (t_0 / F)) - F))) - (x / B);
} else if (F <= -7e-198) {
tmp = (t_1 * (F / B)) - (x / B);
} else if (F <= 1.02e-112) {
tmp = -t_2;
} else if (F <= 1.65e-63) {
tmp = ((F * t_1) - x) / B;
} else if (F <= 2.05e-42) {
tmp = x * (-1.0 / tan(B));
} else if (F <= 1.3e+273) {
tmp = (1.0 / sin(B)) - (x / B);
} else {
tmp = (F * (1.0 / (F * B))) - t_2;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_0 = 2.0d0 + (x * 2.0d0)
t_1 = sqrt((1.0d0 / t_0))
t_2 = x / tan(b)
if (f <= (-6.2d+84)) then
tmp = ((-1.0d0) / b) - t_2
else if (f <= (-3.1d-17)) then
tmp = (f / (sin(b) * (((-0.5d0) * (t_0 / f)) - f))) - (x / b)
else if (f <= (-7d-198)) then
tmp = (t_1 * (f / b)) - (x / b)
else if (f <= 1.02d-112) then
tmp = -t_2
else if (f <= 1.65d-63) then
tmp = ((f * t_1) - x) / b
else if (f <= 2.05d-42) then
tmp = x * ((-1.0d0) / tan(b))
else if (f <= 1.3d+273) then
tmp = (1.0d0 / sin(b)) - (x / b)
else
tmp = (f * (1.0d0 / (f * b))) - t_2
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = 2.0 + (x * 2.0);
double t_1 = Math.sqrt((1.0 / t_0));
double t_2 = x / Math.tan(B);
double tmp;
if (F <= -6.2e+84) {
tmp = (-1.0 / B) - t_2;
} else if (F <= -3.1e-17) {
tmp = (F / (Math.sin(B) * ((-0.5 * (t_0 / F)) - F))) - (x / B);
} else if (F <= -7e-198) {
tmp = (t_1 * (F / B)) - (x / B);
} else if (F <= 1.02e-112) {
tmp = -t_2;
} else if (F <= 1.65e-63) {
tmp = ((F * t_1) - x) / B;
} else if (F <= 2.05e-42) {
tmp = x * (-1.0 / Math.tan(B));
} else if (F <= 1.3e+273) {
tmp = (1.0 / Math.sin(B)) - (x / B);
} else {
tmp = (F * (1.0 / (F * B))) - t_2;
}
return tmp;
}
def code(F, B, x): t_0 = 2.0 + (x * 2.0) t_1 = math.sqrt((1.0 / t_0)) t_2 = x / math.tan(B) tmp = 0 if F <= -6.2e+84: tmp = (-1.0 / B) - t_2 elif F <= -3.1e-17: tmp = (F / (math.sin(B) * ((-0.5 * (t_0 / F)) - F))) - (x / B) elif F <= -7e-198: tmp = (t_1 * (F / B)) - (x / B) elif F <= 1.02e-112: tmp = -t_2 elif F <= 1.65e-63: tmp = ((F * t_1) - x) / B elif F <= 2.05e-42: tmp = x * (-1.0 / math.tan(B)) elif F <= 1.3e+273: tmp = (1.0 / math.sin(B)) - (x / B) else: tmp = (F * (1.0 / (F * B))) - t_2 return tmp
function code(F, B, x) t_0 = Float64(2.0 + Float64(x * 2.0)) t_1 = sqrt(Float64(1.0 / t_0)) t_2 = Float64(x / tan(B)) tmp = 0.0 if (F <= -6.2e+84) tmp = Float64(Float64(-1.0 / B) - t_2); elseif (F <= -3.1e-17) tmp = Float64(Float64(F / Float64(sin(B) * Float64(Float64(-0.5 * Float64(t_0 / F)) - F))) - Float64(x / B)); elseif (F <= -7e-198) tmp = Float64(Float64(t_1 * Float64(F / B)) - Float64(x / B)); elseif (F <= 1.02e-112) tmp = Float64(-t_2); elseif (F <= 1.65e-63) tmp = Float64(Float64(Float64(F * t_1) - x) / B); elseif (F <= 2.05e-42) tmp = Float64(x * Float64(-1.0 / tan(B))); elseif (F <= 1.3e+273) tmp = Float64(Float64(1.0 / sin(B)) - Float64(x / B)); else tmp = Float64(Float64(F * Float64(1.0 / Float64(F * B))) - t_2); end return tmp end
function tmp_2 = code(F, B, x) t_0 = 2.0 + (x * 2.0); t_1 = sqrt((1.0 / t_0)); t_2 = x / tan(B); tmp = 0.0; if (F <= -6.2e+84) tmp = (-1.0 / B) - t_2; elseif (F <= -3.1e-17) tmp = (F / (sin(B) * ((-0.5 * (t_0 / F)) - F))) - (x / B); elseif (F <= -7e-198) tmp = (t_1 * (F / B)) - (x / B); elseif (F <= 1.02e-112) tmp = -t_2; elseif (F <= 1.65e-63) tmp = ((F * t_1) - x) / B; elseif (F <= 2.05e-42) tmp = x * (-1.0 / tan(B)); elseif (F <= 1.3e+273) tmp = (1.0 / sin(B)) - (x / B); else tmp = (F * (1.0 / (F * B))) - t_2; end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(2.0 + N[(x * 2.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[Sqrt[N[(1.0 / t$95$0), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$2 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -6.2e+84], N[(N[(-1.0 / B), $MachinePrecision] - t$95$2), $MachinePrecision], If[LessEqual[F, -3.1e-17], N[(N[(F / N[(N[Sin[B], $MachinePrecision] * N[(N[(-0.5 * N[(t$95$0 / F), $MachinePrecision]), $MachinePrecision] - F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, -7e-198], N[(N[(t$95$1 * N[(F / B), $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, 1.02e-112], (-t$95$2), If[LessEqual[F, 1.65e-63], N[(N[(N[(F * t$95$1), $MachinePrecision] - x), $MachinePrecision] / B), $MachinePrecision], If[LessEqual[F, 2.05e-42], N[(x * N[(-1.0 / N[Tan[B], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, 1.3e+273], N[(N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], N[(N[(F * N[(1.0 / N[(F * B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$2), $MachinePrecision]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 2 + x \cdot 2\\
t_1 := \sqrt{\frac{1}{t\_0}}\\
t_2 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -6.2 \cdot 10^{+84}:\\
\;\;\;\;\frac{-1}{B} - t\_2\\
\mathbf{elif}\;F \leq -3.1 \cdot 10^{-17}:\\
\;\;\;\;\frac{F}{\sin B \cdot \left(-0.5 \cdot \frac{t\_0}{F} - F\right)} - \frac{x}{B}\\
\mathbf{elif}\;F \leq -7 \cdot 10^{-198}:\\
\;\;\;\;t\_1 \cdot \frac{F}{B} - \frac{x}{B}\\
\mathbf{elif}\;F \leq 1.02 \cdot 10^{-112}:\\
\;\;\;\;-t\_2\\
\mathbf{elif}\;F \leq 1.65 \cdot 10^{-63}:\\
\;\;\;\;\frac{F \cdot t\_1 - x}{B}\\
\mathbf{elif}\;F \leq 2.05 \cdot 10^{-42}:\\
\;\;\;\;x \cdot \frac{-1}{\tan B}\\
\mathbf{elif}\;F \leq 1.3 \cdot 10^{+273}:\\
\;\;\;\;\frac{1}{\sin B} - \frac{x}{B}\\
\mathbf{else}:\\
\;\;\;\;F \cdot \frac{1}{F \cdot B} - t\_2\\
\end{array}
\end{array}
if F < -6.20000000000000006e84Initial program 50.9%
distribute-lft-neg-in50.9%
+-commutative50.9%
associate-*l/64.5%
associate-/l*64.5%
fma-define64.5%
/-rgt-identity64.5%
remove-double-neg64.5%
fma-neg64.5%
Simplified64.5%
clear-num64.6%
inv-pow64.6%
fma-define64.6%
fma-undefine64.6%
*-commutative64.6%
fma-define64.6%
fma-define64.6%
Applied egg-rr64.6%
unpow-164.6%
Simplified64.6%
Taylor expanded in F around -inf 99.7%
Taylor expanded in B around 0 80.9%
if -6.20000000000000006e84 < F < -3.0999999999999998e-17Initial program 95.5%
Taylor expanded in B around 0 83.0%
+-commutative83.0%
unsub-neg83.0%
Applied egg-rr87.1%
Taylor expanded in F around -inf 79.0%
if -3.0999999999999998e-17 < F < -7.0000000000000005e-198Initial program 99.4%
Taylor expanded in B around 0 83.5%
+-commutative83.5%
unsub-neg83.5%
Applied egg-rr83.4%
Taylor expanded in F around 0 83.4%
*-commutative83.4%
Simplified83.4%
Taylor expanded in B around 0 65.3%
if -7.0000000000000005e-198 < F < 1.01999999999999996e-112Initial program 99.4%
distribute-lft-neg-in99.4%
+-commutative99.4%
fma-define99.4%
+-commutative99.4%
*-commutative99.4%
fma-define99.4%
fma-define99.4%
metadata-eval99.4%
metadata-eval99.4%
associate-*r/99.6%
*-rgt-identity99.6%
Simplified99.6%
Taylor expanded in F around 0 74.3%
mul-1-neg74.3%
associate-/l*74.2%
Simplified74.2%
clear-num74.2%
un-div-inv74.3%
quot-tan74.4%
Applied egg-rr74.4%
if 1.01999999999999996e-112 < F < 1.64999999999999997e-63Initial program 99.3%
Taylor expanded in B around 0 99.6%
+-commutative99.6%
unsub-neg99.6%
Applied egg-rr99.6%
Taylor expanded in F around 0 99.6%
*-commutative99.6%
Simplified99.6%
Taylor expanded in B around 0 99.7%
if 1.64999999999999997e-63 < F < 2.0500000000000001e-42Initial program 99.7%
distribute-lft-neg-in99.7%
+-commutative99.7%
fma-define99.7%
+-commutative99.7%
*-commutative99.7%
fma-define99.7%
fma-define99.7%
metadata-eval99.7%
metadata-eval99.7%
associate-*r/99.1%
*-rgt-identity99.1%
Simplified99.1%
Taylor expanded in F around 0 60.9%
mul-1-neg60.9%
associate-/l*61.5%
Simplified61.5%
*-un-lft-identity61.5%
clear-num60.9%
quot-tan61.5%
Applied egg-rr61.5%
*-lft-identity61.5%
Simplified61.5%
if 2.0500000000000001e-42 < F < 1.29999999999999997e273Initial program 67.8%
Taylor expanded in B around 0 53.6%
Taylor expanded in F around inf 74.1%
if 1.29999999999999997e273 < F Initial program 50.7%
distribute-lft-neg-in50.7%
+-commutative50.7%
associate-*l/64.0%
associate-/l*64.0%
fma-define64.0%
/-rgt-identity64.0%
remove-double-neg64.0%
fma-neg64.0%
Simplified64.0%
Taylor expanded in F around inf 99.7%
Taylor expanded in B around 0 90.7%
*-commutative90.7%
Simplified90.7%
Final simplification76.6%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (+ 2.0 (* x 2.0))) (t_1 (/ x (tan B))))
(if (<= F -9.6e+84)
(- (/ -1.0 B) t_1)
(if (<= F -3.1e-17)
(- (/ F (* (sin B) (- (* -0.5 (/ t_0 F)) F))) (/ x B))
(if (<= F -7e-198)
(- (* (pow (+ (+ 2.0 (* F F)) (* x 2.0)) -0.5) (/ F B)) (/ x B))
(if (<= F 1e-112)
(- t_1)
(if (<= F 1.25e-64)
(/ (- (* F (sqrt (/ 1.0 t_0))) x) B)
(if (<= F 2.05e-42)
(* x (/ -1.0 (tan B)))
(if (<= F 3.9e+270)
(- (/ 1.0 (sin B)) (/ x B))
(- (* F (/ 1.0 (* F B))) t_1))))))))))
double code(double F, double B, double x) {
double t_0 = 2.0 + (x * 2.0);
double t_1 = x / tan(B);
double tmp;
if (F <= -9.6e+84) {
tmp = (-1.0 / B) - t_1;
} else if (F <= -3.1e-17) {
tmp = (F / (sin(B) * ((-0.5 * (t_0 / F)) - F))) - (x / B);
} else if (F <= -7e-198) {
tmp = (pow(((2.0 + (F * F)) + (x * 2.0)), -0.5) * (F / B)) - (x / B);
} else if (F <= 1e-112) {
tmp = -t_1;
} else if (F <= 1.25e-64) {
tmp = ((F * sqrt((1.0 / t_0))) - x) / B;
} else if (F <= 2.05e-42) {
tmp = x * (-1.0 / tan(B));
} else if (F <= 3.9e+270) {
tmp = (1.0 / sin(B)) - (x / B);
} else {
tmp = (F * (1.0 / (F * B))) - t_1;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = 2.0d0 + (x * 2.0d0)
t_1 = x / tan(b)
if (f <= (-9.6d+84)) then
tmp = ((-1.0d0) / b) - t_1
else if (f <= (-3.1d-17)) then
tmp = (f / (sin(b) * (((-0.5d0) * (t_0 / f)) - f))) - (x / b)
else if (f <= (-7d-198)) then
tmp = ((((2.0d0 + (f * f)) + (x * 2.0d0)) ** (-0.5d0)) * (f / b)) - (x / b)
else if (f <= 1d-112) then
tmp = -t_1
else if (f <= 1.25d-64) then
tmp = ((f * sqrt((1.0d0 / t_0))) - x) / b
else if (f <= 2.05d-42) then
tmp = x * ((-1.0d0) / tan(b))
else if (f <= 3.9d+270) then
tmp = (1.0d0 / sin(b)) - (x / b)
else
tmp = (f * (1.0d0 / (f * b))) - t_1
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = 2.0 + (x * 2.0);
double t_1 = x / Math.tan(B);
double tmp;
if (F <= -9.6e+84) {
tmp = (-1.0 / B) - t_1;
} else if (F <= -3.1e-17) {
tmp = (F / (Math.sin(B) * ((-0.5 * (t_0 / F)) - F))) - (x / B);
} else if (F <= -7e-198) {
tmp = (Math.pow(((2.0 + (F * F)) + (x * 2.0)), -0.5) * (F / B)) - (x / B);
} else if (F <= 1e-112) {
tmp = -t_1;
} else if (F <= 1.25e-64) {
tmp = ((F * Math.sqrt((1.0 / t_0))) - x) / B;
} else if (F <= 2.05e-42) {
tmp = x * (-1.0 / Math.tan(B));
} else if (F <= 3.9e+270) {
tmp = (1.0 / Math.sin(B)) - (x / B);
} else {
tmp = (F * (1.0 / (F * B))) - t_1;
}
return tmp;
}
def code(F, B, x): t_0 = 2.0 + (x * 2.0) t_1 = x / math.tan(B) tmp = 0 if F <= -9.6e+84: tmp = (-1.0 / B) - t_1 elif F <= -3.1e-17: tmp = (F / (math.sin(B) * ((-0.5 * (t_0 / F)) - F))) - (x / B) elif F <= -7e-198: tmp = (math.pow(((2.0 + (F * F)) + (x * 2.0)), -0.5) * (F / B)) - (x / B) elif F <= 1e-112: tmp = -t_1 elif F <= 1.25e-64: tmp = ((F * math.sqrt((1.0 / t_0))) - x) / B elif F <= 2.05e-42: tmp = x * (-1.0 / math.tan(B)) elif F <= 3.9e+270: tmp = (1.0 / math.sin(B)) - (x / B) else: tmp = (F * (1.0 / (F * B))) - t_1 return tmp
function code(F, B, x) t_0 = Float64(2.0 + Float64(x * 2.0)) t_1 = Float64(x / tan(B)) tmp = 0.0 if (F <= -9.6e+84) tmp = Float64(Float64(-1.0 / B) - t_1); elseif (F <= -3.1e-17) tmp = Float64(Float64(F / Float64(sin(B) * Float64(Float64(-0.5 * Float64(t_0 / F)) - F))) - Float64(x / B)); elseif (F <= -7e-198) tmp = Float64(Float64((Float64(Float64(2.0 + Float64(F * F)) + Float64(x * 2.0)) ^ -0.5) * Float64(F / B)) - Float64(x / B)); elseif (F <= 1e-112) tmp = Float64(-t_1); elseif (F <= 1.25e-64) tmp = Float64(Float64(Float64(F * sqrt(Float64(1.0 / t_0))) - x) / B); elseif (F <= 2.05e-42) tmp = Float64(x * Float64(-1.0 / tan(B))); elseif (F <= 3.9e+270) tmp = Float64(Float64(1.0 / sin(B)) - Float64(x / B)); else tmp = Float64(Float64(F * Float64(1.0 / Float64(F * B))) - t_1); end return tmp end
function tmp_2 = code(F, B, x) t_0 = 2.0 + (x * 2.0); t_1 = x / tan(B); tmp = 0.0; if (F <= -9.6e+84) tmp = (-1.0 / B) - t_1; elseif (F <= -3.1e-17) tmp = (F / (sin(B) * ((-0.5 * (t_0 / F)) - F))) - (x / B); elseif (F <= -7e-198) tmp = ((((2.0 + (F * F)) + (x * 2.0)) ^ -0.5) * (F / B)) - (x / B); elseif (F <= 1e-112) tmp = -t_1; elseif (F <= 1.25e-64) tmp = ((F * sqrt((1.0 / t_0))) - x) / B; elseif (F <= 2.05e-42) tmp = x * (-1.0 / tan(B)); elseif (F <= 3.9e+270) tmp = (1.0 / sin(B)) - (x / B); else tmp = (F * (1.0 / (F * B))) - t_1; end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(2.0 + N[(x * 2.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -9.6e+84], N[(N[(-1.0 / B), $MachinePrecision] - t$95$1), $MachinePrecision], If[LessEqual[F, -3.1e-17], N[(N[(F / N[(N[Sin[B], $MachinePrecision] * N[(N[(-0.5 * N[(t$95$0 / F), $MachinePrecision]), $MachinePrecision] - F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, -7e-198], N[(N[(N[Power[N[(N[(2.0 + N[(F * F), $MachinePrecision]), $MachinePrecision] + N[(x * 2.0), $MachinePrecision]), $MachinePrecision], -0.5], $MachinePrecision] * N[(F / B), $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, 1e-112], (-t$95$1), If[LessEqual[F, 1.25e-64], N[(N[(N[(F * N[Sqrt[N[(1.0 / t$95$0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision] / B), $MachinePrecision], If[LessEqual[F, 2.05e-42], N[(x * N[(-1.0 / N[Tan[B], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, 3.9e+270], N[(N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], N[(N[(F * N[(1.0 / N[(F * B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 2 + x \cdot 2\\
t_1 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -9.6 \cdot 10^{+84}:\\
\;\;\;\;\frac{-1}{B} - t\_1\\
\mathbf{elif}\;F \leq -3.1 \cdot 10^{-17}:\\
\;\;\;\;\frac{F}{\sin B \cdot \left(-0.5 \cdot \frac{t\_0}{F} - F\right)} - \frac{x}{B}\\
\mathbf{elif}\;F \leq -7 \cdot 10^{-198}:\\
\;\;\;\;{\left(\left(2 + F \cdot F\right) + x \cdot 2\right)}^{-0.5} \cdot \frac{F}{B} - \frac{x}{B}\\
\mathbf{elif}\;F \leq 10^{-112}:\\
\;\;\;\;-t\_1\\
\mathbf{elif}\;F \leq 1.25 \cdot 10^{-64}:\\
\;\;\;\;\frac{F \cdot \sqrt{\frac{1}{t\_0}} - x}{B}\\
\mathbf{elif}\;F \leq 2.05 \cdot 10^{-42}:\\
\;\;\;\;x \cdot \frac{-1}{\tan B}\\
\mathbf{elif}\;F \leq 3.9 \cdot 10^{+270}:\\
\;\;\;\;\frac{1}{\sin B} - \frac{x}{B}\\
\mathbf{else}:\\
\;\;\;\;F \cdot \frac{1}{F \cdot B} - t\_1\\
\end{array}
\end{array}
if F < -9.5999999999999999e84Initial program 50.9%
distribute-lft-neg-in50.9%
+-commutative50.9%
associate-*l/64.5%
associate-/l*64.5%
fma-define64.5%
/-rgt-identity64.5%
remove-double-neg64.5%
fma-neg64.5%
Simplified64.5%
clear-num64.6%
inv-pow64.6%
fma-define64.6%
fma-undefine64.6%
*-commutative64.6%
fma-define64.6%
fma-define64.6%
Applied egg-rr64.6%
unpow-164.6%
Simplified64.6%
Taylor expanded in F around -inf 99.7%
Taylor expanded in B around 0 80.9%
if -9.5999999999999999e84 < F < -3.0999999999999998e-17Initial program 95.5%
Taylor expanded in B around 0 83.0%
+-commutative83.0%
unsub-neg83.0%
Applied egg-rr87.1%
Taylor expanded in F around -inf 79.0%
if -3.0999999999999998e-17 < F < -7.0000000000000005e-198Initial program 99.4%
Taylor expanded in B around 0 83.5%
Taylor expanded in B around 0 65.3%
if -7.0000000000000005e-198 < F < 9.9999999999999995e-113Initial program 99.4%
distribute-lft-neg-in99.4%
+-commutative99.4%
fma-define99.4%
+-commutative99.4%
*-commutative99.4%
fma-define99.4%
fma-define99.4%
metadata-eval99.4%
metadata-eval99.4%
associate-*r/99.6%
*-rgt-identity99.6%
Simplified99.6%
Taylor expanded in F around 0 74.3%
mul-1-neg74.3%
associate-/l*74.2%
Simplified74.2%
clear-num74.2%
un-div-inv74.3%
quot-tan74.4%
Applied egg-rr74.4%
if 9.9999999999999995e-113 < F < 1.25000000000000008e-64Initial program 99.3%
Taylor expanded in B around 0 99.6%
+-commutative99.6%
unsub-neg99.6%
Applied egg-rr99.6%
Taylor expanded in F around 0 99.6%
*-commutative99.6%
Simplified99.6%
Taylor expanded in B around 0 99.7%
if 1.25000000000000008e-64 < F < 2.0500000000000001e-42Initial program 99.7%
distribute-lft-neg-in99.7%
+-commutative99.7%
fma-define99.7%
+-commutative99.7%
*-commutative99.7%
fma-define99.7%
fma-define99.7%
metadata-eval99.7%
metadata-eval99.7%
associate-*r/99.1%
*-rgt-identity99.1%
Simplified99.1%
Taylor expanded in F around 0 60.9%
mul-1-neg60.9%
associate-/l*61.5%
Simplified61.5%
*-un-lft-identity61.5%
clear-num60.9%
quot-tan61.5%
Applied egg-rr61.5%
*-lft-identity61.5%
Simplified61.5%
if 2.0500000000000001e-42 < F < 3.8999999999999999e270Initial program 67.8%
Taylor expanded in B around 0 53.6%
Taylor expanded in F around inf 74.1%
if 3.8999999999999999e270 < F Initial program 50.7%
distribute-lft-neg-in50.7%
+-commutative50.7%
associate-*l/64.0%
associate-/l*64.0%
fma-define64.0%
/-rgt-identity64.0%
remove-double-neg64.0%
fma-neg64.0%
Simplified64.0%
Taylor expanded in F around inf 99.7%
Taylor expanded in B around 0 90.7%
*-commutative90.7%
Simplified90.7%
Final simplification76.6%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (+ 2.0 (* x 2.0))) (t_1 (/ x (tan B))))
(if (<= F -8.5e+84)
(- (/ -1.0 B) t_1)
(if (<= F -3.1e-17)
(- (/ F (* (sin B) (- (* -0.5 (/ t_0 F)) F))) (/ x B))
(if (<= F -7e-198)
(-
(* (pow (+ (+ 2.0 (* F F)) (* x 2.0)) -0.5) (/ 1.0 (/ B F)))
(/ x B))
(if (<= F 1.65e-112)
(- t_1)
(if (<= F 3.9e-64)
(/ (- (* F (sqrt (/ 1.0 t_0))) x) B)
(if (<= F 2.05e-42)
(* x (/ -1.0 (tan B)))
(if (<= F 1.75e+273)
(- (/ 1.0 (sin B)) (/ x B))
(- (* F (/ 1.0 (* F B))) t_1))))))))))
double code(double F, double B, double x) {
double t_0 = 2.0 + (x * 2.0);
double t_1 = x / tan(B);
double tmp;
if (F <= -8.5e+84) {
tmp = (-1.0 / B) - t_1;
} else if (F <= -3.1e-17) {
tmp = (F / (sin(B) * ((-0.5 * (t_0 / F)) - F))) - (x / B);
} else if (F <= -7e-198) {
tmp = (pow(((2.0 + (F * F)) + (x * 2.0)), -0.5) * (1.0 / (B / F))) - (x / B);
} else if (F <= 1.65e-112) {
tmp = -t_1;
} else if (F <= 3.9e-64) {
tmp = ((F * sqrt((1.0 / t_0))) - x) / B;
} else if (F <= 2.05e-42) {
tmp = x * (-1.0 / tan(B));
} else if (F <= 1.75e+273) {
tmp = (1.0 / sin(B)) - (x / B);
} else {
tmp = (F * (1.0 / (F * B))) - t_1;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = 2.0d0 + (x * 2.0d0)
t_1 = x / tan(b)
if (f <= (-8.5d+84)) then
tmp = ((-1.0d0) / b) - t_1
else if (f <= (-3.1d-17)) then
tmp = (f / (sin(b) * (((-0.5d0) * (t_0 / f)) - f))) - (x / b)
else if (f <= (-7d-198)) then
tmp = ((((2.0d0 + (f * f)) + (x * 2.0d0)) ** (-0.5d0)) * (1.0d0 / (b / f))) - (x / b)
else if (f <= 1.65d-112) then
tmp = -t_1
else if (f <= 3.9d-64) then
tmp = ((f * sqrt((1.0d0 / t_0))) - x) / b
else if (f <= 2.05d-42) then
tmp = x * ((-1.0d0) / tan(b))
else if (f <= 1.75d+273) then
tmp = (1.0d0 / sin(b)) - (x / b)
else
tmp = (f * (1.0d0 / (f * b))) - t_1
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = 2.0 + (x * 2.0);
double t_1 = x / Math.tan(B);
double tmp;
if (F <= -8.5e+84) {
tmp = (-1.0 / B) - t_1;
} else if (F <= -3.1e-17) {
tmp = (F / (Math.sin(B) * ((-0.5 * (t_0 / F)) - F))) - (x / B);
} else if (F <= -7e-198) {
tmp = (Math.pow(((2.0 + (F * F)) + (x * 2.0)), -0.5) * (1.0 / (B / F))) - (x / B);
} else if (F <= 1.65e-112) {
tmp = -t_1;
} else if (F <= 3.9e-64) {
tmp = ((F * Math.sqrt((1.0 / t_0))) - x) / B;
} else if (F <= 2.05e-42) {
tmp = x * (-1.0 / Math.tan(B));
} else if (F <= 1.75e+273) {
tmp = (1.0 / Math.sin(B)) - (x / B);
} else {
tmp = (F * (1.0 / (F * B))) - t_1;
}
return tmp;
}
def code(F, B, x): t_0 = 2.0 + (x * 2.0) t_1 = x / math.tan(B) tmp = 0 if F <= -8.5e+84: tmp = (-1.0 / B) - t_1 elif F <= -3.1e-17: tmp = (F / (math.sin(B) * ((-0.5 * (t_0 / F)) - F))) - (x / B) elif F <= -7e-198: tmp = (math.pow(((2.0 + (F * F)) + (x * 2.0)), -0.5) * (1.0 / (B / F))) - (x / B) elif F <= 1.65e-112: tmp = -t_1 elif F <= 3.9e-64: tmp = ((F * math.sqrt((1.0 / t_0))) - x) / B elif F <= 2.05e-42: tmp = x * (-1.0 / math.tan(B)) elif F <= 1.75e+273: tmp = (1.0 / math.sin(B)) - (x / B) else: tmp = (F * (1.0 / (F * B))) - t_1 return tmp
function code(F, B, x) t_0 = Float64(2.0 + Float64(x * 2.0)) t_1 = Float64(x / tan(B)) tmp = 0.0 if (F <= -8.5e+84) tmp = Float64(Float64(-1.0 / B) - t_1); elseif (F <= -3.1e-17) tmp = Float64(Float64(F / Float64(sin(B) * Float64(Float64(-0.5 * Float64(t_0 / F)) - F))) - Float64(x / B)); elseif (F <= -7e-198) tmp = Float64(Float64((Float64(Float64(2.0 + Float64(F * F)) + Float64(x * 2.0)) ^ -0.5) * Float64(1.0 / Float64(B / F))) - Float64(x / B)); elseif (F <= 1.65e-112) tmp = Float64(-t_1); elseif (F <= 3.9e-64) tmp = Float64(Float64(Float64(F * sqrt(Float64(1.0 / t_0))) - x) / B); elseif (F <= 2.05e-42) tmp = Float64(x * Float64(-1.0 / tan(B))); elseif (F <= 1.75e+273) tmp = Float64(Float64(1.0 / sin(B)) - Float64(x / B)); else tmp = Float64(Float64(F * Float64(1.0 / Float64(F * B))) - t_1); end return tmp end
function tmp_2 = code(F, B, x) t_0 = 2.0 + (x * 2.0); t_1 = x / tan(B); tmp = 0.0; if (F <= -8.5e+84) tmp = (-1.0 / B) - t_1; elseif (F <= -3.1e-17) tmp = (F / (sin(B) * ((-0.5 * (t_0 / F)) - F))) - (x / B); elseif (F <= -7e-198) tmp = ((((2.0 + (F * F)) + (x * 2.0)) ^ -0.5) * (1.0 / (B / F))) - (x / B); elseif (F <= 1.65e-112) tmp = -t_1; elseif (F <= 3.9e-64) tmp = ((F * sqrt((1.0 / t_0))) - x) / B; elseif (F <= 2.05e-42) tmp = x * (-1.0 / tan(B)); elseif (F <= 1.75e+273) tmp = (1.0 / sin(B)) - (x / B); else tmp = (F * (1.0 / (F * B))) - t_1; end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(2.0 + N[(x * 2.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -8.5e+84], N[(N[(-1.0 / B), $MachinePrecision] - t$95$1), $MachinePrecision], If[LessEqual[F, -3.1e-17], N[(N[(F / N[(N[Sin[B], $MachinePrecision] * N[(N[(-0.5 * N[(t$95$0 / F), $MachinePrecision]), $MachinePrecision] - F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, -7e-198], N[(N[(N[Power[N[(N[(2.0 + N[(F * F), $MachinePrecision]), $MachinePrecision] + N[(x * 2.0), $MachinePrecision]), $MachinePrecision], -0.5], $MachinePrecision] * N[(1.0 / N[(B / F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, 1.65e-112], (-t$95$1), If[LessEqual[F, 3.9e-64], N[(N[(N[(F * N[Sqrt[N[(1.0 / t$95$0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision] / B), $MachinePrecision], If[LessEqual[F, 2.05e-42], N[(x * N[(-1.0 / N[Tan[B], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, 1.75e+273], N[(N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], N[(N[(F * N[(1.0 / N[(F * B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 2 + x \cdot 2\\
t_1 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -8.5 \cdot 10^{+84}:\\
\;\;\;\;\frac{-1}{B} - t\_1\\
\mathbf{elif}\;F \leq -3.1 \cdot 10^{-17}:\\
\;\;\;\;\frac{F}{\sin B \cdot \left(-0.5 \cdot \frac{t\_0}{F} - F\right)} - \frac{x}{B}\\
\mathbf{elif}\;F \leq -7 \cdot 10^{-198}:\\
\;\;\;\;{\left(\left(2 + F \cdot F\right) + x \cdot 2\right)}^{-0.5} \cdot \frac{1}{\frac{B}{F}} - \frac{x}{B}\\
\mathbf{elif}\;F \leq 1.65 \cdot 10^{-112}:\\
\;\;\;\;-t\_1\\
\mathbf{elif}\;F \leq 3.9 \cdot 10^{-64}:\\
\;\;\;\;\frac{F \cdot \sqrt{\frac{1}{t\_0}} - x}{B}\\
\mathbf{elif}\;F \leq 2.05 \cdot 10^{-42}:\\
\;\;\;\;x \cdot \frac{-1}{\tan B}\\
\mathbf{elif}\;F \leq 1.75 \cdot 10^{+273}:\\
\;\;\;\;\frac{1}{\sin B} - \frac{x}{B}\\
\mathbf{else}:\\
\;\;\;\;F \cdot \frac{1}{F \cdot B} - t\_1\\
\end{array}
\end{array}
if F < -8.5000000000000008e84Initial program 50.9%
distribute-lft-neg-in50.9%
+-commutative50.9%
associate-*l/64.5%
associate-/l*64.5%
fma-define64.5%
/-rgt-identity64.5%
remove-double-neg64.5%
fma-neg64.5%
Simplified64.5%
clear-num64.6%
inv-pow64.6%
fma-define64.6%
fma-undefine64.6%
*-commutative64.6%
fma-define64.6%
fma-define64.6%
Applied egg-rr64.6%
unpow-164.6%
Simplified64.6%
Taylor expanded in F around -inf 99.7%
Taylor expanded in B around 0 80.9%
if -8.5000000000000008e84 < F < -3.0999999999999998e-17Initial program 95.5%
Taylor expanded in B around 0 83.0%
+-commutative83.0%
unsub-neg83.0%
Applied egg-rr87.1%
Taylor expanded in F around -inf 79.0%
if -3.0999999999999998e-17 < F < -7.0000000000000005e-198Initial program 99.4%
Taylor expanded in B around 0 83.5%
clear-num83.6%
inv-pow83.6%
Applied egg-rr83.6%
unpow-183.6%
Simplified83.6%
Taylor expanded in B around 0 65.5%
if -7.0000000000000005e-198 < F < 1.65e-112Initial program 99.4%
distribute-lft-neg-in99.4%
+-commutative99.4%
fma-define99.4%
+-commutative99.4%
*-commutative99.4%
fma-define99.4%
fma-define99.4%
metadata-eval99.4%
metadata-eval99.4%
associate-*r/99.6%
*-rgt-identity99.6%
Simplified99.6%
Taylor expanded in F around 0 74.3%
mul-1-neg74.3%
associate-/l*74.2%
Simplified74.2%
clear-num74.2%
un-div-inv74.3%
quot-tan74.4%
Applied egg-rr74.4%
if 1.65e-112 < F < 3.8999999999999997e-64Initial program 99.3%
Taylor expanded in B around 0 99.6%
+-commutative99.6%
unsub-neg99.6%
Applied egg-rr99.6%
Taylor expanded in F around 0 99.6%
*-commutative99.6%
Simplified99.6%
Taylor expanded in B around 0 99.7%
if 3.8999999999999997e-64 < F < 2.0500000000000001e-42Initial program 99.7%
distribute-lft-neg-in99.7%
+-commutative99.7%
fma-define99.7%
+-commutative99.7%
*-commutative99.7%
fma-define99.7%
fma-define99.7%
metadata-eval99.7%
metadata-eval99.7%
associate-*r/99.1%
*-rgt-identity99.1%
Simplified99.1%
Taylor expanded in F around 0 60.9%
mul-1-neg60.9%
associate-/l*61.5%
Simplified61.5%
*-un-lft-identity61.5%
clear-num60.9%
quot-tan61.5%
Applied egg-rr61.5%
*-lft-identity61.5%
Simplified61.5%
if 2.0500000000000001e-42 < F < 1.75000000000000005e273Initial program 67.8%
Taylor expanded in B around 0 53.6%
Taylor expanded in F around inf 74.1%
if 1.75000000000000005e273 < F Initial program 50.7%
distribute-lft-neg-in50.7%
+-commutative50.7%
associate-*l/64.0%
associate-/l*64.0%
fma-define64.0%
/-rgt-identity64.0%
remove-double-neg64.0%
fma-neg64.0%
Simplified64.0%
Taylor expanded in F around inf 99.7%
Taylor expanded in B around 0 90.7%
*-commutative90.7%
Simplified90.7%
Final simplification76.6%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (/ x (tan B))))
(if (<= F -7.2e+84)
(- (/ -1.0 B) t_0)
(if (<= F -0.31)
(- (/ -1.0 (sin B)) (/ x B))
(if (<= F 2.05e-42)
(- t_0)
(if (<= F 1.7e+273)
(- (/ 1.0 (sin B)) (/ x B))
(- (* F (/ 1.0 (* F B))) t_0)))))))
double code(double F, double B, double x) {
double t_0 = x / tan(B);
double tmp;
if (F <= -7.2e+84) {
tmp = (-1.0 / B) - t_0;
} else if (F <= -0.31) {
tmp = (-1.0 / sin(B)) - (x / B);
} else if (F <= 2.05e-42) {
tmp = -t_0;
} else if (F <= 1.7e+273) {
tmp = (1.0 / sin(B)) - (x / B);
} else {
tmp = (F * (1.0 / (F * B))) - t_0;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: tmp
t_0 = x / tan(b)
if (f <= (-7.2d+84)) then
tmp = ((-1.0d0) / b) - t_0
else if (f <= (-0.31d0)) then
tmp = ((-1.0d0) / sin(b)) - (x / b)
else if (f <= 2.05d-42) then
tmp = -t_0
else if (f <= 1.7d+273) then
tmp = (1.0d0 / sin(b)) - (x / b)
else
tmp = (f * (1.0d0 / (f * b))) - t_0
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = x / Math.tan(B);
double tmp;
if (F <= -7.2e+84) {
tmp = (-1.0 / B) - t_0;
} else if (F <= -0.31) {
tmp = (-1.0 / Math.sin(B)) - (x / B);
} else if (F <= 2.05e-42) {
tmp = -t_0;
} else if (F <= 1.7e+273) {
tmp = (1.0 / Math.sin(B)) - (x / B);
} else {
tmp = (F * (1.0 / (F * B))) - t_0;
}
return tmp;
}
def code(F, B, x): t_0 = x / math.tan(B) tmp = 0 if F <= -7.2e+84: tmp = (-1.0 / B) - t_0 elif F <= -0.31: tmp = (-1.0 / math.sin(B)) - (x / B) elif F <= 2.05e-42: tmp = -t_0 elif F <= 1.7e+273: tmp = (1.0 / math.sin(B)) - (x / B) else: tmp = (F * (1.0 / (F * B))) - t_0 return tmp
function code(F, B, x) t_0 = Float64(x / tan(B)) tmp = 0.0 if (F <= -7.2e+84) tmp = Float64(Float64(-1.0 / B) - t_0); elseif (F <= -0.31) tmp = Float64(Float64(-1.0 / sin(B)) - Float64(x / B)); elseif (F <= 2.05e-42) tmp = Float64(-t_0); elseif (F <= 1.7e+273) tmp = Float64(Float64(1.0 / sin(B)) - Float64(x / B)); else tmp = Float64(Float64(F * Float64(1.0 / Float64(F * B))) - t_0); end return tmp end
function tmp_2 = code(F, B, x) t_0 = x / tan(B); tmp = 0.0; if (F <= -7.2e+84) tmp = (-1.0 / B) - t_0; elseif (F <= -0.31) tmp = (-1.0 / sin(B)) - (x / B); elseif (F <= 2.05e-42) tmp = -t_0; elseif (F <= 1.7e+273) tmp = (1.0 / sin(B)) - (x / B); else tmp = (F * (1.0 / (F * B))) - t_0; end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -7.2e+84], N[(N[(-1.0 / B), $MachinePrecision] - t$95$0), $MachinePrecision], If[LessEqual[F, -0.31], N[(N[(-1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, 2.05e-42], (-t$95$0), If[LessEqual[F, 1.7e+273], N[(N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], N[(N[(F * N[(1.0 / N[(F * B), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$0), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -7.2 \cdot 10^{+84}:\\
\;\;\;\;\frac{-1}{B} - t\_0\\
\mathbf{elif}\;F \leq -0.31:\\
\;\;\;\;\frac{-1}{\sin B} - \frac{x}{B}\\
\mathbf{elif}\;F \leq 2.05 \cdot 10^{-42}:\\
\;\;\;\;-t\_0\\
\mathbf{elif}\;F \leq 1.7 \cdot 10^{+273}:\\
\;\;\;\;\frac{1}{\sin B} - \frac{x}{B}\\
\mathbf{else}:\\
\;\;\;\;F \cdot \frac{1}{F \cdot B} - t\_0\\
\end{array}
\end{array}
if F < -7.1999999999999999e84Initial program 50.9%
distribute-lft-neg-in50.9%
+-commutative50.9%
associate-*l/64.5%
associate-/l*64.5%
fma-define64.5%
/-rgt-identity64.5%
remove-double-neg64.5%
fma-neg64.5%
Simplified64.5%
clear-num64.6%
inv-pow64.6%
fma-define64.6%
fma-undefine64.6%
*-commutative64.6%
fma-define64.6%
fma-define64.6%
Applied egg-rr64.6%
unpow-164.6%
Simplified64.6%
Taylor expanded in F around -inf 99.7%
Taylor expanded in B around 0 80.9%
if -7.1999999999999999e84 < F < -0.309999999999999998Initial program 94.7%
Taylor expanded in B around 0 84.9%
Taylor expanded in F around -inf 87.9%
distribute-lft-in87.9%
mul-1-neg87.9%
unsub-neg87.9%
neg-mul-187.9%
distribute-neg-frac87.9%
metadata-eval87.9%
Simplified87.9%
if -0.309999999999999998 < F < 2.0500000000000001e-42Initial program 99.4%
distribute-lft-neg-in99.4%
+-commutative99.4%
fma-define99.4%
+-commutative99.4%
*-commutative99.4%
fma-define99.4%
fma-define99.4%
metadata-eval99.4%
metadata-eval99.4%
associate-*r/99.5%
*-rgt-identity99.5%
Simplified99.5%
Taylor expanded in F around 0 62.1%
mul-1-neg62.1%
associate-/l*62.0%
Simplified62.0%
clear-num62.0%
un-div-inv62.1%
quot-tan62.1%
Applied egg-rr62.1%
if 2.0500000000000001e-42 < F < 1.69999999999999999e273Initial program 67.8%
Taylor expanded in B around 0 53.6%
Taylor expanded in F around inf 74.1%
if 1.69999999999999999e273 < F Initial program 50.7%
distribute-lft-neg-in50.7%
+-commutative50.7%
associate-*l/64.0%
associate-/l*64.0%
fma-define64.0%
/-rgt-identity64.0%
remove-double-neg64.0%
fma-neg64.0%
Simplified64.0%
Taylor expanded in F around inf 99.7%
Taylor expanded in B around 0 90.7%
*-commutative90.7%
Simplified90.7%
Final simplification72.5%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (/ x (tan B))))
(if (<= F -6.8e+84)
(- (/ -1.0 B) t_0)
(if (<= F -7.0)
(- (/ -1.0 (sin B)) (/ x B))
(if (or (<= F 215.0) (not (<= F 2.5e+274))) (- t_0) (/ 1.0 (sin B)))))))
double code(double F, double B, double x) {
double t_0 = x / tan(B);
double tmp;
if (F <= -6.8e+84) {
tmp = (-1.0 / B) - t_0;
} else if (F <= -7.0) {
tmp = (-1.0 / sin(B)) - (x / B);
} else if ((F <= 215.0) || !(F <= 2.5e+274)) {
tmp = -t_0;
} else {
tmp = 1.0 / sin(B);
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: tmp
t_0 = x / tan(b)
if (f <= (-6.8d+84)) then
tmp = ((-1.0d0) / b) - t_0
else if (f <= (-7.0d0)) then
tmp = ((-1.0d0) / sin(b)) - (x / b)
else if ((f <= 215.0d0) .or. (.not. (f <= 2.5d+274))) then
tmp = -t_0
else
tmp = 1.0d0 / sin(b)
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = x / Math.tan(B);
double tmp;
if (F <= -6.8e+84) {
tmp = (-1.0 / B) - t_0;
} else if (F <= -7.0) {
tmp = (-1.0 / Math.sin(B)) - (x / B);
} else if ((F <= 215.0) || !(F <= 2.5e+274)) {
tmp = -t_0;
} else {
tmp = 1.0 / Math.sin(B);
}
return tmp;
}
def code(F, B, x): t_0 = x / math.tan(B) tmp = 0 if F <= -6.8e+84: tmp = (-1.0 / B) - t_0 elif F <= -7.0: tmp = (-1.0 / math.sin(B)) - (x / B) elif (F <= 215.0) or not (F <= 2.5e+274): tmp = -t_0 else: tmp = 1.0 / math.sin(B) return tmp
function code(F, B, x) t_0 = Float64(x / tan(B)) tmp = 0.0 if (F <= -6.8e+84) tmp = Float64(Float64(-1.0 / B) - t_0); elseif (F <= -7.0) tmp = Float64(Float64(-1.0 / sin(B)) - Float64(x / B)); elseif ((F <= 215.0) || !(F <= 2.5e+274)) tmp = Float64(-t_0); else tmp = Float64(1.0 / sin(B)); end return tmp end
function tmp_2 = code(F, B, x) t_0 = x / tan(B); tmp = 0.0; if (F <= -6.8e+84) tmp = (-1.0 / B) - t_0; elseif (F <= -7.0) tmp = (-1.0 / sin(B)) - (x / B); elseif ((F <= 215.0) || ~((F <= 2.5e+274))) tmp = -t_0; else tmp = 1.0 / sin(B); end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -6.8e+84], N[(N[(-1.0 / B), $MachinePrecision] - t$95$0), $MachinePrecision], If[LessEqual[F, -7.0], N[(N[(-1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[F, 215.0], N[Not[LessEqual[F, 2.5e+274]], $MachinePrecision]], (-t$95$0), N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -6.8 \cdot 10^{+84}:\\
\;\;\;\;\frac{-1}{B} - t\_0\\
\mathbf{elif}\;F \leq -7:\\
\;\;\;\;\frac{-1}{\sin B} - \frac{x}{B}\\
\mathbf{elif}\;F \leq 215 \lor \neg \left(F \leq 2.5 \cdot 10^{+274}\right):\\
\;\;\;\;-t\_0\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{\sin B}\\
\end{array}
\end{array}
if F < -6.7999999999999996e84Initial program 50.9%
distribute-lft-neg-in50.9%
+-commutative50.9%
associate-*l/64.5%
associate-/l*64.5%
fma-define64.5%
/-rgt-identity64.5%
remove-double-neg64.5%
fma-neg64.5%
Simplified64.5%
clear-num64.6%
inv-pow64.6%
fma-define64.6%
fma-undefine64.6%
*-commutative64.6%
fma-define64.6%
fma-define64.6%
Applied egg-rr64.6%
unpow-164.6%
Simplified64.6%
Taylor expanded in F around -inf 99.7%
Taylor expanded in B around 0 80.9%
if -6.7999999999999996e84 < F < -7Initial program 94.7%
Taylor expanded in B around 0 84.9%
Taylor expanded in F around -inf 87.9%
distribute-lft-in87.9%
mul-1-neg87.9%
unsub-neg87.9%
neg-mul-187.9%
distribute-neg-frac87.9%
metadata-eval87.9%
Simplified87.9%
if -7 < F < 215 or 2.4999999999999999e274 < F Initial program 96.3%
distribute-lft-neg-in96.3%
+-commutative96.3%
fma-define96.3%
+-commutative96.3%
*-commutative96.3%
fma-define96.3%
fma-define96.3%
metadata-eval96.3%
metadata-eval96.3%
associate-*r/96.4%
*-rgt-identity96.4%
Simplified96.4%
Taylor expanded in F around 0 60.3%
mul-1-neg60.3%
associate-/l*60.3%
Simplified60.3%
clear-num60.2%
un-div-inv60.4%
quot-tan60.4%
Applied egg-rr60.4%
if 215 < F < 2.4999999999999999e274Initial program 59.5%
Taylor expanded in B around 0 42.5%
Taylor expanded in F around inf 68.4%
*-un-lft-identity68.4%
+-commutative68.4%
add-sqr-sqrt24.4%
add-sqr-sqrt15.4%
add-sqr-sqrt41.9%
associate-*l/48.0%
rgt-mult-inverse48.1%
sqrt-unprod69.6%
sqr-neg69.6%
sqrt-unprod45.2%
add-sqr-sqrt70.6%
Applied egg-rr70.6%
*-lft-identity70.6%
Simplified70.6%
Taylor expanded in B around inf 71.0%
Final simplification69.6%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (/ x (tan B))))
(if (<= F -9.6e+84)
(- (/ -1.0 B) t_0)
(if (<= F -680.0)
(- (/ -1.0 (sin B)) (/ x B))
(if (<= F 2.05e-42) (- t_0) (- (/ 1.0 (sin B)) (/ x B)))))))
double code(double F, double B, double x) {
double t_0 = x / tan(B);
double tmp;
if (F <= -9.6e+84) {
tmp = (-1.0 / B) - t_0;
} else if (F <= -680.0) {
tmp = (-1.0 / sin(B)) - (x / B);
} else if (F <= 2.05e-42) {
tmp = -t_0;
} else {
tmp = (1.0 / sin(B)) - (x / B);
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: tmp
t_0 = x / tan(b)
if (f <= (-9.6d+84)) then
tmp = ((-1.0d0) / b) - t_0
else if (f <= (-680.0d0)) then
tmp = ((-1.0d0) / sin(b)) - (x / b)
else if (f <= 2.05d-42) then
tmp = -t_0
else
tmp = (1.0d0 / sin(b)) - (x / b)
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = x / Math.tan(B);
double tmp;
if (F <= -9.6e+84) {
tmp = (-1.0 / B) - t_0;
} else if (F <= -680.0) {
tmp = (-1.0 / Math.sin(B)) - (x / B);
} else if (F <= 2.05e-42) {
tmp = -t_0;
} else {
tmp = (1.0 / Math.sin(B)) - (x / B);
}
return tmp;
}
def code(F, B, x): t_0 = x / math.tan(B) tmp = 0 if F <= -9.6e+84: tmp = (-1.0 / B) - t_0 elif F <= -680.0: tmp = (-1.0 / math.sin(B)) - (x / B) elif F <= 2.05e-42: tmp = -t_0 else: tmp = (1.0 / math.sin(B)) - (x / B) return tmp
function code(F, B, x) t_0 = Float64(x / tan(B)) tmp = 0.0 if (F <= -9.6e+84) tmp = Float64(Float64(-1.0 / B) - t_0); elseif (F <= -680.0) tmp = Float64(Float64(-1.0 / sin(B)) - Float64(x / B)); elseif (F <= 2.05e-42) tmp = Float64(-t_0); else tmp = Float64(Float64(1.0 / sin(B)) - Float64(x / B)); end return tmp end
function tmp_2 = code(F, B, x) t_0 = x / tan(B); tmp = 0.0; if (F <= -9.6e+84) tmp = (-1.0 / B) - t_0; elseif (F <= -680.0) tmp = (-1.0 / sin(B)) - (x / B); elseif (F <= 2.05e-42) tmp = -t_0; else tmp = (1.0 / sin(B)) - (x / B); end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -9.6e+84], N[(N[(-1.0 / B), $MachinePrecision] - t$95$0), $MachinePrecision], If[LessEqual[F, -680.0], N[(N[(-1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], If[LessEqual[F, 2.05e-42], (-t$95$0), N[(N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -9.6 \cdot 10^{+84}:\\
\;\;\;\;\frac{-1}{B} - t\_0\\
\mathbf{elif}\;F \leq -680:\\
\;\;\;\;\frac{-1}{\sin B} - \frac{x}{B}\\
\mathbf{elif}\;F \leq 2.05 \cdot 10^{-42}:\\
\;\;\;\;-t\_0\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{\sin B} - \frac{x}{B}\\
\end{array}
\end{array}
if F < -9.5999999999999999e84Initial program 50.9%
distribute-lft-neg-in50.9%
+-commutative50.9%
associate-*l/64.5%
associate-/l*64.5%
fma-define64.5%
/-rgt-identity64.5%
remove-double-neg64.5%
fma-neg64.5%
Simplified64.5%
clear-num64.6%
inv-pow64.6%
fma-define64.6%
fma-undefine64.6%
*-commutative64.6%
fma-define64.6%
fma-define64.6%
Applied egg-rr64.6%
unpow-164.6%
Simplified64.6%
Taylor expanded in F around -inf 99.7%
Taylor expanded in B around 0 80.9%
if -9.5999999999999999e84 < F < -680Initial program 94.7%
Taylor expanded in B around 0 84.9%
Taylor expanded in F around -inf 87.9%
distribute-lft-in87.9%
mul-1-neg87.9%
unsub-neg87.9%
neg-mul-187.9%
distribute-neg-frac87.9%
metadata-eval87.9%
Simplified87.9%
if -680 < F < 2.0500000000000001e-42Initial program 99.4%
distribute-lft-neg-in99.4%
+-commutative99.4%
fma-define99.4%
+-commutative99.4%
*-commutative99.4%
fma-define99.4%
fma-define99.4%
metadata-eval99.4%
metadata-eval99.4%
associate-*r/99.5%
*-rgt-identity99.5%
Simplified99.5%
Taylor expanded in F around 0 62.1%
mul-1-neg62.1%
associate-/l*62.0%
Simplified62.0%
clear-num62.0%
un-div-inv62.1%
quot-tan62.1%
Applied egg-rr62.1%
if 2.0500000000000001e-42 < F Initial program 65.2%
Taylor expanded in B around 0 45.8%
Taylor expanded in F around inf 70.3%
Final simplification70.9%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (/ x (tan B))))
(if (<= F -3e-51)
(- (/ -1.0 B) t_0)
(if (or (<= F 8200.0) (not (<= F 6.5e+277))) (- t_0) (/ 1.0 (sin B))))))
double code(double F, double B, double x) {
double t_0 = x / tan(B);
double tmp;
if (F <= -3e-51) {
tmp = (-1.0 / B) - t_0;
} else if ((F <= 8200.0) || !(F <= 6.5e+277)) {
tmp = -t_0;
} else {
tmp = 1.0 / sin(B);
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: tmp
t_0 = x / tan(b)
if (f <= (-3d-51)) then
tmp = ((-1.0d0) / b) - t_0
else if ((f <= 8200.0d0) .or. (.not. (f <= 6.5d+277))) then
tmp = -t_0
else
tmp = 1.0d0 / sin(b)
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = x / Math.tan(B);
double tmp;
if (F <= -3e-51) {
tmp = (-1.0 / B) - t_0;
} else if ((F <= 8200.0) || !(F <= 6.5e+277)) {
tmp = -t_0;
} else {
tmp = 1.0 / Math.sin(B);
}
return tmp;
}
def code(F, B, x): t_0 = x / math.tan(B) tmp = 0 if F <= -3e-51: tmp = (-1.0 / B) - t_0 elif (F <= 8200.0) or not (F <= 6.5e+277): tmp = -t_0 else: tmp = 1.0 / math.sin(B) return tmp
function code(F, B, x) t_0 = Float64(x / tan(B)) tmp = 0.0 if (F <= -3e-51) tmp = Float64(Float64(-1.0 / B) - t_0); elseif ((F <= 8200.0) || !(F <= 6.5e+277)) tmp = Float64(-t_0); else tmp = Float64(1.0 / sin(B)); end return tmp end
function tmp_2 = code(F, B, x) t_0 = x / tan(B); tmp = 0.0; if (F <= -3e-51) tmp = (-1.0 / B) - t_0; elseif ((F <= 8200.0) || ~((F <= 6.5e+277))) tmp = -t_0; else tmp = 1.0 / sin(B); end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -3e-51], N[(N[(-1.0 / B), $MachinePrecision] - t$95$0), $MachinePrecision], If[Or[LessEqual[F, 8200.0], N[Not[LessEqual[F, 6.5e+277]], $MachinePrecision]], (-t$95$0), N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{x}{\tan B}\\
\mathbf{if}\;F \leq -3 \cdot 10^{-51}:\\
\;\;\;\;\frac{-1}{B} - t\_0\\
\mathbf{elif}\;F \leq 8200 \lor \neg \left(F \leq 6.5 \cdot 10^{+277}\right):\\
\;\;\;\;-t\_0\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{\sin B}\\
\end{array}
\end{array}
if F < -3.00000000000000002e-51Initial program 64.3%
distribute-lft-neg-in64.3%
+-commutative64.3%
associate-*l/74.8%
associate-/l*74.8%
fma-define74.8%
/-rgt-identity74.8%
remove-double-neg74.8%
fma-neg74.8%
Simplified74.9%
clear-num74.8%
inv-pow74.8%
fma-define74.8%
fma-undefine74.8%
*-commutative74.8%
fma-define74.8%
fma-define74.8%
Applied egg-rr74.8%
unpow-174.8%
Simplified74.8%
Taylor expanded in F around -inf 92.7%
Taylor expanded in B around 0 70.1%
if -3.00000000000000002e-51 < F < 8200 or 6.5000000000000003e277 < F Initial program 96.0%
distribute-lft-neg-in96.0%
+-commutative96.0%
fma-define96.0%
+-commutative96.0%
*-commutative96.0%
fma-define96.0%
fma-define96.0%
metadata-eval96.0%
metadata-eval96.0%
associate-*r/96.1%
*-rgt-identity96.1%
Simplified96.1%
Taylor expanded in F around 0 62.8%
mul-1-neg62.8%
associate-/l*62.7%
Simplified62.7%
clear-num62.7%
un-div-inv62.8%
quot-tan62.8%
Applied egg-rr62.8%
if 8200 < F < 6.5000000000000003e277Initial program 59.5%
Taylor expanded in B around 0 42.5%
Taylor expanded in F around inf 68.4%
*-un-lft-identity68.4%
+-commutative68.4%
add-sqr-sqrt24.4%
add-sqr-sqrt15.4%
add-sqr-sqrt41.9%
associate-*l/48.0%
rgt-mult-inverse48.1%
sqrt-unprod69.6%
sqr-neg69.6%
sqrt-unprod45.2%
add-sqr-sqrt70.6%
Applied egg-rr70.6%
*-lft-identity70.6%
Simplified70.6%
Taylor expanded in B around inf 71.0%
Final simplification67.0%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (+ F (* 0.5 (/ (+ 2.0 (* x 2.0)) F)))))
(if (<= F -9.8e+92)
(/ (- -1.0 x) B)
(if (<= F -3.2)
(/ -1.0 (sin B))
(if (<= F 66000.0)
(-
(+ (* 0.16666666666666666 (/ (* F B) t_0)) (/ F (* B t_0)))
(/ x B))
(/ 1.0 (sin B)))))))
double code(double F, double B, double x) {
double t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F));
double tmp;
if (F <= -9.8e+92) {
tmp = (-1.0 - x) / B;
} else if (F <= -3.2) {
tmp = -1.0 / sin(B);
} else if (F <= 66000.0) {
tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B);
} else {
tmp = 1.0 / sin(B);
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: tmp
t_0 = f + (0.5d0 * ((2.0d0 + (x * 2.0d0)) / f))
if (f <= (-9.8d+92)) then
tmp = ((-1.0d0) - x) / b
else if (f <= (-3.2d0)) then
tmp = (-1.0d0) / sin(b)
else if (f <= 66000.0d0) then
tmp = ((0.16666666666666666d0 * ((f * b) / t_0)) + (f / (b * t_0))) - (x / b)
else
tmp = 1.0d0 / sin(b)
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F));
double tmp;
if (F <= -9.8e+92) {
tmp = (-1.0 - x) / B;
} else if (F <= -3.2) {
tmp = -1.0 / Math.sin(B);
} else if (F <= 66000.0) {
tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B);
} else {
tmp = 1.0 / Math.sin(B);
}
return tmp;
}
def code(F, B, x): t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F)) tmp = 0 if F <= -9.8e+92: tmp = (-1.0 - x) / B elif F <= -3.2: tmp = -1.0 / math.sin(B) elif F <= 66000.0: tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B) else: tmp = 1.0 / math.sin(B) return tmp
function code(F, B, x) t_0 = Float64(F + Float64(0.5 * Float64(Float64(2.0 + Float64(x * 2.0)) / F))) tmp = 0.0 if (F <= -9.8e+92) tmp = Float64(Float64(-1.0 - x) / B); elseif (F <= -3.2) tmp = Float64(-1.0 / sin(B)); elseif (F <= 66000.0) tmp = Float64(Float64(Float64(0.16666666666666666 * Float64(Float64(F * B) / t_0)) + Float64(F / Float64(B * t_0))) - Float64(x / B)); else tmp = Float64(1.0 / sin(B)); end return tmp end
function tmp_2 = code(F, B, x) t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F)); tmp = 0.0; if (F <= -9.8e+92) tmp = (-1.0 - x) / B; elseif (F <= -3.2) tmp = -1.0 / sin(B); elseif (F <= 66000.0) tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B); else tmp = 1.0 / sin(B); end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(F + N[(0.5 * N[(N[(2.0 + N[(x * 2.0), $MachinePrecision]), $MachinePrecision] / F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -9.8e+92], N[(N[(-1.0 - x), $MachinePrecision] / B), $MachinePrecision], If[LessEqual[F, -3.2], N[(-1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision], If[LessEqual[F, 66000.0], N[(N[(N[(0.16666666666666666 * N[(N[(F * B), $MachinePrecision] / t$95$0), $MachinePrecision]), $MachinePrecision] + N[(F / N[(B * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], N[(1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := F + 0.5 \cdot \frac{2 + x \cdot 2}{F}\\
\mathbf{if}\;F \leq -9.8 \cdot 10^{+92}:\\
\;\;\;\;\frac{-1 - x}{B}\\
\mathbf{elif}\;F \leq -3.2:\\
\;\;\;\;\frac{-1}{\sin B}\\
\mathbf{elif}\;F \leq 66000:\\
\;\;\;\;\left(0.16666666666666666 \cdot \frac{F \cdot B}{t\_0} + \frac{F}{B \cdot t\_0}\right) - \frac{x}{B}\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{\sin B}\\
\end{array}
\end{array}
if F < -9.8000000000000003e92Initial program 49.4%
distribute-lft-neg-in49.4%
+-commutative49.4%
associate-*l/63.4%
associate-/l*63.4%
fma-define63.4%
/-rgt-identity63.4%
remove-double-neg63.4%
fma-neg63.4%
Simplified63.5%
clear-num63.5%
inv-pow63.5%
fma-define63.5%
fma-undefine63.5%
*-commutative63.5%
fma-define63.5%
fma-define63.5%
Applied egg-rr63.5%
unpow-163.5%
Simplified63.5%
Taylor expanded in F around -inf 99.7%
Taylor expanded in B around 0 55.4%
mul-1-neg55.4%
distribute-neg-frac255.4%
Simplified55.4%
if -9.8000000000000003e92 < F < -3.2000000000000002Initial program 95.3%
distribute-lft-neg-in95.3%
+-commutative95.3%
associate-*l/99.7%
associate-/l*99.7%
fma-define99.7%
/-rgt-identity99.7%
remove-double-neg99.7%
fma-neg99.7%
Simplified99.8%
clear-num99.5%
inv-pow99.5%
fma-define99.5%
fma-undefine99.5%
*-commutative99.5%
fma-define99.5%
fma-define99.5%
Applied egg-rr99.5%
unpow-199.5%
Simplified99.5%
Taylor expanded in F around -inf 98.0%
Taylor expanded in x around 0 65.0%
if -3.2000000000000002 < F < 66000Initial program 99.4%
Taylor expanded in B around 0 72.9%
+-commutative72.9%
unsub-neg72.9%
Applied egg-rr73.0%
Taylor expanded in F around inf 34.6%
Taylor expanded in B around 0 34.6%
if 66000 < F Initial program 59.0%
Taylor expanded in B around 0 36.1%
Taylor expanded in F around inf 59.1%
*-un-lft-identity59.1%
+-commutative59.1%
add-sqr-sqrt20.8%
add-sqr-sqrt13.2%
add-sqr-sqrt35.5%
associate-*l/44.1%
rgt-mult-inverse44.2%
sqrt-unprod63.6%
sqr-neg63.6%
sqrt-unprod39.2%
add-sqr-sqrt62.4%
Applied egg-rr62.4%
*-lft-identity62.4%
Simplified62.4%
Taylor expanded in B around inf 62.8%
Final simplification48.3%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (+ F (* 0.5 (/ (+ 2.0 (* x 2.0)) F)))))
(if (<= B 4.4e-279)
(/ (- -1.0 x) B)
(if (<= B 1500000000.0)
(- (+ (* 0.16666666666666666 (/ (* F B) t_0)) (/ F (* B t_0))) (/ x B))
(* x (/ -1.0 (tan B)))))))
double code(double F, double B, double x) {
double t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F));
double tmp;
if (B <= 4.4e-279) {
tmp = (-1.0 - x) / B;
} else if (B <= 1500000000.0) {
tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B);
} else {
tmp = x * (-1.0 / tan(B));
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: tmp
t_0 = f + (0.5d0 * ((2.0d0 + (x * 2.0d0)) / f))
if (b <= 4.4d-279) then
tmp = ((-1.0d0) - x) / b
else if (b <= 1500000000.0d0) then
tmp = ((0.16666666666666666d0 * ((f * b) / t_0)) + (f / (b * t_0))) - (x / b)
else
tmp = x * ((-1.0d0) / tan(b))
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F));
double tmp;
if (B <= 4.4e-279) {
tmp = (-1.0 - x) / B;
} else if (B <= 1500000000.0) {
tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B);
} else {
tmp = x * (-1.0 / Math.tan(B));
}
return tmp;
}
def code(F, B, x): t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F)) tmp = 0 if B <= 4.4e-279: tmp = (-1.0 - x) / B elif B <= 1500000000.0: tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B) else: tmp = x * (-1.0 / math.tan(B)) return tmp
function code(F, B, x) t_0 = Float64(F + Float64(0.5 * Float64(Float64(2.0 + Float64(x * 2.0)) / F))) tmp = 0.0 if (B <= 4.4e-279) tmp = Float64(Float64(-1.0 - x) / B); elseif (B <= 1500000000.0) tmp = Float64(Float64(Float64(0.16666666666666666 * Float64(Float64(F * B) / t_0)) + Float64(F / Float64(B * t_0))) - Float64(x / B)); else tmp = Float64(x * Float64(-1.0 / tan(B))); end return tmp end
function tmp_2 = code(F, B, x) t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F)); tmp = 0.0; if (B <= 4.4e-279) tmp = (-1.0 - x) / B; elseif (B <= 1500000000.0) tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B); else tmp = x * (-1.0 / tan(B)); end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(F + N[(0.5 * N[(N[(2.0 + N[(x * 2.0), $MachinePrecision]), $MachinePrecision] / F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[B, 4.4e-279], N[(N[(-1.0 - x), $MachinePrecision] / B), $MachinePrecision], If[LessEqual[B, 1500000000.0], N[(N[(N[(0.16666666666666666 * N[(N[(F * B), $MachinePrecision] / t$95$0), $MachinePrecision]), $MachinePrecision] + N[(F / N[(B * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], N[(x * N[(-1.0 / N[Tan[B], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := F + 0.5 \cdot \frac{2 + x \cdot 2}{F}\\
\mathbf{if}\;B \leq 4.4 \cdot 10^{-279}:\\
\;\;\;\;\frac{-1 - x}{B}\\
\mathbf{elif}\;B \leq 1500000000:\\
\;\;\;\;\left(0.16666666666666666 \cdot \frac{F \cdot B}{t\_0} + \frac{F}{B \cdot t\_0}\right) - \frac{x}{B}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{-1}{\tan B}\\
\end{array}
\end{array}
if B < 4.40000000000000001e-279Initial program 77.2%
distribute-lft-neg-in77.2%
+-commutative77.2%
associate-*l/85.5%
associate-/l*85.4%
fma-define85.4%
/-rgt-identity85.4%
remove-double-neg85.4%
fma-neg85.4%
Simplified85.5%
clear-num85.4%
inv-pow85.4%
fma-define85.4%
fma-undefine85.4%
*-commutative85.4%
fma-define85.4%
fma-define85.4%
Applied egg-rr85.4%
unpow-185.4%
Simplified85.4%
Taylor expanded in F around -inf 62.6%
Taylor expanded in B around 0 35.3%
mul-1-neg35.3%
distribute-neg-frac235.3%
Simplified35.3%
if 4.40000000000000001e-279 < B < 1.5e9Initial program 72.3%
Taylor expanded in B around 0 72.1%
+-commutative72.1%
unsub-neg72.1%
Applied egg-rr78.0%
Taylor expanded in F around inf 63.3%
Taylor expanded in B around 0 60.7%
if 1.5e9 < B Initial program 83.9%
distribute-lft-neg-in83.9%
+-commutative83.9%
fma-define83.9%
+-commutative83.9%
*-commutative83.9%
fma-define83.9%
fma-define83.9%
metadata-eval83.9%
metadata-eval83.9%
associate-*r/83.9%
*-rgt-identity83.9%
Simplified83.9%
Taylor expanded in F around 0 47.9%
mul-1-neg47.9%
associate-/l*48.0%
Simplified48.0%
*-un-lft-identity48.0%
clear-num48.0%
quot-tan48.0%
Applied egg-rr48.0%
*-lft-identity48.0%
Simplified48.0%
Final simplification44.6%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (+ F (* 0.5 (/ (+ 2.0 (* x 2.0)) F)))))
(if (<= B 1.3e-279)
(/ (- -1.0 x) B)
(if (<= B 1500000000.0)
(- (+ (* 0.16666666666666666 (/ (* F B) t_0)) (/ F (* B t_0))) (/ x B))
(- (/ x (tan B)))))))
double code(double F, double B, double x) {
double t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F));
double tmp;
if (B <= 1.3e-279) {
tmp = (-1.0 - x) / B;
} else if (B <= 1500000000.0) {
tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B);
} else {
tmp = -(x / tan(B));
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: tmp
t_0 = f + (0.5d0 * ((2.0d0 + (x * 2.0d0)) / f))
if (b <= 1.3d-279) then
tmp = ((-1.0d0) - x) / b
else if (b <= 1500000000.0d0) then
tmp = ((0.16666666666666666d0 * ((f * b) / t_0)) + (f / (b * t_0))) - (x / b)
else
tmp = -(x / tan(b))
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F));
double tmp;
if (B <= 1.3e-279) {
tmp = (-1.0 - x) / B;
} else if (B <= 1500000000.0) {
tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B);
} else {
tmp = -(x / Math.tan(B));
}
return tmp;
}
def code(F, B, x): t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F)) tmp = 0 if B <= 1.3e-279: tmp = (-1.0 - x) / B elif B <= 1500000000.0: tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B) else: tmp = -(x / math.tan(B)) return tmp
function code(F, B, x) t_0 = Float64(F + Float64(0.5 * Float64(Float64(2.0 + Float64(x * 2.0)) / F))) tmp = 0.0 if (B <= 1.3e-279) tmp = Float64(Float64(-1.0 - x) / B); elseif (B <= 1500000000.0) tmp = Float64(Float64(Float64(0.16666666666666666 * Float64(Float64(F * B) / t_0)) + Float64(F / Float64(B * t_0))) - Float64(x / B)); else tmp = Float64(-Float64(x / tan(B))); end return tmp end
function tmp_2 = code(F, B, x) t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F)); tmp = 0.0; if (B <= 1.3e-279) tmp = (-1.0 - x) / B; elseif (B <= 1500000000.0) tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B); else tmp = -(x / tan(B)); end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(F + N[(0.5 * N[(N[(2.0 + N[(x * 2.0), $MachinePrecision]), $MachinePrecision] / F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[B, 1.3e-279], N[(N[(-1.0 - x), $MachinePrecision] / B), $MachinePrecision], If[LessEqual[B, 1500000000.0], N[(N[(N[(0.16666666666666666 * N[(N[(F * B), $MachinePrecision] / t$95$0), $MachinePrecision]), $MachinePrecision] + N[(F / N[(B * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision], (-N[(x / N[Tan[B], $MachinePrecision]), $MachinePrecision])]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := F + 0.5 \cdot \frac{2 + x \cdot 2}{F}\\
\mathbf{if}\;B \leq 1.3 \cdot 10^{-279}:\\
\;\;\;\;\frac{-1 - x}{B}\\
\mathbf{elif}\;B \leq 1500000000:\\
\;\;\;\;\left(0.16666666666666666 \cdot \frac{F \cdot B}{t\_0} + \frac{F}{B \cdot t\_0}\right) - \frac{x}{B}\\
\mathbf{else}:\\
\;\;\;\;-\frac{x}{\tan B}\\
\end{array}
\end{array}
if B < 1.3000000000000001e-279Initial program 77.2%
distribute-lft-neg-in77.2%
+-commutative77.2%
associate-*l/85.5%
associate-/l*85.4%
fma-define85.4%
/-rgt-identity85.4%
remove-double-neg85.4%
fma-neg85.4%
Simplified85.5%
clear-num85.4%
inv-pow85.4%
fma-define85.4%
fma-undefine85.4%
*-commutative85.4%
fma-define85.4%
fma-define85.4%
Applied egg-rr85.4%
unpow-185.4%
Simplified85.4%
Taylor expanded in F around -inf 62.6%
Taylor expanded in B around 0 35.3%
mul-1-neg35.3%
distribute-neg-frac235.3%
Simplified35.3%
if 1.3000000000000001e-279 < B < 1.5e9Initial program 72.3%
Taylor expanded in B around 0 72.1%
+-commutative72.1%
unsub-neg72.1%
Applied egg-rr78.0%
Taylor expanded in F around inf 63.3%
Taylor expanded in B around 0 60.7%
if 1.5e9 < B Initial program 83.9%
distribute-lft-neg-in83.9%
+-commutative83.9%
fma-define83.9%
+-commutative83.9%
*-commutative83.9%
fma-define83.9%
fma-define83.9%
metadata-eval83.9%
metadata-eval83.9%
associate-*r/83.9%
*-rgt-identity83.9%
Simplified83.9%
Taylor expanded in F around 0 47.9%
mul-1-neg47.9%
associate-/l*48.0%
Simplified48.0%
clear-num48.0%
un-div-inv48.0%
quot-tan48.0%
Applied egg-rr48.0%
Final simplification44.6%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (+ F (* 0.5 (/ (+ 2.0 (* x 2.0)) F)))))
(if (<= F -1.15e+92)
(/ (- -1.0 x) B)
(if (<= F -1.65)
(/ -1.0 (sin B))
(-
(+ (* 0.16666666666666666 (/ (* F B) t_0)) (/ F (* B t_0)))
(/ x B))))))
double code(double F, double B, double x) {
double t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F));
double tmp;
if (F <= -1.15e+92) {
tmp = (-1.0 - x) / B;
} else if (F <= -1.65) {
tmp = -1.0 / sin(B);
} else {
tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B);
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: tmp
t_0 = f + (0.5d0 * ((2.0d0 + (x * 2.0d0)) / f))
if (f <= (-1.15d+92)) then
tmp = ((-1.0d0) - x) / b
else if (f <= (-1.65d0)) then
tmp = (-1.0d0) / sin(b)
else
tmp = ((0.16666666666666666d0 * ((f * b) / t_0)) + (f / (b * t_0))) - (x / b)
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F));
double tmp;
if (F <= -1.15e+92) {
tmp = (-1.0 - x) / B;
} else if (F <= -1.65) {
tmp = -1.0 / Math.sin(B);
} else {
tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B);
}
return tmp;
}
def code(F, B, x): t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F)) tmp = 0 if F <= -1.15e+92: tmp = (-1.0 - x) / B elif F <= -1.65: tmp = -1.0 / math.sin(B) else: tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B) return tmp
function code(F, B, x) t_0 = Float64(F + Float64(0.5 * Float64(Float64(2.0 + Float64(x * 2.0)) / F))) tmp = 0.0 if (F <= -1.15e+92) tmp = Float64(Float64(-1.0 - x) / B); elseif (F <= -1.65) tmp = Float64(-1.0 / sin(B)); else tmp = Float64(Float64(Float64(0.16666666666666666 * Float64(Float64(F * B) / t_0)) + Float64(F / Float64(B * t_0))) - Float64(x / B)); end return tmp end
function tmp_2 = code(F, B, x) t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F)); tmp = 0.0; if (F <= -1.15e+92) tmp = (-1.0 - x) / B; elseif (F <= -1.65) tmp = -1.0 / sin(B); else tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B); end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(F + N[(0.5 * N[(N[(2.0 + N[(x * 2.0), $MachinePrecision]), $MachinePrecision] / F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -1.15e+92], N[(N[(-1.0 - x), $MachinePrecision] / B), $MachinePrecision], If[LessEqual[F, -1.65], N[(-1.0 / N[Sin[B], $MachinePrecision]), $MachinePrecision], N[(N[(N[(0.16666666666666666 * N[(N[(F * B), $MachinePrecision] / t$95$0), $MachinePrecision]), $MachinePrecision] + N[(F / N[(B * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := F + 0.5 \cdot \frac{2 + x \cdot 2}{F}\\
\mathbf{if}\;F \leq -1.15 \cdot 10^{+92}:\\
\;\;\;\;\frac{-1 - x}{B}\\
\mathbf{elif}\;F \leq -1.65:\\
\;\;\;\;\frac{-1}{\sin B}\\
\mathbf{else}:\\
\;\;\;\;\left(0.16666666666666666 \cdot \frac{F \cdot B}{t\_0} + \frac{F}{B \cdot t\_0}\right) - \frac{x}{B}\\
\end{array}
\end{array}
if F < -1.14999999999999999e92Initial program 49.4%
distribute-lft-neg-in49.4%
+-commutative49.4%
associate-*l/63.4%
associate-/l*63.4%
fma-define63.4%
/-rgt-identity63.4%
remove-double-neg63.4%
fma-neg63.4%
Simplified63.5%
clear-num63.5%
inv-pow63.5%
fma-define63.5%
fma-undefine63.5%
*-commutative63.5%
fma-define63.5%
fma-define63.5%
Applied egg-rr63.5%
unpow-163.5%
Simplified63.5%
Taylor expanded in F around -inf 99.7%
Taylor expanded in B around 0 55.4%
mul-1-neg55.4%
distribute-neg-frac255.4%
Simplified55.4%
if -1.14999999999999999e92 < F < -1.6499999999999999Initial program 95.3%
distribute-lft-neg-in95.3%
+-commutative95.3%
associate-*l/99.7%
associate-/l*99.7%
fma-define99.7%
/-rgt-identity99.7%
remove-double-neg99.7%
fma-neg99.7%
Simplified99.8%
clear-num99.5%
inv-pow99.5%
fma-define99.5%
fma-undefine99.5%
*-commutative99.5%
fma-define99.5%
fma-define99.5%
Applied egg-rr99.5%
unpow-199.5%
Simplified99.5%
Taylor expanded in F around -inf 98.0%
Taylor expanded in x around 0 65.0%
if -1.6499999999999999 < F Initial program 86.4%
Taylor expanded in B around 0 61.1%
+-commutative61.1%
unsub-neg61.1%
Applied egg-rr63.7%
Taylor expanded in F around inf 48.0%
Taylor expanded in B around 0 38.7%
Final simplification45.0%
(FPCore (F B x)
:precision binary64
(let* ((t_0 (+ F (* 0.5 (/ (+ 2.0 (* x 2.0)) F)))))
(if (<= F -2.2e-50)
(/ (- -1.0 x) B)
(- (+ (* 0.16666666666666666 (/ (* F B) t_0)) (/ F (* B t_0))) (/ x B)))))
double code(double F, double B, double x) {
double t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F));
double tmp;
if (F <= -2.2e-50) {
tmp = (-1.0 - x) / B;
} else {
tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B);
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: tmp
t_0 = f + (0.5d0 * ((2.0d0 + (x * 2.0d0)) / f))
if (f <= (-2.2d-50)) then
tmp = ((-1.0d0) - x) / b
else
tmp = ((0.16666666666666666d0 * ((f * b) / t_0)) + (f / (b * t_0))) - (x / b)
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F));
double tmp;
if (F <= -2.2e-50) {
tmp = (-1.0 - x) / B;
} else {
tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B);
}
return tmp;
}
def code(F, B, x): t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F)) tmp = 0 if F <= -2.2e-50: tmp = (-1.0 - x) / B else: tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B) return tmp
function code(F, B, x) t_0 = Float64(F + Float64(0.5 * Float64(Float64(2.0 + Float64(x * 2.0)) / F))) tmp = 0.0 if (F <= -2.2e-50) tmp = Float64(Float64(-1.0 - x) / B); else tmp = Float64(Float64(Float64(0.16666666666666666 * Float64(Float64(F * B) / t_0)) + Float64(F / Float64(B * t_0))) - Float64(x / B)); end return tmp end
function tmp_2 = code(F, B, x) t_0 = F + (0.5 * ((2.0 + (x * 2.0)) / F)); tmp = 0.0; if (F <= -2.2e-50) tmp = (-1.0 - x) / B; else tmp = ((0.16666666666666666 * ((F * B) / t_0)) + (F / (B * t_0))) - (x / B); end tmp_2 = tmp; end
code[F_, B_, x_] := Block[{t$95$0 = N[(F + N[(0.5 * N[(N[(2.0 + N[(x * 2.0), $MachinePrecision]), $MachinePrecision] / F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[F, -2.2e-50], N[(N[(-1.0 - x), $MachinePrecision] / B), $MachinePrecision], N[(N[(N[(0.16666666666666666 * N[(N[(F * B), $MachinePrecision] / t$95$0), $MachinePrecision]), $MachinePrecision] + N[(F / N[(B * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := F + 0.5 \cdot \frac{2 + x \cdot 2}{F}\\
\mathbf{if}\;F \leq -2.2 \cdot 10^{-50}:\\
\;\;\;\;\frac{-1 - x}{B}\\
\mathbf{else}:\\
\;\;\;\;\left(0.16666666666666666 \cdot \frac{F \cdot B}{t\_0} + \frac{F}{B \cdot t\_0}\right) - \frac{x}{B}\\
\end{array}
\end{array}
if F < -2.1999999999999999e-50Initial program 64.3%
distribute-lft-neg-in64.3%
+-commutative64.3%
associate-*l/74.8%
associate-/l*74.8%
fma-define74.8%
/-rgt-identity74.8%
remove-double-neg74.8%
fma-neg74.8%
Simplified74.9%
clear-num74.8%
inv-pow74.8%
fma-define74.8%
fma-undefine74.8%
*-commutative74.8%
fma-define74.8%
fma-define74.8%
Applied egg-rr74.8%
unpow-174.8%
Simplified74.8%
Taylor expanded in F around -inf 92.7%
Taylor expanded in B around 0 49.5%
mul-1-neg49.5%
distribute-neg-frac249.5%
Simplified49.5%
if -2.1999999999999999e-50 < F Initial program 85.6%
Taylor expanded in B around 0 59.3%
+-commutative59.3%
unsub-neg59.3%
Applied egg-rr62.0%
Taylor expanded in F around inf 49.7%
Taylor expanded in B around 0 39.8%
Final simplification43.4%
(FPCore (F B x) :precision binary64 (if (<= F -6.9e-137) (/ (- -1.0 x) B) (/ (- (/ F (+ F (* 0.5 (/ (+ 2.0 (* x 2.0)) F)))) x) B)))
double code(double F, double B, double x) {
double tmp;
if (F <= -6.9e-137) {
tmp = (-1.0 - x) / B;
} else {
tmp = ((F / (F + (0.5 * ((2.0 + (x * 2.0)) / F)))) - x) / B;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: tmp
if (f <= (-6.9d-137)) then
tmp = ((-1.0d0) - x) / b
else
tmp = ((f / (f + (0.5d0 * ((2.0d0 + (x * 2.0d0)) / f)))) - x) / b
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double tmp;
if (F <= -6.9e-137) {
tmp = (-1.0 - x) / B;
} else {
tmp = ((F / (F + (0.5 * ((2.0 + (x * 2.0)) / F)))) - x) / B;
}
return tmp;
}
def code(F, B, x): tmp = 0 if F <= -6.9e-137: tmp = (-1.0 - x) / B else: tmp = ((F / (F + (0.5 * ((2.0 + (x * 2.0)) / F)))) - x) / B return tmp
function code(F, B, x) tmp = 0.0 if (F <= -6.9e-137) tmp = Float64(Float64(-1.0 - x) / B); else tmp = Float64(Float64(Float64(F / Float64(F + Float64(0.5 * Float64(Float64(2.0 + Float64(x * 2.0)) / F)))) - x) / B); end return tmp end
function tmp_2 = code(F, B, x) tmp = 0.0; if (F <= -6.9e-137) tmp = (-1.0 - x) / B; else tmp = ((F / (F + (0.5 * ((2.0 + (x * 2.0)) / F)))) - x) / B; end tmp_2 = tmp; end
code[F_, B_, x_] := If[LessEqual[F, -6.9e-137], N[(N[(-1.0 - x), $MachinePrecision] / B), $MachinePrecision], N[(N[(N[(F / N[(F + N[(0.5 * N[(N[(2.0 + N[(x * 2.0), $MachinePrecision]), $MachinePrecision] / F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision] / B), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;F \leq -6.9 \cdot 10^{-137}:\\
\;\;\;\;\frac{-1 - x}{B}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{F}{F + 0.5 \cdot \frac{2 + x \cdot 2}{F}} - x}{B}\\
\end{array}
\end{array}
if F < -6.89999999999999976e-137Initial program 68.2%
distribute-lft-neg-in68.2%
+-commutative68.2%
associate-*l/77.6%
associate-/l*77.6%
fma-define77.6%
/-rgt-identity77.6%
remove-double-neg77.6%
fma-neg77.6%
Simplified77.7%
clear-num77.6%
inv-pow77.6%
fma-define77.6%
fma-undefine77.6%
*-commutative77.6%
fma-define77.6%
fma-define77.6%
Applied egg-rr77.6%
unpow-177.6%
Simplified77.6%
Taylor expanded in F around -inf 85.5%
Taylor expanded in B around 0 45.4%
mul-1-neg45.4%
distribute-neg-frac245.4%
Simplified45.4%
if -6.89999999999999976e-137 < F Initial program 84.5%
Taylor expanded in B around 0 58.0%
+-commutative58.0%
unsub-neg58.0%
Applied egg-rr61.0%
Taylor expanded in F around inf 52.6%
Taylor expanded in B around 0 41.6%
Final simplification43.2%
(FPCore (F B x)
:precision binary64
(if (<= F -1.05e-50)
(/ (- -1.0 x) B)
(if (<= F 4.2e-51)
(/ x (- B))
(+ (* B 0.16666666666666666) (/ (- 1.0 x) B)))))
double code(double F, double B, double x) {
double tmp;
if (F <= -1.05e-50) {
tmp = (-1.0 - x) / B;
} else if (F <= 4.2e-51) {
tmp = x / -B;
} else {
tmp = (B * 0.16666666666666666) + ((1.0 - x) / B);
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: tmp
if (f <= (-1.05d-50)) then
tmp = ((-1.0d0) - x) / b
else if (f <= 4.2d-51) then
tmp = x / -b
else
tmp = (b * 0.16666666666666666d0) + ((1.0d0 - x) / b)
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double tmp;
if (F <= -1.05e-50) {
tmp = (-1.0 - x) / B;
} else if (F <= 4.2e-51) {
tmp = x / -B;
} else {
tmp = (B * 0.16666666666666666) + ((1.0 - x) / B);
}
return tmp;
}
def code(F, B, x): tmp = 0 if F <= -1.05e-50: tmp = (-1.0 - x) / B elif F <= 4.2e-51: tmp = x / -B else: tmp = (B * 0.16666666666666666) + ((1.0 - x) / B) return tmp
function code(F, B, x) tmp = 0.0 if (F <= -1.05e-50) tmp = Float64(Float64(-1.0 - x) / B); elseif (F <= 4.2e-51) tmp = Float64(x / Float64(-B)); else tmp = Float64(Float64(B * 0.16666666666666666) + Float64(Float64(1.0 - x) / B)); end return tmp end
function tmp_2 = code(F, B, x) tmp = 0.0; if (F <= -1.05e-50) tmp = (-1.0 - x) / B; elseif (F <= 4.2e-51) tmp = x / -B; else tmp = (B * 0.16666666666666666) + ((1.0 - x) / B); end tmp_2 = tmp; end
code[F_, B_, x_] := If[LessEqual[F, -1.05e-50], N[(N[(-1.0 - x), $MachinePrecision] / B), $MachinePrecision], If[LessEqual[F, 4.2e-51], N[(x / (-B)), $MachinePrecision], N[(N[(B * 0.16666666666666666), $MachinePrecision] + N[(N[(1.0 - x), $MachinePrecision] / B), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;F \leq -1.05 \cdot 10^{-50}:\\
\;\;\;\;\frac{-1 - x}{B}\\
\mathbf{elif}\;F \leq 4.2 \cdot 10^{-51}:\\
\;\;\;\;\frac{x}{-B}\\
\mathbf{else}:\\
\;\;\;\;B \cdot 0.16666666666666666 + \frac{1 - x}{B}\\
\end{array}
\end{array}
if F < -1.05e-50Initial program 64.3%
distribute-lft-neg-in64.3%
+-commutative64.3%
associate-*l/74.8%
associate-/l*74.8%
fma-define74.8%
/-rgt-identity74.8%
remove-double-neg74.8%
fma-neg74.8%
Simplified74.9%
clear-num74.8%
inv-pow74.8%
fma-define74.8%
fma-undefine74.8%
*-commutative74.8%
fma-define74.8%
fma-define74.8%
Applied egg-rr74.8%
unpow-174.8%
Simplified74.8%
Taylor expanded in F around -inf 92.7%
Taylor expanded in B around 0 49.5%
mul-1-neg49.5%
distribute-neg-frac249.5%
Simplified49.5%
if -1.05e-50 < F < 4.20000000000000003e-51Initial program 99.4%
Taylor expanded in B around 0 69.1%
Taylor expanded in x around inf 36.1%
mul-1-neg36.1%
distribute-neg-frac236.1%
Simplified36.1%
if 4.20000000000000003e-51 < F Initial program 65.7%
Taylor expanded in B around 0 45.1%
Taylor expanded in F around inf 54.8%
Taylor expanded in B around 0 44.8%
associate--l+44.8%
*-commutative44.8%
div-sub44.8%
Simplified44.8%
Final simplification43.3%
(FPCore (F B x) :precision binary64 (if (<= F -2.2e-51) (/ (- -1.0 x) B) (if (<= F 2.4e-85) (/ x (- B)) (- (/ 1.0 B) (/ x B)))))
double code(double F, double B, double x) {
double tmp;
if (F <= -2.2e-51) {
tmp = (-1.0 - x) / B;
} else if (F <= 2.4e-85) {
tmp = x / -B;
} else {
tmp = (1.0 / B) - (x / B);
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: tmp
if (f <= (-2.2d-51)) then
tmp = ((-1.0d0) - x) / b
else if (f <= 2.4d-85) then
tmp = x / -b
else
tmp = (1.0d0 / b) - (x / b)
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double tmp;
if (F <= -2.2e-51) {
tmp = (-1.0 - x) / B;
} else if (F <= 2.4e-85) {
tmp = x / -B;
} else {
tmp = (1.0 / B) - (x / B);
}
return tmp;
}
def code(F, B, x): tmp = 0 if F <= -2.2e-51: tmp = (-1.0 - x) / B elif F <= 2.4e-85: tmp = x / -B else: tmp = (1.0 / B) - (x / B) return tmp
function code(F, B, x) tmp = 0.0 if (F <= -2.2e-51) tmp = Float64(Float64(-1.0 - x) / B); elseif (F <= 2.4e-85) tmp = Float64(x / Float64(-B)); else tmp = Float64(Float64(1.0 / B) - Float64(x / B)); end return tmp end
function tmp_2 = code(F, B, x) tmp = 0.0; if (F <= -2.2e-51) tmp = (-1.0 - x) / B; elseif (F <= 2.4e-85) tmp = x / -B; else tmp = (1.0 / B) - (x / B); end tmp_2 = tmp; end
code[F_, B_, x_] := If[LessEqual[F, -2.2e-51], N[(N[(-1.0 - x), $MachinePrecision] / B), $MachinePrecision], If[LessEqual[F, 2.4e-85], N[(x / (-B)), $MachinePrecision], N[(N[(1.0 / B), $MachinePrecision] - N[(x / B), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;F \leq -2.2 \cdot 10^{-51}:\\
\;\;\;\;\frac{-1 - x}{B}\\
\mathbf{elif}\;F \leq 2.4 \cdot 10^{-85}:\\
\;\;\;\;\frac{x}{-B}\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{B} - \frac{x}{B}\\
\end{array}
\end{array}
if F < -2.2e-51Initial program 64.3%
distribute-lft-neg-in64.3%
+-commutative64.3%
associate-*l/74.8%
associate-/l*74.8%
fma-define74.8%
/-rgt-identity74.8%
remove-double-neg74.8%
fma-neg74.8%
Simplified74.9%
clear-num74.8%
inv-pow74.8%
fma-define74.8%
fma-undefine74.8%
*-commutative74.8%
fma-define74.8%
fma-define74.8%
Applied egg-rr74.8%
unpow-174.8%
Simplified74.8%
Taylor expanded in F around -inf 92.7%
Taylor expanded in B around 0 49.5%
mul-1-neg49.5%
distribute-neg-frac249.5%
Simplified49.5%
if -2.2e-51 < F < 2.4000000000000001e-85Initial program 99.4%
Taylor expanded in B around 0 68.4%
Taylor expanded in x around inf 39.0%
mul-1-neg39.0%
distribute-neg-frac239.0%
Simplified39.0%
if 2.4000000000000001e-85 < F Initial program 69.4%
Taylor expanded in B around 0 48.5%
Taylor expanded in F around inf 49.6%
Taylor expanded in B around 0 40.1%
div-sub40.1%
Applied egg-rr40.1%
Final simplification43.2%
(FPCore (F B x) :precision binary64 (if (<= F -1.25e-50) (/ (- -1.0 x) B) (if (<= F 2.9e-85) (/ x (- B)) (/ (- 1.0 x) B))))
double code(double F, double B, double x) {
double tmp;
if (F <= -1.25e-50) {
tmp = (-1.0 - x) / B;
} else if (F <= 2.9e-85) {
tmp = x / -B;
} else {
tmp = (1.0 - x) / B;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: tmp
if (f <= (-1.25d-50)) then
tmp = ((-1.0d0) - x) / b
else if (f <= 2.9d-85) then
tmp = x / -b
else
tmp = (1.0d0 - x) / b
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double tmp;
if (F <= -1.25e-50) {
tmp = (-1.0 - x) / B;
} else if (F <= 2.9e-85) {
tmp = x / -B;
} else {
tmp = (1.0 - x) / B;
}
return tmp;
}
def code(F, B, x): tmp = 0 if F <= -1.25e-50: tmp = (-1.0 - x) / B elif F <= 2.9e-85: tmp = x / -B else: tmp = (1.0 - x) / B return tmp
function code(F, B, x) tmp = 0.0 if (F <= -1.25e-50) tmp = Float64(Float64(-1.0 - x) / B); elseif (F <= 2.9e-85) tmp = Float64(x / Float64(-B)); else tmp = Float64(Float64(1.0 - x) / B); end return tmp end
function tmp_2 = code(F, B, x) tmp = 0.0; if (F <= -1.25e-50) tmp = (-1.0 - x) / B; elseif (F <= 2.9e-85) tmp = x / -B; else tmp = (1.0 - x) / B; end tmp_2 = tmp; end
code[F_, B_, x_] := If[LessEqual[F, -1.25e-50], N[(N[(-1.0 - x), $MachinePrecision] / B), $MachinePrecision], If[LessEqual[F, 2.9e-85], N[(x / (-B)), $MachinePrecision], N[(N[(1.0 - x), $MachinePrecision] / B), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;F \leq -1.25 \cdot 10^{-50}:\\
\;\;\;\;\frac{-1 - x}{B}\\
\mathbf{elif}\;F \leq 2.9 \cdot 10^{-85}:\\
\;\;\;\;\frac{x}{-B}\\
\mathbf{else}:\\
\;\;\;\;\frac{1 - x}{B}\\
\end{array}
\end{array}
if F < -1.24999999999999992e-50Initial program 64.3%
distribute-lft-neg-in64.3%
+-commutative64.3%
associate-*l/74.8%
associate-/l*74.8%
fma-define74.8%
/-rgt-identity74.8%
remove-double-neg74.8%
fma-neg74.8%
Simplified74.9%
clear-num74.8%
inv-pow74.8%
fma-define74.8%
fma-undefine74.8%
*-commutative74.8%
fma-define74.8%
fma-define74.8%
Applied egg-rr74.8%
unpow-174.8%
Simplified74.8%
Taylor expanded in F around -inf 92.7%
Taylor expanded in B around 0 49.5%
mul-1-neg49.5%
distribute-neg-frac249.5%
Simplified49.5%
if -1.24999999999999992e-50 < F < 2.9000000000000002e-85Initial program 99.4%
Taylor expanded in B around 0 68.4%
Taylor expanded in x around inf 39.0%
mul-1-neg39.0%
distribute-neg-frac239.0%
Simplified39.0%
if 2.9000000000000002e-85 < F Initial program 69.4%
Taylor expanded in B around 0 48.5%
Taylor expanded in F around inf 49.6%
Taylor expanded in B around 0 40.1%
Final simplification43.2%
(FPCore (F B x) :precision binary64 (if (<= F 1e-82) (/ x (- B)) (/ (- 1.0 x) B)))
double code(double F, double B, double x) {
double tmp;
if (F <= 1e-82) {
tmp = x / -B;
} else {
tmp = (1.0 - x) / B;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: tmp
if (f <= 1d-82) then
tmp = x / -b
else
tmp = (1.0d0 - x) / b
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double tmp;
if (F <= 1e-82) {
tmp = x / -B;
} else {
tmp = (1.0 - x) / B;
}
return tmp;
}
def code(F, B, x): tmp = 0 if F <= 1e-82: tmp = x / -B else: tmp = (1.0 - x) / B return tmp
function code(F, B, x) tmp = 0.0 if (F <= 1e-82) tmp = Float64(x / Float64(-B)); else tmp = Float64(Float64(1.0 - x) / B); end return tmp end
function tmp_2 = code(F, B, x) tmp = 0.0; if (F <= 1e-82) tmp = x / -B; else tmp = (1.0 - x) / B; end tmp_2 = tmp; end
code[F_, B_, x_] := If[LessEqual[F, 1e-82], N[(x / (-B)), $MachinePrecision], N[(N[(1.0 - x), $MachinePrecision] / B), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;F \leq 10^{-82}:\\
\;\;\;\;\frac{x}{-B}\\
\mathbf{else}:\\
\;\;\;\;\frac{1 - x}{B}\\
\end{array}
\end{array}
if F < 1e-82Initial program 81.1%
Taylor expanded in B around 0 54.3%
Taylor expanded in x around inf 31.6%
mul-1-neg31.6%
distribute-neg-frac231.6%
Simplified31.6%
if 1e-82 < F Initial program 69.4%
Taylor expanded in B around 0 48.5%
Taylor expanded in F around inf 49.6%
Taylor expanded in B around 0 40.1%
Final simplification34.1%
(FPCore (F B x) :precision binary64 (if (<= F 1500000.0) (/ x (- B)) (/ 1.0 B)))
double code(double F, double B, double x) {
double tmp;
if (F <= 1500000.0) {
tmp = x / -B;
} else {
tmp = 1.0 / B;
}
return tmp;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
real(8) :: tmp
if (f <= 1500000.0d0) then
tmp = x / -b
else
tmp = 1.0d0 / b
end if
code = tmp
end function
public static double code(double F, double B, double x) {
double tmp;
if (F <= 1500000.0) {
tmp = x / -B;
} else {
tmp = 1.0 / B;
}
return tmp;
}
def code(F, B, x): tmp = 0 if F <= 1500000.0: tmp = x / -B else: tmp = 1.0 / B return tmp
function code(F, B, x) tmp = 0.0 if (F <= 1500000.0) tmp = Float64(x / Float64(-B)); else tmp = Float64(1.0 / B); end return tmp end
function tmp_2 = code(F, B, x) tmp = 0.0; if (F <= 1500000.0) tmp = x / -B; else tmp = 1.0 / B; end tmp_2 = tmp; end
code[F_, B_, x_] := If[LessEqual[F, 1500000.0], N[(x / (-B)), $MachinePrecision], N[(1.0 / B), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;F \leq 1500000:\\
\;\;\;\;\frac{x}{-B}\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{B}\\
\end{array}
\end{array}
if F < 1.5e6Initial program 82.8%
Taylor expanded in B around 0 57.2%
Taylor expanded in x around inf 30.5%
mul-1-neg30.5%
distribute-neg-frac230.5%
Simplified30.5%
if 1.5e6 < F Initial program 59.0%
Taylor expanded in B around 0 36.1%
Taylor expanded in F around inf 59.1%
Taylor expanded in B around 0 46.9%
Taylor expanded in x around 0 33.2%
Final simplification31.1%
(FPCore (F B x) :precision binary64 (/ 1.0 B))
double code(double F, double B, double x) {
return 1.0 / B;
}
real(8) function code(f, b, x)
real(8), intent (in) :: f
real(8), intent (in) :: b
real(8), intent (in) :: x
code = 1.0d0 / b
end function
public static double code(double F, double B, double x) {
return 1.0 / B;
}
def code(F, B, x): return 1.0 / B
function code(F, B, x) return Float64(1.0 / B) end
function tmp = code(F, B, x) tmp = 1.0 / B; end
code[F_, B_, x_] := N[(1.0 / B), $MachinePrecision]
\begin{array}{l}
\\
\frac{1}{B}
\end{array}
Initial program 77.7%
Taylor expanded in B around 0 52.6%
Taylor expanded in F around inf 27.9%
Taylor expanded in B around 0 28.6%
Taylor expanded in x around 0 9.3%
Final simplification9.3%
herbie shell --seed 2024050
(FPCore (F B x)
:name "VandenBroeck and Keller, Equation (23)"
:precision binary64
(+ (- (* x (/ 1.0 (tan B)))) (* (/ F (sin B)) (pow (+ (+ (* F F) 2.0) (* 2.0 x)) (- (/ 1.0 2.0))))))