
(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)))))) (if (<= y 0.0027) t_0 (if (<= y 3.3e+154) (/ x (/ y (sinh 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.0027) {
tmp = t_0;
} else if (y <= 3.3e+154) {
tmp = x / (y / sinh(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.0027d0) then
tmp = t_0
else if (y <= 3.3d+154) then
tmp = x / (y / sinh(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.0027) {
tmp = t_0;
} else if (y <= 3.3e+154) {
tmp = x / (y / Math.sinh(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.0027: tmp = t_0 elif y <= 3.3e+154: tmp = x / (y / math.sinh(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.0027) tmp = t_0; elseif (y <= 3.3e+154) tmp = Float64(x / Float64(y / sinh(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.0027) tmp = t_0; elseif (y <= 3.3e+154) tmp = x / (y / sinh(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.0027], t$95$0, If[LessEqual[y, 3.3e+154], N[(x / N[(y / N[Sinh[y], $MachinePrecision]), $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.0027:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;y \leq 3.3 \cdot 10^{+154}:\\
\;\;\;\;\frac{x}{\frac{y}{\sinh y}}\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if y < 0.0027000000000000001 or 3.3e154 < 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
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f6488.0%
Simplified88.0%
if 0.0027000000000000001 < y < 3.3e154Initial program 100.0%
Taylor expanded in x around 0
Simplified73.5%
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
sinh-lowering-sinh.f6473.6%
Applied egg-rr73.6%
(FPCore (x y)
:precision binary64
(if (<= y 7.2e-5)
(sin x)
(if (<= y 1e+142)
(* x (/ (sinh y) y))
(*
(* x (+ 1.0 (* (* x x) -0.16666666666666666)))
(/ (* y (+ 1.0 (* 0.16666666666666666 (* y y)))) y)))))
double code(double x, double y) {
double tmp;
if (y <= 7.2e-5) {
tmp = sin(x);
} else if (y <= 1e+142) {
tmp = x * (sinh(y) / y);
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * (1.0 + (0.16666666666666666 * (y * y)))) / y);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= 7.2d-5) then
tmp = sin(x)
else if (y <= 1d+142) then
tmp = x * (sinh(y) / y)
else
tmp = (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))) * ((y * (1.0d0 + (0.16666666666666666d0 * (y * y)))) / y)
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= 7.2e-5) {
tmp = Math.sin(x);
} else if (y <= 1e+142) {
tmp = x * (Math.sinh(y) / y);
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * (1.0 + (0.16666666666666666 * (y * y)))) / y);
}
return tmp;
}
def code(x, y): tmp = 0 if y <= 7.2e-5: tmp = math.sin(x) elif y <= 1e+142: tmp = x * (math.sinh(y) / y) else: tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * (1.0 + (0.16666666666666666 * (y * y)))) / y) return tmp
function code(x, y) tmp = 0.0 if (y <= 7.2e-5) tmp = sin(x); elseif (y <= 1e+142) tmp = Float64(x * Float64(sinh(y) / y)); else tmp = Float64(Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) * Float64(Float64(y * Float64(1.0 + Float64(0.16666666666666666 * Float64(y * y)))) / y)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= 7.2e-5) tmp = sin(x); elseif (y <= 1e+142) tmp = x * (sinh(y) / y); else tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * ((y * (1.0 + (0.16666666666666666 * (y * y)))) / y); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, 7.2e-5], N[Sin[x], $MachinePrecision], If[LessEqual[y, 1e+142], 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 * N[(1.0 + N[(0.16666666666666666 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq 7.2 \cdot 10^{-5}:\\
\;\;\;\;\sin x\\
\mathbf{elif}\;y \leq 10^{+142}:\\
\;\;\;\;x \cdot \frac{\sinh y}{y}\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\right) \cdot \frac{y \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)}{y}\\
\end{array}
\end{array}
if y < 7.20000000000000018e-5Initial program 100.0%
Taylor expanded in y around 0
sin-lowering-sin.f6473.9%
Simplified73.9%
if 7.20000000000000018e-5 < y < 1.00000000000000005e142Initial program 100.0%
Taylor expanded in x around 0
Simplified74.8%
if 1.00000000000000005e142 < y Initial program 100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6493.1%
Simplified93.1%
Taylor expanded in y around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6493.1%
Simplified93.1%
(FPCore (x y)
:precision binary64
(let* ((t_0 (* (* y y) 0.0001984126984126984))
(t_1 (* (* y y) (* (* y y) (* y y)))))
(if (<= y 7.2e-5)
(sin x)
(if (<= y 2.3e+51)
(+
x
(*
(* y y)
(+
(* x 0.16666666666666666)
(/
(*
(- 3.348979766803841e-13 (* 6.101221350130783e-23 (* t_1 t_1)))
(/
(* x (* y y))
(+
6.944444444444444e-5
(*
y
(*
y
(* 0.0001984126984126984 (+ t_0 -0.008333333333333333)))))))
(+ 5.787037037037037e-7 (* t_1 -7.811031526073099e-12))))))
(*
(* x (+ 1.0 (* (* x x) -0.16666666666666666)))
(+
1.0
(*
(* y y)
(+
0.16666666666666666
(* y (* y (+ t_0 0.008333333333333333)))))))))))
double code(double x, double y) {
double t_0 = (y * y) * 0.0001984126984126984;
double t_1 = (y * y) * ((y * y) * (y * y));
double tmp;
if (y <= 7.2e-5) {
tmp = sin(x);
} else if (y <= 2.3e+51) {
tmp = x + ((y * y) * ((x * 0.16666666666666666) + (((3.348979766803841e-13 - (6.101221350130783e-23 * (t_1 * t_1))) * ((x * (y * y)) / (6.944444444444444e-5 + (y * (y * (0.0001984126984126984 * (t_0 + -0.008333333333333333))))))) / (5.787037037037037e-7 + (t_1 * -7.811031526073099e-12)))));
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (t_0 + 0.008333333333333333))))));
}
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 = (y * y) * 0.0001984126984126984d0
t_1 = (y * y) * ((y * y) * (y * y))
if (y <= 7.2d-5) then
tmp = sin(x)
else if (y <= 2.3d+51) then
tmp = x + ((y * y) * ((x * 0.16666666666666666d0) + (((3.348979766803841d-13 - (6.101221350130783d-23 * (t_1 * t_1))) * ((x * (y * y)) / (6.944444444444444d-5 + (y * (y * (0.0001984126984126984d0 * (t_0 + (-0.008333333333333333d0)))))))) / (5.787037037037037d-7 + (t_1 * (-7.811031526073099d-12))))))
else
tmp = (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))) * (1.0d0 + ((y * y) * (0.16666666666666666d0 + (y * (y * (t_0 + 0.008333333333333333d0))))))
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = (y * y) * 0.0001984126984126984;
double t_1 = (y * y) * ((y * y) * (y * y));
double tmp;
if (y <= 7.2e-5) {
tmp = Math.sin(x);
} else if (y <= 2.3e+51) {
tmp = x + ((y * y) * ((x * 0.16666666666666666) + (((3.348979766803841e-13 - (6.101221350130783e-23 * (t_1 * t_1))) * ((x * (y * y)) / (6.944444444444444e-5 + (y * (y * (0.0001984126984126984 * (t_0 + -0.008333333333333333))))))) / (5.787037037037037e-7 + (t_1 * -7.811031526073099e-12)))));
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (t_0 + 0.008333333333333333))))));
}
return tmp;
}
def code(x, y): t_0 = (y * y) * 0.0001984126984126984 t_1 = (y * y) * ((y * y) * (y * y)) tmp = 0 if y <= 7.2e-5: tmp = math.sin(x) elif y <= 2.3e+51: tmp = x + ((y * y) * ((x * 0.16666666666666666) + (((3.348979766803841e-13 - (6.101221350130783e-23 * (t_1 * t_1))) * ((x * (y * y)) / (6.944444444444444e-5 + (y * (y * (0.0001984126984126984 * (t_0 + -0.008333333333333333))))))) / (5.787037037037037e-7 + (t_1 * -7.811031526073099e-12))))) else: tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (t_0 + 0.008333333333333333)))))) return tmp
function code(x, y) t_0 = Float64(Float64(y * y) * 0.0001984126984126984) t_1 = Float64(Float64(y * y) * Float64(Float64(y * y) * Float64(y * y))) tmp = 0.0 if (y <= 7.2e-5) tmp = sin(x); elseif (y <= 2.3e+51) tmp = Float64(x + Float64(Float64(y * y) * Float64(Float64(x * 0.16666666666666666) + Float64(Float64(Float64(3.348979766803841e-13 - Float64(6.101221350130783e-23 * Float64(t_1 * t_1))) * Float64(Float64(x * Float64(y * y)) / Float64(6.944444444444444e-5 + Float64(y * Float64(y * Float64(0.0001984126984126984 * Float64(t_0 + -0.008333333333333333))))))) / Float64(5.787037037037037e-7 + Float64(t_1 * -7.811031526073099e-12)))))); else 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(t_0 + 0.008333333333333333))))))); end return tmp end
function tmp_2 = code(x, y) t_0 = (y * y) * 0.0001984126984126984; t_1 = (y * y) * ((y * y) * (y * y)); tmp = 0.0; if (y <= 7.2e-5) tmp = sin(x); elseif (y <= 2.3e+51) tmp = x + ((y * y) * ((x * 0.16666666666666666) + (((3.348979766803841e-13 - (6.101221350130783e-23 * (t_1 * t_1))) * ((x * (y * y)) / (6.944444444444444e-5 + (y * (y * (0.0001984126984126984 * (t_0 + -0.008333333333333333))))))) / (5.787037037037037e-7 + (t_1 * -7.811031526073099e-12))))); else tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (t_0 + 0.008333333333333333)))))); end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision]}, Block[{t$95$1 = N[(N[(y * y), $MachinePrecision] * N[(N[(y * y), $MachinePrecision] * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, 7.2e-5], N[Sin[x], $MachinePrecision], If[LessEqual[y, 2.3e+51], N[(x + N[(N[(y * y), $MachinePrecision] * N[(N[(x * 0.16666666666666666), $MachinePrecision] + N[(N[(N[(3.348979766803841e-13 - N[(6.101221350130783e-23 * N[(t$95$1 * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(x * N[(y * y), $MachinePrecision]), $MachinePrecision] / N[(6.944444444444444e-5 + N[(y * N[(y * N[(0.0001984126984126984 * N[(t$95$0 + -0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(5.787037037037037e-7 + N[(t$95$1 * -7.811031526073099e-12), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 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[(t$95$0 + 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \left(y \cdot y\right) \cdot 0.0001984126984126984\\
t_1 := \left(y \cdot y\right) \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\\
\mathbf{if}\;y \leq 7.2 \cdot 10^{-5}:\\
\;\;\;\;\sin x\\
\mathbf{elif}\;y \leq 2.3 \cdot 10^{+51}:\\
\;\;\;\;x + \left(y \cdot y\right) \cdot \left(x \cdot 0.16666666666666666 + \frac{\left(3.348979766803841 \cdot 10^{-13} - 6.101221350130783 \cdot 10^{-23} \cdot \left(t\_1 \cdot t\_1\right)\right) \cdot \frac{x \cdot \left(y \cdot y\right)}{6.944444444444444 \cdot 10^{-5} + y \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(t\_0 + -0.008333333333333333\right)\right)\right)}}{5.787037037037037 \cdot 10^{-7} + t\_1 \cdot -7.811031526073099 \cdot 10^{-12}}\right)\\
\mathbf{else}:\\
\;\;\;\;\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(t\_0 + 0.008333333333333333\right)\right)\right)\right)\\
\end{array}
\end{array}
if y < 7.20000000000000018e-5Initial program 100.0%
Taylor expanded in y around 0
sin-lowering-sin.f6473.9%
Simplified73.9%
if 7.20000000000000018e-5 < y < 2.30000000000000005e51Initial program 99.9%
Taylor expanded in x around 0
Simplified78.3%
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
+-commutativeN/A
distribute-rgt-inN/A
*-commutativeN/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
distribute-rgt-outN/A
*-lowering-*.f64N/A
Simplified20.8%
*-commutativeN/A
flip3-+N/A
associate-*l/N/A
/-lowering-/.f64N/A
Applied egg-rr20.8%
Applied egg-rr39.8%
if 2.30000000000000005e51 < y Initial program 100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.0%
Simplified87.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-*.f6487.0%
Simplified87.0%
Final simplification73.6%
(FPCore (x y)
:precision binary64
(let* ((t_0 (* (* y y) (* (* y y) (* y y))))
(t_1 (* (* y y) 0.0001984126984126984)))
(if (<= y 2.3e+51)
(+
x
(*
(* y y)
(+
(* x 0.16666666666666666)
(/
(*
(- 3.348979766803841e-13 (* 6.101221350130783e-23 (* t_0 t_0)))
(/
(* x (* y y))
(+
6.944444444444444e-5
(*
y
(* y (* 0.0001984126984126984 (+ t_1 -0.008333333333333333)))))))
(+ 5.787037037037037e-7 (* t_0 -7.811031526073099e-12))))))
(*
(* x (+ 1.0 (* (* x x) -0.16666666666666666)))
(+
1.0
(*
(* y y)
(+ 0.16666666666666666 (* y (* y (+ t_1 0.008333333333333333))))))))))
double code(double x, double y) {
double t_0 = (y * y) * ((y * y) * (y * y));
double t_1 = (y * y) * 0.0001984126984126984;
double tmp;
if (y <= 2.3e+51) {
tmp = x + ((y * y) * ((x * 0.16666666666666666) + (((3.348979766803841e-13 - (6.101221350130783e-23 * (t_0 * t_0))) * ((x * (y * y)) / (6.944444444444444e-5 + (y * (y * (0.0001984126984126984 * (t_1 + -0.008333333333333333))))))) / (5.787037037037037e-7 + (t_0 * -7.811031526073099e-12)))));
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (t_1 + 0.008333333333333333))))));
}
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 = (y * y) * ((y * y) * (y * y))
t_1 = (y * y) * 0.0001984126984126984d0
if (y <= 2.3d+51) then
tmp = x + ((y * y) * ((x * 0.16666666666666666d0) + (((3.348979766803841d-13 - (6.101221350130783d-23 * (t_0 * t_0))) * ((x * (y * y)) / (6.944444444444444d-5 + (y * (y * (0.0001984126984126984d0 * (t_1 + (-0.008333333333333333d0)))))))) / (5.787037037037037d-7 + (t_0 * (-7.811031526073099d-12))))))
else
tmp = (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))) * (1.0d0 + ((y * y) * (0.16666666666666666d0 + (y * (y * (t_1 + 0.008333333333333333d0))))))
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = (y * y) * ((y * y) * (y * y));
double t_1 = (y * y) * 0.0001984126984126984;
double tmp;
if (y <= 2.3e+51) {
tmp = x + ((y * y) * ((x * 0.16666666666666666) + (((3.348979766803841e-13 - (6.101221350130783e-23 * (t_0 * t_0))) * ((x * (y * y)) / (6.944444444444444e-5 + (y * (y * (0.0001984126984126984 * (t_1 + -0.008333333333333333))))))) / (5.787037037037037e-7 + (t_0 * -7.811031526073099e-12)))));
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (t_1 + 0.008333333333333333))))));
}
return tmp;
}
def code(x, y): t_0 = (y * y) * ((y * y) * (y * y)) t_1 = (y * y) * 0.0001984126984126984 tmp = 0 if y <= 2.3e+51: tmp = x + ((y * y) * ((x * 0.16666666666666666) + (((3.348979766803841e-13 - (6.101221350130783e-23 * (t_0 * t_0))) * ((x * (y * y)) / (6.944444444444444e-5 + (y * (y * (0.0001984126984126984 * (t_1 + -0.008333333333333333))))))) / (5.787037037037037e-7 + (t_0 * -7.811031526073099e-12))))) else: tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (t_1 + 0.008333333333333333)))))) return tmp
function code(x, y) t_0 = Float64(Float64(y * y) * Float64(Float64(y * y) * Float64(y * y))) t_1 = Float64(Float64(y * y) * 0.0001984126984126984) tmp = 0.0 if (y <= 2.3e+51) tmp = Float64(x + Float64(Float64(y * y) * Float64(Float64(x * 0.16666666666666666) + Float64(Float64(Float64(3.348979766803841e-13 - Float64(6.101221350130783e-23 * Float64(t_0 * t_0))) * Float64(Float64(x * Float64(y * y)) / Float64(6.944444444444444e-5 + Float64(y * Float64(y * Float64(0.0001984126984126984 * Float64(t_1 + -0.008333333333333333))))))) / Float64(5.787037037037037e-7 + Float64(t_0 * -7.811031526073099e-12)))))); else 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(t_1 + 0.008333333333333333))))))); end return tmp end
function tmp_2 = code(x, y) t_0 = (y * y) * ((y * y) * (y * y)); t_1 = (y * y) * 0.0001984126984126984; tmp = 0.0; if (y <= 2.3e+51) tmp = x + ((y * y) * ((x * 0.16666666666666666) + (((3.348979766803841e-13 - (6.101221350130783e-23 * (t_0 * t_0))) * ((x * (y * y)) / (6.944444444444444e-5 + (y * (y * (0.0001984126984126984 * (t_1 + -0.008333333333333333))))))) / (5.787037037037037e-7 + (t_0 * -7.811031526073099e-12))))); else tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (t_1 + 0.008333333333333333)))))); end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(N[(y * y), $MachinePrecision] * N[(N[(y * y), $MachinePrecision] * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision]}, If[LessEqual[y, 2.3e+51], N[(x + N[(N[(y * y), $MachinePrecision] * N[(N[(x * 0.16666666666666666), $MachinePrecision] + N[(N[(N[(3.348979766803841e-13 - N[(6.101221350130783e-23 * N[(t$95$0 * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(x * N[(y * y), $MachinePrecision]), $MachinePrecision] / N[(6.944444444444444e-5 + N[(y * N[(y * N[(0.0001984126984126984 * N[(t$95$1 + -0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(5.787037037037037e-7 + N[(t$95$0 * -7.811031526073099e-12), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 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[(t$95$1 + 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \left(y \cdot y\right) \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\\
t_1 := \left(y \cdot y\right) \cdot 0.0001984126984126984\\
\mathbf{if}\;y \leq 2.3 \cdot 10^{+51}:\\
\;\;\;\;x + \left(y \cdot y\right) \cdot \left(x \cdot 0.16666666666666666 + \frac{\left(3.348979766803841 \cdot 10^{-13} - 6.101221350130783 \cdot 10^{-23} \cdot \left(t\_0 \cdot t\_0\right)\right) \cdot \frac{x \cdot \left(y \cdot y\right)}{6.944444444444444 \cdot 10^{-5} + y \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(t\_1 + -0.008333333333333333\right)\right)\right)}}{5.787037037037037 \cdot 10^{-7} + t\_0 \cdot -7.811031526073099 \cdot 10^{-12}}\right)\\
\mathbf{else}:\\
\;\;\;\;\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(t\_1 + 0.008333333333333333\right)\right)\right)\right)\\
\end{array}
\end{array}
if y < 2.30000000000000005e51Initial program 100.0%
Taylor expanded in x around 0
Simplified64.1%
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
+-commutativeN/A
distribute-rgt-inN/A
*-commutativeN/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
distribute-rgt-outN/A
*-lowering-*.f64N/A
Simplified54.0%
*-commutativeN/A
flip3-+N/A
associate-*l/N/A
/-lowering-/.f64N/A
Applied egg-rr42.5%
Applied egg-rr43.8%
if 2.30000000000000005e51 < y Initial program 100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6487.0%
Simplified87.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-*.f6487.0%
Simplified87.0%
Final simplification51.6%
(FPCore (x y)
:precision binary64
(if (<= x 5.5e+99)
(*
(* x (+ 1.0 (* (* x x) -0.16666666666666666)))
(+
1.0
(*
(* y y)
(+
0.16666666666666666
(*
y
(* y (+ (* (* y y) 0.0001984126984126984) 0.008333333333333333)))))))
(* x (+ 1.0 (* x (* x (* x (* x 0.008333333333333333))))))))
double code(double x, double y) {
double tmp;
if (x <= 5.5e+99) {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (((y * y) * 0.0001984126984126984) + 0.008333333333333333))))));
} else {
tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333)))));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 5.5d+99) then
tmp = (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))) * (1.0d0 + ((y * y) * (0.16666666666666666d0 + (y * (y * (((y * y) * 0.0001984126984126984d0) + 0.008333333333333333d0))))))
else
tmp = x * (1.0d0 + (x * (x * (x * (x * 0.008333333333333333d0)))))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 5.5e+99) {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (((y * y) * 0.0001984126984126984) + 0.008333333333333333))))));
} else {
tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333)))));
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 5.5e+99: tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (((y * y) * 0.0001984126984126984) + 0.008333333333333333)))))) else: tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333))))) return tmp
function code(x, y) tmp = 0.0 if (x <= 5.5e+99) 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(Float64(Float64(y * y) * 0.0001984126984126984) + 0.008333333333333333))))))); else tmp = Float64(x * Float64(1.0 + Float64(x * Float64(x * Float64(x * Float64(x * 0.008333333333333333)))))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 5.5e+99) tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (((y * y) * 0.0001984126984126984) + 0.008333333333333333)))))); else tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333))))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 5.5e+99], 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[(N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision] + 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(1.0 + N[(x * N[(x * N[(x * N[(x * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 5.5 \cdot 10^{+99}:\\
\;\;\;\;\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(\left(y \cdot y\right) \cdot 0.0001984126984126984 + 0.008333333333333333\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(1 + x \cdot \left(x \cdot \left(x \cdot \left(x \cdot 0.008333333333333333\right)\right)\right)\right)\\
\end{array}
\end{array}
if x < 5.5000000000000002e99Initial program 100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6472.2%
Simplified72.2%
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-*.f6464.4%
Simplified64.4%
if 5.5000000000000002e99 < x Initial program 100.0%
Taylor expanded in y around 0
sin-lowering-sin.f6456.9%
Simplified56.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
sub-negN/A
metadata-evalN/A
+-commutativeN/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6420.6%
Simplified20.6%
Taylor expanded in x around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6420.6%
Simplified20.6%
Final simplification58.2%
(FPCore (x y)
:precision binary64
(if (<= x 9.2e+23)
(*
x
(/
(*
y
(+
1.0
(*
(* y y)
(+
0.16666666666666666
(*
y
(* y (+ (* (* y y) 0.0001984126984126984) 0.008333333333333333)))))))
y))
(if (<= x 5.5e+99)
(*
(* x (+ 1.0 (* (* x x) -0.16666666666666666)))
(+
1.0
(* y (* y (+ 0.16666666666666666 (* (* y y) 0.008333333333333333))))))
(* x (+ 1.0 (* x (* x (* x (* x 0.008333333333333333)))))))))
double code(double x, double y) {
double tmp;
if (x <= 9.2e+23) {
tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (((y * y) * 0.0001984126984126984) + 0.008333333333333333))))))) / y);
} else if (x <= 5.5e+99) {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333)))));
} else {
tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333)))));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 9.2d+23) then
tmp = x * ((y * (1.0d0 + ((y * y) * (0.16666666666666666d0 + (y * (y * (((y * y) * 0.0001984126984126984d0) + 0.008333333333333333d0))))))) / y)
else if (x <= 5.5d+99) then
tmp = (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))) * (1.0d0 + (y * (y * (0.16666666666666666d0 + ((y * y) * 0.008333333333333333d0)))))
else
tmp = x * (1.0d0 + (x * (x * (x * (x * 0.008333333333333333d0)))))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 9.2e+23) {
tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (((y * y) * 0.0001984126984126984) + 0.008333333333333333))))))) / y);
} else if (x <= 5.5e+99) {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333)))));
} else {
tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333)))));
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 9.2e+23: tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (((y * y) * 0.0001984126984126984) + 0.008333333333333333))))))) / y) elif x <= 5.5e+99: tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333))))) else: tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333))))) return tmp
function code(x, y) tmp = 0.0 if (x <= 9.2e+23) tmp = Float64(x * Float64(Float64(y * Float64(1.0 + Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(y * Float64(y * Float64(Float64(Float64(y * y) * 0.0001984126984126984) + 0.008333333333333333))))))) / y)); elseif (x <= 5.5e+99) tmp = Float64(Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) * Float64(1.0 + Float64(y * Float64(y * Float64(0.16666666666666666 + Float64(Float64(y * y) * 0.008333333333333333)))))); else tmp = Float64(x * Float64(1.0 + Float64(x * Float64(x * Float64(x * Float64(x * 0.008333333333333333)))))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 9.2e+23) tmp = x * ((y * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (((y * y) * 0.0001984126984126984) + 0.008333333333333333))))))) / y); elseif (x <= 5.5e+99) tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333))))); else tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333))))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 9.2e+23], N[(x * N[(N[(y * N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(y * N[(y * N[(N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision] + 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 5.5e+99], N[(N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(1.0 + N[(y * N[(y * N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(1.0 + N[(x * N[(x * N[(x * N[(x * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 9.2 \cdot 10^{+23}:\\
\;\;\;\;x \cdot \frac{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984 + 0.008333333333333333\right)\right)\right)\right)}{y}\\
\mathbf{elif}\;x \leq 5.5 \cdot 10^{+99}:\\
\;\;\;\;\left(x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\right) \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(1 + x \cdot \left(x \cdot \left(x \cdot \left(x \cdot 0.008333333333333333\right)\right)\right)\right)\\
\end{array}
\end{array}
if x < 9.2000000000000002e23Initial program 100.0%
Taylor expanded in x around 0
Simplified75.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-*.f6467.3%
Simplified67.3%
if 9.2000000000000002e23 < x < 5.5000000000000002e99Initial program 100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6438.5%
Simplified38.5%
Taylor expanded in y around 0
+-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-*.f6438.5%
Simplified38.5%
if 5.5000000000000002e99 < x Initial program 100.0%
Taylor expanded in y around 0
sin-lowering-sin.f6456.9%
Simplified56.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
sub-negN/A
metadata-evalN/A
+-commutativeN/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6420.6%
Simplified20.6%
Taylor expanded in x around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6420.6%
Simplified20.6%
Final simplification59.0%
(FPCore (x y)
:precision binary64
(if (<= x 9.2e+23)
(*
x
(+
1.0
(*
(* y y)
(+
0.16666666666666666
(*
y
(* y (+ (* (* y y) 0.0001984126984126984) 0.008333333333333333)))))))
(if (<= x 5.5e+99)
(*
(* x (+ 1.0 (* (* x x) -0.16666666666666666)))
(+
1.0
(* y (* y (+ 0.16666666666666666 (* (* y y) 0.008333333333333333))))))
(* x (+ 1.0 (* x (* x (* x (* x 0.008333333333333333)))))))))
double code(double x, double y) {
double tmp;
if (x <= 9.2e+23) {
tmp = x * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (((y * y) * 0.0001984126984126984) + 0.008333333333333333))))));
} else if (x <= 5.5e+99) {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333)))));
} else {
tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333)))));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 9.2d+23) then
tmp = x * (1.0d0 + ((y * y) * (0.16666666666666666d0 + (y * (y * (((y * y) * 0.0001984126984126984d0) + 0.008333333333333333d0))))))
else if (x <= 5.5d+99) then
tmp = (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))) * (1.0d0 + (y * (y * (0.16666666666666666d0 + ((y * y) * 0.008333333333333333d0)))))
else
tmp = x * (1.0d0 + (x * (x * (x * (x * 0.008333333333333333d0)))))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 9.2e+23) {
tmp = x * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (((y * y) * 0.0001984126984126984) + 0.008333333333333333))))));
} else if (x <= 5.5e+99) {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333)))));
} else {
tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333)))));
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 9.2e+23: tmp = x * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (((y * y) * 0.0001984126984126984) + 0.008333333333333333)))))) elif x <= 5.5e+99: tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333))))) else: tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333))))) return tmp
function code(x, y) tmp = 0.0 if (x <= 9.2e+23) tmp = Float64(x * Float64(1.0 + Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(y * Float64(y * Float64(Float64(Float64(y * y) * 0.0001984126984126984) + 0.008333333333333333))))))); elseif (x <= 5.5e+99) tmp = Float64(Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) * Float64(1.0 + Float64(y * Float64(y * Float64(0.16666666666666666 + Float64(Float64(y * y) * 0.008333333333333333)))))); else tmp = Float64(x * Float64(1.0 + Float64(x * Float64(x * Float64(x * Float64(x * 0.008333333333333333)))))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 9.2e+23) tmp = x * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (((y * y) * 0.0001984126984126984) + 0.008333333333333333)))))); elseif (x <= 5.5e+99) tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333))))); else tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333))))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 9.2e+23], N[(x * N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(y * N[(y * N[(N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision] + 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 5.5e+99], N[(N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(1.0 + N[(y * N[(y * N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(1.0 + N[(x * N[(x * N[(x * N[(x * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 9.2 \cdot 10^{+23}:\\
\;\;\;\;x \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984 + 0.008333333333333333\right)\right)\right)\right)\\
\mathbf{elif}\;x \leq 5.5 \cdot 10^{+99}:\\
\;\;\;\;\left(x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\right) \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(1 + x \cdot \left(x \cdot \left(x \cdot \left(x \cdot 0.008333333333333333\right)\right)\right)\right)\\
\end{array}
\end{array}
if x < 9.2000000000000002e23Initial program 100.0%
Taylor expanded in x around 0
Simplified75.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-*.f6466.9%
Simplified66.9%
if 9.2000000000000002e23 < x < 5.5000000000000002e99Initial program 100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6438.5%
Simplified38.5%
Taylor expanded in y around 0
+-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-*.f6438.5%
Simplified38.5%
if 5.5000000000000002e99 < x Initial program 100.0%
Taylor expanded in y around 0
sin-lowering-sin.f6456.9%
Simplified56.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
sub-negN/A
metadata-evalN/A
+-commutativeN/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6420.6%
Simplified20.6%
Taylor expanded in x around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6420.6%
Simplified20.6%
Final simplification58.6%
(FPCore (x y)
:precision binary64
(if (<= x 9.2e+23)
(*
x
(/
(*
y
(+
1.0
(* y (* y (+ 0.16666666666666666 (* (* y y) 0.008333333333333333))))))
y))
(if (<= x 5.5e+99)
(*
(* x (+ 1.0 (* (* x x) -0.16666666666666666)))
(+ 1.0 (* 0.16666666666666666 (* y y))))
(* x (+ 1.0 (* x (* x (* x (* x 0.008333333333333333)))))))))
double code(double x, double y) {
double tmp;
if (x <= 9.2e+23) {
tmp = x * ((y * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333)))))) / y);
} else if (x <= 5.5e+99) {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (0.16666666666666666 * (y * y)));
} else {
tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333)))));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 9.2d+23) then
tmp = x * ((y * (1.0d0 + (y * (y * (0.16666666666666666d0 + ((y * y) * 0.008333333333333333d0)))))) / y)
else if (x <= 5.5d+99) then
tmp = (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))) * (1.0d0 + (0.16666666666666666d0 * (y * y)))
else
tmp = x * (1.0d0 + (x * (x * (x * (x * 0.008333333333333333d0)))))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 9.2e+23) {
tmp = x * ((y * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333)))))) / y);
} else if (x <= 5.5e+99) {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (0.16666666666666666 * (y * y)));
} else {
tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333)))));
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 9.2e+23: tmp = x * ((y * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333)))))) / y) elif x <= 5.5e+99: tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (0.16666666666666666 * (y * y))) else: tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333))))) return tmp
function code(x, y) tmp = 0.0 if (x <= 9.2e+23) tmp = Float64(x * Float64(Float64(y * Float64(1.0 + Float64(y * Float64(y * Float64(0.16666666666666666 + Float64(Float64(y * y) * 0.008333333333333333)))))) / y)); elseif (x <= 5.5e+99) tmp = Float64(Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) * Float64(1.0 + Float64(0.16666666666666666 * Float64(y * y)))); else tmp = Float64(x * Float64(1.0 + Float64(x * Float64(x * Float64(x * Float64(x * 0.008333333333333333)))))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 9.2e+23) tmp = x * ((y * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333)))))) / y); elseif (x <= 5.5e+99) tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (0.16666666666666666 * (y * y))); else tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333))))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 9.2e+23], N[(x * N[(N[(y * N[(1.0 + N[(y * N[(y * N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 5.5e+99], N[(N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(1.0 + N[(0.16666666666666666 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(1.0 + N[(x * N[(x * N[(x * N[(x * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 9.2 \cdot 10^{+23}:\\
\;\;\;\;x \cdot \frac{y \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)\right)}{y}\\
\mathbf{elif}\;x \leq 5.5 \cdot 10^{+99}:\\
\;\;\;\;\left(x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(1 + x \cdot \left(x \cdot \left(x \cdot \left(x \cdot 0.008333333333333333\right)\right)\right)\right)\\
\end{array}
\end{array}
if x < 9.2000000000000002e23Initial program 100.0%
Taylor expanded in x around 0
Simplified75.8%
Taylor expanded in y around 0
*-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-*.f6465.4%
Simplified65.4%
if 9.2000000000000002e23 < x < 5.5000000000000002e99Initial program 100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6438.5%
Simplified38.5%
Taylor expanded in y around 0
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
distribute-lft1-inN/A
+-commutativeN/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
Simplified32.7%
if 5.5000000000000002e99 < x Initial program 100.0%
Taylor expanded in y around 0
sin-lowering-sin.f6456.9%
Simplified56.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
sub-negN/A
metadata-evalN/A
+-commutativeN/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6420.6%
Simplified20.6%
Taylor expanded in x around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6420.6%
Simplified20.6%
Final simplification57.1%
(FPCore (x y)
:precision binary64
(if (<= x 9.2e+23)
(*
x
(+
1.0
(* y (* y (+ 0.16666666666666666 (* (* y y) 0.008333333333333333))))))
(if (<= x 5.5e+99)
(*
(* x (+ 1.0 (* (* x x) -0.16666666666666666)))
(+ 1.0 (* 0.16666666666666666 (* y y))))
(* x (+ 1.0 (* x (* x (* x (* x 0.008333333333333333)))))))))
double code(double x, double y) {
double tmp;
if (x <= 9.2e+23) {
tmp = x * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333)))));
} else if (x <= 5.5e+99) {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (0.16666666666666666 * (y * y)));
} else {
tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333)))));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 9.2d+23) then
tmp = x * (1.0d0 + (y * (y * (0.16666666666666666d0 + ((y * y) * 0.008333333333333333d0)))))
else if (x <= 5.5d+99) then
tmp = (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))) * (1.0d0 + (0.16666666666666666d0 * (y * y)))
else
tmp = x * (1.0d0 + (x * (x * (x * (x * 0.008333333333333333d0)))))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 9.2e+23) {
tmp = x * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333)))));
} else if (x <= 5.5e+99) {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (0.16666666666666666 * (y * y)));
} else {
tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333)))));
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 9.2e+23: tmp = x * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333))))) elif x <= 5.5e+99: tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (0.16666666666666666 * (y * y))) else: tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333))))) return tmp
function code(x, y) tmp = 0.0 if (x <= 9.2e+23) tmp = Float64(x * Float64(1.0 + Float64(y * Float64(y * Float64(0.16666666666666666 + Float64(Float64(y * y) * 0.008333333333333333)))))); elseif (x <= 5.5e+99) tmp = Float64(Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) * Float64(1.0 + Float64(0.16666666666666666 * Float64(y * y)))); else tmp = Float64(x * Float64(1.0 + Float64(x * Float64(x * Float64(x * Float64(x * 0.008333333333333333)))))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 9.2e+23) tmp = x * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333))))); elseif (x <= 5.5e+99) tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (0.16666666666666666 * (y * y))); else tmp = x * (1.0 + (x * (x * (x * (x * 0.008333333333333333))))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 9.2e+23], N[(x * N[(1.0 + N[(y * N[(y * N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 5.5e+99], N[(N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(1.0 + N[(0.16666666666666666 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(1.0 + N[(x * N[(x * N[(x * N[(x * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 9.2 \cdot 10^{+23}:\\
\;\;\;\;x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)\right)\\
\mathbf{elif}\;x \leq 5.5 \cdot 10^{+99}:\\
\;\;\;\;\left(x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(1 + x \cdot \left(x \cdot \left(x \cdot \left(x \cdot 0.008333333333333333\right)\right)\right)\right)\\
\end{array}
\end{array}
if x < 9.2000000000000002e23Initial program 100.0%
Taylor expanded in x around 0
Simplified75.8%
Taylor expanded in y around 0
+-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-*.f6463.6%
Simplified63.6%
if 9.2000000000000002e23 < x < 5.5000000000000002e99Initial program 100.0%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6438.5%
Simplified38.5%
Taylor expanded in y around 0
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
distribute-lft1-inN/A
+-commutativeN/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
Simplified32.7%
if 5.5000000000000002e99 < x Initial program 100.0%
Taylor expanded in y around 0
sin-lowering-sin.f6456.9%
Simplified56.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
sub-negN/A
metadata-evalN/A
+-commutativeN/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6420.6%
Simplified20.6%
Taylor expanded in x around inf
*-commutativeN/A
cube-multN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6420.6%
Simplified20.6%
Final simplification55.7%
(FPCore (x y)
:precision binary64
(if (<= y 4.1e+259)
(*
x
(+
1.0
(*
(* y y)
(+
0.16666666666666666
(*
y
(* y (+ (* (* y y) 0.0001984126984126984) 0.008333333333333333)))))))
(*
(* x (+ 1.0 (* (* x x) -0.16666666666666666)))
(+ 1.0 (* 0.16666666666666666 (* y y))))))
double code(double x, double y) {
double tmp;
if (y <= 4.1e+259) {
tmp = x * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (((y * y) * 0.0001984126984126984) + 0.008333333333333333))))));
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (0.16666666666666666 * (y * y)));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= 4.1d+259) then
tmp = x * (1.0d0 + ((y * y) * (0.16666666666666666d0 + (y * (y * (((y * y) * 0.0001984126984126984d0) + 0.008333333333333333d0))))))
else
tmp = (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))) * (1.0d0 + (0.16666666666666666d0 * (y * y)))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= 4.1e+259) {
tmp = x * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (((y * y) * 0.0001984126984126984) + 0.008333333333333333))))));
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (0.16666666666666666 * (y * y)));
}
return tmp;
}
def code(x, y): tmp = 0 if y <= 4.1e+259: tmp = x * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (((y * y) * 0.0001984126984126984) + 0.008333333333333333)))))) else: tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (0.16666666666666666 * (y * y))) return tmp
function code(x, y) tmp = 0.0 if (y <= 4.1e+259) tmp = Float64(x * Float64(1.0 + Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(y * Float64(y * Float64(Float64(Float64(y * y) * 0.0001984126984126984) + 0.008333333333333333))))))); else tmp = Float64(Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) * Float64(1.0 + Float64(0.16666666666666666 * Float64(y * y)))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= 4.1e+259) tmp = x * (1.0 + ((y * y) * (0.16666666666666666 + (y * (y * (((y * y) * 0.0001984126984126984) + 0.008333333333333333)))))); else tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (0.16666666666666666 * (y * y))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, 4.1e+259], N[(x * N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(y * N[(y * N[(N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision] + 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(1.0 + N[(0.16666666666666666 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq 4.1 \cdot 10^{+259}:\\
\;\;\;\;x \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984 + 0.008333333333333333\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\
\end{array}
\end{array}
if y < 4.1000000000000003e259Initial program 100.0%
Taylor expanded in x around 0
Simplified65.5%
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.2%
Simplified57.2%
if 4.1000000000000003e259 < y Initial 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
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
distribute-lft1-inN/A
+-commutativeN/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
Simplified100.0%
Final simplification59.5%
(FPCore (x y)
:precision binary64
(if (<= y 3.6e+259)
(+ x (* (* y y) (* y (* y (* x (* (* y y) 0.0001984126984126984))))))
(*
(* x (+ 1.0 (* (* x x) -0.16666666666666666)))
(+ 1.0 (* 0.16666666666666666 (* y y))))))
double code(double x, double y) {
double tmp;
if (y <= 3.6e+259) {
tmp = x + ((y * y) * (y * (y * (x * ((y * y) * 0.0001984126984126984)))));
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (0.16666666666666666 * (y * y)));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= 3.6d+259) then
tmp = x + ((y * y) * (y * (y * (x * ((y * y) * 0.0001984126984126984d0)))))
else
tmp = (x * (1.0d0 + ((x * x) * (-0.16666666666666666d0)))) * (1.0d0 + (0.16666666666666666d0 * (y * y)))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= 3.6e+259) {
tmp = x + ((y * y) * (y * (y * (x * ((y * y) * 0.0001984126984126984)))));
} else {
tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (0.16666666666666666 * (y * y)));
}
return tmp;
}
def code(x, y): tmp = 0 if y <= 3.6e+259: tmp = x + ((y * y) * (y * (y * (x * ((y * y) * 0.0001984126984126984))))) else: tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (0.16666666666666666 * (y * y))) return tmp
function code(x, y) tmp = 0.0 if (y <= 3.6e+259) tmp = Float64(x + Float64(Float64(y * y) * Float64(y * Float64(y * Float64(x * Float64(Float64(y * y) * 0.0001984126984126984)))))); else tmp = Float64(Float64(x * Float64(1.0 + Float64(Float64(x * x) * -0.16666666666666666))) * Float64(1.0 + Float64(0.16666666666666666 * Float64(y * y)))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= 3.6e+259) tmp = x + ((y * y) * (y * (y * (x * ((y * y) * 0.0001984126984126984))))); else tmp = (x * (1.0 + ((x * x) * -0.16666666666666666))) * (1.0 + (0.16666666666666666 * (y * y))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, 3.6e+259], N[(x + N[(N[(y * y), $MachinePrecision] * N[(y * N[(y * N[(x * N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(1.0 + N[(0.16666666666666666 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq 3.6 \cdot 10^{+259}:\\
\;\;\;\;x + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot \left(x \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot \left(1 + \left(x \cdot x\right) \cdot -0.16666666666666666\right)\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\
\end{array}
\end{array}
if y < 3.6000000000000003e259Initial program 100.0%
Taylor expanded in x around 0
Simplified65.5%
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
+-commutativeN/A
distribute-rgt-inN/A
*-commutativeN/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
distribute-rgt-outN/A
*-lowering-*.f64N/A
Simplified56.0%
*-commutativeN/A
flip3-+N/A
associate-*l/N/A
/-lowering-/.f64N/A
Applied egg-rr39.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
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6455.6%
Simplified55.6%
if 3.6000000000000003e259 < y Initial 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
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
distribute-lft1-inN/A
+-commutativeN/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
Simplified100.0%
Final simplification58.0%
(FPCore (x y) :precision binary64 (if (<= x 8e+189) (* x (/ (* y (+ 1.0 (* 0.16666666666666666 (* y y)))) y)) (* x (+ 1.0 (* x (* x -0.16666666666666666))))))
double code(double x, double y) {
double tmp;
if (x <= 8e+189) {
tmp = x * ((y * (1.0 + (0.16666666666666666 * (y * y)))) / y);
} else {
tmp = x * (1.0 + (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 <= 8d+189) then
tmp = x * ((y * (1.0d0 + (0.16666666666666666d0 * (y * y)))) / y)
else
tmp = x * (1.0d0 + (x * (x * (-0.16666666666666666d0))))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 8e+189) {
tmp = x * ((y * (1.0 + (0.16666666666666666 * (y * y)))) / y);
} else {
tmp = x * (1.0 + (x * (x * -0.16666666666666666)));
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 8e+189: tmp = x * ((y * (1.0 + (0.16666666666666666 * (y * y)))) / y) else: tmp = x * (1.0 + (x * (x * -0.16666666666666666))) return tmp
function code(x, y) tmp = 0.0 if (x <= 8e+189) tmp = Float64(x * Float64(Float64(y * Float64(1.0 + Float64(0.16666666666666666 * Float64(y * y)))) / y)); else tmp = Float64(x * Float64(1.0 + Float64(x * Float64(x * -0.16666666666666666)))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 8e+189) tmp = x * ((y * (1.0 + (0.16666666666666666 * (y * y)))) / y); else tmp = x * (1.0 + (x * (x * -0.16666666666666666))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 8e+189], N[(x * N[(N[(y * N[(1.0 + N[(0.16666666666666666 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(x * N[(1.0 + N[(x * N[(x * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 8 \cdot 10^{+189}:\\
\;\;\;\;x \cdot \frac{y \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)}{y}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(1 + x \cdot \left(x \cdot -0.16666666666666666\right)\right)\\
\end{array}
\end{array}
if x < 8.0000000000000002e189Initial program 100.0%
Taylor expanded in x around 0
Simplified69.6%
Taylor expanded in y around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6457.3%
Simplified57.3%
if 8.0000000000000002e189 < x Initial program 100.0%
Taylor expanded in y around 0
sin-lowering-sin.f6456.4%
Simplified56.4%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-commutativeN/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6411.1%
Simplified11.1%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6436.0%
Simplified36.0%
(FPCore (x y) :precision binary64 (if (<= y 3.1e+66) (* x (+ 1.0 (* x (* x -0.16666666666666666)))) (* x (* (* y y) (* (* y y) 0.008333333333333333)))))
double code(double x, double y) {
double tmp;
if (y <= 3.1e+66) {
tmp = x * (1.0 + (x * (x * -0.16666666666666666)));
} else {
tmp = x * ((y * y) * ((y * y) * 0.008333333333333333));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= 3.1d+66) then
tmp = x * (1.0d0 + (x * (x * (-0.16666666666666666d0))))
else
tmp = x * ((y * y) * ((y * y) * 0.008333333333333333d0))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= 3.1e+66) {
tmp = x * (1.0 + (x * (x * -0.16666666666666666)));
} else {
tmp = x * ((y * y) * ((y * y) * 0.008333333333333333));
}
return tmp;
}
def code(x, y): tmp = 0 if y <= 3.1e+66: tmp = x * (1.0 + (x * (x * -0.16666666666666666))) else: tmp = x * ((y * y) * ((y * y) * 0.008333333333333333)) return tmp
function code(x, y) tmp = 0.0 if (y <= 3.1e+66) tmp = Float64(x * Float64(1.0 + Float64(x * Float64(x * -0.16666666666666666)))); else tmp = Float64(x * Float64(Float64(y * y) * Float64(Float64(y * y) * 0.008333333333333333))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= 3.1e+66) tmp = x * (1.0 + (x * (x * -0.16666666666666666))); else tmp = x * ((y * y) * ((y * y) * 0.008333333333333333)); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, 3.1e+66], N[(x * N[(1.0 + N[(x * N[(x * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[(y * y), $MachinePrecision] * N[(N[(y * y), $MachinePrecision] * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq 3.1 \cdot 10^{+66}:\\
\;\;\;\;x \cdot \left(1 + x \cdot \left(x \cdot -0.16666666666666666\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(\left(y \cdot y\right) \cdot \left(\left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)\\
\end{array}
\end{array}
if y < 3.10000000000000019e66Initial program 100.0%
Taylor expanded in y around 0
sin-lowering-sin.f6466.1%
Simplified66.1%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-commutativeN/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6445.7%
Simplified45.7%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6442.1%
Simplified42.1%
if 3.10000000000000019e66 < y Initial program 100.0%
Taylor expanded in x around 0
Simplified71.4%
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
+-commutativeN/A
distribute-rgt-inN/A
*-commutativeN/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
distribute-rgt-outN/A
*-lowering-*.f64N/A
Simplified69.2%
Taylor expanded in y around 0
+-lowering-+.f64N/A
distribute-rgt-inN/A
+-commutativeN/A
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
distribute-rgt-outN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6458.0%
Simplified58.0%
Taylor expanded in y around inf
*-commutativeN/A
associate-*l*N/A
metadata-evalN/A
pow-sqrN/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6464.7%
Simplified64.7%
(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(y * Float64(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[(y * N[(y * N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)\right)
\end{array}
Initial program 100.0%
Taylor expanded in x around 0
Simplified65.0%
Taylor expanded in y around 0
+-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-*.f6454.2%
Simplified54.2%
(FPCore (x y) :precision binary64 (if (<= x 8e+189) (* x (+ 1.0 (* 0.16666666666666666 (* y y)))) (* x (+ 1.0 (* x (* x -0.16666666666666666))))))
double code(double x, double y) {
double tmp;
if (x <= 8e+189) {
tmp = x * (1.0 + (0.16666666666666666 * (y * y)));
} else {
tmp = x * (1.0 + (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 <= 8d+189) then
tmp = x * (1.0d0 + (0.16666666666666666d0 * (y * y)))
else
tmp = x * (1.0d0 + (x * (x * (-0.16666666666666666d0))))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 8e+189) {
tmp = x * (1.0 + (0.16666666666666666 * (y * y)));
} else {
tmp = x * (1.0 + (x * (x * -0.16666666666666666)));
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 8e+189: tmp = x * (1.0 + (0.16666666666666666 * (y * y))) else: tmp = x * (1.0 + (x * (x * -0.16666666666666666))) return tmp
function code(x, y) tmp = 0.0 if (x <= 8e+189) tmp = Float64(x * Float64(1.0 + Float64(0.16666666666666666 * Float64(y * y)))); else tmp = Float64(x * Float64(1.0 + Float64(x * Float64(x * -0.16666666666666666)))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 8e+189) tmp = x * (1.0 + (0.16666666666666666 * (y * y))); else tmp = x * (1.0 + (x * (x * -0.16666666666666666))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 8e+189], N[(x * N[(1.0 + N[(0.16666666666666666 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(1.0 + N[(x * N[(x * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 8 \cdot 10^{+189}:\\
\;\;\;\;x \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(1 + x \cdot \left(x \cdot -0.16666666666666666\right)\right)\\
\end{array}
\end{array}
if x < 8.0000000000000002e189Initial program 100.0%
Taylor expanded in x around 0
Simplified69.6%
Taylor expanded in y around 0
*-rgt-identityN/A
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
distribute-lft-inN/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6452.8%
Simplified52.8%
if 8.0000000000000002e189 < x Initial program 100.0%
Taylor expanded in y around 0
sin-lowering-sin.f6456.4%
Simplified56.4%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
sub-negN/A
metadata-evalN/A
+-commutativeN/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6411.1%
Simplified11.1%
Taylor expanded in x around 0
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6436.0%
Simplified36.0%
(FPCore (x y) :precision binary64 (+ x (* x (* (* y y) (* (* y y) 0.008333333333333333)))))
double code(double x, double y) {
return x + (x * ((y * y) * ((y * y) * 0.008333333333333333)));
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = x + (x * ((y * y) * ((y * y) * 0.008333333333333333d0)))
end function
public static double code(double x, double y) {
return x + (x * ((y * y) * ((y * y) * 0.008333333333333333)));
}
def code(x, y): return x + (x * ((y * y) * ((y * y) * 0.008333333333333333)))
function code(x, y) return Float64(x + Float64(x * Float64(Float64(y * y) * Float64(Float64(y * y) * 0.008333333333333333)))) end
function tmp = code(x, y) tmp = x + (x * ((y * y) * ((y * y) * 0.008333333333333333))); end
code[x_, y_] := N[(x + N[(x * N[(N[(y * y), $MachinePrecision] * N[(N[(y * y), $MachinePrecision] * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + x \cdot \left(\left(y \cdot y\right) \cdot \left(\left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)
\end{array}
Initial program 100.0%
Taylor expanded in x around 0
Simplified65.0%
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
+-commutativeN/A
distribute-rgt-inN/A
*-commutativeN/A
associate-*r*N/A
associate-*r*N/A
*-commutativeN/A
distribute-rgt-outN/A
*-lowering-*.f64N/A
Simplified56.1%
Taylor expanded in y around 0
+-lowering-+.f64N/A
distribute-rgt-inN/A
+-commutativeN/A
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
distribute-rgt-outN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6452.4%
Simplified52.4%
Taylor expanded in y around inf
*-commutativeN/A
associate-*l*N/A
metadata-evalN/A
pow-sqrN/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6453.8%
Simplified53.8%
(FPCore (x y) :precision binary64 (if (<= y 2.4) x (* x (* 0.16666666666666666 (* y y)))))
double code(double x, double y) {
double tmp;
if (y <= 2.4) {
tmp = x;
} else {
tmp = x * (0.16666666666666666 * (y * y));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= 2.4d0) then
tmp = x
else
tmp = x * (0.16666666666666666d0 * (y * y))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= 2.4) {
tmp = x;
} else {
tmp = x * (0.16666666666666666 * (y * y));
}
return tmp;
}
def code(x, y): tmp = 0 if y <= 2.4: tmp = x else: tmp = x * (0.16666666666666666 * (y * y)) return tmp
function code(x, y) tmp = 0.0 if (y <= 2.4) tmp = x; else tmp = Float64(x * Float64(0.16666666666666666 * Float64(y * y))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= 2.4) tmp = x; else tmp = x * (0.16666666666666666 * (y * y)); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, 2.4], x, N[(x * N[(0.16666666666666666 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq 2.4:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\
\end{array}
\end{array}
if y < 2.39999999999999991Initial program 100.0%
Taylor expanded in y around 0
sin-lowering-sin.f6473.8%
Simplified73.8%
Taylor expanded in x around 0
Simplified42.3%
if 2.39999999999999991 < y Initial program 100.0%
Taylor expanded in x around 0
Simplified72.3%
Taylor expanded in y around 0
*-rgt-identityN/A
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
distribute-lft-inN/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6433.9%
Simplified33.9%
Taylor expanded in y around inf
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6433.9%
Simplified33.9%
(FPCore (x y) :precision binary64 (* x (+ 1.0 (* 0.16666666666666666 (* y y)))))
double code(double x, double y) {
return x * (1.0 + (0.16666666666666666 * (y * y)));
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = x * (1.0d0 + (0.16666666666666666d0 * (y * y)))
end function
public static double code(double x, double y) {
return x * (1.0 + (0.16666666666666666 * (y * y)));
}
def code(x, y): return x * (1.0 + (0.16666666666666666 * (y * y)))
function code(x, y) return Float64(x * Float64(1.0 + Float64(0.16666666666666666 * Float64(y * y)))) end
function tmp = code(x, y) tmp = x * (1.0 + (0.16666666666666666 * (y * y))); end
code[x_, y_] := N[(x * N[(1.0 + N[(0.16666666666666666 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)
\end{array}
Initial program 100.0%
Taylor expanded in x around 0
Simplified65.0%
Taylor expanded in y around 0
*-rgt-identityN/A
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
distribute-lft-inN/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6449.2%
Simplified49.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.7%
Simplified55.7%
Taylor expanded in x around 0
Simplified32.1%
herbie shell --seed 2024191
(FPCore (x y)
:name "Linear.Quaternion:$ccos from linear-1.19.1.3"
:precision binary64
(* (sin x) (/ (sinh y) y)))