Numeric.SpecFunctions:logGamma from math-functions-0.1.5.2

Percentage Accurate: 55.8% → 84.7%
Time: 22.4s
Alternatives: 16
Speedup: 2.5×

Specification

?
\[\begin{array}{l} \\ \frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (/
  (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t)
  (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	return ((((((((x * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / (((((((y + a) * y) + b) * y) + c) * y) + i);
}
real(8) function code(x, y, z, t, a, b, c, i)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    code = ((((((((x * y) + z) * y) + 27464.7644705d0) * y) + 230661.510616d0) * y) + t) / (((((((y + a) * y) + b) * y) + c) * y) + i)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	return ((((((((x * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / (((((((y + a) * y) + b) * y) + c) * y) + i);
}
def code(x, y, z, t, a, b, c, i):
	return ((((((((x * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / (((((((y + a) * y) + b) * y) + c) * y) + i)
function code(x, y, z, t, a, b, c, i)
	return Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / Float64(Float64(Float64(Float64(Float64(Float64(Float64(y + a) * y) + b) * y) + c) * y) + i))
end
function tmp = code(x, y, z, t, a, b, c, i)
	tmp = ((((((((x * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / (((((((y + a) * y) + b) * y) + c) * y) + i);
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(N[(N[(N[(N[(N[(N[(N[(N[(x * y), $MachinePrecision] + z), $MachinePrecision] * y), $MachinePrecision] + 27464.7644705), $MachinePrecision] * y), $MachinePrecision] + 230661.510616), $MachinePrecision] * y), $MachinePrecision] + t), $MachinePrecision] / N[(N[(N[(N[(N[(N[(N[(y + a), $MachinePrecision] * y), $MachinePrecision] + b), $MachinePrecision] * y), $MachinePrecision] + c), $MachinePrecision] * y), $MachinePrecision] + i), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i}
\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 16 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: 55.8% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (/
  (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t)
  (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	return ((((((((x * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / (((((((y + a) * y) + b) * y) + c) * y) + i);
}
real(8) function code(x, y, z, t, a, b, c, i)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    code = ((((((((x * y) + z) * y) + 27464.7644705d0) * y) + 230661.510616d0) * y) + t) / (((((((y + a) * y) + b) * y) + c) * y) + i)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	return ((((((((x * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / (((((((y + a) * y) + b) * y) + c) * y) + i);
}
def code(x, y, z, t, a, b, c, i):
	return ((((((((x * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / (((((((y + a) * y) + b) * y) + c) * y) + i)
function code(x, y, z, t, a, b, c, i)
	return Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / Float64(Float64(Float64(Float64(Float64(Float64(Float64(y + a) * y) + b) * y) + c) * y) + i))
end
function tmp = code(x, y, z, t, a, b, c, i)
	tmp = ((((((((x * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / (((((((y + a) * y) + b) * y) + c) * y) + i);
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(N[(N[(N[(N[(N[(N[(N[(N[(x * y), $MachinePrecision] + z), $MachinePrecision] * y), $MachinePrecision] + 27464.7644705), $MachinePrecision] * y), $MachinePrecision] + 230661.510616), $MachinePrecision] * y), $MachinePrecision] + t), $MachinePrecision] / N[(N[(N[(N[(N[(N[(N[(y + a), $MachinePrecision] * y), $MachinePrecision] + b), $MachinePrecision] * y), $MachinePrecision] + c), $MachinePrecision] * y), $MachinePrecision] + i), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i}
\end{array}

Alternative 1: 84.7% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -7.5 \cdot 10^{+53} \lor \neg \left(y \leq 1.58 \cdot 10^{+65}\right):\\ \;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{y \cdot \left(y \cdot \left(y \cdot \left(z + y \cdot x\right) + 27464.7644705\right) + 230661.510616\right) + t}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (if (or (<= y -7.5e+53) (not (<= y 1.58e+65)))
   (+ (/ z y) (- x (/ a (/ y x))))
   (/
    (+ (* y (+ (* y (+ (* y (+ z (* y x))) 27464.7644705)) 230661.510616)) t)
    (+ (* y (+ (* y (+ (* y (+ y a)) b)) c)) i))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((y <= -7.5e+53) || !(y <= 1.58e+65)) {
		tmp = (z / y) + (x - (a / (y / x)));
	} else {
		tmp = ((y * ((y * ((y * (z + (y * x))) + 27464.7644705)) + 230661.510616)) + t) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8) :: tmp
    if ((y <= (-7.5d+53)) .or. (.not. (y <= 1.58d+65))) then
        tmp = (z / y) + (x - (a / (y / x)))
    else
        tmp = ((y * ((y * ((y * (z + (y * x))) + 27464.7644705d0)) + 230661.510616d0)) + t) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i)
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((y <= -7.5e+53) || !(y <= 1.58e+65)) {
		tmp = (z / y) + (x - (a / (y / x)));
	} else {
		tmp = ((y * ((y * ((y * (z + (y * x))) + 27464.7644705)) + 230661.510616)) + t) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i):
	tmp = 0
	if (y <= -7.5e+53) or not (y <= 1.58e+65):
		tmp = (z / y) + (x - (a / (y / x)))
	else:
		tmp = ((y * ((y * ((y * (z + (y * x))) + 27464.7644705)) + 230661.510616)) + t) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i)
	return tmp
function code(x, y, z, t, a, b, c, i)
	tmp = 0.0
	if ((y <= -7.5e+53) || !(y <= 1.58e+65))
		tmp = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x))));
	else
		tmp = Float64(Float64(Float64(y * Float64(Float64(y * Float64(Float64(y * Float64(z + Float64(y * x))) + 27464.7644705)) + 230661.510616)) + t) / Float64(Float64(y * Float64(Float64(y * Float64(Float64(y * Float64(y + a)) + b)) + c)) + i));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i)
	tmp = 0.0;
	if ((y <= -7.5e+53) || ~((y <= 1.58e+65)))
		tmp = (z / y) + (x - (a / (y / x)));
	else
		tmp = ((y * ((y * ((y * (z + (y * x))) + 27464.7644705)) + 230661.510616)) + t) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -7.5e+53], N[Not[LessEqual[y, 1.58e+65]], $MachinePrecision]], N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(y * N[(N[(y * N[(N[(y * N[(z + N[(y * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + 27464.7644705), $MachinePrecision]), $MachinePrecision] + 230661.510616), $MachinePrecision]), $MachinePrecision] + t), $MachinePrecision] / N[(N[(y * N[(N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]), $MachinePrecision] + i), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -7.5 \cdot 10^{+53} \lor \neg \left(y \leq 1.58 \cdot 10^{+65}\right):\\
\;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\

\mathbf{else}:\\
\;\;\;\;\frac{y \cdot \left(y \cdot \left(y \cdot \left(z + y \cdot x\right) + 27464.7644705\right) + 230661.510616\right) + t}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -7.4999999999999997e53 or 1.5800000000000001e65 < y

    1. Initial program 0.5%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around inf 68.4%

      \[\leadsto \color{blue}{\left(\frac{z}{y} + x\right) - \frac{a \cdot x}{y}} \]
    3. Step-by-step derivation
      1. associate--l+68.4%

        \[\leadsto \color{blue}{\frac{z}{y} + \left(x - \frac{a \cdot x}{y}\right)} \]
      2. associate-/l*75.7%

        \[\leadsto \frac{z}{y} + \left(x - \color{blue}{\frac{a}{\frac{y}{x}}}\right) \]
    4. Simplified75.7%

      \[\leadsto \color{blue}{\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)} \]

    if -7.4999999999999997e53 < y < 1.5800000000000001e65

    1. Initial program 94.6%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification86.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -7.5 \cdot 10^{+53} \lor \neg \left(y \leq 1.58 \cdot 10^{+65}\right):\\ \;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{y \cdot \left(y \cdot \left(y \cdot \left(z + y \cdot x\right) + 27464.7644705\right) + 230661.510616\right) + t}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\ \end{array} \]

Alternative 2: 80.9% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i\\ t_2 := \frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \mathbf{if}\;y \leq -4 \cdot 10^{+53}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;y \leq -6.6 \cdot 10^{-50}:\\ \;\;\;\;\frac{t + y \cdot \left(230661.510616 + y \cdot \left(27464.7644705 + x \cdot \left(y \cdot y\right)\right)\right)}{t_1}\\ \mathbf{elif}\;y \leq 1.05 \cdot 10^{+48}:\\ \;\;\;\;\frac{t + y \cdot \left(230661.510616 + z \cdot \left(y \cdot y\right)\right)}{t_1}\\ \mathbf{elif}\;y \leq 5.6 \cdot 10^{+115}:\\ \;\;\;\;\frac{1}{\frac{1}{x} + \frac{\frac{a}{x} - \frac{z}{x \cdot x}}{y}}\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (let* ((t_1 (+ (* y (+ (* y (+ (* y (+ y a)) b)) c)) i))
        (t_2 (+ (/ z y) (- x (/ a (/ y x))))))
   (if (<= y -4e+53)
     t_2
     (if (<= y -6.6e-50)
       (/
        (+ t (* y (+ 230661.510616 (* y (+ 27464.7644705 (* x (* y y)))))))
        t_1)
       (if (<= y 1.05e+48)
         (/ (+ t (* y (+ 230661.510616 (* z (* y y))))) t_1)
         (if (<= y 5.6e+115)
           (/ 1.0 (+ (/ 1.0 x) (/ (- (/ a x) (/ z (* x x))) y)))
           t_2))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double t_1 = (y * ((y * ((y * (y + a)) + b)) + c)) + i;
	double t_2 = (z / y) + (x - (a / (y / x)));
	double tmp;
	if (y <= -4e+53) {
		tmp = t_2;
	} else if (y <= -6.6e-50) {
		tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (x * (y * y))))))) / t_1;
	} else if (y <= 1.05e+48) {
		tmp = (t + (y * (230661.510616 + (z * (y * y))))) / t_1;
	} else if (y <= 5.6e+115) {
		tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y));
	} else {
		tmp = t_2;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = (y * ((y * ((y * (y + a)) + b)) + c)) + i
    t_2 = (z / y) + (x - (a / (y / x)))
    if (y <= (-4d+53)) then
        tmp = t_2
    else if (y <= (-6.6d-50)) then
        tmp = (t + (y * (230661.510616d0 + (y * (27464.7644705d0 + (x * (y * y))))))) / t_1
    else if (y <= 1.05d+48) then
        tmp = (t + (y * (230661.510616d0 + (z * (y * y))))) / t_1
    else if (y <= 5.6d+115) then
        tmp = 1.0d0 / ((1.0d0 / x) + (((a / x) - (z / (x * x))) / y))
    else
        tmp = t_2
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double t_1 = (y * ((y * ((y * (y + a)) + b)) + c)) + i;
	double t_2 = (z / y) + (x - (a / (y / x)));
	double tmp;
	if (y <= -4e+53) {
		tmp = t_2;
	} else if (y <= -6.6e-50) {
		tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (x * (y * y))))))) / t_1;
	} else if (y <= 1.05e+48) {
		tmp = (t + (y * (230661.510616 + (z * (y * y))))) / t_1;
	} else if (y <= 5.6e+115) {
		tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y));
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i):
	t_1 = (y * ((y * ((y * (y + a)) + b)) + c)) + i
	t_2 = (z / y) + (x - (a / (y / x)))
	tmp = 0
	if y <= -4e+53:
		tmp = t_2
	elif y <= -6.6e-50:
		tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (x * (y * y))))))) / t_1
	elif y <= 1.05e+48:
		tmp = (t + (y * (230661.510616 + (z * (y * y))))) / t_1
	elif y <= 5.6e+115:
		tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y))
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a, b, c, i)
	t_1 = Float64(Float64(y * Float64(Float64(y * Float64(Float64(y * Float64(y + a)) + b)) + c)) + i)
	t_2 = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x))))
	tmp = 0.0
	if (y <= -4e+53)
		tmp = t_2;
	elseif (y <= -6.6e-50)
		tmp = Float64(Float64(t + Float64(y * Float64(230661.510616 + Float64(y * Float64(27464.7644705 + Float64(x * Float64(y * y))))))) / t_1);
	elseif (y <= 1.05e+48)
		tmp = Float64(Float64(t + Float64(y * Float64(230661.510616 + Float64(z * Float64(y * y))))) / t_1);
	elseif (y <= 5.6e+115)
		tmp = Float64(1.0 / Float64(Float64(1.0 / x) + Float64(Float64(Float64(a / x) - Float64(z / Float64(x * x))) / y)));
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i)
	t_1 = (y * ((y * ((y * (y + a)) + b)) + c)) + i;
	t_2 = (z / y) + (x - (a / (y / x)));
	tmp = 0.0;
	if (y <= -4e+53)
		tmp = t_2;
	elseif (y <= -6.6e-50)
		tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (x * (y * y))))))) / t_1;
	elseif (y <= 1.05e+48)
		tmp = (t + (y * (230661.510616 + (z * (y * y))))) / t_1;
	elseif (y <= 5.6e+115)
		tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y));
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(y * N[(N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]), $MachinePrecision] + i), $MachinePrecision]}, Block[{t$95$2 = N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -4e+53], t$95$2, If[LessEqual[y, -6.6e-50], N[(N[(t + N[(y * N[(230661.510616 + N[(y * N[(27464.7644705 + N[(x * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / t$95$1), $MachinePrecision], If[LessEqual[y, 1.05e+48], N[(N[(t + N[(y * N[(230661.510616 + N[(z * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / t$95$1), $MachinePrecision], If[LessEqual[y, 5.6e+115], N[(1.0 / N[(N[(1.0 / x), $MachinePrecision] + N[(N[(N[(a / x), $MachinePrecision] - N[(z / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$2]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i\\
t_2 := \frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\
\mathbf{if}\;y \leq -4 \cdot 10^{+53}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;y \leq -6.6 \cdot 10^{-50}:\\
\;\;\;\;\frac{t + y \cdot \left(230661.510616 + y \cdot \left(27464.7644705 + x \cdot \left(y \cdot y\right)\right)\right)}{t_1}\\

\mathbf{elif}\;y \leq 1.05 \cdot 10^{+48}:\\
\;\;\;\;\frac{t + y \cdot \left(230661.510616 + z \cdot \left(y \cdot y\right)\right)}{t_1}\\

\mathbf{elif}\;y \leq 5.6 \cdot 10^{+115}:\\
\;\;\;\;\frac{1}{\frac{1}{x} + \frac{\frac{a}{x} - \frac{z}{x \cdot x}}{y}}\\

\mathbf{else}:\\
\;\;\;\;t_2\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if y < -4e53 or 5.6000000000000001e115 < y

    1. Initial program 0.3%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around inf 74.6%

      \[\leadsto \color{blue}{\left(\frac{z}{y} + x\right) - \frac{a \cdot x}{y}} \]
    3. Step-by-step derivation
      1. associate--l+74.6%

        \[\leadsto \color{blue}{\frac{z}{y} + \left(x - \frac{a \cdot x}{y}\right)} \]
      2. associate-/l*80.6%

        \[\leadsto \frac{z}{y} + \left(x - \color{blue}{\frac{a}{\frac{y}{x}}}\right) \]
    4. Simplified80.6%

      \[\leadsto \color{blue}{\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)} \]

    if -4e53 < y < -6.5999999999999997e-50

    1. Initial program 83.0%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in x around inf 78.9%

      \[\leadsto \frac{\left(\left(\color{blue}{{y}^{2} \cdot x} + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    3. Step-by-step derivation
      1. *-commutative78.9%

        \[\leadsto \frac{\left(\left(\color{blue}{x \cdot {y}^{2}} + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
      2. unpow278.9%

        \[\leadsto \frac{\left(\left(x \cdot \color{blue}{\left(y \cdot y\right)} + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    4. Simplified78.9%

      \[\leadsto \frac{\left(\left(\color{blue}{x \cdot \left(y \cdot y\right)} + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]

    if -6.5999999999999997e-50 < y < 1.0499999999999999e48

    1. Initial program 99.0%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in z around inf 95.9%

      \[\leadsto \frac{\left(\color{blue}{{y}^{2} \cdot z} + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    3. Step-by-step derivation
      1. *-commutative95.9%

        \[\leadsto \frac{\left(\color{blue}{z \cdot {y}^{2}} + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
      2. unpow295.9%

        \[\leadsto \frac{\left(z \cdot \color{blue}{\left(y \cdot y\right)} + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    4. Simplified95.9%

      \[\leadsto \frac{\left(\color{blue}{z \cdot \left(y \cdot y\right)} + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]

    if 1.0499999999999999e48 < y < 5.6000000000000001e115

    1. Initial program 8.4%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Step-by-step derivation
      1. clear-num8.4%

        \[\leadsto \color{blue}{\frac{1}{\frac{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i}{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}}} \]
      2. inv-pow8.4%

        \[\leadsto \color{blue}{{\left(\frac{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i}{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}\right)}^{-1}} \]
    3. Applied egg-rr8.4%

      \[\leadsto \color{blue}{{\left(\frac{\mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(y, y + a, b\right), c\right), i\right)}{\mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(x, y, z\right), 27464.7644705\right), 230661.510616\right), t\right)}\right)}^{-1}} \]
    4. Step-by-step derivation
      1. unpow-18.4%

        \[\leadsto \color{blue}{\frac{1}{\frac{\mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(y, y + a, b\right), c\right), i\right)}{\mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(x, y, z\right), 27464.7644705\right), 230661.510616\right), t\right)}}} \]
      2. fma-udef8.4%

        \[\leadsto \frac{1}{\frac{\mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(y, y + a, b\right), c\right), i\right)}{\mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(y, \color{blue}{x \cdot y + z}, 27464.7644705\right), 230661.510616\right), t\right)}} \]
      3. *-commutative8.4%

        \[\leadsto \frac{1}{\frac{\mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(y, y + a, b\right), c\right), i\right)}{\mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(y, \color{blue}{y \cdot x} + z, 27464.7644705\right), 230661.510616\right), t\right)}} \]
      4. fma-def8.4%

        \[\leadsto \frac{1}{\frac{\mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(y, y + a, b\right), c\right), i\right)}{\mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(y, \color{blue}{\mathsf{fma}\left(y, x, z\right)}, 27464.7644705\right), 230661.510616\right), t\right)}} \]
    5. Simplified8.4%

      \[\leadsto \color{blue}{\frac{1}{\frac{\mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(y, y + a, b\right), c\right), i\right)}{\mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(y, x, z\right), 27464.7644705\right), 230661.510616\right), t\right)}}} \]
    6. Taylor expanded in y around -inf 39.8%

      \[\leadsto \frac{1}{\color{blue}{\frac{1}{x} + -1 \cdot \frac{-1 \cdot \frac{a}{x} - -1 \cdot \frac{z}{{x}^{2}}}{y}}} \]
    7. Step-by-step derivation
      1. mul-1-neg39.8%

        \[\leadsto \frac{1}{\frac{1}{x} + \color{blue}{\left(-\frac{-1 \cdot \frac{a}{x} - -1 \cdot \frac{z}{{x}^{2}}}{y}\right)}} \]
      2. distribute-lft-out--39.8%

        \[\leadsto \frac{1}{\frac{1}{x} + \left(-\frac{\color{blue}{-1 \cdot \left(\frac{a}{x} - \frac{z}{{x}^{2}}\right)}}{y}\right)} \]
      3. unpow239.8%

        \[\leadsto \frac{1}{\frac{1}{x} + \left(-\frac{-1 \cdot \left(\frac{a}{x} - \frac{z}{\color{blue}{x \cdot x}}\right)}{y}\right)} \]
    8. Simplified39.8%

      \[\leadsto \frac{1}{\color{blue}{\frac{1}{x} + \left(-\frac{-1 \cdot \left(\frac{a}{x} - \frac{z}{x \cdot x}\right)}{y}\right)}} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification85.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -4 \cdot 10^{+53}:\\ \;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \mathbf{elif}\;y \leq -6.6 \cdot 10^{-50}:\\ \;\;\;\;\frac{t + y \cdot \left(230661.510616 + y \cdot \left(27464.7644705 + x \cdot \left(y \cdot y\right)\right)\right)}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\ \mathbf{elif}\;y \leq 1.05 \cdot 10^{+48}:\\ \;\;\;\;\frac{t + y \cdot \left(230661.510616 + z \cdot \left(y \cdot y\right)\right)}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\ \mathbf{elif}\;y \leq 5.6 \cdot 10^{+115}:\\ \;\;\;\;\frac{1}{\frac{1}{x} + \frac{\frac{a}{x} - \frac{z}{x \cdot x}}{y}}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \end{array} \]

Alternative 3: 80.2% accurate, 1.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -5 \cdot 10^{+53} \lor \neg \left(y \leq 1.55 \cdot 10^{+59}\right):\\ \;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{t + y \cdot \left(230661.510616 + z \cdot \left(y \cdot y\right)\right)}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (if (or (<= y -5e+53) (not (<= y 1.55e+59)))
   (+ (/ z y) (- x (/ a (/ y x))))
   (/
    (+ t (* y (+ 230661.510616 (* z (* y y)))))
    (+ (* y (+ (* y (+ (* y (+ y a)) b)) c)) i))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((y <= -5e+53) || !(y <= 1.55e+59)) {
		tmp = (z / y) + (x - (a / (y / x)));
	} else {
		tmp = (t + (y * (230661.510616 + (z * (y * y))))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8) :: tmp
    if ((y <= (-5d+53)) .or. (.not. (y <= 1.55d+59))) then
        tmp = (z / y) + (x - (a / (y / x)))
    else
        tmp = (t + (y * (230661.510616d0 + (z * (y * y))))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i)
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((y <= -5e+53) || !(y <= 1.55e+59)) {
		tmp = (z / y) + (x - (a / (y / x)));
	} else {
		tmp = (t + (y * (230661.510616 + (z * (y * y))))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i):
	tmp = 0
	if (y <= -5e+53) or not (y <= 1.55e+59):
		tmp = (z / y) + (x - (a / (y / x)))
	else:
		tmp = (t + (y * (230661.510616 + (z * (y * y))))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i)
	return tmp
function code(x, y, z, t, a, b, c, i)
	tmp = 0.0
	if ((y <= -5e+53) || !(y <= 1.55e+59))
		tmp = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x))));
	else
		tmp = Float64(Float64(t + Float64(y * Float64(230661.510616 + Float64(z * Float64(y * y))))) / Float64(Float64(y * Float64(Float64(y * Float64(Float64(y * Float64(y + a)) + b)) + c)) + i));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i)
	tmp = 0.0;
	if ((y <= -5e+53) || ~((y <= 1.55e+59)))
		tmp = (z / y) + (x - (a / (y / x)));
	else
		tmp = (t + (y * (230661.510616 + (z * (y * y))))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -5e+53], N[Not[LessEqual[y, 1.55e+59]], $MachinePrecision]], N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(t + N[(y * N[(230661.510616 + N[(z * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(y * N[(N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]), $MachinePrecision] + i), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -5 \cdot 10^{+53} \lor \neg \left(y \leq 1.55 \cdot 10^{+59}\right):\\
\;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\

\mathbf{else}:\\
\;\;\;\;\frac{t + y \cdot \left(230661.510616 + z \cdot \left(y \cdot y\right)\right)}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -5.0000000000000004e53 or 1.55000000000000007e59 < y

    1. Initial program 1.4%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around inf 67.3%

      \[\leadsto \color{blue}{\left(\frac{z}{y} + x\right) - \frac{a \cdot x}{y}} \]
    3. Step-by-step derivation
      1. associate--l+67.3%

        \[\leadsto \color{blue}{\frac{z}{y} + \left(x - \frac{a \cdot x}{y}\right)} \]
      2. associate-/l*74.4%

        \[\leadsto \frac{z}{y} + \left(x - \color{blue}{\frac{a}{\frac{y}{x}}}\right) \]
    4. Simplified74.4%

      \[\leadsto \color{blue}{\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)} \]

    if -5.0000000000000004e53 < y < 1.55000000000000007e59

    1. Initial program 95.2%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in z around inf 89.2%

      \[\leadsto \frac{\left(\color{blue}{{y}^{2} \cdot z} + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    3. Step-by-step derivation
      1. *-commutative89.2%

        \[\leadsto \frac{\left(\color{blue}{z \cdot {y}^{2}} + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
      2. unpow289.2%

        \[\leadsto \frac{\left(z \cdot \color{blue}{\left(y \cdot y\right)} + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    4. Simplified89.2%

      \[\leadsto \frac{\left(\color{blue}{z \cdot \left(y \cdot y\right)} + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification82.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -5 \cdot 10^{+53} \lor \neg \left(y \leq 1.55 \cdot 10^{+59}\right):\\ \;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{t + y \cdot \left(230661.510616 + z \cdot \left(y \cdot y\right)\right)}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\ \end{array} \]

Alternative 4: 76.6% accurate, 1.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -5.4 \cdot 10^{+53} \lor \neg \left(y \leq 1.25 \cdot 10^{+56}\right):\\ \;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{t + y \cdot \left(230661.510616 + y \cdot 27464.7644705\right)}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (if (or (<= y -5.4e+53) (not (<= y 1.25e+56)))
   (+ (/ z y) (- x (/ a (/ y x))))
   (/
    (+ t (* y (+ 230661.510616 (* y 27464.7644705))))
    (+ (* y (+ (* y (+ (* y (+ y a)) b)) c)) i))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((y <= -5.4e+53) || !(y <= 1.25e+56)) {
		tmp = (z / y) + (x - (a / (y / x)));
	} else {
		tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8) :: tmp
    if ((y <= (-5.4d+53)) .or. (.not. (y <= 1.25d+56))) then
        tmp = (z / y) + (x - (a / (y / x)))
    else
        tmp = (t + (y * (230661.510616d0 + (y * 27464.7644705d0)))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i)
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((y <= -5.4e+53) || !(y <= 1.25e+56)) {
		tmp = (z / y) + (x - (a / (y / x)));
	} else {
		tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i):
	tmp = 0
	if (y <= -5.4e+53) or not (y <= 1.25e+56):
		tmp = (z / y) + (x - (a / (y / x)))
	else:
		tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i)
	return tmp
function code(x, y, z, t, a, b, c, i)
	tmp = 0.0
	if ((y <= -5.4e+53) || !(y <= 1.25e+56))
		tmp = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x))));
	else
		tmp = Float64(Float64(t + Float64(y * Float64(230661.510616 + Float64(y * 27464.7644705)))) / Float64(Float64(y * Float64(Float64(y * Float64(Float64(y * Float64(y + a)) + b)) + c)) + i));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i)
	tmp = 0.0;
	if ((y <= -5.4e+53) || ~((y <= 1.25e+56)))
		tmp = (z / y) + (x - (a / (y / x)));
	else
		tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -5.4e+53], N[Not[LessEqual[y, 1.25e+56]], $MachinePrecision]], N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(t + N[(y * N[(230661.510616 + N[(y * 27464.7644705), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(y * N[(N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]), $MachinePrecision] + i), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -5.4 \cdot 10^{+53} \lor \neg \left(y \leq 1.25 \cdot 10^{+56}\right):\\
\;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\

\mathbf{else}:\\
\;\;\;\;\frac{t + y \cdot \left(230661.510616 + y \cdot 27464.7644705\right)}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -5.40000000000000039e53 or 1.25000000000000006e56 < y

    1. Initial program 1.4%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around inf 67.3%

      \[\leadsto \color{blue}{\left(\frac{z}{y} + x\right) - \frac{a \cdot x}{y}} \]
    3. Step-by-step derivation
      1. associate--l+67.3%

        \[\leadsto \color{blue}{\frac{z}{y} + \left(x - \frac{a \cdot x}{y}\right)} \]
      2. associate-/l*74.4%

        \[\leadsto \frac{z}{y} + \left(x - \color{blue}{\frac{a}{\frac{y}{x}}}\right) \]
    4. Simplified74.4%

      \[\leadsto \color{blue}{\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)} \]

    if -5.40000000000000039e53 < y < 1.25000000000000006e56

    1. Initial program 95.2%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around 0 84.2%

      \[\leadsto \frac{\left(\color{blue}{27464.7644705 \cdot y} + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    3. Step-by-step derivation
      1. *-commutative84.2%

        \[\leadsto \frac{\left(\color{blue}{y \cdot 27464.7644705} + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    4. Simplified84.2%

      \[\leadsto \frac{\left(\color{blue}{y \cdot 27464.7644705} + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification80.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -5.4 \cdot 10^{+53} \lor \neg \left(y \leq 1.25 \cdot 10^{+56}\right):\\ \;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{t + y \cdot \left(230661.510616 + y \cdot 27464.7644705\right)}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\ \end{array} \]

Alternative 5: 75.7% accurate, 1.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -3.8 \cdot 10^{+53} \lor \neg \left(y \leq 1.4 \cdot 10^{+57}\right):\\ \;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{t + y \cdot 230661.510616}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (if (or (<= y -3.8e+53) (not (<= y 1.4e+57)))
   (+ (/ z y) (- x (/ a (/ y x))))
   (/ (+ t (* y 230661.510616)) (+ (* y (+ (* y (+ (* y (+ y a)) b)) c)) i))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((y <= -3.8e+53) || !(y <= 1.4e+57)) {
		tmp = (z / y) + (x - (a / (y / x)));
	} else {
		tmp = (t + (y * 230661.510616)) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8) :: tmp
    if ((y <= (-3.8d+53)) .or. (.not. (y <= 1.4d+57))) then
        tmp = (z / y) + (x - (a / (y / x)))
    else
        tmp = (t + (y * 230661.510616d0)) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i)
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((y <= -3.8e+53) || !(y <= 1.4e+57)) {
		tmp = (z / y) + (x - (a / (y / x)));
	} else {
		tmp = (t + (y * 230661.510616)) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i):
	tmp = 0
	if (y <= -3.8e+53) or not (y <= 1.4e+57):
		tmp = (z / y) + (x - (a / (y / x)))
	else:
		tmp = (t + (y * 230661.510616)) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i)
	return tmp
function code(x, y, z, t, a, b, c, i)
	tmp = 0.0
	if ((y <= -3.8e+53) || !(y <= 1.4e+57))
		tmp = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x))));
	else
		tmp = Float64(Float64(t + Float64(y * 230661.510616)) / Float64(Float64(y * Float64(Float64(y * Float64(Float64(y * Float64(y + a)) + b)) + c)) + i));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i)
	tmp = 0.0;
	if ((y <= -3.8e+53) || ~((y <= 1.4e+57)))
		tmp = (z / y) + (x - (a / (y / x)));
	else
		tmp = (t + (y * 230661.510616)) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -3.8e+53], N[Not[LessEqual[y, 1.4e+57]], $MachinePrecision]], N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / N[(N[(y * N[(N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]), $MachinePrecision] + i), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.8 \cdot 10^{+53} \lor \neg \left(y \leq 1.4 \cdot 10^{+57}\right):\\
\;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\

\mathbf{else}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -3.79999999999999997e53 or 1.4e57 < y

    1. Initial program 1.4%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around inf 67.3%

      \[\leadsto \color{blue}{\left(\frac{z}{y} + x\right) - \frac{a \cdot x}{y}} \]
    3. Step-by-step derivation
      1. associate--l+67.3%

        \[\leadsto \color{blue}{\frac{z}{y} + \left(x - \frac{a \cdot x}{y}\right)} \]
      2. associate-/l*74.4%

        \[\leadsto \frac{z}{y} + \left(x - \color{blue}{\frac{a}{\frac{y}{x}}}\right) \]
    4. Simplified74.4%

      \[\leadsto \color{blue}{\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)} \]

    if -3.79999999999999997e53 < y < 1.4e57

    1. Initial program 95.2%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around 0 82.7%

      \[\leadsto \frac{\color{blue}{230661.510616 \cdot y} + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    3. Step-by-step derivation
      1. *-commutative82.7%

        \[\leadsto \frac{\color{blue}{y \cdot 230661.510616} + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    4. Simplified82.7%

      \[\leadsto \frac{\color{blue}{y \cdot 230661.510616} + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification79.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -3.8 \cdot 10^{+53} \lor \neg \left(y \leq 1.4 \cdot 10^{+57}\right):\\ \;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{t + y \cdot 230661.510616}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\ \end{array} \]

Alternative 6: 74.0% accurate, 1.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -2.9 \cdot 10^{+53} \lor \neg \left(y \leq 1.8 \cdot 10^{+61}\right):\\ \;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{t + y \cdot 230661.510616}{i + y \cdot \left(c + y \cdot \left(b + y \cdot y\right)\right)}\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (if (or (<= y -2.9e+53) (not (<= y 1.8e+61)))
   (+ (/ z y) (- x (/ a (/ y x))))
   (/ (+ t (* y 230661.510616)) (+ i (* y (+ c (* y (+ b (* y y)))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((y <= -2.9e+53) || !(y <= 1.8e+61)) {
		tmp = (z / y) + (x - (a / (y / x)));
	} else {
		tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * (b + (y * y))))));
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8) :: tmp
    if ((y <= (-2.9d+53)) .or. (.not. (y <= 1.8d+61))) then
        tmp = (z / y) + (x - (a / (y / x)))
    else
        tmp = (t + (y * 230661.510616d0)) / (i + (y * (c + (y * (b + (y * y))))))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((y <= -2.9e+53) || !(y <= 1.8e+61)) {
		tmp = (z / y) + (x - (a / (y / x)));
	} else {
		tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * (b + (y * y))))));
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i):
	tmp = 0
	if (y <= -2.9e+53) or not (y <= 1.8e+61):
		tmp = (z / y) + (x - (a / (y / x)))
	else:
		tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * (b + (y * y))))))
	return tmp
function code(x, y, z, t, a, b, c, i)
	tmp = 0.0
	if ((y <= -2.9e+53) || !(y <= 1.8e+61))
		tmp = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x))));
	else
		tmp = Float64(Float64(t + Float64(y * 230661.510616)) / Float64(i + Float64(y * Float64(c + Float64(y * Float64(b + Float64(y * y)))))));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i)
	tmp = 0.0;
	if ((y <= -2.9e+53) || ~((y <= 1.8e+61)))
		tmp = (z / y) + (x - (a / (y / x)));
	else
		tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * (b + (y * y))))));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -2.9e+53], N[Not[LessEqual[y, 1.8e+61]], $MachinePrecision]], N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * N[(c + N[(y * N[(b + N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.9 \cdot 10^{+53} \lor \neg \left(y \leq 1.8 \cdot 10^{+61}\right):\\
\;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\

\mathbf{else}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{i + y \cdot \left(c + y \cdot \left(b + y \cdot y\right)\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -2.9000000000000002e53 or 1.80000000000000005e61 < y

    1. Initial program 1.4%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around inf 67.9%

      \[\leadsto \color{blue}{\left(\frac{z}{y} + x\right) - \frac{a \cdot x}{y}} \]
    3. Step-by-step derivation
      1. associate--l+67.9%

        \[\leadsto \color{blue}{\frac{z}{y} + \left(x - \frac{a \cdot x}{y}\right)} \]
      2. associate-/l*75.0%

        \[\leadsto \frac{z}{y} + \left(x - \color{blue}{\frac{a}{\frac{y}{x}}}\right) \]
    4. Simplified75.0%

      \[\leadsto \color{blue}{\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)} \]

    if -2.9000000000000002e53 < y < 1.80000000000000005e61

    1. Initial program 94.5%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around 0 82.2%

      \[\leadsto \frac{\color{blue}{230661.510616 \cdot y} + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    3. Step-by-step derivation
      1. *-commutative82.2%

        \[\leadsto \frac{\color{blue}{y \cdot 230661.510616} + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    4. Simplified82.2%

      \[\leadsto \frac{\color{blue}{y \cdot 230661.510616} + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    5. Taylor expanded in a around 0 79.1%

      \[\leadsto \frac{y \cdot 230661.510616 + t}{\left(\color{blue}{\left({y}^{2} + b\right) \cdot y} + c\right) \cdot y + i} \]
    6. Step-by-step derivation
      1. *-commutative79.1%

        \[\leadsto \frac{y \cdot 230661.510616 + t}{\left(\color{blue}{y \cdot \left({y}^{2} + b\right)} + c\right) \cdot y + i} \]
      2. +-commutative79.1%

        \[\leadsto \frac{y \cdot 230661.510616 + t}{\left(y \cdot \color{blue}{\left(b + {y}^{2}\right)} + c\right) \cdot y + i} \]
      3. unpow279.1%

        \[\leadsto \frac{y \cdot 230661.510616 + t}{\left(y \cdot \left(b + \color{blue}{y \cdot y}\right) + c\right) \cdot y + i} \]
    7. Simplified79.1%

      \[\leadsto \frac{y \cdot 230661.510616 + t}{\left(\color{blue}{y \cdot \left(b + y \cdot y\right)} + c\right) \cdot y + i} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification77.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.9 \cdot 10^{+53} \lor \neg \left(y \leq 1.8 \cdot 10^{+61}\right):\\ \;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{t + y \cdot 230661.510616}{i + y \cdot \left(c + y \cdot \left(b + y \cdot y\right)\right)}\\ \end{array} \]

Alternative 7: 73.9% accurate, 1.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -2.9 \cdot 10^{+53} \lor \neg \left(y \leq 1.05 \cdot 10^{+49}\right):\\ \;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{t + y \cdot 230661.510616}{i + y \cdot \left(c + y \cdot b\right)}\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (if (or (<= y -2.9e+53) (not (<= y 1.05e+49)))
   (+ (/ z y) (- x (/ a (/ y x))))
   (/ (+ t (* y 230661.510616)) (+ i (* y (+ c (* y b)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((y <= -2.9e+53) || !(y <= 1.05e+49)) {
		tmp = (z / y) + (x - (a / (y / x)));
	} else {
		tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * b))));
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8) :: tmp
    if ((y <= (-2.9d+53)) .or. (.not. (y <= 1.05d+49))) then
        tmp = (z / y) + (x - (a / (y / x)))
    else
        tmp = (t + (y * 230661.510616d0)) / (i + (y * (c + (y * b))))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((y <= -2.9e+53) || !(y <= 1.05e+49)) {
		tmp = (z / y) + (x - (a / (y / x)));
	} else {
		tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * b))));
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i):
	tmp = 0
	if (y <= -2.9e+53) or not (y <= 1.05e+49):
		tmp = (z / y) + (x - (a / (y / x)))
	else:
		tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * b))))
	return tmp
function code(x, y, z, t, a, b, c, i)
	tmp = 0.0
	if ((y <= -2.9e+53) || !(y <= 1.05e+49))
		tmp = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x))));
	else
		tmp = Float64(Float64(t + Float64(y * 230661.510616)) / Float64(i + Float64(y * Float64(c + Float64(y * b)))));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i)
	tmp = 0.0;
	if ((y <= -2.9e+53) || ~((y <= 1.05e+49)))
		tmp = (z / y) + (x - (a / (y / x)));
	else
		tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * b))));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -2.9e+53], N[Not[LessEqual[y, 1.05e+49]], $MachinePrecision]], N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * N[(c + N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.9 \cdot 10^{+53} \lor \neg \left(y \leq 1.05 \cdot 10^{+49}\right):\\
\;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\

\mathbf{else}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{i + y \cdot \left(c + y \cdot b\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -2.9000000000000002e53 or 1.05000000000000005e49 < y

    1. Initial program 1.5%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around inf 66.7%

      \[\leadsto \color{blue}{\left(\frac{z}{y} + x\right) - \frac{a \cdot x}{y}} \]
    3. Step-by-step derivation
      1. associate--l+66.7%

        \[\leadsto \color{blue}{\frac{z}{y} + \left(x - \frac{a \cdot x}{y}\right)} \]
      2. associate-/l*73.7%

        \[\leadsto \frac{z}{y} + \left(x - \color{blue}{\frac{a}{\frac{y}{x}}}\right) \]
    4. Simplified73.7%

      \[\leadsto \color{blue}{\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)} \]

    if -2.9000000000000002e53 < y < 1.05000000000000005e49

    1. Initial program 95.8%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around 0 83.2%

      \[\leadsto \frac{\color{blue}{230661.510616 \cdot y} + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    3. Step-by-step derivation
      1. *-commutative83.2%

        \[\leadsto \frac{\color{blue}{y \cdot 230661.510616} + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    4. Simplified83.2%

      \[\leadsto \frac{\color{blue}{y \cdot 230661.510616} + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    5. Taylor expanded in y around 0 79.5%

      \[\leadsto \frac{y \cdot 230661.510616 + t}{\left(\color{blue}{y \cdot b} + c\right) \cdot y + i} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification77.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.9 \cdot 10^{+53} \lor \neg \left(y \leq 1.05 \cdot 10^{+49}\right):\\ \;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{t + y \cdot 230661.510616}{i + y \cdot \left(c + y \cdot b\right)}\\ \end{array} \]

Alternative 8: 60.2% accurate, 2.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -6 \cdot 10^{+37} \lor \neg \left(y \leq 7.2 \cdot 10^{-25}\right):\\ \;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{i} + y \cdot \frac{230661.510616}{i}\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (if (or (<= y -6e+37) (not (<= y 7.2e-25)))
   (+ (/ z y) (- x (/ a (/ y x))))
   (+ (/ t i) (* y (/ 230661.510616 i)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((y <= -6e+37) || !(y <= 7.2e-25)) {
		tmp = (z / y) + (x - (a / (y / x)));
	} else {
		tmp = (t / i) + (y * (230661.510616 / i));
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8) :: tmp
    if ((y <= (-6d+37)) .or. (.not. (y <= 7.2d-25))) then
        tmp = (z / y) + (x - (a / (y / x)))
    else
        tmp = (t / i) + (y * (230661.510616d0 / i))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((y <= -6e+37) || !(y <= 7.2e-25)) {
		tmp = (z / y) + (x - (a / (y / x)));
	} else {
		tmp = (t / i) + (y * (230661.510616 / i));
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i):
	tmp = 0
	if (y <= -6e+37) or not (y <= 7.2e-25):
		tmp = (z / y) + (x - (a / (y / x)))
	else:
		tmp = (t / i) + (y * (230661.510616 / i))
	return tmp
function code(x, y, z, t, a, b, c, i)
	tmp = 0.0
	if ((y <= -6e+37) || !(y <= 7.2e-25))
		tmp = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x))));
	else
		tmp = Float64(Float64(t / i) + Float64(y * Float64(230661.510616 / i)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i)
	tmp = 0.0;
	if ((y <= -6e+37) || ~((y <= 7.2e-25)))
		tmp = (z / y) + (x - (a / (y / x)));
	else
		tmp = (t / i) + (y * (230661.510616 / i));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -6e+37], N[Not[LessEqual[y, 7.2e-25]], $MachinePrecision]], N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(t / i), $MachinePrecision] + N[(y * N[(230661.510616 / i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -6 \cdot 10^{+37} \lor \neg \left(y \leq 7.2 \cdot 10^{-25}\right):\\
\;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\

\mathbf{else}:\\
\;\;\;\;\frac{t}{i} + y \cdot \frac{230661.510616}{i}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -6.00000000000000043e37 or 7.1999999999999998e-25 < y

    1. Initial program 11.0%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around inf 59.8%

      \[\leadsto \color{blue}{\left(\frac{z}{y} + x\right) - \frac{a \cdot x}{y}} \]
    3. Step-by-step derivation
      1. associate--l+59.8%

        \[\leadsto \color{blue}{\frac{z}{y} + \left(x - \frac{a \cdot x}{y}\right)} \]
      2. associate-/l*66.0%

        \[\leadsto \frac{z}{y} + \left(x - \color{blue}{\frac{a}{\frac{y}{x}}}\right) \]
    4. Simplified66.0%

      \[\leadsto \color{blue}{\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)} \]

    if -6.00000000000000043e37 < y < 7.1999999999999998e-25

    1. Initial program 97.5%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around 0 48.8%

      \[\leadsto \color{blue}{\frac{t}{i} + \left(230661.510616 \cdot \frac{1}{i} - \frac{c \cdot t}{{i}^{2}}\right) \cdot y} \]
    3. Taylor expanded in i around inf 58.1%

      \[\leadsto \frac{t}{i} + \color{blue}{\frac{230661.510616}{i}} \cdot y \]
  3. Recombined 2 regimes into one program.
  4. Final simplification62.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -6 \cdot 10^{+37} \lor \neg \left(y \leq 7.2 \cdot 10^{-25}\right):\\ \;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{i} + y \cdot \frac{230661.510616}{i}\\ \end{array} \]

Alternative 9: 70.3% accurate, 2.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -2.9 \cdot 10^{+53} \lor \neg \left(y \leq 1.96 \cdot 10^{+31}\right):\\ \;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{t + y \cdot 230661.510616}{i + y \cdot c}\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (if (or (<= y -2.9e+53) (not (<= y 1.96e+31)))
   (+ (/ z y) (- x (/ a (/ y x))))
   (/ (+ t (* y 230661.510616)) (+ i (* y c)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((y <= -2.9e+53) || !(y <= 1.96e+31)) {
		tmp = (z / y) + (x - (a / (y / x)));
	} else {
		tmp = (t + (y * 230661.510616)) / (i + (y * c));
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8) :: tmp
    if ((y <= (-2.9d+53)) .or. (.not. (y <= 1.96d+31))) then
        tmp = (z / y) + (x - (a / (y / x)))
    else
        tmp = (t + (y * 230661.510616d0)) / (i + (y * c))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((y <= -2.9e+53) || !(y <= 1.96e+31)) {
		tmp = (z / y) + (x - (a / (y / x)));
	} else {
		tmp = (t + (y * 230661.510616)) / (i + (y * c));
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i):
	tmp = 0
	if (y <= -2.9e+53) or not (y <= 1.96e+31):
		tmp = (z / y) + (x - (a / (y / x)))
	else:
		tmp = (t + (y * 230661.510616)) / (i + (y * c))
	return tmp
function code(x, y, z, t, a, b, c, i)
	tmp = 0.0
	if ((y <= -2.9e+53) || !(y <= 1.96e+31))
		tmp = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x))));
	else
		tmp = Float64(Float64(t + Float64(y * 230661.510616)) / Float64(i + Float64(y * c)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i)
	tmp = 0.0;
	if ((y <= -2.9e+53) || ~((y <= 1.96e+31)))
		tmp = (z / y) + (x - (a / (y / x)));
	else
		tmp = (t + (y * 230661.510616)) / (i + (y * c));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -2.9e+53], N[Not[LessEqual[y, 1.96e+31]], $MachinePrecision]], N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.9 \cdot 10^{+53} \lor \neg \left(y \leq 1.96 \cdot 10^{+31}\right):\\
\;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\

\mathbf{else}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{i + y \cdot c}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -2.9000000000000002e53 or 1.95999999999999994e31 < y

    1. Initial program 2.4%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around inf 65.6%

      \[\leadsto \color{blue}{\left(\frac{z}{y} + x\right) - \frac{a \cdot x}{y}} \]
    3. Step-by-step derivation
      1. associate--l+65.6%

        \[\leadsto \color{blue}{\frac{z}{y} + \left(x - \frac{a \cdot x}{y}\right)} \]
      2. associate-/l*72.5%

        \[\leadsto \frac{z}{y} + \left(x - \color{blue}{\frac{a}{\frac{y}{x}}}\right) \]
    4. Simplified72.5%

      \[\leadsto \color{blue}{\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)} \]

    if -2.9000000000000002e53 < y < 1.95999999999999994e31

    1. Initial program 96.4%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around 0 83.7%

      \[\leadsto \frac{\color{blue}{230661.510616 \cdot y} + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    3. Step-by-step derivation
      1. *-commutative83.7%

        \[\leadsto \frac{\color{blue}{y \cdot 230661.510616} + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    4. Simplified83.7%

      \[\leadsto \frac{\color{blue}{y \cdot 230661.510616} + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    5. Taylor expanded in y around 0 71.9%

      \[\leadsto \frac{y \cdot 230661.510616 + t}{\color{blue}{c \cdot y} + i} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification72.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.9 \cdot 10^{+53} \lor \neg \left(y \leq 1.96 \cdot 10^{+31}\right):\\ \;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{t + y \cdot 230661.510616}{i + y \cdot c}\\ \end{array} \]

Alternative 10: 58.4% accurate, 2.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -5.6 \cdot 10^{+33} \lor \neg \left(y \leq 6.8 \cdot 10^{-25}\right):\\ \;\;\;\;x - \frac{x \cdot a - z}{y}\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{i} + y \cdot \frac{230661.510616}{i}\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (if (or (<= y -5.6e+33) (not (<= y 6.8e-25)))
   (- x (/ (- (* x a) z) y))
   (+ (/ t i) (* y (/ 230661.510616 i)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((y <= -5.6e+33) || !(y <= 6.8e-25)) {
		tmp = x - (((x * a) - z) / y);
	} else {
		tmp = (t / i) + (y * (230661.510616 / i));
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8) :: tmp
    if ((y <= (-5.6d+33)) .or. (.not. (y <= 6.8d-25))) then
        tmp = x - (((x * a) - z) / y)
    else
        tmp = (t / i) + (y * (230661.510616d0 / i))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((y <= -5.6e+33) || !(y <= 6.8e-25)) {
		tmp = x - (((x * a) - z) / y);
	} else {
		tmp = (t / i) + (y * (230661.510616 / i));
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i):
	tmp = 0
	if (y <= -5.6e+33) or not (y <= 6.8e-25):
		tmp = x - (((x * a) - z) / y)
	else:
		tmp = (t / i) + (y * (230661.510616 / i))
	return tmp
function code(x, y, z, t, a, b, c, i)
	tmp = 0.0
	if ((y <= -5.6e+33) || !(y <= 6.8e-25))
		tmp = Float64(x - Float64(Float64(Float64(x * a) - z) / y));
	else
		tmp = Float64(Float64(t / i) + Float64(y * Float64(230661.510616 / i)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i)
	tmp = 0.0;
	if ((y <= -5.6e+33) || ~((y <= 6.8e-25)))
		tmp = x - (((x * a) - z) / y);
	else
		tmp = (t / i) + (y * (230661.510616 / i));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -5.6e+33], N[Not[LessEqual[y, 6.8e-25]], $MachinePrecision]], N[(x - N[(N[(N[(x * a), $MachinePrecision] - z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(N[(t / i), $MachinePrecision] + N[(y * N[(230661.510616 / i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -5.6 \cdot 10^{+33} \lor \neg \left(y \leq 6.8 \cdot 10^{-25}\right):\\
\;\;\;\;x - \frac{x \cdot a - z}{y}\\

\mathbf{else}:\\
\;\;\;\;\frac{t}{i} + y \cdot \frac{230661.510616}{i}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -5.6000000000000002e33 or 6.80000000000000003e-25 < y

    1. Initial program 11.0%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Step-by-step derivation
      1. div-inv10.9%

        \[\leadsto \color{blue}{\left(\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t\right) \cdot \frac{1}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i}} \]
      2. *-commutative10.9%

        \[\leadsto \left(\color{blue}{y \cdot \left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right)} + t\right) \cdot \frac{1}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
      3. fma-def10.9%

        \[\leadsto \color{blue}{\mathsf{fma}\left(y, \left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616, t\right)} \cdot \frac{1}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
      4. *-commutative10.9%

        \[\leadsto \mathsf{fma}\left(y, \color{blue}{y \cdot \left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right)} + 230661.510616, t\right) \cdot \frac{1}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
      5. fma-def10.9%

        \[\leadsto \mathsf{fma}\left(y, \color{blue}{\mathsf{fma}\left(y, \left(x \cdot y + z\right) \cdot y + 27464.7644705, 230661.510616\right)}, t\right) \cdot \frac{1}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
      6. *-commutative10.9%

        \[\leadsto \mathsf{fma}\left(y, \mathsf{fma}\left(y, \color{blue}{y \cdot \left(x \cdot y + z\right)} + 27464.7644705, 230661.510616\right), t\right) \cdot \frac{1}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
      7. fma-def10.9%

        \[\leadsto \mathsf{fma}\left(y, \mathsf{fma}\left(y, \color{blue}{\mathsf{fma}\left(y, x \cdot y + z, 27464.7644705\right)}, 230661.510616\right), t\right) \cdot \frac{1}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
      8. fma-def10.9%

        \[\leadsto \mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(y, \color{blue}{\mathsf{fma}\left(x, y, z\right)}, 27464.7644705\right), 230661.510616\right), t\right) \cdot \frac{1}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
      9. *-commutative10.9%

        \[\leadsto \mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(x, y, z\right), 27464.7644705\right), 230661.510616\right), t\right) \cdot \frac{1}{\color{blue}{y \cdot \left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right)} + i} \]
      10. fma-def10.9%

        \[\leadsto \mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(x, y, z\right), 27464.7644705\right), 230661.510616\right), t\right) \cdot \frac{1}{\color{blue}{\mathsf{fma}\left(y, \left(\left(y + a\right) \cdot y + b\right) \cdot y + c, i\right)}} \]
    3. Applied egg-rr10.9%

      \[\leadsto \color{blue}{\mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(x, y, z\right), 27464.7644705\right), 230661.510616\right), t\right) \cdot \frac{1}{\mathsf{fma}\left(y, \mathsf{fma}\left(y, \mathsf{fma}\left(y, y + a, b\right), c\right), i\right)}} \]
    4. Taylor expanded in y around -inf 59.8%

      \[\leadsto \color{blue}{-1 \cdot \frac{-1 \cdot z - -1 \cdot \left(a \cdot x\right)}{y} + x} \]
    5. Step-by-step derivation
      1. +-commutative59.8%

        \[\leadsto \color{blue}{x + -1 \cdot \frac{-1 \cdot z - -1 \cdot \left(a \cdot x\right)}{y}} \]
      2. associate-*r/59.8%

        \[\leadsto x + \color{blue}{\frac{-1 \cdot \left(-1 \cdot z - -1 \cdot \left(a \cdot x\right)\right)}{y}} \]
      3. mul-1-neg59.8%

        \[\leadsto x + \frac{\color{blue}{-\left(-1 \cdot z - -1 \cdot \left(a \cdot x\right)\right)}}{y} \]
      4. *-commutative59.8%

        \[\leadsto x + \frac{-\left(\color{blue}{z \cdot -1} - -1 \cdot \left(a \cdot x\right)\right)}{y} \]
      5. fma-neg59.8%

        \[\leadsto x + \frac{-\color{blue}{\mathsf{fma}\left(z, -1, --1 \cdot \left(a \cdot x\right)\right)}}{y} \]
      6. mul-1-neg59.8%

        \[\leadsto x + \frac{-\mathsf{fma}\left(z, -1, -\color{blue}{\left(-a \cdot x\right)}\right)}{y} \]
      7. remove-double-neg59.8%

        \[\leadsto x + \frac{-\mathsf{fma}\left(z, -1, \color{blue}{a \cdot x}\right)}{y} \]
      8. *-commutative59.8%

        \[\leadsto x + \frac{-\mathsf{fma}\left(z, -1, \color{blue}{x \cdot a}\right)}{y} \]
      9. distribute-neg-frac59.8%

        \[\leadsto x + \color{blue}{\left(-\frac{\mathsf{fma}\left(z, -1, x \cdot a\right)}{y}\right)} \]
      10. unsub-neg59.8%

        \[\leadsto \color{blue}{x - \frac{\mathsf{fma}\left(z, -1, x \cdot a\right)}{y}} \]
      11. fma-udef59.8%

        \[\leadsto x - \frac{\color{blue}{z \cdot -1 + x \cdot a}}{y} \]
      12. *-commutative59.8%

        \[\leadsto x - \frac{\color{blue}{-1 \cdot z} + x \cdot a}{y} \]
      13. *-commutative59.8%

        \[\leadsto x - \frac{-1 \cdot z + \color{blue}{a \cdot x}}{y} \]
      14. +-commutative59.8%

        \[\leadsto x - \frac{\color{blue}{a \cdot x + -1 \cdot z}}{y} \]
      15. mul-1-neg59.8%

        \[\leadsto x - \frac{a \cdot x + \color{blue}{\left(-z\right)}}{y} \]
      16. unsub-neg59.8%

        \[\leadsto x - \frac{\color{blue}{a \cdot x - z}}{y} \]
    6. Simplified59.8%

      \[\leadsto \color{blue}{x - \frac{a \cdot x - z}{y}} \]

    if -5.6000000000000002e33 < y < 6.80000000000000003e-25

    1. Initial program 97.5%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around 0 48.8%

      \[\leadsto \color{blue}{\frac{t}{i} + \left(230661.510616 \cdot \frac{1}{i} - \frac{c \cdot t}{{i}^{2}}\right) \cdot y} \]
    3. Taylor expanded in i around inf 58.1%

      \[\leadsto \frac{t}{i} + \color{blue}{\frac{230661.510616}{i}} \cdot y \]
  3. Recombined 2 regimes into one program.
  4. Final simplification59.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -5.6 \cdot 10^{+33} \lor \neg \left(y \leq 6.8 \cdot 10^{-25}\right):\\ \;\;\;\;x - \frac{x \cdot a - z}{y}\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{i} + y \cdot \frac{230661.510616}{i}\\ \end{array} \]

Alternative 11: 53.5% accurate, 2.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -6.2 \cdot 10^{+38}:\\ \;\;\;\;x - \frac{a}{\frac{y}{x}}\\ \mathbf{elif}\;y \leq 2.8 \cdot 10^{-29}:\\ \;\;\;\;\frac{t}{i} + y \cdot \frac{230661.510616}{i}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (if (<= y -6.2e+38)
   (- x (/ a (/ y x)))
   (if (<= y 2.8e-29) (+ (/ t i) (* y (/ 230661.510616 i))) x)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if (y <= -6.2e+38) {
		tmp = x - (a / (y / x));
	} else if (y <= 2.8e-29) {
		tmp = (t / i) + (y * (230661.510616 / i));
	} else {
		tmp = x;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8) :: tmp
    if (y <= (-6.2d+38)) then
        tmp = x - (a / (y / x))
    else if (y <= 2.8d-29) then
        tmp = (t / i) + (y * (230661.510616d0 / i))
    else
        tmp = x
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if (y <= -6.2e+38) {
		tmp = x - (a / (y / x));
	} else if (y <= 2.8e-29) {
		tmp = (t / i) + (y * (230661.510616 / i));
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i):
	tmp = 0
	if y <= -6.2e+38:
		tmp = x - (a / (y / x))
	elif y <= 2.8e-29:
		tmp = (t / i) + (y * (230661.510616 / i))
	else:
		tmp = x
	return tmp
function code(x, y, z, t, a, b, c, i)
	tmp = 0.0
	if (y <= -6.2e+38)
		tmp = Float64(x - Float64(a / Float64(y / x)));
	elseif (y <= 2.8e-29)
		tmp = Float64(Float64(t / i) + Float64(y * Float64(230661.510616 / i)));
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i)
	tmp = 0.0;
	if (y <= -6.2e+38)
		tmp = x - (a / (y / x));
	elseif (y <= 2.8e-29)
		tmp = (t / i) + (y * (230661.510616 / i));
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -6.2e+38], N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.8e-29], N[(N[(t / i), $MachinePrecision] + N[(y * N[(230661.510616 / i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], x]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -6.2 \cdot 10^{+38}:\\
\;\;\;\;x - \frac{a}{\frac{y}{x}}\\

\mathbf{elif}\;y \leq 2.8 \cdot 10^{-29}:\\
\;\;\;\;\frac{t}{i} + y \cdot \frac{230661.510616}{i}\\

\mathbf{else}:\\
\;\;\;\;x\\


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

    1. Initial program 2.4%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in x around inf 2.5%

      \[\leadsto \frac{\left(\left(\color{blue}{{y}^{2} \cdot x} + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    3. Step-by-step derivation
      1. *-commutative2.5%

        \[\leadsto \frac{\left(\left(\color{blue}{x \cdot {y}^{2}} + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
      2. unpow22.5%

        \[\leadsto \frac{\left(\left(x \cdot \color{blue}{\left(y \cdot y\right)} + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    4. Simplified2.5%

      \[\leadsto \frac{\left(\left(\color{blue}{x \cdot \left(y \cdot y\right)} + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    5. Taylor expanded in y around inf 55.7%

      \[\leadsto \color{blue}{-1 \cdot \frac{a \cdot x}{y} + x} \]
    6. Step-by-step derivation
      1. +-commutative55.7%

        \[\leadsto \color{blue}{x + -1 \cdot \frac{a \cdot x}{y}} \]
      2. mul-1-neg55.7%

        \[\leadsto x + \color{blue}{\left(-\frac{a \cdot x}{y}\right)} \]
      3. sub-neg55.7%

        \[\leadsto \color{blue}{x - \frac{a \cdot x}{y}} \]
      4. associate-/l*58.9%

        \[\leadsto x - \color{blue}{\frac{a}{\frac{y}{x}}} \]
    7. Simplified58.9%

      \[\leadsto \color{blue}{x - \frac{a}{\frac{y}{x}}} \]

    if -6.20000000000000035e38 < y < 2.8000000000000002e-29

    1. Initial program 97.5%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around 0 49.1%

      \[\leadsto \color{blue}{\frac{t}{i} + \left(230661.510616 \cdot \frac{1}{i} - \frac{c \cdot t}{{i}^{2}}\right) \cdot y} \]
    3. Taylor expanded in i around inf 58.6%

      \[\leadsto \frac{t}{i} + \color{blue}{\frac{230661.510616}{i}} \cdot y \]

    if 2.8000000000000002e-29 < y

    1. Initial program 19.0%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around inf 47.2%

      \[\leadsto \color{blue}{x} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification55.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -6.2 \cdot 10^{+38}:\\ \;\;\;\;x - \frac{a}{\frac{y}{x}}\\ \mathbf{elif}\;y \leq 2.8 \cdot 10^{-29}:\\ \;\;\;\;\frac{t}{i} + y \cdot \frac{230661.510616}{i}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 12: 53.5% accurate, 3.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -4.9 \cdot 10^{+33}:\\ \;\;\;\;x - \frac{a}{\frac{y}{x}}\\ \mathbf{elif}\;y \leq 2.8 \cdot 10^{-29}:\\ \;\;\;\;\frac{t + y \cdot 230661.510616}{i}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (if (<= y -4.9e+33)
   (- x (/ a (/ y x)))
   (if (<= y 2.8e-29) (/ (+ t (* y 230661.510616)) i) x)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if (y <= -4.9e+33) {
		tmp = x - (a / (y / x));
	} else if (y <= 2.8e-29) {
		tmp = (t + (y * 230661.510616)) / i;
	} else {
		tmp = x;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8) :: tmp
    if (y <= (-4.9d+33)) then
        tmp = x - (a / (y / x))
    else if (y <= 2.8d-29) then
        tmp = (t + (y * 230661.510616d0)) / i
    else
        tmp = x
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if (y <= -4.9e+33) {
		tmp = x - (a / (y / x));
	} else if (y <= 2.8e-29) {
		tmp = (t + (y * 230661.510616)) / i;
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i):
	tmp = 0
	if y <= -4.9e+33:
		tmp = x - (a / (y / x))
	elif y <= 2.8e-29:
		tmp = (t + (y * 230661.510616)) / i
	else:
		tmp = x
	return tmp
function code(x, y, z, t, a, b, c, i)
	tmp = 0.0
	if (y <= -4.9e+33)
		tmp = Float64(x - Float64(a / Float64(y / x)));
	elseif (y <= 2.8e-29)
		tmp = Float64(Float64(t + Float64(y * 230661.510616)) / i);
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i)
	tmp = 0.0;
	if (y <= -4.9e+33)
		tmp = x - (a / (y / x));
	elseif (y <= 2.8e-29)
		tmp = (t + (y * 230661.510616)) / i;
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -4.9e+33], N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.8e-29], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / i), $MachinePrecision], x]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.9 \cdot 10^{+33}:\\
\;\;\;\;x - \frac{a}{\frac{y}{x}}\\

\mathbf{elif}\;y \leq 2.8 \cdot 10^{-29}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{i}\\

\mathbf{else}:\\
\;\;\;\;x\\


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

    1. Initial program 2.4%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in x around inf 2.5%

      \[\leadsto \frac{\left(\left(\color{blue}{{y}^{2} \cdot x} + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    3. Step-by-step derivation
      1. *-commutative2.5%

        \[\leadsto \frac{\left(\left(\color{blue}{x \cdot {y}^{2}} + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
      2. unpow22.5%

        \[\leadsto \frac{\left(\left(x \cdot \color{blue}{\left(y \cdot y\right)} + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    4. Simplified2.5%

      \[\leadsto \frac{\left(\left(\color{blue}{x \cdot \left(y \cdot y\right)} + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    5. Taylor expanded in y around inf 55.7%

      \[\leadsto \color{blue}{-1 \cdot \frac{a \cdot x}{y} + x} \]
    6. Step-by-step derivation
      1. +-commutative55.7%

        \[\leadsto \color{blue}{x + -1 \cdot \frac{a \cdot x}{y}} \]
      2. mul-1-neg55.7%

        \[\leadsto x + \color{blue}{\left(-\frac{a \cdot x}{y}\right)} \]
      3. sub-neg55.7%

        \[\leadsto \color{blue}{x - \frac{a \cdot x}{y}} \]
      4. associate-/l*58.9%

        \[\leadsto x - \color{blue}{\frac{a}{\frac{y}{x}}} \]
    7. Simplified58.9%

      \[\leadsto \color{blue}{x - \frac{a}{\frac{y}{x}}} \]

    if -4.90000000000000014e33 < y < 2.8000000000000002e-29

    1. Initial program 97.5%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around 0 89.2%

      \[\leadsto \frac{\color{blue}{230661.510616 \cdot y} + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    3. Step-by-step derivation
      1. *-commutative89.2%

        \[\leadsto \frac{\color{blue}{y \cdot 230661.510616} + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    4. Simplified89.2%

      \[\leadsto \frac{\color{blue}{y \cdot 230661.510616} + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    5. Taylor expanded in i around inf 58.6%

      \[\leadsto \color{blue}{\frac{t + 230661.510616 \cdot y}{i}} \]

    if 2.8000000000000002e-29 < y

    1. Initial program 19.0%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around inf 47.2%

      \[\leadsto \color{blue}{x} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification55.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -4.9 \cdot 10^{+33}:\\ \;\;\;\;x - \frac{a}{\frac{y}{x}}\\ \mathbf{elif}\;y \leq 2.8 \cdot 10^{-29}:\\ \;\;\;\;\frac{t + y \cdot 230661.510616}{i}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 13: 48.8% accurate, 3.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -6.2 \cdot 10^{+44}:\\ \;\;\;\;x\\ \mathbf{elif}\;y \leq -6.9 \cdot 10^{-147}:\\ \;\;\;\;\frac{t}{y \cdot c}\\ \mathbf{elif}\;y \leq 2.8 \cdot 10^{-29}:\\ \;\;\;\;\frac{t}{i}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (if (<= y -6.2e+44)
   x
   (if (<= y -6.9e-147) (/ t (* y c)) (if (<= y 2.8e-29) (/ t i) x))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if (y <= -6.2e+44) {
		tmp = x;
	} else if (y <= -6.9e-147) {
		tmp = t / (y * c);
	} else if (y <= 2.8e-29) {
		tmp = t / i;
	} else {
		tmp = x;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8) :: tmp
    if (y <= (-6.2d+44)) then
        tmp = x
    else if (y <= (-6.9d-147)) then
        tmp = t / (y * c)
    else if (y <= 2.8d-29) then
        tmp = t / i
    else
        tmp = x
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if (y <= -6.2e+44) {
		tmp = x;
	} else if (y <= -6.9e-147) {
		tmp = t / (y * c);
	} else if (y <= 2.8e-29) {
		tmp = t / i;
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i):
	tmp = 0
	if y <= -6.2e+44:
		tmp = x
	elif y <= -6.9e-147:
		tmp = t / (y * c)
	elif y <= 2.8e-29:
		tmp = t / i
	else:
		tmp = x
	return tmp
function code(x, y, z, t, a, b, c, i)
	tmp = 0.0
	if (y <= -6.2e+44)
		tmp = x;
	elseif (y <= -6.9e-147)
		tmp = Float64(t / Float64(y * c));
	elseif (y <= 2.8e-29)
		tmp = Float64(t / i);
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i)
	tmp = 0.0;
	if (y <= -6.2e+44)
		tmp = x;
	elseif (y <= -6.9e-147)
		tmp = t / (y * c);
	elseif (y <= 2.8e-29)
		tmp = t / i;
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -6.2e+44], x, If[LessEqual[y, -6.9e-147], N[(t / N[(y * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.8e-29], N[(t / i), $MachinePrecision], x]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -6.2 \cdot 10^{+44}:\\
\;\;\;\;x\\

\mathbf{elif}\;y \leq -6.9 \cdot 10^{-147}:\\
\;\;\;\;\frac{t}{y \cdot c}\\

\mathbf{elif}\;y \leq 2.8 \cdot 10^{-29}:\\
\;\;\;\;\frac{t}{i}\\

\mathbf{else}:\\
\;\;\;\;x\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -6.19999999999999991e44 or 2.8000000000000002e-29 < y

    1. Initial program 10.9%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around inf 52.6%

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

    if -6.19999999999999991e44 < y < -6.89999999999999999e-147

    1. Initial program 92.7%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in c around inf 38.0%

      \[\leadsto \color{blue}{\frac{y \cdot \left(230661.510616 + y \cdot \left(27464.7644705 + \left(y \cdot x + z\right) \cdot y\right)\right) + t}{c \cdot y}} \]
    3. Taylor expanded in y around 0 31.0%

      \[\leadsto \color{blue}{\frac{t}{c \cdot y}} \]

    if -6.89999999999999999e-147 < y < 2.8000000000000002e-29

    1. Initial program 99.9%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around 0 65.9%

      \[\leadsto \color{blue}{\frac{t}{i}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification53.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -6.2 \cdot 10^{+44}:\\ \;\;\;\;x\\ \mathbf{elif}\;y \leq -6.9 \cdot 10^{-147}:\\ \;\;\;\;\frac{t}{y \cdot c}\\ \mathbf{elif}\;y \leq 2.8 \cdot 10^{-29}:\\ \;\;\;\;\frac{t}{i}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 14: 48.7% accurate, 3.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -3.3 \cdot 10^{+53}:\\ \;\;\;\;x - \frac{a}{\frac{y}{x}}\\ \mathbf{elif}\;y \leq -3.2 \cdot 10^{-146}:\\ \;\;\;\;\frac{t}{y \cdot c}\\ \mathbf{elif}\;y \leq 2.8 \cdot 10^{-29}:\\ \;\;\;\;\frac{t}{i}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (if (<= y -3.3e+53)
   (- x (/ a (/ y x)))
   (if (<= y -3.2e-146) (/ t (* y c)) (if (<= y 2.8e-29) (/ t i) x))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if (y <= -3.3e+53) {
		tmp = x - (a / (y / x));
	} else if (y <= -3.2e-146) {
		tmp = t / (y * c);
	} else if (y <= 2.8e-29) {
		tmp = t / i;
	} else {
		tmp = x;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8) :: tmp
    if (y <= (-3.3d+53)) then
        tmp = x - (a / (y / x))
    else if (y <= (-3.2d-146)) then
        tmp = t / (y * c)
    else if (y <= 2.8d-29) then
        tmp = t / i
    else
        tmp = x
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if (y <= -3.3e+53) {
		tmp = x - (a / (y / x));
	} else if (y <= -3.2e-146) {
		tmp = t / (y * c);
	} else if (y <= 2.8e-29) {
		tmp = t / i;
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i):
	tmp = 0
	if y <= -3.3e+53:
		tmp = x - (a / (y / x))
	elif y <= -3.2e-146:
		tmp = t / (y * c)
	elif y <= 2.8e-29:
		tmp = t / i
	else:
		tmp = x
	return tmp
function code(x, y, z, t, a, b, c, i)
	tmp = 0.0
	if (y <= -3.3e+53)
		tmp = Float64(x - Float64(a / Float64(y / x)));
	elseif (y <= -3.2e-146)
		tmp = Float64(t / Float64(y * c));
	elseif (y <= 2.8e-29)
		tmp = Float64(t / i);
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i)
	tmp = 0.0;
	if (y <= -3.3e+53)
		tmp = x - (a / (y / x));
	elseif (y <= -3.2e-146)
		tmp = t / (y * c);
	elseif (y <= 2.8e-29)
		tmp = t / i;
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -3.3e+53], N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -3.2e-146], N[(t / N[(y * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.8e-29], N[(t / i), $MachinePrecision], x]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.3 \cdot 10^{+53}:\\
\;\;\;\;x - \frac{a}{\frac{y}{x}}\\

\mathbf{elif}\;y \leq -3.2 \cdot 10^{-146}:\\
\;\;\;\;\frac{t}{y \cdot c}\\

\mathbf{elif}\;y \leq 2.8 \cdot 10^{-29}:\\
\;\;\;\;\frac{t}{i}\\

\mathbf{else}:\\
\;\;\;\;x\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if y < -3.3000000000000002e53

    1. Initial program 0.6%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in x around inf 0.7%

      \[\leadsto \frac{\left(\left(\color{blue}{{y}^{2} \cdot x} + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    3. Step-by-step derivation
      1. *-commutative0.7%

        \[\leadsto \frac{\left(\left(\color{blue}{x \cdot {y}^{2}} + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
      2. unpow20.7%

        \[\leadsto \frac{\left(\left(x \cdot \color{blue}{\left(y \cdot y\right)} + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    4. Simplified0.7%

      \[\leadsto \frac{\left(\left(\color{blue}{x \cdot \left(y \cdot y\right)} + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    5. Taylor expanded in y around inf 57.7%

      \[\leadsto \color{blue}{-1 \cdot \frac{a \cdot x}{y} + x} \]
    6. Step-by-step derivation
      1. +-commutative57.7%

        \[\leadsto \color{blue}{x + -1 \cdot \frac{a \cdot x}{y}} \]
      2. mul-1-neg57.7%

        \[\leadsto x + \color{blue}{\left(-\frac{a \cdot x}{y}\right)} \]
      3. sub-neg57.7%

        \[\leadsto \color{blue}{x - \frac{a \cdot x}{y}} \]
      4. associate-/l*60.9%

        \[\leadsto x - \color{blue}{\frac{a}{\frac{y}{x}}} \]
    7. Simplified60.9%

      \[\leadsto \color{blue}{x - \frac{a}{\frac{y}{x}}} \]

    if -3.3000000000000002e53 < y < -3.1999999999999999e-146

    1. Initial program 90.6%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in c around inf 37.2%

      \[\leadsto \color{blue}{\frac{y \cdot \left(230661.510616 + y \cdot \left(27464.7644705 + \left(y \cdot x + z\right) \cdot y\right)\right) + t}{c \cdot y}} \]
    3. Taylor expanded in y around 0 30.3%

      \[\leadsto \color{blue}{\frac{t}{c \cdot y}} \]

    if -3.1999999999999999e-146 < y < 2.8000000000000002e-29

    1. Initial program 99.9%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around 0 65.9%

      \[\leadsto \color{blue}{\frac{t}{i}} \]

    if 2.8000000000000002e-29 < y

    1. Initial program 19.0%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around inf 47.2%

      \[\leadsto \color{blue}{x} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification53.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -3.3 \cdot 10^{+53}:\\ \;\;\;\;x - \frac{a}{\frac{y}{x}}\\ \mathbf{elif}\;y \leq -3.2 \cdot 10^{-146}:\\ \;\;\;\;\frac{t}{y \cdot c}\\ \mathbf{elif}\;y \leq 2.8 \cdot 10^{-29}:\\ \;\;\;\;\frac{t}{i}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 15: 50.3% accurate, 4.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -1150:\\ \;\;\;\;x\\ \mathbf{elif}\;y \leq 2.8 \cdot 10^{-29}:\\ \;\;\;\;\frac{t}{i}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (if (<= y -1150.0) x (if (<= y 2.8e-29) (/ t i) x)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if (y <= -1150.0) {
		tmp = x;
	} else if (y <= 2.8e-29) {
		tmp = t / i;
	} else {
		tmp = x;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8) :: tmp
    if (y <= (-1150.0d0)) then
        tmp = x
    else if (y <= 2.8d-29) then
        tmp = t / i
    else
        tmp = x
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if (y <= -1150.0) {
		tmp = x;
	} else if (y <= 2.8e-29) {
		tmp = t / i;
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i):
	tmp = 0
	if y <= -1150.0:
		tmp = x
	elif y <= 2.8e-29:
		tmp = t / i
	else:
		tmp = x
	return tmp
function code(x, y, z, t, a, b, c, i)
	tmp = 0.0
	if (y <= -1150.0)
		tmp = x;
	elseif (y <= 2.8e-29)
		tmp = Float64(t / i);
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i)
	tmp = 0.0;
	if (y <= -1150.0)
		tmp = x;
	elseif (y <= 2.8e-29)
		tmp = t / i;
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -1150.0], x, If[LessEqual[y, 2.8e-29], N[(t / i), $MachinePrecision], x]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -1150:\\
\;\;\;\;x\\

\mathbf{elif}\;y \leq 2.8 \cdot 10^{-29}:\\
\;\;\;\;\frac{t}{i}\\

\mathbf{else}:\\
\;\;\;\;x\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -1150 or 2.8000000000000002e-29 < y

    1. Initial program 14.8%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around inf 49.3%

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

    if -1150 < y < 2.8000000000000002e-29

    1. Initial program 99.7%

      \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
    2. Taylor expanded in y around 0 53.9%

      \[\leadsto \color{blue}{\frac{t}{i}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification51.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -1150:\\ \;\;\;\;x\\ \mathbf{elif}\;y \leq 2.8 \cdot 10^{-29}:\\ \;\;\;\;\frac{t}{i}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 16: 25.7% accurate, 33.0× speedup?

\[\begin{array}{l} \\ x \end{array} \]
(FPCore (x y z t a b c i) :precision binary64 x)
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	return x;
}
real(8) function code(x, y, z, t, a, b, c, i)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    code = x
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	return x;
}
def code(x, y, z, t, a, b, c, i):
	return x
function code(x, y, z, t, a, b, c, i)
	return x
end
function tmp = code(x, y, z, t, a, b, c, i)
	tmp = x;
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := x
\begin{array}{l}

\\
x
\end{array}
Derivation
  1. Initial program 55.3%

    \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i} \]
  2. Taylor expanded in y around inf 27.3%

    \[\leadsto \color{blue}{x} \]
  3. Final simplification27.3%

    \[\leadsto x \]

Reproduce

?
herbie shell --seed 2023181 
(FPCore (x y z t a b c i)
  :name "Numeric.SpecFunctions:logGamma from math-functions-0.1.5.2"
  :precision binary64
  (/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)))