
(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 21 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
(if (<= x 40.0)
(*
(/ (sin y) y)
(+
1.0
(*
(* x x)
(+
0.5
(*
x
(* x (+ 0.041666666666666664 (* (* x x) 0.001388888888888889))))))))
(if (<= x 7.2e+51)
(cosh x)
(/
(+ 1.0 (* (* x x) (+ 0.5 (* x (* x (* x (* x 0.001388888888888889)))))))
(/ y (sin y))))))
double code(double x, double y) {
double tmp;
if (x <= 40.0) {
tmp = (sin(y) / y) * (1.0 + ((x * x) * (0.5 + (x * (x * (0.041666666666666664 + ((x * x) * 0.001388888888888889)))))));
} else if (x <= 7.2e+51) {
tmp = cosh(x);
} else {
tmp = (1.0 + ((x * x) * (0.5 + (x * (x * (x * (x * 0.001388888888888889))))))) / (y / sin(y));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 40.0d0) then
tmp = (sin(y) / y) * (1.0d0 + ((x * x) * (0.5d0 + (x * (x * (0.041666666666666664d0 + ((x * x) * 0.001388888888888889d0)))))))
else if (x <= 7.2d+51) then
tmp = cosh(x)
else
tmp = (1.0d0 + ((x * x) * (0.5d0 + (x * (x * (x * (x * 0.001388888888888889d0))))))) / (y / sin(y))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 40.0) {
tmp = (Math.sin(y) / y) * (1.0 + ((x * x) * (0.5 + (x * (x * (0.041666666666666664 + ((x * x) * 0.001388888888888889)))))));
} else if (x <= 7.2e+51) {
tmp = Math.cosh(x);
} else {
tmp = (1.0 + ((x * x) * (0.5 + (x * (x * (x * (x * 0.001388888888888889))))))) / (y / Math.sin(y));
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 40.0: tmp = (math.sin(y) / y) * (1.0 + ((x * x) * (0.5 + (x * (x * (0.041666666666666664 + ((x * x) * 0.001388888888888889))))))) elif x <= 7.2e+51: tmp = math.cosh(x) else: tmp = (1.0 + ((x * x) * (0.5 + (x * (x * (x * (x * 0.001388888888888889))))))) / (y / math.sin(y)) return tmp
function code(x, y) tmp = 0.0 if (x <= 40.0) tmp = Float64(Float64(sin(y) / y) * Float64(1.0 + Float64(Float64(x * x) * Float64(0.5 + Float64(x * Float64(x * Float64(0.041666666666666664 + Float64(Float64(x * x) * 0.001388888888888889)))))))); elseif (x <= 7.2e+51) tmp = cosh(x); else tmp = Float64(Float64(1.0 + Float64(Float64(x * x) * Float64(0.5 + Float64(x * Float64(x * Float64(x * Float64(x * 0.001388888888888889))))))) / Float64(y / sin(y))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 40.0) tmp = (sin(y) / y) * (1.0 + ((x * x) * (0.5 + (x * (x * (0.041666666666666664 + ((x * x) * 0.001388888888888889))))))); elseif (x <= 7.2e+51) tmp = cosh(x); else tmp = (1.0 + ((x * x) * (0.5 + (x * (x * (x * (x * 0.001388888888888889))))))) / (y / sin(y)); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 40.0], N[(N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision] * N[(1.0 + N[(N[(x * x), $MachinePrecision] * N[(0.5 + N[(x * N[(x * N[(0.041666666666666664 + N[(N[(x * x), $MachinePrecision] * 0.001388888888888889), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 7.2e+51], N[Cosh[x], $MachinePrecision], N[(N[(1.0 + N[(N[(x * x), $MachinePrecision] * N[(0.5 + N[(x * N[(x * N[(x * N[(x * 0.001388888888888889), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(y / N[Sin[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 40:\\
\;\;\;\;\frac{\sin y}{y} \cdot \left(1 + \left(x \cdot x\right) \cdot \left(0.5 + x \cdot \left(x \cdot \left(0.041666666666666664 + \left(x \cdot x\right) \cdot 0.001388888888888889\right)\right)\right)\right)\\
\mathbf{elif}\;x \leq 7.2 \cdot 10^{+51}:\\
\;\;\;\;\cosh x\\
\mathbf{else}:\\
\;\;\;\;\frac{1 + \left(x \cdot x\right) \cdot \left(0.5 + x \cdot \left(x \cdot \left(x \cdot \left(x \cdot 0.001388888888888889\right)\right)\right)\right)}{\frac{y}{\sin y}}\\
\end{array}
\end{array}
if x < 40Initial program 99.8%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6495.8%
Simplified95.8%
if 40 < x < 7.20000000000000022e51Initial program 100.0%
Taylor expanded in y around 0
Simplified100.0%
*-rgt-identityN/A
cosh-lowering-cosh.f64100.0%
Applied egg-rr100.0%
if 7.20000000000000022e51 < x Initial program 100.0%
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
cosh-lowering-cosh.f64N/A
/-lowering-/.f64N/A
sin-lowering-sin.f64100.0%
Applied egg-rr100.0%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around inf
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64100.0%
Simplified100.0%
Final simplification96.9%
(FPCore (x y)
:precision binary64
(if (<= x 0.026)
(*
(/ (sin y) y)
(+ 1.0 (* (* x x) (+ 0.5 (* x (* x 0.041666666666666664))))))
(if (<= x 7.2e+51)
(cosh x)
(/
(+ 1.0 (* (* x x) (+ 0.5 (* x (* x (* x (* x 0.001388888888888889)))))))
(/ y (sin y))))))
double code(double x, double y) {
double tmp;
if (x <= 0.026) {
tmp = (sin(y) / y) * (1.0 + ((x * x) * (0.5 + (x * (x * 0.041666666666666664)))));
} else if (x <= 7.2e+51) {
tmp = cosh(x);
} else {
tmp = (1.0 + ((x * x) * (0.5 + (x * (x * (x * (x * 0.001388888888888889))))))) / (y / sin(y));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 0.026d0) then
tmp = (sin(y) / y) * (1.0d0 + ((x * x) * (0.5d0 + (x * (x * 0.041666666666666664d0)))))
else if (x <= 7.2d+51) then
tmp = cosh(x)
else
tmp = (1.0d0 + ((x * x) * (0.5d0 + (x * (x * (x * (x * 0.001388888888888889d0))))))) / (y / sin(y))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 0.026) {
tmp = (Math.sin(y) / y) * (1.0 + ((x * x) * (0.5 + (x * (x * 0.041666666666666664)))));
} else if (x <= 7.2e+51) {
tmp = Math.cosh(x);
} else {
tmp = (1.0 + ((x * x) * (0.5 + (x * (x * (x * (x * 0.001388888888888889))))))) / (y / Math.sin(y));
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 0.026: tmp = (math.sin(y) / y) * (1.0 + ((x * x) * (0.5 + (x * (x * 0.041666666666666664))))) elif x <= 7.2e+51: tmp = math.cosh(x) else: tmp = (1.0 + ((x * x) * (0.5 + (x * (x * (x * (x * 0.001388888888888889))))))) / (y / math.sin(y)) return tmp
function code(x, y) tmp = 0.0 if (x <= 0.026) tmp = Float64(Float64(sin(y) / y) * Float64(1.0 + Float64(Float64(x * x) * Float64(0.5 + Float64(x * Float64(x * 0.041666666666666664)))))); elseif (x <= 7.2e+51) tmp = cosh(x); else tmp = Float64(Float64(1.0 + Float64(Float64(x * x) * Float64(0.5 + Float64(x * Float64(x * Float64(x * Float64(x * 0.001388888888888889))))))) / Float64(y / sin(y))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 0.026) tmp = (sin(y) / y) * (1.0 + ((x * x) * (0.5 + (x * (x * 0.041666666666666664))))); elseif (x <= 7.2e+51) tmp = cosh(x); else tmp = (1.0 + ((x * x) * (0.5 + (x * (x * (x * (x * 0.001388888888888889))))))) / (y / sin(y)); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 0.026], N[(N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision] * N[(1.0 + N[(N[(x * x), $MachinePrecision] * N[(0.5 + N[(x * N[(x * 0.041666666666666664), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 7.2e+51], N[Cosh[x], $MachinePrecision], N[(N[(1.0 + N[(N[(x * x), $MachinePrecision] * N[(0.5 + N[(x * N[(x * N[(x * N[(x * 0.001388888888888889), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(y / N[Sin[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 0.026:\\
\;\;\;\;\frac{\sin y}{y} \cdot \left(1 + \left(x \cdot x\right) \cdot \left(0.5 + x \cdot \left(x \cdot 0.041666666666666664\right)\right)\right)\\
\mathbf{elif}\;x \leq 7.2 \cdot 10^{+51}:\\
\;\;\;\;\cosh x\\
\mathbf{else}:\\
\;\;\;\;\frac{1 + \left(x \cdot x\right) \cdot \left(0.5 + x \cdot \left(x \cdot \left(x \cdot \left(x \cdot 0.001388888888888889\right)\right)\right)\right)}{\frac{y}{\sin y}}\\
\end{array}
\end{array}
if x < 0.0259999999999999988Initial program 99.9%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f6494.1%
Simplified94.1%
if 0.0259999999999999988 < x < 7.20000000000000022e51Initial program 99.9%
Taylor expanded in y around 0
Simplified93.9%
*-rgt-identityN/A
cosh-lowering-cosh.f6493.9%
Applied egg-rr93.9%
if 7.20000000000000022e51 < x Initial program 100.0%
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
cosh-lowering-cosh.f64N/A
/-lowering-/.f64N/A
sin-lowering-sin.f64100.0%
Applied egg-rr100.0%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around inf
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64100.0%
Simplified100.0%
Final simplification95.3%
(FPCore (x y)
:precision binary64
(if (<= x 0.026)
(*
(/ (sin y) y)
(+ 1.0 (* (* x x) (+ 0.5 (* x (* x 0.041666666666666664))))))
(if (<= x 2e+77)
(cosh x)
(/ (* (sin y) (* x (* x (* (* x x) 0.041666666666666664)))) y))))
double code(double x, double y) {
double tmp;
if (x <= 0.026) {
tmp = (sin(y) / y) * (1.0 + ((x * x) * (0.5 + (x * (x * 0.041666666666666664)))));
} else if (x <= 2e+77) {
tmp = cosh(x);
} else {
tmp = (sin(y) * (x * (x * ((x * x) * 0.041666666666666664)))) / y;
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 0.026d0) then
tmp = (sin(y) / y) * (1.0d0 + ((x * x) * (0.5d0 + (x * (x * 0.041666666666666664d0)))))
else if (x <= 2d+77) then
tmp = cosh(x)
else
tmp = (sin(y) * (x * (x * ((x * x) * 0.041666666666666664d0)))) / y
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 0.026) {
tmp = (Math.sin(y) / y) * (1.0 + ((x * x) * (0.5 + (x * (x * 0.041666666666666664)))));
} else if (x <= 2e+77) {
tmp = Math.cosh(x);
} else {
tmp = (Math.sin(y) * (x * (x * ((x * x) * 0.041666666666666664)))) / y;
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 0.026: tmp = (math.sin(y) / y) * (1.0 + ((x * x) * (0.5 + (x * (x * 0.041666666666666664))))) elif x <= 2e+77: tmp = math.cosh(x) else: tmp = (math.sin(y) * (x * (x * ((x * x) * 0.041666666666666664)))) / y return tmp
function code(x, y) tmp = 0.0 if (x <= 0.026) tmp = Float64(Float64(sin(y) / y) * Float64(1.0 + Float64(Float64(x * x) * Float64(0.5 + Float64(x * Float64(x * 0.041666666666666664)))))); elseif (x <= 2e+77) tmp = cosh(x); else tmp = Float64(Float64(sin(y) * Float64(x * Float64(x * Float64(Float64(x * x) * 0.041666666666666664)))) / y); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 0.026) tmp = (sin(y) / y) * (1.0 + ((x * x) * (0.5 + (x * (x * 0.041666666666666664))))); elseif (x <= 2e+77) tmp = cosh(x); else tmp = (sin(y) * (x * (x * ((x * x) * 0.041666666666666664)))) / y; end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 0.026], N[(N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision] * N[(1.0 + N[(N[(x * x), $MachinePrecision] * N[(0.5 + N[(x * N[(x * 0.041666666666666664), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2e+77], N[Cosh[x], $MachinePrecision], N[(N[(N[Sin[y], $MachinePrecision] * N[(x * N[(x * N[(N[(x * x), $MachinePrecision] * 0.041666666666666664), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 0.026:\\
\;\;\;\;\frac{\sin y}{y} \cdot \left(1 + \left(x \cdot x\right) \cdot \left(0.5 + x \cdot \left(x \cdot 0.041666666666666664\right)\right)\right)\\
\mathbf{elif}\;x \leq 2 \cdot 10^{+77}:\\
\;\;\;\;\cosh x\\
\mathbf{else}:\\
\;\;\;\;\frac{\sin y \cdot \left(x \cdot \left(x \cdot \left(\left(x \cdot x\right) \cdot 0.041666666666666664\right)\right)\right)}{y}\\
\end{array}
\end{array}
if x < 0.0259999999999999988Initial program 99.9%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f6494.1%
Simplified94.1%
if 0.0259999999999999988 < x < 1.99999999999999997e77Initial program 99.9%
Taylor expanded in y around 0
Simplified91.8%
*-rgt-identityN/A
cosh-lowering-cosh.f6491.8%
Applied egg-rr91.8%
if 1.99999999999999997e77 < x Initial program 100.0%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around inf
associate-*r/N/A
associate-*r*N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
sin-lowering-sin.f64100.0%
Simplified100.0%
Final simplification94.9%
(FPCore (x y)
:precision binary64
(if (<= x 0.0135)
(* (/ (sin y) y) (+ 1.0 (* (* x x) 0.5)))
(if (<= x 2.6e+77)
(cosh x)
(/ (* (sin y) (* x (* x (* (* x x) 0.041666666666666664)))) y))))
double code(double x, double y) {
double tmp;
if (x <= 0.0135) {
tmp = (sin(y) / y) * (1.0 + ((x * x) * 0.5));
} else if (x <= 2.6e+77) {
tmp = cosh(x);
} else {
tmp = (sin(y) * (x * (x * ((x * x) * 0.041666666666666664)))) / y;
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 0.0135d0) then
tmp = (sin(y) / y) * (1.0d0 + ((x * x) * 0.5d0))
else if (x <= 2.6d+77) then
tmp = cosh(x)
else
tmp = (sin(y) * (x * (x * ((x * x) * 0.041666666666666664d0)))) / y
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 0.0135) {
tmp = (Math.sin(y) / y) * (1.0 + ((x * x) * 0.5));
} else if (x <= 2.6e+77) {
tmp = Math.cosh(x);
} else {
tmp = (Math.sin(y) * (x * (x * ((x * x) * 0.041666666666666664)))) / y;
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 0.0135: tmp = (math.sin(y) / y) * (1.0 + ((x * x) * 0.5)) elif x <= 2.6e+77: tmp = math.cosh(x) else: tmp = (math.sin(y) * (x * (x * ((x * x) * 0.041666666666666664)))) / y return tmp
function code(x, y) tmp = 0.0 if (x <= 0.0135) tmp = Float64(Float64(sin(y) / y) * Float64(1.0 + Float64(Float64(x * x) * 0.5))); elseif (x <= 2.6e+77) tmp = cosh(x); else tmp = Float64(Float64(sin(y) * Float64(x * Float64(x * Float64(Float64(x * x) * 0.041666666666666664)))) / y); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 0.0135) tmp = (sin(y) / y) * (1.0 + ((x * x) * 0.5)); elseif (x <= 2.6e+77) tmp = cosh(x); else tmp = (sin(y) * (x * (x * ((x * x) * 0.041666666666666664)))) / y; end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 0.0135], N[(N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision] * N[(1.0 + N[(N[(x * x), $MachinePrecision] * 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.6e+77], N[Cosh[x], $MachinePrecision], N[(N[(N[Sin[y], $MachinePrecision] * N[(x * N[(x * N[(N[(x * x), $MachinePrecision] * 0.041666666666666664), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 0.0135:\\
\;\;\;\;\frac{\sin y}{y} \cdot \left(1 + \left(x \cdot x\right) \cdot 0.5\right)\\
\mathbf{elif}\;x \leq 2.6 \cdot 10^{+77}:\\
\;\;\;\;\cosh x\\
\mathbf{else}:\\
\;\;\;\;\frac{\sin y \cdot \left(x \cdot \left(x \cdot \left(\left(x \cdot x\right) \cdot 0.041666666666666664\right)\right)\right)}{y}\\
\end{array}
\end{array}
if x < 0.0134999999999999998Initial program 99.9%
Taylor expanded in x around 0
*-commutativeN/A
*-commutativeN/A
associate-/l*N/A
associate-*r*N/A
distribute-lft1-inN/A
+-commutativeN/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
sin-lowering-sin.f6488.2%
Simplified88.2%
if 0.0134999999999999998 < x < 2.6000000000000002e77Initial program 99.9%
Taylor expanded in y around 0
Simplified91.8%
*-rgt-identityN/A
cosh-lowering-cosh.f6491.8%
Applied egg-rr91.8%
if 2.6000000000000002e77 < x Initial program 100.0%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around inf
associate-*r/N/A
associate-*r*N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
sin-lowering-sin.f64100.0%
Simplified100.0%
Final simplification90.7%
(FPCore (x y) :precision binary64 (let* ((t_0 (* (/ (sin y) y) (+ 1.0 (* (* x x) 0.5))))) (if (<= x 0.021) t_0 (if (<= x 4.4e+152) (cosh x) t_0))))
double code(double x, double y) {
double t_0 = (sin(y) / y) * (1.0 + ((x * x) * 0.5));
double tmp;
if (x <= 0.021) {
tmp = t_0;
} else if (x <= 4.4e+152) {
tmp = cosh(x);
} 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(y) / y) * (1.0d0 + ((x * x) * 0.5d0))
if (x <= 0.021d0) then
tmp = t_0
else if (x <= 4.4d+152) then
tmp = cosh(x)
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = (Math.sin(y) / y) * (1.0 + ((x * x) * 0.5));
double tmp;
if (x <= 0.021) {
tmp = t_0;
} else if (x <= 4.4e+152) {
tmp = Math.cosh(x);
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y): t_0 = (math.sin(y) / y) * (1.0 + ((x * x) * 0.5)) tmp = 0 if x <= 0.021: tmp = t_0 elif x <= 4.4e+152: tmp = math.cosh(x) else: tmp = t_0 return tmp
function code(x, y) t_0 = Float64(Float64(sin(y) / y) * Float64(1.0 + Float64(Float64(x * x) * 0.5))) tmp = 0.0 if (x <= 0.021) tmp = t_0; elseif (x <= 4.4e+152) tmp = cosh(x); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y) t_0 = (sin(y) / y) * (1.0 + ((x * x) * 0.5)); tmp = 0.0; if (x <= 0.021) tmp = t_0; elseif (x <= 4.4e+152) tmp = cosh(x); else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision] * N[(1.0 + N[(N[(x * x), $MachinePrecision] * 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, 0.021], t$95$0, If[LessEqual[x, 4.4e+152], N[Cosh[x], $MachinePrecision], t$95$0]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{\sin y}{y} \cdot \left(1 + \left(x \cdot x\right) \cdot 0.5\right)\\
\mathbf{if}\;x \leq 0.021:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;x \leq 4.4 \cdot 10^{+152}:\\
\;\;\;\;\cosh x\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if x < 0.0210000000000000013 or 4.3999999999999996e152 < x Initial program 99.9%
Taylor expanded in x around 0
*-commutativeN/A
*-commutativeN/A
associate-/l*N/A
associate-*r*N/A
distribute-lft1-inN/A
+-commutativeN/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
/-lowering-/.f64N/A
sin-lowering-sin.f6489.6%
Simplified89.6%
if 0.0210000000000000013 < x < 4.3999999999999996e152Initial program 100.0%
Taylor expanded in y around 0
Simplified92.2%
*-rgt-identityN/A
cosh-lowering-cosh.f6492.2%
Applied egg-rr92.2%
Final simplification90.0%
(FPCore (x y) :precision binary64 (if (<= x 2.5e-5) (/ (sin y) y) (if (<= x 4.4e+152) (cosh x) (* (sin y) (/ (* (* x x) 0.5) y)))))
double code(double x, double y) {
double tmp;
if (x <= 2.5e-5) {
tmp = sin(y) / y;
} else if (x <= 4.4e+152) {
tmp = cosh(x);
} else {
tmp = sin(y) * (((x * x) * 0.5) / y);
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 2.5d-5) then
tmp = sin(y) / y
else if (x <= 4.4d+152) then
tmp = cosh(x)
else
tmp = sin(y) * (((x * x) * 0.5d0) / y)
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 2.5e-5) {
tmp = Math.sin(y) / y;
} else if (x <= 4.4e+152) {
tmp = Math.cosh(x);
} else {
tmp = Math.sin(y) * (((x * x) * 0.5) / y);
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 2.5e-5: tmp = math.sin(y) / y elif x <= 4.4e+152: tmp = math.cosh(x) else: tmp = math.sin(y) * (((x * x) * 0.5) / y) return tmp
function code(x, y) tmp = 0.0 if (x <= 2.5e-5) tmp = Float64(sin(y) / y); elseif (x <= 4.4e+152) tmp = cosh(x); else tmp = Float64(sin(y) * Float64(Float64(Float64(x * x) * 0.5) / y)); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 2.5e-5) tmp = sin(y) / y; elseif (x <= 4.4e+152) tmp = cosh(x); else tmp = sin(y) * (((x * x) * 0.5) / y); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 2.5e-5], N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision], If[LessEqual[x, 4.4e+152], N[Cosh[x], $MachinePrecision], N[(N[Sin[y], $MachinePrecision] * N[(N[(N[(x * x), $MachinePrecision] * 0.5), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 2.5 \cdot 10^{-5}:\\
\;\;\;\;\frac{\sin y}{y}\\
\mathbf{elif}\;x \leq 4.4 \cdot 10^{+152}:\\
\;\;\;\;\cosh x\\
\mathbf{else}:\\
\;\;\;\;\sin y \cdot \frac{\left(x \cdot x\right) \cdot 0.5}{y}\\
\end{array}
\end{array}
if x < 2.50000000000000012e-5Initial program 99.9%
Taylor expanded in x around 0
/-lowering-/.f64N/A
sin-lowering-sin.f6472.4%
Simplified72.4%
if 2.50000000000000012e-5 < x < 4.3999999999999996e152Initial program 100.0%
Taylor expanded in y around 0
Simplified92.2%
*-rgt-identityN/A
cosh-lowering-cosh.f6492.2%
Applied egg-rr92.2%
if 4.3999999999999996e152 < x Initial program 100.0%
clear-numN/A
associate-/r/N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
div-invN/A
/-lowering-/.f64N/A
cosh-lowering-cosh.f64N/A
sin-lowering-sin.f64100.0%
Applied egg-rr100.0%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6497.1%
Simplified97.1%
Taylor expanded in x around inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6497.1%
Simplified97.1%
Final simplification78.5%
(FPCore (x y)
:precision binary64
(if (<= x 1.75e-5)
(/ (sin y) y)
(if (<= x 1.5e+174)
(cosh x)
(*
(* x x)
(*
(* x x)
(+ 0.041666666666666664 (* -0.006944444444444444 (* y y))))))))
double code(double x, double y) {
double tmp;
if (x <= 1.75e-5) {
tmp = sin(y) / y;
} else if (x <= 1.5e+174) {
tmp = cosh(x);
} else {
tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y))));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 1.75d-5) then
tmp = sin(y) / y
else if (x <= 1.5d+174) then
tmp = cosh(x)
else
tmp = (x * x) * ((x * x) * (0.041666666666666664d0 + ((-0.006944444444444444d0) * (y * y))))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 1.75e-5) {
tmp = Math.sin(y) / y;
} else if (x <= 1.5e+174) {
tmp = Math.cosh(x);
} else {
tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y))));
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 1.75e-5: tmp = math.sin(y) / y elif x <= 1.5e+174: tmp = math.cosh(x) else: tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y)))) return tmp
function code(x, y) tmp = 0.0 if (x <= 1.75e-5) tmp = Float64(sin(y) / y); elseif (x <= 1.5e+174) tmp = cosh(x); else tmp = Float64(Float64(x * x) * Float64(Float64(x * x) * Float64(0.041666666666666664 + Float64(-0.006944444444444444 * Float64(y * y))))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 1.75e-5) tmp = sin(y) / y; elseif (x <= 1.5e+174) tmp = cosh(x); else tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y)))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 1.75e-5], N[(N[Sin[y], $MachinePrecision] / y), $MachinePrecision], If[LessEqual[x, 1.5e+174], N[Cosh[x], $MachinePrecision], N[(N[(x * x), $MachinePrecision] * N[(N[(x * x), $MachinePrecision] * N[(0.041666666666666664 + N[(-0.006944444444444444 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 1.75 \cdot 10^{-5}:\\
\;\;\;\;\frac{\sin y}{y}\\
\mathbf{elif}\;x \leq 1.5 \cdot 10^{+174}:\\
\;\;\;\;\cosh x\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot x\right) \cdot \left(\left(x \cdot x\right) \cdot \left(0.041666666666666664 + -0.006944444444444444 \cdot \left(y \cdot y\right)\right)\right)\\
\end{array}
\end{array}
if x < 1.7499999999999998e-5Initial program 99.9%
Taylor expanded in x around 0
/-lowering-/.f64N/A
sin-lowering-sin.f6472.4%
Simplified72.4%
if 1.7499999999999998e-5 < x < 1.5e174Initial program 100.0%
Taylor expanded in y around 0
Simplified90.8%
*-rgt-identityN/A
cosh-lowering-cosh.f6490.8%
Applied egg-rr90.8%
if 1.5e174 < x Initial program 100.0%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around inf
associate-*r/N/A
associate-*r*N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
sin-lowering-sin.f64100.0%
Simplified100.0%
Taylor expanded in y around 0
+-commutativeN/A
*-commutativeN/A
associate-*r*N/A
distribute-rgt-outN/A
*-lowering-*.f64N/A
metadata-evalN/A
pow-sqrN/A
unpow2N/A
associate-*l*N/A
unpow2N/A
cube-multN/A
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6492.9%
Simplified92.9%
*-commutativeN/A
associate-*r*N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6492.9%
Applied egg-rr92.9%
Final simplification77.7%
(FPCore (x y)
:precision binary64
(if (<= x 6e+175)
(cosh x)
(*
(* x x)
(* (* x x) (+ 0.041666666666666664 (* -0.006944444444444444 (* y y)))))))
double code(double x, double y) {
double tmp;
if (x <= 6e+175) {
tmp = cosh(x);
} else {
tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y))));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 6d+175) then
tmp = cosh(x)
else
tmp = (x * x) * ((x * x) * (0.041666666666666664d0 + ((-0.006944444444444444d0) * (y * y))))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 6e+175) {
tmp = Math.cosh(x);
} else {
tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y))));
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 6e+175: tmp = math.cosh(x) else: tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y)))) return tmp
function code(x, y) tmp = 0.0 if (x <= 6e+175) tmp = cosh(x); else tmp = Float64(Float64(x * x) * Float64(Float64(x * x) * Float64(0.041666666666666664 + Float64(-0.006944444444444444 * Float64(y * y))))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 6e+175) tmp = cosh(x); else tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y)))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 6e+175], N[Cosh[x], $MachinePrecision], N[(N[(x * x), $MachinePrecision] * N[(N[(x * x), $MachinePrecision] * N[(0.041666666666666664 + N[(-0.006944444444444444 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 6 \cdot 10^{+175}:\\
\;\;\;\;\cosh x\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot x\right) \cdot \left(\left(x \cdot x\right) \cdot \left(0.041666666666666664 + -0.006944444444444444 \cdot \left(y \cdot y\right)\right)\right)\\
\end{array}
\end{array}
if x < 6.0000000000000003e175Initial program 99.9%
Taylor expanded in y around 0
Simplified69.1%
*-rgt-identityN/A
cosh-lowering-cosh.f6469.1%
Applied egg-rr69.1%
if 6.0000000000000003e175 < x Initial program 100.0%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around inf
associate-*r/N/A
associate-*r*N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
sin-lowering-sin.f64100.0%
Simplified100.0%
Taylor expanded in y around 0
+-commutativeN/A
*-commutativeN/A
associate-*r*N/A
distribute-rgt-outN/A
*-lowering-*.f64N/A
metadata-evalN/A
pow-sqrN/A
unpow2N/A
associate-*l*N/A
unpow2N/A
cube-multN/A
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6492.9%
Simplified92.9%
*-commutativeN/A
associate-*r*N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6492.9%
Applied egg-rr92.9%
Final simplification71.7%
(FPCore (x y)
:precision binary64
(if (<= x 2e+174)
(/
(+
1.0
(*
(* x x)
(+
0.5
(* (* x x) (+ 0.041666666666666664 (* (* x x) 0.001388888888888889))))))
(/
y
(*
y
(+
1.0
(*
y
(* y (+ -0.16666666666666666 (* (* y y) 0.008333333333333333))))))))
(*
(* x x)
(* (* x x) (+ 0.041666666666666664 (* -0.006944444444444444 (* y y)))))))
double code(double x, double y) {
double tmp;
if (x <= 2e+174) {
tmp = (1.0 + ((x * x) * (0.5 + ((x * x) * (0.041666666666666664 + ((x * x) * 0.001388888888888889)))))) / (y / (y * (1.0 + (y * (y * (-0.16666666666666666 + ((y * y) * 0.008333333333333333)))))));
} else {
tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y))));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 2d+174) then
tmp = (1.0d0 + ((x * x) * (0.5d0 + ((x * x) * (0.041666666666666664d0 + ((x * x) * 0.001388888888888889d0)))))) / (y / (y * (1.0d0 + (y * (y * ((-0.16666666666666666d0) + ((y * y) * 0.008333333333333333d0)))))))
else
tmp = (x * x) * ((x * x) * (0.041666666666666664d0 + ((-0.006944444444444444d0) * (y * y))))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 2e+174) {
tmp = (1.0 + ((x * x) * (0.5 + ((x * x) * (0.041666666666666664 + ((x * x) * 0.001388888888888889)))))) / (y / (y * (1.0 + (y * (y * (-0.16666666666666666 + ((y * y) * 0.008333333333333333)))))));
} else {
tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y))));
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 2e+174: tmp = (1.0 + ((x * x) * (0.5 + ((x * x) * (0.041666666666666664 + ((x * x) * 0.001388888888888889)))))) / (y / (y * (1.0 + (y * (y * (-0.16666666666666666 + ((y * y) * 0.008333333333333333))))))) else: tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y)))) return tmp
function code(x, y) tmp = 0.0 if (x <= 2e+174) tmp = Float64(Float64(1.0 + Float64(Float64(x * x) * Float64(0.5 + Float64(Float64(x * x) * Float64(0.041666666666666664 + Float64(Float64(x * x) * 0.001388888888888889)))))) / Float64(y / Float64(y * Float64(1.0 + Float64(y * Float64(y * Float64(-0.16666666666666666 + Float64(Float64(y * y) * 0.008333333333333333)))))))); else tmp = Float64(Float64(x * x) * Float64(Float64(x * x) * Float64(0.041666666666666664 + Float64(-0.006944444444444444 * Float64(y * y))))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 2e+174) tmp = (1.0 + ((x * x) * (0.5 + ((x * x) * (0.041666666666666664 + ((x * x) * 0.001388888888888889)))))) / (y / (y * (1.0 + (y * (y * (-0.16666666666666666 + ((y * y) * 0.008333333333333333))))))); else tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y)))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 2e+174], N[(N[(1.0 + N[(N[(x * x), $MachinePrecision] * N[(0.5 + N[(N[(x * x), $MachinePrecision] * N[(0.041666666666666664 + N[(N[(x * x), $MachinePrecision] * 0.001388888888888889), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(y / 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]), $MachinePrecision]), $MachinePrecision], N[(N[(x * x), $MachinePrecision] * N[(N[(x * x), $MachinePrecision] * N[(0.041666666666666664 + N[(-0.006944444444444444 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 2 \cdot 10^{+174}:\\
\;\;\;\;\frac{1 + \left(x \cdot x\right) \cdot \left(0.5 + \left(x \cdot x\right) \cdot \left(0.041666666666666664 + \left(x \cdot x\right) \cdot 0.001388888888888889\right)\right)}{\frac{y}{y \cdot \left(1 + y \cdot \left(y \cdot \left(-0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)\right)}}\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot x\right) \cdot \left(\left(x \cdot x\right) \cdot \left(0.041666666666666664 + -0.006944444444444444 \cdot \left(y \cdot y\right)\right)\right)\\
\end{array}
\end{array}
if x < 2.00000000000000014e174Initial program 99.9%
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
cosh-lowering-cosh.f64N/A
/-lowering-/.f64N/A
sin-lowering-sin.f6499.9%
Applied egg-rr99.9%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6490.2%
Simplified90.2%
Taylor expanded in y 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
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6463.9%
Simplified63.9%
if 2.00000000000000014e174 < x Initial program 100.0%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around inf
associate-*r/N/A
associate-*r*N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
sin-lowering-sin.f64100.0%
Simplified100.0%
Taylor expanded in y around 0
+-commutativeN/A
*-commutativeN/A
associate-*r*N/A
distribute-rgt-outN/A
*-lowering-*.f64N/A
metadata-evalN/A
pow-sqrN/A
unpow2N/A
associate-*l*N/A
unpow2N/A
cube-multN/A
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6492.9%
Simplified92.9%
*-commutativeN/A
associate-*r*N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6492.9%
Applied egg-rr92.9%
Final simplification67.1%
(FPCore (x y)
:precision binary64
(if (<= x 7.2e+51)
(*
(*
y
(+
1.0
(* y (* y (+ -0.16666666666666666 (* (* y y) 0.008333333333333333))))))
(/ (+ 1.0 (* (* x x) 0.5)) y))
(if (<= x 8e+176)
(+
1.0
(*
x
(*
x
(+
0.5
(*
x
(* x (+ 0.041666666666666664 (* x (* x 0.001388888888888889)))))))))
(*
(* x x)
(*
(* x x)
(+ 0.041666666666666664 (* -0.006944444444444444 (* y y))))))))
double code(double x, double y) {
double tmp;
if (x <= 7.2e+51) {
tmp = (y * (1.0 + (y * (y * (-0.16666666666666666 + ((y * y) * 0.008333333333333333)))))) * ((1.0 + ((x * x) * 0.5)) / y);
} else if (x <= 8e+176) {
tmp = 1.0 + (x * (x * (0.5 + (x * (x * (0.041666666666666664 + (x * (x * 0.001388888888888889))))))));
} else {
tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y))));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 7.2d+51) then
tmp = (y * (1.0d0 + (y * (y * ((-0.16666666666666666d0) + ((y * y) * 0.008333333333333333d0)))))) * ((1.0d0 + ((x * x) * 0.5d0)) / y)
else if (x <= 8d+176) then
tmp = 1.0d0 + (x * (x * (0.5d0 + (x * (x * (0.041666666666666664d0 + (x * (x * 0.001388888888888889d0))))))))
else
tmp = (x * x) * ((x * x) * (0.041666666666666664d0 + ((-0.006944444444444444d0) * (y * y))))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 7.2e+51) {
tmp = (y * (1.0 + (y * (y * (-0.16666666666666666 + ((y * y) * 0.008333333333333333)))))) * ((1.0 + ((x * x) * 0.5)) / y);
} else if (x <= 8e+176) {
tmp = 1.0 + (x * (x * (0.5 + (x * (x * (0.041666666666666664 + (x * (x * 0.001388888888888889))))))));
} else {
tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y))));
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 7.2e+51: tmp = (y * (1.0 + (y * (y * (-0.16666666666666666 + ((y * y) * 0.008333333333333333)))))) * ((1.0 + ((x * x) * 0.5)) / y) elif x <= 8e+176: tmp = 1.0 + (x * (x * (0.5 + (x * (x * (0.041666666666666664 + (x * (x * 0.001388888888888889)))))))) else: tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y)))) return tmp
function code(x, y) tmp = 0.0 if (x <= 7.2e+51) tmp = Float64(Float64(y * Float64(1.0 + Float64(y * Float64(y * Float64(-0.16666666666666666 + Float64(Float64(y * y) * 0.008333333333333333)))))) * Float64(Float64(1.0 + Float64(Float64(x * x) * 0.5)) / y)); elseif (x <= 8e+176) tmp = Float64(1.0 + Float64(x * Float64(x * Float64(0.5 + Float64(x * Float64(x * Float64(0.041666666666666664 + Float64(x * Float64(x * 0.001388888888888889))))))))); else tmp = Float64(Float64(x * x) * Float64(Float64(x * x) * Float64(0.041666666666666664 + Float64(-0.006944444444444444 * Float64(y * y))))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 7.2e+51) tmp = (y * (1.0 + (y * (y * (-0.16666666666666666 + ((y * y) * 0.008333333333333333)))))) * ((1.0 + ((x * x) * 0.5)) / y); elseif (x <= 8e+176) tmp = 1.0 + (x * (x * (0.5 + (x * (x * (0.041666666666666664 + (x * (x * 0.001388888888888889)))))))); else tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y)))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 7.2e+51], 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] * N[(N[(1.0 + N[(N[(x * x), $MachinePrecision] * 0.5), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 8e+176], N[(1.0 + N[(x * N[(x * N[(0.5 + N[(x * N[(x * N[(0.041666666666666664 + N[(x * N[(x * 0.001388888888888889), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x * x), $MachinePrecision] * N[(N[(x * x), $MachinePrecision] * N[(0.041666666666666664 + N[(-0.006944444444444444 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 7.2 \cdot 10^{+51}:\\
\;\;\;\;\left(y \cdot \left(1 + y \cdot \left(y \cdot \left(-0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)\right)\right) \cdot \frac{1 + \left(x \cdot x\right) \cdot 0.5}{y}\\
\mathbf{elif}\;x \leq 8 \cdot 10^{+176}:\\
\;\;\;\;1 + x \cdot \left(x \cdot \left(0.5 + x \cdot \left(x \cdot \left(0.041666666666666664 + x \cdot \left(x \cdot 0.001388888888888889\right)\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot x\right) \cdot \left(\left(x \cdot x\right) \cdot \left(0.041666666666666664 + -0.006944444444444444 \cdot \left(y \cdot y\right)\right)\right)\\
\end{array}
\end{array}
if x < 7.20000000000000022e51Initial program 99.9%
clear-numN/A
associate-/r/N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
div-invN/A
/-lowering-/.f64N/A
cosh-lowering-cosh.f64N/A
sin-lowering-sin.f6499.8%
Applied egg-rr99.8%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6485.1%
Simplified85.1%
Taylor expanded in y 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
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6459.2%
Simplified59.2%
if 7.20000000000000022e51 < x < 8.0000000000000001e176Initial program 100.0%
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
cosh-lowering-cosh.f64N/A
/-lowering-/.f64N/A
sin-lowering-sin.f64100.0%
Applied egg-rr100.0%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64100.0%
Simplified100.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
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f6488.9%
Simplified88.9%
if 8.0000000000000001e176 < x Initial program 100.0%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around inf
associate-*r/N/A
associate-*r*N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
sin-lowering-sin.f64100.0%
Simplified100.0%
Taylor expanded in y around 0
+-commutativeN/A
*-commutativeN/A
associate-*r*N/A
distribute-rgt-outN/A
*-lowering-*.f64N/A
metadata-evalN/A
pow-sqrN/A
unpow2N/A
associate-*l*N/A
unpow2N/A
cube-multN/A
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6492.9%
Simplified92.9%
*-commutativeN/A
associate-*r*N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6492.9%
Applied egg-rr92.9%
Final simplification66.1%
(FPCore (x y)
:precision binary64
(let* ((t_0 (* x (* x x))))
(if (<= x 1.05e+21)
(* y (/ (+ 1.0 (* (* x x) 0.5)) y))
(if (<= x 1e+230)
(/ (* y (* x (* 0.041666666666666664 t_0))) y)
(*
(* x t_0)
(+ 0.041666666666666664 (* y (* y -0.006944444444444444))))))))
double code(double x, double y) {
double t_0 = x * (x * x);
double tmp;
if (x <= 1.05e+21) {
tmp = y * ((1.0 + ((x * x) * 0.5)) / y);
} else if (x <= 1e+230) {
tmp = (y * (x * (0.041666666666666664 * t_0))) / y;
} else {
tmp = (x * t_0) * (0.041666666666666664 + (y * (y * -0.006944444444444444)));
}
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 = x * (x * x)
if (x <= 1.05d+21) then
tmp = y * ((1.0d0 + ((x * x) * 0.5d0)) / y)
else if (x <= 1d+230) then
tmp = (y * (x * (0.041666666666666664d0 * t_0))) / y
else
tmp = (x * t_0) * (0.041666666666666664d0 + (y * (y * (-0.006944444444444444d0))))
end if
code = tmp
end function
public static double code(double x, double y) {
double t_0 = x * (x * x);
double tmp;
if (x <= 1.05e+21) {
tmp = y * ((1.0 + ((x * x) * 0.5)) / y);
} else if (x <= 1e+230) {
tmp = (y * (x * (0.041666666666666664 * t_0))) / y;
} else {
tmp = (x * t_0) * (0.041666666666666664 + (y * (y * -0.006944444444444444)));
}
return tmp;
}
def code(x, y): t_0 = x * (x * x) tmp = 0 if x <= 1.05e+21: tmp = y * ((1.0 + ((x * x) * 0.5)) / y) elif x <= 1e+230: tmp = (y * (x * (0.041666666666666664 * t_0))) / y else: tmp = (x * t_0) * (0.041666666666666664 + (y * (y * -0.006944444444444444))) return tmp
function code(x, y) t_0 = Float64(x * Float64(x * x)) tmp = 0.0 if (x <= 1.05e+21) tmp = Float64(y * Float64(Float64(1.0 + Float64(Float64(x * x) * 0.5)) / y)); elseif (x <= 1e+230) tmp = Float64(Float64(y * Float64(x * Float64(0.041666666666666664 * t_0))) / y); else tmp = Float64(Float64(x * t_0) * Float64(0.041666666666666664 + Float64(y * Float64(y * -0.006944444444444444)))); end return tmp end
function tmp_2 = code(x, y) t_0 = x * (x * x); tmp = 0.0; if (x <= 1.05e+21) tmp = y * ((1.0 + ((x * x) * 0.5)) / y); elseif (x <= 1e+230) tmp = (y * (x * (0.041666666666666664 * t_0))) / y; else tmp = (x * t_0) * (0.041666666666666664 + (y * (y * -0.006944444444444444))); end tmp_2 = tmp; end
code[x_, y_] := Block[{t$95$0 = N[(x * N[(x * x), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, 1.05e+21], N[(y * N[(N[(1.0 + N[(N[(x * x), $MachinePrecision] * 0.5), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1e+230], N[(N[(y * N[(x * N[(0.041666666666666664 * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(N[(x * t$95$0), $MachinePrecision] * N[(0.041666666666666664 + N[(y * N[(y * -0.006944444444444444), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x \cdot \left(x \cdot x\right)\\
\mathbf{if}\;x \leq 1.05 \cdot 10^{+21}:\\
\;\;\;\;y \cdot \frac{1 + \left(x \cdot x\right) \cdot 0.5}{y}\\
\mathbf{elif}\;x \leq 10^{+230}:\\
\;\;\;\;\frac{y \cdot \left(x \cdot \left(0.041666666666666664 \cdot t\_0\right)\right)}{y}\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot t\_0\right) \cdot \left(0.041666666666666664 + y \cdot \left(y \cdot -0.006944444444444444\right)\right)\\
\end{array}
\end{array}
if x < 1.05e21Initial program 99.9%
clear-numN/A
associate-/r/N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
div-invN/A
/-lowering-/.f64N/A
cosh-lowering-cosh.f64N/A
sin-lowering-sin.f6499.8%
Applied egg-rr99.8%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6488.5%
Simplified88.5%
Taylor expanded in y around 0
Simplified55.3%
if 1.05e21 < x < 1.0000000000000001e230Initial program 100.0%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f6461.9%
Simplified61.9%
Taylor expanded in x around inf
associate-*r/N/A
associate-*r*N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
sin-lowering-sin.f6461.9%
Simplified61.9%
Taylor expanded in y around 0
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
associate-*r*N/A
unpow2N/A
unpow3N/A
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6466.4%
Simplified66.4%
if 1.0000000000000001e230 < x Initial program 100.0%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around inf
associate-*r/N/A
associate-*r*N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
sin-lowering-sin.f64100.0%
Simplified100.0%
Taylor expanded in y around 0
+-commutativeN/A
*-commutativeN/A
associate-*r*N/A
distribute-rgt-outN/A
*-lowering-*.f64N/A
metadata-evalN/A
pow-sqrN/A
unpow2N/A
associate-*l*N/A
unpow2N/A
cube-multN/A
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6495.7%
Simplified95.7%
Final simplification60.7%
(FPCore (x y)
:precision binary64
(if (<= x 1e+175)
(+
1.0
(*
x
(*
x
(+
0.5
(*
x
(* x (+ 0.041666666666666664 (* x (* x 0.001388888888888889)))))))))
(*
(* x x)
(* (* x x) (+ 0.041666666666666664 (* -0.006944444444444444 (* y y)))))))
double code(double x, double y) {
double tmp;
if (x <= 1e+175) {
tmp = 1.0 + (x * (x * (0.5 + (x * (x * (0.041666666666666664 + (x * (x * 0.001388888888888889))))))));
} else {
tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y))));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 1d+175) then
tmp = 1.0d0 + (x * (x * (0.5d0 + (x * (x * (0.041666666666666664d0 + (x * (x * 0.001388888888888889d0))))))))
else
tmp = (x * x) * ((x * x) * (0.041666666666666664d0 + ((-0.006944444444444444d0) * (y * y))))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 1e+175) {
tmp = 1.0 + (x * (x * (0.5 + (x * (x * (0.041666666666666664 + (x * (x * 0.001388888888888889))))))));
} else {
tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y))));
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 1e+175: tmp = 1.0 + (x * (x * (0.5 + (x * (x * (0.041666666666666664 + (x * (x * 0.001388888888888889)))))))) else: tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y)))) return tmp
function code(x, y) tmp = 0.0 if (x <= 1e+175) tmp = Float64(1.0 + Float64(x * Float64(x * Float64(0.5 + Float64(x * Float64(x * Float64(0.041666666666666664 + Float64(x * Float64(x * 0.001388888888888889))))))))); else tmp = Float64(Float64(x * x) * Float64(Float64(x * x) * Float64(0.041666666666666664 + Float64(-0.006944444444444444 * Float64(y * y))))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 1e+175) tmp = 1.0 + (x * (x * (0.5 + (x * (x * (0.041666666666666664 + (x * (x * 0.001388888888888889)))))))); else tmp = (x * x) * ((x * x) * (0.041666666666666664 + (-0.006944444444444444 * (y * y)))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 1e+175], N[(1.0 + N[(x * N[(x * N[(0.5 + N[(x * N[(x * N[(0.041666666666666664 + N[(x * N[(x * 0.001388888888888889), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x * x), $MachinePrecision] * N[(N[(x * x), $MachinePrecision] * N[(0.041666666666666664 + N[(-0.006944444444444444 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 10^{+175}:\\
\;\;\;\;1 + x \cdot \left(x \cdot \left(0.5 + x \cdot \left(x \cdot \left(0.041666666666666664 + x \cdot \left(x \cdot 0.001388888888888889\right)\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot x\right) \cdot \left(\left(x \cdot x\right) \cdot \left(0.041666666666666664 + -0.006944444444444444 \cdot \left(y \cdot y\right)\right)\right)\\
\end{array}
\end{array}
if x < 9.9999999999999994e174Initial program 99.9%
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
cosh-lowering-cosh.f64N/A
/-lowering-/.f64N/A
sin-lowering-sin.f6499.9%
Applied egg-rr99.9%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6490.2%
Simplified90.2%
Taylor expanded in y around 0
+-lowering-+.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f6460.3%
Simplified60.3%
if 9.9999999999999994e174 < x Initial program 100.0%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64100.0%
Simplified100.0%
Taylor expanded in x around inf
associate-*r/N/A
associate-*r*N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
sin-lowering-sin.f64100.0%
Simplified100.0%
Taylor expanded in y around 0
+-commutativeN/A
*-commutativeN/A
associate-*r*N/A
distribute-rgt-outN/A
*-lowering-*.f64N/A
metadata-evalN/A
pow-sqrN/A
unpow2N/A
associate-*l*N/A
unpow2N/A
cube-multN/A
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6492.9%
Simplified92.9%
*-commutativeN/A
associate-*r*N/A
associate-*r*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f6492.9%
Applied egg-rr92.9%
Final simplification63.9%
(FPCore (x y)
:precision binary64
(if (<= y 3.95e+90)
(+ 1.0 (* x (* x (+ 0.5 (* (* x x) 0.041666666666666664)))))
(if (<= y 2.06e+158)
(* (* y (* y -0.006944444444444444)) (* (* x x) (* x x)))
(/ (* y (* x (* 0.041666666666666664 (* x (* x x))))) y))))
double code(double x, double y) {
double tmp;
if (y <= 3.95e+90) {
tmp = 1.0 + (x * (x * (0.5 + ((x * x) * 0.041666666666666664))));
} else if (y <= 2.06e+158) {
tmp = (y * (y * -0.006944444444444444)) * ((x * x) * (x * x));
} else {
tmp = (y * (x * (0.041666666666666664 * (x * (x * x))))) / 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.95d+90) then
tmp = 1.0d0 + (x * (x * (0.5d0 + ((x * x) * 0.041666666666666664d0))))
else if (y <= 2.06d+158) then
tmp = (y * (y * (-0.006944444444444444d0))) * ((x * x) * (x * x))
else
tmp = (y * (x * (0.041666666666666664d0 * (x * (x * x))))) / y
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= 3.95e+90) {
tmp = 1.0 + (x * (x * (0.5 + ((x * x) * 0.041666666666666664))));
} else if (y <= 2.06e+158) {
tmp = (y * (y * -0.006944444444444444)) * ((x * x) * (x * x));
} else {
tmp = (y * (x * (0.041666666666666664 * (x * (x * x))))) / y;
}
return tmp;
}
def code(x, y): tmp = 0 if y <= 3.95e+90: tmp = 1.0 + (x * (x * (0.5 + ((x * x) * 0.041666666666666664)))) elif y <= 2.06e+158: tmp = (y * (y * -0.006944444444444444)) * ((x * x) * (x * x)) else: tmp = (y * (x * (0.041666666666666664 * (x * (x * x))))) / y return tmp
function code(x, y) tmp = 0.0 if (y <= 3.95e+90) tmp = Float64(1.0 + Float64(x * Float64(x * Float64(0.5 + Float64(Float64(x * x) * 0.041666666666666664))))); elseif (y <= 2.06e+158) tmp = Float64(Float64(y * Float64(y * -0.006944444444444444)) * Float64(Float64(x * x) * Float64(x * x))); else tmp = Float64(Float64(y * Float64(x * Float64(0.041666666666666664 * Float64(x * Float64(x * x))))) / y); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= 3.95e+90) tmp = 1.0 + (x * (x * (0.5 + ((x * x) * 0.041666666666666664)))); elseif (y <= 2.06e+158) tmp = (y * (y * -0.006944444444444444)) * ((x * x) * (x * x)); else tmp = (y * (x * (0.041666666666666664 * (x * (x * x))))) / y; end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, 3.95e+90], N[(1.0 + N[(x * N[(x * N[(0.5 + N[(N[(x * x), $MachinePrecision] * 0.041666666666666664), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.06e+158], N[(N[(y * N[(y * -0.006944444444444444), $MachinePrecision]), $MachinePrecision] * N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y * N[(x * N[(0.041666666666666664 * N[(x * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq 3.95 \cdot 10^{+90}:\\
\;\;\;\;1 + x \cdot \left(x \cdot \left(0.5 + \left(x \cdot x\right) \cdot 0.041666666666666664\right)\right)\\
\mathbf{elif}\;y \leq 2.06 \cdot 10^{+158}:\\
\;\;\;\;\left(y \cdot \left(y \cdot -0.006944444444444444\right)\right) \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{y \cdot \left(x \cdot \left(0.041666666666666664 \cdot \left(x \cdot \left(x \cdot x\right)\right)\right)\right)}{y}\\
\end{array}
\end{array}
if y < 3.9499999999999998e90Initial program 99.9%
Taylor expanded in y around 0
Simplified76.5%
Taylor expanded in x 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-*.f6465.0%
Simplified65.0%
if 3.9499999999999998e90 < y < 2.06000000000000004e158Initial program 99.9%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f6492.4%
Simplified92.4%
Taylor expanded in x around inf
associate-*r/N/A
associate-*r*N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
sin-lowering-sin.f6455.7%
Simplified55.7%
Taylor expanded in y around 0
+-commutativeN/A
*-commutativeN/A
associate-*r*N/A
distribute-rgt-outN/A
*-lowering-*.f64N/A
metadata-evalN/A
pow-sqrN/A
unpow2N/A
associate-*l*N/A
unpow2N/A
cube-multN/A
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6440.9%
Simplified40.9%
Taylor expanded in y around inf
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
metadata-evalN/A
associate-*r*N/A
*-lowering-*.f64N/A
metadata-evalN/A
pow-sqrN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
associate-*r*N/A
metadata-evalN/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6440.9%
Simplified40.9%
if 2.06000000000000004e158 < y Initial program 99.7%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f6479.6%
Simplified79.6%
Taylor expanded in x around inf
associate-*r/N/A
associate-*r*N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
sin-lowering-sin.f6425.2%
Simplified25.2%
Taylor expanded in y around 0
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
associate-*r*N/A
unpow2N/A
unpow3N/A
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6424.7%
Simplified24.7%
Final simplification59.2%
(FPCore (x y)
:precision binary64
(if (<= y 3.95e+90)
(+ 1.0 (* x (* x (+ 0.5 (* (* x x) 0.041666666666666664)))))
(if (<= y 1.15e+203)
(* (* y (* y -0.006944444444444444)) (* (* x x) (* x x)))
(* x (* 0.041666666666666664 (* x (* x x)))))))
double code(double x, double y) {
double tmp;
if (y <= 3.95e+90) {
tmp = 1.0 + (x * (x * (0.5 + ((x * x) * 0.041666666666666664))));
} else if (y <= 1.15e+203) {
tmp = (y * (y * -0.006944444444444444)) * ((x * x) * (x * x));
} else {
tmp = x * (0.041666666666666664 * (x * (x * x)));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= 3.95d+90) then
tmp = 1.0d0 + (x * (x * (0.5d0 + ((x * x) * 0.041666666666666664d0))))
else if (y <= 1.15d+203) then
tmp = (y * (y * (-0.006944444444444444d0))) * ((x * x) * (x * x))
else
tmp = x * (0.041666666666666664d0 * (x * (x * x)))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= 3.95e+90) {
tmp = 1.0 + (x * (x * (0.5 + ((x * x) * 0.041666666666666664))));
} else if (y <= 1.15e+203) {
tmp = (y * (y * -0.006944444444444444)) * ((x * x) * (x * x));
} else {
tmp = x * (0.041666666666666664 * (x * (x * x)));
}
return tmp;
}
def code(x, y): tmp = 0 if y <= 3.95e+90: tmp = 1.0 + (x * (x * (0.5 + ((x * x) * 0.041666666666666664)))) elif y <= 1.15e+203: tmp = (y * (y * -0.006944444444444444)) * ((x * x) * (x * x)) else: tmp = x * (0.041666666666666664 * (x * (x * x))) return tmp
function code(x, y) tmp = 0.0 if (y <= 3.95e+90) tmp = Float64(1.0 + Float64(x * Float64(x * Float64(0.5 + Float64(Float64(x * x) * 0.041666666666666664))))); elseif (y <= 1.15e+203) tmp = Float64(Float64(y * Float64(y * -0.006944444444444444)) * Float64(Float64(x * x) * Float64(x * x))); else tmp = Float64(x * Float64(0.041666666666666664 * Float64(x * Float64(x * x)))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= 3.95e+90) tmp = 1.0 + (x * (x * (0.5 + ((x * x) * 0.041666666666666664)))); elseif (y <= 1.15e+203) tmp = (y * (y * -0.006944444444444444)) * ((x * x) * (x * x)); else tmp = x * (0.041666666666666664 * (x * (x * x))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, 3.95e+90], N[(1.0 + N[(x * N[(x * N[(0.5 + N[(N[(x * x), $MachinePrecision] * 0.041666666666666664), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.15e+203], N[(N[(y * N[(y * -0.006944444444444444), $MachinePrecision]), $MachinePrecision] * N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(0.041666666666666664 * N[(x * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq 3.95 \cdot 10^{+90}:\\
\;\;\;\;1 + x \cdot \left(x \cdot \left(0.5 + \left(x \cdot x\right) \cdot 0.041666666666666664\right)\right)\\
\mathbf{elif}\;y \leq 1.15 \cdot 10^{+203}:\\
\;\;\;\;\left(y \cdot \left(y \cdot -0.006944444444444444\right)\right) \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(0.041666666666666664 \cdot \left(x \cdot \left(x \cdot x\right)\right)\right)\\
\end{array}
\end{array}
if y < 3.9499999999999998e90Initial program 99.9%
Taylor expanded in y around 0
Simplified76.5%
Taylor expanded in x 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-*.f6465.0%
Simplified65.0%
if 3.9499999999999998e90 < y < 1.15e203Initial program 99.9%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f6481.5%
Simplified81.5%
Taylor expanded in x around inf
associate-*r/N/A
associate-*r*N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
sin-lowering-sin.f6440.7%
Simplified40.7%
Taylor expanded in y around 0
+-commutativeN/A
*-commutativeN/A
associate-*r*N/A
distribute-rgt-outN/A
*-lowering-*.f64N/A
metadata-evalN/A
pow-sqrN/A
unpow2N/A
associate-*l*N/A
unpow2N/A
cube-multN/A
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6434.8%
Simplified34.8%
Taylor expanded in y around inf
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
metadata-evalN/A
associate-*r*N/A
*-lowering-*.f64N/A
metadata-evalN/A
pow-sqrN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
associate-*r*N/A
metadata-evalN/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6434.8%
Simplified34.8%
if 1.15e203 < y Initial program 99.6%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f6485.7%
Simplified85.7%
Taylor expanded in y around 0
Simplified16.8%
Taylor expanded in x around inf
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
associate-*r*N/A
unpow2N/A
unpow3N/A
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6419.1%
Simplified19.1%
Final simplification58.8%
(FPCore (x y)
:precision binary64
(if (<= y 3.95e+90)
(* y (/ (+ 1.0 (* (* x x) 0.5)) y))
(if (<= y 1.15e+203)
(* (* y (* y -0.006944444444444444)) (* (* x x) (* x x)))
(* x (* 0.041666666666666664 (* x (* x x)))))))
double code(double x, double y) {
double tmp;
if (y <= 3.95e+90) {
tmp = y * ((1.0 + ((x * x) * 0.5)) / y);
} else if (y <= 1.15e+203) {
tmp = (y * (y * -0.006944444444444444)) * ((x * x) * (x * x));
} else {
tmp = x * (0.041666666666666664 * (x * (x * x)));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (y <= 3.95d+90) then
tmp = y * ((1.0d0 + ((x * x) * 0.5d0)) / y)
else if (y <= 1.15d+203) then
tmp = (y * (y * (-0.006944444444444444d0))) * ((x * x) * (x * x))
else
tmp = x * (0.041666666666666664d0 * (x * (x * x)))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (y <= 3.95e+90) {
tmp = y * ((1.0 + ((x * x) * 0.5)) / y);
} else if (y <= 1.15e+203) {
tmp = (y * (y * -0.006944444444444444)) * ((x * x) * (x * x));
} else {
tmp = x * (0.041666666666666664 * (x * (x * x)));
}
return tmp;
}
def code(x, y): tmp = 0 if y <= 3.95e+90: tmp = y * ((1.0 + ((x * x) * 0.5)) / y) elif y <= 1.15e+203: tmp = (y * (y * -0.006944444444444444)) * ((x * x) * (x * x)) else: tmp = x * (0.041666666666666664 * (x * (x * x))) return tmp
function code(x, y) tmp = 0.0 if (y <= 3.95e+90) tmp = Float64(y * Float64(Float64(1.0 + Float64(Float64(x * x) * 0.5)) / y)); elseif (y <= 1.15e+203) tmp = Float64(Float64(y * Float64(y * -0.006944444444444444)) * Float64(Float64(x * x) * Float64(x * x))); else tmp = Float64(x * Float64(0.041666666666666664 * Float64(x * Float64(x * x)))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (y <= 3.95e+90) tmp = y * ((1.0 + ((x * x) * 0.5)) / y); elseif (y <= 1.15e+203) tmp = (y * (y * -0.006944444444444444)) * ((x * x) * (x * x)); else tmp = x * (0.041666666666666664 * (x * (x * x))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[y, 3.95e+90], N[(y * N[(N[(1.0 + N[(N[(x * x), $MachinePrecision] * 0.5), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.15e+203], N[(N[(y * N[(y * -0.006944444444444444), $MachinePrecision]), $MachinePrecision] * N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(0.041666666666666664 * N[(x * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq 3.95 \cdot 10^{+90}:\\
\;\;\;\;y \cdot \frac{1 + \left(x \cdot x\right) \cdot 0.5}{y}\\
\mathbf{elif}\;y \leq 1.15 \cdot 10^{+203}:\\
\;\;\;\;\left(y \cdot \left(y \cdot -0.006944444444444444\right)\right) \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(0.041666666666666664 \cdot \left(x \cdot \left(x \cdot x\right)\right)\right)\\
\end{array}
\end{array}
if y < 3.9499999999999998e90Initial program 99.9%
clear-numN/A
associate-/r/N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
div-invN/A
/-lowering-/.f64N/A
cosh-lowering-cosh.f64N/A
sin-lowering-sin.f6499.9%
Applied egg-rr99.9%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6484.8%
Simplified84.8%
Taylor expanded in y around 0
Simplified63.3%
if 3.9499999999999998e90 < y < 1.15e203Initial program 99.9%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f6481.5%
Simplified81.5%
Taylor expanded in x around inf
associate-*r/N/A
associate-*r*N/A
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
*-commutativeN/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
sin-lowering-sin.f6440.7%
Simplified40.7%
Taylor expanded in y around 0
+-commutativeN/A
*-commutativeN/A
associate-*r*N/A
distribute-rgt-outN/A
*-lowering-*.f64N/A
metadata-evalN/A
pow-sqrN/A
unpow2N/A
associate-*l*N/A
unpow2N/A
cube-multN/A
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6434.8%
Simplified34.8%
Taylor expanded in y around inf
*-commutativeN/A
associate-*r*N/A
*-commutativeN/A
metadata-evalN/A
associate-*r*N/A
*-lowering-*.f64N/A
metadata-evalN/A
pow-sqrN/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
associate-*r*N/A
metadata-evalN/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
*-lowering-*.f6434.8%
Simplified34.8%
if 1.15e203 < y Initial program 99.6%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f6485.7%
Simplified85.7%
Taylor expanded in y around 0
Simplified16.8%
Taylor expanded in x around inf
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
associate-*r*N/A
unpow2N/A
unpow3N/A
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6419.1%
Simplified19.1%
Final simplification57.4%
(FPCore (x y) :precision binary64 (if (<= x 1.5e+20) (* y (/ (+ 1.0 (* (* x x) 0.5)) y)) (* x (* 0.041666666666666664 (* x (* x x))))))
double code(double x, double y) {
double tmp;
if (x <= 1.5e+20) {
tmp = y * ((1.0 + ((x * x) * 0.5)) / y);
} else {
tmp = x * (0.041666666666666664 * (x * (x * x)));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 1.5d+20) then
tmp = y * ((1.0d0 + ((x * x) * 0.5d0)) / y)
else
tmp = x * (0.041666666666666664d0 * (x * (x * x)))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 1.5e+20) {
tmp = y * ((1.0 + ((x * x) * 0.5)) / y);
} else {
tmp = x * (0.041666666666666664 * (x * (x * x)));
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 1.5e+20: tmp = y * ((1.0 + ((x * x) * 0.5)) / y) else: tmp = x * (0.041666666666666664 * (x * (x * x))) return tmp
function code(x, y) tmp = 0.0 if (x <= 1.5e+20) tmp = Float64(y * Float64(Float64(1.0 + Float64(Float64(x * x) * 0.5)) / y)); else tmp = Float64(x * Float64(0.041666666666666664 * Float64(x * Float64(x * x)))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 1.5e+20) tmp = y * ((1.0 + ((x * x) * 0.5)) / y); else tmp = x * (0.041666666666666664 * (x * (x * x))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 1.5e+20], N[(y * N[(N[(1.0 + N[(N[(x * x), $MachinePrecision] * 0.5), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(x * N[(0.041666666666666664 * N[(x * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 1.5 \cdot 10^{+20}:\\
\;\;\;\;y \cdot \frac{1 + \left(x \cdot x\right) \cdot 0.5}{y}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(0.041666666666666664 \cdot \left(x \cdot \left(x \cdot x\right)\right)\right)\\
\end{array}
\end{array}
if x < 1.5e20Initial program 99.9%
clear-numN/A
associate-/r/N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
*-commutativeN/A
div-invN/A
/-lowering-/.f64N/A
cosh-lowering-cosh.f64N/A
sin-lowering-sin.f6499.8%
Applied egg-rr99.8%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6488.5%
Simplified88.5%
Taylor expanded in y around 0
Simplified55.3%
if 1.5e20 < x Initial program 100.0%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f6475.8%
Simplified75.8%
Taylor expanded in y around 0
Simplified56.9%
Taylor expanded in x around inf
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
associate-*r*N/A
unpow2N/A
unpow3N/A
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6456.9%
Simplified56.9%
Final simplification55.7%
(FPCore (x y) :precision binary64 (if (<= x 82.0) (+ 1.0 (* (* x x) 0.5)) (* x (* 0.041666666666666664 (* x (* x x))))))
double code(double x, double y) {
double tmp;
if (x <= 82.0) {
tmp = 1.0 + ((x * x) * 0.5);
} else {
tmp = x * (0.041666666666666664 * (x * (x * x)));
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 82.0d0) then
tmp = 1.0d0 + ((x * x) * 0.5d0)
else
tmp = x * (0.041666666666666664d0 * (x * (x * x)))
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 82.0) {
tmp = 1.0 + ((x * x) * 0.5);
} else {
tmp = x * (0.041666666666666664 * (x * (x * x)));
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 82.0: tmp = 1.0 + ((x * x) * 0.5) else: tmp = x * (0.041666666666666664 * (x * (x * x))) return tmp
function code(x, y) tmp = 0.0 if (x <= 82.0) tmp = Float64(1.0 + Float64(Float64(x * x) * 0.5)); else tmp = Float64(x * Float64(0.041666666666666664 * Float64(x * Float64(x * x)))); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 82.0) tmp = 1.0 + ((x * x) * 0.5); else tmp = x * (0.041666666666666664 * (x * (x * x))); end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 82.0], N[(1.0 + N[(N[(x * x), $MachinePrecision] * 0.5), $MachinePrecision]), $MachinePrecision], N[(x * N[(0.041666666666666664 * N[(x * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 82:\\
\;\;\;\;1 + \left(x \cdot x\right) \cdot 0.5\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(0.041666666666666664 \cdot \left(x \cdot \left(x \cdot x\right)\right)\right)\\
\end{array}
\end{array}
if x < 82Initial program 99.8%
Taylor expanded in y around 0
Simplified63.7%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6453.3%
Simplified53.3%
if 82 < x Initial program 100.0%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
unpow2N/A
associate-*l*N/A
*-lowering-*.f64N/A
*-lowering-*.f6468.5%
Simplified68.5%
Taylor expanded in y around 0
Simplified51.6%
Taylor expanded in x around inf
metadata-evalN/A
pow-sqrN/A
associate-*l*N/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
*-lowering-*.f64N/A
associate-*r*N/A
unpow2N/A
unpow3N/A
*-lowering-*.f64N/A
cube-multN/A
unpow2N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6451.6%
Simplified51.6%
Final simplification52.8%
(FPCore (x y) :precision binary64 (if (<= x 40.0) 1.0 (* (* x x) 0.5)))
double code(double x, double y) {
double tmp;
if (x <= 40.0) {
tmp = 1.0;
} else {
tmp = (x * x) * 0.5;
}
return tmp;
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8) :: tmp
if (x <= 40.0d0) then
tmp = 1.0d0
else
tmp = (x * x) * 0.5d0
end if
code = tmp
end function
public static double code(double x, double y) {
double tmp;
if (x <= 40.0) {
tmp = 1.0;
} else {
tmp = (x * x) * 0.5;
}
return tmp;
}
def code(x, y): tmp = 0 if x <= 40.0: tmp = 1.0 else: tmp = (x * x) * 0.5 return tmp
function code(x, y) tmp = 0.0 if (x <= 40.0) tmp = 1.0; else tmp = Float64(Float64(x * x) * 0.5); end return tmp end
function tmp_2 = code(x, y) tmp = 0.0; if (x <= 40.0) tmp = 1.0; else tmp = (x * x) * 0.5; end tmp_2 = tmp; end
code[x_, y_] := If[LessEqual[x, 40.0], 1.0, N[(N[(x * x), $MachinePrecision] * 0.5), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 40:\\
\;\;\;\;1\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot x\right) \cdot 0.5\\
\end{array}
\end{array}
if x < 40Initial program 99.8%
Taylor expanded in y around 0
Simplified63.7%
Taylor expanded in x around 0
Simplified41.6%
if 40 < x Initial program 100.0%
Taylor expanded in y around 0
Simplified81.4%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6433.8%
Simplified33.8%
Taylor expanded in x around inf
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6433.8%
Simplified33.8%
Final simplification39.5%
(FPCore (x y) :precision binary64 (+ 1.0 (* (* x x) 0.5)))
double code(double x, double y) {
return 1.0 + ((x * x) * 0.5);
}
real(8) function code(x, y)
real(8), intent (in) :: x
real(8), intent (in) :: y
code = 1.0d0 + ((x * x) * 0.5d0)
end function
public static double code(double x, double y) {
return 1.0 + ((x * x) * 0.5);
}
def code(x, y): return 1.0 + ((x * x) * 0.5)
function code(x, y) return Float64(1.0 + Float64(Float64(x * x) * 0.5)) end
function tmp = code(x, y) tmp = 1.0 + ((x * x) * 0.5); end
code[x_, y_] := N[(1.0 + N[(N[(x * x), $MachinePrecision] * 0.5), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
1 + \left(x \cdot x\right) \cdot 0.5
\end{array}
Initial program 99.9%
Taylor expanded in y around 0
Simplified68.6%
Taylor expanded in x around 0
+-lowering-+.f64N/A
*-lowering-*.f64N/A
unpow2N/A
*-lowering-*.f6448.0%
Simplified48.0%
Final simplification48.0%
(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
Simplified68.6%
Taylor expanded in x around 0
Simplified31.0%
(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 2024161
(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)))