
(FPCore (x y) :precision binary64 (* (cosh x) (/ (sin y) y)))
double code(double x, double y) {
return cosh(x) * (sin(y) / y);
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = cosh(x) * (sin(y) / y)
end function
public static double code(double x, double y) {
return Math.cosh(x) * (Math.sin(y) / y);
}
def code(x, y): return math.cosh(x) * (math.sin(y) / y)
function code(x, y) return Float64(cosh(x) * Float64(sin(y) / y)) end
function tmp = code(x, y) tmp = cosh(x) * (sin(y) / y); end
code[x_, y_] := N[(N[Cosh[x], $MachinePrecision] * N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\cosh x \cdot \frac{\sin y}{y}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 20 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y) :precision binary64 (* (cosh x) (/ (sin y) y)))
double code(double x, double y) {
return cosh(x) * (sin(y) / y);
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = cosh(x) * (sin(y) / y)
end function
public static double code(double x, double y) {
return Math.cosh(x) * (Math.sin(y) / y);
}
def code(x, y): return math.cosh(x) * (math.sin(y) / y)
function code(x, y) return Float64(cosh(x) * Float64(sin(y) / y)) end
function tmp = code(x, y) tmp = cosh(x) * (sin(y) / y); end
code[x_, y_] := N[(N[Cosh[x], $MachinePrecision] * N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\cosh x \cdot \frac{\sin y}{y}
\end{array}
(FPCore (x y) :precision binary64 (* (cosh x) (/ (sin y) y)))
double code(double x, double y) {
return cosh(x) * (sin(y) / y);
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = cosh(x) * (sin(y) / y)
end function
public static double code(double x, double y) {
return Math.cosh(x) * (Math.sin(y) / y);
}
def code(x, y): return math.cosh(x) * (math.sin(y) / y)
function code(x, y) return Float64(cosh(x) * Float64(sin(y) / y)) end
function tmp = code(x, y) tmp = cosh(x) * (sin(y) / y); end
code[x_, y_] := N[(N[Cosh[x], $MachinePrecision] * N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\cosh x \cdot \frac{\sin y}{y}
\end{array}
Initial program 99.9%
(FPCore (x y)
:precision binary64
(let* ((t_0 (/ (sin y) y))
(t_1 (* (cosh x) t_0))
(t_2 (fma (* x x) (fma (* x x) 0.041666666666666664 0.5) 1.0)))
(if (<= t_1 (- INFINITY))
(*
t_2
(fma
y
(*
y
(fma
(* y y)
(fma y (* y -0.0001984126984126984) 0.008333333333333333)
-0.16666666666666666))
1.0))
(if (<= t_1 0.9999999950810876) (* t_0 t_2) (cosh x)))))
double code(double x, double y) {
double t_0 = sin(y) / y;
double t_1 = cosh(x) * t_0;
double t_2 = fma((x * x), fma((x * x), 0.041666666666666664, 0.5), 1.0);
double tmp;
if (t_1 <= -((double) INFINITY)) {
tmp = t_2 * fma(y, (y * fma((y * y), fma(y, (y * -0.0001984126984126984), 0.008333333333333333), -0.16666666666666666)), 1.0);
} else if (t_1 <= 0.9999999950810876) {
tmp = t_0 * t_2;
} else {
tmp = cosh(x);
}
return tmp;
}
function code(x, y) t_0 = Float64(sin(y) / y) t_1 = Float64(cosh(x) * t_0) t_2 = fma(Float64(x * x), fma(Float64(x * x), 0.041666666666666664, 0.5), 1.0) tmp = 0.0 if (t_1 <= Float64(-Inf)) tmp = Float64(t_2 * fma(y, Float64(y * fma(Float64(y * y), fma(y, Float64(y * -0.0001984126984126984), 0.008333333333333333), -0.16666666666666666)), 1.0)); elseif (t_1 <= 0.9999999950810876) tmp = Float64(t_0 * t_2); else tmp = cosh(x); end return tmp end
code[x_, y_] := Block[{t$95$0 = N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]}, Block[{t$95$1 = N[(N[Cosh[x], $MachinePrecision] * t$95$0), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x * x), $MachinePrecision] * N[(N[(x * x), $MachinePrecision] * 0.041666666666666664 + 0.5), $MachinePrecision] + 1.0), $MachinePrecision]}, If[LessEqual[t$95$1, (-Infinity)], N[(t$95$2 * N[(y * N[(y * N[(N[(y * y), $MachinePrecision] * N[(y * N[(y * -0.0001984126984126984), $MachinePrecision] + 0.008333333333333333), $MachinePrecision] + -0.16666666666666666), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 0.9999999950810876], N[(t$95$0 * t$95$2), $MachinePrecision], N[Cosh[x], $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{\sin y}{y}\\
t_1 := \cosh x \cdot t\_0\\
t_2 := \mathsf{fma}\left(x \cdot x, \mathsf{fma}\left(x \cdot x, 0.041666666666666664, 0.5\right), 1\right)\\
\mathbf{if}\;t\_1 \leq -\infty:\\
\;\;\;\;t\_2 \cdot \mathsf{fma}\left(y, y \cdot \mathsf{fma}\left(y \cdot y, \mathsf{fma}\left(y, y \cdot -0.0001984126984126984, 0.008333333333333333\right), -0.16666666666666666\right), 1\right)\\
\mathbf{elif}\;t\_1 \leq 0.9999999950810876:\\
\;\;\;\;t\_0 \cdot t\_2\\
\mathbf{else}:\\
\;\;\;\;\cosh x\\
\end{array}
\end{array}
if (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < -inf.0Initial program 100.0%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6478.6
Simplified78.6%
Taylor expanded in y around 0
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
sub-negN/A
metadata-evalN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64100.0
Simplified100.0%
if -inf.0 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < 0.99999999508108761Initial program 99.7%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6497.0
Simplified97.0%
if 0.99999999508108761 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) Initial program 100.0%
Taylor expanded in y around 0
Simplified100.0%
lift-cosh.f64N/A
*-rgt-identity100.0
Applied egg-rr100.0%
Final simplification99.2%
(FPCore (x y)
:precision binary64
(let* ((t_0 (/ (sin y) y)) (t_1 (* (cosh x) t_0)))
(if (<= t_1 (- INFINITY))
(*
(fma (* x x) (fma (* x x) 0.041666666666666664 0.5) 1.0)
(fma
y
(*
y
(fma
(* y y)
(fma y (* y -0.0001984126984126984) 0.008333333333333333)
-0.16666666666666666))
1.0))
(if (<= t_1 0.9999999950810876) (* t_0 (fma 0.5 (* x x) 1.0)) (cosh x)))))
double code(double x, double y) {
double t_0 = sin(y) / y;
double t_1 = cosh(x) * t_0;
double tmp;
if (t_1 <= -((double) INFINITY)) {
tmp = fma((x * x), fma((x * x), 0.041666666666666664, 0.5), 1.0) * fma(y, (y * fma((y * y), fma(y, (y * -0.0001984126984126984), 0.008333333333333333), -0.16666666666666666)), 1.0);
} else if (t_1 <= 0.9999999950810876) {
tmp = t_0 * fma(0.5, (x * x), 1.0);
} else {
tmp = cosh(x);
}
return tmp;
}
function code(x, y) t_0 = Float64(sin(y) / y) t_1 = Float64(cosh(x) * t_0) tmp = 0.0 if (t_1 <= Float64(-Inf)) tmp = Float64(fma(Float64(x * x), fma(Float64(x * x), 0.041666666666666664, 0.5), 1.0) * fma(y, Float64(y * fma(Float64(y * y), fma(y, Float64(y * -0.0001984126984126984), 0.008333333333333333), -0.16666666666666666)), 1.0)); elseif (t_1 <= 0.9999999950810876) tmp = Float64(t_0 * fma(0.5, Float64(x * x), 1.0)); else tmp = cosh(x); end return tmp end
code[x_, y_] := Block[{t$95$0 = N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]}, Block[{t$95$1 = N[(N[Cosh[x], $MachinePrecision] * t$95$0), $MachinePrecision]}, If[LessEqual[t$95$1, (-Infinity)], N[(N[(N[(x * x), $MachinePrecision] * N[(N[(x * x), $MachinePrecision] * 0.041666666666666664 + 0.5), $MachinePrecision] + 1.0), $MachinePrecision] * N[(y * N[(y * N[(N[(y * y), $MachinePrecision] * N[(y * N[(y * -0.0001984126984126984), $MachinePrecision] + 0.008333333333333333), $MachinePrecision] + -0.16666666666666666), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 0.9999999950810876], N[(t$95$0 * N[(0.5 * N[(x * x), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision], N[Cosh[x], $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{\sin y}{y}\\
t_1 := \cosh x \cdot t\_0\\
\mathbf{if}\;t\_1 \leq -\infty:\\
\;\;\;\;\mathsf{fma}\left(x \cdot x, \mathsf{fma}\left(x \cdot x, 0.041666666666666664, 0.5\right), 1\right) \cdot \mathsf{fma}\left(y, y \cdot \mathsf{fma}\left(y \cdot y, \mathsf{fma}\left(y, y \cdot -0.0001984126984126984, 0.008333333333333333\right), -0.16666666666666666\right), 1\right)\\
\mathbf{elif}\;t\_1 \leq 0.9999999950810876:\\
\;\;\;\;t\_0 \cdot \mathsf{fma}\left(0.5, x \cdot x, 1\right)\\
\mathbf{else}:\\
\;\;\;\;\cosh x\\
\end{array}
\end{array}
if (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < -inf.0Initial program 100.0%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6478.6
Simplified78.6%
Taylor expanded in y around 0
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
sub-negN/A
metadata-evalN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64100.0
Simplified100.0%
if -inf.0 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < 0.99999999508108761Initial program 99.7%
Taylor expanded in x around 0
*-commutativeN/A
associate-/l*N/A
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
distribute-lft1-inN/A
+-commutativeN/A
lower-*.f64N/A
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
lower-sin.f6497.0
Simplified97.0%
if 0.99999999508108761 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) Initial program 100.0%
Taylor expanded in y around 0
Simplified100.0%
lift-cosh.f64N/A
*-rgt-identity100.0
Applied egg-rr100.0%
Final simplification99.2%
(FPCore (x y)
:precision binary64
(let* ((t_0 (/ (sin y) y)) (t_1 (* (cosh x) t_0)))
(if (<= t_1 (- INFINITY))
(*
(fma (* x x) (fma (* x x) 0.041666666666666664 0.5) 1.0)
(fma
y
(*
y
(fma
(* y y)
(fma y (* y -0.0001984126984126984) 0.008333333333333333)
-0.16666666666666666))
1.0))
(if (<= t_1 0.9999999950810876) t_0 (cosh x)))))
double code(double x, double y) {
double t_0 = sin(y) / y;
double t_1 = cosh(x) * t_0;
double tmp;
if (t_1 <= -((double) INFINITY)) {
tmp = fma((x * x), fma((x * x), 0.041666666666666664, 0.5), 1.0) * fma(y, (y * fma((y * y), fma(y, (y * -0.0001984126984126984), 0.008333333333333333), -0.16666666666666666)), 1.0);
} else if (t_1 <= 0.9999999950810876) {
tmp = t_0;
} else {
tmp = cosh(x);
}
return tmp;
}
function code(x, y) t_0 = Float64(sin(y) / y) t_1 = Float64(cosh(x) * t_0) tmp = 0.0 if (t_1 <= Float64(-Inf)) tmp = Float64(fma(Float64(x * x), fma(Float64(x * x), 0.041666666666666664, 0.5), 1.0) * fma(y, Float64(y * fma(Float64(y * y), fma(y, Float64(y * -0.0001984126984126984), 0.008333333333333333), -0.16666666666666666)), 1.0)); elseif (t_1 <= 0.9999999950810876) tmp = t_0; else tmp = cosh(x); end return tmp end
code[x_, y_] := Block[{t$95$0 = N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]}, Block[{t$95$1 = N[(N[Cosh[x], $MachinePrecision] * t$95$0), $MachinePrecision]}, If[LessEqual[t$95$1, (-Infinity)], N[(N[(N[(x * x), $MachinePrecision] * N[(N[(x * x), $MachinePrecision] * 0.041666666666666664 + 0.5), $MachinePrecision] + 1.0), $MachinePrecision] * N[(y * N[(y * N[(N[(y * y), $MachinePrecision] * N[(y * N[(y * -0.0001984126984126984), $MachinePrecision] + 0.008333333333333333), $MachinePrecision] + -0.16666666666666666), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 0.9999999950810876], t$95$0, N[Cosh[x], $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{\sin y}{y}\\
t_1 := \cosh x \cdot t\_0\\
\mathbf{if}\;t\_1 \leq -\infty:\\
\;\;\;\;\mathsf{fma}\left(x \cdot x, \mathsf{fma}\left(x \cdot x, 0.041666666666666664, 0.5\right), 1\right) \cdot \mathsf{fma}\left(y, y \cdot \mathsf{fma}\left(y \cdot y, \mathsf{fma}\left(y, y \cdot -0.0001984126984126984, 0.008333333333333333\right), -0.16666666666666666\right), 1\right)\\
\mathbf{elif}\;t\_1 \leq 0.9999999950810876:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;\cosh x\\
\end{array}
\end{array}
if (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < -inf.0Initial program 100.0%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6478.6
Simplified78.6%
Taylor expanded in y around 0
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
sub-negN/A
metadata-evalN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64100.0
Simplified100.0%
if -inf.0 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < 0.99999999508108761Initial program 99.7%
Taylor expanded in x around 0
lower-/.f64N/A
lower-sin.f6496.9
Simplified96.9%
if 0.99999999508108761 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) Initial program 100.0%
Taylor expanded in y around 0
Simplified100.0%
lift-cosh.f64N/A
*-rgt-identity100.0
Applied egg-rr100.0%
(FPCore (x y)
:precision binary64
(let* ((t_0 (/ (sin y) y)))
(if (<= (* (cosh x) t_0) 0.9999999950810876)
(*
t_0
(fma
(* x x)
(fma
x
(* x (fma (* x x) 0.001388888888888889 0.041666666666666664))
0.5)
1.0))
(cosh x))))
double code(double x, double y) {
double t_0 = sin(y) / y;
double tmp;
if ((cosh(x) * t_0) <= 0.9999999950810876) {
tmp = t_0 * fma((x * x), fma(x, (x * fma((x * x), 0.001388888888888889, 0.041666666666666664)), 0.5), 1.0);
} else {
tmp = cosh(x);
}
return tmp;
}
function code(x, y) t_0 = Float64(sin(y) / y) tmp = 0.0 if (Float64(cosh(x) * t_0) <= 0.9999999950810876) tmp = Float64(t_0 * fma(Float64(x * x), fma(x, Float64(x * fma(Float64(x * x), 0.001388888888888889, 0.041666666666666664)), 0.5), 1.0)); else tmp = cosh(x); end return tmp end
code[x_, y_] := Block[{t$95$0 = N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]}, If[LessEqual[N[(N[Cosh[x], $MachinePrecision] * t$95$0), $MachinePrecision], 0.9999999950810876], N[(t$95$0 * N[(N[(x * x), $MachinePrecision] * N[(x * N[(x * N[(N[(x * x), $MachinePrecision] * 0.001388888888888889 + 0.041666666666666664), $MachinePrecision]), $MachinePrecision] + 0.5), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision], N[Cosh[x], $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{\sin y}{y}\\
\mathbf{if}\;\cosh x \cdot t\_0 \leq 0.9999999950810876:\\
\;\;\;\;t\_0 \cdot \mathsf{fma}\left(x \cdot x, \mathsf{fma}\left(x, x \cdot \mathsf{fma}\left(x \cdot x, 0.001388888888888889, 0.041666666666666664\right), 0.5\right), 1\right)\\
\mathbf{else}:\\
\;\;\;\;\cosh x\\
\end{array}
\end{array}
if (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < 0.99999999508108761Initial program 99.8%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
lower-fma.f64N/A
*-commutativeN/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6494.2
Simplified94.2%
if 0.99999999508108761 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) Initial program 100.0%
Taylor expanded in y around 0
Simplified100.0%
lift-cosh.f64N/A
*-rgt-identity100.0
Applied egg-rr100.0%
Final simplification97.7%
(FPCore (x y)
:precision binary64
(if (<= (* (cosh x) (/ (sin y) y)) -2e-135)
(*
(fma (* x x) (fma (* x x) 0.041666666666666664 0.5) 1.0)
(fma
y
(*
y
(fma
(* y y)
(fma y (* y -0.0001984126984126984) 0.008333333333333333)
-0.16666666666666666))
1.0))
(cosh x)))
double code(double x, double y) {
double tmp;
if ((cosh(x) * (sin(y) / y)) <= -2e-135) {
tmp = fma((x * x), fma((x * x), 0.041666666666666664, 0.5), 1.0) * fma(y, (y * fma((y * y), fma(y, (y * -0.0001984126984126984), 0.008333333333333333), -0.16666666666666666)), 1.0);
} else {
tmp = cosh(x);
}
return tmp;
}
function code(x, y) tmp = 0.0 if (Float64(cosh(x) * Float64(sin(y) / y)) <= -2e-135) tmp = Float64(fma(Float64(x * x), fma(Float64(x * x), 0.041666666666666664, 0.5), 1.0) * fma(y, Float64(y * fma(Float64(y * y), fma(y, Float64(y * -0.0001984126984126984), 0.008333333333333333), -0.16666666666666666)), 1.0)); else tmp = cosh(x); end return tmp end
code[x_, y_] := If[LessEqual[N[(N[Cosh[x], $MachinePrecision] * N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], -2e-135], N[(N[(N[(x * x), $MachinePrecision] * N[(N[(x * x), $MachinePrecision] * 0.041666666666666664 + 0.5), $MachinePrecision] + 1.0), $MachinePrecision] * N[(y * N[(y * N[(N[(y * y), $MachinePrecision] * N[(y * N[(y * -0.0001984126984126984), $MachinePrecision] + 0.008333333333333333), $MachinePrecision] + -0.16666666666666666), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision], N[Cosh[x], $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\cosh x \cdot \frac{\sin y}{y} \leq -2 \cdot 10^{-135}:\\
\;\;\;\;\mathsf{fma}\left(x \cdot x, \mathsf{fma}\left(x \cdot x, 0.041666666666666664, 0.5\right), 1\right) \cdot \mathsf{fma}\left(y, y \cdot \mathsf{fma}\left(y \cdot y, \mathsf{fma}\left(y, y \cdot -0.0001984126984126984, 0.008333333333333333\right), -0.16666666666666666\right), 1\right)\\
\mathbf{else}:\\
\;\;\;\;\cosh x\\
\end{array}
\end{array}
if (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < -2.0000000000000001e-135Initial program 100.0%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6482.4
Simplified82.4%
Taylor expanded in y around 0
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
sub-negN/A
metadata-evalN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f6474.3
Simplified74.3%
if -2.0000000000000001e-135 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) Initial program 99.9%
Taylor expanded in y around 0
Simplified76.5%
lift-cosh.f64N/A
*-rgt-identity76.5
Applied egg-rr76.5%
(FPCore (x y)
:precision binary64
(if (<= (* (cosh x) (/ (sin y) y)) -2e-135)
(*
(fma (* x x) (fma (* x x) 0.041666666666666664 0.5) 1.0)
(fma
y
(*
y
(fma
(* y y)
(fma y (* y -0.0001984126984126984) 0.008333333333333333)
-0.16666666666666666))
1.0))
(fma
(* x x)
(fma x (* x (fma (* x 0.001388888888888889) x 0.041666666666666664)) 0.5)
1.0)))
double code(double x, double y) {
double tmp;
if ((cosh(x) * (sin(y) / y)) <= -2e-135) {
tmp = fma((x * x), fma((x * x), 0.041666666666666664, 0.5), 1.0) * fma(y, (y * fma((y * y), fma(y, (y * -0.0001984126984126984), 0.008333333333333333), -0.16666666666666666)), 1.0);
} else {
tmp = fma((x * x), fma(x, (x * fma((x * 0.001388888888888889), x, 0.041666666666666664)), 0.5), 1.0);
}
return tmp;
}
function code(x, y) tmp = 0.0 if (Float64(cosh(x) * Float64(sin(y) / y)) <= -2e-135) tmp = Float64(fma(Float64(x * x), fma(Float64(x * x), 0.041666666666666664, 0.5), 1.0) * fma(y, Float64(y * fma(Float64(y * y), fma(y, Float64(y * -0.0001984126984126984), 0.008333333333333333), -0.16666666666666666)), 1.0)); else tmp = fma(Float64(x * x), fma(x, Float64(x * fma(Float64(x * 0.001388888888888889), x, 0.041666666666666664)), 0.5), 1.0); end return tmp end
code[x_, y_] := If[LessEqual[N[(N[Cosh[x], $MachinePrecision] * N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], -2e-135], N[(N[(N[(x * x), $MachinePrecision] * N[(N[(x * x), $MachinePrecision] * 0.041666666666666664 + 0.5), $MachinePrecision] + 1.0), $MachinePrecision] * N[(y * N[(y * N[(N[(y * y), $MachinePrecision] * N[(y * N[(y * -0.0001984126984126984), $MachinePrecision] + 0.008333333333333333), $MachinePrecision] + -0.16666666666666666), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision], N[(N[(x * x), $MachinePrecision] * N[(x * N[(x * N[(N[(x * 0.001388888888888889), $MachinePrecision] * x + 0.041666666666666664), $MachinePrecision]), $MachinePrecision] + 0.5), $MachinePrecision] + 1.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\cosh x \cdot \frac{\sin y}{y} \leq -2 \cdot 10^{-135}:\\
\;\;\;\;\mathsf{fma}\left(x \cdot x, \mathsf{fma}\left(x \cdot x, 0.041666666666666664, 0.5\right), 1\right) \cdot \mathsf{fma}\left(y, y \cdot \mathsf{fma}\left(y \cdot y, \mathsf{fma}\left(y, y \cdot -0.0001984126984126984, 0.008333333333333333\right), -0.16666666666666666\right), 1\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(x \cdot x, \mathsf{fma}\left(x, x \cdot \mathsf{fma}\left(x \cdot 0.001388888888888889, x, 0.041666666666666664\right), 0.5\right), 1\right)\\
\end{array}
\end{array}
if (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < -2.0000000000000001e-135Initial program 100.0%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6482.4
Simplified82.4%
Taylor expanded in y around 0
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
sub-negN/A
metadata-evalN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f6474.3
Simplified74.3%
if -2.0000000000000001e-135 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) Initial program 99.9%
Taylor expanded in y around 0
Simplified76.5%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6472.4
Simplified72.4%
associate-*l*N/A
*-commutativeN/A
lower-fma.f64N/A
lower-*.f6472.4
Applied egg-rr72.4%
(FPCore (x y)
:precision binary64
(if (<= (* (cosh x) (/ (sin y) y)) -2e-135)
(*
(fma
(* x x)
(fma x (* x (fma (* x x) 0.001388888888888889 0.041666666666666664)) 0.5)
1.0)
(fma y (* y -0.16666666666666666) 1.0))
(fma
(* x x)
(fma x (* x (fma (* x 0.001388888888888889) x 0.041666666666666664)) 0.5)
1.0)))
double code(double x, double y) {
double tmp;
if ((cosh(x) * (sin(y) / y)) <= -2e-135) {
tmp = fma((x * x), fma(x, (x * fma((x * x), 0.001388888888888889, 0.041666666666666664)), 0.5), 1.0) * fma(y, (y * -0.16666666666666666), 1.0);
} else {
tmp = fma((x * x), fma(x, (x * fma((x * 0.001388888888888889), x, 0.041666666666666664)), 0.5), 1.0);
}
return tmp;
}
function code(x, y) tmp = 0.0 if (Float64(cosh(x) * Float64(sin(y) / y)) <= -2e-135) tmp = Float64(fma(Float64(x * x), fma(x, Float64(x * fma(Float64(x * x), 0.001388888888888889, 0.041666666666666664)), 0.5), 1.0) * fma(y, Float64(y * -0.16666666666666666), 1.0)); else tmp = fma(Float64(x * x), fma(x, Float64(x * fma(Float64(x * 0.001388888888888889), x, 0.041666666666666664)), 0.5), 1.0); end return tmp end
code[x_, y_] := If[LessEqual[N[(N[Cosh[x], $MachinePrecision] * N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], -2e-135], N[(N[(N[(x * x), $MachinePrecision] * N[(x * N[(x * N[(N[(x * x), $MachinePrecision] * 0.001388888888888889 + 0.041666666666666664), $MachinePrecision]), $MachinePrecision] + 0.5), $MachinePrecision] + 1.0), $MachinePrecision] * N[(y * N[(y * -0.16666666666666666), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision], N[(N[(x * x), $MachinePrecision] * N[(x * N[(x * N[(N[(x * 0.001388888888888889), $MachinePrecision] * x + 0.041666666666666664), $MachinePrecision]), $MachinePrecision] + 0.5), $MachinePrecision] + 1.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\cosh x \cdot \frac{\sin y}{y} \leq -2 \cdot 10^{-135}:\\
\;\;\;\;\mathsf{fma}\left(x \cdot x, \mathsf{fma}\left(x, x \cdot \mathsf{fma}\left(x \cdot x, 0.001388888888888889, 0.041666666666666664\right), 0.5\right), 1\right) \cdot \mathsf{fma}\left(y, y \cdot -0.16666666666666666, 1\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(x \cdot x, \mathsf{fma}\left(x, x \cdot \mathsf{fma}\left(x \cdot 0.001388888888888889, x, 0.041666666666666664\right), 0.5\right), 1\right)\\
\end{array}
\end{array}
if (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < -2.0000000000000001e-135Initial program 100.0%
Taylor expanded in y around 0
+-commutativeN/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f6474.6
Simplified74.6%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6472.7
Simplified72.7%
if -2.0000000000000001e-135 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) Initial program 99.9%
Taylor expanded in y around 0
Simplified76.5%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6472.4
Simplified72.4%
associate-*l*N/A
*-commutativeN/A
lower-fma.f64N/A
lower-*.f6472.4
Applied egg-rr72.4%
(FPCore (x y)
:precision binary64
(if (<= (* (cosh x) (/ (sin y) y)) -2e-135)
(*
(fma (* x x) (fma (* x x) 0.041666666666666664 0.5) 1.0)
(fma y (* y -0.16666666666666666) 1.0))
(fma
(* x x)
(fma x (* x (fma (* x 0.001388888888888889) x 0.041666666666666664)) 0.5)
1.0)))
double code(double x, double y) {
double tmp;
if ((cosh(x) * (sin(y) / y)) <= -2e-135) {
tmp = fma((x * x), fma((x * x), 0.041666666666666664, 0.5), 1.0) * fma(y, (y * -0.16666666666666666), 1.0);
} else {
tmp = fma((x * x), fma(x, (x * fma((x * 0.001388888888888889), x, 0.041666666666666664)), 0.5), 1.0);
}
return tmp;
}
function code(x, y) tmp = 0.0 if (Float64(cosh(x) * Float64(sin(y) / y)) <= -2e-135) tmp = Float64(fma(Float64(x * x), fma(Float64(x * x), 0.041666666666666664, 0.5), 1.0) * fma(y, Float64(y * -0.16666666666666666), 1.0)); else tmp = fma(Float64(x * x), fma(x, Float64(x * fma(Float64(x * 0.001388888888888889), x, 0.041666666666666664)), 0.5), 1.0); end return tmp end
code[x_, y_] := If[LessEqual[N[(N[Cosh[x], $MachinePrecision] * N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], -2e-135], N[(N[(N[(x * x), $MachinePrecision] * N[(N[(x * x), $MachinePrecision] * 0.041666666666666664 + 0.5), $MachinePrecision] + 1.0), $MachinePrecision] * N[(y * N[(y * -0.16666666666666666), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision], N[(N[(x * x), $MachinePrecision] * N[(x * N[(x * N[(N[(x * 0.001388888888888889), $MachinePrecision] * x + 0.041666666666666664), $MachinePrecision]), $MachinePrecision] + 0.5), $MachinePrecision] + 1.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\cosh x \cdot \frac{\sin y}{y} \leq -2 \cdot 10^{-135}:\\
\;\;\;\;\mathsf{fma}\left(x \cdot x, \mathsf{fma}\left(x \cdot x, 0.041666666666666664, 0.5\right), 1\right) \cdot \mathsf{fma}\left(y, y \cdot -0.16666666666666666, 1\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(x \cdot x, \mathsf{fma}\left(x, x \cdot \mathsf{fma}\left(x \cdot 0.001388888888888889, x, 0.041666666666666664\right), 0.5\right), 1\right)\\
\end{array}
\end{array}
if (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < -2.0000000000000001e-135Initial program 100.0%
Taylor expanded in y around 0
+-commutativeN/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f6474.6
Simplified74.6%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6472.7
Simplified72.7%
if -2.0000000000000001e-135 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) Initial program 99.9%
Taylor expanded in y around 0
Simplified76.5%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6472.4
Simplified72.4%
associate-*l*N/A
*-commutativeN/A
lower-fma.f64N/A
lower-*.f6472.4
Applied egg-rr72.4%
(FPCore (x y)
:precision binary64
(if (<= (* (cosh x) (/ (sin y) y)) -2e-135)
(*
(* (* x x) (* x x))
(fma (* y y) -0.006944444444444444 0.041666666666666664))
(fma
(* x x)
(fma x (* x (fma (* x 0.001388888888888889) x 0.041666666666666664)) 0.5)
1.0)))
double code(double x, double y) {
double tmp;
if ((cosh(x) * (sin(y) / y)) <= -2e-135) {
tmp = ((x * x) * (x * x)) * fma((y * y), -0.006944444444444444, 0.041666666666666664);
} else {
tmp = fma((x * x), fma(x, (x * fma((x * 0.001388888888888889), x, 0.041666666666666664)), 0.5), 1.0);
}
return tmp;
}
function code(x, y) tmp = 0.0 if (Float64(cosh(x) * Float64(sin(y) / y)) <= -2e-135) tmp = Float64(Float64(Float64(x * x) * Float64(x * x)) * fma(Float64(y * y), -0.006944444444444444, 0.041666666666666664)); else tmp = fma(Float64(x * x), fma(x, Float64(x * fma(Float64(x * 0.001388888888888889), x, 0.041666666666666664)), 0.5), 1.0); end return tmp end
code[x_, y_] := If[LessEqual[N[(N[Cosh[x], $MachinePrecision] * N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], -2e-135], N[(N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(N[(y * y), $MachinePrecision] * -0.006944444444444444 + 0.041666666666666664), $MachinePrecision]), $MachinePrecision], N[(N[(x * x), $MachinePrecision] * N[(x * N[(x * N[(N[(x * 0.001388888888888889), $MachinePrecision] * x + 0.041666666666666664), $MachinePrecision]), $MachinePrecision] + 0.5), $MachinePrecision] + 1.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\cosh x \cdot \frac{\sin y}{y} \leq -2 \cdot 10^{-135}:\\
\;\;\;\;\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \mathsf{fma}\left(y \cdot y, -0.006944444444444444, 0.041666666666666664\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(x \cdot x, \mathsf{fma}\left(x, x \cdot \mathsf{fma}\left(x \cdot 0.001388888888888889, x, 0.041666666666666664\right), 0.5\right), 1\right)\\
\end{array}
\end{array}
if (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < -2.0000000000000001e-135Initial program 100.0%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6482.4
Simplified82.4%
Taylor expanded in x around inf
associate-/l*N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
associate-*l*N/A
associate-*l/N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
associate-/l*N/A
associate-*l/N/A
associate-*l*N/A
*-commutativeN/A
lower-*.f64N/A
lower-sin.f64N/A
*-commutativeN/A
associate-*l*N/A
associate-*l/N/A
associate-*r/N/A
Simplified57.1%
Taylor expanded in y around 0
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
distribute-lft-outN/A
lower-*.f64N/A
metadata-evalN/A
pow-sqrN/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6472.6
Simplified72.6%
if -2.0000000000000001e-135 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) Initial program 99.9%
Taylor expanded in y around 0
Simplified76.5%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6472.4
Simplified72.4%
associate-*l*N/A
*-commutativeN/A
lower-fma.f64N/A
lower-*.f6472.4
Applied egg-rr72.4%
(FPCore (x y)
:precision binary64
(if (<= (* (cosh x) (/ (sin y) y)) -2e-135)
(*
(* (* x x) (* x x))
(fma (* y y) -0.006944444444444444 0.041666666666666664))
(fma (* x x) (fma x (* x (* (* x x) 0.001388888888888889)) 0.5) 1.0)))
double code(double x, double y) {
double tmp;
if ((cosh(x) * (sin(y) / y)) <= -2e-135) {
tmp = ((x * x) * (x * x)) * fma((y * y), -0.006944444444444444, 0.041666666666666664);
} else {
tmp = fma((x * x), fma(x, (x * ((x * x) * 0.001388888888888889)), 0.5), 1.0);
}
return tmp;
}
function code(x, y) tmp = 0.0 if (Float64(cosh(x) * Float64(sin(y) / y)) <= -2e-135) tmp = Float64(Float64(Float64(x * x) * Float64(x * x)) * fma(Float64(y * y), -0.006944444444444444, 0.041666666666666664)); else tmp = fma(Float64(x * x), fma(x, Float64(x * Float64(Float64(x * x) * 0.001388888888888889)), 0.5), 1.0); end return tmp end
code[x_, y_] := If[LessEqual[N[(N[Cosh[x], $MachinePrecision] * N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], -2e-135], N[(N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(N[(y * y), $MachinePrecision] * -0.006944444444444444 + 0.041666666666666664), $MachinePrecision]), $MachinePrecision], N[(N[(x * x), $MachinePrecision] * N[(x * N[(x * N[(N[(x * x), $MachinePrecision] * 0.001388888888888889), $MachinePrecision]), $MachinePrecision] + 0.5), $MachinePrecision] + 1.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\cosh x \cdot \frac{\sin y}{y} \leq -2 \cdot 10^{-135}:\\
\;\;\;\;\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \mathsf{fma}\left(y \cdot y, -0.006944444444444444, 0.041666666666666664\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(x \cdot x, \mathsf{fma}\left(x, x \cdot \left(\left(x \cdot x\right) \cdot 0.001388888888888889\right), 0.5\right), 1\right)\\
\end{array}
\end{array}
if (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < -2.0000000000000001e-135Initial program 100.0%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6482.4
Simplified82.4%
Taylor expanded in x around inf
associate-/l*N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
associate-*l*N/A
associate-*l/N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
associate-/l*N/A
associate-*l/N/A
associate-*l*N/A
*-commutativeN/A
lower-*.f64N/A
lower-sin.f64N/A
*-commutativeN/A
associate-*l*N/A
associate-*l/N/A
associate-*r/N/A
Simplified57.1%
Taylor expanded in y around 0
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
distribute-lft-outN/A
lower-*.f64N/A
metadata-evalN/A
pow-sqrN/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6472.6
Simplified72.6%
if -2.0000000000000001e-135 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) Initial program 99.9%
Taylor expanded in y around 0
Simplified76.5%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6472.4
Simplified72.4%
Taylor expanded in x around inf
unpow3N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
unpow2N/A
lower-*.f6472.3
Simplified72.3%
(FPCore (x y)
:precision binary64
(if (<= (* (cosh x) (/ (sin y) y)) -2e-135)
(*
(* (* x x) (* x x))
(fma (* y y) -0.006944444444444444 0.041666666666666664))
(fma (* x x) (* x (* x (* (* x x) 0.001388888888888889))) 1.0)))
double code(double x, double y) {
double tmp;
if ((cosh(x) * (sin(y) / y)) <= -2e-135) {
tmp = ((x * x) * (x * x)) * fma((y * y), -0.006944444444444444, 0.041666666666666664);
} else {
tmp = fma((x * x), (x * (x * ((x * x) * 0.001388888888888889))), 1.0);
}
return tmp;
}
function code(x, y) tmp = 0.0 if (Float64(cosh(x) * Float64(sin(y) / y)) <= -2e-135) tmp = Float64(Float64(Float64(x * x) * Float64(x * x)) * fma(Float64(y * y), -0.006944444444444444, 0.041666666666666664)); else tmp = fma(Float64(x * x), Float64(x * Float64(x * Float64(Float64(x * x) * 0.001388888888888889))), 1.0); end return tmp end
code[x_, y_] := If[LessEqual[N[(N[Cosh[x], $MachinePrecision] * N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], -2e-135], N[(N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(N[(y * y), $MachinePrecision] * -0.006944444444444444 + 0.041666666666666664), $MachinePrecision]), $MachinePrecision], N[(N[(x * x), $MachinePrecision] * N[(x * N[(x * N[(N[(x * x), $MachinePrecision] * 0.001388888888888889), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\cosh x \cdot \frac{\sin y}{y} \leq -2 \cdot 10^{-135}:\\
\;\;\;\;\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \mathsf{fma}\left(y \cdot y, -0.006944444444444444, 0.041666666666666664\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(x \cdot x, x \cdot \left(x \cdot \left(\left(x \cdot x\right) \cdot 0.001388888888888889\right)\right), 1\right)\\
\end{array}
\end{array}
if (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < -2.0000000000000001e-135Initial program 100.0%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6482.4
Simplified82.4%
Taylor expanded in x around inf
associate-/l*N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
associate-*l*N/A
associate-*l/N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
associate-/l*N/A
associate-*l/N/A
associate-*l*N/A
*-commutativeN/A
lower-*.f64N/A
lower-sin.f64N/A
*-commutativeN/A
associate-*l*N/A
associate-*l/N/A
associate-*r/N/A
Simplified57.1%
Taylor expanded in y around 0
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
distribute-lft-outN/A
lower-*.f64N/A
metadata-evalN/A
pow-sqrN/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6472.6
Simplified72.6%
if -2.0000000000000001e-135 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) Initial program 99.9%
Taylor expanded in y around 0
Simplified76.5%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6472.4
Simplified72.4%
Taylor expanded in x around inf
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
unpow2N/A
associate-*r*N/A
associate-*r*N/A
unpow2N/A
unpow3N/A
*-commutativeN/A
lower-*.f64N/A
unpow3N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
unpow2N/A
lower-*.f6472.1
Simplified72.1%
(FPCore (x y)
:precision binary64
(if (<= (* (cosh x) (/ (sin y) y)) -2e-135)
(*
(* (* x x) (* x x))
(fma (* y y) -0.006944444444444444 0.041666666666666664))
(fma x (* x (fma (* x x) 0.041666666666666664 0.5)) 1.0)))
double code(double x, double y) {
double tmp;
if ((cosh(x) * (sin(y) / y)) <= -2e-135) {
tmp = ((x * x) * (x * x)) * fma((y * y), -0.006944444444444444, 0.041666666666666664);
} else {
tmp = fma(x, (x * fma((x * x), 0.041666666666666664, 0.5)), 1.0);
}
return tmp;
}
function code(x, y) tmp = 0.0 if (Float64(cosh(x) * Float64(sin(y) / y)) <= -2e-135) tmp = Float64(Float64(Float64(x * x) * Float64(x * x)) * fma(Float64(y * y), -0.006944444444444444, 0.041666666666666664)); else tmp = fma(x, Float64(x * fma(Float64(x * x), 0.041666666666666664, 0.5)), 1.0); end return tmp end
code[x_, y_] := If[LessEqual[N[(N[Cosh[x], $MachinePrecision] * N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], -2e-135], N[(N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * N[(N[(y * y), $MachinePrecision] * -0.006944444444444444 + 0.041666666666666664), $MachinePrecision]), $MachinePrecision], N[(x * N[(x * N[(N[(x * x), $MachinePrecision] * 0.041666666666666664 + 0.5), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\cosh x \cdot \frac{\sin y}{y} \leq -2 \cdot 10^{-135}:\\
\;\;\;\;\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot \mathsf{fma}\left(y \cdot y, -0.006944444444444444, 0.041666666666666664\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(x, x \cdot \mathsf{fma}\left(x \cdot x, 0.041666666666666664, 0.5\right), 1\right)\\
\end{array}
\end{array}
if (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < -2.0000000000000001e-135Initial program 100.0%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6482.4
Simplified82.4%
Taylor expanded in x around inf
associate-/l*N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
associate-*l*N/A
associate-*l/N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
associate-/l*N/A
associate-*l/N/A
associate-*l*N/A
*-commutativeN/A
lower-*.f64N/A
lower-sin.f64N/A
*-commutativeN/A
associate-*l*N/A
associate-*l/N/A
associate-*r/N/A
Simplified57.1%
Taylor expanded in y around 0
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
distribute-lft-outN/A
lower-*.f64N/A
metadata-evalN/A
pow-sqrN/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6472.6
Simplified72.6%
if -2.0000000000000001e-135 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) Initial program 99.9%
Taylor expanded in y around 0
Simplified76.5%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6472.4
Simplified72.4%
Taylor expanded in x around 0
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6468.8
Simplified68.8%
(FPCore (x y) :precision binary64 (if (<= (* (cosh x) (/ (sin y) y)) -2e-135) (* (fma 0.5 (* x x) 1.0) (fma y (* y -0.16666666666666666) 1.0)) (fma x (* x (fma (* x x) 0.041666666666666664 0.5)) 1.0)))
double code(double x, double y) {
double tmp;
if ((cosh(x) * (sin(y) / y)) <= -2e-135) {
tmp = fma(0.5, (x * x), 1.0) * fma(y, (y * -0.16666666666666666), 1.0);
} else {
tmp = fma(x, (x * fma((x * x), 0.041666666666666664, 0.5)), 1.0);
}
return tmp;
}
function code(x, y) tmp = 0.0 if (Float64(cosh(x) * Float64(sin(y) / y)) <= -2e-135) tmp = Float64(fma(0.5, Float64(x * x), 1.0) * fma(y, Float64(y * -0.16666666666666666), 1.0)); else tmp = fma(x, Float64(x * fma(Float64(x * x), 0.041666666666666664, 0.5)), 1.0); end return tmp end
code[x_, y_] := If[LessEqual[N[(N[Cosh[x], $MachinePrecision] * N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], -2e-135], N[(N[(0.5 * N[(x * x), $MachinePrecision] + 1.0), $MachinePrecision] * N[(y * N[(y * -0.16666666666666666), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision], N[(x * N[(x * N[(N[(x * x), $MachinePrecision] * 0.041666666666666664 + 0.5), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\cosh x \cdot \frac{\sin y}{y} \leq -2 \cdot 10^{-135}:\\
\;\;\;\;\mathsf{fma}\left(0.5, x \cdot x, 1\right) \cdot \mathsf{fma}\left(y, y \cdot -0.16666666666666666, 1\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(x, x \cdot \mathsf{fma}\left(x \cdot x, 0.041666666666666664, 0.5\right), 1\right)\\
\end{array}
\end{array}
if (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < -2.0000000000000001e-135Initial program 100.0%
Taylor expanded in y around 0
+-commutativeN/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f6474.6
Simplified74.6%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6467.0
Simplified67.0%
if -2.0000000000000001e-135 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) Initial program 99.9%
Taylor expanded in y around 0
Simplified76.5%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6472.4
Simplified72.4%
Taylor expanded in x around 0
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6468.8
Simplified68.8%
(FPCore (x y) :precision binary64 (if (<= (* (cosh x) (/ (sin y) y)) -2e-135) (/ (* -0.16666666666666666 (* y (* y y))) y) (fma x (* x (fma (* x x) 0.041666666666666664 0.5)) 1.0)))
double code(double x, double y) {
double tmp;
if ((cosh(x) * (sin(y) / y)) <= -2e-135) {
tmp = (-0.16666666666666666 * (y * (y * y))) / y;
} else {
tmp = fma(x, (x * fma((x * x), 0.041666666666666664, 0.5)), 1.0);
}
return tmp;
}
function code(x, y) tmp = 0.0 if (Float64(cosh(x) * Float64(sin(y) / y)) <= -2e-135) tmp = Float64(Float64(-0.16666666666666666 * Float64(y * Float64(y * y))) / y); else tmp = fma(x, Float64(x * fma(Float64(x * x), 0.041666666666666664, 0.5)), 1.0); end return tmp end
code[x_, y_] := If[LessEqual[N[(N[Cosh[x], $MachinePrecision] * N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], -2e-135], N[(N[(-0.16666666666666666 * N[(y * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(x * N[(x * N[(N[(x * x), $MachinePrecision] * 0.041666666666666664 + 0.5), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\cosh x \cdot \frac{\sin y}{y} \leq -2 \cdot 10^{-135}:\\
\;\;\;\;\frac{-0.16666666666666666 \cdot \left(y \cdot \left(y \cdot y\right)\right)}{y}\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(x, x \cdot \mathsf{fma}\left(x \cdot x, 0.041666666666666664, 0.5\right), 1\right)\\
\end{array}
\end{array}
if (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < -2.0000000000000001e-135Initial program 100.0%
Taylor expanded in x around 0
lower-/.f64N/A
lower-sin.f6426.2
Simplified26.2%
Taylor expanded in y around 0
+-commutativeN/A
distribute-lft-inN/A
*-rgt-identityN/A
lower-fma.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-*.f64N/A
lower-*.f6457.0
Simplified57.0%
Taylor expanded in y around inf
lower-*.f64N/A
cube-multN/A
unpow2N/A
lower-*.f64N/A
unpow2N/A
lower-*.f6457.0
Simplified57.0%
if -2.0000000000000001e-135 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) Initial program 99.9%
Taylor expanded in y around 0
Simplified76.5%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6472.4
Simplified72.4%
Taylor expanded in x around 0
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6468.8
Simplified68.8%
(FPCore (x y) :precision binary64 (if (<= (* (cosh x) (/ (sin y) y)) -2e-135) (* (* y y) -0.16666666666666666) (fma x (* x (fma (* x x) 0.041666666666666664 0.5)) 1.0)))
double code(double x, double y) {
double tmp;
if ((cosh(x) * (sin(y) / y)) <= -2e-135) {
tmp = (y * y) * -0.16666666666666666;
} else {
tmp = fma(x, (x * fma((x * x), 0.041666666666666664, 0.5)), 1.0);
}
return tmp;
}
function code(x, y) tmp = 0.0 if (Float64(cosh(x) * Float64(sin(y) / y)) <= -2e-135) tmp = Float64(Float64(y * y) * -0.16666666666666666); else tmp = fma(x, Float64(x * fma(Float64(x * x), 0.041666666666666664, 0.5)), 1.0); end return tmp end
code[x_, y_] := If[LessEqual[N[(N[Cosh[x], $MachinePrecision] * N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], -2e-135], N[(N[(y * y), $MachinePrecision] * -0.16666666666666666), $MachinePrecision], N[(x * N[(x * N[(N[(x * x), $MachinePrecision] * 0.041666666666666664 + 0.5), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\cosh x \cdot \frac{\sin y}{y} \leq -2 \cdot 10^{-135}:\\
\;\;\;\;\left(y \cdot y\right) \cdot -0.16666666666666666\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(x, x \cdot \mathsf{fma}\left(x \cdot x, 0.041666666666666664, 0.5\right), 1\right)\\
\end{array}
\end{array}
if (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < -2.0000000000000001e-135Initial program 100.0%
Taylor expanded in x around 0
lower-/.f64N/A
lower-sin.f6426.2
Simplified26.2%
Taylor expanded in y around 0
+-commutativeN/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f6441.8
Simplified41.8%
Taylor expanded in y around inf
lower-*.f64N/A
unpow2N/A
lower-*.f6441.8
Simplified41.8%
if -2.0000000000000001e-135 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) Initial program 99.9%
Taylor expanded in y around 0
Simplified76.5%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6472.4
Simplified72.4%
Taylor expanded in x around 0
+-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6468.8
Simplified68.8%
Final simplification63.6%
(FPCore (x y) :precision binary64 (if (<= (* (cosh x) (/ (sin y) y)) 2.0) (fma y (* y -0.16666666666666666) 1.0) (* x (* x (* (* x x) 0.041666666666666664)))))
double code(double x, double y) {
double tmp;
if ((cosh(x) * (sin(y) / y)) <= 2.0) {
tmp = fma(y, (y * -0.16666666666666666), 1.0);
} else {
tmp = x * (x * ((x * x) * 0.041666666666666664));
}
return tmp;
}
function code(x, y) tmp = 0.0 if (Float64(cosh(x) * Float64(sin(y) / y)) <= 2.0) tmp = fma(y, Float64(y * -0.16666666666666666), 1.0); else tmp = Float64(x * Float64(x * Float64(Float64(x * x) * 0.041666666666666664))); end return tmp end
code[x_, y_] := If[LessEqual[N[(N[Cosh[x], $MachinePrecision] * N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], 2.0], N[(y * N[(y * -0.16666666666666666), $MachinePrecision] + 1.0), $MachinePrecision], N[(x * N[(x * N[(N[(x * x), $MachinePrecision] * 0.041666666666666664), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\cosh x \cdot \frac{\sin y}{y} \leq 2:\\
\;\;\;\;\mathsf{fma}\left(y, y \cdot -0.16666666666666666, 1\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(x \cdot \left(\left(x \cdot x\right) \cdot 0.041666666666666664\right)\right)\\
\end{array}
\end{array}
if (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < 2Initial program 99.9%
Taylor expanded in x around 0
lower-/.f64N/A
lower-sin.f6476.1
Simplified76.1%
Taylor expanded in y around 0
+-commutativeN/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f6450.4
Simplified50.4%
if 2 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) Initial program 100.0%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6483.7
Simplified83.7%
Taylor expanded in x around inf
associate-/l*N/A
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
associate-*l*N/A
associate-*l/N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
associate-/l*N/A
associate-*l/N/A
associate-*l*N/A
*-commutativeN/A
lower-*.f64N/A
lower-sin.f64N/A
*-commutativeN/A
associate-*l*N/A
associate-*l/N/A
associate-*r/N/A
Simplified84.4%
Taylor expanded in y around 0
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
unpow2N/A
lower-*.f6483.8
Simplified83.8%
(FPCore (x y) :precision binary64 (if (<= (* (cosh x) (/ (sin y) y)) -2e-135) (* (* y y) -0.16666666666666666) (fma 0.5 (* x x) 1.0)))
double code(double x, double y) {
double tmp;
if ((cosh(x) * (sin(y) / y)) <= -2e-135) {
tmp = (y * y) * -0.16666666666666666;
} else {
tmp = fma(0.5, (x * x), 1.0);
}
return tmp;
}
function code(x, y) tmp = 0.0 if (Float64(cosh(x) * Float64(sin(y) / y)) <= -2e-135) tmp = Float64(Float64(y * y) * -0.16666666666666666); else tmp = fma(0.5, Float64(x * x), 1.0); end return tmp end
code[x_, y_] := If[LessEqual[N[(N[Cosh[x], $MachinePrecision] * N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], -2e-135], N[(N[(y * y), $MachinePrecision] * -0.16666666666666666), $MachinePrecision], N[(0.5 * N[(x * x), $MachinePrecision] + 1.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\cosh x \cdot \frac{\sin y}{y} \leq -2 \cdot 10^{-135}:\\
\;\;\;\;\left(y \cdot y\right) \cdot -0.16666666666666666\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(0.5, x \cdot x, 1\right)\\
\end{array}
\end{array}
if (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < -2.0000000000000001e-135Initial program 100.0%
Taylor expanded in x around 0
lower-/.f64N/A
lower-sin.f6426.2
Simplified26.2%
Taylor expanded in y around 0
+-commutativeN/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f6441.8
Simplified41.8%
Taylor expanded in y around inf
lower-*.f64N/A
unpow2N/A
lower-*.f6441.8
Simplified41.8%
if -2.0000000000000001e-135 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) Initial program 99.9%
Taylor expanded in y around 0
Simplified76.5%
Taylor expanded in x around 0
+-commutativeN/A
lower-fma.f64N/A
unpow2N/A
lower-*.f6456.8
Simplified56.8%
Final simplification53.9%
(FPCore (x y) :precision binary64 (if (<= (* (cosh x) (/ (sin y) y)) -2e-135) (* (* y y) -0.16666666666666666) 1.0))
double code(double x, double y) {
double tmp;
if ((cosh(x) * (sin(y) / y)) <= -2e-135) {
tmp = (y * y) * -0.16666666666666666;
} else {
tmp = 1.0;
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if ((cosh(x) * (sin(y) / y)) <= (-2d-135)) then
tmp = (y * y) * (-0.16666666666666666d0)
else
tmp = 1.0d0
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if ((Math.cosh(x) * (Math.sin(y) / y)) <= -2e-135) {
tmp = (y * y) * -0.16666666666666666;
} else {
tmp = 1.0;
}
return tmp;
}
def code(x, y): tmp = 0 if (math.cosh(x) * (math.sin(y) / y)) <= -2e-135: tmp = (y * y) * -0.16666666666666666 else: tmp = 1.0 return tmp
function code(x, y) tmp = 0.0 if (Float64(cosh(x) * Float64(sin(y) / y)) <= -2e-135) tmp = Float64(Float64(y * y) * -0.16666666666666666); else tmp = 1.0; end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if ((cosh(x) * (sin(y) / y)) <= -2e-135) tmp = (y * y) * -0.16666666666666666; else tmp = 1.0; end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[N[(N[Cosh[x], $MachinePrecision] * N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], -2e-135], N[(N[(y * y), $MachinePrecision] * -0.16666666666666666), $MachinePrecision], 1.0]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\cosh x \cdot \frac{\sin y}{y} \leq -2 \cdot 10^{-135}:\\
\;\;\;\;\left(y \cdot y\right) \cdot -0.16666666666666666\\
\mathbf{else}:\\
\;\;\;\;1\\
\end{array}
\end{array}
if (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) < -2.0000000000000001e-135Initial program 100.0%
Taylor expanded in x around 0
lower-/.f64N/A
lower-sin.f6426.2
Simplified26.2%
Taylor expanded in y around 0
+-commutativeN/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
lower-fma.f64N/A
lower-*.f6441.8
Simplified41.8%
Taylor expanded in y around inf
lower-*.f64N/A
unpow2N/A
lower-*.f6441.8
Simplified41.8%
if -2.0000000000000001e-135 < (*.f64 (cosh.f64 x) (/.f64 (sin.f64 y) y)) Initial program 99.9%
Taylor expanded in y around 0
Simplified76.5%
Taylor expanded in x around 0
Simplified30.3%
Final simplification32.5%
(FPCore (x y) :precision binary64 1.0)
double code(double x, double y) {
return 1.0;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = 1.0d0
end function
public static double code(double x, double y) {
return 1.0;
}
def code(x, y): return 1.0
function code(x, y) return 1.0 end
function tmp = code(x, y) tmp = 1.0; end
code[x_, y_] := 1.0
\begin{array}{l}
\\
1
\end{array}
Initial program 99.9%
Taylor expanded in y around 0
Simplified61.9%
Taylor expanded in x around 0
Simplified24.7%
(FPCore (x y) :precision binary64 (/ (* (cosh x) (sin y)) y))
double code(double x, double y) {
return (cosh(x) * sin(y)) / y;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = (cosh(x) * sin(y)) / y
end function
public static double code(double x, double y) {
return (Math.cosh(x) * Math.sin(y)) / y;
}
def code(x, y): return (math.cosh(x) * math.sin(y)) / y
function code(x, y) return Float64(Float64(cosh(x) * sin(y)) / y) end
function tmp = code(x, y) tmp = (cosh(x) * sin(y)) / y; end
code[x_, y_] := N[(N[(N[Cosh[x], $MachinePrecision] * N[Sin[y], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]
\begin{array}{l}
\\
\frac{\cosh x \cdot \sin y}{y}
\end{array}
herbie shell --seed 2024208
(FPCore (x y)
:name "Linear.Quaternion:$csinh from linear-1.19.1.3"
:precision binary64
:alt
(! :herbie-platform default (/ (* (cosh x) (sin y)) y))
(* (cosh x) (/ (sin y) y)))