Numeric.Signal.Multichannel:$cput from hsignal-0.2.7.1

Percentage Accurate: 96.8% → 96.8%
Time: 12.3s
Alternatives: 17
Speedup: 1.0×

Specification

?
\[\begin{array}{l} \\ \frac{x - y}{z - y} \cdot t \end{array} \]
(FPCore (x y z t) :precision binary64 (* (/ (- x y) (- z y)) t))
double code(double x, double y, double z, double t) {
	return ((x - y) / (z - y)) * t;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    code = ((x - y) / (z - y)) * t
end function
public static double code(double x, double y, double z, double t) {
	return ((x - y) / (z - y)) * t;
}
def code(x, y, z, t):
	return ((x - y) / (z - y)) * t
function code(x, y, z, t)
	return Float64(Float64(Float64(x - y) / Float64(z - y)) * t)
end
function tmp = code(x, y, z, t)
	tmp = ((x - y) / (z - y)) * t;
end
code[x_, y_, z_, t_] := N[(N[(N[(x - y), $MachinePrecision] / N[(z - y), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision]
\begin{array}{l}

\\
\frac{x - y}{z - y} \cdot t
\end{array}

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

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

Accuracy vs Speed?

Herbie found 17 alternatives:

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

Initial Program: 96.8% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \frac{x - y}{z - y} \cdot t \end{array} \]
(FPCore (x y z t) :precision binary64 (* (/ (- x y) (- z y)) t))
double code(double x, double y, double z, double t) {
	return ((x - y) / (z - y)) * t;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    code = ((x - y) / (z - y)) * t
end function
public static double code(double x, double y, double z, double t) {
	return ((x - y) / (z - y)) * t;
}
def code(x, y, z, t):
	return ((x - y) / (z - y)) * t
function code(x, y, z, t)
	return Float64(Float64(Float64(x - y) / Float64(z - y)) * t)
end
function tmp = code(x, y, z, t)
	tmp = ((x - y) / (z - y)) * t;
end
code[x_, y_, z_, t_] := N[(N[(N[(x - y), $MachinePrecision] / N[(z - y), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision]
\begin{array}{l}

\\
\frac{x - y}{z - y} \cdot t
\end{array}

Alternative 1: 96.8% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \frac{t}{\frac{z - y}{x - y}} \end{array} \]
(FPCore (x y z t) :precision binary64 (/ t (/ (- z y) (- x y))))
double code(double x, double y, double z, double t) {
	return t / ((z - y) / (x - y));
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    code = t / ((z - y) / (x - y))
end function
public static double code(double x, double y, double z, double t) {
	return t / ((z - y) / (x - y));
}
def code(x, y, z, t):
	return t / ((z - y) / (x - y))
function code(x, y, z, t)
	return Float64(t / Float64(Float64(z - y) / Float64(x - y)))
end
function tmp = code(x, y, z, t)
	tmp = t / ((z - y) / (x - y));
end
code[x_, y_, z_, t_] := N[(t / N[(N[(z - y), $MachinePrecision] / N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{t}{\frac{z - y}{x - y}}
\end{array}
Derivation
  1. Initial program 98.0%

    \[\frac{x - y}{z - y} \cdot t \]
  2. Step-by-step derivation
    1. associate-*l/83.2%

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

      \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
  3. Simplified82.2%

    \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
  4. Add Preprocessing
  5. Step-by-step derivation
    1. associate-*r/83.2%

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

      \[\leadsto \color{blue}{\frac{x - y}{z - y} \cdot t} \]
    3. *-commutative98.0%

      \[\leadsto \color{blue}{t \cdot \frac{x - y}{z - y}} \]
    4. clear-num97.9%

      \[\leadsto t \cdot \color{blue}{\frac{1}{\frac{z - y}{x - y}}} \]
    5. un-div-inv98.1%

      \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
  6. Applied egg-rr98.1%

    \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
  7. Add Preprocessing

Alternative 2: 73.4% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t \cdot \frac{x - y}{z}\\ t_2 := t \cdot \left(1 - \frac{x}{y}\right)\\ t_3 := t \cdot \frac{x}{z - y}\\ \mathbf{if}\;y \leq -8 \cdot 10^{-50}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y \leq -5 \cdot 10^{-98}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq -1.3 \cdot 10^{-120}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y \leq -6 \cdot 10^{-236}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;y \leq -5 \cdot 10^{-242}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y \leq -4.2 \cdot 10^{-277}:\\ \;\;\;\;x \cdot \frac{t}{z}\\ \mathbf{elif}\;y \leq 3.4 \cdot 10^{-288}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;y \leq 4.8 \cdot 10^{-142}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 5 \cdot 10^{-142}:\\ \;\;\;\;t\\ \mathbf{elif}\;y \leq 1.05 \cdot 10^{-68}:\\ \;\;\;\;t\_3\\ \mathbf{else}:\\ \;\;\;\;t - t \cdot \frac{x}{y}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (* t (/ (- x y) z)))
        (t_2 (* t (- 1.0 (/ x y))))
        (t_3 (* t (/ x (- z y)))))
   (if (<= y -8e-50)
     t_2
     (if (<= y -5e-98)
       t_1
       (if (<= y -1.3e-120)
         t_2
         (if (<= y -6e-236)
           t_3
           (if (<= y -5e-242)
             t_2
             (if (<= y -4.2e-277)
               (* x (/ t z))
               (if (<= y 3.4e-288)
                 t_3
                 (if (<= y 4.8e-142)
                   t_1
                   (if (<= y 5e-142)
                     t
                     (if (<= y 1.05e-68) t_3 (- t (* t (/ x y)))))))))))))))
double code(double x, double y, double z, double t) {
	double t_1 = t * ((x - y) / z);
	double t_2 = t * (1.0 - (x / y));
	double t_3 = t * (x / (z - y));
	double tmp;
	if (y <= -8e-50) {
		tmp = t_2;
	} else if (y <= -5e-98) {
		tmp = t_1;
	} else if (y <= -1.3e-120) {
		tmp = t_2;
	} else if (y <= -6e-236) {
		tmp = t_3;
	} else if (y <= -5e-242) {
		tmp = t_2;
	} else if (y <= -4.2e-277) {
		tmp = x * (t / z);
	} else if (y <= 3.4e-288) {
		tmp = t_3;
	} else if (y <= 4.8e-142) {
		tmp = t_1;
	} else if (y <= 5e-142) {
		tmp = t;
	} else if (y <= 1.05e-68) {
		tmp = t_3;
	} else {
		tmp = t - (t * (x / y));
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: t_3
    real(8) :: tmp
    t_1 = t * ((x - y) / z)
    t_2 = t * (1.0d0 - (x / y))
    t_3 = t * (x / (z - y))
    if (y <= (-8d-50)) then
        tmp = t_2
    else if (y <= (-5d-98)) then
        tmp = t_1
    else if (y <= (-1.3d-120)) then
        tmp = t_2
    else if (y <= (-6d-236)) then
        tmp = t_3
    else if (y <= (-5d-242)) then
        tmp = t_2
    else if (y <= (-4.2d-277)) then
        tmp = x * (t / z)
    else if (y <= 3.4d-288) then
        tmp = t_3
    else if (y <= 4.8d-142) then
        tmp = t_1
    else if (y <= 5d-142) then
        tmp = t
    else if (y <= 1.05d-68) then
        tmp = t_3
    else
        tmp = t - (t * (x / y))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double t_1 = t * ((x - y) / z);
	double t_2 = t * (1.0 - (x / y));
	double t_3 = t * (x / (z - y));
	double tmp;
	if (y <= -8e-50) {
		tmp = t_2;
	} else if (y <= -5e-98) {
		tmp = t_1;
	} else if (y <= -1.3e-120) {
		tmp = t_2;
	} else if (y <= -6e-236) {
		tmp = t_3;
	} else if (y <= -5e-242) {
		tmp = t_2;
	} else if (y <= -4.2e-277) {
		tmp = x * (t / z);
	} else if (y <= 3.4e-288) {
		tmp = t_3;
	} else if (y <= 4.8e-142) {
		tmp = t_1;
	} else if (y <= 5e-142) {
		tmp = t;
	} else if (y <= 1.05e-68) {
		tmp = t_3;
	} else {
		tmp = t - (t * (x / y));
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = t * ((x - y) / z)
	t_2 = t * (1.0 - (x / y))
	t_3 = t * (x / (z - y))
	tmp = 0
	if y <= -8e-50:
		tmp = t_2
	elif y <= -5e-98:
		tmp = t_1
	elif y <= -1.3e-120:
		tmp = t_2
	elif y <= -6e-236:
		tmp = t_3
	elif y <= -5e-242:
		tmp = t_2
	elif y <= -4.2e-277:
		tmp = x * (t / z)
	elif y <= 3.4e-288:
		tmp = t_3
	elif y <= 4.8e-142:
		tmp = t_1
	elif y <= 5e-142:
		tmp = t
	elif y <= 1.05e-68:
		tmp = t_3
	else:
		tmp = t - (t * (x / y))
	return tmp
function code(x, y, z, t)
	t_1 = Float64(t * Float64(Float64(x - y) / z))
	t_2 = Float64(t * Float64(1.0 - Float64(x / y)))
	t_3 = Float64(t * Float64(x / Float64(z - y)))
	tmp = 0.0
	if (y <= -8e-50)
		tmp = t_2;
	elseif (y <= -5e-98)
		tmp = t_1;
	elseif (y <= -1.3e-120)
		tmp = t_2;
	elseif (y <= -6e-236)
		tmp = t_3;
	elseif (y <= -5e-242)
		tmp = t_2;
	elseif (y <= -4.2e-277)
		tmp = Float64(x * Float64(t / z));
	elseif (y <= 3.4e-288)
		tmp = t_3;
	elseif (y <= 4.8e-142)
		tmp = t_1;
	elseif (y <= 5e-142)
		tmp = t;
	elseif (y <= 1.05e-68)
		tmp = t_3;
	else
		tmp = Float64(t - Float64(t * Float64(x / y)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = t * ((x - y) / z);
	t_2 = t * (1.0 - (x / y));
	t_3 = t * (x / (z - y));
	tmp = 0.0;
	if (y <= -8e-50)
		tmp = t_2;
	elseif (y <= -5e-98)
		tmp = t_1;
	elseif (y <= -1.3e-120)
		tmp = t_2;
	elseif (y <= -6e-236)
		tmp = t_3;
	elseif (y <= -5e-242)
		tmp = t_2;
	elseif (y <= -4.2e-277)
		tmp = x * (t / z);
	elseif (y <= 3.4e-288)
		tmp = t_3;
	elseif (y <= 4.8e-142)
		tmp = t_1;
	elseif (y <= 5e-142)
		tmp = t;
	elseif (y <= 1.05e-68)
		tmp = t_3;
	else
		tmp = t - (t * (x / y));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(t * N[(N[(x - y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t * N[(1.0 - N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(t * N[(x / N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -8e-50], t$95$2, If[LessEqual[y, -5e-98], t$95$1, If[LessEqual[y, -1.3e-120], t$95$2, If[LessEqual[y, -6e-236], t$95$3, If[LessEqual[y, -5e-242], t$95$2, If[LessEqual[y, -4.2e-277], N[(x * N[(t / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3.4e-288], t$95$3, If[LessEqual[y, 4.8e-142], t$95$1, If[LessEqual[y, 5e-142], t, If[LessEqual[y, 1.05e-68], t$95$3, N[(t - N[(t * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := t \cdot \frac{x - y}{z}\\
t_2 := t \cdot \left(1 - \frac{x}{y}\right)\\
t_3 := t \cdot \frac{x}{z - y}\\
\mathbf{if}\;y \leq -8 \cdot 10^{-50}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y \leq -5 \cdot 10^{-98}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq -1.3 \cdot 10^{-120}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y \leq -6 \cdot 10^{-236}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;y \leq -5 \cdot 10^{-242}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y \leq -4.2 \cdot 10^{-277}:\\
\;\;\;\;x \cdot \frac{t}{z}\\

\mathbf{elif}\;y \leq 3.4 \cdot 10^{-288}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;y \leq 4.8 \cdot 10^{-142}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq 5 \cdot 10^{-142}:\\
\;\;\;\;t\\

\mathbf{elif}\;y \leq 1.05 \cdot 10^{-68}:\\
\;\;\;\;t\_3\\

\mathbf{else}:\\
\;\;\;\;t - t \cdot \frac{x}{y}\\


\end{array}
\end{array}
Derivation
  1. Split input into 6 regimes
  2. if y < -8.00000000000000006e-50 or -5.00000000000000018e-98 < y < -1.3000000000000001e-120 or -6.00000000000000027e-236 < y < -4.9999999999999998e-242

    1. Initial program 97.8%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/80.2%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified79.6%

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

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

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

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

        \[\leadsto t + -1 \cdot \color{blue}{\frac{t \cdot x - t \cdot z}{y}} \]
      4. mul-1-neg72.7%

        \[\leadsto t + \color{blue}{\left(-\frac{t \cdot x - t \cdot z}{y}\right)} \]
      5. unsub-neg72.7%

        \[\leadsto \color{blue}{t - \frac{t \cdot x - t \cdot z}{y}} \]
      6. distribute-lft-out--72.7%

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

        \[\leadsto t - \color{blue}{t \cdot \frac{x - z}{y}} \]
    7. Simplified75.7%

      \[\leadsto \color{blue}{t - t \cdot \frac{x - z}{y}} \]
    8. Taylor expanded in x around inf 75.4%

      \[\leadsto t - t \cdot \color{blue}{\frac{x}{y}} \]
    9. Taylor expanded in t around 0 75.4%

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

    if -8.00000000000000006e-50 < y < -5.00000000000000018e-98 or 3.39999999999999972e-288 < y < 4.79999999999999976e-142

    1. Initial program 99.9%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 94.1%

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

    if -1.3000000000000001e-120 < y < -6.00000000000000027e-236 or -4.1999999999999999e-277 < y < 3.39999999999999972e-288 or 5.0000000000000002e-142 < y < 1.05000000000000004e-68

    1. Initial program 96.4%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 77.0%

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

    if -4.9999999999999998e-242 < y < -4.1999999999999999e-277

    1. Initial program 81.1%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/81.0%

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

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

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

      \[\leadsto \color{blue}{\frac{t \cdot x}{z}} \]
    6. Step-by-step derivation
      1. *-commutative81.0%

        \[\leadsto \frac{\color{blue}{x \cdot t}}{z} \]
      2. associate-/l*100.0%

        \[\leadsto \color{blue}{x \cdot \frac{t}{z}} \]
    7. Simplified100.0%

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

    if 4.79999999999999976e-142 < y < 5.0000000000000002e-142

    1. Initial program 100.0%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/100.0%

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

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

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

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

    if 1.05000000000000004e-68 < y

    1. Initial program 99.8%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/80.3%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified74.8%

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

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

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

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

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

        \[\leadsto t + \color{blue}{\left(-\frac{t \cdot x - t \cdot z}{y}\right)} \]
      5. unsub-neg78.2%

        \[\leadsto \color{blue}{t - \frac{t \cdot x - t \cdot z}{y}} \]
      6. distribute-lft-out--79.8%

        \[\leadsto t - \frac{\color{blue}{t \cdot \left(x - z\right)}}{y} \]
      7. associate-/l*89.4%

        \[\leadsto t - \color{blue}{t \cdot \frac{x - z}{y}} \]
    7. Simplified89.4%

      \[\leadsto \color{blue}{t - t \cdot \frac{x - z}{y}} \]
    8. Taylor expanded in x around inf 88.9%

      \[\leadsto t - t \cdot \color{blue}{\frac{x}{y}} \]
  3. Recombined 6 regimes into one program.
  4. Final simplification82.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -8 \cdot 10^{-50}:\\ \;\;\;\;t \cdot \left(1 - \frac{x}{y}\right)\\ \mathbf{elif}\;y \leq -5 \cdot 10^{-98}:\\ \;\;\;\;t \cdot \frac{x - y}{z}\\ \mathbf{elif}\;y \leq -1.3 \cdot 10^{-120}:\\ \;\;\;\;t \cdot \left(1 - \frac{x}{y}\right)\\ \mathbf{elif}\;y \leq -6 \cdot 10^{-236}:\\ \;\;\;\;t \cdot \frac{x}{z - y}\\ \mathbf{elif}\;y \leq -5 \cdot 10^{-242}:\\ \;\;\;\;t \cdot \left(1 - \frac{x}{y}\right)\\ \mathbf{elif}\;y \leq -4.2 \cdot 10^{-277}:\\ \;\;\;\;x \cdot \frac{t}{z}\\ \mathbf{elif}\;y \leq 3.4 \cdot 10^{-288}:\\ \;\;\;\;t \cdot \frac{x}{z - y}\\ \mathbf{elif}\;y \leq 4.8 \cdot 10^{-142}:\\ \;\;\;\;t \cdot \frac{x - y}{z}\\ \mathbf{elif}\;y \leq 5 \cdot 10^{-142}:\\ \;\;\;\;t\\ \mathbf{elif}\;y \leq 1.05 \cdot 10^{-68}:\\ \;\;\;\;t \cdot \frac{x}{z - y}\\ \mathbf{else}:\\ \;\;\;\;t - t \cdot \frac{x}{y}\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 73.4% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t \cdot \frac{x - y}{z}\\ t_2 := t \cdot \left(1 - \frac{x}{y}\right)\\ t_3 := t \cdot \frac{x}{z - y}\\ \mathbf{if}\;y \leq -7.8 \cdot 10^{-50}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y \leq -2.15 \cdot 10^{-97}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq -1.3 \cdot 10^{-120}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y \leq -6 \cdot 10^{-236}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;y \leq -5 \cdot 10^{-242}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y \leq -4.2 \cdot 10^{-277}:\\ \;\;\;\;x \cdot \frac{t}{z}\\ \mathbf{elif}\;y \leq 5.4 \cdot 10^{-287}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;y \leq 4.8 \cdot 10^{-142}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 5 \cdot 10^{-142}:\\ \;\;\;\;t\\ \mathbf{elif}\;y \leq 4.5 \cdot 10^{-68}:\\ \;\;\;\;t\_3\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (* t (/ (- x y) z)))
        (t_2 (* t (- 1.0 (/ x y))))
        (t_3 (* t (/ x (- z y)))))
   (if (<= y -7.8e-50)
     t_2
     (if (<= y -2.15e-97)
       t_1
       (if (<= y -1.3e-120)
         t_2
         (if (<= y -6e-236)
           t_3
           (if (<= y -5e-242)
             t_2
             (if (<= y -4.2e-277)
               (* x (/ t z))
               (if (<= y 5.4e-287)
                 t_3
                 (if (<= y 4.8e-142)
                   t_1
                   (if (<= y 5e-142) t (if (<= y 4.5e-68) t_3 t_2))))))))))))
double code(double x, double y, double z, double t) {
	double t_1 = t * ((x - y) / z);
	double t_2 = t * (1.0 - (x / y));
	double t_3 = t * (x / (z - y));
	double tmp;
	if (y <= -7.8e-50) {
		tmp = t_2;
	} else if (y <= -2.15e-97) {
		tmp = t_1;
	} else if (y <= -1.3e-120) {
		tmp = t_2;
	} else if (y <= -6e-236) {
		tmp = t_3;
	} else if (y <= -5e-242) {
		tmp = t_2;
	} else if (y <= -4.2e-277) {
		tmp = x * (t / z);
	} else if (y <= 5.4e-287) {
		tmp = t_3;
	} else if (y <= 4.8e-142) {
		tmp = t_1;
	} else if (y <= 5e-142) {
		tmp = t;
	} else if (y <= 4.5e-68) {
		tmp = t_3;
	} else {
		tmp = t_2;
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: t_3
    real(8) :: tmp
    t_1 = t * ((x - y) / z)
    t_2 = t * (1.0d0 - (x / y))
    t_3 = t * (x / (z - y))
    if (y <= (-7.8d-50)) then
        tmp = t_2
    else if (y <= (-2.15d-97)) then
        tmp = t_1
    else if (y <= (-1.3d-120)) then
        tmp = t_2
    else if (y <= (-6d-236)) then
        tmp = t_3
    else if (y <= (-5d-242)) then
        tmp = t_2
    else if (y <= (-4.2d-277)) then
        tmp = x * (t / z)
    else if (y <= 5.4d-287) then
        tmp = t_3
    else if (y <= 4.8d-142) then
        tmp = t_1
    else if (y <= 5d-142) then
        tmp = t
    else if (y <= 4.5d-68) then
        tmp = t_3
    else
        tmp = t_2
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double t_1 = t * ((x - y) / z);
	double t_2 = t * (1.0 - (x / y));
	double t_3 = t * (x / (z - y));
	double tmp;
	if (y <= -7.8e-50) {
		tmp = t_2;
	} else if (y <= -2.15e-97) {
		tmp = t_1;
	} else if (y <= -1.3e-120) {
		tmp = t_2;
	} else if (y <= -6e-236) {
		tmp = t_3;
	} else if (y <= -5e-242) {
		tmp = t_2;
	} else if (y <= -4.2e-277) {
		tmp = x * (t / z);
	} else if (y <= 5.4e-287) {
		tmp = t_3;
	} else if (y <= 4.8e-142) {
		tmp = t_1;
	} else if (y <= 5e-142) {
		tmp = t;
	} else if (y <= 4.5e-68) {
		tmp = t_3;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = t * ((x - y) / z)
	t_2 = t * (1.0 - (x / y))
	t_3 = t * (x / (z - y))
	tmp = 0
	if y <= -7.8e-50:
		tmp = t_2
	elif y <= -2.15e-97:
		tmp = t_1
	elif y <= -1.3e-120:
		tmp = t_2
	elif y <= -6e-236:
		tmp = t_3
	elif y <= -5e-242:
		tmp = t_2
	elif y <= -4.2e-277:
		tmp = x * (t / z)
	elif y <= 5.4e-287:
		tmp = t_3
	elif y <= 4.8e-142:
		tmp = t_1
	elif y <= 5e-142:
		tmp = t
	elif y <= 4.5e-68:
		tmp = t_3
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t)
	t_1 = Float64(t * Float64(Float64(x - y) / z))
	t_2 = Float64(t * Float64(1.0 - Float64(x / y)))
	t_3 = Float64(t * Float64(x / Float64(z - y)))
	tmp = 0.0
	if (y <= -7.8e-50)
		tmp = t_2;
	elseif (y <= -2.15e-97)
		tmp = t_1;
	elseif (y <= -1.3e-120)
		tmp = t_2;
	elseif (y <= -6e-236)
		tmp = t_3;
	elseif (y <= -5e-242)
		tmp = t_2;
	elseif (y <= -4.2e-277)
		tmp = Float64(x * Float64(t / z));
	elseif (y <= 5.4e-287)
		tmp = t_3;
	elseif (y <= 4.8e-142)
		tmp = t_1;
	elseif (y <= 5e-142)
		tmp = t;
	elseif (y <= 4.5e-68)
		tmp = t_3;
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = t * ((x - y) / z);
	t_2 = t * (1.0 - (x / y));
	t_3 = t * (x / (z - y));
	tmp = 0.0;
	if (y <= -7.8e-50)
		tmp = t_2;
	elseif (y <= -2.15e-97)
		tmp = t_1;
	elseif (y <= -1.3e-120)
		tmp = t_2;
	elseif (y <= -6e-236)
		tmp = t_3;
	elseif (y <= -5e-242)
		tmp = t_2;
	elseif (y <= -4.2e-277)
		tmp = x * (t / z);
	elseif (y <= 5.4e-287)
		tmp = t_3;
	elseif (y <= 4.8e-142)
		tmp = t_1;
	elseif (y <= 5e-142)
		tmp = t;
	elseif (y <= 4.5e-68)
		tmp = t_3;
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(t * N[(N[(x - y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t * N[(1.0 - N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(t * N[(x / N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -7.8e-50], t$95$2, If[LessEqual[y, -2.15e-97], t$95$1, If[LessEqual[y, -1.3e-120], t$95$2, If[LessEqual[y, -6e-236], t$95$3, If[LessEqual[y, -5e-242], t$95$2, If[LessEqual[y, -4.2e-277], N[(x * N[(t / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 5.4e-287], t$95$3, If[LessEqual[y, 4.8e-142], t$95$1, If[LessEqual[y, 5e-142], t, If[LessEqual[y, 4.5e-68], t$95$3, t$95$2]]]]]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := t \cdot \frac{x - y}{z}\\
t_2 := t \cdot \left(1 - \frac{x}{y}\right)\\
t_3 := t \cdot \frac{x}{z - y}\\
\mathbf{if}\;y \leq -7.8 \cdot 10^{-50}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y \leq -2.15 \cdot 10^{-97}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq -1.3 \cdot 10^{-120}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y \leq -6 \cdot 10^{-236}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;y \leq -5 \cdot 10^{-242}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y \leq -4.2 \cdot 10^{-277}:\\
\;\;\;\;x \cdot \frac{t}{z}\\

\mathbf{elif}\;y \leq 5.4 \cdot 10^{-287}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;y \leq 4.8 \cdot 10^{-142}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq 5 \cdot 10^{-142}:\\
\;\;\;\;t\\

\mathbf{elif}\;y \leq 4.5 \cdot 10^{-68}:\\
\;\;\;\;t\_3\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if y < -7.80000000000000042e-50 or -2.15e-97 < y < -1.3000000000000001e-120 or -6.00000000000000027e-236 < y < -4.9999999999999998e-242 or 4.49999999999999999e-68 < y

    1. Initial program 98.6%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/80.2%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified77.7%

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

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

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

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

        \[\leadsto t + -1 \cdot \color{blue}{\frac{t \cdot x - t \cdot z}{y}} \]
      4. mul-1-neg75.0%

        \[\leadsto t + \color{blue}{\left(-\frac{t \cdot x - t \cdot z}{y}\right)} \]
      5. unsub-neg75.0%

        \[\leadsto \color{blue}{t - \frac{t \cdot x - t \cdot z}{y}} \]
      6. distribute-lft-out--75.7%

        \[\leadsto t - \frac{\color{blue}{t \cdot \left(x - z\right)}}{y} \]
      7. associate-/l*81.3%

        \[\leadsto t - \color{blue}{t \cdot \frac{x - z}{y}} \]
    7. Simplified81.3%

      \[\leadsto \color{blue}{t - t \cdot \frac{x - z}{y}} \]
    8. Taylor expanded in x around inf 81.0%

      \[\leadsto t - t \cdot \color{blue}{\frac{x}{y}} \]
    9. Taylor expanded in t around 0 81.0%

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

    if -7.80000000000000042e-50 < y < -2.15e-97 or 5.4000000000000002e-287 < y < 4.79999999999999976e-142

    1. Initial program 99.9%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 94.1%

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

    if -1.3000000000000001e-120 < y < -6.00000000000000027e-236 or -4.1999999999999999e-277 < y < 5.4000000000000002e-287 or 5.0000000000000002e-142 < y < 4.49999999999999999e-68

    1. Initial program 96.4%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 77.0%

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

    if -4.9999999999999998e-242 < y < -4.1999999999999999e-277

    1. Initial program 81.1%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/81.0%

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

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

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

      \[\leadsto \color{blue}{\frac{t \cdot x}{z}} \]
    6. Step-by-step derivation
      1. *-commutative81.0%

        \[\leadsto \frac{\color{blue}{x \cdot t}}{z} \]
      2. associate-/l*100.0%

        \[\leadsto \color{blue}{x \cdot \frac{t}{z}} \]
    7. Simplified100.0%

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

    if 4.79999999999999976e-142 < y < 5.0000000000000002e-142

    1. Initial program 100.0%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/100.0%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -7.8 \cdot 10^{-50}:\\ \;\;\;\;t \cdot \left(1 - \frac{x}{y}\right)\\ \mathbf{elif}\;y \leq -2.15 \cdot 10^{-97}:\\ \;\;\;\;t \cdot \frac{x - y}{z}\\ \mathbf{elif}\;y \leq -1.3 \cdot 10^{-120}:\\ \;\;\;\;t \cdot \left(1 - \frac{x}{y}\right)\\ \mathbf{elif}\;y \leq -6 \cdot 10^{-236}:\\ \;\;\;\;t \cdot \frac{x}{z - y}\\ \mathbf{elif}\;y \leq -5 \cdot 10^{-242}:\\ \;\;\;\;t \cdot \left(1 - \frac{x}{y}\right)\\ \mathbf{elif}\;y \leq -4.2 \cdot 10^{-277}:\\ \;\;\;\;x \cdot \frac{t}{z}\\ \mathbf{elif}\;y \leq 5.4 \cdot 10^{-287}:\\ \;\;\;\;t \cdot \frac{x}{z - y}\\ \mathbf{elif}\;y \leq 4.8 \cdot 10^{-142}:\\ \;\;\;\;t \cdot \frac{x - y}{z}\\ \mathbf{elif}\;y \leq 5 \cdot 10^{-142}:\\ \;\;\;\;t\\ \mathbf{elif}\;y \leq 4.5 \cdot 10^{-68}:\\ \;\;\;\;t \cdot \frac{x}{z - y}\\ \mathbf{else}:\\ \;\;\;\;t \cdot \left(1 - \frac{x}{y}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 73.8% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t \cdot \frac{x - y}{z}\\ t_2 := t \cdot \frac{x}{z - y}\\ \mathbf{if}\;y \leq -1.62 \cdot 10^{-50}:\\ \;\;\;\;t \cdot \left(1 - \frac{x}{y}\right)\\ \mathbf{elif}\;y \leq -2.15 \cdot 10^{-98}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq -1.3 \cdot 10^{-120}:\\ \;\;\;\;t - \frac{x}{\frac{y}{t}}\\ \mathbf{elif}\;y \leq -9.5 \cdot 10^{-141}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y \leq -1.55 \cdot 10^{-142}:\\ \;\;\;\;t\\ \mathbf{elif}\;y \leq 9.5 \cdot 10^{-289}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y \leq 9 \cdot 10^{-232}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 4.8 \cdot 10^{-73}:\\ \;\;\;\;t\_2\\ \mathbf{else}:\\ \;\;\;\;t - t \cdot \frac{x}{y}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (* t (/ (- x y) z))) (t_2 (* t (/ x (- z y)))))
   (if (<= y -1.62e-50)
     (* t (- 1.0 (/ x y)))
     (if (<= y -2.15e-98)
       t_1
       (if (<= y -1.3e-120)
         (- t (/ x (/ y t)))
         (if (<= y -9.5e-141)
           t_2
           (if (<= y -1.55e-142)
             t
             (if (<= y 9.5e-289)
               t_2
               (if (<= y 9e-232)
                 t_1
                 (if (<= y 4.8e-73) t_2 (- t (* t (/ x y)))))))))))))
double code(double x, double y, double z, double t) {
	double t_1 = t * ((x - y) / z);
	double t_2 = t * (x / (z - y));
	double tmp;
	if (y <= -1.62e-50) {
		tmp = t * (1.0 - (x / y));
	} else if (y <= -2.15e-98) {
		tmp = t_1;
	} else if (y <= -1.3e-120) {
		tmp = t - (x / (y / t));
	} else if (y <= -9.5e-141) {
		tmp = t_2;
	} else if (y <= -1.55e-142) {
		tmp = t;
	} else if (y <= 9.5e-289) {
		tmp = t_2;
	} else if (y <= 9e-232) {
		tmp = t_1;
	} else if (y <= 4.8e-73) {
		tmp = t_2;
	} else {
		tmp = t - (t * (x / y));
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = t * ((x - y) / z)
    t_2 = t * (x / (z - y))
    if (y <= (-1.62d-50)) then
        tmp = t * (1.0d0 - (x / y))
    else if (y <= (-2.15d-98)) then
        tmp = t_1
    else if (y <= (-1.3d-120)) then
        tmp = t - (x / (y / t))
    else if (y <= (-9.5d-141)) then
        tmp = t_2
    else if (y <= (-1.55d-142)) then
        tmp = t
    else if (y <= 9.5d-289) then
        tmp = t_2
    else if (y <= 9d-232) then
        tmp = t_1
    else if (y <= 4.8d-73) then
        tmp = t_2
    else
        tmp = t - (t * (x / y))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double t_1 = t * ((x - y) / z);
	double t_2 = t * (x / (z - y));
	double tmp;
	if (y <= -1.62e-50) {
		tmp = t * (1.0 - (x / y));
	} else if (y <= -2.15e-98) {
		tmp = t_1;
	} else if (y <= -1.3e-120) {
		tmp = t - (x / (y / t));
	} else if (y <= -9.5e-141) {
		tmp = t_2;
	} else if (y <= -1.55e-142) {
		tmp = t;
	} else if (y <= 9.5e-289) {
		tmp = t_2;
	} else if (y <= 9e-232) {
		tmp = t_1;
	} else if (y <= 4.8e-73) {
		tmp = t_2;
	} else {
		tmp = t - (t * (x / y));
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = t * ((x - y) / z)
	t_2 = t * (x / (z - y))
	tmp = 0
	if y <= -1.62e-50:
		tmp = t * (1.0 - (x / y))
	elif y <= -2.15e-98:
		tmp = t_1
	elif y <= -1.3e-120:
		tmp = t - (x / (y / t))
	elif y <= -9.5e-141:
		tmp = t_2
	elif y <= -1.55e-142:
		tmp = t
	elif y <= 9.5e-289:
		tmp = t_2
	elif y <= 9e-232:
		tmp = t_1
	elif y <= 4.8e-73:
		tmp = t_2
	else:
		tmp = t - (t * (x / y))
	return tmp
function code(x, y, z, t)
	t_1 = Float64(t * Float64(Float64(x - y) / z))
	t_2 = Float64(t * Float64(x / Float64(z - y)))
	tmp = 0.0
	if (y <= -1.62e-50)
		tmp = Float64(t * Float64(1.0 - Float64(x / y)));
	elseif (y <= -2.15e-98)
		tmp = t_1;
	elseif (y <= -1.3e-120)
		tmp = Float64(t - Float64(x / Float64(y / t)));
	elseif (y <= -9.5e-141)
		tmp = t_2;
	elseif (y <= -1.55e-142)
		tmp = t;
	elseif (y <= 9.5e-289)
		tmp = t_2;
	elseif (y <= 9e-232)
		tmp = t_1;
	elseif (y <= 4.8e-73)
		tmp = t_2;
	else
		tmp = Float64(t - Float64(t * Float64(x / y)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = t * ((x - y) / z);
	t_2 = t * (x / (z - y));
	tmp = 0.0;
	if (y <= -1.62e-50)
		tmp = t * (1.0 - (x / y));
	elseif (y <= -2.15e-98)
		tmp = t_1;
	elseif (y <= -1.3e-120)
		tmp = t - (x / (y / t));
	elseif (y <= -9.5e-141)
		tmp = t_2;
	elseif (y <= -1.55e-142)
		tmp = t;
	elseif (y <= 9.5e-289)
		tmp = t_2;
	elseif (y <= 9e-232)
		tmp = t_1;
	elseif (y <= 4.8e-73)
		tmp = t_2;
	else
		tmp = t - (t * (x / y));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(t * N[(N[(x - y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t * N[(x / N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.62e-50], N[(t * N[(1.0 - N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -2.15e-98], t$95$1, If[LessEqual[y, -1.3e-120], N[(t - N[(x / N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -9.5e-141], t$95$2, If[LessEqual[y, -1.55e-142], t, If[LessEqual[y, 9.5e-289], t$95$2, If[LessEqual[y, 9e-232], t$95$1, If[LessEqual[y, 4.8e-73], t$95$2, N[(t - N[(t * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;y \leq -2.15 \cdot 10^{-98}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq -1.3 \cdot 10^{-120}:\\
\;\;\;\;t - \frac{x}{\frac{y}{t}}\\

\mathbf{elif}\;y \leq -9.5 \cdot 10^{-141}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y \leq -1.55 \cdot 10^{-142}:\\
\;\;\;\;t\\

\mathbf{elif}\;y \leq 9.5 \cdot 10^{-289}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y \leq 9 \cdot 10^{-232}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq 4.8 \cdot 10^{-73}:\\
\;\;\;\;t\_2\\

\mathbf{else}:\\
\;\;\;\;t - t \cdot \frac{x}{y}\\


\end{array}
\end{array}
Derivation
  1. Split input into 6 regimes
  2. if y < -1.6200000000000001e-50

    1. Initial program 98.8%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/78.6%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified79.2%

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

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

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

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

        \[\leadsto t + -1 \cdot \color{blue}{\frac{t \cdot x - t \cdot z}{y}} \]
      4. mul-1-neg71.6%

        \[\leadsto t + \color{blue}{\left(-\frac{t \cdot x - t \cdot z}{y}\right)} \]
      5. unsub-neg71.6%

        \[\leadsto \color{blue}{t - \frac{t \cdot x - t \cdot z}{y}} \]
      6. distribute-lft-out--71.7%

        \[\leadsto t - \frac{\color{blue}{t \cdot \left(x - z\right)}}{y} \]
      7. associate-/l*75.9%

        \[\leadsto t - \color{blue}{t \cdot \frac{x - z}{y}} \]
    7. Simplified75.9%

      \[\leadsto \color{blue}{t - t \cdot \frac{x - z}{y}} \]
    8. Taylor expanded in x around inf 75.7%

      \[\leadsto t - t \cdot \color{blue}{\frac{x}{y}} \]
    9. Taylor expanded in t around 0 75.7%

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

    if -1.6200000000000001e-50 < y < -2.14999999999999994e-98 or 9.4999999999999995e-289 < y < 8.99999999999999933e-232

    1. Initial program 99.9%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 99.9%

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

    if -2.14999999999999994e-98 < y < -1.3000000000000001e-120

    1. Initial program 68.0%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/99.5%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified99.0%

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

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

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

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

        \[\leadsto t + -1 \cdot \color{blue}{\frac{t \cdot x - t \cdot z}{y}} \]
      4. mul-1-neg100.0%

        \[\leadsto t + \color{blue}{\left(-\frac{t \cdot x - t \cdot z}{y}\right)} \]
      5. unsub-neg100.0%

        \[\leadsto \color{blue}{t - \frac{t \cdot x - t \cdot z}{y}} \]
      6. distribute-lft-out--100.0%

        \[\leadsto t - \frac{\color{blue}{t \cdot \left(x - z\right)}}{y} \]
      7. associate-/l*68.0%

        \[\leadsto t - \color{blue}{t \cdot \frac{x - z}{y}} \]
    7. Simplified68.0%

      \[\leadsto \color{blue}{t - t \cdot \frac{x - z}{y}} \]
    8. Taylor expanded in x around inf 100.0%

      \[\leadsto t - \color{blue}{\frac{t \cdot x}{y}} \]
    9. Step-by-step derivation
      1. associate-/l*68.0%

        \[\leadsto t - \color{blue}{t \cdot \frac{x}{y}} \]
    10. Applied egg-rr68.0%

      \[\leadsto t - \color{blue}{t \cdot \frac{x}{y}} \]
    11. Step-by-step derivation
      1. *-commutative68.0%

        \[\leadsto t - \color{blue}{\frac{x}{y} \cdot t} \]
      2. associate-/r/100.0%

        \[\leadsto t - \color{blue}{\frac{x}{\frac{y}{t}}} \]
    12. Simplified100.0%

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

    if -1.3000000000000001e-120 < y < -9.49999999999999996e-141 or -1.55e-142 < y < 9.4999999999999995e-289 or 8.99999999999999933e-232 < y < 4.80000000000000011e-73

    1. Initial program 96.0%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 77.9%

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

    if -9.49999999999999996e-141 < y < -1.55e-142

    1. Initial program 100.0%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/53.8%

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

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

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

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

    if 4.80000000000000011e-73 < y

    1. Initial program 99.8%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/80.3%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified74.8%

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

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

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

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

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

        \[\leadsto t + \color{blue}{\left(-\frac{t \cdot x - t \cdot z}{y}\right)} \]
      5. unsub-neg78.2%

        \[\leadsto \color{blue}{t - \frac{t \cdot x - t \cdot z}{y}} \]
      6. distribute-lft-out--79.8%

        \[\leadsto t - \frac{\color{blue}{t \cdot \left(x - z\right)}}{y} \]
      7. associate-/l*89.4%

        \[\leadsto t - \color{blue}{t \cdot \frac{x - z}{y}} \]
    7. Simplified89.4%

      \[\leadsto \color{blue}{t - t \cdot \frac{x - z}{y}} \]
    8. Taylor expanded in x around inf 88.9%

      \[\leadsto t - t \cdot \color{blue}{\frac{x}{y}} \]
  3. Recombined 6 regimes into one program.
  4. Final simplification82.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -1.62 \cdot 10^{-50}:\\ \;\;\;\;t \cdot \left(1 - \frac{x}{y}\right)\\ \mathbf{elif}\;y \leq -2.15 \cdot 10^{-98}:\\ \;\;\;\;t \cdot \frac{x - y}{z}\\ \mathbf{elif}\;y \leq -1.3 \cdot 10^{-120}:\\ \;\;\;\;t - \frac{x}{\frac{y}{t}}\\ \mathbf{elif}\;y \leq -9.5 \cdot 10^{-141}:\\ \;\;\;\;t \cdot \frac{x}{z - y}\\ \mathbf{elif}\;y \leq -1.55 \cdot 10^{-142}:\\ \;\;\;\;t\\ \mathbf{elif}\;y \leq 9.5 \cdot 10^{-289}:\\ \;\;\;\;t \cdot \frac{x}{z - y}\\ \mathbf{elif}\;y \leq 9 \cdot 10^{-232}:\\ \;\;\;\;t \cdot \frac{x - y}{z}\\ \mathbf{elif}\;y \leq 4.8 \cdot 10^{-73}:\\ \;\;\;\;t \cdot \frac{x}{z - y}\\ \mathbf{else}:\\ \;\;\;\;t - t \cdot \frac{x}{y}\\ \end{array} \]
  5. Add Preprocessing

Alternative 5: 69.7% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{t}{\frac{z}{x}}\\ t_2 := t \cdot \left(1 - \frac{x}{y}\right)\\ \mathbf{if}\;y \leq -4.1 \cdot 10^{-50}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y \leq -9.5 \cdot 10^{-141}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq -8 \cdot 10^{-168}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y \leq -9.2 \cdot 10^{-215}:\\ \;\;\;\;\frac{t \cdot x}{z}\\ \mathbf{elif}\;y \leq 2.4 \cdot 10^{-68}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 2.65 \cdot 10^{-5} \lor \neg \left(y \leq 370000000000\right):\\ \;\;\;\;t\_2\\ \mathbf{else}:\\ \;\;\;\;t \cdot \frac{x}{z}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (/ t (/ z x))) (t_2 (* t (- 1.0 (/ x y)))))
   (if (<= y -4.1e-50)
     t_2
     (if (<= y -9.5e-141)
       t_1
       (if (<= y -8e-168)
         t_2
         (if (<= y -9.2e-215)
           (/ (* t x) z)
           (if (<= y 2.4e-68)
             t_1
             (if (or (<= y 2.65e-5) (not (<= y 370000000000.0)))
               t_2
               (* t (/ x z))))))))))
double code(double x, double y, double z, double t) {
	double t_1 = t / (z / x);
	double t_2 = t * (1.0 - (x / y));
	double tmp;
	if (y <= -4.1e-50) {
		tmp = t_2;
	} else if (y <= -9.5e-141) {
		tmp = t_1;
	} else if (y <= -8e-168) {
		tmp = t_2;
	} else if (y <= -9.2e-215) {
		tmp = (t * x) / z;
	} else if (y <= 2.4e-68) {
		tmp = t_1;
	} else if ((y <= 2.65e-5) || !(y <= 370000000000.0)) {
		tmp = t_2;
	} else {
		tmp = t * (x / z);
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = t / (z / x)
    t_2 = t * (1.0d0 - (x / y))
    if (y <= (-4.1d-50)) then
        tmp = t_2
    else if (y <= (-9.5d-141)) then
        tmp = t_1
    else if (y <= (-8d-168)) then
        tmp = t_2
    else if (y <= (-9.2d-215)) then
        tmp = (t * x) / z
    else if (y <= 2.4d-68) then
        tmp = t_1
    else if ((y <= 2.65d-5) .or. (.not. (y <= 370000000000.0d0))) then
        tmp = t_2
    else
        tmp = t * (x / z)
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double t_1 = t / (z / x);
	double t_2 = t * (1.0 - (x / y));
	double tmp;
	if (y <= -4.1e-50) {
		tmp = t_2;
	} else if (y <= -9.5e-141) {
		tmp = t_1;
	} else if (y <= -8e-168) {
		tmp = t_2;
	} else if (y <= -9.2e-215) {
		tmp = (t * x) / z;
	} else if (y <= 2.4e-68) {
		tmp = t_1;
	} else if ((y <= 2.65e-5) || !(y <= 370000000000.0)) {
		tmp = t_2;
	} else {
		tmp = t * (x / z);
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = t / (z / x)
	t_2 = t * (1.0 - (x / y))
	tmp = 0
	if y <= -4.1e-50:
		tmp = t_2
	elif y <= -9.5e-141:
		tmp = t_1
	elif y <= -8e-168:
		tmp = t_2
	elif y <= -9.2e-215:
		tmp = (t * x) / z
	elif y <= 2.4e-68:
		tmp = t_1
	elif (y <= 2.65e-5) or not (y <= 370000000000.0):
		tmp = t_2
	else:
		tmp = t * (x / z)
	return tmp
function code(x, y, z, t)
	t_1 = Float64(t / Float64(z / x))
	t_2 = Float64(t * Float64(1.0 - Float64(x / y)))
	tmp = 0.0
	if (y <= -4.1e-50)
		tmp = t_2;
	elseif (y <= -9.5e-141)
		tmp = t_1;
	elseif (y <= -8e-168)
		tmp = t_2;
	elseif (y <= -9.2e-215)
		tmp = Float64(Float64(t * x) / z);
	elseif (y <= 2.4e-68)
		tmp = t_1;
	elseif ((y <= 2.65e-5) || !(y <= 370000000000.0))
		tmp = t_2;
	else
		tmp = Float64(t * Float64(x / z));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = t / (z / x);
	t_2 = t * (1.0 - (x / y));
	tmp = 0.0;
	if (y <= -4.1e-50)
		tmp = t_2;
	elseif (y <= -9.5e-141)
		tmp = t_1;
	elseif (y <= -8e-168)
		tmp = t_2;
	elseif (y <= -9.2e-215)
		tmp = (t * x) / z;
	elseif (y <= 2.4e-68)
		tmp = t_1;
	elseif ((y <= 2.65e-5) || ~((y <= 370000000000.0)))
		tmp = t_2;
	else
		tmp = t * (x / z);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(t / N[(z / x), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t * N[(1.0 - N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -4.1e-50], t$95$2, If[LessEqual[y, -9.5e-141], t$95$1, If[LessEqual[y, -8e-168], t$95$2, If[LessEqual[y, -9.2e-215], N[(N[(t * x), $MachinePrecision] / z), $MachinePrecision], If[LessEqual[y, 2.4e-68], t$95$1, If[Or[LessEqual[y, 2.65e-5], N[Not[LessEqual[y, 370000000000.0]], $MachinePrecision]], t$95$2, N[(t * N[(x / z), $MachinePrecision]), $MachinePrecision]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{t}{\frac{z}{x}}\\
t_2 := t \cdot \left(1 - \frac{x}{y}\right)\\
\mathbf{if}\;y \leq -4.1 \cdot 10^{-50}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y \leq -9.5 \cdot 10^{-141}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq -8 \cdot 10^{-168}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y \leq -9.2 \cdot 10^{-215}:\\
\;\;\;\;\frac{t \cdot x}{z}\\

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

\mathbf{elif}\;y \leq 2.65 \cdot 10^{-5} \lor \neg \left(y \leq 370000000000\right):\\
\;\;\;\;t\_2\\

\mathbf{else}:\\
\;\;\;\;t \cdot \frac{x}{z}\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if y < -4.09999999999999985e-50 or -9.49999999999999996e-141 < y < -8.0000000000000004e-168 or 2.39999999999999991e-68 < y < 2.65e-5 or 3.7e11 < y

    1. Initial program 99.2%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/79.2%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified77.2%

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

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

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

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

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

        \[\leadsto t + \color{blue}{\left(-\frac{t \cdot x - t \cdot z}{y}\right)} \]
      5. unsub-neg76.2%

        \[\leadsto \color{blue}{t - \frac{t \cdot x - t \cdot z}{y}} \]
      6. distribute-lft-out--76.2%

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

        \[\leadsto t - \color{blue}{t \cdot \frac{x - z}{y}} \]
    7. Simplified82.8%

      \[\leadsto \color{blue}{t - t \cdot \frac{x - z}{y}} \]
    8. Taylor expanded in x around inf 82.5%

      \[\leadsto t - t \cdot \color{blue}{\frac{x}{y}} \]
    9. Taylor expanded in t around 0 82.5%

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

    if -4.09999999999999985e-50 < y < -9.49999999999999996e-141 or -9.1999999999999996e-215 < y < 2.39999999999999991e-68

    1. Initial program 96.1%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/88.8%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified89.7%

      \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. associate-*r/88.8%

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

        \[\leadsto \color{blue}{\frac{x - y}{z - y} \cdot t} \]
      3. *-commutative96.1%

        \[\leadsto \color{blue}{t \cdot \frac{x - y}{z - y}} \]
      4. clear-num96.1%

        \[\leadsto t \cdot \color{blue}{\frac{1}{\frac{z - y}{x - y}}} \]
      5. un-div-inv96.2%

        \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
    6. Applied egg-rr96.2%

      \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
    7. Taylor expanded in y around 0 72.6%

      \[\leadsto \frac{t}{\color{blue}{\frac{z}{x}}} \]

    if -8.0000000000000004e-168 < y < -9.1999999999999996e-215

    1. Initial program 94.0%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/93.6%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified93.8%

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

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

    if 2.65e-5 < y < 3.7e11

    1. Initial program 99.8%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0 58.7%

      \[\leadsto \color{blue}{\frac{x}{z}} \cdot t \]
  3. Recombined 4 regimes into one program.
  4. Final simplification78.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -4.1 \cdot 10^{-50}:\\ \;\;\;\;t \cdot \left(1 - \frac{x}{y}\right)\\ \mathbf{elif}\;y \leq -9.5 \cdot 10^{-141}:\\ \;\;\;\;\frac{t}{\frac{z}{x}}\\ \mathbf{elif}\;y \leq -8 \cdot 10^{-168}:\\ \;\;\;\;t \cdot \left(1 - \frac{x}{y}\right)\\ \mathbf{elif}\;y \leq -9.2 \cdot 10^{-215}:\\ \;\;\;\;\frac{t \cdot x}{z}\\ \mathbf{elif}\;y \leq 2.4 \cdot 10^{-68}:\\ \;\;\;\;\frac{t}{\frac{z}{x}}\\ \mathbf{elif}\;y \leq 2.65 \cdot 10^{-5} \lor \neg \left(y \leq 370000000000\right):\\ \;\;\;\;t \cdot \left(1 - \frac{x}{y}\right)\\ \mathbf{else}:\\ \;\;\;\;t \cdot \frac{x}{z}\\ \end{array} \]
  5. Add Preprocessing

Alternative 6: 71.2% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(x - y\right) \cdot \frac{t}{z}\\ t_2 := t \cdot \left(1 - \frac{x}{y}\right)\\ \mathbf{if}\;y \leq -2 \cdot 10^{-53}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y \leq -2.4 \cdot 10^{-98}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq -1.3 \cdot 10^{-120}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y \leq -2.4 \cdot 10^{-308}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 1.1 \cdot 10^{-163}:\\ \;\;\;\;\frac{t}{\frac{z}{x}}\\ \mathbf{elif}\;y \leq 9.5 \cdot 10^{-123}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (* (- x y) (/ t z))) (t_2 (* t (- 1.0 (/ x y)))))
   (if (<= y -2e-53)
     t_2
     (if (<= y -2.4e-98)
       t_1
       (if (<= y -1.3e-120)
         t_2
         (if (<= y -2.4e-308)
           t_1
           (if (<= y 1.1e-163)
             (/ t (/ z x))
             (if (<= y 9.5e-123) t_1 t_2))))))))
double code(double x, double y, double z, double t) {
	double t_1 = (x - y) * (t / z);
	double t_2 = t * (1.0 - (x / y));
	double tmp;
	if (y <= -2e-53) {
		tmp = t_2;
	} else if (y <= -2.4e-98) {
		tmp = t_1;
	} else if (y <= -1.3e-120) {
		tmp = t_2;
	} else if (y <= -2.4e-308) {
		tmp = t_1;
	} else if (y <= 1.1e-163) {
		tmp = t / (z / x);
	} else if (y <= 9.5e-123) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = (x - y) * (t / z)
    t_2 = t * (1.0d0 - (x / y))
    if (y <= (-2d-53)) then
        tmp = t_2
    else if (y <= (-2.4d-98)) then
        tmp = t_1
    else if (y <= (-1.3d-120)) then
        tmp = t_2
    else if (y <= (-2.4d-308)) then
        tmp = t_1
    else if (y <= 1.1d-163) then
        tmp = t / (z / x)
    else if (y <= 9.5d-123) 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 t_1 = (x - y) * (t / z);
	double t_2 = t * (1.0 - (x / y));
	double tmp;
	if (y <= -2e-53) {
		tmp = t_2;
	} else if (y <= -2.4e-98) {
		tmp = t_1;
	} else if (y <= -1.3e-120) {
		tmp = t_2;
	} else if (y <= -2.4e-308) {
		tmp = t_1;
	} else if (y <= 1.1e-163) {
		tmp = t / (z / x);
	} else if (y <= 9.5e-123) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = (x - y) * (t / z)
	t_2 = t * (1.0 - (x / y))
	tmp = 0
	if y <= -2e-53:
		tmp = t_2
	elif y <= -2.4e-98:
		tmp = t_1
	elif y <= -1.3e-120:
		tmp = t_2
	elif y <= -2.4e-308:
		tmp = t_1
	elif y <= 1.1e-163:
		tmp = t / (z / x)
	elif y <= 9.5e-123:
		tmp = t_1
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t)
	t_1 = Float64(Float64(x - y) * Float64(t / z))
	t_2 = Float64(t * Float64(1.0 - Float64(x / y)))
	tmp = 0.0
	if (y <= -2e-53)
		tmp = t_2;
	elseif (y <= -2.4e-98)
		tmp = t_1;
	elseif (y <= -1.3e-120)
		tmp = t_2;
	elseif (y <= -2.4e-308)
		tmp = t_1;
	elseif (y <= 1.1e-163)
		tmp = Float64(t / Float64(z / x));
	elseif (y <= 9.5e-123)
		tmp = t_1;
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = (x - y) * (t / z);
	t_2 = t * (1.0 - (x / y));
	tmp = 0.0;
	if (y <= -2e-53)
		tmp = t_2;
	elseif (y <= -2.4e-98)
		tmp = t_1;
	elseif (y <= -1.3e-120)
		tmp = t_2;
	elseif (y <= -2.4e-308)
		tmp = t_1;
	elseif (y <= 1.1e-163)
		tmp = t / (z / x);
	elseif (y <= 9.5e-123)
		tmp = t_1;
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x - y), $MachinePrecision] * N[(t / z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t * N[(1.0 - N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -2e-53], t$95$2, If[LessEqual[y, -2.4e-98], t$95$1, If[LessEqual[y, -1.3e-120], t$95$2, If[LessEqual[y, -2.4e-308], t$95$1, If[LessEqual[y, 1.1e-163], N[(t / N[(z / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 9.5e-123], t$95$1, t$95$2]]]]]]]]
\begin{array}{l}

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

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

\mathbf{elif}\;y \leq -1.3 \cdot 10^{-120}:\\
\;\;\;\;t\_2\\

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

\mathbf{elif}\;y \leq 1.1 \cdot 10^{-163}:\\
\;\;\;\;\frac{t}{\frac{z}{x}}\\

\mathbf{elif}\;y \leq 9.5 \cdot 10^{-123}:\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -2.00000000000000006e-53 or -2.40000000000000005e-98 < y < -1.3000000000000001e-120 or 9.5000000000000002e-123 < y

    1. Initial program 98.7%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/80.1%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified78.2%

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

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

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

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

        \[\leadsto t + -1 \cdot \color{blue}{\frac{t \cdot x - t \cdot z}{y}} \]
      4. mul-1-neg72.9%

        \[\leadsto t + \color{blue}{\left(-\frac{t \cdot x - t \cdot z}{y}\right)} \]
      5. unsub-neg72.9%

        \[\leadsto \color{blue}{t - \frac{t \cdot x - t \cdot z}{y}} \]
      6. distribute-lft-out--73.6%

        \[\leadsto t - \frac{\color{blue}{t \cdot \left(x - z\right)}}{y} \]
      7. associate-/l*79.2%

        \[\leadsto t - \color{blue}{t \cdot \frac{x - z}{y}} \]
    7. Simplified79.2%

      \[\leadsto \color{blue}{t - t \cdot \frac{x - z}{y}} \]
    8. Taylor expanded in x around inf 78.8%

      \[\leadsto t - t \cdot \color{blue}{\frac{x}{y}} \]
    9. Taylor expanded in t around 0 78.8%

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

    if -2.00000000000000006e-53 < y < -2.40000000000000005e-98 or -1.3000000000000001e-120 < y < -2.40000000000000008e-308 or 1.10000000000000005e-163 < y < 9.5000000000000002e-123

    1. Initial program 95.5%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/88.2%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified95.4%

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

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

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z}} \]
    7. Simplified75.2%

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

    if -2.40000000000000008e-308 < y < 1.10000000000000005e-163

    1. Initial program 99.9%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/91.5%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified74.5%

      \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. associate-*r/91.5%

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

        \[\leadsto \color{blue}{\frac{x - y}{z - y} \cdot t} \]
      3. *-commutative99.9%

        \[\leadsto \color{blue}{t \cdot \frac{x - y}{z - y}} \]
      4. clear-num99.7%

        \[\leadsto t \cdot \color{blue}{\frac{1}{\frac{z - y}{x - y}}} \]
      5. un-div-inv99.9%

        \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
    6. Applied egg-rr99.9%

      \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
    7. Taylor expanded in y around 0 90.3%

      \[\leadsto \frac{t}{\color{blue}{\frac{z}{x}}} \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 7: 87.6% accurate, 0.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(x - y\right) \cdot \frac{t}{z - y}\\ \mathbf{if}\;y \leq -1.9 \cdot 10^{+184}:\\ \;\;\;\;t \cdot \left(1 - \frac{x}{y}\right)\\ \mathbf{elif}\;y \leq 9 \cdot 10^{-307}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 4.9 \cdot 10^{-234}:\\ \;\;\;\;\frac{t}{\frac{z}{x - y}}\\ \mathbf{elif}\;y \leq 1.05 \cdot 10^{+17}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t - t \cdot \frac{x}{y}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (* (- x y) (/ t (- z y)))))
   (if (<= y -1.9e+184)
     (* t (- 1.0 (/ x y)))
     (if (<= y 9e-307)
       t_1
       (if (<= y 4.9e-234)
         (/ t (/ z (- x y)))
         (if (<= y 1.05e+17) t_1 (- t (* t (/ x y)))))))))
double code(double x, double y, double z, double t) {
	double t_1 = (x - y) * (t / (z - y));
	double tmp;
	if (y <= -1.9e+184) {
		tmp = t * (1.0 - (x / y));
	} else if (y <= 9e-307) {
		tmp = t_1;
	} else if (y <= 4.9e-234) {
		tmp = t / (z / (x - y));
	} else if (y <= 1.05e+17) {
		tmp = t_1;
	} else {
		tmp = t - (t * (x / y));
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: t_1
    real(8) :: tmp
    t_1 = (x - y) * (t / (z - y))
    if (y <= (-1.9d+184)) then
        tmp = t * (1.0d0 - (x / y))
    else if (y <= 9d-307) then
        tmp = t_1
    else if (y <= 4.9d-234) then
        tmp = t / (z / (x - y))
    else if (y <= 1.05d+17) then
        tmp = t_1
    else
        tmp = t - (t * (x / y))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double t_1 = (x - y) * (t / (z - y));
	double tmp;
	if (y <= -1.9e+184) {
		tmp = t * (1.0 - (x / y));
	} else if (y <= 9e-307) {
		tmp = t_1;
	} else if (y <= 4.9e-234) {
		tmp = t / (z / (x - y));
	} else if (y <= 1.05e+17) {
		tmp = t_1;
	} else {
		tmp = t - (t * (x / y));
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = (x - y) * (t / (z - y))
	tmp = 0
	if y <= -1.9e+184:
		tmp = t * (1.0 - (x / y))
	elif y <= 9e-307:
		tmp = t_1
	elif y <= 4.9e-234:
		tmp = t / (z / (x - y))
	elif y <= 1.05e+17:
		tmp = t_1
	else:
		tmp = t - (t * (x / y))
	return tmp
function code(x, y, z, t)
	t_1 = Float64(Float64(x - y) * Float64(t / Float64(z - y)))
	tmp = 0.0
	if (y <= -1.9e+184)
		tmp = Float64(t * Float64(1.0 - Float64(x / y)));
	elseif (y <= 9e-307)
		tmp = t_1;
	elseif (y <= 4.9e-234)
		tmp = Float64(t / Float64(z / Float64(x - y)));
	elseif (y <= 1.05e+17)
		tmp = t_1;
	else
		tmp = Float64(t - Float64(t * Float64(x / y)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = (x - y) * (t / (z - y));
	tmp = 0.0;
	if (y <= -1.9e+184)
		tmp = t * (1.0 - (x / y));
	elseif (y <= 9e-307)
		tmp = t_1;
	elseif (y <= 4.9e-234)
		tmp = t / (z / (x - y));
	elseif (y <= 1.05e+17)
		tmp = t_1;
	else
		tmp = t - (t * (x / y));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x - y), $MachinePrecision] * N[(t / N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.9e+184], N[(t * N[(1.0 - N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 9e-307], t$95$1, If[LessEqual[y, 4.9e-234], N[(t / N[(z / N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.05e+17], t$95$1, N[(t - N[(t * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;y \leq 9 \cdot 10^{-307}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq 4.9 \cdot 10^{-234}:\\
\;\;\;\;\frac{t}{\frac{z}{x - y}}\\

\mathbf{elif}\;y \leq 1.05 \cdot 10^{+17}:\\
\;\;\;\;t\_1\\

\mathbf{else}:\\
\;\;\;\;t - t \cdot \frac{x}{y}\\


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

    1. Initial program 99.8%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/66.1%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified61.0%

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

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

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

        \[\leadsto t + \color{blue}{-1 \cdot \left(\frac{t \cdot x}{y} - \frac{t \cdot z}{y}\right)} \]
      3. div-sub81.1%

        \[\leadsto t + -1 \cdot \color{blue}{\frac{t \cdot x - t \cdot z}{y}} \]
      4. mul-1-neg81.1%

        \[\leadsto t + \color{blue}{\left(-\frac{t \cdot x - t \cdot z}{y}\right)} \]
      5. unsub-neg81.1%

        \[\leadsto \color{blue}{t - \frac{t \cdot x - t \cdot z}{y}} \]
      6. distribute-lft-out--81.3%

        \[\leadsto t - \frac{\color{blue}{t \cdot \left(x - z\right)}}{y} \]
      7. associate-/l*90.4%

        \[\leadsto t - \color{blue}{t \cdot \frac{x - z}{y}} \]
    7. Simplified90.4%

      \[\leadsto \color{blue}{t - t \cdot \frac{x - z}{y}} \]
    8. Taylor expanded in x around inf 90.9%

      \[\leadsto t - t \cdot \color{blue}{\frac{x}{y}} \]
    9. Taylor expanded in t around 0 90.9%

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

    if -1.9000000000000001e184 < y < 8.99999999999999978e-307 or 4.90000000000000007e-234 < y < 1.05e17

    1. Initial program 96.8%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/88.5%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified91.6%

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

    if 8.99999999999999978e-307 < y < 4.90000000000000007e-234

    1. Initial program 99.8%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/86.9%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified73.2%

      \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. associate-*r/86.9%

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

        \[\leadsto \color{blue}{\frac{x - y}{z - y} \cdot t} \]
      3. *-commutative99.8%

        \[\leadsto \color{blue}{t \cdot \frac{x - y}{z - y}} \]
      4. clear-num99.7%

        \[\leadsto t \cdot \color{blue}{\frac{1}{\frac{z - y}{x - y}}} \]
      5. un-div-inv99.9%

        \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
    6. Applied egg-rr99.9%

      \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
    7. Taylor expanded in z around inf 99.9%

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

    if 1.05e17 < y

    1. Initial program 99.8%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/76.5%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified69.5%

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

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

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

        \[\leadsto t + \color{blue}{-1 \cdot \left(\frac{t \cdot x}{y} - \frac{t \cdot z}{y}\right)} \]
      3. div-sub83.1%

        \[\leadsto t + -1 \cdot \color{blue}{\frac{t \cdot x - t \cdot z}{y}} \]
      4. mul-1-neg83.1%

        \[\leadsto t + \color{blue}{\left(-\frac{t \cdot x - t \cdot z}{y}\right)} \]
      5. unsub-neg83.1%

        \[\leadsto \color{blue}{t - \frac{t \cdot x - t \cdot z}{y}} \]
      6. distribute-lft-out--83.1%

        \[\leadsto t - \frac{\color{blue}{t \cdot \left(x - z\right)}}{y} \]
      7. associate-/l*95.4%

        \[\leadsto t - \color{blue}{t \cdot \frac{x - z}{y}} \]
    7. Simplified95.4%

      \[\leadsto \color{blue}{t - t \cdot \frac{x - z}{y}} \]
    8. Taylor expanded in x around inf 94.7%

      \[\leadsto t - t \cdot \color{blue}{\frac{x}{y}} \]
  3. Recombined 4 regimes into one program.
  4. Add Preprocessing

Alternative 8: 73.1% accurate, 0.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t \cdot \left(1 - \frac{x}{y}\right)\\ \mathbf{if}\;y \leq -2.5 \cdot 10^{-52}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq -2 \cdot 10^{-98}:\\ \;\;\;\;\left(x - y\right) \cdot \frac{t}{z}\\ \mathbf{elif}\;y \leq -1.3 \cdot 10^{-120} \lor \neg \left(y \leq 2.8 \cdot 10^{-101}\right):\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t \cdot \frac{x}{z - y}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (* t (- 1.0 (/ x y)))))
   (if (<= y -2.5e-52)
     t_1
     (if (<= y -2e-98)
       (* (- x y) (/ t z))
       (if (or (<= y -1.3e-120) (not (<= y 2.8e-101)))
         t_1
         (* t (/ x (- z y))))))))
double code(double x, double y, double z, double t) {
	double t_1 = t * (1.0 - (x / y));
	double tmp;
	if (y <= -2.5e-52) {
		tmp = t_1;
	} else if (y <= -2e-98) {
		tmp = (x - y) * (t / z);
	} else if ((y <= -1.3e-120) || !(y <= 2.8e-101)) {
		tmp = t_1;
	} else {
		tmp = t * (x / (z - y));
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: t_1
    real(8) :: tmp
    t_1 = t * (1.0d0 - (x / y))
    if (y <= (-2.5d-52)) then
        tmp = t_1
    else if (y <= (-2d-98)) then
        tmp = (x - y) * (t / z)
    else if ((y <= (-1.3d-120)) .or. (.not. (y <= 2.8d-101))) then
        tmp = t_1
    else
        tmp = t * (x / (z - y))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double t_1 = t * (1.0 - (x / y));
	double tmp;
	if (y <= -2.5e-52) {
		tmp = t_1;
	} else if (y <= -2e-98) {
		tmp = (x - y) * (t / z);
	} else if ((y <= -1.3e-120) || !(y <= 2.8e-101)) {
		tmp = t_1;
	} else {
		tmp = t * (x / (z - y));
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = t * (1.0 - (x / y))
	tmp = 0
	if y <= -2.5e-52:
		tmp = t_1
	elif y <= -2e-98:
		tmp = (x - y) * (t / z)
	elif (y <= -1.3e-120) or not (y <= 2.8e-101):
		tmp = t_1
	else:
		tmp = t * (x / (z - y))
	return tmp
function code(x, y, z, t)
	t_1 = Float64(t * Float64(1.0 - Float64(x / y)))
	tmp = 0.0
	if (y <= -2.5e-52)
		tmp = t_1;
	elseif (y <= -2e-98)
		tmp = Float64(Float64(x - y) * Float64(t / z));
	elseif ((y <= -1.3e-120) || !(y <= 2.8e-101))
		tmp = t_1;
	else
		tmp = Float64(t * Float64(x / Float64(z - y)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = t * (1.0 - (x / y));
	tmp = 0.0;
	if (y <= -2.5e-52)
		tmp = t_1;
	elseif (y <= -2e-98)
		tmp = (x - y) * (t / z);
	elseif ((y <= -1.3e-120) || ~((y <= 2.8e-101)))
		tmp = t_1;
	else
		tmp = t * (x / (z - y));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(t * N[(1.0 - N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -2.5e-52], t$95$1, If[LessEqual[y, -2e-98], N[(N[(x - y), $MachinePrecision] * N[(t / z), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[y, -1.3e-120], N[Not[LessEqual[y, 2.8e-101]], $MachinePrecision]], t$95$1, N[(t * N[(x / N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := t \cdot \left(1 - \frac{x}{y}\right)\\
\mathbf{if}\;y \leq -2.5 \cdot 10^{-52}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq -2 \cdot 10^{-98}:\\
\;\;\;\;\left(x - y\right) \cdot \frac{t}{z}\\

\mathbf{elif}\;y \leq -1.3 \cdot 10^{-120} \lor \neg \left(y \leq 2.8 \cdot 10^{-101}\right):\\
\;\;\;\;t\_1\\

\mathbf{else}:\\
\;\;\;\;t \cdot \frac{x}{z - y}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -2.5e-52 or -1.99999999999999988e-98 < y < -1.3000000000000001e-120 or 2.79999999999999989e-101 < y

    1. Initial program 98.6%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/79.5%

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

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

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

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

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

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

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

        \[\leadsto t + \color{blue}{\left(-\frac{t \cdot x - t \cdot z}{y}\right)} \]
      5. unsub-neg74.2%

        \[\leadsto \color{blue}{t - \frac{t \cdot x - t \cdot z}{y}} \]
      6. distribute-lft-out--74.9%

        \[\leadsto t - \frac{\color{blue}{t \cdot \left(x - z\right)}}{y} \]
      7. associate-/l*80.7%

        \[\leadsto t - \color{blue}{t \cdot \frac{x - z}{y}} \]
    7. Simplified80.7%

      \[\leadsto \color{blue}{t - t \cdot \frac{x - z}{y}} \]
    8. Taylor expanded in x around inf 80.3%

      \[\leadsto t - t \cdot \color{blue}{\frac{x}{y}} \]
    9. Taylor expanded in t around 0 80.3%

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

    if -2.5e-52 < y < -1.99999999999999988e-98

    1. Initial program 99.8%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/78.6%

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

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

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

      \[\leadsto \color{blue}{\frac{t \cdot \left(x - y\right)}{z}} \]
    6. Step-by-step derivation
      1. *-commutative78.6%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z}} \]
    7. Simplified99.7%

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

    if -1.3000000000000001e-120 < y < 2.79999999999999989e-101

    1. Initial program 96.5%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 77.9%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.5 \cdot 10^{-52}:\\ \;\;\;\;t \cdot \left(1 - \frac{x}{y}\right)\\ \mathbf{elif}\;y \leq -2 \cdot 10^{-98}:\\ \;\;\;\;\left(x - y\right) \cdot \frac{t}{z}\\ \mathbf{elif}\;y \leq -1.3 \cdot 10^{-120} \lor \neg \left(y \leq 2.8 \cdot 10^{-101}\right):\\ \;\;\;\;t \cdot \left(1 - \frac{x}{y}\right)\\ \mathbf{else}:\\ \;\;\;\;t \cdot \frac{x}{z - y}\\ \end{array} \]
  5. Add Preprocessing

Alternative 9: 74.0% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{t}{\frac{z - y}{x}}\\ \mathbf{if}\;x \leq -1.6 \cdot 10^{+106}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;x \leq 0.19:\\ \;\;\;\;\frac{t}{1 - \frac{z}{y}}\\ \mathbf{elif}\;x \leq 5 \cdot 10^{+95}:\\ \;\;\;\;t - \frac{t \cdot x}{y}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (/ t (/ (- z y) x))))
   (if (<= x -1.6e+106)
     t_1
     (if (<= x 0.19)
       (/ t (- 1.0 (/ z y)))
       (if (<= x 5e+95) (- t (/ (* t x) y)) t_1)))))
double code(double x, double y, double z, double t) {
	double t_1 = t / ((z - y) / x);
	double tmp;
	if (x <= -1.6e+106) {
		tmp = t_1;
	} else if (x <= 0.19) {
		tmp = t / (1.0 - (z / y));
	} else if (x <= 5e+95) {
		tmp = t - ((t * x) / y);
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: t_1
    real(8) :: tmp
    t_1 = t / ((z - y) / x)
    if (x <= (-1.6d+106)) then
        tmp = t_1
    else if (x <= 0.19d0) then
        tmp = t / (1.0d0 - (z / y))
    else if (x <= 5d+95) then
        tmp = t - ((t * x) / y)
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double t_1 = t / ((z - y) / x);
	double tmp;
	if (x <= -1.6e+106) {
		tmp = t_1;
	} else if (x <= 0.19) {
		tmp = t / (1.0 - (z / y));
	} else if (x <= 5e+95) {
		tmp = t - ((t * x) / y);
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = t / ((z - y) / x)
	tmp = 0
	if x <= -1.6e+106:
		tmp = t_1
	elif x <= 0.19:
		tmp = t / (1.0 - (z / y))
	elif x <= 5e+95:
		tmp = t - ((t * x) / y)
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t)
	t_1 = Float64(t / Float64(Float64(z - y) / x))
	tmp = 0.0
	if (x <= -1.6e+106)
		tmp = t_1;
	elseif (x <= 0.19)
		tmp = Float64(t / Float64(1.0 - Float64(z / y)));
	elseif (x <= 5e+95)
		tmp = Float64(t - Float64(Float64(t * x) / y));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = t / ((z - y) / x);
	tmp = 0.0;
	if (x <= -1.6e+106)
		tmp = t_1;
	elseif (x <= 0.19)
		tmp = t / (1.0 - (z / y));
	elseif (x <= 5e+95)
		tmp = t - ((t * x) / y);
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(t / N[(N[(z - y), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -1.6e+106], t$95$1, If[LessEqual[x, 0.19], N[(t / N[(1.0 - N[(z / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 5e+95], N[(t - N[(N[(t * x), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{t}{\frac{z - y}{x}}\\
\mathbf{if}\;x \leq -1.6 \cdot 10^{+106}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;x \leq 0.19:\\
\;\;\;\;\frac{t}{1 - \frac{z}{y}}\\

\mathbf{elif}\;x \leq 5 \cdot 10^{+95}:\\
\;\;\;\;t - \frac{t \cdot x}{y}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if x < -1.5999999999999999e106 or 5.00000000000000025e95 < x

    1. Initial program 97.6%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/76.6%

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

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

      \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. associate-*r/76.6%

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

        \[\leadsto \color{blue}{\frac{x - y}{z - y} \cdot t} \]
      3. *-commutative97.6%

        \[\leadsto \color{blue}{t \cdot \frac{x - y}{z - y}} \]
      4. clear-num97.5%

        \[\leadsto t \cdot \color{blue}{\frac{1}{\frac{z - y}{x - y}}} \]
      5. un-div-inv97.9%

        \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
    6. Applied egg-rr97.9%

      \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
    7. Taylor expanded in x around inf 83.1%

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

    if -1.5999999999999999e106 < x < 0.19

    1. Initial program 98.0%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/87.3%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified84.2%

      \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. associate-*r/87.3%

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

        \[\leadsto \color{blue}{\frac{x - y}{z - y} \cdot t} \]
      3. *-commutative98.0%

        \[\leadsto \color{blue}{t \cdot \frac{x - y}{z - y}} \]
      4. clear-num98.0%

        \[\leadsto t \cdot \color{blue}{\frac{1}{\frac{z - y}{x - y}}} \]
      5. un-div-inv98.0%

        \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
    6. Applied egg-rr98.0%

      \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
    7. Taylor expanded in x around 0 81.1%

      \[\leadsto \frac{t}{\color{blue}{-1 \cdot \frac{z - y}{y}}} \]
    8. Step-by-step derivation
      1. mul-1-neg81.1%

        \[\leadsto \frac{t}{\color{blue}{-\frac{z - y}{y}}} \]
      2. neg-sub081.1%

        \[\leadsto \frac{t}{\color{blue}{0 - \frac{z - y}{y}}} \]
      3. div-sub81.1%

        \[\leadsto \frac{t}{0 - \color{blue}{\left(\frac{z}{y} - \frac{y}{y}\right)}} \]
      4. *-inverses81.1%

        \[\leadsto \frac{t}{0 - \left(\frac{z}{y} - \color{blue}{1}\right)} \]
      5. associate-+l-81.1%

        \[\leadsto \frac{t}{\color{blue}{\left(0 - \frac{z}{y}\right) + 1}} \]
      6. neg-sub081.1%

        \[\leadsto \frac{t}{\color{blue}{\left(-\frac{z}{y}\right)} + 1} \]
      7. neg-mul-181.1%

        \[\leadsto \frac{t}{\color{blue}{-1 \cdot \frac{z}{y}} + 1} \]
      8. +-commutative81.1%

        \[\leadsto \frac{t}{\color{blue}{1 + -1 \cdot \frac{z}{y}}} \]
      9. neg-mul-181.1%

        \[\leadsto \frac{t}{1 + \color{blue}{\left(-\frac{z}{y}\right)}} \]
      10. unsub-neg81.1%

        \[\leadsto \frac{t}{\color{blue}{1 - \frac{z}{y}}} \]
    9. Simplified81.1%

      \[\leadsto \frac{t}{\color{blue}{1 - \frac{z}{y}}} \]

    if 0.19 < x < 5.00000000000000025e95

    1. Initial program 99.8%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/80.6%

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

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

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

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

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

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

        \[\leadsto t + -1 \cdot \color{blue}{\frac{t \cdot x - t \cdot z}{y}} \]
      4. mul-1-neg78.0%

        \[\leadsto t + \color{blue}{\left(-\frac{t \cdot x - t \cdot z}{y}\right)} \]
      5. unsub-neg78.0%

        \[\leadsto \color{blue}{t - \frac{t \cdot x - t \cdot z}{y}} \]
      6. distribute-lft-out--78.0%

        \[\leadsto t - \frac{\color{blue}{t \cdot \left(x - z\right)}}{y} \]
      7. associate-/l*77.9%

        \[\leadsto t - \color{blue}{t \cdot \frac{x - z}{y}} \]
    7. Simplified77.9%

      \[\leadsto \color{blue}{t - t \cdot \frac{x - z}{y}} \]
    8. Taylor expanded in x around inf 77.0%

      \[\leadsto t - \color{blue}{\frac{t \cdot x}{y}} \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 10: 73.9% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t \cdot \frac{x}{z - y}\\ \mathbf{if}\;x \leq -1.45 \cdot 10^{+106}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;x \leq 2.2:\\ \;\;\;\;\frac{t}{1 - \frac{z}{y}}\\ \mathbf{elif}\;x \leq 4.2 \cdot 10^{+97}:\\ \;\;\;\;t - \frac{t \cdot x}{y}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (* t (/ x (- z y)))))
   (if (<= x -1.45e+106)
     t_1
     (if (<= x 2.2)
       (/ t (- 1.0 (/ z y)))
       (if (<= x 4.2e+97) (- t (/ (* t x) y)) t_1)))))
double code(double x, double y, double z, double t) {
	double t_1 = t * (x / (z - y));
	double tmp;
	if (x <= -1.45e+106) {
		tmp = t_1;
	} else if (x <= 2.2) {
		tmp = t / (1.0 - (z / y));
	} else if (x <= 4.2e+97) {
		tmp = t - ((t * x) / y);
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: t_1
    real(8) :: tmp
    t_1 = t * (x / (z - y))
    if (x <= (-1.45d+106)) then
        tmp = t_1
    else if (x <= 2.2d0) then
        tmp = t / (1.0d0 - (z / y))
    else if (x <= 4.2d+97) then
        tmp = t - ((t * x) / y)
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double t_1 = t * (x / (z - y));
	double tmp;
	if (x <= -1.45e+106) {
		tmp = t_1;
	} else if (x <= 2.2) {
		tmp = t / (1.0 - (z / y));
	} else if (x <= 4.2e+97) {
		tmp = t - ((t * x) / y);
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = t * (x / (z - y))
	tmp = 0
	if x <= -1.45e+106:
		tmp = t_1
	elif x <= 2.2:
		tmp = t / (1.0 - (z / y))
	elif x <= 4.2e+97:
		tmp = t - ((t * x) / y)
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t)
	t_1 = Float64(t * Float64(x / Float64(z - y)))
	tmp = 0.0
	if (x <= -1.45e+106)
		tmp = t_1;
	elseif (x <= 2.2)
		tmp = Float64(t / Float64(1.0 - Float64(z / y)));
	elseif (x <= 4.2e+97)
		tmp = Float64(t - Float64(Float64(t * x) / y));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = t * (x / (z - y));
	tmp = 0.0;
	if (x <= -1.45e+106)
		tmp = t_1;
	elseif (x <= 2.2)
		tmp = t / (1.0 - (z / y));
	elseif (x <= 4.2e+97)
		tmp = t - ((t * x) / y);
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(t * N[(x / N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -1.45e+106], t$95$1, If[LessEqual[x, 2.2], N[(t / N[(1.0 - N[(z / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 4.2e+97], N[(t - N[(N[(t * x), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := t \cdot \frac{x}{z - y}\\
\mathbf{if}\;x \leq -1.45 \cdot 10^{+106}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;x \leq 2.2:\\
\;\;\;\;\frac{t}{1 - \frac{z}{y}}\\

\mathbf{elif}\;x \leq 4.2 \cdot 10^{+97}:\\
\;\;\;\;t - \frac{t \cdot x}{y}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if x < -1.4500000000000001e106 or 4.20000000000000023e97 < x

    1. Initial program 97.6%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 82.7%

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

    if -1.4500000000000001e106 < x < 2.2000000000000002

    1. Initial program 98.0%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/87.3%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified84.2%

      \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. associate-*r/87.3%

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

        \[\leadsto \color{blue}{\frac{x - y}{z - y} \cdot t} \]
      3. *-commutative98.0%

        \[\leadsto \color{blue}{t \cdot \frac{x - y}{z - y}} \]
      4. clear-num98.0%

        \[\leadsto t \cdot \color{blue}{\frac{1}{\frac{z - y}{x - y}}} \]
      5. un-div-inv98.0%

        \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
    6. Applied egg-rr98.0%

      \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
    7. Taylor expanded in x around 0 81.1%

      \[\leadsto \frac{t}{\color{blue}{-1 \cdot \frac{z - y}{y}}} \]
    8. Step-by-step derivation
      1. mul-1-neg81.1%

        \[\leadsto \frac{t}{\color{blue}{-\frac{z - y}{y}}} \]
      2. neg-sub081.1%

        \[\leadsto \frac{t}{\color{blue}{0 - \frac{z - y}{y}}} \]
      3. div-sub81.1%

        \[\leadsto \frac{t}{0 - \color{blue}{\left(\frac{z}{y} - \frac{y}{y}\right)}} \]
      4. *-inverses81.1%

        \[\leadsto \frac{t}{0 - \left(\frac{z}{y} - \color{blue}{1}\right)} \]
      5. associate-+l-81.1%

        \[\leadsto \frac{t}{\color{blue}{\left(0 - \frac{z}{y}\right) + 1}} \]
      6. neg-sub081.1%

        \[\leadsto \frac{t}{\color{blue}{\left(-\frac{z}{y}\right)} + 1} \]
      7. neg-mul-181.1%

        \[\leadsto \frac{t}{\color{blue}{-1 \cdot \frac{z}{y}} + 1} \]
      8. +-commutative81.1%

        \[\leadsto \frac{t}{\color{blue}{1 + -1 \cdot \frac{z}{y}}} \]
      9. neg-mul-181.1%

        \[\leadsto \frac{t}{1 + \color{blue}{\left(-\frac{z}{y}\right)}} \]
      10. unsub-neg81.1%

        \[\leadsto \frac{t}{\color{blue}{1 - \frac{z}{y}}} \]
    9. Simplified81.1%

      \[\leadsto \frac{t}{\color{blue}{1 - \frac{z}{y}}} \]

    if 2.2000000000000002 < x < 4.20000000000000023e97

    1. Initial program 99.8%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/80.6%

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

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

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

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

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

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

        \[\leadsto t + -1 \cdot \color{blue}{\frac{t \cdot x - t \cdot z}{y}} \]
      4. mul-1-neg78.0%

        \[\leadsto t + \color{blue}{\left(-\frac{t \cdot x - t \cdot z}{y}\right)} \]
      5. unsub-neg78.0%

        \[\leadsto \color{blue}{t - \frac{t \cdot x - t \cdot z}{y}} \]
      6. distribute-lft-out--78.0%

        \[\leadsto t - \frac{\color{blue}{t \cdot \left(x - z\right)}}{y} \]
      7. associate-/l*77.9%

        \[\leadsto t - \color{blue}{t \cdot \frac{x - z}{y}} \]
    7. Simplified77.9%

      \[\leadsto \color{blue}{t - t \cdot \frac{x - z}{y}} \]
    8. Taylor expanded in x around inf 77.0%

      \[\leadsto t - \color{blue}{\frac{t \cdot x}{y}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification81.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -1.45 \cdot 10^{+106}:\\ \;\;\;\;t \cdot \frac{x}{z - y}\\ \mathbf{elif}\;x \leq 2.2:\\ \;\;\;\;\frac{t}{1 - \frac{z}{y}}\\ \mathbf{elif}\;x \leq 4.2 \cdot 10^{+97}:\\ \;\;\;\;t - \frac{t \cdot x}{y}\\ \mathbf{else}:\\ \;\;\;\;t \cdot \frac{x}{z - y}\\ \end{array} \]
  5. Add Preprocessing

Alternative 11: 61.7% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -1.65 \cdot 10^{-49}:\\ \;\;\;\;t\\ \mathbf{elif}\;y \leq 1.55 \cdot 10^{+15}:\\ \;\;\;\;\frac{t}{\frac{z}{x}}\\ \mathbf{elif}\;y \leq 3.4 \cdot 10^{+58}:\\ \;\;\;\;x \cdot \frac{t}{-y}\\ \mathbf{else}:\\ \;\;\;\;t\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (<= y -1.65e-49)
   t
   (if (<= y 1.55e+15) (/ t (/ z x)) (if (<= y 3.4e+58) (* x (/ t (- y))) t))))
double code(double x, double y, double z, double t) {
	double tmp;
	if (y <= -1.65e-49) {
		tmp = t;
	} else if (y <= 1.55e+15) {
		tmp = t / (z / x);
	} else if (y <= 3.4e+58) {
		tmp = x * (t / -y);
	} else {
		tmp = t;
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if (y <= (-1.65d-49)) then
        tmp = t
    else if (y <= 1.55d+15) then
        tmp = t / (z / x)
    else if (y <= 3.4d+58) then
        tmp = x * (t / -y)
    else
        tmp = t
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (y <= -1.65e-49) {
		tmp = t;
	} else if (y <= 1.55e+15) {
		tmp = t / (z / x);
	} else if (y <= 3.4e+58) {
		tmp = x * (t / -y);
	} else {
		tmp = t;
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if y <= -1.65e-49:
		tmp = t
	elif y <= 1.55e+15:
		tmp = t / (z / x)
	elif y <= 3.4e+58:
		tmp = x * (t / -y)
	else:
		tmp = t
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if (y <= -1.65e-49)
		tmp = t;
	elseif (y <= 1.55e+15)
		tmp = Float64(t / Float64(z / x));
	elseif (y <= 3.4e+58)
		tmp = Float64(x * Float64(t / Float64(-y)));
	else
		tmp = t;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (y <= -1.65e-49)
		tmp = t;
	elseif (y <= 1.55e+15)
		tmp = t / (z / x);
	elseif (y <= 3.4e+58)
		tmp = x * (t / -y);
	else
		tmp = t;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[LessEqual[y, -1.65e-49], t, If[LessEqual[y, 1.55e+15], N[(t / N[(z / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3.4e+58], N[(x * N[(t / (-y)), $MachinePrecision]), $MachinePrecision], t]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.65 \cdot 10^{-49}:\\
\;\;\;\;t\\

\mathbf{elif}\;y \leq 1.55 \cdot 10^{+15}:\\
\;\;\;\;\frac{t}{\frac{z}{x}}\\

\mathbf{elif}\;y \leq 3.4 \cdot 10^{+58}:\\
\;\;\;\;x \cdot \frac{t}{-y}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -1.65e-49 or 3.4000000000000001e58 < y

    1. Initial program 99.1%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/77.6%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified74.5%

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

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

    if -1.65e-49 < y < 1.55e15

    1. Initial program 96.5%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/89.9%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified90.5%

      \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. associate-*r/89.9%

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

        \[\leadsto \color{blue}{\frac{x - y}{z - y} \cdot t} \]
      3. *-commutative96.5%

        \[\leadsto \color{blue}{t \cdot \frac{x - y}{z - y}} \]
      4. clear-num96.4%

        \[\leadsto t \cdot \color{blue}{\frac{1}{\frac{z - y}{x - y}}} \]
      5. un-div-inv96.5%

        \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
    6. Applied egg-rr96.5%

      \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
    7. Taylor expanded in y around 0 64.7%

      \[\leadsto \frac{t}{\color{blue}{\frac{z}{x}}} \]

    if 1.55e15 < y < 3.4000000000000001e58

    1. Initial program 99.0%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/84.0%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified99.2%

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

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

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

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

        \[\leadsto t + -1 \cdot \color{blue}{\frac{t \cdot x - t \cdot z}{y}} \]
      4. mul-1-neg68.0%

        \[\leadsto t + \color{blue}{\left(-\frac{t \cdot x - t \cdot z}{y}\right)} \]
      5. unsub-neg68.0%

        \[\leadsto \color{blue}{t - \frac{t \cdot x - t \cdot z}{y}} \]
      6. distribute-lft-out--68.0%

        \[\leadsto t - \frac{\color{blue}{t \cdot \left(x - z\right)}}{y} \]
      7. associate-/l*82.6%

        \[\leadsto t - \color{blue}{t \cdot \frac{x - z}{y}} \]
    7. Simplified82.6%

      \[\leadsto \color{blue}{t - t \cdot \frac{x - z}{y}} \]
    8. Taylor expanded in x around inf 83.3%

      \[\leadsto t - t \cdot \color{blue}{\frac{x}{y}} \]
    9. Taylor expanded in t around 0 83.3%

      \[\leadsto \color{blue}{t \cdot \left(1 - \frac{x}{y}\right)} \]
    10. Taylor expanded in x around inf 59.8%

      \[\leadsto \color{blue}{-1 \cdot \frac{t \cdot x}{y}} \]
    11. Step-by-step derivation
      1. associate-*l/74.8%

        \[\leadsto -1 \cdot \color{blue}{\left(\frac{t}{y} \cdot x\right)} \]
      2. associate-*l*74.8%

        \[\leadsto \color{blue}{\left(-1 \cdot \frac{t}{y}\right) \cdot x} \]
      3. *-commutative74.8%

        \[\leadsto \color{blue}{x \cdot \left(-1 \cdot \frac{t}{y}\right)} \]
      4. mul-1-neg74.8%

        \[\leadsto x \cdot \color{blue}{\left(-\frac{t}{y}\right)} \]
      5. distribute-neg-frac274.8%

        \[\leadsto x \cdot \color{blue}{\frac{t}{-y}} \]
    12. Simplified74.8%

      \[\leadsto \color{blue}{x \cdot \frac{t}{-y}} \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 12: 61.6% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -5.8 \cdot 10^{-50}:\\ \;\;\;\;t\\ \mathbf{elif}\;y \leq 1450000000000:\\ \;\;\;\;\frac{t}{\frac{z}{x}}\\ \mathbf{elif}\;y \leq 1.42 \cdot 10^{+59}:\\ \;\;\;\;t \cdot \frac{x}{-y}\\ \mathbf{else}:\\ \;\;\;\;t\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (<= y -5.8e-50)
   t
   (if (<= y 1450000000000.0)
     (/ t (/ z x))
     (if (<= y 1.42e+59) (* t (/ x (- y))) t))))
double code(double x, double y, double z, double t) {
	double tmp;
	if (y <= -5.8e-50) {
		tmp = t;
	} else if (y <= 1450000000000.0) {
		tmp = t / (z / x);
	} else if (y <= 1.42e+59) {
		tmp = t * (x / -y);
	} else {
		tmp = t;
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if (y <= (-5.8d-50)) then
        tmp = t
    else if (y <= 1450000000000.0d0) then
        tmp = t / (z / x)
    else if (y <= 1.42d+59) then
        tmp = t * (x / -y)
    else
        tmp = t
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (y <= -5.8e-50) {
		tmp = t;
	} else if (y <= 1450000000000.0) {
		tmp = t / (z / x);
	} else if (y <= 1.42e+59) {
		tmp = t * (x / -y);
	} else {
		tmp = t;
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if y <= -5.8e-50:
		tmp = t
	elif y <= 1450000000000.0:
		tmp = t / (z / x)
	elif y <= 1.42e+59:
		tmp = t * (x / -y)
	else:
		tmp = t
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if (y <= -5.8e-50)
		tmp = t;
	elseif (y <= 1450000000000.0)
		tmp = Float64(t / Float64(z / x));
	elseif (y <= 1.42e+59)
		tmp = Float64(t * Float64(x / Float64(-y)));
	else
		tmp = t;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (y <= -5.8e-50)
		tmp = t;
	elseif (y <= 1450000000000.0)
		tmp = t / (z / x);
	elseif (y <= 1.42e+59)
		tmp = t * (x / -y);
	else
		tmp = t;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[LessEqual[y, -5.8e-50], t, If[LessEqual[y, 1450000000000.0], N[(t / N[(z / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.42e+59], N[(t * N[(x / (-y)), $MachinePrecision]), $MachinePrecision], t]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -5.8 \cdot 10^{-50}:\\
\;\;\;\;t\\

\mathbf{elif}\;y \leq 1450000000000:\\
\;\;\;\;\frac{t}{\frac{z}{x}}\\

\mathbf{elif}\;y \leq 1.42 \cdot 10^{+59}:\\
\;\;\;\;t \cdot \frac{x}{-y}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -5.80000000000000016e-50 or 1.42000000000000005e59 < y

    1. Initial program 99.1%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/77.6%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified74.5%

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

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

    if -5.80000000000000016e-50 < y < 1.45e12

    1. Initial program 96.5%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/89.9%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified90.5%

      \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. associate-*r/89.9%

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

        \[\leadsto \color{blue}{\frac{x - y}{z - y} \cdot t} \]
      3. *-commutative96.5%

        \[\leadsto \color{blue}{t \cdot \frac{x - y}{z - y}} \]
      4. clear-num96.4%

        \[\leadsto t \cdot \color{blue}{\frac{1}{\frac{z - y}{x - y}}} \]
      5. un-div-inv96.5%

        \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
    6. Applied egg-rr96.5%

      \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
    7. Taylor expanded in y around 0 64.7%

      \[\leadsto \frac{t}{\color{blue}{\frac{z}{x}}} \]

    if 1.45e12 < y < 1.42000000000000005e59

    1. Initial program 99.0%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/84.0%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified99.2%

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

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

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

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

        \[\leadsto t + -1 \cdot \color{blue}{\frac{t \cdot x - t \cdot z}{y}} \]
      4. mul-1-neg68.0%

        \[\leadsto t + \color{blue}{\left(-\frac{t \cdot x - t \cdot z}{y}\right)} \]
      5. unsub-neg68.0%

        \[\leadsto \color{blue}{t - \frac{t \cdot x - t \cdot z}{y}} \]
      6. distribute-lft-out--68.0%

        \[\leadsto t - \frac{\color{blue}{t \cdot \left(x - z\right)}}{y} \]
      7. associate-/l*82.6%

        \[\leadsto t - \color{blue}{t \cdot \frac{x - z}{y}} \]
    7. Simplified82.6%

      \[\leadsto \color{blue}{t - t \cdot \frac{x - z}{y}} \]
    8. Taylor expanded in x around inf 83.3%

      \[\leadsto t - t \cdot \color{blue}{\frac{x}{y}} \]
    9. Taylor expanded in x around inf 59.8%

      \[\leadsto \color{blue}{-1 \cdot \frac{t \cdot x}{y}} \]
    10. Step-by-step derivation
      1. mul-1-neg59.8%

        \[\leadsto \color{blue}{-\frac{t \cdot x}{y}} \]
      2. associate-*r/74.8%

        \[\leadsto -\color{blue}{t \cdot \frac{x}{y}} \]
      3. distribute-rgt-neg-in74.8%

        \[\leadsto \color{blue}{t \cdot \left(-\frac{x}{y}\right)} \]
      4. distribute-neg-frac274.8%

        \[\leadsto t \cdot \color{blue}{\frac{x}{-y}} \]
    11. Simplified74.8%

      \[\leadsto \color{blue}{t \cdot \frac{x}{-y}} \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 13: 49.7% accurate, 0.6× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3 \cdot 10^{+22} \lor \neg \left(z \leq 2.5 \cdot 10^{+31}\right):\\
\;\;\;\;t \cdot \frac{x}{z}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -3e22 or 2.50000000000000013e31 < z

    1. Initial program 97.4%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0 61.3%

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

    if -3e22 < z < 2.50000000000000013e31

    1. Initial program 98.4%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/82.9%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified81.7%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3 \cdot 10^{+22} \lor \neg \left(z \leq 2.5 \cdot 10^{+31}\right):\\ \;\;\;\;t \cdot \frac{x}{z}\\ \mathbf{else}:\\ \;\;\;\;t\\ \end{array} \]
  5. Add Preprocessing

Alternative 14: 47.2% accurate, 0.6× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -9 \cdot 10^{+26} \lor \neg \left(z \leq 1.32 \cdot 10^{+73}\right):\\
\;\;\;\;x \cdot \frac{t}{z}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -8.99999999999999957e26 or 1.32e73 < z

    1. Initial program 97.2%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/83.5%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified83.5%

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

      \[\leadsto \color{blue}{\frac{t \cdot x}{z}} \]
    6. Step-by-step derivation
      1. *-commutative56.7%

        \[\leadsto \frac{\color{blue}{x \cdot t}}{z} \]
      2. associate-/l*59.8%

        \[\leadsto \color{blue}{x \cdot \frac{t}{z}} \]
    7. Simplified59.8%

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

    if -8.99999999999999957e26 < z < 1.32e73

    1. Initial program 98.5%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/82.9%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified81.2%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -9 \cdot 10^{+26} \lor \neg \left(z \leq 1.32 \cdot 10^{+73}\right):\\ \;\;\;\;x \cdot \frac{t}{z}\\ \mathbf{else}:\\ \;\;\;\;t\\ \end{array} \]
  5. Add Preprocessing

Alternative 15: 58.3% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -1.65 \cdot 10^{-49}:\\ \;\;\;\;t\\ \mathbf{elif}\;y \leq 5.1 \cdot 10^{-124}:\\ \;\;\;\;\frac{t}{\frac{z}{x}}\\ \mathbf{else}:\\ \;\;\;\;t\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (<= y -1.65e-49) t (if (<= y 5.1e-124) (/ t (/ z x)) t)))
double code(double x, double y, double z, double t) {
	double tmp;
	if (y <= -1.65e-49) {
		tmp = t;
	} else if (y <= 5.1e-124) {
		tmp = t / (z / x);
	} else {
		tmp = t;
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if (y <= (-1.65d-49)) then
        tmp = t
    else if (y <= 5.1d-124) then
        tmp = t / (z / x)
    else
        tmp = t
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (y <= -1.65e-49) {
		tmp = t;
	} else if (y <= 5.1e-124) {
		tmp = t / (z / x);
	} else {
		tmp = t;
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if y <= -1.65e-49:
		tmp = t
	elif y <= 5.1e-124:
		tmp = t / (z / x)
	else:
		tmp = t
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if (y <= -1.65e-49)
		tmp = t;
	elseif (y <= 5.1e-124)
		tmp = Float64(t / Float64(z / x));
	else
		tmp = t;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (y <= -1.65e-49)
		tmp = t;
	elseif (y <= 5.1e-124)
		tmp = t / (z / x);
	else
		tmp = t;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[LessEqual[y, -1.65e-49], t, If[LessEqual[y, 5.1e-124], N[(t / N[(z / x), $MachinePrecision]), $MachinePrecision], t]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.65 \cdot 10^{-49}:\\
\;\;\;\;t\\

\mathbf{elif}\;y \leq 5.1 \cdot 10^{-124}:\\
\;\;\;\;\frac{t}{\frac{z}{x}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -1.65e-49 or 5.1000000000000001e-124 < y

    1. Initial program 98.7%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/79.9%

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

        \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    3. Simplified78.0%

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

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

    if -1.65e-49 < y < 5.1000000000000001e-124

    1. Initial program 96.6%

      \[\frac{x - y}{z - y} \cdot t \]
    2. Step-by-step derivation
      1. associate-*l/89.3%

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

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

      \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. associate-*r/89.3%

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

        \[\leadsto \color{blue}{\frac{x - y}{z - y} \cdot t} \]
      3. *-commutative96.6%

        \[\leadsto \color{blue}{t \cdot \frac{x - y}{z - y}} \]
      4. clear-num96.6%

        \[\leadsto t \cdot \color{blue}{\frac{1}{\frac{z - y}{x - y}}} \]
      5. un-div-inv96.7%

        \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
    6. Applied egg-rr96.7%

      \[\leadsto \color{blue}{\frac{t}{\frac{z - y}{x - y}}} \]
    7. Taylor expanded in y around 0 70.2%

      \[\leadsto \frac{t}{\color{blue}{\frac{z}{x}}} \]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 16: 96.8% accurate, 1.0× speedup?

\[\begin{array}{l} \\ t \cdot \frac{x - y}{z - y} \end{array} \]
(FPCore (x y z t) :precision binary64 (* t (/ (- x y) (- z y))))
double code(double x, double y, double z, double t) {
	return t * ((x - y) / (z - y));
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    code = t * ((x - y) / (z - y))
end function
public static double code(double x, double y, double z, double t) {
	return t * ((x - y) / (z - y));
}
def code(x, y, z, t):
	return t * ((x - y) / (z - y))
function code(x, y, z, t)
	return Float64(t * Float64(Float64(x - y) / Float64(z - y)))
end
function tmp = code(x, y, z, t)
	tmp = t * ((x - y) / (z - y));
end
code[x_, y_, z_, t_] := N[(t * N[(N[(x - y), $MachinePrecision] / N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
t \cdot \frac{x - y}{z - y}
\end{array}
Derivation
  1. Initial program 98.0%

    \[\frac{x - y}{z - y} \cdot t \]
  2. Add Preprocessing
  3. Final simplification98.0%

    \[\leadsto t \cdot \frac{x - y}{z - y} \]
  4. Add Preprocessing

Alternative 17: 35.3% accurate, 9.0× speedup?

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

\\
t
\end{array}
Derivation
  1. Initial program 98.0%

    \[\frac{x - y}{z - y} \cdot t \]
  2. Step-by-step derivation
    1. associate-*l/83.2%

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

      \[\leadsto \color{blue}{\left(x - y\right) \cdot \frac{t}{z - y}} \]
  3. Simplified82.2%

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

    \[\leadsto \color{blue}{t} \]
  6. Add Preprocessing

Developer target: 96.8% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \frac{t}{\frac{z - y}{x - y}} \end{array} \]
(FPCore (x y z t) :precision binary64 (/ t (/ (- z y) (- x y))))
double code(double x, double y, double z, double t) {
	return t / ((z - y) / (x - y));
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    code = t / ((z - y) / (x - y))
end function
public static double code(double x, double y, double z, double t) {
	return t / ((z - y) / (x - y));
}
def code(x, y, z, t):
	return t / ((z - y) / (x - y))
function code(x, y, z, t)
	return Float64(t / Float64(Float64(z - y) / Float64(x - y)))
end
function tmp = code(x, y, z, t)
	tmp = t / ((z - y) / (x - y));
end
code[x_, y_, z_, t_] := N[(t / N[(N[(z - y), $MachinePrecision] / N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{t}{\frac{z - y}{x - y}}
\end{array}

Reproduce

?
herbie shell --seed 2024107 
(FPCore (x y z t)
  :name "Numeric.Signal.Multichannel:$cput from hsignal-0.2.7.1"
  :precision binary64

  :alt
  (/ t (/ (- z y) (- x y)))

  (* (/ (- x y) (- z y)) t))