Linear.Quaternion:$csin from linear-1.19.1.3

Percentage Accurate: 100.0% → 100.0%
Time: 11.6s
Alternatives: 18
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 18 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: 73.3% accurate, 1.6× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;y \leq 0.26:\\
\;\;\;\;\frac{\cos x}{1 + y \cdot \left(y \cdot \left(-0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.019444444444444445 + \left(y \cdot y\right) \cdot -0.00205026455026455\right)\right)\right)}\\

\mathbf{elif}\;y \leq 3.8 \cdot 10^{+77}:\\
\;\;\;\;\frac{\sinh y}{y}\\

\mathbf{else}:\\
\;\;\;\;\cos x \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)\\


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

    1. Initial program 100.0%

      \[\cos x \cdot \frac{\sinh y}{y} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. clear-numN/A

        \[\leadsto \cos x \cdot \frac{1}{\color{blue}{\frac{y}{\sinh y}}} \]
      2. un-div-invN/A

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

        \[\leadsto \mathsf{/.f64}\left(\cos x, \color{blue}{\left(\frac{y}{\sinh y}\right)}\right) \]
      4. cos-lowering-cos.f64N/A

        \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \left(\frac{\color{blue}{y}}{\sinh y}\right)\right) \]
      5. /-lowering-/.f64N/A

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

        \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{/.f64}\left(y, \mathsf{sinh.f64}\left(y\right)\right)\right) \]
    4. Applied egg-rr100.0%

      \[\leadsto \color{blue}{\frac{\cos x}{\frac{y}{\sinh y}}} \]
    5. Taylor expanded in y around 0

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

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

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

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

        \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \left(y \cdot \left(\left({y}^{2} \cdot \left(\frac{7}{360} + \frac{-31}{15120} \cdot {y}^{2}\right) - \frac{1}{6}\right) \cdot \color{blue}{y}\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, \color{blue}{\left(\left({y}^{2} \cdot \left(\frac{7}{360} + \frac{-31}{15120} \cdot {y}^{2}\right) - \frac{1}{6}\right) \cdot y\right)}\right)\right)\right) \]
      6. *-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({y}^{2} \cdot \left(\frac{7}{360} + \frac{-31}{15120} \cdot {y}^{2}\right) - \frac{1}{6}\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, \color{blue}{\left({y}^{2} \cdot \left(\frac{7}{360} + \frac{-31}{15120} \cdot {y}^{2}\right) - \frac{1}{6}\right)}\right)\right)\right)\right) \]
      8. sub-negN/A

        \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \left({y}^{2} \cdot \left(\frac{7}{360} + \frac{-31}{15120} \cdot {y}^{2}\right) + \color{blue}{\left(\mathsf{neg}\left(\frac{1}{6}\right)\right)}\right)\right)\right)\right)\right) \]
      9. 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, \left({y}^{2} \cdot \left(\frac{7}{360} + \frac{-31}{15120} \cdot {y}^{2}\right) + \frac{-1}{6}\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, \left(\frac{-1}{6} + \color{blue}{{y}^{2} \cdot \left(\frac{7}{360} + \frac{-31}{15120} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right) \]
      11. +-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}, \color{blue}{\left({y}^{2} \cdot \left(\frac{7}{360} + \frac{-31}{15120} \cdot {y}^{2}\right)\right)}\right)\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(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{-1}{6}, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\left(\frac{7}{360} + \frac{-31}{15120} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right) \]
      13. 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(\left(y \cdot y\right), \left(\color{blue}{\frac{7}{360}} + \frac{-31}{15120} \cdot {y}^{2}\right)\right)\right)\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(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{-1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(\color{blue}{\frac{7}{360}} + \frac{-31}{15120} \cdot {y}^{2}\right)\right)\right)\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(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{-1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{7}{360}, \color{blue}{\left(\frac{-31}{15120} \cdot {y}^{2}\right)}\right)\right)\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(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{-1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{7}{360}, \left({y}^{2} \cdot \color{blue}{\frac{-31}{15120}}\right)\right)\right)\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(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{-1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{7}{360}, \mathsf{*.f64}\left(\left({y}^{2}\right), \color{blue}{\frac{-31}{15120}}\right)\right)\right)\right)\right)\right)\right)\right) \]
      18. 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(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{7}{360}, \mathsf{*.f64}\left(\left(y \cdot y\right), \frac{-31}{15120}\right)\right)\right)\right)\right)\right)\right)\right) \]
      19. *-lowering-*.f6470.1%

        \[\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(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{7}{360}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{-31}{15120}\right)\right)\right)\right)\right)\right)\right)\right) \]
    7. Simplified70.1%

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

    if 0.26000000000000001 < y < 3.8000000000000001e77

    1. Initial program 100.0%

      \[\cos x \cdot \frac{\sinh y}{y} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. clear-numN/A

        \[\leadsto \cos x \cdot \frac{1}{\color{blue}{\frac{y}{\sinh y}}} \]
      2. un-div-invN/A

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

        \[\leadsto \mathsf{/.f64}\left(\cos x, \color{blue}{\left(\frac{y}{\sinh y}\right)}\right) \]
      4. cos-lowering-cos.f64N/A

        \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \left(\frac{\color{blue}{y}}{\sinh y}\right)\right) \]
      5. /-lowering-/.f64N/A

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

        \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{/.f64}\left(y, \mathsf{sinh.f64}\left(y\right)\right)\right) \]
    4. Applied egg-rr100.0%

      \[\leadsto \color{blue}{\frac{\cos x}{\frac{y}{\sinh y}}} \]
    5. Taylor expanded in x around 0

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

        \[\leadsto \frac{\color{blue}{1}}{\frac{y}{\sinh y}} \]
      2. Step-by-step derivation
        1. clear-numN/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.f6481.8%

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

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

      if 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. distribute-rgt-inN/A

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

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

          \[\leadsto \cos x \cdot 1 + {y}^{2} \cdot \color{blue}{\left(\frac{1}{120} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{6} \cdot \cos x\right)} \]
        4. *-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}} \]
        5. 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} \]
        6. 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} \]
        7. +-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} \]
        8. 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)} \]
        9. *-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) \]
        10. 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)} \]
        11. *-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) \]
        12. 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) \]
        13. +-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) \]
      5. Simplified100.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)} \]
    7. Recombined 3 regimes into one program.
    8. Add Preprocessing

    Alternative 3: 92.3% 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 0.39:\\ \;\;\;\;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 0.39) 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 <= 0.39) {
    		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 <= 0.39d0) 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 <= 0.39) {
    		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 <= 0.39:
    		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 <= 0.39)
    		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 <= 0.39)
    		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, 0.39], 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 0.39:\\
    \;\;\;\;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 < 0.39000000000000001 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. distribute-rgt-inN/A

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

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

          \[\leadsto \cos x \cdot 1 + {y}^{2} \cdot \color{blue}{\left(\frac{1}{120} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{6} \cdot \cos x\right)} \]
        4. *-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}} \]
        5. 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} \]
        6. 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} \]
        7. +-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} \]
        8. 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)} \]
        9. *-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) \]
        10. 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)} \]
        11. *-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) \]
        12. 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) \]
        13. +-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) \]
      5. Simplified96.1%

        \[\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 0.39000000000000001 < y < 3.8000000000000001e77

      1. Initial program 100.0%

        \[\cos x \cdot \frac{\sinh y}{y} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. clear-numN/A

          \[\leadsto \cos x \cdot \frac{1}{\color{blue}{\frac{y}{\sinh y}}} \]
        2. un-div-invN/A

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

          \[\leadsto \mathsf{/.f64}\left(\cos x, \color{blue}{\left(\frac{y}{\sinh y}\right)}\right) \]
        4. cos-lowering-cos.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \left(\frac{\color{blue}{y}}{\sinh y}\right)\right) \]
        5. /-lowering-/.f64N/A

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

          \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{/.f64}\left(y, \mathsf{sinh.f64}\left(y\right)\right)\right) \]
      4. Applied egg-rr100.0%

        \[\leadsto \color{blue}{\frac{\cos x}{\frac{y}{\sinh y}}} \]
      5. Taylor expanded in x around 0

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

          \[\leadsto \frac{\color{blue}{1}}{\frac{y}{\sinh y}} \]
        2. Step-by-step derivation
          1. clear-numN/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.f6481.8%

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

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

      Alternative 4: 84.5% accurate, 1.7× speedup?

      \[\begin{array}{l} \\ \begin{array}{l} t_0 := \cos x \cdot \left(1 + \left(y \cdot y\right) \cdot 0.16666666666666666\right)\\ \mathbf{if}\;y \leq 0.054:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;y \leq 1.32 \cdot 10^{+154}:\\ \;\;\;\;\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)))))
         (if (<= y 0.054) t_0 (if (<= y 1.32e+154) (/ (sinh y) y) t_0))))
      double code(double x, double y) {
      	double t_0 = cos(x) * (1.0 + ((y * y) * 0.16666666666666666));
      	double tmp;
      	if (y <= 0.054) {
      		tmp = t_0;
      	} else if (y <= 1.32e+154) {
      		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))
          if (y <= 0.054d0) then
              tmp = t_0
          else if (y <= 1.32d+154) 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));
      	double tmp;
      	if (y <= 0.054) {
      		tmp = t_0;
      	} else if (y <= 1.32e+154) {
      		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))
      	tmp = 0
      	if y <= 0.054:
      		tmp = t_0
      	elif y <= 1.32e+154:
      		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) * 0.16666666666666666)))
      	tmp = 0.0
      	if (y <= 0.054)
      		tmp = t_0;
      	elseif (y <= 1.32e+154)
      		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));
      	tmp = 0.0;
      	if (y <= 0.054)
      		tmp = t_0;
      	elseif (y <= 1.32e+154)
      		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] * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, 0.054], t$95$0, If[LessEqual[y, 1.32e+154], 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 0.16666666666666666\right)\\
      \mathbf{if}\;y \leq 0.054:\\
      \;\;\;\;t\_0\\
      
      \mathbf{elif}\;y \leq 1.32 \cdot 10^{+154}:\\
      \;\;\;\;\frac{\sinh y}{y}\\
      
      \mathbf{else}:\\
      \;\;\;\;t\_0\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 2 regimes
      2. if y < 0.0539999999999999994 or 1.31999999999999998e154 < 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. associate-*r*N/A

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

            \[\leadsto 1 \cdot \cos x + \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)} \cdot \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. *-lowering-*.f64N/A

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

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

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

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

        if 0.0539999999999999994 < y < 1.31999999999999998e154

        1. Initial program 100.0%

          \[\cos x \cdot \frac{\sinh y}{y} \]
        2. Add Preprocessing
        3. Step-by-step derivation
          1. clear-numN/A

            \[\leadsto \cos x \cdot \frac{1}{\color{blue}{\frac{y}{\sinh y}}} \]
          2. un-div-invN/A

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

            \[\leadsto \mathsf{/.f64}\left(\cos x, \color{blue}{\left(\frac{y}{\sinh y}\right)}\right) \]
          4. cos-lowering-cos.f64N/A

            \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \left(\frac{\color{blue}{y}}{\sinh y}\right)\right) \]
          5. /-lowering-/.f64N/A

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

            \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{/.f64}\left(y, \mathsf{sinh.f64}\left(y\right)\right)\right) \]
        4. Applied egg-rr100.0%

          \[\leadsto \color{blue}{\frac{\cos x}{\frac{y}{\sinh y}}} \]
        5. Taylor expanded in x around 0

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

            \[\leadsto \frac{\color{blue}{1}}{\frac{y}{\sinh y}} \]
          2. Step-by-step derivation
            1. clear-numN/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.f6484.0%

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

            \[\leadsto \color{blue}{\frac{\sinh y}{y}} \]
        7. Recombined 2 regimes into one program.
        8. Final simplification90.1%

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

        Alternative 5: 68.4% accurate, 1.9× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq 0.00096:\\ \;\;\;\;\cos x\\ \mathbf{else}:\\ \;\;\;\;\frac{\sinh y}{y}\\ \end{array} \end{array} \]
        (FPCore (x y) :precision binary64 (if (<= y 0.00096) (cos x) (/ (sinh y) y)))
        double code(double x, double y) {
        	double tmp;
        	if (y <= 0.00096) {
        		tmp = cos(x);
        	} else {
        		tmp = sinh(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 <= 0.00096d0) then
                tmp = cos(x)
            else
                tmp = sinh(y) / y
            end if
            code = tmp
        end function
        
        public static double code(double x, double y) {
        	double tmp;
        	if (y <= 0.00096) {
        		tmp = Math.cos(x);
        	} else {
        		tmp = Math.sinh(y) / y;
        	}
        	return tmp;
        }
        
        def code(x, y):
        	tmp = 0
        	if y <= 0.00096:
        		tmp = math.cos(x)
        	else:
        		tmp = math.sinh(y) / y
        	return tmp
        
        function code(x, y)
        	tmp = 0.0
        	if (y <= 0.00096)
        		tmp = cos(x);
        	else
        		tmp = Float64(sinh(y) / y);
        	end
        	return tmp
        end
        
        function tmp_2 = code(x, y)
        	tmp = 0.0;
        	if (y <= 0.00096)
        		tmp = cos(x);
        	else
        		tmp = sinh(y) / y;
        	end
        	tmp_2 = tmp;
        end
        
        code[x_, y_] := If[LessEqual[y, 0.00096], N[Cos[x], $MachinePrecision], N[(N[Sinh[y], $MachinePrecision] / y), $MachinePrecision]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        \mathbf{if}\;y \leq 0.00096:\\
        \;\;\;\;\cos x\\
        
        \mathbf{else}:\\
        \;\;\;\;\frac{\sinh y}{y}\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 2 regimes
        2. if y < 9.60000000000000024e-4

          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.f6469.7%

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

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

          if 9.60000000000000024e-4 < y

          1. Initial program 100.0%

            \[\cos x \cdot \frac{\sinh y}{y} \]
          2. Add Preprocessing
          3. Step-by-step derivation
            1. clear-numN/A

              \[\leadsto \cos x \cdot \frac{1}{\color{blue}{\frac{y}{\sinh y}}} \]
            2. un-div-invN/A

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

              \[\leadsto \mathsf{/.f64}\left(\cos x, \color{blue}{\left(\frac{y}{\sinh y}\right)}\right) \]
            4. cos-lowering-cos.f64N/A

              \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \left(\frac{\color{blue}{y}}{\sinh y}\right)\right) \]
            5. /-lowering-/.f64N/A

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

              \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{/.f64}\left(y, \mathsf{sinh.f64}\left(y\right)\right)\right) \]
          4. Applied egg-rr100.0%

            \[\leadsto \color{blue}{\frac{\cos x}{\frac{y}{\sinh y}}} \]
          5. Taylor expanded in x around 0

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

              \[\leadsto \frac{\color{blue}{1}}{\frac{y}{\sinh y}} \]
            2. Step-by-step derivation
              1. clear-numN/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.0%

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

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

          Alternative 6: 66.7% accurate, 1.9× speedup?

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

            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.f6469.7%

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

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

            if 9.60000000000000024e-4 < y < 2.80000000000000001e39

            1. Initial program 100.0%

              \[\cos x \cdot \frac{\sinh y}{y} \]
            2. Add Preprocessing
            3. Step-by-step derivation
              1. clear-numN/A

                \[\leadsto \cos x \cdot \frac{1}{\color{blue}{\frac{y}{\sinh y}}} \]
              2. un-div-invN/A

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

                \[\leadsto \mathsf{/.f64}\left(\cos x, \color{blue}{\left(\frac{y}{\sinh y}\right)}\right) \]
              4. cos-lowering-cos.f64N/A

                \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \left(\frac{\color{blue}{y}}{\sinh y}\right)\right) \]
              5. /-lowering-/.f64N/A

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

                \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{/.f64}\left(y, \mathsf{sinh.f64}\left(y\right)\right)\right) \]
            4. Applied egg-rr100.0%

              \[\leadsto \color{blue}{\frac{\cos x}{\frac{y}{\sinh y}}} \]
            5. Taylor expanded in x around 0

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

                \[\leadsto \frac{\color{blue}{1}}{\frac{y}{\sinh y}} \]
              2. Taylor expanded in y 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)} \]
              3. 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. *-lowering-*.f64N/A

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

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

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

                  \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                6. *-lowering-*.f64N/A

                  \[\leadsto \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}{\left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right) \]
                7. unpow2N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

              if 2.80000000000000001e39 < y

              1. Initial program 100.0%

                \[\cos x \cdot \frac{\sinh y}{y} \]
              2. Add Preprocessing
              3. Step-by-step derivation
                1. clear-numN/A

                  \[\leadsto \cos x \cdot \frac{1}{\color{blue}{\frac{y}{\sinh y}}} \]
                2. un-div-invN/A

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

                  \[\leadsto \mathsf{/.f64}\left(\cos x, \color{blue}{\left(\frac{y}{\sinh y}\right)}\right) \]
                4. cos-lowering-cos.f64N/A

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \left(\frac{\color{blue}{y}}{\sinh y}\right)\right) \]
                5. /-lowering-/.f64N/A

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

                  \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{/.f64}\left(y, \mathsf{sinh.f64}\left(y\right)\right)\right) \]
              4. Applied egg-rr100.0%

                \[\leadsto \color{blue}{\frac{\cos x}{\frac{y}{\sinh y}}} \]
              5. Taylor expanded in x around 0

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

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

                  \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \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)}\right)\right) \]
                3. Step-by-step derivation
                  1. *-lowering-*.f64N/A

                    \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\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)\right)\right) \]
                  2. +-lowering-+.f64N/A

                    \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \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)\right)\right)\right) \]
                  3. *-lowering-*.f64N/A

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

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

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

                    \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \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}{\left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right)\right) \]
                  8. unpow2N/A

                    \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\left(y \cdot y\right), \left(\color{blue}{\frac{1}{120}} + \frac{1}{5040} \cdot {y}^{2}\right)\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(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(\color{blue}{\frac{1}{120}} + \frac{1}{5040} \cdot {y}^{2}\right)\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(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{120}, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right)\right)\right) \]
                  11. *-commutativeN/A

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

                    \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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)\right) \]
                  13. unpow2N/A

                    \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                  14. *-lowering-*.f6478.0%

                    \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                4. Simplified78.0%

                  \[\leadsto \frac{1}{\frac{y}{\color{blue}{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)}}} \]
              7. Recombined 3 regimes into one program.
              8. Final simplification71.2%

                \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 0.00096:\\ \;\;\;\;\cos x\\ \mathbf{elif}\;y \leq 2.8 \cdot 10^{+39}:\\ \;\;\;\;1 + \frac{\left(y \cdot y\right) \cdot \left(0.004629629629629629 + \left(\left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right) \cdot \left(\left(\left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right) \cdot \left(\left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)}{0.027777777777777776 + \left(\left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right) \cdot \left(\left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right) - 0.16666666666666666\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{\frac{y}{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)}}\\ \end{array} \]
              9. Add Preprocessing

              Alternative 7: 45.5% accurate, 2.7× speedup?

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

                1. Initial program 100.0%

                  \[\cos x \cdot \frac{\sinh y}{y} \]
                2. Add Preprocessing
                3. Step-by-step derivation
                  1. clear-numN/A

                    \[\leadsto \cos x \cdot \frac{1}{\color{blue}{\frac{y}{\sinh y}}} \]
                  2. un-div-invN/A

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

                    \[\leadsto \mathsf{/.f64}\left(\cos x, \color{blue}{\left(\frac{y}{\sinh y}\right)}\right) \]
                  4. cos-lowering-cos.f64N/A

                    \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \left(\frac{\color{blue}{y}}{\sinh y}\right)\right) \]
                  5. /-lowering-/.f64N/A

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

                    \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{/.f64}\left(y, \mathsf{sinh.f64}\left(y\right)\right)\right) \]
                4. Applied egg-rr100.0%

                  \[\leadsto \color{blue}{\frac{\cos x}{\frac{y}{\sinh y}}} \]
                5. Taylor expanded in x around 0

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

                    \[\leadsto \frac{\color{blue}{1}}{\frac{y}{\sinh y}} \]
                  2. Taylor expanded in y 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)} \]
                  3. 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. *-lowering-*.f64N/A

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

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

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

                      \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                    6. *-lowering-*.f64N/A

                      \[\leadsto \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}{\left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right) \]
                    7. unpow2N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

                  if 2.80000000000000001e39 < y

                  1. Initial program 100.0%

                    \[\cos x \cdot \frac{\sinh y}{y} \]
                  2. Add Preprocessing
                  3. Step-by-step derivation
                    1. clear-numN/A

                      \[\leadsto \cos x \cdot \frac{1}{\color{blue}{\frac{y}{\sinh y}}} \]
                    2. un-div-invN/A

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

                      \[\leadsto \mathsf{/.f64}\left(\cos x, \color{blue}{\left(\frac{y}{\sinh y}\right)}\right) \]
                    4. cos-lowering-cos.f64N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \left(\frac{\color{blue}{y}}{\sinh y}\right)\right) \]
                    5. /-lowering-/.f64N/A

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

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{/.f64}\left(y, \mathsf{sinh.f64}\left(y\right)\right)\right) \]
                  4. Applied egg-rr100.0%

                    \[\leadsto \color{blue}{\frac{\cos x}{\frac{y}{\sinh y}}} \]
                  5. Taylor expanded in x around 0

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

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

                      \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \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)}\right)\right) \]
                    3. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\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)\right)\right) \]
                      2. +-lowering-+.f64N/A

                        \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \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)\right)\right)\right) \]
                      3. *-lowering-*.f64N/A

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

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

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

                        \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \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}{\left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right)\right) \]
                      8. unpow2N/A

                        \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\left(y \cdot y\right), \left(\color{blue}{\frac{1}{120}} + \frac{1}{5040} \cdot {y}^{2}\right)\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(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(\color{blue}{\frac{1}{120}} + \frac{1}{5040} \cdot {y}^{2}\right)\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(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{120}, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right)\right)\right) \]
                      11. *-commutativeN/A

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

                        \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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)\right) \]
                      13. unpow2N/A

                        \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                      14. *-lowering-*.f6478.0%

                        \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                    4. Simplified78.0%

                      \[\leadsto \frac{1}{\frac{y}{\color{blue}{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)}}} \]
                  7. Recombined 2 regimes into one program.
                  8. Final simplification50.0%

                    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 2.8 \cdot 10^{+39}:\\ \;\;\;\;1 + \frac{\left(y \cdot y\right) \cdot \left(0.004629629629629629 + \left(\left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right) \cdot \left(\left(\left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right) \cdot \left(\left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)\right)}{0.027777777777777776 + \left(\left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right) \cdot \left(\left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right) - 0.16666666666666666\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{\frac{y}{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)}}\\ \end{array} \]
                  9. Add Preprocessing

                  Alternative 8: 60.4% accurate, 8.2× speedup?

                  \[\begin{array}{l} \\ \frac{1}{\frac{y}{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)}} \end{array} \]
                  (FPCore (x y)
                   :precision binary64
                   (/
                    1.0
                    (/
                     y
                     (*
                      y
                      (+
                       1.0
                       (*
                        (* y y)
                        (+
                         0.16666666666666666
                         (*
                          (* y y)
                          (+ 0.008333333333333333 (* (* y y) 0.0001984126984126984))))))))))
                  double code(double x, double y) {
                  	return 1.0 / (y / (y * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * (0.008333333333333333 + ((y * y) * 0.0001984126984126984))))))));
                  }
                  
                  real(8) function code(x, y)
                      real(8), intent (in) :: x
                      real(8), intent (in) :: y
                      code = 1.0d0 / (y / (y * (1.0d0 + ((y * y) * (0.16666666666666666d0 + ((y * y) * (0.008333333333333333d0 + ((y * y) * 0.0001984126984126984d0))))))))
                  end function
                  
                  public static double code(double x, double y) {
                  	return 1.0 / (y / (y * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * (0.008333333333333333 + ((y * y) * 0.0001984126984126984))))))));
                  }
                  
                  def code(x, y):
                  	return 1.0 / (y / (y * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * (0.008333333333333333 + ((y * y) * 0.0001984126984126984))))))))
                  
                  function code(x, y)
                  	return Float64(1.0 / Float64(y / Float64(y * Float64(1.0 + Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(Float64(y * y) * Float64(0.008333333333333333 + Float64(Float64(y * y) * 0.0001984126984126984)))))))))
                  end
                  
                  function tmp = code(x, y)
                  	tmp = 1.0 / (y / (y * (1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * (0.008333333333333333 + ((y * y) * 0.0001984126984126984))))))));
                  end
                  
                  code[x_, y_] := N[(1.0 / N[(y / N[(y * N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * N[(0.008333333333333333 + N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
                  
                  \begin{array}{l}
                  
                  \\
                  \frac{1}{\frac{y}{y \cdot \left(1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)}}
                  \end{array}
                  
                  Derivation
                  1. Initial program 100.0%

                    \[\cos x \cdot \frac{\sinh y}{y} \]
                  2. Add Preprocessing
                  3. Step-by-step derivation
                    1. clear-numN/A

                      \[\leadsto \cos x \cdot \frac{1}{\color{blue}{\frac{y}{\sinh y}}} \]
                    2. un-div-invN/A

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

                      \[\leadsto \mathsf{/.f64}\left(\cos x, \color{blue}{\left(\frac{y}{\sinh y}\right)}\right) \]
                    4. cos-lowering-cos.f64N/A

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \left(\frac{\color{blue}{y}}{\sinh y}\right)\right) \]
                    5. /-lowering-/.f64N/A

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

                      \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{/.f64}\left(y, \mathsf{sinh.f64}\left(y\right)\right)\right) \]
                  4. Applied egg-rr100.0%

                    \[\leadsto \color{blue}{\frac{\cos x}{\frac{y}{\sinh y}}} \]
                  5. Taylor expanded in x around 0

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

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

                      \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \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)}\right)\right) \]
                    3. Step-by-step derivation
                      1. *-lowering-*.f64N/A

                        \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\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)\right)\right) \]
                      2. +-lowering-+.f64N/A

                        \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \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)\right)\right)\right) \]
                      3. *-lowering-*.f64N/A

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

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

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

                        \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \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}{\left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right)\right) \]
                      8. unpow2N/A

                        \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\left(y \cdot y\right), \left(\color{blue}{\frac{1}{120}} + \frac{1}{5040} \cdot {y}^{2}\right)\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(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \left(\color{blue}{\frac{1}{120}} + \frac{1}{5040} \cdot {y}^{2}\right)\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(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{120}, \color{blue}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right)\right)\right)\right)\right) \]
                      11. *-commutativeN/A

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

                        \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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)\right) \]
                      13. unpow2N/A

                        \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                      14. *-lowering-*.f6466.5%

                        \[\leadsto \mathsf{/.f64}\left(1, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \mathsf{+.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                    4. Simplified66.5%

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

                    Alternative 9: 49.1% accurate, 8.9× speedup?

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

                      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. associate-*r*N/A

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

                          \[\leadsto 1 \cdot \cos x + \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)} \cdot \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. *-lowering-*.f64N/A

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

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

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

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

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

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

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

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

                          \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(1, \mathsf{cos.f64}\left(x\right)\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, y\right)\right)\right)\right) \]
                      7. Applied egg-rr87.6%

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

                        \[\leadsto \color{blue}{1 + \frac{1}{6} \cdot {y}^{2}} \]
                      9. Step-by-step derivation
                        1. +-lowering-+.f64N/A

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

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

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

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

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

                      if 8.0000000000000001e27 < y < 1.65e154

                      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. associate-*r*N/A

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

                          \[\leadsto 1 \cdot \cos x + \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)} \cdot \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. *-lowering-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(\frac{1}{24}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{144}\right)\right), \left({x}^{4}\right)\right) \]
                        14. metadata-evalN/A

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

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

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

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

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

                          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(\frac{1}{24}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{144}\right)\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \left(x \cdot \color{blue}{x}\right)\right)\right) \]
                        20. *-lowering-*.f6434.6%

                          \[\leadsto \mathsf{*.f64}\left(\mathsf{+.f64}\left(\frac{1}{24}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{144}\right)\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \mathsf{*.f64}\left(x, \color{blue}{x}\right)\right)\right) \]
                      11. Simplified34.6%

                        \[\leadsto \color{blue}{\left(0.041666666666666664 + \left(y \cdot y\right) \cdot 0.006944444444444444\right) \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)} \]
                      12. Taylor expanded in y around inf

                        \[\leadsto \mathsf{*.f64}\left(\color{blue}{\left(\frac{1}{144} \cdot {y}^{2}\right)}, \mathsf{*.f64}\left(\mathsf{*.f64}\left(x, x\right), \mathsf{*.f64}\left(x, x\right)\right)\right) \]
                      13. Step-by-step derivation
                        1. *-commutativeN/A

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

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

                          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\left(y \cdot y\right), \frac{1}{144}\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(\color{blue}{x}, x\right), \mathsf{*.f64}\left(x, x\right)\right)\right) \]
                        4. *-lowering-*.f6434.6%

                          \[\leadsto \mathsf{*.f64}\left(\mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \frac{1}{144}\right), \mathsf{*.f64}\left(\mathsf{*.f64}\left(\color{blue}{x}, x\right), \mathsf{*.f64}\left(x, x\right)\right)\right) \]
                      14. Simplified34.6%

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

                      if 1.65e154 < 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. associate-*r*N/A

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

                          \[\leadsto 1 \cdot \cos x + \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)} \cdot \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. *-lowering-*.f64N/A

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

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

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

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

                        \[\leadsto \color{blue}{1 + \frac{1}{6} \cdot {y}^{2}} \]
                      7. Step-by-step derivation
                        1. +-lowering-+.f64N/A

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

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

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

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

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

                          \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                      8. Simplified76.7%

                        \[\leadsto \color{blue}{1 + y \cdot \left(y \cdot 0.16666666666666666\right)} \]
                    3. Recombined 3 regimes into one program.
                    4. Final simplification58.3%

                      \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 8 \cdot 10^{+27}:\\ \;\;\;\;1 + \left(y \cdot y\right) \cdot 0.16666666666666666\\ \mathbf{elif}\;y \leq 1.65 \cdot 10^{+154}:\\ \;\;\;\;\left(\left(y \cdot y\right) \cdot 0.006944444444444444\right) \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\\ \mathbf{else}:\\ \;\;\;\;1 + y \cdot \left(y \cdot 0.16666666666666666\right)\\ \end{array} \]
                    5. Add Preprocessing

                    Alternative 10: 59.6% accurate, 10.8× speedup?

                    \[\begin{array}{l} \\ 1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right) \end{array} \]
                    (FPCore (x y)
                     :precision binary64
                     (+
                      1.0
                      (*
                       (* y y)
                       (+
                        0.16666666666666666
                        (* (* y y) (+ 0.008333333333333333 (* (* y y) 0.0001984126984126984)))))))
                    double code(double x, double y) {
                    	return 1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * (0.008333333333333333 + ((y * y) * 0.0001984126984126984)))));
                    }
                    
                    real(8) function code(x, y)
                        real(8), intent (in) :: x
                        real(8), intent (in) :: y
                        code = 1.0d0 + ((y * y) * (0.16666666666666666d0 + ((y * y) * (0.008333333333333333d0 + ((y * y) * 0.0001984126984126984d0)))))
                    end function
                    
                    public static double code(double x, double y) {
                    	return 1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * (0.008333333333333333 + ((y * y) * 0.0001984126984126984)))));
                    }
                    
                    def code(x, y):
                    	return 1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * (0.008333333333333333 + ((y * y) * 0.0001984126984126984)))))
                    
                    function code(x, y)
                    	return Float64(1.0 + Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(Float64(y * y) * Float64(0.008333333333333333 + Float64(Float64(y * y) * 0.0001984126984126984))))))
                    end
                    
                    function tmp = code(x, y)
                    	tmp = 1.0 + ((y * y) * (0.16666666666666666 + ((y * y) * (0.008333333333333333 + ((y * y) * 0.0001984126984126984)))));
                    end
                    
                    code[x_, y_] := N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * N[(0.008333333333333333 + N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
                    
                    \begin{array}{l}
                    
                    \\
                    1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)
                    \end{array}
                    
                    Derivation
                    1. Initial program 100.0%

                      \[\cos x \cdot \frac{\sinh y}{y} \]
                    2. Add Preprocessing
                    3. Step-by-step derivation
                      1. clear-numN/A

                        \[\leadsto \cos x \cdot \frac{1}{\color{blue}{\frac{y}{\sinh y}}} \]
                      2. un-div-invN/A

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

                        \[\leadsto \mathsf{/.f64}\left(\cos x, \color{blue}{\left(\frac{y}{\sinh y}\right)}\right) \]
                      4. cos-lowering-cos.f64N/A

                        \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \left(\frac{\color{blue}{y}}{\sinh y}\right)\right) \]
                      5. /-lowering-/.f64N/A

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

                        \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{/.f64}\left(y, \mathsf{sinh.f64}\left(y\right)\right)\right) \]
                    4. Applied egg-rr100.0%

                      \[\leadsto \color{blue}{\frac{\cos x}{\frac{y}{\sinh y}}} \]
                    5. Taylor expanded in x around 0

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

                        \[\leadsto \frac{\color{blue}{1}}{\frac{y}{\sinh y}} \]
                      2. Taylor expanded in y 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)} \]
                      3. 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. *-lowering-*.f64N/A

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

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

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

                          \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                        6. *-lowering-*.f64N/A

                          \[\leadsto \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}{\left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right) \]
                        7. unpow2N/A

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

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

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

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

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

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

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

                        \[\leadsto \color{blue}{1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot \left(0.008333333333333333 + \left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)} \]
                      5. Add Preprocessing

                      Alternative 11: 59.5% accurate, 12.1× speedup?

                      \[\begin{array}{l} \\ 1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right) \end{array} \]
                      (FPCore (x y)
                       :precision binary64
                       (+
                        1.0
                        (*
                         (* y y)
                         (+ 0.16666666666666666 (* y (* y (* (* y y) 0.0001984126984126984)))))))
                      double code(double x, double y) {
                      	return 1.0 + ((y * y) * (0.16666666666666666 + (y * (y * ((y * y) * 0.0001984126984126984)))));
                      }
                      
                      real(8) function code(x, y)
                          real(8), intent (in) :: x
                          real(8), intent (in) :: y
                          code = 1.0d0 + ((y * y) * (0.16666666666666666d0 + (y * (y * ((y * y) * 0.0001984126984126984d0)))))
                      end function
                      
                      public static double code(double x, double y) {
                      	return 1.0 + ((y * y) * (0.16666666666666666 + (y * (y * ((y * y) * 0.0001984126984126984)))));
                      }
                      
                      def code(x, y):
                      	return 1.0 + ((y * y) * (0.16666666666666666 + (y * (y * ((y * y) * 0.0001984126984126984)))))
                      
                      function code(x, y)
                      	return Float64(1.0 + Float64(Float64(y * y) * Float64(0.16666666666666666 + Float64(y * Float64(y * Float64(Float64(y * y) * 0.0001984126984126984))))))
                      end
                      
                      function tmp = code(x, y)
                      	tmp = 1.0 + ((y * y) * (0.16666666666666666 + (y * (y * ((y * y) * 0.0001984126984126984)))));
                      end
                      
                      code[x_, y_] := N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(0.16666666666666666 + N[(y * N[(y * N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
                      
                      \begin{array}{l}
                      
                      \\
                      1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)
                      \end{array}
                      
                      Derivation
                      1. Initial program 100.0%

                        \[\cos x \cdot \frac{\sinh y}{y} \]
                      2. Add Preprocessing
                      3. Step-by-step derivation
                        1. clear-numN/A

                          \[\leadsto \cos x \cdot \frac{1}{\color{blue}{\frac{y}{\sinh y}}} \]
                        2. un-div-invN/A

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

                          \[\leadsto \mathsf{/.f64}\left(\cos x, \color{blue}{\left(\frac{y}{\sinh y}\right)}\right) \]
                        4. cos-lowering-cos.f64N/A

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \left(\frac{\color{blue}{y}}{\sinh y}\right)\right) \]
                        5. /-lowering-/.f64N/A

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

                          \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{/.f64}\left(y, \mathsf{sinh.f64}\left(y\right)\right)\right) \]
                      4. Applied egg-rr100.0%

                        \[\leadsto \color{blue}{\frac{\cos x}{\frac{y}{\sinh y}}} \]
                      5. Taylor expanded in x around 0

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

                          \[\leadsto \frac{\color{blue}{1}}{\frac{y}{\sinh y}} \]
                        2. Taylor expanded in y 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)} \]
                        3. 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. *-lowering-*.f64N/A

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

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

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

                            \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                          6. *-lowering-*.f64N/A

                            \[\leadsto \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}{\left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right) \]
                          7. unpow2N/A

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

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

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

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

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

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

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

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

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

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

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

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

                            \[\leadsto \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}{\left(\frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right) \]
                          5. unpow2N/A

                            \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                          6. associate-*l*N/A

                            \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                          7. *-lowering-*.f64N/A

                            \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                          8. *-lowering-*.f64N/A

                            \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                          9. *-commutativeN/A

                            \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                          10. *-lowering-*.f64N/A

                            \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                          11. unpow2N/A

                            \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                          12. *-lowering-*.f6466.1%

                            \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                        7. Simplified66.1%

                          \[\leadsto 1 + \left(y \cdot y\right) \cdot \left(0.16666666666666666 + \color{blue}{y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)}\right) \]
                        8. Add Preprocessing

                        Alternative 12: 59.4% accurate, 13.7× speedup?

                        \[\begin{array}{l} \\ 1 + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right) \end{array} \]
                        (FPCore (x y)
                         :precision binary64
                         (+ 1.0 (* (* y y) (* y (* y (* (* y y) 0.0001984126984126984))))))
                        double code(double x, double y) {
                        	return 1.0 + ((y * y) * (y * (y * ((y * y) * 0.0001984126984126984))));
                        }
                        
                        real(8) function code(x, y)
                            real(8), intent (in) :: x
                            real(8), intent (in) :: y
                            code = 1.0d0 + ((y * y) * (y * (y * ((y * y) * 0.0001984126984126984d0))))
                        end function
                        
                        public static double code(double x, double y) {
                        	return 1.0 + ((y * y) * (y * (y * ((y * y) * 0.0001984126984126984))));
                        }
                        
                        def code(x, y):
                        	return 1.0 + ((y * y) * (y * (y * ((y * y) * 0.0001984126984126984))))
                        
                        function code(x, y)
                        	return Float64(1.0 + Float64(Float64(y * y) * Float64(y * Float64(y * Float64(Float64(y * y) * 0.0001984126984126984)))))
                        end
                        
                        function tmp = code(x, y)
                        	tmp = 1.0 + ((y * y) * (y * (y * ((y * y) * 0.0001984126984126984))));
                        end
                        
                        code[x_, y_] := N[(1.0 + N[(N[(y * y), $MachinePrecision] * N[(y * N[(y * N[(N[(y * y), $MachinePrecision] * 0.0001984126984126984), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
                        
                        \begin{array}{l}
                        
                        \\
                        1 + \left(y \cdot y\right) \cdot \left(y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)
                        \end{array}
                        
                        Derivation
                        1. Initial program 100.0%

                          \[\cos x \cdot \frac{\sinh y}{y} \]
                        2. Add Preprocessing
                        3. Step-by-step derivation
                          1. clear-numN/A

                            \[\leadsto \cos x \cdot \frac{1}{\color{blue}{\frac{y}{\sinh y}}} \]
                          2. un-div-invN/A

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

                            \[\leadsto \mathsf{/.f64}\left(\cos x, \color{blue}{\left(\frac{y}{\sinh y}\right)}\right) \]
                          4. cos-lowering-cos.f64N/A

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \left(\frac{\color{blue}{y}}{\sinh y}\right)\right) \]
                          5. /-lowering-/.f64N/A

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

                            \[\leadsto \mathsf{/.f64}\left(\mathsf{cos.f64}\left(x\right), \mathsf{/.f64}\left(y, \mathsf{sinh.f64}\left(y\right)\right)\right) \]
                        4. Applied egg-rr100.0%

                          \[\leadsto \color{blue}{\frac{\cos x}{\frac{y}{\sinh y}}} \]
                        5. Taylor expanded in x around 0

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

                            \[\leadsto \frac{\color{blue}{1}}{\frac{y}{\sinh y}} \]
                          2. Taylor expanded in y 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)} \]
                          3. 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. *-lowering-*.f64N/A

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

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

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

                              \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                            6. *-lowering-*.f64N/A

                              \[\leadsto \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}{\left(\frac{1}{120} + \frac{1}{5040} \cdot {y}^{2}\right)}\right)\right)\right)\right) \]
                            7. unpow2N/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                              \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                            11. unpow2N/A

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

                              \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\mathsf{*.f64}\left(y, y\right), \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) \]
                          7. Simplified66.0%

                            \[\leadsto 1 + \left(y \cdot y\right) \cdot \color{blue}{\left(y \cdot \left(y \cdot \left(\left(y \cdot y\right) \cdot 0.0001984126984126984\right)\right)\right)} \]
                          8. Add Preprocessing

                          Alternative 13: 48.1% accurate, 14.6× speedup?

                          \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x \leq 4.5 \cdot 10^{+130}:\\ \;\;\;\;1 + \left(y \cdot y\right) \cdot 0.16666666666666666\\ \mathbf{else}:\\ \;\;\;\;\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot 0.041666666666666664\\ \end{array} \end{array} \]
                          (FPCore (x y)
                           :precision binary64
                           (if (<= x 4.5e+130)
                             (+ 1.0 (* (* y y) 0.16666666666666666))
                             (* (* (* x x) (* x x)) 0.041666666666666664)))
                          double code(double x, double y) {
                          	double tmp;
                          	if (x <= 4.5e+130) {
                          		tmp = 1.0 + ((y * y) * 0.16666666666666666);
                          	} else {
                          		tmp = ((x * x) * (x * x)) * 0.041666666666666664;
                          	}
                          	return tmp;
                          }
                          
                          real(8) function code(x, y)
                              real(8), intent (in) :: x
                              real(8), intent (in) :: y
                              real(8) :: tmp
                              if (x <= 4.5d+130) then
                                  tmp = 1.0d0 + ((y * y) * 0.16666666666666666d0)
                              else
                                  tmp = ((x * x) * (x * x)) * 0.041666666666666664d0
                              end if
                              code = tmp
                          end function
                          
                          public static double code(double x, double y) {
                          	double tmp;
                          	if (x <= 4.5e+130) {
                          		tmp = 1.0 + ((y * y) * 0.16666666666666666);
                          	} else {
                          		tmp = ((x * x) * (x * x)) * 0.041666666666666664;
                          	}
                          	return tmp;
                          }
                          
                          def code(x, y):
                          	tmp = 0
                          	if x <= 4.5e+130:
                          		tmp = 1.0 + ((y * y) * 0.16666666666666666)
                          	else:
                          		tmp = ((x * x) * (x * x)) * 0.041666666666666664
                          	return tmp
                          
                          function code(x, y)
                          	tmp = 0.0
                          	if (x <= 4.5e+130)
                          		tmp = Float64(1.0 + Float64(Float64(y * y) * 0.16666666666666666));
                          	else
                          		tmp = Float64(Float64(Float64(x * x) * Float64(x * x)) * 0.041666666666666664);
                          	end
                          	return tmp
                          end
                          
                          function tmp_2 = code(x, y)
                          	tmp = 0.0;
                          	if (x <= 4.5e+130)
                          		tmp = 1.0 + ((y * y) * 0.16666666666666666);
                          	else
                          		tmp = ((x * x) * (x * x)) * 0.041666666666666664;
                          	end
                          	tmp_2 = tmp;
                          end
                          
                          code[x_, y_] := If[LessEqual[x, 4.5e+130], N[(1.0 + N[(N[(y * y), $MachinePrecision] * 0.16666666666666666), $MachinePrecision]), $MachinePrecision], N[(N[(N[(x * x), $MachinePrecision] * N[(x * x), $MachinePrecision]), $MachinePrecision] * 0.041666666666666664), $MachinePrecision]]
                          
                          \begin{array}{l}
                          
                          \\
                          \begin{array}{l}
                          \mathbf{if}\;x \leq 4.5 \cdot 10^{+130}:\\
                          \;\;\;\;1 + \left(y \cdot y\right) \cdot 0.16666666666666666\\
                          
                          \mathbf{else}:\\
                          \;\;\;\;\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot 0.041666666666666664\\
                          
                          
                          \end{array}
                          \end{array}
                          
                          Derivation
                          1. Split input into 2 regimes
                          2. if x < 4.50000000000000039e130

                            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. associate-*r*N/A

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

                                \[\leadsto 1 \cdot \cos x + \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)} \cdot \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. *-lowering-*.f64N/A

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

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

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

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

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

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

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

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

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

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

                              \[\leadsto \color{blue}{1 + \frac{1}{6} \cdot {y}^{2}} \]
                            9. Step-by-step derivation
                              1. +-lowering-+.f64N/A

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

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

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

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

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

                            if 4.50000000000000039e130 < 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.f6458.1%

                                \[\leadsto \mathsf{cos.f64}\left(x\right) \]
                            5. Simplified58.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. *-lowering-*.f64N/A

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

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

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

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

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

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

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

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

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

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

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

                              \[\leadsto \color{blue}{1 + \left(x \cdot x\right) \cdot \left(-0.5 + \left(x \cdot x\right) \cdot 0.041666666666666664\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-*.f6428.3%

                                \[\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. Simplified28.3%

                              \[\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. Final simplification57.1%

                            \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq 4.5 \cdot 10^{+130}:\\ \;\;\;\;1 + \left(y \cdot y\right) \cdot 0.16666666666666666\\ \mathbf{else}:\\ \;\;\;\;\left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right) \cdot 0.041666666666666664\\ \end{array} \]
                          5. Add Preprocessing

                          Alternative 14: 56.5% accurate, 15.8× speedup?

                          \[\begin{array}{l} \\ 1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right) \end{array} \]
                          (FPCore (x y)
                           :precision binary64
                           (+ 1.0 (* y (* y (+ 0.16666666666666666 (* (* y y) 0.008333333333333333))))))
                          double code(double x, double y) {
                          	return 1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333))));
                          }
                          
                          real(8) function code(x, y)
                              real(8), intent (in) :: x
                              real(8), intent (in) :: y
                              code = 1.0d0 + (y * (y * (0.16666666666666666d0 + ((y * y) * 0.008333333333333333d0))))
                          end function
                          
                          public static double code(double x, double y) {
                          	return 1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333))));
                          }
                          
                          def code(x, y):
                          	return 1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333))))
                          
                          function code(x, y)
                          	return Float64(1.0 + Float64(y * Float64(y * Float64(0.16666666666666666 + Float64(Float64(y * y) * 0.008333333333333333)))))
                          end
                          
                          function tmp = code(x, y)
                          	tmp = 1.0 + (y * (y * (0.16666666666666666 + ((y * y) * 0.008333333333333333))));
                          end
                          
                          code[x_, y_] := N[(1.0 + N[(y * N[(y * N[(0.16666666666666666 + N[(N[(y * y), $MachinePrecision] * 0.008333333333333333), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
                          
                          \begin{array}{l}
                          
                          \\
                          1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\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}{120} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{6} \cdot \cos x\right)} \]
                          4. Step-by-step derivation
                            1. distribute-rgt-inN/A

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

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

                              \[\leadsto \cos x \cdot 1 + {y}^{2} \cdot \color{blue}{\left(\frac{1}{120} \cdot \left({y}^{2} \cdot \cos x\right) + \frac{1}{6} \cdot \cos x\right)} \]
                            4. *-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}} \]
                            5. 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} \]
                            6. 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} \]
                            7. +-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} \]
                            8. 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)} \]
                            9. *-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) \]
                            10. 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)} \]
                            11. *-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) \]
                            12. 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) \]
                            13. +-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) \]
                          5. Simplified92.2%

                            \[\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)} \]
                          6. Taylor expanded in x around 0

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

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

                              \[\leadsto \mathsf{+.f64}\left(1, \left(\left(y \cdot y\right) \cdot \left(\color{blue}{\frac{1}{6}} + \frac{1}{120} \cdot {y}^{2}\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} + \frac{1}{120} \cdot {y}^{2}\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} + \frac{1}{120} \cdot {y}^{2}\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} + \frac{1}{120} \cdot {y}^{2}\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(\frac{1}{120} \cdot {y}^{2}\right)}\right)\right)\right)\right) \]
                            7. *-commutativeN/A

                              \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \mathsf{+.f64}\left(\frac{1}{6}, \left({y}^{2} \cdot \color{blue}{\frac{1}{120}}\right)\right)\right)\right)\right) \]
                            8. *-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(\left({y}^{2}\right), \color{blue}{\frac{1}{120}}\right)\right)\right)\right)\right) \]
                            9. unpow2N/A

                              \[\leadsto \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), \frac{1}{120}\right)\right)\right)\right)\right) \]
                            10. *-lowering-*.f6463.6%

                              \[\leadsto \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), \frac{1}{120}\right)\right)\right)\right)\right) \]
                          8. Simplified63.6%

                            \[\leadsto \color{blue}{1 + y \cdot \left(y \cdot \left(0.16666666666666666 + \left(y \cdot y\right) \cdot 0.008333333333333333\right)\right)} \]
                          9. Add Preprocessing

                          Alternative 15: 37.5% accurate, 20.5× speedup?

                          \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq 0.007:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;\left(y \cdot y\right) \cdot 0.16666666666666666\\ \end{array} \end{array} \]
                          (FPCore (x y)
                           :precision binary64
                           (if (<= y 0.007) 1.0 (* (* y y) 0.16666666666666666)))
                          double code(double x, double y) {
                          	double tmp;
                          	if (y <= 0.007) {
                          		tmp = 1.0;
                          	} else {
                          		tmp = (y * y) * 0.16666666666666666;
                          	}
                          	return tmp;
                          }
                          
                          real(8) function code(x, y)
                              real(8), intent (in) :: x
                              real(8), intent (in) :: y
                              real(8) :: tmp
                              if (y <= 0.007d0) then
                                  tmp = 1.0d0
                              else
                                  tmp = (y * y) * 0.16666666666666666d0
                              end if
                              code = tmp
                          end function
                          
                          public static double code(double x, double y) {
                          	double tmp;
                          	if (y <= 0.007) {
                          		tmp = 1.0;
                          	} else {
                          		tmp = (y * y) * 0.16666666666666666;
                          	}
                          	return tmp;
                          }
                          
                          def code(x, y):
                          	tmp = 0
                          	if y <= 0.007:
                          		tmp = 1.0
                          	else:
                          		tmp = (y * y) * 0.16666666666666666
                          	return tmp
                          
                          function code(x, y)
                          	tmp = 0.0
                          	if (y <= 0.007)
                          		tmp = 1.0;
                          	else
                          		tmp = Float64(Float64(y * y) * 0.16666666666666666);
                          	end
                          	return tmp
                          end
                          
                          function tmp_2 = code(x, y)
                          	tmp = 0.0;
                          	if (y <= 0.007)
                          		tmp = 1.0;
                          	else
                          		tmp = (y * y) * 0.16666666666666666;
                          	end
                          	tmp_2 = tmp;
                          end
                          
                          code[x_, y_] := If[LessEqual[y, 0.007], 1.0, N[(N[(y * y), $MachinePrecision] * 0.16666666666666666), $MachinePrecision]]
                          
                          \begin{array}{l}
                          
                          \\
                          \begin{array}{l}
                          \mathbf{if}\;y \leq 0.007:\\
                          \;\;\;\;1\\
                          
                          \mathbf{else}:\\
                          \;\;\;\;\left(y \cdot y\right) \cdot 0.16666666666666666\\
                          
                          
                          \end{array}
                          \end{array}
                          
                          Derivation
                          1. Split input into 2 regimes
                          2. if y < 0.00700000000000000015

                            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.f6469.7%

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

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

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

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

                              if 0.00700000000000000015 < 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. associate-*r*N/A

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

                                  \[\leadsto 1 \cdot \cos x + \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)} \cdot \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. *-lowering-*.f64N/A

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

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

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

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

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

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

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

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

                                  \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(1, \mathsf{cos.f64}\left(x\right)\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, y\right)\right)\right)\right) \]
                              7. Applied egg-rr57.1%

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

                                \[\leadsto \color{blue}{1 + \frac{1}{6} \cdot {y}^{2}} \]
                              9. Step-by-step derivation
                                1. +-lowering-+.f64N/A

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

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

                                  \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\frac{1}{6}, \left(y \cdot \color{blue}{y}\right)\right)\right) \]
                                4. *-lowering-*.f6443.9%

                                  \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \color{blue}{y}\right)\right)\right) \]
                              10. Simplified43.9%

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

                                \[\leadsto \color{blue}{\frac{1}{6} \cdot {y}^{2}} \]
                              12. Step-by-step derivation
                                1. *-lowering-*.f64N/A

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

                                  \[\leadsto \mathsf{*.f64}\left(\frac{1}{6}, \left(y \cdot \color{blue}{y}\right)\right) \]
                                3. *-lowering-*.f6443.9%

                                  \[\leadsto \mathsf{*.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \color{blue}{y}\right)\right) \]
                              13. Simplified43.9%

                                \[\leadsto \color{blue}{0.16666666666666666 \cdot \left(y \cdot y\right)} \]
                            8. Recombined 2 regimes into one program.
                            9. Final simplification42.7%

                              \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq 0.007:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;\left(y \cdot y\right) \cdot 0.16666666666666666\\ \end{array} \]
                            10. Add Preprocessing

                            Alternative 16: 47.1% 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 + \frac{1}{6} \cdot \left({y}^{2} \cdot \cos x\right)} \]
                            4. Step-by-step derivation
                              1. associate-*r*N/A

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

                                \[\leadsto 1 \cdot \cos x + \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)} \cdot \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. *-lowering-*.f64N/A

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

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

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

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

                              \[\leadsto \color{blue}{1 + \frac{1}{6} \cdot {y}^{2}} \]
                            7. Step-by-step derivation
                              1. +-lowering-+.f64N/A

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

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

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

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

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

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(y, \mathsf{*.f64}\left(y, \color{blue}{\frac{1}{6}}\right)\right)\right) \]
                            8. Simplified55.8%

                              \[\leadsto \color{blue}{1 + y \cdot \left(y \cdot 0.16666666666666666\right)} \]
                            9. Add Preprocessing

                            Alternative 17: 47.1% accurate, 29.3× speedup?

                            \[\begin{array}{l} \\ 1 + \left(y \cdot y\right) \cdot 0.16666666666666666 \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(Float64(y * y) * 0.16666666666666666))
                            end
                            
                            function tmp = code(x, y)
                            	tmp = 1.0 + ((y * y) * 0.16666666666666666);
                            end
                            
                            code[x_, y_] := N[(1.0 + N[(N[(y * y), $MachinePrecision] * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]
                            
                            \begin{array}{l}
                            
                            \\
                            1 + \left(y \cdot y\right) \cdot 0.16666666666666666
                            \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 + \frac{1}{6} \cdot \left({y}^{2} \cdot \cos x\right)} \]
                            4. Step-by-step derivation
                              1. associate-*r*N/A

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

                                \[\leadsto 1 \cdot \cos x + \color{blue}{\left(\frac{1}{6} \cdot {y}^{2}\right)} \cdot \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. *-lowering-*.f64N/A

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

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

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

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

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

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

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

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

                                \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(1, \mathsf{cos.f64}\left(x\right)\right)\right), \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, y\right)\right)\right)\right) \]
                            7. Applied egg-rr82.4%

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

                              \[\leadsto \color{blue}{1 + \frac{1}{6} \cdot {y}^{2}} \]
                            9. Step-by-step derivation
                              1. +-lowering-+.f64N/A

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

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

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\frac{1}{6}, \left(y \cdot \color{blue}{y}\right)\right)\right) \]
                              4. *-lowering-*.f6455.8%

                                \[\leadsto \mathsf{+.f64}\left(1, \mathsf{*.f64}\left(\frac{1}{6}, \mathsf{*.f64}\left(y, \color{blue}{y}\right)\right)\right) \]
                            10. Simplified55.8%

                              \[\leadsto \color{blue}{1 + 0.16666666666666666 \cdot \left(y \cdot y\right)} \]
                            11. Final simplification55.8%

                              \[\leadsto 1 + \left(y \cdot y\right) \cdot 0.16666666666666666 \]
                            12. Add Preprocessing

                            Alternative 18: 28.2% 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. Simplified33.8%

                                \[\leadsto \color{blue}{1} \]
                              2. Add Preprocessing

                              Reproduce

                              ?
                              herbie shell --seed 2024161 
                              (FPCore (x y)
                                :name "Linear.Quaternion:$csin from linear-1.19.1.3"
                                :precision binary64
                                (* (cos x) (/ (sinh y) y)))