| Alternative 1 | |
|---|---|
| Error | 0.0 |
| Cost | 11209 |
(FPCore (x)
:precision binary64
(*
(/
(+
(+
(+
(+ (+ 1.0 (* 0.1049934947 (* x x))) (* 0.0424060604 (* (* x x) (* x x))))
(* 0.0072644182 (* (* (* x x) (* x x)) (* x x))))
(* 0.0005064034 (* (* (* (* x x) (* x x)) (* x x)) (* x x))))
(* 0.0001789971 (* (* (* (* (* x x) (* x x)) (* x x)) (* x x)) (* x x))))
(+
(+
(+
(+
(+
(+ 1.0 (* 0.7715471019 (* x x)))
(* 0.2909738639 (* (* x x) (* x x))))
(* 0.0694555761 (* (* (* x x) (* x x)) (* x x))))
(* 0.0140005442 (* (* (* (* x x) (* x x)) (* x x)) (* x x))))
(* 0.0008327945 (* (* (* (* (* x x) (* x x)) (* x x)) (* x x)) (* x x))))
(*
(* 2.0 0.0001789971)
(* (* (* (* (* (* x x) (* x x)) (* x x)) (* x x)) (* x x)) (* x x)))))
x))(FPCore (x)
:precision binary64
(let* ((t_0 (* x (* x (* x x)))) (t_1 (* t_0 t_0)) (t_2 (* (* x x) t_1)))
(if (<= x -200.0)
(+
(/ (/ 0.2514179000665374 x) (* x x))
(+
(/ 0.5 x)
(+
(/ 0.15298196345929074 (pow x 5.0))
(/ 11.259630434457211 (pow x 7.0)))))
(if (<= x 500.0)
(*
x
(/
(+
(+
(+ (+ 1.0 (* (* x x) 0.1049934947)) (* 0.0424060604 t_0))
(* 0.0072644182 (* (* x x) t_0)))
(+ (* 0.0005064034 t_1) (* 0.0001789971 t_2)))
(+
(+
(+
(+ 1.0 (* (* x x) 0.7715471019))
(+ (* t_0 0.2909738639) (* (* x x) (* t_0 0.0694555761))))
(* t_1 0.0140005442))
(+ (* t_2 0.0008327945) (* 0.0003579942 (* t_0 t_1))))))
(/ 1.0 (+ (* x 2.0) (/ -1.0056716002661497 x)))))))double code(double x) {
return ((((((1.0 + (0.1049934947 * (x * x))) + (0.0424060604 * ((x * x) * (x * x)))) + (0.0072644182 * (((x * x) * (x * x)) * (x * x)))) + (0.0005064034 * ((((x * x) * (x * x)) * (x * x)) * (x * x)))) + (0.0001789971 * (((((x * x) * (x * x)) * (x * x)) * (x * x)) * (x * x)))) / ((((((1.0 + (0.7715471019 * (x * x))) + (0.2909738639 * ((x * x) * (x * x)))) + (0.0694555761 * (((x * x) * (x * x)) * (x * x)))) + (0.0140005442 * ((((x * x) * (x * x)) * (x * x)) * (x * x)))) + (0.0008327945 * (((((x * x) * (x * x)) * (x * x)) * (x * x)) * (x * x)))) + ((2.0 * 0.0001789971) * ((((((x * x) * (x * x)) * (x * x)) * (x * x)) * (x * x)) * (x * x))))) * x;
}
double code(double x) {
double t_0 = x * (x * (x * x));
double t_1 = t_0 * t_0;
double t_2 = (x * x) * t_1;
double tmp;
if (x <= -200.0) {
tmp = ((0.2514179000665374 / x) / (x * x)) + ((0.5 / x) + ((0.15298196345929074 / pow(x, 5.0)) + (11.259630434457211 / pow(x, 7.0))));
} else if (x <= 500.0) {
tmp = x * (((((1.0 + ((x * x) * 0.1049934947)) + (0.0424060604 * t_0)) + (0.0072644182 * ((x * x) * t_0))) + ((0.0005064034 * t_1) + (0.0001789971 * t_2))) / ((((1.0 + ((x * x) * 0.7715471019)) + ((t_0 * 0.2909738639) + ((x * x) * (t_0 * 0.0694555761)))) + (t_1 * 0.0140005442)) + ((t_2 * 0.0008327945) + (0.0003579942 * (t_0 * t_1)))));
} else {
tmp = 1.0 / ((x * 2.0) + (-1.0056716002661497 / x));
}
return tmp;
}
real(8) function code(x)
real(8), intent (in) :: x
code = ((((((1.0d0 + (0.1049934947d0 * (x * x))) + (0.0424060604d0 * ((x * x) * (x * x)))) + (0.0072644182d0 * (((x * x) * (x * x)) * (x * x)))) + (0.0005064034d0 * ((((x * x) * (x * x)) * (x * x)) * (x * x)))) + (0.0001789971d0 * (((((x * x) * (x * x)) * (x * x)) * (x * x)) * (x * x)))) / ((((((1.0d0 + (0.7715471019d0 * (x * x))) + (0.2909738639d0 * ((x * x) * (x * x)))) + (0.0694555761d0 * (((x * x) * (x * x)) * (x * x)))) + (0.0140005442d0 * ((((x * x) * (x * x)) * (x * x)) * (x * x)))) + (0.0008327945d0 * (((((x * x) * (x * x)) * (x * x)) * (x * x)) * (x * x)))) + ((2.0d0 * 0.0001789971d0) * ((((((x * x) * (x * x)) * (x * x)) * (x * x)) * (x * x)) * (x * x))))) * x
end function
real(8) function code(x)
real(8), intent (in) :: x
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_0 = x * (x * (x * x))
t_1 = t_0 * t_0
t_2 = (x * x) * t_1
if (x <= (-200.0d0)) then
tmp = ((0.2514179000665374d0 / x) / (x * x)) + ((0.5d0 / x) + ((0.15298196345929074d0 / (x ** 5.0d0)) + (11.259630434457211d0 / (x ** 7.0d0))))
else if (x <= 500.0d0) then
tmp = x * (((((1.0d0 + ((x * x) * 0.1049934947d0)) + (0.0424060604d0 * t_0)) + (0.0072644182d0 * ((x * x) * t_0))) + ((0.0005064034d0 * t_1) + (0.0001789971d0 * t_2))) / ((((1.0d0 + ((x * x) * 0.7715471019d0)) + ((t_0 * 0.2909738639d0) + ((x * x) * (t_0 * 0.0694555761d0)))) + (t_1 * 0.0140005442d0)) + ((t_2 * 0.0008327945d0) + (0.0003579942d0 * (t_0 * t_1)))))
else
tmp = 1.0d0 / ((x * 2.0d0) + ((-1.0056716002661497d0) / x))
end if
code = tmp
end function
public static double code(double x) {
return ((((((1.0 + (0.1049934947 * (x * x))) + (0.0424060604 * ((x * x) * (x * x)))) + (0.0072644182 * (((x * x) * (x * x)) * (x * x)))) + (0.0005064034 * ((((x * x) * (x * x)) * (x * x)) * (x * x)))) + (0.0001789971 * (((((x * x) * (x * x)) * (x * x)) * (x * x)) * (x * x)))) / ((((((1.0 + (0.7715471019 * (x * x))) + (0.2909738639 * ((x * x) * (x * x)))) + (0.0694555761 * (((x * x) * (x * x)) * (x * x)))) + (0.0140005442 * ((((x * x) * (x * x)) * (x * x)) * (x * x)))) + (0.0008327945 * (((((x * x) * (x * x)) * (x * x)) * (x * x)) * (x * x)))) + ((2.0 * 0.0001789971) * ((((((x * x) * (x * x)) * (x * x)) * (x * x)) * (x * x)) * (x * x))))) * x;
}
public static double code(double x) {
double t_0 = x * (x * (x * x));
double t_1 = t_0 * t_0;
double t_2 = (x * x) * t_1;
double tmp;
if (x <= -200.0) {
tmp = ((0.2514179000665374 / x) / (x * x)) + ((0.5 / x) + ((0.15298196345929074 / Math.pow(x, 5.0)) + (11.259630434457211 / Math.pow(x, 7.0))));
} else if (x <= 500.0) {
tmp = x * (((((1.0 + ((x * x) * 0.1049934947)) + (0.0424060604 * t_0)) + (0.0072644182 * ((x * x) * t_0))) + ((0.0005064034 * t_1) + (0.0001789971 * t_2))) / ((((1.0 + ((x * x) * 0.7715471019)) + ((t_0 * 0.2909738639) + ((x * x) * (t_0 * 0.0694555761)))) + (t_1 * 0.0140005442)) + ((t_2 * 0.0008327945) + (0.0003579942 * (t_0 * t_1)))));
} else {
tmp = 1.0 / ((x * 2.0) + (-1.0056716002661497 / x));
}
return tmp;
}
def code(x): return ((((((1.0 + (0.1049934947 * (x * x))) + (0.0424060604 * ((x * x) * (x * x)))) + (0.0072644182 * (((x * x) * (x * x)) * (x * x)))) + (0.0005064034 * ((((x * x) * (x * x)) * (x * x)) * (x * x)))) + (0.0001789971 * (((((x * x) * (x * x)) * (x * x)) * (x * x)) * (x * x)))) / ((((((1.0 + (0.7715471019 * (x * x))) + (0.2909738639 * ((x * x) * (x * x)))) + (0.0694555761 * (((x * x) * (x * x)) * (x * x)))) + (0.0140005442 * ((((x * x) * (x * x)) * (x * x)) * (x * x)))) + (0.0008327945 * (((((x * x) * (x * x)) * (x * x)) * (x * x)) * (x * x)))) + ((2.0 * 0.0001789971) * ((((((x * x) * (x * x)) * (x * x)) * (x * x)) * (x * x)) * (x * x))))) * x
def code(x): t_0 = x * (x * (x * x)) t_1 = t_0 * t_0 t_2 = (x * x) * t_1 tmp = 0 if x <= -200.0: tmp = ((0.2514179000665374 / x) / (x * x)) + ((0.5 / x) + ((0.15298196345929074 / math.pow(x, 5.0)) + (11.259630434457211 / math.pow(x, 7.0)))) elif x <= 500.0: tmp = x * (((((1.0 + ((x * x) * 0.1049934947)) + (0.0424060604 * t_0)) + (0.0072644182 * ((x * x) * t_0))) + ((0.0005064034 * t_1) + (0.0001789971 * t_2))) / ((((1.0 + ((x * x) * 0.7715471019)) + ((t_0 * 0.2909738639) + ((x * x) * (t_0 * 0.0694555761)))) + (t_1 * 0.0140005442)) + ((t_2 * 0.0008327945) + (0.0003579942 * (t_0 * t_1))))) else: tmp = 1.0 / ((x * 2.0) + (-1.0056716002661497 / x)) return tmp
function code(x) return Float64(Float64(Float64(Float64(Float64(Float64(Float64(1.0 + Float64(0.1049934947 * Float64(x * x))) + Float64(0.0424060604 * Float64(Float64(x * x) * Float64(x * x)))) + Float64(0.0072644182 * Float64(Float64(Float64(x * x) * Float64(x * x)) * Float64(x * x)))) + Float64(0.0005064034 * Float64(Float64(Float64(Float64(x * x) * Float64(x * x)) * Float64(x * x)) * Float64(x * x)))) + Float64(0.0001789971 * Float64(Float64(Float64(Float64(Float64(x * x) * Float64(x * x)) * Float64(x * x)) * Float64(x * x)) * Float64(x * x)))) / Float64(Float64(Float64(Float64(Float64(Float64(1.0 + Float64(0.7715471019 * Float64(x * x))) + Float64(0.2909738639 * Float64(Float64(x * x) * Float64(x * x)))) + Float64(0.0694555761 * Float64(Float64(Float64(x * x) * Float64(x * x)) * Float64(x * x)))) + Float64(0.0140005442 * Float64(Float64(Float64(Float64(x * x) * Float64(x * x)) * Float64(x * x)) * Float64(x * x)))) + Float64(0.0008327945 * Float64(Float64(Float64(Float64(Float64(x * x) * Float64(x * x)) * Float64(x * x)) * Float64(x * x)) * Float64(x * x)))) + Float64(Float64(2.0 * 0.0001789971) * Float64(Float64(Float64(Float64(Float64(Float64(x * x) * Float64(x * x)) * Float64(x * x)) * Float64(x * x)) * Float64(x * x)) * Float64(x * x))))) * x) end
function code(x) t_0 = Float64(x * Float64(x * Float64(x * x))) t_1 = Float64(t_0 * t_0) t_2 = Float64(Float64(x * x) * t_1) tmp = 0.0 if (x <= -200.0) tmp = Float64(Float64(Float64(0.2514179000665374 / x) / Float64(x * x)) + Float64(Float64(0.5 / x) + Float64(Float64(0.15298196345929074 / (x ^ 5.0)) + Float64(11.259630434457211 / (x ^ 7.0))))); elseif (x <= 500.0) tmp = Float64(x * Float64(Float64(Float64(Float64(Float64(1.0 + Float64(Float64(x * x) * 0.1049934947)) + Float64(0.0424060604 * t_0)) + Float64(0.0072644182 * Float64(Float64(x * x) * t_0))) + Float64(Float64(0.0005064034 * t_1) + Float64(0.0001789971 * t_2))) / Float64(Float64(Float64(Float64(1.0 + Float64(Float64(x * x) * 0.7715471019)) + Float64(Float64(t_0 * 0.2909738639) + Float64(Float64(x * x) * Float64(t_0 * 0.0694555761)))) + Float64(t_1 * 0.0140005442)) + Float64(Float64(t_2 * 0.0008327945) + Float64(0.0003579942 * Float64(t_0 * t_1)))))); else tmp = Float64(1.0 / Float64(Float64(x * 2.0) + Float64(-1.0056716002661497 / x))); end return tmp end
function tmp = code(x) tmp = ((((((1.0 + (0.1049934947 * (x * x))) + (0.0424060604 * ((x * x) * (x * x)))) + (0.0072644182 * (((x * x) * (x * x)) * (x * x)))) + (0.0005064034 * ((((x * x) * (x * x)) * (x * x)) * (x * x)))) + (0.0001789971 * (((((x * x) * (x * x)) * (x * x)) * (x * x)) * (x * x)))) / ((((((1.0 + (0.7715471019 * (x * x))) + (0.2909738639 * ((x * x) * (x * x)))) + (0.0694555761 * (((x * x) * (x * x)) * (x * x)))) + (0.0140005442 * ((((x * x) * (x * x)) * (x * x)) * (x * x)))) + (0.0008327945 * (((((x * x) * (x * x)) * (x * x)) * (x * x)) * (x * x)))) + ((2.0 * 0.0001789971) * ((((((x * x) * (x * x)) * (x * x)) * (x * x)) * (x * x)) * (x * x))))) * x; end
function tmp_2 = code(x) t_0 = x * (x * (x * x)); t_1 = t_0 * t_0; t_2 = (x * x) * t_1; tmp = 0.0; if (x <= -200.0) tmp = ((0.2514179000665374 / x) / (x * x)) + ((0.5 / x) + ((0.15298196345929074 / (x ^ 5.0)) + (11.259630434457211 / (x ^ 7.0)))); elseif (x <= 500.0) tmp = x * (((((1.0 + ((x * x) * 0.1049934947)) + (0.0424060604 * t_0)) + (0.0072644182 * ((x * x) * t_0))) + ((0.0005064034 * t_1) + (0.0001789971 * t_2))) / ((((1.0 + ((x * x) * 0.7715471019)) + ((t_0 * 0.2909738639) + ((x * x) * (t_0 * 0.0694555761)))) + (t_1 * 0.0140005442)) + ((t_2 * 0.0008327945) + (0.0003579942 * (t_0 * t_1))))); else tmp = 1.0 / ((x * 2.0) + (-1.0056716002661497 / x)); end tmp_2 = tmp; end
code[x_] := N[(N[(N[(N[(N[(N[(N[(1.0 + N[(0.1049934947 * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(0.0424060604 * N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(0.0072644182 * N[(N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(0.0005064034 * N[(N[(N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(0.0001789971 * N[(N[(N[(N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(N[(N[(N[(N[(1.0 + N[(0.7715471019 * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(0.2909738639 * N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(0.0694555761 * N[(N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(0.0140005442 * N[(N[(N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(0.0008327945 * N[(N[(N[(N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(2.0 * 0.0001789971), $MachinePrecision] * N[(N[(N[(N[(N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * x), $MachinePrecision]
code[x_] := Block[{t$95$0 = N[(x * N[(x * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(t$95$0 * t$95$0), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x * x), $MachinePrecision] * t$95$1), $MachinePrecision]}, If[LessEqual[x, -200.0], N[(N[(N[(0.2514179000665374 / x), $MachinePrecision] / N[(x * x), $MachinePrecision]), $MachinePrecision] + N[(N[(0.5 / x), $MachinePrecision] + N[(N[(0.15298196345929074 / N[Power[x, 5.0], $MachinePrecision]), $MachinePrecision] + N[(11.259630434457211 / N[Power[x, 7.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 500.0], N[(x * N[(N[(N[(N[(N[(1.0 + N[(N[(x * x), $MachinePrecision] * 0.1049934947), $MachinePrecision]), $MachinePrecision] + N[(0.0424060604 * t$95$0), $MachinePrecision]), $MachinePrecision] + N[(0.0072644182 * N[(N[(x * x), $MachinePrecision] * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(0.0005064034 * t$95$1), $MachinePrecision] + N[(0.0001789971 * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(N[(N[(1.0 + N[(N[(x * x), $MachinePrecision] * 0.7715471019), $MachinePrecision]), $MachinePrecision] + N[(N[(t$95$0 * 0.2909738639), $MachinePrecision] + N[(N[(x * x), $MachinePrecision] * N[(t$95$0 * 0.0694555761), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(t$95$1 * 0.0140005442), $MachinePrecision]), $MachinePrecision] + N[(N[(t$95$2 * 0.0008327945), $MachinePrecision] + N[(0.0003579942 * N[(t$95$0 * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1.0 / N[(N[(x * 2.0), $MachinePrecision] + N[(-1.0056716002661497 / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\frac{\left(\left(\left(\left(1 + 0.1049934947 \cdot \left(x \cdot x\right)\right) + 0.0424060604 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0072644182 \cdot \left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0005064034 \cdot \left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0001789971 \cdot \left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)}{\left(\left(\left(\left(\left(1 + 0.7715471019 \cdot \left(x \cdot x\right)\right) + 0.2909738639 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0694555761 \cdot \left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0140005442 \cdot \left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0008327945 \cdot \left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + \left(2 \cdot 0.0001789971\right) \cdot \left(\left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)} \cdot x
\begin{array}{l}
t_0 := x \cdot \left(x \cdot \left(x \cdot x\right)\right)\\
t_1 := t_0 \cdot t_0\\
t_2 := \left(x \cdot x\right) \cdot t_1\\
\mathbf{if}\;x \leq -200:\\
\;\;\;\;\frac{\frac{0.2514179000665374}{x}}{x \cdot x} + \left(\frac{0.5}{x} + \left(\frac{0.15298196345929074}{{x}^{5}} + \frac{11.259630434457211}{{x}^{7}}\right)\right)\\
\mathbf{elif}\;x \leq 500:\\
\;\;\;\;x \cdot \frac{\left(\left(\left(1 + \left(x \cdot x\right) \cdot 0.1049934947\right) + 0.0424060604 \cdot t_0\right) + 0.0072644182 \cdot \left(\left(x \cdot x\right) \cdot t_0\right)\right) + \left(0.0005064034 \cdot t_1 + 0.0001789971 \cdot t_2\right)}{\left(\left(\left(1 + \left(x \cdot x\right) \cdot 0.7715471019\right) + \left(t_0 \cdot 0.2909738639 + \left(x \cdot x\right) \cdot \left(t_0 \cdot 0.0694555761\right)\right)\right) + t_1 \cdot 0.0140005442\right) + \left(t_2 \cdot 0.0008327945 + 0.0003579942 \cdot \left(t_0 \cdot t_1\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{x \cdot 2 + \frac{-1.0056716002661497}{x}}\\
\end{array}
Results
if x < -200Initial program 58.1
Simplified58.2
[Start]58.1 | \[ \frac{\left(\left(\left(\left(1 + 0.1049934947 \cdot \left(x \cdot x\right)\right) + 0.0424060604 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0072644182 \cdot \left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0005064034 \cdot \left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0001789971 \cdot \left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)}{\left(\left(\left(\left(\left(1 + 0.7715471019 \cdot \left(x \cdot x\right)\right) + 0.2909738639 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0694555761 \cdot \left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0140005442 \cdot \left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0008327945 \cdot \left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + \left(2 \cdot 0.0001789971\right) \cdot \left(\left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)} \cdot x
\] |
|---|---|
associate-*l/ [=>]58.2 | \[ \color{blue}{\frac{\left(\left(\left(\left(\left(1 + 0.1049934947 \cdot \left(x \cdot x\right)\right) + 0.0424060604 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0072644182 \cdot \left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0005064034 \cdot \left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0001789971 \cdot \left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) \cdot x}{\left(\left(\left(\left(\left(1 + 0.7715471019 \cdot \left(x \cdot x\right)\right) + 0.2909738639 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0694555761 \cdot \left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0140005442 \cdot \left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0008327945 \cdot \left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + \left(2 \cdot 0.0001789971\right) \cdot \left(\left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)}}
\] |
Taylor expanded in x around inf 0.0
Simplified0.0
[Start]0.0 | \[ 0.2514179000665374 \cdot \frac{1}{{x}^{3}} + \left(0.15298196345929074 \cdot \frac{1}{{x}^{5}} + \left(11.259630434457211 \cdot \frac{1}{{x}^{7}} + 0.5 \cdot \frac{1}{x}\right)\right)
\] |
|---|---|
associate-*r/ [=>]0.0 | \[ \color{blue}{\frac{0.2514179000665374 \cdot 1}{{x}^{3}}} + \left(0.15298196345929074 \cdot \frac{1}{{x}^{5}} + \left(11.259630434457211 \cdot \frac{1}{{x}^{7}} + 0.5 \cdot \frac{1}{x}\right)\right)
\] |
metadata-eval [=>]0.0 | \[ \frac{\color{blue}{0.2514179000665374}}{{x}^{3}} + \left(0.15298196345929074 \cdot \frac{1}{{x}^{5}} + \left(11.259630434457211 \cdot \frac{1}{{x}^{7}} + 0.5 \cdot \frac{1}{x}\right)\right)
\] |
associate-+r+ [=>]0.0 | \[ \frac{0.2514179000665374}{{x}^{3}} + \color{blue}{\left(\left(0.15298196345929074 \cdot \frac{1}{{x}^{5}} + 11.259630434457211 \cdot \frac{1}{{x}^{7}}\right) + 0.5 \cdot \frac{1}{x}\right)}
\] |
+-commutative [=>]0.0 | \[ \frac{0.2514179000665374}{{x}^{3}} + \color{blue}{\left(0.5 \cdot \frac{1}{x} + \left(0.15298196345929074 \cdot \frac{1}{{x}^{5}} + 11.259630434457211 \cdot \frac{1}{{x}^{7}}\right)\right)}
\] |
associate-*r/ [=>]0.0 | \[ \frac{0.2514179000665374}{{x}^{3}} + \left(\color{blue}{\frac{0.5 \cdot 1}{x}} + \left(0.15298196345929074 \cdot \frac{1}{{x}^{5}} + 11.259630434457211 \cdot \frac{1}{{x}^{7}}\right)\right)
\] |
metadata-eval [=>]0.0 | \[ \frac{0.2514179000665374}{{x}^{3}} + \left(\frac{\color{blue}{0.5}}{x} + \left(0.15298196345929074 \cdot \frac{1}{{x}^{5}} + 11.259630434457211 \cdot \frac{1}{{x}^{7}}\right)\right)
\] |
associate-*r/ [=>]0.0 | \[ \frac{0.2514179000665374}{{x}^{3}} + \left(\frac{0.5}{x} + \left(\color{blue}{\frac{0.15298196345929074 \cdot 1}{{x}^{5}}} + 11.259630434457211 \cdot \frac{1}{{x}^{7}}\right)\right)
\] |
metadata-eval [=>]0.0 | \[ \frac{0.2514179000665374}{{x}^{3}} + \left(\frac{0.5}{x} + \left(\frac{\color{blue}{0.15298196345929074}}{{x}^{5}} + 11.259630434457211 \cdot \frac{1}{{x}^{7}}\right)\right)
\] |
associate-*r/ [=>]0.0 | \[ \frac{0.2514179000665374}{{x}^{3}} + \left(\frac{0.5}{x} + \left(\frac{0.15298196345929074}{{x}^{5}} + \color{blue}{\frac{11.259630434457211 \cdot 1}{{x}^{7}}}\right)\right)
\] |
metadata-eval [=>]0.0 | \[ \frac{0.2514179000665374}{{x}^{3}} + \left(\frac{0.5}{x} + \left(\frac{0.15298196345929074}{{x}^{5}} + \frac{\color{blue}{11.259630434457211}}{{x}^{7}}\right)\right)
\] |
Applied egg-rr0.0
Applied egg-rr0.0
if -200 < x < 500Initial program 0.0
Simplified0.0
[Start]0.0 | \[ \frac{\left(\left(\left(\left(1 + 0.1049934947 \cdot \left(x \cdot x\right)\right) + 0.0424060604 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0072644182 \cdot \left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0005064034 \cdot \left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0001789971 \cdot \left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)}{\left(\left(\left(\left(\left(1 + 0.7715471019 \cdot \left(x \cdot x\right)\right) + 0.2909738639 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0694555761 \cdot \left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0140005442 \cdot \left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0008327945 \cdot \left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + \left(2 \cdot 0.0001789971\right) \cdot \left(\left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)} \cdot x
\] |
|---|---|
*-commutative [=>]0.0 | \[ \color{blue}{x \cdot \frac{\left(\left(\left(\left(1 + 0.1049934947 \cdot \left(x \cdot x\right)\right) + 0.0424060604 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0072644182 \cdot \left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0005064034 \cdot \left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0001789971 \cdot \left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)}{\left(\left(\left(\left(\left(1 + 0.7715471019 \cdot \left(x \cdot x\right)\right) + 0.2909738639 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0694555761 \cdot \left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0140005442 \cdot \left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0008327945 \cdot \left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + \left(2 \cdot 0.0001789971\right) \cdot \left(\left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)}}
\] |
if 500 < x Initial program 59.4
Simplified59.4
[Start]59.4 | \[ \frac{\left(\left(\left(\left(1 + 0.1049934947 \cdot \left(x \cdot x\right)\right) + 0.0424060604 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0072644182 \cdot \left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0005064034 \cdot \left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0001789971 \cdot \left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)}{\left(\left(\left(\left(\left(1 + 0.7715471019 \cdot \left(x \cdot x\right)\right) + 0.2909738639 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0694555761 \cdot \left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0140005442 \cdot \left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0008327945 \cdot \left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + \left(2 \cdot 0.0001789971\right) \cdot \left(\left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)} \cdot x
\] |
|---|---|
*-commutative [=>]59.4 | \[ \color{blue}{x \cdot \frac{\left(\left(\left(\left(1 + 0.1049934947 \cdot \left(x \cdot x\right)\right) + 0.0424060604 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0072644182 \cdot \left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0005064034 \cdot \left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0001789971 \cdot \left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)}{\left(\left(\left(\left(\left(1 + 0.7715471019 \cdot \left(x \cdot x\right)\right) + 0.2909738639 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0694555761 \cdot \left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0140005442 \cdot \left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + 0.0008327945 \cdot \left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)\right) + \left(2 \cdot 0.0001789971\right) \cdot \left(\left(\left(\left(\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right) \cdot \left(x \cdot x\right)\right)}}
\] |
Taylor expanded in x around inf 0.0
Simplified0.0
[Start]0.0 | \[ 0.2514179000665374 \cdot \frac{1}{{x}^{3}} + 0.5 \cdot \frac{1}{x}
\] |
|---|---|
associate-*r/ [=>]0.0 | \[ \color{blue}{\frac{0.2514179000665374 \cdot 1}{{x}^{3}}} + 0.5 \cdot \frac{1}{x}
\] |
metadata-eval [=>]0.0 | \[ \frac{\color{blue}{0.2514179000665374}}{{x}^{3}} + 0.5 \cdot \frac{1}{x}
\] |
associate-*r/ [=>]0.0 | \[ \frac{0.2514179000665374}{{x}^{3}} + \color{blue}{\frac{0.5 \cdot 1}{x}}
\] |
metadata-eval [=>]0.0 | \[ \frac{0.2514179000665374}{{x}^{3}} + \frac{\color{blue}{0.5}}{x}
\] |
Applied egg-rr0.0
Applied egg-rr0.1
Taylor expanded in x around inf 0.1
Simplified0.1
[Start]0.1 | \[ \frac{1}{2 \cdot x - 1.0056716002661497 \cdot \frac{1}{x}}
\] |
|---|---|
*-commutative [<=]0.1 | \[ \frac{1}{\color{blue}{x \cdot 2} - 1.0056716002661497 \cdot \frac{1}{x}}
\] |
associate-*r/ [=>]0.1 | \[ \frac{1}{x \cdot 2 - \color{blue}{\frac{1.0056716002661497 \cdot 1}{x}}}
\] |
metadata-eval [=>]0.1 | \[ \frac{1}{x \cdot 2 - \frac{\color{blue}{1.0056716002661497}}{x}}
\] |
Final simplification0.0
| Alternative 1 | |
|---|---|
| Error | 0.0 |
| Cost | 11209 |
| Alternative 2 | |
|---|---|
| Error | 0.3 |
| Cost | 1225 |
| Alternative 3 | |
|---|---|
| Error | 0.3 |
| Cost | 1225 |
| Alternative 4 | |
|---|---|
| Error | 0.5 |
| Cost | 841 |
| Alternative 5 | |
|---|---|
| Error | 0.4 |
| Cost | 841 |
| Alternative 6 | |
|---|---|
| Error | 0.5 |
| Cost | 840 |
| Alternative 7 | |
|---|---|
| Error | 0.7 |
| Cost | 456 |
| Alternative 8 | |
|---|---|
| Error | 31.3 |
| Cost | 64 |
herbie shell --seed 2023039
(FPCore (x)
:name "Jmat.Real.dawson"
:precision binary64
(* (/ (+ (+ (+ (+ (+ 1.0 (* 0.1049934947 (* x x))) (* 0.0424060604 (* (* x x) (* x x)))) (* 0.0072644182 (* (* (* x x) (* x x)) (* x x)))) (* 0.0005064034 (* (* (* (* x x) (* x x)) (* x x)) (* x x)))) (* 0.0001789971 (* (* (* (* (* x x) (* x x)) (* x x)) (* x x)) (* x x)))) (+ (+ (+ (+ (+ (+ 1.0 (* 0.7715471019 (* x x))) (* 0.2909738639 (* (* x x) (* x x)))) (* 0.0694555761 (* (* (* x x) (* x x)) (* x x)))) (* 0.0140005442 (* (* (* (* x x) (* x x)) (* x x)) (* x x)))) (* 0.0008327945 (* (* (* (* (* x x) (* x x)) (* x x)) (* x x)) (* x x)))) (* (* 2.0 0.0001789971) (* (* (* (* (* (* x x) (* x x)) (* x x)) (* x x)) (* x x)) (* x x))))) x))