
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (* (* 3.0 x1) x1))
(t_1 (+ (* x1 x1) 1.0))
(t_2 (/ (- (+ t_0 (* 2.0 x2)) x1) t_1)))
(+
x1
(+
(+
(+
(+
(*
(+
(* (* (* 2.0 x1) t_2) (- t_2 3.0))
(* (* x1 x1) (- (* 4.0 t_2) 6.0)))
t_1)
(* t_0 t_2))
(* (* x1 x1) x1))
x1)
(* 3.0 (/ (- (- t_0 (* 2.0 x2)) x1) t_1))))))
double code(double x1, double x2) {
double t_0 = (3.0 * x1) * x1;
double t_1 = (x1 * x1) + 1.0;
double t_2 = ((t_0 + (2.0 * x2)) - x1) / t_1;
return x1 + (((((((((2.0 * x1) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((4.0 * t_2) - 6.0))) * t_1) + (t_0 * t_2)) + ((x1 * x1) * x1)) + x1) + (3.0 * (((t_0 - (2.0 * x2)) - x1) / t_1)));
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
t_0 = (3.0d0 * x1) * x1
t_1 = (x1 * x1) + 1.0d0
t_2 = ((t_0 + (2.0d0 * x2)) - x1) / t_1
code = x1 + (((((((((2.0d0 * x1) * t_2) * (t_2 - 3.0d0)) + ((x1 * x1) * ((4.0d0 * t_2) - 6.0d0))) * t_1) + (t_0 * t_2)) + ((x1 * x1) * x1)) + x1) + (3.0d0 * (((t_0 - (2.0d0 * x2)) - x1) / t_1)))
end function
public static double code(double x1, double x2) {
double t_0 = (3.0 * x1) * x1;
double t_1 = (x1 * x1) + 1.0;
double t_2 = ((t_0 + (2.0 * x2)) - x1) / t_1;
return x1 + (((((((((2.0 * x1) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((4.0 * t_2) - 6.0))) * t_1) + (t_0 * t_2)) + ((x1 * x1) * x1)) + x1) + (3.0 * (((t_0 - (2.0 * x2)) - x1) / t_1)));
}
def code(x1, x2): t_0 = (3.0 * x1) * x1 t_1 = (x1 * x1) + 1.0 t_2 = ((t_0 + (2.0 * x2)) - x1) / t_1 return x1 + (((((((((2.0 * x1) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((4.0 * t_2) - 6.0))) * t_1) + (t_0 * t_2)) + ((x1 * x1) * x1)) + x1) + (3.0 * (((t_0 - (2.0 * x2)) - x1) / t_1)))
function code(x1, x2) t_0 = Float64(Float64(3.0 * x1) * x1) t_1 = Float64(Float64(x1 * x1) + 1.0) t_2 = Float64(Float64(Float64(t_0 + Float64(2.0 * x2)) - x1) / t_1) return Float64(x1 + Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(2.0 * x1) * t_2) * Float64(t_2 - 3.0)) + Float64(Float64(x1 * x1) * Float64(Float64(4.0 * t_2) - 6.0))) * t_1) + Float64(t_0 * t_2)) + Float64(Float64(x1 * x1) * x1)) + x1) + Float64(3.0 * Float64(Float64(Float64(t_0 - Float64(2.0 * x2)) - x1) / t_1)))) end
function tmp = code(x1, x2) t_0 = (3.0 * x1) * x1; t_1 = (x1 * x1) + 1.0; t_2 = ((t_0 + (2.0 * x2)) - x1) / t_1; tmp = x1 + (((((((((2.0 * x1) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((4.0 * t_2) - 6.0))) * t_1) + (t_0 * t_2)) + ((x1 * x1) * x1)) + x1) + (3.0 * (((t_0 - (2.0 * x2)) - x1) / t_1))); end
code[x1_, x2_] := Block[{t$95$0 = N[(N[(3.0 * x1), $MachinePrecision] * x1), $MachinePrecision]}, Block[{t$95$1 = N[(N[(x1 * x1), $MachinePrecision] + 1.0), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(t$95$0 + N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$1), $MachinePrecision]}, N[(x1 + N[(N[(N[(N[(N[(N[(N[(N[(N[(2.0 * x1), $MachinePrecision] * t$95$2), $MachinePrecision] * N[(t$95$2 - 3.0), $MachinePrecision]), $MachinePrecision] + N[(N[(x1 * x1), $MachinePrecision] * N[(N[(4.0 * t$95$2), $MachinePrecision] - 6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * t$95$1), $MachinePrecision] + N[(t$95$0 * t$95$2), $MachinePrecision]), $MachinePrecision] + N[(N[(x1 * x1), $MachinePrecision] * x1), $MachinePrecision]), $MachinePrecision] + x1), $MachinePrecision] + N[(3.0 * N[(N[(N[(t$95$0 - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \left(3 \cdot x1\right) \cdot x1\\
t_1 := x1 \cdot x1 + 1\\
t_2 := \frac{\left(t\_0 + 2 \cdot x2\right) - x1}{t\_1}\\
x1 + \left(\left(\left(\left(\left(\left(\left(2 \cdot x1\right) \cdot t\_2\right) \cdot \left(t\_2 - 3\right) + \left(x1 \cdot x1\right) \cdot \left(4 \cdot t\_2 - 6\right)\right) \cdot t\_1 + t\_0 \cdot t\_2\right) + \left(x1 \cdot x1\right) \cdot x1\right) + x1\right) + 3 \cdot \frac{\left(t\_0 - 2 \cdot x2\right) - x1}{t\_1}\right)
\end{array}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 28 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (* (* 3.0 x1) x1))
(t_1 (+ (* x1 x1) 1.0))
(t_2 (/ (- (+ t_0 (* 2.0 x2)) x1) t_1)))
(+
x1
(+
(+
(+
(+
(*
(+
(* (* (* 2.0 x1) t_2) (- t_2 3.0))
(* (* x1 x1) (- (* 4.0 t_2) 6.0)))
t_1)
(* t_0 t_2))
(* (* x1 x1) x1))
x1)
(* 3.0 (/ (- (- t_0 (* 2.0 x2)) x1) t_1))))))
double code(double x1, double x2) {
double t_0 = (3.0 * x1) * x1;
double t_1 = (x1 * x1) + 1.0;
double t_2 = ((t_0 + (2.0 * x2)) - x1) / t_1;
return x1 + (((((((((2.0 * x1) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((4.0 * t_2) - 6.0))) * t_1) + (t_0 * t_2)) + ((x1 * x1) * x1)) + x1) + (3.0 * (((t_0 - (2.0 * x2)) - x1) / t_1)));
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
t_0 = (3.0d0 * x1) * x1
t_1 = (x1 * x1) + 1.0d0
t_2 = ((t_0 + (2.0d0 * x2)) - x1) / t_1
code = x1 + (((((((((2.0d0 * x1) * t_2) * (t_2 - 3.0d0)) + ((x1 * x1) * ((4.0d0 * t_2) - 6.0d0))) * t_1) + (t_0 * t_2)) + ((x1 * x1) * x1)) + x1) + (3.0d0 * (((t_0 - (2.0d0 * x2)) - x1) / t_1)))
end function
public static double code(double x1, double x2) {
double t_0 = (3.0 * x1) * x1;
double t_1 = (x1 * x1) + 1.0;
double t_2 = ((t_0 + (2.0 * x2)) - x1) / t_1;
return x1 + (((((((((2.0 * x1) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((4.0 * t_2) - 6.0))) * t_1) + (t_0 * t_2)) + ((x1 * x1) * x1)) + x1) + (3.0 * (((t_0 - (2.0 * x2)) - x1) / t_1)));
}
def code(x1, x2): t_0 = (3.0 * x1) * x1 t_1 = (x1 * x1) + 1.0 t_2 = ((t_0 + (2.0 * x2)) - x1) / t_1 return x1 + (((((((((2.0 * x1) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((4.0 * t_2) - 6.0))) * t_1) + (t_0 * t_2)) + ((x1 * x1) * x1)) + x1) + (3.0 * (((t_0 - (2.0 * x2)) - x1) / t_1)))
function code(x1, x2) t_0 = Float64(Float64(3.0 * x1) * x1) t_1 = Float64(Float64(x1 * x1) + 1.0) t_2 = Float64(Float64(Float64(t_0 + Float64(2.0 * x2)) - x1) / t_1) return Float64(x1 + Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(2.0 * x1) * t_2) * Float64(t_2 - 3.0)) + Float64(Float64(x1 * x1) * Float64(Float64(4.0 * t_2) - 6.0))) * t_1) + Float64(t_0 * t_2)) + Float64(Float64(x1 * x1) * x1)) + x1) + Float64(3.0 * Float64(Float64(Float64(t_0 - Float64(2.0 * x2)) - x1) / t_1)))) end
function tmp = code(x1, x2) t_0 = (3.0 * x1) * x1; t_1 = (x1 * x1) + 1.0; t_2 = ((t_0 + (2.0 * x2)) - x1) / t_1; tmp = x1 + (((((((((2.0 * x1) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((4.0 * t_2) - 6.0))) * t_1) + (t_0 * t_2)) + ((x1 * x1) * x1)) + x1) + (3.0 * (((t_0 - (2.0 * x2)) - x1) / t_1))); end
code[x1_, x2_] := Block[{t$95$0 = N[(N[(3.0 * x1), $MachinePrecision] * x1), $MachinePrecision]}, Block[{t$95$1 = N[(N[(x1 * x1), $MachinePrecision] + 1.0), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(t$95$0 + N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$1), $MachinePrecision]}, N[(x1 + N[(N[(N[(N[(N[(N[(N[(N[(N[(2.0 * x1), $MachinePrecision] * t$95$2), $MachinePrecision] * N[(t$95$2 - 3.0), $MachinePrecision]), $MachinePrecision] + N[(N[(x1 * x1), $MachinePrecision] * N[(N[(4.0 * t$95$2), $MachinePrecision] - 6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * t$95$1), $MachinePrecision] + N[(t$95$0 * t$95$2), $MachinePrecision]), $MachinePrecision] + N[(N[(x1 * x1), $MachinePrecision] * x1), $MachinePrecision]), $MachinePrecision] + x1), $MachinePrecision] + N[(3.0 * N[(N[(N[(t$95$0 - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \left(3 \cdot x1\right) \cdot x1\\
t_1 := x1 \cdot x1 + 1\\
t_2 := \frac{\left(t\_0 + 2 \cdot x2\right) - x1}{t\_1}\\
x1 + \left(\left(\left(\left(\left(\left(\left(2 \cdot x1\right) \cdot t\_2\right) \cdot \left(t\_2 - 3\right) + \left(x1 \cdot x1\right) \cdot \left(4 \cdot t\_2 - 6\right)\right) \cdot t\_1 + t\_0 \cdot t\_2\right) + \left(x1 \cdot x1\right) \cdot x1\right) + x1\right) + 3 \cdot \frac{\left(t\_0 - 2 \cdot x2\right) - x1}{t\_1}\right)
\end{array}
\end{array}
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (* x1 (* x1 3.0)))
(t_1 (+ (* x1 x1) 1.0))
(t_2 (/ (- (+ t_0 (* 2.0 x2)) x1) t_1))
(t_3
(+
x1
(+
(+
x1
(+
(+
(*
t_1
(+
(* (* (* x1 2.0) t_2) (- t_2 3.0))
(* (* x1 x1) (- (* t_2 4.0) 6.0))))
(* t_0 t_2))
(* x1 (* x1 x1))))
(* 3.0 (/ (- (- t_0 (* 2.0 x2)) x1) t_1))))))
(if (<= t_3 INFINITY) t_3 (- (* (pow x1 4.0) (+ 6.0 (/ -3.0 x1))) x1))))
double code(double x1, double x2) {
double t_0 = x1 * (x1 * 3.0);
double t_1 = (x1 * x1) + 1.0;
double t_2 = ((t_0 + (2.0 * x2)) - x1) / t_1;
double t_3 = x1 + ((x1 + (((t_1 * ((((x1 * 2.0) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((t_2 * 4.0) - 6.0)))) + (t_0 * t_2)) + (x1 * (x1 * x1)))) + (3.0 * (((t_0 - (2.0 * x2)) - x1) / t_1)));
double tmp;
if (t_3 <= ((double) INFINITY)) {
tmp = t_3;
} else {
tmp = (pow(x1, 4.0) * (6.0 + (-3.0 / x1))) - x1;
}
return tmp;
}
public static double code(double x1, double x2) {
double t_0 = x1 * (x1 * 3.0);
double t_1 = (x1 * x1) + 1.0;
double t_2 = ((t_0 + (2.0 * x2)) - x1) / t_1;
double t_3 = x1 + ((x1 + (((t_1 * ((((x1 * 2.0) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((t_2 * 4.0) - 6.0)))) + (t_0 * t_2)) + (x1 * (x1 * x1)))) + (3.0 * (((t_0 - (2.0 * x2)) - x1) / t_1)));
double tmp;
if (t_3 <= Double.POSITIVE_INFINITY) {
tmp = t_3;
} else {
tmp = (Math.pow(x1, 4.0) * (6.0 + (-3.0 / x1))) - x1;
}
return tmp;
}
def code(x1, x2): t_0 = x1 * (x1 * 3.0) t_1 = (x1 * x1) + 1.0 t_2 = ((t_0 + (2.0 * x2)) - x1) / t_1 t_3 = x1 + ((x1 + (((t_1 * ((((x1 * 2.0) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((t_2 * 4.0) - 6.0)))) + (t_0 * t_2)) + (x1 * (x1 * x1)))) + (3.0 * (((t_0 - (2.0 * x2)) - x1) / t_1))) tmp = 0 if t_3 <= math.inf: tmp = t_3 else: tmp = (math.pow(x1, 4.0) * (6.0 + (-3.0 / x1))) - x1 return tmp
function code(x1, x2) t_0 = Float64(x1 * Float64(x1 * 3.0)) t_1 = Float64(Float64(x1 * x1) + 1.0) t_2 = Float64(Float64(Float64(t_0 + Float64(2.0 * x2)) - x1) / t_1) t_3 = Float64(x1 + Float64(Float64(x1 + Float64(Float64(Float64(t_1 * Float64(Float64(Float64(Float64(x1 * 2.0) * t_2) * Float64(t_2 - 3.0)) + Float64(Float64(x1 * x1) * Float64(Float64(t_2 * 4.0) - 6.0)))) + Float64(t_0 * t_2)) + Float64(x1 * Float64(x1 * x1)))) + Float64(3.0 * Float64(Float64(Float64(t_0 - Float64(2.0 * x2)) - x1) / t_1)))) tmp = 0.0 if (t_3 <= Inf) tmp = t_3; else tmp = Float64(Float64((x1 ^ 4.0) * Float64(6.0 + Float64(-3.0 / x1))) - x1); end return tmp end
function tmp_2 = code(x1, x2) t_0 = x1 * (x1 * 3.0); t_1 = (x1 * x1) + 1.0; t_2 = ((t_0 + (2.0 * x2)) - x1) / t_1; t_3 = x1 + ((x1 + (((t_1 * ((((x1 * 2.0) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((t_2 * 4.0) - 6.0)))) + (t_0 * t_2)) + (x1 * (x1 * x1)))) + (3.0 * (((t_0 - (2.0 * x2)) - x1) / t_1))); tmp = 0.0; if (t_3 <= Inf) tmp = t_3; else tmp = ((x1 ^ 4.0) * (6.0 + (-3.0 / x1))) - x1; end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(x1 * N[(x1 * 3.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[(x1 * x1), $MachinePrecision] + 1.0), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(t$95$0 + N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$1), $MachinePrecision]}, Block[{t$95$3 = N[(x1 + N[(N[(x1 + N[(N[(N[(t$95$1 * N[(N[(N[(N[(x1 * 2.0), $MachinePrecision] * t$95$2), $MachinePrecision] * N[(t$95$2 - 3.0), $MachinePrecision]), $MachinePrecision] + N[(N[(x1 * x1), $MachinePrecision] * N[(N[(t$95$2 * 4.0), $MachinePrecision] - 6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(t$95$0 * t$95$2), $MachinePrecision]), $MachinePrecision] + N[(x1 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(3.0 * N[(N[(N[(t$95$0 - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$3, Infinity], t$95$3, N[(N[(N[Power[x1, 4.0], $MachinePrecision] * N[(6.0 + N[(-3.0 / x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 \cdot \left(x1 \cdot 3\right)\\
t_1 := x1 \cdot x1 + 1\\
t_2 := \frac{\left(t\_0 + 2 \cdot x2\right) - x1}{t\_1}\\
t_3 := x1 + \left(\left(x1 + \left(\left(t\_1 \cdot \left(\left(\left(x1 \cdot 2\right) \cdot t\_2\right) \cdot \left(t\_2 - 3\right) + \left(x1 \cdot x1\right) \cdot \left(t\_2 \cdot 4 - 6\right)\right) + t\_0 \cdot t\_2\right) + x1 \cdot \left(x1 \cdot x1\right)\right)\right) + 3 \cdot \frac{\left(t\_0 - 2 \cdot x2\right) - x1}{t\_1}\right)\\
\mathbf{if}\;t\_3 \leq \infty:\\
\;\;\;\;t\_3\\
\mathbf{else}:\\
\;\;\;\;{x1}^{4} \cdot \left(6 + \frac{-3}{x1}\right) - x1\\
\end{array}
\end{array}
if (+.f64 x1 (+.f64 (+.f64 (+.f64 (+.f64 (*.f64 (+.f64 (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) x1) (/.f64 (-.f64 (+.f64 (*.f64 (*.f64 #s(literal 3 binary64) x1) x1) (*.f64 #s(literal 2 binary64) x2)) x1) (+.f64 (*.f64 x1 x1) #s(literal 1 binary64)))) (-.f64 (/.f64 (-.f64 (+.f64 (*.f64 (*.f64 #s(literal 3 binary64) x1) x1) (*.f64 #s(literal 2 binary64) x2)) x1) (+.f64 (*.f64 x1 x1) #s(literal 1 binary64))) #s(literal 3 binary64))) (*.f64 (*.f64 x1 x1) (-.f64 (*.f64 #s(literal 4 binary64) (/.f64 (-.f64 (+.f64 (*.f64 (*.f64 #s(literal 3 binary64) x1) x1) (*.f64 #s(literal 2 binary64) x2)) x1) (+.f64 (*.f64 x1 x1) #s(literal 1 binary64)))) #s(literal 6 binary64)))) (+.f64 (*.f64 x1 x1) #s(literal 1 binary64))) (*.f64 (*.f64 (*.f64 #s(literal 3 binary64) x1) x1) (/.f64 (-.f64 (+.f64 (*.f64 (*.f64 #s(literal 3 binary64) x1) x1) (*.f64 #s(literal 2 binary64) x2)) x1) (+.f64 (*.f64 x1 x1) #s(literal 1 binary64))))) (*.f64 (*.f64 x1 x1) x1)) x1) (*.f64 #s(literal 3 binary64) (/.f64 (-.f64 (-.f64 (*.f64 (*.f64 #s(literal 3 binary64) x1) x1) (*.f64 #s(literal 2 binary64) x2)) x1) (+.f64 (*.f64 x1 x1) #s(literal 1 binary64)))))) < +inf.0Initial program 99.4%
if +inf.0 < (+.f64 x1 (+.f64 (+.f64 (+.f64 (+.f64 (*.f64 (+.f64 (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) x1) (/.f64 (-.f64 (+.f64 (*.f64 (*.f64 #s(literal 3 binary64) x1) x1) (*.f64 #s(literal 2 binary64) x2)) x1) (+.f64 (*.f64 x1 x1) #s(literal 1 binary64)))) (-.f64 (/.f64 (-.f64 (+.f64 (*.f64 (*.f64 #s(literal 3 binary64) x1) x1) (*.f64 #s(literal 2 binary64) x2)) x1) (+.f64 (*.f64 x1 x1) #s(literal 1 binary64))) #s(literal 3 binary64))) (*.f64 (*.f64 x1 x1) (-.f64 (*.f64 #s(literal 4 binary64) (/.f64 (-.f64 (+.f64 (*.f64 (*.f64 #s(literal 3 binary64) x1) x1) (*.f64 #s(literal 2 binary64) x2)) x1) (+.f64 (*.f64 x1 x1) #s(literal 1 binary64)))) #s(literal 6 binary64)))) (+.f64 (*.f64 x1 x1) #s(literal 1 binary64))) (*.f64 (*.f64 (*.f64 #s(literal 3 binary64) x1) x1) (/.f64 (-.f64 (+.f64 (*.f64 (*.f64 #s(literal 3 binary64) x1) x1) (*.f64 #s(literal 2 binary64) x2)) x1) (+.f64 (*.f64 x1 x1) #s(literal 1 binary64))))) (*.f64 (*.f64 x1 x1) x1)) x1) (*.f64 #s(literal 3 binary64) (/.f64 (-.f64 (-.f64 (*.f64 (*.f64 #s(literal 3 binary64) x1) x1) (*.f64 #s(literal 2 binary64) x2)) x1) (+.f64 (*.f64 x1 x1) #s(literal 1 binary64)))))) Initial program 0.0%
Taylor expanded in x1 around inf 0.0%
Taylor expanded in x1 around 0 0.0%
mul-1-neg0.0%
unsub-neg0.0%
*-commutative0.0%
Simplified0.0%
Taylor expanded in x1 around inf 98.8%
associate-*r/98.8%
metadata-eval98.8%
Simplified98.8%
Taylor expanded in x2 around 0 98.8%
associate-+r+98.8%
distribute-rgt-out98.8%
metadata-eval98.8%
*-commutative98.8%
mul-1-neg98.8%
sub-neg98.8%
associate-*r/98.8%
metadata-eval98.8%
distribute-neg-frac98.8%
metadata-eval98.8%
Simplified98.8%
Final simplification99.2%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (+ (* x1 x1) 1.0))
(t_1 (* x1 (* x1 3.0)))
(t_2 (/ (- (+ t_1 (* 2.0 x2)) x1) t_0))
(t_3 (* 3.0 (- (* x2 -2.0) x1))))
(if (<= x1 -2e+103)
(+ x1 (+ (+ x1 (* x1 (* x1 (+ 9.0 (* x1 -19.0))))) t_3))
(if (<= x1 2.3e+62)
(+
x1
(+
t_3
(+
x1
(+
(* x1 (* x1 x1))
(+
(*
t_0
(+
(* (* (* x1 2.0) t_2) (- t_2 3.0))
(* (* x1 x1) (- (* t_2 4.0) 6.0))))
(* 3.0 t_1))))))
(- (* (pow x1 4.0) (+ 6.0 (/ -3.0 x1))) x1)))))
double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = x1 * (x1 * 3.0);
double t_2 = ((t_1 + (2.0 * x2)) - x1) / t_0;
double t_3 = 3.0 * ((x2 * -2.0) - x1);
double tmp;
if (x1 <= -2e+103) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3);
} else if (x1 <= 2.3e+62) {
tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((t_0 * ((((x1 * 2.0) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((t_2 * 4.0) - 6.0)))) + (3.0 * t_1)))));
} else {
tmp = (pow(x1, 4.0) * (6.0 + (-3.0 / x1))) - x1;
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: tmp
t_0 = (x1 * x1) + 1.0d0
t_1 = x1 * (x1 * 3.0d0)
t_2 = ((t_1 + (2.0d0 * x2)) - x1) / t_0
t_3 = 3.0d0 * ((x2 * (-2.0d0)) - x1)
if (x1 <= (-2d+103)) then
tmp = x1 + ((x1 + (x1 * (x1 * (9.0d0 + (x1 * (-19.0d0)))))) + t_3)
else if (x1 <= 2.3d+62) then
tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((t_0 * ((((x1 * 2.0d0) * t_2) * (t_2 - 3.0d0)) + ((x1 * x1) * ((t_2 * 4.0d0) - 6.0d0)))) + (3.0d0 * t_1)))))
else
tmp = ((x1 ** 4.0d0) * (6.0d0 + ((-3.0d0) / x1))) - x1
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = x1 * (x1 * 3.0);
double t_2 = ((t_1 + (2.0 * x2)) - x1) / t_0;
double t_3 = 3.0 * ((x2 * -2.0) - x1);
double tmp;
if (x1 <= -2e+103) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3);
} else if (x1 <= 2.3e+62) {
tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((t_0 * ((((x1 * 2.0) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((t_2 * 4.0) - 6.0)))) + (3.0 * t_1)))));
} else {
tmp = (Math.pow(x1, 4.0) * (6.0 + (-3.0 / x1))) - x1;
}
return tmp;
}
def code(x1, x2): t_0 = (x1 * x1) + 1.0 t_1 = x1 * (x1 * 3.0) t_2 = ((t_1 + (2.0 * x2)) - x1) / t_0 t_3 = 3.0 * ((x2 * -2.0) - x1) tmp = 0 if x1 <= -2e+103: tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3) elif x1 <= 2.3e+62: tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((t_0 * ((((x1 * 2.0) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((t_2 * 4.0) - 6.0)))) + (3.0 * t_1))))) else: tmp = (math.pow(x1, 4.0) * (6.0 + (-3.0 / x1))) - x1 return tmp
function code(x1, x2) t_0 = Float64(Float64(x1 * x1) + 1.0) t_1 = Float64(x1 * Float64(x1 * 3.0)) t_2 = Float64(Float64(Float64(t_1 + Float64(2.0 * x2)) - x1) / t_0) t_3 = Float64(3.0 * Float64(Float64(x2 * -2.0) - x1)) tmp = 0.0 if (x1 <= -2e+103) tmp = Float64(x1 + Float64(Float64(x1 + Float64(x1 * Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))) + t_3)); elseif (x1 <= 2.3e+62) tmp = Float64(x1 + Float64(t_3 + Float64(x1 + Float64(Float64(x1 * Float64(x1 * x1)) + Float64(Float64(t_0 * Float64(Float64(Float64(Float64(x1 * 2.0) * t_2) * Float64(t_2 - 3.0)) + Float64(Float64(x1 * x1) * Float64(Float64(t_2 * 4.0) - 6.0)))) + Float64(3.0 * t_1)))))); else tmp = Float64(Float64((x1 ^ 4.0) * Float64(6.0 + Float64(-3.0 / x1))) - x1); end return tmp end
function tmp_2 = code(x1, x2) t_0 = (x1 * x1) + 1.0; t_1 = x1 * (x1 * 3.0); t_2 = ((t_1 + (2.0 * x2)) - x1) / t_0; t_3 = 3.0 * ((x2 * -2.0) - x1); tmp = 0.0; if (x1 <= -2e+103) tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3); elseif (x1 <= 2.3e+62) tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((t_0 * ((((x1 * 2.0) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((t_2 * 4.0) - 6.0)))) + (3.0 * t_1))))); else tmp = ((x1 ^ 4.0) * (6.0 + (-3.0 / x1))) - x1; end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(N[(x1 * x1), $MachinePrecision] + 1.0), $MachinePrecision]}, Block[{t$95$1 = N[(x1 * N[(x1 * 3.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(t$95$1 + N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$0), $MachinePrecision]}, Block[{t$95$3 = N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] - x1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -2e+103], N[(x1 + N[(N[(x1 + N[(x1 * N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$3), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 2.3e+62], N[(x1 + N[(t$95$3 + N[(x1 + N[(N[(x1 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision] + N[(N[(t$95$0 * N[(N[(N[(N[(x1 * 2.0), $MachinePrecision] * t$95$2), $MachinePrecision] * N[(t$95$2 - 3.0), $MachinePrecision]), $MachinePrecision] + N[(N[(x1 * x1), $MachinePrecision] * N[(N[(t$95$2 * 4.0), $MachinePrecision] - 6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(3.0 * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[Power[x1, 4.0], $MachinePrecision] * N[(6.0 + N[(-3.0 / x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 \cdot x1 + 1\\
t_1 := x1 \cdot \left(x1 \cdot 3\right)\\
t_2 := \frac{\left(t\_1 + 2 \cdot x2\right) - x1}{t\_0}\\
t_3 := 3 \cdot \left(x2 \cdot -2 - x1\right)\\
\mathbf{if}\;x1 \leq -2 \cdot 10^{+103}:\\
\;\;\;\;x1 + \left(\left(x1 + x1 \cdot \left(x1 \cdot \left(9 + x1 \cdot -19\right)\right)\right) + t\_3\right)\\
\mathbf{elif}\;x1 \leq 2.3 \cdot 10^{+62}:\\
\;\;\;\;x1 + \left(t\_3 + \left(x1 + \left(x1 \cdot \left(x1 \cdot x1\right) + \left(t\_0 \cdot \left(\left(\left(x1 \cdot 2\right) \cdot t\_2\right) \cdot \left(t\_2 - 3\right) + \left(x1 \cdot x1\right) \cdot \left(t\_2 \cdot 4 - 6\right)\right) + 3 \cdot t\_1\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;{x1}^{4} \cdot \left(6 + \frac{-3}{x1}\right) - x1\\
\end{array}
\end{array}
if x1 < -2e103Initial program 0.0%
Taylor expanded in x1 around inf 0.0%
Taylor expanded in x1 around 0 0.0%
mul-1-neg0.0%
unsub-neg0.0%
*-commutative0.0%
Simplified0.0%
Taylor expanded in x1 around 0 70.4%
Taylor expanded in x2 around 0 100.0%
*-commutative100.0%
Simplified100.0%
if -2e103 < x1 < 2.29999999999999984e62Initial program 99.4%
Taylor expanded in x1 around inf 98.7%
Taylor expanded in x1 around 0 99.3%
mul-1-neg99.3%
unsub-neg99.3%
*-commutative99.3%
Simplified99.3%
if 2.29999999999999984e62 < x1 Initial program 42.2%
Taylor expanded in x1 around inf 42.2%
Taylor expanded in x1 around 0 42.2%
mul-1-neg42.2%
unsub-neg42.2%
*-commutative42.2%
Simplified42.2%
Taylor expanded in x1 around inf 97.8%
associate-*r/97.8%
metadata-eval97.8%
Simplified97.8%
Taylor expanded in x2 around 0 97.8%
associate-+r+97.8%
distribute-rgt-out97.8%
metadata-eval97.8%
*-commutative97.8%
mul-1-neg97.8%
sub-neg97.8%
associate-*r/97.8%
metadata-eval97.8%
distribute-neg-frac97.8%
metadata-eval97.8%
Simplified97.8%
Final simplification99.2%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (+ (* x1 x1) 1.0))
(t_1 (* x1 (* x1 3.0)))
(t_2 (/ (- (+ t_1 (* 2.0 x2)) x1) t_0))
(t_3 (* 3.0 (- (* x2 -2.0) x1))))
(if (<= x1 -5e+102)
(+ x1 (+ (+ x1 (* x1 (* x1 (+ 9.0 (* x1 -19.0))))) t_3))
(if (<= x1 1e+152)
(+
x1
(+
t_3
(+
x1
(+
(* x1 (* x1 x1))
(+
(*
t_0
(+
(* (* (* x1 2.0) t_2) (- t_2 3.0))
(* (* x1 x1) (- (* t_2 4.0) 6.0))))
(* 3.0 t_1))))))
(+
x1
(+
t_3
(+
x1
(*
x1
(+
(* 4.0 (* x2 (- (* 2.0 x2) 3.0)))
(*
x1
(+
3.0
(+
(* 2.0 (+ (* x2 -2.0) (- 3.0 (* 2.0 x2))))
(* x2 8.0)))))))))))))
double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = x1 * (x1 * 3.0);
double t_2 = ((t_1 + (2.0 * x2)) - x1) / t_0;
double t_3 = 3.0 * ((x2 * -2.0) - x1);
double tmp;
if (x1 <= -5e+102) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3);
} else if (x1 <= 1e+152) {
tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((t_0 * ((((x1 * 2.0) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((t_2 * 4.0) - 6.0)))) + (3.0 * t_1)))));
} else {
tmp = x1 + (t_3 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0))))))));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: tmp
t_0 = (x1 * x1) + 1.0d0
t_1 = x1 * (x1 * 3.0d0)
t_2 = ((t_1 + (2.0d0 * x2)) - x1) / t_0
t_3 = 3.0d0 * ((x2 * (-2.0d0)) - x1)
if (x1 <= (-5d+102)) then
tmp = x1 + ((x1 + (x1 * (x1 * (9.0d0 + (x1 * (-19.0d0)))))) + t_3)
else if (x1 <= 1d+152) then
tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((t_0 * ((((x1 * 2.0d0) * t_2) * (t_2 - 3.0d0)) + ((x1 * x1) * ((t_2 * 4.0d0) - 6.0d0)))) + (3.0d0 * t_1)))))
else
tmp = x1 + (t_3 + (x1 + (x1 * ((4.0d0 * (x2 * ((2.0d0 * x2) - 3.0d0))) + (x1 * (3.0d0 + ((2.0d0 * ((x2 * (-2.0d0)) + (3.0d0 - (2.0d0 * x2)))) + (x2 * 8.0d0))))))))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = x1 * (x1 * 3.0);
double t_2 = ((t_1 + (2.0 * x2)) - x1) / t_0;
double t_3 = 3.0 * ((x2 * -2.0) - x1);
double tmp;
if (x1 <= -5e+102) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3);
} else if (x1 <= 1e+152) {
tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((t_0 * ((((x1 * 2.0) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((t_2 * 4.0) - 6.0)))) + (3.0 * t_1)))));
} else {
tmp = x1 + (t_3 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0))))))));
}
return tmp;
}
def code(x1, x2): t_0 = (x1 * x1) + 1.0 t_1 = x1 * (x1 * 3.0) t_2 = ((t_1 + (2.0 * x2)) - x1) / t_0 t_3 = 3.0 * ((x2 * -2.0) - x1) tmp = 0 if x1 <= -5e+102: tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3) elif x1 <= 1e+152: tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((t_0 * ((((x1 * 2.0) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((t_2 * 4.0) - 6.0)))) + (3.0 * t_1))))) else: tmp = x1 + (t_3 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0)))))))) return tmp
function code(x1, x2) t_0 = Float64(Float64(x1 * x1) + 1.0) t_1 = Float64(x1 * Float64(x1 * 3.0)) t_2 = Float64(Float64(Float64(t_1 + Float64(2.0 * x2)) - x1) / t_0) t_3 = Float64(3.0 * Float64(Float64(x2 * -2.0) - x1)) tmp = 0.0 if (x1 <= -5e+102) tmp = Float64(x1 + Float64(Float64(x1 + Float64(x1 * Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))) + t_3)); elseif (x1 <= 1e+152) tmp = Float64(x1 + Float64(t_3 + Float64(x1 + Float64(Float64(x1 * Float64(x1 * x1)) + Float64(Float64(t_0 * Float64(Float64(Float64(Float64(x1 * 2.0) * t_2) * Float64(t_2 - 3.0)) + Float64(Float64(x1 * x1) * Float64(Float64(t_2 * 4.0) - 6.0)))) + Float64(3.0 * t_1)))))); else tmp = Float64(x1 + Float64(t_3 + Float64(x1 + Float64(x1 * Float64(Float64(4.0 * Float64(x2 * Float64(Float64(2.0 * x2) - 3.0))) + Float64(x1 * Float64(3.0 + Float64(Float64(2.0 * Float64(Float64(x2 * -2.0) + Float64(3.0 - Float64(2.0 * x2)))) + Float64(x2 * 8.0))))))))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = (x1 * x1) + 1.0; t_1 = x1 * (x1 * 3.0); t_2 = ((t_1 + (2.0 * x2)) - x1) / t_0; t_3 = 3.0 * ((x2 * -2.0) - x1); tmp = 0.0; if (x1 <= -5e+102) tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3); elseif (x1 <= 1e+152) tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((t_0 * ((((x1 * 2.0) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * ((t_2 * 4.0) - 6.0)))) + (3.0 * t_1))))); else tmp = x1 + (t_3 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0)))))))); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(N[(x1 * x1), $MachinePrecision] + 1.0), $MachinePrecision]}, Block[{t$95$1 = N[(x1 * N[(x1 * 3.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(t$95$1 + N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$0), $MachinePrecision]}, Block[{t$95$3 = N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] - x1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -5e+102], N[(x1 + N[(N[(x1 + N[(x1 * N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$3), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 1e+152], N[(x1 + N[(t$95$3 + N[(x1 + N[(N[(x1 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision] + N[(N[(t$95$0 * N[(N[(N[(N[(x1 * 2.0), $MachinePrecision] * t$95$2), $MachinePrecision] * N[(t$95$2 - 3.0), $MachinePrecision]), $MachinePrecision] + N[(N[(x1 * x1), $MachinePrecision] * N[(N[(t$95$2 * 4.0), $MachinePrecision] - 6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(3.0 * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 + N[(t$95$3 + N[(x1 + N[(x1 * N[(N[(4.0 * N[(x2 * N[(N[(2.0 * x2), $MachinePrecision] - 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x1 * N[(3.0 + N[(N[(2.0 * N[(N[(x2 * -2.0), $MachinePrecision] + N[(3.0 - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x2 * 8.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 \cdot x1 + 1\\
t_1 := x1 \cdot \left(x1 \cdot 3\right)\\
t_2 := \frac{\left(t\_1 + 2 \cdot x2\right) - x1}{t\_0}\\
t_3 := 3 \cdot \left(x2 \cdot -2 - x1\right)\\
\mathbf{if}\;x1 \leq -5 \cdot 10^{+102}:\\
\;\;\;\;x1 + \left(\left(x1 + x1 \cdot \left(x1 \cdot \left(9 + x1 \cdot -19\right)\right)\right) + t\_3\right)\\
\mathbf{elif}\;x1 \leq 10^{+152}:\\
\;\;\;\;x1 + \left(t\_3 + \left(x1 + \left(x1 \cdot \left(x1 \cdot x1\right) + \left(t\_0 \cdot \left(\left(\left(x1 \cdot 2\right) \cdot t\_2\right) \cdot \left(t\_2 - 3\right) + \left(x1 \cdot x1\right) \cdot \left(t\_2 \cdot 4 - 6\right)\right) + 3 \cdot t\_1\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 + \left(t\_3 + \left(x1 + x1 \cdot \left(4 \cdot \left(x2 \cdot \left(2 \cdot x2 - 3\right)\right) + x1 \cdot \left(3 + \left(2 \cdot \left(x2 \cdot -2 + \left(3 - 2 \cdot x2\right)\right) + x2 \cdot 8\right)\right)\right)\right)\right)\\
\end{array}
\end{array}
if x1 < -5e102Initial program 0.0%
Taylor expanded in x1 around inf 0.0%
Taylor expanded in x1 around 0 0.0%
mul-1-neg0.0%
unsub-neg0.0%
*-commutative0.0%
Simplified0.0%
Taylor expanded in x1 around 0 70.4%
Taylor expanded in x2 around 0 100.0%
*-commutative100.0%
Simplified100.0%
if -5e102 < x1 < 1e152Initial program 98.9%
Taylor expanded in x1 around inf 98.3%
Taylor expanded in x1 around 0 98.8%
mul-1-neg98.8%
unsub-neg98.8%
*-commutative98.8%
Simplified98.8%
if 1e152 < x1 Initial program 0.0%
Taylor expanded in x1 around inf 0.0%
Taylor expanded in x1 around 0 0.0%
mul-1-neg0.0%
unsub-neg0.0%
*-commutative0.0%
Simplified0.0%
Taylor expanded in x1 around 0 100.0%
Final simplification99.2%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (+ (* x1 x1) 1.0))
(t_1 (* x1 (* x1 x1)))
(t_2 (* 3.0 (- (* x2 -2.0) x1)))
(t_3 (* x1 (* x1 3.0)))
(t_4 (/ (- (+ t_3 (* 2.0 x2)) x1) t_0))
(t_5 (* 3.0 t_3))
(t_6 (* 3.0 (/ (- (- t_3 (* 2.0 x2)) x1) t_0)))
(t_7 (* (- t_4 3.0) (* (* x1 2.0) 3.0))))
(if (<= x1 -2e+103)
(+ x1 (+ (+ x1 (* x1 (* x1 (+ 9.0 (* x1 -19.0))))) t_2))
(if (<= x1 -33000000.0)
(+ x1 (+ t_6 (+ x1 (+ t_1 (+ t_5 (* t_0 (+ (* (* x1 x1) 6.0) t_7)))))))
(if (<= x1 3800.0)
(+ x1 (+ t_6 (+ x1 (* 4.0 (* x2 (+ (* x1 -3.0) (* 2.0 (* x1 x2))))))))
(if (<= x1 1e+152)
(+
x1
(+
(+
x1
(+
t_1
(+ t_5 (* t_0 (+ (* (* x1 x1) (- (* t_4 4.0) 6.0)) t_7)))))
(* 3.0 (* x2 -2.0))))
(+
x1
(+
t_2
(+
x1
(*
x1
(+
(* 4.0 (* x2 (- (* 2.0 x2) 3.0)))
(*
x1
(+
3.0
(+
(* 2.0 (+ (* x2 -2.0) (- 3.0 (* 2.0 x2))))
(* x2 8.0)))))))))))))))
double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = x1 * (x1 * x1);
double t_2 = 3.0 * ((x2 * -2.0) - x1);
double t_3 = x1 * (x1 * 3.0);
double t_4 = ((t_3 + (2.0 * x2)) - x1) / t_0;
double t_5 = 3.0 * t_3;
double t_6 = 3.0 * (((t_3 - (2.0 * x2)) - x1) / t_0);
double t_7 = (t_4 - 3.0) * ((x1 * 2.0) * 3.0);
double tmp;
if (x1 <= -2e+103) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_2);
} else if (x1 <= -33000000.0) {
tmp = x1 + (t_6 + (x1 + (t_1 + (t_5 + (t_0 * (((x1 * x1) * 6.0) + t_7))))));
} else if (x1 <= 3800.0) {
tmp = x1 + (t_6 + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2)))))));
} else if (x1 <= 1e+152) {
tmp = x1 + ((x1 + (t_1 + (t_5 + (t_0 * (((x1 * x1) * ((t_4 * 4.0) - 6.0)) + t_7))))) + (3.0 * (x2 * -2.0)));
} else {
tmp = x1 + (t_2 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0))))))));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: t_4
real(8) :: t_5
real(8) :: t_6
real(8) :: t_7
real(8) :: tmp
t_0 = (x1 * x1) + 1.0d0
t_1 = x1 * (x1 * x1)
t_2 = 3.0d0 * ((x2 * (-2.0d0)) - x1)
t_3 = x1 * (x1 * 3.0d0)
t_4 = ((t_3 + (2.0d0 * x2)) - x1) / t_0
t_5 = 3.0d0 * t_3
t_6 = 3.0d0 * (((t_3 - (2.0d0 * x2)) - x1) / t_0)
t_7 = (t_4 - 3.0d0) * ((x1 * 2.0d0) * 3.0d0)
if (x1 <= (-2d+103)) then
tmp = x1 + ((x1 + (x1 * (x1 * (9.0d0 + (x1 * (-19.0d0)))))) + t_2)
else if (x1 <= (-33000000.0d0)) then
tmp = x1 + (t_6 + (x1 + (t_1 + (t_5 + (t_0 * (((x1 * x1) * 6.0d0) + t_7))))))
else if (x1 <= 3800.0d0) then
tmp = x1 + (t_6 + (x1 + (4.0d0 * (x2 * ((x1 * (-3.0d0)) + (2.0d0 * (x1 * x2)))))))
else if (x1 <= 1d+152) then
tmp = x1 + ((x1 + (t_1 + (t_5 + (t_0 * (((x1 * x1) * ((t_4 * 4.0d0) - 6.0d0)) + t_7))))) + (3.0d0 * (x2 * (-2.0d0))))
else
tmp = x1 + (t_2 + (x1 + (x1 * ((4.0d0 * (x2 * ((2.0d0 * x2) - 3.0d0))) + (x1 * (3.0d0 + ((2.0d0 * ((x2 * (-2.0d0)) + (3.0d0 - (2.0d0 * x2)))) + (x2 * 8.0d0))))))))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = x1 * (x1 * x1);
double t_2 = 3.0 * ((x2 * -2.0) - x1);
double t_3 = x1 * (x1 * 3.0);
double t_4 = ((t_3 + (2.0 * x2)) - x1) / t_0;
double t_5 = 3.0 * t_3;
double t_6 = 3.0 * (((t_3 - (2.0 * x2)) - x1) / t_0);
double t_7 = (t_4 - 3.0) * ((x1 * 2.0) * 3.0);
double tmp;
if (x1 <= -2e+103) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_2);
} else if (x1 <= -33000000.0) {
tmp = x1 + (t_6 + (x1 + (t_1 + (t_5 + (t_0 * (((x1 * x1) * 6.0) + t_7))))));
} else if (x1 <= 3800.0) {
tmp = x1 + (t_6 + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2)))))));
} else if (x1 <= 1e+152) {
tmp = x1 + ((x1 + (t_1 + (t_5 + (t_0 * (((x1 * x1) * ((t_4 * 4.0) - 6.0)) + t_7))))) + (3.0 * (x2 * -2.0)));
} else {
tmp = x1 + (t_2 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0))))))));
}
return tmp;
}
def code(x1, x2): t_0 = (x1 * x1) + 1.0 t_1 = x1 * (x1 * x1) t_2 = 3.0 * ((x2 * -2.0) - x1) t_3 = x1 * (x1 * 3.0) t_4 = ((t_3 + (2.0 * x2)) - x1) / t_0 t_5 = 3.0 * t_3 t_6 = 3.0 * (((t_3 - (2.0 * x2)) - x1) / t_0) t_7 = (t_4 - 3.0) * ((x1 * 2.0) * 3.0) tmp = 0 if x1 <= -2e+103: tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_2) elif x1 <= -33000000.0: tmp = x1 + (t_6 + (x1 + (t_1 + (t_5 + (t_0 * (((x1 * x1) * 6.0) + t_7)))))) elif x1 <= 3800.0: tmp = x1 + (t_6 + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2))))))) elif x1 <= 1e+152: tmp = x1 + ((x1 + (t_1 + (t_5 + (t_0 * (((x1 * x1) * ((t_4 * 4.0) - 6.0)) + t_7))))) + (3.0 * (x2 * -2.0))) else: tmp = x1 + (t_2 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0)))))))) return tmp
function code(x1, x2) t_0 = Float64(Float64(x1 * x1) + 1.0) t_1 = Float64(x1 * Float64(x1 * x1)) t_2 = Float64(3.0 * Float64(Float64(x2 * -2.0) - x1)) t_3 = Float64(x1 * Float64(x1 * 3.0)) t_4 = Float64(Float64(Float64(t_3 + Float64(2.0 * x2)) - x1) / t_0) t_5 = Float64(3.0 * t_3) t_6 = Float64(3.0 * Float64(Float64(Float64(t_3 - Float64(2.0 * x2)) - x1) / t_0)) t_7 = Float64(Float64(t_4 - 3.0) * Float64(Float64(x1 * 2.0) * 3.0)) tmp = 0.0 if (x1 <= -2e+103) tmp = Float64(x1 + Float64(Float64(x1 + Float64(x1 * Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))) + t_2)); elseif (x1 <= -33000000.0) tmp = Float64(x1 + Float64(t_6 + Float64(x1 + Float64(t_1 + Float64(t_5 + Float64(t_0 * Float64(Float64(Float64(x1 * x1) * 6.0) + t_7))))))); elseif (x1 <= 3800.0) tmp = Float64(x1 + Float64(t_6 + Float64(x1 + Float64(4.0 * Float64(x2 * Float64(Float64(x1 * -3.0) + Float64(2.0 * Float64(x1 * x2)))))))); elseif (x1 <= 1e+152) tmp = Float64(x1 + Float64(Float64(x1 + Float64(t_1 + Float64(t_5 + Float64(t_0 * Float64(Float64(Float64(x1 * x1) * Float64(Float64(t_4 * 4.0) - 6.0)) + t_7))))) + Float64(3.0 * Float64(x2 * -2.0)))); else tmp = Float64(x1 + Float64(t_2 + Float64(x1 + Float64(x1 * Float64(Float64(4.0 * Float64(x2 * Float64(Float64(2.0 * x2) - 3.0))) + Float64(x1 * Float64(3.0 + Float64(Float64(2.0 * Float64(Float64(x2 * -2.0) + Float64(3.0 - Float64(2.0 * x2)))) + Float64(x2 * 8.0))))))))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = (x1 * x1) + 1.0; t_1 = x1 * (x1 * x1); t_2 = 3.0 * ((x2 * -2.0) - x1); t_3 = x1 * (x1 * 3.0); t_4 = ((t_3 + (2.0 * x2)) - x1) / t_0; t_5 = 3.0 * t_3; t_6 = 3.0 * (((t_3 - (2.0 * x2)) - x1) / t_0); t_7 = (t_4 - 3.0) * ((x1 * 2.0) * 3.0); tmp = 0.0; if (x1 <= -2e+103) tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_2); elseif (x1 <= -33000000.0) tmp = x1 + (t_6 + (x1 + (t_1 + (t_5 + (t_0 * (((x1 * x1) * 6.0) + t_7)))))); elseif (x1 <= 3800.0) tmp = x1 + (t_6 + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2))))))); elseif (x1 <= 1e+152) tmp = x1 + ((x1 + (t_1 + (t_5 + (t_0 * (((x1 * x1) * ((t_4 * 4.0) - 6.0)) + t_7))))) + (3.0 * (x2 * -2.0))); else tmp = x1 + (t_2 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0)))))))); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(N[(x1 * x1), $MachinePrecision] + 1.0), $MachinePrecision]}, Block[{t$95$1 = N[(x1 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] - x1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(x1 * N[(x1 * 3.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(N[(N[(t$95$3 + N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$0), $MachinePrecision]}, Block[{t$95$5 = N[(3.0 * t$95$3), $MachinePrecision]}, Block[{t$95$6 = N[(3.0 * N[(N[(N[(t$95$3 - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$7 = N[(N[(t$95$4 - 3.0), $MachinePrecision] * N[(N[(x1 * 2.0), $MachinePrecision] * 3.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -2e+103], N[(x1 + N[(N[(x1 + N[(x1 * N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$2), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -33000000.0], N[(x1 + N[(t$95$6 + N[(x1 + N[(t$95$1 + N[(t$95$5 + N[(t$95$0 * N[(N[(N[(x1 * x1), $MachinePrecision] * 6.0), $MachinePrecision] + t$95$7), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 3800.0], N[(x1 + N[(t$95$6 + N[(x1 + N[(4.0 * N[(x2 * N[(N[(x1 * -3.0), $MachinePrecision] + N[(2.0 * N[(x1 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 1e+152], N[(x1 + N[(N[(x1 + N[(t$95$1 + N[(t$95$5 + N[(t$95$0 * N[(N[(N[(x1 * x1), $MachinePrecision] * N[(N[(t$95$4 * 4.0), $MachinePrecision] - 6.0), $MachinePrecision]), $MachinePrecision] + t$95$7), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(3.0 * N[(x2 * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 + N[(t$95$2 + N[(x1 + N[(x1 * N[(N[(4.0 * N[(x2 * N[(N[(2.0 * x2), $MachinePrecision] - 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x1 * N[(3.0 + N[(N[(2.0 * N[(N[(x2 * -2.0), $MachinePrecision] + N[(3.0 - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x2 * 8.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 \cdot x1 + 1\\
t_1 := x1 \cdot \left(x1 \cdot x1\right)\\
t_2 := 3 \cdot \left(x2 \cdot -2 - x1\right)\\
t_3 := x1 \cdot \left(x1 \cdot 3\right)\\
t_4 := \frac{\left(t\_3 + 2 \cdot x2\right) - x1}{t\_0}\\
t_5 := 3 \cdot t\_3\\
t_6 := 3 \cdot \frac{\left(t\_3 - 2 \cdot x2\right) - x1}{t\_0}\\
t_7 := \left(t\_4 - 3\right) \cdot \left(\left(x1 \cdot 2\right) \cdot 3\right)\\
\mathbf{if}\;x1 \leq -2 \cdot 10^{+103}:\\
\;\;\;\;x1 + \left(\left(x1 + x1 \cdot \left(x1 \cdot \left(9 + x1 \cdot -19\right)\right)\right) + t\_2\right)\\
\mathbf{elif}\;x1 \leq -33000000:\\
\;\;\;\;x1 + \left(t\_6 + \left(x1 + \left(t\_1 + \left(t\_5 + t\_0 \cdot \left(\left(x1 \cdot x1\right) \cdot 6 + t\_7\right)\right)\right)\right)\right)\\
\mathbf{elif}\;x1 \leq 3800:\\
\;\;\;\;x1 + \left(t\_6 + \left(x1 + 4 \cdot \left(x2 \cdot \left(x1 \cdot -3 + 2 \cdot \left(x1 \cdot x2\right)\right)\right)\right)\right)\\
\mathbf{elif}\;x1 \leq 10^{+152}:\\
\;\;\;\;x1 + \left(\left(x1 + \left(t\_1 + \left(t\_5 + t\_0 \cdot \left(\left(x1 \cdot x1\right) \cdot \left(t\_4 \cdot 4 - 6\right) + t\_7\right)\right)\right)\right) + 3 \cdot \left(x2 \cdot -2\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 + \left(t\_2 + \left(x1 + x1 \cdot \left(4 \cdot \left(x2 \cdot \left(2 \cdot x2 - 3\right)\right) + x1 \cdot \left(3 + \left(2 \cdot \left(x2 \cdot -2 + \left(3 - 2 \cdot x2\right)\right) + x2 \cdot 8\right)\right)\right)\right)\right)\\
\end{array}
\end{array}
if x1 < -2e103Initial program 0.0%
Taylor expanded in x1 around inf 0.0%
Taylor expanded in x1 around 0 0.0%
mul-1-neg0.0%
unsub-neg0.0%
*-commutative0.0%
Simplified0.0%
Taylor expanded in x1 around 0 70.4%
Taylor expanded in x2 around 0 100.0%
*-commutative100.0%
Simplified100.0%
if -2e103 < x1 < -3.3e7Initial program 99.8%
Taylor expanded in x1 around inf 99.8%
Taylor expanded in x1 around inf 78.7%
Taylor expanded in x1 around inf 83.1%
if -3.3e7 < x1 < 3800Initial program 99.3%
Taylor expanded in x1 around 0 86.7%
Taylor expanded in x2 around 0 98.2%
if 3800 < x1 < 1e152Initial program 95.9%
Taylor expanded in x1 around inf 95.9%
Taylor expanded in x1 around inf 92.5%
Taylor expanded in x1 around 0 92.5%
*-commutative92.5%
Simplified92.5%
if 1e152 < x1 Initial program 0.0%
Taylor expanded in x1 around inf 0.0%
Taylor expanded in x1 around 0 0.0%
mul-1-neg0.0%
unsub-neg0.0%
*-commutative0.0%
Simplified0.0%
Taylor expanded in x1 around 0 100.0%
Final simplification97.0%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (+ (* x1 x1) 1.0))
(t_1 (* (* x1 2.0) 3.0))
(t_2 (* x1 (* x1 x1)))
(t_3 (* x1 (* x1 3.0)))
(t_4 (/ (- (+ t_3 (* 2.0 x2)) x1) t_0))
(t_5 (* 3.0 t_3))
(t_6 (* 3.0 (/ (- (- t_3 (* 2.0 x2)) x1) t_0)))
(t_7 (* 3.0 (- (* x2 -2.0) x1))))
(if (<= x1 -2e+103)
(+ x1 (+ (+ x1 (* x1 (* x1 (+ 9.0 (* x1 -19.0))))) t_7))
(if (<= x1 -1000000000.0)
(+
x1
(+
t_6
(+
x1
(+ t_2 (+ t_5 (* t_0 (+ (* (* x1 x1) 6.0) (* (- t_4 3.0) t_1))))))))
(if (<= x1 280.0)
(+ x1 (+ t_6 (+ x1 (* 4.0 (* x2 (+ (* x1 -3.0) (* 2.0 (* x1 x2))))))))
(if (<= x1 1e+152)
(+
x1
(+
t_6
(+
x1
(+
t_2
(+
t_5
(*
t_0
(+
(* (* x1 x1) (- (* t_4 4.0) 6.0))
(* t_1 (/ -1.0 x1)))))))))
(+
x1
(+
t_7
(+
x1
(*
x1
(+
(* 4.0 (* x2 (- (* 2.0 x2) 3.0)))
(*
x1
(+
3.0
(+
(* 2.0 (+ (* x2 -2.0) (- 3.0 (* 2.0 x2))))
(* x2 8.0)))))))))))))))
double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = (x1 * 2.0) * 3.0;
double t_2 = x1 * (x1 * x1);
double t_3 = x1 * (x1 * 3.0);
double t_4 = ((t_3 + (2.0 * x2)) - x1) / t_0;
double t_5 = 3.0 * t_3;
double t_6 = 3.0 * (((t_3 - (2.0 * x2)) - x1) / t_0);
double t_7 = 3.0 * ((x2 * -2.0) - x1);
double tmp;
if (x1 <= -2e+103) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_7);
} else if (x1 <= -1000000000.0) {
tmp = x1 + (t_6 + (x1 + (t_2 + (t_5 + (t_0 * (((x1 * x1) * 6.0) + ((t_4 - 3.0) * t_1)))))));
} else if (x1 <= 280.0) {
tmp = x1 + (t_6 + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2)))))));
} else if (x1 <= 1e+152) {
tmp = x1 + (t_6 + (x1 + (t_2 + (t_5 + (t_0 * (((x1 * x1) * ((t_4 * 4.0) - 6.0)) + (t_1 * (-1.0 / x1))))))));
} else {
tmp = x1 + (t_7 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0))))))));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: t_4
real(8) :: t_5
real(8) :: t_6
real(8) :: t_7
real(8) :: tmp
t_0 = (x1 * x1) + 1.0d0
t_1 = (x1 * 2.0d0) * 3.0d0
t_2 = x1 * (x1 * x1)
t_3 = x1 * (x1 * 3.0d0)
t_4 = ((t_3 + (2.0d0 * x2)) - x1) / t_0
t_5 = 3.0d0 * t_3
t_6 = 3.0d0 * (((t_3 - (2.0d0 * x2)) - x1) / t_0)
t_7 = 3.0d0 * ((x2 * (-2.0d0)) - x1)
if (x1 <= (-2d+103)) then
tmp = x1 + ((x1 + (x1 * (x1 * (9.0d0 + (x1 * (-19.0d0)))))) + t_7)
else if (x1 <= (-1000000000.0d0)) then
tmp = x1 + (t_6 + (x1 + (t_2 + (t_5 + (t_0 * (((x1 * x1) * 6.0d0) + ((t_4 - 3.0d0) * t_1)))))))
else if (x1 <= 280.0d0) then
tmp = x1 + (t_6 + (x1 + (4.0d0 * (x2 * ((x1 * (-3.0d0)) + (2.0d0 * (x1 * x2)))))))
else if (x1 <= 1d+152) then
tmp = x1 + (t_6 + (x1 + (t_2 + (t_5 + (t_0 * (((x1 * x1) * ((t_4 * 4.0d0) - 6.0d0)) + (t_1 * ((-1.0d0) / x1))))))))
else
tmp = x1 + (t_7 + (x1 + (x1 * ((4.0d0 * (x2 * ((2.0d0 * x2) - 3.0d0))) + (x1 * (3.0d0 + ((2.0d0 * ((x2 * (-2.0d0)) + (3.0d0 - (2.0d0 * x2)))) + (x2 * 8.0d0))))))))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = (x1 * 2.0) * 3.0;
double t_2 = x1 * (x1 * x1);
double t_3 = x1 * (x1 * 3.0);
double t_4 = ((t_3 + (2.0 * x2)) - x1) / t_0;
double t_5 = 3.0 * t_3;
double t_6 = 3.0 * (((t_3 - (2.0 * x2)) - x1) / t_0);
double t_7 = 3.0 * ((x2 * -2.0) - x1);
double tmp;
if (x1 <= -2e+103) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_7);
} else if (x1 <= -1000000000.0) {
tmp = x1 + (t_6 + (x1 + (t_2 + (t_5 + (t_0 * (((x1 * x1) * 6.0) + ((t_4 - 3.0) * t_1)))))));
} else if (x1 <= 280.0) {
tmp = x1 + (t_6 + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2)))))));
} else if (x1 <= 1e+152) {
tmp = x1 + (t_6 + (x1 + (t_2 + (t_5 + (t_0 * (((x1 * x1) * ((t_4 * 4.0) - 6.0)) + (t_1 * (-1.0 / x1))))))));
} else {
tmp = x1 + (t_7 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0))))))));
}
return tmp;
}
def code(x1, x2): t_0 = (x1 * x1) + 1.0 t_1 = (x1 * 2.0) * 3.0 t_2 = x1 * (x1 * x1) t_3 = x1 * (x1 * 3.0) t_4 = ((t_3 + (2.0 * x2)) - x1) / t_0 t_5 = 3.0 * t_3 t_6 = 3.0 * (((t_3 - (2.0 * x2)) - x1) / t_0) t_7 = 3.0 * ((x2 * -2.0) - x1) tmp = 0 if x1 <= -2e+103: tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_7) elif x1 <= -1000000000.0: tmp = x1 + (t_6 + (x1 + (t_2 + (t_5 + (t_0 * (((x1 * x1) * 6.0) + ((t_4 - 3.0) * t_1))))))) elif x1 <= 280.0: tmp = x1 + (t_6 + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2))))))) elif x1 <= 1e+152: tmp = x1 + (t_6 + (x1 + (t_2 + (t_5 + (t_0 * (((x1 * x1) * ((t_4 * 4.0) - 6.0)) + (t_1 * (-1.0 / x1)))))))) else: tmp = x1 + (t_7 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0)))))))) return tmp
function code(x1, x2) t_0 = Float64(Float64(x1 * x1) + 1.0) t_1 = Float64(Float64(x1 * 2.0) * 3.0) t_2 = Float64(x1 * Float64(x1 * x1)) t_3 = Float64(x1 * Float64(x1 * 3.0)) t_4 = Float64(Float64(Float64(t_3 + Float64(2.0 * x2)) - x1) / t_0) t_5 = Float64(3.0 * t_3) t_6 = Float64(3.0 * Float64(Float64(Float64(t_3 - Float64(2.0 * x2)) - x1) / t_0)) t_7 = Float64(3.0 * Float64(Float64(x2 * -2.0) - x1)) tmp = 0.0 if (x1 <= -2e+103) tmp = Float64(x1 + Float64(Float64(x1 + Float64(x1 * Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))) + t_7)); elseif (x1 <= -1000000000.0) tmp = Float64(x1 + Float64(t_6 + Float64(x1 + Float64(t_2 + Float64(t_5 + Float64(t_0 * Float64(Float64(Float64(x1 * x1) * 6.0) + Float64(Float64(t_4 - 3.0) * t_1)))))))); elseif (x1 <= 280.0) tmp = Float64(x1 + Float64(t_6 + Float64(x1 + Float64(4.0 * Float64(x2 * Float64(Float64(x1 * -3.0) + Float64(2.0 * Float64(x1 * x2)))))))); elseif (x1 <= 1e+152) tmp = Float64(x1 + Float64(t_6 + Float64(x1 + Float64(t_2 + Float64(t_5 + Float64(t_0 * Float64(Float64(Float64(x1 * x1) * Float64(Float64(t_4 * 4.0) - 6.0)) + Float64(t_1 * Float64(-1.0 / x1))))))))); else tmp = Float64(x1 + Float64(t_7 + Float64(x1 + Float64(x1 * Float64(Float64(4.0 * Float64(x2 * Float64(Float64(2.0 * x2) - 3.0))) + Float64(x1 * Float64(3.0 + Float64(Float64(2.0 * Float64(Float64(x2 * -2.0) + Float64(3.0 - Float64(2.0 * x2)))) + Float64(x2 * 8.0))))))))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = (x1 * x1) + 1.0; t_1 = (x1 * 2.0) * 3.0; t_2 = x1 * (x1 * x1); t_3 = x1 * (x1 * 3.0); t_4 = ((t_3 + (2.0 * x2)) - x1) / t_0; t_5 = 3.0 * t_3; t_6 = 3.0 * (((t_3 - (2.0 * x2)) - x1) / t_0); t_7 = 3.0 * ((x2 * -2.0) - x1); tmp = 0.0; if (x1 <= -2e+103) tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_7); elseif (x1 <= -1000000000.0) tmp = x1 + (t_6 + (x1 + (t_2 + (t_5 + (t_0 * (((x1 * x1) * 6.0) + ((t_4 - 3.0) * t_1))))))); elseif (x1 <= 280.0) tmp = x1 + (t_6 + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2))))))); elseif (x1 <= 1e+152) tmp = x1 + (t_6 + (x1 + (t_2 + (t_5 + (t_0 * (((x1 * x1) * ((t_4 * 4.0) - 6.0)) + (t_1 * (-1.0 / x1)))))))); else tmp = x1 + (t_7 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0)))))))); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(N[(x1 * x1), $MachinePrecision] + 1.0), $MachinePrecision]}, Block[{t$95$1 = N[(N[(x1 * 2.0), $MachinePrecision] * 3.0), $MachinePrecision]}, Block[{t$95$2 = N[(x1 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(x1 * N[(x1 * 3.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(N[(N[(t$95$3 + N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$0), $MachinePrecision]}, Block[{t$95$5 = N[(3.0 * t$95$3), $MachinePrecision]}, Block[{t$95$6 = N[(3.0 * N[(N[(N[(t$95$3 - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$7 = N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] - x1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -2e+103], N[(x1 + N[(N[(x1 + N[(x1 * N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$7), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -1000000000.0], N[(x1 + N[(t$95$6 + N[(x1 + N[(t$95$2 + N[(t$95$5 + N[(t$95$0 * N[(N[(N[(x1 * x1), $MachinePrecision] * 6.0), $MachinePrecision] + N[(N[(t$95$4 - 3.0), $MachinePrecision] * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 280.0], N[(x1 + N[(t$95$6 + N[(x1 + N[(4.0 * N[(x2 * N[(N[(x1 * -3.0), $MachinePrecision] + N[(2.0 * N[(x1 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 1e+152], N[(x1 + N[(t$95$6 + N[(x1 + N[(t$95$2 + N[(t$95$5 + N[(t$95$0 * N[(N[(N[(x1 * x1), $MachinePrecision] * N[(N[(t$95$4 * 4.0), $MachinePrecision] - 6.0), $MachinePrecision]), $MachinePrecision] + N[(t$95$1 * N[(-1.0 / x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 + N[(t$95$7 + N[(x1 + N[(x1 * N[(N[(4.0 * N[(x2 * N[(N[(2.0 * x2), $MachinePrecision] - 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x1 * N[(3.0 + N[(N[(2.0 * N[(N[(x2 * -2.0), $MachinePrecision] + N[(3.0 - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x2 * 8.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 \cdot x1 + 1\\
t_1 := \left(x1 \cdot 2\right) \cdot 3\\
t_2 := x1 \cdot \left(x1 \cdot x1\right)\\
t_3 := x1 \cdot \left(x1 \cdot 3\right)\\
t_4 := \frac{\left(t\_3 + 2 \cdot x2\right) - x1}{t\_0}\\
t_5 := 3 \cdot t\_3\\
t_6 := 3 \cdot \frac{\left(t\_3 - 2 \cdot x2\right) - x1}{t\_0}\\
t_7 := 3 \cdot \left(x2 \cdot -2 - x1\right)\\
\mathbf{if}\;x1 \leq -2 \cdot 10^{+103}:\\
\;\;\;\;x1 + \left(\left(x1 + x1 \cdot \left(x1 \cdot \left(9 + x1 \cdot -19\right)\right)\right) + t\_7\right)\\
\mathbf{elif}\;x1 \leq -1000000000:\\
\;\;\;\;x1 + \left(t\_6 + \left(x1 + \left(t\_2 + \left(t\_5 + t\_0 \cdot \left(\left(x1 \cdot x1\right) \cdot 6 + \left(t\_4 - 3\right) \cdot t\_1\right)\right)\right)\right)\right)\\
\mathbf{elif}\;x1 \leq 280:\\
\;\;\;\;x1 + \left(t\_6 + \left(x1 + 4 \cdot \left(x2 \cdot \left(x1 \cdot -3 + 2 \cdot \left(x1 \cdot x2\right)\right)\right)\right)\right)\\
\mathbf{elif}\;x1 \leq 10^{+152}:\\
\;\;\;\;x1 + \left(t\_6 + \left(x1 + \left(t\_2 + \left(t\_5 + t\_0 \cdot \left(\left(x1 \cdot x1\right) \cdot \left(t\_4 \cdot 4 - 6\right) + t\_1 \cdot \frac{-1}{x1}\right)\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 + \left(t\_7 + \left(x1 + x1 \cdot \left(4 \cdot \left(x2 \cdot \left(2 \cdot x2 - 3\right)\right) + x1 \cdot \left(3 + \left(2 \cdot \left(x2 \cdot -2 + \left(3 - 2 \cdot x2\right)\right) + x2 \cdot 8\right)\right)\right)\right)\right)\\
\end{array}
\end{array}
if x1 < -2e103Initial program 0.0%
Taylor expanded in x1 around inf 0.0%
Taylor expanded in x1 around 0 0.0%
mul-1-neg0.0%
unsub-neg0.0%
*-commutative0.0%
Simplified0.0%
Taylor expanded in x1 around 0 70.4%
Taylor expanded in x2 around 0 100.0%
*-commutative100.0%
Simplified100.0%
if -2e103 < x1 < -1e9Initial program 99.8%
Taylor expanded in x1 around inf 99.8%
Taylor expanded in x1 around inf 78.7%
Taylor expanded in x1 around inf 83.1%
if -1e9 < x1 < 280Initial program 99.3%
Taylor expanded in x1 around 0 86.7%
Taylor expanded in x2 around 0 98.2%
if 280 < x1 < 1e152Initial program 95.9%
Taylor expanded in x1 around inf 95.9%
Taylor expanded in x1 around inf 92.5%
Taylor expanded in x1 around inf 92.2%
if 1e152 < x1 Initial program 0.0%
Taylor expanded in x1 around inf 0.0%
Taylor expanded in x1 around 0 0.0%
mul-1-neg0.0%
unsub-neg0.0%
*-commutative0.0%
Simplified0.0%
Taylor expanded in x1 around 0 100.0%
Final simplification97.0%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (+ (* x1 x1) 1.0))
(t_1 (- 3.0 (* 2.0 x2)))
(t_2 (* x1 (* x1 3.0)))
(t_3 (* 3.0 (- (* x2 -2.0) x1)))
(t_4 (* 3.0 (/ (- (- t_2 (* 2.0 x2)) x1) t_0)))
(t_5 (- (* 2.0 x2) 3.0))
(t_6 (* x2 t_5))
(t_7 (* 6.0 t_5))
(t_8
(+
x1
(+
t_4
(+
x1
(*
x1
(+
t_7
(*
x1
(-
(+
(* x2 8.0)
(*
x1
(-
(+
(* 6.0 (+ 3.0 (* x2 -2.0)))
(+ t_7 (* x1 (- (+ (* x2 8.0) (* 4.0 t_1)) 6.0))))
3.0)))
3.0)))))))))
(if (<= x1 -2e+104)
(+ x1 (+ (+ x1 (* x1 (* x1 (+ 9.0 (* x1 -19.0))))) t_3))
(if (<= x1 -21500000.0)
t_8
(if (<= x1 14.5)
(+ x1 (+ t_4 (+ x1 (* 4.0 (* x2 (+ (* x1 -3.0) (* 2.0 (* x1 x2))))))))
(if (<= x1 1.45e+77)
t_8
(if (<= x1 1e+139)
(+
x1
(+
t_3
(+
x1
(+
(* x1 (* x1 x1))
(+ (* 3.0 t_2) (* t_0 (* 4.0 (* x1 t_6))))))))
(if (<= x1 4.5e+153)
(+
x1
(+
(* x2 -6.0)
(*
x1
(-
(+
(* x2 -12.0)
(* x1 (+ (* x1 3.0) (* 3.0 (- 3.0 (* x2 -2.0))))))
2.0))))
(+
x1
(+
t_3
(+
x1
(*
x1
(+
(* 4.0 t_6)
(*
x1
(+
3.0
(+ (* 2.0 (+ (* x2 -2.0) t_1)) (* x2 8.0)))))))))))))))))
double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = 3.0 - (2.0 * x2);
double t_2 = x1 * (x1 * 3.0);
double t_3 = 3.0 * ((x2 * -2.0) - x1);
double t_4 = 3.0 * (((t_2 - (2.0 * x2)) - x1) / t_0);
double t_5 = (2.0 * x2) - 3.0;
double t_6 = x2 * t_5;
double t_7 = 6.0 * t_5;
double t_8 = x1 + (t_4 + (x1 + (x1 * (t_7 + (x1 * (((x2 * 8.0) + (x1 * (((6.0 * (3.0 + (x2 * -2.0))) + (t_7 + (x1 * (((x2 * 8.0) + (4.0 * t_1)) - 6.0)))) - 3.0))) - 3.0))))));
double tmp;
if (x1 <= -2e+104) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3);
} else if (x1 <= -21500000.0) {
tmp = t_8;
} else if (x1 <= 14.5) {
tmp = x1 + (t_4 + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2)))))));
} else if (x1 <= 1.45e+77) {
tmp = t_8;
} else if (x1 <= 1e+139) {
tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_2) + (t_0 * (4.0 * (x1 * t_6)))))));
} else if (x1 <= 4.5e+153) {
tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0)));
} else {
tmp = x1 + (t_3 + (x1 + (x1 * ((4.0 * t_6) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + t_1)) + (x2 * 8.0))))))));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: t_4
real(8) :: t_5
real(8) :: t_6
real(8) :: t_7
real(8) :: t_8
real(8) :: tmp
t_0 = (x1 * x1) + 1.0d0
t_1 = 3.0d0 - (2.0d0 * x2)
t_2 = x1 * (x1 * 3.0d0)
t_3 = 3.0d0 * ((x2 * (-2.0d0)) - x1)
t_4 = 3.0d0 * (((t_2 - (2.0d0 * x2)) - x1) / t_0)
t_5 = (2.0d0 * x2) - 3.0d0
t_6 = x2 * t_5
t_7 = 6.0d0 * t_5
t_8 = x1 + (t_4 + (x1 + (x1 * (t_7 + (x1 * (((x2 * 8.0d0) + (x1 * (((6.0d0 * (3.0d0 + (x2 * (-2.0d0)))) + (t_7 + (x1 * (((x2 * 8.0d0) + (4.0d0 * t_1)) - 6.0d0)))) - 3.0d0))) - 3.0d0))))))
if (x1 <= (-2d+104)) then
tmp = x1 + ((x1 + (x1 * (x1 * (9.0d0 + (x1 * (-19.0d0)))))) + t_3)
else if (x1 <= (-21500000.0d0)) then
tmp = t_8
else if (x1 <= 14.5d0) then
tmp = x1 + (t_4 + (x1 + (4.0d0 * (x2 * ((x1 * (-3.0d0)) + (2.0d0 * (x1 * x2)))))))
else if (x1 <= 1.45d+77) then
tmp = t_8
else if (x1 <= 1d+139) then
tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((3.0d0 * t_2) + (t_0 * (4.0d0 * (x1 * t_6)))))))
else if (x1 <= 4.5d+153) then
tmp = x1 + ((x2 * (-6.0d0)) + (x1 * (((x2 * (-12.0d0)) + (x1 * ((x1 * 3.0d0) + (3.0d0 * (3.0d0 - (x2 * (-2.0d0))))))) - 2.0d0)))
else
tmp = x1 + (t_3 + (x1 + (x1 * ((4.0d0 * t_6) + (x1 * (3.0d0 + ((2.0d0 * ((x2 * (-2.0d0)) + t_1)) + (x2 * 8.0d0))))))))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = 3.0 - (2.0 * x2);
double t_2 = x1 * (x1 * 3.0);
double t_3 = 3.0 * ((x2 * -2.0) - x1);
double t_4 = 3.0 * (((t_2 - (2.0 * x2)) - x1) / t_0);
double t_5 = (2.0 * x2) - 3.0;
double t_6 = x2 * t_5;
double t_7 = 6.0 * t_5;
double t_8 = x1 + (t_4 + (x1 + (x1 * (t_7 + (x1 * (((x2 * 8.0) + (x1 * (((6.0 * (3.0 + (x2 * -2.0))) + (t_7 + (x1 * (((x2 * 8.0) + (4.0 * t_1)) - 6.0)))) - 3.0))) - 3.0))))));
double tmp;
if (x1 <= -2e+104) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3);
} else if (x1 <= -21500000.0) {
tmp = t_8;
} else if (x1 <= 14.5) {
tmp = x1 + (t_4 + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2)))))));
} else if (x1 <= 1.45e+77) {
tmp = t_8;
} else if (x1 <= 1e+139) {
tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_2) + (t_0 * (4.0 * (x1 * t_6)))))));
} else if (x1 <= 4.5e+153) {
tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0)));
} else {
tmp = x1 + (t_3 + (x1 + (x1 * ((4.0 * t_6) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + t_1)) + (x2 * 8.0))))))));
}
return tmp;
}
def code(x1, x2): t_0 = (x1 * x1) + 1.0 t_1 = 3.0 - (2.0 * x2) t_2 = x1 * (x1 * 3.0) t_3 = 3.0 * ((x2 * -2.0) - x1) t_4 = 3.0 * (((t_2 - (2.0 * x2)) - x1) / t_0) t_5 = (2.0 * x2) - 3.0 t_6 = x2 * t_5 t_7 = 6.0 * t_5 t_8 = x1 + (t_4 + (x1 + (x1 * (t_7 + (x1 * (((x2 * 8.0) + (x1 * (((6.0 * (3.0 + (x2 * -2.0))) + (t_7 + (x1 * (((x2 * 8.0) + (4.0 * t_1)) - 6.0)))) - 3.0))) - 3.0)))))) tmp = 0 if x1 <= -2e+104: tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3) elif x1 <= -21500000.0: tmp = t_8 elif x1 <= 14.5: tmp = x1 + (t_4 + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2))))))) elif x1 <= 1.45e+77: tmp = t_8 elif x1 <= 1e+139: tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_2) + (t_0 * (4.0 * (x1 * t_6))))))) elif x1 <= 4.5e+153: tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0))) else: tmp = x1 + (t_3 + (x1 + (x1 * ((4.0 * t_6) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + t_1)) + (x2 * 8.0)))))))) return tmp
function code(x1, x2) t_0 = Float64(Float64(x1 * x1) + 1.0) t_1 = Float64(3.0 - Float64(2.0 * x2)) t_2 = Float64(x1 * Float64(x1 * 3.0)) t_3 = Float64(3.0 * Float64(Float64(x2 * -2.0) - x1)) t_4 = Float64(3.0 * Float64(Float64(Float64(t_2 - Float64(2.0 * x2)) - x1) / t_0)) t_5 = Float64(Float64(2.0 * x2) - 3.0) t_6 = Float64(x2 * t_5) t_7 = Float64(6.0 * t_5) t_8 = Float64(x1 + Float64(t_4 + Float64(x1 + Float64(x1 * Float64(t_7 + Float64(x1 * Float64(Float64(Float64(x2 * 8.0) + Float64(x1 * Float64(Float64(Float64(6.0 * Float64(3.0 + Float64(x2 * -2.0))) + Float64(t_7 + Float64(x1 * Float64(Float64(Float64(x2 * 8.0) + Float64(4.0 * t_1)) - 6.0)))) - 3.0))) - 3.0))))))) tmp = 0.0 if (x1 <= -2e+104) tmp = Float64(x1 + Float64(Float64(x1 + Float64(x1 * Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))) + t_3)); elseif (x1 <= -21500000.0) tmp = t_8; elseif (x1 <= 14.5) tmp = Float64(x1 + Float64(t_4 + Float64(x1 + Float64(4.0 * Float64(x2 * Float64(Float64(x1 * -3.0) + Float64(2.0 * Float64(x1 * x2)))))))); elseif (x1 <= 1.45e+77) tmp = t_8; elseif (x1 <= 1e+139) tmp = Float64(x1 + Float64(t_3 + Float64(x1 + Float64(Float64(x1 * Float64(x1 * x1)) + Float64(Float64(3.0 * t_2) + Float64(t_0 * Float64(4.0 * Float64(x1 * t_6)))))))); elseif (x1 <= 4.5e+153) tmp = Float64(x1 + Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(Float64(Float64(x2 * -12.0) + Float64(x1 * Float64(Float64(x1 * 3.0) + Float64(3.0 * Float64(3.0 - Float64(x2 * -2.0)))))) - 2.0)))); else tmp = Float64(x1 + Float64(t_3 + Float64(x1 + Float64(x1 * Float64(Float64(4.0 * t_6) + Float64(x1 * Float64(3.0 + Float64(Float64(2.0 * Float64(Float64(x2 * -2.0) + t_1)) + Float64(x2 * 8.0))))))))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = (x1 * x1) + 1.0; t_1 = 3.0 - (2.0 * x2); t_2 = x1 * (x1 * 3.0); t_3 = 3.0 * ((x2 * -2.0) - x1); t_4 = 3.0 * (((t_2 - (2.0 * x2)) - x1) / t_0); t_5 = (2.0 * x2) - 3.0; t_6 = x2 * t_5; t_7 = 6.0 * t_5; t_8 = x1 + (t_4 + (x1 + (x1 * (t_7 + (x1 * (((x2 * 8.0) + (x1 * (((6.0 * (3.0 + (x2 * -2.0))) + (t_7 + (x1 * (((x2 * 8.0) + (4.0 * t_1)) - 6.0)))) - 3.0))) - 3.0)))))); tmp = 0.0; if (x1 <= -2e+104) tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3); elseif (x1 <= -21500000.0) tmp = t_8; elseif (x1 <= 14.5) tmp = x1 + (t_4 + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2))))))); elseif (x1 <= 1.45e+77) tmp = t_8; elseif (x1 <= 1e+139) tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_2) + (t_0 * (4.0 * (x1 * t_6))))))); elseif (x1 <= 4.5e+153) tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0))); else tmp = x1 + (t_3 + (x1 + (x1 * ((4.0 * t_6) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + t_1)) + (x2 * 8.0)))))))); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(N[(x1 * x1), $MachinePrecision] + 1.0), $MachinePrecision]}, Block[{t$95$1 = N[(3.0 - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x1 * N[(x1 * 3.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] - x1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(3.0 * N[(N[(N[(t$95$2 - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[(N[(2.0 * x2), $MachinePrecision] - 3.0), $MachinePrecision]}, Block[{t$95$6 = N[(x2 * t$95$5), $MachinePrecision]}, Block[{t$95$7 = N[(6.0 * t$95$5), $MachinePrecision]}, Block[{t$95$8 = N[(x1 + N[(t$95$4 + N[(x1 + N[(x1 * N[(t$95$7 + N[(x1 * N[(N[(N[(x2 * 8.0), $MachinePrecision] + N[(x1 * N[(N[(N[(6.0 * N[(3.0 + N[(x2 * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(t$95$7 + N[(x1 * N[(N[(N[(x2 * 8.0), $MachinePrecision] + N[(4.0 * t$95$1), $MachinePrecision]), $MachinePrecision] - 6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -2e+104], N[(x1 + N[(N[(x1 + N[(x1 * N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$3), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -21500000.0], t$95$8, If[LessEqual[x1, 14.5], N[(x1 + N[(t$95$4 + N[(x1 + N[(4.0 * N[(x2 * N[(N[(x1 * -3.0), $MachinePrecision] + N[(2.0 * N[(x1 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 1.45e+77], t$95$8, If[LessEqual[x1, 1e+139], N[(x1 + N[(t$95$3 + N[(x1 + N[(N[(x1 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision] + N[(N[(3.0 * t$95$2), $MachinePrecision] + N[(t$95$0 * N[(4.0 * N[(x1 * t$95$6), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 4.5e+153], N[(x1 + N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(N[(N[(x2 * -12.0), $MachinePrecision] + N[(x1 * N[(N[(x1 * 3.0), $MachinePrecision] + N[(3.0 * N[(3.0 - N[(x2 * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 + N[(t$95$3 + N[(x1 + N[(x1 * N[(N[(4.0 * t$95$6), $MachinePrecision] + N[(x1 * N[(3.0 + N[(N[(2.0 * N[(N[(x2 * -2.0), $MachinePrecision] + t$95$1), $MachinePrecision]), $MachinePrecision] + N[(x2 * 8.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 \cdot x1 + 1\\
t_1 := 3 - 2 \cdot x2\\
t_2 := x1 \cdot \left(x1 \cdot 3\right)\\
t_3 := 3 \cdot \left(x2 \cdot -2 - x1\right)\\
t_4 := 3 \cdot \frac{\left(t\_2 - 2 \cdot x2\right) - x1}{t\_0}\\
t_5 := 2 \cdot x2 - 3\\
t_6 := x2 \cdot t\_5\\
t_7 := 6 \cdot t\_5\\
t_8 := x1 + \left(t\_4 + \left(x1 + x1 \cdot \left(t\_7 + x1 \cdot \left(\left(x2 \cdot 8 + x1 \cdot \left(\left(6 \cdot \left(3 + x2 \cdot -2\right) + \left(t\_7 + x1 \cdot \left(\left(x2 \cdot 8 + 4 \cdot t\_1\right) - 6\right)\right)\right) - 3\right)\right) - 3\right)\right)\right)\right)\\
\mathbf{if}\;x1 \leq -2 \cdot 10^{+104}:\\
\;\;\;\;x1 + \left(\left(x1 + x1 \cdot \left(x1 \cdot \left(9 + x1 \cdot -19\right)\right)\right) + t\_3\right)\\
\mathbf{elif}\;x1 \leq -21500000:\\
\;\;\;\;t\_8\\
\mathbf{elif}\;x1 \leq 14.5:\\
\;\;\;\;x1 + \left(t\_4 + \left(x1 + 4 \cdot \left(x2 \cdot \left(x1 \cdot -3 + 2 \cdot \left(x1 \cdot x2\right)\right)\right)\right)\right)\\
\mathbf{elif}\;x1 \leq 1.45 \cdot 10^{+77}:\\
\;\;\;\;t\_8\\
\mathbf{elif}\;x1 \leq 10^{+139}:\\
\;\;\;\;x1 + \left(t\_3 + \left(x1 + \left(x1 \cdot \left(x1 \cdot x1\right) + \left(3 \cdot t\_2 + t\_0 \cdot \left(4 \cdot \left(x1 \cdot t\_6\right)\right)\right)\right)\right)\right)\\
\mathbf{elif}\;x1 \leq 4.5 \cdot 10^{+153}:\\
\;\;\;\;x1 + \left(x2 \cdot -6 + x1 \cdot \left(\left(x2 \cdot -12 + x1 \cdot \left(x1 \cdot 3 + 3 \cdot \left(3 - x2 \cdot -2\right)\right)\right) - 2\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 + \left(t\_3 + \left(x1 + x1 \cdot \left(4 \cdot t\_6 + x1 \cdot \left(3 + \left(2 \cdot \left(x2 \cdot -2 + t\_1\right) + x2 \cdot 8\right)\right)\right)\right)\right)\\
\end{array}
\end{array}
if x1 < -2e104Initial program 0.0%
Taylor expanded in x1 around inf 0.0%
Taylor expanded in x1 around 0 0.0%
mul-1-neg0.0%
unsub-neg0.0%
*-commutative0.0%
Simplified0.0%
Taylor expanded in x1 around 0 71.7%
Taylor expanded in x2 around 0 100.0%
*-commutative100.0%
Simplified100.0%
if -2e104 < x1 < -2.15e7 or 14.5 < x1 < 1.4500000000000001e77Initial program 96.1%
Taylor expanded in x1 around inf 96.0%
Taylor expanded in x1 around inf 82.9%
Taylor expanded in x1 around 0 79.6%
if -2.15e7 < x1 < 14.5Initial program 99.3%
Taylor expanded in x1 around 0 86.7%
Taylor expanded in x2 around 0 98.2%
if 1.4500000000000001e77 < x1 < 1.00000000000000003e139Initial program 100.0%
Taylor expanded in x1 around inf 100.0%
Taylor expanded in x1 around 0 100.0%
mul-1-neg100.0%
unsub-neg100.0%
*-commutative100.0%
Simplified100.0%
Taylor expanded in x1 around 0 80.3%
if 1.00000000000000003e139 < x1 < 4.5000000000000001e153Initial program 75.0%
Taylor expanded in x1 around 0 3.4%
Taylor expanded in x2 around 0 3.4%
associate-*r*3.4%
*-commutative3.4%
Simplified3.4%
Taylor expanded in x1 around 0 100.0%
if 4.5000000000000001e153 < x1 Initial program 0.0%
Taylor expanded in x1 around inf 0.0%
Taylor expanded in x1 around 0 0.0%
mul-1-neg0.0%
unsub-neg0.0%
*-commutative0.0%
Simplified0.0%
Taylor expanded in x1 around 0 100.0%
Final simplification95.6%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (+ (* x1 x1) 1.0))
(t_1 (* x1 (* x1 3.0)))
(t_2 (* 3.0 (/ (- (- t_1 (* 2.0 x2)) x1) t_0)))
(t_3
(+
x1
(+
t_2
(+
x1
(+
(* x1 (* x1 x1))
(+
(* 3.0 t_1)
(*
t_0
(+
(* (* x1 x1) 6.0)
(*
(- (/ (- (+ t_1 (* 2.0 x2)) x1) t_0) 3.0)
(* (* x1 2.0) 3.0))))))))))
(t_4 (* 3.0 (- (* x2 -2.0) x1))))
(if (<= x1 -2e+103)
(+ x1 (+ (+ x1 (* x1 (* x1 (+ 9.0 (* x1 -19.0))))) t_4))
(if (<= x1 -360000000.0)
t_3
(if (<= x1 58000.0)
(+ x1 (+ t_2 (+ x1 (* 4.0 (* x2 (+ (* x1 -3.0) (* 2.0 (* x1 x2))))))))
(if (<= x1 1e+152)
t_3
(+
x1
(+
t_4
(+
x1
(*
x1
(+
(* 4.0 (* x2 (- (* 2.0 x2) 3.0)))
(*
x1
(+
3.0
(+
(* 2.0 (+ (* x2 -2.0) (- 3.0 (* 2.0 x2))))
(* x2 8.0)))))))))))))))
double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = x1 * (x1 * 3.0);
double t_2 = 3.0 * (((t_1 - (2.0 * x2)) - x1) / t_0);
double t_3 = x1 + (t_2 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_1) + (t_0 * (((x1 * x1) * 6.0) + (((((t_1 + (2.0 * x2)) - x1) / t_0) - 3.0) * ((x1 * 2.0) * 3.0))))))));
double t_4 = 3.0 * ((x2 * -2.0) - x1);
double tmp;
if (x1 <= -2e+103) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_4);
} else if (x1 <= -360000000.0) {
tmp = t_3;
} else if (x1 <= 58000.0) {
tmp = x1 + (t_2 + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2)))))));
} else if (x1 <= 1e+152) {
tmp = t_3;
} else {
tmp = x1 + (t_4 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0))))))));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: t_4
real(8) :: tmp
t_0 = (x1 * x1) + 1.0d0
t_1 = x1 * (x1 * 3.0d0)
t_2 = 3.0d0 * (((t_1 - (2.0d0 * x2)) - x1) / t_0)
t_3 = x1 + (t_2 + (x1 + ((x1 * (x1 * x1)) + ((3.0d0 * t_1) + (t_0 * (((x1 * x1) * 6.0d0) + (((((t_1 + (2.0d0 * x2)) - x1) / t_0) - 3.0d0) * ((x1 * 2.0d0) * 3.0d0))))))))
t_4 = 3.0d0 * ((x2 * (-2.0d0)) - x1)
if (x1 <= (-2d+103)) then
tmp = x1 + ((x1 + (x1 * (x1 * (9.0d0 + (x1 * (-19.0d0)))))) + t_4)
else if (x1 <= (-360000000.0d0)) then
tmp = t_3
else if (x1 <= 58000.0d0) then
tmp = x1 + (t_2 + (x1 + (4.0d0 * (x2 * ((x1 * (-3.0d0)) + (2.0d0 * (x1 * x2)))))))
else if (x1 <= 1d+152) then
tmp = t_3
else
tmp = x1 + (t_4 + (x1 + (x1 * ((4.0d0 * (x2 * ((2.0d0 * x2) - 3.0d0))) + (x1 * (3.0d0 + ((2.0d0 * ((x2 * (-2.0d0)) + (3.0d0 - (2.0d0 * x2)))) + (x2 * 8.0d0))))))))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = x1 * (x1 * 3.0);
double t_2 = 3.0 * (((t_1 - (2.0 * x2)) - x1) / t_0);
double t_3 = x1 + (t_2 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_1) + (t_0 * (((x1 * x1) * 6.0) + (((((t_1 + (2.0 * x2)) - x1) / t_0) - 3.0) * ((x1 * 2.0) * 3.0))))))));
double t_4 = 3.0 * ((x2 * -2.0) - x1);
double tmp;
if (x1 <= -2e+103) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_4);
} else if (x1 <= -360000000.0) {
tmp = t_3;
} else if (x1 <= 58000.0) {
tmp = x1 + (t_2 + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2)))))));
} else if (x1 <= 1e+152) {
tmp = t_3;
} else {
tmp = x1 + (t_4 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0))))))));
}
return tmp;
}
def code(x1, x2): t_0 = (x1 * x1) + 1.0 t_1 = x1 * (x1 * 3.0) t_2 = 3.0 * (((t_1 - (2.0 * x2)) - x1) / t_0) t_3 = x1 + (t_2 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_1) + (t_0 * (((x1 * x1) * 6.0) + (((((t_1 + (2.0 * x2)) - x1) / t_0) - 3.0) * ((x1 * 2.0) * 3.0)))))))) t_4 = 3.0 * ((x2 * -2.0) - x1) tmp = 0 if x1 <= -2e+103: tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_4) elif x1 <= -360000000.0: tmp = t_3 elif x1 <= 58000.0: tmp = x1 + (t_2 + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2))))))) elif x1 <= 1e+152: tmp = t_3 else: tmp = x1 + (t_4 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0)))))))) return tmp
function code(x1, x2) t_0 = Float64(Float64(x1 * x1) + 1.0) t_1 = Float64(x1 * Float64(x1 * 3.0)) t_2 = Float64(3.0 * Float64(Float64(Float64(t_1 - Float64(2.0 * x2)) - x1) / t_0)) t_3 = Float64(x1 + Float64(t_2 + Float64(x1 + Float64(Float64(x1 * Float64(x1 * x1)) + Float64(Float64(3.0 * t_1) + Float64(t_0 * Float64(Float64(Float64(x1 * x1) * 6.0) + Float64(Float64(Float64(Float64(Float64(t_1 + Float64(2.0 * x2)) - x1) / t_0) - 3.0) * Float64(Float64(x1 * 2.0) * 3.0))))))))) t_4 = Float64(3.0 * Float64(Float64(x2 * -2.0) - x1)) tmp = 0.0 if (x1 <= -2e+103) tmp = Float64(x1 + Float64(Float64(x1 + Float64(x1 * Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))) + t_4)); elseif (x1 <= -360000000.0) tmp = t_3; elseif (x1 <= 58000.0) tmp = Float64(x1 + Float64(t_2 + Float64(x1 + Float64(4.0 * Float64(x2 * Float64(Float64(x1 * -3.0) + Float64(2.0 * Float64(x1 * x2)))))))); elseif (x1 <= 1e+152) tmp = t_3; else tmp = Float64(x1 + Float64(t_4 + Float64(x1 + Float64(x1 * Float64(Float64(4.0 * Float64(x2 * Float64(Float64(2.0 * x2) - 3.0))) + Float64(x1 * Float64(3.0 + Float64(Float64(2.0 * Float64(Float64(x2 * -2.0) + Float64(3.0 - Float64(2.0 * x2)))) + Float64(x2 * 8.0))))))))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = (x1 * x1) + 1.0; t_1 = x1 * (x1 * 3.0); t_2 = 3.0 * (((t_1 - (2.0 * x2)) - x1) / t_0); t_3 = x1 + (t_2 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_1) + (t_0 * (((x1 * x1) * 6.0) + (((((t_1 + (2.0 * x2)) - x1) / t_0) - 3.0) * ((x1 * 2.0) * 3.0)))))))); t_4 = 3.0 * ((x2 * -2.0) - x1); tmp = 0.0; if (x1 <= -2e+103) tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_4); elseif (x1 <= -360000000.0) tmp = t_3; elseif (x1 <= 58000.0) tmp = x1 + (t_2 + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2))))))); elseif (x1 <= 1e+152) tmp = t_3; else tmp = x1 + (t_4 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0)))))))); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(N[(x1 * x1), $MachinePrecision] + 1.0), $MachinePrecision]}, Block[{t$95$1 = N[(x1 * N[(x1 * 3.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(3.0 * N[(N[(N[(t$95$1 - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(x1 + N[(t$95$2 + N[(x1 + N[(N[(x1 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision] + N[(N[(3.0 * t$95$1), $MachinePrecision] + N[(t$95$0 * N[(N[(N[(x1 * x1), $MachinePrecision] * 6.0), $MachinePrecision] + N[(N[(N[(N[(N[(t$95$1 + N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$0), $MachinePrecision] - 3.0), $MachinePrecision] * N[(N[(x1 * 2.0), $MachinePrecision] * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] - x1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -2e+103], N[(x1 + N[(N[(x1 + N[(x1 * N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$4), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -360000000.0], t$95$3, If[LessEqual[x1, 58000.0], N[(x1 + N[(t$95$2 + N[(x1 + N[(4.0 * N[(x2 * N[(N[(x1 * -3.0), $MachinePrecision] + N[(2.0 * N[(x1 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 1e+152], t$95$3, N[(x1 + N[(t$95$4 + N[(x1 + N[(x1 * N[(N[(4.0 * N[(x2 * N[(N[(2.0 * x2), $MachinePrecision] - 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x1 * N[(3.0 + N[(N[(2.0 * N[(N[(x2 * -2.0), $MachinePrecision] + N[(3.0 - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x2 * 8.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 \cdot x1 + 1\\
t_1 := x1 \cdot \left(x1 \cdot 3\right)\\
t_2 := 3 \cdot \frac{\left(t\_1 - 2 \cdot x2\right) - x1}{t\_0}\\
t_3 := x1 + \left(t\_2 + \left(x1 + \left(x1 \cdot \left(x1 \cdot x1\right) + \left(3 \cdot t\_1 + t\_0 \cdot \left(\left(x1 \cdot x1\right) \cdot 6 + \left(\frac{\left(t\_1 + 2 \cdot x2\right) - x1}{t\_0} - 3\right) \cdot \left(\left(x1 \cdot 2\right) \cdot 3\right)\right)\right)\right)\right)\right)\\
t_4 := 3 \cdot \left(x2 \cdot -2 - x1\right)\\
\mathbf{if}\;x1 \leq -2 \cdot 10^{+103}:\\
\;\;\;\;x1 + \left(\left(x1 + x1 \cdot \left(x1 \cdot \left(9 + x1 \cdot -19\right)\right)\right) + t\_4\right)\\
\mathbf{elif}\;x1 \leq -360000000:\\
\;\;\;\;t\_3\\
\mathbf{elif}\;x1 \leq 58000:\\
\;\;\;\;x1 + \left(t\_2 + \left(x1 + 4 \cdot \left(x2 \cdot \left(x1 \cdot -3 + 2 \cdot \left(x1 \cdot x2\right)\right)\right)\right)\right)\\
\mathbf{elif}\;x1 \leq 10^{+152}:\\
\;\;\;\;t\_3\\
\mathbf{else}:\\
\;\;\;\;x1 + \left(t\_4 + \left(x1 + x1 \cdot \left(4 \cdot \left(x2 \cdot \left(2 \cdot x2 - 3\right)\right) + x1 \cdot \left(3 + \left(2 \cdot \left(x2 \cdot -2 + \left(3 - 2 \cdot x2\right)\right) + x2 \cdot 8\right)\right)\right)\right)\right)\\
\end{array}
\end{array}
if x1 < -2e103Initial program 0.0%
Taylor expanded in x1 around inf 0.0%
Taylor expanded in x1 around 0 0.0%
mul-1-neg0.0%
unsub-neg0.0%
*-commutative0.0%
Simplified0.0%
Taylor expanded in x1 around 0 70.4%
Taylor expanded in x2 around 0 100.0%
*-commutative100.0%
Simplified100.0%
if -2e103 < x1 < -3.6e8 or 58000 < x1 < 1e152Initial program 97.5%
Taylor expanded in x1 around inf 97.5%
Taylor expanded in x1 around inf 86.9%
Taylor expanded in x1 around inf 85.3%
if -3.6e8 < x1 < 58000Initial program 99.3%
Taylor expanded in x1 around 0 86.7%
Taylor expanded in x2 around 0 98.2%
if 1e152 < x1 Initial program 0.0%
Taylor expanded in x1 around inf 0.0%
Taylor expanded in x1 around 0 0.0%
mul-1-neg0.0%
unsub-neg0.0%
*-commutative0.0%
Simplified0.0%
Taylor expanded in x1 around 0 100.0%
Final simplification96.4%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (* x1 (* x1 3.0)))
(t_1 (+ (* x1 x1) 1.0))
(t_2 (/ (- (+ t_0 (* 2.0 x2)) x1) t_1))
(t_3 (* 3.0 (- (* x2 -2.0) x1))))
(if (<= x1 -6.2e+101)
(+ x1 (+ (+ x1 (* x1 (* x1 (+ 9.0 (* x1 -19.0))))) t_3))
(if (<= x1 1e+152)
(+
x1
(+
t_3
(+
x1
(+
(* x1 (* x1 x1))
(+
(* 3.0 t_0)
(*
t_1
(+ (* (* (* x1 2.0) t_2) (- t_2 3.0)) (* (* x1 x1) 6.0))))))))
(+
x1
(+
t_3
(+
x1
(*
x1
(+
(* 4.0 (* x2 (- (* 2.0 x2) 3.0)))
(*
x1
(+
3.0
(+
(* 2.0 (+ (* x2 -2.0) (- 3.0 (* 2.0 x2))))
(* x2 8.0)))))))))))))
double code(double x1, double x2) {
double t_0 = x1 * (x1 * 3.0);
double t_1 = (x1 * x1) + 1.0;
double t_2 = ((t_0 + (2.0 * x2)) - x1) / t_1;
double t_3 = 3.0 * ((x2 * -2.0) - x1);
double tmp;
if (x1 <= -6.2e+101) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3);
} else if (x1 <= 1e+152) {
tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_0) + (t_1 * ((((x1 * 2.0) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * 6.0)))))));
} else {
tmp = x1 + (t_3 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0))))))));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: tmp
t_0 = x1 * (x1 * 3.0d0)
t_1 = (x1 * x1) + 1.0d0
t_2 = ((t_0 + (2.0d0 * x2)) - x1) / t_1
t_3 = 3.0d0 * ((x2 * (-2.0d0)) - x1)
if (x1 <= (-6.2d+101)) then
tmp = x1 + ((x1 + (x1 * (x1 * (9.0d0 + (x1 * (-19.0d0)))))) + t_3)
else if (x1 <= 1d+152) then
tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((3.0d0 * t_0) + (t_1 * ((((x1 * 2.0d0) * t_2) * (t_2 - 3.0d0)) + ((x1 * x1) * 6.0d0)))))))
else
tmp = x1 + (t_3 + (x1 + (x1 * ((4.0d0 * (x2 * ((2.0d0 * x2) - 3.0d0))) + (x1 * (3.0d0 + ((2.0d0 * ((x2 * (-2.0d0)) + (3.0d0 - (2.0d0 * x2)))) + (x2 * 8.0d0))))))))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = x1 * (x1 * 3.0);
double t_1 = (x1 * x1) + 1.0;
double t_2 = ((t_0 + (2.0 * x2)) - x1) / t_1;
double t_3 = 3.0 * ((x2 * -2.0) - x1);
double tmp;
if (x1 <= -6.2e+101) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3);
} else if (x1 <= 1e+152) {
tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_0) + (t_1 * ((((x1 * 2.0) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * 6.0)))))));
} else {
tmp = x1 + (t_3 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0))))))));
}
return tmp;
}
def code(x1, x2): t_0 = x1 * (x1 * 3.0) t_1 = (x1 * x1) + 1.0 t_2 = ((t_0 + (2.0 * x2)) - x1) / t_1 t_3 = 3.0 * ((x2 * -2.0) - x1) tmp = 0 if x1 <= -6.2e+101: tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3) elif x1 <= 1e+152: tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_0) + (t_1 * ((((x1 * 2.0) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * 6.0))))))) else: tmp = x1 + (t_3 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0)))))))) return tmp
function code(x1, x2) t_0 = Float64(x1 * Float64(x1 * 3.0)) t_1 = Float64(Float64(x1 * x1) + 1.0) t_2 = Float64(Float64(Float64(t_0 + Float64(2.0 * x2)) - x1) / t_1) t_3 = Float64(3.0 * Float64(Float64(x2 * -2.0) - x1)) tmp = 0.0 if (x1 <= -6.2e+101) tmp = Float64(x1 + Float64(Float64(x1 + Float64(x1 * Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))) + t_3)); elseif (x1 <= 1e+152) tmp = Float64(x1 + Float64(t_3 + Float64(x1 + Float64(Float64(x1 * Float64(x1 * x1)) + Float64(Float64(3.0 * t_0) + Float64(t_1 * Float64(Float64(Float64(Float64(x1 * 2.0) * t_2) * Float64(t_2 - 3.0)) + Float64(Float64(x1 * x1) * 6.0)))))))); else tmp = Float64(x1 + Float64(t_3 + Float64(x1 + Float64(x1 * Float64(Float64(4.0 * Float64(x2 * Float64(Float64(2.0 * x2) - 3.0))) + Float64(x1 * Float64(3.0 + Float64(Float64(2.0 * Float64(Float64(x2 * -2.0) + Float64(3.0 - Float64(2.0 * x2)))) + Float64(x2 * 8.0))))))))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = x1 * (x1 * 3.0); t_1 = (x1 * x1) + 1.0; t_2 = ((t_0 + (2.0 * x2)) - x1) / t_1; t_3 = 3.0 * ((x2 * -2.0) - x1); tmp = 0.0; if (x1 <= -6.2e+101) tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3); elseif (x1 <= 1e+152) tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_0) + (t_1 * ((((x1 * 2.0) * t_2) * (t_2 - 3.0)) + ((x1 * x1) * 6.0))))))); else tmp = x1 + (t_3 + (x1 + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0)))))))); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(x1 * N[(x1 * 3.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[(x1 * x1), $MachinePrecision] + 1.0), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(t$95$0 + N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$1), $MachinePrecision]}, Block[{t$95$3 = N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] - x1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -6.2e+101], N[(x1 + N[(N[(x1 + N[(x1 * N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$3), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 1e+152], N[(x1 + N[(t$95$3 + N[(x1 + N[(N[(x1 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision] + N[(N[(3.0 * t$95$0), $MachinePrecision] + N[(t$95$1 * N[(N[(N[(N[(x1 * 2.0), $MachinePrecision] * t$95$2), $MachinePrecision] * N[(t$95$2 - 3.0), $MachinePrecision]), $MachinePrecision] + N[(N[(x1 * x1), $MachinePrecision] * 6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 + N[(t$95$3 + N[(x1 + N[(x1 * N[(N[(4.0 * N[(x2 * N[(N[(2.0 * x2), $MachinePrecision] - 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x1 * N[(3.0 + N[(N[(2.0 * N[(N[(x2 * -2.0), $MachinePrecision] + N[(3.0 - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x2 * 8.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 \cdot \left(x1 \cdot 3\right)\\
t_1 := x1 \cdot x1 + 1\\
t_2 := \frac{\left(t\_0 + 2 \cdot x2\right) - x1}{t\_1}\\
t_3 := 3 \cdot \left(x2 \cdot -2 - x1\right)\\
\mathbf{if}\;x1 \leq -6.2 \cdot 10^{+101}:\\
\;\;\;\;x1 + \left(\left(x1 + x1 \cdot \left(x1 \cdot \left(9 + x1 \cdot -19\right)\right)\right) + t\_3\right)\\
\mathbf{elif}\;x1 \leq 10^{+152}:\\
\;\;\;\;x1 + \left(t\_3 + \left(x1 + \left(x1 \cdot \left(x1 \cdot x1\right) + \left(3 \cdot t\_0 + t\_1 \cdot \left(\left(\left(x1 \cdot 2\right) \cdot t\_2\right) \cdot \left(t\_2 - 3\right) + \left(x1 \cdot x1\right) \cdot 6\right)\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 + \left(t\_3 + \left(x1 + x1 \cdot \left(4 \cdot \left(x2 \cdot \left(2 \cdot x2 - 3\right)\right) + x1 \cdot \left(3 + \left(2 \cdot \left(x2 \cdot -2 + \left(3 - 2 \cdot x2\right)\right) + x2 \cdot 8\right)\right)\right)\right)\right)\\
\end{array}
\end{array}
if x1 < -6.19999999999999998e101Initial program 1.8%
Taylor expanded in x1 around inf 1.8%
Taylor expanded in x1 around 0 1.8%
mul-1-neg1.8%
unsub-neg1.8%
*-commutative1.8%
Simplified1.8%
Taylor expanded in x1 around 0 69.1%
Taylor expanded in x2 around 0 98.5%
*-commutative98.5%
Simplified98.5%
if -6.19999999999999998e101 < x1 < 1e152Initial program 98.8%
Taylor expanded in x1 around inf 98.3%
Taylor expanded in x1 around 0 98.8%
mul-1-neg98.8%
unsub-neg98.8%
*-commutative98.8%
Simplified98.8%
Taylor expanded in x1 around inf 97.2%
if 1e152 < x1 Initial program 0.0%
Taylor expanded in x1 around inf 0.0%
Taylor expanded in x1 around 0 0.0%
mul-1-neg0.0%
unsub-neg0.0%
*-commutative0.0%
Simplified0.0%
Taylor expanded in x1 around 0 100.0%
Final simplification97.8%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (+ (* x1 x1) 1.0))
(t_1 (* x2 (- (* 2.0 x2) 3.0)))
(t_2 (* x1 (* x1 3.0)))
(t_3 (* 3.0 (- (* x2 -2.0) x1))))
(if (<= x1 -3.55e+96)
(+ x1 (+ (+ x1 (* x1 (* x1 (+ 9.0 (* x1 -19.0))))) t_3))
(if (<= x1 3e-102)
(+
x1
(+
(* 3.0 (/ (- (- t_2 (* 2.0 x2)) x1) t_0))
(+ x1 (* 4.0 (* x2 (+ (* x1 -3.0) (* 2.0 (* x1 x2))))))))
(if (<= x1 7.6e+153)
(+
x1
(+
t_3
(+
x1
(+ (* x1 (* x1 x1)) (+ (* 3.0 t_2) (* t_0 (* 4.0 (* x1 t_1))))))))
(+
x1
(+
t_3
(+
x1
(*
x1
(+
(* 4.0 t_1)
(*
x1
(+
3.0
(+
(* 2.0 (+ (* x2 -2.0) (- 3.0 (* 2.0 x2))))
(* x2 8.0))))))))))))))
double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = x2 * ((2.0 * x2) - 3.0);
double t_2 = x1 * (x1 * 3.0);
double t_3 = 3.0 * ((x2 * -2.0) - x1);
double tmp;
if (x1 <= -3.55e+96) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3);
} else if (x1 <= 3e-102) {
tmp = x1 + ((3.0 * (((t_2 - (2.0 * x2)) - x1) / t_0)) + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2)))))));
} else if (x1 <= 7.6e+153) {
tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_2) + (t_0 * (4.0 * (x1 * t_1)))))));
} else {
tmp = x1 + (t_3 + (x1 + (x1 * ((4.0 * t_1) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0))))))));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: tmp
t_0 = (x1 * x1) + 1.0d0
t_1 = x2 * ((2.0d0 * x2) - 3.0d0)
t_2 = x1 * (x1 * 3.0d0)
t_3 = 3.0d0 * ((x2 * (-2.0d0)) - x1)
if (x1 <= (-3.55d+96)) then
tmp = x1 + ((x1 + (x1 * (x1 * (9.0d0 + (x1 * (-19.0d0)))))) + t_3)
else if (x1 <= 3d-102) then
tmp = x1 + ((3.0d0 * (((t_2 - (2.0d0 * x2)) - x1) / t_0)) + (x1 + (4.0d0 * (x2 * ((x1 * (-3.0d0)) + (2.0d0 * (x1 * x2)))))))
else if (x1 <= 7.6d+153) then
tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((3.0d0 * t_2) + (t_0 * (4.0d0 * (x1 * t_1)))))))
else
tmp = x1 + (t_3 + (x1 + (x1 * ((4.0d0 * t_1) + (x1 * (3.0d0 + ((2.0d0 * ((x2 * (-2.0d0)) + (3.0d0 - (2.0d0 * x2)))) + (x2 * 8.0d0))))))))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = x2 * ((2.0 * x2) - 3.0);
double t_2 = x1 * (x1 * 3.0);
double t_3 = 3.0 * ((x2 * -2.0) - x1);
double tmp;
if (x1 <= -3.55e+96) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3);
} else if (x1 <= 3e-102) {
tmp = x1 + ((3.0 * (((t_2 - (2.0 * x2)) - x1) / t_0)) + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2)))))));
} else if (x1 <= 7.6e+153) {
tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_2) + (t_0 * (4.0 * (x1 * t_1)))))));
} else {
tmp = x1 + (t_3 + (x1 + (x1 * ((4.0 * t_1) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0))))))));
}
return tmp;
}
def code(x1, x2): t_0 = (x1 * x1) + 1.0 t_1 = x2 * ((2.0 * x2) - 3.0) t_2 = x1 * (x1 * 3.0) t_3 = 3.0 * ((x2 * -2.0) - x1) tmp = 0 if x1 <= -3.55e+96: tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3) elif x1 <= 3e-102: tmp = x1 + ((3.0 * (((t_2 - (2.0 * x2)) - x1) / t_0)) + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2))))))) elif x1 <= 7.6e+153: tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_2) + (t_0 * (4.0 * (x1 * t_1))))))) else: tmp = x1 + (t_3 + (x1 + (x1 * ((4.0 * t_1) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0)))))))) return tmp
function code(x1, x2) t_0 = Float64(Float64(x1 * x1) + 1.0) t_1 = Float64(x2 * Float64(Float64(2.0 * x2) - 3.0)) t_2 = Float64(x1 * Float64(x1 * 3.0)) t_3 = Float64(3.0 * Float64(Float64(x2 * -2.0) - x1)) tmp = 0.0 if (x1 <= -3.55e+96) tmp = Float64(x1 + Float64(Float64(x1 + Float64(x1 * Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))) + t_3)); elseif (x1 <= 3e-102) tmp = Float64(x1 + Float64(Float64(3.0 * Float64(Float64(Float64(t_2 - Float64(2.0 * x2)) - x1) / t_0)) + Float64(x1 + Float64(4.0 * Float64(x2 * Float64(Float64(x1 * -3.0) + Float64(2.0 * Float64(x1 * x2)))))))); elseif (x1 <= 7.6e+153) tmp = Float64(x1 + Float64(t_3 + Float64(x1 + Float64(Float64(x1 * Float64(x1 * x1)) + Float64(Float64(3.0 * t_2) + Float64(t_0 * Float64(4.0 * Float64(x1 * t_1)))))))); else tmp = Float64(x1 + Float64(t_3 + Float64(x1 + Float64(x1 * Float64(Float64(4.0 * t_1) + Float64(x1 * Float64(3.0 + Float64(Float64(2.0 * Float64(Float64(x2 * -2.0) + Float64(3.0 - Float64(2.0 * x2)))) + Float64(x2 * 8.0))))))))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = (x1 * x1) + 1.0; t_1 = x2 * ((2.0 * x2) - 3.0); t_2 = x1 * (x1 * 3.0); t_3 = 3.0 * ((x2 * -2.0) - x1); tmp = 0.0; if (x1 <= -3.55e+96) tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_3); elseif (x1 <= 3e-102) tmp = x1 + ((3.0 * (((t_2 - (2.0 * x2)) - x1) / t_0)) + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2))))))); elseif (x1 <= 7.6e+153) tmp = x1 + (t_3 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_2) + (t_0 * (4.0 * (x1 * t_1))))))); else tmp = x1 + (t_3 + (x1 + (x1 * ((4.0 * t_1) + (x1 * (3.0 + ((2.0 * ((x2 * -2.0) + (3.0 - (2.0 * x2)))) + (x2 * 8.0)))))))); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(N[(x1 * x1), $MachinePrecision] + 1.0), $MachinePrecision]}, Block[{t$95$1 = N[(x2 * N[(N[(2.0 * x2), $MachinePrecision] - 3.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x1 * N[(x1 * 3.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] - x1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -3.55e+96], N[(x1 + N[(N[(x1 + N[(x1 * N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$3), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 3e-102], N[(x1 + N[(N[(3.0 * N[(N[(N[(t$95$2 - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$0), $MachinePrecision]), $MachinePrecision] + N[(x1 + N[(4.0 * N[(x2 * N[(N[(x1 * -3.0), $MachinePrecision] + N[(2.0 * N[(x1 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 7.6e+153], N[(x1 + N[(t$95$3 + N[(x1 + N[(N[(x1 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision] + N[(N[(3.0 * t$95$2), $MachinePrecision] + N[(t$95$0 * N[(4.0 * N[(x1 * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 + N[(t$95$3 + N[(x1 + N[(x1 * N[(N[(4.0 * t$95$1), $MachinePrecision] + N[(x1 * N[(3.0 + N[(N[(2.0 * N[(N[(x2 * -2.0), $MachinePrecision] + N[(3.0 - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x2 * 8.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 \cdot x1 + 1\\
t_1 := x2 \cdot \left(2 \cdot x2 - 3\right)\\
t_2 := x1 \cdot \left(x1 \cdot 3\right)\\
t_3 := 3 \cdot \left(x2 \cdot -2 - x1\right)\\
\mathbf{if}\;x1 \leq -3.55 \cdot 10^{+96}:\\
\;\;\;\;x1 + \left(\left(x1 + x1 \cdot \left(x1 \cdot \left(9 + x1 \cdot -19\right)\right)\right) + t\_3\right)\\
\mathbf{elif}\;x1 \leq 3 \cdot 10^{-102}:\\
\;\;\;\;x1 + \left(3 \cdot \frac{\left(t\_2 - 2 \cdot x2\right) - x1}{t\_0} + \left(x1 + 4 \cdot \left(x2 \cdot \left(x1 \cdot -3 + 2 \cdot \left(x1 \cdot x2\right)\right)\right)\right)\right)\\
\mathbf{elif}\;x1 \leq 7.6 \cdot 10^{+153}:\\
\;\;\;\;x1 + \left(t\_3 + \left(x1 + \left(x1 \cdot \left(x1 \cdot x1\right) + \left(3 \cdot t\_2 + t\_0 \cdot \left(4 \cdot \left(x1 \cdot t\_1\right)\right)\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 + \left(t\_3 + \left(x1 + x1 \cdot \left(4 \cdot t\_1 + x1 \cdot \left(3 + \left(2 \cdot \left(x2 \cdot -2 + \left(3 - 2 \cdot x2\right)\right) + x2 \cdot 8\right)\right)\right)\right)\right)\\
\end{array}
\end{array}
if x1 < -3.54999999999999977e96Initial program 5.3%
Taylor expanded in x1 around inf 5.3%
Taylor expanded in x1 around 0 5.3%
mul-1-neg5.3%
unsub-neg5.3%
*-commutative5.3%
Simplified5.3%
Taylor expanded in x1 around 0 67.1%
Taylor expanded in x2 around 0 95.4%
*-commutative95.4%
Simplified95.4%
if -3.54999999999999977e96 < x1 < 3e-102Initial program 99.5%
Taylor expanded in x1 around 0 76.3%
Taylor expanded in x2 around 0 89.8%
if 3e-102 < x1 < 7.59999999999999933e153Initial program 97.6%
Taylor expanded in x1 around inf 96.1%
Taylor expanded in x1 around 0 97.6%
mul-1-neg97.6%
unsub-neg97.6%
*-commutative97.6%
Simplified97.6%
Taylor expanded in x1 around 0 79.5%
if 7.59999999999999933e153 < x1 Initial program 0.0%
Taylor expanded in x1 around inf 0.0%
Taylor expanded in x1 around 0 0.0%
mul-1-neg0.0%
unsub-neg0.0%
*-commutative0.0%
Simplified0.0%
Taylor expanded in x1 around 0 100.0%
Final simplification89.5%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (+ (* x1 x1) 1.0))
(t_1 (* x1 (* x1 3.0)))
(t_2 (* 3.0 (- (* x2 -2.0) x1))))
(if (<= x1 -7e+95)
(+ x1 (+ (+ x1 (* x1 (* x1 (+ 9.0 (* x1 -19.0))))) t_2))
(if (<= x1 1e-102)
(+
x1
(+
(* 3.0 (/ (- (- t_1 (* 2.0 x2)) x1) t_0))
(+ x1 (* 4.0 (* x2 (+ (* x1 -3.0) (* 2.0 (* x1 x2))))))))
(if (<= x1 9.2e+194)
(+
x1
(+
t_2
(+
x1
(+
(* x1 (* x1 x1))
(+
(* 3.0 t_1)
(* t_0 (* 4.0 (* x1 (* x2 (- (* 2.0 x2) 3.0))))))))))
(+
x1
(+
(* x2 -6.0)
(*
x1
(-
(+ (* x2 -12.0) (* x1 (+ (* x1 3.0) (* 3.0 (- 3.0 (* x2 -2.0))))))
2.0)))))))))
double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = x1 * (x1 * 3.0);
double t_2 = 3.0 * ((x2 * -2.0) - x1);
double tmp;
if (x1 <= -7e+95) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_2);
} else if (x1 <= 1e-102) {
tmp = x1 + ((3.0 * (((t_1 - (2.0 * x2)) - x1) / t_0)) + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2)))))));
} else if (x1 <= 9.2e+194) {
tmp = x1 + (t_2 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_1) + (t_0 * (4.0 * (x1 * (x2 * ((2.0 * x2) - 3.0)))))))));
} else {
tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0)));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_0 = (x1 * x1) + 1.0d0
t_1 = x1 * (x1 * 3.0d0)
t_2 = 3.0d0 * ((x2 * (-2.0d0)) - x1)
if (x1 <= (-7d+95)) then
tmp = x1 + ((x1 + (x1 * (x1 * (9.0d0 + (x1 * (-19.0d0)))))) + t_2)
else if (x1 <= 1d-102) then
tmp = x1 + ((3.0d0 * (((t_1 - (2.0d0 * x2)) - x1) / t_0)) + (x1 + (4.0d0 * (x2 * ((x1 * (-3.0d0)) + (2.0d0 * (x1 * x2)))))))
else if (x1 <= 9.2d+194) then
tmp = x1 + (t_2 + (x1 + ((x1 * (x1 * x1)) + ((3.0d0 * t_1) + (t_0 * (4.0d0 * (x1 * (x2 * ((2.0d0 * x2) - 3.0d0)))))))))
else
tmp = x1 + ((x2 * (-6.0d0)) + (x1 * (((x2 * (-12.0d0)) + (x1 * ((x1 * 3.0d0) + (3.0d0 * (3.0d0 - (x2 * (-2.0d0))))))) - 2.0d0)))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = x1 * (x1 * 3.0);
double t_2 = 3.0 * ((x2 * -2.0) - x1);
double tmp;
if (x1 <= -7e+95) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_2);
} else if (x1 <= 1e-102) {
tmp = x1 + ((3.0 * (((t_1 - (2.0 * x2)) - x1) / t_0)) + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2)))))));
} else if (x1 <= 9.2e+194) {
tmp = x1 + (t_2 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_1) + (t_0 * (4.0 * (x1 * (x2 * ((2.0 * x2) - 3.0)))))))));
} else {
tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0)));
}
return tmp;
}
def code(x1, x2): t_0 = (x1 * x1) + 1.0 t_1 = x1 * (x1 * 3.0) t_2 = 3.0 * ((x2 * -2.0) - x1) tmp = 0 if x1 <= -7e+95: tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_2) elif x1 <= 1e-102: tmp = x1 + ((3.0 * (((t_1 - (2.0 * x2)) - x1) / t_0)) + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2))))))) elif x1 <= 9.2e+194: tmp = x1 + (t_2 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_1) + (t_0 * (4.0 * (x1 * (x2 * ((2.0 * x2) - 3.0))))))))) else: tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0))) return tmp
function code(x1, x2) t_0 = Float64(Float64(x1 * x1) + 1.0) t_1 = Float64(x1 * Float64(x1 * 3.0)) t_2 = Float64(3.0 * Float64(Float64(x2 * -2.0) - x1)) tmp = 0.0 if (x1 <= -7e+95) tmp = Float64(x1 + Float64(Float64(x1 + Float64(x1 * Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))) + t_2)); elseif (x1 <= 1e-102) tmp = Float64(x1 + Float64(Float64(3.0 * Float64(Float64(Float64(t_1 - Float64(2.0 * x2)) - x1) / t_0)) + Float64(x1 + Float64(4.0 * Float64(x2 * Float64(Float64(x1 * -3.0) + Float64(2.0 * Float64(x1 * x2)))))))); elseif (x1 <= 9.2e+194) tmp = Float64(x1 + Float64(t_2 + Float64(x1 + Float64(Float64(x1 * Float64(x1 * x1)) + Float64(Float64(3.0 * t_1) + Float64(t_0 * Float64(4.0 * Float64(x1 * Float64(x2 * Float64(Float64(2.0 * x2) - 3.0)))))))))); else tmp = Float64(x1 + Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(Float64(Float64(x2 * -12.0) + Float64(x1 * Float64(Float64(x1 * 3.0) + Float64(3.0 * Float64(3.0 - Float64(x2 * -2.0)))))) - 2.0)))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = (x1 * x1) + 1.0; t_1 = x1 * (x1 * 3.0); t_2 = 3.0 * ((x2 * -2.0) - x1); tmp = 0.0; if (x1 <= -7e+95) tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + t_2); elseif (x1 <= 1e-102) tmp = x1 + ((3.0 * (((t_1 - (2.0 * x2)) - x1) / t_0)) + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2))))))); elseif (x1 <= 9.2e+194) tmp = x1 + (t_2 + (x1 + ((x1 * (x1 * x1)) + ((3.0 * t_1) + (t_0 * (4.0 * (x1 * (x2 * ((2.0 * x2) - 3.0))))))))); else tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0))); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(N[(x1 * x1), $MachinePrecision] + 1.0), $MachinePrecision]}, Block[{t$95$1 = N[(x1 * N[(x1 * 3.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] - x1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -7e+95], N[(x1 + N[(N[(x1 + N[(x1 * N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$2), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 1e-102], N[(x1 + N[(N[(3.0 * N[(N[(N[(t$95$1 - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$0), $MachinePrecision]), $MachinePrecision] + N[(x1 + N[(4.0 * N[(x2 * N[(N[(x1 * -3.0), $MachinePrecision] + N[(2.0 * N[(x1 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 9.2e+194], N[(x1 + N[(t$95$2 + N[(x1 + N[(N[(x1 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision] + N[(N[(3.0 * t$95$1), $MachinePrecision] + N[(t$95$0 * N[(4.0 * N[(x1 * N[(x2 * N[(N[(2.0 * x2), $MachinePrecision] - 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 + N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(N[(N[(x2 * -12.0), $MachinePrecision] + N[(x1 * N[(N[(x1 * 3.0), $MachinePrecision] + N[(3.0 * N[(3.0 - N[(x2 * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 \cdot x1 + 1\\
t_1 := x1 \cdot \left(x1 \cdot 3\right)\\
t_2 := 3 \cdot \left(x2 \cdot -2 - x1\right)\\
\mathbf{if}\;x1 \leq -7 \cdot 10^{+95}:\\
\;\;\;\;x1 + \left(\left(x1 + x1 \cdot \left(x1 \cdot \left(9 + x1 \cdot -19\right)\right)\right) + t\_2\right)\\
\mathbf{elif}\;x1 \leq 10^{-102}:\\
\;\;\;\;x1 + \left(3 \cdot \frac{\left(t\_1 - 2 \cdot x2\right) - x1}{t\_0} + \left(x1 + 4 \cdot \left(x2 \cdot \left(x1 \cdot -3 + 2 \cdot \left(x1 \cdot x2\right)\right)\right)\right)\right)\\
\mathbf{elif}\;x1 \leq 9.2 \cdot 10^{+194}:\\
\;\;\;\;x1 + \left(t\_2 + \left(x1 + \left(x1 \cdot \left(x1 \cdot x1\right) + \left(3 \cdot t\_1 + t\_0 \cdot \left(4 \cdot \left(x1 \cdot \left(x2 \cdot \left(2 \cdot x2 - 3\right)\right)\right)\right)\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 + \left(x2 \cdot -6 + x1 \cdot \left(\left(x2 \cdot -12 + x1 \cdot \left(x1 \cdot 3 + 3 \cdot \left(3 - x2 \cdot -2\right)\right)\right) - 2\right)\right)\\
\end{array}
\end{array}
if x1 < -6.99999999999999999e95Initial program 5.3%
Taylor expanded in x1 around inf 5.3%
Taylor expanded in x1 around 0 5.3%
mul-1-neg5.3%
unsub-neg5.3%
*-commutative5.3%
Simplified5.3%
Taylor expanded in x1 around 0 67.1%
Taylor expanded in x2 around 0 95.4%
*-commutative95.4%
Simplified95.4%
if -6.99999999999999999e95 < x1 < 9.99999999999999933e-103Initial program 99.5%
Taylor expanded in x1 around 0 76.3%
Taylor expanded in x2 around 0 89.8%
if 9.99999999999999933e-103 < x1 < 9.2000000000000002e194Initial program 90.4%
Taylor expanded in x1 around inf 89.0%
Taylor expanded in x1 around 0 90.4%
mul-1-neg90.4%
unsub-neg90.4%
*-commutative90.4%
Simplified90.4%
Taylor expanded in x1 around 0 81.0%
if 9.2000000000000002e194 < x1 Initial program 0.0%
Taylor expanded in x1 around 0 0.0%
Taylor expanded in x2 around 0 0.0%
associate-*r*0.0%
*-commutative0.0%
Simplified0.0%
Taylor expanded in x1 around 0 100.0%
Final simplification89.5%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (* x2 (- (* 2.0 x2) 3.0))))
(if (<= x1 -1.55e+96)
(+
x1
(+ (+ x1 (* x1 (* x1 (+ 9.0 (* x1 -19.0))))) (* 3.0 (- (* x2 -2.0) x1))))
(if (<= x1 -3.3e-229)
(+ x1 (+ (* x2 -6.0) (* x1 (- (* 4.0 t_0) 2.0))))
(if (<= x1 4e-195)
(- (* x2 -6.0) x1)
(if (<= x1 8e+81)
(+
x1
(+
(*
3.0
(/ (- (- (* x1 (* x1 3.0)) (* 2.0 x2)) x1) (+ (* x1 x1) 1.0)))
(+ x1 (* 4.0 (* x1 t_0)))))
(+
x1
(+
(* x2 -6.0)
(*
x1
(-
(+
(* x2 -12.0)
(* x1 (+ (* x1 3.0) (* 3.0 (- 3.0 (* x2 -2.0))))))
2.0))))))))))
double code(double x1, double x2) {
double t_0 = x2 * ((2.0 * x2) - 3.0);
double tmp;
if (x1 <= -1.55e+96) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1)));
} else if (x1 <= -3.3e-229) {
tmp = x1 + ((x2 * -6.0) + (x1 * ((4.0 * t_0) - 2.0)));
} else if (x1 <= 4e-195) {
tmp = (x2 * -6.0) - x1;
} else if (x1 <= 8e+81) {
tmp = x1 + ((3.0 * ((((x1 * (x1 * 3.0)) - (2.0 * x2)) - x1) / ((x1 * x1) + 1.0))) + (x1 + (4.0 * (x1 * t_0))));
} else {
tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0)));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: tmp
t_0 = x2 * ((2.0d0 * x2) - 3.0d0)
if (x1 <= (-1.55d+96)) then
tmp = x1 + ((x1 + (x1 * (x1 * (9.0d0 + (x1 * (-19.0d0)))))) + (3.0d0 * ((x2 * (-2.0d0)) - x1)))
else if (x1 <= (-3.3d-229)) then
tmp = x1 + ((x2 * (-6.0d0)) + (x1 * ((4.0d0 * t_0) - 2.0d0)))
else if (x1 <= 4d-195) then
tmp = (x2 * (-6.0d0)) - x1
else if (x1 <= 8d+81) then
tmp = x1 + ((3.0d0 * ((((x1 * (x1 * 3.0d0)) - (2.0d0 * x2)) - x1) / ((x1 * x1) + 1.0d0))) + (x1 + (4.0d0 * (x1 * t_0))))
else
tmp = x1 + ((x2 * (-6.0d0)) + (x1 * (((x2 * (-12.0d0)) + (x1 * ((x1 * 3.0d0) + (3.0d0 * (3.0d0 - (x2 * (-2.0d0))))))) - 2.0d0)))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = x2 * ((2.0 * x2) - 3.0);
double tmp;
if (x1 <= -1.55e+96) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1)));
} else if (x1 <= -3.3e-229) {
tmp = x1 + ((x2 * -6.0) + (x1 * ((4.0 * t_0) - 2.0)));
} else if (x1 <= 4e-195) {
tmp = (x2 * -6.0) - x1;
} else if (x1 <= 8e+81) {
tmp = x1 + ((3.0 * ((((x1 * (x1 * 3.0)) - (2.0 * x2)) - x1) / ((x1 * x1) + 1.0))) + (x1 + (4.0 * (x1 * t_0))));
} else {
tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0)));
}
return tmp;
}
def code(x1, x2): t_0 = x2 * ((2.0 * x2) - 3.0) tmp = 0 if x1 <= -1.55e+96: tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1))) elif x1 <= -3.3e-229: tmp = x1 + ((x2 * -6.0) + (x1 * ((4.0 * t_0) - 2.0))) elif x1 <= 4e-195: tmp = (x2 * -6.0) - x1 elif x1 <= 8e+81: tmp = x1 + ((3.0 * ((((x1 * (x1 * 3.0)) - (2.0 * x2)) - x1) / ((x1 * x1) + 1.0))) + (x1 + (4.0 * (x1 * t_0)))) else: tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0))) return tmp
function code(x1, x2) t_0 = Float64(x2 * Float64(Float64(2.0 * x2) - 3.0)) tmp = 0.0 if (x1 <= -1.55e+96) tmp = Float64(x1 + Float64(Float64(x1 + Float64(x1 * Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))) + Float64(3.0 * Float64(Float64(x2 * -2.0) - x1)))); elseif (x1 <= -3.3e-229) tmp = Float64(x1 + Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(Float64(4.0 * t_0) - 2.0)))); elseif (x1 <= 4e-195) tmp = Float64(Float64(x2 * -6.0) - x1); elseif (x1 <= 8e+81) tmp = Float64(x1 + Float64(Float64(3.0 * Float64(Float64(Float64(Float64(x1 * Float64(x1 * 3.0)) - Float64(2.0 * x2)) - x1) / Float64(Float64(x1 * x1) + 1.0))) + Float64(x1 + Float64(4.0 * Float64(x1 * t_0))))); else tmp = Float64(x1 + Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(Float64(Float64(x2 * -12.0) + Float64(x1 * Float64(Float64(x1 * 3.0) + Float64(3.0 * Float64(3.0 - Float64(x2 * -2.0)))))) - 2.0)))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = x2 * ((2.0 * x2) - 3.0); tmp = 0.0; if (x1 <= -1.55e+96) tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1))); elseif (x1 <= -3.3e-229) tmp = x1 + ((x2 * -6.0) + (x1 * ((4.0 * t_0) - 2.0))); elseif (x1 <= 4e-195) tmp = (x2 * -6.0) - x1; elseif (x1 <= 8e+81) tmp = x1 + ((3.0 * ((((x1 * (x1 * 3.0)) - (2.0 * x2)) - x1) / ((x1 * x1) + 1.0))) + (x1 + (4.0 * (x1 * t_0)))); else tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0))); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(x2 * N[(N[(2.0 * x2), $MachinePrecision] - 3.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -1.55e+96], N[(x1 + N[(N[(x1 + N[(x1 * N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] - x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -3.3e-229], N[(x1 + N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(N[(4.0 * t$95$0), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 4e-195], N[(N[(x2 * -6.0), $MachinePrecision] - x1), $MachinePrecision], If[LessEqual[x1, 8e+81], N[(x1 + N[(N[(3.0 * N[(N[(N[(N[(x1 * N[(x1 * 3.0), $MachinePrecision]), $MachinePrecision] - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / N[(N[(x1 * x1), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x1 + N[(4.0 * N[(x1 * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 + N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(N[(N[(x2 * -12.0), $MachinePrecision] + N[(x1 * N[(N[(x1 * 3.0), $MachinePrecision] + N[(3.0 * N[(3.0 - N[(x2 * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x2 \cdot \left(2 \cdot x2 - 3\right)\\
\mathbf{if}\;x1 \leq -1.55 \cdot 10^{+96}:\\
\;\;\;\;x1 + \left(\left(x1 + x1 \cdot \left(x1 \cdot \left(9 + x1 \cdot -19\right)\right)\right) + 3 \cdot \left(x2 \cdot -2 - x1\right)\right)\\
\mathbf{elif}\;x1 \leq -3.3 \cdot 10^{-229}:\\
\;\;\;\;x1 + \left(x2 \cdot -6 + x1 \cdot \left(4 \cdot t\_0 - 2\right)\right)\\
\mathbf{elif}\;x1 \leq 4 \cdot 10^{-195}:\\
\;\;\;\;x2 \cdot -6 - x1\\
\mathbf{elif}\;x1 \leq 8 \cdot 10^{+81}:\\
\;\;\;\;x1 + \left(3 \cdot \frac{\left(x1 \cdot \left(x1 \cdot 3\right) - 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1} + \left(x1 + 4 \cdot \left(x1 \cdot t\_0\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 + \left(x2 \cdot -6 + x1 \cdot \left(\left(x2 \cdot -12 + x1 \cdot \left(x1 \cdot 3 + 3 \cdot \left(3 - x2 \cdot -2\right)\right)\right) - 2\right)\right)\\
\end{array}
\end{array}
if x1 < -1.5499999999999999e96Initial program 5.3%
Taylor expanded in x1 around inf 5.3%
Taylor expanded in x1 around 0 5.3%
mul-1-neg5.3%
unsub-neg5.3%
*-commutative5.3%
Simplified5.3%
Taylor expanded in x1 around 0 67.1%
Taylor expanded in x2 around 0 95.4%
*-commutative95.4%
Simplified95.4%
if -1.5499999999999999e96 < x1 < -3.30000000000000021e-229Initial program 99.6%
Taylor expanded in x1 around 0 76.3%
Taylor expanded in x1 around 0 77.2%
if -3.30000000000000021e-229 < x1 < 4.0000000000000004e-195Initial program 99.7%
Taylor expanded in x1 around inf 99.7%
Taylor expanded in x1 around 0 99.7%
mul-1-neg99.7%
unsub-neg99.7%
*-commutative99.7%
Simplified99.7%
Taylor expanded in x1 around inf 92.3%
associate-*r/92.3%
metadata-eval92.3%
Simplified92.3%
Taylor expanded in x1 around 0 92.5%
if 4.0000000000000004e-195 < x1 < 7.99999999999999937e81Initial program 99.0%
Taylor expanded in x1 around 0 75.5%
if 7.99999999999999937e81 < x1 Initial program 33.3%
Taylor expanded in x1 around 0 11.4%
Taylor expanded in x2 around 0 6.0%
associate-*r*6.0%
*-commutative6.0%
Simplified6.0%
Taylor expanded in x1 around 0 82.7%
Final simplification83.6%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (- 3.0 (* x2 -2.0))) (t_1 (* 4.0 (* x2 (- (* 2.0 x2) 3.0)))))
(if (<= x1 -1.9e+97)
(+
x1
(+ (+ x1 (* x1 (* x1 (+ 9.0 (* x1 -19.0))))) (* 3.0 (- (* x2 -2.0) x1))))
(if (<= x1 -2.05e-231)
(+ x1 (+ (* x2 -6.0) (* x1 (- t_1 2.0))))
(if (<= x1 4.4e-195)
(- (* x2 -6.0) x1)
(if (<= x1 70000.0)
(+ x1 (+ (* x2 -6.0) (* x1 (- (+ t_1 (* 3.0 (* x1 t_0))) 2.0))))
(+
x1
(+
(* x2 -6.0)
(*
x1
(-
(+ (* x2 -12.0) (* x1 (+ (* x1 3.0) (* 3.0 t_0))))
2.0))))))))))
double code(double x1, double x2) {
double t_0 = 3.0 - (x2 * -2.0);
double t_1 = 4.0 * (x2 * ((2.0 * x2) - 3.0));
double tmp;
if (x1 <= -1.9e+97) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1)));
} else if (x1 <= -2.05e-231) {
tmp = x1 + ((x2 * -6.0) + (x1 * (t_1 - 2.0)));
} else if (x1 <= 4.4e-195) {
tmp = (x2 * -6.0) - x1;
} else if (x1 <= 70000.0) {
tmp = x1 + ((x2 * -6.0) + (x1 * ((t_1 + (3.0 * (x1 * t_0))) - 2.0)));
} else {
tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * t_0)))) - 2.0)));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = 3.0d0 - (x2 * (-2.0d0))
t_1 = 4.0d0 * (x2 * ((2.0d0 * x2) - 3.0d0))
if (x1 <= (-1.9d+97)) then
tmp = x1 + ((x1 + (x1 * (x1 * (9.0d0 + (x1 * (-19.0d0)))))) + (3.0d0 * ((x2 * (-2.0d0)) - x1)))
else if (x1 <= (-2.05d-231)) then
tmp = x1 + ((x2 * (-6.0d0)) + (x1 * (t_1 - 2.0d0)))
else if (x1 <= 4.4d-195) then
tmp = (x2 * (-6.0d0)) - x1
else if (x1 <= 70000.0d0) then
tmp = x1 + ((x2 * (-6.0d0)) + (x1 * ((t_1 + (3.0d0 * (x1 * t_0))) - 2.0d0)))
else
tmp = x1 + ((x2 * (-6.0d0)) + (x1 * (((x2 * (-12.0d0)) + (x1 * ((x1 * 3.0d0) + (3.0d0 * t_0)))) - 2.0d0)))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = 3.0 - (x2 * -2.0);
double t_1 = 4.0 * (x2 * ((2.0 * x2) - 3.0));
double tmp;
if (x1 <= -1.9e+97) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1)));
} else if (x1 <= -2.05e-231) {
tmp = x1 + ((x2 * -6.0) + (x1 * (t_1 - 2.0)));
} else if (x1 <= 4.4e-195) {
tmp = (x2 * -6.0) - x1;
} else if (x1 <= 70000.0) {
tmp = x1 + ((x2 * -6.0) + (x1 * ((t_1 + (3.0 * (x1 * t_0))) - 2.0)));
} else {
tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * t_0)))) - 2.0)));
}
return tmp;
}
def code(x1, x2): t_0 = 3.0 - (x2 * -2.0) t_1 = 4.0 * (x2 * ((2.0 * x2) - 3.0)) tmp = 0 if x1 <= -1.9e+97: tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1))) elif x1 <= -2.05e-231: tmp = x1 + ((x2 * -6.0) + (x1 * (t_1 - 2.0))) elif x1 <= 4.4e-195: tmp = (x2 * -6.0) - x1 elif x1 <= 70000.0: tmp = x1 + ((x2 * -6.0) + (x1 * ((t_1 + (3.0 * (x1 * t_0))) - 2.0))) else: tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * t_0)))) - 2.0))) return tmp
function code(x1, x2) t_0 = Float64(3.0 - Float64(x2 * -2.0)) t_1 = Float64(4.0 * Float64(x2 * Float64(Float64(2.0 * x2) - 3.0))) tmp = 0.0 if (x1 <= -1.9e+97) tmp = Float64(x1 + Float64(Float64(x1 + Float64(x1 * Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))) + Float64(3.0 * Float64(Float64(x2 * -2.0) - x1)))); elseif (x1 <= -2.05e-231) tmp = Float64(x1 + Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(t_1 - 2.0)))); elseif (x1 <= 4.4e-195) tmp = Float64(Float64(x2 * -6.0) - x1); elseif (x1 <= 70000.0) tmp = Float64(x1 + Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(Float64(t_1 + Float64(3.0 * Float64(x1 * t_0))) - 2.0)))); else tmp = Float64(x1 + Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(Float64(Float64(x2 * -12.0) + Float64(x1 * Float64(Float64(x1 * 3.0) + Float64(3.0 * t_0)))) - 2.0)))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = 3.0 - (x2 * -2.0); t_1 = 4.0 * (x2 * ((2.0 * x2) - 3.0)); tmp = 0.0; if (x1 <= -1.9e+97) tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1))); elseif (x1 <= -2.05e-231) tmp = x1 + ((x2 * -6.0) + (x1 * (t_1 - 2.0))); elseif (x1 <= 4.4e-195) tmp = (x2 * -6.0) - x1; elseif (x1 <= 70000.0) tmp = x1 + ((x2 * -6.0) + (x1 * ((t_1 + (3.0 * (x1 * t_0))) - 2.0))); else tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * t_0)))) - 2.0))); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(3.0 - N[(x2 * -2.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(4.0 * N[(x2 * N[(N[(2.0 * x2), $MachinePrecision] - 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -1.9e+97], N[(x1 + N[(N[(x1 + N[(x1 * N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] - x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -2.05e-231], N[(x1 + N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(t$95$1 - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 4.4e-195], N[(N[(x2 * -6.0), $MachinePrecision] - x1), $MachinePrecision], If[LessEqual[x1, 70000.0], N[(x1 + N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(N[(t$95$1 + N[(3.0 * N[(x1 * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 + N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(N[(N[(x2 * -12.0), $MachinePrecision] + N[(x1 * N[(N[(x1 * 3.0), $MachinePrecision] + N[(3.0 * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 3 - x2 \cdot -2\\
t_1 := 4 \cdot \left(x2 \cdot \left(2 \cdot x2 - 3\right)\right)\\
\mathbf{if}\;x1 \leq -1.9 \cdot 10^{+97}:\\
\;\;\;\;x1 + \left(\left(x1 + x1 \cdot \left(x1 \cdot \left(9 + x1 \cdot -19\right)\right)\right) + 3 \cdot \left(x2 \cdot -2 - x1\right)\right)\\
\mathbf{elif}\;x1 \leq -2.05 \cdot 10^{-231}:\\
\;\;\;\;x1 + \left(x2 \cdot -6 + x1 \cdot \left(t\_1 - 2\right)\right)\\
\mathbf{elif}\;x1 \leq 4.4 \cdot 10^{-195}:\\
\;\;\;\;x2 \cdot -6 - x1\\
\mathbf{elif}\;x1 \leq 70000:\\
\;\;\;\;x1 + \left(x2 \cdot -6 + x1 \cdot \left(\left(t\_1 + 3 \cdot \left(x1 \cdot t\_0\right)\right) - 2\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 + \left(x2 \cdot -6 + x1 \cdot \left(\left(x2 \cdot -12 + x1 \cdot \left(x1 \cdot 3 + 3 \cdot t\_0\right)\right) - 2\right)\right)\\
\end{array}
\end{array}
if x1 < -1.90000000000000018e97Initial program 5.3%
Taylor expanded in x1 around inf 5.3%
Taylor expanded in x1 around 0 5.3%
mul-1-neg5.3%
unsub-neg5.3%
*-commutative5.3%
Simplified5.3%
Taylor expanded in x1 around 0 67.1%
Taylor expanded in x2 around 0 95.4%
*-commutative95.4%
Simplified95.4%
if -1.90000000000000018e97 < x1 < -2.0500000000000001e-231Initial program 99.6%
Taylor expanded in x1 around 0 76.3%
Taylor expanded in x1 around 0 77.2%
if -2.0500000000000001e-231 < x1 < 4.40000000000000011e-195Initial program 99.7%
Taylor expanded in x1 around inf 99.7%
Taylor expanded in x1 around 0 99.7%
mul-1-neg99.7%
unsub-neg99.7%
*-commutative99.7%
Simplified99.7%
Taylor expanded in x1 around inf 92.3%
associate-*r/92.3%
metadata-eval92.3%
Simplified92.3%
Taylor expanded in x1 around 0 92.5%
if 4.40000000000000011e-195 < x1 < 7e4Initial program 99.0%
Taylor expanded in x1 around 0 89.0%
Taylor expanded in x1 around 0 89.8%
if 7e4 < x1 Initial program 50.7%
Taylor expanded in x1 around 0 15.4%
Taylor expanded in x2 around 0 7.3%
associate-*r*7.3%
*-commutative7.3%
Simplified7.3%
Taylor expanded in x1 around 0 66.4%
Final simplification83.5%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0
(+
x1
(+ (* x2 -6.0) (* x1 (- (* 4.0 (* x2 (- (* 2.0 x2) 3.0))) 2.0))))))
(if (<= x1 -2.3e+97)
(+
x1
(+ (+ x1 (* x1 (* x1 (+ 9.0 (* x1 -19.0))))) (* 3.0 (- (* x2 -2.0) x1))))
(if (<= x1 -4.6e-241)
t_0
(if (<= x1 6.6e-195)
(- (* x2 -6.0) x1)
(if (<= x1 1.15e+82)
t_0
(+
x1
(+
(* x2 -6.0)
(*
x1
(-
(+
(* x2 -12.0)
(* x1 (+ (* x1 3.0) (* 3.0 (- 3.0 (* x2 -2.0))))))
2.0))))))))))
double code(double x1, double x2) {
double t_0 = x1 + ((x2 * -6.0) + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) - 2.0)));
double tmp;
if (x1 <= -2.3e+97) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1)));
} else if (x1 <= -4.6e-241) {
tmp = t_0;
} else if (x1 <= 6.6e-195) {
tmp = (x2 * -6.0) - x1;
} else if (x1 <= 1.15e+82) {
tmp = t_0;
} else {
tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0)));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: tmp
t_0 = x1 + ((x2 * (-6.0d0)) + (x1 * ((4.0d0 * (x2 * ((2.0d0 * x2) - 3.0d0))) - 2.0d0)))
if (x1 <= (-2.3d+97)) then
tmp = x1 + ((x1 + (x1 * (x1 * (9.0d0 + (x1 * (-19.0d0)))))) + (3.0d0 * ((x2 * (-2.0d0)) - x1)))
else if (x1 <= (-4.6d-241)) then
tmp = t_0
else if (x1 <= 6.6d-195) then
tmp = (x2 * (-6.0d0)) - x1
else if (x1 <= 1.15d+82) then
tmp = t_0
else
tmp = x1 + ((x2 * (-6.0d0)) + (x1 * (((x2 * (-12.0d0)) + (x1 * ((x1 * 3.0d0) + (3.0d0 * (3.0d0 - (x2 * (-2.0d0))))))) - 2.0d0)))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = x1 + ((x2 * -6.0) + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) - 2.0)));
double tmp;
if (x1 <= -2.3e+97) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1)));
} else if (x1 <= -4.6e-241) {
tmp = t_0;
} else if (x1 <= 6.6e-195) {
tmp = (x2 * -6.0) - x1;
} else if (x1 <= 1.15e+82) {
tmp = t_0;
} else {
tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0)));
}
return tmp;
}
def code(x1, x2): t_0 = x1 + ((x2 * -6.0) + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) - 2.0))) tmp = 0 if x1 <= -2.3e+97: tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1))) elif x1 <= -4.6e-241: tmp = t_0 elif x1 <= 6.6e-195: tmp = (x2 * -6.0) - x1 elif x1 <= 1.15e+82: tmp = t_0 else: tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0))) return tmp
function code(x1, x2) t_0 = Float64(x1 + Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(Float64(4.0 * Float64(x2 * Float64(Float64(2.0 * x2) - 3.0))) - 2.0)))) tmp = 0.0 if (x1 <= -2.3e+97) tmp = Float64(x1 + Float64(Float64(x1 + Float64(x1 * Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))) + Float64(3.0 * Float64(Float64(x2 * -2.0) - x1)))); elseif (x1 <= -4.6e-241) tmp = t_0; elseif (x1 <= 6.6e-195) tmp = Float64(Float64(x2 * -6.0) - x1); elseif (x1 <= 1.15e+82) tmp = t_0; else tmp = Float64(x1 + Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(Float64(Float64(x2 * -12.0) + Float64(x1 * Float64(Float64(x1 * 3.0) + Float64(3.0 * Float64(3.0 - Float64(x2 * -2.0)))))) - 2.0)))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = x1 + ((x2 * -6.0) + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) - 2.0))); tmp = 0.0; if (x1 <= -2.3e+97) tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1))); elseif (x1 <= -4.6e-241) tmp = t_0; elseif (x1 <= 6.6e-195) tmp = (x2 * -6.0) - x1; elseif (x1 <= 1.15e+82) tmp = t_0; else tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0))); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(x1 + N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(N[(4.0 * N[(x2 * N[(N[(2.0 * x2), $MachinePrecision] - 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -2.3e+97], N[(x1 + N[(N[(x1 + N[(x1 * N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] - x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -4.6e-241], t$95$0, If[LessEqual[x1, 6.6e-195], N[(N[(x2 * -6.0), $MachinePrecision] - x1), $MachinePrecision], If[LessEqual[x1, 1.15e+82], t$95$0, N[(x1 + N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(N[(N[(x2 * -12.0), $MachinePrecision] + N[(x1 * N[(N[(x1 * 3.0), $MachinePrecision] + N[(3.0 * N[(3.0 - N[(x2 * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 + \left(x2 \cdot -6 + x1 \cdot \left(4 \cdot \left(x2 \cdot \left(2 \cdot x2 - 3\right)\right) - 2\right)\right)\\
\mathbf{if}\;x1 \leq -2.3 \cdot 10^{+97}:\\
\;\;\;\;x1 + \left(\left(x1 + x1 \cdot \left(x1 \cdot \left(9 + x1 \cdot -19\right)\right)\right) + 3 \cdot \left(x2 \cdot -2 - x1\right)\right)\\
\mathbf{elif}\;x1 \leq -4.6 \cdot 10^{-241}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;x1 \leq 6.6 \cdot 10^{-195}:\\
\;\;\;\;x2 \cdot -6 - x1\\
\mathbf{elif}\;x1 \leq 1.15 \cdot 10^{+82}:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;x1 + \left(x2 \cdot -6 + x1 \cdot \left(\left(x2 \cdot -12 + x1 \cdot \left(x1 \cdot 3 + 3 \cdot \left(3 - x2 \cdot -2\right)\right)\right) - 2\right)\right)\\
\end{array}
\end{array}
if x1 < -2.30000000000000006e97Initial program 5.3%
Taylor expanded in x1 around inf 5.3%
Taylor expanded in x1 around 0 5.3%
mul-1-neg5.3%
unsub-neg5.3%
*-commutative5.3%
Simplified5.3%
Taylor expanded in x1 around 0 67.1%
Taylor expanded in x2 around 0 95.4%
*-commutative95.4%
Simplified95.4%
if -2.30000000000000006e97 < x1 < -4.5999999999999999e-241 or 6.6e-195 < x1 < 1.14999999999999994e82Initial program 99.3%
Taylor expanded in x1 around 0 75.9%
Taylor expanded in x1 around 0 76.0%
if -4.5999999999999999e-241 < x1 < 6.6e-195Initial program 99.7%
Taylor expanded in x1 around inf 99.7%
Taylor expanded in x1 around 0 99.7%
mul-1-neg99.7%
unsub-neg99.7%
*-commutative99.7%
Simplified99.7%
Taylor expanded in x1 around inf 92.3%
associate-*r/92.3%
metadata-eval92.3%
Simplified92.3%
Taylor expanded in x1 around 0 92.5%
if 1.14999999999999994e82 < x1 Initial program 33.3%
Taylor expanded in x1 around 0 11.4%
Taylor expanded in x2 around 0 6.0%
associate-*r*6.0%
*-commutative6.0%
Simplified6.0%
Taylor expanded in x1 around 0 82.7%
Final simplification83.5%
(FPCore (x1 x2)
:precision binary64
(if (<= x1 -5.4e+95)
(+
x1
(+ (+ x1 (* x1 (* x1 (+ 9.0 (* x1 -19.0))))) (* 3.0 (- (* x2 -2.0) x1))))
(if (<= x1 2.15e+82)
(+
x1
(+
(* 3.0 (/ (- (- (* x1 (* x1 3.0)) (* 2.0 x2)) x1) (+ (* x1 x1) 1.0)))
(+ x1 (* 4.0 (* x2 (+ (* x1 -3.0) (* 2.0 (* x1 x2))))))))
(+
x1
(+
(* x2 -6.0)
(*
x1
(-
(+ (* x2 -12.0) (* x1 (+ (* x1 3.0) (* 3.0 (- 3.0 (* x2 -2.0))))))
2.0)))))))
double code(double x1, double x2) {
double tmp;
if (x1 <= -5.4e+95) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1)));
} else if (x1 <= 2.15e+82) {
tmp = x1 + ((3.0 * ((((x1 * (x1 * 3.0)) - (2.0 * x2)) - x1) / ((x1 * x1) + 1.0))) + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2)))))));
} else {
tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0)));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: tmp
if (x1 <= (-5.4d+95)) then
tmp = x1 + ((x1 + (x1 * (x1 * (9.0d0 + (x1 * (-19.0d0)))))) + (3.0d0 * ((x2 * (-2.0d0)) - x1)))
else if (x1 <= 2.15d+82) then
tmp = x1 + ((3.0d0 * ((((x1 * (x1 * 3.0d0)) - (2.0d0 * x2)) - x1) / ((x1 * x1) + 1.0d0))) + (x1 + (4.0d0 * (x2 * ((x1 * (-3.0d0)) + (2.0d0 * (x1 * x2)))))))
else
tmp = x1 + ((x2 * (-6.0d0)) + (x1 * (((x2 * (-12.0d0)) + (x1 * ((x1 * 3.0d0) + (3.0d0 * (3.0d0 - (x2 * (-2.0d0))))))) - 2.0d0)))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double tmp;
if (x1 <= -5.4e+95) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1)));
} else if (x1 <= 2.15e+82) {
tmp = x1 + ((3.0 * ((((x1 * (x1 * 3.0)) - (2.0 * x2)) - x1) / ((x1 * x1) + 1.0))) + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2)))))));
} else {
tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0)));
}
return tmp;
}
def code(x1, x2): tmp = 0 if x1 <= -5.4e+95: tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1))) elif x1 <= 2.15e+82: tmp = x1 + ((3.0 * ((((x1 * (x1 * 3.0)) - (2.0 * x2)) - x1) / ((x1 * x1) + 1.0))) + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2))))))) else: tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0))) return tmp
function code(x1, x2) tmp = 0.0 if (x1 <= -5.4e+95) tmp = Float64(x1 + Float64(Float64(x1 + Float64(x1 * Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))) + Float64(3.0 * Float64(Float64(x2 * -2.0) - x1)))); elseif (x1 <= 2.15e+82) tmp = Float64(x1 + Float64(Float64(3.0 * Float64(Float64(Float64(Float64(x1 * Float64(x1 * 3.0)) - Float64(2.0 * x2)) - x1) / Float64(Float64(x1 * x1) + 1.0))) + Float64(x1 + Float64(4.0 * Float64(x2 * Float64(Float64(x1 * -3.0) + Float64(2.0 * Float64(x1 * x2)))))))); else tmp = Float64(x1 + Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(Float64(Float64(x2 * -12.0) + Float64(x1 * Float64(Float64(x1 * 3.0) + Float64(3.0 * Float64(3.0 - Float64(x2 * -2.0)))))) - 2.0)))); end return tmp end
function tmp_2 = code(x1, x2) tmp = 0.0; if (x1 <= -5.4e+95) tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1))); elseif (x1 <= 2.15e+82) tmp = x1 + ((3.0 * ((((x1 * (x1 * 3.0)) - (2.0 * x2)) - x1) / ((x1 * x1) + 1.0))) + (x1 + (4.0 * (x2 * ((x1 * -3.0) + (2.0 * (x1 * x2))))))); else tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (x1 * ((x1 * 3.0) + (3.0 * (3.0 - (x2 * -2.0)))))) - 2.0))); end tmp_2 = tmp; end
code[x1_, x2_] := If[LessEqual[x1, -5.4e+95], N[(x1 + N[(N[(x1 + N[(x1 * N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] - x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 2.15e+82], N[(x1 + N[(N[(3.0 * N[(N[(N[(N[(x1 * N[(x1 * 3.0), $MachinePrecision]), $MachinePrecision] - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / N[(N[(x1 * x1), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x1 + N[(4.0 * N[(x2 * N[(N[(x1 * -3.0), $MachinePrecision] + N[(2.0 * N[(x1 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 + N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(N[(N[(x2 * -12.0), $MachinePrecision] + N[(x1 * N[(N[(x1 * 3.0), $MachinePrecision] + N[(3.0 * N[(3.0 - N[(x2 * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x1 \leq -5.4 \cdot 10^{+95}:\\
\;\;\;\;x1 + \left(\left(x1 + x1 \cdot \left(x1 \cdot \left(9 + x1 \cdot -19\right)\right)\right) + 3 \cdot \left(x2 \cdot -2 - x1\right)\right)\\
\mathbf{elif}\;x1 \leq 2.15 \cdot 10^{+82}:\\
\;\;\;\;x1 + \left(3 \cdot \frac{\left(x1 \cdot \left(x1 \cdot 3\right) - 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1} + \left(x1 + 4 \cdot \left(x2 \cdot \left(x1 \cdot -3 + 2 \cdot \left(x1 \cdot x2\right)\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 + \left(x2 \cdot -6 + x1 \cdot \left(\left(x2 \cdot -12 + x1 \cdot \left(x1 \cdot 3 + 3 \cdot \left(3 - x2 \cdot -2\right)\right)\right) - 2\right)\right)\\
\end{array}
\end{array}
if x1 < -5.4e95Initial program 5.3%
Taylor expanded in x1 around inf 5.3%
Taylor expanded in x1 around 0 5.3%
mul-1-neg5.3%
unsub-neg5.3%
*-commutative5.3%
Simplified5.3%
Taylor expanded in x1 around 0 67.1%
Taylor expanded in x2 around 0 95.4%
*-commutative95.4%
Simplified95.4%
if -5.4e95 < x1 < 2.15000000000000007e82Initial program 99.4%
Taylor expanded in x1 around 0 76.6%
Taylor expanded in x2 around 0 85.9%
if 2.15000000000000007e82 < x1 Initial program 33.3%
Taylor expanded in x1 around 0 11.4%
Taylor expanded in x2 around 0 6.0%
associate-*r*6.0%
*-commutative6.0%
Simplified6.0%
Taylor expanded in x1 around 0 82.7%
Final simplification87.6%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0
(+
x1
(+ (* x2 -6.0) (* x1 (- (* 4.0 (* x2 (- (* 2.0 x2) 3.0))) 2.0))))))
(if (<= x1 -2.3e+97)
(+
x1
(+ (+ x1 (* x1 (* x1 (+ 9.0 (* x1 -19.0))))) (* 3.0 (- (* x2 -2.0) x1))))
(if (<= x1 -9.5e-246)
t_0
(if (<= x1 4e-195)
(- (* x2 -6.0) x1)
(if (<= x1 6.6e+138)
t_0
(+
x1
(+
(* x2 -6.0)
(*
x1
(-
(+ (* x2 -12.0) (* 3.0 (* x1 (- 3.0 (* x2 -2.0)))))
2.0))))))))))
double code(double x1, double x2) {
double t_0 = x1 + ((x2 * -6.0) + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) - 2.0)));
double tmp;
if (x1 <= -2.3e+97) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1)));
} else if (x1 <= -9.5e-246) {
tmp = t_0;
} else if (x1 <= 4e-195) {
tmp = (x2 * -6.0) - x1;
} else if (x1 <= 6.6e+138) {
tmp = t_0;
} else {
tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (3.0 * (x1 * (3.0 - (x2 * -2.0))))) - 2.0)));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: tmp
t_0 = x1 + ((x2 * (-6.0d0)) + (x1 * ((4.0d0 * (x2 * ((2.0d0 * x2) - 3.0d0))) - 2.0d0)))
if (x1 <= (-2.3d+97)) then
tmp = x1 + ((x1 + (x1 * (x1 * (9.0d0 + (x1 * (-19.0d0)))))) + (3.0d0 * ((x2 * (-2.0d0)) - x1)))
else if (x1 <= (-9.5d-246)) then
tmp = t_0
else if (x1 <= 4d-195) then
tmp = (x2 * (-6.0d0)) - x1
else if (x1 <= 6.6d+138) then
tmp = t_0
else
tmp = x1 + ((x2 * (-6.0d0)) + (x1 * (((x2 * (-12.0d0)) + (3.0d0 * (x1 * (3.0d0 - (x2 * (-2.0d0)))))) - 2.0d0)))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = x1 + ((x2 * -6.0) + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) - 2.0)));
double tmp;
if (x1 <= -2.3e+97) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1)));
} else if (x1 <= -9.5e-246) {
tmp = t_0;
} else if (x1 <= 4e-195) {
tmp = (x2 * -6.0) - x1;
} else if (x1 <= 6.6e+138) {
tmp = t_0;
} else {
tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (3.0 * (x1 * (3.0 - (x2 * -2.0))))) - 2.0)));
}
return tmp;
}
def code(x1, x2): t_0 = x1 + ((x2 * -6.0) + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) - 2.0))) tmp = 0 if x1 <= -2.3e+97: tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1))) elif x1 <= -9.5e-246: tmp = t_0 elif x1 <= 4e-195: tmp = (x2 * -6.0) - x1 elif x1 <= 6.6e+138: tmp = t_0 else: tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (3.0 * (x1 * (3.0 - (x2 * -2.0))))) - 2.0))) return tmp
function code(x1, x2) t_0 = Float64(x1 + Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(Float64(4.0 * Float64(x2 * Float64(Float64(2.0 * x2) - 3.0))) - 2.0)))) tmp = 0.0 if (x1 <= -2.3e+97) tmp = Float64(x1 + Float64(Float64(x1 + Float64(x1 * Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))) + Float64(3.0 * Float64(Float64(x2 * -2.0) - x1)))); elseif (x1 <= -9.5e-246) tmp = t_0; elseif (x1 <= 4e-195) tmp = Float64(Float64(x2 * -6.0) - x1); elseif (x1 <= 6.6e+138) tmp = t_0; else tmp = Float64(x1 + Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(Float64(Float64(x2 * -12.0) + Float64(3.0 * Float64(x1 * Float64(3.0 - Float64(x2 * -2.0))))) - 2.0)))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = x1 + ((x2 * -6.0) + (x1 * ((4.0 * (x2 * ((2.0 * x2) - 3.0))) - 2.0))); tmp = 0.0; if (x1 <= -2.3e+97) tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1))); elseif (x1 <= -9.5e-246) tmp = t_0; elseif (x1 <= 4e-195) tmp = (x2 * -6.0) - x1; elseif (x1 <= 6.6e+138) tmp = t_0; else tmp = x1 + ((x2 * -6.0) + (x1 * (((x2 * -12.0) + (3.0 * (x1 * (3.0 - (x2 * -2.0))))) - 2.0))); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(x1 + N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(N[(4.0 * N[(x2 * N[(N[(2.0 * x2), $MachinePrecision] - 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -2.3e+97], N[(x1 + N[(N[(x1 + N[(x1 * N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] - x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -9.5e-246], t$95$0, If[LessEqual[x1, 4e-195], N[(N[(x2 * -6.0), $MachinePrecision] - x1), $MachinePrecision], If[LessEqual[x1, 6.6e+138], t$95$0, N[(x1 + N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(N[(N[(x2 * -12.0), $MachinePrecision] + N[(3.0 * N[(x1 * N[(3.0 - N[(x2 * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 + \left(x2 \cdot -6 + x1 \cdot \left(4 \cdot \left(x2 \cdot \left(2 \cdot x2 - 3\right)\right) - 2\right)\right)\\
\mathbf{if}\;x1 \leq -2.3 \cdot 10^{+97}:\\
\;\;\;\;x1 + \left(\left(x1 + x1 \cdot \left(x1 \cdot \left(9 + x1 \cdot -19\right)\right)\right) + 3 \cdot \left(x2 \cdot -2 - x1\right)\right)\\
\mathbf{elif}\;x1 \leq -9.5 \cdot 10^{-246}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;x1 \leq 4 \cdot 10^{-195}:\\
\;\;\;\;x2 \cdot -6 - x1\\
\mathbf{elif}\;x1 \leq 6.6 \cdot 10^{+138}:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;x1 + \left(x2 \cdot -6 + x1 \cdot \left(\left(x2 \cdot -12 + 3 \cdot \left(x1 \cdot \left(3 - x2 \cdot -2\right)\right)\right) - 2\right)\right)\\
\end{array}
\end{array}
if x1 < -2.30000000000000006e97Initial program 5.3%
Taylor expanded in x1 around inf 5.3%
Taylor expanded in x1 around 0 5.3%
mul-1-neg5.3%
unsub-neg5.3%
*-commutative5.3%
Simplified5.3%
Taylor expanded in x1 around 0 67.1%
Taylor expanded in x2 around 0 95.4%
*-commutative95.4%
Simplified95.4%
if -2.30000000000000006e97 < x1 < -9.5000000000000002e-246 or 4.0000000000000004e-195 < x1 < 6.59999999999999956e138Initial program 99.3%
Taylor expanded in x1 around 0 73.3%
Taylor expanded in x1 around 0 73.3%
if -9.5000000000000002e-246 < x1 < 4.0000000000000004e-195Initial program 99.7%
Taylor expanded in x1 around inf 99.7%
Taylor expanded in x1 around 0 99.7%
mul-1-neg99.7%
unsub-neg99.7%
*-commutative99.7%
Simplified99.7%
Taylor expanded in x1 around inf 92.3%
associate-*r/92.3%
metadata-eval92.3%
Simplified92.3%
Taylor expanded in x1 around 0 92.5%
if 6.59999999999999956e138 < x1 Initial program 13.3%
Taylor expanded in x1 around 0 3.8%
Taylor expanded in x2 around 0 0.5%
associate-*r*0.5%
*-commutative0.5%
Simplified0.5%
Taylor expanded in x1 around 0 77.6%
Final simplification81.2%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (* 4.0 (* x2 (- (* 2.0 x2) 3.0))))
(t_1 (+ x1 (+ (* x2 -6.0) (* x1 (- t_0 2.0))))))
(if (<= x1 -6.5e+96)
(+
x1
(+ (+ x1 (* x1 (* x1 (+ 9.0 (* x1 -19.0))))) (* 3.0 (- (* x2 -2.0) x1))))
(if (<= x1 -3.3e-231)
t_1
(if (<= x1 1.25e-194)
(- (* x2 -6.0) x1)
(if (<= x1 1.8e+265)
t_1
(if (<= x1 1.2e+293)
(* x2 (- (/ x1 x2) 6.0))
(+ x1 (* x1 (+ 1.0 t_0))))))))))
double code(double x1, double x2) {
double t_0 = 4.0 * (x2 * ((2.0 * x2) - 3.0));
double t_1 = x1 + ((x2 * -6.0) + (x1 * (t_0 - 2.0)));
double tmp;
if (x1 <= -6.5e+96) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1)));
} else if (x1 <= -3.3e-231) {
tmp = t_1;
} else if (x1 <= 1.25e-194) {
tmp = (x2 * -6.0) - x1;
} else if (x1 <= 1.8e+265) {
tmp = t_1;
} else if (x1 <= 1.2e+293) {
tmp = x2 * ((x1 / x2) - 6.0);
} else {
tmp = x1 + (x1 * (1.0 + t_0));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = 4.0d0 * (x2 * ((2.0d0 * x2) - 3.0d0))
t_1 = x1 + ((x2 * (-6.0d0)) + (x1 * (t_0 - 2.0d0)))
if (x1 <= (-6.5d+96)) then
tmp = x1 + ((x1 + (x1 * (x1 * (9.0d0 + (x1 * (-19.0d0)))))) + (3.0d0 * ((x2 * (-2.0d0)) - x1)))
else if (x1 <= (-3.3d-231)) then
tmp = t_1
else if (x1 <= 1.25d-194) then
tmp = (x2 * (-6.0d0)) - x1
else if (x1 <= 1.8d+265) then
tmp = t_1
else if (x1 <= 1.2d+293) then
tmp = x2 * ((x1 / x2) - 6.0d0)
else
tmp = x1 + (x1 * (1.0d0 + t_0))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = 4.0 * (x2 * ((2.0 * x2) - 3.0));
double t_1 = x1 + ((x2 * -6.0) + (x1 * (t_0 - 2.0)));
double tmp;
if (x1 <= -6.5e+96) {
tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1)));
} else if (x1 <= -3.3e-231) {
tmp = t_1;
} else if (x1 <= 1.25e-194) {
tmp = (x2 * -6.0) - x1;
} else if (x1 <= 1.8e+265) {
tmp = t_1;
} else if (x1 <= 1.2e+293) {
tmp = x2 * ((x1 / x2) - 6.0);
} else {
tmp = x1 + (x1 * (1.0 + t_0));
}
return tmp;
}
def code(x1, x2): t_0 = 4.0 * (x2 * ((2.0 * x2) - 3.0)) t_1 = x1 + ((x2 * -6.0) + (x1 * (t_0 - 2.0))) tmp = 0 if x1 <= -6.5e+96: tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1))) elif x1 <= -3.3e-231: tmp = t_1 elif x1 <= 1.25e-194: tmp = (x2 * -6.0) - x1 elif x1 <= 1.8e+265: tmp = t_1 elif x1 <= 1.2e+293: tmp = x2 * ((x1 / x2) - 6.0) else: tmp = x1 + (x1 * (1.0 + t_0)) return tmp
function code(x1, x2) t_0 = Float64(4.0 * Float64(x2 * Float64(Float64(2.0 * x2) - 3.0))) t_1 = Float64(x1 + Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(t_0 - 2.0)))) tmp = 0.0 if (x1 <= -6.5e+96) tmp = Float64(x1 + Float64(Float64(x1 + Float64(x1 * Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))) + Float64(3.0 * Float64(Float64(x2 * -2.0) - x1)))); elseif (x1 <= -3.3e-231) tmp = t_1; elseif (x1 <= 1.25e-194) tmp = Float64(Float64(x2 * -6.0) - x1); elseif (x1 <= 1.8e+265) tmp = t_1; elseif (x1 <= 1.2e+293) tmp = Float64(x2 * Float64(Float64(x1 / x2) - 6.0)); else tmp = Float64(x1 + Float64(x1 * Float64(1.0 + t_0))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = 4.0 * (x2 * ((2.0 * x2) - 3.0)); t_1 = x1 + ((x2 * -6.0) + (x1 * (t_0 - 2.0))); tmp = 0.0; if (x1 <= -6.5e+96) tmp = x1 + ((x1 + (x1 * (x1 * (9.0 + (x1 * -19.0))))) + (3.0 * ((x2 * -2.0) - x1))); elseif (x1 <= -3.3e-231) tmp = t_1; elseif (x1 <= 1.25e-194) tmp = (x2 * -6.0) - x1; elseif (x1 <= 1.8e+265) tmp = t_1; elseif (x1 <= 1.2e+293) tmp = x2 * ((x1 / x2) - 6.0); else tmp = x1 + (x1 * (1.0 + t_0)); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(4.0 * N[(x2 * N[(N[(2.0 * x2), $MachinePrecision] - 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(x1 + N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(t$95$0 - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -6.5e+96], N[(x1 + N[(N[(x1 + N[(x1 * N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] - x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -3.3e-231], t$95$1, If[LessEqual[x1, 1.25e-194], N[(N[(x2 * -6.0), $MachinePrecision] - x1), $MachinePrecision], If[LessEqual[x1, 1.8e+265], t$95$1, If[LessEqual[x1, 1.2e+293], N[(x2 * N[(N[(x1 / x2), $MachinePrecision] - 6.0), $MachinePrecision]), $MachinePrecision], N[(x1 + N[(x1 * N[(1.0 + t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 4 \cdot \left(x2 \cdot \left(2 \cdot x2 - 3\right)\right)\\
t_1 := x1 + \left(x2 \cdot -6 + x1 \cdot \left(t\_0 - 2\right)\right)\\
\mathbf{if}\;x1 \leq -6.5 \cdot 10^{+96}:\\
\;\;\;\;x1 + \left(\left(x1 + x1 \cdot \left(x1 \cdot \left(9 + x1 \cdot -19\right)\right)\right) + 3 \cdot \left(x2 \cdot -2 - x1\right)\right)\\
\mathbf{elif}\;x1 \leq -3.3 \cdot 10^{-231}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x1 \leq 1.25 \cdot 10^{-194}:\\
\;\;\;\;x2 \cdot -6 - x1\\
\mathbf{elif}\;x1 \leq 1.8 \cdot 10^{+265}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x1 \leq 1.2 \cdot 10^{+293}:\\
\;\;\;\;x2 \cdot \left(\frac{x1}{x2} - 6\right)\\
\mathbf{else}:\\
\;\;\;\;x1 + x1 \cdot \left(1 + t\_0\right)\\
\end{array}
\end{array}
if x1 < -6.5e96Initial program 5.3%
Taylor expanded in x1 around inf 5.3%
Taylor expanded in x1 around 0 5.3%
mul-1-neg5.3%
unsub-neg5.3%
*-commutative5.3%
Simplified5.3%
Taylor expanded in x1 around 0 67.1%
Taylor expanded in x2 around 0 95.4%
*-commutative95.4%
Simplified95.4%
if -6.5e96 < x1 < -3.30000000000000028e-231 or 1.2500000000000001e-194 < x1 < 1.80000000000000001e265Initial program 90.3%
Taylor expanded in x1 around 0 65.5%
Taylor expanded in x1 around 0 71.2%
if -3.30000000000000028e-231 < x1 < 1.2500000000000001e-194Initial program 99.7%
Taylor expanded in x1 around inf 99.7%
Taylor expanded in x1 around 0 99.7%
mul-1-neg99.7%
unsub-neg99.7%
*-commutative99.7%
Simplified99.7%
Taylor expanded in x1 around inf 92.3%
associate-*r/92.3%
metadata-eval92.3%
Simplified92.3%
Taylor expanded in x1 around 0 92.5%
if 1.80000000000000001e265 < x1 < 1.20000000000000002e293Initial program 0.0%
Taylor expanded in x1 around 0 0.0%
Taylor expanded in x1 around 0 8.3%
*-commutative8.3%
Simplified8.3%
Taylor expanded in x2 around inf 72.5%
if 1.20000000000000002e293 < x1 Initial program 0.0%
Taylor expanded in x1 around 0 0.0%
Taylor expanded in x1 around inf 100.0%
Final simplification79.6%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (* 4.0 (* x2 (- (* 2.0 x2) 3.0))))
(t_1 (+ x1 (+ (* x2 -6.0) (* x1 (- t_0 2.0))))))
(if (<= x1 -5.1e+101)
(+
x1
(+ (+ x1 (* 4.0 (* x2 (* x1 -3.0)))) (* x2 (- (* -3.0 (/ x1 x2)) 6.0))))
(if (<= x1 -2.2e-235)
t_1
(if (<= x1 5.4e-195)
(- (* x2 -6.0) x1)
(if (<= x1 5.7e+265)
t_1
(if (<= x1 1.1e+291)
(* x2 (- (/ x1 x2) 6.0))
(+ x1 (* x1 (+ 1.0 t_0))))))))))
double code(double x1, double x2) {
double t_0 = 4.0 * (x2 * ((2.0 * x2) - 3.0));
double t_1 = x1 + ((x2 * -6.0) + (x1 * (t_0 - 2.0)));
double tmp;
if (x1 <= -5.1e+101) {
tmp = x1 + ((x1 + (4.0 * (x2 * (x1 * -3.0)))) + (x2 * ((-3.0 * (x1 / x2)) - 6.0)));
} else if (x1 <= -2.2e-235) {
tmp = t_1;
} else if (x1 <= 5.4e-195) {
tmp = (x2 * -6.0) - x1;
} else if (x1 <= 5.7e+265) {
tmp = t_1;
} else if (x1 <= 1.1e+291) {
tmp = x2 * ((x1 / x2) - 6.0);
} else {
tmp = x1 + (x1 * (1.0 + t_0));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = 4.0d0 * (x2 * ((2.0d0 * x2) - 3.0d0))
t_1 = x1 + ((x2 * (-6.0d0)) + (x1 * (t_0 - 2.0d0)))
if (x1 <= (-5.1d+101)) then
tmp = x1 + ((x1 + (4.0d0 * (x2 * (x1 * (-3.0d0))))) + (x2 * (((-3.0d0) * (x1 / x2)) - 6.0d0)))
else if (x1 <= (-2.2d-235)) then
tmp = t_1
else if (x1 <= 5.4d-195) then
tmp = (x2 * (-6.0d0)) - x1
else if (x1 <= 5.7d+265) then
tmp = t_1
else if (x1 <= 1.1d+291) then
tmp = x2 * ((x1 / x2) - 6.0d0)
else
tmp = x1 + (x1 * (1.0d0 + t_0))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = 4.0 * (x2 * ((2.0 * x2) - 3.0));
double t_1 = x1 + ((x2 * -6.0) + (x1 * (t_0 - 2.0)));
double tmp;
if (x1 <= -5.1e+101) {
tmp = x1 + ((x1 + (4.0 * (x2 * (x1 * -3.0)))) + (x2 * ((-3.0 * (x1 / x2)) - 6.0)));
} else if (x1 <= -2.2e-235) {
tmp = t_1;
} else if (x1 <= 5.4e-195) {
tmp = (x2 * -6.0) - x1;
} else if (x1 <= 5.7e+265) {
tmp = t_1;
} else if (x1 <= 1.1e+291) {
tmp = x2 * ((x1 / x2) - 6.0);
} else {
tmp = x1 + (x1 * (1.0 + t_0));
}
return tmp;
}
def code(x1, x2): t_0 = 4.0 * (x2 * ((2.0 * x2) - 3.0)) t_1 = x1 + ((x2 * -6.0) + (x1 * (t_0 - 2.0))) tmp = 0 if x1 <= -5.1e+101: tmp = x1 + ((x1 + (4.0 * (x2 * (x1 * -3.0)))) + (x2 * ((-3.0 * (x1 / x2)) - 6.0))) elif x1 <= -2.2e-235: tmp = t_1 elif x1 <= 5.4e-195: tmp = (x2 * -6.0) - x1 elif x1 <= 5.7e+265: tmp = t_1 elif x1 <= 1.1e+291: tmp = x2 * ((x1 / x2) - 6.0) else: tmp = x1 + (x1 * (1.0 + t_0)) return tmp
function code(x1, x2) t_0 = Float64(4.0 * Float64(x2 * Float64(Float64(2.0 * x2) - 3.0))) t_1 = Float64(x1 + Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(t_0 - 2.0)))) tmp = 0.0 if (x1 <= -5.1e+101) tmp = Float64(x1 + Float64(Float64(x1 + Float64(4.0 * Float64(x2 * Float64(x1 * -3.0)))) + Float64(x2 * Float64(Float64(-3.0 * Float64(x1 / x2)) - 6.0)))); elseif (x1 <= -2.2e-235) tmp = t_1; elseif (x1 <= 5.4e-195) tmp = Float64(Float64(x2 * -6.0) - x1); elseif (x1 <= 5.7e+265) tmp = t_1; elseif (x1 <= 1.1e+291) tmp = Float64(x2 * Float64(Float64(x1 / x2) - 6.0)); else tmp = Float64(x1 + Float64(x1 * Float64(1.0 + t_0))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = 4.0 * (x2 * ((2.0 * x2) - 3.0)); t_1 = x1 + ((x2 * -6.0) + (x1 * (t_0 - 2.0))); tmp = 0.0; if (x1 <= -5.1e+101) tmp = x1 + ((x1 + (4.0 * (x2 * (x1 * -3.0)))) + (x2 * ((-3.0 * (x1 / x2)) - 6.0))); elseif (x1 <= -2.2e-235) tmp = t_1; elseif (x1 <= 5.4e-195) tmp = (x2 * -6.0) - x1; elseif (x1 <= 5.7e+265) tmp = t_1; elseif (x1 <= 1.1e+291) tmp = x2 * ((x1 / x2) - 6.0); else tmp = x1 + (x1 * (1.0 + t_0)); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(4.0 * N[(x2 * N[(N[(2.0 * x2), $MachinePrecision] - 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(x1 + N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(t$95$0 - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -5.1e+101], N[(x1 + N[(N[(x1 + N[(4.0 * N[(x2 * N[(x1 * -3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x2 * N[(N[(-3.0 * N[(x1 / x2), $MachinePrecision]), $MachinePrecision] - 6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -2.2e-235], t$95$1, If[LessEqual[x1, 5.4e-195], N[(N[(x2 * -6.0), $MachinePrecision] - x1), $MachinePrecision], If[LessEqual[x1, 5.7e+265], t$95$1, If[LessEqual[x1, 1.1e+291], N[(x2 * N[(N[(x1 / x2), $MachinePrecision] - 6.0), $MachinePrecision]), $MachinePrecision], N[(x1 + N[(x1 * N[(1.0 + t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 4 \cdot \left(x2 \cdot \left(2 \cdot x2 - 3\right)\right)\\
t_1 := x1 + \left(x2 \cdot -6 + x1 \cdot \left(t\_0 - 2\right)\right)\\
\mathbf{if}\;x1 \leq -5.1 \cdot 10^{+101}:\\
\;\;\;\;x1 + \left(\left(x1 + 4 \cdot \left(x2 \cdot \left(x1 \cdot -3\right)\right)\right) + x2 \cdot \left(-3 \cdot \frac{x1}{x2} - 6\right)\right)\\
\mathbf{elif}\;x1 \leq -2.2 \cdot 10^{-235}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x1 \leq 5.4 \cdot 10^{-195}:\\
\;\;\;\;x2 \cdot -6 - x1\\
\mathbf{elif}\;x1 \leq 5.7 \cdot 10^{+265}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x1 \leq 1.1 \cdot 10^{+291}:\\
\;\;\;\;x2 \cdot \left(\frac{x1}{x2} - 6\right)\\
\mathbf{else}:\\
\;\;\;\;x1 + x1 \cdot \left(1 + t\_0\right)\\
\end{array}
\end{array}
if x1 < -5.09999999999999995e101Initial program 1.8%
Taylor expanded in x1 around 0 0.0%
Taylor expanded in x2 around 0 5.7%
associate-*r*5.7%
*-commutative5.7%
Simplified5.7%
Taylor expanded in x1 around 0 25.1%
mul-1-neg1.8%
unsub-neg1.8%
*-commutative1.8%
Simplified25.1%
Taylor expanded in x2 around inf 57.1%
if -5.09999999999999995e101 < x1 < -2.19999999999999984e-235 or 5.4e-195 < x1 < 5.6999999999999999e265Initial program 90.4%
Taylor expanded in x1 around 0 64.7%
Taylor expanded in x1 around 0 70.4%
if -2.19999999999999984e-235 < x1 < 5.4e-195Initial program 99.7%
Taylor expanded in x1 around inf 99.7%
Taylor expanded in x1 around 0 99.7%
mul-1-neg99.7%
unsub-neg99.7%
*-commutative99.7%
Simplified99.7%
Taylor expanded in x1 around inf 92.3%
associate-*r/92.3%
metadata-eval92.3%
Simplified92.3%
Taylor expanded in x1 around 0 92.5%
if 5.6999999999999999e265 < x1 < 1.1e291Initial program 0.0%
Taylor expanded in x1 around 0 0.0%
Taylor expanded in x1 around 0 8.3%
*-commutative8.3%
Simplified8.3%
Taylor expanded in x2 around inf 72.5%
if 1.1e291 < x1 Initial program 0.0%
Taylor expanded in x1 around 0 0.0%
Taylor expanded in x1 around inf 100.0%
Final simplification70.7%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (* 4.0 (* x2 (- (* 2.0 x2) 3.0))))
(t_1 (+ x1 (+ (* x2 -6.0) (* x1 (- t_0 2.0))))))
(if (<= x1 -5.1e+101)
(+ x1 (* x1 (- (* x2 -12.0) 2.0)))
(if (<= x1 -7e-231)
t_1
(if (<= x1 6.6e-195)
(- (* x2 -6.0) x1)
(if (<= x1 5.4e+265)
t_1
(if (<= x1 2.3e+291)
(* x2 (- (/ x1 x2) 6.0))
(+ x1 (* x1 (+ 1.0 t_0))))))))))
double code(double x1, double x2) {
double t_0 = 4.0 * (x2 * ((2.0 * x2) - 3.0));
double t_1 = x1 + ((x2 * -6.0) + (x1 * (t_0 - 2.0)));
double tmp;
if (x1 <= -5.1e+101) {
tmp = x1 + (x1 * ((x2 * -12.0) - 2.0));
} else if (x1 <= -7e-231) {
tmp = t_1;
} else if (x1 <= 6.6e-195) {
tmp = (x2 * -6.0) - x1;
} else if (x1 <= 5.4e+265) {
tmp = t_1;
} else if (x1 <= 2.3e+291) {
tmp = x2 * ((x1 / x2) - 6.0);
} else {
tmp = x1 + (x1 * (1.0 + t_0));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = 4.0d0 * (x2 * ((2.0d0 * x2) - 3.0d0))
t_1 = x1 + ((x2 * (-6.0d0)) + (x1 * (t_0 - 2.0d0)))
if (x1 <= (-5.1d+101)) then
tmp = x1 + (x1 * ((x2 * (-12.0d0)) - 2.0d0))
else if (x1 <= (-7d-231)) then
tmp = t_1
else if (x1 <= 6.6d-195) then
tmp = (x2 * (-6.0d0)) - x1
else if (x1 <= 5.4d+265) then
tmp = t_1
else if (x1 <= 2.3d+291) then
tmp = x2 * ((x1 / x2) - 6.0d0)
else
tmp = x1 + (x1 * (1.0d0 + t_0))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = 4.0 * (x2 * ((2.0 * x2) - 3.0));
double t_1 = x1 + ((x2 * -6.0) + (x1 * (t_0 - 2.0)));
double tmp;
if (x1 <= -5.1e+101) {
tmp = x1 + (x1 * ((x2 * -12.0) - 2.0));
} else if (x1 <= -7e-231) {
tmp = t_1;
} else if (x1 <= 6.6e-195) {
tmp = (x2 * -6.0) - x1;
} else if (x1 <= 5.4e+265) {
tmp = t_1;
} else if (x1 <= 2.3e+291) {
tmp = x2 * ((x1 / x2) - 6.0);
} else {
tmp = x1 + (x1 * (1.0 + t_0));
}
return tmp;
}
def code(x1, x2): t_0 = 4.0 * (x2 * ((2.0 * x2) - 3.0)) t_1 = x1 + ((x2 * -6.0) + (x1 * (t_0 - 2.0))) tmp = 0 if x1 <= -5.1e+101: tmp = x1 + (x1 * ((x2 * -12.0) - 2.0)) elif x1 <= -7e-231: tmp = t_1 elif x1 <= 6.6e-195: tmp = (x2 * -6.0) - x1 elif x1 <= 5.4e+265: tmp = t_1 elif x1 <= 2.3e+291: tmp = x2 * ((x1 / x2) - 6.0) else: tmp = x1 + (x1 * (1.0 + t_0)) return tmp
function code(x1, x2) t_0 = Float64(4.0 * Float64(x2 * Float64(Float64(2.0 * x2) - 3.0))) t_1 = Float64(x1 + Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(t_0 - 2.0)))) tmp = 0.0 if (x1 <= -5.1e+101) tmp = Float64(x1 + Float64(x1 * Float64(Float64(x2 * -12.0) - 2.0))); elseif (x1 <= -7e-231) tmp = t_1; elseif (x1 <= 6.6e-195) tmp = Float64(Float64(x2 * -6.0) - x1); elseif (x1 <= 5.4e+265) tmp = t_1; elseif (x1 <= 2.3e+291) tmp = Float64(x2 * Float64(Float64(x1 / x2) - 6.0)); else tmp = Float64(x1 + Float64(x1 * Float64(1.0 + t_0))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = 4.0 * (x2 * ((2.0 * x2) - 3.0)); t_1 = x1 + ((x2 * -6.0) + (x1 * (t_0 - 2.0))); tmp = 0.0; if (x1 <= -5.1e+101) tmp = x1 + (x1 * ((x2 * -12.0) - 2.0)); elseif (x1 <= -7e-231) tmp = t_1; elseif (x1 <= 6.6e-195) tmp = (x2 * -6.0) - x1; elseif (x1 <= 5.4e+265) tmp = t_1; elseif (x1 <= 2.3e+291) tmp = x2 * ((x1 / x2) - 6.0); else tmp = x1 + (x1 * (1.0 + t_0)); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(4.0 * N[(x2 * N[(N[(2.0 * x2), $MachinePrecision] - 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(x1 + N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(t$95$0 - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -5.1e+101], N[(x1 + N[(x1 * N[(N[(x2 * -12.0), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -7e-231], t$95$1, If[LessEqual[x1, 6.6e-195], N[(N[(x2 * -6.0), $MachinePrecision] - x1), $MachinePrecision], If[LessEqual[x1, 5.4e+265], t$95$1, If[LessEqual[x1, 2.3e+291], N[(x2 * N[(N[(x1 / x2), $MachinePrecision] - 6.0), $MachinePrecision]), $MachinePrecision], N[(x1 + N[(x1 * N[(1.0 + t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 4 \cdot \left(x2 \cdot \left(2 \cdot x2 - 3\right)\right)\\
t_1 := x1 + \left(x2 \cdot -6 + x1 \cdot \left(t\_0 - 2\right)\right)\\
\mathbf{if}\;x1 \leq -5.1 \cdot 10^{+101}:\\
\;\;\;\;x1 + x1 \cdot \left(x2 \cdot -12 - 2\right)\\
\mathbf{elif}\;x1 \leq -7 \cdot 10^{-231}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x1 \leq 6.6 \cdot 10^{-195}:\\
\;\;\;\;x2 \cdot -6 - x1\\
\mathbf{elif}\;x1 \leq 5.4 \cdot 10^{+265}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x1 \leq 2.3 \cdot 10^{+291}:\\
\;\;\;\;x2 \cdot \left(\frac{x1}{x2} - 6\right)\\
\mathbf{else}:\\
\;\;\;\;x1 + x1 \cdot \left(1 + t\_0\right)\\
\end{array}
\end{array}
if x1 < -5.09999999999999995e101Initial program 1.8%
Taylor expanded in x1 around 0 0.0%
Taylor expanded in x2 around 0 5.7%
associate-*r*5.7%
*-commutative5.7%
Simplified5.7%
Taylor expanded in x1 around 0 25.1%
mul-1-neg1.8%
unsub-neg1.8%
*-commutative1.8%
Simplified25.1%
Taylor expanded in x1 around inf 25.1%
if -5.09999999999999995e101 < x1 < -7.0000000000000002e-231 or 6.6e-195 < x1 < 5.39999999999999968e265Initial program 90.4%
Taylor expanded in x1 around 0 64.7%
Taylor expanded in x1 around 0 70.4%
if -7.0000000000000002e-231 < x1 < 6.6e-195Initial program 99.7%
Taylor expanded in x1 around inf 99.7%
Taylor expanded in x1 around 0 99.7%
mul-1-neg99.7%
unsub-neg99.7%
*-commutative99.7%
Simplified99.7%
Taylor expanded in x1 around inf 92.3%
associate-*r/92.3%
metadata-eval92.3%
Simplified92.3%
Taylor expanded in x1 around 0 92.5%
if 5.39999999999999968e265 < x1 < 2.3e291Initial program 0.0%
Taylor expanded in x1 around 0 0.0%
Taylor expanded in x1 around 0 8.3%
*-commutative8.3%
Simplified8.3%
Taylor expanded in x2 around inf 72.5%
if 2.3e291 < x1 Initial program 0.0%
Taylor expanded in x1 around 0 0.0%
Taylor expanded in x1 around inf 100.0%
Final simplification63.8%
(FPCore (x1 x2)
:precision binary64
(if (<= x1 -5.1e+95)
(+ x1 (* x1 (- (* x2 -12.0) 2.0)))
(if (or (<= x1 -4.8e-38) (not (<= x1 2.2e-37)))
(+ x1 (* x1 (+ 1.0 (* 4.0 (* x2 (- (* 2.0 x2) 3.0))))))
(- (* x2 -6.0) x1))))
double code(double x1, double x2) {
double tmp;
if (x1 <= -5.1e+95) {
tmp = x1 + (x1 * ((x2 * -12.0) - 2.0));
} else if ((x1 <= -4.8e-38) || !(x1 <= 2.2e-37)) {
tmp = x1 + (x1 * (1.0 + (4.0 * (x2 * ((2.0 * x2) - 3.0)))));
} else {
tmp = (x2 * -6.0) - x1;
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: tmp
if (x1 <= (-5.1d+95)) then
tmp = x1 + (x1 * ((x2 * (-12.0d0)) - 2.0d0))
else if ((x1 <= (-4.8d-38)) .or. (.not. (x1 <= 2.2d-37))) then
tmp = x1 + (x1 * (1.0d0 + (4.0d0 * (x2 * ((2.0d0 * x2) - 3.0d0)))))
else
tmp = (x2 * (-6.0d0)) - x1
end if
code = tmp
end function
public static double code(double x1, double x2) {
double tmp;
if (x1 <= -5.1e+95) {
tmp = x1 + (x1 * ((x2 * -12.0) - 2.0));
} else if ((x1 <= -4.8e-38) || !(x1 <= 2.2e-37)) {
tmp = x1 + (x1 * (1.0 + (4.0 * (x2 * ((2.0 * x2) - 3.0)))));
} else {
tmp = (x2 * -6.0) - x1;
}
return tmp;
}
def code(x1, x2): tmp = 0 if x1 <= -5.1e+95: tmp = x1 + (x1 * ((x2 * -12.0) - 2.0)) elif (x1 <= -4.8e-38) or not (x1 <= 2.2e-37): tmp = x1 + (x1 * (1.0 + (4.0 * (x2 * ((2.0 * x2) - 3.0))))) else: tmp = (x2 * -6.0) - x1 return tmp
function code(x1, x2) tmp = 0.0 if (x1 <= -5.1e+95) tmp = Float64(x1 + Float64(x1 * Float64(Float64(x2 * -12.0) - 2.0))); elseif ((x1 <= -4.8e-38) || !(x1 <= 2.2e-37)) tmp = Float64(x1 + Float64(x1 * Float64(1.0 + Float64(4.0 * Float64(x2 * Float64(Float64(2.0 * x2) - 3.0)))))); else tmp = Float64(Float64(x2 * -6.0) - x1); end return tmp end
function tmp_2 = code(x1, x2) tmp = 0.0; if (x1 <= -5.1e+95) tmp = x1 + (x1 * ((x2 * -12.0) - 2.0)); elseif ((x1 <= -4.8e-38) || ~((x1 <= 2.2e-37))) tmp = x1 + (x1 * (1.0 + (4.0 * (x2 * ((2.0 * x2) - 3.0))))); else tmp = (x2 * -6.0) - x1; end tmp_2 = tmp; end
code[x1_, x2_] := If[LessEqual[x1, -5.1e+95], N[(x1 + N[(x1 * N[(N[(x2 * -12.0), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[x1, -4.8e-38], N[Not[LessEqual[x1, 2.2e-37]], $MachinePrecision]], N[(x1 + N[(x1 * N[(1.0 + N[(4.0 * N[(x2 * N[(N[(2.0 * x2), $MachinePrecision] - 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x2 * -6.0), $MachinePrecision] - x1), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x1 \leq -5.1 \cdot 10^{+95}:\\
\;\;\;\;x1 + x1 \cdot \left(x2 \cdot -12 - 2\right)\\
\mathbf{elif}\;x1 \leq -4.8 \cdot 10^{-38} \lor \neg \left(x1 \leq 2.2 \cdot 10^{-37}\right):\\
\;\;\;\;x1 + x1 \cdot \left(1 + 4 \cdot \left(x2 \cdot \left(2 \cdot x2 - 3\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x2 \cdot -6 - x1\\
\end{array}
\end{array}
if x1 < -5.10000000000000003e95Initial program 5.3%
Taylor expanded in x1 around 0 0.1%
Taylor expanded in x2 around 0 5.5%
associate-*r*5.5%
*-commutative5.5%
Simplified5.5%
Taylor expanded in x1 around 0 24.4%
mul-1-neg5.3%
unsub-neg5.3%
*-commutative5.3%
Simplified24.4%
Taylor expanded in x1 around inf 24.4%
if -5.10000000000000003e95 < x1 < -4.80000000000000044e-38 or 2.20000000000000002e-37 < x1 Initial program 70.5%
Taylor expanded in x1 around 0 36.8%
Taylor expanded in x1 around inf 44.2%
if -4.80000000000000044e-38 < x1 < 2.20000000000000002e-37Initial program 99.3%
Taylor expanded in x1 around inf 99.3%
Taylor expanded in x1 around 0 99.3%
mul-1-neg99.3%
unsub-neg99.3%
*-commutative99.3%
Simplified99.3%
Taylor expanded in x1 around inf 82.1%
associate-*r/82.1%
metadata-eval82.1%
Simplified82.1%
Taylor expanded in x1 around 0 82.7%
Final simplification56.3%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (+ x1 (* x1 -2.0))))
(if (<= x1 -5.4e-104)
t_0
(if (<= x1 1.8e-88)
(* x2 -6.0)
(if (<= x1 1.4) t_0 (* x2 (- (/ x1 x2) 6.0)))))))
double code(double x1, double x2) {
double t_0 = x1 + (x1 * -2.0);
double tmp;
if (x1 <= -5.4e-104) {
tmp = t_0;
} else if (x1 <= 1.8e-88) {
tmp = x2 * -6.0;
} else if (x1 <= 1.4) {
tmp = t_0;
} else {
tmp = x2 * ((x1 / x2) - 6.0);
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: t_0
real(8) :: tmp
t_0 = x1 + (x1 * (-2.0d0))
if (x1 <= (-5.4d-104)) then
tmp = t_0
else if (x1 <= 1.8d-88) then
tmp = x2 * (-6.0d0)
else if (x1 <= 1.4d0) then
tmp = t_0
else
tmp = x2 * ((x1 / x2) - 6.0d0)
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = x1 + (x1 * -2.0);
double tmp;
if (x1 <= -5.4e-104) {
tmp = t_0;
} else if (x1 <= 1.8e-88) {
tmp = x2 * -6.0;
} else if (x1 <= 1.4) {
tmp = t_0;
} else {
tmp = x2 * ((x1 / x2) - 6.0);
}
return tmp;
}
def code(x1, x2): t_0 = x1 + (x1 * -2.0) tmp = 0 if x1 <= -5.4e-104: tmp = t_0 elif x1 <= 1.8e-88: tmp = x2 * -6.0 elif x1 <= 1.4: tmp = t_0 else: tmp = x2 * ((x1 / x2) - 6.0) return tmp
function code(x1, x2) t_0 = Float64(x1 + Float64(x1 * -2.0)) tmp = 0.0 if (x1 <= -5.4e-104) tmp = t_0; elseif (x1 <= 1.8e-88) tmp = Float64(x2 * -6.0); elseif (x1 <= 1.4) tmp = t_0; else tmp = Float64(x2 * Float64(Float64(x1 / x2) - 6.0)); end return tmp end
function tmp_2 = code(x1, x2) t_0 = x1 + (x1 * -2.0); tmp = 0.0; if (x1 <= -5.4e-104) tmp = t_0; elseif (x1 <= 1.8e-88) tmp = x2 * -6.0; elseif (x1 <= 1.4) tmp = t_0; else tmp = x2 * ((x1 / x2) - 6.0); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(x1 + N[(x1 * -2.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -5.4e-104], t$95$0, If[LessEqual[x1, 1.8e-88], N[(x2 * -6.0), $MachinePrecision], If[LessEqual[x1, 1.4], t$95$0, N[(x2 * N[(N[(x1 / x2), $MachinePrecision] - 6.0), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 + x1 \cdot -2\\
\mathbf{if}\;x1 \leq -5.4 \cdot 10^{-104}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;x1 \leq 1.8 \cdot 10^{-88}:\\
\;\;\;\;x2 \cdot -6\\
\mathbf{elif}\;x1 \leq 1.4:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;x2 \cdot \left(\frac{x1}{x2} - 6\right)\\
\end{array}
\end{array}
if x1 < -5.3999999999999997e-104 or 1.8e-88 < x1 < 1.3999999999999999Initial program 52.6%
Taylor expanded in x1 around 0 39.5%
Taylor expanded in x2 around 0 27.3%
associate-*r*27.3%
*-commutative27.3%
Simplified27.3%
Taylor expanded in x1 around 0 36.6%
mul-1-neg52.6%
unsub-neg52.6%
*-commutative52.6%
Simplified36.6%
Taylor expanded in x2 around 0 21.1%
distribute-rgt1-in21.4%
metadata-eval21.4%
*-commutative21.4%
Simplified21.4%
if -5.3999999999999997e-104 < x1 < 1.8e-88Initial program 99.5%
Taylor expanded in x1 around 0 83.2%
Taylor expanded in x1 around 0 62.7%
*-commutative62.7%
Simplified62.7%
Taylor expanded in x1 around 0 63.3%
*-commutative63.3%
Simplified63.3%
if 1.3999999999999999 < x1 Initial program 51.6%
Taylor expanded in x1 around 0 16.9%
Taylor expanded in x1 around 0 5.5%
*-commutative5.5%
Simplified5.5%
Taylor expanded in x2 around inf 31.5%
(FPCore (x1 x2) :precision binary64 (if (<= x1 4.5) (+ x1 (+ (* x2 -6.0) (* x1 (- (* x2 -12.0) 2.0)))) (* x2 (- (/ x1 x2) 6.0))))
double code(double x1, double x2) {
double tmp;
if (x1 <= 4.5) {
tmp = x1 + ((x2 * -6.0) + (x1 * ((x2 * -12.0) - 2.0)));
} else {
tmp = x2 * ((x1 / x2) - 6.0);
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: tmp
if (x1 <= 4.5d0) then
tmp = x1 + ((x2 * (-6.0d0)) + (x1 * ((x2 * (-12.0d0)) - 2.0d0)))
else
tmp = x2 * ((x1 / x2) - 6.0d0)
end if
code = tmp
end function
public static double code(double x1, double x2) {
double tmp;
if (x1 <= 4.5) {
tmp = x1 + ((x2 * -6.0) + (x1 * ((x2 * -12.0) - 2.0)));
} else {
tmp = x2 * ((x1 / x2) - 6.0);
}
return tmp;
}
def code(x1, x2): tmp = 0 if x1 <= 4.5: tmp = x1 + ((x2 * -6.0) + (x1 * ((x2 * -12.0) - 2.0))) else: tmp = x2 * ((x1 / x2) - 6.0) return tmp
function code(x1, x2) tmp = 0.0 if (x1 <= 4.5) tmp = Float64(x1 + Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(Float64(x2 * -12.0) - 2.0)))); else tmp = Float64(x2 * Float64(Float64(x1 / x2) - 6.0)); end return tmp end
function tmp_2 = code(x1, x2) tmp = 0.0; if (x1 <= 4.5) tmp = x1 + ((x2 * -6.0) + (x1 * ((x2 * -12.0) - 2.0))); else tmp = x2 * ((x1 / x2) - 6.0); end tmp_2 = tmp; end
code[x1_, x2_] := If[LessEqual[x1, 4.5], N[(x1 + N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(N[(x2 * -12.0), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x2 * N[(N[(x1 / x2), $MachinePrecision] - 6.0), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x1 \leq 4.5:\\
\;\;\;\;x1 + \left(x2 \cdot -6 + x1 \cdot \left(x2 \cdot -12 - 2\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x2 \cdot \left(\frac{x1}{x2} - 6\right)\\
\end{array}
\end{array}
if x1 < 4.5Initial program 73.0%
Taylor expanded in x1 around 0 58.5%
Taylor expanded in x2 around 0 50.3%
associate-*r*50.3%
*-commutative50.3%
Simplified50.3%
Taylor expanded in x1 around 0 55.9%
if 4.5 < x1 Initial program 50.7%
Taylor expanded in x1 around 0 15.4%
Taylor expanded in x1 around 0 5.5%
*-commutative5.5%
Simplified5.5%
Taylor expanded in x2 around inf 32.0%
Final simplification50.9%
(FPCore (x1 x2) :precision binary64 (if (<= x1 -3.7e-35) (+ x1 (* x1 (- (* x2 -12.0) 2.0))) (if (<= x1 1.4) (- (* x2 -6.0) x1) (* x2 (- (/ x1 x2) 6.0)))))
double code(double x1, double x2) {
double tmp;
if (x1 <= -3.7e-35) {
tmp = x1 + (x1 * ((x2 * -12.0) - 2.0));
} else if (x1 <= 1.4) {
tmp = (x2 * -6.0) - x1;
} else {
tmp = x2 * ((x1 / x2) - 6.0);
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: tmp
if (x1 <= (-3.7d-35)) then
tmp = x1 + (x1 * ((x2 * (-12.0d0)) - 2.0d0))
else if (x1 <= 1.4d0) then
tmp = (x2 * (-6.0d0)) - x1
else
tmp = x2 * ((x1 / x2) - 6.0d0)
end if
code = tmp
end function
public static double code(double x1, double x2) {
double tmp;
if (x1 <= -3.7e-35) {
tmp = x1 + (x1 * ((x2 * -12.0) - 2.0));
} else if (x1 <= 1.4) {
tmp = (x2 * -6.0) - x1;
} else {
tmp = x2 * ((x1 / x2) - 6.0);
}
return tmp;
}
def code(x1, x2): tmp = 0 if x1 <= -3.7e-35: tmp = x1 + (x1 * ((x2 * -12.0) - 2.0)) elif x1 <= 1.4: tmp = (x2 * -6.0) - x1 else: tmp = x2 * ((x1 / x2) - 6.0) return tmp
function code(x1, x2) tmp = 0.0 if (x1 <= -3.7e-35) tmp = Float64(x1 + Float64(x1 * Float64(Float64(x2 * -12.0) - 2.0))); elseif (x1 <= 1.4) tmp = Float64(Float64(x2 * -6.0) - x1); else tmp = Float64(x2 * Float64(Float64(x1 / x2) - 6.0)); end return tmp end
function tmp_2 = code(x1, x2) tmp = 0.0; if (x1 <= -3.7e-35) tmp = x1 + (x1 * ((x2 * -12.0) - 2.0)); elseif (x1 <= 1.4) tmp = (x2 * -6.0) - x1; else tmp = x2 * ((x1 / x2) - 6.0); end tmp_2 = tmp; end
code[x1_, x2_] := If[LessEqual[x1, -3.7e-35], N[(x1 + N[(x1 * N[(N[(x2 * -12.0), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 1.4], N[(N[(x2 * -6.0), $MachinePrecision] - x1), $MachinePrecision], N[(x2 * N[(N[(x1 / x2), $MachinePrecision] - 6.0), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x1 \leq -3.7 \cdot 10^{-35}:\\
\;\;\;\;x1 + x1 \cdot \left(x2 \cdot -12 - 2\right)\\
\mathbf{elif}\;x1 \leq 1.4:\\
\;\;\;\;x2 \cdot -6 - x1\\
\mathbf{else}:\\
\;\;\;\;x2 \cdot \left(\frac{x1}{x2} - 6\right)\\
\end{array}
\end{array}
if x1 < -3.6999999999999999e-35Initial program 29.8%
Taylor expanded in x1 around 0 12.0%
Taylor expanded in x2 around 0 7.0%
associate-*r*7.0%
*-commutative7.0%
Simplified7.0%
Taylor expanded in x1 around 0 21.5%
mul-1-neg29.8%
unsub-neg29.8%
*-commutative29.8%
Simplified21.5%
Taylor expanded in x1 around inf 21.6%
if -3.6999999999999999e-35 < x1 < 1.3999999999999999Initial program 99.4%
Taylor expanded in x1 around inf 98.6%
Taylor expanded in x1 around 0 99.3%
mul-1-neg99.3%
unsub-neg99.3%
*-commutative99.3%
Simplified99.3%
Taylor expanded in x1 around inf 77.0%
associate-*r/77.0%
metadata-eval77.0%
Simplified77.0%
Taylor expanded in x1 around 0 77.5%
if 1.3999999999999999 < x1 Initial program 51.6%
Taylor expanded in x1 around 0 16.9%
Taylor expanded in x1 around 0 5.5%
*-commutative5.5%
Simplified5.5%
Taylor expanded in x2 around inf 31.5%
Final simplification51.0%
(FPCore (x1 x2) :precision binary64 (if (<= x1 -3.3e+56) (+ x1 (* x1 (+ 1.0 (* x2 -12.0)))) (if (<= x1 1.4) (- (* x2 -6.0) x1) (* x2 (- (/ x1 x2) 6.0)))))
double code(double x1, double x2) {
double tmp;
if (x1 <= -3.3e+56) {
tmp = x1 + (x1 * (1.0 + (x2 * -12.0)));
} else if (x1 <= 1.4) {
tmp = (x2 * -6.0) - x1;
} else {
tmp = x2 * ((x1 / x2) - 6.0);
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: tmp
if (x1 <= (-3.3d+56)) then
tmp = x1 + (x1 * (1.0d0 + (x2 * (-12.0d0))))
else if (x1 <= 1.4d0) then
tmp = (x2 * (-6.0d0)) - x1
else
tmp = x2 * ((x1 / x2) - 6.0d0)
end if
code = tmp
end function
public static double code(double x1, double x2) {
double tmp;
if (x1 <= -3.3e+56) {
tmp = x1 + (x1 * (1.0 + (x2 * -12.0)));
} else if (x1 <= 1.4) {
tmp = (x2 * -6.0) - x1;
} else {
tmp = x2 * ((x1 / x2) - 6.0);
}
return tmp;
}
def code(x1, x2): tmp = 0 if x1 <= -3.3e+56: tmp = x1 + (x1 * (1.0 + (x2 * -12.0))) elif x1 <= 1.4: tmp = (x2 * -6.0) - x1 else: tmp = x2 * ((x1 / x2) - 6.0) return tmp
function code(x1, x2) tmp = 0.0 if (x1 <= -3.3e+56) tmp = Float64(x1 + Float64(x1 * Float64(1.0 + Float64(x2 * -12.0)))); elseif (x1 <= 1.4) tmp = Float64(Float64(x2 * -6.0) - x1); else tmp = Float64(x2 * Float64(Float64(x1 / x2) - 6.0)); end return tmp end
function tmp_2 = code(x1, x2) tmp = 0.0; if (x1 <= -3.3e+56) tmp = x1 + (x1 * (1.0 + (x2 * -12.0))); elseif (x1 <= 1.4) tmp = (x2 * -6.0) - x1; else tmp = x2 * ((x1 / x2) - 6.0); end tmp_2 = tmp; end
code[x1_, x2_] := If[LessEqual[x1, -3.3e+56], N[(x1 + N[(x1 * N[(1.0 + N[(x2 * -12.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 1.4], N[(N[(x2 * -6.0), $MachinePrecision] - x1), $MachinePrecision], N[(x2 * N[(N[(x1 / x2), $MachinePrecision] - 6.0), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x1 \leq -3.3 \cdot 10^{+56}:\\
\;\;\;\;x1 + x1 \cdot \left(1 + x2 \cdot -12\right)\\
\mathbf{elif}\;x1 \leq 1.4:\\
\;\;\;\;x2 \cdot -6 - x1\\
\mathbf{else}:\\
\;\;\;\;x2 \cdot \left(\frac{x1}{x2} - 6\right)\\
\end{array}
\end{array}
if x1 < -3.30000000000000002e56Initial program 15.6%
Taylor expanded in x1 around 0 7.9%
Taylor expanded in x2 around 0 6.6%
associate-*r*6.6%
*-commutative6.6%
Simplified6.6%
Taylor expanded in x1 around inf 20.7%
*-commutative20.7%
Simplified20.7%
if -3.30000000000000002e56 < x1 < 1.3999999999999999Initial program 99.4%
Taylor expanded in x1 around inf 98.6%
Taylor expanded in x1 around 0 99.3%
mul-1-neg99.3%
unsub-neg99.3%
*-commutative99.3%
Simplified99.3%
Taylor expanded in x1 around inf 76.3%
associate-*r/76.3%
metadata-eval76.3%
Simplified76.3%
Taylor expanded in x1 around 0 71.3%
if 1.3999999999999999 < x1 Initial program 51.6%
Taylor expanded in x1 around 0 16.9%
Taylor expanded in x1 around 0 5.5%
*-commutative5.5%
Simplified5.5%
Taylor expanded in x2 around inf 31.5%
Final simplification50.3%
(FPCore (x1 x2) :precision binary64 (if (or (<= x2 -1.12e-138) (not (<= x2 2e-95))) (* x2 -6.0) (+ x1 (* x1 -2.0))))
double code(double x1, double x2) {
double tmp;
if ((x2 <= -1.12e-138) || !(x2 <= 2e-95)) {
tmp = x2 * -6.0;
} else {
tmp = x1 + (x1 * -2.0);
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: tmp
if ((x2 <= (-1.12d-138)) .or. (.not. (x2 <= 2d-95))) then
tmp = x2 * (-6.0d0)
else
tmp = x1 + (x1 * (-2.0d0))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double tmp;
if ((x2 <= -1.12e-138) || !(x2 <= 2e-95)) {
tmp = x2 * -6.0;
} else {
tmp = x1 + (x1 * -2.0);
}
return tmp;
}
def code(x1, x2): tmp = 0 if (x2 <= -1.12e-138) or not (x2 <= 2e-95): tmp = x2 * -6.0 else: tmp = x1 + (x1 * -2.0) return tmp
function code(x1, x2) tmp = 0.0 if ((x2 <= -1.12e-138) || !(x2 <= 2e-95)) tmp = Float64(x2 * -6.0); else tmp = Float64(x1 + Float64(x1 * -2.0)); end return tmp end
function tmp_2 = code(x1, x2) tmp = 0.0; if ((x2 <= -1.12e-138) || ~((x2 <= 2e-95))) tmp = x2 * -6.0; else tmp = x1 + (x1 * -2.0); end tmp_2 = tmp; end
code[x1_, x2_] := If[Or[LessEqual[x2, -1.12e-138], N[Not[LessEqual[x2, 2e-95]], $MachinePrecision]], N[(x2 * -6.0), $MachinePrecision], N[(x1 + N[(x1 * -2.0), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x2 \leq -1.12 \cdot 10^{-138} \lor \neg \left(x2 \leq 2 \cdot 10^{-95}\right):\\
\;\;\;\;x2 \cdot -6\\
\mathbf{else}:\\
\;\;\;\;x1 + x1 \cdot -2\\
\end{array}
\end{array}
if x2 < -1.1199999999999999e-138 or 1.99999999999999998e-95 < x2 Initial program 68.2%
Taylor expanded in x1 around 0 49.4%
Taylor expanded in x1 around 0 31.7%
*-commutative31.7%
Simplified31.7%
Taylor expanded in x1 around 0 31.6%
*-commutative31.6%
Simplified31.6%
if -1.1199999999999999e-138 < x2 < 1.99999999999999998e-95Initial program 68.8%
Taylor expanded in x1 around 0 49.9%
Taylor expanded in x2 around 0 49.9%
associate-*r*49.9%
*-commutative49.9%
Simplified49.9%
Taylor expanded in x1 around 0 50.9%
mul-1-neg68.7%
unsub-neg68.7%
*-commutative68.7%
Simplified50.9%
Taylor expanded in x2 around 0 38.9%
distribute-rgt1-in39.4%
metadata-eval39.4%
*-commutative39.4%
Simplified39.4%
Final simplification34.0%
(FPCore (x1 x2) :precision binary64 (if (<= x2 -2.02e-140) (* x2 -6.0) (if (<= x2 4e-60) (+ x1 (* x1 -2.0)) (+ x1 (* x2 -6.0)))))
double code(double x1, double x2) {
double tmp;
if (x2 <= -2.02e-140) {
tmp = x2 * -6.0;
} else if (x2 <= 4e-60) {
tmp = x1 + (x1 * -2.0);
} else {
tmp = x1 + (x2 * -6.0);
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: tmp
if (x2 <= (-2.02d-140)) then
tmp = x2 * (-6.0d0)
else if (x2 <= 4d-60) then
tmp = x1 + (x1 * (-2.0d0))
else
tmp = x1 + (x2 * (-6.0d0))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double tmp;
if (x2 <= -2.02e-140) {
tmp = x2 * -6.0;
} else if (x2 <= 4e-60) {
tmp = x1 + (x1 * -2.0);
} else {
tmp = x1 + (x2 * -6.0);
}
return tmp;
}
def code(x1, x2): tmp = 0 if x2 <= -2.02e-140: tmp = x2 * -6.0 elif x2 <= 4e-60: tmp = x1 + (x1 * -2.0) else: tmp = x1 + (x2 * -6.0) return tmp
function code(x1, x2) tmp = 0.0 if (x2 <= -2.02e-140) tmp = Float64(x2 * -6.0); elseif (x2 <= 4e-60) tmp = Float64(x1 + Float64(x1 * -2.0)); else tmp = Float64(x1 + Float64(x2 * -6.0)); end return tmp end
function tmp_2 = code(x1, x2) tmp = 0.0; if (x2 <= -2.02e-140) tmp = x2 * -6.0; elseif (x2 <= 4e-60) tmp = x1 + (x1 * -2.0); else tmp = x1 + (x2 * -6.0); end tmp_2 = tmp; end
code[x1_, x2_] := If[LessEqual[x2, -2.02e-140], N[(x2 * -6.0), $MachinePrecision], If[LessEqual[x2, 4e-60], N[(x1 + N[(x1 * -2.0), $MachinePrecision]), $MachinePrecision], N[(x1 + N[(x2 * -6.0), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x2 \leq -2.02 \cdot 10^{-140}:\\
\;\;\;\;x2 \cdot -6\\
\mathbf{elif}\;x2 \leq 4 \cdot 10^{-60}:\\
\;\;\;\;x1 + x1 \cdot -2\\
\mathbf{else}:\\
\;\;\;\;x1 + x2 \cdot -6\\
\end{array}
\end{array}
if x2 < -2.02000000000000005e-140Initial program 67.4%
Taylor expanded in x1 around 0 47.8%
Taylor expanded in x1 around 0 32.5%
*-commutative32.5%
Simplified32.5%
Taylor expanded in x1 around 0 32.8%
*-commutative32.8%
Simplified32.8%
if -2.02000000000000005e-140 < x2 < 3.9999999999999999e-60Initial program 69.9%
Taylor expanded in x1 around 0 50.5%
Taylor expanded in x2 around 0 50.5%
associate-*r*50.5%
*-commutative50.5%
Simplified50.5%
Taylor expanded in x1 around 0 51.5%
mul-1-neg69.9%
unsub-neg69.9%
*-commutative69.9%
Simplified51.5%
Taylor expanded in x2 around 0 38.7%
distribute-rgt1-in39.3%
metadata-eval39.3%
*-commutative39.3%
Simplified39.3%
if 3.9999999999999999e-60 < x2 Initial program 68.0%
Taylor expanded in x1 around 0 51.0%
Taylor expanded in x1 around 0 30.5%
*-commutative30.5%
Simplified30.5%
(FPCore (x1 x2) :precision binary64 (if (<= x1 1.4) (- (* x2 -6.0) x1) (* x2 (- (/ x1 x2) 6.0))))
double code(double x1, double x2) {
double tmp;
if (x1 <= 1.4) {
tmp = (x2 * -6.0) - x1;
} else {
tmp = x2 * ((x1 / x2) - 6.0);
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: tmp
if (x1 <= 1.4d0) then
tmp = (x2 * (-6.0d0)) - x1
else
tmp = x2 * ((x1 / x2) - 6.0d0)
end if
code = tmp
end function
public static double code(double x1, double x2) {
double tmp;
if (x1 <= 1.4) {
tmp = (x2 * -6.0) - x1;
} else {
tmp = x2 * ((x1 / x2) - 6.0);
}
return tmp;
}
def code(x1, x2): tmp = 0 if x1 <= 1.4: tmp = (x2 * -6.0) - x1 else: tmp = x2 * ((x1 / x2) - 6.0) return tmp
function code(x1, x2) tmp = 0.0 if (x1 <= 1.4) tmp = Float64(Float64(x2 * -6.0) - x1); else tmp = Float64(x2 * Float64(Float64(x1 / x2) - 6.0)); end return tmp end
function tmp_2 = code(x1, x2) tmp = 0.0; if (x1 <= 1.4) tmp = (x2 * -6.0) - x1; else tmp = x2 * ((x1 / x2) - 6.0); end tmp_2 = tmp; end
code[x1_, x2_] := If[LessEqual[x1, 1.4], N[(N[(x2 * -6.0), $MachinePrecision] - x1), $MachinePrecision], N[(x2 * N[(N[(x1 / x2), $MachinePrecision] - 6.0), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x1 \leq 1.4:\\
\;\;\;\;x2 \cdot -6 - x1\\
\mathbf{else}:\\
\;\;\;\;x2 \cdot \left(\frac{x1}{x2} - 6\right)\\
\end{array}
\end{array}
if x1 < 1.3999999999999999Initial program 72.8%
Taylor expanded in x1 around inf 72.3%
Taylor expanded in x1 around 0 72.8%
mul-1-neg72.8%
unsub-neg72.8%
*-commutative72.8%
Simplified72.8%
Taylor expanded in x1 around inf 81.4%
associate-*r/81.4%
metadata-eval81.4%
Simplified81.4%
Taylor expanded in x1 around 0 50.7%
if 1.3999999999999999 < x1 Initial program 51.6%
Taylor expanded in x1 around 0 16.9%
Taylor expanded in x1 around 0 5.5%
*-commutative5.5%
Simplified5.5%
Taylor expanded in x2 around inf 31.5%
Final simplification46.6%
(FPCore (x1 x2) :precision binary64 (* x2 -6.0))
double code(double x1, double x2) {
return x2 * -6.0;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
code = x2 * (-6.0d0)
end function
public static double code(double x1, double x2) {
return x2 * -6.0;
}
def code(x1, x2): return x2 * -6.0
function code(x1, x2) return Float64(x2 * -6.0) end
function tmp = code(x1, x2) tmp = x2 * -6.0; end
code[x1_, x2_] := N[(x2 * -6.0), $MachinePrecision]
\begin{array}{l}
\\
x2 \cdot -6
\end{array}
Initial program 68.3%
Taylor expanded in x1 around 0 49.6%
Taylor expanded in x1 around 0 25.8%
*-commutative25.8%
Simplified25.8%
Taylor expanded in x1 around 0 25.9%
*-commutative25.9%
Simplified25.9%
(FPCore (x1 x2) :precision binary64 x1)
double code(double x1, double x2) {
return x1;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
code = x1
end function
public static double code(double x1, double x2) {
return x1;
}
def code(x1, x2): return x1
function code(x1, x2) return x1 end
function tmp = code(x1, x2) tmp = x1; end
code[x1_, x2_] := x1
\begin{array}{l}
\\
x1
\end{array}
Initial program 68.3%
Taylor expanded in x1 around 0 49.6%
Taylor expanded in x1 around 0 25.8%
*-commutative25.8%
Simplified25.8%
Taylor expanded in x1 around inf 3.0%
herbie shell --seed 2024084
(FPCore (x1 x2)
:name "Rosa's FloatVsDoubleBenchmark"
:precision binary64
(+ x1 (+ (+ (+ (+ (* (+ (* (* (* 2.0 x1) (/ (- (+ (* (* 3.0 x1) x1) (* 2.0 x2)) x1) (+ (* x1 x1) 1.0))) (- (/ (- (+ (* (* 3.0 x1) x1) (* 2.0 x2)) x1) (+ (* x1 x1) 1.0)) 3.0)) (* (* x1 x1) (- (* 4.0 (/ (- (+ (* (* 3.0 x1) x1) (* 2.0 x2)) x1) (+ (* x1 x1) 1.0))) 6.0))) (+ (* x1 x1) 1.0)) (* (* (* 3.0 x1) x1) (/ (- (+ (* (* 3.0 x1) x1) (* 2.0 x2)) x1) (+ (* x1 x1) 1.0)))) (* (* x1 x1) x1)) x1) (* 3.0 (/ (- (- (* (* 3.0 x1) x1) (* 2.0 x2)) x1) (+ (* x1 x1) 1.0))))))