Linear.Quaternion:$csin from linear-1.19.1.3

Percentage Accurate: 100.0% → 100.0%
Time: 25.9s
Alternatives: 23
Speedup: 1.0×

Specification

?
\[\begin{array}{l} \\ \cos x \cdot \frac{\sinh y}{y} \end{array} \]
(FPCore (x y) :precision binary64 (* (cos x) (/ (sinh y) y)))
double code(double x, double y) {
	return cos(x) * (sinh(y) / y);
}
real(8) function code(x, y)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    code = cos(x) * (sinh(y) / y)
end function
public static double code(double x, double y) {
	return Math.cos(x) * (Math.sinh(y) / y);
}
def code(x, y):
	return math.cos(x) * (math.sinh(y) / y)
function code(x, y)
	return Float64(cos(x) * Float64(sinh(y) / y))
end
function tmp = code(x, y)
	tmp = cos(x) * (sinh(y) / y);
end
code[x_, y_] := N[(N[Cos[x], $MachinePrecision] * N[(N[Sinh[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\cos x \cdot \frac{\sinh y}{y}
\end{array}

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

The average percentage accuracy by input value. Horizontal axis shows value of an input variable; the variable is choosen in the title. Vertical axis is accuracy; higher is better. Red represent the original program, while blue represents Herbie's suggestion. These can be toggled with buttons below the plot. The line is an average while dots represent individual samples.

Accuracy vs Speed?

Herbie found 23 alternatives:

AlternativeAccuracySpeedup
The accuracy (vertical axis) and speed (horizontal axis) of each alternatives. Up and to the right is better. The red square shows the initial program, and each blue circle shows an alternative.The line shows the best available speed-accuracy tradeoffs.

Initial Program: 100.0% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \cos x \cdot \frac{\sinh y}{y} \end{array} \]
(FPCore (x y) :precision binary64 (* (cos x) (/ (sinh y) y)))
double code(double x, double y) {
	return cos(x) * (sinh(y) / y);
}
real(8) function code(x, y)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    code = cos(x) * (sinh(y) / y)
end function
public static double code(double x, double y) {
	return Math.cos(x) * (Math.sinh(y) / y);
}
def code(x, y):
	return math.cos(x) * (math.sinh(y) / y)
function code(x, y)
	return Float64(cos(x) * Float64(sinh(y) / y))
end
function tmp = code(x, y)
	tmp = cos(x) * (sinh(y) / y);
end
code[x_, y_] := N[(N[Cos[x], $MachinePrecision] * N[(N[Sinh[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\cos x \cdot \frac{\sinh y}{y}
\end{array}

Alternative 1: 100.0% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \cos x \cdot \frac{\sinh y}{y} \end{array} \]
(FPCore (x y) :precision binary64 (* (cos x) (/ (sinh y) y)))
double code(double x, double y) {
	return cos(x) * (sinh(y) / y);
}
real(8) function code(x, y)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    code = cos(x) * (sinh(y) / y)
end function
public static double code(double x, double y) {
	return Math.cos(x) * (Math.sinh(y) / y);
}
def code(x, y):
	return math.cos(x) * (math.sinh(y) / y)
function code(x, y)
	return Float64(cos(x) * Float64(sinh(y) / y))
end
function tmp = code(x, y)
	tmp = cos(x) * (sinh(y) / y);
end
code[x_, y_] := N[(N[Cos[x], $MachinePrecision] * N[(N[Sinh[y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\cos x \cdot \frac{\sinh y}{y}
\end{array}
Derivation
  1. Initial program 100.0%

    \[\cos x \cdot \frac{\sinh y}{y} \]
  2. Add Preprocessing
  3. Add Preprocessing

Alternative 2: 95.4% accurate, 1.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq 31.5:\\ \;\;\;\;\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right)\\ \mathbf{elif}\;y \leq 9.8 \cdot 10^{+51}:\\ \;\;\;\;\frac{\sinh y}{y}\\ \mathbf{else}:\\ \;\;\;\;\cos x \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y)
 :precision binary64
 (if (<= y 31.5)
   (*
    (cos x)
    (+
     1.0
     (*
      y
      (*
       y
       (+
        0.16666666666666666
        (*
         (* y y)
         (+ 0.008333333333333333 (* y (* y 0.0001984126984126984)))))))))
   (if (<= y 9.8e+51)
     (/ (sinh y) y)
     (* (cos x) (* y (* 0.0001984126984126984 (* y (* (* y y) (* y y)))))))))
double code(double x, double y) {
	double tmp;
	if (y <= 31.5) {
		tmp = cos(x) * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * (0.008333333333333333 + (y * (y * 0.0001984126984126984))))))));
	} else if (y <= 9.8e+51) {
		tmp = sinh(y) / y;
	} else {
		tmp = cos(x) * (y * (0.0001984126984126984 * (y * ((y * y) * (y * y)))));
	}
	return tmp;
}
real(8) function code(x, y)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8) :: tmp
    if (y <= 31.5d0) then
        tmp = cos(x) * (1.0d0 + (y * (y * (0.16666666666666666d0 + ((y * y) * (0.008333333333333333d0 + (y * (y * 0.0001984126984126984d0))))))))
    else if (y <= 9.8d+51) then
        tmp = sinh(y) / y
    else
        tmp = cos(x) * (y * (0.0001984126984126984d0 * (y * ((y * y) * (y * y)))))
    end if
    code = tmp
end function
public static double code(double x, double y) {
	double tmp;
	if (y <= 31.5) {
		tmp = Math.cos(x) * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * (0.008333333333333333 + (y * (y * 0.0001984126984126984))))))));
	} else if (y <= 9.8e+51) {
		tmp = Math.sinh(y) / y;
	} else {
		tmp = Math.cos(x) * (y * (0.0001984126984126984 * (y * ((y * y) * (y * y)))));
	}
	return tmp;
}
def code(x, y):
	tmp = 0
	if y <= 31.5:
		tmp = math.cos(x) * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * (0.008333333333333333 + (y * (y * 0.0001984126984126984))))))))
	elif y <= 9.8e+51:
		tmp = math.sinh(y) / y
	else:
		tmp = math.cos(x) * (y * (0.0001984126984126984 * (y * ((y * y) * (y * y)))))
	return tmp
function code(x, y)
	tmp = 0.0
	if (y <= 31.5)
		tmp = Float64(cos(x) * Float64(1.0 + Float64(y * Float64(y * Float64(0.16666666666666666 + Float64(Float64(y * y) * Float64(0.008333333333333333 + Float64(y * Float64(y * 0.0001984126984126984)))))))));
	elseif (y <= 9.8e+51)
		tmp = Float64(sinh(y) / y);
	else
		tmp = Float64(cos(x) * Float64(y * Float64(0.0001984126984126984 * Float64(y * Float64(Float64(y * y) * Float64(y * y))))));
	end
	return tmp
end
function tmp_2 = code(x, y)
	tmp = 0.0;
	if (y <= 31.5)
		tmp = cos(x) * (1.0 + (y * (y * (0.16666666666666666 + ((y * y) * (0.008333333333333333 + (y * (y * 0.0001984126984126984))))))));
	elseif (y <= 9.8e+51)
		tmp = sinh(y) / y;
	else
		tmp = cos(x) * (y * (0.0001984126984126984 * (y * ((y * y) * (y * y)))));
	end
	tmp_2 = tmp;
end
code[x_, y_] := If[LessEqual[y, 31.5], N[(N[Cos[x], $MachinePrecision] * N[(1.0 + N[(y * N[(y * N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * N[(0.008333333333333333 + N[(y * N[(y * 0.0001984126984126984), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 9.8e+51], N[(N[Sinh[y], $MachinePrecision] / y), $MachinePrecision], N[(N[Cos[x], $MachinePrecision] * N[(y * N[(0.0001984126984126984 * N[(y * N[(N[(y * y), $MachinePrecision] * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq 31.5:\\
\;\;\;\;\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right)\\

\mathbf{elif}\;y \leq 9.8 \cdot 10^{+51}:\\
\;\;\;\;\frac{\sinh y}{y}\\

\mathbf{else}:\\
\;\;\;\;\cos x \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < 31.5

    1. Initial program 100.0%

      \[\cos x \cdot \frac{\sinh y}{y} \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0

      \[\leadsto \color{blue}{\cos x + {y}^{2} \cdot \left(\frac{1}{6} \cdot \cos x + {y}^{2} \cdot \left(\frac{1}{5040} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{120} \cdot \cos x\right)\right)} \]
    4. Simplified97.5%

      \[\leadsto \color{blue}{\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right)} \]

    if 31.5 < y < 9.79999999999999967e51

    1. Initial program 100.0%

      \[\cos x \cdot \frac{\sinh y}{y} \]
    2. Add Preprocessing
    3. Taylor expanded in x around 0

      \[\leadsto \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
    4. Step-by-step derivation
      1. Simplified90.9%

        \[\leadsto \color{blue}{1} \cdot \frac{\sinh y}{y} \]
      2. Step-by-step derivation
        1. *-lft-identityN/A

          \[\leadsto \frac{\sinh y}{\color{blue}{y}} \]
        2. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\sinh y, \color{blue}{y}\right) \]
        3. sinh-lowering-sinh.f6490.9%

          \[\leadsto \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right) \]
      3. Applied egg-rr90.9%

        \[\leadsto \color{blue}{\frac{\sinh y}{y}} \]

      if 9.79999999999999967e51 < y

      1. Initial program 100.0%

        \[\cos x \cdot \frac{\sinh y}{y} \]
      2. Add Preprocessing
      3. Taylor expanded in y around 0

        \[\leadsto \color{blue}{\cos x + {y}^{2} \cdot \left(\frac{1}{6} \cdot \cos x + {y}^{2} \cdot \left(\frac{1}{5040} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{120} \cdot \cos x\right)\right)} \]
      4. Simplified100.0%

        \[\leadsto \color{blue}{\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right)} \]
      5. Taylor expanded in y around inf

        \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{4}\right)}\right)\right)\right)\right)\right) \]
      6. Step-by-step derivation
        1. metadata-evalN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\frac{1}{5040} \cdot {y}^{\left(2 \cdot \color{blue}{2}\right)}\right)\right)\right)\right)\right)\right) \]
        2. pow-sqrN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\frac{1}{5040} \cdot \left({y}^{2} \cdot \color{blue}{{y}^{2}}\right)\right)\right)\right)\right)\right)\right) \]
        3. associate-*l*N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(\frac{1}{5040} \cdot {y}^{2}\right) \cdot \color{blue}{{y}^{2}}\right)\right)\right)\right)\right)\right) \]
        4. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right) \]
        5. unpow2N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{5040}} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right) \]
        6. associate-*l*N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \color{blue}{\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right)\right) \]
        7. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \color{blue}{\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right)\right) \]
        8. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right)\right) \]
        9. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left({y}^{2} \cdot \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
        10. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
        11. unpow2N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
        12. *-lowering-*.f64100.0%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
      7. Simplified100.0%

        \[\leadsto \cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \color{blue}{y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)}\right)\right)\right) \]
      8. Step-by-step derivation
        1. *-commutativeN/A

          \[\leadsto \left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right) \cdot \color{blue}{\cos x} \]
        2. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right), \color{blue}{\cos x}\right) \]
        3. +-lowering-+.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos \color{blue}{x}\right) \]
        4. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
        5. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
        6. +-lowering-+.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \cos x\right) \]
        7. associate-*r*N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
        8. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\left(y \cdot y\right), \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
        9. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
        10. associate-*l*N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(y \cdot \left(y \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \cos x\right) \]
        11. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, \left(y \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \cos x\right) \]
        12. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \cos x\right) \]
        13. cos-lowering-cos.f64100.0%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
      9. Applied egg-rr100.0%

        \[\leadsto \color{blue}{\left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right) \cdot \cos x} \]
      10. Taylor expanded in y around inf

        \[\leadsto \mathsf{*.f64}\left(\color{blue}{\left(\frac{1}{5040} \cdot {y}^{6}\right)}, \mathsf{cos.f64}\left(x\right)\right) \]
      11. Step-by-step derivation
        1. metadata-evalN/A

          \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{5040} \cdot {y}^{\left(5 + 1\right)}\right), \mathsf{cos.f64}\left(x\right)\right) \]
        2. pow-plusN/A

          \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{5040} \cdot \left({y}^{5} \cdot y\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
        3. associate-*l*N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\left(\frac{1}{5040} \cdot {y}^{5}\right) \cdot y\right), \mathsf{cos.f64}\left(\color{blue}{x}\right)\right) \]
        4. metadata-evalN/A

          \[\leadsto \mathsf{*.f64}\left(\left(\left(\frac{1}{5040} \cdot {y}^{\left(4 + 1\right)}\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
        5. pow-plusN/A

          \[\leadsto \mathsf{*.f64}\left(\left(\left(\frac{1}{5040} \cdot \left({y}^{4} \cdot y\right)\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
        6. associate-*l*N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\left(\left(\frac{1}{5040} \cdot {y}^{4}\right) \cdot y\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
        7. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\left(\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{4}\right)\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
        8. associate-*r*N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\left(\left(y \cdot \frac{1}{5040}\right) \cdot {y}^{4}\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
        9. associate-*l*N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\left(y \cdot \frac{1}{5040}\right) \cdot \left({y}^{4} \cdot y\right)\right), \mathsf{cos.f64}\left(\color{blue}{x}\right)\right) \]
        10. pow-plusN/A

          \[\leadsto \mathsf{*.f64}\left(\left(\left(y \cdot \frac{1}{5040}\right) \cdot {y}^{\left(4 + 1\right)}\right), \mathsf{cos.f64}\left(x\right)\right) \]
        11. metadata-evalN/A

          \[\leadsto \mathsf{*.f64}\left(\left(\left(y \cdot \frac{1}{5040}\right) \cdot {y}^{5}\right), \mathsf{cos.f64}\left(x\right)\right) \]
        12. associate-*r*N/A

          \[\leadsto \mathsf{*.f64}\left(\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{5}\right)\right), \mathsf{cos.f64}\left(\color{blue}{x}\right)\right) \]
        13. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \left(\frac{1}{5040} \cdot {y}^{5}\right)\right), \mathsf{cos.f64}\left(\color{blue}{x}\right)\right) \]
        14. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{5}\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
        15. metadata-evalN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{\left(4 + 1\right)}\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
        16. pow-plusN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{4} \cdot y\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
        17. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot {y}^{4}\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
        18. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{4}\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
        19. metadata-evalN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{\left(2 \cdot 2\right)}\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
        20. pow-sqrN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{2} \cdot {y}^{2}\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
        21. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left({y}^{2}\right), \left({y}^{2}\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
        22. unpow2N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left(y \cdot y\right), \left({y}^{2}\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
        23. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left({y}^{2}\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
        24. unpow2N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(y \cdot y\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
        25. *-lowering-*.f64100.0%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, y\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
      12. Simplified100.0%

        \[\leadsto \color{blue}{\left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\right)} \cdot \cos x \]
    5. Recombined 3 regimes into one program.
    6. Final simplification97.8%

      \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 31.5:\\ \;\;\;\;\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right)\\ \mathbf{elif}\;y \leq 9.8 \cdot 10^{+51}:\\ \;\;\;\;\frac{\sinh y}{y}\\ \mathbf{else}:\\ \;\;\;\;\cos x \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\right)\\ \end{array} \]
    7. Add Preprocessing

    Alternative 3: 95.3% accurate, 1.6× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq 31.5:\\ \;\;\;\;\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)\right)\\ \mathbf{elif}\;y \leq 9.8 \cdot 10^{+51}:\\ \;\;\;\;\frac{\sinh y}{y}\\ \mathbf{else}:\\ \;\;\;\;\cos x \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\right)\\ \end{array} \end{array} \]
    (FPCore (x y)
     :precision binary64
     (if (<= y 31.5)
       (*
        (cos x)
        (+
         1.0
         (*
          y
          (*
           y
           (+
            0.16666666666666666
            (* y (* y (* (* y y) 0.0001984126984126984))))))))
       (if (<= y 9.8e+51)
         (/ (sinh y) y)
         (* (cos x) (* y (* 0.0001984126984126984 (* y (* (* y y) (* y y)))))))))
    double code(double x, double y) {
    	double tmp;
    	if (y <= 31.5) {
    		tmp = cos(x) * (1.0 + (y * (y * (0.16666666666666666 + (y * (y * ((y * y) * 0.0001984126984126984)))))));
    	} else if (y <= 9.8e+51) {
    		tmp = sinh(y) / y;
    	} else {
    		tmp = cos(x) * (y * (0.0001984126984126984 * (y * ((y * y) * (y * y)))));
    	}
    	return tmp;
    }
    
    real(8) function code(x, y)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        real(8) :: tmp
        if (y <= 31.5d0) then
            tmp = cos(x) * (1.0d0 + (y * (y * (0.16666666666666666d0 + (y * (y * ((y * y) * 0.0001984126984126984d0)))))))
        else if (y <= 9.8d+51) then
            tmp = sinh(y) / y
        else
            tmp = cos(x) * (y * (0.0001984126984126984d0 * (y * ((y * y) * (y * y)))))
        end if
        code = tmp
    end function
    
    public static double code(double x, double y) {
    	double tmp;
    	if (y <= 31.5) {
    		tmp = Math.cos(x) * (1.0 + (y * (y * (0.16666666666666666 + (y * (y * ((y * y) * 0.0001984126984126984)))))));
    	} else if (y <= 9.8e+51) {
    		tmp = Math.sinh(y) / y;
    	} else {
    		tmp = Math.cos(x) * (y * (0.0001984126984126984 * (y * ((y * y) * (y * y)))));
    	}
    	return tmp;
    }
    
    def code(x, y):
    	tmp = 0
    	if y <= 31.5:
    		tmp = math.cos(x) * (1.0 + (y * (y * (0.16666666666666666 + (y * (y * ((y * y) * 0.0001984126984126984)))))))
    	elif y <= 9.8e+51:
    		tmp = math.sinh(y) / y
    	else:
    		tmp = math.cos(x) * (y * (0.0001984126984126984 * (y * ((y * y) * (y * y)))))
    	return tmp
    
    function code(x, y)
    	tmp = 0.0
    	if (y <= 31.5)
    		tmp = Float64(cos(x) * Float64(1.0 + Float64(y * Float64(y * Float64(0.16666666666666666 + Float64(y * Float64(y * Float64(Float64(y * y) * 0.0001984126984126984))))))));
    	elseif (y <= 9.8e+51)
    		tmp = Float64(sinh(y) / y);
    	else
    		tmp = Float64(cos(x) * Float64(y * Float64(0.0001984126984126984 * Float64(y * Float64(Float64(y * y) * Float64(y * y))))));
    	end
    	return tmp
    end
    
    function tmp_2 = code(x, y)
    	tmp = 0.0;
    	if (y <= 31.5)
    		tmp = cos(x) * (1.0 + (y * (y * (0.16666666666666666 + (y * (y * ((y * y) * 0.0001984126984126984)))))));
    	elseif (y <= 9.8e+51)
    		tmp = sinh(y) / y;
    	else
    		tmp = cos(x) * (y * (0.0001984126984126984 * (y * ((y * y) * (y * y)))));
    	end
    	tmp_2 = tmp;
    end
    
    code[x_, y_] := If[LessEqual[y, 31.5], N[(N[Cos[x], $MachinePrecision] * N[(1.0 + N[(y * N[(y * N[(0.16666666666666666 + N[(y * N[(y * N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 9.8e+51], N[(N[Sinh[y], $MachinePrecision] / y), $MachinePrecision], N[(N[Cos[x], $MachinePrecision] * N[(y * N[(0.0001984126984126984 * N[(y * N[(N[(y * y), $MachinePrecision] * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;y \leq 31.5:\\
    \;\;\;\;\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)\right)\\
    
    \mathbf{elif}\;y \leq 9.8 \cdot 10^{+51}:\\
    \;\;\;\;\frac{\sinh y}{y}\\
    
    \mathbf{else}:\\
    \;\;\;\;\cos x \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\right)\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 3 regimes
    2. if y < 31.5

      1. Initial program 100.0%

        \[\cos x \cdot \frac{\sinh y}{y} \]
      2. Add Preprocessing
      3. Taylor expanded in y around 0

        \[\leadsto \color{blue}{\cos x + {y}^{2} \cdot \left(\frac{1}{6} \cdot \cos x + {y}^{2} \cdot \left(\frac{1}{5040} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{120} \cdot \cos x\right)\right)} \]
      4. Simplified97.5%

        \[\leadsto \color{blue}{\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right)} \]
      5. Taylor expanded in y around inf

        \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{4}\right)}\right)\right)\right)\right)\right) \]
      6. Step-by-step derivation
        1. metadata-evalN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\frac{1}{5040} \cdot {y}^{\left(2 \cdot \color{blue}{2}\right)}\right)\right)\right)\right)\right)\right) \]
        2. pow-sqrN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\frac{1}{5040} \cdot \left({y}^{2} \cdot \color{blue}{{y}^{2}}\right)\right)\right)\right)\right)\right)\right) \]
        3. associate-*l*N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(\frac{1}{5040} \cdot {y}^{2}\right) \cdot \color{blue}{{y}^{2}}\right)\right)\right)\right)\right)\right) \]
        4. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right) \]
        5. unpow2N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{5040}} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right) \]
        6. associate-*l*N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \color{blue}{\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right)\right) \]
        7. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \color{blue}{\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right)\right) \]
        8. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right)\right) \]
        9. *-commutativeN/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left({y}^{2} \cdot \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
        10. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
        11. unpow2N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
        12. *-lowering-*.f6497.5%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
      7. Simplified97.5%

        \[\leadsto \cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \color{blue}{y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)}\right)\right)\right) \]

      if 31.5 < y < 9.79999999999999967e51

      1. Initial program 100.0%

        \[\cos x \cdot \frac{\sinh y}{y} \]
      2. Add Preprocessing
      3. Taylor expanded in x around 0

        \[\leadsto \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
      4. Step-by-step derivation
        1. Simplified90.9%

          \[\leadsto \color{blue}{1} \cdot \frac{\sinh y}{y} \]
        2. Step-by-step derivation
          1. *-lft-identityN/A

            \[\leadsto \frac{\sinh y}{\color{blue}{y}} \]
          2. /-lowering-/.f64N/A

            \[\leadsto \mathsf{/.f64}\left(\sinh y, \color{blue}{y}\right) \]
          3. sinh-lowering-sinh.f6490.9%

            \[\leadsto \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right) \]
        3. Applied egg-rr90.9%

          \[\leadsto \color{blue}{\frac{\sinh y}{y}} \]

        if 9.79999999999999967e51 < y

        1. Initial program 100.0%

          \[\cos x \cdot \frac{\sinh y}{y} \]
        2. Add Preprocessing
        3. Taylor expanded in y around 0

          \[\leadsto \color{blue}{\cos x + {y}^{2} \cdot \left(\frac{1}{6} \cdot \cos x + {y}^{2} \cdot \left(\frac{1}{5040} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{120} \cdot \cos x\right)\right)} \]
        4. Simplified100.0%

          \[\leadsto \color{blue}{\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right)} \]
        5. Taylor expanded in y around inf

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{4}\right)}\right)\right)\right)\right)\right) \]
        6. Step-by-step derivation
          1. metadata-evalN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\frac{1}{5040} \cdot {y}^{\left(2 \cdot \color{blue}{2}\right)}\right)\right)\right)\right)\right)\right) \]
          2. pow-sqrN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\frac{1}{5040} \cdot \left({y}^{2} \cdot \color{blue}{{y}^{2}}\right)\right)\right)\right)\right)\right)\right) \]
          3. associate-*l*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(\frac{1}{5040} \cdot {y}^{2}\right) \cdot \color{blue}{{y}^{2}}\right)\right)\right)\right)\right)\right) \]
          4. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right) \]
          5. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{5040}} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right) \]
          6. associate-*l*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \color{blue}{\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right)\right) \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \color{blue}{\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right)\right) \]
          9. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left({y}^{2} \cdot \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
          10. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
          11. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
          12. *-lowering-*.f64100.0%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
        7. Simplified100.0%

          \[\leadsto \cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \color{blue}{y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)}\right)\right)\right) \]
        8. Step-by-step derivation
          1. *-commutativeN/A

            \[\leadsto \left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right) \cdot \color{blue}{\cos x} \]
          2. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right), \color{blue}{\cos x}\right) \]
          3. +-lowering-+.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos \color{blue}{x}\right) \]
          4. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
          6. +-lowering-+.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \cos x\right) \]
          7. associate-*r*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\left(y \cdot y\right), \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
          9. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
          10. associate-*l*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(y \cdot \left(y \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \cos x\right) \]
          11. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, \left(y \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \cos x\right) \]
          12. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \cos x\right) \]
          13. cos-lowering-cos.f64100.0%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
        9. Applied egg-rr100.0%

          \[\leadsto \color{blue}{\left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right) \cdot \cos x} \]
        10. Taylor expanded in y around inf

          \[\leadsto \mathsf{*.f64}\left(\color{blue}{\left(\frac{1}{5040} \cdot {y}^{6}\right)}, \mathsf{cos.f64}\left(x\right)\right) \]
        11. Step-by-step derivation
          1. metadata-evalN/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{5040} \cdot {y}^{\left(5 + 1\right)}\right), \mathsf{cos.f64}\left(x\right)\right) \]
          2. pow-plusN/A

            \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{5040} \cdot \left({y}^{5} \cdot y\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
          3. associate-*l*N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(\frac{1}{5040} \cdot {y}^{5}\right) \cdot y\right), \mathsf{cos.f64}\left(\color{blue}{x}\right)\right) \]
          4. metadata-evalN/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(\frac{1}{5040} \cdot {y}^{\left(4 + 1\right)}\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
          5. pow-plusN/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(\frac{1}{5040} \cdot \left({y}^{4} \cdot y\right)\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
          6. associate-*l*N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(\left(\frac{1}{5040} \cdot {y}^{4}\right) \cdot y\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
          7. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{4}\right)\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
          8. associate-*r*N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(\left(y \cdot \frac{1}{5040}\right) \cdot {y}^{4}\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
          9. associate-*l*N/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(y \cdot \frac{1}{5040}\right) \cdot \left({y}^{4} \cdot y\right)\right), \mathsf{cos.f64}\left(\color{blue}{x}\right)\right) \]
          10. pow-plusN/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(y \cdot \frac{1}{5040}\right) \cdot {y}^{\left(4 + 1\right)}\right), \mathsf{cos.f64}\left(x\right)\right) \]
          11. metadata-evalN/A

            \[\leadsto \mathsf{*.f64}\left(\left(\left(y \cdot \frac{1}{5040}\right) \cdot {y}^{5}\right), \mathsf{cos.f64}\left(x\right)\right) \]
          12. associate-*r*N/A

            \[\leadsto \mathsf{*.f64}\left(\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{5}\right)\right), \mathsf{cos.f64}\left(\color{blue}{x}\right)\right) \]
          13. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \left(\frac{1}{5040} \cdot {y}^{5}\right)\right), \mathsf{cos.f64}\left(\color{blue}{x}\right)\right) \]
          14. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{5}\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
          15. metadata-evalN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{\left(4 + 1\right)}\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
          16. pow-plusN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{4} \cdot y\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
          17. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot {y}^{4}\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
          18. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{4}\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
          19. metadata-evalN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{\left(2 \cdot 2\right)}\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
          20. pow-sqrN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{2} \cdot {y}^{2}\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
          21. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left({y}^{2}\right), \left({y}^{2}\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
          22. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left(y \cdot y\right), \left({y}^{2}\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
          23. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left({y}^{2}\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
          24. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(y \cdot y\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
          25. *-lowering-*.f64100.0%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, y\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
        12. Simplified100.0%

          \[\leadsto \color{blue}{\left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\right)} \cdot \cos x \]
      5. Recombined 3 regimes into one program.
      6. Final simplification97.8%

        \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 31.5:\\ \;\;\;\;\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)\right)\\ \mathbf{elif}\;y \leq 9.8 \cdot 10^{+51}:\\ \;\;\;\;\frac{\sinh y}{y}\\ \mathbf{else}:\\ \;\;\;\;\cos x \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\right)\\ \end{array} \]
      7. Add Preprocessing

      Alternative 4: 95.0% accurate, 1.6× speedup?

      \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq 31.5:\\ \;\;\;\;\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right)\right)\right)\\ \mathbf{elif}\;y \leq 9.8 \cdot 10^{+51}:\\ \;\;\;\;\frac{\sinh y}{y}\\ \mathbf{else}:\\ \;\;\;\;\cos x \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\right)\\ \end{array} \end{array} \]
      (FPCore (x y)
       :precision binary64
       (if (<= y 31.5)
         (*
          (cos x)
          (+ 1.0 (* y (* y (* 0.0001984126984126984 (* y (* y (* y y))))))))
         (if (<= y 9.8e+51)
           (/ (sinh y) y)
           (* (cos x) (* y (* 0.0001984126984126984 (* y (* (* y y) (* y y)))))))))
      double code(double x, double y) {
      	double tmp;
      	if (y <= 31.5) {
      		tmp = cos(x) * (1.0 + (y * (y * (0.0001984126984126984 * (y * (y * (y * y)))))));
      	} else if (y <= 9.8e+51) {
      		tmp = sinh(y) / y;
      	} else {
      		tmp = cos(x) * (y * (0.0001984126984126984 * (y * ((y * y) * (y * y)))));
      	}
      	return tmp;
      }
      
      real(8) function code(x, y)
          real(8), intent (in) :: x
          real(8), intent (in) :: y
          real(8) :: tmp
          if (y <= 31.5d0) then
              tmp = cos(x) * (1.0d0 + (y * (y * (0.0001984126984126984d0 * (y * (y * (y * y)))))))
          else if (y <= 9.8d+51) then
              tmp = sinh(y) / y
          else
              tmp = cos(x) * (y * (0.0001984126984126984d0 * (y * ((y * y) * (y * y)))))
          end if
          code = tmp
      end function
      
      public static double code(double x, double y) {
      	double tmp;
      	if (y <= 31.5) {
      		tmp = Math.cos(x) * (1.0 + (y * (y * (0.0001984126984126984 * (y * (y * (y * y)))))));
      	} else if (y <= 9.8e+51) {
      		tmp = Math.sinh(y) / y;
      	} else {
      		tmp = Math.cos(x) * (y * (0.0001984126984126984 * (y * ((y * y) * (y * y)))));
      	}
      	return tmp;
      }
      
      def code(x, y):
      	tmp = 0
      	if y <= 31.5:
      		tmp = math.cos(x) * (1.0 + (y * (y * (0.0001984126984126984 * (y * (y * (y * y)))))))
      	elif y <= 9.8e+51:
      		tmp = math.sinh(y) / y
      	else:
      		tmp = math.cos(x) * (y * (0.0001984126984126984 * (y * ((y * y) * (y * y)))))
      	return tmp
      
      function code(x, y)
      	tmp = 0.0
      	if (y <= 31.5)
      		tmp = Float64(cos(x) * Float64(1.0 + Float64(y * Float64(y * Float64(0.0001984126984126984 * Float64(y * Float64(y * Float64(y * y))))))));
      	elseif (y <= 9.8e+51)
      		tmp = Float64(sinh(y) / y);
      	else
      		tmp = Float64(cos(x) * Float64(y * Float64(0.0001984126984126984 * Float64(y * Float64(Float64(y * y) * Float64(y * y))))));
      	end
      	return tmp
      end
      
      function tmp_2 = code(x, y)
      	tmp = 0.0;
      	if (y <= 31.5)
      		tmp = cos(x) * (1.0 + (y * (y * (0.0001984126984126984 * (y * (y * (y * y)))))));
      	elseif (y <= 9.8e+51)
      		tmp = sinh(y) / y;
      	else
      		tmp = cos(x) * (y * (0.0001984126984126984 * (y * ((y * y) * (y * y)))));
      	end
      	tmp_2 = tmp;
      end
      
      code[x_, y_] := If[LessEqual[y, 31.5], N[(N[Cos[x], $MachinePrecision] * N[(1.0 + N[(y * N[(y * N[(0.0001984126984126984 * N[(y * N[(y * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 9.8e+51], N[(N[Sinh[y], $MachinePrecision] / y), $MachinePrecision], N[(N[Cos[x], $MachinePrecision] * N[(y * N[(0.0001984126984126984 * N[(y * N[(N[(y * y), $MachinePrecision] * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
      
      \begin{array}{l}
      
      \\
      \begin{array}{l}
      \mathbf{if}\;y \leq 31.5:\\
      \;\;\;\;\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right)\right)\right)\\
      
      \mathbf{elif}\;y \leq 9.8 \cdot 10^{+51}:\\
      \;\;\;\;\frac{\sinh y}{y}\\
      
      \mathbf{else}:\\
      \;\;\;\;\cos x \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\right)\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 3 regimes
      2. if y < 31.5

        1. Initial program 100.0%

          \[\cos x \cdot \frac{\sinh y}{y} \]
        2. Add Preprocessing
        3. Taylor expanded in y around 0

          \[\leadsto \color{blue}{\cos x + {y}^{2} \cdot \left(\frac{1}{6} \cdot \cos x + {y}^{2} \cdot \left(\frac{1}{5040} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{120} \cdot \cos x\right)\right)} \]
        4. Simplified97.5%

          \[\leadsto \color{blue}{\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right)} \]
        5. Taylor expanded in y around inf

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{4}\right)}\right)\right)\right)\right)\right) \]
        6. Step-by-step derivation
          1. metadata-evalN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\frac{1}{5040} \cdot {y}^{\left(2 \cdot \color{blue}{2}\right)}\right)\right)\right)\right)\right)\right) \]
          2. pow-sqrN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\frac{1}{5040} \cdot \left({y}^{2} \cdot \color{blue}{{y}^{2}}\right)\right)\right)\right)\right)\right)\right) \]
          3. associate-*l*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(\frac{1}{5040} \cdot {y}^{2}\right) \cdot \color{blue}{{y}^{2}}\right)\right)\right)\right)\right)\right) \]
          4. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right) \]
          5. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{5040}} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right) \]
          6. associate-*l*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \color{blue}{\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right)\right) \]
          7. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \color{blue}{\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right)\right) \]
          8. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right)\right) \]
          9. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left({y}^{2} \cdot \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
          10. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
          11. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
          12. *-lowering-*.f6497.5%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
        7. Simplified97.5%

          \[\leadsto \cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \color{blue}{y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)}\right)\right)\right) \]
        8. Taylor expanded in y around inf

          \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{5}\right)}\right)\right)\right) \]
        9. Step-by-step derivation
          1. metadata-evalN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(\frac{1}{5040} \cdot {y}^{\left(4 + \color{blue}{1}\right)}\right)\right)\right)\right) \]
          2. pow-plusN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(\frac{1}{5040} \cdot \left({y}^{4} \cdot \color{blue}{y}\right)\right)\right)\right)\right) \]
          3. associate-*l*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(\left(\frac{1}{5040} \cdot {y}^{4}\right) \cdot \color{blue}{y}\right)\right)\right)\right) \]
          4. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \color{blue}{\left(\frac{1}{5040} \cdot {y}^{4}\right)}\right)\right)\right)\right) \]
          5. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{4}\right)}\right)\right)\right)\right) \]
          6. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \color{blue}{\left({y}^{4}\right)}\right)\right)\right)\right)\right) \]
          7. *-rgt-identityN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{4} \cdot \color{blue}{1}\right)\right)\right)\right)\right)\right) \]
          8. *-inversesN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{4} \cdot \frac{y}{\color{blue}{y}}\right)\right)\right)\right)\right)\right) \]
          9. associate-/l*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(\frac{{y}^{4} \cdot y}{\color{blue}{y}}\right)\right)\right)\right)\right)\right) \]
          10. *-commutativeN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(\frac{y \cdot {y}^{4}}{y}\right)\right)\right)\right)\right)\right) \]
          11. associate-/l*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \color{blue}{\frac{{y}^{4}}{y}}\right)\right)\right)\right)\right)\right) \]
          12. metadata-evalN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \frac{{y}^{\left(2 \cdot 2\right)}}{y}\right)\right)\right)\right)\right)\right) \]
          13. pow-sqrN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \frac{{y}^{2} \cdot {y}^{2}}{y}\right)\right)\right)\right)\right)\right) \]
          14. associate-/l*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left({y}^{2} \cdot \color{blue}{\frac{{y}^{2}}{y}}\right)\right)\right)\right)\right)\right)\right) \]
          15. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{\color{blue}{{y}^{2}}}{y}\right)\right)\right)\right)\right)\right)\right) \]
          16. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{y \cdot y}{y}\right)\right)\right)\right)\right)\right)\right) \]
          17. associate-/l*N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot \color{blue}{\frac{y}{y}}\right)\right)\right)\right)\right)\right)\right)\right) \]
          18. *-inversesN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot 1\right)\right)\right)\right)\right)\right)\right)\right) \]
          19. *-rgt-identityN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot y\right)\right)\right)\right)\right)\right)\right) \]
          20. unpow3N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot {y}^{\color{blue}{3}}\right)\right)\right)\right)\right)\right) \]
          21. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \color{blue}{\left({y}^{3}\right)}\right)\right)\right)\right)\right)\right) \]
          22. cube-multN/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left(y \cdot \color{blue}{\left(y \cdot y\right)}\right)\right)\right)\right)\right)\right)\right) \]
          23. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left(y \cdot {y}^{\color{blue}{2}}\right)\right)\right)\right)\right)\right)\right) \]
          24. *-lowering-*.f64N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left({y}^{2}\right)}\right)\right)\right)\right)\right)\right)\right) \]
          25. unpow2N/A

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(y \cdot \color{blue}{y}\right)\right)\right)\right)\right)\right)\right)\right) \]
          26. *-lowering-*.f6497.5%

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{y}\right)\right)\right)\right)\right)\right)\right)\right) \]
        10. Simplified97.5%

          \[\leadsto \cos x \cdot \left(1 + y \cdot \color{blue}{\left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right)\right)}\right) \]

        if 31.5 < y < 9.79999999999999967e51

        1. Initial program 100.0%

          \[\cos x \cdot \frac{\sinh y}{y} \]
        2. Add Preprocessing
        3. Taylor expanded in x around 0

          \[\leadsto \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
        4. Step-by-step derivation
          1. Simplified90.9%

            \[\leadsto \color{blue}{1} \cdot \frac{\sinh y}{y} \]
          2. Step-by-step derivation
            1. *-lft-identityN/A

              \[\leadsto \frac{\sinh y}{\color{blue}{y}} \]
            2. /-lowering-/.f64N/A

              \[\leadsto \mathsf{/.f64}\left(\sinh y, \color{blue}{y}\right) \]
            3. sinh-lowering-sinh.f6490.9%

              \[\leadsto \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right) \]
          3. Applied egg-rr90.9%

            \[\leadsto \color{blue}{\frac{\sinh y}{y}} \]

          if 9.79999999999999967e51 < y

          1. Initial program 100.0%

            \[\cos x \cdot \frac{\sinh y}{y} \]
          2. Add Preprocessing
          3. Taylor expanded in y around 0

            \[\leadsto \color{blue}{\cos x + {y}^{2} \cdot \left(\frac{1}{6} \cdot \cos x + {y}^{2} \cdot \left(\frac{1}{5040} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{120} \cdot \cos x\right)\right)} \]
          4. Simplified100.0%

            \[\leadsto \color{blue}{\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right)} \]
          5. Taylor expanded in y around inf

            \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{4}\right)}\right)\right)\right)\right)\right) \]
          6. Step-by-step derivation
            1. metadata-evalN/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\frac{1}{5040} \cdot {y}^{\left(2 \cdot \color{blue}{2}\right)}\right)\right)\right)\right)\right)\right) \]
            2. pow-sqrN/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\frac{1}{5040} \cdot \left({y}^{2} \cdot \color{blue}{{y}^{2}}\right)\right)\right)\right)\right)\right)\right) \]
            3. associate-*l*N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(\frac{1}{5040} \cdot {y}^{2}\right) \cdot \color{blue}{{y}^{2}}\right)\right)\right)\right)\right)\right) \]
            4. *-commutativeN/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right) \]
            5. unpow2N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{5040}} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right) \]
            6. associate-*l*N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \color{blue}{\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right)\right) \]
            7. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \color{blue}{\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right)\right) \]
            8. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right)\right) \]
            9. *-commutativeN/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left({y}^{2} \cdot \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
            10. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
            11. unpow2N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
            12. *-lowering-*.f64100.0%

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
          7. Simplified100.0%

            \[\leadsto \cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \color{blue}{y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)}\right)\right)\right) \]
          8. Step-by-step derivation
            1. *-commutativeN/A

              \[\leadsto \left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right) \cdot \color{blue}{\cos x} \]
            2. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right), \color{blue}{\cos x}\right) \]
            3. +-lowering-+.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos \color{blue}{x}\right) \]
            4. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
            5. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
            6. +-lowering-+.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \cos x\right) \]
            7. associate-*r*N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
            8. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\left(y \cdot y\right), \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
            9. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
            10. associate-*l*N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(y \cdot \left(y \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \cos x\right) \]
            11. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, \left(y \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \cos x\right) \]
            12. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \cos x\right) \]
            13. cos-lowering-cos.f64100.0%

              \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
          9. Applied egg-rr100.0%

            \[\leadsto \color{blue}{\left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right) \cdot \cos x} \]
          10. Taylor expanded in y around inf

            \[\leadsto \mathsf{*.f64}\left(\color{blue}{\left(\frac{1}{5040} \cdot {y}^{6}\right)}, \mathsf{cos.f64}\left(x\right)\right) \]
          11. Step-by-step derivation
            1. metadata-evalN/A

              \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{5040} \cdot {y}^{\left(5 + 1\right)}\right), \mathsf{cos.f64}\left(x\right)\right) \]
            2. pow-plusN/A

              \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{5040} \cdot \left({y}^{5} \cdot y\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
            3. associate-*l*N/A

              \[\leadsto \mathsf{*.f64}\left(\left(\left(\frac{1}{5040} \cdot {y}^{5}\right) \cdot y\right), \mathsf{cos.f64}\left(\color{blue}{x}\right)\right) \]
            4. metadata-evalN/A

              \[\leadsto \mathsf{*.f64}\left(\left(\left(\frac{1}{5040} \cdot {y}^{\left(4 + 1\right)}\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
            5. pow-plusN/A

              \[\leadsto \mathsf{*.f64}\left(\left(\left(\frac{1}{5040} \cdot \left({y}^{4} \cdot y\right)\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
            6. associate-*l*N/A

              \[\leadsto \mathsf{*.f64}\left(\left(\left(\left(\frac{1}{5040} \cdot {y}^{4}\right) \cdot y\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
            7. *-commutativeN/A

              \[\leadsto \mathsf{*.f64}\left(\left(\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{4}\right)\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
            8. associate-*r*N/A

              \[\leadsto \mathsf{*.f64}\left(\left(\left(\left(y \cdot \frac{1}{5040}\right) \cdot {y}^{4}\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
            9. associate-*l*N/A

              \[\leadsto \mathsf{*.f64}\left(\left(\left(y \cdot \frac{1}{5040}\right) \cdot \left({y}^{4} \cdot y\right)\right), \mathsf{cos.f64}\left(\color{blue}{x}\right)\right) \]
            10. pow-plusN/A

              \[\leadsto \mathsf{*.f64}\left(\left(\left(y \cdot \frac{1}{5040}\right) \cdot {y}^{\left(4 + 1\right)}\right), \mathsf{cos.f64}\left(x\right)\right) \]
            11. metadata-evalN/A

              \[\leadsto \mathsf{*.f64}\left(\left(\left(y \cdot \frac{1}{5040}\right) \cdot {y}^{5}\right), \mathsf{cos.f64}\left(x\right)\right) \]
            12. associate-*r*N/A

              \[\leadsto \mathsf{*.f64}\left(\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{5}\right)\right), \mathsf{cos.f64}\left(\color{blue}{x}\right)\right) \]
            13. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \left(\frac{1}{5040} \cdot {y}^{5}\right)\right), \mathsf{cos.f64}\left(\color{blue}{x}\right)\right) \]
            14. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{5}\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
            15. metadata-evalN/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{\left(4 + 1\right)}\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
            16. pow-plusN/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{4} \cdot y\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
            17. *-commutativeN/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot {y}^{4}\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
            18. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{4}\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
            19. metadata-evalN/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{\left(2 \cdot 2\right)}\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
            20. pow-sqrN/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{2} \cdot {y}^{2}\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
            21. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left({y}^{2}\right), \left({y}^{2}\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
            22. unpow2N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left(y \cdot y\right), \left({y}^{2}\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
            23. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left({y}^{2}\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
            24. unpow2N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(y \cdot y\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
            25. *-lowering-*.f64100.0%

              \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, y\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
          12. Simplified100.0%

            \[\leadsto \color{blue}{\left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\right)} \cdot \cos x \]
        5. Recombined 3 regimes into one program.
        6. Final simplification97.8%

          \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 31.5:\\ \;\;\;\;\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right)\right)\right)\\ \mathbf{elif}\;y \leq 9.8 \cdot 10^{+51}:\\ \;\;\;\;\frac{\sinh y}{y}\\ \mathbf{else}:\\ \;\;\;\;\cos x \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\right)\\ \end{array} \]
        7. Add Preprocessing

        Alternative 5: 93.4% accurate, 1.6× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq 31.5:\\ \;\;\;\;\cos x \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)\\ \mathbf{elif}\;y \leq 10^{+52}:\\ \;\;\;\;\frac{\sinh y}{y}\\ \mathbf{else}:\\ \;\;\;\;\cos x \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\right)\\ \end{array} \end{array} \]
        (FPCore (x y)
         :precision binary64
         (if (<= y 31.5)
           (*
            (cos x)
            (+
             1.0
             (* (* y y) (+ 0.16666666666666666 (* (* y y) 0.008333333333333333)))))
           (if (<= y 1e+52)
             (/ (sinh y) y)
             (* (cos x) (* y (* 0.0001984126984126984 (* y (* (* y y) (* y y)))))))))
        double code(double x, double y) {
        	double tmp;
        	if (y <= 31.5) {
        		tmp = cos(x) * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))));
        	} else if (y <= 1e+52) {
        		tmp = sinh(y) / y;
        	} else {
        		tmp = cos(x) * (y * (0.0001984126984126984 * (y * ((y * y) * (y * y)))));
        	}
        	return tmp;
        }
        
        real(8) function code(x, y)
            real(8), intent (in) :: x
            real(8), intent (in) :: y
            real(8) :: tmp
            if (y <= 31.5d0) then
                tmp = cos(x) * (1.0d0 + ((y * y) * (0.16666666666666666d0 + ((y * y) * 0.008333333333333333d0))))
            else if (y <= 1d+52) then
                tmp = sinh(y) / y
            else
                tmp = cos(x) * (y * (0.0001984126984126984d0 * (y * ((y * y) * (y * y)))))
            end if
            code = tmp
        end function
        
        public static double code(double x, double y) {
        	double tmp;
        	if (y <= 31.5) {
        		tmp = Math.cos(x) * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))));
        	} else if (y <= 1e+52) {
        		tmp = Math.sinh(y) / y;
        	} else {
        		tmp = Math.cos(x) * (y * (0.0001984126984126984 * (y * ((y * y) * (y * y)))));
        	}
        	return tmp;
        }
        
        def code(x, y):
        	tmp = 0
        	if y <= 31.5:
        		tmp = math.cos(x) * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))))
        	elif y <= 1e+52:
        		tmp = math.sinh(y) / y
        	else:
        		tmp = math.cos(x) * (y * (0.0001984126984126984 * (y * ((y * y) * (y * y)))))
        	return tmp
        
        function code(x, y)
        	tmp = 0.0
        	if (y <= 31.5)
        		tmp = Float64(cos(x) * Float64(1.0 + Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(Float64(y * y) * 0.008333333333333333)))));
        	elseif (y <= 1e+52)
        		tmp = Float64(sinh(y) / y);
        	else
        		tmp = Float64(cos(x) * Float64(y * Float64(0.0001984126984126984 * Float64(y * Float64(Float64(y * y) * Float64(y * y))))));
        	end
        	return tmp
        end
        
        function tmp_2 = code(x, y)
        	tmp = 0.0;
        	if (y <= 31.5)
        		tmp = cos(x) * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))));
        	elseif (y <= 1e+52)
        		tmp = sinh(y) / y;
        	else
        		tmp = cos(x) * (y * (0.0001984126984126984 * (y * ((y * y) * (y * y)))));
        	end
        	tmp_2 = tmp;
        end
        
        code[x_, y_] := If[LessEqual[y, 31.5], N[(N[Cos[x], $MachinePrecision] * N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1e+52], N[(N[Sinh[y], $MachinePrecision] / y), $MachinePrecision], N[(N[Cos[x], $MachinePrecision] * N[(y * N[(0.0001984126984126984 * N[(y * N[(N[(y * y), $MachinePrecision] * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        \mathbf{if}\;y \leq 31.5:\\
        \;\;\;\;\cos x \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)\\
        
        \mathbf{elif}\;y \leq 10^{+52}:\\
        \;\;\;\;\frac{\sinh y}{y}\\
        
        \mathbf{else}:\\
        \;\;\;\;\cos x \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\right)\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 3 regimes
        2. if y < 31.5

          1. Initial program 100.0%

            \[\cos x \cdot \frac{\sinh y}{y} \]
          2. Add Preprocessing
          3. Taylor expanded in y around 0

            \[\leadsto \color{blue}{\cos x + {y}^{2} \cdot \left(\frac{1}{120} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{6} \cdot \cos x\right)} \]
          4. Step-by-step derivation
            1. *-rgt-identityN/A

              \[\leadsto \cos x \cdot 1 + \color{blue}{{y}^{2}} \cdot \left(\frac{1}{120} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{6} \cdot \cos x\right) \]
            2. *-commutativeN/A

              \[\leadsto \cos x \cdot 1 + \left(\frac{1}{120} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{6} \cdot \cos x\right) \cdot \color{blue}{{y}^{2}} \]
            3. associate-*r*N/A

              \[\leadsto \cos x \cdot 1 + \left(\left(\frac{1}{120} \cdot {y}^{2}\right) \cdot \cos x + \frac{1}{6} \cdot \cos x\right) \cdot {y}^{2} \]
            4. distribute-rgt-outN/A

              \[\leadsto \cos x \cdot 1 + \left(\cos x \cdot \left(\frac{1}{120} \cdot {y}^{2} + \frac{1}{6}\right)\right) \cdot {\color{blue}{y}}^{2} \]
            5. +-commutativeN/A

              \[\leadsto \cos x \cdot 1 + \left(\cos x \cdot \left(\frac{1}{6} + \frac{1}{120} \cdot {y}^{2}\right)\right) \cdot {y}^{2} \]
            6. associate-*l*N/A

              \[\leadsto \cos x \cdot 1 + \cos x \cdot \color{blue}{\left(\left(\frac{1}{6} + \frac{1}{120} \cdot {y}^{2}\right) \cdot {y}^{2}\right)} \]
            7. *-commutativeN/A

              \[\leadsto \cos x \cdot 1 + \cos x \cdot \left({y}^{2} \cdot \color{blue}{\left(\frac{1}{6} + \frac{1}{120} \cdot {y}^{2}\right)}\right) \]
            8. distribute-lft-inN/A

              \[\leadsto \cos x \cdot \color{blue}{\left(1 + {y}^{2} \cdot \left(\frac{1}{6} + \frac{1}{120} \cdot {y}^{2}\right)\right)} \]
            9. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\cos x, \color{blue}{\left(1 + {y}^{2} \cdot \left(\frac{1}{6} + \frac{1}{120} \cdot {y}^{2}\right)\right)}\right) \]
            10. cos-lowering-cos.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \left(\color{blue}{1} + {y}^{2} \cdot \left(\frac{1}{6} + \frac{1}{120} \cdot {y}^{2}\right)\right)\right) \]
            11. +-lowering-+.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \color{blue}{\left({y}^{2} \cdot \left(\frac{1}{6} + \frac{1}{120} \cdot {y}^{2}\right)\right)}\right)\right) \]
            12. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\left(\frac{1}{6} + \frac{1}{120} \cdot {y}^{2}\right)}\right)\right)\right) \]
            13. unpow2N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(y \cdot y\right), \left(\color{blue}{\frac{1}{6}} + \frac{1}{120} \cdot {y}^{2}\right)\right)\right)\right) \]
            14. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(\color{blue}{\frac{1}{6}} + \frac{1}{120} \cdot {y}^{2}\right)\right)\right)\right) \]
            15. +-lowering-+.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \color{blue}{\left(\frac{1}{120} \cdot {y}^{2}\right)}\right)\right)\right)\right) \]
            16. *-commutativeN/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \color{blue}{\frac{1}{120}}\right)\right)\right)\right)\right) \]
            17. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{120}}\right)\right)\right)\right)\right) \]
          5. Simplified93.6%

            \[\leadsto \color{blue}{\cos x \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)} \]

          if 31.5 < y < 9.9999999999999999e51

          1. Initial program 100.0%

            \[\cos x \cdot \frac{\sinh y}{y} \]
          2. Add Preprocessing
          3. Taylor expanded in x around 0

            \[\leadsto \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
          4. Step-by-step derivation
            1. Simplified90.9%

              \[\leadsto \color{blue}{1} \cdot \frac{\sinh y}{y} \]
            2. Step-by-step derivation
              1. *-lft-identityN/A

                \[\leadsto \frac{\sinh y}{\color{blue}{y}} \]
              2. /-lowering-/.f64N/A

                \[\leadsto \mathsf{/.f64}\left(\sinh y, \color{blue}{y}\right) \]
              3. sinh-lowering-sinh.f6490.9%

                \[\leadsto \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right) \]
            3. Applied egg-rr90.9%

              \[\leadsto \color{blue}{\frac{\sinh y}{y}} \]

            if 9.9999999999999999e51 < y

            1. Initial program 100.0%

              \[\cos x \cdot \frac{\sinh y}{y} \]
            2. Add Preprocessing
            3. Taylor expanded in y around 0

              \[\leadsto \color{blue}{\cos x + {y}^{2} \cdot \left(\frac{1}{6} \cdot \cos x + {y}^{2} \cdot \left(\frac{1}{5040} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{120} \cdot \cos x\right)\right)} \]
            4. Simplified100.0%

              \[\leadsto \color{blue}{\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right)} \]
            5. Taylor expanded in y around inf

              \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{4}\right)}\right)\right)\right)\right)\right) \]
            6. Step-by-step derivation
              1. metadata-evalN/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\frac{1}{5040} \cdot {y}^{\left(2 \cdot \color{blue}{2}\right)}\right)\right)\right)\right)\right)\right) \]
              2. pow-sqrN/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\frac{1}{5040} \cdot \left({y}^{2} \cdot \color{blue}{{y}^{2}}\right)\right)\right)\right)\right)\right)\right) \]
              3. associate-*l*N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(\frac{1}{5040} \cdot {y}^{2}\right) \cdot \color{blue}{{y}^{2}}\right)\right)\right)\right)\right)\right) \]
              4. *-commutativeN/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right) \]
              5. unpow2N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{5040}} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right) \]
              6. associate-*l*N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \color{blue}{\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right)\right) \]
              7. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \color{blue}{\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right)\right) \]
              8. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right)\right) \]
              9. *-commutativeN/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left({y}^{2} \cdot \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
              10. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
              11. unpow2N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
              12. *-lowering-*.f64100.0%

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
            7. Simplified100.0%

              \[\leadsto \cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \color{blue}{y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)}\right)\right)\right) \]
            8. Step-by-step derivation
              1. *-commutativeN/A

                \[\leadsto \left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right) \cdot \color{blue}{\cos x} \]
              2. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right), \color{blue}{\cos x}\right) \]
              3. +-lowering-+.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos \color{blue}{x}\right) \]
              4. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
              5. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
              6. +-lowering-+.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \cos x\right) \]
              7. associate-*r*N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
              8. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\left(y \cdot y\right), \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
              9. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(\left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \cos x\right) \]
              10. associate-*l*N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(y \cdot \left(y \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \cos x\right) \]
              11. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, \left(y \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \cos x\right) \]
              12. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \cos x\right) \]
              13. cos-lowering-cos.f64100.0%

                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
            9. Applied egg-rr100.0%

              \[\leadsto \color{blue}{\left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right) \cdot \cos x} \]
            10. Taylor expanded in y around inf

              \[\leadsto \mathsf{*.f64}\left(\color{blue}{\left(\frac{1}{5040} \cdot {y}^{6}\right)}, \mathsf{cos.f64}\left(x\right)\right) \]
            11. Step-by-step derivation
              1. metadata-evalN/A

                \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{5040} \cdot {y}^{\left(5 + 1\right)}\right), \mathsf{cos.f64}\left(x\right)\right) \]
              2. pow-plusN/A

                \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{5040} \cdot \left({y}^{5} \cdot y\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
              3. associate-*l*N/A

                \[\leadsto \mathsf{*.f64}\left(\left(\left(\frac{1}{5040} \cdot {y}^{5}\right) \cdot y\right), \mathsf{cos.f64}\left(\color{blue}{x}\right)\right) \]
              4. metadata-evalN/A

                \[\leadsto \mathsf{*.f64}\left(\left(\left(\frac{1}{5040} \cdot {y}^{\left(4 + 1\right)}\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
              5. pow-plusN/A

                \[\leadsto \mathsf{*.f64}\left(\left(\left(\frac{1}{5040} \cdot \left({y}^{4} \cdot y\right)\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
              6. associate-*l*N/A

                \[\leadsto \mathsf{*.f64}\left(\left(\left(\left(\frac{1}{5040} \cdot {y}^{4}\right) \cdot y\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
              7. *-commutativeN/A

                \[\leadsto \mathsf{*.f64}\left(\left(\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{4}\right)\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
              8. associate-*r*N/A

                \[\leadsto \mathsf{*.f64}\left(\left(\left(\left(y \cdot \frac{1}{5040}\right) \cdot {y}^{4}\right) \cdot y\right), \mathsf{cos.f64}\left(x\right)\right) \]
              9. associate-*l*N/A

                \[\leadsto \mathsf{*.f64}\left(\left(\left(y \cdot \frac{1}{5040}\right) \cdot \left({y}^{4} \cdot y\right)\right), \mathsf{cos.f64}\left(\color{blue}{x}\right)\right) \]
              10. pow-plusN/A

                \[\leadsto \mathsf{*.f64}\left(\left(\left(y \cdot \frac{1}{5040}\right) \cdot {y}^{\left(4 + 1\right)}\right), \mathsf{cos.f64}\left(x\right)\right) \]
              11. metadata-evalN/A

                \[\leadsto \mathsf{*.f64}\left(\left(\left(y \cdot \frac{1}{5040}\right) \cdot {y}^{5}\right), \mathsf{cos.f64}\left(x\right)\right) \]
              12. associate-*r*N/A

                \[\leadsto \mathsf{*.f64}\left(\left(y \cdot \left(\frac{1}{5040} \cdot {y}^{5}\right)\right), \mathsf{cos.f64}\left(\color{blue}{x}\right)\right) \]
              13. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \left(\frac{1}{5040} \cdot {y}^{5}\right)\right), \mathsf{cos.f64}\left(\color{blue}{x}\right)\right) \]
              14. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{5}\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
              15. metadata-evalN/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{\left(4 + 1\right)}\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
              16. pow-plusN/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{4} \cdot y\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
              17. *-commutativeN/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot {y}^{4}\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
              18. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{4}\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
              19. metadata-evalN/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{\left(2 \cdot 2\right)}\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
              20. pow-sqrN/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{2} \cdot {y}^{2}\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
              21. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left({y}^{2}\right), \left({y}^{2}\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
              22. unpow2N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left(y \cdot y\right), \left({y}^{2}\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
              23. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left({y}^{2}\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
              24. unpow2N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(y \cdot y\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
              25. *-lowering-*.f64100.0%

                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, y\right)\right)\right)\right)\right), \mathsf{cos.f64}\left(x\right)\right) \]
            12. Simplified100.0%

              \[\leadsto \color{blue}{\left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\right)} \cdot \cos x \]
          5. Recombined 3 regimes into one program.
          6. Final simplification94.9%

            \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 31.5:\\ \;\;\;\;\cos x \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)\\ \mathbf{elif}\;y \leq 10^{+52}:\\ \;\;\;\;\frac{\sinh y}{y}\\ \mathbf{else}:\\ \;\;\;\;\cos x \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\right)\\ \end{array} \]
          7. Add Preprocessing

          Alternative 6: 93.0% accurate, 1.6× speedup?

          \[\begin{array}{l} \\ \begin{array}{l} t_0 := \cos x \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)\\ \mathbf{if}\;y \leq 31.5:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;y \leq 3.8 \cdot 10^{+77}:\\ \;\;\;\;\frac{\sinh y}{y}\\ \mathbf{else}:\\ \;\;\;\;t\_0\\ \end{array} \end{array} \]
          (FPCore (x y)
           :precision binary64
           (let* ((t_0
                   (*
                    (cos x)
                    (+
                     1.0
                     (*
                      (* y y)
                      (+ 0.16666666666666666 (* (* y y) 0.008333333333333333)))))))
             (if (<= y 31.5) t_0 (if (<= y 3.8e+77) (/ (sinh y) y) t_0))))
          double code(double x, double y) {
          	double t_0 = cos(x) * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))));
          	double tmp;
          	if (y <= 31.5) {
          		tmp = t_0;
          	} else if (y <= 3.8e+77) {
          		tmp = sinh(y) / y;
          	} else {
          		tmp = t_0;
          	}
          	return tmp;
          }
          
          real(8) function code(x, y)
              real(8), intent (in) :: x
              real(8), intent (in) :: y
              real(8) :: t_0
              real(8) :: tmp
              t_0 = cos(x) * (1.0d0 + ((y * y) * (0.16666666666666666d0 + ((y * y) * 0.008333333333333333d0))))
              if (y <= 31.5d0) then
                  tmp = t_0
              else if (y <= 3.8d+77) then
                  tmp = sinh(y) / y
              else
                  tmp = t_0
              end if
              code = tmp
          end function
          
          public static double code(double x, double y) {
          	double t_0 = Math.cos(x) * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))));
          	double tmp;
          	if (y <= 31.5) {
          		tmp = t_0;
          	} else if (y <= 3.8e+77) {
          		tmp = Math.sinh(y) / y;
          	} else {
          		tmp = t_0;
          	}
          	return tmp;
          }
          
          def code(x, y):
          	t_0 = math.cos(x) * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))))
          	tmp = 0
          	if y <= 31.5:
          		tmp = t_0
          	elif y <= 3.8e+77:
          		tmp = math.sinh(y) / y
          	else:
          		tmp = t_0
          	return tmp
          
          function code(x, y)
          	t_0 = Float64(cos(x) * Float64(1.0 + Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(Float64(y * y) * 0.008333333333333333)))))
          	tmp = 0.0
          	if (y <= 31.5)
          		tmp = t_0;
          	elseif (y <= 3.8e+77)
          		tmp = Float64(sinh(y) / y);
          	else
          		tmp = t_0;
          	end
          	return tmp
          end
          
          function tmp_2 = code(x, y)
          	t_0 = cos(x) * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * 0.008333333333333333))));
          	tmp = 0.0;
          	if (y <= 31.5)
          		tmp = t_0;
          	elseif (y <= 3.8e+77)
          		tmp = sinh(y) / y;
          	else
          		tmp = t_0;
          	end
          	tmp_2 = tmp;
          end
          
          code[x_, y_] := Block[{t$95$0 = N[(N[Cos[x], $MachinePrecision] * N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, 31.5], t$95$0, If[LessEqual[y, 3.8e+77], N[(N[Sinh[y], $MachinePrecision] / y), $MachinePrecision], t$95$0]]]
          
          \begin{array}{l}
          
          \\
          \begin{array}{l}
          t_0 := \cos x \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)\\
          \mathbf{if}\;y \leq 31.5:\\
          \;\;\;\;t\_0\\
          
          \mathbf{elif}\;y \leq 3.8 \cdot 10^{+77}:\\
          \;\;\;\;\frac{\sinh y}{y}\\
          
          \mathbf{else}:\\
          \;\;\;\;t\_0\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 2 regimes
          2. if y < 31.5 or 3.8000000000000001e77 < y

            1. Initial program 100.0%

              \[\cos x \cdot \frac{\sinh y}{y} \]
            2. Add Preprocessing
            3. Taylor expanded in y around 0

              \[\leadsto \color{blue}{\cos x + {y}^{2} \cdot \left(\frac{1}{120} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{6} \cdot \cos x\right)} \]
            4. Step-by-step derivation
              1. *-rgt-identityN/A

                \[\leadsto \cos x \cdot 1 + \color{blue}{{y}^{2}} \cdot \left(\frac{1}{120} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{6} \cdot \cos x\right) \]
              2. *-commutativeN/A

                \[\leadsto \cos x \cdot 1 + \left(\frac{1}{120} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{6} \cdot \cos x\right) \cdot \color{blue}{{y}^{2}} \]
              3. associate-*r*N/A

                \[\leadsto \cos x \cdot 1 + \left(\left(\frac{1}{120} \cdot {y}^{2}\right) \cdot \cos x + \frac{1}{6} \cdot \cos x\right) \cdot {y}^{2} \]
              4. distribute-rgt-outN/A

                \[\leadsto \cos x \cdot 1 + \left(\cos x \cdot \left(\frac{1}{120} \cdot {y}^{2} + \frac{1}{6}\right)\right) \cdot {\color{blue}{y}}^{2} \]
              5. +-commutativeN/A

                \[\leadsto \cos x \cdot 1 + \left(\cos x \cdot \left(\frac{1}{6} + \frac{1}{120} \cdot {y}^{2}\right)\right) \cdot {y}^{2} \]
              6. associate-*l*N/A

                \[\leadsto \cos x \cdot 1 + \cos x \cdot \color{blue}{\left(\left(\frac{1}{6} + \frac{1}{120} \cdot {y}^{2}\right) \cdot {y}^{2}\right)} \]
              7. *-commutativeN/A

                \[\leadsto \cos x \cdot 1 + \cos x \cdot \left({y}^{2} \cdot \color{blue}{\left(\frac{1}{6} + \frac{1}{120} \cdot {y}^{2}\right)}\right) \]
              8. distribute-lft-inN/A

                \[\leadsto \cos x \cdot \color{blue}{\left(1 + {y}^{2} \cdot \left(\frac{1}{6} + \frac{1}{120} \cdot {y}^{2}\right)\right)} \]
              9. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\cos x, \color{blue}{\left(1 + {y}^{2} \cdot \left(\frac{1}{6} + \frac{1}{120} \cdot {y}^{2}\right)\right)}\right) \]
              10. cos-lowering-cos.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \left(\color{blue}{1} + {y}^{2} \cdot \left(\frac{1}{6} + \frac{1}{120} \cdot {y}^{2}\right)\right)\right) \]
              11. +-lowering-+.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \color{blue}{\left({y}^{2} \cdot \left(\frac{1}{6} + \frac{1}{120} \cdot {y}^{2}\right)\right)}\right)\right) \]
              12. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\left(\frac{1}{6} + \frac{1}{120} \cdot {y}^{2}\right)}\right)\right)\right) \]
              13. unpow2N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(y \cdot y\right), \left(\color{blue}{\frac{1}{6}} + \frac{1}{120} \cdot {y}^{2}\right)\right)\right)\right) \]
              14. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(\color{blue}{\frac{1}{6}} + \frac{1}{120} \cdot {y}^{2}\right)\right)\right)\right) \]
              15. +-lowering-+.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \color{blue}{\left(\frac{1}{120} \cdot {y}^{2}\right)}\right)\right)\right)\right) \]
              16. *-commutativeN/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \color{blue}{\frac{1}{120}}\right)\right)\right)\right)\right) \]
              17. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{120}}\right)\right)\right)\right)\right) \]
            5. Simplified95.0%

              \[\leadsto \color{blue}{\cos x \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)} \]

            if 31.5 < y < 3.8000000000000001e77

            1. Initial program 100.0%

              \[\cos x \cdot \frac{\sinh y}{y} \]
            2. Add Preprocessing
            3. Taylor expanded in x around 0

              \[\leadsto \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
            4. Step-by-step derivation
              1. Simplified86.7%

                \[\leadsto \color{blue}{1} \cdot \frac{\sinh y}{y} \]
              2. Step-by-step derivation
                1. *-lft-identityN/A

                  \[\leadsto \frac{\sinh y}{\color{blue}{y}} \]
                2. /-lowering-/.f64N/A

                  \[\leadsto \mathsf{/.f64}\left(\sinh y, \color{blue}{y}\right) \]
                3. sinh-lowering-sinh.f6486.7%

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right) \]
              3. Applied egg-rr86.7%

                \[\leadsto \color{blue}{\frac{\sinh y}{y}} \]
            5. Recombined 2 regimes into one program.
            6. Add Preprocessing

            Alternative 7: 85.6% accurate, 1.8× speedup?

            \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq 31.5:\\ \;\;\;\;\cos x \cdot \left(1 + y \cdot \left(y \cdot 0.16666666666666666\right)\right)\\ \mathbf{elif}\;y \leq 3.8 \cdot 10^{+154}:\\ \;\;\;\;\frac{\sinh y}{y}\\ \mathbf{else}:\\ \;\;\;\;y \cdot \left(y \cdot \left(\cos x \cdot 0.16666666666666666\right)\right)\\ \end{array} \end{array} \]
            (FPCore (x y)
             :precision binary64
             (if (<= y 31.5)
               (* (cos x) (+ 1.0 (* y (* y 0.16666666666666666))))
               (if (<= y 3.8e+154)
                 (/ (sinh y) y)
                 (* y (* y (* (cos x) 0.16666666666666666))))))
            double code(double x, double y) {
            	double tmp;
            	if (y <= 31.5) {
            		tmp = cos(x) * (1.0 + (y * (y * 0.16666666666666666)));
            	} else if (y <= 3.8e+154) {
            		tmp = sinh(y) / y;
            	} else {
            		tmp = y * (y * (cos(x) * 0.16666666666666666));
            	}
            	return tmp;
            }
            
            real(8) function code(x, y)
                real(8), intent (in) :: x
                real(8), intent (in) :: y
                real(8) :: tmp
                if (y <= 31.5d0) then
                    tmp = cos(x) * (1.0d0 + (y * (y * 0.16666666666666666d0)))
                else if (y <= 3.8d+154) then
                    tmp = sinh(y) / y
                else
                    tmp = y * (y * (cos(x) * 0.16666666666666666d0))
                end if
                code = tmp
            end function
            
            public static double code(double x, double y) {
            	double tmp;
            	if (y <= 31.5) {
            		tmp = Math.cos(x) * (1.0 + (y * (y * 0.16666666666666666)));
            	} else if (y <= 3.8e+154) {
            		tmp = Math.sinh(y) / y;
            	} else {
            		tmp = y * (y * (Math.cos(x) * 0.16666666666666666));
            	}
            	return tmp;
            }
            
            def code(x, y):
            	tmp = 0
            	if y <= 31.5:
            		tmp = math.cos(x) * (1.0 + (y * (y * 0.16666666666666666)))
            	elif y <= 3.8e+154:
            		tmp = math.sinh(y) / y
            	else:
            		tmp = y * (y * (math.cos(x) * 0.16666666666666666))
            	return tmp
            
            function code(x, y)
            	tmp = 0.0
            	if (y <= 31.5)
            		tmp = Float64(cos(x) * Float64(1.0 + Float64(y * Float64(y * 0.16666666666666666))));
            	elseif (y <= 3.8e+154)
            		tmp = Float64(sinh(y) / y);
            	else
            		tmp = Float64(y * Float64(y * Float64(cos(x) * 0.16666666666666666)));
            	end
            	return tmp
            end
            
            function tmp_2 = code(x, y)
            	tmp = 0.0;
            	if (y <= 31.5)
            		tmp = cos(x) * (1.0 + (y * (y * 0.16666666666666666)));
            	elseif (y <= 3.8e+154)
            		tmp = sinh(y) / y;
            	else
            		tmp = y * (y * (cos(x) * 0.16666666666666666));
            	end
            	tmp_2 = tmp;
            end
            
            code[x_, y_] := If[LessEqual[y, 31.5], N[(N[Cos[x], $MachinePrecision] * N[(1.0 + N[(y * N[(y * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3.8e+154], N[(N[Sinh[y], $MachinePrecision] / y), $MachinePrecision], N[(y * N[(y * N[(N[Cos[x], $MachinePrecision] * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
            
            \begin{array}{l}
            
            \\
            \begin{array}{l}
            \mathbf{if}\;y \leq 31.5:\\
            \;\;\;\;\cos x \cdot \left(1 + y \cdot \left(y \cdot 0.16666666666666666\right)\right)\\
            
            \mathbf{elif}\;y \leq 3.8 \cdot 10^{+154}:\\
            \;\;\;\;\frac{\sinh y}{y}\\
            
            \mathbf{else}:\\
            \;\;\;\;y \cdot \left(y \cdot \left(\cos x \cdot 0.16666666666666666\right)\right)\\
            
            
            \end{array}
            \end{array}
            
            Derivation
            1. Split input into 3 regimes
            2. if y < 31.5

              1. Initial program 100.0%

                \[\cos x \cdot \frac{\sinh y}{y} \]
              2. Add Preprocessing
              3. Taylor expanded in y around 0

                \[\leadsto \color{blue}{\cos x + \frac{1}{6} \cdot \left({y}^{2} \cdot \cos x\right)} \]
              4. Step-by-step derivation
                1. *-lft-identityN/A

                  \[\leadsto 1 \cdot \cos x + \color{blue}{\frac{1}{6}} \cdot \left({y}^{2} \cdot \cos x\right) \]
                2. associate-*r*N/A

                  \[\leadsto 1 \cdot \cos x + \left(\frac{1}{6} \cdot {y}^{2}\right) \cdot \color{blue}{\cos x} \]
                3. distribute-rgt-inN/A

                  \[\leadsto \cos x \cdot \color{blue}{\left(1 + \frac{1}{6} \cdot {y}^{2}\right)} \]
                4. *-lowering-*.f64N/A

                  \[\leadsto \mathsf{*.f64}\left(\cos x, \color{blue}{\left(1 + \frac{1}{6} \cdot {y}^{2}\right)}\right) \]
                5. cos-lowering-cos.f64N/A

                  \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \left(\color{blue}{1} + \frac{1}{6} \cdot {y}^{2}\right)\right) \]
                6. +-lowering-+.f64N/A

                  \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)}\right)\right) \]
                7. unpow2N/A

                  \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \left(\frac{1}{6} \cdot \left(y \cdot \color{blue}{y}\right)\right)\right)\right) \]
                8. associate-*r*N/A

                  \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \left(\left(\frac{1}{6} \cdot y\right) \cdot \color{blue}{y}\right)\right)\right) \]
                9. *-commutativeN/A

                  \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \left(y \cdot \color{blue}{\left(\frac{1}{6} \cdot y\right)}\right)\right)\right) \]
                10. *-lowering-*.f64N/A

                  \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{6} \cdot y\right)}\right)\right)\right) \]
                11. *-commutativeN/A

                  \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \color{blue}{\frac{1}{6}}\right)\right)\right)\right) \]
                12. *-lowering-*.f6489.6%

                  \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\frac{1}{6}}\right)\right)\right)\right) \]
              5. Simplified89.6%

                \[\leadsto \color{blue}{\cos x \cdot \left(1 + y \cdot \left(y \cdot 0.16666666666666666\right)\right)} \]

              if 31.5 < y < 3.7999999999999998e154

              1. Initial program 100.0%

                \[\cos x \cdot \frac{\sinh y}{y} \]
              2. Add Preprocessing
              3. Taylor expanded in x around 0

                \[\leadsto \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
              4. Step-by-step derivation
                1. Simplified80.6%

                  \[\leadsto \color{blue}{1} \cdot \frac{\sinh y}{y} \]
                2. Step-by-step derivation
                  1. *-lft-identityN/A

                    \[\leadsto \frac{\sinh y}{\color{blue}{y}} \]
                  2. /-lowering-/.f64N/A

                    \[\leadsto \mathsf{/.f64}\left(\sinh y, \color{blue}{y}\right) \]
                  3. sinh-lowering-sinh.f6480.6%

                    \[\leadsto \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right) \]
                3. Applied egg-rr80.6%

                  \[\leadsto \color{blue}{\frac{\sinh y}{y}} \]

                if 3.7999999999999998e154 < y

                1. Initial program 100.0%

                  \[\cos x \cdot \frac{\sinh y}{y} \]
                2. Add Preprocessing
                3. Taylor expanded in y around 0

                  \[\leadsto \color{blue}{\cos x + \frac{1}{6} \cdot \left({y}^{2} \cdot \cos x\right)} \]
                4. Step-by-step derivation
                  1. *-lft-identityN/A

                    \[\leadsto 1 \cdot \cos x + \color{blue}{\frac{1}{6}} \cdot \left({y}^{2} \cdot \cos x\right) \]
                  2. associate-*r*N/A

                    \[\leadsto 1 \cdot \cos x + \left(\frac{1}{6} \cdot {y}^{2}\right) \cdot \color{blue}{\cos x} \]
                  3. distribute-rgt-inN/A

                    \[\leadsto \cos x \cdot \color{blue}{\left(1 + \frac{1}{6} \cdot {y}^{2}\right)} \]
                  4. *-lowering-*.f64N/A

                    \[\leadsto \mathsf{*.f64}\left(\cos x, \color{blue}{\left(1 + \frac{1}{6} \cdot {y}^{2}\right)}\right) \]
                  5. cos-lowering-cos.f64N/A

                    \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \left(\color{blue}{1} + \frac{1}{6} \cdot {y}^{2}\right)\right) \]
                  6. +-lowering-+.f64N/A

                    \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)}\right)\right) \]
                  7. unpow2N/A

                    \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \left(\frac{1}{6} \cdot \left(y \cdot \color{blue}{y}\right)\right)\right)\right) \]
                  8. associate-*r*N/A

                    \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \left(\left(\frac{1}{6} \cdot y\right) \cdot \color{blue}{y}\right)\right)\right) \]
                  9. *-commutativeN/A

                    \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \left(y \cdot \color{blue}{\left(\frac{1}{6} \cdot y\right)}\right)\right)\right) \]
                  10. *-lowering-*.f64N/A

                    \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{6} \cdot y\right)}\right)\right)\right) \]
                  11. *-commutativeN/A

                    \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \color{blue}{\frac{1}{6}}\right)\right)\right)\right) \]
                  12. *-lowering-*.f64100.0%

                    \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\frac{1}{6}}\right)\right)\right)\right) \]
                5. Simplified100.0%

                  \[\leadsto \color{blue}{\cos x \cdot \left(1 + y \cdot \left(y \cdot 0.16666666666666666\right)\right)} \]
                6. Taylor expanded in y around inf

                  \[\leadsto \color{blue}{\frac{1}{6} \cdot \left({y}^{2} \cdot \cos x\right)} \]
                7. Step-by-step derivation
                  1. associate-*r*N/A

                    \[\leadsto \left(\frac{1}{6} \cdot {y}^{2}\right) \cdot \color{blue}{\cos x} \]
                  2. *-commutativeN/A

                    \[\leadsto \left({y}^{2} \cdot \frac{1}{6}\right) \cdot \cos \color{blue}{x} \]
                  3. associate-*r*N/A

                    \[\leadsto {y}^{2} \cdot \color{blue}{\left(\frac{1}{6} \cdot \cos x\right)} \]
                  4. unpow2N/A

                    \[\leadsto \left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{6}} \cdot \cos x\right) \]
                  5. associate-*l*N/A

                    \[\leadsto y \cdot \color{blue}{\left(y \cdot \left(\frac{1}{6} \cdot \cos x\right)\right)} \]
                  6. *-lowering-*.f64N/A

                    \[\leadsto \mathsf{*.f64}\left(y, \color{blue}{\left(y \cdot \left(\frac{1}{6} \cdot \cos x\right)\right)}\right) \]
                  7. *-lowering-*.f64N/A

                    \[\leadsto \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{6} \cdot \cos x\right)}\right)\right) \]
                  8. *-lowering-*.f64N/A

                    \[\leadsto \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{6}, \color{blue}{\cos x}\right)\right)\right) \]
                  9. cos-lowering-cos.f64100.0%

                    \[\leadsto \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{6}, \mathsf{cos.f64}\left(x\right)\right)\right)\right) \]
                8. Simplified100.0%

                  \[\leadsto \color{blue}{y \cdot \left(y \cdot \left(0.16666666666666666 \cdot \cos x\right)\right)} \]
              5. Recombined 3 regimes into one program.
              6. Final simplification90.0%

                \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 31.5:\\ \;\;\;\;\cos x \cdot \left(1 + y \cdot \left(y \cdot 0.16666666666666666\right)\right)\\ \mathbf{elif}\;y \leq 3.8 \cdot 10^{+154}:\\ \;\;\;\;\frac{\sinh y}{y}\\ \mathbf{else}:\\ \;\;\;\;y \cdot \left(y \cdot \left(\cos x \cdot 0.16666666666666666\right)\right)\\ \end{array} \]
              7. Add Preprocessing

              Alternative 8: 72.7% accurate, 1.8× speedup?

              \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq 31.5:\\ \;\;\;\;\cos x\\ \mathbf{elif}\;y \leq 3.9 \cdot 10^{+154}:\\ \;\;\;\;\frac{\sinh y}{y}\\ \mathbf{else}:\\ \;\;\;\;y \cdot \left(y \cdot \left(\cos x \cdot 0.16666666666666666\right)\right)\\ \end{array} \end{array} \]
              (FPCore (x y)
               :precision binary64
               (if (<= y 31.5)
                 (cos x)
                 (if (<= y 3.9e+154)
                   (/ (sinh y) y)
                   (* y (* y (* (cos x) 0.16666666666666666))))))
              double code(double x, double y) {
              	double tmp;
              	if (y <= 31.5) {
              		tmp = cos(x);
              	} else if (y <= 3.9e+154) {
              		tmp = sinh(y) / y;
              	} else {
              		tmp = y * (y * (cos(x) * 0.16666666666666666));
              	}
              	return tmp;
              }
              
              real(8) function code(x, y)
                  real(8), intent (in) :: x
                  real(8), intent (in) :: y
                  real(8) :: tmp
                  if (y <= 31.5d0) then
                      tmp = cos(x)
                  else if (y <= 3.9d+154) then
                      tmp = sinh(y) / y
                  else
                      tmp = y * (y * (cos(x) * 0.16666666666666666d0))
                  end if
                  code = tmp
              end function
              
              public static double code(double x, double y) {
              	double tmp;
              	if (y <= 31.5) {
              		tmp = Math.cos(x);
              	} else if (y <= 3.9e+154) {
              		tmp = Math.sinh(y) / y;
              	} else {
              		tmp = y * (y * (Math.cos(x) * 0.16666666666666666));
              	}
              	return tmp;
              }
              
              def code(x, y):
              	tmp = 0
              	if y <= 31.5:
              		tmp = math.cos(x)
              	elif y <= 3.9e+154:
              		tmp = math.sinh(y) / y
              	else:
              		tmp = y * (y * (math.cos(x) * 0.16666666666666666))
              	return tmp
              
              function code(x, y)
              	tmp = 0.0
              	if (y <= 31.5)
              		tmp = cos(x);
              	elseif (y <= 3.9e+154)
              		tmp = Float64(sinh(y) / y);
              	else
              		tmp = Float64(y * Float64(y * Float64(cos(x) * 0.16666666666666666)));
              	end
              	return tmp
              end
              
              function tmp_2 = code(x, y)
              	tmp = 0.0;
              	if (y <= 31.5)
              		tmp = cos(x);
              	elseif (y <= 3.9e+154)
              		tmp = sinh(y) / y;
              	else
              		tmp = y * (y * (cos(x) * 0.16666666666666666));
              	end
              	tmp_2 = tmp;
              end
              
              code[x_, y_] := If[LessEqual[y, 31.5], N[Cos[x], $MachinePrecision], If[LessEqual[y, 3.9e+154], N[(N[Sinh[y], $MachinePrecision] / y), $MachinePrecision], N[(y * N[(y * N[(N[Cos[x], $MachinePrecision] * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
              
              \begin{array}{l}
              
              \\
              \begin{array}{l}
              \mathbf{if}\;y \leq 31.5:\\
              \;\;\;\;\cos x\\
              
              \mathbf{elif}\;y \leq 3.9 \cdot 10^{+154}:\\
              \;\;\;\;\frac{\sinh y}{y}\\
              
              \mathbf{else}:\\
              \;\;\;\;y \cdot \left(y \cdot \left(\cos x \cdot 0.16666666666666666\right)\right)\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 3 regimes
              2. if y < 31.5

                1. Initial program 100.0%

                  \[\cos x \cdot \frac{\sinh y}{y} \]
                2. Add Preprocessing
                3. Taylor expanded in y around 0

                  \[\leadsto \color{blue}{\cos x} \]
                4. Step-by-step derivation
                  1. cos-lowering-cos.f6473.9%

                    \[\leadsto \mathsf{cos.f64}\left(x\right) \]
                5. Simplified73.9%

                  \[\leadsto \color{blue}{\cos x} \]

                if 31.5 < y < 3.9000000000000003e154

                1. Initial program 100.0%

                  \[\cos x \cdot \frac{\sinh y}{y} \]
                2. Add Preprocessing
                3. Taylor expanded in x around 0

                  \[\leadsto \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                4. Step-by-step derivation
                  1. Simplified80.6%

                    \[\leadsto \color{blue}{1} \cdot \frac{\sinh y}{y} \]
                  2. Step-by-step derivation
                    1. *-lft-identityN/A

                      \[\leadsto \frac{\sinh y}{\color{blue}{y}} \]
                    2. /-lowering-/.f64N/A

                      \[\leadsto \mathsf{/.f64}\left(\sinh y, \color{blue}{y}\right) \]
                    3. sinh-lowering-sinh.f6480.6%

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right) \]
                  3. Applied egg-rr80.6%

                    \[\leadsto \color{blue}{\frac{\sinh y}{y}} \]

                  if 3.9000000000000003e154 < y

                  1. Initial program 100.0%

                    \[\cos x \cdot \frac{\sinh y}{y} \]
                  2. Add Preprocessing
                  3. Taylor expanded in y around 0

                    \[\leadsto \color{blue}{\cos x + \frac{1}{6} \cdot \left({y}^{2} \cdot \cos x\right)} \]
                  4. Step-by-step derivation
                    1. *-lft-identityN/A

                      \[\leadsto 1 \cdot \cos x + \color{blue}{\frac{1}{6}} \cdot \left({y}^{2} \cdot \cos x\right) \]
                    2. associate-*r*N/A

                      \[\leadsto 1 \cdot \cos x + \left(\frac{1}{6} \cdot {y}^{2}\right) \cdot \color{blue}{\cos x} \]
                    3. distribute-rgt-inN/A

                      \[\leadsto \cos x \cdot \color{blue}{\left(1 + \frac{1}{6} \cdot {y}^{2}\right)} \]
                    4. *-lowering-*.f64N/A

                      \[\leadsto \mathsf{*.f64}\left(\cos x, \color{blue}{\left(1 + \frac{1}{6} \cdot {y}^{2}\right)}\right) \]
                    5. cos-lowering-cos.f64N/A

                      \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \left(\color{blue}{1} + \frac{1}{6} \cdot {y}^{2}\right)\right) \]
                    6. +-lowering-+.f64N/A

                      \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)}\right)\right) \]
                    7. unpow2N/A

                      \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \left(\frac{1}{6} \cdot \left(y \cdot \color{blue}{y}\right)\right)\right)\right) \]
                    8. associate-*r*N/A

                      \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \left(\left(\frac{1}{6} \cdot y\right) \cdot \color{blue}{y}\right)\right)\right) \]
                    9. *-commutativeN/A

                      \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \left(y \cdot \color{blue}{\left(\frac{1}{6} \cdot y\right)}\right)\right)\right) \]
                    10. *-lowering-*.f64N/A

                      \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{6} \cdot y\right)}\right)\right)\right) \]
                    11. *-commutativeN/A

                      \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \color{blue}{\frac{1}{6}}\right)\right)\right)\right) \]
                    12. *-lowering-*.f64100.0%

                      \[\leadsto \mathsf{*.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\frac{1}{6}}\right)\right)\right)\right) \]
                  5. Simplified100.0%

                    \[\leadsto \color{blue}{\cos x \cdot \left(1 + y \cdot \left(y \cdot 0.16666666666666666\right)\right)} \]
                  6. Taylor expanded in y around inf

                    \[\leadsto \color{blue}{\frac{1}{6} \cdot \left({y}^{2} \cdot \cos x\right)} \]
                  7. Step-by-step derivation
                    1. associate-*r*N/A

                      \[\leadsto \left(\frac{1}{6} \cdot {y}^{2}\right) \cdot \color{blue}{\cos x} \]
                    2. *-commutativeN/A

                      \[\leadsto \left({y}^{2} \cdot \frac{1}{6}\right) \cdot \cos \color{blue}{x} \]
                    3. associate-*r*N/A

                      \[\leadsto {y}^{2} \cdot \color{blue}{\left(\frac{1}{6} \cdot \cos x\right)} \]
                    4. unpow2N/A

                      \[\leadsto \left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{6}} \cdot \cos x\right) \]
                    5. associate-*l*N/A

                      \[\leadsto y \cdot \color{blue}{\left(y \cdot \left(\frac{1}{6} \cdot \cos x\right)\right)} \]
                    6. *-lowering-*.f64N/A

                      \[\leadsto \mathsf{*.f64}\left(y, \color{blue}{\left(y \cdot \left(\frac{1}{6} \cdot \cos x\right)\right)}\right) \]
                    7. *-lowering-*.f64N/A

                      \[\leadsto \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{6} \cdot \cos x\right)}\right)\right) \]
                    8. *-lowering-*.f64N/A

                      \[\leadsto \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{6}, \color{blue}{\cos x}\right)\right)\right) \]
                    9. cos-lowering-cos.f64100.0%

                      \[\leadsto \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{6}, \mathsf{cos.f64}\left(x\right)\right)\right)\right) \]
                  8. Simplified100.0%

                    \[\leadsto \color{blue}{y \cdot \left(y \cdot \left(0.16666666666666666 \cdot \cos x\right)\right)} \]
                5. Recombined 3 regimes into one program.
                6. Final simplification78.4%

                  \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 31.5:\\ \;\;\;\;\cos x\\ \mathbf{elif}\;y \leq 3.9 \cdot 10^{+154}:\\ \;\;\;\;\frac{\sinh y}{y}\\ \mathbf{else}:\\ \;\;\;\;y \cdot \left(y \cdot \left(\cos x \cdot 0.16666666666666666\right)\right)\\ \end{array} \]
                7. Add Preprocessing

                Alternative 9: 69.6% accurate, 1.8× speedup?

                \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq 31.5:\\ \;\;\;\;\cos x\\ \mathbf{elif}\;y \leq 10^{+246}:\\ \;\;\;\;\frac{\sinh y}{y}\\ \mathbf{else}:\\ \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\ \end{array} \end{array} \]
                (FPCore (x y)
                 :precision binary64
                 (if (<= y 31.5)
                   (cos x)
                   (if (<= y 1e+246)
                     (/ (sinh y) y)
                     (* (+ 1.0 (* (* x x) -0.5)) (+ 1.0 (* 0.16666666666666666 (* y y)))))))
                double code(double x, double y) {
                	double tmp;
                	if (y <= 31.5) {
                		tmp = cos(x);
                	} else if (y <= 1e+246) {
                		tmp = sinh(y) / y;
                	} else {
                		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                	}
                	return tmp;
                }
                
                real(8) function code(x, y)
                    real(8), intent (in) :: x
                    real(8), intent (in) :: y
                    real(8) :: tmp
                    if (y <= 31.5d0) then
                        tmp = cos(x)
                    else if (y <= 1d+246) then
                        tmp = sinh(y) / y
                    else
                        tmp = (1.0d0 + ((x * x) * (-0.5d0))) * (1.0d0 + (0.16666666666666666d0 * (y * y)))
                    end if
                    code = tmp
                end function
                
                public static double code(double x, double y) {
                	double tmp;
                	if (y <= 31.5) {
                		tmp = Math.cos(x);
                	} else if (y <= 1e+246) {
                		tmp = Math.sinh(y) / y;
                	} else {
                		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                	}
                	return tmp;
                }
                
                def code(x, y):
                	tmp = 0
                	if y <= 31.5:
                		tmp = math.cos(x)
                	elif y <= 1e+246:
                		tmp = math.sinh(y) / y
                	else:
                		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)))
                	return tmp
                
                function code(x, y)
                	tmp = 0.0
                	if (y <= 31.5)
                		tmp = cos(x);
                	elseif (y <= 1e+246)
                		tmp = Float64(sinh(y) / y);
                	else
                		tmp = Float64(Float64(1.0 + Float64(Float64(x * x) * -0.5)) * Float64(1.0 + Float64(0.16666666666666666 * Float64(y * y))));
                	end
                	return tmp
                end
                
                function tmp_2 = code(x, y)
                	tmp = 0.0;
                	if (y <= 31.5)
                		tmp = cos(x);
                	elseif (y <= 1e+246)
                		tmp = sinh(y) / y;
                	else
                		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                	end
                	tmp_2 = tmp;
                end
                
                code[x_, y_] := If[LessEqual[y, 31.5], N[Cos[x], $MachinePrecision], If[LessEqual[y, 1e+246], N[(N[Sinh[y], $MachinePrecision] / y), $MachinePrecision], N[(N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.5), $MachinePrecision]), $MachinePrecision] * N[(1.0 + N[(0.16666666666666666 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
                
                \begin{array}{l}
                
                \\
                \begin{array}{l}
                \mathbf{if}\;y \leq 31.5:\\
                \;\;\;\;\cos x\\
                
                \mathbf{elif}\;y \leq 10^{+246}:\\
                \;\;\;\;\frac{\sinh y}{y}\\
                
                \mathbf{else}:\\
                \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\
                
                
                \end{array}
                \end{array}
                
                Derivation
                1. Split input into 3 regimes
                2. if y < 31.5

                  1. Initial program 100.0%

                    \[\cos x \cdot \frac{\sinh y}{y} \]
                  2. Add Preprocessing
                  3. Taylor expanded in y around 0

                    \[\leadsto \color{blue}{\cos x} \]
                  4. Step-by-step derivation
                    1. cos-lowering-cos.f6473.9%

                      \[\leadsto \mathsf{cos.f64}\left(x\right) \]
                  5. Simplified73.9%

                    \[\leadsto \color{blue}{\cos x} \]

                  if 31.5 < y < 1.00000000000000007e246

                  1. Initial program 100.0%

                    \[\cos x \cdot \frac{\sinh y}{y} \]
                  2. Add Preprocessing
                  3. Taylor expanded in x around 0

                    \[\leadsto \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                  4. Step-by-step derivation
                    1. Simplified86.0%

                      \[\leadsto \color{blue}{1} \cdot \frac{\sinh y}{y} \]
                    2. Step-by-step derivation
                      1. *-lft-identityN/A

                        \[\leadsto \frac{\sinh y}{\color{blue}{y}} \]
                      2. /-lowering-/.f64N/A

                        \[\leadsto \mathsf{/.f64}\left(\sinh y, \color{blue}{y}\right) \]
                      3. sinh-lowering-sinh.f6486.0%

                        \[\leadsto \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right) \]
                    3. Applied egg-rr86.0%

                      \[\leadsto \color{blue}{\frac{\sinh y}{y}} \]

                    if 1.00000000000000007e246 < y

                    1. Initial program 100.0%

                      \[\cos x \cdot \frac{\sinh y}{y} \]
                    2. Add Preprocessing
                    3. Taylor expanded in x around 0

                      \[\leadsto \mathsf{*.f64}\left(\color{blue}{\left(1 + \frac{-1}{2} \cdot {x}^{2}\right)}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                    4. Step-by-step derivation
                      1. +-lowering-+.f64N/A

                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left(\frac{-1}{2} \cdot {x}^{2}\right)\right), \mathsf{/.f64}\left(\color{blue}{\mathsf{sinh.f64}\left(y\right)}, y\right)\right) \]
                      2. *-commutativeN/A

                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left({x}^{2} \cdot \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                      3. *-lowering-*.f64N/A

                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({x}^{2}\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                      4. unpow2N/A

                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(x \cdot x\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                      5. *-lowering-*.f6482.4%

                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                    5. Simplified82.4%

                      \[\leadsto \color{blue}{\left(1 + \left(x \cdot x\right) \cdot -0.5\right)} \cdot \frac{\sinh y}{y} \]
                    6. Taylor expanded in y around 0

                      \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \color{blue}{\left(1 + \frac{1}{6} \cdot {y}^{2}\right)}\right) \]
                    7. Step-by-step derivation
                      1. +-lowering-+.f64N/A

                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)}\right)\right) \]
                      2. *-commutativeN/A

                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \left({y}^{2} \cdot \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                      3. *-lowering-*.f64N/A

                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                      4. unpow2N/A

                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{6}\right)\right)\right) \]
                      5. *-lowering-*.f6482.4%

                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{6}\right)\right)\right) \]
                    8. Simplified82.4%

                      \[\leadsto \left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \color{blue}{\left(1 + \left(y \cdot y\right) \cdot 0.16666666666666666\right)} \]
                  5. Recombined 3 regimes into one program.
                  6. Final simplification76.8%

                    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 31.5:\\ \;\;\;\;\cos x\\ \mathbf{elif}\;y \leq 10^{+246}:\\ \;\;\;\;\frac{\sinh y}{y}\\ \mathbf{else}:\\ \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\ \end{array} \]
                  7. Add Preprocessing

                  Alternative 10: 68.3% accurate, 1.9× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} t_0 := \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\\ t_1 := y \cdot t\_0\\ \mathbf{if}\;y \leq 59000:\\ \;\;\;\;\cos x\\ \mathbf{elif}\;y \leq 3.35 \cdot 10^{+44}:\\ \;\;\;\;\frac{\frac{y \cdot y - t\_1 \cdot t\_1}{y - t\_1}}{y}\\ \mathbf{elif}\;y \leq 2 \cdot 10^{+244}:\\ \;\;\;\;\frac{y \cdot \left(1 + t\_0\right)}{y}\\ \mathbf{else}:\\ \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\ \end{array} \end{array} \]
                  (FPCore (x y)
                   :precision binary64
                   (let* ((t_0
                           (*
                            (* y y)
                            (+
                             0.16666666666666666
                             (*
                              (* y y)
                              (+ 0.008333333333333333 (* y (* y 0.0001984126984126984)))))))
                          (t_1 (* y t_0)))
                     (if (<= y 59000.0)
                       (cos x)
                       (if (<= y 3.35e+44)
                         (/ (/ (- (* y y) (* t_1 t_1)) (- y t_1)) y)
                         (if (<= y 2e+244)
                           (/ (* y (+ 1.0 t_0)) y)
                           (*
                            (+ 1.0 (* (* x x) -0.5))
                            (+ 1.0 (* 0.16666666666666666 (* y y)))))))))
                  double code(double x, double y) {
                  	double t_0 = (y * y) * (0.16666666666666666 + ((y * y) * (0.008333333333333333 + (y * (y * 0.0001984126984126984)))));
                  	double t_1 = y * t_0;
                  	double tmp;
                  	if (y <= 59000.0) {
                  		tmp = cos(x);
                  	} else if (y <= 3.35e+44) {
                  		tmp = (((y * y) - (t_1 * t_1)) / (y - t_1)) / y;
                  	} else if (y <= 2e+244) {
                  		tmp = (y * (1.0 + t_0)) / y;
                  	} else {
                  		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                  	}
                  	return tmp;
                  }
                  
                  real(8) function code(x, y)
                      real(8), intent (in) :: x
                      real(8), intent (in) :: y
                      real(8) :: t_0
                      real(8) :: t_1
                      real(8) :: tmp
                      t_0 = (y * y) * (0.16666666666666666d0 + ((y * y) * (0.008333333333333333d0 + (y * (y * 0.0001984126984126984d0)))))
                      t_1 = y * t_0
                      if (y <= 59000.0d0) then
                          tmp = cos(x)
                      else if (y <= 3.35d+44) then
                          tmp = (((y * y) - (t_1 * t_1)) / (y - t_1)) / y
                      else if (y <= 2d+244) then
                          tmp = (y * (1.0d0 + t_0)) / y
                      else
                          tmp = (1.0d0 + ((x * x) * (-0.5d0))) * (1.0d0 + (0.16666666666666666d0 * (y * y)))
                      end if
                      code = tmp
                  end function
                  
                  public static double code(double x, double y) {
                  	double t_0 = (y * y) * (0.16666666666666666 + ((y * y) * (0.008333333333333333 + (y * (y * 0.0001984126984126984)))));
                  	double t_1 = y * t_0;
                  	double tmp;
                  	if (y <= 59000.0) {
                  		tmp = Math.cos(x);
                  	} else if (y <= 3.35e+44) {
                  		tmp = (((y * y) - (t_1 * t_1)) / (y - t_1)) / y;
                  	} else if (y <= 2e+244) {
                  		tmp = (y * (1.0 + t_0)) / y;
                  	} else {
                  		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                  	}
                  	return tmp;
                  }
                  
                  def code(x, y):
                  	t_0 = (y * y) * (0.16666666666666666 + ((y * y) * (0.008333333333333333 + (y * (y * 0.0001984126984126984)))))
                  	t_1 = y * t_0
                  	tmp = 0
                  	if y <= 59000.0:
                  		tmp = math.cos(x)
                  	elif y <= 3.35e+44:
                  		tmp = (((y * y) - (t_1 * t_1)) / (y - t_1)) / y
                  	elif y <= 2e+244:
                  		tmp = (y * (1.0 + t_0)) / y
                  	else:
                  		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)))
                  	return tmp
                  
                  function code(x, y)
                  	t_0 = Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(Float64(y * y) * Float64(0.008333333333333333 + Float64(y * Float64(y * 0.0001984126984126984))))))
                  	t_1 = Float64(y * t_0)
                  	tmp = 0.0
                  	if (y <= 59000.0)
                  		tmp = cos(x);
                  	elseif (y <= 3.35e+44)
                  		tmp = Float64(Float64(Float64(Float64(y * y) - Float64(t_1 * t_1)) / Float64(y - t_1)) / y);
                  	elseif (y <= 2e+244)
                  		tmp = Float64(Float64(y * Float64(1.0 + t_0)) / y);
                  	else
                  		tmp = Float64(Float64(1.0 + Float64(Float64(x * x) * -0.5)) * Float64(1.0 + Float64(0.16666666666666666 * Float64(y * y))));
                  	end
                  	return tmp
                  end
                  
                  function tmp_2 = code(x, y)
                  	t_0 = (y * y) * (0.16666666666666666 + ((y * y) * (0.008333333333333333 + (y * (y * 0.0001984126984126984)))));
                  	t_1 = y * t_0;
                  	tmp = 0.0;
                  	if (y <= 59000.0)
                  		tmp = cos(x);
                  	elseif (y <= 3.35e+44)
                  		tmp = (((y * y) - (t_1 * t_1)) / (y - t_1)) / y;
                  	elseif (y <= 2e+244)
                  		tmp = (y * (1.0 + t_0)) / y;
                  	else
                  		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                  	end
                  	tmp_2 = tmp;
                  end
                  
                  code[x_, y_] := Block[{t$95$0 = N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * N[(0.008333333333333333 + N[(y * N[(y * 0.0001984126984126984), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(y * t$95$0), $MachinePrecision]}, If[LessEqual[y, 59000.0], N[Cos[x], $MachinePrecision], If[LessEqual[y, 3.35e+44], N[(N[(N[(N[(y * y), $MachinePrecision] - N[(t$95$1 * t$95$1), $MachinePrecision]), $MachinePrecision] / N[(y - t$95$1), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[y, 2e+244], N[(N[(y * N[(1.0 + t$95$0), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.5), $MachinePrecision]), $MachinePrecision] * N[(1.0 + N[(0.16666666666666666 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  t_0 := \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\\
                  t_1 := y \cdot t\_0\\
                  \mathbf{if}\;y \leq 59000:\\
                  \;\;\;\;\cos x\\
                  
                  \mathbf{elif}\;y \leq 3.35 \cdot 10^{+44}:\\
                  \;\;\;\;\frac{\frac{y \cdot y - t\_1 \cdot t\_1}{y - t\_1}}{y}\\
                  
                  \mathbf{elif}\;y \leq 2 \cdot 10^{+244}:\\
                  \;\;\;\;\frac{y \cdot \left(1 + t\_0\right)}{y}\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 4 regimes
                  2. if y < 59000

                    1. Initial program 100.0%

                      \[\cos x \cdot \frac{\sinh y}{y} \]
                    2. Add Preprocessing
                    3. Taylor expanded in y around 0

                      \[\leadsto \color{blue}{\cos x} \]
                    4. Step-by-step derivation
                      1. cos-lowering-cos.f6473.9%

                        \[\leadsto \mathsf{cos.f64}\left(x\right) \]
                    5. Simplified73.9%

                      \[\leadsto \color{blue}{\cos x} \]

                    if 59000 < y < 3.35000000000000018e44

                    1. Initial program 100.0%

                      \[\cos x \cdot \frac{\sinh y}{y} \]
                    2. Add Preprocessing
                    3. Taylor expanded in x around 0

                      \[\leadsto \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                    4. Step-by-step derivation
                      1. Simplified100.0%

                        \[\leadsto \color{blue}{1} \cdot \frac{\sinh y}{y} \]
                      2. Taylor expanded in y around 0

                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\color{blue}{\left(y \cdot \left(1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)}, y\right)\right) \]
                      3. Step-by-step derivation
                        1. *-lowering-*.f64N/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right), y\right)\right) \]
                        2. +-lowering-+.f64N/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left({y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right), y\right)\right) \]
                        3. unpow2N/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right), y\right)\right) \]
                        4. associate-*l*N/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left(y \cdot \left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                        5. *-lowering-*.f64N/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                        6. *-lowering-*.f64N/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                        7. +-lowering-+.f64N/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                        8. unpow2N/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                        9. associate-*l*N/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                        10. *-lowering-*.f64N/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                        11. *-lowering-*.f64N/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                        12. +-lowering-+.f64N/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                        13. *-commutativeN/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left({y}^{2} \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                        14. *-lowering-*.f64N/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left({y}^{2}\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                        15. unpow2N/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                        16. *-lowering-*.f645.4%

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                      4. Simplified5.4%

                        \[\leadsto 1 \cdot \frac{\color{blue}{y \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)\right)}}{y} \]
                      5. Step-by-step derivation
                        1. distribute-lft-inN/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\left(y \cdot 1 + y \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                        2. *-rgt-identityN/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\left(y + y \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                        3. flip-+N/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\left(\frac{y \cdot y - \left(y \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right) \cdot \left(y \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)}{y - y \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)}\right), y\right)\right) \]
                        4. *-lft-identityN/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\left(\frac{y \cdot y - \left(y \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right) \cdot \left(y \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)}{1 \cdot y - y \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)}\right), y\right)\right) \]
                        5. fmm-defN/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\left(\frac{y \cdot y - \left(y \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right) \cdot \left(y \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)}{\mathsf{fma}\left(1, y, \mathsf{neg}\left(y \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)}\right), y\right)\right) \]
                        6. *-commutativeN/A

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\left(\frac{y \cdot y - \left(y \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right) \cdot \left(y \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)}{\mathsf{fma}\left(1, y, \mathsf{neg}\left(\left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right) \cdot y\right)\right)}\right), y\right)\right) \]
                      6. Applied egg-rr72.5%

                        \[\leadsto 1 \cdot \frac{\color{blue}{\frac{y \cdot y - \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right) + 0.008333333333333333\right)\right)\right)\right) \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right) + 0.008333333333333333\right)\right)\right)\right)}{y - y \cdot \left(\left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right) + 0.008333333333333333\right)\right)\right)}}}{y} \]

                      if 3.35000000000000018e44 < y < 2.00000000000000015e244

                      1. Initial program 100.0%

                        \[\cos x \cdot \frac{\sinh y}{y} \]
                      2. Add Preprocessing
                      3. Taylor expanded in x around 0

                        \[\leadsto \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                      4. Step-by-step derivation
                        1. Simplified83.7%

                          \[\leadsto \color{blue}{1} \cdot \frac{\sinh y}{y} \]
                        2. Taylor expanded in y around 0

                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\color{blue}{\left(y \cdot \left(1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)}, y\right)\right) \]
                        3. Step-by-step derivation
                          1. *-lowering-*.f64N/A

                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right), y\right)\right) \]
                          2. +-lowering-+.f64N/A

                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left({y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right), y\right)\right) \]
                          3. unpow2N/A

                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right), y\right)\right) \]
                          4. associate-*l*N/A

                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left(y \cdot \left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                          5. *-lowering-*.f64N/A

                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                          6. *-lowering-*.f64N/A

                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                          7. +-lowering-+.f64N/A

                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                          8. unpow2N/A

                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                          9. associate-*l*N/A

                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                          10. *-lowering-*.f64N/A

                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                          11. *-lowering-*.f64N/A

                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                          12. +-lowering-+.f64N/A

                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                          13. *-commutativeN/A

                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left({y}^{2} \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                          14. *-lowering-*.f64N/A

                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left({y}^{2}\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                          15. unpow2N/A

                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                          16. *-lowering-*.f6483.7%

                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                        4. Simplified83.7%

                          \[\leadsto 1 \cdot \frac{\color{blue}{y \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)\right)}}{y} \]
                        5. Step-by-step derivation
                          1. *-lft-identityN/A

                            \[\leadsto \frac{y \cdot \left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)}{\color{blue}{y}} \]
                          2. /-lowering-/.f64N/A

                            \[\leadsto \mathsf{/.f64}\left(\left(y \cdot \left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \color{blue}{y}\right) \]
                        6. Applied egg-rr83.7%

                          \[\leadsto \color{blue}{\frac{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right) + 0.008333333333333333\right)\right)\right)}{y}} \]

                        if 2.00000000000000015e244 < y

                        1. Initial program 100.0%

                          \[\cos x \cdot \frac{\sinh y}{y} \]
                        2. Add Preprocessing
                        3. Taylor expanded in x around 0

                          \[\leadsto \mathsf{*.f64}\left(\color{blue}{\left(1 + \frac{-1}{2} \cdot {x}^{2}\right)}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                        4. Step-by-step derivation
                          1. +-lowering-+.f64N/A

                            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left(\frac{-1}{2} \cdot {x}^{2}\right)\right), \mathsf{/.f64}\left(\color{blue}{\mathsf{sinh.f64}\left(y\right)}, y\right)\right) \]
                          2. *-commutativeN/A

                            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left({x}^{2} \cdot \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                          3. *-lowering-*.f64N/A

                            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({x}^{2}\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                          4. unpow2N/A

                            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(x \cdot x\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                          5. *-lowering-*.f6482.4%

                            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                        5. Simplified82.4%

                          \[\leadsto \color{blue}{\left(1 + \left(x \cdot x\right) \cdot -0.5\right)} \cdot \frac{\sinh y}{y} \]
                        6. Taylor expanded in y around 0

                          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \color{blue}{\left(1 + \frac{1}{6} \cdot {y}^{2}\right)}\right) \]
                        7. Step-by-step derivation
                          1. +-lowering-+.f64N/A

                            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)}\right)\right) \]
                          2. *-commutativeN/A

                            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \left({y}^{2} \cdot \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                          3. *-lowering-*.f64N/A

                            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                          4. unpow2N/A

                            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{6}\right)\right)\right) \]
                          5. *-lowering-*.f6482.4%

                            \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{6}\right)\right)\right) \]
                        8. Simplified82.4%

                          \[\leadsto \left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \color{blue}{\left(1 + \left(y \cdot y\right) \cdot 0.16666666666666666\right)} \]
                      5. Recombined 4 regimes into one program.
                      6. Final simplification76.1%

                        \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 59000:\\ \;\;\;\;\cos x\\ \mathbf{elif}\;y \leq 3.35 \cdot 10^{+44}:\\ \;\;\;\;\frac{\frac{y \cdot y - \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right) \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right)}{y - y \cdot \left(\left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)}}{y}\\ \mathbf{elif}\;y \leq 2 \cdot 10^{+244}:\\ \;\;\;\;\frac{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)}{y}\\ \mathbf{else}:\\ \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\ \end{array} \]
                      7. Add Preprocessing

                      Alternative 11: 46.6% accurate, 3.1× speedup?

                      \[\begin{array}{l} \\ \begin{array}{l} t_0 := 0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\\ t_1 := \left(y \cdot y\right) \cdot t\_0\\ \mathbf{if}\;y \leq 3.35 \cdot 10^{+44}:\\ \;\;\;\;\frac{y \cdot \left(\left(y \cdot t\_1\right) \cdot \left(y \cdot t\_0\right) + -1\right)}{y \cdot \left(t\_1 + -1\right)}\\ \mathbf{elif}\;y \leq 2 \cdot 10^{+249}:\\ \;\;\;\;\frac{y \cdot \left(1 + t\_1\right)}{y}\\ \mathbf{else}:\\ \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\ \end{array} \end{array} \]
                      (FPCore (x y)
                       :precision binary64
                       (let* ((t_0
                               (+
                                0.16666666666666666
                                (*
                                 (* y y)
                                 (+ 0.008333333333333333 (* y (* y 0.0001984126984126984))))))
                              (t_1 (* (* y y) t_0)))
                         (if (<= y 3.35e+44)
                           (/ (* y (+ (* (* y t_1) (* y t_0)) -1.0)) (* y (+ t_1 -1.0)))
                           (if (<= y 2e+249)
                             (/ (* y (+ 1.0 t_1)) y)
                             (* (+ 1.0 (* (* x x) -0.5)) (+ 1.0 (* 0.16666666666666666 (* y y))))))))
                      double code(double x, double y) {
                      	double t_0 = 0.16666666666666666 + ((y * y) * (0.008333333333333333 + (y * (y * 0.0001984126984126984))));
                      	double t_1 = (y * y) * t_0;
                      	double tmp;
                      	if (y <= 3.35e+44) {
                      		tmp = (y * (((y * t_1) * (y * t_0)) + -1.0)) / (y * (t_1 + -1.0));
                      	} else if (y <= 2e+249) {
                      		tmp = (y * (1.0 + t_1)) / y;
                      	} else {
                      		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                      	}
                      	return tmp;
                      }
                      
                      real(8) function code(x, y)
                          real(8), intent (in) :: x
                          real(8), intent (in) :: y
                          real(8) :: t_0
                          real(8) :: t_1
                          real(8) :: tmp
                          t_0 = 0.16666666666666666d0 + ((y * y) * (0.008333333333333333d0 + (y * (y * 0.0001984126984126984d0))))
                          t_1 = (y * y) * t_0
                          if (y <= 3.35d+44) then
                              tmp = (y * (((y * t_1) * (y * t_0)) + (-1.0d0))) / (y * (t_1 + (-1.0d0)))
                          else if (y <= 2d+249) then
                              tmp = (y * (1.0d0 + t_1)) / y
                          else
                              tmp = (1.0d0 + ((x * x) * (-0.5d0))) * (1.0d0 + (0.16666666666666666d0 * (y * y)))
                          end if
                          code = tmp
                      end function
                      
                      public static double code(double x, double y) {
                      	double t_0 = 0.16666666666666666 + ((y * y) * (0.008333333333333333 + (y * (y * 0.0001984126984126984))));
                      	double t_1 = (y * y) * t_0;
                      	double tmp;
                      	if (y <= 3.35e+44) {
                      		tmp = (y * (((y * t_1) * (y * t_0)) + -1.0)) / (y * (t_1 + -1.0));
                      	} else if (y <= 2e+249) {
                      		tmp = (y * (1.0 + t_1)) / y;
                      	} else {
                      		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                      	}
                      	return tmp;
                      }
                      
                      def code(x, y):
                      	t_0 = 0.16666666666666666 + ((y * y) * (0.008333333333333333 + (y * (y * 0.0001984126984126984))))
                      	t_1 = (y * y) * t_0
                      	tmp = 0
                      	if y <= 3.35e+44:
                      		tmp = (y * (((y * t_1) * (y * t_0)) + -1.0)) / (y * (t_1 + -1.0))
                      	elif y <= 2e+249:
                      		tmp = (y * (1.0 + t_1)) / y
                      	else:
                      		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)))
                      	return tmp
                      
                      function code(x, y)
                      	t_0 = Float64(0.16666666666666666 + Float64(Float64(y * y) * Float64(0.008333333333333333 + Float64(y * Float64(y * 0.0001984126984126984)))))
                      	t_1 = Float64(Float64(y * y) * t_0)
                      	tmp = 0.0
                      	if (y <= 3.35e+44)
                      		tmp = Float64(Float64(y * Float64(Float64(Float64(y * t_1) * Float64(y * t_0)) + -1.0)) / Float64(y * Float64(t_1 + -1.0)));
                      	elseif (y <= 2e+249)
                      		tmp = Float64(Float64(y * Float64(1.0 + t_1)) / y);
                      	else
                      		tmp = Float64(Float64(1.0 + Float64(Float64(x * x) * -0.5)) * Float64(1.0 + Float64(0.16666666666666666 * Float64(y * y))));
                      	end
                      	return tmp
                      end
                      
                      function tmp_2 = code(x, y)
                      	t_0 = 0.16666666666666666 + ((y * y) * (0.008333333333333333 + (y * (y * 0.0001984126984126984))));
                      	t_1 = (y * y) * t_0;
                      	tmp = 0.0;
                      	if (y <= 3.35e+44)
                      		tmp = (y * (((y * t_1) * (y * t_0)) + -1.0)) / (y * (t_1 + -1.0));
                      	elseif (y <= 2e+249)
                      		tmp = (y * (1.0 + t_1)) / y;
                      	else
                      		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                      	end
                      	tmp_2 = tmp;
                      end
                      
                      code[x_, y_] := Block[{t$95$0 = N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * N[(0.008333333333333333 + N[(y * N[(y * 0.0001984126984126984), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[(y * y), $MachinePrecision] * t$95$0), $MachinePrecision]}, If[LessEqual[y, 3.35e+44], N[(N[(y * N[(N[(N[(y * t$95$1), $MachinePrecision] * N[(y * t$95$0), $MachinePrecision]), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision] / N[(y * N[(t$95$1 + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2e+249], N[(N[(y * N[(1.0 + t$95$1), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.5), $MachinePrecision]), $MachinePrecision] * N[(1.0 + N[(0.16666666666666666 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
                      
                      \begin{array}{l}
                      
                      \\
                      \begin{array}{l}
                      t_0 := 0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\\
                      t_1 := \left(y \cdot y\right) \cdot t\_0\\
                      \mathbf{if}\;y \leq 3.35 \cdot 10^{+44}:\\
                      \;\;\;\;\frac{y \cdot \left(\left(y \cdot t\_1\right) \cdot \left(y \cdot t\_0\right) + -1\right)}{y \cdot \left(t\_1 + -1\right)}\\
                      
                      \mathbf{elif}\;y \leq 2 \cdot 10^{+249}:\\
                      \;\;\;\;\frac{y \cdot \left(1 + t\_1\right)}{y}\\
                      
                      \mathbf{else}:\\
                      \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\
                      
                      
                      \end{array}
                      \end{array}
                      
                      Derivation
                      1. Split input into 3 regimes
                      2. if y < 3.35000000000000018e44

                        1. Initial program 100.0%

                          \[\cos x \cdot \frac{\sinh y}{y} \]
                        2. Add Preprocessing
                        3. Taylor expanded in x around 0

                          \[\leadsto \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                        4. Step-by-step derivation
                          1. Simplified58.6%

                            \[\leadsto \color{blue}{1} \cdot \frac{\sinh y}{y} \]
                          2. Taylor expanded in y around 0

                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\color{blue}{\left(y \cdot \left(1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)}, y\right)\right) \]
                          3. Step-by-step derivation
                            1. *-lowering-*.f64N/A

                              \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right), y\right)\right) \]
                            2. +-lowering-+.f64N/A

                              \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left({y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right), y\right)\right) \]
                            3. unpow2N/A

                              \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right), y\right)\right) \]
                            4. associate-*l*N/A

                              \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left(y \cdot \left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                            5. *-lowering-*.f64N/A

                              \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                            6. *-lowering-*.f64N/A

                              \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                            7. +-lowering-+.f64N/A

                              \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                            8. unpow2N/A

                              \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                            9. associate-*l*N/A

                              \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                            10. *-lowering-*.f64N/A

                              \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                            11. *-lowering-*.f64N/A

                              \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                            12. +-lowering-+.f64N/A

                              \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                            13. *-commutativeN/A

                              \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left({y}^{2} \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                            14. *-lowering-*.f64N/A

                              \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left({y}^{2}\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                            15. unpow2N/A

                              \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                            16. *-lowering-*.f6453.7%

                              \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                          4. Simplified53.7%

                            \[\leadsto 1 \cdot \frac{\color{blue}{y \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)\right)}}{y} \]
                          5. Step-by-step derivation
                            1. *-lft-identityN/A

                              \[\leadsto \frac{y \cdot \left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)}{\color{blue}{y}} \]
                            2. *-commutativeN/A

                              \[\leadsto \frac{\left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right) \cdot y}{y} \]
                            3. associate-/l*N/A

                              \[\leadsto \left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right) \cdot \color{blue}{\frac{y}{y}} \]
                            4. +-commutativeN/A

                              \[\leadsto \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right) + 1\right) \cdot \frac{\color{blue}{y}}{y} \]
                            5. flip-+N/A

                              \[\leadsto \frac{\left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right) \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right) - 1 \cdot 1}{y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right) - 1} \cdot \frac{\color{blue}{y}}{y} \]
                            6. frac-timesN/A

                              \[\leadsto \frac{\left(\left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right) \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right) - 1 \cdot 1\right) \cdot y}{\color{blue}{\left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right) - 1\right) \cdot y}} \]
                            7. /-lowering-/.f64N/A

                              \[\leadsto \mathsf{/.f64}\left(\left(\left(\left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right) \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right) - 1 \cdot 1\right) \cdot y\right), \color{blue}{\left(\left(y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right) - 1\right) \cdot y\right)}\right) \]
                          6. Applied egg-rr38.2%

                            \[\leadsto \color{blue}{\frac{\left(\left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right) + 0.008333333333333333\right)\right)\right) \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right) + 0.008333333333333333\right)\right)\right)\right) - 1\right) \cdot y}{\left(\left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right) + 0.008333333333333333\right)\right) - 1\right) \cdot y}} \]

                          if 3.35000000000000018e44 < y < 1.9999999999999998e249

                          1. Initial program 100.0%

                            \[\cos x \cdot \frac{\sinh y}{y} \]
                          2. Add Preprocessing
                          3. Taylor expanded in x around 0

                            \[\leadsto \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                          4. Step-by-step derivation
                            1. Simplified83.7%

                              \[\leadsto \color{blue}{1} \cdot \frac{\sinh y}{y} \]
                            2. Taylor expanded in y around 0

                              \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\color{blue}{\left(y \cdot \left(1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)}, y\right)\right) \]
                            3. Step-by-step derivation
                              1. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right), y\right)\right) \]
                              2. +-lowering-+.f64N/A

                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left({y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right), y\right)\right) \]
                              3. unpow2N/A

                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right), y\right)\right) \]
                              4. associate-*l*N/A

                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left(y \cdot \left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                              5. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                              6. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                              7. +-lowering-+.f64N/A

                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                              8. unpow2N/A

                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                              9. associate-*l*N/A

                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                              10. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                              11. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                              12. +-lowering-+.f64N/A

                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                              13. *-commutativeN/A

                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left({y}^{2} \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                              14. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left({y}^{2}\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                              15. unpow2N/A

                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                              16. *-lowering-*.f6483.7%

                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                            4. Simplified83.7%

                              \[\leadsto 1 \cdot \frac{\color{blue}{y \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)\right)}}{y} \]
                            5. Step-by-step derivation
                              1. *-lft-identityN/A

                                \[\leadsto \frac{y \cdot \left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)}{\color{blue}{y}} \]
                              2. /-lowering-/.f64N/A

                                \[\leadsto \mathsf{/.f64}\left(\left(y \cdot \left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \color{blue}{y}\right) \]
                            6. Applied egg-rr83.7%

                              \[\leadsto \color{blue}{\frac{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right) + 0.008333333333333333\right)\right)\right)}{y}} \]

                            if 1.9999999999999998e249 < y

                            1. Initial program 100.0%

                              \[\cos x \cdot \frac{\sinh y}{y} \]
                            2. Add Preprocessing
                            3. Taylor expanded in x around 0

                              \[\leadsto \mathsf{*.f64}\left(\color{blue}{\left(1 + \frac{-1}{2} \cdot {x}^{2}\right)}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                            4. Step-by-step derivation
                              1. +-lowering-+.f64N/A

                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left(\frac{-1}{2} \cdot {x}^{2}\right)\right), \mathsf{/.f64}\left(\color{blue}{\mathsf{sinh.f64}\left(y\right)}, y\right)\right) \]
                              2. *-commutativeN/A

                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left({x}^{2} \cdot \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                              3. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({x}^{2}\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                              4. unpow2N/A

                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(x \cdot x\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                              5. *-lowering-*.f6482.4%

                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                            5. Simplified82.4%

                              \[\leadsto \color{blue}{\left(1 + \left(x \cdot x\right) \cdot -0.5\right)} \cdot \frac{\sinh y}{y} \]
                            6. Taylor expanded in y around 0

                              \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \color{blue}{\left(1 + \frac{1}{6} \cdot {y}^{2}\right)}\right) \]
                            7. Step-by-step derivation
                              1. +-lowering-+.f64N/A

                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)}\right)\right) \]
                              2. *-commutativeN/A

                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \left({y}^{2} \cdot \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                              3. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                              4. unpow2N/A

                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{6}\right)\right)\right) \]
                              5. *-lowering-*.f6482.4%

                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{6}\right)\right)\right) \]
                            8. Simplified82.4%

                              \[\leadsto \left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \color{blue}{\left(1 + \left(y \cdot y\right) \cdot 0.16666666666666666\right)} \]
                          5. Recombined 3 regimes into one program.
                          6. Final simplification48.8%

                            \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 3.35 \cdot 10^{+44}:\\ \;\;\;\;\frac{y \cdot \left(\left(y \cdot \left(\left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right) \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right) + -1\right)}{y \cdot \left(\left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right) + -1\right)}\\ \mathbf{elif}\;y \leq 2 \cdot 10^{+249}:\\ \;\;\;\;\frac{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)}{y}\\ \mathbf{else}:\\ \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\ \end{array} \]
                          7. Add Preprocessing

                          Alternative 12: 52.5% accurate, 4.7× speedup?

                          \[\begin{array}{l} \\ \begin{array}{l} t_0 := 0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\\ t_1 := y \cdot t\_0\\ \mathbf{if}\;y \leq 3.35 \cdot 10^{+44}:\\ \;\;\;\;1 + \frac{\left(y \cdot y\right) \cdot \left(0.027777777777777776 - \left(y \cdot y\right) \cdot \left(t\_1 \cdot t\_1\right)\right)}{0.16666666666666666 - \left(y \cdot y\right) \cdot 0.008333333333333333}\\ \mathbf{elif}\;y \leq 10^{+250}:\\ \;\;\;\;\frac{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot t\_0\right)\right)}{y}\\ \mathbf{else}:\\ \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\ \end{array} \end{array} \]
                          (FPCore (x y)
                           :precision binary64
                           (let* ((t_0 (+ 0.008333333333333333 (* y (* y 0.0001984126984126984))))
                                  (t_1 (* y t_0)))
                             (if (<= y 3.35e+44)
                               (+
                                1.0
                                (/
                                 (* (* y y) (- 0.027777777777777776 (* (* y y) (* t_1 t_1))))
                                 (- 0.16666666666666666 (* (* y y) 0.008333333333333333))))
                               (if (<= y 1e+250)
                                 (/ (* y (+ 1.0 (* (* y y) (+ 0.16666666666666666 (* (* y y) t_0))))) y)
                                 (* (+ 1.0 (* (* x x) -0.5)) (+ 1.0 (* 0.16666666666666666 (* y y))))))))
                          double code(double x, double y) {
                          	double t_0 = 0.008333333333333333 + (y * (y * 0.0001984126984126984));
                          	double t_1 = y * t_0;
                          	double tmp;
                          	if (y <= 3.35e+44) {
                          		tmp = 1.0 + (((y * y) * (0.027777777777777776 - ((y * y) * (t_1 * t_1)))) / (0.16666666666666666 - ((y * y) * 0.008333333333333333)));
                          	} else if (y <= 1e+250) {
                          		tmp = (y * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * t_0))))) / y;
                          	} else {
                          		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                          	}
                          	return tmp;
                          }
                          
                          real(8) function code(x, y)
                              real(8), intent (in) :: x
                              real(8), intent (in) :: y
                              real(8) :: t_0
                              real(8) :: t_1
                              real(8) :: tmp
                              t_0 = 0.008333333333333333d0 + (y * (y * 0.0001984126984126984d0))
                              t_1 = y * t_0
                              if (y <= 3.35d+44) then
                                  tmp = 1.0d0 + (((y * y) * (0.027777777777777776d0 - ((y * y) * (t_1 * t_1)))) / (0.16666666666666666d0 - ((y * y) * 0.008333333333333333d0)))
                              else if (y <= 1d+250) then
                                  tmp = (y * (1.0d0 + ((y * y) * (0.16666666666666666d0 + ((y * y) * t_0))))) / y
                              else
                                  tmp = (1.0d0 + ((x * x) * (-0.5d0))) * (1.0d0 + (0.16666666666666666d0 * (y * y)))
                              end if
                              code = tmp
                          end function
                          
                          public static double code(double x, double y) {
                          	double t_0 = 0.008333333333333333 + (y * (y * 0.0001984126984126984));
                          	double t_1 = y * t_0;
                          	double tmp;
                          	if (y <= 3.35e+44) {
                          		tmp = 1.0 + (((y * y) * (0.027777777777777776 - ((y * y) * (t_1 * t_1)))) / (0.16666666666666666 - ((y * y) * 0.008333333333333333)));
                          	} else if (y <= 1e+250) {
                          		tmp = (y * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * t_0))))) / y;
                          	} else {
                          		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                          	}
                          	return tmp;
                          }
                          
                          def code(x, y):
                          	t_0 = 0.008333333333333333 + (y * (y * 0.0001984126984126984))
                          	t_1 = y * t_0
                          	tmp = 0
                          	if y <= 3.35e+44:
                          		tmp = 1.0 + (((y * y) * (0.027777777777777776 - ((y * y) * (t_1 * t_1)))) / (0.16666666666666666 - ((y * y) * 0.008333333333333333)))
                          	elif y <= 1e+250:
                          		tmp = (y * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * t_0))))) / y
                          	else:
                          		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)))
                          	return tmp
                          
                          function code(x, y)
                          	t_0 = Float64(0.008333333333333333 + Float64(y * Float64(y * 0.0001984126984126984)))
                          	t_1 = Float64(y * t_0)
                          	tmp = 0.0
                          	if (y <= 3.35e+44)
                          		tmp = Float64(1.0 + Float64(Float64(Float64(y * y) * Float64(0.027777777777777776 - Float64(Float64(y * y) * Float64(t_1 * t_1)))) / Float64(0.16666666666666666 - Float64(Float64(y * y) * 0.008333333333333333))));
                          	elseif (y <= 1e+250)
                          		tmp = Float64(Float64(y * Float64(1.0 + Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(Float64(y * y) * t_0))))) / y);
                          	else
                          		tmp = Float64(Float64(1.0 + Float64(Float64(x * x) * -0.5)) * Float64(1.0 + Float64(0.16666666666666666 * Float64(y * y))));
                          	end
                          	return tmp
                          end
                          
                          function tmp_2 = code(x, y)
                          	t_0 = 0.008333333333333333 + (y * (y * 0.0001984126984126984));
                          	t_1 = y * t_0;
                          	tmp = 0.0;
                          	if (y <= 3.35e+44)
                          		tmp = 1.0 + (((y * y) * (0.027777777777777776 - ((y * y) * (t_1 * t_1)))) / (0.16666666666666666 - ((y * y) * 0.008333333333333333)));
                          	elseif (y <= 1e+250)
                          		tmp = (y * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * t_0))))) / y;
                          	else
                          		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                          	end
                          	tmp_2 = tmp;
                          end
                          
                          code[x_, y_] := Block[{t$95$0 = N[(0.008333333333333333 + N[(y * N[(y * 0.0001984126984126984), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(y * t$95$0), $MachinePrecision]}, If[LessEqual[y, 3.35e+44], N[(1.0 + N[(N[(N[(y * y), $MachinePrecision] * N[(0.027777777777777776 - N[(N[(y * y), $MachinePrecision] * N[(t$95$1 * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(0.16666666666666666 - N[(N[(y * y), $MachinePrecision] * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1e+250], N[(N[(y * N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * t$95$0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.5), $MachinePrecision]), $MachinePrecision] * N[(1.0 + N[(0.16666666666666666 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
                          
                          \begin{array}{l}
                          
                          \\
                          \begin{array}{l}
                          t_0 := 0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\\
                          t_1 := y \cdot t\_0\\
                          \mathbf{if}\;y \leq 3.35 \cdot 10^{+44}:\\
                          \;\;\;\;1 + \frac{\left(y \cdot y\right) \cdot \left(0.027777777777777776 - \left(y \cdot y\right) \cdot \left(t\_1 \cdot t\_1\right)\right)}{0.16666666666666666 - \left(y \cdot y\right) \cdot 0.008333333333333333}\\
                          
                          \mathbf{elif}\;y \leq 10^{+250}:\\
                          \;\;\;\;\frac{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot t\_0\right)\right)}{y}\\
                          
                          \mathbf{else}:\\
                          \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\
                          
                          
                          \end{array}
                          \end{array}
                          
                          Derivation
                          1. Split input into 3 regimes
                          2. if y < 3.35000000000000018e44

                            1. Initial program 100.0%

                              \[\cos x \cdot \frac{\sinh y}{y} \]
                            2. Add Preprocessing
                            3. Taylor expanded in y around 0

                              \[\leadsto \color{blue}{\cos x + {y}^{2} \cdot \left(\frac{1}{6} \cdot \cos x + {y}^{2} \cdot \left(\frac{1}{5040} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{120} \cdot \cos x\right)\right)} \]
                            4. Simplified94.2%

                              \[\leadsto \color{blue}{\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right)} \]
                            5. Taylor expanded in x around 0

                              \[\leadsto \color{blue}{1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)} \]
                            6. Step-by-step derivation
                              1. +-lowering-+.f64N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \color{blue}{\left({y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)}\right) \]
                              2. unpow2N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{6}} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right) \]
                              3. associate-*l*N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \left(y \cdot \color{blue}{\left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)}\right)\right) \]
                              4. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \color{blue}{\left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)}\right)\right) \]
                              5. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right) \]
                              6. +-lowering-+.f64N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \color{blue}{\left({y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right) \]
                              7. unpow2N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{120}} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right) \]
                              8. associate-*l*N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \color{blue}{\left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right) \]
                              9. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \color{blue}{\left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right) \]
                              10. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right) \]
                              11. +-lowering-+.f64N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right)\right) \]
                              12. *-commutativeN/A

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left({y}^{2} \cdot \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
                              13. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
                              14. unpow2N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
                              15. *-lowering-*.f6453.7%

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
                            7. Simplified53.7%

                              \[\leadsto \color{blue}{1 + y \cdot \left(y \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)} \]
                            8. Step-by-step derivation
                              1. associate-*r*N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \color{blue}{\left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)}\right)\right) \]
                              2. flip-+N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \frac{\frac{1}{6} \cdot \frac{1}{6} - \left(y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right) \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)}{\color{blue}{\frac{1}{6} - y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)}}\right)\right) \]
                              3. associate-*r/N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \left(\frac{\left(y \cdot y\right) \cdot \left(\frac{1}{6} \cdot \frac{1}{6} - \left(y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right) \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)}{\color{blue}{\frac{1}{6} - y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)}}\right)\right) \]
                              4. /-lowering-/.f64N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{/.f64}\left(\left(\left(y \cdot y\right) \cdot \left(\frac{1}{6} \cdot \frac{1}{6} - \left(y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right) \cdot \left(y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right), \color{blue}{\left(\frac{1}{6} - y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)}\right)\right) \]
                            9. Applied egg-rr41.8%

                              \[\leadsto 1 + \color{blue}{\frac{\left(y \cdot y\right) \cdot \left(0.027777777777777776 - \left(y \cdot y\right) \cdot \left(\left(y \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right) + 0.008333333333333333\right)\right) \cdot \left(y \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right) + 0.008333333333333333\right)\right)\right)\right)}{0.16666666666666666 - \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right) + 0.008333333333333333\right)}} \]
                            10. Taylor expanded in y around 0

                              \[\leadsto \mathsf{+.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{\_.f64}\left(\frac{1}{36}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \frac{1}{5040}\right)\right), \frac{1}{120}\right)\right), \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \frac{1}{5040}\right)\right), \frac{1}{120}\right)\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(\frac{1}{6}, \color{blue}{\left(\frac{1}{120} \cdot {y}^{2}\right)}\right)\right)\right) \]
                            11. Step-by-step derivation
                              1. *-commutativeN/A

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{\_.f64}\left(\frac{1}{36}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \frac{1}{5040}\right)\right), \frac{1}{120}\right)\right), \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \frac{1}{5040}\right)\right), \frac{1}{120}\right)\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \color{blue}{\frac{1}{120}}\right)\right)\right)\right) \]
                              2. *-lowering-*.f64N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{\_.f64}\left(\frac{1}{36}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \frac{1}{5040}\right)\right), \frac{1}{120}\right)\right), \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \frac{1}{5040}\right)\right), \frac{1}{120}\right)\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{120}}\right)\right)\right)\right) \]
                              3. unpow2N/A

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{\_.f64}\left(\frac{1}{36}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \frac{1}{5040}\right)\right), \frac{1}{120}\right)\right), \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \frac{1}{5040}\right)\right), \frac{1}{120}\right)\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{120}\right)\right)\right)\right) \]
                              4. *-lowering-*.f6445.9%

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{\_.f64}\left(\frac{1}{36}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \frac{1}{5040}\right)\right), \frac{1}{120}\right)\right), \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \frac{1}{5040}\right)\right), \frac{1}{120}\right)\right)\right)\right)\right)\right), \mathsf{\_.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{120}\right)\right)\right)\right) \]
                            12. Simplified45.9%

                              \[\leadsto 1 + \frac{\left(y \cdot y\right) \cdot \left(0.027777777777777776 - \left(y \cdot y\right) \cdot \left(\left(y \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right) + 0.008333333333333333\right)\right) \cdot \left(y \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right) + 0.008333333333333333\right)\right)\right)\right)}{0.16666666666666666 - \color{blue}{\left(y \cdot y\right) \cdot 0.008333333333333333}} \]

                            if 3.35000000000000018e44 < y < 9.9999999999999992e249

                            1. Initial program 100.0%

                              \[\cos x \cdot \frac{\sinh y}{y} \]
                            2. Add Preprocessing
                            3. Taylor expanded in x around 0

                              \[\leadsto \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                            4. Step-by-step derivation
                              1. Simplified83.7%

                                \[\leadsto \color{blue}{1} \cdot \frac{\sinh y}{y} \]
                              2. Taylor expanded in y around 0

                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\color{blue}{\left(y \cdot \left(1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)}, y\right)\right) \]
                              3. Step-by-step derivation
                                1. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right), y\right)\right) \]
                                2. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left({y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right), y\right)\right) \]
                                3. unpow2N/A

                                  \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right), y\right)\right) \]
                                4. associate-*l*N/A

                                  \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left(y \cdot \left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                5. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                6. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                7. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                8. unpow2N/A

                                  \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                9. associate-*l*N/A

                                  \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                10. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                11. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                12. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                13. *-commutativeN/A

                                  \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left({y}^{2} \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                14. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left({y}^{2}\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                15. unpow2N/A

                                  \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                16. *-lowering-*.f6483.7%

                                  \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                              4. Simplified83.7%

                                \[\leadsto 1 \cdot \frac{\color{blue}{y \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)\right)}}{y} \]
                              5. Step-by-step derivation
                                1. *-lft-identityN/A

                                  \[\leadsto \frac{y \cdot \left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)}{\color{blue}{y}} \]
                                2. /-lowering-/.f64N/A

                                  \[\leadsto \mathsf{/.f64}\left(\left(y \cdot \left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right), \color{blue}{y}\right) \]
                              6. Applied egg-rr83.7%

                                \[\leadsto \color{blue}{\frac{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right) + 0.008333333333333333\right)\right)\right)}{y}} \]

                              if 9.9999999999999992e249 < y

                              1. Initial program 100.0%

                                \[\cos x \cdot \frac{\sinh y}{y} \]
                              2. Add Preprocessing
                              3. Taylor expanded in x around 0

                                \[\leadsto \mathsf{*.f64}\left(\color{blue}{\left(1 + \frac{-1}{2} \cdot {x}^{2}\right)}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                              4. Step-by-step derivation
                                1. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left(\frac{-1}{2} \cdot {x}^{2}\right)\right), \mathsf{/.f64}\left(\color{blue}{\mathsf{sinh.f64}\left(y\right)}, y\right)\right) \]
                                2. *-commutativeN/A

                                  \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left({x}^{2} \cdot \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                3. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({x}^{2}\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                4. unpow2N/A

                                  \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(x \cdot x\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                5. *-lowering-*.f6482.4%

                                  \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                              5. Simplified82.4%

                                \[\leadsto \color{blue}{\left(1 + \left(x \cdot x\right) \cdot -0.5\right)} \cdot \frac{\sinh y}{y} \]
                              6. Taylor expanded in y around 0

                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \color{blue}{\left(1 + \frac{1}{6} \cdot {y}^{2}\right)}\right) \]
                              7. Step-by-step derivation
                                1. +-lowering-+.f64N/A

                                  \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)}\right)\right) \]
                                2. *-commutativeN/A

                                  \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \left({y}^{2} \cdot \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                                3. *-lowering-*.f64N/A

                                  \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                                4. unpow2N/A

                                  \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{6}\right)\right)\right) \]
                                5. *-lowering-*.f6482.4%

                                  \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{6}\right)\right)\right) \]
                              8. Simplified82.4%

                                \[\leadsto \left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \color{blue}{\left(1 + \left(y \cdot y\right) \cdot 0.16666666666666666\right)} \]
                            5. Recombined 3 regimes into one program.
                            6. Final simplification54.7%

                              \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 3.35 \cdot 10^{+44}:\\ \;\;\;\;1 + \frac{\left(y \cdot y\right) \cdot \left(0.027777777777777776 - \left(y \cdot y\right) \cdot \left(\left(y \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right) \cdot \left(y \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right)}{0.16666666666666666 - \left(y \cdot y\right) \cdot 0.008333333333333333}\\ \mathbf{elif}\;y \leq 10^{+250}:\\ \;\;\;\;\frac{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)}{y}\\ \mathbf{else}:\\ \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\ \end{array} \]
                            7. Add Preprocessing

                            Alternative 13: 45.0% accurate, 6.8× speedup?

                            \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq 370:\\ \;\;\;\;1\\ \mathbf{elif}\;y \leq 2.5 \cdot 10^{+51}:\\ \;\;\;\;1 + x \cdot \left(x \cdot \left(-0.5 + \left(x \cdot x\right) \cdot 0.041666666666666664\right)\right)\\ \mathbf{elif}\;y \leq 1.1 \cdot 10^{+250}:\\ \;\;\;\;y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\ \end{array} \end{array} \]
                            (FPCore (x y)
                             :precision binary64
                             (if (<= y 370.0)
                               1.0
                               (if (<= y 2.5e+51)
                                 (+ 1.0 (* x (* x (+ -0.5 (* (* x x) 0.041666666666666664)))))
                                 (if (<= y 1.1e+250)
                                   (* y (* 0.0001984126984126984 (* y (* (* y y) (* y y)))))
                                   (* (+ 1.0 (* (* x x) -0.5)) (+ 1.0 (* 0.16666666666666666 (* y y))))))))
                            double code(double x, double y) {
                            	double tmp;
                            	if (y <= 370.0) {
                            		tmp = 1.0;
                            	} else if (y <= 2.5e+51) {
                            		tmp = 1.0 + (x * (x * (-0.5 + ((x * x) * 0.041666666666666664))));
                            	} else if (y <= 1.1e+250) {
                            		tmp = y * (0.0001984126984126984 * (y * ((y * y) * (y * y))));
                            	} else {
                            		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                            	}
                            	return tmp;
                            }
                            
                            real(8) function code(x, y)
                                real(8), intent (in) :: x
                                real(8), intent (in) :: y
                                real(8) :: tmp
                                if (y <= 370.0d0) then
                                    tmp = 1.0d0
                                else if (y <= 2.5d+51) then
                                    tmp = 1.0d0 + (x * (x * ((-0.5d0) + ((x * x) * 0.041666666666666664d0))))
                                else if (y <= 1.1d+250) then
                                    tmp = y * (0.0001984126984126984d0 * (y * ((y * y) * (y * y))))
                                else
                                    tmp = (1.0d0 + ((x * x) * (-0.5d0))) * (1.0d0 + (0.16666666666666666d0 * (y * y)))
                                end if
                                code = tmp
                            end function
                            
                            public static double code(double x, double y) {
                            	double tmp;
                            	if (y <= 370.0) {
                            		tmp = 1.0;
                            	} else if (y <= 2.5e+51) {
                            		tmp = 1.0 + (x * (x * (-0.5 + ((x * x) * 0.041666666666666664))));
                            	} else if (y <= 1.1e+250) {
                            		tmp = y * (0.0001984126984126984 * (y * ((y * y) * (y * y))));
                            	} else {
                            		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                            	}
                            	return tmp;
                            }
                            
                            def code(x, y):
                            	tmp = 0
                            	if y <= 370.0:
                            		tmp = 1.0
                            	elif y <= 2.5e+51:
                            		tmp = 1.0 + (x * (x * (-0.5 + ((x * x) * 0.041666666666666664))))
                            	elif y <= 1.1e+250:
                            		tmp = y * (0.0001984126984126984 * (y * ((y * y) * (y * y))))
                            	else:
                            		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)))
                            	return tmp
                            
                            function code(x, y)
                            	tmp = 0.0
                            	if (y <= 370.0)
                            		tmp = 1.0;
                            	elseif (y <= 2.5e+51)
                            		tmp = Float64(1.0 + Float64(x * Float64(x * Float64(-0.5 + Float64(Float64(x * x) * 0.041666666666666664)))));
                            	elseif (y <= 1.1e+250)
                            		tmp = Float64(y * Float64(0.0001984126984126984 * Float64(y * Float64(Float64(y * y) * Float64(y * y)))));
                            	else
                            		tmp = Float64(Float64(1.0 + Float64(Float64(x * x) * -0.5)) * Float64(1.0 + Float64(0.16666666666666666 * Float64(y * y))));
                            	end
                            	return tmp
                            end
                            
                            function tmp_2 = code(x, y)
                            	tmp = 0.0;
                            	if (y <= 370.0)
                            		tmp = 1.0;
                            	elseif (y <= 2.5e+51)
                            		tmp = 1.0 + (x * (x * (-0.5 + ((x * x) * 0.041666666666666664))));
                            	elseif (y <= 1.1e+250)
                            		tmp = y * (0.0001984126984126984 * (y * ((y * y) * (y * y))));
                            	else
                            		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                            	end
                            	tmp_2 = tmp;
                            end
                            
                            code[x_, y_] := If[LessEqual[y, 370.0], 1.0, If[LessEqual[y, 2.5e+51], 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.1e+250], N[(y * N[(0.0001984126984126984 * N[(y * N[(N[(y * y), $MachinePrecision] * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.5), $MachinePrecision]), $MachinePrecision] * N[(1.0 + N[(0.16666666666666666 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
                            
                            \begin{array}{l}
                            
                            \\
                            \begin{array}{l}
                            \mathbf{if}\;y \leq 370:\\
                            \;\;\;\;1\\
                            
                            \mathbf{elif}\;y \leq 2.5 \cdot 10^{+51}:\\
                            \;\;\;\;1 + x \cdot \left(x \cdot \left(-0.5 + \left(x \cdot x\right) \cdot 0.041666666666666664\right)\right)\\
                            
                            \mathbf{elif}\;y \leq 1.1 \cdot 10^{+250}:\\
                            \;\;\;\;y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\\
                            
                            \mathbf{else}:\\
                            \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\
                            
                            
                            \end{array}
                            \end{array}
                            
                            Derivation
                            1. Split input into 4 regimes
                            2. if y < 370

                              1. Initial program 100.0%

                                \[\cos x \cdot \frac{\sinh y}{y} \]
                              2. Add Preprocessing
                              3. Taylor expanded in y around 0

                                \[\leadsto \color{blue}{\cos x} \]
                              4. Step-by-step derivation
                                1. cos-lowering-cos.f6473.9%

                                  \[\leadsto \mathsf{cos.f64}\left(x\right) \]
                              5. Simplified73.9%

                                \[\leadsto \color{blue}{\cos x} \]
                              6. Taylor expanded in x around 0

                                \[\leadsto \color{blue}{1} \]
                              7. Step-by-step derivation
                                1. Simplified37.1%

                                  \[\leadsto \color{blue}{1} \]

                                if 370 < y < 2.5e51

                                1. Initial program 100.0%

                                  \[\cos x \cdot \frac{\sinh y}{y} \]
                                2. Add Preprocessing
                                3. Taylor expanded in y around 0

                                  \[\leadsto \color{blue}{\cos x} \]
                                4. Step-by-step derivation
                                  1. cos-lowering-cos.f643.1%

                                    \[\leadsto \mathsf{cos.f64}\left(x\right) \]
                                5. Simplified3.1%

                                  \[\leadsto \color{blue}{\cos x} \]
                                6. Taylor expanded in x around 0

                                  \[\leadsto \color{blue}{1 + {x}^{2} \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)} \]
                                7. Step-by-step derivation
                                  1. +-lowering-+.f64N/A

                                    \[\leadsto \mathsf{+.f64}\left(1, \color{blue}{\left({x}^{2} \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)\right)}\right) \]
                                  2. unpow2N/A

                                    \[\leadsto \mathsf{+.f64}\left(1, \left(\left(x \cdot x\right) \cdot \left(\color{blue}{\frac{1}{24} \cdot {x}^{2}} - \frac{1}{2}\right)\right)\right) \]
                                  3. associate-*l*N/A

                                    \[\leadsto \mathsf{+.f64}\left(1, \left(x \cdot \color{blue}{\left(x \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)\right)}\right)\right) \]
                                  4. *-lowering-*.f64N/A

                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \color{blue}{\left(x \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)\right)}\right)\right) \]
                                  5. *-lowering-*.f64N/A

                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \color{blue}{\left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)}\right)\right)\right) \]
                                  6. sub-negN/A

                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \left(\frac{1}{24} \cdot {x}^{2} + \color{blue}{\left(\mathsf{neg}\left(\frac{1}{2}\right)\right)}\right)\right)\right)\right) \]
                                  7. metadata-evalN/A

                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \left(\frac{1}{24} \cdot {x}^{2} + \frac{-1}{2}\right)\right)\right)\right) \]
                                  8. +-commutativeN/A

                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \left(\frac{-1}{2} + \color{blue}{\frac{1}{24} \cdot {x}^{2}}\right)\right)\right)\right) \]
                                  9. +-lowering-+.f64N/A

                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \color{blue}{\left(\frac{1}{24} \cdot {x}^{2}\right)}\right)\right)\right)\right) \]
                                  10. *-commutativeN/A

                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \left({x}^{2} \cdot \color{blue}{\frac{1}{24}}\right)\right)\right)\right)\right) \]
                                  11. *-lowering-*.f64N/A

                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \mathsf{*.f64}\left(\left({x}^{2}\right), \color{blue}{\frac{1}{24}}\right)\right)\right)\right)\right) \]
                                  12. unpow2N/A

                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \mathsf{*.f64}\left(\left(x \cdot x\right), \frac{1}{24}\right)\right)\right)\right)\right) \]
                                  13. *-lowering-*.f6451.3%

                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{1}{24}\right)\right)\right)\right)\right) \]
                                8. Simplified51.3%

                                  \[\leadsto \color{blue}{1 + x \cdot \left(x \cdot \left(-0.5 + \left(x \cdot x\right) \cdot 0.041666666666666664\right)\right)} \]

                                if 2.5e51 < y < 1.10000000000000007e250

                                1. Initial program 100.0%

                                  \[\cos x \cdot \frac{\sinh y}{y} \]
                                2. Add Preprocessing
                                3. Taylor expanded in x around 0

                                  \[\leadsto \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                4. Step-by-step derivation
                                  1. Simplified85.0%

                                    \[\leadsto \color{blue}{1} \cdot \frac{\sinh y}{y} \]
                                  2. Taylor expanded in y around 0

                                    \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\color{blue}{\left(y \cdot \left(1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)}, y\right)\right) \]
                                  3. Step-by-step derivation
                                    1. *-lowering-*.f64N/A

                                      \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right), y\right)\right) \]
                                    2. +-lowering-+.f64N/A

                                      \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left({y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right), y\right)\right) \]
                                    3. unpow2N/A

                                      \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right), y\right)\right) \]
                                    4. associate-*l*N/A

                                      \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left(y \cdot \left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                    5. *-lowering-*.f64N/A

                                      \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                    6. *-lowering-*.f64N/A

                                      \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                    7. +-lowering-+.f64N/A

                                      \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                    8. unpow2N/A

                                      \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                    9. associate-*l*N/A

                                      \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                    10. *-lowering-*.f64N/A

                                      \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                    11. *-lowering-*.f64N/A

                                      \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                    12. +-lowering-+.f64N/A

                                      \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                    13. *-commutativeN/A

                                      \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left({y}^{2} \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                    14. *-lowering-*.f64N/A

                                      \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left({y}^{2}\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                    15. unpow2N/A

                                      \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                    16. *-lowering-*.f6485.0%

                                      \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                  4. Simplified85.0%

                                    \[\leadsto 1 \cdot \frac{\color{blue}{y \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)\right)}}{y} \]
                                  5. Step-by-step derivation
                                    1. *-lft-identityN/A

                                      \[\leadsto \frac{y \cdot \left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)}{\color{blue}{y}} \]
                                    2. associate-/l*N/A

                                      \[\leadsto y \cdot \color{blue}{\frac{1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)}{y}} \]
                                    3. *-commutativeN/A

                                      \[\leadsto \frac{1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)}{y} \cdot \color{blue}{y} \]
                                    4. *-lowering-*.f64N/A

                                      \[\leadsto \mathsf{*.f64}\left(\left(\frac{1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)}{y}\right), \color{blue}{y}\right) \]
                                  6. Applied egg-rr82.8%

                                    \[\leadsto \color{blue}{\frac{1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right) + 0.008333333333333333\right)\right)}{y} \cdot y} \]
                                  7. Taylor expanded in y around inf

                                    \[\leadsto \mathsf{*.f64}\left(\color{blue}{\left(\frac{1}{5040} \cdot {y}^{5}\right)}, y\right) \]
                                  8. Step-by-step derivation
                                    1. *-lowering-*.f64N/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{5}\right)\right), y\right) \]
                                    2. metadata-evalN/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{\left(4 + 1\right)}\right)\right), y\right) \]
                                    3. pow-plusN/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{4} \cdot y\right)\right), y\right) \]
                                    4. *-commutativeN/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot {y}^{4}\right)\right), y\right) \]
                                    5. *-lowering-*.f64N/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{4}\right)\right)\right), y\right) \]
                                    6. metadata-evalN/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{\left(2 \cdot 2\right)}\right)\right)\right), y\right) \]
                                    7. pow-sqrN/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{2} \cdot {y}^{2}\right)\right)\right), y\right) \]
                                    8. *-lowering-*.f64N/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left({y}^{2}\right), \left({y}^{2}\right)\right)\right)\right), y\right) \]
                                    9. unpow2N/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left(y \cdot y\right), \left({y}^{2}\right)\right)\right)\right), y\right) \]
                                    10. *-lowering-*.f64N/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left({y}^{2}\right)\right)\right)\right), y\right) \]
                                    11. unpow2N/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(y \cdot y\right)\right)\right)\right), y\right) \]
                                    12. *-lowering-*.f6482.8%

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, y\right)\right)\right)\right), y\right) \]
                                  9. Simplified82.8%

                                    \[\leadsto \color{blue}{\left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)} \cdot y \]

                                  if 1.10000000000000007e250 < y

                                  1. Initial program 100.0%

                                    \[\cos x \cdot \frac{\sinh y}{y} \]
                                  2. Add Preprocessing
                                  3. Taylor expanded in x around 0

                                    \[\leadsto \mathsf{*.f64}\left(\color{blue}{\left(1 + \frac{-1}{2} \cdot {x}^{2}\right)}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                  4. Step-by-step derivation
                                    1. +-lowering-+.f64N/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left(\frac{-1}{2} \cdot {x}^{2}\right)\right), \mathsf{/.f64}\left(\color{blue}{\mathsf{sinh.f64}\left(y\right)}, y\right)\right) \]
                                    2. *-commutativeN/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left({x}^{2} \cdot \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                    3. *-lowering-*.f64N/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({x}^{2}\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                    4. unpow2N/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(x \cdot x\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                    5. *-lowering-*.f6482.4%

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                  5. Simplified82.4%

                                    \[\leadsto \color{blue}{\left(1 + \left(x \cdot x\right) \cdot -0.5\right)} \cdot \frac{\sinh y}{y} \]
                                  6. Taylor expanded in y around 0

                                    \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \color{blue}{\left(1 + \frac{1}{6} \cdot {y}^{2}\right)}\right) \]
                                  7. Step-by-step derivation
                                    1. +-lowering-+.f64N/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)}\right)\right) \]
                                    2. *-commutativeN/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \left({y}^{2} \cdot \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                                    3. *-lowering-*.f64N/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                                    4. unpow2N/A

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{6}\right)\right)\right) \]
                                    5. *-lowering-*.f6482.4%

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{6}\right)\right)\right) \]
                                  8. Simplified82.4%

                                    \[\leadsto \left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \color{blue}{\left(1 + \left(y \cdot y\right) \cdot 0.16666666666666666\right)} \]
                                5. Recombined 4 regimes into one program.
                                6. Final simplification47.8%

                                  \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 370:\\ \;\;\;\;1\\ \mathbf{elif}\;y \leq 2.5 \cdot 10^{+51}:\\ \;\;\;\;1 + x \cdot \left(x \cdot \left(-0.5 + \left(x \cdot x\right) \cdot 0.041666666666666664\right)\right)\\ \mathbf{elif}\;y \leq 1.1 \cdot 10^{+250}:\\ \;\;\;\;y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\ \end{array} \]
                                7. Add Preprocessing

                                Alternative 14: 60.4% accurate, 8.5× speedup?

                                \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq 3.8 \cdot 10^{+245}:\\ \;\;\;\;\frac{y \cdot \left(1 + y \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right)\right)\right)}{y}\\ \mathbf{else}:\\ \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\ \end{array} \end{array} \]
                                (FPCore (x y)
                                 :precision binary64
                                 (if (<= y 3.8e+245)
                                   (/
                                    (* y (+ 1.0 (* y (* y (* 0.0001984126984126984 (* y (* y (* y y))))))))
                                    y)
                                   (* (+ 1.0 (* (* x x) -0.5)) (+ 1.0 (* 0.16666666666666666 (* y y))))))
                                double code(double x, double y) {
                                	double tmp;
                                	if (y <= 3.8e+245) {
                                		tmp = (y * (1.0 + (y * (y * (0.0001984126984126984 * (y * (y * (y * y)))))))) / y;
                                	} else {
                                		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                                	}
                                	return tmp;
                                }
                                
                                real(8) function code(x, y)
                                    real(8), intent (in) :: x
                                    real(8), intent (in) :: y
                                    real(8) :: tmp
                                    if (y <= 3.8d+245) then
                                        tmp = (y * (1.0d0 + (y * (y * (0.0001984126984126984d0 * (y * (y * (y * y)))))))) / y
                                    else
                                        tmp = (1.0d0 + ((x * x) * (-0.5d0))) * (1.0d0 + (0.16666666666666666d0 * (y * y)))
                                    end if
                                    code = tmp
                                end function
                                
                                public static double code(double x, double y) {
                                	double tmp;
                                	if (y <= 3.8e+245) {
                                		tmp = (y * (1.0 + (y * (y * (0.0001984126984126984 * (y * (y * (y * y)))))))) / y;
                                	} else {
                                		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                                	}
                                	return tmp;
                                }
                                
                                def code(x, y):
                                	tmp = 0
                                	if y <= 3.8e+245:
                                		tmp = (y * (1.0 + (y * (y * (0.0001984126984126984 * (y * (y * (y * y)))))))) / y
                                	else:
                                		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)))
                                	return tmp
                                
                                function code(x, y)
                                	tmp = 0.0
                                	if (y <= 3.8e+245)
                                		tmp = Float64(Float64(y * Float64(1.0 + Float64(y * Float64(y * Float64(0.0001984126984126984 * Float64(y * Float64(y * Float64(y * y)))))))) / y);
                                	else
                                		tmp = Float64(Float64(1.0 + Float64(Float64(x * x) * -0.5)) * Float64(1.0 + Float64(0.16666666666666666 * Float64(y * y))));
                                	end
                                	return tmp
                                end
                                
                                function tmp_2 = code(x, y)
                                	tmp = 0.0;
                                	if (y <= 3.8e+245)
                                		tmp = (y * (1.0 + (y * (y * (0.0001984126984126984 * (y * (y * (y * y)))))))) / y;
                                	else
                                		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                                	end
                                	tmp_2 = tmp;
                                end
                                
                                code[x_, y_] := If[LessEqual[y, 3.8e+245], N[(N[(y * N[(1.0 + N[(y * N[(y * N[(0.0001984126984126984 * N[(y * N[(y * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.5), $MachinePrecision]), $MachinePrecision] * N[(1.0 + N[(0.16666666666666666 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
                                
                                \begin{array}{l}
                                
                                \\
                                \begin{array}{l}
                                \mathbf{if}\;y \leq 3.8 \cdot 10^{+245}:\\
                                \;\;\;\;\frac{y \cdot \left(1 + y \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right)\right)\right)}{y}\\
                                
                                \mathbf{else}:\\
                                \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\
                                
                                
                                \end{array}
                                \end{array}
                                
                                Derivation
                                1. Split input into 2 regimes
                                2. if y < 3.8e245

                                  1. Initial program 100.0%

                                    \[\cos x \cdot \frac{\sinh y}{y} \]
                                  2. Add Preprocessing
                                  3. Taylor expanded in x around 0

                                    \[\leadsto \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                  4. Step-by-step derivation
                                    1. Simplified63.1%

                                      \[\leadsto \color{blue}{1} \cdot \frac{\sinh y}{y} \]
                                    2. Taylor expanded in y around 0

                                      \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\color{blue}{\left(y \cdot \left(1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)}, y\right)\right) \]
                                    3. Step-by-step derivation
                                      1. *-lowering-*.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right), y\right)\right) \]
                                      2. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left({y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right), y\right)\right) \]
                                      3. unpow2N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right), y\right)\right) \]
                                      4. associate-*l*N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left(y \cdot \left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      5. *-lowering-*.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      6. *-lowering-*.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      7. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      8. unpow2N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      9. associate-*l*N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      10. *-lowering-*.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      11. *-lowering-*.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      12. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      13. *-commutativeN/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left({y}^{2} \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      14. *-lowering-*.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left({y}^{2}\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      15. unpow2N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      16. *-lowering-*.f6459.1%

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                    4. Simplified59.1%

                                      \[\leadsto 1 \cdot \frac{\color{blue}{y \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)\right)}}{y} \]
                                    5. Taylor expanded in y around inf

                                      \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{5}\right)}\right)\right)\right), y\right)\right) \]
                                    6. Step-by-step derivation
                                      1. metadata-evalN/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(\frac{1}{5040} \cdot {y}^{\left(4 + 1\right)}\right)\right)\right)\right), y\right)\right) \]
                                      2. pow-plusN/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(\frac{1}{5040} \cdot \left({y}^{4} \cdot y\right)\right)\right)\right)\right), y\right)\right) \]
                                      3. associate-*l*N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(\left(\frac{1}{5040} \cdot {y}^{4}\right) \cdot y\right)\right)\right)\right), y\right)\right) \]
                                      4. *-commutativeN/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{5040} \cdot {y}^{4}\right)\right)\right)\right)\right), y\right)\right) \]
                                      5. *-lowering-*.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{5040} \cdot {y}^{4}\right)\right)\right)\right)\right), y\right)\right) \]
                                      6. *-lowering-*.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{4}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      7. *-rgt-identityN/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{4} \cdot 1\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      8. *-inversesN/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{4} \cdot \frac{y}{y}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      9. associate-/l*N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(\frac{{y}^{4} \cdot y}{y}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      10. *-commutativeN/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(\frac{y \cdot {y}^{4}}{y}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      11. associate-/l*N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \frac{{y}^{4}}{y}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      12. metadata-evalN/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \frac{{y}^{\left(2 \cdot 2\right)}}{y}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      13. pow-sqrN/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \frac{{y}^{2} \cdot {y}^{2}}{y}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      14. associate-/l*N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left({y}^{2} \cdot \frac{{y}^{2}}{y}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      15. unpow2N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{{y}^{2}}{y}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      16. unpow2N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{y \cdot y}{y}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      17. associate-/l*N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot \frac{y}{y}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      18. *-inversesN/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot 1\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      19. *-rgt-identityN/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot y\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      20. unpow3N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot {y}^{3}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      21. *-lowering-*.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{3}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      22. cube-multN/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left(y \cdot \left(y \cdot y\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      23. unpow2N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left(y \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      24. *-lowering-*.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left({y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      25. unpow2N/A

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(y \cdot y\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                      26. *-lowering-*.f6459.1%

                                        \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, y\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                    7. Simplified59.1%

                                      \[\leadsto 1 \cdot \frac{y \cdot \left(1 + y \cdot \color{blue}{\left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right)\right)}\right)}{y} \]

                                    if 3.8e245 < y

                                    1. Initial program 100.0%

                                      \[\cos x \cdot \frac{\sinh y}{y} \]
                                    2. Add Preprocessing
                                    3. Taylor expanded in x around 0

                                      \[\leadsto \mathsf{*.f64}\left(\color{blue}{\left(1 + \frac{-1}{2} \cdot {x}^{2}\right)}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                    4. Step-by-step derivation
                                      1. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left(\frac{-1}{2} \cdot {x}^{2}\right)\right), \mathsf{/.f64}\left(\color{blue}{\mathsf{sinh.f64}\left(y\right)}, y\right)\right) \]
                                      2. *-commutativeN/A

                                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left({x}^{2} \cdot \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                      3. *-lowering-*.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({x}^{2}\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                      4. unpow2N/A

                                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(x \cdot x\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                      5. *-lowering-*.f6482.4%

                                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                    5. Simplified82.4%

                                      \[\leadsto \color{blue}{\left(1 + \left(x \cdot x\right) \cdot -0.5\right)} \cdot \frac{\sinh y}{y} \]
                                    6. Taylor expanded in y around 0

                                      \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \color{blue}{\left(1 + \frac{1}{6} \cdot {y}^{2}\right)}\right) \]
                                    7. Step-by-step derivation
                                      1. +-lowering-+.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)}\right)\right) \]
                                      2. *-commutativeN/A

                                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \left({y}^{2} \cdot \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                                      3. *-lowering-*.f64N/A

                                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                                      4. unpow2N/A

                                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{6}\right)\right)\right) \]
                                      5. *-lowering-*.f6482.4%

                                        \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{6}\right)\right)\right) \]
                                    8. Simplified82.4%

                                      \[\leadsto \left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \color{blue}{\left(1 + \left(y \cdot y\right) \cdot 0.16666666666666666\right)} \]
                                  5. Recombined 2 regimes into one program.
                                  6. Final simplification60.7%

                                    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 3.8 \cdot 10^{+245}:\\ \;\;\;\;\frac{y \cdot \left(1 + y \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right)\right)\right)}{y}\\ \mathbf{else}:\\ \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\ \end{array} \]
                                  7. Add Preprocessing

                                  Alternative 15: 45.0% accurate, 8.9× speedup?

                                  \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq 210:\\ \;\;\;\;1\\ \mathbf{elif}\;y \leq 1.35 \cdot 10^{+51}:\\ \;\;\;\;1 + x \cdot \left(x \cdot \left(-0.5 + \left(x \cdot x\right) \cdot 0.041666666666666664\right)\right)\\ \mathbf{else}:\\ \;\;\;\;y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\\ \end{array} \end{array} \]
                                  (FPCore (x y)
                                   :precision binary64
                                   (if (<= y 210.0)
                                     1.0
                                     (if (<= y 1.35e+51)
                                       (+ 1.0 (* x (* x (+ -0.5 (* (* x x) 0.041666666666666664)))))
                                       (* y (* 0.0001984126984126984 (* y (* (* y y) (* y y))))))))
                                  double code(double x, double y) {
                                  	double tmp;
                                  	if (y <= 210.0) {
                                  		tmp = 1.0;
                                  	} else if (y <= 1.35e+51) {
                                  		tmp = 1.0 + (x * (x * (-0.5 + ((x * x) * 0.041666666666666664))));
                                  	} else {
                                  		tmp = y * (0.0001984126984126984 * (y * ((y * y) * (y * y))));
                                  	}
                                  	return tmp;
                                  }
                                  
                                  real(8) function code(x, y)
                                      real(8), intent (in) :: x
                                      real(8), intent (in) :: y
                                      real(8) :: tmp
                                      if (y <= 210.0d0) then
                                          tmp = 1.0d0
                                      else if (y <= 1.35d+51) then
                                          tmp = 1.0d0 + (x * (x * ((-0.5d0) + ((x * x) * 0.041666666666666664d0))))
                                      else
                                          tmp = y * (0.0001984126984126984d0 * (y * ((y * y) * (y * y))))
                                      end if
                                      code = tmp
                                  end function
                                  
                                  public static double code(double x, double y) {
                                  	double tmp;
                                  	if (y <= 210.0) {
                                  		tmp = 1.0;
                                  	} else if (y <= 1.35e+51) {
                                  		tmp = 1.0 + (x * (x * (-0.5 + ((x * x) * 0.041666666666666664))));
                                  	} else {
                                  		tmp = y * (0.0001984126984126984 * (y * ((y * y) * (y * y))));
                                  	}
                                  	return tmp;
                                  }
                                  
                                  def code(x, y):
                                  	tmp = 0
                                  	if y <= 210.0:
                                  		tmp = 1.0
                                  	elif y <= 1.35e+51:
                                  		tmp = 1.0 + (x * (x * (-0.5 + ((x * x) * 0.041666666666666664))))
                                  	else:
                                  		tmp = y * (0.0001984126984126984 * (y * ((y * y) * (y * y))))
                                  	return tmp
                                  
                                  function code(x, y)
                                  	tmp = 0.0
                                  	if (y <= 210.0)
                                  		tmp = 1.0;
                                  	elseif (y <= 1.35e+51)
                                  		tmp = Float64(1.0 + Float64(x * Float64(x * Float64(-0.5 + Float64(Float64(x * x) * 0.041666666666666664)))));
                                  	else
                                  		tmp = Float64(y * Float64(0.0001984126984126984 * Float64(y * Float64(Float64(y * y) * Float64(y * y)))));
                                  	end
                                  	return tmp
                                  end
                                  
                                  function tmp_2 = code(x, y)
                                  	tmp = 0.0;
                                  	if (y <= 210.0)
                                  		tmp = 1.0;
                                  	elseif (y <= 1.35e+51)
                                  		tmp = 1.0 + (x * (x * (-0.5 + ((x * x) * 0.041666666666666664))));
                                  	else
                                  		tmp = y * (0.0001984126984126984 * (y * ((y * y) * (y * y))));
                                  	end
                                  	tmp_2 = tmp;
                                  end
                                  
                                  code[x_, y_] := If[LessEqual[y, 210.0], 1.0, If[LessEqual[y, 1.35e+51], N[(1.0 + N[(x * N[(x * N[(-0.5 + N[(N[(x * x), $MachinePrecision] * 0.041666666666666664), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y * N[(0.0001984126984126984 * N[(y * N[(N[(y * y), $MachinePrecision] * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
                                  
                                  \begin{array}{l}
                                  
                                  \\
                                  \begin{array}{l}
                                  \mathbf{if}\;y \leq 210:\\
                                  \;\;\;\;1\\
                                  
                                  \mathbf{elif}\;y \leq 1.35 \cdot 10^{+51}:\\
                                  \;\;\;\;1 + x \cdot \left(x \cdot \left(-0.5 + \left(x \cdot x\right) \cdot 0.041666666666666664\right)\right)\\
                                  
                                  \mathbf{else}:\\
                                  \;\;\;\;y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\\
                                  
                                  
                                  \end{array}
                                  \end{array}
                                  
                                  Derivation
                                  1. Split input into 3 regimes
                                  2. if y < 210

                                    1. Initial program 100.0%

                                      \[\cos x \cdot \frac{\sinh y}{y} \]
                                    2. Add Preprocessing
                                    3. Taylor expanded in y around 0

                                      \[\leadsto \color{blue}{\cos x} \]
                                    4. Step-by-step derivation
                                      1. cos-lowering-cos.f6473.9%

                                        \[\leadsto \mathsf{cos.f64}\left(x\right) \]
                                    5. Simplified73.9%

                                      \[\leadsto \color{blue}{\cos x} \]
                                    6. Taylor expanded in x around 0

                                      \[\leadsto \color{blue}{1} \]
                                    7. Step-by-step derivation
                                      1. Simplified37.1%

                                        \[\leadsto \color{blue}{1} \]

                                      if 210 < y < 1.34999999999999996e51

                                      1. Initial program 100.0%

                                        \[\cos x \cdot \frac{\sinh y}{y} \]
                                      2. Add Preprocessing
                                      3. Taylor expanded in y around 0

                                        \[\leadsto \color{blue}{\cos x} \]
                                      4. Step-by-step derivation
                                        1. cos-lowering-cos.f643.1%

                                          \[\leadsto \mathsf{cos.f64}\left(x\right) \]
                                      5. Simplified3.1%

                                        \[\leadsto \color{blue}{\cos x} \]
                                      6. Taylor expanded in x around 0

                                        \[\leadsto \color{blue}{1 + {x}^{2} \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)} \]
                                      7. Step-by-step derivation
                                        1. +-lowering-+.f64N/A

                                          \[\leadsto \mathsf{+.f64}\left(1, \color{blue}{\left({x}^{2} \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)\right)}\right) \]
                                        2. unpow2N/A

                                          \[\leadsto \mathsf{+.f64}\left(1, \left(\left(x \cdot x\right) \cdot \left(\color{blue}{\frac{1}{24} \cdot {x}^{2}} - \frac{1}{2}\right)\right)\right) \]
                                        3. associate-*l*N/A

                                          \[\leadsto \mathsf{+.f64}\left(1, \left(x \cdot \color{blue}{\left(x \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)\right)}\right)\right) \]
                                        4. *-lowering-*.f64N/A

                                          \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \color{blue}{\left(x \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)\right)}\right)\right) \]
                                        5. *-lowering-*.f64N/A

                                          \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \color{blue}{\left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)}\right)\right)\right) \]
                                        6. sub-negN/A

                                          \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \left(\frac{1}{24} \cdot {x}^{2} + \color{blue}{\left(\mathsf{neg}\left(\frac{1}{2}\right)\right)}\right)\right)\right)\right) \]
                                        7. metadata-evalN/A

                                          \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \left(\frac{1}{24} \cdot {x}^{2} + \frac{-1}{2}\right)\right)\right)\right) \]
                                        8. +-commutativeN/A

                                          \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \left(\frac{-1}{2} + \color{blue}{\frac{1}{24} \cdot {x}^{2}}\right)\right)\right)\right) \]
                                        9. +-lowering-+.f64N/A

                                          \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \color{blue}{\left(\frac{1}{24} \cdot {x}^{2}\right)}\right)\right)\right)\right) \]
                                        10. *-commutativeN/A

                                          \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \left({x}^{2} \cdot \color{blue}{\frac{1}{24}}\right)\right)\right)\right)\right) \]
                                        11. *-lowering-*.f64N/A

                                          \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \mathsf{*.f64}\left(\left({x}^{2}\right), \color{blue}{\frac{1}{24}}\right)\right)\right)\right)\right) \]
                                        12. unpow2N/A

                                          \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \mathsf{*.f64}\left(\left(x \cdot x\right), \frac{1}{24}\right)\right)\right)\right)\right) \]
                                        13. *-lowering-*.f6451.3%

                                          \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{1}{24}\right)\right)\right)\right)\right) \]
                                      8. Simplified51.3%

                                        \[\leadsto \color{blue}{1 + x \cdot \left(x \cdot \left(-0.5 + \left(x \cdot x\right) \cdot 0.041666666666666664\right)\right)} \]

                                      if 1.34999999999999996e51 < y

                                      1. Initial program 100.0%

                                        \[\cos x \cdot \frac{\sinh y}{y} \]
                                      2. Add Preprocessing
                                      3. Taylor expanded in x around 0

                                        \[\leadsto \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                      4. Step-by-step derivation
                                        1. Simplified78.9%

                                          \[\leadsto \color{blue}{1} \cdot \frac{\sinh y}{y} \]
                                        2. Taylor expanded in y around 0

                                          \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\color{blue}{\left(y \cdot \left(1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)}, y\right)\right) \]
                                        3. Step-by-step derivation
                                          1. *-lowering-*.f64N/A

                                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right), y\right)\right) \]
                                          2. +-lowering-+.f64N/A

                                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left({y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right), y\right)\right) \]
                                          3. unpow2N/A

                                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right), y\right)\right) \]
                                          4. associate-*l*N/A

                                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left(y \cdot \left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                          5. *-lowering-*.f64N/A

                                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                          6. *-lowering-*.f64N/A

                                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                          7. +-lowering-+.f64N/A

                                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                          8. unpow2N/A

                                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                          9. associate-*l*N/A

                                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                          10. *-lowering-*.f64N/A

                                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                          11. *-lowering-*.f64N/A

                                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                          12. +-lowering-+.f64N/A

                                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                          13. *-commutativeN/A

                                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left({y}^{2} \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                          14. *-lowering-*.f64N/A

                                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left({y}^{2}\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                          15. unpow2N/A

                                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                          16. *-lowering-*.f6478.9%

                                            \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                        4. Simplified78.9%

                                          \[\leadsto 1 \cdot \frac{\color{blue}{y \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)\right)}}{y} \]
                                        5. Step-by-step derivation
                                          1. *-lft-identityN/A

                                            \[\leadsto \frac{y \cdot \left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)}{\color{blue}{y}} \]
                                          2. associate-/l*N/A

                                            \[\leadsto y \cdot \color{blue}{\frac{1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)}{y}} \]
                                          3. *-commutativeN/A

                                            \[\leadsto \frac{1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)}{y} \cdot \color{blue}{y} \]
                                          4. *-lowering-*.f64N/A

                                            \[\leadsto \mathsf{*.f64}\left(\left(\frac{1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)}{y}\right), \color{blue}{y}\right) \]
                                        6. Applied egg-rr77.4%

                                          \[\leadsto \color{blue}{\frac{1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right) + 0.008333333333333333\right)\right)}{y} \cdot y} \]
                                        7. Taylor expanded in y around inf

                                          \[\leadsto \mathsf{*.f64}\left(\color{blue}{\left(\frac{1}{5040} \cdot {y}^{5}\right)}, y\right) \]
                                        8. Step-by-step derivation
                                          1. *-lowering-*.f64N/A

                                            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{5}\right)\right), y\right) \]
                                          2. metadata-evalN/A

                                            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{\left(4 + 1\right)}\right)\right), y\right) \]
                                          3. pow-plusN/A

                                            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{4} \cdot y\right)\right), y\right) \]
                                          4. *-commutativeN/A

                                            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot {y}^{4}\right)\right), y\right) \]
                                          5. *-lowering-*.f64N/A

                                            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{4}\right)\right)\right), y\right) \]
                                          6. metadata-evalN/A

                                            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{\left(2 \cdot 2\right)}\right)\right)\right), y\right) \]
                                          7. pow-sqrN/A

                                            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{2} \cdot {y}^{2}\right)\right)\right), y\right) \]
                                          8. *-lowering-*.f64N/A

                                            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left({y}^{2}\right), \left({y}^{2}\right)\right)\right)\right), y\right) \]
                                          9. unpow2N/A

                                            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left(y \cdot y\right), \left({y}^{2}\right)\right)\right)\right), y\right) \]
                                          10. *-lowering-*.f64N/A

                                            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left({y}^{2}\right)\right)\right)\right), y\right) \]
                                          11. unpow2N/A

                                            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(y \cdot y\right)\right)\right)\right), y\right) \]
                                          12. *-lowering-*.f6477.4%

                                            \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, y\right)\right)\right)\right), y\right) \]
                                        9. Simplified77.4%

                                          \[\leadsto \color{blue}{\left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)} \cdot y \]
                                      5. Recombined 3 regimes into one program.
                                      6. Final simplification46.6%

                                        \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 210:\\ \;\;\;\;1\\ \mathbf{elif}\;y \leq 1.35 \cdot 10^{+51}:\\ \;\;\;\;1 + x \cdot \left(x \cdot \left(-0.5 + \left(x \cdot x\right) \cdot 0.041666666666666664\right)\right)\\ \mathbf{else}:\\ \;\;\;\;y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\\ \end{array} \]
                                      7. Add Preprocessing

                                      Alternative 16: 45.0% accurate, 8.9× speedup?

                                      \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq 620:\\ \;\;\;\;1\\ \mathbf{elif}\;y \leq 2.1 \cdot 10^{+51}:\\ \;\;\;\;0.041666666666666664 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\\ \mathbf{else}:\\ \;\;\;\;y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\\ \end{array} \end{array} \]
                                      (FPCore (x y)
                                       :precision binary64
                                       (if (<= y 620.0)
                                         1.0
                                         (if (<= y 2.1e+51)
                                           (* 0.041666666666666664 (* (* x x) (* x x)))
                                           (* y (* 0.0001984126984126984 (* y (* (* y y) (* y y))))))))
                                      double code(double x, double y) {
                                      	double tmp;
                                      	if (y <= 620.0) {
                                      		tmp = 1.0;
                                      	} else if (y <= 2.1e+51) {
                                      		tmp = 0.041666666666666664 * ((x * x) * (x * x));
                                      	} else {
                                      		tmp = y * (0.0001984126984126984 * (y * ((y * y) * (y * y))));
                                      	}
                                      	return tmp;
                                      }
                                      
                                      real(8) function code(x, y)
                                          real(8), intent (in) :: x
                                          real(8), intent (in) :: y
                                          real(8) :: tmp
                                          if (y <= 620.0d0) then
                                              tmp = 1.0d0
                                          else if (y <= 2.1d+51) then
                                              tmp = 0.041666666666666664d0 * ((x * x) * (x * x))
                                          else
                                              tmp = y * (0.0001984126984126984d0 * (y * ((y * y) * (y * y))))
                                          end if
                                          code = tmp
                                      end function
                                      
                                      public static double code(double x, double y) {
                                      	double tmp;
                                      	if (y <= 620.0) {
                                      		tmp = 1.0;
                                      	} else if (y <= 2.1e+51) {
                                      		tmp = 0.041666666666666664 * ((x * x) * (x * x));
                                      	} else {
                                      		tmp = y * (0.0001984126984126984 * (y * ((y * y) * (y * y))));
                                      	}
                                      	return tmp;
                                      }
                                      
                                      def code(x, y):
                                      	tmp = 0
                                      	if y <= 620.0:
                                      		tmp = 1.0
                                      	elif y <= 2.1e+51:
                                      		tmp = 0.041666666666666664 * ((x * x) * (x * x))
                                      	else:
                                      		tmp = y * (0.0001984126984126984 * (y * ((y * y) * (y * y))))
                                      	return tmp
                                      
                                      function code(x, y)
                                      	tmp = 0.0
                                      	if (y <= 620.0)
                                      		tmp = 1.0;
                                      	elseif (y <= 2.1e+51)
                                      		tmp = Float64(0.041666666666666664 * Float64(Float64(x * x) * Float64(x * x)));
                                      	else
                                      		tmp = Float64(y * Float64(0.0001984126984126984 * Float64(y * Float64(Float64(y * y) * Float64(y * y)))));
                                      	end
                                      	return tmp
                                      end
                                      
                                      function tmp_2 = code(x, y)
                                      	tmp = 0.0;
                                      	if (y <= 620.0)
                                      		tmp = 1.0;
                                      	elseif (y <= 2.1e+51)
                                      		tmp = 0.041666666666666664 * ((x * x) * (x * x));
                                      	else
                                      		tmp = y * (0.0001984126984126984 * (y * ((y * y) * (y * y))));
                                      	end
                                      	tmp_2 = tmp;
                                      end
                                      
                                      code[x_, y_] := If[LessEqual[y, 620.0], 1.0, If[LessEqual[y, 2.1e+51], N[(0.041666666666666664 * N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y * N[(0.0001984126984126984 * N[(y * N[(N[(y * y), $MachinePrecision] * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
                                      
                                      \begin{array}{l}
                                      
                                      \\
                                      \begin{array}{l}
                                      \mathbf{if}\;y \leq 620:\\
                                      \;\;\;\;1\\
                                      
                                      \mathbf{elif}\;y \leq 2.1 \cdot 10^{+51}:\\
                                      \;\;\;\;0.041666666666666664 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\\
                                      
                                      \mathbf{else}:\\
                                      \;\;\;\;y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\\
                                      
                                      
                                      \end{array}
                                      \end{array}
                                      
                                      Derivation
                                      1. Split input into 3 regimes
                                      2. if y < 620

                                        1. Initial program 100.0%

                                          \[\cos x \cdot \frac{\sinh y}{y} \]
                                        2. Add Preprocessing
                                        3. Taylor expanded in y around 0

                                          \[\leadsto \color{blue}{\cos x} \]
                                        4. Step-by-step derivation
                                          1. cos-lowering-cos.f6473.9%

                                            \[\leadsto \mathsf{cos.f64}\left(x\right) \]
                                        5. Simplified73.9%

                                          \[\leadsto \color{blue}{\cos x} \]
                                        6. Taylor expanded in x around 0

                                          \[\leadsto \color{blue}{1} \]
                                        7. Step-by-step derivation
                                          1. Simplified37.1%

                                            \[\leadsto \color{blue}{1} \]

                                          if 620 < y < 2.1000000000000001e51

                                          1. Initial program 100.0%

                                            \[\cos x \cdot \frac{\sinh y}{y} \]
                                          2. Add Preprocessing
                                          3. Taylor expanded in y around 0

                                            \[\leadsto \color{blue}{\cos x} \]
                                          4. Step-by-step derivation
                                            1. cos-lowering-cos.f643.1%

                                              \[\leadsto \mathsf{cos.f64}\left(x\right) \]
                                          5. Simplified3.1%

                                            \[\leadsto \color{blue}{\cos x} \]
                                          6. Taylor expanded in x around 0

                                            \[\leadsto \color{blue}{1 + {x}^{2} \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)} \]
                                          7. Step-by-step derivation
                                            1. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{+.f64}\left(1, \color{blue}{\left({x}^{2} \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)\right)}\right) \]
                                            2. unpow2N/A

                                              \[\leadsto \mathsf{+.f64}\left(1, \left(\left(x \cdot x\right) \cdot \left(\color{blue}{\frac{1}{24} \cdot {x}^{2}} - \frac{1}{2}\right)\right)\right) \]
                                            3. associate-*l*N/A

                                              \[\leadsto \mathsf{+.f64}\left(1, \left(x \cdot \color{blue}{\left(x \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)\right)}\right)\right) \]
                                            4. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \color{blue}{\left(x \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)\right)}\right)\right) \]
                                            5. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \color{blue}{\left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)}\right)\right)\right) \]
                                            6. sub-negN/A

                                              \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \left(\frac{1}{24} \cdot {x}^{2} + \color{blue}{\left(\mathsf{neg}\left(\frac{1}{2}\right)\right)}\right)\right)\right)\right) \]
                                            7. metadata-evalN/A

                                              \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \left(\frac{1}{24} \cdot {x}^{2} + \frac{-1}{2}\right)\right)\right)\right) \]
                                            8. +-commutativeN/A

                                              \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \left(\frac{-1}{2} + \color{blue}{\frac{1}{24} \cdot {x}^{2}}\right)\right)\right)\right) \]
                                            9. +-lowering-+.f64N/A

                                              \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \color{blue}{\left(\frac{1}{24} \cdot {x}^{2}\right)}\right)\right)\right)\right) \]
                                            10. *-commutativeN/A

                                              \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \left({x}^{2} \cdot \color{blue}{\frac{1}{24}}\right)\right)\right)\right)\right) \]
                                            11. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \mathsf{*.f64}\left(\left({x}^{2}\right), \color{blue}{\frac{1}{24}}\right)\right)\right)\right)\right) \]
                                            12. unpow2N/A

                                              \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \mathsf{*.f64}\left(\left(x \cdot x\right), \frac{1}{24}\right)\right)\right)\right)\right) \]
                                            13. *-lowering-*.f6451.3%

                                              \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{1}{24}\right)\right)\right)\right)\right) \]
                                          8. Simplified51.3%

                                            \[\leadsto \color{blue}{1 + x \cdot \left(x \cdot \left(-0.5 + \left(x \cdot x\right) \cdot 0.041666666666666664\right)\right)} \]
                                          9. Taylor expanded in x around inf

                                            \[\leadsto \color{blue}{\frac{1}{24} \cdot {x}^{4}} \]
                                          10. Step-by-step derivation
                                            1. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{*.f64}\left(\frac{1}{24}, \color{blue}{\left({x}^{4}\right)}\right) \]
                                            2. metadata-evalN/A

                                              \[\leadsto \mathsf{*.f64}\left(\frac{1}{24}, \left({x}^{\left(2 \cdot \color{blue}{2}\right)}\right)\right) \]
                                            3. pow-sqrN/A

                                              \[\leadsto \mathsf{*.f64}\left(\frac{1}{24}, \left({x}^{2} \cdot \color{blue}{{x}^{2}}\right)\right) \]
                                            4. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{*.f64}\left(\frac{1}{24}, \mathsf{*.f64}\left(\left({x}^{2}\right), \color{blue}{\left({x}^{2}\right)}\right)\right) \]
                                            5. unpow2N/A

                                              \[\leadsto \mathsf{*.f64}\left(\frac{1}{24}, \mathsf{*.f64}\left(\left(x \cdot x\right), \left({\color{blue}{x}}^{2}\right)\right)\right) \]
                                            6. *-lowering-*.f64N/A

                                              \[\leadsto \mathsf{*.f64}\left(\frac{1}{24}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \left({\color{blue}{x}}^{2}\right)\right)\right) \]
                                            7. unpow2N/A

                                              \[\leadsto \mathsf{*.f64}\left(\frac{1}{24}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \left(x \cdot \color{blue}{x}\right)\right)\right) \]
                                            8. *-lowering-*.f6450.7%

                                              \[\leadsto \mathsf{*.f64}\left(\frac{1}{24}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \mathsf{*.f64}\left(x, \color{blue}{x}\right)\right)\right) \]
                                          11. Simplified50.7%

                                            \[\leadsto \color{blue}{0.041666666666666664 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)} \]

                                          if 2.1000000000000001e51 < y

                                          1. Initial program 100.0%

                                            \[\cos x \cdot \frac{\sinh y}{y} \]
                                          2. Add Preprocessing
                                          3. Taylor expanded in x around 0

                                            \[\leadsto \mathsf{*.f64}\left(\color{blue}{1}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                          4. Step-by-step derivation
                                            1. Simplified78.9%

                                              \[\leadsto \color{blue}{1} \cdot \frac{\sinh y}{y} \]
                                            2. Taylor expanded in y around 0

                                              \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\color{blue}{\left(y \cdot \left(1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)}, y\right)\right) \]
                                            3. Step-by-step derivation
                                              1. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right), y\right)\right) \]
                                              2. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left({y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right), y\right)\right) \]
                                              3. unpow2N/A

                                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right), y\right)\right) \]
                                              4. associate-*l*N/A

                                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \left(y \cdot \left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                              5. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                              6. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                              7. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                              8. unpow2N/A

                                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                              9. associate-*l*N/A

                                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                              10. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                              11. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                              12. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left(\frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                              13. *-commutativeN/A

                                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left({y}^{2} \cdot \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                              14. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left({y}^{2}\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                              15. unpow2N/A

                                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                              16. *-lowering-*.f6478.9%

                                                \[\leadsto \mathsf{*.f64}\left(1, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right)\right), y\right)\right) \]
                                            4. Simplified78.9%

                                              \[\leadsto 1 \cdot \frac{\color{blue}{y \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)\right)}}{y} \]
                                            5. Step-by-step derivation
                                              1. *-lft-identityN/A

                                                \[\leadsto \frac{y \cdot \left(1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)\right)}{\color{blue}{y}} \]
                                              2. associate-/l*N/A

                                                \[\leadsto y \cdot \color{blue}{\frac{1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)}{y}} \]
                                              3. *-commutativeN/A

                                                \[\leadsto \frac{1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)}{y} \cdot \color{blue}{y} \]
                                              4. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(\left(\frac{1 + y \cdot \left(y \cdot \left(\frac{1}{6} + y \cdot \left(y \cdot \left(\frac{1}{120} + \left(y \cdot y\right) \cdot \frac{1}{5040}\right)\right)\right)\right)}{y}\right), \color{blue}{y}\right) \]
                                            6. Applied egg-rr77.4%

                                              \[\leadsto \color{blue}{\frac{1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot 0.0001984126984126984\right) + 0.008333333333333333\right)\right)}{y} \cdot y} \]
                                            7. Taylor expanded in y around inf

                                              \[\leadsto \mathsf{*.f64}\left(\color{blue}{\left(\frac{1}{5040} \cdot {y}^{5}\right)}, y\right) \]
                                            8. Step-by-step derivation
                                              1. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{5}\right)\right), y\right) \]
                                              2. metadata-evalN/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{\left(4 + 1\right)}\right)\right), y\right) \]
                                              3. pow-plusN/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{4} \cdot y\right)\right), y\right) \]
                                              4. *-commutativeN/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot {y}^{4}\right)\right), y\right) \]
                                              5. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{4}\right)\right)\right), y\right) \]
                                              6. metadata-evalN/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{\left(2 \cdot 2\right)}\right)\right)\right), y\right) \]
                                              7. pow-sqrN/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left({y}^{2} \cdot {y}^{2}\right)\right)\right), y\right) \]
                                              8. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left({y}^{2}\right), \left({y}^{2}\right)\right)\right)\right), y\right) \]
                                              9. unpow2N/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\left(y \cdot y\right), \left({y}^{2}\right)\right)\right)\right), y\right) \]
                                              10. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left({y}^{2}\right)\right)\right)\right), y\right) \]
                                              11. unpow2N/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(y \cdot y\right)\right)\right)\right), y\right) \]
                                              12. *-lowering-*.f6477.4%

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, y\right)\right)\right)\right), y\right) \]
                                            9. Simplified77.4%

                                              \[\leadsto \color{blue}{\left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)} \cdot y \]
                                          5. Recombined 3 regimes into one program.
                                          6. Final simplification46.6%

                                            \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 620:\\ \;\;\;\;1\\ \mathbf{elif}\;y \leq 2.1 \cdot 10^{+51}:\\ \;\;\;\;0.041666666666666664 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\\ \mathbf{else}:\\ \;\;\;\;y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right)\right)\\ \end{array} \]
                                          7. Add Preprocessing

                                          Alternative 17: 59.6% accurate, 10.2× speedup?

                                          \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq 5 \cdot 10^{+246}:\\ \;\;\;\;1 + 0.0001984126984126984 \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\ \end{array} \end{array} \]
                                          (FPCore (x y)
                                           :precision binary64
                                           (if (<= y 5e+246)
                                             (+ 1.0 (* 0.0001984126984126984 (* (* y y) (* y (* y (* y y))))))
                                             (* (+ 1.0 (* (* x x) -0.5)) (+ 1.0 (* 0.16666666666666666 (* y y))))))
                                          double code(double x, double y) {
                                          	double tmp;
                                          	if (y <= 5e+246) {
                                          		tmp = 1.0 + (0.0001984126984126984 * ((y * y) * (y * (y * (y * y)))));
                                          	} else {
                                          		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                                          	}
                                          	return tmp;
                                          }
                                          
                                          real(8) function code(x, y)
                                              real(8), intent (in) :: x
                                              real(8), intent (in) :: y
                                              real(8) :: tmp
                                              if (y <= 5d+246) then
                                                  tmp = 1.0d0 + (0.0001984126984126984d0 * ((y * y) * (y * (y * (y * y)))))
                                              else
                                                  tmp = (1.0d0 + ((x * x) * (-0.5d0))) * (1.0d0 + (0.16666666666666666d0 * (y * y)))
                                              end if
                                              code = tmp
                                          end function
                                          
                                          public static double code(double x, double y) {
                                          	double tmp;
                                          	if (y <= 5e+246) {
                                          		tmp = 1.0 + (0.0001984126984126984 * ((y * y) * (y * (y * (y * y)))));
                                          	} else {
                                          		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                                          	}
                                          	return tmp;
                                          }
                                          
                                          def code(x, y):
                                          	tmp = 0
                                          	if y <= 5e+246:
                                          		tmp = 1.0 + (0.0001984126984126984 * ((y * y) * (y * (y * (y * y)))))
                                          	else:
                                          		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)))
                                          	return tmp
                                          
                                          function code(x, y)
                                          	tmp = 0.0
                                          	if (y <= 5e+246)
                                          		tmp = Float64(1.0 + Float64(0.0001984126984126984 * Float64(Float64(y * y) * Float64(y * Float64(y * Float64(y * y))))));
                                          	else
                                          		tmp = Float64(Float64(1.0 + Float64(Float64(x * x) * -0.5)) * Float64(1.0 + Float64(0.16666666666666666 * Float64(y * y))));
                                          	end
                                          	return tmp
                                          end
                                          
                                          function tmp_2 = code(x, y)
                                          	tmp = 0.0;
                                          	if (y <= 5e+246)
                                          		tmp = 1.0 + (0.0001984126984126984 * ((y * y) * (y * (y * (y * y)))));
                                          	else
                                          		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                                          	end
                                          	tmp_2 = tmp;
                                          end
                                          
                                          code[x_, y_] := If[LessEqual[y, 5e+246], N[(1.0 + N[(0.0001984126984126984 * N[(N[(y * y), $MachinePrecision] * N[(y * N[(y * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.5), $MachinePrecision]), $MachinePrecision] * N[(1.0 + N[(0.16666666666666666 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
                                          
                                          \begin{array}{l}
                                          
                                          \\
                                          \begin{array}{l}
                                          \mathbf{if}\;y \leq 5 \cdot 10^{+246}:\\
                                          \;\;\;\;1 + 0.0001984126984126984 \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right)\\
                                          
                                          \mathbf{else}:\\
                                          \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\
                                          
                                          
                                          \end{array}
                                          \end{array}
                                          
                                          Derivation
                                          1. Split input into 2 regimes
                                          2. if y < 4.99999999999999976e246

                                            1. Initial program 100.0%

                                              \[\cos x \cdot \frac{\sinh y}{y} \]
                                            2. Add Preprocessing
                                            3. Taylor expanded in y around 0

                                              \[\leadsto \color{blue}{\cos x + {y}^{2} \cdot \left(\frac{1}{6} \cdot \cos x + {y}^{2} \cdot \left(\frac{1}{5040} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{120} \cdot \cos x\right)\right)} \]
                                            4. Simplified93.8%

                                              \[\leadsto \color{blue}{\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right)} \]
                                            5. Taylor expanded in x around 0

                                              \[\leadsto \color{blue}{1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)} \]
                                            6. Step-by-step derivation
                                              1. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \color{blue}{\left({y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)}\right) \]
                                              2. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{6}} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right) \]
                                              3. associate-*l*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \left(y \cdot \color{blue}{\left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)}\right)\right) \]
                                              4. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \color{blue}{\left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)}\right)\right) \]
                                              5. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right) \]
                                              6. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \color{blue}{\left({y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right) \]
                                              7. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{120}} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right) \]
                                              8. associate-*l*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \color{blue}{\left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right) \]
                                              9. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \color{blue}{\left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right) \]
                                              10. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right) \]
                                              11. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right)\right) \]
                                              12. *-commutativeN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left({y}^{2} \cdot \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
                                              13. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
                                              14. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
                                              15. *-lowering-*.f6458.0%

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
                                            7. Simplified58.0%

                                              \[\leadsto \color{blue}{1 + y \cdot \left(y \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)} \]
                                            8. Taylor expanded in y around inf

                                              \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{5}\right)}\right)\right) \]
                                            9. Step-by-step derivation
                                              1. metadata-evalN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(\frac{1}{5040} \cdot {y}^{\left(4 + \color{blue}{1}\right)}\right)\right)\right) \]
                                              2. pow-plusN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(\frac{1}{5040} \cdot \left({y}^{4} \cdot \color{blue}{y}\right)\right)\right)\right) \]
                                              3. associate-*l*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(\left(\frac{1}{5040} \cdot {y}^{4}\right) \cdot \color{blue}{y}\right)\right)\right) \]
                                              4. *-commutativeN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \color{blue}{\left(\frac{1}{5040} \cdot {y}^{4}\right)}\right)\right)\right) \]
                                              5. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{4}\right)}\right)\right)\right) \]
                                              6. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \color{blue}{\left({y}^{4}\right)}\right)\right)\right)\right) \]
                                              7. *-rgt-identityN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{4} \cdot \color{blue}{1}\right)\right)\right)\right)\right) \]
                                              8. *-inversesN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{4} \cdot \frac{y}{\color{blue}{y}}\right)\right)\right)\right)\right) \]
                                              9. associate-/l*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(\frac{{y}^{4} \cdot y}{\color{blue}{y}}\right)\right)\right)\right)\right) \]
                                              10. *-commutativeN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(\frac{y \cdot {y}^{4}}{y}\right)\right)\right)\right)\right) \]
                                              11. associate-/l*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \color{blue}{\frac{{y}^{4}}{y}}\right)\right)\right)\right)\right) \]
                                              12. metadata-evalN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \frac{{y}^{\left(2 \cdot 2\right)}}{y}\right)\right)\right)\right)\right) \]
                                              13. pow-sqrN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \frac{{y}^{2} \cdot {y}^{2}}{y}\right)\right)\right)\right)\right) \]
                                              14. associate-/l*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left({y}^{2} \cdot \color{blue}{\frac{{y}^{2}}{y}}\right)\right)\right)\right)\right)\right) \]
                                              15. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{\color{blue}{{y}^{2}}}{y}\right)\right)\right)\right)\right)\right) \]
                                              16. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{y \cdot y}{y}\right)\right)\right)\right)\right)\right) \]
                                              17. associate-/l*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot \color{blue}{\frac{y}{y}}\right)\right)\right)\right)\right)\right)\right) \]
                                              18. *-inversesN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot 1\right)\right)\right)\right)\right)\right)\right) \]
                                              19. *-rgt-identityN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot y\right)\right)\right)\right)\right)\right) \]
                                              20. unpow3N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot {y}^{\color{blue}{3}}\right)\right)\right)\right)\right) \]
                                              21. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \color{blue}{\left({y}^{3}\right)}\right)\right)\right)\right)\right) \]
                                              22. cube-multN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left(y \cdot \color{blue}{\left(y \cdot y\right)}\right)\right)\right)\right)\right)\right) \]
                                              23. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left(y \cdot {y}^{\color{blue}{2}}\right)\right)\right)\right)\right)\right) \]
                                              24. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left({y}^{2}\right)}\right)\right)\right)\right)\right)\right) \]
                                              25. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(y \cdot \color{blue}{y}\right)\right)\right)\right)\right)\right)\right) \]
                                              26. *-lowering-*.f6458.0%

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{y}\right)\right)\right)\right)\right)\right)\right) \]
                                            10. Simplified58.0%

                                              \[\leadsto 1 + y \cdot \color{blue}{\left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right)\right)} \]
                                            11. Step-by-step derivation
                                              1. associate-*r*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \color{blue}{\left(\frac{1}{5040} \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right)}\right)\right) \]
                                              2. *-commutativeN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \left(\left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right) \cdot \color{blue}{\frac{1}{5040}}\right)\right)\right) \]
                                              3. associate-*r*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \left(\left(\left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right) \cdot \color{blue}{\frac{1}{5040}}\right)\right) \]
                                              4. associate-*r*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \left(\left(\left(y \cdot y\right) \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right) \cdot \frac{1}{5040}\right)\right) \]
                                              5. cube-unmultN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \left({\left(y \cdot y\right)}^{3} \cdot \frac{1}{5040}\right)\right) \]
                                              6. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({\left(y \cdot y\right)}^{3}\right), \color{blue}{\frac{1}{5040}}\right)\right) \]
                                              7. cube-unmultN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(\left(y \cdot y\right) \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot y\right)\right)\right), \frac{1}{5040}\right)\right) \]
                                              8. associate-*r*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(\left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right), \frac{1}{5040}\right)\right) \]
                                              9. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(\left(y \cdot y\right), \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right), \frac{1}{5040}\right)\right) \]
                                              10. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right), \frac{1}{5040}\right)\right) \]
                                              11. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, \left(y \cdot \left(y \cdot y\right)\right)\right)\right), \frac{1}{5040}\right)\right) \]
                                              12. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(y \cdot y\right)\right)\right)\right), \frac{1}{5040}\right)\right) \]
                                              13. *-lowering-*.f6458.4%

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, y\right)\right)\right)\right), \frac{1}{5040}\right)\right) \]
                                            12. Applied egg-rr58.4%

                                              \[\leadsto 1 + \color{blue}{\left(\left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right) \cdot 0.0001984126984126984} \]

                                            if 4.99999999999999976e246 < y

                                            1. Initial program 100.0%

                                              \[\cos x \cdot \frac{\sinh y}{y} \]
                                            2. Add Preprocessing
                                            3. Taylor expanded in x around 0

                                              \[\leadsto \mathsf{*.f64}\left(\color{blue}{\left(1 + \frac{-1}{2} \cdot {x}^{2}\right)}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                            4. Step-by-step derivation
                                              1. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left(\frac{-1}{2} \cdot {x}^{2}\right)\right), \mathsf{/.f64}\left(\color{blue}{\mathsf{sinh.f64}\left(y\right)}, y\right)\right) \]
                                              2. *-commutativeN/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left({x}^{2} \cdot \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                              3. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({x}^{2}\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                              4. unpow2N/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(x \cdot x\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                              5. *-lowering-*.f6482.4%

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                            5. Simplified82.4%

                                              \[\leadsto \color{blue}{\left(1 + \left(x \cdot x\right) \cdot -0.5\right)} \cdot \frac{\sinh y}{y} \]
                                            6. Taylor expanded in y around 0

                                              \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \color{blue}{\left(1 + \frac{1}{6} \cdot {y}^{2}\right)}\right) \]
                                            7. Step-by-step derivation
                                              1. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)}\right)\right) \]
                                              2. *-commutativeN/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \left({y}^{2} \cdot \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                                              3. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                                              4. unpow2N/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{6}\right)\right)\right) \]
                                              5. *-lowering-*.f6482.4%

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{6}\right)\right)\right) \]
                                            8. Simplified82.4%

                                              \[\leadsto \left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \color{blue}{\left(1 + \left(y \cdot y\right) \cdot 0.16666666666666666\right)} \]
                                          3. Recombined 2 regimes into one program.
                                          4. Final simplification60.0%

                                            \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 5 \cdot 10^{+246}:\\ \;\;\;\;1 + 0.0001984126984126984 \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\ \end{array} \]
                                          5. Add Preprocessing

                                          Alternative 18: 59.5% accurate, 10.2× speedup?

                                          \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq 4 \cdot 10^{+250}:\\ \;\;\;\;1 + y \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\ \end{array} \end{array} \]
                                          (FPCore (x y)
                                           :precision binary64
                                           (if (<= y 4e+250)
                                             (+ 1.0 (* y (* y (* 0.0001984126984126984 (* y (* y (* y y)))))))
                                             (* (+ 1.0 (* (* x x) -0.5)) (+ 1.0 (* 0.16666666666666666 (* y y))))))
                                          double code(double x, double y) {
                                          	double tmp;
                                          	if (y <= 4e+250) {
                                          		tmp = 1.0 + (y * (y * (0.0001984126984126984 * (y * (y * (y * y))))));
                                          	} else {
                                          		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                                          	}
                                          	return tmp;
                                          }
                                          
                                          real(8) function code(x, y)
                                              real(8), intent (in) :: x
                                              real(8), intent (in) :: y
                                              real(8) :: tmp
                                              if (y <= 4d+250) then
                                                  tmp = 1.0d0 + (y * (y * (0.0001984126984126984d0 * (y * (y * (y * y))))))
                                              else
                                                  tmp = (1.0d0 + ((x * x) * (-0.5d0))) * (1.0d0 + (0.16666666666666666d0 * (y * y)))
                                              end if
                                              code = tmp
                                          end function
                                          
                                          public static double code(double x, double y) {
                                          	double tmp;
                                          	if (y <= 4e+250) {
                                          		tmp = 1.0 + (y * (y * (0.0001984126984126984 * (y * (y * (y * y))))));
                                          	} else {
                                          		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                                          	}
                                          	return tmp;
                                          }
                                          
                                          def code(x, y):
                                          	tmp = 0
                                          	if y <= 4e+250:
                                          		tmp = 1.0 + (y * (y * (0.0001984126984126984 * (y * (y * (y * y))))))
                                          	else:
                                          		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)))
                                          	return tmp
                                          
                                          function code(x, y)
                                          	tmp = 0.0
                                          	if (y <= 4e+250)
                                          		tmp = Float64(1.0 + Float64(y * Float64(y * Float64(0.0001984126984126984 * Float64(y * Float64(y * Float64(y * y)))))));
                                          	else
                                          		tmp = Float64(Float64(1.0 + Float64(Float64(x * x) * -0.5)) * Float64(1.0 + Float64(0.16666666666666666 * Float64(y * y))));
                                          	end
                                          	return tmp
                                          end
                                          
                                          function tmp_2 = code(x, y)
                                          	tmp = 0.0;
                                          	if (y <= 4e+250)
                                          		tmp = 1.0 + (y * (y * (0.0001984126984126984 * (y * (y * (y * y))))));
                                          	else
                                          		tmp = (1.0 + ((x * x) * -0.5)) * (1.0 + (0.16666666666666666 * (y * y)));
                                          	end
                                          	tmp_2 = tmp;
                                          end
                                          
                                          code[x_, y_] := If[LessEqual[y, 4e+250], N[(1.0 + N[(y * N[(y * N[(0.0001984126984126984 * N[(y * N[(y * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.5), $MachinePrecision]), $MachinePrecision] * N[(1.0 + N[(0.16666666666666666 * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
                                          
                                          \begin{array}{l}
                                          
                                          \\
                                          \begin{array}{l}
                                          \mathbf{if}\;y \leq 4 \cdot 10^{+250}:\\
                                          \;\;\;\;1 + y \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right)\right)\\
                                          
                                          \mathbf{else}:\\
                                          \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\
                                          
                                          
                                          \end{array}
                                          \end{array}
                                          
                                          Derivation
                                          1. Split input into 2 regimes
                                          2. if y < 3.9999999999999997e250

                                            1. Initial program 100.0%

                                              \[\cos x \cdot \frac{\sinh y}{y} \]
                                            2. Add Preprocessing
                                            3. Taylor expanded in y around 0

                                              \[\leadsto \color{blue}{\cos x + {y}^{2} \cdot \left(\frac{1}{6} \cdot \cos x + {y}^{2} \cdot \left(\frac{1}{5040} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{120} \cdot \cos x\right)\right)} \]
                                            4. Simplified93.8%

                                              \[\leadsto \color{blue}{\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right)} \]
                                            5. Taylor expanded in x around 0

                                              \[\leadsto \color{blue}{1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)} \]
                                            6. Step-by-step derivation
                                              1. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \color{blue}{\left({y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)}\right) \]
                                              2. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{6}} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right) \]
                                              3. associate-*l*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \left(y \cdot \color{blue}{\left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)}\right)\right) \]
                                              4. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \color{blue}{\left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)}\right)\right) \]
                                              5. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right) \]
                                              6. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \color{blue}{\left({y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right) \]
                                              7. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{120}} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right) \]
                                              8. associate-*l*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \color{blue}{\left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right) \]
                                              9. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \color{blue}{\left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right) \]
                                              10. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right) \]
                                              11. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right)\right) \]
                                              12. *-commutativeN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left({y}^{2} \cdot \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
                                              13. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
                                              14. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
                                              15. *-lowering-*.f6458.0%

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
                                            7. Simplified58.0%

                                              \[\leadsto \color{blue}{1 + y \cdot \left(y \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)} \]
                                            8. Taylor expanded in y around inf

                                              \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{5}\right)}\right)\right) \]
                                            9. Step-by-step derivation
                                              1. metadata-evalN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(\frac{1}{5040} \cdot {y}^{\left(4 + \color{blue}{1}\right)}\right)\right)\right) \]
                                              2. pow-plusN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(\frac{1}{5040} \cdot \left({y}^{4} \cdot \color{blue}{y}\right)\right)\right)\right) \]
                                              3. associate-*l*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(\left(\frac{1}{5040} \cdot {y}^{4}\right) \cdot \color{blue}{y}\right)\right)\right) \]
                                              4. *-commutativeN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \color{blue}{\left(\frac{1}{5040} \cdot {y}^{4}\right)}\right)\right)\right) \]
                                              5. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{4}\right)}\right)\right)\right) \]
                                              6. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \color{blue}{\left({y}^{4}\right)}\right)\right)\right)\right) \]
                                              7. *-rgt-identityN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{4} \cdot \color{blue}{1}\right)\right)\right)\right)\right) \]
                                              8. *-inversesN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left({y}^{4} \cdot \frac{y}{\color{blue}{y}}\right)\right)\right)\right)\right) \]
                                              9. associate-/l*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(\frac{{y}^{4} \cdot y}{\color{blue}{y}}\right)\right)\right)\right)\right) \]
                                              10. *-commutativeN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(\frac{y \cdot {y}^{4}}{y}\right)\right)\right)\right)\right) \]
                                              11. associate-/l*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \color{blue}{\frac{{y}^{4}}{y}}\right)\right)\right)\right)\right) \]
                                              12. metadata-evalN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \frac{{y}^{\left(2 \cdot 2\right)}}{y}\right)\right)\right)\right)\right) \]
                                              13. pow-sqrN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \frac{{y}^{2} \cdot {y}^{2}}{y}\right)\right)\right)\right)\right) \]
                                              14. associate-/l*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left({y}^{2} \cdot \color{blue}{\frac{{y}^{2}}{y}}\right)\right)\right)\right)\right)\right) \]
                                              15. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{\color{blue}{{y}^{2}}}{y}\right)\right)\right)\right)\right)\right) \]
                                              16. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot \frac{y \cdot y}{y}\right)\right)\right)\right)\right)\right) \]
                                              17. associate-/l*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot \color{blue}{\frac{y}{y}}\right)\right)\right)\right)\right)\right)\right) \]
                                              18. *-inversesN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot \left(y \cdot 1\right)\right)\right)\right)\right)\right)\right) \]
                                              19. *-rgt-identityN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot \left(\left(y \cdot y\right) \cdot y\right)\right)\right)\right)\right)\right) \]
                                              20. unpow3N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \left(y \cdot {y}^{\color{blue}{3}}\right)\right)\right)\right)\right) \]
                                              21. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \color{blue}{\left({y}^{3}\right)}\right)\right)\right)\right)\right) \]
                                              22. cube-multN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left(y \cdot \color{blue}{\left(y \cdot y\right)}\right)\right)\right)\right)\right)\right) \]
                                              23. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \left(y \cdot {y}^{\color{blue}{2}}\right)\right)\right)\right)\right)\right) \]
                                              24. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left({y}^{2}\right)}\right)\right)\right)\right)\right)\right) \]
                                              25. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left(y \cdot \color{blue}{y}\right)\right)\right)\right)\right)\right)\right) \]
                                              26. *-lowering-*.f6458.0%

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(\frac{1}{5040}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{y}\right)\right)\right)\right)\right)\right)\right) \]
                                            10. Simplified58.0%

                                              \[\leadsto 1 + y \cdot \color{blue}{\left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right)\right)} \]

                                            if 3.9999999999999997e250 < y

                                            1. Initial program 100.0%

                                              \[\cos x \cdot \frac{\sinh y}{y} \]
                                            2. Add Preprocessing
                                            3. Taylor expanded in x around 0

                                              \[\leadsto \mathsf{*.f64}\left(\color{blue}{\left(1 + \frac{-1}{2} \cdot {x}^{2}\right)}, \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                            4. Step-by-step derivation
                                              1. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left(\frac{-1}{2} \cdot {x}^{2}\right)\right), \mathsf{/.f64}\left(\color{blue}{\mathsf{sinh.f64}\left(y\right)}, y\right)\right) \]
                                              2. *-commutativeN/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \left({x}^{2} \cdot \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                              3. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({x}^{2}\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                              4. unpow2N/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(x \cdot x\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                              5. *-lowering-*.f6482.4%

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{/.f64}\left(\mathsf{sinh.f64}\left(y\right), y\right)\right) \]
                                            5. Simplified82.4%

                                              \[\leadsto \color{blue}{\left(1 + \left(x \cdot x\right) \cdot -0.5\right)} \cdot \frac{\sinh y}{y} \]
                                            6. Taylor expanded in y around 0

                                              \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \color{blue}{\left(1 + \frac{1}{6} \cdot {y}^{2}\right)}\right) \]
                                            7. Step-by-step derivation
                                              1. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)}\right)\right) \]
                                              2. *-commutativeN/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \left({y}^{2} \cdot \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                                              3. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                                              4. unpow2N/A

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{6}\right)\right)\right) \]
                                              5. *-lowering-*.f6482.4%

                                                \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{-1}{2}\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{6}\right)\right)\right) \]
                                            8. Simplified82.4%

                                              \[\leadsto \left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \color{blue}{\left(1 + \left(y \cdot y\right) \cdot 0.16666666666666666\right)} \]
                                          3. Recombined 2 regimes into one program.
                                          4. Final simplification59.6%

                                            \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 4 \cdot 10^{+250}:\\ \;\;\;\;1 + y \cdot \left(y \cdot \left(0.0001984126984126984 \cdot \left(y \cdot \left(y \cdot \left(y \cdot y\right)\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(1 + \left(x \cdot x\right) \cdot -0.5\right) \cdot \left(1 + 0.16666666666666666 \cdot \left(y \cdot y\right)\right)\\ \end{array} \]
                                          5. Add Preprocessing

                                          Alternative 19: 48.7% accurate, 14.6× speedup?

                                          \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x \leq 1.58 \cdot 10^{+116}:\\ \;\;\;\;1 + y \cdot \left(y \cdot 0.16666666666666666\right)\\ \mathbf{else}:\\ \;\;\;\;0.041666666666666664 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\\ \end{array} \end{array} \]
                                          (FPCore (x y)
                                           :precision binary64
                                           (if (<= x 1.58e+116)
                                             (+ 1.0 (* y (* y 0.16666666666666666)))
                                             (* 0.041666666666666664 (* (* x x) (* x x)))))
                                          double code(double x, double y) {
                                          	double tmp;
                                          	if (x <= 1.58e+116) {
                                          		tmp = 1.0 + (y * (y * 0.16666666666666666));
                                          	} else {
                                          		tmp = 0.041666666666666664 * ((x * 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.58d+116) then
                                                  tmp = 1.0d0 + (y * (y * 0.16666666666666666d0))
                                              else
                                                  tmp = 0.041666666666666664d0 * ((x * x) * (x * x))
                                              end if
                                              code = tmp
                                          end function
                                          
                                          public static double code(double x, double y) {
                                          	double tmp;
                                          	if (x <= 1.58e+116) {
                                          		tmp = 1.0 + (y * (y * 0.16666666666666666));
                                          	} else {
                                          		tmp = 0.041666666666666664 * ((x * x) * (x * x));
                                          	}
                                          	return tmp;
                                          }
                                          
                                          def code(x, y):
                                          	tmp = 0
                                          	if x <= 1.58e+116:
                                          		tmp = 1.0 + (y * (y * 0.16666666666666666))
                                          	else:
                                          		tmp = 0.041666666666666664 * ((x * x) * (x * x))
                                          	return tmp
                                          
                                          function code(x, y)
                                          	tmp = 0.0
                                          	if (x <= 1.58e+116)
                                          		tmp = Float64(1.0 + Float64(y * Float64(y * 0.16666666666666666)));
                                          	else
                                          		tmp = Float64(0.041666666666666664 * Float64(Float64(x * x) * Float64(x * x)));
                                          	end
                                          	return tmp
                                          end
                                          
                                          function tmp_2 = code(x, y)
                                          	tmp = 0.0;
                                          	if (x <= 1.58e+116)
                                          		tmp = 1.0 + (y * (y * 0.16666666666666666));
                                          	else
                                          		tmp = 0.041666666666666664 * ((x * x) * (x * x));
                                          	end
                                          	tmp_2 = tmp;
                                          end
                                          
                                          code[x_, y_] := If[LessEqual[x, 1.58e+116], N[(1.0 + N[(y * N[(y * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(0.041666666666666664 * N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
                                          
                                          \begin{array}{l}
                                          
                                          \\
                                          \begin{array}{l}
                                          \mathbf{if}\;x \leq 1.58 \cdot 10^{+116}:\\
                                          \;\;\;\;1 + y \cdot \left(y \cdot 0.16666666666666666\right)\\
                                          
                                          \mathbf{else}:\\
                                          \;\;\;\;0.041666666666666664 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\\
                                          
                                          
                                          \end{array}
                                          \end{array}
                                          
                                          Derivation
                                          1. Split input into 2 regimes
                                          2. if x < 1.5799999999999999e116

                                            1. Initial program 100.0%

                                              \[\cos x \cdot \frac{\sinh y}{y} \]
                                            2. Add Preprocessing
                                            3. Taylor expanded in y around 0

                                              \[\leadsto \color{blue}{\cos x + {y}^{2} \cdot \left(\frac{1}{6} \cdot \cos x + {y}^{2} \cdot \left(\frac{1}{5040} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{120} \cdot \cos x\right)\right)} \]
                                            4. Simplified94.9%

                                              \[\leadsto \color{blue}{\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right)} \]
                                            5. Taylor expanded in x around 0

                                              \[\leadsto \color{blue}{1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)} \]
                                            6. Step-by-step derivation
                                              1. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \color{blue}{\left({y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)}\right) \]
                                              2. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{6}} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right) \]
                                              3. associate-*l*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \left(y \cdot \color{blue}{\left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)}\right)\right) \]
                                              4. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \color{blue}{\left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)}\right)\right) \]
                                              5. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right) \]
                                              6. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \color{blue}{\left({y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right) \]
                                              7. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{120}} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right) \]
                                              8. associate-*l*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \color{blue}{\left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right) \]
                                              9. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \color{blue}{\left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right) \]
                                              10. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right) \]
                                              11. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right)\right) \]
                                              12. *-commutativeN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left({y}^{2} \cdot \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
                                              13. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
                                              14. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
                                              15. *-lowering-*.f6462.9%

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
                                            7. Simplified62.9%

                                              \[\leadsto \color{blue}{1 + y \cdot \left(y \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)} \]
                                            8. Taylor expanded in y around 0

                                              \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{6} \cdot y\right)}\right)\right) \]
                                            9. Step-by-step derivation
                                              1. *-commutativeN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                                              2. *-lowering-*.f6451.2%

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                                            10. Simplified51.2%

                                              \[\leadsto 1 + y \cdot \color{blue}{\left(y \cdot 0.16666666666666666\right)} \]

                                            if 1.5799999999999999e116 < x

                                            1. Initial program 100.0%

                                              \[\cos x \cdot \frac{\sinh y}{y} \]
                                            2. Add Preprocessing
                                            3. Taylor expanded in y around 0

                                              \[\leadsto \color{blue}{\cos x} \]
                                            4. Step-by-step derivation
                                              1. cos-lowering-cos.f6446.5%

                                                \[\leadsto \mathsf{cos.f64}\left(x\right) \]
                                            5. Simplified46.5%

                                              \[\leadsto \color{blue}{\cos x} \]
                                            6. Taylor expanded in x around 0

                                              \[\leadsto \color{blue}{1 + {x}^{2} \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)} \]
                                            7. Step-by-step derivation
                                              1. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \color{blue}{\left({x}^{2} \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)\right)}\right) \]
                                              2. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \left(\left(x \cdot x\right) \cdot \left(\color{blue}{\frac{1}{24} \cdot {x}^{2}} - \frac{1}{2}\right)\right)\right) \]
                                              3. associate-*l*N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \left(x \cdot \color{blue}{\left(x \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)\right)}\right)\right) \]
                                              4. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \color{blue}{\left(x \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)\right)}\right)\right) \]
                                              5. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \color{blue}{\left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)}\right)\right)\right) \]
                                              6. sub-negN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \left(\frac{1}{24} \cdot {x}^{2} + \color{blue}{\left(\mathsf{neg}\left(\frac{1}{2}\right)\right)}\right)\right)\right)\right) \]
                                              7. metadata-evalN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \left(\frac{1}{24} \cdot {x}^{2} + \frac{-1}{2}\right)\right)\right)\right) \]
                                              8. +-commutativeN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \left(\frac{-1}{2} + \color{blue}{\frac{1}{24} \cdot {x}^{2}}\right)\right)\right)\right) \]
                                              9. +-lowering-+.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \color{blue}{\left(\frac{1}{24} \cdot {x}^{2}\right)}\right)\right)\right)\right) \]
                                              10. *-commutativeN/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \left({x}^{2} \cdot \color{blue}{\frac{1}{24}}\right)\right)\right)\right)\right) \]
                                              11. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \mathsf{*.f64}\left(\left({x}^{2}\right), \color{blue}{\frac{1}{24}}\right)\right)\right)\right)\right) \]
                                              12. unpow2N/A

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \mathsf{*.f64}\left(\left(x \cdot x\right), \frac{1}{24}\right)\right)\right)\right)\right) \]
                                              13. *-lowering-*.f6440.2%

                                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{1}{24}\right)\right)\right)\right)\right) \]
                                            8. Simplified40.2%

                                              \[\leadsto \color{blue}{1 + x \cdot \left(x \cdot \left(-0.5 + \left(x \cdot x\right) \cdot 0.041666666666666664\right)\right)} \]
                                            9. Taylor expanded in x around inf

                                              \[\leadsto \color{blue}{\frac{1}{24} \cdot {x}^{4}} \]
                                            10. Step-by-step derivation
                                              1. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(\frac{1}{24}, \color{blue}{\left({x}^{4}\right)}\right) \]
                                              2. metadata-evalN/A

                                                \[\leadsto \mathsf{*.f64}\left(\frac{1}{24}, \left({x}^{\left(2 \cdot \color{blue}{2}\right)}\right)\right) \]
                                              3. pow-sqrN/A

                                                \[\leadsto \mathsf{*.f64}\left(\frac{1}{24}, \left({x}^{2} \cdot \color{blue}{{x}^{2}}\right)\right) \]
                                              4. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(\frac{1}{24}, \mathsf{*.f64}\left(\left({x}^{2}\right), \color{blue}{\left({x}^{2}\right)}\right)\right) \]
                                              5. unpow2N/A

                                                \[\leadsto \mathsf{*.f64}\left(\frac{1}{24}, \mathsf{*.f64}\left(\left(x \cdot x\right), \left({\color{blue}{x}}^{2}\right)\right)\right) \]
                                              6. *-lowering-*.f64N/A

                                                \[\leadsto \mathsf{*.f64}\left(\frac{1}{24}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \left({\color{blue}{x}}^{2}\right)\right)\right) \]
                                              7. unpow2N/A

                                                \[\leadsto \mathsf{*.f64}\left(\frac{1}{24}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \left(x \cdot \color{blue}{x}\right)\right)\right) \]
                                              8. *-lowering-*.f6440.2%

                                                \[\leadsto \mathsf{*.f64}\left(\frac{1}{24}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \mathsf{*.f64}\left(x, \color{blue}{x}\right)\right)\right) \]
                                            11. Simplified40.2%

                                              \[\leadsto \color{blue}{0.041666666666666664 \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)} \]
                                          3. Recombined 2 regimes into one program.
                                          4. Add Preprocessing

                                          Alternative 20: 31.4% accurate, 17.1× speedup?

                                          \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq 2.9 \cdot 10^{+34}:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;1 + \left(x \cdot x\right) \cdot -0.5\\ \end{array} \end{array} \]
                                          (FPCore (x y)
                                           :precision binary64
                                           (if (<= y 2.9e+34) 1.0 (+ 1.0 (* (* x x) -0.5))))
                                          double code(double x, double y) {
                                          	double tmp;
                                          	if (y <= 2.9e+34) {
                                          		tmp = 1.0;
                                          	} else {
                                          		tmp = 1.0 + ((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 (y <= 2.9d+34) then
                                                  tmp = 1.0d0
                                              else
                                                  tmp = 1.0d0 + ((x * x) * (-0.5d0))
                                              end if
                                              code = tmp
                                          end function
                                          
                                          public static double code(double x, double y) {
                                          	double tmp;
                                          	if (y <= 2.9e+34) {
                                          		tmp = 1.0;
                                          	} else {
                                          		tmp = 1.0 + ((x * x) * -0.5);
                                          	}
                                          	return tmp;
                                          }
                                          
                                          def code(x, y):
                                          	tmp = 0
                                          	if y <= 2.9e+34:
                                          		tmp = 1.0
                                          	else:
                                          		tmp = 1.0 + ((x * x) * -0.5)
                                          	return tmp
                                          
                                          function code(x, y)
                                          	tmp = 0.0
                                          	if (y <= 2.9e+34)
                                          		tmp = 1.0;
                                          	else
                                          		tmp = Float64(1.0 + Float64(Float64(x * x) * -0.5));
                                          	end
                                          	return tmp
                                          end
                                          
                                          function tmp_2 = code(x, y)
                                          	tmp = 0.0;
                                          	if (y <= 2.9e+34)
                                          		tmp = 1.0;
                                          	else
                                          		tmp = 1.0 + ((x * x) * -0.5);
                                          	end
                                          	tmp_2 = tmp;
                                          end
                                          
                                          code[x_, y_] := If[LessEqual[y, 2.9e+34], 1.0, N[(1.0 + N[(N[(x * x), $MachinePrecision] * -0.5), $MachinePrecision]), $MachinePrecision]]
                                          
                                          \begin{array}{l}
                                          
                                          \\
                                          \begin{array}{l}
                                          \mathbf{if}\;y \leq 2.9 \cdot 10^{+34}:\\
                                          \;\;\;\;1\\
                                          
                                          \mathbf{else}:\\
                                          \;\;\;\;1 + \left(x \cdot x\right) \cdot -0.5\\
                                          
                                          
                                          \end{array}
                                          \end{array}
                                          
                                          Derivation
                                          1. Split input into 2 regimes
                                          2. if y < 2.9000000000000001e34

                                            1. Initial program 100.0%

                                              \[\cos x \cdot \frac{\sinh y}{y} \]
                                            2. Add Preprocessing
                                            3. Taylor expanded in y around 0

                                              \[\leadsto \color{blue}{\cos x} \]
                                            4. Step-by-step derivation
                                              1. cos-lowering-cos.f6472.4%

                                                \[\leadsto \mathsf{cos.f64}\left(x\right) \]
                                            5. Simplified72.4%

                                              \[\leadsto \color{blue}{\cos x} \]
                                            6. Taylor expanded in x around 0

                                              \[\leadsto \color{blue}{1} \]
                                            7. Step-by-step derivation
                                              1. Simplified36.4%

                                                \[\leadsto \color{blue}{1} \]

                                              if 2.9000000000000001e34 < y

                                              1. Initial program 100.0%

                                                \[\cos x \cdot \frac{\sinh y}{y} \]
                                              2. Add Preprocessing
                                              3. Taylor expanded in y around 0

                                                \[\leadsto \color{blue}{\cos x} \]
                                              4. Step-by-step derivation
                                                1. cos-lowering-cos.f643.1%

                                                  \[\leadsto \mathsf{cos.f64}\left(x\right) \]
                                              5. Simplified3.1%

                                                \[\leadsto \color{blue}{\cos x} \]
                                              6. Taylor expanded in x around 0

                                                \[\leadsto \color{blue}{1 + \frac{-1}{2} \cdot {x}^{2}} \]
                                              7. Step-by-step derivation
                                                1. +-lowering-+.f64N/A

                                                  \[\leadsto \mathsf{+.f64}\left(1, \color{blue}{\left(\frac{-1}{2} \cdot {x}^{2}\right)}\right) \]
                                                2. *-lowering-*.f64N/A

                                                  \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\frac{-1}{2}, \color{blue}{\left({x}^{2}\right)}\right)\right) \]
                                                3. unpow2N/A

                                                  \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\frac{-1}{2}, \left(x \cdot \color{blue}{x}\right)\right)\right) \]
                                                4. *-lowering-*.f648.9%

                                                  \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\frac{-1}{2}, \mathsf{*.f64}\left(x, \color{blue}{x}\right)\right)\right) \]
                                              8. Simplified8.9%

                                                \[\leadsto \color{blue}{1 + -0.5 \cdot \left(x \cdot x\right)} \]
                                            8. Recombined 2 regimes into one program.
                                            9. Final simplification29.6%

                                              \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 2.9 \cdot 10^{+34}:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;1 + \left(x \cdot x\right) \cdot -0.5\\ \end{array} \]
                                            10. Add Preprocessing

                                            Alternative 21: 31.1% accurate, 20.5× speedup?

                                            \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq 2.32 \cdot 10^{+42}:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;\left(x \cdot x\right) \cdot -0.5\\ \end{array} \end{array} \]
                                            (FPCore (x y) :precision binary64 (if (<= y 2.32e+42) 1.0 (* (* x x) -0.5)))
                                            double code(double x, double y) {
                                            	double tmp;
                                            	if (y <= 2.32e+42) {
                                            		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 (y <= 2.32d+42) 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 (y <= 2.32e+42) {
                                            		tmp = 1.0;
                                            	} else {
                                            		tmp = (x * x) * -0.5;
                                            	}
                                            	return tmp;
                                            }
                                            
                                            def code(x, y):
                                            	tmp = 0
                                            	if y <= 2.32e+42:
                                            		tmp = 1.0
                                            	else:
                                            		tmp = (x * x) * -0.5
                                            	return tmp
                                            
                                            function code(x, y)
                                            	tmp = 0.0
                                            	if (y <= 2.32e+42)
                                            		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 (y <= 2.32e+42)
                                            		tmp = 1.0;
                                            	else
                                            		tmp = (x * x) * -0.5;
                                            	end
                                            	tmp_2 = tmp;
                                            end
                                            
                                            code[x_, y_] := If[LessEqual[y, 2.32e+42], 1.0, N[(N[(x * x), $MachinePrecision] * -0.5), $MachinePrecision]]
                                            
                                            \begin{array}{l}
                                            
                                            \\
                                            \begin{array}{l}
                                            \mathbf{if}\;y \leq 2.32 \cdot 10^{+42}:\\
                                            \;\;\;\;1\\
                                            
                                            \mathbf{else}:\\
                                            \;\;\;\;\left(x \cdot x\right) \cdot -0.5\\
                                            
                                            
                                            \end{array}
                                            \end{array}
                                            
                                            Derivation
                                            1. Split input into 2 regimes
                                            2. if y < 2.31999999999999991e42

                                              1. Initial program 100.0%

                                                \[\cos x \cdot \frac{\sinh y}{y} \]
                                              2. Add Preprocessing
                                              3. Taylor expanded in y around 0

                                                \[\leadsto \color{blue}{\cos x} \]
                                              4. Step-by-step derivation
                                                1. cos-lowering-cos.f6471.4%

                                                  \[\leadsto \mathsf{cos.f64}\left(x\right) \]
                                              5. Simplified71.4%

                                                \[\leadsto \color{blue}{\cos x} \]
                                              6. Taylor expanded in x around 0

                                                \[\leadsto \color{blue}{1} \]
                                              7. Step-by-step derivation
                                                1. Simplified35.9%

                                                  \[\leadsto \color{blue}{1} \]

                                                if 2.31999999999999991e42 < y

                                                1. Initial program 100.0%

                                                  \[\cos x \cdot \frac{\sinh y}{y} \]
                                                2. Add Preprocessing
                                                3. Taylor expanded in y around 0

                                                  \[\leadsto \color{blue}{\cos x} \]
                                                4. Step-by-step derivation
                                                  1. cos-lowering-cos.f643.1%

                                                    \[\leadsto \mathsf{cos.f64}\left(x\right) \]
                                                5. Simplified3.1%

                                                  \[\leadsto \color{blue}{\cos x} \]
                                                6. Taylor expanded in x around 0

                                                  \[\leadsto \color{blue}{1 + {x}^{2} \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)} \]
                                                7. Step-by-step derivation
                                                  1. +-lowering-+.f64N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \color{blue}{\left({x}^{2} \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)\right)}\right) \]
                                                  2. unpow2N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \left(\left(x \cdot x\right) \cdot \left(\color{blue}{\frac{1}{24} \cdot {x}^{2}} - \frac{1}{2}\right)\right)\right) \]
                                                  3. associate-*l*N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \left(x \cdot \color{blue}{\left(x \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)\right)}\right)\right) \]
                                                  4. *-lowering-*.f64N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \color{blue}{\left(x \cdot \left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)\right)}\right)\right) \]
                                                  5. *-lowering-*.f64N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \color{blue}{\left(\frac{1}{24} \cdot {x}^{2} - \frac{1}{2}\right)}\right)\right)\right) \]
                                                  6. sub-negN/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \left(\frac{1}{24} \cdot {x}^{2} + \color{blue}{\left(\mathsf{neg}\left(\frac{1}{2}\right)\right)}\right)\right)\right)\right) \]
                                                  7. metadata-evalN/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \left(\frac{1}{24} \cdot {x}^{2} + \frac{-1}{2}\right)\right)\right)\right) \]
                                                  8. +-commutativeN/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \left(\frac{-1}{2} + \color{blue}{\frac{1}{24} \cdot {x}^{2}}\right)\right)\right)\right) \]
                                                  9. +-lowering-+.f64N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \color{blue}{\left(\frac{1}{24} \cdot {x}^{2}\right)}\right)\right)\right)\right) \]
                                                  10. *-commutativeN/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \left({x}^{2} \cdot \color{blue}{\frac{1}{24}}\right)\right)\right)\right)\right) \]
                                                  11. *-lowering-*.f64N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \mathsf{*.f64}\left(\left({x}^{2}\right), \color{blue}{\frac{1}{24}}\right)\right)\right)\right)\right) \]
                                                  12. unpow2N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \mathsf{*.f64}\left(\left(x \cdot x\right), \frac{1}{24}\right)\right)\right)\right)\right) \]
                                                  13. *-lowering-*.f6419.0%

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \mathsf{+.f64}\left(\frac{-1}{2}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \frac{1}{24}\right)\right)\right)\right)\right) \]
                                                8. Simplified19.0%

                                                  \[\leadsto \color{blue}{1 + x \cdot \left(x \cdot \left(-0.5 + \left(x \cdot x\right) \cdot 0.041666666666666664\right)\right)} \]
                                                9. Taylor expanded in x around 0

                                                  \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(x, \mathsf{*.f64}\left(x, \color{blue}{\frac{-1}{2}}\right)\right)\right) \]
                                                10. Step-by-step derivation
                                                  1. Simplified9.2%

                                                    \[\leadsto 1 + x \cdot \left(x \cdot \color{blue}{-0.5}\right) \]
                                                  2. Taylor expanded in x around inf

                                                    \[\leadsto \color{blue}{\frac{-1}{2} \cdot {x}^{2}} \]
                                                  3. Step-by-step derivation
                                                    1. *-lowering-*.f64N/A

                                                      \[\leadsto \mathsf{*.f64}\left(\frac{-1}{2}, \color{blue}{\left({x}^{2}\right)}\right) \]
                                                    2. unpow2N/A

                                                      \[\leadsto \mathsf{*.f64}\left(\frac{-1}{2}, \left(x \cdot \color{blue}{x}\right)\right) \]
                                                    3. *-lowering-*.f648.3%

                                                      \[\leadsto \mathsf{*.f64}\left(\frac{-1}{2}, \mathsf{*.f64}\left(x, \color{blue}{x}\right)\right) \]
                                                  4. Simplified8.3%

                                                    \[\leadsto \color{blue}{-0.5 \cdot \left(x \cdot x\right)} \]
                                                11. Recombined 2 regimes into one program.
                                                12. Final simplification29.4%

                                                  \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 2.32 \cdot 10^{+42}:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;\left(x \cdot x\right) \cdot -0.5\\ \end{array} \]
                                                13. Add Preprocessing

                                                Alternative 22: 47.8% accurate, 29.3× speedup?

                                                \[\begin{array}{l} \\ 1 + y \cdot \left(y \cdot 0.16666666666666666\right) \end{array} \]
                                                (FPCore (x y) :precision binary64 (+ 1.0 (* y (* y 0.16666666666666666))))
                                                double code(double x, double y) {
                                                	return 1.0 + (y * (y * 0.16666666666666666));
                                                }
                                                
                                                real(8) function code(x, y)
                                                    real(8), intent (in) :: x
                                                    real(8), intent (in) :: y
                                                    code = 1.0d0 + (y * (y * 0.16666666666666666d0))
                                                end function
                                                
                                                public static double code(double x, double y) {
                                                	return 1.0 + (y * (y * 0.16666666666666666));
                                                }
                                                
                                                def code(x, y):
                                                	return 1.0 + (y * (y * 0.16666666666666666))
                                                
                                                function code(x, y)
                                                	return Float64(1.0 + Float64(y * Float64(y * 0.16666666666666666)))
                                                end
                                                
                                                function tmp = code(x, y)
                                                	tmp = 1.0 + (y * (y * 0.16666666666666666));
                                                end
                                                
                                                code[x_, y_] := N[(1.0 + N[(y * N[(y * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
                                                
                                                \begin{array}{l}
                                                
                                                \\
                                                1 + y \cdot \left(y \cdot 0.16666666666666666\right)
                                                \end{array}
                                                
                                                Derivation
                                                1. Initial program 100.0%

                                                  \[\cos x \cdot \frac{\sinh y}{y} \]
                                                2. Add Preprocessing
                                                3. Taylor expanded in y around 0

                                                  \[\leadsto \color{blue}{\cos x + {y}^{2} \cdot \left(\frac{1}{6} \cdot \cos x + {y}^{2} \cdot \left(\frac{1}{5040} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{120} \cdot \cos x\right)\right)} \]
                                                4. Simplified94.2%

                                                  \[\leadsto \color{blue}{\cos x \cdot \left(1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + y \cdot \left(y \cdot 0.0001984126984126984\right)\right)\right)\right)\right)} \]
                                                5. Taylor expanded in x around 0

                                                  \[\leadsto \color{blue}{1 + {y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)} \]
                                                6. Step-by-step derivation
                                                  1. +-lowering-+.f64N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \color{blue}{\left({y}^{2} \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)}\right) \]
                                                  2. unpow2N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{6}} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right) \]
                                                  3. associate-*l*N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \left(y \cdot \color{blue}{\left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)}\right)\right) \]
                                                  4. *-lowering-*.f64N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \color{blue}{\left(y \cdot \left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)}\right)\right) \]
                                                  5. *-lowering-*.f64N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{6} + {y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right) \]
                                                  6. +-lowering-+.f64N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \color{blue}{\left({y}^{2} \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right) \]
                                                  7. unpow2N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(\left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{120}} + \frac{1}{5040} \cdot {y}^{2}\right)\right)\right)\right)\right)\right) \]
                                                  8. associate-*l*N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left(y \cdot \color{blue}{\left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right) \]
                                                  9. *-lowering-*.f64N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \color{blue}{\left(y \cdot \left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)\right)}\right)\right)\right)\right)\right) \]
                                                  10. *-lowering-*.f64N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right) \]
                                                  11. +-lowering-+.f64N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right)\right) \]
                                                  12. *-commutativeN/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \left({y}^{2} \cdot \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
                                                  13. *-lowering-*.f64N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{1}{5040}}\right)\right)\right)\right)\right)\right)\right)\right) \]
                                                  14. unpow2N/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
                                                  15. *-lowering-*.f6458.4%

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{120}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{5040}\right)\right)\right)\right)\right)\right)\right)\right) \]
                                                7. Simplified58.4%

                                                  \[\leadsto \color{blue}{1 + y \cdot \left(y \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)} \]
                                                8. Taylor expanded in y around 0

                                                  \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \color{blue}{\left(\frac{1}{6} \cdot y\right)}\right)\right) \]
                                                9. Step-by-step derivation
                                                  1. *-commutativeN/A

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \left(y \cdot \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                                                  2. *-lowering-*.f6447.0%

                                                    \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                                                10. Simplified47.0%

                                                  \[\leadsto 1 + y \cdot \color{blue}{\left(y \cdot 0.16666666666666666\right)} \]
                                                11. Add Preprocessing

                                                Alternative 23: 28.6% accurate, 205.0× speedup?

                                                \[\begin{array}{l} \\ 1 \end{array} \]
                                                (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}
                                                
                                                Derivation
                                                1. Initial program 100.0%

                                                  \[\cos x \cdot \frac{\sinh y}{y} \]
                                                2. Add Preprocessing
                                                3. Taylor expanded in y around 0

                                                  \[\leadsto \color{blue}{\cos x} \]
                                                4. Step-by-step derivation
                                                  1. cos-lowering-cos.f6455.4%

                                                    \[\leadsto \mathsf{cos.f64}\left(x\right) \]
                                                5. Simplified55.4%

                                                  \[\leadsto \color{blue}{\cos x} \]
                                                6. Taylor expanded in x around 0

                                                  \[\leadsto \color{blue}{1} \]
                                                7. Step-by-step derivation
                                                  1. Simplified28.1%

                                                    \[\leadsto \color{blue}{1} \]
                                                  2. Add Preprocessing

                                                  Reproduce

                                                  ?
                                                  herbie shell --seed 2024141 
                                                  (FPCore (x y)
                                                    :name "Linear.Quaternion:$csin from linear-1.19.1.3"
                                                    :precision binary64
                                                    (* (cos x) (/ (sinh y) y)))