Numeric.SpecFunctions:invIncompleteBetaWorker from math-functions-0.1.5.2, C

Percentage Accurate: 94.4% → 98.3%
Time: 12.3s
Alternatives: 13
Speedup: 0.4×

Specification

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

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

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

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

Alternative 1: 98.3% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{y}{z} - \frac{t}{1 - z}\\ \mathbf{if}\;t_1 \leq -\infty \lor \neg \left(t_1 \leq 5 \cdot 10^{+306}\right):\\ \;\;\;\;y \cdot \frac{x}{z}\\ \mathbf{else}:\\ \;\;\;\;x \cdot t_1\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (- (/ y z) (/ t (- 1.0 z)))))
   (if (or (<= t_1 (- INFINITY)) (not (<= t_1 5e+306)))
     (* y (/ x z))
     (* x t_1))))
double code(double x, double y, double z, double t) {
	double t_1 = (y / z) - (t / (1.0 - z));
	double tmp;
	if ((t_1 <= -((double) INFINITY)) || !(t_1 <= 5e+306)) {
		tmp = y * (x / z);
	} else {
		tmp = x * t_1;
	}
	return tmp;
}
public static double code(double x, double y, double z, double t) {
	double t_1 = (y / z) - (t / (1.0 - z));
	double tmp;
	if ((t_1 <= -Double.POSITIVE_INFINITY) || !(t_1 <= 5e+306)) {
		tmp = y * (x / z);
	} else {
		tmp = x * t_1;
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = (y / z) - (t / (1.0 - z))
	tmp = 0
	if (t_1 <= -math.inf) or not (t_1 <= 5e+306):
		tmp = y * (x / z)
	else:
		tmp = x * t_1
	return tmp
function code(x, y, z, t)
	t_1 = Float64(Float64(y / z) - Float64(t / Float64(1.0 - z)))
	tmp = 0.0
	if ((t_1 <= Float64(-Inf)) || !(t_1 <= 5e+306))
		tmp = Float64(y * Float64(x / z));
	else
		tmp = Float64(x * t_1);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = (y / z) - (t / (1.0 - z));
	tmp = 0.0;
	if ((t_1 <= -Inf) || ~((t_1 <= 5e+306)))
		tmp = y * (x / z);
	else
		tmp = x * t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(y / z), $MachinePrecision] - N[(t / N[(1.0 - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$1, (-Infinity)], N[Not[LessEqual[t$95$1, 5e+306]], $MachinePrecision]], N[(y * N[(x / z), $MachinePrecision]), $MachinePrecision], N[(x * t$95$1), $MachinePrecision]]]
\begin{array}{l}

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (-.f64 (/.f64 y z) (/.f64 t (-.f64 1 z))) < -inf.0 or 4.99999999999999993e306 < (-.f64 (/.f64 y z) (/.f64 t (-.f64 1 z)))

    1. Initial program 61.8%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in y around inf 99.7%

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

        \[\leadsto \color{blue}{\frac{x}{\frac{z}{y}}} \]
      2. associate-/r/99.9%

        \[\leadsto \color{blue}{\frac{x}{z} \cdot y} \]
    4. Simplified99.9%

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

    if -inf.0 < (-.f64 (/.f64 y z) (/.f64 t (-.f64 1 z))) < 4.99999999999999993e306

    1. Initial program 99.4%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
  3. Recombined 2 regimes into one program.
  4. Final simplification99.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{y}{z} - \frac{t}{1 - z} \leq -\infty \lor \neg \left(\frac{y}{z} - \frac{t}{1 - z} \leq 5 \cdot 10^{+306}\right):\\ \;\;\;\;y \cdot \frac{x}{z}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right)\\ \end{array} \]

Alternative 2: 96.3% accurate, 0.1× speedup?

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

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

\mathbf{else}:\\
\;\;\;\;t_1\\


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

    1. Initial program 80.8%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Step-by-step derivation
      1. *-commutative80.8%

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

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

        \[\leadsto \color{blue}{\frac{\left(y \cdot \left(1 - z\right) - z \cdot t\right) \cdot x}{z \cdot \left(1 - z\right)}} \]
      4. cancel-sign-sub-inv99.8%

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

        \[\leadsto \frac{\color{blue}{\mathsf{fma}\left(y, 1 - z, \left(-z\right) \cdot t\right)} \cdot x}{z \cdot \left(1 - z\right)} \]
    3. Applied egg-rr99.8%

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

    if -inf.0 < (*.f64 x (-.f64 (/.f64 y z) (/.f64 t (-.f64 1 z))))

    1. Initial program 97.7%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
  3. Recombined 2 regimes into one program.
  4. Final simplification97.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \leq -\infty:\\ \;\;\;\;\frac{x \cdot \mathsf{fma}\left(y, 1 - z, -z \cdot t\right)}{z \cdot \left(1 - z\right)}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right)\\ \end{array} \]

Alternative 3: 64.1% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x \cdot \frac{y}{z}\\ t_2 := t \cdot \frac{x}{z}\\ \mathbf{if}\;z \leq -7.5 \cdot 10^{+97}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -10000000:\\ \;\;\;\;t_2\\ \mathbf{elif}\;z \leq 1.1 \cdot 10^{+18}:\\ \;\;\;\;y \cdot \frac{x}{z}\\ \mathbf{elif}\;z \leq 2.4 \cdot 10^{+114}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;z \leq 1.05 \cdot 10^{+192}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;x \cdot \frac{t}{z}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (* x (/ y z))) (t_2 (* t (/ x z))))
   (if (<= z -7.5e+97)
     t_1
     (if (<= z -10000000.0)
       t_2
       (if (<= z 1.1e+18)
         (* y (/ x z))
         (if (<= z 2.4e+114) t_2 (if (<= z 1.05e+192) t_1 (* x (/ t z)))))))))
double code(double x, double y, double z, double t) {
	double t_1 = x * (y / z);
	double t_2 = t * (x / z);
	double tmp;
	if (z <= -7.5e+97) {
		tmp = t_1;
	} else if (z <= -10000000.0) {
		tmp = t_2;
	} else if (z <= 1.1e+18) {
		tmp = y * (x / z);
	} else if (z <= 2.4e+114) {
		tmp = t_2;
	} else if (z <= 1.05e+192) {
		tmp = t_1;
	} else {
		tmp = x * (t / 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 = x * (y / z)
    t_2 = t * (x / z)
    if (z <= (-7.5d+97)) then
        tmp = t_1
    else if (z <= (-10000000.0d0)) then
        tmp = t_2
    else if (z <= 1.1d+18) then
        tmp = y * (x / z)
    else if (z <= 2.4d+114) then
        tmp = t_2
    else if (z <= 1.05d+192) then
        tmp = t_1
    else
        tmp = x * (t / z)
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double t_1 = x * (y / z);
	double t_2 = t * (x / z);
	double tmp;
	if (z <= -7.5e+97) {
		tmp = t_1;
	} else if (z <= -10000000.0) {
		tmp = t_2;
	} else if (z <= 1.1e+18) {
		tmp = y * (x / z);
	} else if (z <= 2.4e+114) {
		tmp = t_2;
	} else if (z <= 1.05e+192) {
		tmp = t_1;
	} else {
		tmp = x * (t / z);
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = x * (y / z)
	t_2 = t * (x / z)
	tmp = 0
	if z <= -7.5e+97:
		tmp = t_1
	elif z <= -10000000.0:
		tmp = t_2
	elif z <= 1.1e+18:
		tmp = y * (x / z)
	elif z <= 2.4e+114:
		tmp = t_2
	elif z <= 1.05e+192:
		tmp = t_1
	else:
		tmp = x * (t / z)
	return tmp
function code(x, y, z, t)
	t_1 = Float64(x * Float64(y / z))
	t_2 = Float64(t * Float64(x / z))
	tmp = 0.0
	if (z <= -7.5e+97)
		tmp = t_1;
	elseif (z <= -10000000.0)
		tmp = t_2;
	elseif (z <= 1.1e+18)
		tmp = Float64(y * Float64(x / z));
	elseif (z <= 2.4e+114)
		tmp = t_2;
	elseif (z <= 1.05e+192)
		tmp = t_1;
	else
		tmp = Float64(x * Float64(t / z));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = x * (y / z);
	t_2 = t * (x / z);
	tmp = 0.0;
	if (z <= -7.5e+97)
		tmp = t_1;
	elseif (z <= -10000000.0)
		tmp = t_2;
	elseif (z <= 1.1e+18)
		tmp = y * (x / z);
	elseif (z <= 2.4e+114)
		tmp = t_2;
	elseif (z <= 1.05e+192)
		tmp = t_1;
	else
		tmp = x * (t / z);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x * N[(y / z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t * N[(x / z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -7.5e+97], t$95$1, If[LessEqual[z, -10000000.0], t$95$2, If[LessEqual[z, 1.1e+18], N[(y * N[(x / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.4e+114], t$95$2, If[LessEqual[z, 1.05e+192], t$95$1, N[(x * N[(t / z), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x \cdot \frac{y}{z}\\
t_2 := t \cdot \frac{x}{z}\\
\mathbf{if}\;z \leq -7.5 \cdot 10^{+97}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq -10000000:\\
\;\;\;\;t_2\\

\mathbf{elif}\;z \leq 1.1 \cdot 10^{+18}:\\
\;\;\;\;y \cdot \frac{x}{z}\\

\mathbf{elif}\;z \leq 2.4 \cdot 10^{+114}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;z \leq 1.05 \cdot 10^{+192}:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -7.5000000000000004e97 or 2.4e114 < z < 1.04999999999999997e192

    1. Initial program 98.0%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in y around inf 59.9%

      \[\leadsto \color{blue}{\frac{x \cdot y}{z}} \]
    3. Step-by-step derivation
      1. associate-*r/74.2%

        \[\leadsto \color{blue}{x \cdot \frac{y}{z}} \]
    4. Simplified74.2%

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

    if -7.5000000000000004e97 < z < -1e7 or 1.1e18 < z < 2.4e114

    1. Initial program 99.6%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around inf 90.6%

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

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

        \[\leadsto \color{blue}{\frac{x}{z} \cdot \left(y - -1 \cdot t\right)} \]
      3. cancel-sign-sub-inv92.7%

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

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

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

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

      \[\leadsto \color{blue}{\frac{x}{z} \cdot \left(t + y\right)} \]
    5. Taylor expanded in t around inf 70.5%

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

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

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

    if -1e7 < z < 1.1e18

    1. Initial program 92.1%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in y around inf 67.2%

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

        \[\leadsto \color{blue}{\frac{x}{\frac{z}{y}}} \]
      2. associate-/r/71.7%

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

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

    if 1.04999999999999997e192 < z

    1. Initial program 99.8%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around inf 84.8%

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

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

        \[\leadsto \color{blue}{\frac{x}{z} \cdot \left(y - -1 \cdot t\right)} \]
      3. cancel-sign-sub-inv62.9%

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

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

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

        \[\leadsto \frac{x}{z} \cdot \color{blue}{\left(t + y\right)} \]
    4. Simplified62.9%

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

        \[\leadsto \color{blue}{\left(t + y\right) \cdot \frac{x}{z}} \]
      2. clear-num62.8%

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

        \[\leadsto \color{blue}{\frac{t + y}{\frac{z}{x}}} \]
      4. +-commutative62.9%

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

      \[\leadsto \color{blue}{\frac{y + t}{\frac{z}{x}}} \]
    7. Step-by-step derivation
      1. associate-/r/99.8%

        \[\leadsto \color{blue}{\frac{y + t}{z} \cdot x} \]
    8. Simplified99.8%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -7.5 \cdot 10^{+97}:\\ \;\;\;\;x \cdot \frac{y}{z}\\ \mathbf{elif}\;z \leq -10000000:\\ \;\;\;\;t \cdot \frac{x}{z}\\ \mathbf{elif}\;z \leq 1.1 \cdot 10^{+18}:\\ \;\;\;\;y \cdot \frac{x}{z}\\ \mathbf{elif}\;z \leq 2.4 \cdot 10^{+114}:\\ \;\;\;\;t \cdot \frac{x}{z}\\ \mathbf{elif}\;z \leq 1.05 \cdot 10^{+192}:\\ \;\;\;\;x \cdot \frac{y}{z}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \frac{t}{z}\\ \end{array} \]

Alternative 4: 63.9% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x \cdot \frac{y}{z}\\ \mathbf{if}\;z \leq -9.2 \cdot 10^{+96}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -7000000:\\ \;\;\;\;\frac{t}{\frac{z}{x}}\\ \mathbf{elif}\;z \leq 7 \cdot 10^{+17}:\\ \;\;\;\;y \cdot \frac{x}{z}\\ \mathbf{elif}\;z \leq 1.7 \cdot 10^{+118}:\\ \;\;\;\;t \cdot \frac{x}{z}\\ \mathbf{elif}\;z \leq 4.2 \cdot 10^{+192}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;x \cdot \frac{t}{z}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (* x (/ y z))))
   (if (<= z -9.2e+96)
     t_1
     (if (<= z -7000000.0)
       (/ t (/ z x))
       (if (<= z 7e+17)
         (* y (/ x z))
         (if (<= z 1.7e+118)
           (* t (/ x z))
           (if (<= z 4.2e+192) t_1 (* x (/ t z)))))))))
double code(double x, double y, double z, double t) {
	double t_1 = x * (y / z);
	double tmp;
	if (z <= -9.2e+96) {
		tmp = t_1;
	} else if (z <= -7000000.0) {
		tmp = t / (z / x);
	} else if (z <= 7e+17) {
		tmp = y * (x / z);
	} else if (z <= 1.7e+118) {
		tmp = t * (x / z);
	} else if (z <= 4.2e+192) {
		tmp = t_1;
	} else {
		tmp = x * (t / 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) :: tmp
    t_1 = x * (y / z)
    if (z <= (-9.2d+96)) then
        tmp = t_1
    else if (z <= (-7000000.0d0)) then
        tmp = t / (z / x)
    else if (z <= 7d+17) then
        tmp = y * (x / z)
    else if (z <= 1.7d+118) then
        tmp = t * (x / z)
    else if (z <= 4.2d+192) then
        tmp = t_1
    else
        tmp = x * (t / z)
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double t_1 = x * (y / z);
	double tmp;
	if (z <= -9.2e+96) {
		tmp = t_1;
	} else if (z <= -7000000.0) {
		tmp = t / (z / x);
	} else if (z <= 7e+17) {
		tmp = y * (x / z);
	} else if (z <= 1.7e+118) {
		tmp = t * (x / z);
	} else if (z <= 4.2e+192) {
		tmp = t_1;
	} else {
		tmp = x * (t / z);
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = x * (y / z)
	tmp = 0
	if z <= -9.2e+96:
		tmp = t_1
	elif z <= -7000000.0:
		tmp = t / (z / x)
	elif z <= 7e+17:
		tmp = y * (x / z)
	elif z <= 1.7e+118:
		tmp = t * (x / z)
	elif z <= 4.2e+192:
		tmp = t_1
	else:
		tmp = x * (t / z)
	return tmp
function code(x, y, z, t)
	t_1 = Float64(x * Float64(y / z))
	tmp = 0.0
	if (z <= -9.2e+96)
		tmp = t_1;
	elseif (z <= -7000000.0)
		tmp = Float64(t / Float64(z / x));
	elseif (z <= 7e+17)
		tmp = Float64(y * Float64(x / z));
	elseif (z <= 1.7e+118)
		tmp = Float64(t * Float64(x / z));
	elseif (z <= 4.2e+192)
		tmp = t_1;
	else
		tmp = Float64(x * Float64(t / z));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = x * (y / z);
	tmp = 0.0;
	if (z <= -9.2e+96)
		tmp = t_1;
	elseif (z <= -7000000.0)
		tmp = t / (z / x);
	elseif (z <= 7e+17)
		tmp = y * (x / z);
	elseif (z <= 1.7e+118)
		tmp = t * (x / z);
	elseif (z <= 4.2e+192)
		tmp = t_1;
	else
		tmp = x * (t / z);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x * N[(y / z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -9.2e+96], t$95$1, If[LessEqual[z, -7000000.0], N[(t / N[(z / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 7e+17], N[(y * N[(x / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.7e+118], N[(t * N[(x / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.2e+192], t$95$1, N[(x * N[(t / z), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x \cdot \frac{y}{z}\\
\mathbf{if}\;z \leq -9.2 \cdot 10^{+96}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq -7000000:\\
\;\;\;\;\frac{t}{\frac{z}{x}}\\

\mathbf{elif}\;z \leq 7 \cdot 10^{+17}:\\
\;\;\;\;y \cdot \frac{x}{z}\\

\mathbf{elif}\;z \leq 1.7 \cdot 10^{+118}:\\
\;\;\;\;t \cdot \frac{x}{z}\\

\mathbf{elif}\;z \leq 4.2 \cdot 10^{+192}:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if z < -9.2000000000000006e96 or 1.69999999999999993e118 < z < 4.19999999999999989e192

    1. Initial program 98.0%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in y around inf 59.9%

      \[\leadsto \color{blue}{\frac{x \cdot y}{z}} \]
    3. Step-by-step derivation
      1. associate-*r/74.2%

        \[\leadsto \color{blue}{x \cdot \frac{y}{z}} \]
    4. Simplified74.2%

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

    if -9.2000000000000006e96 < z < -7e6

    1. Initial program 99.5%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around inf 88.1%

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

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

        \[\leadsto \color{blue}{\frac{x}{z} \cdot \left(y - -1 \cdot t\right)} \]
      3. cancel-sign-sub-inv88.0%

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

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

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

        \[\leadsto \frac{x}{z} \cdot \color{blue}{\left(t + y\right)} \]
    4. Simplified88.0%

      \[\leadsto \color{blue}{\frac{x}{z} \cdot \left(t + y\right)} \]
    5. Taylor expanded in t around inf 73.2%

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

        \[\leadsto \color{blue}{\frac{t}{\frac{z}{x}}} \]
    7. Simplified78.2%

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

    if -7e6 < z < 7e17

    1. Initial program 92.1%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in y around inf 67.2%

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

        \[\leadsto \color{blue}{\frac{x}{\frac{z}{y}}} \]
      2. associate-/r/71.7%

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

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

    if 7e17 < z < 1.69999999999999993e118

    1. Initial program 99.8%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around inf 92.4%

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

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

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

        \[\leadsto \frac{x}{z} \cdot \color{blue}{\left(y + \left(--1\right) \cdot t\right)} \]
      4. metadata-eval96.1%

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

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

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

      \[\leadsto \color{blue}{\frac{x}{z} \cdot \left(t + y\right)} \]
    5. Taylor expanded in t around inf 68.7%

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

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

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

    if 4.19999999999999989e192 < z

    1. Initial program 99.8%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around inf 84.8%

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

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

        \[\leadsto \color{blue}{\frac{x}{z} \cdot \left(y - -1 \cdot t\right)} \]
      3. cancel-sign-sub-inv62.9%

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

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

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

        \[\leadsto \frac{x}{z} \cdot \color{blue}{\left(t + y\right)} \]
    4. Simplified62.9%

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

        \[\leadsto \color{blue}{\left(t + y\right) \cdot \frac{x}{z}} \]
      2. clear-num62.8%

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

        \[\leadsto \color{blue}{\frac{t + y}{\frac{z}{x}}} \]
      4. +-commutative62.9%

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

      \[\leadsto \color{blue}{\frac{y + t}{\frac{z}{x}}} \]
    7. Step-by-step derivation
      1. associate-/r/99.8%

        \[\leadsto \color{blue}{\frac{y + t}{z} \cdot x} \]
    8. Simplified99.8%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -9.2 \cdot 10^{+96}:\\ \;\;\;\;x \cdot \frac{y}{z}\\ \mathbf{elif}\;z \leq -7000000:\\ \;\;\;\;\frac{t}{\frac{z}{x}}\\ \mathbf{elif}\;z \leq 7 \cdot 10^{+17}:\\ \;\;\;\;y \cdot \frac{x}{z}\\ \mathbf{elif}\;z \leq 1.7 \cdot 10^{+118}:\\ \;\;\;\;t \cdot \frac{x}{z}\\ \mathbf{elif}\;z \leq 4.2 \cdot 10^{+192}:\\ \;\;\;\;x \cdot \frac{y}{z}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \frac{t}{z}\\ \end{array} \]

Alternative 5: 64.2% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x \cdot \frac{y}{z}\\ t_2 := \frac{x}{\frac{z}{t}}\\ \mathbf{if}\;z \leq -1.9 \cdot 10^{+98}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -11200000:\\ \;\;\;\;t_2\\ \mathbf{elif}\;z \leq 1.25 \cdot 10^{+18}:\\ \;\;\;\;y \cdot \frac{x}{z}\\ \mathbf{elif}\;z \leq 2.1 \cdot 10^{+114}:\\ \;\;\;\;t \cdot \frac{x}{z}\\ \mathbf{elif}\;z \leq 8 \cdot 10^{+191}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (* x (/ y z))) (t_2 (/ x (/ z t))))
   (if (<= z -1.9e+98)
     t_1
     (if (<= z -11200000.0)
       t_2
       (if (<= z 1.25e+18)
         (* y (/ x z))
         (if (<= z 2.1e+114) (* t (/ x z)) (if (<= z 8e+191) t_1 t_2)))))))
double code(double x, double y, double z, double t) {
	double t_1 = x * (y / z);
	double t_2 = x / (z / t);
	double tmp;
	if (z <= -1.9e+98) {
		tmp = t_1;
	} else if (z <= -11200000.0) {
		tmp = t_2;
	} else if (z <= 1.25e+18) {
		tmp = y * (x / z);
	} else if (z <= 2.1e+114) {
		tmp = t * (x / z);
	} else if (z <= 8e+191) {
		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 / z)
    t_2 = x / (z / t)
    if (z <= (-1.9d+98)) then
        tmp = t_1
    else if (z <= (-11200000.0d0)) then
        tmp = t_2
    else if (z <= 1.25d+18) then
        tmp = y * (x / z)
    else if (z <= 2.1d+114) then
        tmp = t * (x / z)
    else if (z <= 8d+191) 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 / z);
	double t_2 = x / (z / t);
	double tmp;
	if (z <= -1.9e+98) {
		tmp = t_1;
	} else if (z <= -11200000.0) {
		tmp = t_2;
	} else if (z <= 1.25e+18) {
		tmp = y * (x / z);
	} else if (z <= 2.1e+114) {
		tmp = t * (x / z);
	} else if (z <= 8e+191) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = x * (y / z)
	t_2 = x / (z / t)
	tmp = 0
	if z <= -1.9e+98:
		tmp = t_1
	elif z <= -11200000.0:
		tmp = t_2
	elif z <= 1.25e+18:
		tmp = y * (x / z)
	elif z <= 2.1e+114:
		tmp = t * (x / z)
	elif z <= 8e+191:
		tmp = t_1
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t)
	t_1 = Float64(x * Float64(y / z))
	t_2 = Float64(x / Float64(z / t))
	tmp = 0.0
	if (z <= -1.9e+98)
		tmp = t_1;
	elseif (z <= -11200000.0)
		tmp = t_2;
	elseif (z <= 1.25e+18)
		tmp = Float64(y * Float64(x / z));
	elseif (z <= 2.1e+114)
		tmp = Float64(t * Float64(x / z));
	elseif (z <= 8e+191)
		tmp = t_1;
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = x * (y / z);
	t_2 = x / (z / t);
	tmp = 0.0;
	if (z <= -1.9e+98)
		tmp = t_1;
	elseif (z <= -11200000.0)
		tmp = t_2;
	elseif (z <= 1.25e+18)
		tmp = y * (x / z);
	elseif (z <= 2.1e+114)
		tmp = t * (x / z);
	elseif (z <= 8e+191)
		tmp = t_1;
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x * N[(y / z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x / N[(z / t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.9e+98], t$95$1, If[LessEqual[z, -11200000.0], t$95$2, If[LessEqual[z, 1.25e+18], N[(y * N[(x / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.1e+114], N[(t * N[(x / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 8e+191], t$95$1, t$95$2]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x \cdot \frac{y}{z}\\
t_2 := \frac{x}{\frac{z}{t}}\\
\mathbf{if}\;z \leq -1.9 \cdot 10^{+98}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq -11200000:\\
\;\;\;\;t_2\\

\mathbf{elif}\;z \leq 1.25 \cdot 10^{+18}:\\
\;\;\;\;y \cdot \frac{x}{z}\\

\mathbf{elif}\;z \leq 2.1 \cdot 10^{+114}:\\
\;\;\;\;t \cdot \frac{x}{z}\\

\mathbf{elif}\;z \leq 8 \cdot 10^{+191}:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -1.89999999999999995e98 or 2.1e114 < z < 8.00000000000000058e191

    1. Initial program 98.0%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in y around inf 59.9%

      \[\leadsto \color{blue}{\frac{x \cdot y}{z}} \]
    3. Step-by-step derivation
      1. associate-*r/74.2%

        \[\leadsto \color{blue}{x \cdot \frac{y}{z}} \]
    4. Simplified74.2%

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

    if -1.89999999999999995e98 < z < -1.12e7 or 8.00000000000000058e191 < z

    1. Initial program 99.6%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around inf 86.2%

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

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

        \[\leadsto \color{blue}{\frac{x}{z} \cdot \left(y - -1 \cdot t\right)} \]
      3. cancel-sign-sub-inv73.4%

        \[\leadsto \frac{x}{z} \cdot \color{blue}{\left(y + \left(--1\right) \cdot t\right)} \]
      4. metadata-eval73.4%

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

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{t + y}{\frac{z}{x}}} \]
      4. +-commutative73.4%

        \[\leadsto \frac{\color{blue}{y + t}}{\frac{z}{x}} \]
    6. Applied egg-rr73.4%

      \[\leadsto \color{blue}{\frac{y + t}{\frac{z}{x}}} \]
    7. Step-by-step derivation
      1. associate-/r/97.0%

        \[\leadsto \color{blue}{\frac{y + t}{z} \cdot x} \]
    8. Simplified97.0%

      \[\leadsto \color{blue}{\frac{y + t}{z} \cdot x} \]
    9. Step-by-step derivation
      1. *-commutative97.0%

        \[\leadsto \color{blue}{x \cdot \frac{y + t}{z}} \]
      2. clear-num97.0%

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

        \[\leadsto \color{blue}{\frac{x}{\frac{z}{y + t}}} \]
    10. Applied egg-rr97.2%

      \[\leadsto \color{blue}{\frac{x}{\frac{z}{y + t}}} \]
    11. Taylor expanded in y around 0 73.6%

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

    if -1.12e7 < z < 1.25e18

    1. Initial program 92.1%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in y around inf 67.2%

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

        \[\leadsto \color{blue}{\frac{x}{\frac{z}{y}}} \]
      2. associate-/r/71.7%

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

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

    if 1.25e18 < z < 2.1e114

    1. Initial program 99.8%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around inf 92.4%

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

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

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

        \[\leadsto \frac{x}{z} \cdot \color{blue}{\left(y + \left(--1\right) \cdot t\right)} \]
      4. metadata-eval96.1%

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

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

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

      \[\leadsto \color{blue}{\frac{x}{z} \cdot \left(t + y\right)} \]
    5. Taylor expanded in t around inf 68.7%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.9 \cdot 10^{+98}:\\ \;\;\;\;x \cdot \frac{y}{z}\\ \mathbf{elif}\;z \leq -11200000:\\ \;\;\;\;\frac{x}{\frac{z}{t}}\\ \mathbf{elif}\;z \leq 1.25 \cdot 10^{+18}:\\ \;\;\;\;y \cdot \frac{x}{z}\\ \mathbf{elif}\;z \leq 2.1 \cdot 10^{+114}:\\ \;\;\;\;t \cdot \frac{x}{z}\\ \mathbf{elif}\;z \leq 8 \cdot 10^{+191}:\\ \;\;\;\;x \cdot \frac{y}{z}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{\frac{z}{t}}\\ \end{array} \]

Alternative 6: 74.5% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x \cdot \frac{y}{z}\\ t_2 := \frac{x}{\frac{z}{t}}\\ \mathbf{if}\;z \leq -2.02 \cdot 10^{+96}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -3700000:\\ \;\;\;\;t_2\\ \mathbf{elif}\;z \leq 2.9 \cdot 10^{+17}:\\ \;\;\;\;x \cdot \left(\frac{y}{z} - t\right)\\ \mathbf{elif}\;z \leq 7.6 \cdot 10^{+113}:\\ \;\;\;\;t \cdot \frac{x}{z}\\ \mathbf{elif}\;z \leq 4.2 \cdot 10^{+192}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (* x (/ y z))) (t_2 (/ x (/ z t))))
   (if (<= z -2.02e+96)
     t_1
     (if (<= z -3700000.0)
       t_2
       (if (<= z 2.9e+17)
         (* x (- (/ y z) t))
         (if (<= z 7.6e+113) (* t (/ x z)) (if (<= z 4.2e+192) t_1 t_2)))))))
double code(double x, double y, double z, double t) {
	double t_1 = x * (y / z);
	double t_2 = x / (z / t);
	double tmp;
	if (z <= -2.02e+96) {
		tmp = t_1;
	} else if (z <= -3700000.0) {
		tmp = t_2;
	} else if (z <= 2.9e+17) {
		tmp = x * ((y / z) - t);
	} else if (z <= 7.6e+113) {
		tmp = t * (x / z);
	} else if (z <= 4.2e+192) {
		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 / z)
    t_2 = x / (z / t)
    if (z <= (-2.02d+96)) then
        tmp = t_1
    else if (z <= (-3700000.0d0)) then
        tmp = t_2
    else if (z <= 2.9d+17) then
        tmp = x * ((y / z) - t)
    else if (z <= 7.6d+113) then
        tmp = t * (x / z)
    else if (z <= 4.2d+192) 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 / z);
	double t_2 = x / (z / t);
	double tmp;
	if (z <= -2.02e+96) {
		tmp = t_1;
	} else if (z <= -3700000.0) {
		tmp = t_2;
	} else if (z <= 2.9e+17) {
		tmp = x * ((y / z) - t);
	} else if (z <= 7.6e+113) {
		tmp = t * (x / z);
	} else if (z <= 4.2e+192) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = x * (y / z)
	t_2 = x / (z / t)
	tmp = 0
	if z <= -2.02e+96:
		tmp = t_1
	elif z <= -3700000.0:
		tmp = t_2
	elif z <= 2.9e+17:
		tmp = x * ((y / z) - t)
	elif z <= 7.6e+113:
		tmp = t * (x / z)
	elif z <= 4.2e+192:
		tmp = t_1
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t)
	t_1 = Float64(x * Float64(y / z))
	t_2 = Float64(x / Float64(z / t))
	tmp = 0.0
	if (z <= -2.02e+96)
		tmp = t_1;
	elseif (z <= -3700000.0)
		tmp = t_2;
	elseif (z <= 2.9e+17)
		tmp = Float64(x * Float64(Float64(y / z) - t));
	elseif (z <= 7.6e+113)
		tmp = Float64(t * Float64(x / z));
	elseif (z <= 4.2e+192)
		tmp = t_1;
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = x * (y / z);
	t_2 = x / (z / t);
	tmp = 0.0;
	if (z <= -2.02e+96)
		tmp = t_1;
	elseif (z <= -3700000.0)
		tmp = t_2;
	elseif (z <= 2.9e+17)
		tmp = x * ((y / z) - t);
	elseif (z <= 7.6e+113)
		tmp = t * (x / z);
	elseif (z <= 4.2e+192)
		tmp = t_1;
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x * N[(y / z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x / N[(z / t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2.02e+96], t$95$1, If[LessEqual[z, -3700000.0], t$95$2, If[LessEqual[z, 2.9e+17], N[(x * N[(N[(y / z), $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 7.6e+113], N[(t * N[(x / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.2e+192], t$95$1, t$95$2]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x \cdot \frac{y}{z}\\
t_2 := \frac{x}{\frac{z}{t}}\\
\mathbf{if}\;z \leq -2.02 \cdot 10^{+96}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq -3700000:\\
\;\;\;\;t_2\\

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

\mathbf{elif}\;z \leq 7.6 \cdot 10^{+113}:\\
\;\;\;\;t \cdot \frac{x}{z}\\

\mathbf{elif}\;z \leq 4.2 \cdot 10^{+192}:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -2.02000000000000006e96 or 7.6000000000000007e113 < z < 4.19999999999999989e192

    1. Initial program 98.0%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in y around inf 59.9%

      \[\leadsto \color{blue}{\frac{x \cdot y}{z}} \]
    3. Step-by-step derivation
      1. associate-*r/74.2%

        \[\leadsto \color{blue}{x \cdot \frac{y}{z}} \]
    4. Simplified74.2%

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

    if -2.02000000000000006e96 < z < -3.7e6 or 4.19999999999999989e192 < z

    1. Initial program 99.6%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around inf 86.2%

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

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

        \[\leadsto \color{blue}{\frac{x}{z} \cdot \left(y - -1 \cdot t\right)} \]
      3. cancel-sign-sub-inv73.4%

        \[\leadsto \frac{x}{z} \cdot \color{blue}{\left(y + \left(--1\right) \cdot t\right)} \]
      4. metadata-eval73.4%

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

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{t + y}{\frac{z}{x}}} \]
      4. +-commutative73.4%

        \[\leadsto \frac{\color{blue}{y + t}}{\frac{z}{x}} \]
    6. Applied egg-rr73.4%

      \[\leadsto \color{blue}{\frac{y + t}{\frac{z}{x}}} \]
    7. Step-by-step derivation
      1. associate-/r/97.0%

        \[\leadsto \color{blue}{\frac{y + t}{z} \cdot x} \]
    8. Simplified97.0%

      \[\leadsto \color{blue}{\frac{y + t}{z} \cdot x} \]
    9. Step-by-step derivation
      1. *-commutative97.0%

        \[\leadsto \color{blue}{x \cdot \frac{y + t}{z}} \]
      2. clear-num97.0%

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

        \[\leadsto \color{blue}{\frac{x}{\frac{z}{y + t}}} \]
    10. Applied egg-rr97.2%

      \[\leadsto \color{blue}{\frac{x}{\frac{z}{y + t}}} \]
    11. Taylor expanded in y around 0 73.6%

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

    if -3.7e6 < z < 2.9e17

    1. Initial program 92.1%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around 0 89.8%

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

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

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

        \[\leadsto \color{blue}{\frac{y}{z} \cdot x} + -1 \cdot \left(t \cdot x\right) \]
      4. associate-*r*87.4%

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

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

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

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

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

    if 2.9e17 < z < 7.6000000000000007e113

    1. Initial program 99.8%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around inf 92.4%

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

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

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

        \[\leadsto \frac{x}{z} \cdot \color{blue}{\left(y + \left(--1\right) \cdot t\right)} \]
      4. metadata-eval96.1%

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

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

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

      \[\leadsto \color{blue}{\frac{x}{z} \cdot \left(t + y\right)} \]
    5. Taylor expanded in t around inf 68.7%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.02 \cdot 10^{+96}:\\ \;\;\;\;x \cdot \frac{y}{z}\\ \mathbf{elif}\;z \leq -3700000:\\ \;\;\;\;\frac{x}{\frac{z}{t}}\\ \mathbf{elif}\;z \leq 2.9 \cdot 10^{+17}:\\ \;\;\;\;x \cdot \left(\frac{y}{z} - t\right)\\ \mathbf{elif}\;z \leq 7.6 \cdot 10^{+113}:\\ \;\;\;\;t \cdot \frac{x}{z}\\ \mathbf{elif}\;z \leq 4.2 \cdot 10^{+192}:\\ \;\;\;\;x \cdot \frac{y}{z}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{\frac{z}{t}}\\ \end{array} \]

Alternative 7: 74.5% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -5.3 \cdot 10^{+160} \lor \neg \left(t \leq -9.6 \cdot 10^{+105}\right) \land \left(t \leq -3.3 \cdot 10^{+51} \lor \neg \left(t \leq 4.8 \cdot 10^{+53}\right)\right):\\ \;\;\;\;x \cdot \frac{t}{z + -1}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{\frac{z}{y}}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (or (<= t -5.3e+160)
         (and (not (<= t -9.6e+105))
              (or (<= t -3.3e+51) (not (<= t 4.8e+53)))))
   (* x (/ t (+ z -1.0)))
   (/ x (/ z y))))
double code(double x, double y, double z, double t) {
	double tmp;
	if ((t <= -5.3e+160) || (!(t <= -9.6e+105) && ((t <= -3.3e+51) || !(t <= 4.8e+53)))) {
		tmp = x * (t / (z + -1.0));
	} else {
		tmp = 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) :: tmp
    if ((t <= (-5.3d+160)) .or. (.not. (t <= (-9.6d+105))) .and. (t <= (-3.3d+51)) .or. (.not. (t <= 4.8d+53))) then
        tmp = x * (t / (z + (-1.0d0)))
    else
        tmp = x / (z / y)
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if ((t <= -5.3e+160) || (!(t <= -9.6e+105) && ((t <= -3.3e+51) || !(t <= 4.8e+53)))) {
		tmp = x * (t / (z + -1.0));
	} else {
		tmp = x / (z / y);
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if (t <= -5.3e+160) or (not (t <= -9.6e+105) and ((t <= -3.3e+51) or not (t <= 4.8e+53))):
		tmp = x * (t / (z + -1.0))
	else:
		tmp = x / (z / y)
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if ((t <= -5.3e+160) || (!(t <= -9.6e+105) && ((t <= -3.3e+51) || !(t <= 4.8e+53))))
		tmp = Float64(x * Float64(t / Float64(z + -1.0)));
	else
		tmp = Float64(x / Float64(z / y));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if ((t <= -5.3e+160) || (~((t <= -9.6e+105)) && ((t <= -3.3e+51) || ~((t <= 4.8e+53)))))
		tmp = x * (t / (z + -1.0));
	else
		tmp = x / (z / y);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[Or[LessEqual[t, -5.3e+160], And[N[Not[LessEqual[t, -9.6e+105]], $MachinePrecision], Or[LessEqual[t, -3.3e+51], N[Not[LessEqual[t, 4.8e+53]], $MachinePrecision]]]], N[(x * N[(t / N[(z + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(z / y), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -5.3 \cdot 10^{+160} \lor \neg \left(t \leq -9.6 \cdot 10^{+105}\right) \land \left(t \leq -3.3 \cdot 10^{+51} \lor \neg \left(t \leq 4.8 \cdot 10^{+53}\right)\right):\\
\;\;\;\;x \cdot \frac{t}{z + -1}\\

\mathbf{else}:\\
\;\;\;\;\frac{x}{\frac{z}{y}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -5.3000000000000001e160 or -9.599999999999999e105 < t < -3.2999999999999997e51 or 4.8e53 < t

    1. Initial program 95.4%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in y around 0 73.4%

      \[\leadsto \color{blue}{-1 \cdot \frac{t \cdot x}{1 - z}} \]
    3. Step-by-step derivation
      1. associate-*r/73.4%

        \[\leadsto \color{blue}{\frac{-1 \cdot \left(t \cdot x\right)}{1 - z}} \]
      2. mul-1-neg73.4%

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

        \[\leadsto \frac{-\color{blue}{x \cdot t}}{1 - z} \]
      4. distribute-rgt-neg-in73.4%

        \[\leadsto \frac{\color{blue}{x \cdot \left(-t\right)}}{1 - z} \]
      5. associate-*r/77.6%

        \[\leadsto \color{blue}{x \cdot \frac{-t}{1 - z}} \]
      6. distribute-frac-neg77.6%

        \[\leadsto x \cdot \color{blue}{\left(-\frac{t}{1 - z}\right)} \]
      7. mul-1-neg77.6%

        \[\leadsto x \cdot \color{blue}{\left(-1 \cdot \frac{t}{1 - z}\right)} \]
      8. *-commutative77.6%

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

        \[\leadsto x \cdot \color{blue}{\frac{t \cdot -1}{1 - z}} \]
      10. associate-*r/77.6%

        \[\leadsto x \cdot \color{blue}{\left(t \cdot \frac{-1}{1 - z}\right)} \]
      11. metadata-eval77.6%

        \[\leadsto x \cdot \left(t \cdot \frac{\color{blue}{\frac{1}{-1}}}{1 - z}\right) \]
      12. associate-/r*77.6%

        \[\leadsto x \cdot \left(t \cdot \color{blue}{\frac{1}{-1 \cdot \left(1 - z\right)}}\right) \]
      13. neg-mul-177.6%

        \[\leadsto x \cdot \left(t \cdot \frac{1}{\color{blue}{-\left(1 - z\right)}}\right) \]
      14. associate-*r/77.6%

        \[\leadsto x \cdot \color{blue}{\frac{t \cdot 1}{-\left(1 - z\right)}} \]
      15. *-rgt-identity77.6%

        \[\leadsto x \cdot \frac{\color{blue}{t}}{-\left(1 - z\right)} \]
      16. neg-sub077.6%

        \[\leadsto x \cdot \frac{t}{\color{blue}{0 - \left(1 - z\right)}} \]
      17. associate--r-77.6%

        \[\leadsto x \cdot \frac{t}{\color{blue}{\left(0 - 1\right) + z}} \]
      18. metadata-eval77.6%

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

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

    if -5.3000000000000001e160 < t < -9.599999999999999e105 or -3.2999999999999997e51 < t < 4.8e53

    1. Initial program 95.4%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in y around inf 79.3%

      \[\leadsto \color{blue}{\frac{x \cdot y}{z}} \]
    3. Step-by-step derivation
      1. associate-*r/86.2%

        \[\leadsto \color{blue}{x \cdot \frac{y}{z}} \]
    4. Simplified86.2%

      \[\leadsto \color{blue}{x \cdot \frac{y}{z}} \]
    5. Step-by-step derivation
      1. clear-num86.1%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -5.3 \cdot 10^{+160} \lor \neg \left(t \leq -9.6 \cdot 10^{+105}\right) \land \left(t \leq -3.3 \cdot 10^{+51} \lor \neg \left(t \leq 4.8 \cdot 10^{+53}\right)\right):\\ \;\;\;\;x \cdot \frac{t}{z + -1}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{\frac{z}{y}}\\ \end{array} \]

Alternative 8: 65.2% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -3.3 \cdot 10^{+263} \lor \neg \left(t \leq -3.45 \cdot 10^{+106}\right) \land \left(t \leq -7.8 \cdot 10^{+51} \lor \neg \left(t \leq 7.5 \cdot 10^{+54}\right)\right):\\ \;\;\;\;x \cdot \frac{t}{z}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \frac{y}{z}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (or (<= t -3.3e+263)
         (and (not (<= t -3.45e+106))
              (or (<= t -7.8e+51) (not (<= t 7.5e+54)))))
   (* x (/ t z))
   (* x (/ y z))))
double code(double x, double y, double z, double t) {
	double tmp;
	if ((t <= -3.3e+263) || (!(t <= -3.45e+106) && ((t <= -7.8e+51) || !(t <= 7.5e+54)))) {
		tmp = x * (t / z);
	} else {
		tmp = x * (y / 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) :: tmp
    if ((t <= (-3.3d+263)) .or. (.not. (t <= (-3.45d+106))) .and. (t <= (-7.8d+51)) .or. (.not. (t <= 7.5d+54))) then
        tmp = x * (t / z)
    else
        tmp = x * (y / z)
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if ((t <= -3.3e+263) || (!(t <= -3.45e+106) && ((t <= -7.8e+51) || !(t <= 7.5e+54)))) {
		tmp = x * (t / z);
	} else {
		tmp = x * (y / z);
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if (t <= -3.3e+263) or (not (t <= -3.45e+106) and ((t <= -7.8e+51) or not (t <= 7.5e+54))):
		tmp = x * (t / z)
	else:
		tmp = x * (y / z)
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if ((t <= -3.3e+263) || (!(t <= -3.45e+106) && ((t <= -7.8e+51) || !(t <= 7.5e+54))))
		tmp = Float64(x * Float64(t / z));
	else
		tmp = Float64(x * Float64(y / z));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if ((t <= -3.3e+263) || (~((t <= -3.45e+106)) && ((t <= -7.8e+51) || ~((t <= 7.5e+54)))))
		tmp = x * (t / z);
	else
		tmp = x * (y / z);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[Or[LessEqual[t, -3.3e+263], And[N[Not[LessEqual[t, -3.45e+106]], $MachinePrecision], Or[LessEqual[t, -7.8e+51], N[Not[LessEqual[t, 7.5e+54]], $MachinePrecision]]]], N[(x * N[(t / z), $MachinePrecision]), $MachinePrecision], N[(x * N[(y / z), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.3 \cdot 10^{+263} \lor \neg \left(t \leq -3.45 \cdot 10^{+106}\right) \land \left(t \leq -7.8 \cdot 10^{+51} \lor \neg \left(t \leq 7.5 \cdot 10^{+54}\right)\right):\\
\;\;\;\;x \cdot \frac{t}{z}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -3.3e263 or -3.4499999999999999e106 < t < -7.79999999999999968e51 or 7.50000000000000042e54 < t

    1. Initial program 95.7%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around inf 65.6%

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

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

        \[\leadsto \color{blue}{\frac{x}{z} \cdot \left(y - -1 \cdot t\right)} \]
      3. cancel-sign-sub-inv55.7%

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

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

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

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

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

        \[\leadsto \color{blue}{\left(t + y\right) \cdot \frac{x}{z}} \]
      2. clear-num54.9%

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

        \[\leadsto \color{blue}{\frac{t + y}{\frac{z}{x}}} \]
      4. +-commutative54.9%

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

      \[\leadsto \color{blue}{\frac{y + t}{\frac{z}{x}}} \]
    7. Step-by-step derivation
      1. associate-/r/69.5%

        \[\leadsto \color{blue}{\frac{y + t}{z} \cdot x} \]
    8. Simplified69.5%

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

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

    if -3.3e263 < t < -3.4499999999999999e106 or -7.79999999999999968e51 < t < 7.50000000000000042e54

    1. Initial program 95.3%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in y around inf 76.1%

      \[\leadsto \color{blue}{\frac{x \cdot y}{z}} \]
    3. Step-by-step derivation
      1. associate-*r/82.3%

        \[\leadsto \color{blue}{x \cdot \frac{y}{z}} \]
    4. Simplified82.3%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -3.3 \cdot 10^{+263} \lor \neg \left(t \leq -3.45 \cdot 10^{+106}\right) \land \left(t \leq -7.8 \cdot 10^{+51} \lor \neg \left(t \leq 7.5 \cdot 10^{+54}\right)\right):\\ \;\;\;\;x \cdot \frac{t}{z}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \frac{y}{z}\\ \end{array} \]

Alternative 9: 64.0% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x \cdot \left(-t\right)\\ t_2 := x \cdot \frac{y}{z}\\ \mathbf{if}\;t \leq -2.7 \cdot 10^{+229}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;t \leq 9.8 \cdot 10^{+54}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;t \leq 3.45 \cdot 10^{+106}:\\ \;\;\;\;t \cdot \frac{x}{z}\\ \mathbf{elif}\;t \leq 1.15 \cdot 10^{+171}:\\ \;\;\;\;t_2\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (* x (- t))) (t_2 (* x (/ y z))))
   (if (<= t -2.7e+229)
     t_1
     (if (<= t 9.8e+54)
       t_2
       (if (<= t 3.45e+106) (* t (/ x z)) (if (<= t 1.15e+171) t_2 t_1))))))
double code(double x, double y, double z, double t) {
	double t_1 = x * -t;
	double t_2 = x * (y / z);
	double tmp;
	if (t <= -2.7e+229) {
		tmp = t_1;
	} else if (t <= 9.8e+54) {
		tmp = t_2;
	} else if (t <= 3.45e+106) {
		tmp = t * (x / z);
	} else if (t <= 1.15e+171) {
		tmp = t_2;
	} 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) :: t_2
    real(8) :: tmp
    t_1 = x * -t
    t_2 = x * (y / z)
    if (t <= (-2.7d+229)) then
        tmp = t_1
    else if (t <= 9.8d+54) then
        tmp = t_2
    else if (t <= 3.45d+106) then
        tmp = t * (x / z)
    else if (t <= 1.15d+171) then
        tmp = t_2
    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 = x * -t;
	double t_2 = x * (y / z);
	double tmp;
	if (t <= -2.7e+229) {
		tmp = t_1;
	} else if (t <= 9.8e+54) {
		tmp = t_2;
	} else if (t <= 3.45e+106) {
		tmp = t * (x / z);
	} else if (t <= 1.15e+171) {
		tmp = t_2;
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = x * -t
	t_2 = x * (y / z)
	tmp = 0
	if t <= -2.7e+229:
		tmp = t_1
	elif t <= 9.8e+54:
		tmp = t_2
	elif t <= 3.45e+106:
		tmp = t * (x / z)
	elif t <= 1.15e+171:
		tmp = t_2
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t)
	t_1 = Float64(x * Float64(-t))
	t_2 = Float64(x * Float64(y / z))
	tmp = 0.0
	if (t <= -2.7e+229)
		tmp = t_1;
	elseif (t <= 9.8e+54)
		tmp = t_2;
	elseif (t <= 3.45e+106)
		tmp = Float64(t * Float64(x / z));
	elseif (t <= 1.15e+171)
		tmp = t_2;
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = x * -t;
	t_2 = x * (y / z);
	tmp = 0.0;
	if (t <= -2.7e+229)
		tmp = t_1;
	elseif (t <= 9.8e+54)
		tmp = t_2;
	elseif (t <= 3.45e+106)
		tmp = t * (x / z);
	elseif (t <= 1.15e+171)
		tmp = t_2;
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x * (-t)), $MachinePrecision]}, Block[{t$95$2 = N[(x * N[(y / z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -2.7e+229], t$95$1, If[LessEqual[t, 9.8e+54], t$95$2, If[LessEqual[t, 3.45e+106], N[(t * N[(x / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.15e+171], t$95$2, t$95$1]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;t \leq 9.8 \cdot 10^{+54}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;t \leq 3.45 \cdot 10^{+106}:\\
\;\;\;\;t \cdot \frac{x}{z}\\

\mathbf{elif}\;t \leq 1.15 \cdot 10^{+171}:\\
\;\;\;\;t_2\\

\mathbf{else}:\\
\;\;\;\;t_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -2.7e229 or 1.15000000000000009e171 < t

    1. Initial program 93.7%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around 0 54.4%

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

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

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

        \[\leadsto \color{blue}{\frac{y}{z} \cdot x} + -1 \cdot \left(t \cdot x\right) \]
      4. associate-*r*48.3%

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

        \[\leadsto \frac{y}{z} \cdot x + \color{blue}{\left(-t\right)} \cdot x \]
      6. distribute-rgt-out50.0%

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

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

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

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

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

        \[\leadsto \color{blue}{\left(-t\right)} \cdot x \]
      3. *-commutative43.3%

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

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

    if -2.7e229 < t < 9.80000000000000002e54 or 3.4499999999999999e106 < t < 1.15000000000000009e171

    1. Initial program 95.6%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in y around inf 74.3%

      \[\leadsto \color{blue}{\frac{x \cdot y}{z}} \]
    3. Step-by-step derivation
      1. associate-*r/80.1%

        \[\leadsto \color{blue}{x \cdot \frac{y}{z}} \]
    4. Simplified80.1%

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

    if 9.80000000000000002e54 < t < 3.4499999999999999e106

    1. Initial program 99.5%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around inf 84.6%

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

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

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

        \[\leadsto \frac{x}{z} \cdot \color{blue}{\left(y + \left(--1\right) \cdot t\right)} \]
      4. metadata-eval78.1%

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

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

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

      \[\leadsto \color{blue}{\frac{x}{z} \cdot \left(t + y\right)} \]
    5. Taylor expanded in t around inf 54.4%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -2.7 \cdot 10^{+229}:\\ \;\;\;\;x \cdot \left(-t\right)\\ \mathbf{elif}\;t \leq 9.8 \cdot 10^{+54}:\\ \;\;\;\;x \cdot \frac{y}{z}\\ \mathbf{elif}\;t \leq 3.45 \cdot 10^{+106}:\\ \;\;\;\;t \cdot \frac{x}{z}\\ \mathbf{elif}\;t \leq 1.15 \cdot 10^{+171}:\\ \;\;\;\;x \cdot \frac{y}{z}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(-t\right)\\ \end{array} \]

Alternative 10: 93.6% accurate, 1.0× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -440 \lor \neg \left(z \leq 1\right):\\
\;\;\;\;x \cdot \frac{y + t}{z}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -440 or 1 < z

    1. Initial program 99.0%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around inf 97.8%

      \[\leadsto x \cdot \color{blue}{\frac{y - -1 \cdot t}{z}} \]
    3. Step-by-step derivation
      1. cancel-sign-sub-inv97.8%

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

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

        \[\leadsto x \cdot \frac{y + \color{blue}{t}}{z} \]
      4. +-commutative97.8%

        \[\leadsto x \cdot \frac{\color{blue}{t + y}}{z} \]
    4. Simplified97.8%

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

    if -440 < z < 1

    1. Initial program 91.8%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around 0 90.1%

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

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

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

        \[\leadsto \color{blue}{\frac{y}{z} \cdot x} + -1 \cdot \left(t \cdot x\right) \]
      4. associate-*r*87.6%

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

        \[\leadsto \frac{y}{z} \cdot x + \color{blue}{\left(-t\right)} \cdot x \]
      6. distribute-rgt-out90.7%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -440 \lor \neg \left(z \leq 1\right):\\ \;\;\;\;x \cdot \frac{y + t}{z}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(\frac{y}{z} - t\right)\\ \end{array} \]

Alternative 11: 92.8% accurate, 1.0× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.8 \cdot 10^{-27} \lor \neg \left(z \leq 1\right):\\
\;\;\;\;\frac{x}{\frac{z}{y + t}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -2.8e-27 or 1 < z

    1. Initial program 98.4%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around inf 85.5%

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

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

        \[\leadsto \color{blue}{\frac{x}{z} \cdot \left(y - -1 \cdot t\right)} \]
      3. cancel-sign-sub-inv80.6%

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\frac{y + t}{\frac{z}{x}}} \]
    7. Step-by-step derivation
      1. associate-/r/96.1%

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

      \[\leadsto \color{blue}{\frac{y + t}{z} \cdot x} \]
    9. Step-by-step derivation
      1. *-commutative96.1%

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

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

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

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

    if -2.8e-27 < z < 1

    1. Initial program 91.7%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around 0 90.8%

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

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

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

        \[\leadsto \color{blue}{\frac{y}{z} \cdot x} + -1 \cdot \left(t \cdot x\right) \]
      4. associate-*r*88.7%

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.8 \cdot 10^{-27} \lor \neg \left(z \leq 1\right):\\ \;\;\;\;\frac{x}{\frac{z}{y + t}}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(\frac{y}{z} - t\right)\\ \end{array} \]

Alternative 12: 42.9% accurate, 1.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -0.00031 \lor \neg \left(z \leq 0.001\right):\\ \;\;\;\;t \cdot \frac{x}{z}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(-t\right)\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (or (<= z -0.00031) (not (<= z 0.001))) (* t (/ x z)) (* x (- t))))
double code(double x, double y, double z, double t) {
	double tmp;
	if ((z <= -0.00031) || !(z <= 0.001)) {
		tmp = t * (x / z);
	} else {
		tmp = x * -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 <= (-0.00031d0)) .or. (.not. (z <= 0.001d0))) then
        tmp = t * (x / z)
    else
        tmp = x * -t
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if ((z <= -0.00031) || !(z <= 0.001)) {
		tmp = t * (x / z);
	} else {
		tmp = x * -t;
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if (z <= -0.00031) or not (z <= 0.001):
		tmp = t * (x / z)
	else:
		tmp = x * -t
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if ((z <= -0.00031) || !(z <= 0.001))
		tmp = Float64(t * Float64(x / z));
	else
		tmp = Float64(x * Float64(-t));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if ((z <= -0.00031) || ~((z <= 0.001)))
		tmp = t * (x / z);
	else
		tmp = x * -t;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[Or[LessEqual[z, -0.00031], N[Not[LessEqual[z, 0.001]], $MachinePrecision]], N[(t * N[(x / z), $MachinePrecision]), $MachinePrecision], N[(x * (-t)), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -0.00031 \lor \neg \left(z \leq 0.001\right):\\
\;\;\;\;t \cdot \frac{x}{z}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -3.1e-4 or 1e-3 < z

    1. Initial program 99.0%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around inf 85.9%

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

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

        \[\leadsto \color{blue}{\frac{x}{z} \cdot \left(y - -1 \cdot t\right)} \]
      3. cancel-sign-sub-inv80.7%

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

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

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

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

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

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

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

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

    if -3.1e-4 < z < 1e-3

    1. Initial program 91.4%

      \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
    2. Taylor expanded in z around 0 89.8%

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

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

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

        \[\leadsto \color{blue}{\frac{y}{z} \cdot x} + -1 \cdot \left(t \cdot x\right) \]
      4. associate-*r*87.1%

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\left(-t\right)} \cdot x \]
      3. *-commutative38.4%

        \[\leadsto \color{blue}{x \cdot \left(-t\right)} \]
    7. Simplified38.4%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -0.00031 \lor \neg \left(z \leq 0.001\right):\\ \;\;\;\;t \cdot \frac{x}{z}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(-t\right)\\ \end{array} \]

Alternative 13: 23.0% accurate, 2.8× speedup?

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

\\
x \cdot \left(-t\right)
\end{array}
Derivation
  1. Initial program 95.4%

    \[x \cdot \left(\frac{y}{z} - \frac{t}{1 - z}\right) \]
  2. Taylor expanded in z around 0 60.5%

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

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

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

      \[\leadsto \color{blue}{\frac{y}{z} \cdot x} + -1 \cdot \left(t \cdot x\right) \]
    4. associate-*r*61.4%

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

      \[\leadsto \frac{y}{z} \cdot x + \color{blue}{\left(-t\right)} \cdot x \]
    6. distribute-rgt-out63.0%

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

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

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

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

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

      \[\leadsto \color{blue}{\left(-t\right)} \cdot x \]
    3. *-commutative26.0%

      \[\leadsto \color{blue}{x \cdot \left(-t\right)} \]
  7. Simplified26.0%

    \[\leadsto \color{blue}{x \cdot \left(-t\right)} \]
  8. Final simplification26.0%

    \[\leadsto x \cdot \left(-t\right) \]

Developer target: 94.8% accurate, 0.3× speedup?

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

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

\mathbf{elif}\;t_2 < 1.4133944927702302 \cdot 10^{-211}:\\
\;\;\;\;\frac{y \cdot x}{z} + \left(-\frac{t \cdot x}{1 - z}\right)\\

\mathbf{else}:\\
\;\;\;\;t_1\\


\end{array}
\end{array}

Reproduce

?
herbie shell --seed 2023275 
(FPCore (x y z t)
  :name "Numeric.SpecFunctions:invIncompleteBetaWorker from math-functions-0.1.5.2, C"
  :precision binary64

  :herbie-target
  (if (< (* x (- (/ y z) (/ t (- 1.0 z)))) -7.623226303312042e-196) (* x (- (/ y z) (* t (/ 1.0 (- 1.0 z))))) (if (< (* x (- (/ y z) (/ t (- 1.0 z)))) 1.4133944927702302e-211) (+ (/ (* y x) z) (- (/ (* t x) (- 1.0 z)))) (* x (- (/ y z) (* t (/ 1.0 (- 1.0 z)))))))

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