Diagrams.Solve.Tridiagonal:solveCyclicTriDiagonal from diagrams-solve-0.1, B

Percentage Accurate: 74.9% → 88.8%
Time: 18.3s
Alternatives: 17
Speedup: 0.6×

Specification

?
\[\begin{array}{l} \\ \frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (/ (+ x (/ (* y z) t)) (+ (+ a 1.0) (/ (* y b) t))))
double code(double x, double y, double z, double t, double a, double b) {
	return (x + ((y * z) / t)) / ((a + 1.0) + ((y * b) / t));
}
real(8) function code(x, y, z, t, a, b)
    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
    code = (x + ((y * z) / t)) / ((a + 1.0d0) + ((y * b) / t))
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	return (x + ((y * z) / t)) / ((a + 1.0) + ((y * b) / t));
}
def code(x, y, z, t, a, b):
	return (x + ((y * z) / t)) / ((a + 1.0) + ((y * b) / t))
function code(x, y, z, t, a, b)
	return Float64(Float64(x + Float64(Float64(y * z) / t)) / Float64(Float64(a + 1.0) + Float64(Float64(y * b) / t)))
end
function tmp = code(x, y, z, t, a, b)
	tmp = (x + ((y * z) / t)) / ((a + 1.0) + ((y * b) / t));
end
code[x_, y_, z_, t_, a_, b_] := N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / N[(N[(a + 1.0), $MachinePrecision] + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}}
\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 17 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: 74.9% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (/ (+ x (/ (* y z) t)) (+ (+ a 1.0) (/ (* y b) t))))
double code(double x, double y, double z, double t, double a, double b) {
	return (x + ((y * z) / t)) / ((a + 1.0) + ((y * b) / t));
}
real(8) function code(x, y, z, t, a, b)
    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
    code = (x + ((y * z) / t)) / ((a + 1.0d0) + ((y * b) / t))
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	return (x + ((y * z) / t)) / ((a + 1.0) + ((y * b) / t));
}
def code(x, y, z, t, a, b):
	return (x + ((y * z) / t)) / ((a + 1.0) + ((y * b) / t))
function code(x, y, z, t, a, b)
	return Float64(Float64(x + Float64(Float64(y * z) / t)) / Float64(Float64(a + 1.0) + Float64(Float64(y * b) / t)))
end
function tmp = code(x, y, z, t, a, b)
	tmp = (x + ((y * z) / t)) / ((a + 1.0) + ((y * b) / t));
end
code[x_, y_, z_, t_, a_, b_] := N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / N[(N[(a + 1.0), $MachinePrecision] + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}}
\end{array}

Alternative 1: 88.8% accurate, 0.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}}\\ \mathbf{if}\;t\_1 \leq -\infty:\\ \;\;\;\;\frac{y \cdot \frac{z}{1 + \mathsf{fma}\left(y, \frac{b}{t}, a\right)}}{t}\\ \mathbf{elif}\;t\_1 \leq -4 \cdot 10^{-298}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_1 \leq 0:\\ \;\;\;\;\frac{t}{y} \cdot \frac{\mathsf{fma}\left(y, \frac{z}{t}, x\right)}{b}\\ \mathbf{elif}\;t\_1 \leq 2 \cdot 10^{+284}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (/ (+ x (/ (* y z) t)) (+ (+ a 1.0) (/ (* y b) t)))))
   (if (<= t_1 (- INFINITY))
     (/ (* y (/ z (+ 1.0 (fma y (/ b t) a)))) t)
     (if (<= t_1 -4e-298)
       t_1
       (if (<= t_1 0.0)
         (* (/ t y) (/ (fma y (/ z t) x) b))
         (if (<= t_1 2e+284) t_1 (/ z b)))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = (x + ((y * z) / t)) / ((a + 1.0) + ((y * b) / t));
	double tmp;
	if (t_1 <= -((double) INFINITY)) {
		tmp = (y * (z / (1.0 + fma(y, (b / t), a)))) / t;
	} else if (t_1 <= -4e-298) {
		tmp = t_1;
	} else if (t_1 <= 0.0) {
		tmp = (t / y) * (fma(y, (z / t), x) / b);
	} else if (t_1 <= 2e+284) {
		tmp = t_1;
	} else {
		tmp = z / b;
	}
	return tmp;
}
function code(x, y, z, t, a, b)
	t_1 = Float64(Float64(x + Float64(Float64(y * z) / t)) / Float64(Float64(a + 1.0) + Float64(Float64(y * b) / t)))
	tmp = 0.0
	if (t_1 <= Float64(-Inf))
		tmp = Float64(Float64(y * Float64(z / Float64(1.0 + fma(y, Float64(b / t), a)))) / t);
	elseif (t_1 <= -4e-298)
		tmp = t_1;
	elseif (t_1 <= 0.0)
		tmp = Float64(Float64(t / y) * Float64(fma(y, Float64(z / t), x) / b));
	elseif (t_1 <= 2e+284)
		tmp = t_1;
	else
		tmp = Float64(z / b);
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / N[(N[(a + 1.0), $MachinePrecision] + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, (-Infinity)], N[(N[(y * N[(z / N[(1.0 + N[(y * N[(b / t), $MachinePrecision] + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[t$95$1, -4e-298], t$95$1, If[LessEqual[t$95$1, 0.0], N[(N[(t / y), $MachinePrecision] * N[(N[(y * N[(z / t), $MachinePrecision] + x), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 2e+284], t$95$1, N[(z / b), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}}\\
\mathbf{if}\;t\_1 \leq -\infty:\\
\;\;\;\;\frac{y \cdot \frac{z}{1 + \mathsf{fma}\left(y, \frac{b}{t}, a\right)}}{t}\\

\mathbf{elif}\;t\_1 \leq -4 \cdot 10^{-298}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t\_1 \leq 0:\\
\;\;\;\;\frac{t}{y} \cdot \frac{\mathsf{fma}\left(y, \frac{z}{t}, x\right)}{b}\\

\mathbf{elif}\;t\_1 \leq 2 \cdot 10^{+284}:\\
\;\;\;\;t\_1\\

\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < -inf.0

    1. Initial program 33.1%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*52.1%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified52.2%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in x around 0 61.1%

      \[\leadsto \color{blue}{\frac{y \cdot z}{t \cdot \left(1 + \left(a + \frac{b \cdot y}{t}\right)\right)}} \]
    6. Step-by-step derivation
      1. times-frac89.6%

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

        \[\leadsto \frac{y}{t} \cdot \frac{z}{1 + \left(a + \color{blue}{\frac{b}{t} \cdot y}\right)} \]
      3. *-commutative89.9%

        \[\leadsto \frac{y}{t} \cdot \frac{z}{1 + \left(a + \color{blue}{y \cdot \frac{b}{t}}\right)} \]
    7. Simplified89.9%

      \[\leadsto \color{blue}{\frac{y}{t} \cdot \frac{z}{1 + \left(a + y \cdot \frac{b}{t}\right)}} \]
    8. Step-by-step derivation
      1. associate-*l/99.4%

        \[\leadsto \color{blue}{\frac{y \cdot \frac{z}{1 + \left(a + y \cdot \frac{b}{t}\right)}}{t}} \]
      2. +-commutative99.4%

        \[\leadsto \frac{y \cdot \frac{z}{1 + \color{blue}{\left(y \cdot \frac{b}{t} + a\right)}}}{t} \]
      3. fma-define99.4%

        \[\leadsto \frac{y \cdot \frac{z}{1 + \color{blue}{\mathsf{fma}\left(y, \frac{b}{t}, a\right)}}}{t} \]
    9. Applied egg-rr99.4%

      \[\leadsto \color{blue}{\frac{y \cdot \frac{z}{1 + \mathsf{fma}\left(y, \frac{b}{t}, a\right)}}{t}} \]

    if -inf.0 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < -3.99999999999999965e-298 or 0.0 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < 2.00000000000000016e284

    1. Initial program 99.7%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Add Preprocessing

    if -3.99999999999999965e-298 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < 0.0

    1. Initial program 49.9%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*49.7%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified64.5%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in a around 0 31.5%

      \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\color{blue}{1 + \frac{b \cdot y}{t}}} \]
    6. Step-by-step derivation
      1. associate-*r/46.4%

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{1 + \color{blue}{b \cdot \frac{y}{t}}} \]
      2. *-commutative46.4%

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{1 + \color{blue}{\frac{y}{t} \cdot b}} \]
    7. Applied egg-rr46.4%

      \[\leadsto \frac{x + y \cdot \frac{z}{t}}{1 + \color{blue}{\frac{y}{t} \cdot b}} \]
    8. Taylor expanded in b around inf 57.0%

      \[\leadsto \color{blue}{\frac{t \cdot \left(x + \frac{y \cdot z}{t}\right)}{b \cdot y}} \]
    9. Step-by-step derivation
      1. +-commutative57.0%

        \[\leadsto \frac{t \cdot \color{blue}{\left(\frac{y \cdot z}{t} + x\right)}}{b \cdot y} \]
      2. *-commutative57.0%

        \[\leadsto \frac{t \cdot \left(\frac{\color{blue}{z \cdot y}}{t} + x\right)}{b \cdot y} \]
      3. associate-*r/46.6%

        \[\leadsto \frac{t \cdot \left(\color{blue}{z \cdot \frac{y}{t}} + x\right)}{b \cdot y} \]
      4. fma-undefine46.6%

        \[\leadsto \frac{t \cdot \color{blue}{\mathsf{fma}\left(z, \frac{y}{t}, x\right)}}{b \cdot y} \]
      5. *-commutative46.6%

        \[\leadsto \frac{t \cdot \mathsf{fma}\left(z, \frac{y}{t}, x\right)}{\color{blue}{y \cdot b}} \]
      6. times-frac73.9%

        \[\leadsto \color{blue}{\frac{t}{y} \cdot \frac{\mathsf{fma}\left(z, \frac{y}{t}, x\right)}{b}} \]
      7. fma-undefine73.9%

        \[\leadsto \frac{t}{y} \cdot \frac{\color{blue}{z \cdot \frac{y}{t} + x}}{b} \]
      8. associate-*r/77.5%

        \[\leadsto \frac{t}{y} \cdot \frac{\color{blue}{\frac{z \cdot y}{t}} + x}{b} \]
      9. *-commutative77.5%

        \[\leadsto \frac{t}{y} \cdot \frac{\frac{\color{blue}{y \cdot z}}{t} + x}{b} \]
      10. associate-/l*72.3%

        \[\leadsto \frac{t}{y} \cdot \frac{\color{blue}{y \cdot \frac{z}{t}} + x}{b} \]
      11. fma-undefine72.3%

        \[\leadsto \frac{t}{y} \cdot \frac{\color{blue}{\mathsf{fma}\left(y, \frac{z}{t}, x\right)}}{b} \]
    10. Simplified72.3%

      \[\leadsto \color{blue}{\frac{t}{y} \cdot \frac{\mathsf{fma}\left(y, \frac{z}{t}, x\right)}{b}} \]

    if 2.00000000000000016e284 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t)))

    1. Initial program 15.9%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*19.1%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified38.5%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in y around inf 85.5%

      \[\leadsto \color{blue}{\frac{z}{b}} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification93.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \leq -\infty:\\ \;\;\;\;\frac{y \cdot \frac{z}{1 + \mathsf{fma}\left(y, \frac{b}{t}, a\right)}}{t}\\ \mathbf{elif}\;\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \leq -4 \cdot 10^{-298}:\\ \;\;\;\;\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}}\\ \mathbf{elif}\;\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \leq 0:\\ \;\;\;\;\frac{t}{y} \cdot \frac{\mathsf{fma}\left(y, \frac{z}{t}, x\right)}{b}\\ \mathbf{elif}\;\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \leq 2 \cdot 10^{+284}:\\ \;\;\;\;\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 88.8% accurate, 0.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}}\\ \mathbf{if}\;t\_1 \leq -5 \cdot 10^{+293}:\\ \;\;\;\;\frac{y}{t} \cdot \frac{z}{1 + \left(a + y \cdot \frac{b}{t}\right)}\\ \mathbf{elif}\;t\_1 \leq -4 \cdot 10^{-298}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_1 \leq 0:\\ \;\;\;\;\frac{t}{y} \cdot \frac{\mathsf{fma}\left(y, \frac{z}{t}, x\right)}{b}\\ \mathbf{elif}\;t\_1 \leq 2 \cdot 10^{+284}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (/ (+ x (/ (* y z) t)) (+ (+ a 1.0) (/ (* y b) t)))))
   (if (<= t_1 -5e+293)
     (* (/ y t) (/ z (+ 1.0 (+ a (* y (/ b t))))))
     (if (<= t_1 -4e-298)
       t_1
       (if (<= t_1 0.0)
         (* (/ t y) (/ (fma y (/ z t) x) b))
         (if (<= t_1 2e+284) t_1 (/ z b)))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = (x + ((y * z) / t)) / ((a + 1.0) + ((y * b) / t));
	double tmp;
	if (t_1 <= -5e+293) {
		tmp = (y / t) * (z / (1.0 + (a + (y * (b / t)))));
	} else if (t_1 <= -4e-298) {
		tmp = t_1;
	} else if (t_1 <= 0.0) {
		tmp = (t / y) * (fma(y, (z / t), x) / b);
	} else if (t_1 <= 2e+284) {
		tmp = t_1;
	} else {
		tmp = z / b;
	}
	return tmp;
}
function code(x, y, z, t, a, b)
	t_1 = Float64(Float64(x + Float64(Float64(y * z) / t)) / Float64(Float64(a + 1.0) + Float64(Float64(y * b) / t)))
	tmp = 0.0
	if (t_1 <= -5e+293)
		tmp = Float64(Float64(y / t) * Float64(z / Float64(1.0 + Float64(a + Float64(y * Float64(b / t))))));
	elseif (t_1 <= -4e-298)
		tmp = t_1;
	elseif (t_1 <= 0.0)
		tmp = Float64(Float64(t / y) * Float64(fma(y, Float64(z / t), x) / b));
	elseif (t_1 <= 2e+284)
		tmp = t_1;
	else
		tmp = Float64(z / b);
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / N[(N[(a + 1.0), $MachinePrecision] + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, -5e+293], N[(N[(y / t), $MachinePrecision] * N[(z / N[(1.0 + N[(a + N[(y * N[(b / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, -4e-298], t$95$1, If[LessEqual[t$95$1, 0.0], N[(N[(t / y), $MachinePrecision] * N[(N[(y * N[(z / t), $MachinePrecision] + x), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 2e+284], t$95$1, N[(z / b), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}}\\
\mathbf{if}\;t\_1 \leq -5 \cdot 10^{+293}:\\
\;\;\;\;\frac{y}{t} \cdot \frac{z}{1 + \left(a + y \cdot \frac{b}{t}\right)}\\

\mathbf{elif}\;t\_1 \leq -4 \cdot 10^{-298}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t\_1 \leq 0:\\
\;\;\;\;\frac{t}{y} \cdot \frac{\mathsf{fma}\left(y, \frac{z}{t}, x\right)}{b}\\

\mathbf{elif}\;t\_1 \leq 2 \cdot 10^{+284}:\\
\;\;\;\;t\_1\\

\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < -5.00000000000000033e293

    1. Initial program 39.0%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*56.3%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified56.4%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in x around 0 64.5%

      \[\leadsto \color{blue}{\frac{y \cdot z}{t \cdot \left(1 + \left(a + \frac{b \cdot y}{t}\right)\right)}} \]
    6. Step-by-step derivation
      1. times-frac90.6%

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

        \[\leadsto \frac{y}{t} \cdot \frac{z}{1 + \left(a + \color{blue}{\frac{b}{t} \cdot y}\right)} \]
      3. *-commutative90.8%

        \[\leadsto \frac{y}{t} \cdot \frac{z}{1 + \left(a + \color{blue}{y \cdot \frac{b}{t}}\right)} \]
    7. Simplified90.8%

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

    if -5.00000000000000033e293 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < -3.99999999999999965e-298 or 0.0 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < 2.00000000000000016e284

    1. Initial program 99.7%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Add Preprocessing

    if -3.99999999999999965e-298 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < 0.0

    1. Initial program 49.9%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*49.7%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified64.5%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in a around 0 31.5%

      \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\color{blue}{1 + \frac{b \cdot y}{t}}} \]
    6. Step-by-step derivation
      1. associate-*r/46.4%

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{1 + \color{blue}{b \cdot \frac{y}{t}}} \]
      2. *-commutative46.4%

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{1 + \color{blue}{\frac{y}{t} \cdot b}} \]
    7. Applied egg-rr46.4%

      \[\leadsto \frac{x + y \cdot \frac{z}{t}}{1 + \color{blue}{\frac{y}{t} \cdot b}} \]
    8. Taylor expanded in b around inf 57.0%

      \[\leadsto \color{blue}{\frac{t \cdot \left(x + \frac{y \cdot z}{t}\right)}{b \cdot y}} \]
    9. Step-by-step derivation
      1. +-commutative57.0%

        \[\leadsto \frac{t \cdot \color{blue}{\left(\frac{y \cdot z}{t} + x\right)}}{b \cdot y} \]
      2. *-commutative57.0%

        \[\leadsto \frac{t \cdot \left(\frac{\color{blue}{z \cdot y}}{t} + x\right)}{b \cdot y} \]
      3. associate-*r/46.6%

        \[\leadsto \frac{t \cdot \left(\color{blue}{z \cdot \frac{y}{t}} + x\right)}{b \cdot y} \]
      4. fma-undefine46.6%

        \[\leadsto \frac{t \cdot \color{blue}{\mathsf{fma}\left(z, \frac{y}{t}, x\right)}}{b \cdot y} \]
      5. *-commutative46.6%

        \[\leadsto \frac{t \cdot \mathsf{fma}\left(z, \frac{y}{t}, x\right)}{\color{blue}{y \cdot b}} \]
      6. times-frac73.9%

        \[\leadsto \color{blue}{\frac{t}{y} \cdot \frac{\mathsf{fma}\left(z, \frac{y}{t}, x\right)}{b}} \]
      7. fma-undefine73.9%

        \[\leadsto \frac{t}{y} \cdot \frac{\color{blue}{z \cdot \frac{y}{t} + x}}{b} \]
      8. associate-*r/77.5%

        \[\leadsto \frac{t}{y} \cdot \frac{\color{blue}{\frac{z \cdot y}{t}} + x}{b} \]
      9. *-commutative77.5%

        \[\leadsto \frac{t}{y} \cdot \frac{\frac{\color{blue}{y \cdot z}}{t} + x}{b} \]
      10. associate-/l*72.3%

        \[\leadsto \frac{t}{y} \cdot \frac{\color{blue}{y \cdot \frac{z}{t}} + x}{b} \]
      11. fma-undefine72.3%

        \[\leadsto \frac{t}{y} \cdot \frac{\color{blue}{\mathsf{fma}\left(y, \frac{z}{t}, x\right)}}{b} \]
    10. Simplified72.3%

      \[\leadsto \color{blue}{\frac{t}{y} \cdot \frac{\mathsf{fma}\left(y, \frac{z}{t}, x\right)}{b}} \]

    if 2.00000000000000016e284 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t)))

    1. Initial program 15.9%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*19.1%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified38.5%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in y around inf 85.5%

      \[\leadsto \color{blue}{\frac{z}{b}} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification93.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \leq -5 \cdot 10^{+293}:\\ \;\;\;\;\frac{y}{t} \cdot \frac{z}{1 + \left(a + y \cdot \frac{b}{t}\right)}\\ \mathbf{elif}\;\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \leq -4 \cdot 10^{-298}:\\ \;\;\;\;\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}}\\ \mathbf{elif}\;\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \leq 0:\\ \;\;\;\;\frac{t}{y} \cdot \frac{\mathsf{fma}\left(y, \frac{z}{t}, x\right)}{b}\\ \mathbf{elif}\;\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \leq 2 \cdot 10^{+284}:\\ \;\;\;\;\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 88.1% accurate, 0.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x + \frac{y \cdot z}{t}\\ t_2 := \frac{t\_1}{\left(a + 1\right) + \frac{y \cdot b}{t}}\\ \mathbf{if}\;t\_2 \leq -5 \cdot 10^{+293}:\\ \;\;\;\;\frac{y}{t} \cdot \frac{z}{1 + \left(a + y \cdot \frac{b}{t}\right)}\\ \mathbf{elif}\;t\_2 \leq 2 \cdot 10^{+284}:\\ \;\;\;\;\frac{t\_1}{b \cdot \frac{y}{t} + \left(a + 1\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (+ x (/ (* y z) t))) (t_2 (/ t_1 (+ (+ a 1.0) (/ (* y b) t)))))
   (if (<= t_2 -5e+293)
     (* (/ y t) (/ z (+ 1.0 (+ a (* y (/ b t))))))
     (if (<= t_2 2e+284) (/ t_1 (+ (* b (/ y t)) (+ a 1.0))) (/ z b)))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = x + ((y * z) / t);
	double t_2 = t_1 / ((a + 1.0) + ((y * b) / t));
	double tmp;
	if (t_2 <= -5e+293) {
		tmp = (y / t) * (z / (1.0 + (a + (y * (b / t)))));
	} else if (t_2 <= 2e+284) {
		tmp = t_1 / ((b * (y / t)) + (a + 1.0));
	} else {
		tmp = z / b;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = x + ((y * z) / t)
    t_2 = t_1 / ((a + 1.0d0) + ((y * b) / t))
    if (t_2 <= (-5d+293)) then
        tmp = (y / t) * (z / (1.0d0 + (a + (y * (b / t)))))
    else if (t_2 <= 2d+284) then
        tmp = t_1 / ((b * (y / t)) + (a + 1.0d0))
    else
        tmp = z / b
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = x + ((y * z) / t);
	double t_2 = t_1 / ((a + 1.0) + ((y * b) / t));
	double tmp;
	if (t_2 <= -5e+293) {
		tmp = (y / t) * (z / (1.0 + (a + (y * (b / t)))));
	} else if (t_2 <= 2e+284) {
		tmp = t_1 / ((b * (y / t)) + (a + 1.0));
	} else {
		tmp = z / b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = x + ((y * z) / t)
	t_2 = t_1 / ((a + 1.0) + ((y * b) / t))
	tmp = 0
	if t_2 <= -5e+293:
		tmp = (y / t) * (z / (1.0 + (a + (y * (b / t)))))
	elif t_2 <= 2e+284:
		tmp = t_1 / ((b * (y / t)) + (a + 1.0))
	else:
		tmp = z / b
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(x + Float64(Float64(y * z) / t))
	t_2 = Float64(t_1 / Float64(Float64(a + 1.0) + Float64(Float64(y * b) / t)))
	tmp = 0.0
	if (t_2 <= -5e+293)
		tmp = Float64(Float64(y / t) * Float64(z / Float64(1.0 + Float64(a + Float64(y * Float64(b / t))))));
	elseif (t_2 <= 2e+284)
		tmp = Float64(t_1 / Float64(Float64(b * Float64(y / t)) + Float64(a + 1.0)));
	else
		tmp = Float64(z / b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = x + ((y * z) / t);
	t_2 = t_1 / ((a + 1.0) + ((y * b) / t));
	tmp = 0.0;
	if (t_2 <= -5e+293)
		tmp = (y / t) * (z / (1.0 + (a + (y * (b / t)))));
	elseif (t_2 <= 2e+284)
		tmp = t_1 / ((b * (y / t)) + (a + 1.0));
	else
		tmp = z / b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t$95$1 / N[(N[(a + 1.0), $MachinePrecision] + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, -5e+293], N[(N[(y / t), $MachinePrecision] * N[(z / N[(1.0 + N[(a + N[(y * N[(b / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, 2e+284], N[(t$95$1 / N[(N[(b * N[(y / t), $MachinePrecision]), $MachinePrecision] + N[(a + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(z / b), $MachinePrecision]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x + \frac{y \cdot z}{t}\\
t_2 := \frac{t\_1}{\left(a + 1\right) + \frac{y \cdot b}{t}}\\
\mathbf{if}\;t\_2 \leq -5 \cdot 10^{+293}:\\
\;\;\;\;\frac{y}{t} \cdot \frac{z}{1 + \left(a + y \cdot \frac{b}{t}\right)}\\

\mathbf{elif}\;t\_2 \leq 2 \cdot 10^{+284}:\\
\;\;\;\;\frac{t\_1}{b \cdot \frac{y}{t} + \left(a + 1\right)}\\

\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < -5.00000000000000033e293

    1. Initial program 39.0%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*56.3%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified56.4%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in x around 0 64.5%

      \[\leadsto \color{blue}{\frac{y \cdot z}{t \cdot \left(1 + \left(a + \frac{b \cdot y}{t}\right)\right)}} \]
    6. Step-by-step derivation
      1. times-frac90.6%

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

        \[\leadsto \frac{y}{t} \cdot \frac{z}{1 + \left(a + \color{blue}{\frac{b}{t} \cdot y}\right)} \]
      3. *-commutative90.8%

        \[\leadsto \frac{y}{t} \cdot \frac{z}{1 + \left(a + \color{blue}{y \cdot \frac{b}{t}}\right)} \]
    7. Simplified90.8%

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

    if -5.00000000000000033e293 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < 2.00000000000000016e284

    1. Initial program 90.5%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. *-commutative90.5%

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

        \[\leadsto \frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \color{blue}{b \cdot \frac{y}{t}}} \]
    4. Applied egg-rr91.9%

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

    if 2.00000000000000016e284 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t)))

    1. Initial program 15.9%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*19.1%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified38.5%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in y around inf 85.5%

      \[\leadsto \color{blue}{\frac{z}{b}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification90.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \leq -5 \cdot 10^{+293}:\\ \;\;\;\;\frac{y}{t} \cdot \frac{z}{1 + \left(a + y \cdot \frac{b}{t}\right)}\\ \mathbf{elif}\;\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \leq 2 \cdot 10^{+284}:\\ \;\;\;\;\frac{x + \frac{y \cdot z}{t}}{b \cdot \frac{y}{t} + \left(a + 1\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 63.8% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x}{1 + \left(a + y \cdot \frac{b}{t}\right)}\\ t_2 := \frac{x + z \cdot \frac{y}{t}}{a + 1}\\ \mathbf{if}\;y \leq -3.7 \cdot 10^{+156}:\\ \;\;\;\;\frac{z}{b}\\ \mathbf{elif}\;y \leq -6.4 \cdot 10^{-28}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 3.7 \cdot 10^{-125}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y \leq 1850000000:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 6 \cdot 10^{+52}:\\ \;\;\;\;t\_2\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (/ x (+ 1.0 (+ a (* y (/ b t))))))
        (t_2 (/ (+ x (* z (/ y t))) (+ a 1.0))))
   (if (<= y -3.7e+156)
     (/ z b)
     (if (<= y -6.4e-28)
       t_1
       (if (<= y 3.7e-125)
         t_2
         (if (<= y 1850000000.0) t_1 (if (<= y 6e+52) t_2 (/ z b))))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = x / (1.0 + (a + (y * (b / t))));
	double t_2 = (x + (z * (y / t))) / (a + 1.0);
	double tmp;
	if (y <= -3.7e+156) {
		tmp = z / b;
	} else if (y <= -6.4e-28) {
		tmp = t_1;
	} else if (y <= 3.7e-125) {
		tmp = t_2;
	} else if (y <= 1850000000.0) {
		tmp = t_1;
	} else if (y <= 6e+52) {
		tmp = t_2;
	} else {
		tmp = z / b;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = x / (1.0d0 + (a + (y * (b / t))))
    t_2 = (x + (z * (y / t))) / (a + 1.0d0)
    if (y <= (-3.7d+156)) then
        tmp = z / b
    else if (y <= (-6.4d-28)) then
        tmp = t_1
    else if (y <= 3.7d-125) then
        tmp = t_2
    else if (y <= 1850000000.0d0) then
        tmp = t_1
    else if (y <= 6d+52) then
        tmp = t_2
    else
        tmp = z / b
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = x / (1.0 + (a + (y * (b / t))));
	double t_2 = (x + (z * (y / t))) / (a + 1.0);
	double tmp;
	if (y <= -3.7e+156) {
		tmp = z / b;
	} else if (y <= -6.4e-28) {
		tmp = t_1;
	} else if (y <= 3.7e-125) {
		tmp = t_2;
	} else if (y <= 1850000000.0) {
		tmp = t_1;
	} else if (y <= 6e+52) {
		tmp = t_2;
	} else {
		tmp = z / b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = x / (1.0 + (a + (y * (b / t))))
	t_2 = (x + (z * (y / t))) / (a + 1.0)
	tmp = 0
	if y <= -3.7e+156:
		tmp = z / b
	elif y <= -6.4e-28:
		tmp = t_1
	elif y <= 3.7e-125:
		tmp = t_2
	elif y <= 1850000000.0:
		tmp = t_1
	elif y <= 6e+52:
		tmp = t_2
	else:
		tmp = z / b
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(x / Float64(1.0 + Float64(a + Float64(y * Float64(b / t)))))
	t_2 = Float64(Float64(x + Float64(z * Float64(y / t))) / Float64(a + 1.0))
	tmp = 0.0
	if (y <= -3.7e+156)
		tmp = Float64(z / b);
	elseif (y <= -6.4e-28)
		tmp = t_1;
	elseif (y <= 3.7e-125)
		tmp = t_2;
	elseif (y <= 1850000000.0)
		tmp = t_1;
	elseif (y <= 6e+52)
		tmp = t_2;
	else
		tmp = Float64(z / b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = x / (1.0 + (a + (y * (b / t))));
	t_2 = (x + (z * (y / t))) / (a + 1.0);
	tmp = 0.0;
	if (y <= -3.7e+156)
		tmp = z / b;
	elseif (y <= -6.4e-28)
		tmp = t_1;
	elseif (y <= 3.7e-125)
		tmp = t_2;
	elseif (y <= 1850000000.0)
		tmp = t_1;
	elseif (y <= 6e+52)
		tmp = t_2;
	else
		tmp = z / b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x / N[(1.0 + N[(a + N[(y * N[(b / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x + N[(z * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(a + 1.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -3.7e+156], N[(z / b), $MachinePrecision], If[LessEqual[y, -6.4e-28], t$95$1, If[LessEqual[y, 3.7e-125], t$95$2, If[LessEqual[y, 1850000000.0], t$95$1, If[LessEqual[y, 6e+52], t$95$2, N[(z / b), $MachinePrecision]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{x}{1 + \left(a + y \cdot \frac{b}{t}\right)}\\
t_2 := \frac{x + z \cdot \frac{y}{t}}{a + 1}\\
\mathbf{if}\;y \leq -3.7 \cdot 10^{+156}:\\
\;\;\;\;\frac{z}{b}\\

\mathbf{elif}\;y \leq -6.4 \cdot 10^{-28}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq 3.7 \cdot 10^{-125}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y \leq 1850000000:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq 6 \cdot 10^{+52}:\\
\;\;\;\;t\_2\\

\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -3.70000000000000001e156 or 6e52 < y

    1. Initial program 41.8%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*44.6%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified60.1%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in y around inf 64.0%

      \[\leadsto \color{blue}{\frac{z}{b}} \]

    if -3.70000000000000001e156 < y < -6.39999999999999964e-28 or 3.6999999999999999e-125 < y < 1.85e9

    1. Initial program 85.1%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*82.5%

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

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

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in x around inf 61.6%

      \[\leadsto \color{blue}{\frac{x}{1 + \left(a + \frac{b \cdot y}{t}\right)}} \]
    6. Step-by-step derivation
      1. associate-*l/61.6%

        \[\leadsto \frac{x}{1 + \left(a + \color{blue}{\frac{b}{t} \cdot y}\right)} \]
      2. *-commutative61.6%

        \[\leadsto \frac{x}{1 + \left(a + \color{blue}{y \cdot \frac{b}{t}}\right)} \]
    7. Simplified61.6%

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

    if -6.39999999999999964e-28 < y < 3.6999999999999999e-125 or 1.85e9 < y < 6e52

    1. Initial program 98.1%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. *-commutative98.1%

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

        \[\leadsto \frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \color{blue}{b \cdot \frac{y}{t}}} \]
    4. Applied egg-rr98.0%

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

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

        \[\leadsto \frac{x + \color{blue}{z \cdot \frac{y}{t}}}{\left(a + 1\right) + b \cdot \frac{y}{t}} \]
    6. Applied egg-rr98.0%

      \[\leadsto \frac{x + \color{blue}{z \cdot \frac{y}{t}}}{\left(a + 1\right) + b \cdot \frac{y}{t}} \]
    7. Taylor expanded in b around 0 90.9%

      \[\leadsto \frac{x + z \cdot \frac{y}{t}}{\color{blue}{1 + a}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification74.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -3.7 \cdot 10^{+156}:\\ \;\;\;\;\frac{z}{b}\\ \mathbf{elif}\;y \leq -6.4 \cdot 10^{-28}:\\ \;\;\;\;\frac{x}{1 + \left(a + y \cdot \frac{b}{t}\right)}\\ \mathbf{elif}\;y \leq 3.7 \cdot 10^{-125}:\\ \;\;\;\;\frac{x + z \cdot \frac{y}{t}}{a + 1}\\ \mathbf{elif}\;y \leq 1850000000:\\ \;\;\;\;\frac{x}{1 + \left(a + y \cdot \frac{b}{t}\right)}\\ \mathbf{elif}\;y \leq 6 \cdot 10^{+52}:\\ \;\;\;\;\frac{x + z \cdot \frac{y}{t}}{a + 1}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \]
  5. Add Preprocessing

Alternative 5: 64.8% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -4.4 \cdot 10^{+150}:\\ \;\;\;\;\frac{z}{b}\\ \mathbf{elif}\;y \leq -5.6 \cdot 10^{-28}:\\ \;\;\;\;\frac{x + y \cdot \frac{z}{t}}{1 + b \cdot \frac{y}{t}}\\ \mathbf{elif}\;y \leq 1.95 \cdot 10^{-78}:\\ \;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a + 1}\\ \mathbf{elif}\;y \leq 3.5 \cdot 10^{+107}:\\ \;\;\;\;\frac{x + z \cdot \frac{y}{t}}{1 + \frac{y \cdot b}{t}}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (<= y -4.4e+150)
   (/ z b)
   (if (<= y -5.6e-28)
     (/ (+ x (* y (/ z t))) (+ 1.0 (* b (/ y t))))
     (if (<= y 1.95e-78)
       (/ (+ x (/ (* y z) t)) (+ a 1.0))
       (if (<= y 3.5e+107)
         (/ (+ x (* z (/ y t))) (+ 1.0 (/ (* y b) t)))
         (/ z b))))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (y <= -4.4e+150) {
		tmp = z / b;
	} else if (y <= -5.6e-28) {
		tmp = (x + (y * (z / t))) / (1.0 + (b * (y / t)));
	} else if (y <= 1.95e-78) {
		tmp = (x + ((y * z) / t)) / (a + 1.0);
	} else if (y <= 3.5e+107) {
		tmp = (x + (z * (y / t))) / (1.0 + ((y * b) / t));
	} else {
		tmp = z / b;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: tmp
    if (y <= (-4.4d+150)) then
        tmp = z / b
    else if (y <= (-5.6d-28)) then
        tmp = (x + (y * (z / t))) / (1.0d0 + (b * (y / t)))
    else if (y <= 1.95d-78) then
        tmp = (x + ((y * z) / t)) / (a + 1.0d0)
    else if (y <= 3.5d+107) then
        tmp = (x + (z * (y / t))) / (1.0d0 + ((y * b) / t))
    else
        tmp = z / b
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (y <= -4.4e+150) {
		tmp = z / b;
	} else if (y <= -5.6e-28) {
		tmp = (x + (y * (z / t))) / (1.0 + (b * (y / t)));
	} else if (y <= 1.95e-78) {
		tmp = (x + ((y * z) / t)) / (a + 1.0);
	} else if (y <= 3.5e+107) {
		tmp = (x + (z * (y / t))) / (1.0 + ((y * b) / t));
	} else {
		tmp = z / b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if y <= -4.4e+150:
		tmp = z / b
	elif y <= -5.6e-28:
		tmp = (x + (y * (z / t))) / (1.0 + (b * (y / t)))
	elif y <= 1.95e-78:
		tmp = (x + ((y * z) / t)) / (a + 1.0)
	elif y <= 3.5e+107:
		tmp = (x + (z * (y / t))) / (1.0 + ((y * b) / t))
	else:
		tmp = z / b
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (y <= -4.4e+150)
		tmp = Float64(z / b);
	elseif (y <= -5.6e-28)
		tmp = Float64(Float64(x + Float64(y * Float64(z / t))) / Float64(1.0 + Float64(b * Float64(y / t))));
	elseif (y <= 1.95e-78)
		tmp = Float64(Float64(x + Float64(Float64(y * z) / t)) / Float64(a + 1.0));
	elseif (y <= 3.5e+107)
		tmp = Float64(Float64(x + Float64(z * Float64(y / t))) / Float64(1.0 + Float64(Float64(y * b) / t)));
	else
		tmp = Float64(z / b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (y <= -4.4e+150)
		tmp = z / b;
	elseif (y <= -5.6e-28)
		tmp = (x + (y * (z / t))) / (1.0 + (b * (y / t)));
	elseif (y <= 1.95e-78)
		tmp = (x + ((y * z) / t)) / (a + 1.0);
	elseif (y <= 3.5e+107)
		tmp = (x + (z * (y / t))) / (1.0 + ((y * b) / t));
	else
		tmp = z / b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -4.4e+150], N[(z / b), $MachinePrecision], If[LessEqual[y, -5.6e-28], N[(N[(x + N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(1.0 + N[(b * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.95e-78], N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / N[(a + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3.5e+107], N[(N[(x + N[(z * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(1.0 + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(z / b), $MachinePrecision]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.4 \cdot 10^{+150}:\\
\;\;\;\;\frac{z}{b}\\

\mathbf{elif}\;y \leq -5.6 \cdot 10^{-28}:\\
\;\;\;\;\frac{x + y \cdot \frac{z}{t}}{1 + b \cdot \frac{y}{t}}\\

\mathbf{elif}\;y \leq 1.95 \cdot 10^{-78}:\\
\;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a + 1}\\

\mathbf{elif}\;y \leq 3.5 \cdot 10^{+107}:\\
\;\;\;\;\frac{x + z \cdot \frac{y}{t}}{1 + \frac{y \cdot b}{t}}\\

\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if y < -4.39999999999999999e150 or 3.4999999999999997e107 < y

    1. Initial program 35.9%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*39.1%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified57.3%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in y around inf 65.2%

      \[\leadsto \color{blue}{\frac{z}{b}} \]

    if -4.39999999999999999e150 < y < -5.5999999999999996e-28

    1. Initial program 87.7%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*87.8%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified90.1%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in a around 0 68.6%

      \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\color{blue}{1 + \frac{b \cdot y}{t}}} \]
    6. Step-by-step derivation
      1. associate-*r/70.7%

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{1 + \color{blue}{b \cdot \frac{y}{t}}} \]
      2. *-commutative70.7%

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{1 + \color{blue}{\frac{y}{t} \cdot b}} \]
    7. Applied egg-rr70.7%

      \[\leadsto \frac{x + y \cdot \frac{z}{t}}{1 + \color{blue}{\frac{y}{t} \cdot b}} \]

    if -5.5999999999999996e-28 < y < 1.9500000000000001e-78

    1. Initial program 95.6%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*84.3%

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

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

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in b around 0 88.3%

      \[\leadsto \color{blue}{\frac{x + \frac{y \cdot z}{t}}{1 + a}} \]

    if 1.9500000000000001e-78 < y < 3.4999999999999997e107

    1. Initial program 83.8%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. *-commutative83.8%

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

        \[\leadsto \frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \color{blue}{b \cdot \frac{y}{t}}} \]
    4. Applied egg-rr83.8%

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

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

        \[\leadsto \frac{x + \color{blue}{z \cdot \frac{y}{t}}}{\left(a + 1\right) + b \cdot \frac{y}{t}} \]
    6. Applied egg-rr83.9%

      \[\leadsto \frac{x + \color{blue}{z \cdot \frac{y}{t}}}{\left(a + 1\right) + b \cdot \frac{y}{t}} \]
    7. Taylor expanded in a around 0 66.0%

      \[\leadsto \frac{x + z \cdot \frac{y}{t}}{\color{blue}{1 + \frac{b \cdot y}{t}}} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification76.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -4.4 \cdot 10^{+150}:\\ \;\;\;\;\frac{z}{b}\\ \mathbf{elif}\;y \leq -5.6 \cdot 10^{-28}:\\ \;\;\;\;\frac{x + y \cdot \frac{z}{t}}{1 + b \cdot \frac{y}{t}}\\ \mathbf{elif}\;y \leq 1.95 \cdot 10^{-78}:\\ \;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a + 1}\\ \mathbf{elif}\;y \leq 3.5 \cdot 10^{+107}:\\ \;\;\;\;\frac{x + z \cdot \frac{y}{t}}{1 + \frac{y \cdot b}{t}}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \]
  5. Add Preprocessing

Alternative 6: 74.9% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x + y \cdot \frac{z}{t}}{y \cdot \frac{b}{t} + \left(a + 1\right)}\\ \mathbf{if}\;y \leq -3.5 \cdot 10^{-38}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 9.2 \cdot 10^{-135}:\\ \;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a + 1}\\ \mathbf{elif}\;y \leq 2.5 \cdot 10^{+171}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (/ (+ x (* y (/ z t))) (+ (* y (/ b t)) (+ a 1.0)))))
   (if (<= y -3.5e-38)
     t_1
     (if (<= y 9.2e-135)
       (/ (+ x (/ (* y z) t)) (+ a 1.0))
       (if (<= y 2.5e+171) t_1 (/ z b))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = (x + (y * (z / t))) / ((y * (b / t)) + (a + 1.0));
	double tmp;
	if (y <= -3.5e-38) {
		tmp = t_1;
	} else if (y <= 9.2e-135) {
		tmp = (x + ((y * z) / t)) / (a + 1.0);
	} else if (y <= 2.5e+171) {
		tmp = t_1;
	} else {
		tmp = z / b;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: t_1
    real(8) :: tmp
    t_1 = (x + (y * (z / t))) / ((y * (b / t)) + (a + 1.0d0))
    if (y <= (-3.5d-38)) then
        tmp = t_1
    else if (y <= 9.2d-135) then
        tmp = (x + ((y * z) / t)) / (a + 1.0d0)
    else if (y <= 2.5d+171) then
        tmp = t_1
    else
        tmp = z / b
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = (x + (y * (z / t))) / ((y * (b / t)) + (a + 1.0));
	double tmp;
	if (y <= -3.5e-38) {
		tmp = t_1;
	} else if (y <= 9.2e-135) {
		tmp = (x + ((y * z) / t)) / (a + 1.0);
	} else if (y <= 2.5e+171) {
		tmp = t_1;
	} else {
		tmp = z / b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = (x + (y * (z / t))) / ((y * (b / t)) + (a + 1.0))
	tmp = 0
	if y <= -3.5e-38:
		tmp = t_1
	elif y <= 9.2e-135:
		tmp = (x + ((y * z) / t)) / (a + 1.0)
	elif y <= 2.5e+171:
		tmp = t_1
	else:
		tmp = z / b
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(Float64(x + Float64(y * Float64(z / t))) / Float64(Float64(y * Float64(b / t)) + Float64(a + 1.0)))
	tmp = 0.0
	if (y <= -3.5e-38)
		tmp = t_1;
	elseif (y <= 9.2e-135)
		tmp = Float64(Float64(x + Float64(Float64(y * z) / t)) / Float64(a + 1.0));
	elseif (y <= 2.5e+171)
		tmp = t_1;
	else
		tmp = Float64(z / b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = (x + (y * (z / t))) / ((y * (b / t)) + (a + 1.0));
	tmp = 0.0;
	if (y <= -3.5e-38)
		tmp = t_1;
	elseif (y <= 9.2e-135)
		tmp = (x + ((y * z) / t)) / (a + 1.0);
	elseif (y <= 2.5e+171)
		tmp = t_1;
	else
		tmp = z / b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(x + N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(y * N[(b / t), $MachinePrecision]), $MachinePrecision] + N[(a + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -3.5e-38], t$95$1, If[LessEqual[y, 9.2e-135], N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / N[(a + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.5e+171], t$95$1, N[(z / b), $MachinePrecision]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{x + y \cdot \frac{z}{t}}{y \cdot \frac{b}{t} + \left(a + 1\right)}\\
\mathbf{if}\;y \leq -3.5 \cdot 10^{-38}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq 9.2 \cdot 10^{-135}:\\
\;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a + 1}\\

\mathbf{elif}\;y \leq 2.5 \cdot 10^{+171}:\\
\;\;\;\;t\_1\\

\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -3.5000000000000001e-38 or 9.1999999999999996e-135 < y < 2.5000000000000002e171

    1. Initial program 72.6%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*72.1%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified78.3%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing

    if -3.5000000000000001e-38 < y < 9.1999999999999996e-135

    1. Initial program 98.8%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*84.7%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified80.3%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in b around 0 92.9%

      \[\leadsto \color{blue}{\frac{x + \frac{y \cdot z}{t}}{1 + a}} \]

    if 2.5000000000000002e171 < y

    1. Initial program 25.9%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*29.9%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified47.1%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in y around inf 79.9%

      \[\leadsto \color{blue}{\frac{z}{b}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification83.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -3.5 \cdot 10^{-38}:\\ \;\;\;\;\frac{x + y \cdot \frac{z}{t}}{y \cdot \frac{b}{t} + \left(a + 1\right)}\\ \mathbf{elif}\;y \leq 9.2 \cdot 10^{-135}:\\ \;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a + 1}\\ \mathbf{elif}\;y \leq 2.5 \cdot 10^{+171}:\\ \;\;\;\;\frac{x + y \cdot \frac{z}{t}}{y \cdot \frac{b}{t} + \left(a + 1\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \]
  5. Add Preprocessing

Alternative 7: 54.4% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -3.1 \cdot 10^{+40}:\\ \;\;\;\;\frac{z}{b}\\ \mathbf{elif}\;y \leq -2.6 \cdot 10^{-25}:\\ \;\;\;\;\frac{x}{1 + \frac{y \cdot b}{t}}\\ \mathbf{elif}\;y \leq -8.5 \cdot 10^{-46}:\\ \;\;\;\;\frac{y}{t} \cdot \frac{z}{a + 1}\\ \mathbf{elif}\;y \leq -3 \cdot 10^{-72}:\\ \;\;\;\;\frac{x + y \cdot \frac{z}{t}}{a}\\ \mathbf{elif}\;y \leq 1.4 \cdot 10^{-12}:\\ \;\;\;\;\frac{x}{a + 1}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (<= y -3.1e+40)
   (/ z b)
   (if (<= y -2.6e-25)
     (/ x (+ 1.0 (/ (* y b) t)))
     (if (<= y -8.5e-46)
       (* (/ y t) (/ z (+ a 1.0)))
       (if (<= y -3e-72)
         (/ (+ x (* y (/ z t))) a)
         (if (<= y 1.4e-12) (/ x (+ a 1.0)) (/ z b)))))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (y <= -3.1e+40) {
		tmp = z / b;
	} else if (y <= -2.6e-25) {
		tmp = x / (1.0 + ((y * b) / t));
	} else if (y <= -8.5e-46) {
		tmp = (y / t) * (z / (a + 1.0));
	} else if (y <= -3e-72) {
		tmp = (x + (y * (z / t))) / a;
	} else if (y <= 1.4e-12) {
		tmp = x / (a + 1.0);
	} else {
		tmp = z / b;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: tmp
    if (y <= (-3.1d+40)) then
        tmp = z / b
    else if (y <= (-2.6d-25)) then
        tmp = x / (1.0d0 + ((y * b) / t))
    else if (y <= (-8.5d-46)) then
        tmp = (y / t) * (z / (a + 1.0d0))
    else if (y <= (-3d-72)) then
        tmp = (x + (y * (z / t))) / a
    else if (y <= 1.4d-12) then
        tmp = x / (a + 1.0d0)
    else
        tmp = z / b
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (y <= -3.1e+40) {
		tmp = z / b;
	} else if (y <= -2.6e-25) {
		tmp = x / (1.0 + ((y * b) / t));
	} else if (y <= -8.5e-46) {
		tmp = (y / t) * (z / (a + 1.0));
	} else if (y <= -3e-72) {
		tmp = (x + (y * (z / t))) / a;
	} else if (y <= 1.4e-12) {
		tmp = x / (a + 1.0);
	} else {
		tmp = z / b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if y <= -3.1e+40:
		tmp = z / b
	elif y <= -2.6e-25:
		tmp = x / (1.0 + ((y * b) / t))
	elif y <= -8.5e-46:
		tmp = (y / t) * (z / (a + 1.0))
	elif y <= -3e-72:
		tmp = (x + (y * (z / t))) / a
	elif y <= 1.4e-12:
		tmp = x / (a + 1.0)
	else:
		tmp = z / b
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (y <= -3.1e+40)
		tmp = Float64(z / b);
	elseif (y <= -2.6e-25)
		tmp = Float64(x / Float64(1.0 + Float64(Float64(y * b) / t)));
	elseif (y <= -8.5e-46)
		tmp = Float64(Float64(y / t) * Float64(z / Float64(a + 1.0)));
	elseif (y <= -3e-72)
		tmp = Float64(Float64(x + Float64(y * Float64(z / t))) / a);
	elseif (y <= 1.4e-12)
		tmp = Float64(x / Float64(a + 1.0));
	else
		tmp = Float64(z / b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (y <= -3.1e+40)
		tmp = z / b;
	elseif (y <= -2.6e-25)
		tmp = x / (1.0 + ((y * b) / t));
	elseif (y <= -8.5e-46)
		tmp = (y / t) * (z / (a + 1.0));
	elseif (y <= -3e-72)
		tmp = (x + (y * (z / t))) / a;
	elseif (y <= 1.4e-12)
		tmp = x / (a + 1.0);
	else
		tmp = z / b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -3.1e+40], N[(z / b), $MachinePrecision], If[LessEqual[y, -2.6e-25], N[(x / N[(1.0 + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -8.5e-46], N[(N[(y / t), $MachinePrecision] * N[(z / N[(a + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -3e-72], N[(N[(x + N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision], If[LessEqual[y, 1.4e-12], N[(x / N[(a + 1.0), $MachinePrecision]), $MachinePrecision], N[(z / b), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.1 \cdot 10^{+40}:\\
\;\;\;\;\frac{z}{b}\\

\mathbf{elif}\;y \leq -2.6 \cdot 10^{-25}:\\
\;\;\;\;\frac{x}{1 + \frac{y \cdot b}{t}}\\

\mathbf{elif}\;y \leq -8.5 \cdot 10^{-46}:\\
\;\;\;\;\frac{y}{t} \cdot \frac{z}{a + 1}\\

\mathbf{elif}\;y \leq -3 \cdot 10^{-72}:\\
\;\;\;\;\frac{x + y \cdot \frac{z}{t}}{a}\\

\mathbf{elif}\;y \leq 1.4 \cdot 10^{-12}:\\
\;\;\;\;\frac{x}{a + 1}\\

\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if y < -3.0999999999999998e40 or 1.4000000000000001e-12 < y

    1. Initial program 55.5%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*57.4%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified68.7%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in y around inf 55.1%

      \[\leadsto \color{blue}{\frac{z}{b}} \]

    if -3.0999999999999998e40 < y < -2.6e-25

    1. Initial program 99.8%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*99.8%

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

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

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in x around inf 73.5%

      \[\leadsto \color{blue}{\frac{x}{1 + \left(a + \frac{b \cdot y}{t}\right)}} \]
    6. Step-by-step derivation
      1. associate-*l/73.5%

        \[\leadsto \frac{x}{1 + \left(a + \color{blue}{\frac{b}{t} \cdot y}\right)} \]
      2. *-commutative73.5%

        \[\leadsto \frac{x}{1 + \left(a + \color{blue}{y \cdot \frac{b}{t}}\right)} \]
    7. Simplified73.5%

      \[\leadsto \color{blue}{\frac{x}{1 + \left(a + y \cdot \frac{b}{t}\right)}} \]
    8. Taylor expanded in a around 0 58.9%

      \[\leadsto \color{blue}{\frac{x}{1 + \frac{b \cdot y}{t}}} \]

    if -2.6e-25 < y < -8.5000000000000001e-46

    1. Initial program 86.5%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*73.1%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified73.1%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in x around 0 72.2%

      \[\leadsto \color{blue}{\frac{y \cdot z}{t \cdot \left(1 + \left(a + \frac{b \cdot y}{t}\right)\right)}} \]
    6. Step-by-step derivation
      1. times-frac72.6%

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

        \[\leadsto \frac{y}{t} \cdot \frac{z}{1 + \left(a + \color{blue}{\frac{b}{t} \cdot y}\right)} \]
      3. *-commutative72.6%

        \[\leadsto \frac{y}{t} \cdot \frac{z}{1 + \left(a + \color{blue}{y \cdot \frac{b}{t}}\right)} \]
    7. Simplified72.6%

      \[\leadsto \color{blue}{\frac{y}{t} \cdot \frac{z}{1 + \left(a + y \cdot \frac{b}{t}\right)}} \]
    8. Taylor expanded in y around 0 44.1%

      \[\leadsto \color{blue}{\frac{y \cdot z}{t \cdot \left(1 + a\right)}} \]
    9. Step-by-step derivation
      1. times-frac44.4%

        \[\leadsto \color{blue}{\frac{y}{t} \cdot \frac{z}{1 + a}} \]
    10. Simplified44.4%

      \[\leadsto \color{blue}{\frac{y}{t} \cdot \frac{z}{1 + a}} \]

    if -8.5000000000000001e-46 < y < -3e-72

    1. Initial program 100.0%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*100.0%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified100.0%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in a around inf 100.0%

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

    if -3e-72 < y < 1.4000000000000001e-12

    1. Initial program 94.7%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*82.5%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified79.0%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in y around 0 69.6%

      \[\leadsto \color{blue}{\frac{x}{1 + a}} \]
  3. Recombined 5 regimes into one program.
  4. Final simplification62.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -3.1 \cdot 10^{+40}:\\ \;\;\;\;\frac{z}{b}\\ \mathbf{elif}\;y \leq -2.6 \cdot 10^{-25}:\\ \;\;\;\;\frac{x}{1 + \frac{y \cdot b}{t}}\\ \mathbf{elif}\;y \leq -8.5 \cdot 10^{-46}:\\ \;\;\;\;\frac{y}{t} \cdot \frac{z}{a + 1}\\ \mathbf{elif}\;y \leq -3 \cdot 10^{-72}:\\ \;\;\;\;\frac{x + y \cdot \frac{z}{t}}{a}\\ \mathbf{elif}\;y \leq 1.4 \cdot 10^{-12}:\\ \;\;\;\;\frac{x}{a + 1}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \]
  5. Add Preprocessing

Alternative 8: 54.6% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -1.7 \cdot 10^{+39}:\\ \;\;\;\;\frac{z}{b}\\ \mathbf{elif}\;y \leq -9 \cdot 10^{-24}:\\ \;\;\;\;\frac{x}{1 + \frac{y \cdot b}{t}}\\ \mathbf{elif}\;y \leq -1.62 \cdot 10^{-37}:\\ \;\;\;\;\frac{z}{b}\\ \mathbf{elif}\;y \leq -1.8 \cdot 10^{-73}:\\ \;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a}\\ \mathbf{elif}\;y \leq 8.4 \cdot 10^{-10}:\\ \;\;\;\;\frac{x}{a + 1}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (<= y -1.7e+39)
   (/ z b)
   (if (<= y -9e-24)
     (/ x (+ 1.0 (/ (* y b) t)))
     (if (<= y -1.62e-37)
       (/ z b)
       (if (<= y -1.8e-73)
         (/ (+ x (/ (* y z) t)) a)
         (if (<= y 8.4e-10) (/ x (+ a 1.0)) (/ z b)))))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (y <= -1.7e+39) {
		tmp = z / b;
	} else if (y <= -9e-24) {
		tmp = x / (1.0 + ((y * b) / t));
	} else if (y <= -1.62e-37) {
		tmp = z / b;
	} else if (y <= -1.8e-73) {
		tmp = (x + ((y * z) / t)) / a;
	} else if (y <= 8.4e-10) {
		tmp = x / (a + 1.0);
	} else {
		tmp = z / b;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: tmp
    if (y <= (-1.7d+39)) then
        tmp = z / b
    else if (y <= (-9d-24)) then
        tmp = x / (1.0d0 + ((y * b) / t))
    else if (y <= (-1.62d-37)) then
        tmp = z / b
    else if (y <= (-1.8d-73)) then
        tmp = (x + ((y * z) / t)) / a
    else if (y <= 8.4d-10) then
        tmp = x / (a + 1.0d0)
    else
        tmp = z / b
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (y <= -1.7e+39) {
		tmp = z / b;
	} else if (y <= -9e-24) {
		tmp = x / (1.0 + ((y * b) / t));
	} else if (y <= -1.62e-37) {
		tmp = z / b;
	} else if (y <= -1.8e-73) {
		tmp = (x + ((y * z) / t)) / a;
	} else if (y <= 8.4e-10) {
		tmp = x / (a + 1.0);
	} else {
		tmp = z / b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if y <= -1.7e+39:
		tmp = z / b
	elif y <= -9e-24:
		tmp = x / (1.0 + ((y * b) / t))
	elif y <= -1.62e-37:
		tmp = z / b
	elif y <= -1.8e-73:
		tmp = (x + ((y * z) / t)) / a
	elif y <= 8.4e-10:
		tmp = x / (a + 1.0)
	else:
		tmp = z / b
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (y <= -1.7e+39)
		tmp = Float64(z / b);
	elseif (y <= -9e-24)
		tmp = Float64(x / Float64(1.0 + Float64(Float64(y * b) / t)));
	elseif (y <= -1.62e-37)
		tmp = Float64(z / b);
	elseif (y <= -1.8e-73)
		tmp = Float64(Float64(x + Float64(Float64(y * z) / t)) / a);
	elseif (y <= 8.4e-10)
		tmp = Float64(x / Float64(a + 1.0));
	else
		tmp = Float64(z / b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (y <= -1.7e+39)
		tmp = z / b;
	elseif (y <= -9e-24)
		tmp = x / (1.0 + ((y * b) / t));
	elseif (y <= -1.62e-37)
		tmp = z / b;
	elseif (y <= -1.8e-73)
		tmp = (x + ((y * z) / t)) / a;
	elseif (y <= 8.4e-10)
		tmp = x / (a + 1.0);
	else
		tmp = z / b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -1.7e+39], N[(z / b), $MachinePrecision], If[LessEqual[y, -9e-24], N[(x / N[(1.0 + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -1.62e-37], N[(z / b), $MachinePrecision], If[LessEqual[y, -1.8e-73], N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision], If[LessEqual[y, 8.4e-10], N[(x / N[(a + 1.0), $MachinePrecision]), $MachinePrecision], N[(z / b), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.7 \cdot 10^{+39}:\\
\;\;\;\;\frac{z}{b}\\

\mathbf{elif}\;y \leq -9 \cdot 10^{-24}:\\
\;\;\;\;\frac{x}{1 + \frac{y \cdot b}{t}}\\

\mathbf{elif}\;y \leq -1.62 \cdot 10^{-37}:\\
\;\;\;\;\frac{z}{b}\\

\mathbf{elif}\;y \leq -1.8 \cdot 10^{-73}:\\
\;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a}\\

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

\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if y < -1.6999999999999999e39 or -8.9999999999999995e-24 < y < -1.6199999999999999e-37 or 8.3999999999999999e-10 < y

    1. Initial program 57.2%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*59.1%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified69.7%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in y around inf 55.3%

      \[\leadsto \color{blue}{\frac{z}{b}} \]

    if -1.6999999999999999e39 < y < -8.9999999999999995e-24

    1. Initial program 99.7%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*99.7%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified99.7%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in x around inf 71.3%

      \[\leadsto \color{blue}{\frac{x}{1 + \left(a + \frac{b \cdot y}{t}\right)}} \]
    6. Step-by-step derivation
      1. associate-*l/71.3%

        \[\leadsto \frac{x}{1 + \left(a + \color{blue}{\frac{b}{t} \cdot y}\right)} \]
      2. *-commutative71.3%

        \[\leadsto \frac{x}{1 + \left(a + \color{blue}{y \cdot \frac{b}{t}}\right)} \]
    7. Simplified71.3%

      \[\leadsto \color{blue}{\frac{x}{1 + \left(a + y \cdot \frac{b}{t}\right)}} \]
    8. Taylor expanded in a around 0 55.4%

      \[\leadsto \color{blue}{\frac{x}{1 + \frac{b \cdot y}{t}}} \]

    if -1.6199999999999999e-37 < y < -1.8e-73

    1. Initial program 100.0%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*86.4%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified86.4%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in a around inf 100.0%

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

    if -1.8e-73 < y < 8.3999999999999999e-10

    1. Initial program 94.7%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*82.5%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified79.0%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in y around 0 69.6%

      \[\leadsto \color{blue}{\frac{x}{1 + a}} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification62.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -1.7 \cdot 10^{+39}:\\ \;\;\;\;\frac{z}{b}\\ \mathbf{elif}\;y \leq -9 \cdot 10^{-24}:\\ \;\;\;\;\frac{x}{1 + \frac{y \cdot b}{t}}\\ \mathbf{elif}\;y \leq -1.62 \cdot 10^{-37}:\\ \;\;\;\;\frac{z}{b}\\ \mathbf{elif}\;y \leq -1.8 \cdot 10^{-73}:\\ \;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a}\\ \mathbf{elif}\;y \leq 8.4 \cdot 10^{-10}:\\ \;\;\;\;\frac{x}{a + 1}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \]
  5. Add Preprocessing

Alternative 9: 80.6% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -2.9 \cdot 10^{+201} \lor \neg \left(y \leq 2.5 \cdot 10^{+171}\right):\\ \;\;\;\;\frac{z}{b}\\ \mathbf{else}:\\ \;\;\;\;\frac{x + z \cdot \frac{y}{t}}{b \cdot \frac{y}{t} + \left(a + 1\right)}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (or (<= y -2.9e+201) (not (<= y 2.5e+171)))
   (/ z b)
   (/ (+ x (* z (/ y t))) (+ (* b (/ y t)) (+ a 1.0)))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if ((y <= -2.9e+201) || !(y <= 2.5e+171)) {
		tmp = z / b;
	} else {
		tmp = (x + (z * (y / t))) / ((b * (y / t)) + (a + 1.0));
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: tmp
    if ((y <= (-2.9d+201)) .or. (.not. (y <= 2.5d+171))) then
        tmp = z / b
    else
        tmp = (x + (z * (y / t))) / ((b * (y / t)) + (a + 1.0d0))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if ((y <= -2.9e+201) || !(y <= 2.5e+171)) {
		tmp = z / b;
	} else {
		tmp = (x + (z * (y / t))) / ((b * (y / t)) + (a + 1.0));
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if (y <= -2.9e+201) or not (y <= 2.5e+171):
		tmp = z / b
	else:
		tmp = (x + (z * (y / t))) / ((b * (y / t)) + (a + 1.0))
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if ((y <= -2.9e+201) || !(y <= 2.5e+171))
		tmp = Float64(z / b);
	else
		tmp = Float64(Float64(x + Float64(z * Float64(y / t))) / Float64(Float64(b * Float64(y / t)) + Float64(a + 1.0)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if ((y <= -2.9e+201) || ~((y <= 2.5e+171)))
		tmp = z / b;
	else
		tmp = (x + (z * (y / t))) / ((b * (y / t)) + (a + 1.0));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -2.9e+201], N[Not[LessEqual[y, 2.5e+171]], $MachinePrecision]], N[(z / b), $MachinePrecision], N[(N[(x + N[(z * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(b * N[(y / t), $MachinePrecision]), $MachinePrecision] + N[(a + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.9 \cdot 10^{+201} \lor \neg \left(y \leq 2.5 \cdot 10^{+171}\right):\\
\;\;\;\;\frac{z}{b}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -2.9000000000000002e201 or 2.5000000000000002e171 < y

    1. Initial program 25.5%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*28.1%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified47.4%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in y around inf 74.5%

      \[\leadsto \color{blue}{\frac{z}{b}} \]

    if -2.9000000000000002e201 < y < 2.5000000000000002e171

    1. Initial program 87.5%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. *-commutative87.5%

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

        \[\leadsto \frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \color{blue}{b \cdot \frac{y}{t}}} \]
    4. Applied egg-rr88.4%

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

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

        \[\leadsto \frac{x + \color{blue}{z \cdot \frac{y}{t}}}{\left(a + 1\right) + b \cdot \frac{y}{t}} \]
    6. Applied egg-rr89.3%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.9 \cdot 10^{+201} \lor \neg \left(y \leq 2.5 \cdot 10^{+171}\right):\\ \;\;\;\;\frac{z}{b}\\ \mathbf{else}:\\ \;\;\;\;\frac{x + z \cdot \frac{y}{t}}{b \cdot \frac{y}{t} + \left(a + 1\right)}\\ \end{array} \]
  5. Add Preprocessing

Alternative 10: 65.2% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -1.25 \cdot 10^{+157}:\\ \;\;\;\;\frac{z}{b}\\ \mathbf{elif}\;y \leq -5.6 \cdot 10^{-28}:\\ \;\;\;\;\frac{x}{1 + \left(a + y \cdot \frac{b}{t}\right)}\\ \mathbf{elif}\;y \leq 1.1 \cdot 10^{+49}:\\ \;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a + 1}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (<= y -1.25e+157)
   (/ z b)
   (if (<= y -5.6e-28)
     (/ x (+ 1.0 (+ a (* y (/ b t)))))
     (if (<= y 1.1e+49) (/ (+ x (/ (* y z) t)) (+ a 1.0)) (/ z b)))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (y <= -1.25e+157) {
		tmp = z / b;
	} else if (y <= -5.6e-28) {
		tmp = x / (1.0 + (a + (y * (b / t))));
	} else if (y <= 1.1e+49) {
		tmp = (x + ((y * z) / t)) / (a + 1.0);
	} else {
		tmp = z / b;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: tmp
    if (y <= (-1.25d+157)) then
        tmp = z / b
    else if (y <= (-5.6d-28)) then
        tmp = x / (1.0d0 + (a + (y * (b / t))))
    else if (y <= 1.1d+49) then
        tmp = (x + ((y * z) / t)) / (a + 1.0d0)
    else
        tmp = z / b
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (y <= -1.25e+157) {
		tmp = z / b;
	} else if (y <= -5.6e-28) {
		tmp = x / (1.0 + (a + (y * (b / t))));
	} else if (y <= 1.1e+49) {
		tmp = (x + ((y * z) / t)) / (a + 1.0);
	} else {
		tmp = z / b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if y <= -1.25e+157:
		tmp = z / b
	elif y <= -5.6e-28:
		tmp = x / (1.0 + (a + (y * (b / t))))
	elif y <= 1.1e+49:
		tmp = (x + ((y * z) / t)) / (a + 1.0)
	else:
		tmp = z / b
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (y <= -1.25e+157)
		tmp = Float64(z / b);
	elseif (y <= -5.6e-28)
		tmp = Float64(x / Float64(1.0 + Float64(a + Float64(y * Float64(b / t)))));
	elseif (y <= 1.1e+49)
		tmp = Float64(Float64(x + Float64(Float64(y * z) / t)) / Float64(a + 1.0));
	else
		tmp = Float64(z / b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (y <= -1.25e+157)
		tmp = z / b;
	elseif (y <= -5.6e-28)
		tmp = x / (1.0 + (a + (y * (b / t))));
	elseif (y <= 1.1e+49)
		tmp = (x + ((y * z) / t)) / (a + 1.0);
	else
		tmp = z / b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -1.25e+157], N[(z / b), $MachinePrecision], If[LessEqual[y, -5.6e-28], N[(x / N[(1.0 + N[(a + N[(y * N[(b / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.1e+49], N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / N[(a + 1.0), $MachinePrecision]), $MachinePrecision], N[(z / b), $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.25 \cdot 10^{+157}:\\
\;\;\;\;\frac{z}{b}\\

\mathbf{elif}\;y \leq -5.6 \cdot 10^{-28}:\\
\;\;\;\;\frac{x}{1 + \left(a + y \cdot \frac{b}{t}\right)}\\

\mathbf{elif}\;y \leq 1.1 \cdot 10^{+49}:\\
\;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a + 1}\\

\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -1.24999999999999994e157 or 1.1e49 < y

    1. Initial program 41.8%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*44.6%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified60.1%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in y around inf 64.0%

      \[\leadsto \color{blue}{\frac{z}{b}} \]

    if -1.24999999999999994e157 < y < -5.5999999999999996e-28

    1. Initial program 88.0%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*88.1%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified90.3%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in x around inf 58.3%

      \[\leadsto \color{blue}{\frac{x}{1 + \left(a + \frac{b \cdot y}{t}\right)}} \]
    6. Step-by-step derivation
      1. associate-*l/58.4%

        \[\leadsto \frac{x}{1 + \left(a + \color{blue}{\frac{b}{t} \cdot y}\right)} \]
      2. *-commutative58.4%

        \[\leadsto \frac{x}{1 + \left(a + \color{blue}{y \cdot \frac{b}{t}}\right)} \]
    7. Simplified58.4%

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

    if -5.5999999999999996e-28 < y < 1.1e49

    1. Initial program 94.2%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*83.4%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified80.5%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in b around 0 82.3%

      \[\leadsto \color{blue}{\frac{x + \frac{y \cdot z}{t}}{1 + a}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification72.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -1.25 \cdot 10^{+157}:\\ \;\;\;\;\frac{z}{b}\\ \mathbf{elif}\;y \leq -5.6 \cdot 10^{-28}:\\ \;\;\;\;\frac{x}{1 + \left(a + y \cdot \frac{b}{t}\right)}\\ \mathbf{elif}\;y \leq 1.1 \cdot 10^{+49}:\\ \;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a + 1}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \]
  5. Add Preprocessing

Alternative 11: 65.5% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -2.9 \cdot 10^{+152}:\\ \;\;\;\;\frac{z}{b}\\ \mathbf{elif}\;y \leq -2 \cdot 10^{-28}:\\ \;\;\;\;\frac{x + y \cdot \frac{z}{t}}{1 + b \cdot \frac{y}{t}}\\ \mathbf{elif}\;y \leq 3.8 \cdot 10^{+51}:\\ \;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a + 1}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (<= y -2.9e+152)
   (/ z b)
   (if (<= y -2e-28)
     (/ (+ x (* y (/ z t))) (+ 1.0 (* b (/ y t))))
     (if (<= y 3.8e+51) (/ (+ x (/ (* y z) t)) (+ a 1.0)) (/ z b)))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (y <= -2.9e+152) {
		tmp = z / b;
	} else if (y <= -2e-28) {
		tmp = (x + (y * (z / t))) / (1.0 + (b * (y / t)));
	} else if (y <= 3.8e+51) {
		tmp = (x + ((y * z) / t)) / (a + 1.0);
	} else {
		tmp = z / b;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: tmp
    if (y <= (-2.9d+152)) then
        tmp = z / b
    else if (y <= (-2d-28)) then
        tmp = (x + (y * (z / t))) / (1.0d0 + (b * (y / t)))
    else if (y <= 3.8d+51) then
        tmp = (x + ((y * z) / t)) / (a + 1.0d0)
    else
        tmp = z / b
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (y <= -2.9e+152) {
		tmp = z / b;
	} else if (y <= -2e-28) {
		tmp = (x + (y * (z / t))) / (1.0 + (b * (y / t)));
	} else if (y <= 3.8e+51) {
		tmp = (x + ((y * z) / t)) / (a + 1.0);
	} else {
		tmp = z / b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if y <= -2.9e+152:
		tmp = z / b
	elif y <= -2e-28:
		tmp = (x + (y * (z / t))) / (1.0 + (b * (y / t)))
	elif y <= 3.8e+51:
		tmp = (x + ((y * z) / t)) / (a + 1.0)
	else:
		tmp = z / b
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (y <= -2.9e+152)
		tmp = Float64(z / b);
	elseif (y <= -2e-28)
		tmp = Float64(Float64(x + Float64(y * Float64(z / t))) / Float64(1.0 + Float64(b * Float64(y / t))));
	elseif (y <= 3.8e+51)
		tmp = Float64(Float64(x + Float64(Float64(y * z) / t)) / Float64(a + 1.0));
	else
		tmp = Float64(z / b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (y <= -2.9e+152)
		tmp = z / b;
	elseif (y <= -2e-28)
		tmp = (x + (y * (z / t))) / (1.0 + (b * (y / t)));
	elseif (y <= 3.8e+51)
		tmp = (x + ((y * z) / t)) / (a + 1.0);
	else
		tmp = z / b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -2.9e+152], N[(z / b), $MachinePrecision], If[LessEqual[y, -2e-28], N[(N[(x + N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(1.0 + N[(b * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3.8e+51], N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / N[(a + 1.0), $MachinePrecision]), $MachinePrecision], N[(z / b), $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.9 \cdot 10^{+152}:\\
\;\;\;\;\frac{z}{b}\\

\mathbf{elif}\;y \leq -2 \cdot 10^{-28}:\\
\;\;\;\;\frac{x + y \cdot \frac{z}{t}}{1 + b \cdot \frac{y}{t}}\\

\mathbf{elif}\;y \leq 3.8 \cdot 10^{+51}:\\
\;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a + 1}\\

\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -2.8999999999999998e152 or 3.7999999999999997e51 < y

    1. Initial program 42.6%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*45.3%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified60.5%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in y around inf 63.3%

      \[\leadsto \color{blue}{\frac{z}{b}} \]

    if -2.8999999999999998e152 < y < -1.99999999999999994e-28

    1. Initial program 87.7%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*87.8%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified90.1%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in a around 0 68.6%

      \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\color{blue}{1 + \frac{b \cdot y}{t}}} \]
    6. Step-by-step derivation
      1. associate-*r/70.7%

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{1 + \color{blue}{b \cdot \frac{y}{t}}} \]
      2. *-commutative70.7%

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{1 + \color{blue}{\frac{y}{t} \cdot b}} \]
    7. Applied egg-rr70.7%

      \[\leadsto \frac{x + y \cdot \frac{z}{t}}{1 + \color{blue}{\frac{y}{t} \cdot b}} \]

    if -1.99999999999999994e-28 < y < 3.7999999999999997e51

    1. Initial program 94.2%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*83.4%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified80.5%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in b around 0 82.3%

      \[\leadsto \color{blue}{\frac{x + \frac{y \cdot z}{t}}{1 + a}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification74.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.9 \cdot 10^{+152}:\\ \;\;\;\;\frac{z}{b}\\ \mathbf{elif}\;y \leq -2 \cdot 10^{-28}:\\ \;\;\;\;\frac{x + y \cdot \frac{z}{t}}{1 + b \cdot \frac{y}{t}}\\ \mathbf{elif}\;y \leq 3.8 \cdot 10^{+51}:\\ \;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a + 1}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \]
  5. Add Preprocessing

Alternative 12: 42.6% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -7.5 \cdot 10^{-38}:\\ \;\;\;\;\frac{z}{b}\\ \mathbf{elif}\;y \leq -1.18 \cdot 10^{-247}:\\ \;\;\;\;\frac{x}{a}\\ \mathbf{elif}\;y \leq -6.6 \cdot 10^{-271}:\\ \;\;\;\;x\\ \mathbf{elif}\;y \leq 1.95 \cdot 10^{-78}:\\ \;\;\;\;\frac{x}{a}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (<= y -7.5e-38)
   (/ z b)
   (if (<= y -1.18e-247)
     (/ x a)
     (if (<= y -6.6e-271) x (if (<= y 1.95e-78) (/ x a) (/ z b))))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (y <= -7.5e-38) {
		tmp = z / b;
	} else if (y <= -1.18e-247) {
		tmp = x / a;
	} else if (y <= -6.6e-271) {
		tmp = x;
	} else if (y <= 1.95e-78) {
		tmp = x / a;
	} else {
		tmp = z / b;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: tmp
    if (y <= (-7.5d-38)) then
        tmp = z / b
    else if (y <= (-1.18d-247)) then
        tmp = x / a
    else if (y <= (-6.6d-271)) then
        tmp = x
    else if (y <= 1.95d-78) then
        tmp = x / a
    else
        tmp = z / b
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (y <= -7.5e-38) {
		tmp = z / b;
	} else if (y <= -1.18e-247) {
		tmp = x / a;
	} else if (y <= -6.6e-271) {
		tmp = x;
	} else if (y <= 1.95e-78) {
		tmp = x / a;
	} else {
		tmp = z / b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if y <= -7.5e-38:
		tmp = z / b
	elif y <= -1.18e-247:
		tmp = x / a
	elif y <= -6.6e-271:
		tmp = x
	elif y <= 1.95e-78:
		tmp = x / a
	else:
		tmp = z / b
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (y <= -7.5e-38)
		tmp = Float64(z / b);
	elseif (y <= -1.18e-247)
		tmp = Float64(x / a);
	elseif (y <= -6.6e-271)
		tmp = x;
	elseif (y <= 1.95e-78)
		tmp = Float64(x / a);
	else
		tmp = Float64(z / b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (y <= -7.5e-38)
		tmp = z / b;
	elseif (y <= -1.18e-247)
		tmp = x / a;
	elseif (y <= -6.6e-271)
		tmp = x;
	elseif (y <= 1.95e-78)
		tmp = x / a;
	else
		tmp = z / b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -7.5e-38], N[(z / b), $MachinePrecision], If[LessEqual[y, -1.18e-247], N[(x / a), $MachinePrecision], If[LessEqual[y, -6.6e-271], x, If[LessEqual[y, 1.95e-78], N[(x / a), $MachinePrecision], N[(z / b), $MachinePrecision]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -7.5 \cdot 10^{-38}:\\
\;\;\;\;\frac{z}{b}\\

\mathbf{elif}\;y \leq -1.18 \cdot 10^{-247}:\\
\;\;\;\;\frac{x}{a}\\

\mathbf{elif}\;y \leq -6.6 \cdot 10^{-271}:\\
\;\;\;\;x\\

\mathbf{elif}\;y \leq 1.95 \cdot 10^{-78}:\\
\;\;\;\;\frac{x}{a}\\

\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -7.5e-38 or 1.9500000000000001e-78 < y

    1. Initial program 62.7%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*63.0%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified71.9%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in y around inf 51.3%

      \[\leadsto \color{blue}{\frac{z}{b}} \]

    if -7.5e-38 < y < -1.17999999999999997e-247 or -6.6000000000000004e-271 < y < 1.9500000000000001e-78

    1. Initial program 96.0%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*84.3%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified80.4%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in x around inf 74.6%

      \[\leadsto \color{blue}{\frac{x}{1 + \left(a + \frac{b \cdot y}{t}\right)}} \]
    6. Step-by-step derivation
      1. associate-*l/70.7%

        \[\leadsto \frac{x}{1 + \left(a + \color{blue}{\frac{b}{t} \cdot y}\right)} \]
      2. *-commutative70.7%

        \[\leadsto \frac{x}{1 + \left(a + \color{blue}{y \cdot \frac{b}{t}}\right)} \]
    7. Simplified70.7%

      \[\leadsto \color{blue}{\frac{x}{1 + \left(a + y \cdot \frac{b}{t}\right)}} \]
    8. Taylor expanded in a around inf 48.5%

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

    if -1.17999999999999997e-247 < y < -6.6000000000000004e-271

    1. Initial program 100.0%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*86.3%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified86.3%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in a around 0 86.3%

      \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\color{blue}{1 + \frac{b \cdot y}{t}}} \]
    6. Taylor expanded in y around 0 87.1%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -7.5 \cdot 10^{-38}:\\ \;\;\;\;\frac{z}{b}\\ \mathbf{elif}\;y \leq -1.18 \cdot 10^{-247}:\\ \;\;\;\;\frac{x}{a}\\ \mathbf{elif}\;y \leq -6.6 \cdot 10^{-271}:\\ \;\;\;\;x\\ \mathbf{elif}\;y \leq 1.95 \cdot 10^{-78}:\\ \;\;\;\;\frac{x}{a}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{b}\\ \end{array} \]
  5. Add Preprocessing

Alternative 13: 59.8% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -1.85 \cdot 10^{+156} \lor \neg \left(y \leq 4.5 \cdot 10^{+52}\right):\\ \;\;\;\;\frac{z}{b}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{1 + \left(a + y \cdot \frac{b}{t}\right)}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (or (<= y -1.85e+156) (not (<= y 4.5e+52)))
   (/ z b)
   (/ x (+ 1.0 (+ a (* y (/ b t)))))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if ((y <= -1.85e+156) || !(y <= 4.5e+52)) {
		tmp = z / b;
	} else {
		tmp = x / (1.0 + (a + (y * (b / t))));
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: tmp
    if ((y <= (-1.85d+156)) .or. (.not. (y <= 4.5d+52))) then
        tmp = z / b
    else
        tmp = x / (1.0d0 + (a + (y * (b / t))))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if ((y <= -1.85e+156) || !(y <= 4.5e+52)) {
		tmp = z / b;
	} else {
		tmp = x / (1.0 + (a + (y * (b / t))));
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if (y <= -1.85e+156) or not (y <= 4.5e+52):
		tmp = z / b
	else:
		tmp = x / (1.0 + (a + (y * (b / t))))
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if ((y <= -1.85e+156) || !(y <= 4.5e+52))
		tmp = Float64(z / b);
	else
		tmp = Float64(x / Float64(1.0 + Float64(a + Float64(y * Float64(b / t)))));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if ((y <= -1.85e+156) || ~((y <= 4.5e+52)))
		tmp = z / b;
	else
		tmp = x / (1.0 + (a + (y * (b / t))));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -1.85e+156], N[Not[LessEqual[y, 4.5e+52]], $MachinePrecision]], N[(z / b), $MachinePrecision], N[(x / N[(1.0 + N[(a + N[(y * N[(b / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.85 \cdot 10^{+156} \lor \neg \left(y \leq 4.5 \cdot 10^{+52}\right):\\
\;\;\;\;\frac{z}{b}\\

\mathbf{else}:\\
\;\;\;\;\frac{x}{1 + \left(a + y \cdot \frac{b}{t}\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -1.85000000000000001e156 or 4.5e52 < y

    1. Initial program 41.8%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*44.6%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified60.1%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in y around inf 64.0%

      \[\leadsto \color{blue}{\frac{z}{b}} \]

    if -1.85000000000000001e156 < y < 4.5e52

    1. Initial program 92.7%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*84.5%

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

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

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in x around inf 66.8%

      \[\leadsto \color{blue}{\frac{x}{1 + \left(a + \frac{b \cdot y}{t}\right)}} \]
    6. Step-by-step derivation
      1. associate-*l/64.7%

        \[\leadsto \frac{x}{1 + \left(a + \color{blue}{\frac{b}{t} \cdot y}\right)} \]
      2. *-commutative64.7%

        \[\leadsto \frac{x}{1 + \left(a + \color{blue}{y \cdot \frac{b}{t}}\right)} \]
    7. Simplified64.7%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -1.85 \cdot 10^{+156} \lor \neg \left(y \leq 4.5 \cdot 10^{+52}\right):\\ \;\;\;\;\frac{z}{b}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{1 + \left(a + y \cdot \frac{b}{t}\right)}\\ \end{array} \]
  5. Add Preprocessing

Alternative 14: 61.3% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -2 \cdot 10^{+156} \lor \neg \left(y \leq 3.1 \cdot 10^{+50}\right):\\ \;\;\;\;\frac{z}{b}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{1 + \left(a + \frac{y \cdot b}{t}\right)}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (or (<= y -2e+156) (not (<= y 3.1e+50)))
   (/ z b)
   (/ x (+ 1.0 (+ a (/ (* y b) t))))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if ((y <= -2e+156) || !(y <= 3.1e+50)) {
		tmp = z / b;
	} else {
		tmp = x / (1.0 + (a + ((y * b) / t)));
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: tmp
    if ((y <= (-2d+156)) .or. (.not. (y <= 3.1d+50))) then
        tmp = z / b
    else
        tmp = x / (1.0d0 + (a + ((y * b) / t)))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if ((y <= -2e+156) || !(y <= 3.1e+50)) {
		tmp = z / b;
	} else {
		tmp = x / (1.0 + (a + ((y * b) / t)));
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if (y <= -2e+156) or not (y <= 3.1e+50):
		tmp = z / b
	else:
		tmp = x / (1.0 + (a + ((y * b) / t)))
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if ((y <= -2e+156) || !(y <= 3.1e+50))
		tmp = Float64(z / b);
	else
		tmp = Float64(x / Float64(1.0 + Float64(a + Float64(Float64(y * b) / t))));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if ((y <= -2e+156) || ~((y <= 3.1e+50)))
		tmp = z / b;
	else
		tmp = x / (1.0 + (a + ((y * b) / t)));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -2e+156], N[Not[LessEqual[y, 3.1e+50]], $MachinePrecision]], N[(z / b), $MachinePrecision], N[(x / N[(1.0 + N[(a + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -2 \cdot 10^{+156} \lor \neg \left(y \leq 3.1 \cdot 10^{+50}\right):\\
\;\;\;\;\frac{z}{b}\\

\mathbf{else}:\\
\;\;\;\;\frac{x}{1 + \left(a + \frac{y \cdot b}{t}\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -2e156 or 3.10000000000000003e50 < y

    1. Initial program 41.8%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*44.6%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified60.1%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in y around inf 64.0%

      \[\leadsto \color{blue}{\frac{z}{b}} \]

    if -2e156 < y < 3.10000000000000003e50

    1. Initial program 92.7%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*84.5%

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

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

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in x around inf 66.8%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2 \cdot 10^{+156} \lor \neg \left(y \leq 3.1 \cdot 10^{+50}\right):\\ \;\;\;\;\frac{z}{b}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{1 + \left(a + \frac{y \cdot b}{t}\right)}\\ \end{array} \]
  5. Add Preprocessing

Alternative 15: 55.5% accurate, 1.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -4 \cdot 10^{+73} \lor \neg \left(y \leq 1.4 \cdot 10^{-12}\right):\\ \;\;\;\;\frac{z}{b}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{a + 1}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (or (<= y -4e+73) (not (<= y 1.4e-12))) (/ z b) (/ x (+ a 1.0))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if ((y <= -4e+73) || !(y <= 1.4e-12)) {
		tmp = z / b;
	} else {
		tmp = x / (a + 1.0);
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: tmp
    if ((y <= (-4d+73)) .or. (.not. (y <= 1.4d-12))) then
        tmp = z / b
    else
        tmp = x / (a + 1.0d0)
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if ((y <= -4e+73) || !(y <= 1.4e-12)) {
		tmp = z / b;
	} else {
		tmp = x / (a + 1.0);
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if (y <= -4e+73) or not (y <= 1.4e-12):
		tmp = z / b
	else:
		tmp = x / (a + 1.0)
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if ((y <= -4e+73) || !(y <= 1.4e-12))
		tmp = Float64(z / b);
	else
		tmp = Float64(x / Float64(a + 1.0));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if ((y <= -4e+73) || ~((y <= 1.4e-12)))
		tmp = z / b;
	else
		tmp = x / (a + 1.0);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -4e+73], N[Not[LessEqual[y, 1.4e-12]], $MachinePrecision]], N[(z / b), $MachinePrecision], N[(x / N[(a + 1.0), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -4 \cdot 10^{+73} \lor \neg \left(y \leq 1.4 \cdot 10^{-12}\right):\\
\;\;\;\;\frac{z}{b}\\

\mathbf{else}:\\
\;\;\;\;\frac{x}{a + 1}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -3.99999999999999993e73 or 1.4000000000000001e-12 < y

    1. Initial program 54.1%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*56.1%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified67.6%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in y around inf 57.2%

      \[\leadsto \color{blue}{\frac{z}{b}} \]

    if -3.99999999999999993e73 < y < 1.4000000000000001e-12

    1. Initial program 93.4%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*83.6%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified81.5%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in y around 0 62.7%

      \[\leadsto \color{blue}{\frac{x}{1 + a}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification60.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -4 \cdot 10^{+73} \lor \neg \left(y \leq 1.4 \cdot 10^{-12}\right):\\ \;\;\;\;\frac{z}{b}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{a + 1}\\ \end{array} \]
  5. Add Preprocessing

Alternative 16: 39.7% accurate, 1.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;a \leq -8 \cdot 10^{-23} \lor \neg \left(a \leq 7.2 \cdot 10^{+22}\right):\\ \;\;\;\;\frac{x}{a}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (or (<= a -8e-23) (not (<= a 7.2e+22))) (/ x a) x))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if ((a <= -8e-23) || !(a <= 7.2e+22)) {
		tmp = x / a;
	} else {
		tmp = x;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: tmp
    if ((a <= (-8d-23)) .or. (.not. (a <= 7.2d+22))) then
        tmp = x / a
    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 tmp;
	if ((a <= -8e-23) || !(a <= 7.2e+22)) {
		tmp = x / a;
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if (a <= -8e-23) or not (a <= 7.2e+22):
		tmp = x / a
	else:
		tmp = x
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if ((a <= -8e-23) || !(a <= 7.2e+22))
		tmp = Float64(x / a);
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if ((a <= -8e-23) || ~((a <= 7.2e+22)))
		tmp = x / a;
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[a, -8e-23], N[Not[LessEqual[a, 7.2e+22]], $MachinePrecision]], N[(x / a), $MachinePrecision], x]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;a \leq -8 \cdot 10^{-23} \lor \neg \left(a \leq 7.2 \cdot 10^{+22}\right):\\
\;\;\;\;\frac{x}{a}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if a < -7.99999999999999968e-23 or 7.2e22 < a

    1. Initial program 73.3%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*67.1%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified72.0%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in x around inf 52.2%

      \[\leadsto \color{blue}{\frac{x}{1 + \left(a + \frac{b \cdot y}{t}\right)}} \]
    6. Step-by-step derivation
      1. associate-*l/53.0%

        \[\leadsto \frac{x}{1 + \left(a + \color{blue}{\frac{b}{t} \cdot y}\right)} \]
      2. *-commutative53.0%

        \[\leadsto \frac{x}{1 + \left(a + \color{blue}{y \cdot \frac{b}{t}}\right)} \]
    7. Simplified53.0%

      \[\leadsto \color{blue}{\frac{x}{1 + \left(a + y \cdot \frac{b}{t}\right)}} \]
    8. Taylor expanded in a around inf 46.6%

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

    if -7.99999999999999968e-23 < a < 7.2e22

    1. Initial program 80.4%

      \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
    2. Step-by-step derivation
      1. associate-/l*77.3%

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

        \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
    3. Simplified79.7%

      \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
    4. Add Preprocessing
    5. Taylor expanded in a around 0 77.0%

      \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\color{blue}{1 + \frac{b \cdot y}{t}}} \]
    6. Taylor expanded in y around 0 36.4%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -8 \cdot 10^{-23} \lor \neg \left(a \leq 7.2 \cdot 10^{+22}\right):\\ \;\;\;\;\frac{x}{a}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]
  5. Add Preprocessing

Alternative 17: 19.4% accurate, 17.0× speedup?

\[\begin{array}{l} \\ x \end{array} \]
(FPCore (x y z t a b) :precision binary64 x)
double code(double x, double y, double z, double t, double a, double b) {
	return x;
}
real(8) function code(x, y, z, t, a, b)
    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
    code = x
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	return x;
}
def code(x, y, z, t, a, b):
	return x
function code(x, y, z, t, a, b)
	return x
end
function tmp = code(x, y, z, t, a, b)
	tmp = x;
end
code[x_, y_, z_, t_, a_, b_] := x
\begin{array}{l}

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

    \[\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}} \]
  2. Step-by-step derivation
    1. associate-/l*71.9%

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

      \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \color{blue}{y \cdot \frac{b}{t}}} \]
  3. Simplified75.6%

    \[\leadsto \color{blue}{\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}} \]
  4. Add Preprocessing
  5. Taylor expanded in a around 0 44.6%

    \[\leadsto \frac{x + y \cdot \frac{z}{t}}{\color{blue}{1 + \frac{b \cdot y}{t}}} \]
  6. Taylor expanded in y around 0 19.1%

    \[\leadsto \color{blue}{x} \]
  7. Final simplification19.1%

    \[\leadsto x \]
  8. Add Preprocessing

Developer target: 79.0% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := 1 \cdot \left(\left(x + \frac{y}{t} \cdot z\right) \cdot \frac{1}{\left(a + 1\right) + \frac{y}{t} \cdot b}\right)\\ \mathbf{if}\;t < -1.3659085366310088 \cdot 10^{-271}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t < 3.036967103737246 \cdot 10^{-130}:\\ \;\;\;\;\frac{z}{b}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1
         (* 1.0 (* (+ x (* (/ y t) z)) (/ 1.0 (+ (+ a 1.0) (* (/ y t) b)))))))
   (if (< t -1.3659085366310088e-271)
     t_1
     (if (< t 3.036967103737246e-130) (/ z b) t_1))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = 1.0 * ((x + ((y / t) * z)) * (1.0 / ((a + 1.0) + ((y / t) * b))));
	double tmp;
	if (t < -1.3659085366310088e-271) {
		tmp = t_1;
	} else if (t < 3.036967103737246e-130) {
		tmp = z / b;
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: t_1
    real(8) :: tmp
    t_1 = 1.0d0 * ((x + ((y / t) * z)) * (1.0d0 / ((a + 1.0d0) + ((y / t) * b))))
    if (t < (-1.3659085366310088d-271)) then
        tmp = t_1
    else if (t < 3.036967103737246d-130) then
        tmp = z / b
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = 1.0 * ((x + ((y / t) * z)) * (1.0 / ((a + 1.0) + ((y / t) * b))));
	double tmp;
	if (t < -1.3659085366310088e-271) {
		tmp = t_1;
	} else if (t < 3.036967103737246e-130) {
		tmp = z / b;
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = 1.0 * ((x + ((y / t) * z)) * (1.0 / ((a + 1.0) + ((y / t) * b))))
	tmp = 0
	if t < -1.3659085366310088e-271:
		tmp = t_1
	elif t < 3.036967103737246e-130:
		tmp = z / b
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(1.0 * Float64(Float64(x + Float64(Float64(y / t) * z)) * Float64(1.0 / Float64(Float64(a + 1.0) + Float64(Float64(y / t) * b)))))
	tmp = 0.0
	if (t < -1.3659085366310088e-271)
		tmp = t_1;
	elseif (t < 3.036967103737246e-130)
		tmp = Float64(z / b);
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = 1.0 * ((x + ((y / t) * z)) * (1.0 / ((a + 1.0) + ((y / t) * b))));
	tmp = 0.0;
	if (t < -1.3659085366310088e-271)
		tmp = t_1;
	elseif (t < 3.036967103737246e-130)
		tmp = z / b;
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(1.0 * N[(N[(x + N[(N[(y / t), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision] * N[(1.0 / N[(N[(a + 1.0), $MachinePrecision] + N[(N[(y / t), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Less[t, -1.3659085366310088e-271], t$95$1, If[Less[t, 3.036967103737246e-130], N[(z / b), $MachinePrecision], t$95$1]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := 1 \cdot \left(\left(x + \frac{y}{t} \cdot z\right) \cdot \frac{1}{\left(a + 1\right) + \frac{y}{t} \cdot b}\right)\\
\mathbf{if}\;t < -1.3659085366310088 \cdot 10^{-271}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t < 3.036967103737246 \cdot 10^{-130}:\\
\;\;\;\;\frac{z}{b}\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}

Reproduce

?
herbie shell --seed 2024050 
(FPCore (x y z t a b)
  :name "Diagrams.Solve.Tridiagonal:solveCyclicTriDiagonal from diagrams-solve-0.1, B"
  :precision binary64

  :alt
  (if (< t -1.3659085366310088e-271) (* 1.0 (* (+ x (* (/ y t) z)) (/ 1.0 (+ (+ a 1.0) (* (/ y t) b))))) (if (< t 3.036967103737246e-130) (/ z b) (* 1.0 (* (+ x (* (/ y t) z)) (/ 1.0 (+ (+ a 1.0) (* (/ y t) b)))))))

  (/ (+ x (/ (* y z) t)) (+ (+ a 1.0) (/ (* y b) t))))