
(FPCore (x y z)
:precision binary64
(/
(*
(- x 2.0)
(+
(*
(+ (* (+ (* (+ (* x 4.16438922228) 78.6994924154) x) 137.519416416) x) y)
x)
z))
(+
(* (+ (* (+ (* (+ x 43.3400022514) x) 263.505074721) x) 313.399215894) x)
47.066876606)))
double code(double x, double y, double z) {
return ((x - 2.0) * ((((((((x * 4.16438922228) + 78.6994924154) * x) + 137.519416416) * x) + y) * x) + z)) / (((((((x + 43.3400022514) * x) + 263.505074721) * x) + 313.399215894) * x) + 47.066876606);
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = ((x - 2.0d0) * ((((((((x * 4.16438922228d0) + 78.6994924154d0) * x) + 137.519416416d0) * x) + y) * x) + z)) / (((((((x + 43.3400022514d0) * x) + 263.505074721d0) * x) + 313.399215894d0) * x) + 47.066876606d0)
end function
public static double code(double x, double y, double z) {
return ((x - 2.0) * ((((((((x * 4.16438922228) + 78.6994924154) * x) + 137.519416416) * x) + y) * x) + z)) / (((((((x + 43.3400022514) * x) + 263.505074721) * x) + 313.399215894) * x) + 47.066876606);
}
def code(x, y, z): return ((x - 2.0) * ((((((((x * 4.16438922228) + 78.6994924154) * x) + 137.519416416) * x) + y) * x) + z)) / (((((((x + 43.3400022514) * x) + 263.505074721) * x) + 313.399215894) * x) + 47.066876606)
function code(x, y, z) return Float64(Float64(Float64(x - 2.0) * Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 4.16438922228) + 78.6994924154) * x) + 137.519416416) * x) + y) * x) + z)) / Float64(Float64(Float64(Float64(Float64(Float64(Float64(x + 43.3400022514) * x) + 263.505074721) * x) + 313.399215894) * x) + 47.066876606)) end
function tmp = code(x, y, z) tmp = ((x - 2.0) * ((((((((x * 4.16438922228) + 78.6994924154) * x) + 137.519416416) * x) + y) * x) + z)) / (((((((x + 43.3400022514) * x) + 263.505074721) * x) + 313.399215894) * x) + 47.066876606); end
code[x_, y_, z_] := N[(N[(N[(x - 2.0), $MachinePrecision] * N[(N[(N[(N[(N[(N[(N[(N[(x * 4.16438922228), $MachinePrecision] + 78.6994924154), $MachinePrecision] * x), $MachinePrecision] + 137.519416416), $MachinePrecision] * x), $MachinePrecision] + y), $MachinePrecision] * x), $MachinePrecision] + z), $MachinePrecision]), $MachinePrecision] / N[(N[(N[(N[(N[(N[(N[(x + 43.3400022514), $MachinePrecision] * x), $MachinePrecision] + 263.505074721), $MachinePrecision] * x), $MachinePrecision] + 313.399215894), $MachinePrecision] * x), $MachinePrecision] + 47.066876606), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{\left(x - 2\right) \cdot \left(\left(\left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right) \cdot x + y\right) \cdot x + z\right)}{\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right) \cdot x + 47.066876606}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 21 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z)
:precision binary64
(/
(*
(- x 2.0)
(+
(*
(+ (* (+ (* (+ (* x 4.16438922228) 78.6994924154) x) 137.519416416) x) y)
x)
z))
(+
(* (+ (* (+ (* (+ x 43.3400022514) x) 263.505074721) x) 313.399215894) x)
47.066876606)))
double code(double x, double y, double z) {
return ((x - 2.0) * ((((((((x * 4.16438922228) + 78.6994924154) * x) + 137.519416416) * x) + y) * x) + z)) / (((((((x + 43.3400022514) * x) + 263.505074721) * x) + 313.399215894) * x) + 47.066876606);
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = ((x - 2.0d0) * ((((((((x * 4.16438922228d0) + 78.6994924154d0) * x) + 137.519416416d0) * x) + y) * x) + z)) / (((((((x + 43.3400022514d0) * x) + 263.505074721d0) * x) + 313.399215894d0) * x) + 47.066876606d0)
end function
public static double code(double x, double y, double z) {
return ((x - 2.0) * ((((((((x * 4.16438922228) + 78.6994924154) * x) + 137.519416416) * x) + y) * x) + z)) / (((((((x + 43.3400022514) * x) + 263.505074721) * x) + 313.399215894) * x) + 47.066876606);
}
def code(x, y, z): return ((x - 2.0) * ((((((((x * 4.16438922228) + 78.6994924154) * x) + 137.519416416) * x) + y) * x) + z)) / (((((((x + 43.3400022514) * x) + 263.505074721) * x) + 313.399215894) * x) + 47.066876606)
function code(x, y, z) return Float64(Float64(Float64(x - 2.0) * Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 4.16438922228) + 78.6994924154) * x) + 137.519416416) * x) + y) * x) + z)) / Float64(Float64(Float64(Float64(Float64(Float64(Float64(x + 43.3400022514) * x) + 263.505074721) * x) + 313.399215894) * x) + 47.066876606)) end
function tmp = code(x, y, z) tmp = ((x - 2.0) * ((((((((x * 4.16438922228) + 78.6994924154) * x) + 137.519416416) * x) + y) * x) + z)) / (((((((x + 43.3400022514) * x) + 263.505074721) * x) + 313.399215894) * x) + 47.066876606); end
code[x_, y_, z_] := N[(N[(N[(x - 2.0), $MachinePrecision] * N[(N[(N[(N[(N[(N[(N[(N[(x * 4.16438922228), $MachinePrecision] + 78.6994924154), $MachinePrecision] * x), $MachinePrecision] + 137.519416416), $MachinePrecision] * x), $MachinePrecision] + y), $MachinePrecision] * x), $MachinePrecision] + z), $MachinePrecision]), $MachinePrecision] / N[(N[(N[(N[(N[(N[(N[(x + 43.3400022514), $MachinePrecision] * x), $MachinePrecision] + 263.505074721), $MachinePrecision] * x), $MachinePrecision] + 313.399215894), $MachinePrecision] * x), $MachinePrecision] + 47.066876606), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{\left(x - 2\right) \cdot \left(\left(\left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right) \cdot x + y\right) \cdot x + z\right)}{\left(\left(\left(x + 43.3400022514\right) \cdot x + 263.505074721\right) \cdot x + 313.399215894\right) \cdot x + 47.066876606}
\end{array}
(FPCore (x y z)
:precision binary64
(if (<=
(/
(*
(- x 2.0)
(+
(*
x
(+
(* x (+ (* x (+ (* x 4.16438922228) 78.6994924154)) 137.519416416))
y))
z))
(+
(*
x
(+ (* x (+ (* x (+ x 43.3400022514)) 263.505074721)) 313.399215894))
47.066876606))
2e+294)
(*
(+ x -2.0)
(/
(fma
x
(fma x (fma x (fma x 4.16438922228 78.6994924154) 137.519416416) y)
z)
(fma
x
(fma x (fma x (+ x 43.3400022514) 263.505074721) 313.399215894)
47.066876606)))
(+
(/ 4752.4581585918595 x)
(-
(+ (* x 4.16438922228) (/ y (* x x)))
(+ 110.1139242984811 (/ 207551.7024428275 (* x x)))))))
double code(double x, double y, double z) {
double tmp;
if ((((x - 2.0) * ((x * ((x * ((x * ((x * 4.16438922228) + 78.6994924154)) + 137.519416416)) + y)) + z)) / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606)) <= 2e+294) {
tmp = (x + -2.0) * (fma(x, fma(x, fma(x, fma(x, 4.16438922228, 78.6994924154), 137.519416416), y), z) / fma(x, fma(x, fma(x, (x + 43.3400022514), 263.505074721), 313.399215894), 47.066876606));
} else {
tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x))));
}
return tmp;
}
function code(x, y, z) tmp = 0.0 if (Float64(Float64(Float64(x - 2.0) * Float64(Float64(x * Float64(Float64(x * Float64(Float64(x * Float64(Float64(x * 4.16438922228) + 78.6994924154)) + 137.519416416)) + y)) + z)) / Float64(Float64(x * Float64(Float64(x * Float64(Float64(x * Float64(x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606)) <= 2e+294) tmp = Float64(Float64(x + -2.0) * Float64(fma(x, fma(x, fma(x, fma(x, 4.16438922228, 78.6994924154), 137.519416416), y), z) / fma(x, fma(x, fma(x, Float64(x + 43.3400022514), 263.505074721), 313.399215894), 47.066876606))); else tmp = Float64(Float64(4752.4581585918595 / x) + Float64(Float64(Float64(x * 4.16438922228) + Float64(y / Float64(x * x))) - Float64(110.1139242984811 + Float64(207551.7024428275 / Float64(x * x))))); end return tmp end
code[x_, y_, z_] := If[LessEqual[N[(N[(N[(x - 2.0), $MachinePrecision] * N[(N[(x * N[(N[(x * N[(N[(x * N[(N[(x * 4.16438922228), $MachinePrecision] + 78.6994924154), $MachinePrecision]), $MachinePrecision] + 137.519416416), $MachinePrecision]), $MachinePrecision] + y), $MachinePrecision]), $MachinePrecision] + z), $MachinePrecision]), $MachinePrecision] / N[(N[(x * N[(N[(x * N[(N[(x * N[(x + 43.3400022514), $MachinePrecision]), $MachinePrecision] + 263.505074721), $MachinePrecision]), $MachinePrecision] + 313.399215894), $MachinePrecision]), $MachinePrecision] + 47.066876606), $MachinePrecision]), $MachinePrecision], 2e+294], N[(N[(x + -2.0), $MachinePrecision] * N[(N[(x * N[(x * N[(x * N[(x * 4.16438922228 + 78.6994924154), $MachinePrecision] + 137.519416416), $MachinePrecision] + y), $MachinePrecision] + z), $MachinePrecision] / N[(x * N[(x * N[(x * N[(x + 43.3400022514), $MachinePrecision] + 263.505074721), $MachinePrecision] + 313.399215894), $MachinePrecision] + 47.066876606), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(4752.4581585918595 / x), $MachinePrecision] + N[(N[(N[(x * 4.16438922228), $MachinePrecision] + N[(y / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(110.1139242984811 + N[(207551.7024428275 / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\frac{\left(x - 2\right) \cdot \left(x \cdot \left(x \cdot \left(x \cdot \left(x \cdot 4.16438922228 + 78.6994924154\right) + 137.519416416\right) + y\right) + z\right)}{x \cdot \left(x \cdot \left(x \cdot \left(x + 43.3400022514\right) + 263.505074721\right) + 313.399215894\right) + 47.066876606} \leq 2 \cdot 10^{+294}:\\
\;\;\;\;\left(x + -2\right) \cdot \frac{\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, 4.16438922228, 78.6994924154\right), 137.519416416\right), y\right), z\right)}{\mathsf{fma}\left(x, \mathsf{fma}\left(x, \mathsf{fma}\left(x, x + 43.3400022514, 263.505074721\right), 313.399215894\right), 47.066876606\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{4752.4581585918595}{x} + \left(\left(x \cdot 4.16438922228 + \frac{y}{x \cdot x}\right) - \left(110.1139242984811 + \frac{207551.7024428275}{x \cdot x}\right)\right)\\
\end{array}
\end{array}
if (/.f64 (*.f64 (-.f64 x 2) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 x 104109730557/25000000000) 393497462077/5000000000) x) 4297481763/31250000) x) y) x) z)) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 x 216700011257/5000000000) x) 263505074721/1000000000) x) 156699607947/500000000) x) 23533438303/500000000)) < 2.00000000000000013e294Initial program 97.7%
associate-*r/99.5%
sub-neg99.5%
metadata-eval99.5%
*-commutative99.5%
fma-def99.5%
*-commutative99.5%
fma-def99.5%
*-commutative99.5%
fma-def99.5%
fma-def99.5%
*-commutative99.5%
Simplified99.5%
if 2.00000000000000013e294 < (/.f64 (*.f64 (-.f64 x 2) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 x 104109730557/25000000000) 393497462077/5000000000) x) 4297481763/31250000) x) y) x) z)) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 x 216700011257/5000000000) x) 263505074721/1000000000) x) 156699607947/500000000) x) 23533438303/500000000)) Initial program 0.2%
Taylor expanded in x around inf 0.2%
cube-mult0.2%
unpow20.2%
distribute-rgt-out0.2%
+-commutative0.2%
unpow20.2%
Simplified0.2%
Taylor expanded in x around inf 99.1%
associate--l+99.1%
associate-*r/99.1%
metadata-eval99.1%
+-commutative99.1%
*-commutative99.1%
unpow299.1%
associate-*r/99.1%
metadata-eval99.1%
unpow299.1%
Simplified99.1%
Final simplification99.4%
(FPCore (x y z)
:precision binary64
(let* ((t_0
(+
(*
x
(+ (* x (+ (* x (+ x 43.3400022514)) 263.505074721)) 313.399215894))
47.066876606))
(t_1
(*
x
(+
(* x (+ (* x (+ (* x 4.16438922228) 78.6994924154)) 137.519416416))
y))))
(if (<= (/ (* (- x 2.0) (+ t_1 z)) t_0) 2e+294)
(* (+ x -2.0) (+ (/ t_1 t_0) (/ z t_0)))
(+
(/ 4752.4581585918595 x)
(-
(+ (* x 4.16438922228) (/ y (* x x)))
(+ 110.1139242984811 (/ 207551.7024428275 (* x x))))))))
double code(double x, double y, double z) {
double t_0 = (x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606;
double t_1 = x * ((x * ((x * ((x * 4.16438922228) + 78.6994924154)) + 137.519416416)) + y);
double tmp;
if ((((x - 2.0) * (t_1 + z)) / t_0) <= 2e+294) {
tmp = (x + -2.0) * ((t_1 / t_0) + (z / t_0));
} else {
tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x))));
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = (x * ((x * ((x * (x + 43.3400022514d0)) + 263.505074721d0)) + 313.399215894d0)) + 47.066876606d0
t_1 = x * ((x * ((x * ((x * 4.16438922228d0) + 78.6994924154d0)) + 137.519416416d0)) + y)
if ((((x - 2.0d0) * (t_1 + z)) / t_0) <= 2d+294) then
tmp = (x + (-2.0d0)) * ((t_1 / t_0) + (z / t_0))
else
tmp = (4752.4581585918595d0 / x) + (((x * 4.16438922228d0) + (y / (x * x))) - (110.1139242984811d0 + (207551.7024428275d0 / (x * x))))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = (x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606;
double t_1 = x * ((x * ((x * ((x * 4.16438922228) + 78.6994924154)) + 137.519416416)) + y);
double tmp;
if ((((x - 2.0) * (t_1 + z)) / t_0) <= 2e+294) {
tmp = (x + -2.0) * ((t_1 / t_0) + (z / t_0));
} else {
tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x))));
}
return tmp;
}
def code(x, y, z): t_0 = (x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606 t_1 = x * ((x * ((x * ((x * 4.16438922228) + 78.6994924154)) + 137.519416416)) + y) tmp = 0 if (((x - 2.0) * (t_1 + z)) / t_0) <= 2e+294: tmp = (x + -2.0) * ((t_1 / t_0) + (z / t_0)) else: tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x)))) return tmp
function code(x, y, z) t_0 = Float64(Float64(x * Float64(Float64(x * Float64(Float64(x * Float64(x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606) t_1 = Float64(x * Float64(Float64(x * Float64(Float64(x * Float64(Float64(x * 4.16438922228) + 78.6994924154)) + 137.519416416)) + y)) tmp = 0.0 if (Float64(Float64(Float64(x - 2.0) * Float64(t_1 + z)) / t_0) <= 2e+294) tmp = Float64(Float64(x + -2.0) * Float64(Float64(t_1 / t_0) + Float64(z / t_0))); else tmp = Float64(Float64(4752.4581585918595 / x) + Float64(Float64(Float64(x * 4.16438922228) + Float64(y / Float64(x * x))) - Float64(110.1139242984811 + Float64(207551.7024428275 / Float64(x * x))))); end return tmp end
function tmp_2 = code(x, y, z) t_0 = (x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606; t_1 = x * ((x * ((x * ((x * 4.16438922228) + 78.6994924154)) + 137.519416416)) + y); tmp = 0.0; if ((((x - 2.0) * (t_1 + z)) / t_0) <= 2e+294) tmp = (x + -2.0) * ((t_1 / t_0) + (z / t_0)); else tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x)))); end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(N[(x * N[(N[(x * N[(N[(x * N[(x + 43.3400022514), $MachinePrecision]), $MachinePrecision] + 263.505074721), $MachinePrecision]), $MachinePrecision] + 313.399215894), $MachinePrecision]), $MachinePrecision] + 47.066876606), $MachinePrecision]}, Block[{t$95$1 = N[(x * N[(N[(x * N[(N[(x * N[(N[(x * 4.16438922228), $MachinePrecision] + 78.6994924154), $MachinePrecision]), $MachinePrecision] + 137.519416416), $MachinePrecision]), $MachinePrecision] + y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(N[(N[(x - 2.0), $MachinePrecision] * N[(t$95$1 + z), $MachinePrecision]), $MachinePrecision] / t$95$0), $MachinePrecision], 2e+294], N[(N[(x + -2.0), $MachinePrecision] * N[(N[(t$95$1 / t$95$0), $MachinePrecision] + N[(z / t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(4752.4581585918595 / x), $MachinePrecision] + N[(N[(N[(x * 4.16438922228), $MachinePrecision] + N[(y / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(110.1139242984811 + N[(207551.7024428275 / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x \cdot \left(x \cdot \left(x \cdot \left(x + 43.3400022514\right) + 263.505074721\right) + 313.399215894\right) + 47.066876606\\
t_1 := x \cdot \left(x \cdot \left(x \cdot \left(x \cdot 4.16438922228 + 78.6994924154\right) + 137.519416416\right) + y\right)\\
\mathbf{if}\;\frac{\left(x - 2\right) \cdot \left(t_1 + z\right)}{t_0} \leq 2 \cdot 10^{+294}:\\
\;\;\;\;\left(x + -2\right) \cdot \left(\frac{t_1}{t_0} + \frac{z}{t_0}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{4752.4581585918595}{x} + \left(\left(x \cdot 4.16438922228 + \frac{y}{x \cdot x}\right) - \left(110.1139242984811 + \frac{207551.7024428275}{x \cdot x}\right)\right)\\
\end{array}
\end{array}
if (/.f64 (*.f64 (-.f64 x 2) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 x 104109730557/25000000000) 393497462077/5000000000) x) 4297481763/31250000) x) y) x) z)) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 x 216700011257/5000000000) x) 263505074721/1000000000) x) 156699607947/500000000) x) 23533438303/500000000)) < 2.00000000000000013e294Initial program 97.7%
associate-*r/99.5%
sub-neg99.5%
metadata-eval99.5%
*-commutative99.5%
fma-def99.5%
*-commutative99.5%
fma-def99.5%
*-commutative99.5%
fma-def99.5%
fma-def99.5%
*-commutative99.5%
Simplified99.5%
Taylor expanded in z around 0 99.5%
if 2.00000000000000013e294 < (/.f64 (*.f64 (-.f64 x 2) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 x 104109730557/25000000000) 393497462077/5000000000) x) 4297481763/31250000) x) y) x) z)) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 x 216700011257/5000000000) x) 263505074721/1000000000) x) 156699607947/500000000) x) 23533438303/500000000)) Initial program 0.2%
Taylor expanded in x around inf 0.2%
cube-mult0.2%
unpow20.2%
distribute-rgt-out0.2%
+-commutative0.2%
unpow20.2%
Simplified0.2%
Taylor expanded in x around inf 99.1%
associate--l+99.1%
associate-*r/99.1%
metadata-eval99.1%
+-commutative99.1%
*-commutative99.1%
unpow299.1%
associate-*r/99.1%
metadata-eval99.1%
unpow299.1%
Simplified99.1%
Final simplification99.4%
(FPCore (x y z)
:precision binary64
(let* ((t_0
(/
(*
(- x 2.0)
(+
(*
x
(+
(*
x
(+ (* x (+ (* x 4.16438922228) 78.6994924154)) 137.519416416))
y))
z))
(+
(*
x
(+
(* x (+ (* x (+ x 43.3400022514)) 263.505074721))
313.399215894))
47.066876606))))
(if (<= t_0 2e+294)
t_0
(+
(/ 4752.4581585918595 x)
(-
(+ (* x 4.16438922228) (/ y (* x x)))
(+ 110.1139242984811 (/ 207551.7024428275 (* x x))))))))
double code(double x, double y, double z) {
double t_0 = ((x - 2.0) * ((x * ((x * ((x * ((x * 4.16438922228) + 78.6994924154)) + 137.519416416)) + y)) + z)) / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606);
double tmp;
if (t_0 <= 2e+294) {
tmp = t_0;
} else {
tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x))));
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: t_0
real(8) :: tmp
t_0 = ((x - 2.0d0) * ((x * ((x * ((x * ((x * 4.16438922228d0) + 78.6994924154d0)) + 137.519416416d0)) + y)) + z)) / ((x * ((x * ((x * (x + 43.3400022514d0)) + 263.505074721d0)) + 313.399215894d0)) + 47.066876606d0)
if (t_0 <= 2d+294) then
tmp = t_0
else
tmp = (4752.4581585918595d0 / x) + (((x * 4.16438922228d0) + (y / (x * x))) - (110.1139242984811d0 + (207551.7024428275d0 / (x * x))))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = ((x - 2.0) * ((x * ((x * ((x * ((x * 4.16438922228) + 78.6994924154)) + 137.519416416)) + y)) + z)) / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606);
double tmp;
if (t_0 <= 2e+294) {
tmp = t_0;
} else {
tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x))));
}
return tmp;
}
def code(x, y, z): t_0 = ((x - 2.0) * ((x * ((x * ((x * ((x * 4.16438922228) + 78.6994924154)) + 137.519416416)) + y)) + z)) / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606) tmp = 0 if t_0 <= 2e+294: tmp = t_0 else: tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x)))) return tmp
function code(x, y, z) t_0 = Float64(Float64(Float64(x - 2.0) * Float64(Float64(x * Float64(Float64(x * Float64(Float64(x * Float64(Float64(x * 4.16438922228) + 78.6994924154)) + 137.519416416)) + y)) + z)) / Float64(Float64(x * Float64(Float64(x * Float64(Float64(x * Float64(x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606)) tmp = 0.0 if (t_0 <= 2e+294) tmp = t_0; else tmp = Float64(Float64(4752.4581585918595 / x) + Float64(Float64(Float64(x * 4.16438922228) + Float64(y / Float64(x * x))) - Float64(110.1139242984811 + Float64(207551.7024428275 / Float64(x * x))))); end return tmp end
function tmp_2 = code(x, y, z) t_0 = ((x - 2.0) * ((x * ((x * ((x * ((x * 4.16438922228) + 78.6994924154)) + 137.519416416)) + y)) + z)) / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606); tmp = 0.0; if (t_0 <= 2e+294) tmp = t_0; else tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x)))); end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(N[(N[(x - 2.0), $MachinePrecision] * N[(N[(x * N[(N[(x * N[(N[(x * N[(N[(x * 4.16438922228), $MachinePrecision] + 78.6994924154), $MachinePrecision]), $MachinePrecision] + 137.519416416), $MachinePrecision]), $MachinePrecision] + y), $MachinePrecision]), $MachinePrecision] + z), $MachinePrecision]), $MachinePrecision] / N[(N[(x * N[(N[(x * N[(N[(x * N[(x + 43.3400022514), $MachinePrecision]), $MachinePrecision] + 263.505074721), $MachinePrecision]), $MachinePrecision] + 313.399215894), $MachinePrecision]), $MachinePrecision] + 47.066876606), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$0, 2e+294], t$95$0, N[(N[(4752.4581585918595 / x), $MachinePrecision] + N[(N[(N[(x * 4.16438922228), $MachinePrecision] + N[(y / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(110.1139242984811 + N[(207551.7024428275 / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{\left(x - 2\right) \cdot \left(x \cdot \left(x \cdot \left(x \cdot \left(x \cdot 4.16438922228 + 78.6994924154\right) + 137.519416416\right) + y\right) + z\right)}{x \cdot \left(x \cdot \left(x \cdot \left(x + 43.3400022514\right) + 263.505074721\right) + 313.399215894\right) + 47.066876606}\\
\mathbf{if}\;t_0 \leq 2 \cdot 10^{+294}:\\
\;\;\;\;t_0\\
\mathbf{else}:\\
\;\;\;\;\frac{4752.4581585918595}{x} + \left(\left(x \cdot 4.16438922228 + \frac{y}{x \cdot x}\right) - \left(110.1139242984811 + \frac{207551.7024428275}{x \cdot x}\right)\right)\\
\end{array}
\end{array}
if (/.f64 (*.f64 (-.f64 x 2) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 x 104109730557/25000000000) 393497462077/5000000000) x) 4297481763/31250000) x) y) x) z)) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 x 216700011257/5000000000) x) 263505074721/1000000000) x) 156699607947/500000000) x) 23533438303/500000000)) < 2.00000000000000013e294Initial program 97.7%
if 2.00000000000000013e294 < (/.f64 (*.f64 (-.f64 x 2) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 x 104109730557/25000000000) 393497462077/5000000000) x) 4297481763/31250000) x) y) x) z)) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 x 216700011257/5000000000) x) 263505074721/1000000000) x) 156699607947/500000000) x) 23533438303/500000000)) Initial program 0.2%
Taylor expanded in x around inf 0.2%
cube-mult0.2%
unpow20.2%
distribute-rgt-out0.2%
+-commutative0.2%
unpow20.2%
Simplified0.2%
Taylor expanded in x around inf 99.1%
associate--l+99.1%
associate-*r/99.1%
metadata-eval99.1%
+-commutative99.1%
*-commutative99.1%
unpow299.1%
associate-*r/99.1%
metadata-eval99.1%
unpow299.1%
Simplified99.1%
Final simplification98.2%
(FPCore (x y z)
:precision binary64
(let* ((t_0
(/
z
(+
47.066876606
(* x (+ 313.399215894 (* (+ x 43.3400022514) (* x x))))))))
(if (<= x -8e+21)
(* (+ x -2.0) (+ 4.16438922228 t_0))
(if (<= x 50000.0)
(/
(* (- x 2.0) (+ z (* x (+ y (* x 137.519416416)))))
(+
(*
x
(+ (* x (+ (* x (+ x 43.3400022514)) 263.505074721)) 313.399215894))
47.066876606))
(*
(+ x -2.0)
(+
t_0
(+
4.16438922228
(+ (/ 3451.550173699799 (* x x)) (/ -101.7851458539211 x)))))))))
double code(double x, double y, double z) {
double t_0 = z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x)))));
double tmp;
if (x <= -8e+21) {
tmp = (x + -2.0) * (4.16438922228 + t_0);
} else if (x <= 50000.0) {
tmp = ((x - 2.0) * (z + (x * (y + (x * 137.519416416))))) / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606);
} else {
tmp = (x + -2.0) * (t_0 + (4.16438922228 + ((3451.550173699799 / (x * x)) + (-101.7851458539211 / x))));
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: t_0
real(8) :: tmp
t_0 = z / (47.066876606d0 + (x * (313.399215894d0 + ((x + 43.3400022514d0) * (x * x)))))
if (x <= (-8d+21)) then
tmp = (x + (-2.0d0)) * (4.16438922228d0 + t_0)
else if (x <= 50000.0d0) then
tmp = ((x - 2.0d0) * (z + (x * (y + (x * 137.519416416d0))))) / ((x * ((x * ((x * (x + 43.3400022514d0)) + 263.505074721d0)) + 313.399215894d0)) + 47.066876606d0)
else
tmp = (x + (-2.0d0)) * (t_0 + (4.16438922228d0 + ((3451.550173699799d0 / (x * x)) + ((-101.7851458539211d0) / x))))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x)))));
double tmp;
if (x <= -8e+21) {
tmp = (x + -2.0) * (4.16438922228 + t_0);
} else if (x <= 50000.0) {
tmp = ((x - 2.0) * (z + (x * (y + (x * 137.519416416))))) / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606);
} else {
tmp = (x + -2.0) * (t_0 + (4.16438922228 + ((3451.550173699799 / (x * x)) + (-101.7851458539211 / x))));
}
return tmp;
}
def code(x, y, z): t_0 = z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x))))) tmp = 0 if x <= -8e+21: tmp = (x + -2.0) * (4.16438922228 + t_0) elif x <= 50000.0: tmp = ((x - 2.0) * (z + (x * (y + (x * 137.519416416))))) / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606) else: tmp = (x + -2.0) * (t_0 + (4.16438922228 + ((3451.550173699799 / (x * x)) + (-101.7851458539211 / x)))) return tmp
function code(x, y, z) t_0 = Float64(z / Float64(47.066876606 + Float64(x * Float64(313.399215894 + Float64(Float64(x + 43.3400022514) * Float64(x * x)))))) tmp = 0.0 if (x <= -8e+21) tmp = Float64(Float64(x + -2.0) * Float64(4.16438922228 + t_0)); elseif (x <= 50000.0) tmp = Float64(Float64(Float64(x - 2.0) * Float64(z + Float64(x * Float64(y + Float64(x * 137.519416416))))) / Float64(Float64(x * Float64(Float64(x * Float64(Float64(x * Float64(x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606)); else tmp = Float64(Float64(x + -2.0) * Float64(t_0 + Float64(4.16438922228 + Float64(Float64(3451.550173699799 / Float64(x * x)) + Float64(-101.7851458539211 / x))))); end return tmp end
function tmp_2 = code(x, y, z) t_0 = z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x))))); tmp = 0.0; if (x <= -8e+21) tmp = (x + -2.0) * (4.16438922228 + t_0); elseif (x <= 50000.0) tmp = ((x - 2.0) * (z + (x * (y + (x * 137.519416416))))) / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606); else tmp = (x + -2.0) * (t_0 + (4.16438922228 + ((3451.550173699799 / (x * x)) + (-101.7851458539211 / x)))); end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(z / N[(47.066876606 + N[(x * N[(313.399215894 + N[(N[(x + 43.3400022514), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -8e+21], N[(N[(x + -2.0), $MachinePrecision] * N[(4.16438922228 + t$95$0), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 50000.0], N[(N[(N[(x - 2.0), $MachinePrecision] * N[(z + N[(x * N[(y + N[(x * 137.519416416), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(x * N[(N[(x * N[(N[(x * N[(x + 43.3400022514), $MachinePrecision]), $MachinePrecision] + 263.505074721), $MachinePrecision]), $MachinePrecision] + 313.399215894), $MachinePrecision]), $MachinePrecision] + 47.066876606), $MachinePrecision]), $MachinePrecision], N[(N[(x + -2.0), $MachinePrecision] * N[(t$95$0 + N[(4.16438922228 + N[(N[(3451.550173699799 / N[(x * x), $MachinePrecision]), $MachinePrecision] + N[(-101.7851458539211 / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{z}{47.066876606 + x \cdot \left(313.399215894 + \left(x + 43.3400022514\right) \cdot \left(x \cdot x\right)\right)}\\
\mathbf{if}\;x \leq -8 \cdot 10^{+21}:\\
\;\;\;\;\left(x + -2\right) \cdot \left(4.16438922228 + t_0\right)\\
\mathbf{elif}\;x \leq 50000:\\
\;\;\;\;\frac{\left(x - 2\right) \cdot \left(z + x \cdot \left(y + x \cdot 137.519416416\right)\right)}{x \cdot \left(x \cdot \left(x \cdot \left(x + 43.3400022514\right) + 263.505074721\right) + 313.399215894\right) + 47.066876606}\\
\mathbf{else}:\\
\;\;\;\;\left(x + -2\right) \cdot \left(t_0 + \left(4.16438922228 + \left(\frac{3451.550173699799}{x \cdot x} + \frac{-101.7851458539211}{x}\right)\right)\right)\\
\end{array}
\end{array}
if x < -8e21Initial program 16.7%
associate-*r/21.4%
sub-neg21.4%
metadata-eval21.4%
*-commutative21.4%
fma-def21.4%
*-commutative21.4%
fma-def21.4%
*-commutative21.4%
fma-def21.4%
fma-def21.4%
*-commutative21.4%
Simplified21.4%
Taylor expanded in z around 0 21.4%
Taylor expanded in x around inf 96.0%
Taylor expanded in x around inf 49.8%
cube-mult49.8%
unpow249.8%
distribute-rgt-in96.0%
unpow296.0%
+-commutative96.0%
Simplified96.0%
if -8e21 < x < 5e4Initial program 99.6%
Taylor expanded in x around 0 99.3%
*-commutative96.2%
Simplified99.3%
if 5e4 < x Initial program 12.1%
associate-*r/17.0%
sub-neg17.0%
metadata-eval17.0%
*-commutative17.0%
fma-def17.0%
*-commutative17.0%
fma-def17.0%
*-commutative17.0%
fma-def17.0%
fma-def17.0%
*-commutative17.0%
Simplified17.0%
Taylor expanded in z around 0 17.0%
Taylor expanded in x around inf 95.2%
associate--l+95.2%
sub-neg95.2%
associate-*r/95.2%
metadata-eval95.2%
unpow295.2%
associate-*r/95.2%
metadata-eval95.2%
distribute-neg-frac95.2%
metadata-eval95.2%
Simplified95.2%
Taylor expanded in x around inf 95.2%
cube-mult93.9%
unpow293.9%
distribute-rgt-in93.9%
unpow293.9%
+-commutative93.9%
Simplified95.2%
Final simplification97.6%
(FPCore (x y z)
:precision binary64
(let* ((t_0
(+
(*
x
(+ (* x (+ (* x (+ x 43.3400022514)) 263.505074721)) 313.399215894))
47.066876606))
(t_1 (/ z t_0)))
(if (<= x -1.4e+21)
(*
(+ x -2.0)
(+
4.16438922228
(/
z
(+
47.066876606
(* x (+ 313.399215894 (* (+ x 43.3400022514) (* x x))))))))
(if (<= x -4.6e-13)
(/ (+ x -2.0) (/ t_0 (* x y)))
(if (<= x -4.2e-26)
(* (+ x -2.0) (+ t_1 (* x (* x 2.9217875995295866))))
(if (<= x 0.00016)
(*
(+ x -2.0)
(+
(* z 0.0212463641547976)
(* x (- (* y 0.0212463641547976) (* z 0.14147091005106402)))))
(* (+ x -2.0) (+ 4.16438922228 t_1))))))))
double code(double x, double y, double z) {
double t_0 = (x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606;
double t_1 = z / t_0;
double tmp;
if (x <= -1.4e+21) {
tmp = (x + -2.0) * (4.16438922228 + (z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x)))))));
} else if (x <= -4.6e-13) {
tmp = (x + -2.0) / (t_0 / (x * y));
} else if (x <= -4.2e-26) {
tmp = (x + -2.0) * (t_1 + (x * (x * 2.9217875995295866)));
} else if (x <= 0.00016) {
tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402))));
} else {
tmp = (x + -2.0) * (4.16438922228 + t_1);
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = (x * ((x * ((x * (x + 43.3400022514d0)) + 263.505074721d0)) + 313.399215894d0)) + 47.066876606d0
t_1 = z / t_0
if (x <= (-1.4d+21)) then
tmp = (x + (-2.0d0)) * (4.16438922228d0 + (z / (47.066876606d0 + (x * (313.399215894d0 + ((x + 43.3400022514d0) * (x * x)))))))
else if (x <= (-4.6d-13)) then
tmp = (x + (-2.0d0)) / (t_0 / (x * y))
else if (x <= (-4.2d-26)) then
tmp = (x + (-2.0d0)) * (t_1 + (x * (x * 2.9217875995295866d0)))
else if (x <= 0.00016d0) then
tmp = (x + (-2.0d0)) * ((z * 0.0212463641547976d0) + (x * ((y * 0.0212463641547976d0) - (z * 0.14147091005106402d0))))
else
tmp = (x + (-2.0d0)) * (4.16438922228d0 + t_1)
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = (x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606;
double t_1 = z / t_0;
double tmp;
if (x <= -1.4e+21) {
tmp = (x + -2.0) * (4.16438922228 + (z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x)))))));
} else if (x <= -4.6e-13) {
tmp = (x + -2.0) / (t_0 / (x * y));
} else if (x <= -4.2e-26) {
tmp = (x + -2.0) * (t_1 + (x * (x * 2.9217875995295866)));
} else if (x <= 0.00016) {
tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402))));
} else {
tmp = (x + -2.0) * (4.16438922228 + t_1);
}
return tmp;
}
def code(x, y, z): t_0 = (x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606 t_1 = z / t_0 tmp = 0 if x <= -1.4e+21: tmp = (x + -2.0) * (4.16438922228 + (z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x))))))) elif x <= -4.6e-13: tmp = (x + -2.0) / (t_0 / (x * y)) elif x <= -4.2e-26: tmp = (x + -2.0) * (t_1 + (x * (x * 2.9217875995295866))) elif x <= 0.00016: tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402)))) else: tmp = (x + -2.0) * (4.16438922228 + t_1) return tmp
function code(x, y, z) t_0 = Float64(Float64(x * Float64(Float64(x * Float64(Float64(x * Float64(x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606) t_1 = Float64(z / t_0) tmp = 0.0 if (x <= -1.4e+21) tmp = Float64(Float64(x + -2.0) * Float64(4.16438922228 + Float64(z / Float64(47.066876606 + Float64(x * Float64(313.399215894 + Float64(Float64(x + 43.3400022514) * Float64(x * x)))))))); elseif (x <= -4.6e-13) tmp = Float64(Float64(x + -2.0) / Float64(t_0 / Float64(x * y))); elseif (x <= -4.2e-26) tmp = Float64(Float64(x + -2.0) * Float64(t_1 + Float64(x * Float64(x * 2.9217875995295866)))); elseif (x <= 0.00016) tmp = Float64(Float64(x + -2.0) * Float64(Float64(z * 0.0212463641547976) + Float64(x * Float64(Float64(y * 0.0212463641547976) - Float64(z * 0.14147091005106402))))); else tmp = Float64(Float64(x + -2.0) * Float64(4.16438922228 + t_1)); end return tmp end
function tmp_2 = code(x, y, z) t_0 = (x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606; t_1 = z / t_0; tmp = 0.0; if (x <= -1.4e+21) tmp = (x + -2.0) * (4.16438922228 + (z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x))))))); elseif (x <= -4.6e-13) tmp = (x + -2.0) / (t_0 / (x * y)); elseif (x <= -4.2e-26) tmp = (x + -2.0) * (t_1 + (x * (x * 2.9217875995295866))); elseif (x <= 0.00016) tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402)))); else tmp = (x + -2.0) * (4.16438922228 + t_1); end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(N[(x * N[(N[(x * N[(N[(x * N[(x + 43.3400022514), $MachinePrecision]), $MachinePrecision] + 263.505074721), $MachinePrecision]), $MachinePrecision] + 313.399215894), $MachinePrecision]), $MachinePrecision] + 47.066876606), $MachinePrecision]}, Block[{t$95$1 = N[(z / t$95$0), $MachinePrecision]}, If[LessEqual[x, -1.4e+21], N[(N[(x + -2.0), $MachinePrecision] * N[(4.16438922228 + N[(z / N[(47.066876606 + N[(x * N[(313.399215894 + N[(N[(x + 43.3400022514), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, -4.6e-13], N[(N[(x + -2.0), $MachinePrecision] / N[(t$95$0 / N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, -4.2e-26], N[(N[(x + -2.0), $MachinePrecision] * N[(t$95$1 + N[(x * N[(x * 2.9217875995295866), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 0.00016], N[(N[(x + -2.0), $MachinePrecision] * N[(N[(z * 0.0212463641547976), $MachinePrecision] + N[(x * N[(N[(y * 0.0212463641547976), $MachinePrecision] - N[(z * 0.14147091005106402), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x + -2.0), $MachinePrecision] * N[(4.16438922228 + t$95$1), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x \cdot \left(x \cdot \left(x \cdot \left(x + 43.3400022514\right) + 263.505074721\right) + 313.399215894\right) + 47.066876606\\
t_1 := \frac{z}{t_0}\\
\mathbf{if}\;x \leq -1.4 \cdot 10^{+21}:\\
\;\;\;\;\left(x + -2\right) \cdot \left(4.16438922228 + \frac{z}{47.066876606 + x \cdot \left(313.399215894 + \left(x + 43.3400022514\right) \cdot \left(x \cdot x\right)\right)}\right)\\
\mathbf{elif}\;x \leq -4.6 \cdot 10^{-13}:\\
\;\;\;\;\frac{x + -2}{\frac{t_0}{x \cdot y}}\\
\mathbf{elif}\;x \leq -4.2 \cdot 10^{-26}:\\
\;\;\;\;\left(x + -2\right) \cdot \left(t_1 + x \cdot \left(x \cdot 2.9217875995295866\right)\right)\\
\mathbf{elif}\;x \leq 0.00016:\\
\;\;\;\;\left(x + -2\right) \cdot \left(z \cdot 0.0212463641547976 + x \cdot \left(y \cdot 0.0212463641547976 - z \cdot 0.14147091005106402\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x + -2\right) \cdot \left(4.16438922228 + t_1\right)\\
\end{array}
\end{array}
if x < -1.4e21Initial program 16.7%
associate-*r/21.4%
sub-neg21.4%
metadata-eval21.4%
*-commutative21.4%
fma-def21.4%
*-commutative21.4%
fma-def21.4%
*-commutative21.4%
fma-def21.4%
fma-def21.4%
*-commutative21.4%
Simplified21.4%
Taylor expanded in z around 0 21.4%
Taylor expanded in x around inf 96.0%
Taylor expanded in x around inf 49.8%
cube-mult49.8%
unpow249.8%
distribute-rgt-in96.0%
unpow296.0%
+-commutative96.0%
Simplified96.0%
if -1.4e21 < x < -4.59999999999999958e-13Initial program 98.4%
associate-/l*98.4%
sub-neg98.4%
metadata-eval98.4%
fma-def98.5%
fma-def98.6%
fma-def98.6%
fma-def98.6%
fma-def98.6%
fma-def98.6%
fma-def98.6%
Simplified98.6%
Taylor expanded in y around inf 84.3%
if -4.59999999999999958e-13 < x < -4.20000000000000016e-26Initial program 98.7%
associate-*r/98.7%
sub-neg98.7%
metadata-eval98.7%
*-commutative98.7%
fma-def98.7%
*-commutative98.7%
fma-def98.7%
*-commutative98.7%
fma-def98.7%
fma-def98.7%
*-commutative98.7%
Simplified98.7%
Taylor expanded in z around 0 98.7%
Taylor expanded in x around 0 93.9%
+-commutative93.9%
fma-def93.9%
sub-neg93.9%
*-commutative93.9%
distribute-rgt-neg-in93.9%
metadata-eval93.9%
unpow293.9%
Simplified93.9%
Taylor expanded in y around 0 93.9%
*-commutative93.9%
unpow293.9%
associate-*l*94.4%
Simplified94.4%
if -4.20000000000000016e-26 < x < 1.60000000000000013e-4Initial program 99.7%
associate-*r/99.7%
sub-neg99.7%
metadata-eval99.7%
*-commutative99.7%
fma-def99.7%
*-commutative99.7%
fma-def99.7%
*-commutative99.7%
fma-def99.7%
fma-def99.7%
*-commutative99.7%
Simplified99.7%
Taylor expanded in x around 0 93.7%
if 1.60000000000000013e-4 < x Initial program 14.9%
associate-*r/19.7%
sub-neg19.7%
metadata-eval19.7%
*-commutative19.7%
fma-def19.7%
*-commutative19.7%
fma-def19.7%
*-commutative19.7%
fma-def19.6%
fma-def19.6%
*-commutative19.6%
Simplified19.7%
Taylor expanded in z around 0 19.7%
Taylor expanded in x around inf 92.6%
Final simplification93.7%
(FPCore (x y z)
:precision binary64
(if (or (<= x -1.2e+22) (not (<= x 52000.0)))
(*
(+ x -2.0)
(+
4.16438922228
(/
z
(+
47.066876606
(* x (+ 313.399215894 (* (+ x 43.3400022514) (* x x))))))))
(/
(* (- x 2.0) (+ z (* x (+ y (* x 137.519416416)))))
(+
(* x (+ (* x (+ (* x (+ x 43.3400022514)) 263.505074721)) 313.399215894))
47.066876606))))
double code(double x, double y, double z) {
double tmp;
if ((x <= -1.2e+22) || !(x <= 52000.0)) {
tmp = (x + -2.0) * (4.16438922228 + (z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x)))))));
} else {
tmp = ((x - 2.0) * (z + (x * (y + (x * 137.519416416))))) / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606);
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if ((x <= (-1.2d+22)) .or. (.not. (x <= 52000.0d0))) then
tmp = (x + (-2.0d0)) * (4.16438922228d0 + (z / (47.066876606d0 + (x * (313.399215894d0 + ((x + 43.3400022514d0) * (x * x)))))))
else
tmp = ((x - 2.0d0) * (z + (x * (y + (x * 137.519416416d0))))) / ((x * ((x * ((x * (x + 43.3400022514d0)) + 263.505074721d0)) + 313.399215894d0)) + 47.066876606d0)
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((x <= -1.2e+22) || !(x <= 52000.0)) {
tmp = (x + -2.0) * (4.16438922228 + (z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x)))))));
} else {
tmp = ((x - 2.0) * (z + (x * (y + (x * 137.519416416))))) / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606);
}
return tmp;
}
def code(x, y, z): tmp = 0 if (x <= -1.2e+22) or not (x <= 52000.0): tmp = (x + -2.0) * (4.16438922228 + (z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x))))))) else: tmp = ((x - 2.0) * (z + (x * (y + (x * 137.519416416))))) / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606) return tmp
function code(x, y, z) tmp = 0.0 if ((x <= -1.2e+22) || !(x <= 52000.0)) tmp = Float64(Float64(x + -2.0) * Float64(4.16438922228 + Float64(z / Float64(47.066876606 + Float64(x * Float64(313.399215894 + Float64(Float64(x + 43.3400022514) * Float64(x * x)))))))); else tmp = Float64(Float64(Float64(x - 2.0) * Float64(z + Float64(x * Float64(y + Float64(x * 137.519416416))))) / Float64(Float64(x * Float64(Float64(x * Float64(Float64(x * Float64(x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606)); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((x <= -1.2e+22) || ~((x <= 52000.0))) tmp = (x + -2.0) * (4.16438922228 + (z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x))))))); else tmp = ((x - 2.0) * (z + (x * (y + (x * 137.519416416))))) / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606); end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[x, -1.2e+22], N[Not[LessEqual[x, 52000.0]], $MachinePrecision]], N[(N[(x + -2.0), $MachinePrecision] * N[(4.16438922228 + N[(z / N[(47.066876606 + N[(x * N[(313.399215894 + N[(N[(x + 43.3400022514), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(x - 2.0), $MachinePrecision] * N[(z + N[(x * N[(y + N[(x * 137.519416416), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(x * N[(N[(x * N[(N[(x * N[(x + 43.3400022514), $MachinePrecision]), $MachinePrecision] + 263.505074721), $MachinePrecision]), $MachinePrecision] + 313.399215894), $MachinePrecision]), $MachinePrecision] + 47.066876606), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.2 \cdot 10^{+22} \lor \neg \left(x \leq 52000\right):\\
\;\;\;\;\left(x + -2\right) \cdot \left(4.16438922228 + \frac{z}{47.066876606 + x \cdot \left(313.399215894 + \left(x + 43.3400022514\right) \cdot \left(x \cdot x\right)\right)}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{\left(x - 2\right) \cdot \left(z + x \cdot \left(y + x \cdot 137.519416416\right)\right)}{x \cdot \left(x \cdot \left(x \cdot \left(x + 43.3400022514\right) + 263.505074721\right) + 313.399215894\right) + 47.066876606}\\
\end{array}
\end{array}
if x < -1.2e22 or 52000 < x Initial program 14.4%
associate-*r/19.2%
sub-neg19.2%
metadata-eval19.2%
*-commutative19.2%
fma-def19.2%
*-commutative19.2%
fma-def19.2%
*-commutative19.2%
fma-def19.2%
fma-def19.2%
*-commutative19.2%
Simplified19.2%
Taylor expanded in z around 0 19.2%
Taylor expanded in x around inf 94.9%
Taylor expanded in x around inf 71.6%
cube-mult71.6%
unpow271.6%
distribute-rgt-in94.9%
unpow294.9%
+-commutative94.9%
Simplified94.9%
if -1.2e22 < x < 52000Initial program 99.6%
Taylor expanded in x around 0 99.3%
*-commutative96.2%
Simplified99.3%
Final simplification97.3%
(FPCore (x y z)
:precision binary64
(if (<= x -1.35)
(+
(/ 4752.4581585918595 x)
(-
(+ (* x 4.16438922228) (/ y (* x x)))
(+ 110.1139242984811 (/ 207551.7024428275 (* x x)))))
(if (<= x 0.00032)
(/
(* (- x 2.0) (+ z (* x (+ y (* x 137.519416416)))))
(+ 47.066876606 (* x (+ 313.399215894 (* (+ x 43.3400022514) (* x x))))))
(*
(+ x -2.0)
(+
4.16438922228
(/
z
(+
(*
x
(+ (* x (+ (* x (+ x 43.3400022514)) 263.505074721)) 313.399215894))
47.066876606)))))))
double code(double x, double y, double z) {
double tmp;
if (x <= -1.35) {
tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x))));
} else if (x <= 0.00032) {
tmp = ((x - 2.0) * (z + (x * (y + (x * 137.519416416))))) / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x)))));
} else {
tmp = (x + -2.0) * (4.16438922228 + (z / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606)));
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if (x <= (-1.35d0)) then
tmp = (4752.4581585918595d0 / x) + (((x * 4.16438922228d0) + (y / (x * x))) - (110.1139242984811d0 + (207551.7024428275d0 / (x * x))))
else if (x <= 0.00032d0) then
tmp = ((x - 2.0d0) * (z + (x * (y + (x * 137.519416416d0))))) / (47.066876606d0 + (x * (313.399215894d0 + ((x + 43.3400022514d0) * (x * x)))))
else
tmp = (x + (-2.0d0)) * (4.16438922228d0 + (z / ((x * ((x * ((x * (x + 43.3400022514d0)) + 263.505074721d0)) + 313.399215894d0)) + 47.066876606d0)))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= -1.35) {
tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x))));
} else if (x <= 0.00032) {
tmp = ((x - 2.0) * (z + (x * (y + (x * 137.519416416))))) / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x)))));
} else {
tmp = (x + -2.0) * (4.16438922228 + (z / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606)));
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= -1.35: tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x)))) elif x <= 0.00032: tmp = ((x - 2.0) * (z + (x * (y + (x * 137.519416416))))) / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x))))) else: tmp = (x + -2.0) * (4.16438922228 + (z / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606))) return tmp
function code(x, y, z) tmp = 0.0 if (x <= -1.35) tmp = Float64(Float64(4752.4581585918595 / x) + Float64(Float64(Float64(x * 4.16438922228) + Float64(y / Float64(x * x))) - Float64(110.1139242984811 + Float64(207551.7024428275 / Float64(x * x))))); elseif (x <= 0.00032) tmp = Float64(Float64(Float64(x - 2.0) * Float64(z + Float64(x * Float64(y + Float64(x * 137.519416416))))) / Float64(47.066876606 + Float64(x * Float64(313.399215894 + Float64(Float64(x + 43.3400022514) * Float64(x * x)))))); else tmp = Float64(Float64(x + -2.0) * Float64(4.16438922228 + Float64(z / Float64(Float64(x * Float64(Float64(x * Float64(Float64(x * Float64(x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606)))); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= -1.35) tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x)))); elseif (x <= 0.00032) tmp = ((x - 2.0) * (z + (x * (y + (x * 137.519416416))))) / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x))))); else tmp = (x + -2.0) * (4.16438922228 + (z / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606))); end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, -1.35], N[(N[(4752.4581585918595 / x), $MachinePrecision] + N[(N[(N[(x * 4.16438922228), $MachinePrecision] + N[(y / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(110.1139242984811 + N[(207551.7024428275 / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 0.00032], N[(N[(N[(x - 2.0), $MachinePrecision] * N[(z + N[(x * N[(y + N[(x * 137.519416416), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(47.066876606 + N[(x * N[(313.399215894 + N[(N[(x + 43.3400022514), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x + -2.0), $MachinePrecision] * N[(4.16438922228 + N[(z / N[(N[(x * N[(N[(x * N[(N[(x * N[(x + 43.3400022514), $MachinePrecision]), $MachinePrecision] + 263.505074721), $MachinePrecision]), $MachinePrecision] + 313.399215894), $MachinePrecision]), $MachinePrecision] + 47.066876606), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.35:\\
\;\;\;\;\frac{4752.4581585918595}{x} + \left(\left(x \cdot 4.16438922228 + \frac{y}{x \cdot x}\right) - \left(110.1139242984811 + \frac{207551.7024428275}{x \cdot x}\right)\right)\\
\mathbf{elif}\;x \leq 0.00032:\\
\;\;\;\;\frac{\left(x - 2\right) \cdot \left(z + x \cdot \left(y + x \cdot 137.519416416\right)\right)}{47.066876606 + x \cdot \left(313.399215894 + \left(x + 43.3400022514\right) \cdot \left(x \cdot x\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\left(x + -2\right) \cdot \left(4.16438922228 + \frac{z}{x \cdot \left(x \cdot \left(x \cdot \left(x + 43.3400022514\right) + 263.505074721\right) + 313.399215894\right) + 47.066876606}\right)\\
\end{array}
\end{array}
if x < -1.3500000000000001Initial program 19.3%
Taylor expanded in x around inf 17.8%
cube-mult17.7%
unpow217.7%
distribute-rgt-out17.7%
+-commutative17.7%
unpow217.7%
Simplified17.7%
Taylor expanded in x around inf 94.7%
associate--l+94.7%
associate-*r/94.7%
metadata-eval94.7%
+-commutative94.7%
*-commutative94.7%
unpow294.7%
associate-*r/94.7%
metadata-eval94.7%
unpow294.7%
Simplified94.7%
if -1.3500000000000001 < x < 3.20000000000000026e-4Initial program 99.6%
Taylor expanded in x around inf 98.1%
cube-mult98.1%
unpow298.1%
distribute-rgt-out98.1%
+-commutative98.1%
unpow298.1%
Simplified98.1%
Taylor expanded in x around 0 97.8%
*-commutative97.8%
Simplified97.8%
if 3.20000000000000026e-4 < x Initial program 14.9%
associate-*r/19.7%
sub-neg19.7%
metadata-eval19.7%
*-commutative19.7%
fma-def19.7%
*-commutative19.7%
fma-def19.7%
*-commutative19.7%
fma-def19.6%
fma-def19.6%
*-commutative19.6%
Simplified19.7%
Taylor expanded in z around 0 19.7%
Taylor expanded in x around inf 92.6%
Final simplification95.8%
(FPCore (x y z)
:precision binary64
(if (<= x -0.39)
(+
(/ 4752.4581585918595 x)
(-
(+ (* x 4.16438922228) (/ y (* x x)))
(+ 110.1139242984811 (/ 207551.7024428275 (* x x)))))
(if (<= x 0.000175)
(*
(+ x -2.0)
(+
(* z 0.0212463641547976)
(* x (- (* y 0.0212463641547976) (* z 0.14147091005106402)))))
(*
(+ x -2.0)
(+
4.16438922228
(/
z
(+
(*
x
(+ (* x (+ (* x (+ x 43.3400022514)) 263.505074721)) 313.399215894))
47.066876606)))))))
double code(double x, double y, double z) {
double tmp;
if (x <= -0.39) {
tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x))));
} else if (x <= 0.000175) {
tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402))));
} else {
tmp = (x + -2.0) * (4.16438922228 + (z / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606)));
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if (x <= (-0.39d0)) then
tmp = (4752.4581585918595d0 / x) + (((x * 4.16438922228d0) + (y / (x * x))) - (110.1139242984811d0 + (207551.7024428275d0 / (x * x))))
else if (x <= 0.000175d0) then
tmp = (x + (-2.0d0)) * ((z * 0.0212463641547976d0) + (x * ((y * 0.0212463641547976d0) - (z * 0.14147091005106402d0))))
else
tmp = (x + (-2.0d0)) * (4.16438922228d0 + (z / ((x * ((x * ((x * (x + 43.3400022514d0)) + 263.505074721d0)) + 313.399215894d0)) + 47.066876606d0)))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= -0.39) {
tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x))));
} else if (x <= 0.000175) {
tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402))));
} else {
tmp = (x + -2.0) * (4.16438922228 + (z / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606)));
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= -0.39: tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x)))) elif x <= 0.000175: tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402)))) else: tmp = (x + -2.0) * (4.16438922228 + (z / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606))) return tmp
function code(x, y, z) tmp = 0.0 if (x <= -0.39) tmp = Float64(Float64(4752.4581585918595 / x) + Float64(Float64(Float64(x * 4.16438922228) + Float64(y / Float64(x * x))) - Float64(110.1139242984811 + Float64(207551.7024428275 / Float64(x * x))))); elseif (x <= 0.000175) tmp = Float64(Float64(x + -2.0) * Float64(Float64(z * 0.0212463641547976) + Float64(x * Float64(Float64(y * 0.0212463641547976) - Float64(z * 0.14147091005106402))))); else tmp = Float64(Float64(x + -2.0) * Float64(4.16438922228 + Float64(z / Float64(Float64(x * Float64(Float64(x * Float64(Float64(x * Float64(x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606)))); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= -0.39) tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x)))); elseif (x <= 0.000175) tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402)))); else tmp = (x + -2.0) * (4.16438922228 + (z / ((x * ((x * ((x * (x + 43.3400022514)) + 263.505074721)) + 313.399215894)) + 47.066876606))); end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, -0.39], N[(N[(4752.4581585918595 / x), $MachinePrecision] + N[(N[(N[(x * 4.16438922228), $MachinePrecision] + N[(y / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(110.1139242984811 + N[(207551.7024428275 / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 0.000175], N[(N[(x + -2.0), $MachinePrecision] * N[(N[(z * 0.0212463641547976), $MachinePrecision] + N[(x * N[(N[(y * 0.0212463641547976), $MachinePrecision] - N[(z * 0.14147091005106402), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x + -2.0), $MachinePrecision] * N[(4.16438922228 + N[(z / N[(N[(x * N[(N[(x * N[(N[(x * N[(x + 43.3400022514), $MachinePrecision]), $MachinePrecision] + 263.505074721), $MachinePrecision]), $MachinePrecision] + 313.399215894), $MachinePrecision]), $MachinePrecision] + 47.066876606), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -0.39:\\
\;\;\;\;\frac{4752.4581585918595}{x} + \left(\left(x \cdot 4.16438922228 + \frac{y}{x \cdot x}\right) - \left(110.1139242984811 + \frac{207551.7024428275}{x \cdot x}\right)\right)\\
\mathbf{elif}\;x \leq 0.000175:\\
\;\;\;\;\left(x + -2\right) \cdot \left(z \cdot 0.0212463641547976 + x \cdot \left(y \cdot 0.0212463641547976 - z \cdot 0.14147091005106402\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x + -2\right) \cdot \left(4.16438922228 + \frac{z}{x \cdot \left(x \cdot \left(x \cdot \left(x + 43.3400022514\right) + 263.505074721\right) + 313.399215894\right) + 47.066876606}\right)\\
\end{array}
\end{array}
if x < -0.39000000000000001Initial program 19.3%
Taylor expanded in x around inf 17.8%
cube-mult17.7%
unpow217.7%
distribute-rgt-out17.7%
+-commutative17.7%
unpow217.7%
Simplified17.7%
Taylor expanded in x around inf 94.7%
associate--l+94.7%
associate-*r/94.7%
metadata-eval94.7%
+-commutative94.7%
*-commutative94.7%
unpow294.7%
associate-*r/94.7%
metadata-eval94.7%
unpow294.7%
Simplified94.7%
if -0.39000000000000001 < x < 1.74999999999999998e-4Initial program 99.6%
associate-*r/99.6%
sub-neg99.6%
metadata-eval99.6%
*-commutative99.6%
fma-def99.6%
*-commutative99.6%
fma-def99.6%
*-commutative99.6%
fma-def99.6%
fma-def99.6%
*-commutative99.6%
Simplified99.7%
Taylor expanded in x around 0 90.6%
if 1.74999999999999998e-4 < x Initial program 14.9%
associate-*r/19.7%
sub-neg19.7%
metadata-eval19.7%
*-commutative19.7%
fma-def19.7%
*-commutative19.7%
fma-def19.7%
*-commutative19.7%
fma-def19.6%
fma-def19.6%
*-commutative19.6%
Simplified19.7%
Taylor expanded in z around 0 19.7%
Taylor expanded in x around inf 92.6%
Final simplification92.1%
(FPCore (x y z)
:precision binary64
(if (or (<= x -1.4e+21) (not (<= x 1450.0)))
(*
(+ x -2.0)
(+
4.16438922228
(/
z
(+
47.066876606
(* x (+ 313.399215894 (* (+ x 43.3400022514) (* x x))))))))
(*
(+ x -2.0)
(+
(* z 0.0212463641547976)
(* x (- (* y 0.0212463641547976) (* z 0.14147091005106402)))))))
double code(double x, double y, double z) {
double tmp;
if ((x <= -1.4e+21) || !(x <= 1450.0)) {
tmp = (x + -2.0) * (4.16438922228 + (z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x)))))));
} else {
tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402))));
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if ((x <= (-1.4d+21)) .or. (.not. (x <= 1450.0d0))) then
tmp = (x + (-2.0d0)) * (4.16438922228d0 + (z / (47.066876606d0 + (x * (313.399215894d0 + ((x + 43.3400022514d0) * (x * x)))))))
else
tmp = (x + (-2.0d0)) * ((z * 0.0212463641547976d0) + (x * ((y * 0.0212463641547976d0) - (z * 0.14147091005106402d0))))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((x <= -1.4e+21) || !(x <= 1450.0)) {
tmp = (x + -2.0) * (4.16438922228 + (z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x)))))));
} else {
tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402))));
}
return tmp;
}
def code(x, y, z): tmp = 0 if (x <= -1.4e+21) or not (x <= 1450.0): tmp = (x + -2.0) * (4.16438922228 + (z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x))))))) else: tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402)))) return tmp
function code(x, y, z) tmp = 0.0 if ((x <= -1.4e+21) || !(x <= 1450.0)) tmp = Float64(Float64(x + -2.0) * Float64(4.16438922228 + Float64(z / Float64(47.066876606 + Float64(x * Float64(313.399215894 + Float64(Float64(x + 43.3400022514) * Float64(x * x)))))))); else tmp = Float64(Float64(x + -2.0) * Float64(Float64(z * 0.0212463641547976) + Float64(x * Float64(Float64(y * 0.0212463641547976) - Float64(z * 0.14147091005106402))))); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((x <= -1.4e+21) || ~((x <= 1450.0))) tmp = (x + -2.0) * (4.16438922228 + (z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x))))))); else tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402)))); end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[x, -1.4e+21], N[Not[LessEqual[x, 1450.0]], $MachinePrecision]], N[(N[(x + -2.0), $MachinePrecision] * N[(4.16438922228 + N[(z / N[(47.066876606 + N[(x * N[(313.399215894 + N[(N[(x + 43.3400022514), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x + -2.0), $MachinePrecision] * N[(N[(z * 0.0212463641547976), $MachinePrecision] + N[(x * N[(N[(y * 0.0212463641547976), $MachinePrecision] - N[(z * 0.14147091005106402), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.4 \cdot 10^{+21} \lor \neg \left(x \leq 1450\right):\\
\;\;\;\;\left(x + -2\right) \cdot \left(4.16438922228 + \frac{z}{47.066876606 + x \cdot \left(313.399215894 + \left(x + 43.3400022514\right) \cdot \left(x \cdot x\right)\right)}\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x + -2\right) \cdot \left(z \cdot 0.0212463641547976 + x \cdot \left(y \cdot 0.0212463641547976 - z \cdot 0.14147091005106402\right)\right)\\
\end{array}
\end{array}
if x < -1.4e21 or 1450 < x Initial program 14.4%
associate-*r/19.2%
sub-neg19.2%
metadata-eval19.2%
*-commutative19.2%
fma-def19.2%
*-commutative19.2%
fma-def19.2%
*-commutative19.2%
fma-def19.2%
fma-def19.2%
*-commutative19.2%
Simplified19.2%
Taylor expanded in z around 0 19.2%
Taylor expanded in x around inf 94.9%
Taylor expanded in x around inf 71.6%
cube-mult71.6%
unpow271.6%
distribute-rgt-in94.9%
unpow294.9%
+-commutative94.9%
Simplified94.9%
if -1.4e21 < x < 1450Initial program 99.6%
associate-*r/99.6%
sub-neg99.6%
metadata-eval99.6%
*-commutative99.6%
fma-def99.6%
*-commutative99.6%
fma-def99.6%
*-commutative99.6%
fma-def99.6%
fma-def99.6%
*-commutative99.6%
Simplified99.6%
Taylor expanded in x around 0 88.5%
Final simplification91.5%
(FPCore (x y z)
:precision binary64
(if (<= x -0.42)
(+
(/ 4752.4581585918595 x)
(-
(+ (* x 4.16438922228) (/ y (* x x)))
(+ 110.1139242984811 (/ 207551.7024428275 (* x x)))))
(if (<= x 1450.0)
(*
(+ x -2.0)
(+
(* z 0.0212463641547976)
(* x (- (* y 0.0212463641547976) (* z 0.14147091005106402)))))
(*
(+ x -2.0)
(+
4.16438922228
(/
z
(+
47.066876606
(* x (+ 313.399215894 (* (+ x 43.3400022514) (* x x)))))))))))
double code(double x, double y, double z) {
double tmp;
if (x <= -0.42) {
tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x))));
} else if (x <= 1450.0) {
tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402))));
} else {
tmp = (x + -2.0) * (4.16438922228 + (z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x)))))));
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if (x <= (-0.42d0)) then
tmp = (4752.4581585918595d0 / x) + (((x * 4.16438922228d0) + (y / (x * x))) - (110.1139242984811d0 + (207551.7024428275d0 / (x * x))))
else if (x <= 1450.0d0) then
tmp = (x + (-2.0d0)) * ((z * 0.0212463641547976d0) + (x * ((y * 0.0212463641547976d0) - (z * 0.14147091005106402d0))))
else
tmp = (x + (-2.0d0)) * (4.16438922228d0 + (z / (47.066876606d0 + (x * (313.399215894d0 + ((x + 43.3400022514d0) * (x * x)))))))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= -0.42) {
tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x))));
} else if (x <= 1450.0) {
tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402))));
} else {
tmp = (x + -2.0) * (4.16438922228 + (z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x)))))));
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= -0.42: tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x)))) elif x <= 1450.0: tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402)))) else: tmp = (x + -2.0) * (4.16438922228 + (z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x))))))) return tmp
function code(x, y, z) tmp = 0.0 if (x <= -0.42) tmp = Float64(Float64(4752.4581585918595 / x) + Float64(Float64(Float64(x * 4.16438922228) + Float64(y / Float64(x * x))) - Float64(110.1139242984811 + Float64(207551.7024428275 / Float64(x * x))))); elseif (x <= 1450.0) tmp = Float64(Float64(x + -2.0) * Float64(Float64(z * 0.0212463641547976) + Float64(x * Float64(Float64(y * 0.0212463641547976) - Float64(z * 0.14147091005106402))))); else tmp = Float64(Float64(x + -2.0) * Float64(4.16438922228 + Float64(z / Float64(47.066876606 + Float64(x * Float64(313.399215894 + Float64(Float64(x + 43.3400022514) * Float64(x * x)))))))); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= -0.42) tmp = (4752.4581585918595 / x) + (((x * 4.16438922228) + (y / (x * x))) - (110.1139242984811 + (207551.7024428275 / (x * x)))); elseif (x <= 1450.0) tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402)))); else tmp = (x + -2.0) * (4.16438922228 + (z / (47.066876606 + (x * (313.399215894 + ((x + 43.3400022514) * (x * x))))))); end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, -0.42], N[(N[(4752.4581585918595 / x), $MachinePrecision] + N[(N[(N[(x * 4.16438922228), $MachinePrecision] + N[(y / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(110.1139242984811 + N[(207551.7024428275 / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1450.0], N[(N[(x + -2.0), $MachinePrecision] * N[(N[(z * 0.0212463641547976), $MachinePrecision] + N[(x * N[(N[(y * 0.0212463641547976), $MachinePrecision] - N[(z * 0.14147091005106402), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x + -2.0), $MachinePrecision] * N[(4.16438922228 + N[(z / N[(47.066876606 + N[(x * N[(313.399215894 + N[(N[(x + 43.3400022514), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -0.42:\\
\;\;\;\;\frac{4752.4581585918595}{x} + \left(\left(x \cdot 4.16438922228 + \frac{y}{x \cdot x}\right) - \left(110.1139242984811 + \frac{207551.7024428275}{x \cdot x}\right)\right)\\
\mathbf{elif}\;x \leq 1450:\\
\;\;\;\;\left(x + -2\right) \cdot \left(z \cdot 0.0212463641547976 + x \cdot \left(y \cdot 0.0212463641547976 - z \cdot 0.14147091005106402\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x + -2\right) \cdot \left(4.16438922228 + \frac{z}{47.066876606 + x \cdot \left(313.399215894 + \left(x + 43.3400022514\right) \cdot \left(x \cdot x\right)\right)}\right)\\
\end{array}
\end{array}
if x < -0.419999999999999984Initial program 19.3%
Taylor expanded in x around inf 17.8%
cube-mult17.7%
unpow217.7%
distribute-rgt-out17.7%
+-commutative17.7%
unpow217.7%
Simplified17.7%
Taylor expanded in x around inf 94.7%
associate--l+94.7%
associate-*r/94.7%
metadata-eval94.7%
+-commutative94.7%
*-commutative94.7%
unpow294.7%
associate-*r/94.7%
metadata-eval94.7%
unpow294.7%
Simplified94.7%
if -0.419999999999999984 < x < 1450Initial program 99.6%
associate-*r/99.6%
sub-neg99.6%
metadata-eval99.6%
*-commutative99.6%
fma-def99.6%
*-commutative99.6%
fma-def99.6%
*-commutative99.6%
fma-def99.6%
fma-def99.6%
*-commutative99.6%
Simplified99.7%
Taylor expanded in x around 0 89.6%
if 1450 < x Initial program 12.1%
associate-*r/17.0%
sub-neg17.0%
metadata-eval17.0%
*-commutative17.0%
fma-def17.0%
*-commutative17.0%
fma-def17.0%
*-commutative17.0%
fma-def17.0%
fma-def17.0%
*-commutative17.0%
Simplified17.0%
Taylor expanded in z around 0 17.0%
Taylor expanded in x around inf 93.9%
Taylor expanded in x around inf 93.9%
cube-mult93.9%
unpow293.9%
distribute-rgt-in93.9%
unpow293.9%
+-commutative93.9%
Simplified93.9%
Final simplification91.8%
(FPCore (x y z)
:precision binary64
(if (<= x -1.4e+21)
(/ (+ x -2.0) 0.24013125253755718)
(if (<= x 1450.0)
(*
(+ x -2.0)
(+
(* z 0.0212463641547976)
(* x (- (* y 0.0212463641547976) (* z 0.14147091005106402)))))
(/
(+ x -2.0)
(+
(/ 5.86923874282773 x)
(- 0.24013125253755718 (/ 55.572073733743466 (* x x))))))))
double code(double x, double y, double z) {
double tmp;
if (x <= -1.4e+21) {
tmp = (x + -2.0) / 0.24013125253755718;
} else if (x <= 1450.0) {
tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402))));
} else {
tmp = (x + -2.0) / ((5.86923874282773 / x) + (0.24013125253755718 - (55.572073733743466 / (x * x))));
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if (x <= (-1.4d+21)) then
tmp = (x + (-2.0d0)) / 0.24013125253755718d0
else if (x <= 1450.0d0) then
tmp = (x + (-2.0d0)) * ((z * 0.0212463641547976d0) + (x * ((y * 0.0212463641547976d0) - (z * 0.14147091005106402d0))))
else
tmp = (x + (-2.0d0)) / ((5.86923874282773d0 / x) + (0.24013125253755718d0 - (55.572073733743466d0 / (x * x))))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= -1.4e+21) {
tmp = (x + -2.0) / 0.24013125253755718;
} else if (x <= 1450.0) {
tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402))));
} else {
tmp = (x + -2.0) / ((5.86923874282773 / x) + (0.24013125253755718 - (55.572073733743466 / (x * x))));
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= -1.4e+21: tmp = (x + -2.0) / 0.24013125253755718 elif x <= 1450.0: tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402)))) else: tmp = (x + -2.0) / ((5.86923874282773 / x) + (0.24013125253755718 - (55.572073733743466 / (x * x)))) return tmp
function code(x, y, z) tmp = 0.0 if (x <= -1.4e+21) tmp = Float64(Float64(x + -2.0) / 0.24013125253755718); elseif (x <= 1450.0) tmp = Float64(Float64(x + -2.0) * Float64(Float64(z * 0.0212463641547976) + Float64(x * Float64(Float64(y * 0.0212463641547976) - Float64(z * 0.14147091005106402))))); else tmp = Float64(Float64(x + -2.0) / Float64(Float64(5.86923874282773 / x) + Float64(0.24013125253755718 - Float64(55.572073733743466 / Float64(x * x))))); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= -1.4e+21) tmp = (x + -2.0) / 0.24013125253755718; elseif (x <= 1450.0) tmp = (x + -2.0) * ((z * 0.0212463641547976) + (x * ((y * 0.0212463641547976) - (z * 0.14147091005106402)))); else tmp = (x + -2.0) / ((5.86923874282773 / x) + (0.24013125253755718 - (55.572073733743466 / (x * x)))); end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, -1.4e+21], N[(N[(x + -2.0), $MachinePrecision] / 0.24013125253755718), $MachinePrecision], If[LessEqual[x, 1450.0], N[(N[(x + -2.0), $MachinePrecision] * N[(N[(z * 0.0212463641547976), $MachinePrecision] + N[(x * N[(N[(y * 0.0212463641547976), $MachinePrecision] - N[(z * 0.14147091005106402), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x + -2.0), $MachinePrecision] / N[(N[(5.86923874282773 / x), $MachinePrecision] + N[(0.24013125253755718 - N[(55.572073733743466 / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.4 \cdot 10^{+21}:\\
\;\;\;\;\frac{x + -2}{0.24013125253755718}\\
\mathbf{elif}\;x \leq 1450:\\
\;\;\;\;\left(x + -2\right) \cdot \left(z \cdot 0.0212463641547976 + x \cdot \left(y \cdot 0.0212463641547976 - z \cdot 0.14147091005106402\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{x + -2}{\frac{5.86923874282773}{x} + \left(0.24013125253755718 - \frac{55.572073733743466}{x \cdot x}\right)}\\
\end{array}
\end{array}
if x < -1.4e21Initial program 16.7%
associate-/l*21.4%
sub-neg21.4%
metadata-eval21.4%
fma-def21.4%
fma-def21.4%
fma-def21.4%
fma-def21.4%
fma-def21.4%
fma-def21.4%
fma-def21.4%
Simplified21.4%
Taylor expanded in x around inf 93.4%
if -1.4e21 < x < 1450Initial program 99.6%
associate-*r/99.6%
sub-neg99.6%
metadata-eval99.6%
*-commutative99.6%
fma-def99.6%
*-commutative99.6%
fma-def99.6%
*-commutative99.6%
fma-def99.6%
fma-def99.6%
*-commutative99.6%
Simplified99.6%
Taylor expanded in x around 0 88.5%
if 1450 < x Initial program 12.1%
associate-/l*16.9%
sub-neg16.9%
metadata-eval16.9%
fma-def16.9%
fma-def16.9%
fma-def16.9%
fma-def16.9%
fma-def16.9%
fma-def16.9%
fma-def16.9%
Simplified16.9%
Taylor expanded in x around inf 90.8%
+-commutative90.8%
associate--l+90.8%
associate-*r/90.8%
metadata-eval90.8%
associate-*r/90.8%
metadata-eval90.8%
unpow290.8%
Simplified90.8%
Final simplification90.1%
(FPCore (x y z)
:precision binary64
(if (<= x -0.36)
(/ (+ x -2.0) 0.24013125253755718)
(if (<= x 1800.0)
(/ (+ x -2.0) (/ 47.066876606 z))
(/
(+ x -2.0)
(+
(/ 5.86923874282773 x)
(- 0.24013125253755718 (/ 55.572073733743466 (* x x))))))))
double code(double x, double y, double z) {
double tmp;
if (x <= -0.36) {
tmp = (x + -2.0) / 0.24013125253755718;
} else if (x <= 1800.0) {
tmp = (x + -2.0) / (47.066876606 / z);
} else {
tmp = (x + -2.0) / ((5.86923874282773 / x) + (0.24013125253755718 - (55.572073733743466 / (x * x))));
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if (x <= (-0.36d0)) then
tmp = (x + (-2.0d0)) / 0.24013125253755718d0
else if (x <= 1800.0d0) then
tmp = (x + (-2.0d0)) / (47.066876606d0 / z)
else
tmp = (x + (-2.0d0)) / ((5.86923874282773d0 / x) + (0.24013125253755718d0 - (55.572073733743466d0 / (x * x))))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= -0.36) {
tmp = (x + -2.0) / 0.24013125253755718;
} else if (x <= 1800.0) {
tmp = (x + -2.0) / (47.066876606 / z);
} else {
tmp = (x + -2.0) / ((5.86923874282773 / x) + (0.24013125253755718 - (55.572073733743466 / (x * x))));
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= -0.36: tmp = (x + -2.0) / 0.24013125253755718 elif x <= 1800.0: tmp = (x + -2.0) / (47.066876606 / z) else: tmp = (x + -2.0) / ((5.86923874282773 / x) + (0.24013125253755718 - (55.572073733743466 / (x * x)))) return tmp
function code(x, y, z) tmp = 0.0 if (x <= -0.36) tmp = Float64(Float64(x + -2.0) / 0.24013125253755718); elseif (x <= 1800.0) tmp = Float64(Float64(x + -2.0) / Float64(47.066876606 / z)); else tmp = Float64(Float64(x + -2.0) / Float64(Float64(5.86923874282773 / x) + Float64(0.24013125253755718 - Float64(55.572073733743466 / Float64(x * x))))); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= -0.36) tmp = (x + -2.0) / 0.24013125253755718; elseif (x <= 1800.0) tmp = (x + -2.0) / (47.066876606 / z); else tmp = (x + -2.0) / ((5.86923874282773 / x) + (0.24013125253755718 - (55.572073733743466 / (x * x)))); end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, -0.36], N[(N[(x + -2.0), $MachinePrecision] / 0.24013125253755718), $MachinePrecision], If[LessEqual[x, 1800.0], N[(N[(x + -2.0), $MachinePrecision] / N[(47.066876606 / z), $MachinePrecision]), $MachinePrecision], N[(N[(x + -2.0), $MachinePrecision] / N[(N[(5.86923874282773 / x), $MachinePrecision] + N[(0.24013125253755718 - N[(55.572073733743466 / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -0.36:\\
\;\;\;\;\frac{x + -2}{0.24013125253755718}\\
\mathbf{elif}\;x \leq 1800:\\
\;\;\;\;\frac{x + -2}{\frac{47.066876606}{z}}\\
\mathbf{else}:\\
\;\;\;\;\frac{x + -2}{\frac{5.86923874282773}{x} + \left(0.24013125253755718 - \frac{55.572073733743466}{x \cdot x}\right)}\\
\end{array}
\end{array}
if x < -0.35999999999999999Initial program 19.3%
associate-/l*23.9%
sub-neg23.9%
metadata-eval23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
Simplified23.9%
Taylor expanded in x around inf 90.4%
if -0.35999999999999999 < x < 1800Initial program 99.6%
associate-/l*99.4%
sub-neg99.4%
metadata-eval99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
Simplified99.4%
Taylor expanded in x around 0 72.2%
if 1800 < x Initial program 12.1%
associate-/l*16.9%
sub-neg16.9%
metadata-eval16.9%
fma-def16.9%
fma-def16.9%
fma-def16.9%
fma-def16.9%
fma-def16.9%
fma-def16.9%
fma-def16.9%
Simplified16.9%
Taylor expanded in x around inf 90.8%
+-commutative90.8%
associate--l+90.8%
associate-*r/90.8%
metadata-eval90.8%
associate-*r/90.8%
metadata-eval90.8%
unpow290.8%
Simplified90.8%
Final simplification80.9%
(FPCore (x y z)
:precision binary64
(if (<= x -0.4)
(/ (+ x -2.0) 0.24013125253755718)
(if (<= x 1450.0)
(/ (+ x -2.0) (/ 47.066876606 z))
(* (+ x -2.0) (- 4.16438922228 (/ 101.7851458539211 x))))))
double code(double x, double y, double z) {
double tmp;
if (x <= -0.4) {
tmp = (x + -2.0) / 0.24013125253755718;
} else if (x <= 1450.0) {
tmp = (x + -2.0) / (47.066876606 / z);
} else {
tmp = (x + -2.0) * (4.16438922228 - (101.7851458539211 / x));
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if (x <= (-0.4d0)) then
tmp = (x + (-2.0d0)) / 0.24013125253755718d0
else if (x <= 1450.0d0) then
tmp = (x + (-2.0d0)) / (47.066876606d0 / z)
else
tmp = (x + (-2.0d0)) * (4.16438922228d0 - (101.7851458539211d0 / x))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= -0.4) {
tmp = (x + -2.0) / 0.24013125253755718;
} else if (x <= 1450.0) {
tmp = (x + -2.0) / (47.066876606 / z);
} else {
tmp = (x + -2.0) * (4.16438922228 - (101.7851458539211 / x));
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= -0.4: tmp = (x + -2.0) / 0.24013125253755718 elif x <= 1450.0: tmp = (x + -2.0) / (47.066876606 / z) else: tmp = (x + -2.0) * (4.16438922228 - (101.7851458539211 / x)) return tmp
function code(x, y, z) tmp = 0.0 if (x <= -0.4) tmp = Float64(Float64(x + -2.0) / 0.24013125253755718); elseif (x <= 1450.0) tmp = Float64(Float64(x + -2.0) / Float64(47.066876606 / z)); else tmp = Float64(Float64(x + -2.0) * Float64(4.16438922228 - Float64(101.7851458539211 / x))); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= -0.4) tmp = (x + -2.0) / 0.24013125253755718; elseif (x <= 1450.0) tmp = (x + -2.0) / (47.066876606 / z); else tmp = (x + -2.0) * (4.16438922228 - (101.7851458539211 / x)); end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, -0.4], N[(N[(x + -2.0), $MachinePrecision] / 0.24013125253755718), $MachinePrecision], If[LessEqual[x, 1450.0], N[(N[(x + -2.0), $MachinePrecision] / N[(47.066876606 / z), $MachinePrecision]), $MachinePrecision], N[(N[(x + -2.0), $MachinePrecision] * N[(4.16438922228 - N[(101.7851458539211 / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -0.4:\\
\;\;\;\;\frac{x + -2}{0.24013125253755718}\\
\mathbf{elif}\;x \leq 1450:\\
\;\;\;\;\frac{x + -2}{\frac{47.066876606}{z}}\\
\mathbf{else}:\\
\;\;\;\;\left(x + -2\right) \cdot \left(4.16438922228 - \frac{101.7851458539211}{x}\right)\\
\end{array}
\end{array}
if x < -0.40000000000000002Initial program 19.3%
associate-/l*23.9%
sub-neg23.9%
metadata-eval23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
Simplified23.9%
Taylor expanded in x around inf 90.4%
if -0.40000000000000002 < x < 1450Initial program 99.6%
associate-/l*99.4%
sub-neg99.4%
metadata-eval99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
Simplified99.4%
Taylor expanded in x around 0 72.2%
if 1450 < x Initial program 12.1%
associate-*r/17.0%
sub-neg17.0%
metadata-eval17.0%
*-commutative17.0%
fma-def17.0%
*-commutative17.0%
fma-def17.0%
*-commutative17.0%
fma-def17.0%
fma-def17.0%
*-commutative17.0%
Simplified17.0%
Taylor expanded in x around inf 90.2%
associate-*r/90.2%
metadata-eval90.2%
Simplified90.2%
Final simplification80.7%
(FPCore (x y z)
:precision binary64
(if (<= x -3.4)
(/ (+ x -2.0) 0.24013125253755718)
(if (<= x 1450.0)
(/ (+ x -2.0) (/ 47.066876606 z))
(/ (+ x -2.0) (+ 0.24013125253755718 (/ 5.86923874282773 x))))))
double code(double x, double y, double z) {
double tmp;
if (x <= -3.4) {
tmp = (x + -2.0) / 0.24013125253755718;
} else if (x <= 1450.0) {
tmp = (x + -2.0) / (47.066876606 / z);
} else {
tmp = (x + -2.0) / (0.24013125253755718 + (5.86923874282773 / x));
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if (x <= (-3.4d0)) then
tmp = (x + (-2.0d0)) / 0.24013125253755718d0
else if (x <= 1450.0d0) then
tmp = (x + (-2.0d0)) / (47.066876606d0 / z)
else
tmp = (x + (-2.0d0)) / (0.24013125253755718d0 + (5.86923874282773d0 / x))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= -3.4) {
tmp = (x + -2.0) / 0.24013125253755718;
} else if (x <= 1450.0) {
tmp = (x + -2.0) / (47.066876606 / z);
} else {
tmp = (x + -2.0) / (0.24013125253755718 + (5.86923874282773 / x));
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= -3.4: tmp = (x + -2.0) / 0.24013125253755718 elif x <= 1450.0: tmp = (x + -2.0) / (47.066876606 / z) else: tmp = (x + -2.0) / (0.24013125253755718 + (5.86923874282773 / x)) return tmp
function code(x, y, z) tmp = 0.0 if (x <= -3.4) tmp = Float64(Float64(x + -2.0) / 0.24013125253755718); elseif (x <= 1450.0) tmp = Float64(Float64(x + -2.0) / Float64(47.066876606 / z)); else tmp = Float64(Float64(x + -2.0) / Float64(0.24013125253755718 + Float64(5.86923874282773 / x))); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= -3.4) tmp = (x + -2.0) / 0.24013125253755718; elseif (x <= 1450.0) tmp = (x + -2.0) / (47.066876606 / z); else tmp = (x + -2.0) / (0.24013125253755718 + (5.86923874282773 / x)); end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, -3.4], N[(N[(x + -2.0), $MachinePrecision] / 0.24013125253755718), $MachinePrecision], If[LessEqual[x, 1450.0], N[(N[(x + -2.0), $MachinePrecision] / N[(47.066876606 / z), $MachinePrecision]), $MachinePrecision], N[(N[(x + -2.0), $MachinePrecision] / N[(0.24013125253755718 + N[(5.86923874282773 / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -3.4:\\
\;\;\;\;\frac{x + -2}{0.24013125253755718}\\
\mathbf{elif}\;x \leq 1450:\\
\;\;\;\;\frac{x + -2}{\frac{47.066876606}{z}}\\
\mathbf{else}:\\
\;\;\;\;\frac{x + -2}{0.24013125253755718 + \frac{5.86923874282773}{x}}\\
\end{array}
\end{array}
if x < -3.39999999999999991Initial program 19.3%
associate-/l*23.9%
sub-neg23.9%
metadata-eval23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
Simplified23.9%
Taylor expanded in x around inf 90.4%
if -3.39999999999999991 < x < 1450Initial program 99.6%
associate-/l*99.4%
sub-neg99.4%
metadata-eval99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
Simplified99.4%
Taylor expanded in x around 0 72.2%
if 1450 < x Initial program 12.1%
associate-/l*16.9%
sub-neg16.9%
metadata-eval16.9%
fma-def16.9%
fma-def16.9%
fma-def16.9%
fma-def16.9%
fma-def16.9%
fma-def16.9%
fma-def16.9%
Simplified16.9%
Taylor expanded in x around inf 90.7%
associate-*r/90.7%
metadata-eval90.7%
Simplified90.7%
Final simplification80.9%
(FPCore (x y z)
:precision binary64
(if (<= x -0.39)
(/ (+ x -2.0) 0.24013125253755718)
(if (<= x 1550.0)
(* (+ x -2.0) (* z 0.0212463641547976))
(- (* x 4.16438922228) 110.1139242984811))))
double code(double x, double y, double z) {
double tmp;
if (x <= -0.39) {
tmp = (x + -2.0) / 0.24013125253755718;
} else if (x <= 1550.0) {
tmp = (x + -2.0) * (z * 0.0212463641547976);
} else {
tmp = (x * 4.16438922228) - 110.1139242984811;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if (x <= (-0.39d0)) then
tmp = (x + (-2.0d0)) / 0.24013125253755718d0
else if (x <= 1550.0d0) then
tmp = (x + (-2.0d0)) * (z * 0.0212463641547976d0)
else
tmp = (x * 4.16438922228d0) - 110.1139242984811d0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= -0.39) {
tmp = (x + -2.0) / 0.24013125253755718;
} else if (x <= 1550.0) {
tmp = (x + -2.0) * (z * 0.0212463641547976);
} else {
tmp = (x * 4.16438922228) - 110.1139242984811;
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= -0.39: tmp = (x + -2.0) / 0.24013125253755718 elif x <= 1550.0: tmp = (x + -2.0) * (z * 0.0212463641547976) else: tmp = (x * 4.16438922228) - 110.1139242984811 return tmp
function code(x, y, z) tmp = 0.0 if (x <= -0.39) tmp = Float64(Float64(x + -2.0) / 0.24013125253755718); elseif (x <= 1550.0) tmp = Float64(Float64(x + -2.0) * Float64(z * 0.0212463641547976)); else tmp = Float64(Float64(x * 4.16438922228) - 110.1139242984811); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= -0.39) tmp = (x + -2.0) / 0.24013125253755718; elseif (x <= 1550.0) tmp = (x + -2.0) * (z * 0.0212463641547976); else tmp = (x * 4.16438922228) - 110.1139242984811; end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, -0.39], N[(N[(x + -2.0), $MachinePrecision] / 0.24013125253755718), $MachinePrecision], If[LessEqual[x, 1550.0], N[(N[(x + -2.0), $MachinePrecision] * N[(z * 0.0212463641547976), $MachinePrecision]), $MachinePrecision], N[(N[(x * 4.16438922228), $MachinePrecision] - 110.1139242984811), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -0.39:\\
\;\;\;\;\frac{x + -2}{0.24013125253755718}\\
\mathbf{elif}\;x \leq 1550:\\
\;\;\;\;\left(x + -2\right) \cdot \left(z \cdot 0.0212463641547976\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot 4.16438922228 - 110.1139242984811\\
\end{array}
\end{array}
if x < -0.39000000000000001Initial program 19.3%
associate-/l*23.9%
sub-neg23.9%
metadata-eval23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
Simplified23.9%
Taylor expanded in x around inf 90.4%
if -0.39000000000000001 < x < 1550Initial program 99.6%
associate-*r/99.6%
sub-neg99.6%
metadata-eval99.6%
*-commutative99.6%
fma-def99.6%
*-commutative99.6%
fma-def99.6%
*-commutative99.6%
fma-def99.6%
fma-def99.6%
*-commutative99.6%
Simplified99.7%
Taylor expanded in x around 0 72.0%
if 1550 < x Initial program 12.1%
associate-*r/17.0%
sub-neg17.0%
metadata-eval17.0%
*-commutative17.0%
fma-def17.0%
*-commutative17.0%
fma-def17.0%
*-commutative17.0%
fma-def17.0%
fma-def17.0%
*-commutative17.0%
Simplified17.0%
Taylor expanded in x around inf 90.2%
Final simplification80.7%
(FPCore (x y z)
:precision binary64
(if (<= x -0.39)
(/ (+ x -2.0) 0.24013125253755718)
(if (<= x 1450.0)
(/ (+ x -2.0) (/ 47.066876606 z))
(- (* x 4.16438922228) 110.1139242984811))))
double code(double x, double y, double z) {
double tmp;
if (x <= -0.39) {
tmp = (x + -2.0) / 0.24013125253755718;
} else if (x <= 1450.0) {
tmp = (x + -2.0) / (47.066876606 / z);
} else {
tmp = (x * 4.16438922228) - 110.1139242984811;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if (x <= (-0.39d0)) then
tmp = (x + (-2.0d0)) / 0.24013125253755718d0
else if (x <= 1450.0d0) then
tmp = (x + (-2.0d0)) / (47.066876606d0 / z)
else
tmp = (x * 4.16438922228d0) - 110.1139242984811d0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= -0.39) {
tmp = (x + -2.0) / 0.24013125253755718;
} else if (x <= 1450.0) {
tmp = (x + -2.0) / (47.066876606 / z);
} else {
tmp = (x * 4.16438922228) - 110.1139242984811;
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= -0.39: tmp = (x + -2.0) / 0.24013125253755718 elif x <= 1450.0: tmp = (x + -2.0) / (47.066876606 / z) else: tmp = (x * 4.16438922228) - 110.1139242984811 return tmp
function code(x, y, z) tmp = 0.0 if (x <= -0.39) tmp = Float64(Float64(x + -2.0) / 0.24013125253755718); elseif (x <= 1450.0) tmp = Float64(Float64(x + -2.0) / Float64(47.066876606 / z)); else tmp = Float64(Float64(x * 4.16438922228) - 110.1139242984811); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= -0.39) tmp = (x + -2.0) / 0.24013125253755718; elseif (x <= 1450.0) tmp = (x + -2.0) / (47.066876606 / z); else tmp = (x * 4.16438922228) - 110.1139242984811; end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, -0.39], N[(N[(x + -2.0), $MachinePrecision] / 0.24013125253755718), $MachinePrecision], If[LessEqual[x, 1450.0], N[(N[(x + -2.0), $MachinePrecision] / N[(47.066876606 / z), $MachinePrecision]), $MachinePrecision], N[(N[(x * 4.16438922228), $MachinePrecision] - 110.1139242984811), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -0.39:\\
\;\;\;\;\frac{x + -2}{0.24013125253755718}\\
\mathbf{elif}\;x \leq 1450:\\
\;\;\;\;\frac{x + -2}{\frac{47.066876606}{z}}\\
\mathbf{else}:\\
\;\;\;\;x \cdot 4.16438922228 - 110.1139242984811\\
\end{array}
\end{array}
if x < -0.39000000000000001Initial program 19.3%
associate-/l*23.9%
sub-neg23.9%
metadata-eval23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
Simplified23.9%
Taylor expanded in x around inf 90.4%
if -0.39000000000000001 < x < 1450Initial program 99.6%
associate-/l*99.4%
sub-neg99.4%
metadata-eval99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
fma-def99.4%
Simplified99.4%
Taylor expanded in x around 0 72.2%
if 1450 < x Initial program 12.1%
associate-*r/17.0%
sub-neg17.0%
metadata-eval17.0%
*-commutative17.0%
fma-def17.0%
*-commutative17.0%
fma-def17.0%
*-commutative17.0%
fma-def17.0%
fma-def17.0%
*-commutative17.0%
Simplified17.0%
Taylor expanded in x around inf 90.2%
Final simplification80.7%
(FPCore (x y z) :precision binary64 (if (or (<= x -3.4) (not (<= x 2.0))) (- (* x 4.16438922228) 110.1139242984811) (* z -0.0424927283095952)))
double code(double x, double y, double z) {
double tmp;
if ((x <= -3.4) || !(x <= 2.0)) {
tmp = (x * 4.16438922228) - 110.1139242984811;
} else {
tmp = z * -0.0424927283095952;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if ((x <= (-3.4d0)) .or. (.not. (x <= 2.0d0))) then
tmp = (x * 4.16438922228d0) - 110.1139242984811d0
else
tmp = z * (-0.0424927283095952d0)
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((x <= -3.4) || !(x <= 2.0)) {
tmp = (x * 4.16438922228) - 110.1139242984811;
} else {
tmp = z * -0.0424927283095952;
}
return tmp;
}
def code(x, y, z): tmp = 0 if (x <= -3.4) or not (x <= 2.0): tmp = (x * 4.16438922228) - 110.1139242984811 else: tmp = z * -0.0424927283095952 return tmp
function code(x, y, z) tmp = 0.0 if ((x <= -3.4) || !(x <= 2.0)) tmp = Float64(Float64(x * 4.16438922228) - 110.1139242984811); else tmp = Float64(z * -0.0424927283095952); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((x <= -3.4) || ~((x <= 2.0))) tmp = (x * 4.16438922228) - 110.1139242984811; else tmp = z * -0.0424927283095952; end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[x, -3.4], N[Not[LessEqual[x, 2.0]], $MachinePrecision]], N[(N[(x * 4.16438922228), $MachinePrecision] - 110.1139242984811), $MachinePrecision], N[(z * -0.0424927283095952), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -3.4 \lor \neg \left(x \leq 2\right):\\
\;\;\;\;x \cdot 4.16438922228 - 110.1139242984811\\
\mathbf{else}:\\
\;\;\;\;z \cdot -0.0424927283095952\\
\end{array}
\end{array}
if x < -3.39999999999999991 or 2 < x Initial program 16.4%
associate-*r/21.1%
sub-neg21.1%
metadata-eval21.1%
*-commutative21.1%
fma-def21.1%
*-commutative21.1%
fma-def21.1%
*-commutative21.1%
fma-def21.1%
fma-def21.1%
*-commutative21.1%
Simplified21.1%
Taylor expanded in x around inf 89.3%
if -3.39999999999999991 < x < 2Initial program 99.6%
associate-*r/99.6%
sub-neg99.6%
metadata-eval99.6%
*-commutative99.6%
fma-def99.6%
*-commutative99.6%
fma-def99.6%
*-commutative99.6%
fma-def99.6%
fma-def99.6%
*-commutative99.6%
Simplified99.7%
Taylor expanded in x around 0 72.5%
*-commutative72.5%
Simplified72.5%
Final simplification80.5%
(FPCore (x y z)
:precision binary64
(if (<= x -0.35)
(/ (+ x -2.0) 0.24013125253755718)
(if (<= x 20.0)
(* z -0.0424927283095952)
(- (* x 4.16438922228) 110.1139242984811))))
double code(double x, double y, double z) {
double tmp;
if (x <= -0.35) {
tmp = (x + -2.0) / 0.24013125253755718;
} else if (x <= 20.0) {
tmp = z * -0.0424927283095952;
} else {
tmp = (x * 4.16438922228) - 110.1139242984811;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if (x <= (-0.35d0)) then
tmp = (x + (-2.0d0)) / 0.24013125253755718d0
else if (x <= 20.0d0) then
tmp = z * (-0.0424927283095952d0)
else
tmp = (x * 4.16438922228d0) - 110.1139242984811d0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= -0.35) {
tmp = (x + -2.0) / 0.24013125253755718;
} else if (x <= 20.0) {
tmp = z * -0.0424927283095952;
} else {
tmp = (x * 4.16438922228) - 110.1139242984811;
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= -0.35: tmp = (x + -2.0) / 0.24013125253755718 elif x <= 20.0: tmp = z * -0.0424927283095952 else: tmp = (x * 4.16438922228) - 110.1139242984811 return tmp
function code(x, y, z) tmp = 0.0 if (x <= -0.35) tmp = Float64(Float64(x + -2.0) / 0.24013125253755718); elseif (x <= 20.0) tmp = Float64(z * -0.0424927283095952); else tmp = Float64(Float64(x * 4.16438922228) - 110.1139242984811); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= -0.35) tmp = (x + -2.0) / 0.24013125253755718; elseif (x <= 20.0) tmp = z * -0.0424927283095952; else tmp = (x * 4.16438922228) - 110.1139242984811; end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, -0.35], N[(N[(x + -2.0), $MachinePrecision] / 0.24013125253755718), $MachinePrecision], If[LessEqual[x, 20.0], N[(z * -0.0424927283095952), $MachinePrecision], N[(N[(x * 4.16438922228), $MachinePrecision] - 110.1139242984811), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -0.35:\\
\;\;\;\;\frac{x + -2}{0.24013125253755718}\\
\mathbf{elif}\;x \leq 20:\\
\;\;\;\;z \cdot -0.0424927283095952\\
\mathbf{else}:\\
\;\;\;\;x \cdot 4.16438922228 - 110.1139242984811\\
\end{array}
\end{array}
if x < -0.34999999999999998Initial program 19.3%
associate-/l*23.9%
sub-neg23.9%
metadata-eval23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
fma-def23.9%
Simplified23.9%
Taylor expanded in x around inf 90.4%
if -0.34999999999999998 < x < 20Initial program 99.6%
associate-*r/99.6%
sub-neg99.6%
metadata-eval99.6%
*-commutative99.6%
fma-def99.6%
*-commutative99.6%
fma-def99.6%
*-commutative99.6%
fma-def99.6%
fma-def99.6%
*-commutative99.6%
Simplified99.7%
Taylor expanded in x around 0 72.5%
*-commutative72.5%
Simplified72.5%
if 20 < x Initial program 13.5%
associate-*r/18.3%
sub-neg18.3%
metadata-eval18.3%
*-commutative18.3%
fma-def18.3%
*-commutative18.3%
fma-def18.3%
*-commutative18.3%
fma-def18.3%
fma-def18.3%
*-commutative18.3%
Simplified18.3%
Taylor expanded in x around inf 88.7%
Final simplification80.6%
(FPCore (x y z) :precision binary64 (if (<= x -3.4) (* x 4.16438922228) (if (<= x 2.0) (* z -0.0424927283095952) (* x 4.16438922228))))
double code(double x, double y, double z) {
double tmp;
if (x <= -3.4) {
tmp = x * 4.16438922228;
} else if (x <= 2.0) {
tmp = z * -0.0424927283095952;
} else {
tmp = x * 4.16438922228;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if (x <= (-3.4d0)) then
tmp = x * 4.16438922228d0
else if (x <= 2.0d0) then
tmp = z * (-0.0424927283095952d0)
else
tmp = x * 4.16438922228d0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= -3.4) {
tmp = x * 4.16438922228;
} else if (x <= 2.0) {
tmp = z * -0.0424927283095952;
} else {
tmp = x * 4.16438922228;
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= -3.4: tmp = x * 4.16438922228 elif x <= 2.0: tmp = z * -0.0424927283095952 else: tmp = x * 4.16438922228 return tmp
function code(x, y, z) tmp = 0.0 if (x <= -3.4) tmp = Float64(x * 4.16438922228); elseif (x <= 2.0) tmp = Float64(z * -0.0424927283095952); else tmp = Float64(x * 4.16438922228); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= -3.4) tmp = x * 4.16438922228; elseif (x <= 2.0) tmp = z * -0.0424927283095952; else tmp = x * 4.16438922228; end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, -3.4], N[(x * 4.16438922228), $MachinePrecision], If[LessEqual[x, 2.0], N[(z * -0.0424927283095952), $MachinePrecision], N[(x * 4.16438922228), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -3.4:\\
\;\;\;\;x \cdot 4.16438922228\\
\mathbf{elif}\;x \leq 2:\\
\;\;\;\;z \cdot -0.0424927283095952\\
\mathbf{else}:\\
\;\;\;\;x \cdot 4.16438922228\\
\end{array}
\end{array}
if x < -3.39999999999999991 or 2 < x Initial program 16.4%
associate-*r/21.1%
sub-neg21.1%
metadata-eval21.1%
*-commutative21.1%
fma-def21.1%
*-commutative21.1%
fma-def21.1%
*-commutative21.1%
fma-def21.1%
fma-def21.1%
*-commutative21.1%
Simplified21.1%
Taylor expanded in x around inf 88.9%
*-commutative88.9%
Simplified88.9%
if -3.39999999999999991 < x < 2Initial program 99.6%
associate-*r/99.6%
sub-neg99.6%
metadata-eval99.6%
*-commutative99.6%
fma-def99.6%
*-commutative99.6%
fma-def99.6%
*-commutative99.6%
fma-def99.6%
fma-def99.6%
*-commutative99.6%
Simplified99.7%
Taylor expanded in x around 0 72.5%
*-commutative72.5%
Simplified72.5%
Final simplification80.3%
(FPCore (x y z) :precision binary64 (* x -0.3407596943375357))
double code(double x, double y, double z) {
return x * -0.3407596943375357;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = x * (-0.3407596943375357d0)
end function
public static double code(double x, double y, double z) {
return x * -0.3407596943375357;
}
def code(x, y, z): return x * -0.3407596943375357
function code(x, y, z) return Float64(x * -0.3407596943375357) end
function tmp = code(x, y, z) tmp = x * -0.3407596943375357; end
code[x_, y_, z_] := N[(x * -0.3407596943375357), $MachinePrecision]
\begin{array}{l}
\\
x \cdot -0.3407596943375357
\end{array}
Initial program 60.0%
associate-/l*62.1%
sub-neg62.1%
metadata-eval62.1%
fma-def62.1%
fma-def62.1%
fma-def62.1%
fma-def62.1%
fma-def62.1%
fma-def62.1%
fma-def62.1%
Simplified62.1%
Taylor expanded in x around inf 44.6%
associate-*r/44.6%
metadata-eval44.6%
Simplified44.6%
Taylor expanded in x around 0 2.2%
*-commutative2.2%
Simplified2.2%
Final simplification2.2%
(FPCore (x y z) :precision binary64 (* x 4.16438922228))
double code(double x, double y, double z) {
return x * 4.16438922228;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = x * 4.16438922228d0
end function
public static double code(double x, double y, double z) {
return x * 4.16438922228;
}
def code(x, y, z): return x * 4.16438922228
function code(x, y, z) return Float64(x * 4.16438922228) end
function tmp = code(x, y, z) tmp = x * 4.16438922228; end
code[x_, y_, z_] := N[(x * 4.16438922228), $MachinePrecision]
\begin{array}{l}
\\
x \cdot 4.16438922228
\end{array}
Initial program 60.0%
associate-*r/62.2%
sub-neg62.2%
metadata-eval62.2%
*-commutative62.2%
fma-def62.2%
*-commutative62.2%
fma-def62.2%
*-commutative62.2%
fma-def62.2%
fma-def62.2%
*-commutative62.2%
Simplified62.2%
Taylor expanded in x around inf 44.1%
*-commutative44.1%
Simplified44.1%
Final simplification44.1%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (- (+ (/ y (* x x)) (* 4.16438922228 x)) 110.1139242984811)))
(if (< x -3.326128725870005e+62)
t_0
(if (< x 9.429991714554673e+55)
(*
(/ (- x 2.0) 1.0)
(/
(+
(*
(+
(* (+ (* (+ (* x 4.16438922228) 78.6994924154) x) 137.519416416) x)
y)
x)
z)
(+
(*
(+
(+ (* 263.505074721 x) (+ (* 43.3400022514 (* x x)) (* x (* x x))))
313.399215894)
x)
47.066876606)))
t_0))))
double code(double x, double y, double z) {
double t_0 = ((y / (x * x)) + (4.16438922228 * x)) - 110.1139242984811;
double tmp;
if (x < -3.326128725870005e+62) {
tmp = t_0;
} else if (x < 9.429991714554673e+55) {
tmp = ((x - 2.0) / 1.0) * (((((((((x * 4.16438922228) + 78.6994924154) * x) + 137.519416416) * x) + y) * x) + z) / (((((263.505074721 * x) + ((43.3400022514 * (x * x)) + (x * (x * x)))) + 313.399215894) * x) + 47.066876606));
} else {
tmp = t_0;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: t_0
real(8) :: tmp
t_0 = ((y / (x * x)) + (4.16438922228d0 * x)) - 110.1139242984811d0
if (x < (-3.326128725870005d+62)) then
tmp = t_0
else if (x < 9.429991714554673d+55) then
tmp = ((x - 2.0d0) / 1.0d0) * (((((((((x * 4.16438922228d0) + 78.6994924154d0) * x) + 137.519416416d0) * x) + y) * x) + z) / (((((263.505074721d0 * x) + ((43.3400022514d0 * (x * x)) + (x * (x * x)))) + 313.399215894d0) * x) + 47.066876606d0))
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = ((y / (x * x)) + (4.16438922228 * x)) - 110.1139242984811;
double tmp;
if (x < -3.326128725870005e+62) {
tmp = t_0;
} else if (x < 9.429991714554673e+55) {
tmp = ((x - 2.0) / 1.0) * (((((((((x * 4.16438922228) + 78.6994924154) * x) + 137.519416416) * x) + y) * x) + z) / (((((263.505074721 * x) + ((43.3400022514 * (x * x)) + (x * (x * x)))) + 313.399215894) * x) + 47.066876606));
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = ((y / (x * x)) + (4.16438922228 * x)) - 110.1139242984811 tmp = 0 if x < -3.326128725870005e+62: tmp = t_0 elif x < 9.429991714554673e+55: tmp = ((x - 2.0) / 1.0) * (((((((((x * 4.16438922228) + 78.6994924154) * x) + 137.519416416) * x) + y) * x) + z) / (((((263.505074721 * x) + ((43.3400022514 * (x * x)) + (x * (x * x)))) + 313.399215894) * x) + 47.066876606)) else: tmp = t_0 return tmp
function code(x, y, z) t_0 = Float64(Float64(Float64(y / Float64(x * x)) + Float64(4.16438922228 * x)) - 110.1139242984811) tmp = 0.0 if (x < -3.326128725870005e+62) tmp = t_0; elseif (x < 9.429991714554673e+55) tmp = Float64(Float64(Float64(x - 2.0) / 1.0) * Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 4.16438922228) + 78.6994924154) * x) + 137.519416416) * x) + y) * x) + z) / Float64(Float64(Float64(Float64(Float64(263.505074721 * x) + Float64(Float64(43.3400022514 * Float64(x * x)) + Float64(x * Float64(x * x)))) + 313.399215894) * x) + 47.066876606))); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y, z) t_0 = ((y / (x * x)) + (4.16438922228 * x)) - 110.1139242984811; tmp = 0.0; if (x < -3.326128725870005e+62) tmp = t_0; elseif (x < 9.429991714554673e+55) tmp = ((x - 2.0) / 1.0) * (((((((((x * 4.16438922228) + 78.6994924154) * x) + 137.519416416) * x) + y) * x) + z) / (((((263.505074721 * x) + ((43.3400022514 * (x * x)) + (x * (x * x)))) + 313.399215894) * x) + 47.066876606)); else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(N[(N[(y / N[(x * x), $MachinePrecision]), $MachinePrecision] + N[(4.16438922228 * x), $MachinePrecision]), $MachinePrecision] - 110.1139242984811), $MachinePrecision]}, If[Less[x, -3.326128725870005e+62], t$95$0, If[Less[x, 9.429991714554673e+55], N[(N[(N[(x - 2.0), $MachinePrecision] / 1.0), $MachinePrecision] * N[(N[(N[(N[(N[(N[(N[(N[(N[(x * 4.16438922228), $MachinePrecision] + 78.6994924154), $MachinePrecision] * x), $MachinePrecision] + 137.519416416), $MachinePrecision] * x), $MachinePrecision] + y), $MachinePrecision] * x), $MachinePrecision] + z), $MachinePrecision] / N[(N[(N[(N[(N[(263.505074721 * x), $MachinePrecision] + N[(N[(43.3400022514 * N[(x * x), $MachinePrecision]), $MachinePrecision] + N[(x * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + 313.399215894), $MachinePrecision] * x), $MachinePrecision] + 47.066876606), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$0]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \left(\frac{y}{x \cdot x} + 4.16438922228 \cdot x\right) - 110.1139242984811\\
\mathbf{if}\;x < -3.326128725870005 \cdot 10^{+62}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;x < 9.429991714554673 \cdot 10^{+55}:\\
\;\;\;\;\frac{x - 2}{1} \cdot \frac{\left(\left(\left(x \cdot 4.16438922228 + 78.6994924154\right) \cdot x + 137.519416416\right) \cdot x + y\right) \cdot x + z}{\left(\left(263.505074721 \cdot x + \left(43.3400022514 \cdot \left(x \cdot x\right) + x \cdot \left(x \cdot x\right)\right)\right) + 313.399215894\right) \cdot x + 47.066876606}\\
\mathbf{else}:\\
\;\;\;\;t_0\\
\end{array}
\end{array}
herbie shell --seed 2023181
(FPCore (x y z)
:name "Numeric.SpecFunctions:logGamma from math-functions-0.1.5.2, C"
:precision binary64
:herbie-target
(if (< x -3.326128725870005e+62) (- (+ (/ y (* x x)) (* 4.16438922228 x)) 110.1139242984811) (if (< x 9.429991714554673e+55) (* (/ (- x 2.0) 1.0) (/ (+ (* (+ (* (+ (* (+ (* x 4.16438922228) 78.6994924154) x) 137.519416416) x) y) x) z) (+ (* (+ (+ (* 263.505074721 x) (+ (* 43.3400022514 (* x x)) (* x (* x x)))) 313.399215894) x) 47.066876606))) (- (+ (/ y (* x x)) (* 4.16438922228 x)) 110.1139242984811)))
(/ (* (- x 2.0) (+ (* (+ (* (+ (* (+ (* x 4.16438922228) 78.6994924154) x) 137.519416416) x) y) x) z)) (+ (* (+ (* (+ (* (+ x 43.3400022514) x) 263.505074721) x) 313.399215894) x) 47.066876606)))