
(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 27 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) 1.0))
(t_1 (* x1 (* x1 3.0)))
(t_2 (- (+ t_1 (* 2.0 x2)) x1))
(t_3 (/ t_2 (- -1.0 (* x1 x1))))
(t_4 (* x1 (+ (* x1 3.0) -1.0)))
(t_5 (+ (* 2.0 x2) t_4)))
(if (<=
(+
x1
(+
(+
x1
(-
(* x1 (* x1 x1))
(+
(* t_1 t_3)
(*
t_0
(+
(* (* x1 x1) (+ 6.0 (* 4.0 t_3)))
(* (* (/ t_2 t_0) (* x1 2.0)) (+ 3.0 t_3)))))))
(* 3.0 (/ (- (- t_1 (* 2.0 x2)) x1) t_0))))
INFINITY)
(fma
3.0
(/ (+ (* x2 -2.0) t_4) t_0)
(+
(*
t_0
(+
(* (* x1 x1) -6.0)
(/ (* x1 (+ (+ -6.0 (/ t_5 (/ t_0 2.0))) (* x1 4.0))) (/ t_0 t_5))))
(* x1 (+ 2.0 (* x1 (+ x1 (/ t_5 (/ t_0 3.0))))))))
(* 6.0 (pow x1 4.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;
double t_3 = t_2 / (-1.0 - (x1 * x1));
double t_4 = x1 * ((x1 * 3.0) + -1.0);
double t_5 = (2.0 * x2) + t_4;
double tmp;
if ((x1 + ((x1 + ((x1 * (x1 * x1)) - ((t_1 * t_3) + (t_0 * (((x1 * x1) * (6.0 + (4.0 * t_3))) + (((t_2 / t_0) * (x1 * 2.0)) * (3.0 + t_3))))))) + (3.0 * (((t_1 - (2.0 * x2)) - x1) / t_0)))) <= ((double) INFINITY)) {
tmp = fma(3.0, (((x2 * -2.0) + t_4) / t_0), ((t_0 * (((x1 * x1) * -6.0) + ((x1 * ((-6.0 + (t_5 / (t_0 / 2.0))) + (x1 * 4.0))) / (t_0 / t_5)))) + (x1 * (2.0 + (x1 * (x1 + (t_5 / (t_0 / 3.0))))))));
} else {
tmp = 6.0 * pow(x1, 4.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(t_1 + Float64(2.0 * x2)) - x1) t_3 = Float64(t_2 / Float64(-1.0 - Float64(x1 * x1))) t_4 = Float64(x1 * Float64(Float64(x1 * 3.0) + -1.0)) t_5 = Float64(Float64(2.0 * x2) + t_4) tmp = 0.0 if (Float64(x1 + Float64(Float64(x1 + Float64(Float64(x1 * Float64(x1 * x1)) - Float64(Float64(t_1 * t_3) + Float64(t_0 * Float64(Float64(Float64(x1 * x1) * Float64(6.0 + Float64(4.0 * t_3))) + Float64(Float64(Float64(t_2 / t_0) * Float64(x1 * 2.0)) * Float64(3.0 + t_3))))))) + Float64(3.0 * Float64(Float64(Float64(t_1 - Float64(2.0 * x2)) - x1) / t_0)))) <= Inf) tmp = fma(3.0, Float64(Float64(Float64(x2 * -2.0) + t_4) / t_0), Float64(Float64(t_0 * Float64(Float64(Float64(x1 * x1) * -6.0) + Float64(Float64(x1 * Float64(Float64(-6.0 + Float64(t_5 / Float64(t_0 / 2.0))) + Float64(x1 * 4.0))) / Float64(t_0 / t_5)))) + Float64(x1 * Float64(2.0 + Float64(x1 * Float64(x1 + Float64(t_5 / Float64(t_0 / 3.0)))))))); else tmp = Float64(6.0 * (x1 ^ 4.0)); end return 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[(t$95$1 + N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision]}, Block[{t$95$3 = N[(t$95$2 / N[(-1.0 - N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(x1 * N[(N[(x1 * 3.0), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[(N[(2.0 * x2), $MachinePrecision] + t$95$4), $MachinePrecision]}, If[LessEqual[N[(x1 + N[(N[(x1 + N[(N[(x1 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision] - N[(N[(t$95$1 * t$95$3), $MachinePrecision] + N[(t$95$0 * N[(N[(N[(x1 * x1), $MachinePrecision] * N[(6.0 + N[(4.0 * t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(t$95$2 / t$95$0), $MachinePrecision] * N[(x1 * 2.0), $MachinePrecision]), $MachinePrecision] * N[(3.0 + t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(3.0 * N[(N[(N[(t$95$1 - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], Infinity], N[(3.0 * N[(N[(N[(x2 * -2.0), $MachinePrecision] + t$95$4), $MachinePrecision] / t$95$0), $MachinePrecision] + N[(N[(t$95$0 * N[(N[(N[(x1 * x1), $MachinePrecision] * -6.0), $MachinePrecision] + N[(N[(x1 * N[(N[(-6.0 + N[(t$95$5 / N[(t$95$0 / 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x1 * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(t$95$0 / t$95$5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x1 * N[(2.0 + N[(x1 * N[(x1 + N[(t$95$5 / N[(t$95$0 / 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(6.0 * N[Power[x1, 4.0], $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 := \left(t\_1 + 2 \cdot x2\right) - x1\\
t_3 := \frac{t\_2}{-1 - x1 \cdot x1}\\
t_4 := x1 \cdot \left(x1 \cdot 3 + -1\right)\\
t_5 := 2 \cdot x2 + t\_4\\
\mathbf{if}\;x1 + \left(\left(x1 + \left(x1 \cdot \left(x1 \cdot x1\right) - \left(t\_1 \cdot t\_3 + t\_0 \cdot \left(\left(x1 \cdot x1\right) \cdot \left(6 + 4 \cdot t\_3\right) + \left(\frac{t\_2}{t\_0} \cdot \left(x1 \cdot 2\right)\right) \cdot \left(3 + t\_3\right)\right)\right)\right)\right) + 3 \cdot \frac{\left(t\_1 - 2 \cdot x2\right) - x1}{t\_0}\right) \leq \infty:\\
\;\;\;\;\mathsf{fma}\left(3, \frac{x2 \cdot -2 + t\_4}{t\_0}, t\_0 \cdot \left(\left(x1 \cdot x1\right) \cdot -6 + \frac{x1 \cdot \left(\left(-6 + \frac{t\_5}{\frac{t\_0}{2}}\right) + x1 \cdot 4\right)}{\frac{t\_0}{t\_5}}\right) + x1 \cdot \left(2 + x1 \cdot \left(x1 + \frac{t\_5}{\frac{t\_0}{3}}\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;6 \cdot {x1}^{4}\\
\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.5%
Simplified99.6%
Applied egg-rr99.7%
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
*-lowering-*.f64N/A
pow-lowering-pow.f6496.8%
Simplified96.8%
Final simplification99.0%
(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_3 (/ t_2 (- -1.0 (* x1 x1))))
(t_4 (* x1 (+ (* x1 3.0) -1.0)))
(t_5 (+ (* 2.0 x2) t_4)))
(if (<=
(+
x1
(+
(+
x1
(-
(* x1 (* x1 x1))
(+
(* t_1 t_3)
(*
t_0
(+
(* (* x1 x1) (+ 6.0 (* 4.0 t_3)))
(* (* (/ t_2 t_0) (* x1 2.0)) (+ 3.0 t_3)))))))
(* 3.0 (/ (- (- t_1 (* 2.0 x2)) x1) t_0))))
INFINITY)
(+
(/ (* 3.0 (+ (* x2 -2.0) t_4)) t_0)
(+
(*
t_0
(+
(* x1 (* x1 -6.0))
(*
(/ t_5 t_0)
(+ (* x1 (+ -6.0 (* t_5 (/ 2.0 t_0)))) (* (* x1 x1) 4.0)))))
(* x1 (+ 2.0 (* x1 (+ x1 (* t_5 (/ 3.0 t_0))))))))
(* 6.0 (pow x1 4.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;
double t_3 = t_2 / (-1.0 - (x1 * x1));
double t_4 = x1 * ((x1 * 3.0) + -1.0);
double t_5 = (2.0 * x2) + t_4;
double tmp;
if ((x1 + ((x1 + ((x1 * (x1 * x1)) - ((t_1 * t_3) + (t_0 * (((x1 * x1) * (6.0 + (4.0 * t_3))) + (((t_2 / t_0) * (x1 * 2.0)) * (3.0 + t_3))))))) + (3.0 * (((t_1 - (2.0 * x2)) - x1) / t_0)))) <= ((double) INFINITY)) {
tmp = ((3.0 * ((x2 * -2.0) + t_4)) / t_0) + ((t_0 * ((x1 * (x1 * -6.0)) + ((t_5 / t_0) * ((x1 * (-6.0 + (t_5 * (2.0 / t_0)))) + ((x1 * x1) * 4.0))))) + (x1 * (2.0 + (x1 * (x1 + (t_5 * (3.0 / t_0)))))));
} else {
tmp = 6.0 * pow(x1, 4.0);
}
return tmp;
}
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;
double t_3 = t_2 / (-1.0 - (x1 * x1));
double t_4 = x1 * ((x1 * 3.0) + -1.0);
double t_5 = (2.0 * x2) + t_4;
double tmp;
if ((x1 + ((x1 + ((x1 * (x1 * x1)) - ((t_1 * t_3) + (t_0 * (((x1 * x1) * (6.0 + (4.0 * t_3))) + (((t_2 / t_0) * (x1 * 2.0)) * (3.0 + t_3))))))) + (3.0 * (((t_1 - (2.0 * x2)) - x1) / t_0)))) <= Double.POSITIVE_INFINITY) {
tmp = ((3.0 * ((x2 * -2.0) + t_4)) / t_0) + ((t_0 * ((x1 * (x1 * -6.0)) + ((t_5 / t_0) * ((x1 * (-6.0 + (t_5 * (2.0 / t_0)))) + ((x1 * x1) * 4.0))))) + (x1 * (2.0 + (x1 * (x1 + (t_5 * (3.0 / t_0)))))));
} else {
tmp = 6.0 * Math.pow(x1, 4.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_3 = t_2 / (-1.0 - (x1 * x1)) t_4 = x1 * ((x1 * 3.0) + -1.0) t_5 = (2.0 * x2) + t_4 tmp = 0 if (x1 + ((x1 + ((x1 * (x1 * x1)) - ((t_1 * t_3) + (t_0 * (((x1 * x1) * (6.0 + (4.0 * t_3))) + (((t_2 / t_0) * (x1 * 2.0)) * (3.0 + t_3))))))) + (3.0 * (((t_1 - (2.0 * x2)) - x1) / t_0)))) <= math.inf: tmp = ((3.0 * ((x2 * -2.0) + t_4)) / t_0) + ((t_0 * ((x1 * (x1 * -6.0)) + ((t_5 / t_0) * ((x1 * (-6.0 + (t_5 * (2.0 / t_0)))) + ((x1 * x1) * 4.0))))) + (x1 * (2.0 + (x1 * (x1 + (t_5 * (3.0 / t_0))))))) else: tmp = 6.0 * math.pow(x1, 4.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(t_1 + Float64(2.0 * x2)) - x1) t_3 = Float64(t_2 / Float64(-1.0 - Float64(x1 * x1))) t_4 = Float64(x1 * Float64(Float64(x1 * 3.0) + -1.0)) t_5 = Float64(Float64(2.0 * x2) + t_4) tmp = 0.0 if (Float64(x1 + Float64(Float64(x1 + Float64(Float64(x1 * Float64(x1 * x1)) - Float64(Float64(t_1 * t_3) + Float64(t_0 * Float64(Float64(Float64(x1 * x1) * Float64(6.0 + Float64(4.0 * t_3))) + Float64(Float64(Float64(t_2 / t_0) * Float64(x1 * 2.0)) * Float64(3.0 + t_3))))))) + Float64(3.0 * Float64(Float64(Float64(t_1 - Float64(2.0 * x2)) - x1) / t_0)))) <= Inf) tmp = Float64(Float64(Float64(3.0 * Float64(Float64(x2 * -2.0) + t_4)) / t_0) + Float64(Float64(t_0 * Float64(Float64(x1 * Float64(x1 * -6.0)) + Float64(Float64(t_5 / t_0) * Float64(Float64(x1 * Float64(-6.0 + Float64(t_5 * Float64(2.0 / t_0)))) + Float64(Float64(x1 * x1) * 4.0))))) + Float64(x1 * Float64(2.0 + Float64(x1 * Float64(x1 + Float64(t_5 * Float64(3.0 / t_0)))))))); else tmp = Float64(6.0 * (x1 ^ 4.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_3 = t_2 / (-1.0 - (x1 * x1)); t_4 = x1 * ((x1 * 3.0) + -1.0); t_5 = (2.0 * x2) + t_4; tmp = 0.0; if ((x1 + ((x1 + ((x1 * (x1 * x1)) - ((t_1 * t_3) + (t_0 * (((x1 * x1) * (6.0 + (4.0 * t_3))) + (((t_2 / t_0) * (x1 * 2.0)) * (3.0 + t_3))))))) + (3.0 * (((t_1 - (2.0 * x2)) - x1) / t_0)))) <= Inf) tmp = ((3.0 * ((x2 * -2.0) + t_4)) / t_0) + ((t_0 * ((x1 * (x1 * -6.0)) + ((t_5 / t_0) * ((x1 * (-6.0 + (t_5 * (2.0 / t_0)))) + ((x1 * x1) * 4.0))))) + (x1 * (2.0 + (x1 * (x1 + (t_5 * (3.0 / t_0))))))); else tmp = 6.0 * (x1 ^ 4.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[(t$95$1 + N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision]}, Block[{t$95$3 = N[(t$95$2 / N[(-1.0 - N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(x1 * N[(N[(x1 * 3.0), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[(N[(2.0 * x2), $MachinePrecision] + t$95$4), $MachinePrecision]}, If[LessEqual[N[(x1 + N[(N[(x1 + N[(N[(x1 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision] - N[(N[(t$95$1 * t$95$3), $MachinePrecision] + N[(t$95$0 * N[(N[(N[(x1 * x1), $MachinePrecision] * N[(6.0 + N[(4.0 * t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(t$95$2 / t$95$0), $MachinePrecision] * N[(x1 * 2.0), $MachinePrecision]), $MachinePrecision] * N[(3.0 + t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(3.0 * N[(N[(N[(t$95$1 - N[(2.0 * x2), $MachinePrecision]), $MachinePrecision] - x1), $MachinePrecision] / t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], Infinity], N[(N[(N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] + t$95$4), $MachinePrecision]), $MachinePrecision] / t$95$0), $MachinePrecision] + N[(N[(t$95$0 * N[(N[(x1 * N[(x1 * -6.0), $MachinePrecision]), $MachinePrecision] + N[(N[(t$95$5 / t$95$0), $MachinePrecision] * N[(N[(x1 * N[(-6.0 + N[(t$95$5 * N[(2.0 / t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(x1 * x1), $MachinePrecision] * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x1 * N[(2.0 + N[(x1 * N[(x1 + N[(t$95$5 * N[(3.0 / t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(6.0 * N[Power[x1, 4.0], $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 := \left(t\_1 + 2 \cdot x2\right) - x1\\
t_3 := \frac{t\_2}{-1 - x1 \cdot x1}\\
t_4 := x1 \cdot \left(x1 \cdot 3 + -1\right)\\
t_5 := 2 \cdot x2 + t\_4\\
\mathbf{if}\;x1 + \left(\left(x1 + \left(x1 \cdot \left(x1 \cdot x1\right) - \left(t\_1 \cdot t\_3 + t\_0 \cdot \left(\left(x1 \cdot x1\right) \cdot \left(6 + 4 \cdot t\_3\right) + \left(\frac{t\_2}{t\_0} \cdot \left(x1 \cdot 2\right)\right) \cdot \left(3 + t\_3\right)\right)\right)\right)\right) + 3 \cdot \frac{\left(t\_1 - 2 \cdot x2\right) - x1}{t\_0}\right) \leq \infty:\\
\;\;\;\;\frac{3 \cdot \left(x2 \cdot -2 + t\_4\right)}{t\_0} + \left(t\_0 \cdot \left(x1 \cdot \left(x1 \cdot -6\right) + \frac{t\_5}{t\_0} \cdot \left(x1 \cdot \left(-6 + t\_5 \cdot \frac{2}{t\_0}\right) + \left(x1 \cdot x1\right) \cdot 4\right)\right) + x1 \cdot \left(2 + x1 \cdot \left(x1 + t\_5 \cdot \frac{3}{t\_0}\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;6 \cdot {x1}^{4}\\
\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.5%
Simplified99.6%
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
*-lowering-*.f64N/A
pow-lowering-pow.f6496.8%
Simplified96.8%
Final simplification98.9%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (+ (* x1 x1) 1.0))
(t_1 (* x1 (+ (* x1 3.0) -1.0)))
(t_2 (+ (* 2.0 x2) t_1)))
(if (<= x1 -5.5e+102)
(* x1 (+ -1.0 (* x1 (+ 9.0 (* x1 -19.0)))))
(if (<= x1 1e+100)
(+
(/ 3.0 (/ t_0 (+ (* x2 -2.0) t_1)))
(+
(*
t_0
(+
(/ (* x1 (+ (+ -6.0 (/ t_2 (/ t_0 2.0))) (* x1 4.0))) (/ t_0 t_2))
(* x1 (* x1 -6.0))))
(* x1 (+ 2.0 (* x1 (+ x1 (/ t_2 (/ t_0 3.0))))))))
(* x1 (* 3.0 (* x1 x1)))))))
double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = x1 * ((x1 * 3.0) + -1.0);
double t_2 = (2.0 * x2) + t_1;
double tmp;
if (x1 <= -5.5e+102) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= 1e+100) {
tmp = (3.0 / (t_0 / ((x2 * -2.0) + t_1))) + ((t_0 * (((x1 * ((-6.0 + (t_2 / (t_0 / 2.0))) + (x1 * 4.0))) / (t_0 / t_2)) + (x1 * (x1 * -6.0)))) + (x1 * (2.0 + (x1 * (x1 + (t_2 / (t_0 / 3.0)))))));
} else {
tmp = x1 * (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) :: tmp
t_0 = (x1 * x1) + 1.0d0
t_1 = x1 * ((x1 * 3.0d0) + (-1.0d0))
t_2 = (2.0d0 * x2) + t_1
if (x1 <= (-5.5d+102)) then
tmp = x1 * ((-1.0d0) + (x1 * (9.0d0 + (x1 * (-19.0d0)))))
else if (x1 <= 1d+100) then
tmp = (3.0d0 / (t_0 / ((x2 * (-2.0d0)) + t_1))) + ((t_0 * (((x1 * (((-6.0d0) + (t_2 / (t_0 / 2.0d0))) + (x1 * 4.0d0))) / (t_0 / t_2)) + (x1 * (x1 * (-6.0d0))))) + (x1 * (2.0d0 + (x1 * (x1 + (t_2 / (t_0 / 3.0d0)))))))
else
tmp = x1 * (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) + -1.0);
double t_2 = (2.0 * x2) + t_1;
double tmp;
if (x1 <= -5.5e+102) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= 1e+100) {
tmp = (3.0 / (t_0 / ((x2 * -2.0) + t_1))) + ((t_0 * (((x1 * ((-6.0 + (t_2 / (t_0 / 2.0))) + (x1 * 4.0))) / (t_0 / t_2)) + (x1 * (x1 * -6.0)))) + (x1 * (2.0 + (x1 * (x1 + (t_2 / (t_0 / 3.0)))))));
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
def code(x1, x2): t_0 = (x1 * x1) + 1.0 t_1 = x1 * ((x1 * 3.0) + -1.0) t_2 = (2.0 * x2) + t_1 tmp = 0 if x1 <= -5.5e+102: tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))) elif x1 <= 1e+100: tmp = (3.0 / (t_0 / ((x2 * -2.0) + t_1))) + ((t_0 * (((x1 * ((-6.0 + (t_2 / (t_0 / 2.0))) + (x1 * 4.0))) / (t_0 / t_2)) + (x1 * (x1 * -6.0)))) + (x1 * (2.0 + (x1 * (x1 + (t_2 / (t_0 / 3.0))))))) else: tmp = x1 * (3.0 * (x1 * x1)) return tmp
function code(x1, x2) t_0 = Float64(Float64(x1 * x1) + 1.0) t_1 = Float64(x1 * Float64(Float64(x1 * 3.0) + -1.0)) t_2 = Float64(Float64(2.0 * x2) + t_1) tmp = 0.0 if (x1 <= -5.5e+102) tmp = Float64(x1 * Float64(-1.0 + Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))); elseif (x1 <= 1e+100) tmp = Float64(Float64(3.0 / Float64(t_0 / Float64(Float64(x2 * -2.0) + t_1))) + Float64(Float64(t_0 * Float64(Float64(Float64(x1 * Float64(Float64(-6.0 + Float64(t_2 / Float64(t_0 / 2.0))) + Float64(x1 * 4.0))) / Float64(t_0 / t_2)) + Float64(x1 * Float64(x1 * -6.0)))) + Float64(x1 * Float64(2.0 + Float64(x1 * Float64(x1 + Float64(t_2 / Float64(t_0 / 3.0)))))))); else tmp = Float64(x1 * Float64(3.0 * Float64(x1 * x1))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = (x1 * x1) + 1.0; t_1 = x1 * ((x1 * 3.0) + -1.0); t_2 = (2.0 * x2) + t_1; tmp = 0.0; if (x1 <= -5.5e+102) tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))); elseif (x1 <= 1e+100) tmp = (3.0 / (t_0 / ((x2 * -2.0) + t_1))) + ((t_0 * (((x1 * ((-6.0 + (t_2 / (t_0 / 2.0))) + (x1 * 4.0))) / (t_0 / t_2)) + (x1 * (x1 * -6.0)))) + (x1 * (2.0 + (x1 * (x1 + (t_2 / (t_0 / 3.0))))))); else tmp = x1 * (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[(N[(x1 * 3.0), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(2.0 * x2), $MachinePrecision] + t$95$1), $MachinePrecision]}, If[LessEqual[x1, -5.5e+102], N[(x1 * N[(-1.0 + N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 1e+100], N[(N[(3.0 / N[(t$95$0 / N[(N[(x2 * -2.0), $MachinePrecision] + t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(t$95$0 * N[(N[(N[(x1 * N[(N[(-6.0 + N[(t$95$2 / N[(t$95$0 / 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x1 * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(t$95$0 / t$95$2), $MachinePrecision]), $MachinePrecision] + N[(x1 * N[(x1 * -6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x1 * N[(2.0 + N[(x1 * N[(x1 + N[(t$95$2 / N[(t$95$0 / 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 * N[(3.0 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 \cdot x1 + 1\\
t_1 := x1 \cdot \left(x1 \cdot 3 + -1\right)\\
t_2 := 2 \cdot x2 + t\_1\\
\mathbf{if}\;x1 \leq -5.5 \cdot 10^{+102}:\\
\;\;\;\;x1 \cdot \left(-1 + x1 \cdot \left(9 + x1 \cdot -19\right)\right)\\
\mathbf{elif}\;x1 \leq 10^{+100}:\\
\;\;\;\;\frac{3}{\frac{t\_0}{x2 \cdot -2 + t\_1}} + \left(t\_0 \cdot \left(\frac{x1 \cdot \left(\left(-6 + \frac{t\_2}{\frac{t\_0}{2}}\right) + x1 \cdot 4\right)}{\frac{t\_0}{t\_2}} + x1 \cdot \left(x1 \cdot -6\right)\right) + x1 \cdot \left(2 + x1 \cdot \left(x1 + \frac{t\_2}{\frac{t\_0}{3}}\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 \cdot \left(3 \cdot \left(x1 \cdot x1\right)\right)\\
\end{array}
\end{array}
if x1 < -5.49999999999999981e102Initial program 0.0%
Simplified0.0%
Taylor expanded in x1 around 0
Simplified76.5%
Taylor expanded in x2 around 0
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64100.0%
Simplified100.0%
if -5.49999999999999981e102 < x1 < 1.00000000000000002e100Initial program 99.4%
Simplified99.6%
Applied egg-rr99.7%
Applied egg-rr99.4%
if 1.00000000000000002e100 < x1 Initial program 34.1%
Simplified34.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f648.1%
Simplified8.1%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified88.6%
Taylor expanded in x1 around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6495.5%
Simplified95.5%
Final simplification98.8%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (* x1 (+ (* x1 3.0) -1.0)))
(t_1 (+ (* 2.0 x2) t_0))
(t_2 (+ (* x1 x1) 1.0)))
(if (<= x1 -5e+102)
(* x1 (+ -1.0 (* x1 (+ 9.0 (* x1 -19.0)))))
(if (<= x1 1e+100)
(+
(/ (* 3.0 (+ (* x2 -2.0) t_0)) t_2)
(+
(*
t_2
(+
(* x1 (* x1 -6.0))
(*
(/ t_1 t_2)
(+ (* x1 (+ -6.0 (* t_1 (/ 2.0 t_2)))) (* (* x1 x1) 4.0)))))
(* x1 (+ 2.0 (* x1 (+ x1 9.0))))))
(* x1 (* 3.0 (* x1 x1)))))))
double code(double x1, double x2) {
double t_0 = x1 * ((x1 * 3.0) + -1.0);
double t_1 = (2.0 * x2) + t_0;
double t_2 = (x1 * x1) + 1.0;
double tmp;
if (x1 <= -5e+102) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= 1e+100) {
tmp = ((3.0 * ((x2 * -2.0) + t_0)) / t_2) + ((t_2 * ((x1 * (x1 * -6.0)) + ((t_1 / t_2) * ((x1 * (-6.0 + (t_1 * (2.0 / t_2)))) + ((x1 * x1) * 4.0))))) + (x1 * (2.0 + (x1 * (x1 + 9.0)))));
} else {
tmp = x1 * (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) :: tmp
t_0 = x1 * ((x1 * 3.0d0) + (-1.0d0))
t_1 = (2.0d0 * x2) + t_0
t_2 = (x1 * x1) + 1.0d0
if (x1 <= (-5d+102)) then
tmp = x1 * ((-1.0d0) + (x1 * (9.0d0 + (x1 * (-19.0d0)))))
else if (x1 <= 1d+100) then
tmp = ((3.0d0 * ((x2 * (-2.0d0)) + t_0)) / t_2) + ((t_2 * ((x1 * (x1 * (-6.0d0))) + ((t_1 / t_2) * ((x1 * ((-6.0d0) + (t_1 * (2.0d0 / t_2)))) + ((x1 * x1) * 4.0d0))))) + (x1 * (2.0d0 + (x1 * (x1 + 9.0d0)))))
else
tmp = x1 * (3.0d0 * (x1 * x1))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = x1 * ((x1 * 3.0) + -1.0);
double t_1 = (2.0 * x2) + t_0;
double t_2 = (x1 * x1) + 1.0;
double tmp;
if (x1 <= -5e+102) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= 1e+100) {
tmp = ((3.0 * ((x2 * -2.0) + t_0)) / t_2) + ((t_2 * ((x1 * (x1 * -6.0)) + ((t_1 / t_2) * ((x1 * (-6.0 + (t_1 * (2.0 / t_2)))) + ((x1 * x1) * 4.0))))) + (x1 * (2.0 + (x1 * (x1 + 9.0)))));
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
def code(x1, x2): t_0 = x1 * ((x1 * 3.0) + -1.0) t_1 = (2.0 * x2) + t_0 t_2 = (x1 * x1) + 1.0 tmp = 0 if x1 <= -5e+102: tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))) elif x1 <= 1e+100: tmp = ((3.0 * ((x2 * -2.0) + t_0)) / t_2) + ((t_2 * ((x1 * (x1 * -6.0)) + ((t_1 / t_2) * ((x1 * (-6.0 + (t_1 * (2.0 / t_2)))) + ((x1 * x1) * 4.0))))) + (x1 * (2.0 + (x1 * (x1 + 9.0))))) else: tmp = x1 * (3.0 * (x1 * x1)) return tmp
function code(x1, x2) t_0 = Float64(x1 * Float64(Float64(x1 * 3.0) + -1.0)) t_1 = Float64(Float64(2.0 * x2) + t_0) t_2 = Float64(Float64(x1 * x1) + 1.0) tmp = 0.0 if (x1 <= -5e+102) tmp = Float64(x1 * Float64(-1.0 + Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))); elseif (x1 <= 1e+100) tmp = Float64(Float64(Float64(3.0 * Float64(Float64(x2 * -2.0) + t_0)) / t_2) + Float64(Float64(t_2 * Float64(Float64(x1 * Float64(x1 * -6.0)) + Float64(Float64(t_1 / t_2) * Float64(Float64(x1 * Float64(-6.0 + Float64(t_1 * Float64(2.0 / t_2)))) + Float64(Float64(x1 * x1) * 4.0))))) + Float64(x1 * Float64(2.0 + Float64(x1 * Float64(x1 + 9.0)))))); else tmp = Float64(x1 * Float64(3.0 * Float64(x1 * x1))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = x1 * ((x1 * 3.0) + -1.0); t_1 = (2.0 * x2) + t_0; t_2 = (x1 * x1) + 1.0; tmp = 0.0; if (x1 <= -5e+102) tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))); elseif (x1 <= 1e+100) tmp = ((3.0 * ((x2 * -2.0) + t_0)) / t_2) + ((t_2 * ((x1 * (x1 * -6.0)) + ((t_1 / t_2) * ((x1 * (-6.0 + (t_1 * (2.0 / t_2)))) + ((x1 * x1) * 4.0))))) + (x1 * (2.0 + (x1 * (x1 + 9.0))))); else tmp = x1 * (3.0 * (x1 * x1)); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(x1 * N[(N[(x1 * 3.0), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[(2.0 * x2), $MachinePrecision] + t$95$0), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x1 * x1), $MachinePrecision] + 1.0), $MachinePrecision]}, If[LessEqual[x1, -5e+102], N[(x1 * N[(-1.0 + N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 1e+100], N[(N[(N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] + t$95$0), $MachinePrecision]), $MachinePrecision] / t$95$2), $MachinePrecision] + N[(N[(t$95$2 * N[(N[(x1 * N[(x1 * -6.0), $MachinePrecision]), $MachinePrecision] + N[(N[(t$95$1 / t$95$2), $MachinePrecision] * N[(N[(x1 * N[(-6.0 + N[(t$95$1 * N[(2.0 / t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(x1 * x1), $MachinePrecision] * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x1 * N[(2.0 + N[(x1 * N[(x1 + 9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 * N[(3.0 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 \cdot \left(x1 \cdot 3 + -1\right)\\
t_1 := 2 \cdot x2 + t\_0\\
t_2 := x1 \cdot x1 + 1\\
\mathbf{if}\;x1 \leq -5 \cdot 10^{+102}:\\
\;\;\;\;x1 \cdot \left(-1 + x1 \cdot \left(9 + x1 \cdot -19\right)\right)\\
\mathbf{elif}\;x1 \leq 10^{+100}:\\
\;\;\;\;\frac{3 \cdot \left(x2 \cdot -2 + t\_0\right)}{t\_2} + \left(t\_2 \cdot \left(x1 \cdot \left(x1 \cdot -6\right) + \frac{t\_1}{t\_2} \cdot \left(x1 \cdot \left(-6 + t\_1 \cdot \frac{2}{t\_2}\right) + \left(x1 \cdot x1\right) \cdot 4\right)\right) + x1 \cdot \left(2 + x1 \cdot \left(x1 + 9\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 \cdot \left(3 \cdot \left(x1 \cdot x1\right)\right)\\
\end{array}
\end{array}
if x1 < -5e102Initial program 0.0%
Simplified0.0%
Taylor expanded in x1 around 0
Simplified76.5%
Taylor expanded in x2 around 0
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64100.0%
Simplified100.0%
if -5e102 < x1 < 1.00000000000000002e100Initial program 99.4%
Simplified99.6%
Taylor expanded in x1 around inf
Simplified99.0%
if 1.00000000000000002e100 < x1 Initial program 34.1%
Simplified34.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f648.1%
Simplified8.1%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified88.6%
Taylor expanded in x1 around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6495.5%
Simplified95.5%
Final simplification98.5%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (+ (* x1 x1) 1.0))
(t_1 (* x1 (+ (* x1 3.0) -1.0)))
(t_2 (+ (* 2.0 x2) t_1))
(t_3 (+ (* x2 -2.0) t_1))
(t_4 (/ (* 3.0 t_3) t_0)))
(if (<= x1 -4.4e+102)
(* x1 (+ -1.0 (* x1 (+ 9.0 (* x1 -19.0)))))
(if (<= x1 -9.2e+21)
(+
(/ 3.0 (/ t_0 t_3))
(+
(* x1 (+ 2.0 (* x1 (+ x1 (/ t_2 (/ t_0 3.0))))))
(*
t_0
(+
(* x1 (* x1 -6.0))
(/ (* x1 (+ (* x1 4.0) (/ -2.0 x1))) (/ t_0 t_2))))))
(if (<= x1 1.35e+42)
(+ t_4 (+ (* x1 2.0) (* x2 (+ (* x1 -12.0) (* x2 (* x1 8.0))))))
(if (<= x1 4e+102)
(+
t_4
(+
(* x1 (+ 2.0 (* x1 (+ x1 (* t_2 (/ 3.0 t_0))))))
(*
t_0
(*
(* x1 x1)
(+ 6.0 (/ (- (/ (+ (* x2 8.0) -18.0) x1) 4.0) x1))))))
(* x1 (* 3.0 (* x1 x1)))))))))
double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = x1 * ((x1 * 3.0) + -1.0);
double t_2 = (2.0 * x2) + t_1;
double t_3 = (x2 * -2.0) + t_1;
double t_4 = (3.0 * t_3) / t_0;
double tmp;
if (x1 <= -4.4e+102) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= -9.2e+21) {
tmp = (3.0 / (t_0 / t_3)) + ((x1 * (2.0 + (x1 * (x1 + (t_2 / (t_0 / 3.0)))))) + (t_0 * ((x1 * (x1 * -6.0)) + ((x1 * ((x1 * 4.0) + (-2.0 / x1))) / (t_0 / t_2)))));
} else if (x1 <= 1.35e+42) {
tmp = t_4 + ((x1 * 2.0) + (x2 * ((x1 * -12.0) + (x2 * (x1 * 8.0)))));
} else if (x1 <= 4e+102) {
tmp = t_4 + ((x1 * (2.0 + (x1 * (x1 + (t_2 * (3.0 / t_0)))))) + (t_0 * ((x1 * x1) * (6.0 + (((((x2 * 8.0) + -18.0) / x1) - 4.0) / x1)))));
} else {
tmp = x1 * (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) :: t_4
real(8) :: tmp
t_0 = (x1 * x1) + 1.0d0
t_1 = x1 * ((x1 * 3.0d0) + (-1.0d0))
t_2 = (2.0d0 * x2) + t_1
t_3 = (x2 * (-2.0d0)) + t_1
t_4 = (3.0d0 * t_3) / t_0
if (x1 <= (-4.4d+102)) then
tmp = x1 * ((-1.0d0) + (x1 * (9.0d0 + (x1 * (-19.0d0)))))
else if (x1 <= (-9.2d+21)) then
tmp = (3.0d0 / (t_0 / t_3)) + ((x1 * (2.0d0 + (x1 * (x1 + (t_2 / (t_0 / 3.0d0)))))) + (t_0 * ((x1 * (x1 * (-6.0d0))) + ((x1 * ((x1 * 4.0d0) + ((-2.0d0) / x1))) / (t_0 / t_2)))))
else if (x1 <= 1.35d+42) then
tmp = t_4 + ((x1 * 2.0d0) + (x2 * ((x1 * (-12.0d0)) + (x2 * (x1 * 8.0d0)))))
else if (x1 <= 4d+102) then
tmp = t_4 + ((x1 * (2.0d0 + (x1 * (x1 + (t_2 * (3.0d0 / t_0)))))) + (t_0 * ((x1 * x1) * (6.0d0 + (((((x2 * 8.0d0) + (-18.0d0)) / x1) - 4.0d0) / x1)))))
else
tmp = x1 * (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) + -1.0);
double t_2 = (2.0 * x2) + t_1;
double t_3 = (x2 * -2.0) + t_1;
double t_4 = (3.0 * t_3) / t_0;
double tmp;
if (x1 <= -4.4e+102) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= -9.2e+21) {
tmp = (3.0 / (t_0 / t_3)) + ((x1 * (2.0 + (x1 * (x1 + (t_2 / (t_0 / 3.0)))))) + (t_0 * ((x1 * (x1 * -6.0)) + ((x1 * ((x1 * 4.0) + (-2.0 / x1))) / (t_0 / t_2)))));
} else if (x1 <= 1.35e+42) {
tmp = t_4 + ((x1 * 2.0) + (x2 * ((x1 * -12.0) + (x2 * (x1 * 8.0)))));
} else if (x1 <= 4e+102) {
tmp = t_4 + ((x1 * (2.0 + (x1 * (x1 + (t_2 * (3.0 / t_0)))))) + (t_0 * ((x1 * x1) * (6.0 + (((((x2 * 8.0) + -18.0) / x1) - 4.0) / x1)))));
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
def code(x1, x2): t_0 = (x1 * x1) + 1.0 t_1 = x1 * ((x1 * 3.0) + -1.0) t_2 = (2.0 * x2) + t_1 t_3 = (x2 * -2.0) + t_1 t_4 = (3.0 * t_3) / t_0 tmp = 0 if x1 <= -4.4e+102: tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))) elif x1 <= -9.2e+21: tmp = (3.0 / (t_0 / t_3)) + ((x1 * (2.0 + (x1 * (x1 + (t_2 / (t_0 / 3.0)))))) + (t_0 * ((x1 * (x1 * -6.0)) + ((x1 * ((x1 * 4.0) + (-2.0 / x1))) / (t_0 / t_2))))) elif x1 <= 1.35e+42: tmp = t_4 + ((x1 * 2.0) + (x2 * ((x1 * -12.0) + (x2 * (x1 * 8.0))))) elif x1 <= 4e+102: tmp = t_4 + ((x1 * (2.0 + (x1 * (x1 + (t_2 * (3.0 / t_0)))))) + (t_0 * ((x1 * x1) * (6.0 + (((((x2 * 8.0) + -18.0) / x1) - 4.0) / x1))))) else: tmp = x1 * (3.0 * (x1 * x1)) return tmp
function code(x1, x2) t_0 = Float64(Float64(x1 * x1) + 1.0) t_1 = Float64(x1 * Float64(Float64(x1 * 3.0) + -1.0)) t_2 = Float64(Float64(2.0 * x2) + t_1) t_3 = Float64(Float64(x2 * -2.0) + t_1) t_4 = Float64(Float64(3.0 * t_3) / t_0) tmp = 0.0 if (x1 <= -4.4e+102) tmp = Float64(x1 * Float64(-1.0 + Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))); elseif (x1 <= -9.2e+21) tmp = Float64(Float64(3.0 / Float64(t_0 / t_3)) + Float64(Float64(x1 * Float64(2.0 + Float64(x1 * Float64(x1 + Float64(t_2 / Float64(t_0 / 3.0)))))) + Float64(t_0 * Float64(Float64(x1 * Float64(x1 * -6.0)) + Float64(Float64(x1 * Float64(Float64(x1 * 4.0) + Float64(-2.0 / x1))) / Float64(t_0 / t_2)))))); elseif (x1 <= 1.35e+42) tmp = Float64(t_4 + Float64(Float64(x1 * 2.0) + Float64(x2 * Float64(Float64(x1 * -12.0) + Float64(x2 * Float64(x1 * 8.0)))))); elseif (x1 <= 4e+102) tmp = Float64(t_4 + Float64(Float64(x1 * Float64(2.0 + Float64(x1 * Float64(x1 + Float64(t_2 * Float64(3.0 / t_0)))))) + Float64(t_0 * Float64(Float64(x1 * x1) * Float64(6.0 + Float64(Float64(Float64(Float64(Float64(x2 * 8.0) + -18.0) / x1) - 4.0) / x1)))))); else tmp = Float64(x1 * Float64(3.0 * Float64(x1 * x1))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = (x1 * x1) + 1.0; t_1 = x1 * ((x1 * 3.0) + -1.0); t_2 = (2.0 * x2) + t_1; t_3 = (x2 * -2.0) + t_1; t_4 = (3.0 * t_3) / t_0; tmp = 0.0; if (x1 <= -4.4e+102) tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))); elseif (x1 <= -9.2e+21) tmp = (3.0 / (t_0 / t_3)) + ((x1 * (2.0 + (x1 * (x1 + (t_2 / (t_0 / 3.0)))))) + (t_0 * ((x1 * (x1 * -6.0)) + ((x1 * ((x1 * 4.0) + (-2.0 / x1))) / (t_0 / t_2))))); elseif (x1 <= 1.35e+42) tmp = t_4 + ((x1 * 2.0) + (x2 * ((x1 * -12.0) + (x2 * (x1 * 8.0))))); elseif (x1 <= 4e+102) tmp = t_4 + ((x1 * (2.0 + (x1 * (x1 + (t_2 * (3.0 / t_0)))))) + (t_0 * ((x1 * x1) * (6.0 + (((((x2 * 8.0) + -18.0) / x1) - 4.0) / x1))))); else tmp = x1 * (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[(N[(x1 * 3.0), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(2.0 * x2), $MachinePrecision] + t$95$1), $MachinePrecision]}, Block[{t$95$3 = N[(N[(x2 * -2.0), $MachinePrecision] + t$95$1), $MachinePrecision]}, Block[{t$95$4 = N[(N[(3.0 * t$95$3), $MachinePrecision] / t$95$0), $MachinePrecision]}, If[LessEqual[x1, -4.4e+102], N[(x1 * N[(-1.0 + N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -9.2e+21], N[(N[(3.0 / N[(t$95$0 / t$95$3), $MachinePrecision]), $MachinePrecision] + N[(N[(x1 * N[(2.0 + N[(x1 * N[(x1 + N[(t$95$2 / N[(t$95$0 / 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(t$95$0 * N[(N[(x1 * N[(x1 * -6.0), $MachinePrecision]), $MachinePrecision] + N[(N[(x1 * N[(N[(x1 * 4.0), $MachinePrecision] + N[(-2.0 / x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(t$95$0 / t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 1.35e+42], N[(t$95$4 + N[(N[(x1 * 2.0), $MachinePrecision] + N[(x2 * N[(N[(x1 * -12.0), $MachinePrecision] + N[(x2 * N[(x1 * 8.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 4e+102], N[(t$95$4 + N[(N[(x1 * N[(2.0 + N[(x1 * N[(x1 + N[(t$95$2 * N[(3.0 / t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(t$95$0 * N[(N[(x1 * x1), $MachinePrecision] * N[(6.0 + N[(N[(N[(N[(N[(x2 * 8.0), $MachinePrecision] + -18.0), $MachinePrecision] / x1), $MachinePrecision] - 4.0), $MachinePrecision] / x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 * N[(3.0 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 \cdot x1 + 1\\
t_1 := x1 \cdot \left(x1 \cdot 3 + -1\right)\\
t_2 := 2 \cdot x2 + t\_1\\
t_3 := x2 \cdot -2 + t\_1\\
t_4 := \frac{3 \cdot t\_3}{t\_0}\\
\mathbf{if}\;x1 \leq -4.4 \cdot 10^{+102}:\\
\;\;\;\;x1 \cdot \left(-1 + x1 \cdot \left(9 + x1 \cdot -19\right)\right)\\
\mathbf{elif}\;x1 \leq -9.2 \cdot 10^{+21}:\\
\;\;\;\;\frac{3}{\frac{t\_0}{t\_3}} + \left(x1 \cdot \left(2 + x1 \cdot \left(x1 + \frac{t\_2}{\frac{t\_0}{3}}\right)\right) + t\_0 \cdot \left(x1 \cdot \left(x1 \cdot -6\right) + \frac{x1 \cdot \left(x1 \cdot 4 + \frac{-2}{x1}\right)}{\frac{t\_0}{t\_2}}\right)\right)\\
\mathbf{elif}\;x1 \leq 1.35 \cdot 10^{+42}:\\
\;\;\;\;t\_4 + \left(x1 \cdot 2 + x2 \cdot \left(x1 \cdot -12 + x2 \cdot \left(x1 \cdot 8\right)\right)\right)\\
\mathbf{elif}\;x1 \leq 4 \cdot 10^{+102}:\\
\;\;\;\;t\_4 + \left(x1 \cdot \left(2 + x1 \cdot \left(x1 + t\_2 \cdot \frac{3}{t\_0}\right)\right) + t\_0 \cdot \left(\left(x1 \cdot x1\right) \cdot \left(6 + \frac{\frac{x2 \cdot 8 + -18}{x1} - 4}{x1}\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 \cdot \left(3 \cdot \left(x1 \cdot x1\right)\right)\\
\end{array}
\end{array}
if x1 < -4.40000000000000015e102Initial program 0.0%
Simplified0.0%
Taylor expanded in x1 around 0
Simplified76.5%
Taylor expanded in x2 around 0
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64100.0%
Simplified100.0%
if -4.40000000000000015e102 < x1 < -9.2e21Initial program 99.6%
Simplified99.8%
Applied egg-rr99.5%
Applied egg-rr99.9%
Taylor expanded in x1 around inf
/-lowering-/.f6495.7%
Simplified95.7%
if -9.2e21 < x1 < 1.35e42Initial program 99.4%
Simplified99.5%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6488.6%
Simplified88.6%
Taylor expanded in x2 around 0
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6495.7%
Simplified95.7%
if 1.35e42 < x1 < 3.99999999999999991e102Initial program 99.0%
Simplified99.2%
Taylor expanded in x1 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
mul-1-negN/A
unsub-negN/A
--lowering--.f64N/A
/-lowering-/.f64N/A
mul-1-negN/A
unsub-negN/A
--lowering--.f64N/A
/-lowering-/.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
metadata-eval99.4%
Simplified99.4%
if 3.99999999999999991e102 < x1 Initial program 34.1%
Simplified34.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f648.1%
Simplified8.1%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified88.6%
Taylor expanded in x1 around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6495.5%
Simplified95.5%
Final simplification96.4%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (* x1 (+ (* x1 3.0) -1.0)))
(t_1 (+ (* x1 x1) 1.0))
(t_2 (/ (* 3.0 (+ (* x2 -2.0) t_0)) t_1))
(t_3
(+
t_2
(+
(* x1 (+ 2.0 (* x1 (+ x1 (* (+ (* 2.0 x2) t_0) (/ 3.0 t_1))))))
(*
t_1
(*
(* x1 x1)
(+ 6.0 (/ (- (/ (+ (* x2 8.0) -18.0) x1) 4.0) x1))))))))
(if (<= x1 -5.6e+102)
(* x1 (+ -1.0 (* x1 (+ 9.0 (* x1 -19.0)))))
(if (<= x1 -9.2e+21)
t_3
(if (<= x1 1.35e+42)
(+ t_2 (+ (* x1 2.0) (* x2 (+ (* x1 -12.0) (* x2 (* x1 8.0))))))
(if (<= x1 1e+100) t_3 (* x1 (* 3.0 (* x1 x1)))))))))
double code(double x1, double x2) {
double t_0 = x1 * ((x1 * 3.0) + -1.0);
double t_1 = (x1 * x1) + 1.0;
double t_2 = (3.0 * ((x2 * -2.0) + t_0)) / t_1;
double t_3 = t_2 + ((x1 * (2.0 + (x1 * (x1 + (((2.0 * x2) + t_0) * (3.0 / t_1)))))) + (t_1 * ((x1 * x1) * (6.0 + (((((x2 * 8.0) + -18.0) / x1) - 4.0) / x1)))));
double tmp;
if (x1 <= -5.6e+102) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= -9.2e+21) {
tmp = t_3;
} else if (x1 <= 1.35e+42) {
tmp = t_2 + ((x1 * 2.0) + (x2 * ((x1 * -12.0) + (x2 * (x1 * 8.0)))));
} else if (x1 <= 1e+100) {
tmp = t_3;
} else {
tmp = x1 * (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 * 3.0d0) + (-1.0d0))
t_1 = (x1 * x1) + 1.0d0
t_2 = (3.0d0 * ((x2 * (-2.0d0)) + t_0)) / t_1
t_3 = t_2 + ((x1 * (2.0d0 + (x1 * (x1 + (((2.0d0 * x2) + t_0) * (3.0d0 / t_1)))))) + (t_1 * ((x1 * x1) * (6.0d0 + (((((x2 * 8.0d0) + (-18.0d0)) / x1) - 4.0d0) / x1)))))
if (x1 <= (-5.6d+102)) then
tmp = x1 * ((-1.0d0) + (x1 * (9.0d0 + (x1 * (-19.0d0)))))
else if (x1 <= (-9.2d+21)) then
tmp = t_3
else if (x1 <= 1.35d+42) then
tmp = t_2 + ((x1 * 2.0d0) + (x2 * ((x1 * (-12.0d0)) + (x2 * (x1 * 8.0d0)))))
else if (x1 <= 1d+100) then
tmp = t_3
else
tmp = x1 * (3.0d0 * (x1 * x1))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = x1 * ((x1 * 3.0) + -1.0);
double t_1 = (x1 * x1) + 1.0;
double t_2 = (3.0 * ((x2 * -2.0) + t_0)) / t_1;
double t_3 = t_2 + ((x1 * (2.0 + (x1 * (x1 + (((2.0 * x2) + t_0) * (3.0 / t_1)))))) + (t_1 * ((x1 * x1) * (6.0 + (((((x2 * 8.0) + -18.0) / x1) - 4.0) / x1)))));
double tmp;
if (x1 <= -5.6e+102) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= -9.2e+21) {
tmp = t_3;
} else if (x1 <= 1.35e+42) {
tmp = t_2 + ((x1 * 2.0) + (x2 * ((x1 * -12.0) + (x2 * (x1 * 8.0)))));
} else if (x1 <= 1e+100) {
tmp = t_3;
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
def code(x1, x2): t_0 = x1 * ((x1 * 3.0) + -1.0) t_1 = (x1 * x1) + 1.0 t_2 = (3.0 * ((x2 * -2.0) + t_0)) / t_1 t_3 = t_2 + ((x1 * (2.0 + (x1 * (x1 + (((2.0 * x2) + t_0) * (3.0 / t_1)))))) + (t_1 * ((x1 * x1) * (6.0 + (((((x2 * 8.0) + -18.0) / x1) - 4.0) / x1))))) tmp = 0 if x1 <= -5.6e+102: tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))) elif x1 <= -9.2e+21: tmp = t_3 elif x1 <= 1.35e+42: tmp = t_2 + ((x1 * 2.0) + (x2 * ((x1 * -12.0) + (x2 * (x1 * 8.0))))) elif x1 <= 1e+100: tmp = t_3 else: tmp = x1 * (3.0 * (x1 * x1)) return tmp
function code(x1, x2) t_0 = Float64(x1 * Float64(Float64(x1 * 3.0) + -1.0)) t_1 = Float64(Float64(x1 * x1) + 1.0) t_2 = Float64(Float64(3.0 * Float64(Float64(x2 * -2.0) + t_0)) / t_1) t_3 = Float64(t_2 + Float64(Float64(x1 * Float64(2.0 + Float64(x1 * Float64(x1 + Float64(Float64(Float64(2.0 * x2) + t_0) * Float64(3.0 / t_1)))))) + Float64(t_1 * Float64(Float64(x1 * x1) * Float64(6.0 + Float64(Float64(Float64(Float64(Float64(x2 * 8.0) + -18.0) / x1) - 4.0) / x1)))))) tmp = 0.0 if (x1 <= -5.6e+102) tmp = Float64(x1 * Float64(-1.0 + Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))); elseif (x1 <= -9.2e+21) tmp = t_3; elseif (x1 <= 1.35e+42) tmp = Float64(t_2 + Float64(Float64(x1 * 2.0) + Float64(x2 * Float64(Float64(x1 * -12.0) + Float64(x2 * Float64(x1 * 8.0)))))); elseif (x1 <= 1e+100) tmp = t_3; else tmp = Float64(x1 * Float64(3.0 * Float64(x1 * x1))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = x1 * ((x1 * 3.0) + -1.0); t_1 = (x1 * x1) + 1.0; t_2 = (3.0 * ((x2 * -2.0) + t_0)) / t_1; t_3 = t_2 + ((x1 * (2.0 + (x1 * (x1 + (((2.0 * x2) + t_0) * (3.0 / t_1)))))) + (t_1 * ((x1 * x1) * (6.0 + (((((x2 * 8.0) + -18.0) / x1) - 4.0) / x1))))); tmp = 0.0; if (x1 <= -5.6e+102) tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))); elseif (x1 <= -9.2e+21) tmp = t_3; elseif (x1 <= 1.35e+42) tmp = t_2 + ((x1 * 2.0) + (x2 * ((x1 * -12.0) + (x2 * (x1 * 8.0))))); elseif (x1 <= 1e+100) tmp = t_3; else tmp = x1 * (3.0 * (x1 * x1)); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(x1 * N[(N[(x1 * 3.0), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[(x1 * x1), $MachinePrecision] + 1.0), $MachinePrecision]}, Block[{t$95$2 = N[(N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] + t$95$0), $MachinePrecision]), $MachinePrecision] / t$95$1), $MachinePrecision]}, Block[{t$95$3 = N[(t$95$2 + N[(N[(x1 * N[(2.0 + N[(x1 * N[(x1 + N[(N[(N[(2.0 * x2), $MachinePrecision] + t$95$0), $MachinePrecision] * N[(3.0 / t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(t$95$1 * N[(N[(x1 * x1), $MachinePrecision] * N[(6.0 + N[(N[(N[(N[(N[(x2 * 8.0), $MachinePrecision] + -18.0), $MachinePrecision] / x1), $MachinePrecision] - 4.0), $MachinePrecision] / x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -5.6e+102], N[(x1 * N[(-1.0 + N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -9.2e+21], t$95$3, If[LessEqual[x1, 1.35e+42], N[(t$95$2 + N[(N[(x1 * 2.0), $MachinePrecision] + N[(x2 * N[(N[(x1 * -12.0), $MachinePrecision] + N[(x2 * N[(x1 * 8.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 1e+100], t$95$3, N[(x1 * N[(3.0 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 \cdot \left(x1 \cdot 3 + -1\right)\\
t_1 := x1 \cdot x1 + 1\\
t_2 := \frac{3 \cdot \left(x2 \cdot -2 + t\_0\right)}{t\_1}\\
t_3 := t\_2 + \left(x1 \cdot \left(2 + x1 \cdot \left(x1 + \left(2 \cdot x2 + t\_0\right) \cdot \frac{3}{t\_1}\right)\right) + t\_1 \cdot \left(\left(x1 \cdot x1\right) \cdot \left(6 + \frac{\frac{x2 \cdot 8 + -18}{x1} - 4}{x1}\right)\right)\right)\\
\mathbf{if}\;x1 \leq -5.6 \cdot 10^{+102}:\\
\;\;\;\;x1 \cdot \left(-1 + x1 \cdot \left(9 + x1 \cdot -19\right)\right)\\
\mathbf{elif}\;x1 \leq -9.2 \cdot 10^{+21}:\\
\;\;\;\;t\_3\\
\mathbf{elif}\;x1 \leq 1.35 \cdot 10^{+42}:\\
\;\;\;\;t\_2 + \left(x1 \cdot 2 + x2 \cdot \left(x1 \cdot -12 + x2 \cdot \left(x1 \cdot 8\right)\right)\right)\\
\mathbf{elif}\;x1 \leq 10^{+100}:\\
\;\;\;\;t\_3\\
\mathbf{else}:\\
\;\;\;\;x1 \cdot \left(3 \cdot \left(x1 \cdot x1\right)\right)\\
\end{array}
\end{array}
if x1 < -5.60000000000000037e102Initial program 0.0%
Simplified0.0%
Taylor expanded in x1 around 0
Simplified76.5%
Taylor expanded in x2 around 0
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64100.0%
Simplified100.0%
if -5.60000000000000037e102 < x1 < -9.2e21 or 1.35e42 < x1 < 1.00000000000000002e100Initial program 99.4%
Simplified99.6%
Taylor expanded in x1 around -inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
mul-1-negN/A
unsub-negN/A
--lowering--.f64N/A
/-lowering-/.f64N/A
mul-1-negN/A
unsub-negN/A
--lowering--.f64N/A
/-lowering-/.f64N/A
sub-negN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
metadata-eval96.4%
Simplified96.4%
if -9.2e21 < x1 < 1.35e42Initial program 99.4%
Simplified99.5%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6488.6%
Simplified88.6%
Taylor expanded in x2 around 0
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6495.7%
Simplified95.7%
if 1.00000000000000002e100 < x1 Initial program 34.1%
Simplified34.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f648.1%
Simplified8.1%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified88.6%
Taylor expanded in x1 around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6495.5%
Simplified95.5%
Final simplification96.3%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (+ (* x1 x1) 1.0))
(t_1 (* x1 (+ (* x1 3.0) -1.0)))
(t_2 (+ (* x2 -2.0) t_1))
(t_3
(+
(/ 3.0 (/ t_0 t_2))
(+
(* x1 (+ 2.0 (* x1 (+ x1 (/ (+ (* 2.0 x2) t_1) (/ t_0 3.0))))))
(* t_0 (* (* x1 x1) 6.0))))))
(if (<= x1 -5e+102)
(* x1 (+ -1.0 (* x1 (+ 9.0 (* x1 -19.0)))))
(if (<= x1 -9.2e+21)
t_3
(if (<= x1 1.35e+42)
(+
(/ (* 3.0 t_2) t_0)
(+ (* x1 2.0) (* x2 (+ (* x1 -12.0) (* x2 (* x1 8.0))))))
(if (<= x1 1e+100) t_3 (* x1 (* 3.0 (* x1 x1)))))))))
double code(double x1, double x2) {
double t_0 = (x1 * x1) + 1.0;
double t_1 = x1 * ((x1 * 3.0) + -1.0);
double t_2 = (x2 * -2.0) + t_1;
double t_3 = (3.0 / (t_0 / t_2)) + ((x1 * (2.0 + (x1 * (x1 + (((2.0 * x2) + t_1) / (t_0 / 3.0)))))) + (t_0 * ((x1 * x1) * 6.0)));
double tmp;
if (x1 <= -5e+102) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= -9.2e+21) {
tmp = t_3;
} else if (x1 <= 1.35e+42) {
tmp = ((3.0 * t_2) / t_0) + ((x1 * 2.0) + (x2 * ((x1 * -12.0) + (x2 * (x1 * 8.0)))));
} else if (x1 <= 1e+100) {
tmp = t_3;
} else {
tmp = x1 * (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) + (-1.0d0))
t_2 = (x2 * (-2.0d0)) + t_1
t_3 = (3.0d0 / (t_0 / t_2)) + ((x1 * (2.0d0 + (x1 * (x1 + (((2.0d0 * x2) + t_1) / (t_0 / 3.0d0)))))) + (t_0 * ((x1 * x1) * 6.0d0)))
if (x1 <= (-5d+102)) then
tmp = x1 * ((-1.0d0) + (x1 * (9.0d0 + (x1 * (-19.0d0)))))
else if (x1 <= (-9.2d+21)) then
tmp = t_3
else if (x1 <= 1.35d+42) then
tmp = ((3.0d0 * t_2) / t_0) + ((x1 * 2.0d0) + (x2 * ((x1 * (-12.0d0)) + (x2 * (x1 * 8.0d0)))))
else if (x1 <= 1d+100) then
tmp = t_3
else
tmp = x1 * (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) + -1.0);
double t_2 = (x2 * -2.0) + t_1;
double t_3 = (3.0 / (t_0 / t_2)) + ((x1 * (2.0 + (x1 * (x1 + (((2.0 * x2) + t_1) / (t_0 / 3.0)))))) + (t_0 * ((x1 * x1) * 6.0)));
double tmp;
if (x1 <= -5e+102) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= -9.2e+21) {
tmp = t_3;
} else if (x1 <= 1.35e+42) {
tmp = ((3.0 * t_2) / t_0) + ((x1 * 2.0) + (x2 * ((x1 * -12.0) + (x2 * (x1 * 8.0)))));
} else if (x1 <= 1e+100) {
tmp = t_3;
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
def code(x1, x2): t_0 = (x1 * x1) + 1.0 t_1 = x1 * ((x1 * 3.0) + -1.0) t_2 = (x2 * -2.0) + t_1 t_3 = (3.0 / (t_0 / t_2)) + ((x1 * (2.0 + (x1 * (x1 + (((2.0 * x2) + t_1) / (t_0 / 3.0)))))) + (t_0 * ((x1 * x1) * 6.0))) tmp = 0 if x1 <= -5e+102: tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))) elif x1 <= -9.2e+21: tmp = t_3 elif x1 <= 1.35e+42: tmp = ((3.0 * t_2) / t_0) + ((x1 * 2.0) + (x2 * ((x1 * -12.0) + (x2 * (x1 * 8.0))))) elif x1 <= 1e+100: tmp = t_3 else: tmp = x1 * (3.0 * (x1 * x1)) return tmp
function code(x1, x2) t_0 = Float64(Float64(x1 * x1) + 1.0) t_1 = Float64(x1 * Float64(Float64(x1 * 3.0) + -1.0)) t_2 = Float64(Float64(x2 * -2.0) + t_1) t_3 = Float64(Float64(3.0 / Float64(t_0 / t_2)) + Float64(Float64(x1 * Float64(2.0 + Float64(x1 * Float64(x1 + Float64(Float64(Float64(2.0 * x2) + t_1) / Float64(t_0 / 3.0)))))) + Float64(t_0 * Float64(Float64(x1 * x1) * 6.0)))) tmp = 0.0 if (x1 <= -5e+102) tmp = Float64(x1 * Float64(-1.0 + Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))); elseif (x1 <= -9.2e+21) tmp = t_3; elseif (x1 <= 1.35e+42) tmp = Float64(Float64(Float64(3.0 * t_2) / t_0) + Float64(Float64(x1 * 2.0) + Float64(x2 * Float64(Float64(x1 * -12.0) + Float64(x2 * Float64(x1 * 8.0)))))); elseif (x1 <= 1e+100) tmp = t_3; else tmp = Float64(x1 * Float64(3.0 * Float64(x1 * x1))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = (x1 * x1) + 1.0; t_1 = x1 * ((x1 * 3.0) + -1.0); t_2 = (x2 * -2.0) + t_1; t_3 = (3.0 / (t_0 / t_2)) + ((x1 * (2.0 + (x1 * (x1 + (((2.0 * x2) + t_1) / (t_0 / 3.0)))))) + (t_0 * ((x1 * x1) * 6.0))); tmp = 0.0; if (x1 <= -5e+102) tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))); elseif (x1 <= -9.2e+21) tmp = t_3; elseif (x1 <= 1.35e+42) tmp = ((3.0 * t_2) / t_0) + ((x1 * 2.0) + (x2 * ((x1 * -12.0) + (x2 * (x1 * 8.0))))); elseif (x1 <= 1e+100) tmp = t_3; else tmp = x1 * (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[(N[(x1 * 3.0), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x2 * -2.0), $MachinePrecision] + t$95$1), $MachinePrecision]}, Block[{t$95$3 = N[(N[(3.0 / N[(t$95$0 / t$95$2), $MachinePrecision]), $MachinePrecision] + N[(N[(x1 * N[(2.0 + N[(x1 * N[(x1 + N[(N[(N[(2.0 * x2), $MachinePrecision] + t$95$1), $MachinePrecision] / N[(t$95$0 / 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(t$95$0 * N[(N[(x1 * x1), $MachinePrecision] * 6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -5e+102], N[(x1 * N[(-1.0 + N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -9.2e+21], t$95$3, If[LessEqual[x1, 1.35e+42], N[(N[(N[(3.0 * t$95$2), $MachinePrecision] / t$95$0), $MachinePrecision] + N[(N[(x1 * 2.0), $MachinePrecision] + N[(x2 * N[(N[(x1 * -12.0), $MachinePrecision] + N[(x2 * N[(x1 * 8.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 1e+100], t$95$3, N[(x1 * N[(3.0 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 \cdot x1 + 1\\
t_1 := x1 \cdot \left(x1 \cdot 3 + -1\right)\\
t_2 := x2 \cdot -2 + t\_1\\
t_3 := \frac{3}{\frac{t\_0}{t\_2}} + \left(x1 \cdot \left(2 + x1 \cdot \left(x1 + \frac{2 \cdot x2 + t\_1}{\frac{t\_0}{3}}\right)\right) + t\_0 \cdot \left(\left(x1 \cdot x1\right) \cdot 6\right)\right)\\
\mathbf{if}\;x1 \leq -5 \cdot 10^{+102}:\\
\;\;\;\;x1 \cdot \left(-1 + x1 \cdot \left(9 + x1 \cdot -19\right)\right)\\
\mathbf{elif}\;x1 \leq -9.2 \cdot 10^{+21}:\\
\;\;\;\;t\_3\\
\mathbf{elif}\;x1 \leq 1.35 \cdot 10^{+42}:\\
\;\;\;\;\frac{3 \cdot t\_2}{t\_0} + \left(x1 \cdot 2 + x2 \cdot \left(x1 \cdot -12 + x2 \cdot \left(x1 \cdot 8\right)\right)\right)\\
\mathbf{elif}\;x1 \leq 10^{+100}:\\
\;\;\;\;t\_3\\
\mathbf{else}:\\
\;\;\;\;x1 \cdot \left(3 \cdot \left(x1 \cdot x1\right)\right)\\
\end{array}
\end{array}
if x1 < -5e102Initial program 0.0%
Simplified0.0%
Taylor expanded in x1 around 0
Simplified76.5%
Taylor expanded in x2 around 0
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64100.0%
Simplified100.0%
if -5e102 < x1 < -9.2e21 or 1.35e42 < x1 < 1.00000000000000002e100Initial program 99.4%
Simplified99.6%
Applied egg-rr99.4%
Applied egg-rr99.7%
Taylor expanded in x1 around inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6475.9%
Simplified75.9%
if -9.2e21 < x1 < 1.35e42Initial program 99.4%
Simplified99.5%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6488.6%
Simplified88.6%
Taylor expanded in x2 around 0
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6495.7%
Simplified95.7%
if 1.00000000000000002e100 < x1 Initial program 34.1%
Simplified34.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f648.1%
Simplified8.1%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified88.6%
Taylor expanded in x1 around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6495.5%
Simplified95.5%
Final simplification93.8%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (* x1 (* x1 x1))))
(if (<= x1 -6.2e+78)
(* t_0 (+ (* 4.0 (* x2 (+ 3.0 (* x2 -2.0)))) (+ -19.0 (* x2 12.0))))
(if (<= x1 2.5e+17)
(+
(/
(* 3.0 (+ (* x2 -2.0) (* x1 (+ (* x1 3.0) -1.0))))
(+ (* x1 x1) 1.0))
(+ (* x1 2.0) (* x2 (+ (* x1 -12.0) (* x2 (* x1 8.0))))))
(*
t_0
(-
(/
(+
(+ 9.0 (* x2 6.0))
(/ (+ -1.0 (* (* 2.0 x2) (+ -6.0 (* x2 4.0)))) x1))
x1)
-3.0))))))
double code(double x1, double x2) {
double t_0 = x1 * (x1 * x1);
double tmp;
if (x1 <= -6.2e+78) {
tmp = t_0 * ((4.0 * (x2 * (3.0 + (x2 * -2.0)))) + (-19.0 + (x2 * 12.0)));
} else if (x1 <= 2.5e+17) {
tmp = ((3.0 * ((x2 * -2.0) + (x1 * ((x1 * 3.0) + -1.0)))) / ((x1 * x1) + 1.0)) + ((x1 * 2.0) + (x2 * ((x1 * -12.0) + (x2 * (x1 * 8.0)))));
} else {
tmp = t_0 * ((((9.0 + (x2 * 6.0)) + ((-1.0 + ((2.0 * x2) * (-6.0 + (x2 * 4.0)))) / x1)) / x1) - -3.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 * x1)
if (x1 <= (-6.2d+78)) then
tmp = t_0 * ((4.0d0 * (x2 * (3.0d0 + (x2 * (-2.0d0))))) + ((-19.0d0) + (x2 * 12.0d0)))
else if (x1 <= 2.5d+17) then
tmp = ((3.0d0 * ((x2 * (-2.0d0)) + (x1 * ((x1 * 3.0d0) + (-1.0d0))))) / ((x1 * x1) + 1.0d0)) + ((x1 * 2.0d0) + (x2 * ((x1 * (-12.0d0)) + (x2 * (x1 * 8.0d0)))))
else
tmp = t_0 * ((((9.0d0 + (x2 * 6.0d0)) + (((-1.0d0) + ((2.0d0 * x2) * ((-6.0d0) + (x2 * 4.0d0)))) / x1)) / x1) - (-3.0d0))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = x1 * (x1 * x1);
double tmp;
if (x1 <= -6.2e+78) {
tmp = t_0 * ((4.0 * (x2 * (3.0 + (x2 * -2.0)))) + (-19.0 + (x2 * 12.0)));
} else if (x1 <= 2.5e+17) {
tmp = ((3.0 * ((x2 * -2.0) + (x1 * ((x1 * 3.0) + -1.0)))) / ((x1 * x1) + 1.0)) + ((x1 * 2.0) + (x2 * ((x1 * -12.0) + (x2 * (x1 * 8.0)))));
} else {
tmp = t_0 * ((((9.0 + (x2 * 6.0)) + ((-1.0 + ((2.0 * x2) * (-6.0 + (x2 * 4.0)))) / x1)) / x1) - -3.0);
}
return tmp;
}
def code(x1, x2): t_0 = x1 * (x1 * x1) tmp = 0 if x1 <= -6.2e+78: tmp = t_0 * ((4.0 * (x2 * (3.0 + (x2 * -2.0)))) + (-19.0 + (x2 * 12.0))) elif x1 <= 2.5e+17: tmp = ((3.0 * ((x2 * -2.0) + (x1 * ((x1 * 3.0) + -1.0)))) / ((x1 * x1) + 1.0)) + ((x1 * 2.0) + (x2 * ((x1 * -12.0) + (x2 * (x1 * 8.0))))) else: tmp = t_0 * ((((9.0 + (x2 * 6.0)) + ((-1.0 + ((2.0 * x2) * (-6.0 + (x2 * 4.0)))) / x1)) / x1) - -3.0) return tmp
function code(x1, x2) t_0 = Float64(x1 * Float64(x1 * x1)) tmp = 0.0 if (x1 <= -6.2e+78) tmp = Float64(t_0 * Float64(Float64(4.0 * Float64(x2 * Float64(3.0 + Float64(x2 * -2.0)))) + Float64(-19.0 + Float64(x2 * 12.0)))); elseif (x1 <= 2.5e+17) tmp = Float64(Float64(Float64(3.0 * Float64(Float64(x2 * -2.0) + Float64(x1 * Float64(Float64(x1 * 3.0) + -1.0)))) / Float64(Float64(x1 * x1) + 1.0)) + Float64(Float64(x1 * 2.0) + Float64(x2 * Float64(Float64(x1 * -12.0) + Float64(x2 * Float64(x1 * 8.0)))))); else tmp = Float64(t_0 * Float64(Float64(Float64(Float64(9.0 + Float64(x2 * 6.0)) + Float64(Float64(-1.0 + Float64(Float64(2.0 * x2) * Float64(-6.0 + Float64(x2 * 4.0)))) / x1)) / x1) - -3.0)); end return tmp end
function tmp_2 = code(x1, x2) t_0 = x1 * (x1 * x1); tmp = 0.0; if (x1 <= -6.2e+78) tmp = t_0 * ((4.0 * (x2 * (3.0 + (x2 * -2.0)))) + (-19.0 + (x2 * 12.0))); elseif (x1 <= 2.5e+17) tmp = ((3.0 * ((x2 * -2.0) + (x1 * ((x1 * 3.0) + -1.0)))) / ((x1 * x1) + 1.0)) + ((x1 * 2.0) + (x2 * ((x1 * -12.0) + (x2 * (x1 * 8.0))))); else tmp = t_0 * ((((9.0 + (x2 * 6.0)) + ((-1.0 + ((2.0 * x2) * (-6.0 + (x2 * 4.0)))) / x1)) / x1) - -3.0); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(x1 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -6.2e+78], N[(t$95$0 * N[(N[(4.0 * N[(x2 * N[(3.0 + N[(x2 * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-19.0 + N[(x2 * 12.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 2.5e+17], N[(N[(N[(3.0 * N[(N[(x2 * -2.0), $MachinePrecision] + N[(x1 * N[(N[(x1 * 3.0), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(x1 * x1), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision] + N[(N[(x1 * 2.0), $MachinePrecision] + N[(x2 * N[(N[(x1 * -12.0), $MachinePrecision] + N[(x2 * N[(x1 * 8.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t$95$0 * N[(N[(N[(N[(9.0 + N[(x2 * 6.0), $MachinePrecision]), $MachinePrecision] + N[(N[(-1.0 + N[(N[(2.0 * x2), $MachinePrecision] * N[(-6.0 + N[(x2 * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / x1), $MachinePrecision]), $MachinePrecision] / x1), $MachinePrecision] - -3.0), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 \cdot \left(x1 \cdot x1\right)\\
\mathbf{if}\;x1 \leq -6.2 \cdot 10^{+78}:\\
\;\;\;\;t\_0 \cdot \left(4 \cdot \left(x2 \cdot \left(3 + x2 \cdot -2\right)\right) + \left(-19 + x2 \cdot 12\right)\right)\\
\mathbf{elif}\;x1 \leq 2.5 \cdot 10^{+17}:\\
\;\;\;\;\frac{3 \cdot \left(x2 \cdot -2 + x1 \cdot \left(x1 \cdot 3 + -1\right)\right)}{x1 \cdot x1 + 1} + \left(x1 \cdot 2 + x2 \cdot \left(x1 \cdot -12 + x2 \cdot \left(x1 \cdot 8\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_0 \cdot \left(\frac{\left(9 + x2 \cdot 6\right) + \frac{-1 + \left(2 \cdot x2\right) \cdot \left(-6 + x2 \cdot 4\right)}{x1}}{x1} - -3\right)\\
\end{array}
\end{array}
if x1 < -6.2e78Initial program 19.0%
Simplified19.0%
Taylor expanded in x1 around 0
Simplified69.7%
Taylor expanded in x1 around inf
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
cancel-sign-sub-invN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6488.8%
Simplified88.8%
if -6.2e78 < x1 < 2.5e17Initial program 99.4%
Simplified99.6%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6485.3%
Simplified85.3%
Taylor expanded in x2 around 0
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6492.0%
Simplified92.0%
if 2.5e17 < x1 Initial program 50.6%
Simplified50.7%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6412.2%
Simplified12.2%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified72.7%
Taylor expanded in x1 around -inf
Simplified77.8%
Final simplification88.2%
(FPCore (x1 x2)
:precision binary64
(if (<= x1 -6.2e+78)
(*
(* x1 (* x1 x1))
(+ (* 4.0 (* x2 (+ 3.0 (* x2 -2.0)))) (+ -19.0 (* x2 12.0))))
(if (<= x1 2.2e+59)
(+
(* x2 -6.0)
(*
x1
(+
(* 2.0 (* x2 (+ -6.0 (* x2 4.0))))
(+ -1.0 (* 3.0 (* x1 (+ 3.0 (* 2.0 x2))))))))
(* x1 (* 3.0 (* x1 x1))))))
double code(double x1, double x2) {
double tmp;
if (x1 <= -6.2e+78) {
tmp = (x1 * (x1 * x1)) * ((4.0 * (x2 * (3.0 + (x2 * -2.0)))) + (-19.0 + (x2 * 12.0)));
} else if (x1 <= 2.2e+59) {
tmp = (x2 * -6.0) + (x1 * ((2.0 * (x2 * (-6.0 + (x2 * 4.0)))) + (-1.0 + (3.0 * (x1 * (3.0 + (2.0 * x2)))))));
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: tmp
if (x1 <= (-6.2d+78)) then
tmp = (x1 * (x1 * x1)) * ((4.0d0 * (x2 * (3.0d0 + (x2 * (-2.0d0))))) + ((-19.0d0) + (x2 * 12.0d0)))
else if (x1 <= 2.2d+59) then
tmp = (x2 * (-6.0d0)) + (x1 * ((2.0d0 * (x2 * ((-6.0d0) + (x2 * 4.0d0)))) + ((-1.0d0) + (3.0d0 * (x1 * (3.0d0 + (2.0d0 * x2)))))))
else
tmp = x1 * (3.0d0 * (x1 * x1))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double tmp;
if (x1 <= -6.2e+78) {
tmp = (x1 * (x1 * x1)) * ((4.0 * (x2 * (3.0 + (x2 * -2.0)))) + (-19.0 + (x2 * 12.0)));
} else if (x1 <= 2.2e+59) {
tmp = (x2 * -6.0) + (x1 * ((2.0 * (x2 * (-6.0 + (x2 * 4.0)))) + (-1.0 + (3.0 * (x1 * (3.0 + (2.0 * x2)))))));
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
def code(x1, x2): tmp = 0 if x1 <= -6.2e+78: tmp = (x1 * (x1 * x1)) * ((4.0 * (x2 * (3.0 + (x2 * -2.0)))) + (-19.0 + (x2 * 12.0))) elif x1 <= 2.2e+59: tmp = (x2 * -6.0) + (x1 * ((2.0 * (x2 * (-6.0 + (x2 * 4.0)))) + (-1.0 + (3.0 * (x1 * (3.0 + (2.0 * x2))))))) else: tmp = x1 * (3.0 * (x1 * x1)) return tmp
function code(x1, x2) tmp = 0.0 if (x1 <= -6.2e+78) tmp = Float64(Float64(x1 * Float64(x1 * x1)) * Float64(Float64(4.0 * Float64(x2 * Float64(3.0 + Float64(x2 * -2.0)))) + Float64(-19.0 + Float64(x2 * 12.0)))); elseif (x1 <= 2.2e+59) tmp = Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(Float64(2.0 * Float64(x2 * Float64(-6.0 + Float64(x2 * 4.0)))) + Float64(-1.0 + Float64(3.0 * Float64(x1 * Float64(3.0 + Float64(2.0 * x2)))))))); else tmp = Float64(x1 * Float64(3.0 * Float64(x1 * x1))); end return tmp end
function tmp_2 = code(x1, x2) tmp = 0.0; if (x1 <= -6.2e+78) tmp = (x1 * (x1 * x1)) * ((4.0 * (x2 * (3.0 + (x2 * -2.0)))) + (-19.0 + (x2 * 12.0))); elseif (x1 <= 2.2e+59) tmp = (x2 * -6.0) + (x1 * ((2.0 * (x2 * (-6.0 + (x2 * 4.0)))) + (-1.0 + (3.0 * (x1 * (3.0 + (2.0 * x2))))))); else tmp = x1 * (3.0 * (x1 * x1)); end tmp_2 = tmp; end
code[x1_, x2_] := If[LessEqual[x1, -6.2e+78], N[(N[(x1 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision] * N[(N[(4.0 * N[(x2 * N[(3.0 + N[(x2 * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-19.0 + N[(x2 * 12.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 2.2e+59], N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(N[(2.0 * N[(x2 * N[(-6.0 + N[(x2 * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-1.0 + N[(3.0 * N[(x1 * N[(3.0 + N[(2.0 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 * N[(3.0 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x1 \leq -6.2 \cdot 10^{+78}:\\
\;\;\;\;\left(x1 \cdot \left(x1 \cdot x1\right)\right) \cdot \left(4 \cdot \left(x2 \cdot \left(3 + x2 \cdot -2\right)\right) + \left(-19 + x2 \cdot 12\right)\right)\\
\mathbf{elif}\;x1 \leq 2.2 \cdot 10^{+59}:\\
\;\;\;\;x2 \cdot -6 + x1 \cdot \left(2 \cdot \left(x2 \cdot \left(-6 + x2 \cdot 4\right)\right) + \left(-1 + 3 \cdot \left(x1 \cdot \left(3 + 2 \cdot x2\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 \cdot \left(3 \cdot \left(x1 \cdot x1\right)\right)\\
\end{array}
\end{array}
if x1 < -6.2e78Initial program 19.0%
Simplified19.0%
Taylor expanded in x1 around 0
Simplified69.7%
Taylor expanded in x1 around inf
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
cancel-sign-sub-invN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6488.8%
Simplified88.8%
if -6.2e78 < x1 < 2.2e59Initial program 99.4%
Simplified99.6%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6483.6%
Simplified83.6%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified84.1%
if 2.2e59 < x1 Initial program 44.1%
Simplified44.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f647.6%
Simplified7.6%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified76.1%
Taylor expanded in x1 around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6481.8%
Simplified81.8%
Final simplification84.4%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (* x1 (+ -1.0 (* x1 (+ 9.0 (* x1 -19.0)))))))
(if (<= x1 -2.1e+90)
t_0
(if (<= x1 -2.05e-66)
(+ (* x2 -6.0) (* x1 (* x2 (* x2 8.0))))
(if (<= x1 7.4e-184)
(+ t_0 (* x2 -6.0))
(if (<= x1 3.9e+102)
(* x2 (* x2 (+ (* x1 (+ 8.0 (/ -12.0 x2))) (/ -6.0 x2))))
(* x1 (* 3.0 (* x1 x1)))))))))
double code(double x1, double x2) {
double t_0 = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
double tmp;
if (x1 <= -2.1e+90) {
tmp = t_0;
} else if (x1 <= -2.05e-66) {
tmp = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0)));
} else if (x1 <= 7.4e-184) {
tmp = t_0 + (x2 * -6.0);
} else if (x1 <= 3.9e+102) {
tmp = x2 * (x2 * ((x1 * (8.0 + (-12.0 / x2))) + (-6.0 / x2)));
} else {
tmp = x1 * (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) :: tmp
t_0 = x1 * ((-1.0d0) + (x1 * (9.0d0 + (x1 * (-19.0d0)))))
if (x1 <= (-2.1d+90)) then
tmp = t_0
else if (x1 <= (-2.05d-66)) then
tmp = (x2 * (-6.0d0)) + (x1 * (x2 * (x2 * 8.0d0)))
else if (x1 <= 7.4d-184) then
tmp = t_0 + (x2 * (-6.0d0))
else if (x1 <= 3.9d+102) then
tmp = x2 * (x2 * ((x1 * (8.0d0 + ((-12.0d0) / x2))) + ((-6.0d0) / x2)))
else
tmp = x1 * (3.0d0 * (x1 * x1))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
double tmp;
if (x1 <= -2.1e+90) {
tmp = t_0;
} else if (x1 <= -2.05e-66) {
tmp = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0)));
} else if (x1 <= 7.4e-184) {
tmp = t_0 + (x2 * -6.0);
} else if (x1 <= 3.9e+102) {
tmp = x2 * (x2 * ((x1 * (8.0 + (-12.0 / x2))) + (-6.0 / x2)));
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
def code(x1, x2): t_0 = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))) tmp = 0 if x1 <= -2.1e+90: tmp = t_0 elif x1 <= -2.05e-66: tmp = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0))) elif x1 <= 7.4e-184: tmp = t_0 + (x2 * -6.0) elif x1 <= 3.9e+102: tmp = x2 * (x2 * ((x1 * (8.0 + (-12.0 / x2))) + (-6.0 / x2))) else: tmp = x1 * (3.0 * (x1 * x1)) return tmp
function code(x1, x2) t_0 = Float64(x1 * Float64(-1.0 + Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))) tmp = 0.0 if (x1 <= -2.1e+90) tmp = t_0; elseif (x1 <= -2.05e-66) tmp = Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(x2 * Float64(x2 * 8.0)))); elseif (x1 <= 7.4e-184) tmp = Float64(t_0 + Float64(x2 * -6.0)); elseif (x1 <= 3.9e+102) tmp = Float64(x2 * Float64(x2 * Float64(Float64(x1 * Float64(8.0 + Float64(-12.0 / x2))) + Float64(-6.0 / x2)))); else tmp = Float64(x1 * Float64(3.0 * Float64(x1 * x1))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))); tmp = 0.0; if (x1 <= -2.1e+90) tmp = t_0; elseif (x1 <= -2.05e-66) tmp = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0))); elseif (x1 <= 7.4e-184) tmp = t_0 + (x2 * -6.0); elseif (x1 <= 3.9e+102) tmp = x2 * (x2 * ((x1 * (8.0 + (-12.0 / x2))) + (-6.0 / x2))); else tmp = x1 * (3.0 * (x1 * x1)); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(x1 * N[(-1.0 + N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -2.1e+90], t$95$0, If[LessEqual[x1, -2.05e-66], N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(x2 * N[(x2 * 8.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 7.4e-184], N[(t$95$0 + N[(x2 * -6.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 3.9e+102], N[(x2 * N[(x2 * N[(N[(x1 * N[(8.0 + N[(-12.0 / x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-6.0 / x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 * N[(3.0 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x1 \cdot \left(-1 + x1 \cdot \left(9 + x1 \cdot -19\right)\right)\\
\mathbf{if}\;x1 \leq -2.1 \cdot 10^{+90}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;x1 \leq -2.05 \cdot 10^{-66}:\\
\;\;\;\;x2 \cdot -6 + x1 \cdot \left(x2 \cdot \left(x2 \cdot 8\right)\right)\\
\mathbf{elif}\;x1 \leq 7.4 \cdot 10^{-184}:\\
\;\;\;\;t\_0 + x2 \cdot -6\\
\mathbf{elif}\;x1 \leq 3.9 \cdot 10^{+102}:\\
\;\;\;\;x2 \cdot \left(x2 \cdot \left(x1 \cdot \left(8 + \frac{-12}{x2}\right) + \frac{-6}{x2}\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 \cdot \left(3 \cdot \left(x1 \cdot x1\right)\right)\\
\end{array}
\end{array}
if x1 < -2.09999999999999981e90Initial program 5.6%
Simplified5.6%
Taylor expanded in x1 around 0
Simplified77.8%
Taylor expanded in x2 around 0
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6494.9%
Simplified94.9%
if -2.09999999999999981e90 < x1 < -2.04999999999999999e-66Initial program 99.3%
Simplified99.5%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6464.3%
Simplified64.3%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified65.9%
Taylor expanded in x2 around inf
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6450.9%
Simplified50.9%
if -2.04999999999999999e-66 < x1 < 7.3999999999999997e-184Initial program 99.4%
Simplified99.5%
Taylor expanded in x1 around 0
Simplified85.4%
Taylor expanded in x2 around 0
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6493.9%
Simplified93.9%
if 7.3999999999999997e-184 < x1 < 3.8999999999999998e102Initial program 99.5%
Simplified99.6%
Taylor expanded in x2 around -inf
Simplified63.5%
Taylor expanded in x1 around 0
sub-negN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f6458.7%
Simplified58.7%
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
/-lowering-/.f6465.3%
Applied egg-rr65.3%
if 3.8999999999999998e102 < x1 Initial program 34.1%
Simplified34.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f648.1%
Simplified8.1%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified88.6%
Taylor expanded in x1 around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6495.5%
Simplified95.5%
Final simplification80.8%
(FPCore (x1 x2)
:precision binary64
(if (<= x1 -3.65e+90)
(* x1 (+ -1.0 (* x1 (+ 9.0 (* x1 -19.0)))))
(if (<= x1 -1.05e-68)
(+ (* x2 -6.0) (* x1 (* x2 (* x2 8.0))))
(if (<= x1 6.2e-184)
(+ (* x2 -6.0) (* x1 (+ -1.0 (* x2 -12.0))))
(if (<= x1 3.9e+102)
(* x2 (* x2 (+ (* x1 (+ 8.0 (/ -12.0 x2))) (/ -6.0 x2))))
(* x1 (* 3.0 (* x1 x1))))))))
double code(double x1, double x2) {
double tmp;
if (x1 <= -3.65e+90) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= -1.05e-68) {
tmp = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0)));
} else if (x1 <= 6.2e-184) {
tmp = (x2 * -6.0) + (x1 * (-1.0 + (x2 * -12.0)));
} else if (x1 <= 3.9e+102) {
tmp = x2 * (x2 * ((x1 * (8.0 + (-12.0 / x2))) + (-6.0 / x2)));
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: tmp
if (x1 <= (-3.65d+90)) then
tmp = x1 * ((-1.0d0) + (x1 * (9.0d0 + (x1 * (-19.0d0)))))
else if (x1 <= (-1.05d-68)) then
tmp = (x2 * (-6.0d0)) + (x1 * (x2 * (x2 * 8.0d0)))
else if (x1 <= 6.2d-184) then
tmp = (x2 * (-6.0d0)) + (x1 * ((-1.0d0) + (x2 * (-12.0d0))))
else if (x1 <= 3.9d+102) then
tmp = x2 * (x2 * ((x1 * (8.0d0 + ((-12.0d0) / x2))) + ((-6.0d0) / x2)))
else
tmp = x1 * (3.0d0 * (x1 * x1))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double tmp;
if (x1 <= -3.65e+90) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= -1.05e-68) {
tmp = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0)));
} else if (x1 <= 6.2e-184) {
tmp = (x2 * -6.0) + (x1 * (-1.0 + (x2 * -12.0)));
} else if (x1 <= 3.9e+102) {
tmp = x2 * (x2 * ((x1 * (8.0 + (-12.0 / x2))) + (-6.0 / x2)));
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
def code(x1, x2): tmp = 0 if x1 <= -3.65e+90: tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))) elif x1 <= -1.05e-68: tmp = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0))) elif x1 <= 6.2e-184: tmp = (x2 * -6.0) + (x1 * (-1.0 + (x2 * -12.0))) elif x1 <= 3.9e+102: tmp = x2 * (x2 * ((x1 * (8.0 + (-12.0 / x2))) + (-6.0 / x2))) else: tmp = x1 * (3.0 * (x1 * x1)) return tmp
function code(x1, x2) tmp = 0.0 if (x1 <= -3.65e+90) tmp = Float64(x1 * Float64(-1.0 + Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))); elseif (x1 <= -1.05e-68) tmp = Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(x2 * Float64(x2 * 8.0)))); elseif (x1 <= 6.2e-184) tmp = Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(-1.0 + Float64(x2 * -12.0)))); elseif (x1 <= 3.9e+102) tmp = Float64(x2 * Float64(x2 * Float64(Float64(x1 * Float64(8.0 + Float64(-12.0 / x2))) + Float64(-6.0 / x2)))); else tmp = Float64(x1 * Float64(3.0 * Float64(x1 * x1))); end return tmp end
function tmp_2 = code(x1, x2) tmp = 0.0; if (x1 <= -3.65e+90) tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))); elseif (x1 <= -1.05e-68) tmp = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0))); elseif (x1 <= 6.2e-184) tmp = (x2 * -6.0) + (x1 * (-1.0 + (x2 * -12.0))); elseif (x1 <= 3.9e+102) tmp = x2 * (x2 * ((x1 * (8.0 + (-12.0 / x2))) + (-6.0 / x2))); else tmp = x1 * (3.0 * (x1 * x1)); end tmp_2 = tmp; end
code[x1_, x2_] := If[LessEqual[x1, -3.65e+90], N[(x1 * N[(-1.0 + N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -1.05e-68], N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(x2 * N[(x2 * 8.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 6.2e-184], N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(-1.0 + N[(x2 * -12.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 3.9e+102], N[(x2 * N[(x2 * N[(N[(x1 * N[(8.0 + N[(-12.0 / x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-6.0 / x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 * N[(3.0 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x1 \leq -3.65 \cdot 10^{+90}:\\
\;\;\;\;x1 \cdot \left(-1 + x1 \cdot \left(9 + x1 \cdot -19\right)\right)\\
\mathbf{elif}\;x1 \leq -1.05 \cdot 10^{-68}:\\
\;\;\;\;x2 \cdot -6 + x1 \cdot \left(x2 \cdot \left(x2 \cdot 8\right)\right)\\
\mathbf{elif}\;x1 \leq 6.2 \cdot 10^{-184}:\\
\;\;\;\;x2 \cdot -6 + x1 \cdot \left(-1 + x2 \cdot -12\right)\\
\mathbf{elif}\;x1 \leq 3.9 \cdot 10^{+102}:\\
\;\;\;\;x2 \cdot \left(x2 \cdot \left(x1 \cdot \left(8 + \frac{-12}{x2}\right) + \frac{-6}{x2}\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 \cdot \left(3 \cdot \left(x1 \cdot x1\right)\right)\\
\end{array}
\end{array}
if x1 < -3.64999999999999997e90Initial program 5.6%
Simplified5.6%
Taylor expanded in x1 around 0
Simplified77.8%
Taylor expanded in x2 around 0
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6494.9%
Simplified94.9%
if -3.64999999999999997e90 < x1 < -1.05000000000000004e-68Initial program 99.3%
Simplified99.5%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6464.3%
Simplified64.3%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified65.9%
Taylor expanded in x2 around inf
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6450.9%
Simplified50.9%
if -1.05000000000000004e-68 < x1 < 6.2000000000000004e-184Initial program 99.4%
Simplified99.5%
Taylor expanded in x1 around 0
Simplified85.4%
Taylor expanded in x2 around 0
distribute-lft-outN/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified93.9%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6493.9%
Simplified93.9%
if 6.2000000000000004e-184 < x1 < 3.8999999999999998e102Initial program 99.5%
Simplified99.6%
Taylor expanded in x2 around -inf
Simplified63.5%
Taylor expanded in x1 around 0
sub-negN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f6458.7%
Simplified58.7%
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
/-lowering-/.f6465.3%
Applied egg-rr65.3%
if 3.8999999999999998e102 < x1 Initial program 34.1%
Simplified34.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f648.1%
Simplified8.1%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified88.6%
Taylor expanded in x1 around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6495.5%
Simplified95.5%
Final simplification80.8%
(FPCore (x1 x2)
:precision binary64
(if (<= x1 -6.2e+78)
(*
(* x1 (* x1 x1))
(+ (* 4.0 (* x2 (+ 3.0 (* x2 -2.0)))) (+ -19.0 (* x2 12.0))))
(+
(* x2 -6.0)
(*
x1
(+
(* 2.0 (* x2 (+ -6.0 (* x2 4.0))))
(+ -1.0 (* x1 (* 3.0 (+ x1 (+ 3.0 (* 2.0 x2)))))))))))
double code(double x1, double x2) {
double tmp;
if (x1 <= -6.2e+78) {
tmp = (x1 * (x1 * x1)) * ((4.0 * (x2 * (3.0 + (x2 * -2.0)))) + (-19.0 + (x2 * 12.0)));
} else {
tmp = (x2 * -6.0) + (x1 * ((2.0 * (x2 * (-6.0 + (x2 * 4.0)))) + (-1.0 + (x1 * (3.0 * (x1 + (3.0 + (2.0 * x2))))))));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: tmp
if (x1 <= (-6.2d+78)) then
tmp = (x1 * (x1 * x1)) * ((4.0d0 * (x2 * (3.0d0 + (x2 * (-2.0d0))))) + ((-19.0d0) + (x2 * 12.0d0)))
else
tmp = (x2 * (-6.0d0)) + (x1 * ((2.0d0 * (x2 * ((-6.0d0) + (x2 * 4.0d0)))) + ((-1.0d0) + (x1 * (3.0d0 * (x1 + (3.0d0 + (2.0d0 * x2))))))))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double tmp;
if (x1 <= -6.2e+78) {
tmp = (x1 * (x1 * x1)) * ((4.0 * (x2 * (3.0 + (x2 * -2.0)))) + (-19.0 + (x2 * 12.0)));
} else {
tmp = (x2 * -6.0) + (x1 * ((2.0 * (x2 * (-6.0 + (x2 * 4.0)))) + (-1.0 + (x1 * (3.0 * (x1 + (3.0 + (2.0 * x2))))))));
}
return tmp;
}
def code(x1, x2): tmp = 0 if x1 <= -6.2e+78: tmp = (x1 * (x1 * x1)) * ((4.0 * (x2 * (3.0 + (x2 * -2.0)))) + (-19.0 + (x2 * 12.0))) else: tmp = (x2 * -6.0) + (x1 * ((2.0 * (x2 * (-6.0 + (x2 * 4.0)))) + (-1.0 + (x1 * (3.0 * (x1 + (3.0 + (2.0 * x2)))))))) return tmp
function code(x1, x2) tmp = 0.0 if (x1 <= -6.2e+78) tmp = Float64(Float64(x1 * Float64(x1 * x1)) * Float64(Float64(4.0 * Float64(x2 * Float64(3.0 + Float64(x2 * -2.0)))) + Float64(-19.0 + Float64(x2 * 12.0)))); else tmp = Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(Float64(2.0 * Float64(x2 * Float64(-6.0 + Float64(x2 * 4.0)))) + Float64(-1.0 + Float64(x1 * Float64(3.0 * Float64(x1 + Float64(3.0 + Float64(2.0 * x2))))))))); end return tmp end
function tmp_2 = code(x1, x2) tmp = 0.0; if (x1 <= -6.2e+78) tmp = (x1 * (x1 * x1)) * ((4.0 * (x2 * (3.0 + (x2 * -2.0)))) + (-19.0 + (x2 * 12.0))); else tmp = (x2 * -6.0) + (x1 * ((2.0 * (x2 * (-6.0 + (x2 * 4.0)))) + (-1.0 + (x1 * (3.0 * (x1 + (3.0 + (2.0 * x2)))))))); end tmp_2 = tmp; end
code[x1_, x2_] := If[LessEqual[x1, -6.2e+78], N[(N[(x1 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision] * N[(N[(4.0 * N[(x2 * N[(3.0 + N[(x2 * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-19.0 + N[(x2 * 12.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(N[(2.0 * N[(x2 * N[(-6.0 + N[(x2 * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-1.0 + N[(x1 * N[(3.0 * N[(x1 + N[(3.0 + N[(2.0 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x1 \leq -6.2 \cdot 10^{+78}:\\
\;\;\;\;\left(x1 \cdot \left(x1 \cdot x1\right)\right) \cdot \left(4 \cdot \left(x2 \cdot \left(3 + x2 \cdot -2\right)\right) + \left(-19 + x2 \cdot 12\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x2 \cdot -6 + x1 \cdot \left(2 \cdot \left(x2 \cdot \left(-6 + x2 \cdot 4\right)\right) + \left(-1 + x1 \cdot \left(3 \cdot \left(x1 + \left(3 + 2 \cdot x2\right)\right)\right)\right)\right)\\
\end{array}
\end{array}
if x1 < -6.2e78Initial program 19.0%
Simplified19.0%
Taylor expanded in x1 around 0
Simplified69.7%
Taylor expanded in x1 around inf
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
cancel-sign-sub-invN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6488.8%
Simplified88.8%
if -6.2e78 < x1 Initial program 86.0%
Simplified86.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6465.1%
Simplified65.1%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified82.0%
Final simplification83.1%
(FPCore (x1 x2)
:precision binary64
(if (<= x1 -3.2e+90)
(* x1 (+ -1.0 (* x1 (+ 9.0 (* x1 -19.0)))))
(if (<= x1 -4.5e-65)
(+ (* x2 -6.0) (* x1 (* x2 (* x2 8.0))))
(if (<= x1 2.3e-183)
(+ (* x2 -6.0) (* x1 (+ -1.0 (* x2 -12.0))))
(if (<= x1 1.9e+59)
(* x2 (+ (* x1 -12.0) (+ -6.0 (* 8.0 (* x1 x2)))))
(* x1 (* 3.0 (* x1 x1))))))))
double code(double x1, double x2) {
double tmp;
if (x1 <= -3.2e+90) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= -4.5e-65) {
tmp = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0)));
} else if (x1 <= 2.3e-183) {
tmp = (x2 * -6.0) + (x1 * (-1.0 + (x2 * -12.0)));
} else if (x1 <= 1.9e+59) {
tmp = x2 * ((x1 * -12.0) + (-6.0 + (8.0 * (x1 * x2))));
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: tmp
if (x1 <= (-3.2d+90)) then
tmp = x1 * ((-1.0d0) + (x1 * (9.0d0 + (x1 * (-19.0d0)))))
else if (x1 <= (-4.5d-65)) then
tmp = (x2 * (-6.0d0)) + (x1 * (x2 * (x2 * 8.0d0)))
else if (x1 <= 2.3d-183) then
tmp = (x2 * (-6.0d0)) + (x1 * ((-1.0d0) + (x2 * (-12.0d0))))
else if (x1 <= 1.9d+59) then
tmp = x2 * ((x1 * (-12.0d0)) + ((-6.0d0) + (8.0d0 * (x1 * x2))))
else
tmp = x1 * (3.0d0 * (x1 * x1))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double tmp;
if (x1 <= -3.2e+90) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= -4.5e-65) {
tmp = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0)));
} else if (x1 <= 2.3e-183) {
tmp = (x2 * -6.0) + (x1 * (-1.0 + (x2 * -12.0)));
} else if (x1 <= 1.9e+59) {
tmp = x2 * ((x1 * -12.0) + (-6.0 + (8.0 * (x1 * x2))));
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
def code(x1, x2): tmp = 0 if x1 <= -3.2e+90: tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))) elif x1 <= -4.5e-65: tmp = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0))) elif x1 <= 2.3e-183: tmp = (x2 * -6.0) + (x1 * (-1.0 + (x2 * -12.0))) elif x1 <= 1.9e+59: tmp = x2 * ((x1 * -12.0) + (-6.0 + (8.0 * (x1 * x2)))) else: tmp = x1 * (3.0 * (x1 * x1)) return tmp
function code(x1, x2) tmp = 0.0 if (x1 <= -3.2e+90) tmp = Float64(x1 * Float64(-1.0 + Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))); elseif (x1 <= -4.5e-65) tmp = Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(x2 * Float64(x2 * 8.0)))); elseif (x1 <= 2.3e-183) tmp = Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(-1.0 + Float64(x2 * -12.0)))); elseif (x1 <= 1.9e+59) tmp = Float64(x2 * Float64(Float64(x1 * -12.0) + Float64(-6.0 + Float64(8.0 * Float64(x1 * x2))))); else tmp = Float64(x1 * Float64(3.0 * Float64(x1 * x1))); end return tmp end
function tmp_2 = code(x1, x2) tmp = 0.0; if (x1 <= -3.2e+90) tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))); elseif (x1 <= -4.5e-65) tmp = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0))); elseif (x1 <= 2.3e-183) tmp = (x2 * -6.0) + (x1 * (-1.0 + (x2 * -12.0))); elseif (x1 <= 1.9e+59) tmp = x2 * ((x1 * -12.0) + (-6.0 + (8.0 * (x1 * x2)))); else tmp = x1 * (3.0 * (x1 * x1)); end tmp_2 = tmp; end
code[x1_, x2_] := If[LessEqual[x1, -3.2e+90], N[(x1 * N[(-1.0 + N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -4.5e-65], N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(x2 * N[(x2 * 8.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 2.3e-183], N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(-1.0 + N[(x2 * -12.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 1.9e+59], N[(x2 * N[(N[(x1 * -12.0), $MachinePrecision] + N[(-6.0 + N[(8.0 * N[(x1 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 * N[(3.0 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x1 \leq -3.2 \cdot 10^{+90}:\\
\;\;\;\;x1 \cdot \left(-1 + x1 \cdot \left(9 + x1 \cdot -19\right)\right)\\
\mathbf{elif}\;x1 \leq -4.5 \cdot 10^{-65}:\\
\;\;\;\;x2 \cdot -6 + x1 \cdot \left(x2 \cdot \left(x2 \cdot 8\right)\right)\\
\mathbf{elif}\;x1 \leq 2.3 \cdot 10^{-183}:\\
\;\;\;\;x2 \cdot -6 + x1 \cdot \left(-1 + x2 \cdot -12\right)\\
\mathbf{elif}\;x1 \leq 1.9 \cdot 10^{+59}:\\
\;\;\;\;x2 \cdot \left(x1 \cdot -12 + \left(-6 + 8 \cdot \left(x1 \cdot x2\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 \cdot \left(3 \cdot \left(x1 \cdot x1\right)\right)\\
\end{array}
\end{array}
if x1 < -3.19999999999999998e90Initial program 5.6%
Simplified5.6%
Taylor expanded in x1 around 0
Simplified77.8%
Taylor expanded in x2 around 0
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6494.9%
Simplified94.9%
if -3.19999999999999998e90 < x1 < -4.4999999999999998e-65Initial program 99.3%
Simplified99.5%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6464.3%
Simplified64.3%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified65.9%
Taylor expanded in x2 around inf
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6450.9%
Simplified50.9%
if -4.4999999999999998e-65 < x1 < 2.30000000000000016e-183Initial program 99.4%
Simplified99.5%
Taylor expanded in x1 around 0
Simplified85.4%
Taylor expanded in x2 around 0
distribute-lft-outN/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified93.9%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6493.9%
Simplified93.9%
if 2.30000000000000016e-183 < x1 < 1.9e59Initial program 99.5%
Simplified99.7%
Taylor expanded in x2 around -inf
Simplified73.2%
Taylor expanded in x1 around 0
sub-negN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f6467.7%
Simplified67.7%
Taylor expanded in x2 around 0
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6473.4%
Simplified73.4%
if 1.9e59 < x1 Initial program 44.1%
Simplified44.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f647.6%
Simplified7.6%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified76.1%
Taylor expanded in x1 around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6481.8%
Simplified81.8%
Final simplification80.5%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (+ (* x2 -6.0) (* x1 (* x2 (* x2 8.0))))))
(if (<= x1 -1.75e+89)
(* x1 (+ -1.0 (* x1 (+ 9.0 (* x1 -19.0)))))
(if (<= x1 -5.5e-67)
t_0
(if (<= x1 9.5e-161)
(+ (* x2 -6.0) (* x1 (+ -1.0 (* x2 -12.0))))
(if (<= x1 2.2e+59) t_0 (* x1 (* 3.0 (* x1 x1)))))))))
double code(double x1, double x2) {
double t_0 = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0)));
double tmp;
if (x1 <= -1.75e+89) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= -5.5e-67) {
tmp = t_0;
} else if (x1 <= 9.5e-161) {
tmp = (x2 * -6.0) + (x1 * (-1.0 + (x2 * -12.0)));
} else if (x1 <= 2.2e+59) {
tmp = t_0;
} else {
tmp = x1 * (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) :: tmp
t_0 = (x2 * (-6.0d0)) + (x1 * (x2 * (x2 * 8.0d0)))
if (x1 <= (-1.75d+89)) then
tmp = x1 * ((-1.0d0) + (x1 * (9.0d0 + (x1 * (-19.0d0)))))
else if (x1 <= (-5.5d-67)) then
tmp = t_0
else if (x1 <= 9.5d-161) then
tmp = (x2 * (-6.0d0)) + (x1 * ((-1.0d0) + (x2 * (-12.0d0))))
else if (x1 <= 2.2d+59) then
tmp = t_0
else
tmp = x1 * (3.0d0 * (x1 * x1))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0)));
double tmp;
if (x1 <= -1.75e+89) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= -5.5e-67) {
tmp = t_0;
} else if (x1 <= 9.5e-161) {
tmp = (x2 * -6.0) + (x1 * (-1.0 + (x2 * -12.0)));
} else if (x1 <= 2.2e+59) {
tmp = t_0;
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
def code(x1, x2): t_0 = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0))) tmp = 0 if x1 <= -1.75e+89: tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))) elif x1 <= -5.5e-67: tmp = t_0 elif x1 <= 9.5e-161: tmp = (x2 * -6.0) + (x1 * (-1.0 + (x2 * -12.0))) elif x1 <= 2.2e+59: tmp = t_0 else: tmp = x1 * (3.0 * (x1 * x1)) return tmp
function code(x1, x2) t_0 = Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(x2 * Float64(x2 * 8.0)))) tmp = 0.0 if (x1 <= -1.75e+89) tmp = Float64(x1 * Float64(-1.0 + Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))); elseif (x1 <= -5.5e-67) tmp = t_0; elseif (x1 <= 9.5e-161) tmp = Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(-1.0 + Float64(x2 * -12.0)))); elseif (x1 <= 2.2e+59) tmp = t_0; else tmp = Float64(x1 * Float64(3.0 * Float64(x1 * x1))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0))); tmp = 0.0; if (x1 <= -1.75e+89) tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))); elseif (x1 <= -5.5e-67) tmp = t_0; elseif (x1 <= 9.5e-161) tmp = (x2 * -6.0) + (x1 * (-1.0 + (x2 * -12.0))); elseif (x1 <= 2.2e+59) tmp = t_0; else tmp = x1 * (3.0 * (x1 * x1)); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(x2 * N[(x2 * 8.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -1.75e+89], N[(x1 * N[(-1.0 + N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -5.5e-67], t$95$0, If[LessEqual[x1, 9.5e-161], N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(-1.0 + N[(x2 * -12.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 2.2e+59], t$95$0, N[(x1 * N[(3.0 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x2 \cdot -6 + x1 \cdot \left(x2 \cdot \left(x2 \cdot 8\right)\right)\\
\mathbf{if}\;x1 \leq -1.75 \cdot 10^{+89}:\\
\;\;\;\;x1 \cdot \left(-1 + x1 \cdot \left(9 + x1 \cdot -19\right)\right)\\
\mathbf{elif}\;x1 \leq -5.5 \cdot 10^{-67}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;x1 \leq 9.5 \cdot 10^{-161}:\\
\;\;\;\;x2 \cdot -6 + x1 \cdot \left(-1 + x2 \cdot -12\right)\\
\mathbf{elif}\;x1 \leq 2.2 \cdot 10^{+59}:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;x1 \cdot \left(3 \cdot \left(x1 \cdot x1\right)\right)\\
\end{array}
\end{array}
if x1 < -1.75e89Initial program 5.6%
Simplified5.6%
Taylor expanded in x1 around 0
Simplified77.8%
Taylor expanded in x2 around 0
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6494.9%
Simplified94.9%
if -1.75e89 < x1 < -5.5000000000000003e-67 or 9.4999999999999996e-161 < x1 < 2.2e59Initial program 99.4%
Simplified99.6%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6474.8%
Simplified74.8%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified75.7%
Taylor expanded in x2 around inf
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6460.6%
Simplified60.6%
if -5.5000000000000003e-67 < x1 < 9.4999999999999996e-161Initial program 99.5%
Simplified99.6%
Taylor expanded in x1 around 0
Simplified82.8%
Taylor expanded in x2 around 0
distribute-lft-outN/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified91.9%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6491.9%
Simplified91.9%
if 2.2e59 < x1 Initial program 44.1%
Simplified44.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f647.6%
Simplified7.6%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified76.1%
Taylor expanded in x1 around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6481.8%
Simplified81.8%
Final simplification79.8%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (* (* x2 x2) (+ (* x1 8.0) (/ -6.0 x2)))))
(if (<= x1 -2e+90)
(* x1 (+ -1.0 (* x1 (+ 9.0 (* x1 -19.0)))))
(if (<= x1 -2.2e-196)
t_0
(if (<= x1 1.65e-181)
(* x2 -6.0)
(if (<= x1 1.9e+58) t_0 (* x1 (* 3.0 (* x1 x1)))))))))
double code(double x1, double x2) {
double t_0 = (x2 * x2) * ((x1 * 8.0) + (-6.0 / x2));
double tmp;
if (x1 <= -2e+90) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= -2.2e-196) {
tmp = t_0;
} else if (x1 <= 1.65e-181) {
tmp = x2 * -6.0;
} else if (x1 <= 1.9e+58) {
tmp = t_0;
} else {
tmp = x1 * (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) :: tmp
t_0 = (x2 * x2) * ((x1 * 8.0d0) + ((-6.0d0) / x2))
if (x1 <= (-2d+90)) then
tmp = x1 * ((-1.0d0) + (x1 * (9.0d0 + (x1 * (-19.0d0)))))
else if (x1 <= (-2.2d-196)) then
tmp = t_0
else if (x1 <= 1.65d-181) then
tmp = x2 * (-6.0d0)
else if (x1 <= 1.9d+58) then
tmp = t_0
else
tmp = x1 * (3.0d0 * (x1 * x1))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = (x2 * x2) * ((x1 * 8.0) + (-6.0 / x2));
double tmp;
if (x1 <= -2e+90) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= -2.2e-196) {
tmp = t_0;
} else if (x1 <= 1.65e-181) {
tmp = x2 * -6.0;
} else if (x1 <= 1.9e+58) {
tmp = t_0;
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
def code(x1, x2): t_0 = (x2 * x2) * ((x1 * 8.0) + (-6.0 / x2)) tmp = 0 if x1 <= -2e+90: tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))) elif x1 <= -2.2e-196: tmp = t_0 elif x1 <= 1.65e-181: tmp = x2 * -6.0 elif x1 <= 1.9e+58: tmp = t_0 else: tmp = x1 * (3.0 * (x1 * x1)) return tmp
function code(x1, x2) t_0 = Float64(Float64(x2 * x2) * Float64(Float64(x1 * 8.0) + Float64(-6.0 / x2))) tmp = 0.0 if (x1 <= -2e+90) tmp = Float64(x1 * Float64(-1.0 + Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))); elseif (x1 <= -2.2e-196) tmp = t_0; elseif (x1 <= 1.65e-181) tmp = Float64(x2 * -6.0); elseif (x1 <= 1.9e+58) tmp = t_0; else tmp = Float64(x1 * Float64(3.0 * Float64(x1 * x1))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = (x2 * x2) * ((x1 * 8.0) + (-6.0 / x2)); tmp = 0.0; if (x1 <= -2e+90) tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))); elseif (x1 <= -2.2e-196) tmp = t_0; elseif (x1 <= 1.65e-181) tmp = x2 * -6.0; elseif (x1 <= 1.9e+58) tmp = t_0; else tmp = x1 * (3.0 * (x1 * x1)); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(N[(x2 * x2), $MachinePrecision] * N[(N[(x1 * 8.0), $MachinePrecision] + N[(-6.0 / x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -2e+90], N[(x1 * N[(-1.0 + N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -2.2e-196], t$95$0, If[LessEqual[x1, 1.65e-181], N[(x2 * -6.0), $MachinePrecision], If[LessEqual[x1, 1.9e+58], t$95$0, N[(x1 * N[(3.0 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \left(x2 \cdot x2\right) \cdot \left(x1 \cdot 8 + \frac{-6}{x2}\right)\\
\mathbf{if}\;x1 \leq -2 \cdot 10^{+90}:\\
\;\;\;\;x1 \cdot \left(-1 + x1 \cdot \left(9 + x1 \cdot -19\right)\right)\\
\mathbf{elif}\;x1 \leq -2.2 \cdot 10^{-196}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;x1 \leq 1.65 \cdot 10^{-181}:\\
\;\;\;\;x2 \cdot -6\\
\mathbf{elif}\;x1 \leq 1.9 \cdot 10^{+58}:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;x1 \cdot \left(3 \cdot \left(x1 \cdot x1\right)\right)\\
\end{array}
\end{array}
if x1 < -1.99999999999999993e90Initial program 5.6%
Simplified5.6%
Taylor expanded in x1 around 0
Simplified77.8%
Taylor expanded in x2 around 0
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6494.9%
Simplified94.9%
if -1.99999999999999993e90 < x1 < -2.20000000000000015e-196 or 1.65000000000000004e-181 < x1 < 1.8999999999999999e58Initial program 99.4%
Simplified99.6%
Taylor expanded in x2 around -inf
Simplified63.1%
Taylor expanded in x1 around 0
sub-negN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f6460.5%
Simplified60.5%
Taylor expanded in x2 around inf
*-commutativeN/A
*-lowering-*.f6460.5%
Simplified60.5%
if -2.20000000000000015e-196 < x1 < 1.65000000000000004e-181Initial program 99.5%
Taylor expanded in x1 around 0
*-lowering-*.f6480.9%
Simplified80.9%
if 1.8999999999999999e58 < x1 Initial program 44.1%
Simplified44.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f647.6%
Simplified7.6%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified76.1%
Taylor expanded in x1 around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6481.8%
Simplified81.8%
Final simplification74.2%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (* (* x1 (+ 8.0 (/ -12.0 x2))) (* x2 x2))))
(if (<= x1 -3.45e+90)
(* x1 (+ -1.0 (* x1 (+ 9.0 (* x1 -19.0)))))
(if (<= x1 -2e-71)
t_0
(if (<= x1 2.1e-113)
(* x2 -6.0)
(if (<= x1 6.5e+58) t_0 (* x1 (* 3.0 (* x1 x1)))))))))
double code(double x1, double x2) {
double t_0 = (x1 * (8.0 + (-12.0 / x2))) * (x2 * x2);
double tmp;
if (x1 <= -3.45e+90) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= -2e-71) {
tmp = t_0;
} else if (x1 <= 2.1e-113) {
tmp = x2 * -6.0;
} else if (x1 <= 6.5e+58) {
tmp = t_0;
} else {
tmp = x1 * (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) :: tmp
t_0 = (x1 * (8.0d0 + ((-12.0d0) / x2))) * (x2 * x2)
if (x1 <= (-3.45d+90)) then
tmp = x1 * ((-1.0d0) + (x1 * (9.0d0 + (x1 * (-19.0d0)))))
else if (x1 <= (-2d-71)) then
tmp = t_0
else if (x1 <= 2.1d-113) then
tmp = x2 * (-6.0d0)
else if (x1 <= 6.5d+58) then
tmp = t_0
else
tmp = x1 * (3.0d0 * (x1 * x1))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = (x1 * (8.0 + (-12.0 / x2))) * (x2 * x2);
double tmp;
if (x1 <= -3.45e+90) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= -2e-71) {
tmp = t_0;
} else if (x1 <= 2.1e-113) {
tmp = x2 * -6.0;
} else if (x1 <= 6.5e+58) {
tmp = t_0;
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
def code(x1, x2): t_0 = (x1 * (8.0 + (-12.0 / x2))) * (x2 * x2) tmp = 0 if x1 <= -3.45e+90: tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))) elif x1 <= -2e-71: tmp = t_0 elif x1 <= 2.1e-113: tmp = x2 * -6.0 elif x1 <= 6.5e+58: tmp = t_0 else: tmp = x1 * (3.0 * (x1 * x1)) return tmp
function code(x1, x2) t_0 = Float64(Float64(x1 * Float64(8.0 + Float64(-12.0 / x2))) * Float64(x2 * x2)) tmp = 0.0 if (x1 <= -3.45e+90) tmp = Float64(x1 * Float64(-1.0 + Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))); elseif (x1 <= -2e-71) tmp = t_0; elseif (x1 <= 2.1e-113) tmp = Float64(x2 * -6.0); elseif (x1 <= 6.5e+58) tmp = t_0; else tmp = Float64(x1 * Float64(3.0 * Float64(x1 * x1))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = (x1 * (8.0 + (-12.0 / x2))) * (x2 * x2); tmp = 0.0; if (x1 <= -3.45e+90) tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))); elseif (x1 <= -2e-71) tmp = t_0; elseif (x1 <= 2.1e-113) tmp = x2 * -6.0; elseif (x1 <= 6.5e+58) tmp = t_0; else tmp = x1 * (3.0 * (x1 * x1)); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(N[(x1 * N[(8.0 + N[(-12.0 / x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(x2 * x2), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -3.45e+90], N[(x1 * N[(-1.0 + N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -2e-71], t$95$0, If[LessEqual[x1, 2.1e-113], N[(x2 * -6.0), $MachinePrecision], If[LessEqual[x1, 6.5e+58], t$95$0, N[(x1 * N[(3.0 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \left(x1 \cdot \left(8 + \frac{-12}{x2}\right)\right) \cdot \left(x2 \cdot x2\right)\\
\mathbf{if}\;x1 \leq -3.45 \cdot 10^{+90}:\\
\;\;\;\;x1 \cdot \left(-1 + x1 \cdot \left(9 + x1 \cdot -19\right)\right)\\
\mathbf{elif}\;x1 \leq -2 \cdot 10^{-71}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;x1 \leq 2.1 \cdot 10^{-113}:\\
\;\;\;\;x2 \cdot -6\\
\mathbf{elif}\;x1 \leq 6.5 \cdot 10^{+58}:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;x1 \cdot \left(3 \cdot \left(x1 \cdot x1\right)\right)\\
\end{array}
\end{array}
if x1 < -3.44999999999999978e90Initial program 5.6%
Simplified5.6%
Taylor expanded in x1 around 0
Simplified77.8%
Taylor expanded in x2 around 0
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6494.9%
Simplified94.9%
if -3.44999999999999978e90 < x1 < -1.9999999999999998e-71 or 2.1e-113 < x1 < 6.49999999999999998e58Initial program 99.3%
Simplified99.6%
Taylor expanded in x2 around -inf
Simplified61.7%
Taylor expanded in x1 around 0
sub-negN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f6457.9%
Simplified57.9%
Taylor expanded in x1 around inf
*-lowering-*.f64N/A
sub-negN/A
+-lowering-+.f64N/A
associate-*r/N/A
metadata-evalN/A
distribute-neg-fracN/A
metadata-evalN/A
/-lowering-/.f6447.9%
Simplified47.9%
if -1.9999999999999998e-71 < x1 < 2.1e-113Initial program 99.5%
Taylor expanded in x1 around 0
*-lowering-*.f6471.4%
Simplified71.4%
if 6.49999999999999998e58 < x1 Initial program 44.1%
Simplified44.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f647.6%
Simplified7.6%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified76.1%
Taylor expanded in x1 around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6481.8%
Simplified81.8%
Final simplification69.9%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (* 8.0 (* x1 (* x2 x2)))))
(if (<= x1 -2.9e+88)
(* x1 (+ -1.0 (* x1 (+ 9.0 (* x1 -19.0)))))
(if (<= x1 -2.55e-67)
t_0
(if (<= x1 2.1e-113)
(* x2 -6.0)
(if (<= x1 2.2e+59) t_0 (* x1 (* 3.0 (* x1 x1)))))))))
double code(double x1, double x2) {
double t_0 = 8.0 * (x1 * (x2 * x2));
double tmp;
if (x1 <= -2.9e+88) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= -2.55e-67) {
tmp = t_0;
} else if (x1 <= 2.1e-113) {
tmp = x2 * -6.0;
} else if (x1 <= 2.2e+59) {
tmp = t_0;
} else {
tmp = x1 * (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) :: tmp
t_0 = 8.0d0 * (x1 * (x2 * x2))
if (x1 <= (-2.9d+88)) then
tmp = x1 * ((-1.0d0) + (x1 * (9.0d0 + (x1 * (-19.0d0)))))
else if (x1 <= (-2.55d-67)) then
tmp = t_0
else if (x1 <= 2.1d-113) then
tmp = x2 * (-6.0d0)
else if (x1 <= 2.2d+59) then
tmp = t_0
else
tmp = x1 * (3.0d0 * (x1 * x1))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = 8.0 * (x1 * (x2 * x2));
double tmp;
if (x1 <= -2.9e+88) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= -2.55e-67) {
tmp = t_0;
} else if (x1 <= 2.1e-113) {
tmp = x2 * -6.0;
} else if (x1 <= 2.2e+59) {
tmp = t_0;
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
def code(x1, x2): t_0 = 8.0 * (x1 * (x2 * x2)) tmp = 0 if x1 <= -2.9e+88: tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))) elif x1 <= -2.55e-67: tmp = t_0 elif x1 <= 2.1e-113: tmp = x2 * -6.0 elif x1 <= 2.2e+59: tmp = t_0 else: tmp = x1 * (3.0 * (x1 * x1)) return tmp
function code(x1, x2) t_0 = Float64(8.0 * Float64(x1 * Float64(x2 * x2))) tmp = 0.0 if (x1 <= -2.9e+88) tmp = Float64(x1 * Float64(-1.0 + Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))); elseif (x1 <= -2.55e-67) tmp = t_0; elseif (x1 <= 2.1e-113) tmp = Float64(x2 * -6.0); elseif (x1 <= 2.2e+59) tmp = t_0; else tmp = Float64(x1 * Float64(3.0 * Float64(x1 * x1))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = 8.0 * (x1 * (x2 * x2)); tmp = 0.0; if (x1 <= -2.9e+88) tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))); elseif (x1 <= -2.55e-67) tmp = t_0; elseif (x1 <= 2.1e-113) tmp = x2 * -6.0; elseif (x1 <= 2.2e+59) tmp = t_0; else tmp = x1 * (3.0 * (x1 * x1)); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(8.0 * N[(x1 * N[(x2 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -2.9e+88], N[(x1 * N[(-1.0 + N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -2.55e-67], t$95$0, If[LessEqual[x1, 2.1e-113], N[(x2 * -6.0), $MachinePrecision], If[LessEqual[x1, 2.2e+59], t$95$0, N[(x1 * N[(3.0 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 8 \cdot \left(x1 \cdot \left(x2 \cdot x2\right)\right)\\
\mathbf{if}\;x1 \leq -2.9 \cdot 10^{+88}:\\
\;\;\;\;x1 \cdot \left(-1 + x1 \cdot \left(9 + x1 \cdot -19\right)\right)\\
\mathbf{elif}\;x1 \leq -2.55 \cdot 10^{-67}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;x1 \leq 2.1 \cdot 10^{-113}:\\
\;\;\;\;x2 \cdot -6\\
\mathbf{elif}\;x1 \leq 2.2 \cdot 10^{+59}:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;x1 \cdot \left(3 \cdot \left(x1 \cdot x1\right)\right)\\
\end{array}
\end{array}
if x1 < -2.9e88Initial program 5.6%
Simplified5.6%
Taylor expanded in x1 around 0
Simplified77.8%
Taylor expanded in x2 around 0
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6494.9%
Simplified94.9%
if -2.9e88 < x1 < -2.54999999999999991e-67 or 2.1e-113 < x1 < 2.2e59Initial program 99.3%
Simplified99.6%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6471.5%
Simplified71.5%
Taylor expanded in x2 around inf
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6447.7%
Simplified47.7%
if -2.54999999999999991e-67 < x1 < 2.1e-113Initial program 99.5%
Taylor expanded in x1 around 0
*-lowering-*.f6471.4%
Simplified71.4%
if 2.2e59 < x1 Initial program 44.1%
Simplified44.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f647.6%
Simplified7.6%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified76.1%
Taylor expanded in x1 around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6481.8%
Simplified81.8%
Final simplification69.8%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (* 8.0 (* x1 (* x2 x2)))))
(if (<= x1 -3.8e+90)
(* x1 (+ -1.0 (* x1 9.0)))
(if (<= x1 -3.4e-69)
t_0
(if (<= x1 2.6e-113)
(* x2 -6.0)
(if (<= x1 2.2e+59) t_0 (* x1 (* 3.0 (* x1 x1)))))))))
double code(double x1, double x2) {
double t_0 = 8.0 * (x1 * (x2 * x2));
double tmp;
if (x1 <= -3.8e+90) {
tmp = x1 * (-1.0 + (x1 * 9.0));
} else if (x1 <= -3.4e-69) {
tmp = t_0;
} else if (x1 <= 2.6e-113) {
tmp = x2 * -6.0;
} else if (x1 <= 2.2e+59) {
tmp = t_0;
} else {
tmp = x1 * (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) :: tmp
t_0 = 8.0d0 * (x1 * (x2 * x2))
if (x1 <= (-3.8d+90)) then
tmp = x1 * ((-1.0d0) + (x1 * 9.0d0))
else if (x1 <= (-3.4d-69)) then
tmp = t_0
else if (x1 <= 2.6d-113) then
tmp = x2 * (-6.0d0)
else if (x1 <= 2.2d+59) then
tmp = t_0
else
tmp = x1 * (3.0d0 * (x1 * x1))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = 8.0 * (x1 * (x2 * x2));
double tmp;
if (x1 <= -3.8e+90) {
tmp = x1 * (-1.0 + (x1 * 9.0));
} else if (x1 <= -3.4e-69) {
tmp = t_0;
} else if (x1 <= 2.6e-113) {
tmp = x2 * -6.0;
} else if (x1 <= 2.2e+59) {
tmp = t_0;
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
def code(x1, x2): t_0 = 8.0 * (x1 * (x2 * x2)) tmp = 0 if x1 <= -3.8e+90: tmp = x1 * (-1.0 + (x1 * 9.0)) elif x1 <= -3.4e-69: tmp = t_0 elif x1 <= 2.6e-113: tmp = x2 * -6.0 elif x1 <= 2.2e+59: tmp = t_0 else: tmp = x1 * (3.0 * (x1 * x1)) return tmp
function code(x1, x2) t_0 = Float64(8.0 * Float64(x1 * Float64(x2 * x2))) tmp = 0.0 if (x1 <= -3.8e+90) tmp = Float64(x1 * Float64(-1.0 + Float64(x1 * 9.0))); elseif (x1 <= -3.4e-69) tmp = t_0; elseif (x1 <= 2.6e-113) tmp = Float64(x2 * -6.0); elseif (x1 <= 2.2e+59) tmp = t_0; else tmp = Float64(x1 * Float64(3.0 * Float64(x1 * x1))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = 8.0 * (x1 * (x2 * x2)); tmp = 0.0; if (x1 <= -3.8e+90) tmp = x1 * (-1.0 + (x1 * 9.0)); elseif (x1 <= -3.4e-69) tmp = t_0; elseif (x1 <= 2.6e-113) tmp = x2 * -6.0; elseif (x1 <= 2.2e+59) tmp = t_0; else tmp = x1 * (3.0 * (x1 * x1)); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(8.0 * N[(x1 * N[(x2 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -3.8e+90], N[(x1 * N[(-1.0 + N[(x1 * 9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -3.4e-69], t$95$0, If[LessEqual[x1, 2.6e-113], N[(x2 * -6.0), $MachinePrecision], If[LessEqual[x1, 2.2e+59], t$95$0, N[(x1 * N[(3.0 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 8 \cdot \left(x1 \cdot \left(x2 \cdot x2\right)\right)\\
\mathbf{if}\;x1 \leq -3.8 \cdot 10^{+90}:\\
\;\;\;\;x1 \cdot \left(-1 + x1 \cdot 9\right)\\
\mathbf{elif}\;x1 \leq -3.4 \cdot 10^{-69}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;x1 \leq 2.6 \cdot 10^{-113}:\\
\;\;\;\;x2 \cdot -6\\
\mathbf{elif}\;x1 \leq 2.2 \cdot 10^{+59}:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;x1 \cdot \left(3 \cdot \left(x1 \cdot x1\right)\right)\\
\end{array}
\end{array}
if x1 < -3.8000000000000001e90Initial program 5.6%
Simplified5.6%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f640.0%
Simplified0.0%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified51.8%
Taylor expanded in x2 around 0
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6469.2%
Simplified69.2%
if -3.8000000000000001e90 < x1 < -3.40000000000000008e-69 or 2.5999999999999999e-113 < x1 < 2.2e59Initial program 99.3%
Simplified99.6%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6471.5%
Simplified71.5%
Taylor expanded in x2 around inf
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6447.7%
Simplified47.7%
if -3.40000000000000008e-69 < x1 < 2.5999999999999999e-113Initial program 99.5%
Taylor expanded in x1 around 0
*-lowering-*.f6471.4%
Simplified71.4%
if 2.2e59 < x1 Initial program 44.1%
Simplified44.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f647.6%
Simplified7.6%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified76.1%
Taylor expanded in x1 around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6481.8%
Simplified81.8%
Final simplification66.2%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (* 8.0 (* x1 (* x2 x2)))))
(if (<= x1 -3.1e+38)
(* 8.0 (* x2 (* x1 x1)))
(if (<= x1 -9.5e-70)
t_0
(if (<= x1 4.9e-113)
(* x2 -6.0)
(if (<= x1 2.1e+59) t_0 (* x1 (* 3.0 (* x1 x1)))))))))
double code(double x1, double x2) {
double t_0 = 8.0 * (x1 * (x2 * x2));
double tmp;
if (x1 <= -3.1e+38) {
tmp = 8.0 * (x2 * (x1 * x1));
} else if (x1 <= -9.5e-70) {
tmp = t_0;
} else if (x1 <= 4.9e-113) {
tmp = x2 * -6.0;
} else if (x1 <= 2.1e+59) {
tmp = t_0;
} else {
tmp = x1 * (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) :: tmp
t_0 = 8.0d0 * (x1 * (x2 * x2))
if (x1 <= (-3.1d+38)) then
tmp = 8.0d0 * (x2 * (x1 * x1))
else if (x1 <= (-9.5d-70)) then
tmp = t_0
else if (x1 <= 4.9d-113) then
tmp = x2 * (-6.0d0)
else if (x1 <= 2.1d+59) then
tmp = t_0
else
tmp = x1 * (3.0d0 * (x1 * x1))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = 8.0 * (x1 * (x2 * x2));
double tmp;
if (x1 <= -3.1e+38) {
tmp = 8.0 * (x2 * (x1 * x1));
} else if (x1 <= -9.5e-70) {
tmp = t_0;
} else if (x1 <= 4.9e-113) {
tmp = x2 * -6.0;
} else if (x1 <= 2.1e+59) {
tmp = t_0;
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
def code(x1, x2): t_0 = 8.0 * (x1 * (x2 * x2)) tmp = 0 if x1 <= -3.1e+38: tmp = 8.0 * (x2 * (x1 * x1)) elif x1 <= -9.5e-70: tmp = t_0 elif x1 <= 4.9e-113: tmp = x2 * -6.0 elif x1 <= 2.1e+59: tmp = t_0 else: tmp = x1 * (3.0 * (x1 * x1)) return tmp
function code(x1, x2) t_0 = Float64(8.0 * Float64(x1 * Float64(x2 * x2))) tmp = 0.0 if (x1 <= -3.1e+38) tmp = Float64(8.0 * Float64(x2 * Float64(x1 * x1))); elseif (x1 <= -9.5e-70) tmp = t_0; elseif (x1 <= 4.9e-113) tmp = Float64(x2 * -6.0); elseif (x1 <= 2.1e+59) tmp = t_0; else tmp = Float64(x1 * Float64(3.0 * Float64(x1 * x1))); end return tmp end
function tmp_2 = code(x1, x2) t_0 = 8.0 * (x1 * (x2 * x2)); tmp = 0.0; if (x1 <= -3.1e+38) tmp = 8.0 * (x2 * (x1 * x1)); elseif (x1 <= -9.5e-70) tmp = t_0; elseif (x1 <= 4.9e-113) tmp = x2 * -6.0; elseif (x1 <= 2.1e+59) tmp = t_0; else tmp = x1 * (3.0 * (x1 * x1)); end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(8.0 * N[(x1 * N[(x2 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -3.1e+38], N[(8.0 * N[(x2 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, -9.5e-70], t$95$0, If[LessEqual[x1, 4.9e-113], N[(x2 * -6.0), $MachinePrecision], If[LessEqual[x1, 2.1e+59], t$95$0, N[(x1 * N[(3.0 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 8 \cdot \left(x1 \cdot \left(x2 \cdot x2\right)\right)\\
\mathbf{if}\;x1 \leq -3.1 \cdot 10^{+38}:\\
\;\;\;\;8 \cdot \left(x2 \cdot \left(x1 \cdot x1\right)\right)\\
\mathbf{elif}\;x1 \leq -9.5 \cdot 10^{-70}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;x1 \leq 4.9 \cdot 10^{-113}:\\
\;\;\;\;x2 \cdot -6\\
\mathbf{elif}\;x1 \leq 2.1 \cdot 10^{+59}:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;x1 \cdot \left(3 \cdot \left(x1 \cdot x1\right)\right)\\
\end{array}
\end{array}
if x1 < -3.10000000000000018e38Initial program 35.7%
Simplified35.8%
Taylor expanded in x2 around -inf
Simplified9.9%
Taylor expanded in x1 around inf
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6441.1%
Simplified41.1%
if -3.10000000000000018e38 < x1 < -9.4999999999999994e-70 or 4.9000000000000003e-113 < x1 < 2.09999999999999984e59Initial program 99.3%
Simplified99.5%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6483.5%
Simplified83.5%
Taylor expanded in x2 around inf
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6452.8%
Simplified52.8%
if -9.4999999999999994e-70 < x1 < 4.9000000000000003e-113Initial program 99.5%
Taylor expanded in x1 around 0
*-lowering-*.f6471.4%
Simplified71.4%
if 2.09999999999999984e59 < x1 Initial program 44.1%
Simplified44.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f647.6%
Simplified7.6%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified76.1%
Taylor expanded in x1 around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6481.8%
Simplified81.8%
Final simplification63.0%
(FPCore (x1 x2)
:precision binary64
(let* ((t_0 (* 8.0 (* x2 (* x1 x1)))) (t_1 (* 8.0 (* x1 (* x2 x2)))))
(if (<= x1 -5.1e+38)
t_0
(if (<= x1 -3.9e-72)
t_1
(if (<= x1 4.5e-113) (* x2 -6.0) (if (<= x1 1.46e+63) t_1 t_0))))))
double code(double x1, double x2) {
double t_0 = 8.0 * (x2 * (x1 * x1));
double t_1 = 8.0 * (x1 * (x2 * x2));
double tmp;
if (x1 <= -5.1e+38) {
tmp = t_0;
} else if (x1 <= -3.9e-72) {
tmp = t_1;
} else if (x1 <= 4.5e-113) {
tmp = x2 * -6.0;
} else if (x1 <= 1.46e+63) {
tmp = t_1;
} else {
tmp = 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 = 8.0d0 * (x2 * (x1 * x1))
t_1 = 8.0d0 * (x1 * (x2 * x2))
if (x1 <= (-5.1d+38)) then
tmp = t_0
else if (x1 <= (-3.9d-72)) then
tmp = t_1
else if (x1 <= 4.5d-113) then
tmp = x2 * (-6.0d0)
else if (x1 <= 1.46d+63) then
tmp = t_1
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = 8.0 * (x2 * (x1 * x1));
double t_1 = 8.0 * (x1 * (x2 * x2));
double tmp;
if (x1 <= -5.1e+38) {
tmp = t_0;
} else if (x1 <= -3.9e-72) {
tmp = t_1;
} else if (x1 <= 4.5e-113) {
tmp = x2 * -6.0;
} else if (x1 <= 1.46e+63) {
tmp = t_1;
} else {
tmp = t_0;
}
return tmp;
}
def code(x1, x2): t_0 = 8.0 * (x2 * (x1 * x1)) t_1 = 8.0 * (x1 * (x2 * x2)) tmp = 0 if x1 <= -5.1e+38: tmp = t_0 elif x1 <= -3.9e-72: tmp = t_1 elif x1 <= 4.5e-113: tmp = x2 * -6.0 elif x1 <= 1.46e+63: tmp = t_1 else: tmp = t_0 return tmp
function code(x1, x2) t_0 = Float64(8.0 * Float64(x2 * Float64(x1 * x1))) t_1 = Float64(8.0 * Float64(x1 * Float64(x2 * x2))) tmp = 0.0 if (x1 <= -5.1e+38) tmp = t_0; elseif (x1 <= -3.9e-72) tmp = t_1; elseif (x1 <= 4.5e-113) tmp = Float64(x2 * -6.0); elseif (x1 <= 1.46e+63) tmp = t_1; else tmp = t_0; end return tmp end
function tmp_2 = code(x1, x2) t_0 = 8.0 * (x2 * (x1 * x1)); t_1 = 8.0 * (x1 * (x2 * x2)); tmp = 0.0; if (x1 <= -5.1e+38) tmp = t_0; elseif (x1 <= -3.9e-72) tmp = t_1; elseif (x1 <= 4.5e-113) tmp = x2 * -6.0; elseif (x1 <= 1.46e+63) tmp = t_1; else tmp = t_0; end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(8.0 * N[(x2 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(8.0 * N[(x1 * N[(x2 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -5.1e+38], t$95$0, If[LessEqual[x1, -3.9e-72], t$95$1, If[LessEqual[x1, 4.5e-113], N[(x2 * -6.0), $MachinePrecision], If[LessEqual[x1, 1.46e+63], t$95$1, t$95$0]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 8 \cdot \left(x2 \cdot \left(x1 \cdot x1\right)\right)\\
t_1 := 8 \cdot \left(x1 \cdot \left(x2 \cdot x2\right)\right)\\
\mathbf{if}\;x1 \leq -5.1 \cdot 10^{+38}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;x1 \leq -3.9 \cdot 10^{-72}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x1 \leq 4.5 \cdot 10^{-113}:\\
\;\;\;\;x2 \cdot -6\\
\mathbf{elif}\;x1 \leq 1.46 \cdot 10^{+63}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if x1 < -5.1000000000000001e38 or 1.4599999999999999e63 < x1 Initial program 39.3%
Simplified39.3%
Taylor expanded in x2 around -inf
Simplified5.3%
Taylor expanded in x1 around inf
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6441.6%
Simplified41.6%
if -5.1000000000000001e38 < x1 < -3.9e-72 or 4.5000000000000001e-113 < x1 < 1.4599999999999999e63Initial program 99.3%
Simplified99.5%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6482.2%
Simplified82.2%
Taylor expanded in x2 around inf
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6452.0%
Simplified52.0%
if -3.9e-72 < x1 < 4.5000000000000001e-113Initial program 99.5%
Taylor expanded in x1 around 0
*-lowering-*.f6471.4%
Simplified71.4%
Final simplification54.8%
(FPCore (x1 x2)
:precision binary64
(if (<= x1 -6.8e+78)
(*
(* x1 (* x1 x1))
(+ (* 4.0 (* x2 (+ 3.0 (* x2 -2.0)))) (+ -19.0 (* x2 12.0))))
(if (<= x1 2.2e+59)
(+ (* x2 -6.0) (* x1 (+ -1.0 (* (* x2 4.0) (+ (* 2.0 x2) -3.0)))))
(* x1 (* 3.0 (* x1 x1))))))
double code(double x1, double x2) {
double tmp;
if (x1 <= -6.8e+78) {
tmp = (x1 * (x1 * x1)) * ((4.0 * (x2 * (3.0 + (x2 * -2.0)))) + (-19.0 + (x2 * 12.0)));
} else if (x1 <= 2.2e+59) {
tmp = (x2 * -6.0) + (x1 * (-1.0 + ((x2 * 4.0) * ((2.0 * x2) + -3.0))));
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: tmp
if (x1 <= (-6.8d+78)) then
tmp = (x1 * (x1 * x1)) * ((4.0d0 * (x2 * (3.0d0 + (x2 * (-2.0d0))))) + ((-19.0d0) + (x2 * 12.0d0)))
else if (x1 <= 2.2d+59) then
tmp = (x2 * (-6.0d0)) + (x1 * ((-1.0d0) + ((x2 * 4.0d0) * ((2.0d0 * x2) + (-3.0d0)))))
else
tmp = x1 * (3.0d0 * (x1 * x1))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double tmp;
if (x1 <= -6.8e+78) {
tmp = (x1 * (x1 * x1)) * ((4.0 * (x2 * (3.0 + (x2 * -2.0)))) + (-19.0 + (x2 * 12.0)));
} else if (x1 <= 2.2e+59) {
tmp = (x2 * -6.0) + (x1 * (-1.0 + ((x2 * 4.0) * ((2.0 * x2) + -3.0))));
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
def code(x1, x2): tmp = 0 if x1 <= -6.8e+78: tmp = (x1 * (x1 * x1)) * ((4.0 * (x2 * (3.0 + (x2 * -2.0)))) + (-19.0 + (x2 * 12.0))) elif x1 <= 2.2e+59: tmp = (x2 * -6.0) + (x1 * (-1.0 + ((x2 * 4.0) * ((2.0 * x2) + -3.0)))) else: tmp = x1 * (3.0 * (x1 * x1)) return tmp
function code(x1, x2) tmp = 0.0 if (x1 <= -6.8e+78) tmp = Float64(Float64(x1 * Float64(x1 * x1)) * Float64(Float64(4.0 * Float64(x2 * Float64(3.0 + Float64(x2 * -2.0)))) + Float64(-19.0 + Float64(x2 * 12.0)))); elseif (x1 <= 2.2e+59) tmp = Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(-1.0 + Float64(Float64(x2 * 4.0) * Float64(Float64(2.0 * x2) + -3.0))))); else tmp = Float64(x1 * Float64(3.0 * Float64(x1 * x1))); end return tmp end
function tmp_2 = code(x1, x2) tmp = 0.0; if (x1 <= -6.8e+78) tmp = (x1 * (x1 * x1)) * ((4.0 * (x2 * (3.0 + (x2 * -2.0)))) + (-19.0 + (x2 * 12.0))); elseif (x1 <= 2.2e+59) tmp = (x2 * -6.0) + (x1 * (-1.0 + ((x2 * 4.0) * ((2.0 * x2) + -3.0)))); else tmp = x1 * (3.0 * (x1 * x1)); end tmp_2 = tmp; end
code[x1_, x2_] := If[LessEqual[x1, -6.8e+78], N[(N[(x1 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision] * N[(N[(4.0 * N[(x2 * N[(3.0 + N[(x2 * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-19.0 + N[(x2 * 12.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 2.2e+59], N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(-1.0 + N[(N[(x2 * 4.0), $MachinePrecision] * N[(N[(2.0 * x2), $MachinePrecision] + -3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 * N[(3.0 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x1 \leq -6.8 \cdot 10^{+78}:\\
\;\;\;\;\left(x1 \cdot \left(x1 \cdot x1\right)\right) \cdot \left(4 \cdot \left(x2 \cdot \left(3 + x2 \cdot -2\right)\right) + \left(-19 + x2 \cdot 12\right)\right)\\
\mathbf{elif}\;x1 \leq 2.2 \cdot 10^{+59}:\\
\;\;\;\;x2 \cdot -6 + x1 \cdot \left(-1 + \left(x2 \cdot 4\right) \cdot \left(2 \cdot x2 + -3\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 \cdot \left(3 \cdot \left(x1 \cdot x1\right)\right)\\
\end{array}
\end{array}
if x1 < -6.80000000000000014e78Initial program 19.0%
Simplified19.0%
Taylor expanded in x1 around 0
Simplified69.7%
Taylor expanded in x1 around inf
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
cancel-sign-sub-invN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6488.8%
Simplified88.8%
if -6.80000000000000014e78 < x1 < 2.2e59Initial program 99.4%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6484.0%
Simplified84.0%
if 2.2e59 < x1 Initial program 44.1%
Simplified44.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f647.6%
Simplified7.6%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified76.1%
Taylor expanded in x1 around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6481.8%
Simplified81.8%
Final simplification84.4%
(FPCore (x1 x2)
:precision binary64
(if (<= x1 -2.65e+90)
(* x1 (+ -1.0 (* x1 (+ 9.0 (* x1 -19.0)))))
(if (<= x1 2.2e+59)
(+ (* x2 -6.0) (* x1 (+ -1.0 (* (* x2 4.0) (+ (* 2.0 x2) -3.0)))))
(* x1 (* 3.0 (* x1 x1))))))
double code(double x1, double x2) {
double tmp;
if (x1 <= -2.65e+90) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= 2.2e+59) {
tmp = (x2 * -6.0) + (x1 * (-1.0 + ((x2 * 4.0) * ((2.0 * x2) + -3.0))));
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: tmp
if (x1 <= (-2.65d+90)) then
tmp = x1 * ((-1.0d0) + (x1 * (9.0d0 + (x1 * (-19.0d0)))))
else if (x1 <= 2.2d+59) then
tmp = (x2 * (-6.0d0)) + (x1 * ((-1.0d0) + ((x2 * 4.0d0) * ((2.0d0 * x2) + (-3.0d0)))))
else
tmp = x1 * (3.0d0 * (x1 * x1))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double tmp;
if (x1 <= -2.65e+90) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= 2.2e+59) {
tmp = (x2 * -6.0) + (x1 * (-1.0 + ((x2 * 4.0) * ((2.0 * x2) + -3.0))));
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
def code(x1, x2): tmp = 0 if x1 <= -2.65e+90: tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))) elif x1 <= 2.2e+59: tmp = (x2 * -6.0) + (x1 * (-1.0 + ((x2 * 4.0) * ((2.0 * x2) + -3.0)))) else: tmp = x1 * (3.0 * (x1 * x1)) return tmp
function code(x1, x2) tmp = 0.0 if (x1 <= -2.65e+90) tmp = Float64(x1 * Float64(-1.0 + Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))); elseif (x1 <= 2.2e+59) tmp = Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(-1.0 + Float64(Float64(x2 * 4.0) * Float64(Float64(2.0 * x2) + -3.0))))); else tmp = Float64(x1 * Float64(3.0 * Float64(x1 * x1))); end return tmp end
function tmp_2 = code(x1, x2) tmp = 0.0; if (x1 <= -2.65e+90) tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))); elseif (x1 <= 2.2e+59) tmp = (x2 * -6.0) + (x1 * (-1.0 + ((x2 * 4.0) * ((2.0 * x2) + -3.0)))); else tmp = x1 * (3.0 * (x1 * x1)); end tmp_2 = tmp; end
code[x1_, x2_] := If[LessEqual[x1, -2.65e+90], N[(x1 * N[(-1.0 + N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 2.2e+59], N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(-1.0 + N[(N[(x2 * 4.0), $MachinePrecision] * N[(N[(2.0 * x2), $MachinePrecision] + -3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 * N[(3.0 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x1 \leq -2.65 \cdot 10^{+90}:\\
\;\;\;\;x1 \cdot \left(-1 + x1 \cdot \left(9 + x1 \cdot -19\right)\right)\\
\mathbf{elif}\;x1 \leq 2.2 \cdot 10^{+59}:\\
\;\;\;\;x2 \cdot -6 + x1 \cdot \left(-1 + \left(x2 \cdot 4\right) \cdot \left(2 \cdot x2 + -3\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 \cdot \left(3 \cdot \left(x1 \cdot x1\right)\right)\\
\end{array}
\end{array}
if x1 < -2.64999999999999989e90Initial program 5.6%
Simplified5.6%
Taylor expanded in x1 around 0
Simplified77.8%
Taylor expanded in x2 around 0
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6494.9%
Simplified94.9%
if -2.64999999999999989e90 < x1 < 2.2e59Initial program 99.4%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6481.7%
Simplified81.7%
if 2.2e59 < x1 Initial program 44.1%
Simplified44.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f647.6%
Simplified7.6%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified76.1%
Taylor expanded in x1 around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6481.8%
Simplified81.8%
Final simplification83.6%
(FPCore (x1 x2)
:precision binary64
(if (<= x1 -1.65e+90)
(* x1 (+ -1.0 (* x1 (+ 9.0 (* x1 -19.0)))))
(if (<= x1 1.65e+59)
(+ (* x2 -6.0) (* x1 (* x2 (* x2 8.0))))
(* x1 (* 3.0 (* x1 x1))))))
double code(double x1, double x2) {
double tmp;
if (x1 <= -1.65e+90) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= 1.65e+59) {
tmp = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0)));
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
real(8) :: tmp
if (x1 <= (-1.65d+90)) then
tmp = x1 * ((-1.0d0) + (x1 * (9.0d0 + (x1 * (-19.0d0)))))
else if (x1 <= 1.65d+59) then
tmp = (x2 * (-6.0d0)) + (x1 * (x2 * (x2 * 8.0d0)))
else
tmp = x1 * (3.0d0 * (x1 * x1))
end if
code = tmp
end function
public static double code(double x1, double x2) {
double tmp;
if (x1 <= -1.65e+90) {
tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0))));
} else if (x1 <= 1.65e+59) {
tmp = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0)));
} else {
tmp = x1 * (3.0 * (x1 * x1));
}
return tmp;
}
def code(x1, x2): tmp = 0 if x1 <= -1.65e+90: tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))) elif x1 <= 1.65e+59: tmp = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0))) else: tmp = x1 * (3.0 * (x1 * x1)) return tmp
function code(x1, x2) tmp = 0.0 if (x1 <= -1.65e+90) tmp = Float64(x1 * Float64(-1.0 + Float64(x1 * Float64(9.0 + Float64(x1 * -19.0))))); elseif (x1 <= 1.65e+59) tmp = Float64(Float64(x2 * -6.0) + Float64(x1 * Float64(x2 * Float64(x2 * 8.0)))); else tmp = Float64(x1 * Float64(3.0 * Float64(x1 * x1))); end return tmp end
function tmp_2 = code(x1, x2) tmp = 0.0; if (x1 <= -1.65e+90) tmp = x1 * (-1.0 + (x1 * (9.0 + (x1 * -19.0)))); elseif (x1 <= 1.65e+59) tmp = (x2 * -6.0) + (x1 * (x2 * (x2 * 8.0))); else tmp = x1 * (3.0 * (x1 * x1)); end tmp_2 = tmp; end
code[x1_, x2_] := If[LessEqual[x1, -1.65e+90], N[(x1 * N[(-1.0 + N[(x1 * N[(9.0 + N[(x1 * -19.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x1, 1.65e+59], N[(N[(x2 * -6.0), $MachinePrecision] + N[(x1 * N[(x2 * N[(x2 * 8.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x1 * N[(3.0 * N[(x1 * x1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x1 \leq -1.65 \cdot 10^{+90}:\\
\;\;\;\;x1 \cdot \left(-1 + x1 \cdot \left(9 + x1 \cdot -19\right)\right)\\
\mathbf{elif}\;x1 \leq 1.65 \cdot 10^{+59}:\\
\;\;\;\;x2 \cdot -6 + x1 \cdot \left(x2 \cdot \left(x2 \cdot 8\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x1 \cdot \left(3 \cdot \left(x1 \cdot x1\right)\right)\\
\end{array}
\end{array}
if x1 < -1.65000000000000004e90Initial program 5.6%
Simplified5.6%
Taylor expanded in x1 around 0
Simplified77.8%
Taylor expanded in x2 around 0
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6494.9%
Simplified94.9%
if -1.65000000000000004e90 < x1 < 1.65e59Initial program 99.4%
Simplified99.6%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6481.2%
Simplified81.2%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified81.8%
Taylor expanded in x2 around inf
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6464.7%
Simplified64.7%
if 1.65e59 < x1 Initial program 44.1%
Simplified44.1%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f647.6%
Simplified7.6%
Taylor expanded in x1 around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate--l+N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
Simplified76.1%
Taylor expanded in x1 around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6481.8%
Simplified81.8%
Final simplification72.4%
(FPCore (x1 x2) :precision binary64 (let* ((t_0 (* 8.0 (* x1 (* x2 x2))))) (if (<= x1 -7.2e-72) t_0 (if (<= x1 3.8e-113) (* x2 -6.0) t_0))))
double code(double x1, double x2) {
double t_0 = 8.0 * (x1 * (x2 * x2));
double tmp;
if (x1 <= -7.2e-72) {
tmp = t_0;
} else if (x1 <= 3.8e-113) {
tmp = x2 * -6.0;
} else {
tmp = 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) :: tmp
t_0 = 8.0d0 * (x1 * (x2 * x2))
if (x1 <= (-7.2d-72)) then
tmp = t_0
else if (x1 <= 3.8d-113) then
tmp = x2 * (-6.0d0)
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x1, double x2) {
double t_0 = 8.0 * (x1 * (x2 * x2));
double tmp;
if (x1 <= -7.2e-72) {
tmp = t_0;
} else if (x1 <= 3.8e-113) {
tmp = x2 * -6.0;
} else {
tmp = t_0;
}
return tmp;
}
def code(x1, x2): t_0 = 8.0 * (x1 * (x2 * x2)) tmp = 0 if x1 <= -7.2e-72: tmp = t_0 elif x1 <= 3.8e-113: tmp = x2 * -6.0 else: tmp = t_0 return tmp
function code(x1, x2) t_0 = Float64(8.0 * Float64(x1 * Float64(x2 * x2))) tmp = 0.0 if (x1 <= -7.2e-72) tmp = t_0; elseif (x1 <= 3.8e-113) tmp = Float64(x2 * -6.0); else tmp = t_0; end return tmp end
function tmp_2 = code(x1, x2) t_0 = 8.0 * (x1 * (x2 * x2)); tmp = 0.0; if (x1 <= -7.2e-72) tmp = t_0; elseif (x1 <= 3.8e-113) tmp = x2 * -6.0; else tmp = t_0; end tmp_2 = tmp; end
code[x1_, x2_] := Block[{t$95$0 = N[(8.0 * N[(x1 * N[(x2 * x2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x1, -7.2e-72], t$95$0, If[LessEqual[x1, 3.8e-113], N[(x2 * -6.0), $MachinePrecision], t$95$0]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 8 \cdot \left(x1 \cdot \left(x2 \cdot x2\right)\right)\\
\mathbf{if}\;x1 \leq -7.2 \cdot 10^{-72}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;x1 \leq 3.8 \cdot 10^{-113}:\\
\;\;\;\;x2 \cdot -6\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if x1 < -7.2e-72 or 3.79999999999999983e-113 < x1 Initial program 61.2%
Simplified61.3%
Taylor expanded in x1 around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6435.5%
Simplified35.5%
Taylor expanded in x2 around inf
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6432.1%
Simplified32.1%
if -7.2e-72 < x1 < 3.79999999999999983e-113Initial program 99.5%
Taylor expanded in x1 around 0
*-lowering-*.f6471.4%
Simplified71.4%
Final simplification46.2%
(FPCore (x1 x2) :precision binary64 (+ x1 (* x2 -6.0)))
double code(double x1, double x2) {
return x1 + (x2 * -6.0);
}
real(8) function code(x1, x2)
real(8), intent (in) :: x1
real(8), intent (in) :: x2
code = x1 + (x2 * (-6.0d0))
end function
public static double code(double x1, double x2) {
return x1 + (x2 * -6.0);
}
def code(x1, x2): return x1 + (x2 * -6.0)
function code(x1, x2) return Float64(x1 + Float64(x2 * -6.0)) end
function tmp = code(x1, x2) tmp = x1 + (x2 * -6.0); end
code[x1_, x2_] := N[(x1 + N[(x2 * -6.0), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x1 + x2 \cdot -6
\end{array}
Initial program 75.0%
Taylor expanded in x1 around 0
*-lowering-*.f6429.6%
Simplified29.6%
Final simplification29.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 75.0%
Taylor expanded in x1 around 0
*-lowering-*.f6429.4%
Simplified29.4%
Final simplification29.4%
(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 75.0%
Taylor expanded in x1 around 0
*-lowering-*.f6429.6%
Simplified29.6%
Taylor expanded in x1 around inf
Simplified3.3%
herbie shell --seed 2024155
(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))))))