Statistics.Distribution.Beta:$centropy from math-functions-0.1.5.2

Percentage Accurate: 95.2% → 98.1%
Time: 17.2s
Alternatives: 23
Speedup: 0.5×

Specification

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

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

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

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

Accuracy vs Speed?

Herbie found 23 alternatives:

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

Initial Program: 95.2% accurate, 1.0× speedup?

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

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

Alternative 1: 98.1% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(\left(x + z \cdot \left(1 - y\right)\right) + a \cdot \left(1 - t\right)\right) + b \cdot \left(\left(y + t\right) - 2\right)\\ \mathbf{if}\;t\_1 \leq \infty:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t \cdot \left(b - a\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1
         (+ (+ (+ x (* z (- 1.0 y))) (* a (- 1.0 t))) (* b (- (+ y t) 2.0)))))
   (if (<= t_1 INFINITY) t_1 (* t (- b a)))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = ((x + (z * (1.0 - y))) + (a * (1.0 - t))) + (b * ((y + t) - 2.0));
	double tmp;
	if (t_1 <= ((double) INFINITY)) {
		tmp = t_1;
	} else {
		tmp = t * (b - a);
	}
	return tmp;
}
public static double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = ((x + (z * (1.0 - y))) + (a * (1.0 - t))) + (b * ((y + t) - 2.0));
	double tmp;
	if (t_1 <= Double.POSITIVE_INFINITY) {
		tmp = t_1;
	} else {
		tmp = t * (b - a);
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = ((x + (z * (1.0 - y))) + (a * (1.0 - t))) + (b * ((y + t) - 2.0))
	tmp = 0
	if t_1 <= math.inf:
		tmp = t_1
	else:
		tmp = t * (b - a)
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(Float64(Float64(x + Float64(z * Float64(1.0 - y))) + Float64(a * Float64(1.0 - t))) + Float64(b * Float64(Float64(y + t) - 2.0)))
	tmp = 0.0
	if (t_1 <= Inf)
		tmp = t_1;
	else
		tmp = Float64(t * Float64(b - a));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = ((x + (z * (1.0 - y))) + (a * (1.0 - t))) + (b * ((y + t) - 2.0));
	tmp = 0.0;
	if (t_1 <= Inf)
		tmp = t_1;
	else
		tmp = t * (b - a);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[(x + N[(z * N[(1.0 - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, Infinity], t$95$1, N[(t * N[(b - a), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

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

\mathbf{else}:\\
\;\;\;\;t \cdot \left(b - a\right)\\


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

    1. Initial program 100.0%

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

    if +inf.0 < (+.f64 (-.f64 (-.f64 x (*.f64 (-.f64 y 1) z)) (*.f64 (-.f64 t 1) a)) (*.f64 (-.f64 (+.f64 y t) 2) b))

    1. Initial program 0.0%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 70.2%

      \[\leadsto \color{blue}{t \cdot \left(b - a\right)} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification98.8%

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

Alternative 2: 97.6% accurate, 0.1× speedup?

\[\begin{array}{l} \\ \mathsf{fma}\left(y + \left(t + -2\right), b, x - \mathsf{fma}\left(y + -1, z, a \cdot \left(t + -1\right)\right)\right) \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (fma (+ y (+ t -2.0)) b (- x (fma (+ y -1.0) z (* a (+ t -1.0))))))
double code(double x, double y, double z, double t, double a, double b) {
	return fma((y + (t + -2.0)), b, (x - fma((y + -1.0), z, (a * (t + -1.0)))));
}
function code(x, y, z, t, a, b)
	return fma(Float64(y + Float64(t + -2.0)), b, Float64(x - fma(Float64(y + -1.0), z, Float64(a * Float64(t + -1.0)))))
end
code[x_, y_, z_, t_, a_, b_] := N[(N[(y + N[(t + -2.0), $MachinePrecision]), $MachinePrecision] * b + N[(x - N[(N[(y + -1.0), $MachinePrecision] * z + N[(a * N[(t + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\mathsf{fma}\left(y + \left(t + -2\right), b, x - \mathsf{fma}\left(y + -1, z, a \cdot \left(t + -1\right)\right)\right)
\end{array}
Derivation
  1. Initial program 96.1%

    \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
  2. Step-by-step derivation
    1. +-commutative96.1%

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

      \[\leadsto \color{blue}{\mathsf{fma}\left(\left(y + t\right) - 2, b, \left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right)} \]
    3. associate--l+97.2%

      \[\leadsto \mathsf{fma}\left(\color{blue}{y + \left(t - 2\right)}, b, \left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) \]
    4. sub-neg97.2%

      \[\leadsto \mathsf{fma}\left(y + \color{blue}{\left(t + \left(-2\right)\right)}, b, \left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) \]
    5. metadata-eval97.2%

      \[\leadsto \mathsf{fma}\left(y + \left(t + \color{blue}{-2}\right), b, \left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) \]
    6. sub-neg97.2%

      \[\leadsto \mathsf{fma}\left(y + \left(t + -2\right), b, \color{blue}{\left(x - \left(y - 1\right) \cdot z\right) + \left(-\left(t - 1\right) \cdot a\right)}\right) \]
    7. associate-+l-97.2%

      \[\leadsto \mathsf{fma}\left(y + \left(t + -2\right), b, \color{blue}{x - \left(\left(y - 1\right) \cdot z - \left(-\left(t - 1\right) \cdot a\right)\right)}\right) \]
    8. fma-neg97.6%

      \[\leadsto \mathsf{fma}\left(y + \left(t + -2\right), b, x - \color{blue}{\mathsf{fma}\left(y - 1, z, -\left(-\left(t - 1\right) \cdot a\right)\right)}\right) \]
    9. sub-neg97.6%

      \[\leadsto \mathsf{fma}\left(y + \left(t + -2\right), b, x - \mathsf{fma}\left(\color{blue}{y + \left(-1\right)}, z, -\left(-\left(t - 1\right) \cdot a\right)\right)\right) \]
    10. metadata-eval97.6%

      \[\leadsto \mathsf{fma}\left(y + \left(t + -2\right), b, x - \mathsf{fma}\left(y + \color{blue}{-1}, z, -\left(-\left(t - 1\right) \cdot a\right)\right)\right) \]
    11. remove-double-neg97.6%

      \[\leadsto \mathsf{fma}\left(y + \left(t + -2\right), b, x - \mathsf{fma}\left(y + -1, z, \color{blue}{\left(t - 1\right) \cdot a}\right)\right) \]
    12. sub-neg97.6%

      \[\leadsto \mathsf{fma}\left(y + \left(t + -2\right), b, x - \mathsf{fma}\left(y + -1, z, \color{blue}{\left(t + \left(-1\right)\right)} \cdot a\right)\right) \]
    13. metadata-eval97.6%

      \[\leadsto \mathsf{fma}\left(y + \left(t + -2\right), b, x - \mathsf{fma}\left(y + -1, z, \left(t + \color{blue}{-1}\right) \cdot a\right)\right) \]
  3. Simplified97.6%

    \[\leadsto \color{blue}{\mathsf{fma}\left(y + \left(t + -2\right), b, x - \mathsf{fma}\left(y + -1, z, \left(t + -1\right) \cdot a\right)\right)} \]
  4. Add Preprocessing
  5. Final simplification97.6%

    \[\leadsto \mathsf{fma}\left(y + \left(t + -2\right), b, x - \mathsf{fma}\left(y + -1, z, a \cdot \left(t + -1\right)\right)\right) \]
  6. Add Preprocessing

Alternative 3: 36.2% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := a \cdot \left(1 - t\right)\\ t_2 := b \cdot \left(y - 2\right)\\ \mathbf{if}\;b \leq -5.8 \cdot 10^{+182}:\\ \;\;\;\;t \cdot b\\ \mathbf{elif}\;b \leq -280000000000:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;b \leq 3.4 \cdot 10^{-271}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;b \leq 6.5 \cdot 10^{-238}:\\ \;\;\;\;x\\ \mathbf{elif}\;b \leq 0.061:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;b \leq 1.1 \cdot 10^{+38}:\\ \;\;\;\;t \cdot b\\ \mathbf{elif}\;b \leq 1.1 \cdot 10^{+149}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;b \leq 5.2 \cdot 10^{+207}:\\ \;\;\;\;t \cdot b\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (* a (- 1.0 t))) (t_2 (* b (- y 2.0))))
   (if (<= b -5.8e+182)
     (* t b)
     (if (<= b -280000000000.0)
       t_2
       (if (<= b 3.4e-271)
         t_1
         (if (<= b 6.5e-238)
           x
           (if (<= b 0.061)
             t_1
             (if (<= b 1.1e+38)
               (* t b)
               (if (<= b 1.1e+149)
                 t_1
                 (if (<= b 5.2e+207) (* t b) t_2))))))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = a * (1.0 - t);
	double t_2 = b * (y - 2.0);
	double tmp;
	if (b <= -5.8e+182) {
		tmp = t * b;
	} else if (b <= -280000000000.0) {
		tmp = t_2;
	} else if (b <= 3.4e-271) {
		tmp = t_1;
	} else if (b <= 6.5e-238) {
		tmp = x;
	} else if (b <= 0.061) {
		tmp = t_1;
	} else if (b <= 1.1e+38) {
		tmp = t * b;
	} else if (b <= 1.1e+149) {
		tmp = t_1;
	} else if (b <= 5.2e+207) {
		tmp = t * b;
	} else {
		tmp = t_2;
	}
	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 = a * (1.0d0 - t)
    t_2 = b * (y - 2.0d0)
    if (b <= (-5.8d+182)) then
        tmp = t * b
    else if (b <= (-280000000000.0d0)) then
        tmp = t_2
    else if (b <= 3.4d-271) then
        tmp = t_1
    else if (b <= 6.5d-238) then
        tmp = x
    else if (b <= 0.061d0) then
        tmp = t_1
    else if (b <= 1.1d+38) then
        tmp = t * b
    else if (b <= 1.1d+149) then
        tmp = t_1
    else if (b <= 5.2d+207) then
        tmp = t * b
    else
        tmp = t_2
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = a * (1.0 - t);
	double t_2 = b * (y - 2.0);
	double tmp;
	if (b <= -5.8e+182) {
		tmp = t * b;
	} else if (b <= -280000000000.0) {
		tmp = t_2;
	} else if (b <= 3.4e-271) {
		tmp = t_1;
	} else if (b <= 6.5e-238) {
		tmp = x;
	} else if (b <= 0.061) {
		tmp = t_1;
	} else if (b <= 1.1e+38) {
		tmp = t * b;
	} else if (b <= 1.1e+149) {
		tmp = t_1;
	} else if (b <= 5.2e+207) {
		tmp = t * b;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = a * (1.0 - t)
	t_2 = b * (y - 2.0)
	tmp = 0
	if b <= -5.8e+182:
		tmp = t * b
	elif b <= -280000000000.0:
		tmp = t_2
	elif b <= 3.4e-271:
		tmp = t_1
	elif b <= 6.5e-238:
		tmp = x
	elif b <= 0.061:
		tmp = t_1
	elif b <= 1.1e+38:
		tmp = t * b
	elif b <= 1.1e+149:
		tmp = t_1
	elif b <= 5.2e+207:
		tmp = t * b
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(a * Float64(1.0 - t))
	t_2 = Float64(b * Float64(y - 2.0))
	tmp = 0.0
	if (b <= -5.8e+182)
		tmp = Float64(t * b);
	elseif (b <= -280000000000.0)
		tmp = t_2;
	elseif (b <= 3.4e-271)
		tmp = t_1;
	elseif (b <= 6.5e-238)
		tmp = x;
	elseif (b <= 0.061)
		tmp = t_1;
	elseif (b <= 1.1e+38)
		tmp = Float64(t * b);
	elseif (b <= 1.1e+149)
		tmp = t_1;
	elseif (b <= 5.2e+207)
		tmp = Float64(t * b);
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = a * (1.0 - t);
	t_2 = b * (y - 2.0);
	tmp = 0.0;
	if (b <= -5.8e+182)
		tmp = t * b;
	elseif (b <= -280000000000.0)
		tmp = t_2;
	elseif (b <= 3.4e-271)
		tmp = t_1;
	elseif (b <= 6.5e-238)
		tmp = x;
	elseif (b <= 0.061)
		tmp = t_1;
	elseif (b <= 1.1e+38)
		tmp = t * b;
	elseif (b <= 1.1e+149)
		tmp = t_1;
	elseif (b <= 5.2e+207)
		tmp = t * b;
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(b * N[(y - 2.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -5.8e+182], N[(t * b), $MachinePrecision], If[LessEqual[b, -280000000000.0], t$95$2, If[LessEqual[b, 3.4e-271], t$95$1, If[LessEqual[b, 6.5e-238], x, If[LessEqual[b, 0.061], t$95$1, If[LessEqual[b, 1.1e+38], N[(t * b), $MachinePrecision], If[LessEqual[b, 1.1e+149], t$95$1, If[LessEqual[b, 5.2e+207], N[(t * b), $MachinePrecision], t$95$2]]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := a \cdot \left(1 - t\right)\\
t_2 := b \cdot \left(y - 2\right)\\
\mathbf{if}\;b \leq -5.8 \cdot 10^{+182}:\\
\;\;\;\;t \cdot b\\

\mathbf{elif}\;b \leq -280000000000:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;b \leq 3.4 \cdot 10^{-271}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;b \leq 6.5 \cdot 10^{-238}:\\
\;\;\;\;x\\

\mathbf{elif}\;b \leq 0.061:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;b \leq 1.1 \cdot 10^{+38}:\\
\;\;\;\;t \cdot b\\

\mathbf{elif}\;b \leq 1.1 \cdot 10^{+149}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;b \leq 5.2 \cdot 10^{+207}:\\
\;\;\;\;t \cdot b\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if b < -5.7999999999999997e182 or 0.060999999999999999 < b < 1.10000000000000003e38 or 1.1e149 < b < 5.1999999999999996e207

    1. Initial program 94.3%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in a around 0 96.2%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - z \cdot \left(y - 1\right)} \]
    4. Taylor expanded in t around inf 61.5%

      \[\leadsto \color{blue}{b \cdot t} \]

    if -5.7999999999999997e182 < b < -2.8e11 or 5.1999999999999996e207 < b

    1. Initial program 92.8%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 71.0%

      \[\leadsto \color{blue}{-1 \cdot \left(a \cdot t\right)} + \left(\left(y + t\right) - 2\right) \cdot b \]
    4. Step-by-step derivation
      1. mul-1-neg71.0%

        \[\leadsto \color{blue}{\left(-a \cdot t\right)} + \left(\left(y + t\right) - 2\right) \cdot b \]
      2. distribute-rgt-neg-in71.0%

        \[\leadsto \color{blue}{a \cdot \left(-t\right)} + \left(\left(y + t\right) - 2\right) \cdot b \]
    5. Simplified71.0%

      \[\leadsto \color{blue}{a \cdot \left(-t\right)} + \left(\left(y + t\right) - 2\right) \cdot b \]
    6. Taylor expanded in t around 0 51.9%

      \[\leadsto \color{blue}{b \cdot \left(y - 2\right)} \]

    if -2.8e11 < b < 3.4000000000000001e-271 or 6.5000000000000006e-238 < b < 0.060999999999999999 or 1.10000000000000003e38 < b < 1.1e149

    1. Initial program 98.5%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in a around inf 47.5%

      \[\leadsto \color{blue}{a \cdot \left(1 - t\right)} \]

    if 3.4000000000000001e-271 < b < 6.5000000000000006e-238

    1. Initial program 90.9%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 63.4%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -5.8 \cdot 10^{+182}:\\ \;\;\;\;t \cdot b\\ \mathbf{elif}\;b \leq -280000000000:\\ \;\;\;\;b \cdot \left(y - 2\right)\\ \mathbf{elif}\;b \leq 3.4 \cdot 10^{-271}:\\ \;\;\;\;a \cdot \left(1 - t\right)\\ \mathbf{elif}\;b \leq 6.5 \cdot 10^{-238}:\\ \;\;\;\;x\\ \mathbf{elif}\;b \leq 0.061:\\ \;\;\;\;a \cdot \left(1 - t\right)\\ \mathbf{elif}\;b \leq 1.1 \cdot 10^{+38}:\\ \;\;\;\;t \cdot b\\ \mathbf{elif}\;b \leq 1.1 \cdot 10^{+149}:\\ \;\;\;\;a \cdot \left(1 - t\right)\\ \mathbf{elif}\;b \leq 5.2 \cdot 10^{+207}:\\ \;\;\;\;t \cdot b\\ \mathbf{else}:\\ \;\;\;\;b \cdot \left(y - 2\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 50.1% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x + t \cdot b\\ t_2 := t \cdot \left(b - a\right)\\ t_3 := y \cdot \left(b - z\right)\\ t_4 := a \cdot \left(1 - t\right)\\ \mathbf{if}\;y \leq -2.85 \cdot 10^{+32}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;y \leq -2.4 \cdot 10^{-96}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq -1.05 \cdot 10^{-284}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y \leq 9.5 \cdot 10^{-290}:\\ \;\;\;\;t\_4\\ \mathbf{elif}\;y \leq 2.6 \cdot 10^{-281}:\\ \;\;\;\;-2 \cdot b\\ \mathbf{elif}\;y \leq 2.95 \cdot 10^{-162}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y \leq 1.7 \cdot 10^{-126}:\\ \;\;\;\;t\_4\\ \mathbf{elif}\;y \leq 5.6 \cdot 10^{+36}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t\_3\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (+ x (* t b)))
        (t_2 (* t (- b a)))
        (t_3 (* y (- b z)))
        (t_4 (* a (- 1.0 t))))
   (if (<= y -2.85e+32)
     t_3
     (if (<= y -2.4e-96)
       t_1
       (if (<= y -1.05e-284)
         t_2
         (if (<= y 9.5e-290)
           t_4
           (if (<= y 2.6e-281)
             (* -2.0 b)
             (if (<= y 2.95e-162)
               t_2
               (if (<= y 1.7e-126) t_4 (if (<= y 5.6e+36) t_1 t_3))))))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = x + (t * b);
	double t_2 = t * (b - a);
	double t_3 = y * (b - z);
	double t_4 = a * (1.0 - t);
	double tmp;
	if (y <= -2.85e+32) {
		tmp = t_3;
	} else if (y <= -2.4e-96) {
		tmp = t_1;
	} else if (y <= -1.05e-284) {
		tmp = t_2;
	} else if (y <= 9.5e-290) {
		tmp = t_4;
	} else if (y <= 2.6e-281) {
		tmp = -2.0 * b;
	} else if (y <= 2.95e-162) {
		tmp = t_2;
	} else if (y <= 1.7e-126) {
		tmp = t_4;
	} else if (y <= 5.6e+36) {
		tmp = t_1;
	} else {
		tmp = t_3;
	}
	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) :: t_3
    real(8) :: t_4
    real(8) :: tmp
    t_1 = x + (t * b)
    t_2 = t * (b - a)
    t_3 = y * (b - z)
    t_4 = a * (1.0d0 - t)
    if (y <= (-2.85d+32)) then
        tmp = t_3
    else if (y <= (-2.4d-96)) then
        tmp = t_1
    else if (y <= (-1.05d-284)) then
        tmp = t_2
    else if (y <= 9.5d-290) then
        tmp = t_4
    else if (y <= 2.6d-281) then
        tmp = (-2.0d0) * b
    else if (y <= 2.95d-162) then
        tmp = t_2
    else if (y <= 1.7d-126) then
        tmp = t_4
    else if (y <= 5.6d+36) then
        tmp = t_1
    else
        tmp = t_3
    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 + (t * b);
	double t_2 = t * (b - a);
	double t_3 = y * (b - z);
	double t_4 = a * (1.0 - t);
	double tmp;
	if (y <= -2.85e+32) {
		tmp = t_3;
	} else if (y <= -2.4e-96) {
		tmp = t_1;
	} else if (y <= -1.05e-284) {
		tmp = t_2;
	} else if (y <= 9.5e-290) {
		tmp = t_4;
	} else if (y <= 2.6e-281) {
		tmp = -2.0 * b;
	} else if (y <= 2.95e-162) {
		tmp = t_2;
	} else if (y <= 1.7e-126) {
		tmp = t_4;
	} else if (y <= 5.6e+36) {
		tmp = t_1;
	} else {
		tmp = t_3;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = x + (t * b)
	t_2 = t * (b - a)
	t_3 = y * (b - z)
	t_4 = a * (1.0 - t)
	tmp = 0
	if y <= -2.85e+32:
		tmp = t_3
	elif y <= -2.4e-96:
		tmp = t_1
	elif y <= -1.05e-284:
		tmp = t_2
	elif y <= 9.5e-290:
		tmp = t_4
	elif y <= 2.6e-281:
		tmp = -2.0 * b
	elif y <= 2.95e-162:
		tmp = t_2
	elif y <= 1.7e-126:
		tmp = t_4
	elif y <= 5.6e+36:
		tmp = t_1
	else:
		tmp = t_3
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(x + Float64(t * b))
	t_2 = Float64(t * Float64(b - a))
	t_3 = Float64(y * Float64(b - z))
	t_4 = Float64(a * Float64(1.0 - t))
	tmp = 0.0
	if (y <= -2.85e+32)
		tmp = t_3;
	elseif (y <= -2.4e-96)
		tmp = t_1;
	elseif (y <= -1.05e-284)
		tmp = t_2;
	elseif (y <= 9.5e-290)
		tmp = t_4;
	elseif (y <= 2.6e-281)
		tmp = Float64(-2.0 * b);
	elseif (y <= 2.95e-162)
		tmp = t_2;
	elseif (y <= 1.7e-126)
		tmp = t_4;
	elseif (y <= 5.6e+36)
		tmp = t_1;
	else
		tmp = t_3;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = x + (t * b);
	t_2 = t * (b - a);
	t_3 = y * (b - z);
	t_4 = a * (1.0 - t);
	tmp = 0.0;
	if (y <= -2.85e+32)
		tmp = t_3;
	elseif (y <= -2.4e-96)
		tmp = t_1;
	elseif (y <= -1.05e-284)
		tmp = t_2;
	elseif (y <= 9.5e-290)
		tmp = t_4;
	elseif (y <= 2.6e-281)
		tmp = -2.0 * b;
	elseif (y <= 2.95e-162)
		tmp = t_2;
	elseif (y <= 1.7e-126)
		tmp = t_4;
	elseif (y <= 5.6e+36)
		tmp = t_1;
	else
		tmp = t_3;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x + N[(t * b), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t * N[(b - a), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(y * N[(b - z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -2.85e+32], t$95$3, If[LessEqual[y, -2.4e-96], t$95$1, If[LessEqual[y, -1.05e-284], t$95$2, If[LessEqual[y, 9.5e-290], t$95$4, If[LessEqual[y, 2.6e-281], N[(-2.0 * b), $MachinePrecision], If[LessEqual[y, 2.95e-162], t$95$2, If[LessEqual[y, 1.7e-126], t$95$4, If[LessEqual[y, 5.6e+36], t$95$1, t$95$3]]]]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x + t \cdot b\\
t_2 := t \cdot \left(b - a\right)\\
t_3 := y \cdot \left(b - z\right)\\
t_4 := a \cdot \left(1 - t\right)\\
\mathbf{if}\;y \leq -2.85 \cdot 10^{+32}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;y \leq -2.4 \cdot 10^{-96}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq -1.05 \cdot 10^{-284}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y \leq 9.5 \cdot 10^{-290}:\\
\;\;\;\;t\_4\\

\mathbf{elif}\;y \leq 2.6 \cdot 10^{-281}:\\
\;\;\;\;-2 \cdot b\\

\mathbf{elif}\;y \leq 2.95 \cdot 10^{-162}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y \leq 1.7 \cdot 10^{-126}:\\
\;\;\;\;t\_4\\

\mathbf{elif}\;y \leq 5.6 \cdot 10^{+36}:\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if y < -2.85e32 or 5.6000000000000001e36 < y

    1. Initial program 94.2%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 64.3%

      \[\leadsto \color{blue}{y \cdot \left(b - z\right)} \]

    if -2.85e32 < y < -2.40000000000000019e-96 or 1.7e-126 < y < 5.6000000000000001e36

    1. Initial program 96.5%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 86.1%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - a \cdot \left(t - 1\right)} \]
    4. Taylor expanded in a around 0 67.9%

      \[\leadsto \color{blue}{x + b \cdot \left(\left(t + y\right) - 2\right)} \]
    5. Taylor expanded in t around inf 57.4%

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

    if -2.40000000000000019e-96 < y < -1.04999999999999996e-284 or 2.60000000000000005e-281 < y < 2.9499999999999998e-162

    1. Initial program 96.9%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 58.0%

      \[\leadsto \color{blue}{t \cdot \left(b - a\right)} \]

    if -1.04999999999999996e-284 < y < 9.50000000000000023e-290 or 2.9499999999999998e-162 < y < 1.7e-126

    1. Initial program 100.0%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in a around inf 62.5%

      \[\leadsto \color{blue}{a \cdot \left(1 - t\right)} \]

    if 9.50000000000000023e-290 < y < 2.60000000000000005e-281

    1. Initial program 100.0%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 63.3%

      \[\leadsto \color{blue}{-1 \cdot \left(a \cdot t\right)} + \left(\left(y + t\right) - 2\right) \cdot b \]
    4. Step-by-step derivation
      1. mul-1-neg63.3%

        \[\leadsto \color{blue}{\left(-a \cdot t\right)} + \left(\left(y + t\right) - 2\right) \cdot b \]
      2. distribute-rgt-neg-in63.3%

        \[\leadsto \color{blue}{a \cdot \left(-t\right)} + \left(\left(y + t\right) - 2\right) \cdot b \]
    5. Simplified63.3%

      \[\leadsto \color{blue}{a \cdot \left(-t\right)} + \left(\left(y + t\right) - 2\right) \cdot b \]
    6. Taylor expanded in t around 0 61.2%

      \[\leadsto \color{blue}{b \cdot \left(y - 2\right)} \]
    7. Taylor expanded in y around 0 61.2%

      \[\leadsto \color{blue}{-2 \cdot b} \]
    8. Step-by-step derivation
      1. *-commutative61.2%

        \[\leadsto \color{blue}{b \cdot -2} \]
    9. Simplified61.2%

      \[\leadsto \color{blue}{b \cdot -2} \]
  3. Recombined 5 regimes into one program.
  4. Final simplification60.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.85 \cdot 10^{+32}:\\ \;\;\;\;y \cdot \left(b - z\right)\\ \mathbf{elif}\;y \leq -2.4 \cdot 10^{-96}:\\ \;\;\;\;x + t \cdot b\\ \mathbf{elif}\;y \leq -1.05 \cdot 10^{-284}:\\ \;\;\;\;t \cdot \left(b - a\right)\\ \mathbf{elif}\;y \leq 9.5 \cdot 10^{-290}:\\ \;\;\;\;a \cdot \left(1 - t\right)\\ \mathbf{elif}\;y \leq 2.6 \cdot 10^{-281}:\\ \;\;\;\;-2 \cdot b\\ \mathbf{elif}\;y \leq 2.95 \cdot 10^{-162}:\\ \;\;\;\;t \cdot \left(b - a\right)\\ \mathbf{elif}\;y \leq 1.7 \cdot 10^{-126}:\\ \;\;\;\;a \cdot \left(1 - t\right)\\ \mathbf{elif}\;y \leq 5.6 \cdot 10^{+36}:\\ \;\;\;\;x + t \cdot b\\ \mathbf{else}:\\ \;\;\;\;y \cdot \left(b - z\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 5: 48.9% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := z \cdot \left(1 - y\right)\\ t_2 := a \cdot \left(1 - t\right)\\ t_3 := b \cdot \left(\left(y + t\right) - 2\right)\\ \mathbf{if}\;b \leq -66000000000:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;b \leq 3.4 \cdot 10^{-271}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;b \leq 6.5 \cdot 10^{-238}:\\ \;\;\;\;x\\ \mathbf{elif}\;b \leq 2.7 \cdot 10^{-140}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;b \leq 9 \cdot 10^{-77}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;b \leq 1.15 \cdot 10^{+63}:\\ \;\;\;\;x + t \cdot b\\ \mathbf{elif}\;b \leq 4.6 \cdot 10^{+115}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t\_3\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (* z (- 1.0 y)))
        (t_2 (* a (- 1.0 t)))
        (t_3 (* b (- (+ y t) 2.0))))
   (if (<= b -66000000000.0)
     t_3
     (if (<= b 3.4e-271)
       t_2
       (if (<= b 6.5e-238)
         x
         (if (<= b 2.7e-140)
           t_2
           (if (<= b 9e-77)
             t_1
             (if (<= b 1.15e+63)
               (+ x (* t b))
               (if (<= b 4.6e+115) t_1 t_3)))))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = z * (1.0 - y);
	double t_2 = a * (1.0 - t);
	double t_3 = b * ((y + t) - 2.0);
	double tmp;
	if (b <= -66000000000.0) {
		tmp = t_3;
	} else if (b <= 3.4e-271) {
		tmp = t_2;
	} else if (b <= 6.5e-238) {
		tmp = x;
	} else if (b <= 2.7e-140) {
		tmp = t_2;
	} else if (b <= 9e-77) {
		tmp = t_1;
	} else if (b <= 1.15e+63) {
		tmp = x + (t * b);
	} else if (b <= 4.6e+115) {
		tmp = t_1;
	} else {
		tmp = t_3;
	}
	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) :: t_3
    real(8) :: tmp
    t_1 = z * (1.0d0 - y)
    t_2 = a * (1.0d0 - t)
    t_3 = b * ((y + t) - 2.0d0)
    if (b <= (-66000000000.0d0)) then
        tmp = t_3
    else if (b <= 3.4d-271) then
        tmp = t_2
    else if (b <= 6.5d-238) then
        tmp = x
    else if (b <= 2.7d-140) then
        tmp = t_2
    else if (b <= 9d-77) then
        tmp = t_1
    else if (b <= 1.15d+63) then
        tmp = x + (t * b)
    else if (b <= 4.6d+115) then
        tmp = t_1
    else
        tmp = t_3
    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 = z * (1.0 - y);
	double t_2 = a * (1.0 - t);
	double t_3 = b * ((y + t) - 2.0);
	double tmp;
	if (b <= -66000000000.0) {
		tmp = t_3;
	} else if (b <= 3.4e-271) {
		tmp = t_2;
	} else if (b <= 6.5e-238) {
		tmp = x;
	} else if (b <= 2.7e-140) {
		tmp = t_2;
	} else if (b <= 9e-77) {
		tmp = t_1;
	} else if (b <= 1.15e+63) {
		tmp = x + (t * b);
	} else if (b <= 4.6e+115) {
		tmp = t_1;
	} else {
		tmp = t_3;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = z * (1.0 - y)
	t_2 = a * (1.0 - t)
	t_3 = b * ((y + t) - 2.0)
	tmp = 0
	if b <= -66000000000.0:
		tmp = t_3
	elif b <= 3.4e-271:
		tmp = t_2
	elif b <= 6.5e-238:
		tmp = x
	elif b <= 2.7e-140:
		tmp = t_2
	elif b <= 9e-77:
		tmp = t_1
	elif b <= 1.15e+63:
		tmp = x + (t * b)
	elif b <= 4.6e+115:
		tmp = t_1
	else:
		tmp = t_3
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(z * Float64(1.0 - y))
	t_2 = Float64(a * Float64(1.0 - t))
	t_3 = Float64(b * Float64(Float64(y + t) - 2.0))
	tmp = 0.0
	if (b <= -66000000000.0)
		tmp = t_3;
	elseif (b <= 3.4e-271)
		tmp = t_2;
	elseif (b <= 6.5e-238)
		tmp = x;
	elseif (b <= 2.7e-140)
		tmp = t_2;
	elseif (b <= 9e-77)
		tmp = t_1;
	elseif (b <= 1.15e+63)
		tmp = Float64(x + Float64(t * b));
	elseif (b <= 4.6e+115)
		tmp = t_1;
	else
		tmp = t_3;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = z * (1.0 - y);
	t_2 = a * (1.0 - t);
	t_3 = b * ((y + t) - 2.0);
	tmp = 0.0;
	if (b <= -66000000000.0)
		tmp = t_3;
	elseif (b <= 3.4e-271)
		tmp = t_2;
	elseif (b <= 6.5e-238)
		tmp = x;
	elseif (b <= 2.7e-140)
		tmp = t_2;
	elseif (b <= 9e-77)
		tmp = t_1;
	elseif (b <= 1.15e+63)
		tmp = x + (t * b);
	elseif (b <= 4.6e+115)
		tmp = t_1;
	else
		tmp = t_3;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(z * N[(1.0 - y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -66000000000.0], t$95$3, If[LessEqual[b, 3.4e-271], t$95$2, If[LessEqual[b, 6.5e-238], x, If[LessEqual[b, 2.7e-140], t$95$2, If[LessEqual[b, 9e-77], t$95$1, If[LessEqual[b, 1.15e+63], N[(x + N[(t * b), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 4.6e+115], t$95$1, t$95$3]]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := z \cdot \left(1 - y\right)\\
t_2 := a \cdot \left(1 - t\right)\\
t_3 := b \cdot \left(\left(y + t\right) - 2\right)\\
\mathbf{if}\;b \leq -66000000000:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;b \leq 3.4 \cdot 10^{-271}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;b \leq 6.5 \cdot 10^{-238}:\\
\;\;\;\;x\\

\mathbf{elif}\;b \leq 2.7 \cdot 10^{-140}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;b \leq 9 \cdot 10^{-77}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;b \leq 1.15 \cdot 10^{+63}:\\
\;\;\;\;x + t \cdot b\\

\mathbf{elif}\;b \leq 4.6 \cdot 10^{+115}:\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if b < -6.6e10 or 4.60000000000000007e115 < b

    1. Initial program 92.6%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in b around inf 74.6%

      \[\leadsto \color{blue}{b \cdot \left(\left(t + y\right) - 2\right)} \]

    if -6.6e10 < b < 3.4000000000000001e-271 or 6.5000000000000006e-238 < b < 2.7e-140

    1. Initial program 100.0%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in a around inf 55.7%

      \[\leadsto \color{blue}{a \cdot \left(1 - t\right)} \]

    if 3.4000000000000001e-271 < b < 6.5000000000000006e-238

    1. Initial program 90.9%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 63.4%

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

    if 2.7e-140 < b < 9.0000000000000001e-77 or 1.14999999999999997e63 < b < 4.60000000000000007e115

    1. Initial program 95.4%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 64.6%

      \[\leadsto \color{blue}{z \cdot \left(1 - y\right)} \]

    if 9.0000000000000001e-77 < b < 1.14999999999999997e63

    1. Initial program 100.0%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 85.3%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - a \cdot \left(t - 1\right)} \]
    4. Taylor expanded in a around 0 67.8%

      \[\leadsto \color{blue}{x + b \cdot \left(\left(t + y\right) - 2\right)} \]
    5. Taylor expanded in t around inf 58.2%

      \[\leadsto x + \color{blue}{b \cdot t} \]
  3. Recombined 5 regimes into one program.
  4. Final simplification65.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -66000000000:\\ \;\;\;\;b \cdot \left(\left(y + t\right) - 2\right)\\ \mathbf{elif}\;b \leq 3.4 \cdot 10^{-271}:\\ \;\;\;\;a \cdot \left(1 - t\right)\\ \mathbf{elif}\;b \leq 6.5 \cdot 10^{-238}:\\ \;\;\;\;x\\ \mathbf{elif}\;b \leq 2.7 \cdot 10^{-140}:\\ \;\;\;\;a \cdot \left(1 - t\right)\\ \mathbf{elif}\;b \leq 9 \cdot 10^{-77}:\\ \;\;\;\;z \cdot \left(1 - y\right)\\ \mathbf{elif}\;b \leq 1.15 \cdot 10^{+63}:\\ \;\;\;\;x + t \cdot b\\ \mathbf{elif}\;b \leq 4.6 \cdot 10^{+115}:\\ \;\;\;\;z \cdot \left(1 - y\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot \left(\left(y + t\right) - 2\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 6: 58.1% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x + a \cdot \left(1 - t\right)\\ t_2 := x + b \cdot \left(t - 2\right)\\ t_3 := b \cdot \left(\left(y + t\right) - 2\right)\\ t_4 := z \cdot \left(1 - y\right)\\ \mathbf{if}\;b \leq -3 \cdot 10^{+16}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;b \leq 4.8 \cdot 10^{-140}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;b \leq 3.2 \cdot 10^{-75}:\\ \;\;\;\;t\_4\\ \mathbf{elif}\;b \leq 0.17:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;b \leq 7.2 \cdot 10^{+56}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;b \leq 4.6 \cdot 10^{+115}:\\ \;\;\;\;t\_4\\ \mathbf{elif}\;b \leq 4.8 \cdot 10^{+204}:\\ \;\;\;\;t\_2\\ \mathbf{else}:\\ \;\;\;\;t\_3\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (+ x (* a (- 1.0 t))))
        (t_2 (+ x (* b (- t 2.0))))
        (t_3 (* b (- (+ y t) 2.0)))
        (t_4 (* z (- 1.0 y))))
   (if (<= b -3e+16)
     t_3
     (if (<= b 4.8e-140)
       t_1
       (if (<= b 3.2e-75)
         t_4
         (if (<= b 0.17)
           t_1
           (if (<= b 7.2e+56)
             t_2
             (if (<= b 4.6e+115) t_4 (if (<= b 4.8e+204) t_2 t_3)))))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = x + (a * (1.0 - t));
	double t_2 = x + (b * (t - 2.0));
	double t_3 = b * ((y + t) - 2.0);
	double t_4 = z * (1.0 - y);
	double tmp;
	if (b <= -3e+16) {
		tmp = t_3;
	} else if (b <= 4.8e-140) {
		tmp = t_1;
	} else if (b <= 3.2e-75) {
		tmp = t_4;
	} else if (b <= 0.17) {
		tmp = t_1;
	} else if (b <= 7.2e+56) {
		tmp = t_2;
	} else if (b <= 4.6e+115) {
		tmp = t_4;
	} else if (b <= 4.8e+204) {
		tmp = t_2;
	} else {
		tmp = t_3;
	}
	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) :: t_3
    real(8) :: t_4
    real(8) :: tmp
    t_1 = x + (a * (1.0d0 - t))
    t_2 = x + (b * (t - 2.0d0))
    t_3 = b * ((y + t) - 2.0d0)
    t_4 = z * (1.0d0 - y)
    if (b <= (-3d+16)) then
        tmp = t_3
    else if (b <= 4.8d-140) then
        tmp = t_1
    else if (b <= 3.2d-75) then
        tmp = t_4
    else if (b <= 0.17d0) then
        tmp = t_1
    else if (b <= 7.2d+56) then
        tmp = t_2
    else if (b <= 4.6d+115) then
        tmp = t_4
    else if (b <= 4.8d+204) then
        tmp = t_2
    else
        tmp = t_3
    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 + (a * (1.0 - t));
	double t_2 = x + (b * (t - 2.0));
	double t_3 = b * ((y + t) - 2.0);
	double t_4 = z * (1.0 - y);
	double tmp;
	if (b <= -3e+16) {
		tmp = t_3;
	} else if (b <= 4.8e-140) {
		tmp = t_1;
	} else if (b <= 3.2e-75) {
		tmp = t_4;
	} else if (b <= 0.17) {
		tmp = t_1;
	} else if (b <= 7.2e+56) {
		tmp = t_2;
	} else if (b <= 4.6e+115) {
		tmp = t_4;
	} else if (b <= 4.8e+204) {
		tmp = t_2;
	} else {
		tmp = t_3;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = x + (a * (1.0 - t))
	t_2 = x + (b * (t - 2.0))
	t_3 = b * ((y + t) - 2.0)
	t_4 = z * (1.0 - y)
	tmp = 0
	if b <= -3e+16:
		tmp = t_3
	elif b <= 4.8e-140:
		tmp = t_1
	elif b <= 3.2e-75:
		tmp = t_4
	elif b <= 0.17:
		tmp = t_1
	elif b <= 7.2e+56:
		tmp = t_2
	elif b <= 4.6e+115:
		tmp = t_4
	elif b <= 4.8e+204:
		tmp = t_2
	else:
		tmp = t_3
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(x + Float64(a * Float64(1.0 - t)))
	t_2 = Float64(x + Float64(b * Float64(t - 2.0)))
	t_3 = Float64(b * Float64(Float64(y + t) - 2.0))
	t_4 = Float64(z * Float64(1.0 - y))
	tmp = 0.0
	if (b <= -3e+16)
		tmp = t_3;
	elseif (b <= 4.8e-140)
		tmp = t_1;
	elseif (b <= 3.2e-75)
		tmp = t_4;
	elseif (b <= 0.17)
		tmp = t_1;
	elseif (b <= 7.2e+56)
		tmp = t_2;
	elseif (b <= 4.6e+115)
		tmp = t_4;
	elseif (b <= 4.8e+204)
		tmp = t_2;
	else
		tmp = t_3;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = x + (a * (1.0 - t));
	t_2 = x + (b * (t - 2.0));
	t_3 = b * ((y + t) - 2.0);
	t_4 = z * (1.0 - y);
	tmp = 0.0;
	if (b <= -3e+16)
		tmp = t_3;
	elseif (b <= 4.8e-140)
		tmp = t_1;
	elseif (b <= 3.2e-75)
		tmp = t_4;
	elseif (b <= 0.17)
		tmp = t_1;
	elseif (b <= 7.2e+56)
		tmp = t_2;
	elseif (b <= 4.6e+115)
		tmp = t_4;
	elseif (b <= 4.8e+204)
		tmp = t_2;
	else
		tmp = t_3;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x + N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(b * N[(t - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(z * N[(1.0 - y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -3e+16], t$95$3, If[LessEqual[b, 4.8e-140], t$95$1, If[LessEqual[b, 3.2e-75], t$95$4, If[LessEqual[b, 0.17], t$95$1, If[LessEqual[b, 7.2e+56], t$95$2, If[LessEqual[b, 4.6e+115], t$95$4, If[LessEqual[b, 4.8e+204], t$95$2, t$95$3]]]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x + a \cdot \left(1 - t\right)\\
t_2 := x + b \cdot \left(t - 2\right)\\
t_3 := b \cdot \left(\left(y + t\right) - 2\right)\\
t_4 := z \cdot \left(1 - y\right)\\
\mathbf{if}\;b \leq -3 \cdot 10^{+16}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;b \leq 4.8 \cdot 10^{-140}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;b \leq 3.2 \cdot 10^{-75}:\\
\;\;\;\;t\_4\\

\mathbf{elif}\;b \leq 0.17:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;b \leq 7.2 \cdot 10^{+56}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;b \leq 4.6 \cdot 10^{+115}:\\
\;\;\;\;t\_4\\

\mathbf{elif}\;b \leq 4.8 \cdot 10^{+204}:\\
\;\;\;\;t\_2\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if b < -3e16 or 4.7999999999999999e204 < b

    1. Initial program 93.2%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in b around inf 79.3%

      \[\leadsto \color{blue}{b \cdot \left(\left(t + y\right) - 2\right)} \]

    if -3e16 < b < 4.79999999999999973e-140 or 3.19999999999999977e-75 < b < 0.170000000000000012

    1. Initial program 99.1%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 72.9%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - a \cdot \left(t - 1\right)} \]
    4. Taylor expanded in b around 0 69.3%

      \[\leadsto \color{blue}{x - a \cdot \left(t - 1\right)} \]

    if 4.79999999999999973e-140 < b < 3.19999999999999977e-75 or 7.19999999999999996e56 < b < 4.60000000000000007e115

    1. Initial program 95.8%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 63.4%

      \[\leadsto \color{blue}{z \cdot \left(1 - y\right)} \]

    if 0.170000000000000012 < b < 7.19999999999999996e56 or 4.60000000000000007e115 < b < 4.7999999999999999e204

    1. Initial program 94.1%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 90.2%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - a \cdot \left(t - 1\right)} \]
    4. Taylor expanded in a around 0 81.9%

      \[\leadsto \color{blue}{x + b \cdot \left(\left(t + y\right) - 2\right)} \]
    5. Taylor expanded in y around 0 73.5%

      \[\leadsto x + \color{blue}{b \cdot \left(t - 2\right)} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification72.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -3 \cdot 10^{+16}:\\ \;\;\;\;b \cdot \left(\left(y + t\right) - 2\right)\\ \mathbf{elif}\;b \leq 4.8 \cdot 10^{-140}:\\ \;\;\;\;x + a \cdot \left(1 - t\right)\\ \mathbf{elif}\;b \leq 3.2 \cdot 10^{-75}:\\ \;\;\;\;z \cdot \left(1 - y\right)\\ \mathbf{elif}\;b \leq 0.17:\\ \;\;\;\;x + a \cdot \left(1 - t\right)\\ \mathbf{elif}\;b \leq 7.2 \cdot 10^{+56}:\\ \;\;\;\;x + b \cdot \left(t - 2\right)\\ \mathbf{elif}\;b \leq 4.6 \cdot 10^{+115}:\\ \;\;\;\;z \cdot \left(1 - y\right)\\ \mathbf{elif}\;b \leq 4.8 \cdot 10^{+204}:\\ \;\;\;\;x + b \cdot \left(t - 2\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot \left(\left(y + t\right) - 2\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 7: 58.6% accurate, 0.5× speedup?

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

\\
\begin{array}{l}
t_1 := x + a \cdot \left(1 - t\right)\\
t_2 := b \cdot \left(\left(y + t\right) - 2\right)\\
t_3 := z \cdot \left(1 - y\right)\\
\mathbf{if}\;b \leq -1.45 \cdot 10^{+16}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;b \leq 4.8 \cdot 10^{-140}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;b \leq 4 \cdot 10^{-77}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;b \leq 0.011:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;b \leq 2 \cdot 10^{+50}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;b \leq 6.5 \cdot 10^{+80}:\\
\;\;\;\;x + t\_3\\

\mathbf{elif}\;b \leq 1.65 \cdot 10^{+204}:\\
\;\;\;\;x + b \cdot \left(t - 2\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if b < -1.45e16 or 0.010999999999999999 < b < 2.0000000000000002e50 or 1.6499999999999999e204 < b

    1. Initial program 94.0%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in b around inf 78.3%

      \[\leadsto \color{blue}{b \cdot \left(\left(t + y\right) - 2\right)} \]

    if -1.45e16 < b < 4.79999999999999973e-140 or 3.9999999999999997e-77 < b < 0.010999999999999999

    1. Initial program 99.1%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 72.9%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - a \cdot \left(t - 1\right)} \]
    4. Taylor expanded in b around 0 69.3%

      \[\leadsto \color{blue}{x - a \cdot \left(t - 1\right)} \]

    if 4.79999999999999973e-140 < b < 3.9999999999999997e-77

    1. Initial program 99.9%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 65.0%

      \[\leadsto \color{blue}{z \cdot \left(1 - y\right)} \]

    if 2.0000000000000002e50 < b < 6.4999999999999998e80

    1. Initial program 100.0%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in a around 0 70.8%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - z \cdot \left(y - 1\right)} \]
    4. Taylor expanded in b around 0 69.5%

      \[\leadsto \color{blue}{x - z \cdot \left(y - 1\right)} \]

    if 6.4999999999999998e80 < b < 1.6499999999999999e204

    1. Initial program 87.5%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 79.4%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - a \cdot \left(t - 1\right)} \]
    4. Taylor expanded in a around 0 75.7%

      \[\leadsto \color{blue}{x + b \cdot \left(\left(t + y\right) - 2\right)} \]
    5. Taylor expanded in y around 0 68.2%

      \[\leadsto x + \color{blue}{b \cdot \left(t - 2\right)} \]
  3. Recombined 5 regimes into one program.
  4. Final simplification72.6%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -1.45 \cdot 10^{+16}:\\ \;\;\;\;b \cdot \left(\left(y + t\right) - 2\right)\\ \mathbf{elif}\;b \leq 4.8 \cdot 10^{-140}:\\ \;\;\;\;x + a \cdot \left(1 - t\right)\\ \mathbf{elif}\;b \leq 4 \cdot 10^{-77}:\\ \;\;\;\;z \cdot \left(1 - y\right)\\ \mathbf{elif}\;b \leq 0.011:\\ \;\;\;\;x + a \cdot \left(1 - t\right)\\ \mathbf{elif}\;b \leq 2 \cdot 10^{+50}:\\ \;\;\;\;b \cdot \left(\left(y + t\right) - 2\right)\\ \mathbf{elif}\;b \leq 6.5 \cdot 10^{+80}:\\ \;\;\;\;x + z \cdot \left(1 - y\right)\\ \mathbf{elif}\;b \leq 1.65 \cdot 10^{+204}:\\ \;\;\;\;x + b \cdot \left(t - 2\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot \left(\left(y + t\right) - 2\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 8: 46.5% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := y \cdot \left(b - z\right)\\ t_2 := t \cdot \left(b - a\right)\\ \mathbf{if}\;t \leq -9.5 \cdot 10^{+57}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;t \leq -3.1 \cdot 10^{-89}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t \leq -1.56 \cdot 10^{-134}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq -1.55 \cdot 10^{-290}:\\ \;\;\;\;a \cdot \left(1 - t\right)\\ \mathbf{elif}\;t \leq 2.4 \cdot 10^{-93}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t \leq 4.2 \cdot 10^{-38}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq 360000000:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (* y (- b z))) (t_2 (* t (- b a))))
   (if (<= t -9.5e+57)
     t_2
     (if (<= t -3.1e-89)
       t_1
       (if (<= t -1.56e-134)
         x
         (if (<= t -1.55e-290)
           (* a (- 1.0 t))
           (if (<= t 2.4e-93)
             t_1
             (if (<= t 4.2e-38) x (if (<= t 360000000.0) t_1 t_2)))))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = y * (b - z);
	double t_2 = t * (b - a);
	double tmp;
	if (t <= -9.5e+57) {
		tmp = t_2;
	} else if (t <= -3.1e-89) {
		tmp = t_1;
	} else if (t <= -1.56e-134) {
		tmp = x;
	} else if (t <= -1.55e-290) {
		tmp = a * (1.0 - t);
	} else if (t <= 2.4e-93) {
		tmp = t_1;
	} else if (t <= 4.2e-38) {
		tmp = x;
	} else if (t <= 360000000.0) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	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 = y * (b - z)
    t_2 = t * (b - a)
    if (t <= (-9.5d+57)) then
        tmp = t_2
    else if (t <= (-3.1d-89)) then
        tmp = t_1
    else if (t <= (-1.56d-134)) then
        tmp = x
    else if (t <= (-1.55d-290)) then
        tmp = a * (1.0d0 - t)
    else if (t <= 2.4d-93) then
        tmp = t_1
    else if (t <= 4.2d-38) then
        tmp = x
    else if (t <= 360000000.0d0) then
        tmp = t_1
    else
        tmp = t_2
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = y * (b - z);
	double t_2 = t * (b - a);
	double tmp;
	if (t <= -9.5e+57) {
		tmp = t_2;
	} else if (t <= -3.1e-89) {
		tmp = t_1;
	} else if (t <= -1.56e-134) {
		tmp = x;
	} else if (t <= -1.55e-290) {
		tmp = a * (1.0 - t);
	} else if (t <= 2.4e-93) {
		tmp = t_1;
	} else if (t <= 4.2e-38) {
		tmp = x;
	} else if (t <= 360000000.0) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = y * (b - z)
	t_2 = t * (b - a)
	tmp = 0
	if t <= -9.5e+57:
		tmp = t_2
	elif t <= -3.1e-89:
		tmp = t_1
	elif t <= -1.56e-134:
		tmp = x
	elif t <= -1.55e-290:
		tmp = a * (1.0 - t)
	elif t <= 2.4e-93:
		tmp = t_1
	elif t <= 4.2e-38:
		tmp = x
	elif t <= 360000000.0:
		tmp = t_1
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(y * Float64(b - z))
	t_2 = Float64(t * Float64(b - a))
	tmp = 0.0
	if (t <= -9.5e+57)
		tmp = t_2;
	elseif (t <= -3.1e-89)
		tmp = t_1;
	elseif (t <= -1.56e-134)
		tmp = x;
	elseif (t <= -1.55e-290)
		tmp = Float64(a * Float64(1.0 - t));
	elseif (t <= 2.4e-93)
		tmp = t_1;
	elseif (t <= 4.2e-38)
		tmp = x;
	elseif (t <= 360000000.0)
		tmp = t_1;
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = y * (b - z);
	t_2 = t * (b - a);
	tmp = 0.0;
	if (t <= -9.5e+57)
		tmp = t_2;
	elseif (t <= -3.1e-89)
		tmp = t_1;
	elseif (t <= -1.56e-134)
		tmp = x;
	elseif (t <= -1.55e-290)
		tmp = a * (1.0 - t);
	elseif (t <= 2.4e-93)
		tmp = t_1;
	elseif (t <= 4.2e-38)
		tmp = x;
	elseif (t <= 360000000.0)
		tmp = t_1;
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(y * N[(b - z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t * N[(b - a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -9.5e+57], t$95$2, If[LessEqual[t, -3.1e-89], t$95$1, If[LessEqual[t, -1.56e-134], x, If[LessEqual[t, -1.55e-290], N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.4e-93], t$95$1, If[LessEqual[t, 4.2e-38], x, If[LessEqual[t, 360000000.0], t$95$1, t$95$2]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := y \cdot \left(b - z\right)\\
t_2 := t \cdot \left(b - a\right)\\
\mathbf{if}\;t \leq -9.5 \cdot 10^{+57}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;t \leq -3.1 \cdot 10^{-89}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t \leq -1.56 \cdot 10^{-134}:\\
\;\;\;\;x\\

\mathbf{elif}\;t \leq -1.55 \cdot 10^{-290}:\\
\;\;\;\;a \cdot \left(1 - t\right)\\

\mathbf{elif}\;t \leq 2.4 \cdot 10^{-93}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t \leq 4.2 \cdot 10^{-38}:\\
\;\;\;\;x\\

\mathbf{elif}\;t \leq 360000000:\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < -9.4999999999999997e57 or 3.6e8 < t

    1. Initial program 92.7%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 74.5%

      \[\leadsto \color{blue}{t \cdot \left(b - a\right)} \]

    if -9.4999999999999997e57 < t < -3.09999999999999996e-89 or -1.54999999999999995e-290 < t < 2.4000000000000001e-93 or 4.20000000000000026e-38 < t < 3.6e8

    1. Initial program 100.0%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 44.6%

      \[\leadsto \color{blue}{y \cdot \left(b - z\right)} \]

    if -3.09999999999999996e-89 < t < -1.56000000000000009e-134 or 2.4000000000000001e-93 < t < 4.20000000000000026e-38

    1. Initial program 99.9%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 46.7%

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

    if -1.56000000000000009e-134 < t < -1.54999999999999995e-290

    1. Initial program 96.3%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in a around inf 42.2%

      \[\leadsto \color{blue}{a \cdot \left(1 - t\right)} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification59.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -9.5 \cdot 10^{+57}:\\ \;\;\;\;t \cdot \left(b - a\right)\\ \mathbf{elif}\;t \leq -3.1 \cdot 10^{-89}:\\ \;\;\;\;y \cdot \left(b - z\right)\\ \mathbf{elif}\;t \leq -1.56 \cdot 10^{-134}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq -1.55 \cdot 10^{-290}:\\ \;\;\;\;a \cdot \left(1 - t\right)\\ \mathbf{elif}\;t \leq 2.4 \cdot 10^{-93}:\\ \;\;\;\;y \cdot \left(b - z\right)\\ \mathbf{elif}\;t \leq 4.2 \cdot 10^{-38}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq 360000000:\\ \;\;\;\;y \cdot \left(b - z\right)\\ \mathbf{else}:\\ \;\;\;\;t \cdot \left(b - a\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 9: 46.2% accurate, 0.5× speedup?

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

\\
\begin{array}{l}
t_1 := y \cdot \left(b - z\right)\\
t_2 := t \cdot \left(b - a\right)\\
\mathbf{if}\;t \leq -8 \cdot 10^{+57}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;t \leq -1.65 \cdot 10^{-90}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t \leq -1.95 \cdot 10^{-134}:\\
\;\;\;\;x\\

\mathbf{elif}\;t \leq -1.65 \cdot 10^{-290}:\\
\;\;\;\;a \cdot \left(1 - t\right)\\

\mathbf{elif}\;t \leq 2.4 \cdot 10^{-92}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t \leq 2.05 \cdot 10^{-38}:\\
\;\;\;\;x\\

\mathbf{elif}\;t \leq 2.76 \cdot 10^{+14}:\\
\;\;\;\;z \cdot \left(1 - y\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if t < -8.00000000000000039e57 or 2.76e14 < t

    1. Initial program 92.5%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 75.8%

      \[\leadsto \color{blue}{t \cdot \left(b - a\right)} \]

    if -8.00000000000000039e57 < t < -1.65e-90 or -1.64999999999999993e-290 < t < 2.4000000000000001e-92

    1. Initial program 100.0%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 43.9%

      \[\leadsto \color{blue}{y \cdot \left(b - z\right)} \]

    if -1.65e-90 < t < -1.95e-134 or 2.4000000000000001e-92 < t < 2.0499999999999999e-38

    1. Initial program 99.9%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 46.7%

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

    if -1.95e-134 < t < -1.64999999999999993e-290

    1. Initial program 96.3%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in a around inf 42.2%

      \[\leadsto \color{blue}{a \cdot \left(1 - t\right)} \]

    if 2.0499999999999999e-38 < t < 2.76e14

    1. Initial program 100.0%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 45.6%

      \[\leadsto \color{blue}{z \cdot \left(1 - y\right)} \]
  3. Recombined 5 regimes into one program.
  4. Final simplification59.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -8 \cdot 10^{+57}:\\ \;\;\;\;t \cdot \left(b - a\right)\\ \mathbf{elif}\;t \leq -1.65 \cdot 10^{-90}:\\ \;\;\;\;y \cdot \left(b - z\right)\\ \mathbf{elif}\;t \leq -1.95 \cdot 10^{-134}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq -1.65 \cdot 10^{-290}:\\ \;\;\;\;a \cdot \left(1 - t\right)\\ \mathbf{elif}\;t \leq 2.4 \cdot 10^{-92}:\\ \;\;\;\;y \cdot \left(b - z\right)\\ \mathbf{elif}\;t \leq 2.05 \cdot 10^{-38}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq 2.76 \cdot 10^{+14}:\\ \;\;\;\;z \cdot \left(1 - y\right)\\ \mathbf{else}:\\ \;\;\;\;t \cdot \left(b - a\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 10: 62.9% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x + a \cdot \left(1 - t\right)\\ t_2 := x + b \cdot \left(\left(y + t\right) - 2\right)\\ t_3 := z \cdot \left(1 - y\right)\\ \mathbf{if}\;b \leq -2.05 \cdot 10^{+15}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;b \leq 4.1 \cdot 10^{-140}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;b \leq 4 \cdot 10^{-77}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;b \leq 2.65 \cdot 10^{-5}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;b \leq 1.28 \cdot 10^{+57} \lor \neg \left(b \leq 4.6 \cdot 10^{+115}\right):\\ \;\;\;\;t\_2\\ \mathbf{else}:\\ \;\;\;\;x + t\_3\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (+ x (* a (- 1.0 t))))
        (t_2 (+ x (* b (- (+ y t) 2.0))))
        (t_3 (* z (- 1.0 y))))
   (if (<= b -2.05e+15)
     t_2
     (if (<= b 4.1e-140)
       t_1
       (if (<= b 4e-77)
         t_3
         (if (<= b 2.65e-5)
           t_1
           (if (or (<= b 1.28e+57) (not (<= b 4.6e+115))) t_2 (+ x t_3))))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = x + (a * (1.0 - t));
	double t_2 = x + (b * ((y + t) - 2.0));
	double t_3 = z * (1.0 - y);
	double tmp;
	if (b <= -2.05e+15) {
		tmp = t_2;
	} else if (b <= 4.1e-140) {
		tmp = t_1;
	} else if (b <= 4e-77) {
		tmp = t_3;
	} else if (b <= 2.65e-5) {
		tmp = t_1;
	} else if ((b <= 1.28e+57) || !(b <= 4.6e+115)) {
		tmp = t_2;
	} else {
		tmp = x + t_3;
	}
	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) :: t_3
    real(8) :: tmp
    t_1 = x + (a * (1.0d0 - t))
    t_2 = x + (b * ((y + t) - 2.0d0))
    t_3 = z * (1.0d0 - y)
    if (b <= (-2.05d+15)) then
        tmp = t_2
    else if (b <= 4.1d-140) then
        tmp = t_1
    else if (b <= 4d-77) then
        tmp = t_3
    else if (b <= 2.65d-5) then
        tmp = t_1
    else if ((b <= 1.28d+57) .or. (.not. (b <= 4.6d+115))) then
        tmp = t_2
    else
        tmp = x + t_3
    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 + (a * (1.0 - t));
	double t_2 = x + (b * ((y + t) - 2.0));
	double t_3 = z * (1.0 - y);
	double tmp;
	if (b <= -2.05e+15) {
		tmp = t_2;
	} else if (b <= 4.1e-140) {
		tmp = t_1;
	} else if (b <= 4e-77) {
		tmp = t_3;
	} else if (b <= 2.65e-5) {
		tmp = t_1;
	} else if ((b <= 1.28e+57) || !(b <= 4.6e+115)) {
		tmp = t_2;
	} else {
		tmp = x + t_3;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = x + (a * (1.0 - t))
	t_2 = x + (b * ((y + t) - 2.0))
	t_3 = z * (1.0 - y)
	tmp = 0
	if b <= -2.05e+15:
		tmp = t_2
	elif b <= 4.1e-140:
		tmp = t_1
	elif b <= 4e-77:
		tmp = t_3
	elif b <= 2.65e-5:
		tmp = t_1
	elif (b <= 1.28e+57) or not (b <= 4.6e+115):
		tmp = t_2
	else:
		tmp = x + t_3
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(x + Float64(a * Float64(1.0 - t)))
	t_2 = Float64(x + Float64(b * Float64(Float64(y + t) - 2.0)))
	t_3 = Float64(z * Float64(1.0 - y))
	tmp = 0.0
	if (b <= -2.05e+15)
		tmp = t_2;
	elseif (b <= 4.1e-140)
		tmp = t_1;
	elseif (b <= 4e-77)
		tmp = t_3;
	elseif (b <= 2.65e-5)
		tmp = t_1;
	elseif ((b <= 1.28e+57) || !(b <= 4.6e+115))
		tmp = t_2;
	else
		tmp = Float64(x + t_3);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = x + (a * (1.0 - t));
	t_2 = x + (b * ((y + t) - 2.0));
	t_3 = z * (1.0 - y);
	tmp = 0.0;
	if (b <= -2.05e+15)
		tmp = t_2;
	elseif (b <= 4.1e-140)
		tmp = t_1;
	elseif (b <= 4e-77)
		tmp = t_3;
	elseif (b <= 2.65e-5)
		tmp = t_1;
	elseif ((b <= 1.28e+57) || ~((b <= 4.6e+115)))
		tmp = t_2;
	else
		tmp = x + t_3;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x + N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(z * N[(1.0 - y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -2.05e+15], t$95$2, If[LessEqual[b, 4.1e-140], t$95$1, If[LessEqual[b, 4e-77], t$95$3, If[LessEqual[b, 2.65e-5], t$95$1, If[Or[LessEqual[b, 1.28e+57], N[Not[LessEqual[b, 4.6e+115]], $MachinePrecision]], t$95$2, N[(x + t$95$3), $MachinePrecision]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x + a \cdot \left(1 - t\right)\\
t_2 := x + b \cdot \left(\left(y + t\right) - 2\right)\\
t_3 := z \cdot \left(1 - y\right)\\
\mathbf{if}\;b \leq -2.05 \cdot 10^{+15}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;b \leq 4.1 \cdot 10^{-140}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;b \leq 4 \cdot 10^{-77}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;b \leq 2.65 \cdot 10^{-5}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;b \leq 1.28 \cdot 10^{+57} \lor \neg \left(b \leq 4.6 \cdot 10^{+115}\right):\\
\;\;\;\;t\_2\\

\mathbf{else}:\\
\;\;\;\;x + t\_3\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if b < -2.05e15 or 2.65e-5 < b < 1.28000000000000001e57 or 4.60000000000000007e115 < b

    1. Initial program 93.5%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 87.9%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - a \cdot \left(t - 1\right)} \]
    4. Taylor expanded in a around 0 83.7%

      \[\leadsto \color{blue}{x + b \cdot \left(\left(t + y\right) - 2\right)} \]

    if -2.05e15 < b < 4.1000000000000001e-140 or 3.9999999999999997e-77 < b < 2.65e-5

    1. Initial program 99.1%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 72.6%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - a \cdot \left(t - 1\right)} \]
    4. Taylor expanded in b around 0 69.1%

      \[\leadsto \color{blue}{x - a \cdot \left(t - 1\right)} \]

    if 4.1000000000000001e-140 < b < 3.9999999999999997e-77

    1. Initial program 99.9%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 65.0%

      \[\leadsto \color{blue}{z \cdot \left(1 - y\right)} \]

    if 1.28000000000000001e57 < b < 4.60000000000000007e115

    1. Initial program 92.3%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in a around 0 77.5%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - z \cdot \left(y - 1\right)} \]
    4. Taylor expanded in b around 0 69.8%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -2.05 \cdot 10^{+15}:\\ \;\;\;\;x + b \cdot \left(\left(y + t\right) - 2\right)\\ \mathbf{elif}\;b \leq 4.1 \cdot 10^{-140}:\\ \;\;\;\;x + a \cdot \left(1 - t\right)\\ \mathbf{elif}\;b \leq 4 \cdot 10^{-77}:\\ \;\;\;\;z \cdot \left(1 - y\right)\\ \mathbf{elif}\;b \leq 2.65 \cdot 10^{-5}:\\ \;\;\;\;x + a \cdot \left(1 - t\right)\\ \mathbf{elif}\;b \leq 1.28 \cdot 10^{+57} \lor \neg \left(b \leq 4.6 \cdot 10^{+115}\right):\\ \;\;\;\;x + b \cdot \left(\left(y + t\right) - 2\right)\\ \mathbf{else}:\\ \;\;\;\;x + z \cdot \left(1 - y\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 11: 56.0% accurate, 0.6× speedup?

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

\\
\begin{array}{l}
t_1 := x + b \cdot \left(t - 2\right)\\
t_2 := y \cdot \left(b - z\right)\\
\mathbf{if}\;y \leq -5.2 \cdot 10^{+36}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y \leq 3.1 \cdot 10^{-282}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq 1.2 \cdot 10^{-166}:\\
\;\;\;\;t \cdot \left(b - a\right)\\

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

\mathbf{elif}\;y \leq 5.6 \cdot 10^{-126}:\\
\;\;\;\;a \cdot \left(1 - t\right)\\

\mathbf{elif}\;y \leq 6 \cdot 10^{+37}:\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if y < -5.2000000000000003e36 or 6.00000000000000043e37 < y

    1. Initial program 94.2%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 64.3%

      \[\leadsto \color{blue}{y \cdot \left(b - z\right)} \]

    if -5.2000000000000003e36 < y < 3.10000000000000013e-282 or 1.1999999999999999e-166 < y < 6.39999999999999976e-163 or 5.59999999999999983e-126 < y < 6.00000000000000043e37

    1. Initial program 97.2%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 83.6%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - a \cdot \left(t - 1\right)} \]
    4. Taylor expanded in a around 0 62.6%

      \[\leadsto \color{blue}{x + b \cdot \left(\left(t + y\right) - 2\right)} \]
    5. Taylor expanded in y around 0 61.9%

      \[\leadsto x + \color{blue}{b \cdot \left(t - 2\right)} \]

    if 3.10000000000000013e-282 < y < 1.1999999999999999e-166

    1. Initial program 96.2%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 65.9%

      \[\leadsto \color{blue}{t \cdot \left(b - a\right)} \]

    if 6.39999999999999976e-163 < y < 5.59999999999999983e-126

    1. Initial program 100.0%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in a around inf 69.2%

      \[\leadsto \color{blue}{a \cdot \left(1 - t\right)} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification63.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -5.2 \cdot 10^{+36}:\\ \;\;\;\;y \cdot \left(b - z\right)\\ \mathbf{elif}\;y \leq 3.1 \cdot 10^{-282}:\\ \;\;\;\;x + b \cdot \left(t - 2\right)\\ \mathbf{elif}\;y \leq 1.2 \cdot 10^{-166}:\\ \;\;\;\;t \cdot \left(b - a\right)\\ \mathbf{elif}\;y \leq 6.4 \cdot 10^{-163}:\\ \;\;\;\;x + b \cdot \left(t - 2\right)\\ \mathbf{elif}\;y \leq 5.6 \cdot 10^{-126}:\\ \;\;\;\;a \cdot \left(1 - t\right)\\ \mathbf{elif}\;y \leq 6 \cdot 10^{+37}:\\ \;\;\;\;x + b \cdot \left(t - 2\right)\\ \mathbf{else}:\\ \;\;\;\;y \cdot \left(b - z\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 12: 33.0% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := a \cdot \left(1 - t\right)\\ \mathbf{if}\;b \leq -2.18 \cdot 10^{+175}:\\ \;\;\;\;t \cdot b\\ \mathbf{elif}\;b \leq 3.4 \cdot 10^{-271}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;b \leq 6.2 \cdot 10^{-238}:\\ \;\;\;\;x\\ \mathbf{elif}\;b \leq 2.6 \lor \neg \left(b \leq 4.9 \cdot 10^{+38}\right) \land b \leq 6.6 \cdot 10^{+148}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t \cdot b\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (* a (- 1.0 t))))
   (if (<= b -2.18e+175)
     (* t b)
     (if (<= b 3.4e-271)
       t_1
       (if (<= b 6.2e-238)
         x
         (if (or (<= b 2.6) (and (not (<= b 4.9e+38)) (<= b 6.6e+148)))
           t_1
           (* t b)))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = a * (1.0 - t);
	double tmp;
	if (b <= -2.18e+175) {
		tmp = t * b;
	} else if (b <= 3.4e-271) {
		tmp = t_1;
	} else if (b <= 6.2e-238) {
		tmp = x;
	} else if ((b <= 2.6) || (!(b <= 4.9e+38) && (b <= 6.6e+148))) {
		tmp = t_1;
	} else {
		tmp = t * 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 = a * (1.0d0 - t)
    if (b <= (-2.18d+175)) then
        tmp = t * b
    else if (b <= 3.4d-271) then
        tmp = t_1
    else if (b <= 6.2d-238) then
        tmp = x
    else if ((b <= 2.6d0) .or. (.not. (b <= 4.9d+38)) .and. (b <= 6.6d+148)) then
        tmp = t_1
    else
        tmp = t * 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 = a * (1.0 - t);
	double tmp;
	if (b <= -2.18e+175) {
		tmp = t * b;
	} else if (b <= 3.4e-271) {
		tmp = t_1;
	} else if (b <= 6.2e-238) {
		tmp = x;
	} else if ((b <= 2.6) || (!(b <= 4.9e+38) && (b <= 6.6e+148))) {
		tmp = t_1;
	} else {
		tmp = t * b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = a * (1.0 - t)
	tmp = 0
	if b <= -2.18e+175:
		tmp = t * b
	elif b <= 3.4e-271:
		tmp = t_1
	elif b <= 6.2e-238:
		tmp = x
	elif (b <= 2.6) or (not (b <= 4.9e+38) and (b <= 6.6e+148)):
		tmp = t_1
	else:
		tmp = t * b
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(a * Float64(1.0 - t))
	tmp = 0.0
	if (b <= -2.18e+175)
		tmp = Float64(t * b);
	elseif (b <= 3.4e-271)
		tmp = t_1;
	elseif (b <= 6.2e-238)
		tmp = x;
	elseif ((b <= 2.6) || (!(b <= 4.9e+38) && (b <= 6.6e+148)))
		tmp = t_1;
	else
		tmp = Float64(t * b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = a * (1.0 - t);
	tmp = 0.0;
	if (b <= -2.18e+175)
		tmp = t * b;
	elseif (b <= 3.4e-271)
		tmp = t_1;
	elseif (b <= 6.2e-238)
		tmp = x;
	elseif ((b <= 2.6) || (~((b <= 4.9e+38)) && (b <= 6.6e+148)))
		tmp = t_1;
	else
		tmp = t * b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(a * N[(1.0 - t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -2.18e+175], N[(t * b), $MachinePrecision], If[LessEqual[b, 3.4e-271], t$95$1, If[LessEqual[b, 6.2e-238], x, If[Or[LessEqual[b, 2.6], And[N[Not[LessEqual[b, 4.9e+38]], $MachinePrecision], LessEqual[b, 6.6e+148]]], t$95$1, N[(t * b), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := a \cdot \left(1 - t\right)\\
\mathbf{if}\;b \leq -2.18 \cdot 10^{+175}:\\
\;\;\;\;t \cdot b\\

\mathbf{elif}\;b \leq 3.4 \cdot 10^{-271}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;b \leq 6.2 \cdot 10^{-238}:\\
\;\;\;\;x\\

\mathbf{elif}\;b \leq 2.6 \lor \neg \left(b \leq 4.9 \cdot 10^{+38}\right) \land b \leq 6.6 \cdot 10^{+148}:\\
\;\;\;\;t\_1\\

\mathbf{else}:\\
\;\;\;\;t \cdot b\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if b < -2.1799999999999999e175 or 2.60000000000000009 < b < 4.90000000000000002e38 or 6.60000000000000021e148 < b

    1. Initial program 92.6%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in a around 0 95.7%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - z \cdot \left(y - 1\right)} \]
    4. Taylor expanded in t around inf 54.3%

      \[\leadsto \color{blue}{b \cdot t} \]

    if -2.1799999999999999e175 < b < 3.4000000000000001e-271 or 6.2000000000000002e-238 < b < 2.60000000000000009 or 4.90000000000000002e38 < b < 6.60000000000000021e148

    1. Initial program 98.1%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in a around inf 42.9%

      \[\leadsto \color{blue}{a \cdot \left(1 - t\right)} \]

    if 3.4000000000000001e-271 < b < 6.2000000000000002e-238

    1. Initial program 90.9%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 63.4%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -2.18 \cdot 10^{+175}:\\ \;\;\;\;t \cdot b\\ \mathbf{elif}\;b \leq 3.4 \cdot 10^{-271}:\\ \;\;\;\;a \cdot \left(1 - t\right)\\ \mathbf{elif}\;b \leq 6.2 \cdot 10^{-238}:\\ \;\;\;\;x\\ \mathbf{elif}\;b \leq 2.6 \lor \neg \left(b \leq 4.9 \cdot 10^{+38}\right) \land b \leq 6.6 \cdot 10^{+148}:\\ \;\;\;\;a \cdot \left(1 - t\right)\\ \mathbf{else}:\\ \;\;\;\;t \cdot b\\ \end{array} \]
  5. Add Preprocessing

Alternative 13: 82.9% accurate, 0.6× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;b \leq -3.6 \cdot 10^{+50} \lor \neg \left(b \leq 100 \lor \neg \left(b \leq 1.12 \cdot 10^{+38}\right) \land b \leq 4.6 \cdot 10^{+115}\right):\\
\;\;\;\;x + b \cdot \left(\left(y + t\right) - 2\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if b < -3.59999999999999986e50 or 100 < b < 1.1199999999999999e38 or 4.60000000000000007e115 < b

    1. Initial program 93.8%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 90.1%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - a \cdot \left(t - 1\right)} \]
    4. Taylor expanded in a around 0 87.3%

      \[\leadsto \color{blue}{x + b \cdot \left(\left(t + y\right) - 2\right)} \]

    if -3.59999999999999986e50 < b < 100 or 1.1199999999999999e38 < b < 4.60000000000000007e115

    1. Initial program 97.9%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in b around 0 93.4%

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

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

Alternative 14: 84.4% accurate, 0.6× speedup?

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

\\
\begin{array}{l}
t_1 := a \cdot \left(1 - t\right)\\
t_2 := x + b \cdot \left(\left(y + t\right) - 2\right)\\
t_3 := t\_2 + t\_1\\
t_4 := x + \left(t\_1 + z \cdot \left(1 - y\right)\right)\\
\mathbf{if}\;b \leq -5.9 \cdot 10^{+51}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;b \leq 3.8 \cdot 10^{-77}:\\
\;\;\;\;t\_4\\

\mathbf{elif}\;b \leq 1.28 \cdot 10^{+57}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;b \leq 1.75 \cdot 10^{+118}:\\
\;\;\;\;t\_4\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if b < -5.89999999999999983e51 or 3.7999999999999999e-77 < b < 1.28000000000000001e57

    1. Initial program 97.5%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 90.0%

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

    if -5.89999999999999983e51 < b < 3.7999999999999999e-77 or 1.28000000000000001e57 < b < 1.75000000000000008e118

    1. Initial program 97.7%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in b around 0 94.4%

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

    if 1.75000000000000008e118 < b

    1. Initial program 88.6%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 88.8%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - a \cdot \left(t - 1\right)} \]
    4. Taylor expanded in a around 0 90.2%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -5.9 \cdot 10^{+51}:\\ \;\;\;\;\left(x + b \cdot \left(\left(y + t\right) - 2\right)\right) + a \cdot \left(1 - t\right)\\ \mathbf{elif}\;b \leq 3.8 \cdot 10^{-77}:\\ \;\;\;\;x + \left(a \cdot \left(1 - t\right) + z \cdot \left(1 - y\right)\right)\\ \mathbf{elif}\;b \leq 1.28 \cdot 10^{+57}:\\ \;\;\;\;\left(x + b \cdot \left(\left(y + t\right) - 2\right)\right) + a \cdot \left(1 - t\right)\\ \mathbf{elif}\;b \leq 1.75 \cdot 10^{+118}:\\ \;\;\;\;x + \left(a \cdot \left(1 - t\right) + z \cdot \left(1 - y\right)\right)\\ \mathbf{else}:\\ \;\;\;\;x + b \cdot \left(\left(y + t\right) - 2\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 15: 26.8% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t \cdot \left(-a\right)\\ \mathbf{if}\;b \leq -2.18 \cdot 10^{+175}:\\ \;\;\;\;t \cdot b\\ \mathbf{elif}\;b \leq -2.05 \cdot 10^{+16}:\\ \;\;\;\;y \cdot b\\ \mathbf{elif}\;b \leq 3.3 \cdot 10^{-271}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;b \leq 2.75 \cdot 10^{-219}:\\ \;\;\;\;x\\ \mathbf{elif}\;b \leq 1.72:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t \cdot b\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (* t (- a))))
   (if (<= b -2.18e+175)
     (* t b)
     (if (<= b -2.05e+16)
       (* y b)
       (if (<= b 3.3e-271)
         t_1
         (if (<= b 2.75e-219) x (if (<= b 1.72) t_1 (* t b))))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = t * -a;
	double tmp;
	if (b <= -2.18e+175) {
		tmp = t * b;
	} else if (b <= -2.05e+16) {
		tmp = y * b;
	} else if (b <= 3.3e-271) {
		tmp = t_1;
	} else if (b <= 2.75e-219) {
		tmp = x;
	} else if (b <= 1.72) {
		tmp = t_1;
	} else {
		tmp = t * 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 = t * -a
    if (b <= (-2.18d+175)) then
        tmp = t * b
    else if (b <= (-2.05d+16)) then
        tmp = y * b
    else if (b <= 3.3d-271) then
        tmp = t_1
    else if (b <= 2.75d-219) then
        tmp = x
    else if (b <= 1.72d0) then
        tmp = t_1
    else
        tmp = t * 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 = t * -a;
	double tmp;
	if (b <= -2.18e+175) {
		tmp = t * b;
	} else if (b <= -2.05e+16) {
		tmp = y * b;
	} else if (b <= 3.3e-271) {
		tmp = t_1;
	} else if (b <= 2.75e-219) {
		tmp = x;
	} else if (b <= 1.72) {
		tmp = t_1;
	} else {
		tmp = t * b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = t * -a
	tmp = 0
	if b <= -2.18e+175:
		tmp = t * b
	elif b <= -2.05e+16:
		tmp = y * b
	elif b <= 3.3e-271:
		tmp = t_1
	elif b <= 2.75e-219:
		tmp = x
	elif b <= 1.72:
		tmp = t_1
	else:
		tmp = t * b
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(t * Float64(-a))
	tmp = 0.0
	if (b <= -2.18e+175)
		tmp = Float64(t * b);
	elseif (b <= -2.05e+16)
		tmp = Float64(y * b);
	elseif (b <= 3.3e-271)
		tmp = t_1;
	elseif (b <= 2.75e-219)
		tmp = x;
	elseif (b <= 1.72)
		tmp = t_1;
	else
		tmp = Float64(t * b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = t * -a;
	tmp = 0.0;
	if (b <= -2.18e+175)
		tmp = t * b;
	elseif (b <= -2.05e+16)
		tmp = y * b;
	elseif (b <= 3.3e-271)
		tmp = t_1;
	elseif (b <= 2.75e-219)
		tmp = x;
	elseif (b <= 1.72)
		tmp = t_1;
	else
		tmp = t * b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(t * (-a)), $MachinePrecision]}, If[LessEqual[b, -2.18e+175], N[(t * b), $MachinePrecision], If[LessEqual[b, -2.05e+16], N[(y * b), $MachinePrecision], If[LessEqual[b, 3.3e-271], t$95$1, If[LessEqual[b, 2.75e-219], x, If[LessEqual[b, 1.72], t$95$1, N[(t * b), $MachinePrecision]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := t \cdot \left(-a\right)\\
\mathbf{if}\;b \leq -2.18 \cdot 10^{+175}:\\
\;\;\;\;t \cdot b\\

\mathbf{elif}\;b \leq -2.05 \cdot 10^{+16}:\\
\;\;\;\;y \cdot b\\

\mathbf{elif}\;b \leq 3.3 \cdot 10^{-271}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;b \leq 2.75 \cdot 10^{-219}:\\
\;\;\;\;x\\

\mathbf{elif}\;b \leq 1.72:\\
\;\;\;\;t\_1\\

\mathbf{else}:\\
\;\;\;\;t \cdot b\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if b < -2.1799999999999999e175 or 1.71999999999999997 < b

    1. Initial program 92.6%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in a around 0 90.6%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - z \cdot \left(y - 1\right)} \]
    4. Taylor expanded in t around inf 44.6%

      \[\leadsto \color{blue}{b \cdot t} \]

    if -2.1799999999999999e175 < b < -2.05e16

    1. Initial program 96.2%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 81.7%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - a \cdot \left(t - 1\right)} \]
    4. Taylor expanded in y around inf 36.2%

      \[\leadsto \color{blue}{b \cdot y} \]

    if -2.05e16 < b < 3.3000000000000002e-271 or 2.75000000000000009e-219 < b < 1.71999999999999997

    1. Initial program 100.0%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 38.8%

      \[\leadsto \color{blue}{t \cdot \left(b - a\right)} \]
    4. Taylor expanded in b around 0 36.1%

      \[\leadsto \color{blue}{-1 \cdot \left(a \cdot t\right)} \]
    5. Step-by-step derivation
      1. associate-*r*36.1%

        \[\leadsto \color{blue}{\left(-1 \cdot a\right) \cdot t} \]
      2. mul-1-neg36.1%

        \[\leadsto \color{blue}{\left(-a\right)} \cdot t \]
    6. Simplified36.1%

      \[\leadsto \color{blue}{\left(-a\right) \cdot t} \]

    if 3.3000000000000002e-271 < b < 2.75000000000000009e-219

    1. Initial program 93.8%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 51.0%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -2.18 \cdot 10^{+175}:\\ \;\;\;\;t \cdot b\\ \mathbf{elif}\;b \leq -2.05 \cdot 10^{+16}:\\ \;\;\;\;y \cdot b\\ \mathbf{elif}\;b \leq 3.3 \cdot 10^{-271}:\\ \;\;\;\;t \cdot \left(-a\right)\\ \mathbf{elif}\;b \leq 2.75 \cdot 10^{-219}:\\ \;\;\;\;x\\ \mathbf{elif}\;b \leq 1.72:\\ \;\;\;\;t \cdot \left(-a\right)\\ \mathbf{else}:\\ \;\;\;\;t \cdot b\\ \end{array} \]
  5. Add Preprocessing

Alternative 16: 27.1% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -4.1 \cdot 10^{+34}:\\ \;\;\;\;t \cdot b\\ \mathbf{elif}\;t \leq -8.5 \cdot 10^{-88}:\\ \;\;\;\;y \cdot b\\ \mathbf{elif}\;t \leq -1.56 \cdot 10^{-134}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq 2.35 \cdot 10^{-267}:\\ \;\;\;\;a\\ \mathbf{elif}\;t \leq 3.8 \cdot 10^{+18}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;t \cdot b\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (<= t -4.1e+34)
   (* t b)
   (if (<= t -8.5e-88)
     (* y b)
     (if (<= t -1.56e-134)
       x
       (if (<= t 2.35e-267) a (if (<= t 3.8e+18) x (* t b)))))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (t <= -4.1e+34) {
		tmp = t * b;
	} else if (t <= -8.5e-88) {
		tmp = y * b;
	} else if (t <= -1.56e-134) {
		tmp = x;
	} else if (t <= 2.35e-267) {
		tmp = a;
	} else if (t <= 3.8e+18) {
		tmp = x;
	} else {
		tmp = t * 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 (t <= (-4.1d+34)) then
        tmp = t * b
    else if (t <= (-8.5d-88)) then
        tmp = y * b
    else if (t <= (-1.56d-134)) then
        tmp = x
    else if (t <= 2.35d-267) then
        tmp = a
    else if (t <= 3.8d+18) then
        tmp = x
    else
        tmp = t * 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 (t <= -4.1e+34) {
		tmp = t * b;
	} else if (t <= -8.5e-88) {
		tmp = y * b;
	} else if (t <= -1.56e-134) {
		tmp = x;
	} else if (t <= 2.35e-267) {
		tmp = a;
	} else if (t <= 3.8e+18) {
		tmp = x;
	} else {
		tmp = t * b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if t <= -4.1e+34:
		tmp = t * b
	elif t <= -8.5e-88:
		tmp = y * b
	elif t <= -1.56e-134:
		tmp = x
	elif t <= 2.35e-267:
		tmp = a
	elif t <= 3.8e+18:
		tmp = x
	else:
		tmp = t * b
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (t <= -4.1e+34)
		tmp = Float64(t * b);
	elseif (t <= -8.5e-88)
		tmp = Float64(y * b);
	elseif (t <= -1.56e-134)
		tmp = x;
	elseif (t <= 2.35e-267)
		tmp = a;
	elseif (t <= 3.8e+18)
		tmp = x;
	else
		tmp = Float64(t * b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (t <= -4.1e+34)
		tmp = t * b;
	elseif (t <= -8.5e-88)
		tmp = y * b;
	elseif (t <= -1.56e-134)
		tmp = x;
	elseif (t <= 2.35e-267)
		tmp = a;
	elseif (t <= 3.8e+18)
		tmp = x;
	else
		tmp = t * b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[t, -4.1e+34], N[(t * b), $MachinePrecision], If[LessEqual[t, -8.5e-88], N[(y * b), $MachinePrecision], If[LessEqual[t, -1.56e-134], x, If[LessEqual[t, 2.35e-267], a, If[LessEqual[t, 3.8e+18], x, N[(t * b), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.1 \cdot 10^{+34}:\\
\;\;\;\;t \cdot b\\

\mathbf{elif}\;t \leq -8.5 \cdot 10^{-88}:\\
\;\;\;\;y \cdot b\\

\mathbf{elif}\;t \leq -1.56 \cdot 10^{-134}:\\
\;\;\;\;x\\

\mathbf{elif}\;t \leq 2.35 \cdot 10^{-267}:\\
\;\;\;\;a\\

\mathbf{elif}\;t \leq 3.8 \cdot 10^{+18}:\\
\;\;\;\;x\\

\mathbf{else}:\\
\;\;\;\;t \cdot b\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < -4.0999999999999998e34 or 3.8e18 < t

    1. Initial program 92.7%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in a around 0 69.2%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - z \cdot \left(y - 1\right)} \]
    4. Taylor expanded in t around inf 44.8%

      \[\leadsto \color{blue}{b \cdot t} \]

    if -4.0999999999999998e34 < t < -8.4999999999999996e-88

    1. Initial program 100.0%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 72.3%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - a \cdot \left(t - 1\right)} \]
    4. Taylor expanded in y around inf 28.2%

      \[\leadsto \color{blue}{b \cdot y} \]

    if -8.4999999999999996e-88 < t < -1.56000000000000009e-134 or 2.3500000000000001e-267 < t < 3.8e18

    1. Initial program 100.0%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 32.4%

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

    if -1.56000000000000009e-134 < t < 2.3500000000000001e-267

    1. Initial program 97.1%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in a around inf 38.9%

      \[\leadsto \color{blue}{a \cdot \left(1 - t\right)} \]
    4. Taylor expanded in t around 0 38.9%

      \[\leadsto \color{blue}{a} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification38.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -4.1 \cdot 10^{+34}:\\ \;\;\;\;t \cdot b\\ \mathbf{elif}\;t \leq -8.5 \cdot 10^{-88}:\\ \;\;\;\;y \cdot b\\ \mathbf{elif}\;t \leq -1.56 \cdot 10^{-134}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq 2.35 \cdot 10^{-267}:\\ \;\;\;\;a\\ \mathbf{elif}\;t \leq 3.8 \cdot 10^{+18}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;t \cdot b\\ \end{array} \]
  5. Add Preprocessing

Alternative 17: 47.7% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
t_1 := b \cdot \left(y - 2\right)\\
t_2 := t \cdot \left(b - a\right)\\
\mathbf{if}\;t \leq -11200000:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;t \leq -3.8 \cdot 10^{-84}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t \leq -1.22 \cdot 10^{-113}:\\
\;\;\;\;x\\

\mathbf{elif}\;t \leq 16000000:\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -1.12e7 or 1.6e7 < t

    1. Initial program 93.3%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 71.8%

      \[\leadsto \color{blue}{t \cdot \left(b - a\right)} \]

    if -1.12e7 < t < -3.79999999999999986e-84 or -1.21999999999999995e-113 < t < 1.6e7

    1. Initial program 99.1%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 33.8%

      \[\leadsto \color{blue}{-1 \cdot \left(a \cdot t\right)} + \left(\left(y + t\right) - 2\right) \cdot b \]
    4. Step-by-step derivation
      1. mul-1-neg33.8%

        \[\leadsto \color{blue}{\left(-a \cdot t\right)} + \left(\left(y + t\right) - 2\right) \cdot b \]
      2. distribute-rgt-neg-in33.8%

        \[\leadsto \color{blue}{a \cdot \left(-t\right)} + \left(\left(y + t\right) - 2\right) \cdot b \]
    5. Simplified33.8%

      \[\leadsto \color{blue}{a \cdot \left(-t\right)} + \left(\left(y + t\right) - 2\right) \cdot b \]
    6. Taylor expanded in t around 0 33.4%

      \[\leadsto \color{blue}{b \cdot \left(y - 2\right)} \]

    if -3.79999999999999986e-84 < t < -1.21999999999999995e-113

    1. Initial program 100.0%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 56.5%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -11200000:\\ \;\;\;\;t \cdot \left(b - a\right)\\ \mathbf{elif}\;t \leq -3.8 \cdot 10^{-84}:\\ \;\;\;\;b \cdot \left(y - 2\right)\\ \mathbf{elif}\;t \leq -1.22 \cdot 10^{-113}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq 16000000:\\ \;\;\;\;b \cdot \left(y - 2\right)\\ \mathbf{else}:\\ \;\;\;\;t \cdot \left(b - a\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 18: 86.5% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
t_1 := z \cdot \left(1 - y\right)\\
\mathbf{if}\;b \leq -2.2 \cdot 10^{+43} \lor \neg \left(b \leq 22\right):\\
\;\;\;\;\left(x + b \cdot \left(\left(y + t\right) - 2\right)\right) + t\_1\\

\mathbf{else}:\\
\;\;\;\;x + \left(a \cdot \left(1 - t\right) + t\_1\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if b < -2.20000000000000001e43 or 22 < b

    1. Initial program 93.9%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in a around 0 88.6%

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

    if -2.20000000000000001e43 < b < 22

    1. Initial program 98.3%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in b around 0 94.1%

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

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

Alternative 19: 67.2% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -480000000:\\ \;\;\;\;t \cdot \left(b - a\right)\\ \mathbf{elif}\;t \leq 3 \cdot 10^{+14}:\\ \;\;\;\;x + \left(a + b \cdot \left(y + -2\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot \left(\left(y + t\right) - 2\right) - t \cdot a\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (<= t -480000000.0)
   (* t (- b a))
   (if (<= t 3e+14)
     (+ x (+ a (* b (+ y -2.0))))
     (- (* b (- (+ y t) 2.0)) (* t a)))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (t <= -480000000.0) {
		tmp = t * (b - a);
	} else if (t <= 3e+14) {
		tmp = x + (a + (b * (y + -2.0)));
	} else {
		tmp = (b * ((y + t) - 2.0)) - (t * a);
	}
	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 (t <= (-480000000.0d0)) then
        tmp = t * (b - a)
    else if (t <= 3d+14) then
        tmp = x + (a + (b * (y + (-2.0d0))))
    else
        tmp = (b * ((y + t) - 2.0d0)) - (t * a)
    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 (t <= -480000000.0) {
		tmp = t * (b - a);
	} else if (t <= 3e+14) {
		tmp = x + (a + (b * (y + -2.0)));
	} else {
		tmp = (b * ((y + t) - 2.0)) - (t * a);
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if t <= -480000000.0:
		tmp = t * (b - a)
	elif t <= 3e+14:
		tmp = x + (a + (b * (y + -2.0)))
	else:
		tmp = (b * ((y + t) - 2.0)) - (t * a)
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (t <= -480000000.0)
		tmp = Float64(t * Float64(b - a));
	elseif (t <= 3e+14)
		tmp = Float64(x + Float64(a + Float64(b * Float64(y + -2.0))));
	else
		tmp = Float64(Float64(b * Float64(Float64(y + t) - 2.0)) - Float64(t * a));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (t <= -480000000.0)
		tmp = t * (b - a);
	elseif (t <= 3e+14)
		tmp = x + (a + (b * (y + -2.0)));
	else
		tmp = (b * ((y + t) - 2.0)) - (t * a);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[t, -480000000.0], N[(t * N[(b - a), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 3e+14], N[(x + N[(a + N[(b * N[(y + -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(b * N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision] - N[(t * a), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -480000000:\\
\;\;\;\;t \cdot \left(b - a\right)\\

\mathbf{elif}\;t \leq 3 \cdot 10^{+14}:\\
\;\;\;\;x + \left(a + b \cdot \left(y + -2\right)\right)\\

\mathbf{else}:\\
\;\;\;\;b \cdot \left(\left(y + t\right) - 2\right) - t \cdot a\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -4.8e8

    1. Initial program 89.8%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 71.5%

      \[\leadsto \color{blue}{t \cdot \left(b - a\right)} \]

    if -4.8e8 < t < 3e14

    1. Initial program 99.2%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 74.8%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - a \cdot \left(t - 1\right)} \]
    4. Taylor expanded in t around 0 73.9%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(y - 2\right)\right) - -1 \cdot a} \]
    5. Step-by-step derivation
      1. associate--l+73.9%

        \[\leadsto \color{blue}{x + \left(b \cdot \left(y - 2\right) - -1 \cdot a\right)} \]
      2. sub-neg73.9%

        \[\leadsto x + \left(b \cdot \color{blue}{\left(y + \left(-2\right)\right)} - -1 \cdot a\right) \]
      3. metadata-eval73.9%

        \[\leadsto x + \left(b \cdot \left(y + \color{blue}{-2}\right) - -1 \cdot a\right) \]
      4. neg-mul-173.9%

        \[\leadsto x + \left(b \cdot \left(y + -2\right) - \color{blue}{\left(-a\right)}\right) \]
    6. Simplified73.9%

      \[\leadsto \color{blue}{x + \left(b \cdot \left(y + -2\right) - \left(-a\right)\right)} \]

    if 3e14 < t

    1. Initial program 95.8%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 77.8%

      \[\leadsto \color{blue}{-1 \cdot \left(a \cdot t\right)} + \left(\left(y + t\right) - 2\right) \cdot b \]
    4. Step-by-step derivation
      1. mul-1-neg77.8%

        \[\leadsto \color{blue}{\left(-a \cdot t\right)} + \left(\left(y + t\right) - 2\right) \cdot b \]
      2. distribute-rgt-neg-in77.8%

        \[\leadsto \color{blue}{a \cdot \left(-t\right)} + \left(\left(y + t\right) - 2\right) \cdot b \]
    5. Simplified77.8%

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

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

Alternative 20: 66.8% accurate, 1.1× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.1 \cdot 10^{+14} \lor \neg \left(t \leq 4.1 \cdot 10^{+14}\right):\\
\;\;\;\;t \cdot \left(b - a\right)\\

\mathbf{else}:\\
\;\;\;\;x + \left(a + b \cdot \left(y + -2\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -3.1e14 or 4.1e14 < t

    1. Initial program 93.2%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 72.9%

      \[\leadsto \color{blue}{t \cdot \left(b - a\right)} \]

    if -3.1e14 < t < 4.1e14

    1. Initial program 99.2%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 74.8%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - a \cdot \left(t - 1\right)} \]
    4. Taylor expanded in t around 0 73.9%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(y - 2\right)\right) - -1 \cdot a} \]
    5. Step-by-step derivation
      1. associate--l+73.9%

        \[\leadsto \color{blue}{x + \left(b \cdot \left(y - 2\right) - -1 \cdot a\right)} \]
      2. sub-neg73.9%

        \[\leadsto x + \left(b \cdot \color{blue}{\left(y + \left(-2\right)\right)} - -1 \cdot a\right) \]
      3. metadata-eval73.9%

        \[\leadsto x + \left(b \cdot \left(y + \color{blue}{-2}\right) - -1 \cdot a\right) \]
      4. neg-mul-173.9%

        \[\leadsto x + \left(b \cdot \left(y + -2\right) - \color{blue}{\left(-a\right)}\right) \]
    6. Simplified73.9%

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

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

Alternative 21: 26.3% accurate, 1.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -6 \cdot 10^{+25}:\\ \;\;\;\;t \cdot b\\ \mathbf{elif}\;t \leq 5.8 \cdot 10^{-267}:\\ \;\;\;\;a\\ \mathbf{elif}\;t \leq 2.1 \cdot 10^{+18}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;t \cdot b\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (<= t -6e+25)
   (* t b)
   (if (<= t 5.8e-267) a (if (<= t 2.1e+18) x (* t b)))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (t <= -6e+25) {
		tmp = t * b;
	} else if (t <= 5.8e-267) {
		tmp = a;
	} else if (t <= 2.1e+18) {
		tmp = x;
	} else {
		tmp = t * 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 (t <= (-6d+25)) then
        tmp = t * b
    else if (t <= 5.8d-267) then
        tmp = a
    else if (t <= 2.1d+18) then
        tmp = x
    else
        tmp = t * 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 (t <= -6e+25) {
		tmp = t * b;
	} else if (t <= 5.8e-267) {
		tmp = a;
	} else if (t <= 2.1e+18) {
		tmp = x;
	} else {
		tmp = t * b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if t <= -6e+25:
		tmp = t * b
	elif t <= 5.8e-267:
		tmp = a
	elif t <= 2.1e+18:
		tmp = x
	else:
		tmp = t * b
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (t <= -6e+25)
		tmp = Float64(t * b);
	elseif (t <= 5.8e-267)
		tmp = a;
	elseif (t <= 2.1e+18)
		tmp = x;
	else
		tmp = Float64(t * b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (t <= -6e+25)
		tmp = t * b;
	elseif (t <= 5.8e-267)
		tmp = a;
	elseif (t <= 2.1e+18)
		tmp = x;
	else
		tmp = t * b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[t, -6e+25], N[(t * b), $MachinePrecision], If[LessEqual[t, 5.8e-267], a, If[LessEqual[t, 2.1e+18], x, N[(t * b), $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -6 \cdot 10^{+25}:\\
\;\;\;\;t \cdot b\\

\mathbf{elif}\;t \leq 5.8 \cdot 10^{-267}:\\
\;\;\;\;a\\

\mathbf{elif}\;t \leq 2.1 \cdot 10^{+18}:\\
\;\;\;\;x\\

\mathbf{else}:\\
\;\;\;\;t \cdot b\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -6.00000000000000011e25 or 2.1e18 < t

    1. Initial program 92.7%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in a around 0 69.2%

      \[\leadsto \color{blue}{\left(x + b \cdot \left(\left(t + y\right) - 2\right)\right) - z \cdot \left(y - 1\right)} \]
    4. Taylor expanded in t around inf 44.8%

      \[\leadsto \color{blue}{b \cdot t} \]

    if -6.00000000000000011e25 < t < 5.80000000000000043e-267

    1. Initial program 98.6%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in a around inf 31.4%

      \[\leadsto \color{blue}{a \cdot \left(1 - t\right)} \]
    4. Taylor expanded in t around 0 27.6%

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

    if 5.80000000000000043e-267 < t < 2.1e18

    1. Initial program 99.9%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 27.6%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -6 \cdot 10^{+25}:\\ \;\;\;\;t \cdot b\\ \mathbf{elif}\;t \leq 5.8 \cdot 10^{-267}:\\ \;\;\;\;a\\ \mathbf{elif}\;t \leq 2.1 \cdot 10^{+18}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;t \cdot b\\ \end{array} \]
  5. Add Preprocessing

Alternative 22: 21.9% accurate, 1.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x \leq -3.9 \cdot 10^{+40}:\\ \;\;\;\;x\\ \mathbf{elif}\;x \leq 1.55 \cdot 10^{+45}:\\ \;\;\;\;a\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (<= x -3.9e+40) x (if (<= x 1.55e+45) a x)))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (x <= -3.9e+40) {
		tmp = x;
	} else if (x <= 1.55e+45) {
		tmp = 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 (x <= (-3.9d+40)) then
        tmp = x
    else if (x <= 1.55d+45) then
        tmp = 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 (x <= -3.9e+40) {
		tmp = x;
	} else if (x <= 1.55e+45) {
		tmp = a;
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if x <= -3.9e+40:
		tmp = x
	elif x <= 1.55e+45:
		tmp = a
	else:
		tmp = x
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (x <= -3.9e+40)
		tmp = x;
	elseif (x <= 1.55e+45)
		tmp = a;
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (x <= -3.9e+40)
		tmp = x;
	elseif (x <= 1.55e+45)
		tmp = a;
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[x, -3.9e+40], x, If[LessEqual[x, 1.55e+45], a, x]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;x \leq -3.9 \cdot 10^{+40}:\\
\;\;\;\;x\\

\mathbf{elif}\;x \leq 1.55 \cdot 10^{+45}:\\
\;\;\;\;a\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if x < -3.9000000000000001e40 or 1.54999999999999994e45 < x

    1. Initial program 94.6%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 30.8%

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

    if -3.9000000000000001e40 < x < 1.54999999999999994e45

    1. Initial program 97.2%

      \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
    2. Add Preprocessing
    3. Taylor expanded in a around inf 37.0%

      \[\leadsto \color{blue}{a \cdot \left(1 - t\right)} \]
    4. Taylor expanded in t around 0 14.8%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -3.9 \cdot 10^{+40}:\\ \;\;\;\;x\\ \mathbf{elif}\;x \leq 1.55 \cdot 10^{+45}:\\ \;\;\;\;a\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]
  5. Add Preprocessing

Alternative 23: 11.4% accurate, 21.0× speedup?

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

\\
a
\end{array}
Derivation
  1. Initial program 96.1%

    \[\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b \]
  2. Add Preprocessing
  3. Taylor expanded in a around inf 32.4%

    \[\leadsto \color{blue}{a \cdot \left(1 - t\right)} \]
  4. Taylor expanded in t around 0 12.1%

    \[\leadsto \color{blue}{a} \]
  5. Final simplification12.1%

    \[\leadsto a \]
  6. Add Preprocessing

Reproduce

?
herbie shell --seed 2024031 
(FPCore (x y z t a b)
  :name "Statistics.Distribution.Beta:$centropy from math-functions-0.1.5.2"
  :precision binary64
  (+ (- (- x (* (- y 1.0) z)) (* (- t 1.0) a)) (* (- (+ y t) 2.0) b)))