
(FPCore (x y) :precision binary64 (* (sin x) (/ (sinh y) y)))
double code(double x, double y) {
return sin(x) * (sinh(y) / y);
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = sin(x) * (sinh(y) / y)
end function
public static double code(double x, double y) {
return Math.sin(x) * (Math.sinh(y) / y);
}
def code(x, y): return math.sin(x) * (math.sinh(y) / y)
function code(x, y) return Float64(sin(x) * Float64(sinh(y) / y)) end
function tmp = code(x, y) tmp = sin(x) * (sinh(y) / y); end
code[x_, y_] := N[(N[Sin[x], $MachinePrecision] * N[(N[Sinh[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\sin x \cdot \frac{\sinh y}{y}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 20 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y) :precision binary64 (* (sin x) (/ (sinh y) y)))
double code(double x, double y) {
return sin(x) * (sinh(y) / y);
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = sin(x) * (sinh(y) / y)
end function
public static double code(double x, double y) {
return Math.sin(x) * (Math.sinh(y) / y);
}
def code(x, y): return math.sin(x) * (math.sinh(y) / y)
function code(x, y) return Float64(sin(x) * Float64(sinh(y) / y)) end
function tmp = code(x, y) tmp = sin(x) * (sinh(y) / y); end
code[x_, y_] := N[(N[Sin[x], $MachinePrecision] * N[(N[Sinh[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\sin x \cdot \frac{\sinh y}{y}
\end{array}
(FPCore (x y) :precision binary64 (* (sin x) (/ (sinh y) y)))
double code(double x, double y) {
return sin(x) * (sinh(y) / y);
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = sin(x) * (sinh(y) / y)
end function
public static double code(double x, double y) {
return Math.sin(x) * (Math.sinh(y) / y);
}
def code(x, y): return math.sin(x) * (math.sinh(y) / y)
function code(x, y) return Float64(sin(x) * Float64(sinh(y) / y)) end
function tmp = code(x, y) tmp = sin(x) * (sinh(y) / y); end
code[x_, y_] := N[(N[Sin[x], $MachinePrecision] * N[(N[Sinh[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\sin x \cdot \frac{\sinh y}{y}
\end{array}
Initial program 100.0%
(FPCore (x y)
:precision binary64
(let* ((t_0
(*
(sin x)
(+
1.0
(*
(* y y)
(+ 0.16666666666666666 (* (* y y) 0.008333333333333333)))))))
(if (<= y 0.24)
t_0
(if (<= y 5e+77)
(* (/ (sinh y) y) (* x (+ 1.0 (* (* x x) -0.16666666666666666))))
t_0))))
double code(double x, double y) {
double t_0 = sin(x) * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))));
double tmp;
if (y <= 0.24) {
tmp = t_0;
} else if (y <= 5e+77) {
tmp = (sinh(y) / y) * (x * (1.0 + ((x * x) * -0.16666666666666666)));
} else {
tmp = t_0;
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: t_0
real(8) :: tmp
t_0 = sin(x) * (1.0d0 + ((y * y) * (0.16666666666666666d0 + ((y * y) * 0.008333333333333333d0))))
if (y <= 0.24d0) then
tmp = t_0
else if (y <= 5d+77) then
tmp = (sinh(y) / y) * (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0))))
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = Math.sin(x) * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))));
double tmp;
if (y <= 0.24) {
tmp = t_0;
} else if (y <= 5e+77) {
tmp = (Math.sinh(y) / y) * (x * (1.0 + ((x * x) * -0.16666666666666666)));
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y): t_0 = math.sin(x) * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333)))) tmp = 0 if y <= 0.24: tmp = t_0 elif y <= 5e+77: tmp = (math.sinh(y) / y) * (x * (1.0 + ((x * x) * -0.16666666666666666))) else: tmp = t_0 return tmp
function code(x, y) t_0 = Float64(sin(x) * Float64(1.0 + Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(Float64(y * y) * 0.008333333333333333))))) tmp = 0.0 if (y <= 0.24) tmp = t_0; elseif (y <= 5e+77) tmp = Float64(Float64(sinh(y) / y) * Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666)))); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y) t_0 = sin(x) * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333)))); tmp = 0.0; if (y <= 0.24) tmp = t_0; elseif (y <= 5e+77) tmp = (sinh(y) / y) * (x * (1.0 + ((x * x) * -0.16666666666666666))); else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(N[Sin[x], $MachinePrecision] * N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, 0.24], t$95$0, If[LessEqual[y, 5e+77], N[(N[(N[Sinh[y], $MachinePrecision] / y), $MachinePrecision] * N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$0]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \sin x \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)\\
\mathbf{if}\;y \leq 0.24:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;y \leq 5 \cdot 10^{+77}:\\
\;\;\;\;\frac{\sinh y}{y} \cdot \left(x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if y < 0.23999999999999999 or 5.00000000000000004e77 < y Initial program 100.0%
Taylor expanded in y around 0
distribute-lft-inN/A
*-rgt-identityN/A
distribute-lft-inN/A
*-commutativeN/A
associate-*r*N/A
distribute-rgt-outN/A
+-commutativeN/A
associate-*l*N/A
*-commutativeN/A
distribute-lft-inN/A
*-lowering-*.f64N/A
sin-lowering-sin.f64N/A
+-lowering-+.f64N/A
Simplified96.1%
if 0.23999999999999999 < y < 5.00000000000000004e77Initial program 100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6481.8%
Simplified81.8%
Final simplification95.5%
(FPCore (x y) :precision binary64 (let* ((t_0 (* (sin x) (+ 1.0 (* y (* y 0.16666666666666666)))))) (if (<= y 0.215) t_0 (if (<= y 1.65e+154) (* x (/ (sinh y) y)) t_0))))
double code(double x, double y) {
double t_0 = sin(x) * (1.0 + (y * (y * 0.16666666666666666)));
double tmp;
if (y <= 0.215) {
tmp = t_0;
} else if (y <= 1.65e+154) {
tmp = x * (sinh(y) / y);
} else {
tmp = t_0;
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: t_0
real(8) :: tmp
t_0 = sin(x) * (1.0d0 + (y * (y * 0.16666666666666666d0)))
if (y <= 0.215d0) then
tmp = t_0
else if (y <= 1.65d+154) then
tmp = x * (sinh(y) / y)
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = Math.sin(x) * (1.0 + (y * (y * 0.16666666666666666)));
double tmp;
if (y <= 0.215) {
tmp = t_0;
} else if (y <= 1.65e+154) {
tmp = x * (Math.sinh(y) / y);
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y): t_0 = math.sin(x) * (1.0 + (y * (y * 0.16666666666666666))) tmp = 0 if y <= 0.215: tmp = t_0 elif y <= 1.65e+154: tmp = x * (math.sinh(y) / y) else: tmp = t_0 return tmp
function code(x, y) t_0 = Float64(sin(x) * Float64(1.0 + Float64(y * Float64(y * 0.16666666666666666)))) tmp = 0.0 if (y <= 0.215) tmp = t_0; elseif (y <= 1.65e+154) tmp = Float64(x * Float64(sinh(y) / y)); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y) t_0 = sin(x) * (1.0 + (y * (y * 0.16666666666666666))); tmp = 0.0; if (y <= 0.215) tmp = t_0; elseif (y <= 1.65e+154) tmp = x * (sinh(y) / y); else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(N[Sin[x], $MachinePrecision] * N[(1.0 + N[(y * N[(y * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, 0.215], t$95$0, If[LessEqual[y, 1.65e+154], N[(x * N[(N[Sinh[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], t$95$0]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \sin x \cdot \left(1 + y \cdot \left(y \cdot 0.16666666666666666\right)\right)\\
\mathbf{if}\;y \leq 0.215:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;y \leq 1.65 \cdot 10^{+154}:\\
\;\;\;\;x \cdot \frac{\sinh y}{y}\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if y < 0.214999999999999997 or 1.65e154 < y Initial program 100.0%
Taylor expanded in y around 0
*-lft-identityN/A
associate-*r*N/A
distribute-rgt-inN/A
*-lowering-*.f64N/A
sin-lowering-sin.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6490.4%
Simplified90.4%
if 0.214999999999999997 < y < 1.65e154Initial program 100.0%
Taylor expanded in x around 0
Simplified80.0%
(FPCore (x y)
:precision binary64
(if (<= y 0.00115)
(sin x)
(if (<= y 7.4e+220)
(* x (/ (sinh y) y))
(*
(* x (+ 1.0 (* (* x x) -0.16666666666666666)))
(* (* y y) 0.16666666666666666)))))
double code(double x, double y) {
double tmp;
if (y <= 0.00115) {
tmp = sin(x);
} else if (y <= 7.4e+220) {
tmp = x * (sinh(y) / y);
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= 0.00115d0) then
tmp = sin(x)
else if (y <= 7.4d+220) then
tmp = x * (sinh(y) / y)
else
tmp = (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))) * ((y * y) * 0.16666666666666666d0)
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= 0.00115) {
tmp = Math.sin(x);
} else if (y <= 7.4e+220) {
tmp = x * (Math.sinh(y) / y);
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666);
}
return tmp;
}
def code(x, y): tmp = 0 if y <= 0.00115: tmp = math.sin(x) elif y <= 7.4e+220: tmp = x * (math.sinh(y) / y) else: tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666) return tmp
function code(x, y) tmp = 0.0 if (y <= 0.00115) tmp = sin(x); elseif (y <= 7.4e+220) tmp = Float64(x * Float64(sinh(y) / y)); else tmp = Float64(Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) * Float64(Float64(y * y) * 0.16666666666666666)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= 0.00115) tmp = sin(x); elseif (y <= 7.4e+220) tmp = x * (sinh(y) / y); else tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, 0.00115], N[Sin[x], $MachinePrecision], If[LessEqual[y, 7.4e+220], N[(x * N[(N[Sinh[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(y * y), $MachinePrecision] * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq 0.00115:\\
\;\;\;\;\sin x\\
\mathbf{elif}\;y \leq 7.4 \cdot 10^{+220}:\\
\;\;\;\;x \cdot \frac{\sinh y}{y}\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\right) \cdot \left(\left(y \cdot y\right) \cdot 0.16666666666666666\right)\\
\end{array}
\end{array}
if y < 0.00115Initial program 100.0%
Taylor expanded in y around 0
sin-lowering-sin.f6469.6%
Simplified69.6%
if 0.00115 < y < 7.4e220Initial program 100.0%
Taylor expanded in x around 0
Simplified76.9%
if 7.4e220 < y Initial program 100.0%
Taylor expanded in y around 0
*-lft-identityN/A
associate-*r*N/A
distribute-rgt-inN/A
*-lowering-*.f64N/A
sin-lowering-sin.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Taylor expanded in y around inf
*-commutativeN/A
associate-*r*N/A
associate-*l*N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Final simplification71.9%
(FPCore (x y)
:precision binary64
(let* ((t_0 (+ 0.008333333333333333 (* (* y y) 0.0001984126984126984)))
(t_1 (* (* y y) t_0))
(t_2 (* x (+ 1.0 (* (* x x) -0.16666666666666666)))))
(if (<= y 0.0013)
(sin x)
(if (<= y 2.8e+39)
(*
t_2
(+
1.0
(/
(*
(* y y)
(+
0.004629629629629629
(* t_1 (* (* y (* y (* y y))) (* t_0 t_0)))))
(+ 0.027777777777777776 (* t_1 (- t_1 0.16666666666666666))))))
(if (<= y 4e+220)
(*
x
(/
(* y (+ 1.0 (* (* y y) (+ 0.16666666666666666 (* y (* y t_0))))))
y))
(* t_2 (* (* y y) 0.16666666666666666)))))))
double code(double x, double y) {
double t_0 = 0.008333333333333333 + ((y * y) * 0.0001984126984126984);
double t_1 = (y * y) * t_0;
double t_2 = x * (1.0 + ((x * x) * -0.16666666666666666));
double tmp;
if (y <= 0.0013) {
tmp = sin(x);
} else if (y <= 2.8e+39) {
tmp = t_2 * (1.0 + (((y * y) * (0.004629629629629629 + (t_1 * ((y * (y * (y * y))) * (t_0 * t_0))))) / (0.027777777777777776 + (t_1 * (t_1 - 0.16666666666666666)))));
} else if (y <= 4e+220) {
tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * t_0)))))) / y);
} else {
tmp = t_2 * ((y * y) * 0.16666666666666666);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_0 = 0.008333333333333333d0 + ((y * y) * 0.0001984126984126984d0)
t_1 = (y * y) * t_0
t_2 = x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))
if (y <= 0.0013d0) then
tmp = sin(x)
else if (y <= 2.8d+39) then
tmp = t_2 * (1.0d0 + (((y * y) * (0.004629629629629629d0 + (t_1 * ((y * (y * (y * y))) * (t_0 * t_0))))) / (0.027777777777777776d0 + (t_1 * (t_1 - 0.16666666666666666d0)))))
else if (y <= 4d+220) then
tmp = x * ((y * (1.0d0 + ((y * y) * (0.16666666666666666d0 + (y * (y * t_0)))))) / y)
else
tmp = t_2 * ((y * y) * 0.16666666666666666d0)
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = 0.008333333333333333 + ((y * y) * 0.0001984126984126984);
double t_1 = (y * y) * t_0;
double t_2 = x * (1.0 + ((x * x) * -0.16666666666666666));
double tmp;
if (y <= 0.0013) {
tmp = Math.sin(x);
} else if (y <= 2.8e+39) {
tmp = t_2 * (1.0 + (((y * y) * (0.004629629629629629 + (t_1 * ((y * (y * (y * y))) * (t_0 * t_0))))) / (0.027777777777777776 + (t_1 * (t_1 - 0.16666666666666666)))));
} else if (y <= 4e+220) {
tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * t_0)))))) / y);
} else {
tmp = t_2 * ((y * y) * 0.16666666666666666);
}
return tmp;
}
def code(x, y): t_0 = 0.008333333333333333 + ((y * y) * 0.0001984126984126984) t_1 = (y * y) * t_0 t_2 = x * (1.0 + ((x * x) * -0.16666666666666666)) tmp = 0 if y <= 0.0013: tmp = math.sin(x) elif y <= 2.8e+39: tmp = t_2 * (1.0 + (((y * y) * (0.004629629629629629 + (t_1 * ((y * (y * (y * y))) * (t_0 * t_0))))) / (0.027777777777777776 + (t_1 * (t_1 - 0.16666666666666666))))) elif y <= 4e+220: tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * t_0)))))) / y) else: tmp = t_2 * ((y * y) * 0.16666666666666666) return tmp
function code(x, y) t_0 = Float64(0.008333333333333333 + Float64(Float64(y * y) * 0.0001984126984126984)) t_1 = Float64(Float64(y * y) * t_0) t_2 = Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) tmp = 0.0 if (y <= 0.0013) tmp = sin(x); elseif (y <= 2.8e+39) tmp = Float64(t_2 * Float64(1.0 + Float64(Float64(Float64(y * y) * Float64(0.004629629629629629 + Float64(t_1 * Float64(Float64(y * Float64(y * Float64(y * y))) * Float64(t_0 * t_0))))) / Float64(0.027777777777777776 + Float64(t_1 * Float64(t_1 - 0.16666666666666666)))))); elseif (y <= 4e+220) tmp = Float64(x * Float64(Float64(y * Float64(1.0 + Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(y * Float64(y * t_0)))))) / y)); else tmp = Float64(t_2 * Float64(Float64(y * y) * 0.16666666666666666)); end return tmp end
function tmp_2 = code(x, y) t_0 = 0.008333333333333333 + ((y * y) * 0.0001984126984126984); t_1 = (y * y) * t_0; t_2 = x * (1.0 + ((x * x) * -0.16666666666666666)); tmp = 0.0; if (y <= 0.0013) tmp = sin(x); elseif (y <= 2.8e+39) tmp = t_2 * (1.0 + (((y * y) * (0.004629629629629629 + (t_1 * ((y * (y * (y * y))) * (t_0 * t_0))))) / (0.027777777777777776 + (t_1 * (t_1 - 0.16666666666666666))))); elseif (y <= 4e+220) tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * t_0)))))) / y); else tmp = t_2 * ((y * y) * 0.16666666666666666); end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(0.008333333333333333 + N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[(y * y), $MachinePrecision] * t$95$0), $MachinePrecision]}, Block[{t$95$2 = N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, 0.0013], N[Sin[x], $MachinePrecision], If[LessEqual[y, 2.8e+39], N[(t$95$2 * N[(1.0 + N[(N[(N[(y * y), $MachinePrecision] * N[(0.004629629629629629 + N[(t$95$1 * N[(N[(y * N[(y * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(t$95$0 * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(0.027777777777777776 + N[(t$95$1 * N[(t$95$1 - 0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 4e+220], N[(x * N[(N[(y * N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(y * N[(y * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(t$95$2 * N[(N[(y * y), $MachinePrecision] * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\\
t_1 := \left(y \cdot y\right) \cdot t\_0\\
t_2 := x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\\
\mathbf{if}\;y \leq 0.0013:\\
\;\;\;\;\sin x\\
\mathbf{elif}\;y \leq 2.8 \cdot 10^{+39}:\\
\;\;\;\;t\_2 \cdot \left(1 + \frac{\left(y \cdot y\right) \cdot \left(0.004629629629629629 + t\_1 \cdot \left(\left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right) \cdot \left(t\_0 \cdot t\_0\right)\right)\right)}{0.027777777777777776 + t\_1 \cdot \left(t\_1 - 0.16666666666666666\right)}\right)\\
\mathbf{elif}\;y \leq 4 \cdot 10^{+220}:\\
\;\;\;\;x \cdot \frac{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot t\_0\right)\right)\right)}{y}\\
\mathbf{else}:\\
\;\;\;\;t\_2 \cdot \left(\left(y \cdot y\right) \cdot 0.16666666666666666\right)\\
\end{array}
\end{array}
if y < 0.0012999999999999999Initial program 100.0%
Taylor expanded in y around 0
sin-lowering-sin.f6469.6%
Simplified69.6%
if 0.0012999999999999999 < y < 2.80000000000000001e39Initial program 100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in y around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f643.2%
Simplified3.2%
*-commutativeN/A
flip3-+N/A
associate-*l/N/A
/-lowering-/.f64N/A
Applied egg-rr61.5%
if 2.80000000000000001e39 < y < 4e220Initial program 100.0%
Taylor expanded in x around 0
Simplified76.5%
Taylor expanded in y around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6476.5%
Simplified76.5%
if 4e220 < y Initial program 100.0%
Taylor expanded in y around 0
*-lft-identityN/A
associate-*r*N/A
distribute-rgt-inN/A
*-lowering-*.f64N/A
sin-lowering-sin.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Taylor expanded in y around inf
*-commutativeN/A
associate-*r*N/A
associate-*l*N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Final simplification71.5%
(FPCore (x y)
:precision binary64
(let* ((t_0 (+ 0.008333333333333333 (* (* y y) 0.0001984126984126984)))
(t_1 (* (* y y) t_0))
(t_2 (* x (+ 1.0 (* (* x x) -0.16666666666666666)))))
(if (<= y 2.8e+39)
(*
t_2
(+
1.0
(/
(*
(* y y)
(+ 0.004629629629629629 (* t_1 (* (* y (* y (* y y))) (* t_0 t_0)))))
(+ 0.027777777777777776 (* t_1 (- t_1 0.16666666666666666))))))
(if (<= y 2.5e+220)
(*
x
(/
(* y (+ 1.0 (* (* y y) (+ 0.16666666666666666 (* y (* y t_0))))))
y))
(* t_2 (* (* y y) 0.16666666666666666))))))
double code(double x, double y) {
double t_0 = 0.008333333333333333 + ((y * y) * 0.0001984126984126984);
double t_1 = (y * y) * t_0;
double t_2 = x * (1.0 + ((x * x) * -0.16666666666666666));
double tmp;
if (y <= 2.8e+39) {
tmp = t_2 * (1.0 + (((y * y) * (0.004629629629629629 + (t_1 * ((y * (y * (y * y))) * (t_0 * t_0))))) / (0.027777777777777776 + (t_1 * (t_1 - 0.16666666666666666)))));
} else if (y <= 2.5e+220) {
tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * t_0)))))) / y);
} else {
tmp = t_2 * ((y * y) * 0.16666666666666666);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_0 = 0.008333333333333333d0 + ((y * y) * 0.0001984126984126984d0)
t_1 = (y * y) * t_0
t_2 = x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))
if (y <= 2.8d+39) then
tmp = t_2 * (1.0d0 + (((y * y) * (0.004629629629629629d0 + (t_1 * ((y * (y * (y * y))) * (t_0 * t_0))))) / (0.027777777777777776d0 + (t_1 * (t_1 - 0.16666666666666666d0)))))
else if (y <= 2.5d+220) then
tmp = x * ((y * (1.0d0 + ((y * y) * (0.16666666666666666d0 + (y * (y * t_0)))))) / y)
else
tmp = t_2 * ((y * y) * 0.16666666666666666d0)
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = 0.008333333333333333 + ((y * y) * 0.0001984126984126984);
double t_1 = (y * y) * t_0;
double t_2 = x * (1.0 + ((x * x) * -0.16666666666666666));
double tmp;
if (y <= 2.8e+39) {
tmp = t_2 * (1.0 + (((y * y) * (0.004629629629629629 + (t_1 * ((y * (y * (y * y))) * (t_0 * t_0))))) / (0.027777777777777776 + (t_1 * (t_1 - 0.16666666666666666)))));
} else if (y <= 2.5e+220) {
tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * t_0)))))) / y);
} else {
tmp = t_2 * ((y * y) * 0.16666666666666666);
}
return tmp;
}
def code(x, y): t_0 = 0.008333333333333333 + ((y * y) * 0.0001984126984126984) t_1 = (y * y) * t_0 t_2 = x * (1.0 + ((x * x) * -0.16666666666666666)) tmp = 0 if y <= 2.8e+39: tmp = t_2 * (1.0 + (((y * y) * (0.004629629629629629 + (t_1 * ((y * (y * (y * y))) * (t_0 * t_0))))) / (0.027777777777777776 + (t_1 * (t_1 - 0.16666666666666666))))) elif y <= 2.5e+220: tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * t_0)))))) / y) else: tmp = t_2 * ((y * y) * 0.16666666666666666) return tmp
function code(x, y) t_0 = Float64(0.008333333333333333 + Float64(Float64(y * y) * 0.0001984126984126984)) t_1 = Float64(Float64(y * y) * t_0) t_2 = Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) tmp = 0.0 if (y <= 2.8e+39) tmp = Float64(t_2 * Float64(1.0 + Float64(Float64(Float64(y * y) * Float64(0.004629629629629629 + Float64(t_1 * Float64(Float64(y * Float64(y * Float64(y * y))) * Float64(t_0 * t_0))))) / Float64(0.027777777777777776 + Float64(t_1 * Float64(t_1 - 0.16666666666666666)))))); elseif (y <= 2.5e+220) tmp = Float64(x * Float64(Float64(y * Float64(1.0 + Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(y * Float64(y * t_0)))))) / y)); else tmp = Float64(t_2 * Float64(Float64(y * y) * 0.16666666666666666)); end return tmp end
function tmp_2 = code(x, y) t_0 = 0.008333333333333333 + ((y * y) * 0.0001984126984126984); t_1 = (y * y) * t_0; t_2 = x * (1.0 + ((x * x) * -0.16666666666666666)); tmp = 0.0; if (y <= 2.8e+39) tmp = t_2 * (1.0 + (((y * y) * (0.004629629629629629 + (t_1 * ((y * (y * (y * y))) * (t_0 * t_0))))) / (0.027777777777777776 + (t_1 * (t_1 - 0.16666666666666666))))); elseif (y <= 2.5e+220) tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * t_0)))))) / y); else tmp = t_2 * ((y * y) * 0.16666666666666666); end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(0.008333333333333333 + N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[(y * y), $MachinePrecision] * t$95$0), $MachinePrecision]}, Block[{t$95$2 = N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, 2.8e+39], N[(t$95$2 * N[(1.0 + N[(N[(N[(y * y), $MachinePrecision] * N[(0.004629629629629629 + N[(t$95$1 * N[(N[(y * N[(y * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(t$95$0 * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(0.027777777777777776 + N[(t$95$1 * N[(t$95$1 - 0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.5e+220], N[(x * N[(N[(y * N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(y * N[(y * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(t$95$2 * N[(N[(y * y), $MachinePrecision] * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\\
t_1 := \left(y \cdot y\right) \cdot t\_0\\
t_2 := x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\\
\mathbf{if}\;y \leq 2.8 \cdot 10^{+39}:\\
\;\;\;\;t\_2 \cdot \left(1 + \frac{\left(y \cdot y\right) \cdot \left(0.004629629629629629 + t\_1 \cdot \left(\left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right) \cdot \left(t\_0 \cdot t\_0\right)\right)\right)}{0.027777777777777776 + t\_1 \cdot \left(t\_1 - 0.16666666666666666\right)}\right)\\
\mathbf{elif}\;y \leq 2.5 \cdot 10^{+220}:\\
\;\;\;\;x \cdot \frac{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot t\_0\right)\right)\right)}{y}\\
\mathbf{else}:\\
\;\;\;\;t\_2 \cdot \left(\left(y \cdot y\right) \cdot 0.16666666666666666\right)\\
\end{array}
\end{array}
if y < 2.80000000000000001e39Initial program 100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6461.8%
Simplified61.8%
Taylor expanded in y around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6457.7%
Simplified57.7%
*-commutativeN/A
flip3-+N/A
associate-*l/N/A
/-lowering-/.f64N/A
Applied egg-rr40.5%
if 2.80000000000000001e39 < y < 2.5000000000000001e220Initial program 100.0%
Taylor expanded in x around 0
Simplified76.5%
Taylor expanded in y around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6476.5%
Simplified76.5%
if 2.5000000000000001e220 < y Initial program 100.0%
Taylor expanded in y around 0
*-lft-identityN/A
associate-*r*N/A
distribute-rgt-inN/A
*-lowering-*.f64N/A
sin-lowering-sin.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Taylor expanded in y around inf
*-commutativeN/A
associate-*r*N/A
associate-*l*N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Final simplification48.2%
(FPCore (x y)
:precision binary64
(let* ((t_0 (+ 0.008333333333333333 (* (* y y) 0.0001984126984126984)))
(t_1 (+ 0.16666666666666666 (* (* y y) t_0))))
(if (<= y 5e+45)
(/
(*
(- 1.0 (* (* y (* y (* y y))) (* t_1 t_1)))
(* x (+ 1.0 (* x (* x -0.16666666666666666)))))
(- 1.0 (* y (* y t_1))))
(if (<= y 4.2e+220)
(*
x
(/
(* y (+ 1.0 (* (* y y) (+ 0.16666666666666666 (* y (* y t_0))))))
y))
(*
(* x (+ 1.0 (* (* x x) -0.16666666666666666)))
(* (* y y) 0.16666666666666666))))))
double code(double x, double y) {
double t_0 = 0.008333333333333333 + ((y * y) * 0.0001984126984126984);
double t_1 = 0.16666666666666666 + ((y * y) * t_0);
double tmp;
if (y <= 5e+45) {
tmp = ((1.0 - ((y * (y * (y * y))) * (t_1 * t_1))) * (x * (1.0 + (x * (x * -0.16666666666666666))))) / (1.0 - (y * (y * t_1)));
} else if (y <= 4.2e+220) {
tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * t_0)))))) / y);
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = 0.008333333333333333d0 + ((y * y) * 0.0001984126984126984d0)
t_1 = 0.16666666666666666d0 + ((y * y) * t_0)
if (y <= 5d+45) then
tmp = ((1.0d0 - ((y * (y * (y * y))) * (t_1 * t_1))) * (x * (1.0d0 + (x * (x * (-0.16666666666666666d0)))))) / (1.0d0 - (y * (y * t_1)))
else if (y <= 4.2d+220) then
tmp = x * ((y * (1.0d0 + ((y * y) * (0.16666666666666666d0 + (y * (y * t_0)))))) / y)
else
tmp = (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))) * ((y * y) * 0.16666666666666666d0)
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = 0.008333333333333333 + ((y * y) * 0.0001984126984126984);
double t_1 = 0.16666666666666666 + ((y * y) * t_0);
double tmp;
if (y <= 5e+45) {
tmp = ((1.0 - ((y * (y * (y * y))) * (t_1 * t_1))) * (x * (1.0 + (x * (x * -0.16666666666666666))))) / (1.0 - (y * (y * t_1)));
} else if (y <= 4.2e+220) {
tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * t_0)))))) / y);
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666);
}
return tmp;
}
def code(x, y): t_0 = 0.008333333333333333 + ((y * y) * 0.0001984126984126984) t_1 = 0.16666666666666666 + ((y * y) * t_0) tmp = 0 if y <= 5e+45: tmp = ((1.0 - ((y * (y * (y * y))) * (t_1 * t_1))) * (x * (1.0 + (x * (x * -0.16666666666666666))))) / (1.0 - (y * (y * t_1))) elif y <= 4.2e+220: tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * t_0)))))) / y) else: tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666) return tmp
function code(x, y) t_0 = Float64(0.008333333333333333 + Float64(Float64(y * y) * 0.0001984126984126984)) t_1 = Float64(0.16666666666666666 + Float64(Float64(y * y) * t_0)) tmp = 0.0 if (y <= 5e+45) tmp = Float64(Float64(Float64(1.0 - Float64(Float64(y * Float64(y * Float64(y * y))) * Float64(t_1 * t_1))) * Float64(x * Float64(1.0 + Float64(x * Float64(x * -0.16666666666666666))))) / Float64(1.0 - Float64(y * Float64(y * t_1)))); elseif (y <= 4.2e+220) tmp = Float64(x * Float64(Float64(y * Float64(1.0 + Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(y * Float64(y * t_0)))))) / y)); else tmp = Float64(Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) * Float64(Float64(y * y) * 0.16666666666666666)); end return tmp end
function tmp_2 = code(x, y) t_0 = 0.008333333333333333 + ((y * y) * 0.0001984126984126984); t_1 = 0.16666666666666666 + ((y * y) * t_0); tmp = 0.0; if (y <= 5e+45) tmp = ((1.0 - ((y * (y * (y * y))) * (t_1 * t_1))) * (x * (1.0 + (x * (x * -0.16666666666666666))))) / (1.0 - (y * (y * t_1))); elseif (y <= 4.2e+220) tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * t_0)))))) / y); else tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666); end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(0.008333333333333333 + N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * t$95$0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, 5e+45], N[(N[(N[(1.0 - N[(N[(y * N[(y * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(t$95$1 * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(x * N[(1.0 + N[(x * N[(x * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(1.0 - N[(y * N[(y * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 4.2e+220], N[(x * N[(N[(y * N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(y * N[(y * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(y * y), $MachinePrecision] * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\\
t_1 := 0.16666666666666666 + \left(y \cdot y\right) \cdot t\_0\\
\mathbf{if}\;y \leq 5 \cdot 10^{+45}:\\
\;\;\;\;\frac{\left(1 - \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right) \cdot \left(t\_1 \cdot t\_1\right)\right) \cdot \left(x \cdot \left(1 + x \cdot \left(x \cdot -0.16666666666666666\right)\right)\right)}{1 - y \cdot \left(y \cdot t\_1\right)}\\
\mathbf{elif}\;y \leq 4.2 \cdot 10^{+220}:\\
\;\;\;\;x \cdot \frac{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot t\_0\right)\right)\right)}{y}\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\right) \cdot \left(\left(y \cdot y\right) \cdot 0.16666666666666666\right)\\
\end{array}
\end{array}
if y < 5e45Initial program 100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6461.8%
Simplified61.8%
Taylor expanded in y around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6457.7%
Simplified57.7%
*-commutativeN/A
flip-+N/A
associate-*l/N/A
/-lowering-/.f64N/A
Applied egg-rr40.5%
if 5e45 < y < 4.20000000000000014e220Initial program 100.0%
Taylor expanded in x around 0
Simplified76.5%
Taylor expanded in y around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6476.5%
Simplified76.5%
if 4.20000000000000014e220 < y Initial program 100.0%
Taylor expanded in y around 0
*-lft-identityN/A
associate-*r*N/A
distribute-rgt-inN/A
*-lowering-*.f64N/A
sin-lowering-sin.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Taylor expanded in y around inf
*-commutativeN/A
associate-*r*N/A
associate-*l*N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Final simplification48.2%
(FPCore (x y)
:precision binary64
(let* ((t_0 (* x (+ 1.0 (* (* x x) -0.16666666666666666))))
(t_1 (* (* y y) 0.0001984126984126984))
(t_2 (+ 0.008333333333333333 t_1)))
(if (<= y 6.2e+61)
(*
t_0
(+
1.0
(/
(*
(* y y)
(- 0.027777777777777776 (* (* y (* y (* y y))) (* t_2 t_2))))
(- 0.16666666666666666 (* (* y y) t_2)))))
(if (<= y 4.5e+220)
(+ x (* (* y y) (* (* y y) (* x t_1))))
(* t_0 (* (* y y) 0.16666666666666666))))))
double code(double x, double y) {
double t_0 = x * (1.0 + ((x * x) * -0.16666666666666666));
double t_1 = (y * y) * 0.0001984126984126984;
double t_2 = 0.008333333333333333 + t_1;
double tmp;
if (y <= 6.2e+61) {
tmp = t_0 * (1.0 + (((y * y) * (0.027777777777777776 - ((y * (y * (y * y))) * (t_2 * t_2)))) / (0.16666666666666666 - ((y * y) * t_2))));
} else if (y <= 4.5e+220) {
tmp = x + ((y * y) * ((y * y) * (x * t_1)));
} else {
tmp = t_0 * ((y * y) * 0.16666666666666666);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_0 = x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))
t_1 = (y * y) * 0.0001984126984126984d0
t_2 = 0.008333333333333333d0 + t_1
if (y <= 6.2d+61) then
tmp = t_0 * (1.0d0 + (((y * y) * (0.027777777777777776d0 - ((y * (y * (y * y))) * (t_2 * t_2)))) / (0.16666666666666666d0 - ((y * y) * t_2))))
else if (y <= 4.5d+220) then
tmp = x + ((y * y) * ((y * y) * (x * t_1)))
else
tmp = t_0 * ((y * y) * 0.16666666666666666d0)
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = x * (1.0 + ((x * x) * -0.16666666666666666));
double t_1 = (y * y) * 0.0001984126984126984;
double t_2 = 0.008333333333333333 + t_1;
double tmp;
if (y <= 6.2e+61) {
tmp = t_0 * (1.0 + (((y * y) * (0.027777777777777776 - ((y * (y * (y * y))) * (t_2 * t_2)))) / (0.16666666666666666 - ((y * y) * t_2))));
} else if (y <= 4.5e+220) {
tmp = x + ((y * y) * ((y * y) * (x * t_1)));
} else {
tmp = t_0 * ((y * y) * 0.16666666666666666);
}
return tmp;
}
def code(x, y): t_0 = x * (1.0 + ((x * x) * -0.16666666666666666)) t_1 = (y * y) * 0.0001984126984126984 t_2 = 0.008333333333333333 + t_1 tmp = 0 if y <= 6.2e+61: tmp = t_0 * (1.0 + (((y * y) * (0.027777777777777776 - ((y * (y * (y * y))) * (t_2 * t_2)))) / (0.16666666666666666 - ((y * y) * t_2)))) elif y <= 4.5e+220: tmp = x + ((y * y) * ((y * y) * (x * t_1))) else: tmp = t_0 * ((y * y) * 0.16666666666666666) return tmp
function code(x, y) t_0 = Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) t_1 = Float64(Float64(y * y) * 0.0001984126984126984) t_2 = Float64(0.008333333333333333 + t_1) tmp = 0.0 if (y <= 6.2e+61) tmp = Float64(t_0 * Float64(1.0 + Float64(Float64(Float64(y * y) * Float64(0.027777777777777776 - Float64(Float64(y * Float64(y * Float64(y * y))) * Float64(t_2 * t_2)))) / Float64(0.16666666666666666 - Float64(Float64(y * y) * t_2))))); elseif (y <= 4.5e+220) tmp = Float64(x + Float64(Float64(y * y) * Float64(Float64(y * y) * Float64(x * t_1)))); else tmp = Float64(t_0 * Float64(Float64(y * y) * 0.16666666666666666)); end return tmp end
function tmp_2 = code(x, y) t_0 = x * (1.0 + ((x * x) * -0.16666666666666666)); t_1 = (y * y) * 0.0001984126984126984; t_2 = 0.008333333333333333 + t_1; tmp = 0.0; if (y <= 6.2e+61) tmp = t_0 * (1.0 + (((y * y) * (0.027777777777777776 - ((y * (y * (y * y))) * (t_2 * t_2)))) / (0.16666666666666666 - ((y * y) * t_2)))); elseif (y <= 4.5e+220) tmp = x + ((y * y) * ((y * y) * (x * t_1))); else tmp = t_0 * ((y * y) * 0.16666666666666666); end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision]}, Block[{t$95$2 = N[(0.008333333333333333 + t$95$1), $MachinePrecision]}, If[LessEqual[y, 6.2e+61], N[(t$95$0 * N[(1.0 + N[(N[(N[(y * y), $MachinePrecision] * N[(0.027777777777777776 - N[(N[(y * N[(y * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(t$95$2 * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(0.16666666666666666 - N[(N[(y * y), $MachinePrecision] * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 4.5e+220], N[(x + N[(N[(y * y), $MachinePrecision] * N[(N[(y * y), $MachinePrecision] * N[(x * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t$95$0 * N[(N[(y * y), $MachinePrecision] * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\\
t_1 := \left(y \cdot y\right) \cdot 0.0001984126984126984\\
t_2 := 0.008333333333333333 + t\_1\\
\mathbf{if}\;y \leq 6.2 \cdot 10^{+61}:\\
\;\;\;\;t\_0 \cdot \left(1 + \frac{\left(y \cdot y\right) \cdot \left(0.027777777777777776 - \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right) \cdot \left(t\_2 \cdot t\_2\right)\right)}{0.16666666666666666 - \left(y \cdot y\right) \cdot t\_2}\right)\\
\mathbf{elif}\;y \leq 4.5 \cdot 10^{+220}:\\
\;\;\;\;x + \left(y \cdot y\right) \cdot \left(\left(y \cdot y\right) \cdot \left(x \cdot t\_1\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_0 \cdot \left(\left(y \cdot y\right) \cdot 0.16666666666666666\right)\\
\end{array}
\end{array}
if y < 6.1999999999999998e61Initial program 100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6461.9%
Simplified61.9%
Taylor expanded in y around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6457.8%
Simplified57.8%
*-commutativeN/A
flip-+N/A
associate-*l/N/A
/-lowering-/.f64N/A
Applied egg-rr41.4%
if 6.1999999999999998e61 < y < 4.50000000000000011e220Initial program 100.0%
Taylor expanded in x around 0
Simplified74.2%
Taylor expanded in y around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*r*N/A
distribute-rgt-outN/A
+-commutativeN/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6474.2%
Simplified74.2%
Taylor expanded in y around inf
associate-*r*N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6474.2%
Simplified74.2%
if 4.50000000000000011e220 < y Initial program 100.0%
Taylor expanded in y around 0
*-lft-identityN/A
associate-*r*N/A
distribute-rgt-inN/A
*-lowering-*.f64N/A
sin-lowering-sin.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Taylor expanded in y around inf
*-commutativeN/A
associate-*r*N/A
associate-*l*N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Final simplification48.3%
(FPCore (x y)
:precision binary64
(let* ((t_0 (* (* y y) 0.0001984126984126984)))
(if (<= x 6.2e+52)
(*
(* x (+ 1.0 (* (* x x) -0.16666666666666666)))
(+
1.0
(*
(* y y)
(+ 0.16666666666666666 (* y (* y (+ 0.008333333333333333 t_0)))))))
(+ x (* (* y y) (* (* y y) (* x t_0)))))))
double code(double x, double y) {
double t_0 = (y * y) * 0.0001984126984126984;
double tmp;
if (x <= 6.2e+52) {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (0.008333333333333333 + t_0))))));
} else {
tmp = x + ((y * y) * ((y * y) * (x * t_0)));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: t_0
real(8) :: tmp
t_0 = (y * y) * 0.0001984126984126984d0
if (x <= 6.2d+52) then
tmp = (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))) * (1.0d0 + ((y * y) * (0.16666666666666666d0 + (y * (y * (0.008333333333333333d0 + t_0))))))
else
tmp = x + ((y * y) * ((y * y) * (x * t_0)))
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = (y * y) * 0.0001984126984126984;
double tmp;
if (x <= 6.2e+52) {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (0.008333333333333333 + t_0))))));
} else {
tmp = x + ((y * y) * ((y * y) * (x * t_0)));
}
return tmp;
}
def code(x, y): t_0 = (y * y) * 0.0001984126984126984 tmp = 0 if x <= 6.2e+52: tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (0.008333333333333333 + t_0)))))) else: tmp = x + ((y * y) * ((y * y) * (x * t_0))) return tmp
function code(x, y) t_0 = Float64(Float64(y * y) * 0.0001984126984126984) tmp = 0.0 if (x <= 6.2e+52) tmp = Float64(Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) * Float64(1.0 + Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(y * Float64(y * Float64(0.008333333333333333 + t_0))))))); else tmp = Float64(x + Float64(Float64(y * y) * Float64(Float64(y * y) * Float64(x * t_0)))); end return tmp end
function tmp_2 = code(x, y) t_0 = (y * y) * 0.0001984126984126984; tmp = 0.0; if (x <= 6.2e+52) tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (0.008333333333333333 + t_0)))))); else tmp = x + ((y * y) * ((y * y) * (x * t_0))); end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision]}, If[LessEqual[x, 6.2e+52], N[(N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(y * N[(y * N[(0.008333333333333333 + t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(y * y), $MachinePrecision] * N[(N[(y * y), $MachinePrecision] * N[(x * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \left(y \cdot y\right) \cdot 0.0001984126984126984\\
\mathbf{if}\;x \leq 6.2 \cdot 10^{+52}:\\
\;\;\;\;\left(x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\right) \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(0.008333333333333333 + t\_0\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x + \left(y \cdot y\right) \cdot \left(\left(y \cdot y\right) \cdot \left(x \cdot t\_0\right)\right)\\
\end{array}
\end{array}
if x < 6.2e52Initial program 100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6475.9%
Simplified75.9%
Taylor expanded in y around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6471.7%
Simplified71.7%
if 6.2e52 < x Initial program 100.0%
Taylor expanded in x around 0
Simplified26.7%
Taylor expanded in y around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*r*N/A
distribute-rgt-outN/A
+-commutativeN/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6425.0%
Simplified25.0%
Taylor expanded in y around inf
associate-*r*N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6425.0%
Simplified25.0%
(FPCore (x y)
:precision binary64
(if (<= y 5e+220)
(*
x
(/
(*
y
(+
1.0
(*
(* y y)
(+
0.16666666666666666
(*
y
(* y (+ 0.008333333333333333 (* (* y y) 0.0001984126984126984))))))))
y))
(*
(* x (+ 1.0 (* (* x x) -0.16666666666666666)))
(* (* y y) 0.16666666666666666))))
double code(double x, double y) {
double tmp;
if (y <= 5e+220) {
tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (0.008333333333333333 + ((y * y) * 0.0001984126984126984)))))))) / y);
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= 5d+220) then
tmp = x * ((y * (1.0d0 + ((y * y) * (0.16666666666666666d0 + (y * (y * (0.008333333333333333d0 + ((y * y) * 0.0001984126984126984d0)))))))) / y)
else
tmp = (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))) * ((y * y) * 0.16666666666666666d0)
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= 5e+220) {
tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (0.008333333333333333 + ((y * y) * 0.0001984126984126984)))))))) / y);
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666);
}
return tmp;
}
def code(x, y): tmp = 0 if y <= 5e+220: tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (0.008333333333333333 + ((y * y) * 0.0001984126984126984)))))))) / y) else: tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666) return tmp
function code(x, y) tmp = 0.0 if (y <= 5e+220) tmp = Float64(x * Float64(Float64(y * Float64(1.0 + Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(y * Float64(y * Float64(0.008333333333333333 + Float64(Float64(y * y) * 0.0001984126984126984)))))))) / y)); else tmp = Float64(Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) * Float64(Float64(y * y) * 0.16666666666666666)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= 5e+220) tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (0.008333333333333333 + ((y * y) * 0.0001984126984126984)))))))) / y); else tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, 5e+220], N[(x * N[(N[(y * N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(y * N[(y * N[(0.008333333333333333 + N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(y * y), $MachinePrecision] * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq 5 \cdot 10^{+220}:\\
\;\;\;\;x \cdot \frac{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)}{y}\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\right) \cdot \left(\left(y \cdot y\right) \cdot 0.16666666666666666\right)\\
\end{array}
\end{array}
if y < 5.0000000000000002e220Initial program 100.0%
Taylor expanded in x around 0
Simplified63.8%
Taylor expanded in y around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6461.0%
Simplified61.0%
if 5.0000000000000002e220 < y Initial program 100.0%
Taylor expanded in y around 0
*-lft-identityN/A
associate-*r*N/A
distribute-rgt-inN/A
*-lowering-*.f64N/A
sin-lowering-sin.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Taylor expanded in y around inf
*-commutativeN/A
associate-*r*N/A
associate-*l*N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Final simplification62.7%
(FPCore (x y)
:precision binary64
(if (<= y 2.7e+220)
(*
x
(+
1.0
(*
y
(*
y
(+
0.16666666666666666
(*
y
(* y (+ 0.008333333333333333 (* (* y y) 0.0001984126984126984)))))))))
(*
(* x (+ 1.0 (* (* x x) -0.16666666666666666)))
(* (* y y) 0.16666666666666666))))
double code(double x, double y) {
double tmp;
if (y <= 2.7e+220) {
tmp = x * (1.0 + (y * (y * (0.16666666666666666 + (y * (y * (0.008333333333333333 + ((y * y) * 0.0001984126984126984))))))));
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= 2.7d+220) then
tmp = x * (1.0d0 + (y * (y * (0.16666666666666666d0 + (y * (y * (0.008333333333333333d0 + ((y * y) * 0.0001984126984126984d0))))))))
else
tmp = (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))) * ((y * y) * 0.16666666666666666d0)
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= 2.7e+220) {
tmp = x * (1.0 + (y * (y * (0.16666666666666666 + (y * (y * (0.008333333333333333 + ((y * y) * 0.0001984126984126984))))))));
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666);
}
return tmp;
}
def code(x, y): tmp = 0 if y <= 2.7e+220: tmp = x * (1.0 + (y * (y * (0.16666666666666666 + (y * (y * (0.008333333333333333 + ((y * y) * 0.0001984126984126984)))))))) else: tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666) return tmp
function code(x, y) tmp = 0.0 if (y <= 2.7e+220) tmp = Float64(x * Float64(1.0 + Float64(y * Float64(y * Float64(0.16666666666666666 + Float64(y * Float64(y * Float64(0.008333333333333333 + Float64(Float64(y * y) * 0.0001984126984126984))))))))); else tmp = Float64(Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) * Float64(Float64(y * y) * 0.16666666666666666)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= 2.7e+220) tmp = x * (1.0 + (y * (y * (0.16666666666666666 + (y * (y * (0.008333333333333333 + ((y * y) * 0.0001984126984126984)))))))); else tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, 2.7e+220], N[(x * N[(1.0 + N[(y * N[(y * N[(0.16666666666666666 + N[(y * N[(y * N[(0.008333333333333333 + N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(y * y), $MachinePrecision] * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq 2.7 \cdot 10^{+220}:\\
\;\;\;\;x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\right) \cdot \left(\left(y \cdot y\right) \cdot 0.16666666666666666\right)\\
\end{array}
\end{array}
if y < 2.6999999999999998e220Initial program 100.0%
Taylor expanded in x around 0
Simplified63.8%
Taylor expanded in y around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*r*N/A
distribute-rgt-outN/A
+-commutativeN/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6459.9%
Simplified59.9%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6460.7%
Simplified60.7%
if 2.6999999999999998e220 < y Initial program 100.0%
Taylor expanded in y around 0
*-lft-identityN/A
associate-*r*N/A
distribute-rgt-inN/A
*-lowering-*.f64N/A
sin-lowering-sin.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Taylor expanded in y around inf
*-commutativeN/A
associate-*r*N/A
associate-*l*N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Final simplification62.3%
(FPCore (x y)
:precision binary64
(if (<= y 2.5e+220)
(*
x
(/
(*
y
(+
1.0
(* (* y y) (+ 0.16666666666666666 (* (* y y) 0.008333333333333333)))))
y))
(*
(* x (+ 1.0 (* (* x x) -0.16666666666666666)))
(* (* y y) 0.16666666666666666))))
double code(double x, double y) {
double tmp;
if (y <= 2.5e+220) {
tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))))) / y);
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= 2.5d+220) then
tmp = x * ((y * (1.0d0 + ((y * y) * (0.16666666666666666d0 + ((y * y) * 0.008333333333333333d0))))) / y)
else
tmp = (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))) * ((y * y) * 0.16666666666666666d0)
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= 2.5e+220) {
tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))))) / y);
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666);
}
return tmp;
}
def code(x, y): tmp = 0 if y <= 2.5e+220: tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))))) / y) else: tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666) return tmp
function code(x, y) tmp = 0.0 if (y <= 2.5e+220) tmp = Float64(x * Float64(Float64(y * Float64(1.0 + Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(Float64(y * y) * 0.008333333333333333))))) / y)); else tmp = Float64(Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) * Float64(Float64(y * y) * 0.16666666666666666)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= 2.5e+220) tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))))) / y); else tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, 2.5e+220], N[(x * N[(N[(y * N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(y * y), $MachinePrecision] * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq 2.5 \cdot 10^{+220}:\\
\;\;\;\;x \cdot \frac{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)}{y}\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\right) \cdot \left(\left(y \cdot y\right) \cdot 0.16666666666666666\right)\\
\end{array}
\end{array}
if y < 2.5000000000000001e220Initial program 100.0%
Taylor expanded in x around 0
Simplified63.8%
Taylor expanded in y around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6459.8%
Simplified59.8%
if 2.5000000000000001e220 < y Initial program 100.0%
Taylor expanded in y around 0
*-lft-identityN/A
associate-*r*N/A
distribute-rgt-inN/A
*-lowering-*.f64N/A
sin-lowering-sin.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Taylor expanded in y around inf
*-commutativeN/A
associate-*r*N/A
associate-*l*N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Final simplification61.6%
(FPCore (x y)
:precision binary64
(if (<= y 2.2e+220)
(+ x (* (* y y) (* (* y y) (* x (* (* y y) 0.0001984126984126984)))))
(*
(* x (+ 1.0 (* (* x x) -0.16666666666666666)))
(* (* y y) 0.16666666666666666))))
double code(double x, double y) {
double tmp;
if (y <= 2.2e+220) {
tmp = x + ((y * y) * ((y * y) * (x * ((y * y) * 0.0001984126984126984))));
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= 2.2d+220) then
tmp = x + ((y * y) * ((y * y) * (x * ((y * y) * 0.0001984126984126984d0))))
else
tmp = (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))) * ((y * y) * 0.16666666666666666d0)
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= 2.2e+220) {
tmp = x + ((y * y) * ((y * y) * (x * ((y * y) * 0.0001984126984126984))));
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666);
}
return tmp;
}
def code(x, y): tmp = 0 if y <= 2.2e+220: tmp = x + ((y * y) * ((y * y) * (x * ((y * y) * 0.0001984126984126984)))) else: tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666) return tmp
function code(x, y) tmp = 0.0 if (y <= 2.2e+220) tmp = Float64(x + Float64(Float64(y * y) * Float64(Float64(y * y) * Float64(x * Float64(Float64(y * y) * 0.0001984126984126984))))); else tmp = Float64(Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) * Float64(Float64(y * y) * 0.16666666666666666)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= 2.2e+220) tmp = x + ((y * y) * ((y * y) * (x * ((y * y) * 0.0001984126984126984)))); else tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, 2.2e+220], N[(x + N[(N[(y * y), $MachinePrecision] * N[(N[(y * y), $MachinePrecision] * N[(x * N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(y * y), $MachinePrecision] * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq 2.2 \cdot 10^{+220}:\\
\;\;\;\;x + \left(y \cdot y\right) \cdot \left(\left(y \cdot y\right) \cdot \left(x \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\right) \cdot \left(\left(y \cdot y\right) \cdot 0.16666666666666666\right)\\
\end{array}
\end{array}
if y < 2.19999999999999989e220Initial program 100.0%
Taylor expanded in x around 0
Simplified63.8%
Taylor expanded in y around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*r*N/A
distribute-rgt-outN/A
+-commutativeN/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6459.9%
Simplified59.9%
Taylor expanded in y around inf
associate-*r*N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6459.7%
Simplified59.7%
if 2.19999999999999989e220 < y Initial program 100.0%
Taylor expanded in y around 0
*-lft-identityN/A
associate-*r*N/A
distribute-rgt-inN/A
*-lowering-*.f64N/A
sin-lowering-sin.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Taylor expanded in y around inf
*-commutativeN/A
associate-*r*N/A
associate-*l*N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Final simplification61.4%
(FPCore (x y)
:precision binary64
(if (<= y 4e+220)
(*
x
(+
1.0
(* (* y y) (+ 0.16666666666666666 (* (* y y) 0.008333333333333333)))))
(*
(* x (+ 1.0 (* (* x x) -0.16666666666666666)))
(* (* y y) 0.16666666666666666))))
double code(double x, double y) {
double tmp;
if (y <= 4e+220) {
tmp = x * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))));
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= 4d+220) then
tmp = x * (1.0d0 + ((y * y) * (0.16666666666666666d0 + ((y * y) * 0.008333333333333333d0))))
else
tmp = (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))) * ((y * y) * 0.16666666666666666d0)
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= 4e+220) {
tmp = x * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))));
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666);
}
return tmp;
}
def code(x, y): tmp = 0 if y <= 4e+220: tmp = x * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333)))) else: tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666) return tmp
function code(x, y) tmp = 0.0 if (y <= 4e+220) tmp = Float64(x * Float64(1.0 + Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(Float64(y * y) * 0.008333333333333333))))); else tmp = Float64(Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) * Float64(Float64(y * y) * 0.16666666666666666)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= 4e+220) tmp = x * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333)))); else tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * y) * 0.16666666666666666); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, 4e+220], N[(x * N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(y * y), $MachinePrecision] * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq 4 \cdot 10^{+220}:\\
\;\;\;\;x \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\right) \cdot \left(\left(y \cdot y\right) \cdot 0.16666666666666666\right)\\
\end{array}
\end{array}
if y < 4e220Initial program 100.0%
Taylor expanded in y around 0
distribute-lft-inN/A
*-rgt-identityN/A
distribute-lft-inN/A
*-commutativeN/A
associate-*r*N/A
distribute-rgt-outN/A
+-commutativeN/A
associate-*l*N/A
*-commutativeN/A
distribute-lft-inN/A
*-lowering-*.f64N/A
sin-lowering-sin.f64N/A
+-lowering-+.f64N/A
Simplified91.7%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6459.5%
Simplified59.5%
if 4e220 < y Initial program 100.0%
Taylor expanded in y around 0
*-lft-identityN/A
associate-*r*N/A
distribute-rgt-inN/A
*-lowering-*.f64N/A
sin-lowering-sin.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Taylor expanded in y around inf
*-commutativeN/A
associate-*r*N/A
associate-*l*N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.5%
Simplified87.5%
Final simplification61.2%
(FPCore (x y) :precision binary64 (* x (+ 1.0 (* (* y y) (+ 0.16666666666666666 (* (* y y) 0.008333333333333333))))))
double code(double x, double y) {
return x * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))));
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = x * (1.0d0 + ((y * y) * (0.16666666666666666d0 + ((y * y) * 0.008333333333333333d0))))
end function
public static double code(double x, double y) {
return x * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))));
}
def code(x, y): return x * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))))
function code(x, y) return Float64(x * Float64(1.0 + Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(Float64(y * y) * 0.008333333333333333))))) end
function tmp = code(x, y) tmp = x * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333)))); end
code[x_, y_] := N[(x * N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)
\end{array}
Initial program 100.0%
Taylor expanded in y around 0
distribute-lft-inN/A
*-rgt-identityN/A
distribute-lft-inN/A
*-commutativeN/A
associate-*r*N/A
distribute-rgt-outN/A
+-commutativeN/A
associate-*l*N/A
*-commutativeN/A
distribute-lft-inN/A
*-lowering-*.f64N/A
sin-lowering-sin.f64N/A
+-lowering-+.f64N/A
Simplified92.2%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6460.8%
Simplified60.8%
(FPCore (x y) :precision binary64 (* x (/ (* y (+ 1.0 (* (* y y) 0.16666666666666666))) y)))
double code(double x, double y) {
return x * ((y * (1.0 + ((y * y) * 0.16666666666666666))) / y);
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = x * ((y * (1.0d0 + ((y * y) * 0.16666666666666666d0))) / y)
end function
public static double code(double x, double y) {
return x * ((y * (1.0 + ((y * y) * 0.16666666666666666))) / y);
}
def code(x, y): return x * ((y * (1.0 + ((y * y) * 0.16666666666666666))) / y)
function code(x, y) return Float64(x * Float64(Float64(y * Float64(1.0 + Float64(Float64(y * y) * 0.16666666666666666))) / y)) end
function tmp = code(x, y) tmp = x * ((y * (1.0 + ((y * y) * 0.16666666666666666))) / y); end
code[x_, y_] := N[(x * N[(N[(y * N[(1.0 + N[(N[(y * y), $MachinePrecision] * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x \cdot \frac{y \cdot \left(1 + \left(y \cdot y\right) \cdot 0.16666666666666666\right)}{y}
\end{array}
Initial program 100.0%
Taylor expanded in x around 0
Simplified64.9%
Taylor expanded in y around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6459.3%
Simplified59.3%
(FPCore (x y) :precision binary64 (if (<= x 12000.0) x (* x (* (* x x) -0.16666666666666666))))
double code(double x, double y) {
double tmp;
if (x <= 12000.0) {
tmp = x;
} else {
tmp = x * ((x * x) * -0.16666666666666666);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 12000.0d0) then
tmp = x
else
tmp = x * ((x * x) * (-0.16666666666666666d0))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 12000.0) {
tmp = x;
} else {
tmp = x * ((x * x) * -0.16666666666666666);
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 12000.0: tmp = x else: tmp = x * ((x * x) * -0.16666666666666666) return tmp
function code(x, y) tmp = 0.0 if (x <= 12000.0) tmp = x; else tmp = Float64(x * Float64(Float64(x * x) * -0.16666666666666666)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 12000.0) tmp = x; else tmp = x * ((x * x) * -0.16666666666666666); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 12000.0], x, N[(x * N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 12000:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(\left(x \cdot x\right) \cdot -0.16666666666666666\right)\\
\end{array}
\end{array}
if x < 12000Initial program 100.0%
Taylor expanded in y around 0
sin-lowering-sin.f6453.8%
Simplified53.8%
Taylor expanded in x around 0
Simplified41.2%
if 12000 < x Initial program 100.0%
Taylor expanded in y around 0
sin-lowering-sin.f6459.3%
Simplified59.3%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6413.8%
Simplified13.8%
Taylor expanded in x around inf
unpow3N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6413.8%
Simplified13.8%
Final simplification33.8%
(FPCore (x y) :precision binary64 (* x (+ 1.0 (* y (* y 0.16666666666666666)))))
double code(double x, double y) {
return x * (1.0 + (y * (y * 0.16666666666666666)));
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = x * (1.0d0 + (y * (y * 0.16666666666666666d0)))
end function
public static double code(double x, double y) {
return x * (1.0 + (y * (y * 0.16666666666666666)));
}
def code(x, y): return x * (1.0 + (y * (y * 0.16666666666666666)))
function code(x, y) return Float64(x * Float64(1.0 + Float64(y * Float64(y * 0.16666666666666666)))) end
function tmp = code(x, y) tmp = x * (1.0 + (y * (y * 0.16666666666666666))); end
code[x_, y_] := N[(x * N[(1.0 + N[(y * N[(y * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x \cdot \left(1 + y \cdot \left(y \cdot 0.16666666666666666\right)\right)
\end{array}
Initial program 100.0%
Taylor expanded in y around 0
*-lft-identityN/A
associate-*r*N/A
distribute-rgt-inN/A
*-lowering-*.f64N/A
sin-lowering-sin.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6482.0%
Simplified82.0%
Taylor expanded in x around 0
Simplified55.6%
(FPCore (x y) :precision binary64 (* x (+ 1.0 (* (* x x) -0.16666666666666666))))
double code(double x, double y) {
return x * (1.0 + ((x * x) * -0.16666666666666666));
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))
end function
public static double code(double x, double y) {
return x * (1.0 + ((x * x) * -0.16666666666666666));
}
def code(x, y): return x * (1.0 + ((x * x) * -0.16666666666666666))
function code(x, y) return Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) end
function tmp = code(x, y) tmp = x * (1.0 + ((x * x) * -0.16666666666666666)); end
code[x_, y_] := N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)
\end{array}
Initial program 100.0%
Taylor expanded in y around 0
sin-lowering-sin.f6455.2%
Simplified55.2%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6436.2%
Simplified36.2%
Final simplification36.2%
(FPCore (x y) :precision binary64 x)
double code(double x, double y) {
return x;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = x
end function
public static double code(double x, double y) {
return x;
}
def code(x, y): return x
function code(x, y) return x end
function tmp = code(x, y) tmp = x; end
code[x_, y_] := x
\begin{array}{l}
\\
x
\end{array}
Initial program 100.0%
Taylor expanded in y around 0
sin-lowering-sin.f6455.2%
Simplified55.2%
Taylor expanded in x around 0
Simplified30.8%
herbie shell --seed 2024161
(FPCore (x y)
:name "Linear.Quaternion:$ccos from linear-1.19.1.3"
:precision binary64
(* (sin x) (/ (sinh y) y)))