Data.Random.Distribution.Triangular:triangularCDF from random-fu-0.2.6.2, B

Percentage Accurate: 88.6% → 96.9%
Time: 12.9s
Alternatives: 19
Speedup: 1.0×

Specification

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

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

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

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

Alternative 1: 96.9% accurate, 1.0× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \frac{\frac{x}{t - z}}{y - z} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t) :precision binary64 (/ (/ x (- t z)) (- y z)))
assert(y < t);
double code(double x, double y, double z, double t) {
	return (x / (t - z)) / (y - z);
}
NOTE: y and t should be sorted in increasing order before calling this function.
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 - z)) / (y - z)
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	return (x / (t - z)) / (y - z);
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	return (x / (t - z)) / (y - z)
y, t = sort([y, t])
function code(x, y, z, t)
	return Float64(Float64(x / Float64(t - z)) / Float64(y - z))
end
y, t = num2cell(sort([y, t])){:}
function tmp = code(x, y, z, t)
	tmp = (x / (t - z)) / (y - z);
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := N[(N[(x / N[(t - z), $MachinePrecision]), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\frac{\frac{x}{t - z}}{y - z}
\end{array}
Derivation
  1. Initial program 89.7%

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

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

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

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

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

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

    \[\leadsto \color{blue}{\frac{\frac{x}{t - z}}{y - z}} \]
  6. Final simplification97.2%

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

Alternative 2: 81.6% accurate, 0.6× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \begin{array}{l} t_1 := \frac{-x}{z}\\ \mathbf{if}\;y \leq -1 \cdot 10^{+43}:\\ \;\;\;\;\frac{\frac{x}{y}}{t - z}\\ \mathbf{elif}\;y \leq -1.45 \cdot 10^{-12}:\\ \;\;\;\;\frac{t_1}{y - z}\\ \mathbf{elif}\;y \leq -3.5 \cdot 10^{-43}:\\ \;\;\;\;\frac{x}{\left(t - z\right) \cdot y}\\ \mathbf{elif}\;y \leq 1.3 \cdot 10^{-57}:\\ \;\;\;\;\frac{t_1}{t - z}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{t}}{y - z}\\ \end{array} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (/ (- x) z)))
   (if (<= y -1e+43)
     (/ (/ x y) (- t z))
     (if (<= y -1.45e-12)
       (/ t_1 (- y z))
       (if (<= y -3.5e-43)
         (/ x (* (- t z) y))
         (if (<= y 1.3e-57) (/ t_1 (- t z)) (/ (/ x t) (- y z))))))))
assert(y < t);
double code(double x, double y, double z, double t) {
	double t_1 = -x / z;
	double tmp;
	if (y <= -1e+43) {
		tmp = (x / y) / (t - z);
	} else if (y <= -1.45e-12) {
		tmp = t_1 / (y - z);
	} else if (y <= -3.5e-43) {
		tmp = x / ((t - z) * y);
	} else if (y <= 1.3e-57) {
		tmp = t_1 / (t - z);
	} else {
		tmp = (x / t) / (y - z);
	}
	return tmp;
}
NOTE: y and t should be sorted in increasing order before calling this function.
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 / z
    if (y <= (-1d+43)) then
        tmp = (x / y) / (t - z)
    else if (y <= (-1.45d-12)) then
        tmp = t_1 / (y - z)
    else if (y <= (-3.5d-43)) then
        tmp = x / ((t - z) * y)
    else if (y <= 1.3d-57) then
        tmp = t_1 / (t - z)
    else
        tmp = (x / t) / (y - z)
    end if
    code = tmp
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	double t_1 = -x / z;
	double tmp;
	if (y <= -1e+43) {
		tmp = (x / y) / (t - z);
	} else if (y <= -1.45e-12) {
		tmp = t_1 / (y - z);
	} else if (y <= -3.5e-43) {
		tmp = x / ((t - z) * y);
	} else if (y <= 1.3e-57) {
		tmp = t_1 / (t - z);
	} else {
		tmp = (x / t) / (y - z);
	}
	return tmp;
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	t_1 = -x / z
	tmp = 0
	if y <= -1e+43:
		tmp = (x / y) / (t - z)
	elif y <= -1.45e-12:
		tmp = t_1 / (y - z)
	elif y <= -3.5e-43:
		tmp = x / ((t - z) * y)
	elif y <= 1.3e-57:
		tmp = t_1 / (t - z)
	else:
		tmp = (x / t) / (y - z)
	return tmp
y, t = sort([y, t])
function code(x, y, z, t)
	t_1 = Float64(Float64(-x) / z)
	tmp = 0.0
	if (y <= -1e+43)
		tmp = Float64(Float64(x / y) / Float64(t - z));
	elseif (y <= -1.45e-12)
		tmp = Float64(t_1 / Float64(y - z));
	elseif (y <= -3.5e-43)
		tmp = Float64(x / Float64(Float64(t - z) * y));
	elseif (y <= 1.3e-57)
		tmp = Float64(t_1 / Float64(t - z));
	else
		tmp = Float64(Float64(x / t) / Float64(y - z));
	end
	return tmp
end
y, t = num2cell(sort([y, t])){:}
function tmp_2 = code(x, y, z, t)
	t_1 = -x / z;
	tmp = 0.0;
	if (y <= -1e+43)
		tmp = (x / y) / (t - z);
	elseif (y <= -1.45e-12)
		tmp = t_1 / (y - z);
	elseif (y <= -3.5e-43)
		tmp = x / ((t - z) * y);
	elseif (y <= 1.3e-57)
		tmp = t_1 / (t - z);
	else
		tmp = (x / t) / (y - z);
	end
	tmp_2 = tmp;
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := Block[{t$95$1 = N[((-x) / z), $MachinePrecision]}, If[LessEqual[y, -1e+43], N[(N[(x / y), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -1.45e-12], N[(t$95$1 / N[(y - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -3.5e-43], N[(x / N[(N[(t - z), $MachinePrecision] * y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.3e-57], N[(t$95$1 / N[(t - z), $MachinePrecision]), $MachinePrecision], N[(N[(x / t), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\begin{array}{l}
t_1 := \frac{-x}{z}\\
\mathbf{if}\;y \leq -1 \cdot 10^{+43}:\\
\;\;\;\;\frac{\frac{x}{y}}{t - z}\\

\mathbf{elif}\;y \leq -1.45 \cdot 10^{-12}:\\
\;\;\;\;\frac{t_1}{y - z}\\

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

\mathbf{elif}\;y \leq 1.3 \cdot 10^{-57}:\\
\;\;\;\;\frac{t_1}{t - z}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if y < -1.00000000000000001e43

    1. Initial program 84.0%

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

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

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

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

    if -1.00000000000000001e43 < y < -1.4500000000000001e-12

    1. Initial program 100.0%

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

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

        \[\leadsto \color{blue}{\frac{-1 \cdot x}{\left(y - z\right) \cdot z}} \]
      2. neg-mul-168.5%

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

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

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

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

    if -1.4500000000000001e-12 < y < -3.49999999999999997e-43

    1. Initial program 99.6%

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

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

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

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

    if -3.49999999999999997e-43 < y < 1.29999999999999993e-57

    1. Initial program 91.3%

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

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

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

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

        \[\leadsto \color{blue}{\frac{\frac{-x}{z}}{t - z}} \]
    4. Simplified81.8%

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

    if 1.29999999999999993e-57 < y

    1. Initial program 90.5%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -1 \cdot 10^{+43}:\\ \;\;\;\;\frac{\frac{x}{y}}{t - z}\\ \mathbf{elif}\;y \leq -1.45 \cdot 10^{-12}:\\ \;\;\;\;\frac{\frac{-x}{z}}{y - z}\\ \mathbf{elif}\;y \leq -3.5 \cdot 10^{-43}:\\ \;\;\;\;\frac{x}{\left(t - z\right) \cdot y}\\ \mathbf{elif}\;y \leq 1.3 \cdot 10^{-57}:\\ \;\;\;\;\frac{\frac{-x}{z}}{t - z}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{t}}{y - z}\\ \end{array} \]

Alternative 3: 81.2% accurate, 0.6× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \begin{array}{l} t_1 := \frac{-x}{z}\\ \mathbf{if}\;y \leq -5.8 \cdot 10^{+42}:\\ \;\;\;\;\frac{1}{\frac{y}{\frac{x}{t - z}}}\\ \mathbf{elif}\;y \leq -3.5 \cdot 10^{-13}:\\ \;\;\;\;\frac{t_1}{y - z}\\ \mathbf{elif}\;y \leq -3.5 \cdot 10^{-43}:\\ \;\;\;\;\frac{x}{\left(t - z\right) \cdot y}\\ \mathbf{elif}\;y \leq 2.55 \cdot 10^{-58}:\\ \;\;\;\;\frac{t_1}{t - z}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{t}}{y - z}\\ \end{array} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (/ (- x) z)))
   (if (<= y -5.8e+42)
     (/ 1.0 (/ y (/ x (- t z))))
     (if (<= y -3.5e-13)
       (/ t_1 (- y z))
       (if (<= y -3.5e-43)
         (/ x (* (- t z) y))
         (if (<= y 2.55e-58) (/ t_1 (- t z)) (/ (/ x t) (- y z))))))))
assert(y < t);
double code(double x, double y, double z, double t) {
	double t_1 = -x / z;
	double tmp;
	if (y <= -5.8e+42) {
		tmp = 1.0 / (y / (x / (t - z)));
	} else if (y <= -3.5e-13) {
		tmp = t_1 / (y - z);
	} else if (y <= -3.5e-43) {
		tmp = x / ((t - z) * y);
	} else if (y <= 2.55e-58) {
		tmp = t_1 / (t - z);
	} else {
		tmp = (x / t) / (y - z);
	}
	return tmp;
}
NOTE: y and t should be sorted in increasing order before calling this function.
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 / z
    if (y <= (-5.8d+42)) then
        tmp = 1.0d0 / (y / (x / (t - z)))
    else if (y <= (-3.5d-13)) then
        tmp = t_1 / (y - z)
    else if (y <= (-3.5d-43)) then
        tmp = x / ((t - z) * y)
    else if (y <= 2.55d-58) then
        tmp = t_1 / (t - z)
    else
        tmp = (x / t) / (y - z)
    end if
    code = tmp
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	double t_1 = -x / z;
	double tmp;
	if (y <= -5.8e+42) {
		tmp = 1.0 / (y / (x / (t - z)));
	} else if (y <= -3.5e-13) {
		tmp = t_1 / (y - z);
	} else if (y <= -3.5e-43) {
		tmp = x / ((t - z) * y);
	} else if (y <= 2.55e-58) {
		tmp = t_1 / (t - z);
	} else {
		tmp = (x / t) / (y - z);
	}
	return tmp;
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	t_1 = -x / z
	tmp = 0
	if y <= -5.8e+42:
		tmp = 1.0 / (y / (x / (t - z)))
	elif y <= -3.5e-13:
		tmp = t_1 / (y - z)
	elif y <= -3.5e-43:
		tmp = x / ((t - z) * y)
	elif y <= 2.55e-58:
		tmp = t_1 / (t - z)
	else:
		tmp = (x / t) / (y - z)
	return tmp
y, t = sort([y, t])
function code(x, y, z, t)
	t_1 = Float64(Float64(-x) / z)
	tmp = 0.0
	if (y <= -5.8e+42)
		tmp = Float64(1.0 / Float64(y / Float64(x / Float64(t - z))));
	elseif (y <= -3.5e-13)
		tmp = Float64(t_1 / Float64(y - z));
	elseif (y <= -3.5e-43)
		tmp = Float64(x / Float64(Float64(t - z) * y));
	elseif (y <= 2.55e-58)
		tmp = Float64(t_1 / Float64(t - z));
	else
		tmp = Float64(Float64(x / t) / Float64(y - z));
	end
	return tmp
end
y, t = num2cell(sort([y, t])){:}
function tmp_2 = code(x, y, z, t)
	t_1 = -x / z;
	tmp = 0.0;
	if (y <= -5.8e+42)
		tmp = 1.0 / (y / (x / (t - z)));
	elseif (y <= -3.5e-13)
		tmp = t_1 / (y - z);
	elseif (y <= -3.5e-43)
		tmp = x / ((t - z) * y);
	elseif (y <= 2.55e-58)
		tmp = t_1 / (t - z);
	else
		tmp = (x / t) / (y - z);
	end
	tmp_2 = tmp;
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := Block[{t$95$1 = N[((-x) / z), $MachinePrecision]}, If[LessEqual[y, -5.8e+42], N[(1.0 / N[(y / N[(x / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -3.5e-13], N[(t$95$1 / N[(y - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -3.5e-43], N[(x / N[(N[(t - z), $MachinePrecision] * y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.55e-58], N[(t$95$1 / N[(t - z), $MachinePrecision]), $MachinePrecision], N[(N[(x / t), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\begin{array}{l}
t_1 := \frac{-x}{z}\\
\mathbf{if}\;y \leq -5.8 \cdot 10^{+42}:\\
\;\;\;\;\frac{1}{\frac{y}{\frac{x}{t - z}}}\\

\mathbf{elif}\;y \leq -3.5 \cdot 10^{-13}:\\
\;\;\;\;\frac{t_1}{y - z}\\

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

\mathbf{elif}\;y \leq 2.55 \cdot 10^{-58}:\\
\;\;\;\;\frac{t_1}{t - z}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if y < -5.79999999999999961e42

    1. Initial program 84.0%

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{{\left(\frac{y \cdot \left(t - z\right)}{x}\right)}^{-1}} \]
    7. Step-by-step derivation
      1. unpow-183.9%

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

        \[\leadsto \frac{1}{\color{blue}{\frac{y}{\frac{x}{t - z}}}} \]
    8. Simplified92.0%

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

    if -5.79999999999999961e42 < y < -3.5000000000000002e-13

    1. Initial program 100.0%

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

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

        \[\leadsto \color{blue}{\frac{-1 \cdot x}{\left(y - z\right) \cdot z}} \]
      2. neg-mul-168.5%

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

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

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

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

    if -3.5000000000000002e-13 < y < -3.49999999999999997e-43

    1. Initial program 99.6%

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

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

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

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

    if -3.49999999999999997e-43 < y < 2.55e-58

    1. Initial program 91.3%

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

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

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

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

        \[\leadsto \color{blue}{\frac{\frac{-x}{z}}{t - z}} \]
    4. Simplified81.8%

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

    if 2.55e-58 < y

    1. Initial program 90.5%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -5.8 \cdot 10^{+42}:\\ \;\;\;\;\frac{1}{\frac{y}{\frac{x}{t - z}}}\\ \mathbf{elif}\;y \leq -3.5 \cdot 10^{-13}:\\ \;\;\;\;\frac{\frac{-x}{z}}{y - z}\\ \mathbf{elif}\;y \leq -3.5 \cdot 10^{-43}:\\ \;\;\;\;\frac{x}{\left(t - z\right) \cdot y}\\ \mathbf{elif}\;y \leq 2.55 \cdot 10^{-58}:\\ \;\;\;\;\frac{\frac{-x}{z}}{t - z}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{t}}{y - z}\\ \end{array} \]

Alternative 4: 67.0% accurate, 0.7× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \begin{array}{l} t_1 := \frac{\frac{x}{z}}{z}\\ \mathbf{if}\;z \leq -1.5 \cdot 10^{+47}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -6.5 \cdot 10^{-12}:\\ \;\;\;\;\frac{-\frac{x}{y}}{z}\\ \mathbf{elif}\;z \leq 2.8 \cdot 10^{+65}:\\ \;\;\;\;\frac{1}{t \cdot \frac{y}{x}}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (/ (/ x z) z)))
   (if (<= z -1.5e+47)
     t_1
     (if (<= z -6.5e-12)
       (/ (- (/ x y)) z)
       (if (<= z 2.8e+65) (/ 1.0 (* t (/ y x))) t_1)))))
assert(y < t);
double code(double x, double y, double z, double t) {
	double t_1 = (x / z) / z;
	double tmp;
	if (z <= -1.5e+47) {
		tmp = t_1;
	} else if (z <= -6.5e-12) {
		tmp = -(x / y) / z;
	} else if (z <= 2.8e+65) {
		tmp = 1.0 / (t * (y / x));
	} else {
		tmp = t_1;
	}
	return tmp;
}
NOTE: y and t should be sorted in increasing order before calling this function.
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 / z) / z
    if (z <= (-1.5d+47)) then
        tmp = t_1
    else if (z <= (-6.5d-12)) then
        tmp = -(x / y) / z
    else if (z <= 2.8d+65) then
        tmp = 1.0d0 / (t * (y / x))
    else
        tmp = t_1
    end if
    code = tmp
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	double t_1 = (x / z) / z;
	double tmp;
	if (z <= -1.5e+47) {
		tmp = t_1;
	} else if (z <= -6.5e-12) {
		tmp = -(x / y) / z;
	} else if (z <= 2.8e+65) {
		tmp = 1.0 / (t * (y / x));
	} else {
		tmp = t_1;
	}
	return tmp;
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	t_1 = (x / z) / z
	tmp = 0
	if z <= -1.5e+47:
		tmp = t_1
	elif z <= -6.5e-12:
		tmp = -(x / y) / z
	elif z <= 2.8e+65:
		tmp = 1.0 / (t * (y / x))
	else:
		tmp = t_1
	return tmp
y, t = sort([y, t])
function code(x, y, z, t)
	t_1 = Float64(Float64(x / z) / z)
	tmp = 0.0
	if (z <= -1.5e+47)
		tmp = t_1;
	elseif (z <= -6.5e-12)
		tmp = Float64(Float64(-Float64(x / y)) / z);
	elseif (z <= 2.8e+65)
		tmp = Float64(1.0 / Float64(t * Float64(y / x)));
	else
		tmp = t_1;
	end
	return tmp
end
y, t = num2cell(sort([y, t])){:}
function tmp_2 = code(x, y, z, t)
	t_1 = (x / z) / z;
	tmp = 0.0;
	if (z <= -1.5e+47)
		tmp = t_1;
	elseif (z <= -6.5e-12)
		tmp = -(x / y) / z;
	elseif (z <= 2.8e+65)
		tmp = 1.0 / (t * (y / x));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x / z), $MachinePrecision] / z), $MachinePrecision]}, If[LessEqual[z, -1.5e+47], t$95$1, If[LessEqual[z, -6.5e-12], N[((-N[(x / y), $MachinePrecision]) / z), $MachinePrecision], If[LessEqual[z, 2.8e+65], N[(1.0 / N[(t * N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\begin{array}{l}
t_1 := \frac{\frac{x}{z}}{z}\\
\mathbf{if}\;z \leq -1.5 \cdot 10^{+47}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq -6.5 \cdot 10^{-12}:\\
\;\;\;\;\frac{-\frac{x}{y}}{z}\\

\mathbf{elif}\;z \leq 2.8 \cdot 10^{+65}:\\
\;\;\;\;\frac{1}{t \cdot \frac{y}{x}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.5000000000000001e47 or 2.7999999999999999e65 < z

    1. Initial program 85.1%

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

      \[\leadsto \color{blue}{\frac{x}{{z}^{2}}} \]
    3. Step-by-step derivation
      1. unpow276.0%

        \[\leadsto \frac{x}{\color{blue}{z \cdot z}} \]
      2. associate-/r*79.9%

        \[\leadsto \color{blue}{\frac{\frac{x}{z}}{z}} \]
    4. Simplified79.9%

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

    if -1.5000000000000001e47 < z < -6.5000000000000002e-12

    1. Initial program 99.6%

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

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

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{x}{y \cdot z}} \]
    6. Step-by-step derivation
      1. mul-1-neg52.9%

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

        \[\leadsto -\color{blue}{\frac{\frac{x}{y}}{z}} \]
      3. distribute-neg-frac52.7%

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

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

    if -6.5000000000000002e-12 < z < 2.7999999999999999e65

    1. Initial program 92.9%

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

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

        \[\leadsto \color{blue}{\frac{1}{\frac{y \cdot t}{x}}} \]
      2. inv-pow56.5%

        \[\leadsto \color{blue}{{\left(\frac{y \cdot t}{x}\right)}^{-1}} \]
    4. Applied egg-rr56.5%

      \[\leadsto \color{blue}{{\left(\frac{y \cdot t}{x}\right)}^{-1}} \]
    5. Step-by-step derivation
      1. unpow-156.5%

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

        \[\leadsto \frac{1}{\color{blue}{\frac{y}{\frac{x}{t}}}} \]
    6. Simplified60.3%

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

        \[\leadsto \frac{1}{\color{blue}{\frac{y}{x} \cdot t}} \]
    8. Applied egg-rr61.4%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.5 \cdot 10^{+47}:\\ \;\;\;\;\frac{\frac{x}{z}}{z}\\ \mathbf{elif}\;z \leq -6.5 \cdot 10^{-12}:\\ \;\;\;\;\frac{-\frac{x}{y}}{z}\\ \mathbf{elif}\;z \leq 2.8 \cdot 10^{+65}:\\ \;\;\;\;\frac{1}{t \cdot \frac{y}{x}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{z}}{z}\\ \end{array} \]

Alternative 5: 67.1% accurate, 0.7× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \begin{array}{l} t_1 := \frac{1}{z \cdot \frac{z}{x}}\\ \mathbf{if}\;z \leq -2.1 \cdot 10^{+49}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -5.2 \cdot 10^{-13}:\\ \;\;\;\;\frac{-\frac{x}{y}}{z}\\ \mathbf{elif}\;z \leq 4.5 \cdot 10^{+60}:\\ \;\;\;\;\frac{1}{t \cdot \frac{y}{x}}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (/ 1.0 (* z (/ z x)))))
   (if (<= z -2.1e+49)
     t_1
     (if (<= z -5.2e-13)
       (/ (- (/ x y)) z)
       (if (<= z 4.5e+60) (/ 1.0 (* t (/ y x))) t_1)))))
assert(y < t);
double code(double x, double y, double z, double t) {
	double t_1 = 1.0 / (z * (z / x));
	double tmp;
	if (z <= -2.1e+49) {
		tmp = t_1;
	} else if (z <= -5.2e-13) {
		tmp = -(x / y) / z;
	} else if (z <= 4.5e+60) {
		tmp = 1.0 / (t * (y / x));
	} else {
		tmp = t_1;
	}
	return tmp;
}
NOTE: y and t should be sorted in increasing order before calling this function.
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 = 1.0d0 / (z * (z / x))
    if (z <= (-2.1d+49)) then
        tmp = t_1
    else if (z <= (-5.2d-13)) then
        tmp = -(x / y) / z
    else if (z <= 4.5d+60) then
        tmp = 1.0d0 / (t * (y / x))
    else
        tmp = t_1
    end if
    code = tmp
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	double t_1 = 1.0 / (z * (z / x));
	double tmp;
	if (z <= -2.1e+49) {
		tmp = t_1;
	} else if (z <= -5.2e-13) {
		tmp = -(x / y) / z;
	} else if (z <= 4.5e+60) {
		tmp = 1.0 / (t * (y / x));
	} else {
		tmp = t_1;
	}
	return tmp;
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	t_1 = 1.0 / (z * (z / x))
	tmp = 0
	if z <= -2.1e+49:
		tmp = t_1
	elif z <= -5.2e-13:
		tmp = -(x / y) / z
	elif z <= 4.5e+60:
		tmp = 1.0 / (t * (y / x))
	else:
		tmp = t_1
	return tmp
y, t = sort([y, t])
function code(x, y, z, t)
	t_1 = Float64(1.0 / Float64(z * Float64(z / x)))
	tmp = 0.0
	if (z <= -2.1e+49)
		tmp = t_1;
	elseif (z <= -5.2e-13)
		tmp = Float64(Float64(-Float64(x / y)) / z);
	elseif (z <= 4.5e+60)
		tmp = Float64(1.0 / Float64(t * Float64(y / x)));
	else
		tmp = t_1;
	end
	return tmp
end
y, t = num2cell(sort([y, t])){:}
function tmp_2 = code(x, y, z, t)
	t_1 = 1.0 / (z * (z / x));
	tmp = 0.0;
	if (z <= -2.1e+49)
		tmp = t_1;
	elseif (z <= -5.2e-13)
		tmp = -(x / y) / z;
	elseif (z <= 4.5e+60)
		tmp = 1.0 / (t * (y / x));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(1.0 / N[(z * N[(z / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2.1e+49], t$95$1, If[LessEqual[z, -5.2e-13], N[((-N[(x / y), $MachinePrecision]) / z), $MachinePrecision], If[LessEqual[z, 4.5e+60], N[(1.0 / N[(t * N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\begin{array}{l}
t_1 := \frac{1}{z \cdot \frac{z}{x}}\\
\mathbf{if}\;z \leq -2.1 \cdot 10^{+49}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq -5.2 \cdot 10^{-13}:\\
\;\;\;\;\frac{-\frac{x}{y}}{z}\\

\mathbf{elif}\;z \leq 4.5 \cdot 10^{+60}:\\
\;\;\;\;\frac{1}{t \cdot \frac{y}{x}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -2.10000000000000011e49 or 4.50000000000000013e60 < z

    1. Initial program 85.1%

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

      \[\leadsto \color{blue}{\frac{x}{{z}^{2}}} \]
    3. Step-by-step derivation
      1. unpow276.0%

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

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

        \[\leadsto \color{blue}{\frac{1}{\frac{z \cdot z}{x}}} \]
      2. inv-pow76.4%

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

        \[\leadsto {\color{blue}{\left(\frac{z}{\frac{x}{z}}\right)}}^{-1} \]
    6. Applied egg-rr80.4%

      \[\leadsto \color{blue}{{\left(\frac{z}{\frac{x}{z}}\right)}^{-1}} \]
    7. Step-by-step derivation
      1. unpow-180.4%

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

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

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

    if -2.10000000000000011e49 < z < -5.2000000000000001e-13

    1. Initial program 99.6%

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

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

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{x}{y \cdot z}} \]
    6. Step-by-step derivation
      1. mul-1-neg52.9%

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

        \[\leadsto -\color{blue}{\frac{\frac{x}{y}}{z}} \]
      3. distribute-neg-frac52.7%

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

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

    if -5.2000000000000001e-13 < z < 4.50000000000000013e60

    1. Initial program 92.9%

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

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

        \[\leadsto \color{blue}{\frac{1}{\frac{y \cdot t}{x}}} \]
      2. inv-pow56.5%

        \[\leadsto \color{blue}{{\left(\frac{y \cdot t}{x}\right)}^{-1}} \]
    4. Applied egg-rr56.5%

      \[\leadsto \color{blue}{{\left(\frac{y \cdot t}{x}\right)}^{-1}} \]
    5. Step-by-step derivation
      1. unpow-156.5%

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

        \[\leadsto \frac{1}{\color{blue}{\frac{y}{\frac{x}{t}}}} \]
    6. Simplified60.3%

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

        \[\leadsto \frac{1}{\color{blue}{\frac{y}{x} \cdot t}} \]
    8. Applied egg-rr61.4%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.1 \cdot 10^{+49}:\\ \;\;\;\;\frac{1}{z \cdot \frac{z}{x}}\\ \mathbf{elif}\;z \leq -5.2 \cdot 10^{-13}:\\ \;\;\;\;\frac{-\frac{x}{y}}{z}\\ \mathbf{elif}\;z \leq 4.5 \cdot 10^{+60}:\\ \;\;\;\;\frac{1}{t \cdot \frac{y}{x}}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{z \cdot \frac{z}{x}}\\ \end{array} \]

Alternative 6: 67.4% accurate, 0.7× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \begin{array}{l} t_1 := \frac{1}{z \cdot \frac{z}{x}}\\ \mathbf{if}\;z \leq -7.7 \cdot 10^{+46}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -2.1 \cdot 10^{-11}:\\ \;\;\;\;\frac{-\frac{x}{y}}{z}\\ \mathbf{elif}\;z \leq 6.2 \cdot 10^{+16}:\\ \;\;\;\;\frac{1}{\frac{y}{\frac{x}{t}}}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (/ 1.0 (* z (/ z x)))))
   (if (<= z -7.7e+46)
     t_1
     (if (<= z -2.1e-11)
       (/ (- (/ x y)) z)
       (if (<= z 6.2e+16) (/ 1.0 (/ y (/ x t))) t_1)))))
assert(y < t);
double code(double x, double y, double z, double t) {
	double t_1 = 1.0 / (z * (z / x));
	double tmp;
	if (z <= -7.7e+46) {
		tmp = t_1;
	} else if (z <= -2.1e-11) {
		tmp = -(x / y) / z;
	} else if (z <= 6.2e+16) {
		tmp = 1.0 / (y / (x / t));
	} else {
		tmp = t_1;
	}
	return tmp;
}
NOTE: y and t should be sorted in increasing order before calling this function.
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 = 1.0d0 / (z * (z / x))
    if (z <= (-7.7d+46)) then
        tmp = t_1
    else if (z <= (-2.1d-11)) then
        tmp = -(x / y) / z
    else if (z <= 6.2d+16) then
        tmp = 1.0d0 / (y / (x / t))
    else
        tmp = t_1
    end if
    code = tmp
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	double t_1 = 1.0 / (z * (z / x));
	double tmp;
	if (z <= -7.7e+46) {
		tmp = t_1;
	} else if (z <= -2.1e-11) {
		tmp = -(x / y) / z;
	} else if (z <= 6.2e+16) {
		tmp = 1.0 / (y / (x / t));
	} else {
		tmp = t_1;
	}
	return tmp;
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	t_1 = 1.0 / (z * (z / x))
	tmp = 0
	if z <= -7.7e+46:
		tmp = t_1
	elif z <= -2.1e-11:
		tmp = -(x / y) / z
	elif z <= 6.2e+16:
		tmp = 1.0 / (y / (x / t))
	else:
		tmp = t_1
	return tmp
y, t = sort([y, t])
function code(x, y, z, t)
	t_1 = Float64(1.0 / Float64(z * Float64(z / x)))
	tmp = 0.0
	if (z <= -7.7e+46)
		tmp = t_1;
	elseif (z <= -2.1e-11)
		tmp = Float64(Float64(-Float64(x / y)) / z);
	elseif (z <= 6.2e+16)
		tmp = Float64(1.0 / Float64(y / Float64(x / t)));
	else
		tmp = t_1;
	end
	return tmp
end
y, t = num2cell(sort([y, t])){:}
function tmp_2 = code(x, y, z, t)
	t_1 = 1.0 / (z * (z / x));
	tmp = 0.0;
	if (z <= -7.7e+46)
		tmp = t_1;
	elseif (z <= -2.1e-11)
		tmp = -(x / y) / z;
	elseif (z <= 6.2e+16)
		tmp = 1.0 / (y / (x / t));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(1.0 / N[(z * N[(z / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -7.7e+46], t$95$1, If[LessEqual[z, -2.1e-11], N[((-N[(x / y), $MachinePrecision]) / z), $MachinePrecision], If[LessEqual[z, 6.2e+16], N[(1.0 / N[(y / N[(x / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\begin{array}{l}
t_1 := \frac{1}{z \cdot \frac{z}{x}}\\
\mathbf{if}\;z \leq -7.7 \cdot 10^{+46}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq -2.1 \cdot 10^{-11}:\\
\;\;\;\;\frac{-\frac{x}{y}}{z}\\

\mathbf{elif}\;z \leq 6.2 \cdot 10^{+16}:\\
\;\;\;\;\frac{1}{\frac{y}{\frac{x}{t}}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -7.70000000000000038e46 or 6.2e16 < z

    1. Initial program 86.5%

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

      \[\leadsto \color{blue}{\frac{x}{{z}^{2}}} \]
    3. Step-by-step derivation
      1. unpow273.4%

        \[\leadsto \frac{x}{\color{blue}{z \cdot z}} \]
    4. Simplified73.4%

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

        \[\leadsto \color{blue}{\frac{1}{\frac{z \cdot z}{x}}} \]
      2. inv-pow73.7%

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

        \[\leadsto {\color{blue}{\left(\frac{z}{\frac{x}{z}}\right)}}^{-1} \]
    6. Applied egg-rr77.4%

      \[\leadsto \color{blue}{{\left(\frac{z}{\frac{x}{z}}\right)}^{-1}} \]
    7. Step-by-step derivation
      1. unpow-177.4%

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

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

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

    if -7.70000000000000038e46 < z < -2.0999999999999999e-11

    1. Initial program 99.6%

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

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

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{x}{y \cdot z}} \]
    6. Step-by-step derivation
      1. mul-1-neg52.9%

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

        \[\leadsto -\color{blue}{\frac{\frac{x}{y}}{z}} \]
      3. distribute-neg-frac52.7%

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

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

    if -2.0999999999999999e-11 < z < 6.2e16

    1. Initial program 92.1%

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

      \[\leadsto \color{blue}{\frac{x}{y \cdot t}} \]
    3. Step-by-step derivation
      1. clear-num58.7%

        \[\leadsto \color{blue}{\frac{1}{\frac{y \cdot t}{x}}} \]
      2. inv-pow58.7%

        \[\leadsto \color{blue}{{\left(\frac{y \cdot t}{x}\right)}^{-1}} \]
    4. Applied egg-rr58.7%

      \[\leadsto \color{blue}{{\left(\frac{y \cdot t}{x}\right)}^{-1}} \]
    5. Step-by-step derivation
      1. unpow-158.7%

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

        \[\leadsto \frac{1}{\color{blue}{\frac{y}{\frac{x}{t}}}} \]
    6. Simplified62.1%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -7.7 \cdot 10^{+46}:\\ \;\;\;\;\frac{1}{z \cdot \frac{z}{x}}\\ \mathbf{elif}\;z \leq -2.1 \cdot 10^{-11}:\\ \;\;\;\;\frac{-\frac{x}{y}}{z}\\ \mathbf{elif}\;z \leq 6.2 \cdot 10^{+16}:\\ \;\;\;\;\frac{1}{\frac{y}{\frac{x}{t}}}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{z \cdot \frac{z}{x}}\\ \end{array} \]

Alternative 7: 73.0% accurate, 0.7× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \begin{array}{l} t_1 := \frac{1}{z \cdot \frac{z}{x}}\\ \mathbf{if}\;z \leq -2.6 \cdot 10^{+48}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -1.8 \cdot 10^{-11}:\\ \;\;\;\;\frac{-\frac{x}{y}}{z}\\ \mathbf{elif}\;z \leq 9.2 \cdot 10^{+29}:\\ \;\;\;\;\frac{x}{t \cdot \left(y - z\right)}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (/ 1.0 (* z (/ z x)))))
   (if (<= z -2.6e+48)
     t_1
     (if (<= z -1.8e-11)
       (/ (- (/ x y)) z)
       (if (<= z 9.2e+29) (/ x (* t (- y z))) t_1)))))
assert(y < t);
double code(double x, double y, double z, double t) {
	double t_1 = 1.0 / (z * (z / x));
	double tmp;
	if (z <= -2.6e+48) {
		tmp = t_1;
	} else if (z <= -1.8e-11) {
		tmp = -(x / y) / z;
	} else if (z <= 9.2e+29) {
		tmp = x / (t * (y - z));
	} else {
		tmp = t_1;
	}
	return tmp;
}
NOTE: y and t should be sorted in increasing order before calling this function.
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 = 1.0d0 / (z * (z / x))
    if (z <= (-2.6d+48)) then
        tmp = t_1
    else if (z <= (-1.8d-11)) then
        tmp = -(x / y) / z
    else if (z <= 9.2d+29) then
        tmp = x / (t * (y - z))
    else
        tmp = t_1
    end if
    code = tmp
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	double t_1 = 1.0 / (z * (z / x));
	double tmp;
	if (z <= -2.6e+48) {
		tmp = t_1;
	} else if (z <= -1.8e-11) {
		tmp = -(x / y) / z;
	} else if (z <= 9.2e+29) {
		tmp = x / (t * (y - z));
	} else {
		tmp = t_1;
	}
	return tmp;
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	t_1 = 1.0 / (z * (z / x))
	tmp = 0
	if z <= -2.6e+48:
		tmp = t_1
	elif z <= -1.8e-11:
		tmp = -(x / y) / z
	elif z <= 9.2e+29:
		tmp = x / (t * (y - z))
	else:
		tmp = t_1
	return tmp
y, t = sort([y, t])
function code(x, y, z, t)
	t_1 = Float64(1.0 / Float64(z * Float64(z / x)))
	tmp = 0.0
	if (z <= -2.6e+48)
		tmp = t_1;
	elseif (z <= -1.8e-11)
		tmp = Float64(Float64(-Float64(x / y)) / z);
	elseif (z <= 9.2e+29)
		tmp = Float64(x / Float64(t * Float64(y - z)));
	else
		tmp = t_1;
	end
	return tmp
end
y, t = num2cell(sort([y, t])){:}
function tmp_2 = code(x, y, z, t)
	t_1 = 1.0 / (z * (z / x));
	tmp = 0.0;
	if (z <= -2.6e+48)
		tmp = t_1;
	elseif (z <= -1.8e-11)
		tmp = -(x / y) / z;
	elseif (z <= 9.2e+29)
		tmp = x / (t * (y - z));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(1.0 / N[(z * N[(z / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2.6e+48], t$95$1, If[LessEqual[z, -1.8e-11], N[((-N[(x / y), $MachinePrecision]) / z), $MachinePrecision], If[LessEqual[z, 9.2e+29], N[(x / N[(t * N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\begin{array}{l}
t_1 := \frac{1}{z \cdot \frac{z}{x}}\\
\mathbf{if}\;z \leq -2.6 \cdot 10^{+48}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq -1.8 \cdot 10^{-11}:\\
\;\;\;\;\frac{-\frac{x}{y}}{z}\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -2.59999999999999995e48 or 9.2000000000000004e29 < z

    1. Initial program 86.2%

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

      \[\leadsto \color{blue}{\frac{x}{{z}^{2}}} \]
    3. Step-by-step derivation
      1. unpow273.5%

        \[\leadsto \frac{x}{\color{blue}{z \cdot z}} \]
    4. Simplified73.5%

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

        \[\leadsto \color{blue}{\frac{1}{\frac{z \cdot z}{x}}} \]
      2. inv-pow73.9%

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

        \[\leadsto {\color{blue}{\left(\frac{z}{\frac{x}{z}}\right)}}^{-1} \]
    6. Applied egg-rr77.6%

      \[\leadsto \color{blue}{{\left(\frac{z}{\frac{x}{z}}\right)}^{-1}} \]
    7. Step-by-step derivation
      1. unpow-177.6%

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

        \[\leadsto \frac{1}{\color{blue}{\frac{z}{x} \cdot z}} \]
    8. Simplified77.6%

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

    if -2.59999999999999995e48 < z < -1.79999999999999992e-11

    1. Initial program 99.6%

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

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

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{x}{y \cdot z}} \]
    6. Step-by-step derivation
      1. mul-1-neg52.9%

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

        \[\leadsto -\color{blue}{\frac{\frac{x}{y}}{z}} \]
      3. distribute-neg-frac52.7%

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

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

    if -1.79999999999999992e-11 < z < 9.2000000000000004e29

    1. Initial program 92.3%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.6 \cdot 10^{+48}:\\ \;\;\;\;\frac{1}{z \cdot \frac{z}{x}}\\ \mathbf{elif}\;z \leq -1.8 \cdot 10^{-11}:\\ \;\;\;\;\frac{-\frac{x}{y}}{z}\\ \mathbf{elif}\;z \leq 9.2 \cdot 10^{+29}:\\ \;\;\;\;\frac{x}{t \cdot \left(y - z\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{z \cdot \frac{z}{x}}\\ \end{array} \]

Alternative 8: 82.0% accurate, 0.7× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq -2.6 \cdot 10^{-43}:\\ \;\;\;\;\frac{\frac{x}{y}}{t - z}\\ \mathbf{elif}\;y \leq 6.1 \cdot 10^{-58}:\\ \;\;\;\;\frac{\frac{-x}{z}}{t - z}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{t}}{y - z}\\ \end{array} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
 :precision binary64
 (if (<= y -2.6e-43)
   (/ (/ x y) (- t z))
   (if (<= y 6.1e-58) (/ (/ (- x) z) (- t z)) (/ (/ x t) (- y z)))))
assert(y < t);
double code(double x, double y, double z, double t) {
	double tmp;
	if (y <= -2.6e-43) {
		tmp = (x / y) / (t - z);
	} else if (y <= 6.1e-58) {
		tmp = (-x / z) / (t - z);
	} else {
		tmp = (x / t) / (y - z);
	}
	return tmp;
}
NOTE: y and t should be sorted in increasing order before calling this function.
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 <= (-2.6d-43)) then
        tmp = (x / y) / (t - z)
    else if (y <= 6.1d-58) then
        tmp = (-x / z) / (t - z)
    else
        tmp = (x / t) / (y - z)
    end if
    code = tmp
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (y <= -2.6e-43) {
		tmp = (x / y) / (t - z);
	} else if (y <= 6.1e-58) {
		tmp = (-x / z) / (t - z);
	} else {
		tmp = (x / t) / (y - z);
	}
	return tmp;
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	tmp = 0
	if y <= -2.6e-43:
		tmp = (x / y) / (t - z)
	elif y <= 6.1e-58:
		tmp = (-x / z) / (t - z)
	else:
		tmp = (x / t) / (y - z)
	return tmp
y, t = sort([y, t])
function code(x, y, z, t)
	tmp = 0.0
	if (y <= -2.6e-43)
		tmp = Float64(Float64(x / y) / Float64(t - z));
	elseif (y <= 6.1e-58)
		tmp = Float64(Float64(Float64(-x) / z) / Float64(t - z));
	else
		tmp = Float64(Float64(x / t) / Float64(y - z));
	end
	return tmp
end
y, t = num2cell(sort([y, t])){:}
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (y <= -2.6e-43)
		tmp = (x / y) / (t - z);
	elseif (y <= 6.1e-58)
		tmp = (-x / z) / (t - z);
	else
		tmp = (x / t) / (y - z);
	end
	tmp_2 = tmp;
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := If[LessEqual[y, -2.6e-43], N[(N[(x / y), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 6.1e-58], N[(N[((-x) / z), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision], N[(N[(x / t), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.6 \cdot 10^{-43}:\\
\;\;\;\;\frac{\frac{x}{y}}{t - z}\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -2.6e-43

    1. Initial program 87.1%

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

        \[\leadsto \color{blue}{\frac{\frac{x}{y - z}}{t - z}} \]
    3. Simplified98.2%

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

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

    if -2.6e-43 < y < 6.1000000000000003e-58

    1. Initial program 91.3%

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

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

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

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

        \[\leadsto \color{blue}{\frac{\frac{-x}{z}}{t - z}} \]
    4. Simplified81.8%

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

    if 6.1000000000000003e-58 < y

    1. Initial program 90.5%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.6 \cdot 10^{-43}:\\ \;\;\;\;\frac{\frac{x}{y}}{t - z}\\ \mathbf{elif}\;y \leq 6.1 \cdot 10^{-58}:\\ \;\;\;\;\frac{\frac{-x}{z}}{t - z}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{t}}{y - z}\\ \end{array} \]

Alternative 9: 66.2% accurate, 0.8× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \begin{array}{l} t_1 := \frac{\frac{x}{z}}{z}\\ \mathbf{if}\;z \leq -1.62 \cdot 10^{+44}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -1.65 \cdot 10^{-17}:\\ \;\;\;\;\frac{x}{y \cdot \left(-z\right)}\\ \mathbf{elif}\;z \leq 510000000000:\\ \;\;\;\;\frac{x}{t \cdot y}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (/ (/ x z) z)))
   (if (<= z -1.62e+44)
     t_1
     (if (<= z -1.65e-17)
       (/ x (* y (- z)))
       (if (<= z 510000000000.0) (/ x (* t y)) t_1)))))
assert(y < t);
double code(double x, double y, double z, double t) {
	double t_1 = (x / z) / z;
	double tmp;
	if (z <= -1.62e+44) {
		tmp = t_1;
	} else if (z <= -1.65e-17) {
		tmp = x / (y * -z);
	} else if (z <= 510000000000.0) {
		tmp = x / (t * y);
	} else {
		tmp = t_1;
	}
	return tmp;
}
NOTE: y and t should be sorted in increasing order before calling this function.
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 / z) / z
    if (z <= (-1.62d+44)) then
        tmp = t_1
    else if (z <= (-1.65d-17)) then
        tmp = x / (y * -z)
    else if (z <= 510000000000.0d0) then
        tmp = x / (t * y)
    else
        tmp = t_1
    end if
    code = tmp
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	double t_1 = (x / z) / z;
	double tmp;
	if (z <= -1.62e+44) {
		tmp = t_1;
	} else if (z <= -1.65e-17) {
		tmp = x / (y * -z);
	} else if (z <= 510000000000.0) {
		tmp = x / (t * y);
	} else {
		tmp = t_1;
	}
	return tmp;
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	t_1 = (x / z) / z
	tmp = 0
	if z <= -1.62e+44:
		tmp = t_1
	elif z <= -1.65e-17:
		tmp = x / (y * -z)
	elif z <= 510000000000.0:
		tmp = x / (t * y)
	else:
		tmp = t_1
	return tmp
y, t = sort([y, t])
function code(x, y, z, t)
	t_1 = Float64(Float64(x / z) / z)
	tmp = 0.0
	if (z <= -1.62e+44)
		tmp = t_1;
	elseif (z <= -1.65e-17)
		tmp = Float64(x / Float64(y * Float64(-z)));
	elseif (z <= 510000000000.0)
		tmp = Float64(x / Float64(t * y));
	else
		tmp = t_1;
	end
	return tmp
end
y, t = num2cell(sort([y, t])){:}
function tmp_2 = code(x, y, z, t)
	t_1 = (x / z) / z;
	tmp = 0.0;
	if (z <= -1.62e+44)
		tmp = t_1;
	elseif (z <= -1.65e-17)
		tmp = x / (y * -z);
	elseif (z <= 510000000000.0)
		tmp = x / (t * y);
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x / z), $MachinePrecision] / z), $MachinePrecision]}, If[LessEqual[z, -1.62e+44], t$95$1, If[LessEqual[z, -1.65e-17], N[(x / N[(y * (-z)), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 510000000000.0], N[(x / N[(t * y), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\begin{array}{l}
t_1 := \frac{\frac{x}{z}}{z}\\
\mathbf{if}\;z \leq -1.62 \cdot 10^{+44}:\\
\;\;\;\;t_1\\

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.6199999999999999e44 or 5.1e11 < z

    1. Initial program 86.5%

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

      \[\leadsto \color{blue}{\frac{x}{{z}^{2}}} \]
    3. Step-by-step derivation
      1. unpow273.4%

        \[\leadsto \frac{x}{\color{blue}{z \cdot z}} \]
      2. associate-/r*77.0%

        \[\leadsto \color{blue}{\frac{\frac{x}{z}}{z}} \]
    4. Simplified77.0%

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

    if -1.6199999999999999e44 < z < -1.65e-17

    1. Initial program 99.6%

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

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

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

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

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

        \[\leadsto \frac{x}{\color{blue}{-y \cdot z}} \]
      2. *-commutative52.9%

        \[\leadsto \frac{x}{-\color{blue}{z \cdot y}} \]
      3. distribute-rgt-neg-in52.9%

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

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

    if -1.65e-17 < z < 5.1e11

    1. Initial program 92.1%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.62 \cdot 10^{+44}:\\ \;\;\;\;\frac{\frac{x}{z}}{z}\\ \mathbf{elif}\;z \leq -1.65 \cdot 10^{-17}:\\ \;\;\;\;\frac{x}{y \cdot \left(-z\right)}\\ \mathbf{elif}\;z \leq 510000000000:\\ \;\;\;\;\frac{x}{t \cdot y}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{z}}{z}\\ \end{array} \]

Alternative 10: 66.3% accurate, 0.8× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \begin{array}{l} t_1 := \frac{\frac{x}{z}}{z}\\ \mathbf{if}\;z \leq -5.5 \cdot 10^{+49}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -1.1 \cdot 10^{-13}:\\ \;\;\;\;\frac{-\frac{x}{y}}{z}\\ \mathbf{elif}\;z \leq 12200000000:\\ \;\;\;\;\frac{x}{t \cdot y}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (/ (/ x z) z)))
   (if (<= z -5.5e+49)
     t_1
     (if (<= z -1.1e-13)
       (/ (- (/ x y)) z)
       (if (<= z 12200000000.0) (/ x (* t y)) t_1)))))
assert(y < t);
double code(double x, double y, double z, double t) {
	double t_1 = (x / z) / z;
	double tmp;
	if (z <= -5.5e+49) {
		tmp = t_1;
	} else if (z <= -1.1e-13) {
		tmp = -(x / y) / z;
	} else if (z <= 12200000000.0) {
		tmp = x / (t * y);
	} else {
		tmp = t_1;
	}
	return tmp;
}
NOTE: y and t should be sorted in increasing order before calling this function.
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 / z) / z
    if (z <= (-5.5d+49)) then
        tmp = t_1
    else if (z <= (-1.1d-13)) then
        tmp = -(x / y) / z
    else if (z <= 12200000000.0d0) then
        tmp = x / (t * y)
    else
        tmp = t_1
    end if
    code = tmp
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	double t_1 = (x / z) / z;
	double tmp;
	if (z <= -5.5e+49) {
		tmp = t_1;
	} else if (z <= -1.1e-13) {
		tmp = -(x / y) / z;
	} else if (z <= 12200000000.0) {
		tmp = x / (t * y);
	} else {
		tmp = t_1;
	}
	return tmp;
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	t_1 = (x / z) / z
	tmp = 0
	if z <= -5.5e+49:
		tmp = t_1
	elif z <= -1.1e-13:
		tmp = -(x / y) / z
	elif z <= 12200000000.0:
		tmp = x / (t * y)
	else:
		tmp = t_1
	return tmp
y, t = sort([y, t])
function code(x, y, z, t)
	t_1 = Float64(Float64(x / z) / z)
	tmp = 0.0
	if (z <= -5.5e+49)
		tmp = t_1;
	elseif (z <= -1.1e-13)
		tmp = Float64(Float64(-Float64(x / y)) / z);
	elseif (z <= 12200000000.0)
		tmp = Float64(x / Float64(t * y));
	else
		tmp = t_1;
	end
	return tmp
end
y, t = num2cell(sort([y, t])){:}
function tmp_2 = code(x, y, z, t)
	t_1 = (x / z) / z;
	tmp = 0.0;
	if (z <= -5.5e+49)
		tmp = t_1;
	elseif (z <= -1.1e-13)
		tmp = -(x / y) / z;
	elseif (z <= 12200000000.0)
		tmp = x / (t * y);
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x / z), $MachinePrecision] / z), $MachinePrecision]}, If[LessEqual[z, -5.5e+49], t$95$1, If[LessEqual[z, -1.1e-13], N[((-N[(x / y), $MachinePrecision]) / z), $MachinePrecision], If[LessEqual[z, 12200000000.0], N[(x / N[(t * y), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\begin{array}{l}
t_1 := \frac{\frac{x}{z}}{z}\\
\mathbf{if}\;z \leq -5.5 \cdot 10^{+49}:\\
\;\;\;\;t_1\\

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -5.50000000000000042e49 or 1.22e10 < z

    1. Initial program 86.5%

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

      \[\leadsto \color{blue}{\frac{x}{{z}^{2}}} \]
    3. Step-by-step derivation
      1. unpow273.4%

        \[\leadsto \frac{x}{\color{blue}{z \cdot z}} \]
      2. associate-/r*77.0%

        \[\leadsto \color{blue}{\frac{\frac{x}{z}}{z}} \]
    4. Simplified77.0%

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

    if -5.50000000000000042e49 < z < -1.09999999999999998e-13

    1. Initial program 99.6%

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

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

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{x}{y \cdot z}} \]
    6. Step-by-step derivation
      1. mul-1-neg52.9%

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

        \[\leadsto -\color{blue}{\frac{\frac{x}{y}}{z}} \]
      3. distribute-neg-frac52.7%

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

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

    if -1.09999999999999998e-13 < z < 1.22e10

    1. Initial program 92.1%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -5.5 \cdot 10^{+49}:\\ \;\;\;\;\frac{\frac{x}{z}}{z}\\ \mathbf{elif}\;z \leq -1.1 \cdot 10^{-13}:\\ \;\;\;\;\frac{-\frac{x}{y}}{z}\\ \mathbf{elif}\;z \leq 12200000000:\\ \;\;\;\;\frac{x}{t \cdot y}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{z}}{z}\\ \end{array} \]

Alternative 11: 72.5% accurate, 0.8× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq -2.4 \cdot 10^{-43}:\\ \;\;\;\;\frac{x}{\left(t - z\right) \cdot y}\\ \mathbf{elif}\;y \leq 6.1 \cdot 10^{-307}:\\ \;\;\;\;\frac{1}{z \cdot \frac{z}{x}}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{t \cdot \left(y - z\right)}\\ \end{array} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
 :precision binary64
 (if (<= y -2.4e-43)
   (/ x (* (- t z) y))
   (if (<= y 6.1e-307) (/ 1.0 (* z (/ z x))) (/ x (* t (- y z))))))
assert(y < t);
double code(double x, double y, double z, double t) {
	double tmp;
	if (y <= -2.4e-43) {
		tmp = x / ((t - z) * y);
	} else if (y <= 6.1e-307) {
		tmp = 1.0 / (z * (z / x));
	} else {
		tmp = x / (t * (y - z));
	}
	return tmp;
}
NOTE: y and t should be sorted in increasing order before calling this function.
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 <= (-2.4d-43)) then
        tmp = x / ((t - z) * y)
    else if (y <= 6.1d-307) then
        tmp = 1.0d0 / (z * (z / x))
    else
        tmp = x / (t * (y - z))
    end if
    code = tmp
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (y <= -2.4e-43) {
		tmp = x / ((t - z) * y);
	} else if (y <= 6.1e-307) {
		tmp = 1.0 / (z * (z / x));
	} else {
		tmp = x / (t * (y - z));
	}
	return tmp;
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	tmp = 0
	if y <= -2.4e-43:
		tmp = x / ((t - z) * y)
	elif y <= 6.1e-307:
		tmp = 1.0 / (z * (z / x))
	else:
		tmp = x / (t * (y - z))
	return tmp
y, t = sort([y, t])
function code(x, y, z, t)
	tmp = 0.0
	if (y <= -2.4e-43)
		tmp = Float64(x / Float64(Float64(t - z) * y));
	elseif (y <= 6.1e-307)
		tmp = Float64(1.0 / Float64(z * Float64(z / x)));
	else
		tmp = Float64(x / Float64(t * Float64(y - z)));
	end
	return tmp
end
y, t = num2cell(sort([y, t])){:}
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (y <= -2.4e-43)
		tmp = x / ((t - z) * y);
	elseif (y <= 6.1e-307)
		tmp = 1.0 / (z * (z / x));
	else
		tmp = x / (t * (y - z));
	end
	tmp_2 = tmp;
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := If[LessEqual[y, -2.4e-43], N[(x / N[(N[(t - z), $MachinePrecision] * y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 6.1e-307], N[(1.0 / N[(z * N[(z / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(t * N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.4 \cdot 10^{-43}:\\
\;\;\;\;\frac{x}{\left(t - z\right) \cdot y}\\

\mathbf{elif}\;y \leq 6.1 \cdot 10^{-307}:\\
\;\;\;\;\frac{1}{z \cdot \frac{z}{x}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -2.4000000000000002e-43

    1. Initial program 87.1%

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

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

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

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

    if -2.4000000000000002e-43 < y < 6.09999999999999974e-307

    1. Initial program 93.9%

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

      \[\leadsto \color{blue}{\frac{x}{{z}^{2}}} \]
    3. Step-by-step derivation
      1. unpow271.3%

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

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

        \[\leadsto \color{blue}{\frac{1}{\frac{z \cdot z}{x}}} \]
      2. inv-pow72.3%

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

        \[\leadsto {\color{blue}{\left(\frac{z}{\frac{x}{z}}\right)}}^{-1} \]
    6. Applied egg-rr76.3%

      \[\leadsto \color{blue}{{\left(\frac{z}{\frac{x}{z}}\right)}^{-1}} \]
    7. Step-by-step derivation
      1. unpow-176.3%

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

        \[\leadsto \frac{1}{\color{blue}{\frac{z}{x} \cdot z}} \]
    8. Simplified76.3%

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

    if 6.09999999999999974e-307 < y

    1. Initial program 89.8%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.4 \cdot 10^{-43}:\\ \;\;\;\;\frac{x}{\left(t - z\right) \cdot y}\\ \mathbf{elif}\;y \leq 6.1 \cdot 10^{-307}:\\ \;\;\;\;\frac{1}{z \cdot \frac{z}{x}}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{t \cdot \left(y - z\right)}\\ \end{array} \]

Alternative 12: 77.1% accurate, 0.8× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq -3.05 \cdot 10^{-43}:\\ \;\;\;\;\frac{x}{\left(t - z\right) \cdot y}\\ \mathbf{elif}\;y \leq 4.7 \cdot 10^{-58}:\\ \;\;\;\;\frac{x}{z \cdot \left(z - t\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{t \cdot \left(y - z\right)}\\ \end{array} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
 :precision binary64
 (if (<= y -3.05e-43)
   (/ x (* (- t z) y))
   (if (<= y 4.7e-58) (/ x (* z (- z t))) (/ x (* t (- y z))))))
assert(y < t);
double code(double x, double y, double z, double t) {
	double tmp;
	if (y <= -3.05e-43) {
		tmp = x / ((t - z) * y);
	} else if (y <= 4.7e-58) {
		tmp = x / (z * (z - t));
	} else {
		tmp = x / (t * (y - z));
	}
	return tmp;
}
NOTE: y and t should be sorted in increasing order before calling this function.
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 <= (-3.05d-43)) then
        tmp = x / ((t - z) * y)
    else if (y <= 4.7d-58) then
        tmp = x / (z * (z - t))
    else
        tmp = x / (t * (y - z))
    end if
    code = tmp
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (y <= -3.05e-43) {
		tmp = x / ((t - z) * y);
	} else if (y <= 4.7e-58) {
		tmp = x / (z * (z - t));
	} else {
		tmp = x / (t * (y - z));
	}
	return tmp;
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	tmp = 0
	if y <= -3.05e-43:
		tmp = x / ((t - z) * y)
	elif y <= 4.7e-58:
		tmp = x / (z * (z - t))
	else:
		tmp = x / (t * (y - z))
	return tmp
y, t = sort([y, t])
function code(x, y, z, t)
	tmp = 0.0
	if (y <= -3.05e-43)
		tmp = Float64(x / Float64(Float64(t - z) * y));
	elseif (y <= 4.7e-58)
		tmp = Float64(x / Float64(z * Float64(z - t)));
	else
		tmp = Float64(x / Float64(t * Float64(y - z)));
	end
	return tmp
end
y, t = num2cell(sort([y, t])){:}
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (y <= -3.05e-43)
		tmp = x / ((t - z) * y);
	elseif (y <= 4.7e-58)
		tmp = x / (z * (z - t));
	else
		tmp = x / (t * (y - z));
	end
	tmp_2 = tmp;
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := If[LessEqual[y, -3.05e-43], N[(x / N[(N[(t - z), $MachinePrecision] * y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 4.7e-58], N[(x / N[(z * N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(t * N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.05 \cdot 10^{-43}:\\
\;\;\;\;\frac{x}{\left(t - z\right) \cdot y}\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -3.05000000000000019e-43

    1. Initial program 87.1%

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

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

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

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

    if -3.05000000000000019e-43 < y < 4.69999999999999994e-58

    1. Initial program 91.3%

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

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

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

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

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

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

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

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

    if 4.69999999999999994e-58 < y

    1. Initial program 90.5%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -3.05 \cdot 10^{-43}:\\ \;\;\;\;\frac{x}{\left(t - z\right) \cdot y}\\ \mathbf{elif}\;y \leq 4.7 \cdot 10^{-58}:\\ \;\;\;\;\frac{x}{z \cdot \left(z - t\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{t \cdot \left(y - z\right)}\\ \end{array} \]

Alternative 13: 78.0% accurate, 0.8× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq -2.35 \cdot 10^{-43}:\\ \;\;\;\;\frac{x}{\left(t - z\right) \cdot y}\\ \mathbf{elif}\;y \leq 2 \cdot 10^{-57}:\\ \;\;\;\;\frac{x}{z \cdot \left(z - t\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{t}}{y - z}\\ \end{array} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
 :precision binary64
 (if (<= y -2.35e-43)
   (/ x (* (- t z) y))
   (if (<= y 2e-57) (/ x (* z (- z t))) (/ (/ x t) (- y z)))))
assert(y < t);
double code(double x, double y, double z, double t) {
	double tmp;
	if (y <= -2.35e-43) {
		tmp = x / ((t - z) * y);
	} else if (y <= 2e-57) {
		tmp = x / (z * (z - t));
	} else {
		tmp = (x / t) / (y - z);
	}
	return tmp;
}
NOTE: y and t should be sorted in increasing order before calling this function.
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 <= (-2.35d-43)) then
        tmp = x / ((t - z) * y)
    else if (y <= 2d-57) then
        tmp = x / (z * (z - t))
    else
        tmp = (x / t) / (y - z)
    end if
    code = tmp
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (y <= -2.35e-43) {
		tmp = x / ((t - z) * y);
	} else if (y <= 2e-57) {
		tmp = x / (z * (z - t));
	} else {
		tmp = (x / t) / (y - z);
	}
	return tmp;
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	tmp = 0
	if y <= -2.35e-43:
		tmp = x / ((t - z) * y)
	elif y <= 2e-57:
		tmp = x / (z * (z - t))
	else:
		tmp = (x / t) / (y - z)
	return tmp
y, t = sort([y, t])
function code(x, y, z, t)
	tmp = 0.0
	if (y <= -2.35e-43)
		tmp = Float64(x / Float64(Float64(t - z) * y));
	elseif (y <= 2e-57)
		tmp = Float64(x / Float64(z * Float64(z - t)));
	else
		tmp = Float64(Float64(x / t) / Float64(y - z));
	end
	return tmp
end
y, t = num2cell(sort([y, t])){:}
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (y <= -2.35e-43)
		tmp = x / ((t - z) * y);
	elseif (y <= 2e-57)
		tmp = x / (z * (z - t));
	else
		tmp = (x / t) / (y - z);
	end
	tmp_2 = tmp;
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := If[LessEqual[y, -2.35e-43], N[(x / N[(N[(t - z), $MachinePrecision] * y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2e-57], N[(x / N[(z * N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x / t), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.35 \cdot 10^{-43}:\\
\;\;\;\;\frac{x}{\left(t - z\right) \cdot y}\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -2.35e-43

    1. Initial program 87.1%

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

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

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

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

    if -2.35e-43 < y < 1.99999999999999991e-57

    1. Initial program 91.3%

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

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

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

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

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

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

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

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

    if 1.99999999999999991e-57 < y

    1. Initial program 90.5%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.35 \cdot 10^{-43}:\\ \;\;\;\;\frac{x}{\left(t - z\right) \cdot y}\\ \mathbf{elif}\;y \leq 2 \cdot 10^{-57}:\\ \;\;\;\;\frac{x}{z \cdot \left(z - t\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{t}}{y - z}\\ \end{array} \]

Alternative 14: 79.2% accurate, 0.8× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq -4.8 \cdot 10^{-43}:\\ \;\;\;\;\frac{\frac{x}{y}}{t - z}\\ \mathbf{elif}\;y \leq 1.7 \cdot 10^{-57}:\\ \;\;\;\;\frac{x}{z \cdot \left(z - t\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{t}}{y - z}\\ \end{array} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
 :precision binary64
 (if (<= y -4.8e-43)
   (/ (/ x y) (- t z))
   (if (<= y 1.7e-57) (/ x (* z (- z t))) (/ (/ x t) (- y z)))))
assert(y < t);
double code(double x, double y, double z, double t) {
	double tmp;
	if (y <= -4.8e-43) {
		tmp = (x / y) / (t - z);
	} else if (y <= 1.7e-57) {
		tmp = x / (z * (z - t));
	} else {
		tmp = (x / t) / (y - z);
	}
	return tmp;
}
NOTE: y and t should be sorted in increasing order before calling this function.
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 <= (-4.8d-43)) then
        tmp = (x / y) / (t - z)
    else if (y <= 1.7d-57) then
        tmp = x / (z * (z - t))
    else
        tmp = (x / t) / (y - z)
    end if
    code = tmp
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (y <= -4.8e-43) {
		tmp = (x / y) / (t - z);
	} else if (y <= 1.7e-57) {
		tmp = x / (z * (z - t));
	} else {
		tmp = (x / t) / (y - z);
	}
	return tmp;
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	tmp = 0
	if y <= -4.8e-43:
		tmp = (x / y) / (t - z)
	elif y <= 1.7e-57:
		tmp = x / (z * (z - t))
	else:
		tmp = (x / t) / (y - z)
	return tmp
y, t = sort([y, t])
function code(x, y, z, t)
	tmp = 0.0
	if (y <= -4.8e-43)
		tmp = Float64(Float64(x / y) / Float64(t - z));
	elseif (y <= 1.7e-57)
		tmp = Float64(x / Float64(z * Float64(z - t)));
	else
		tmp = Float64(Float64(x / t) / Float64(y - z));
	end
	return tmp
end
y, t = num2cell(sort([y, t])){:}
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (y <= -4.8e-43)
		tmp = (x / y) / (t - z);
	elseif (y <= 1.7e-57)
		tmp = x / (z * (z - t));
	else
		tmp = (x / t) / (y - z);
	end
	tmp_2 = tmp;
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := If[LessEqual[y, -4.8e-43], N[(N[(x / y), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.7e-57], N[(x / N[(z * N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x / t), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.8 \cdot 10^{-43}:\\
\;\;\;\;\frac{\frac{x}{y}}{t - z}\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -4.8000000000000004e-43

    1. Initial program 87.1%

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

        \[\leadsto \color{blue}{\frac{\frac{x}{y - z}}{t - z}} \]
    3. Simplified98.2%

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

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

    if -4.8000000000000004e-43 < y < 1.70000000000000008e-57

    1. Initial program 91.3%

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

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

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

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

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

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

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

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

    if 1.70000000000000008e-57 < y

    1. Initial program 90.5%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -4.8 \cdot 10^{-43}:\\ \;\;\;\;\frac{\frac{x}{y}}{t - z}\\ \mathbf{elif}\;y \leq 1.7 \cdot 10^{-57}:\\ \;\;\;\;\frac{x}{z \cdot \left(z - t\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{x}{t}}{y - z}\\ \end{array} \]

Alternative 15: 90.1% accurate, 0.8× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq -1.4 \cdot 10^{+161}:\\ \;\;\;\;\frac{1}{\frac{y}{\frac{x}{t - z}}}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{\left(t - z\right) \cdot \left(y - z\right)}\\ \end{array} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
 :precision binary64
 (if (<= y -1.4e+161) (/ 1.0 (/ y (/ x (- t z)))) (/ x (* (- t z) (- y z)))))
assert(y < t);
double code(double x, double y, double z, double t) {
	double tmp;
	if (y <= -1.4e+161) {
		tmp = 1.0 / (y / (x / (t - z)));
	} else {
		tmp = x / ((t - z) * (y - z));
	}
	return tmp;
}
NOTE: y and t should be sorted in increasing order before calling this function.
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.4d+161)) then
        tmp = 1.0d0 / (y / (x / (t - z)))
    else
        tmp = x / ((t - z) * (y - z))
    end if
    code = tmp
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (y <= -1.4e+161) {
		tmp = 1.0 / (y / (x / (t - z)));
	} else {
		tmp = x / ((t - z) * (y - z));
	}
	return tmp;
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	tmp = 0
	if y <= -1.4e+161:
		tmp = 1.0 / (y / (x / (t - z)))
	else:
		tmp = x / ((t - z) * (y - z))
	return tmp
y, t = sort([y, t])
function code(x, y, z, t)
	tmp = 0.0
	if (y <= -1.4e+161)
		tmp = Float64(1.0 / Float64(y / Float64(x / Float64(t - z))));
	else
		tmp = Float64(x / Float64(Float64(t - z) * Float64(y - z)));
	end
	return tmp
end
y, t = num2cell(sort([y, t])){:}
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (y <= -1.4e+161)
		tmp = 1.0 / (y / (x / (t - z)));
	else
		tmp = x / ((t - z) * (y - z));
	end
	tmp_2 = tmp;
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := If[LessEqual[y, -1.4e+161], N[(1.0 / N[(y / N[(x / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(N[(t - z), $MachinePrecision] * N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.4 \cdot 10^{+161}:\\
\;\;\;\;\frac{1}{\frac{y}{\frac{x}{t - z}}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -1.4000000000000001e161

    1. Initial program 77.1%

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{{\left(\frac{y \cdot \left(t - z\right)}{x}\right)}^{-1}} \]
    7. Step-by-step derivation
      1. unpow-177.0%

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

        \[\leadsto \frac{1}{\color{blue}{\frac{y}{\frac{x}{t - z}}}} \]
    8. Simplified98.8%

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

    if -1.4000000000000001e161 < y

    1. Initial program 91.6%

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

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

Alternative 16: 46.9% accurate, 1.0× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \begin{array}{l} \mathbf{if}\;z \leq -3.5 \cdot 10^{+26} \lor \neg \left(z \leq 6.4 \cdot 10^{+57}\right):\\ \;\;\;\;\frac{x}{z \cdot y}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{t \cdot y}\\ \end{array} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
 :precision binary64
 (if (or (<= z -3.5e+26) (not (<= z 6.4e+57))) (/ x (* z y)) (/ x (* t y))))
assert(y < t);
double code(double x, double y, double z, double t) {
	double tmp;
	if ((z <= -3.5e+26) || !(z <= 6.4e+57)) {
		tmp = x / (z * y);
	} else {
		tmp = x / (t * y);
	}
	return tmp;
}
NOTE: y and t should be sorted in increasing order before calling this function.
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 <= (-3.5d+26)) .or. (.not. (z <= 6.4d+57))) then
        tmp = x / (z * y)
    else
        tmp = x / (t * y)
    end if
    code = tmp
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	double tmp;
	if ((z <= -3.5e+26) || !(z <= 6.4e+57)) {
		tmp = x / (z * y);
	} else {
		tmp = x / (t * y);
	}
	return tmp;
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	tmp = 0
	if (z <= -3.5e+26) or not (z <= 6.4e+57):
		tmp = x / (z * y)
	else:
		tmp = x / (t * y)
	return tmp
y, t = sort([y, t])
function code(x, y, z, t)
	tmp = 0.0
	if ((z <= -3.5e+26) || !(z <= 6.4e+57))
		tmp = Float64(x / Float64(z * y));
	else
		tmp = Float64(x / Float64(t * y));
	end
	return tmp
end
y, t = num2cell(sort([y, t])){:}
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if ((z <= -3.5e+26) || ~((z <= 6.4e+57)))
		tmp = x / (z * y);
	else
		tmp = x / (t * y);
	end
	tmp_2 = tmp;
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := If[Or[LessEqual[z, -3.5e+26], N[Not[LessEqual[z, 6.4e+57]], $MachinePrecision]], N[(x / N[(z * y), $MachinePrecision]), $MachinePrecision], N[(x / N[(t * y), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.5 \cdot 10^{+26} \lor \neg \left(z \leq 6.4 \cdot 10^{+57}\right):\\
\;\;\;\;\frac{x}{z \cdot y}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -3.4999999999999999e26 or 6.40000000000000059e57 < z

    1. Initial program 86.0%

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

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

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

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

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

        \[\leadsto \frac{x}{\color{blue}{-y \cdot z}} \]
      2. *-commutative43.6%

        \[\leadsto \frac{x}{-\color{blue}{z \cdot y}} \]
      3. distribute-rgt-neg-in43.6%

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

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

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\frac{x}{z \cdot \left(-y\right)}\right)\right)} \]
      2. expm1-udef63.2%

        \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\frac{x}{z \cdot \left(-y\right)}\right)} - 1} \]
      3. add-sqr-sqrt31.9%

        \[\leadsto e^{\mathsf{log1p}\left(\frac{x}{z \cdot \color{blue}{\left(\sqrt{-y} \cdot \sqrt{-y}\right)}}\right)} - 1 \]
      4. sqrt-unprod56.5%

        \[\leadsto e^{\mathsf{log1p}\left(\frac{x}{z \cdot \color{blue}{\sqrt{\left(-y\right) \cdot \left(-y\right)}}}\right)} - 1 \]
      5. sqr-neg56.5%

        \[\leadsto e^{\mathsf{log1p}\left(\frac{x}{z \cdot \sqrt{\color{blue}{y \cdot y}}}\right)} - 1 \]
      6. sqrt-unprod30.9%

        \[\leadsto e^{\mathsf{log1p}\left(\frac{x}{z \cdot \color{blue}{\left(\sqrt{y} \cdot \sqrt{y}\right)}}\right)} - 1 \]
      7. add-sqr-sqrt63.0%

        \[\leadsto e^{\mathsf{log1p}\left(\frac{x}{z \cdot \color{blue}{y}}\right)} - 1 \]
    9. Applied egg-rr63.0%

      \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\frac{x}{z \cdot y}\right)} - 1} \]
    10. Step-by-step derivation
      1. expm1-def40.3%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\frac{x}{z \cdot y}\right)\right)} \]
      2. expm1-log1p40.6%

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

        \[\leadsto \frac{x}{\color{blue}{y \cdot z}} \]
    11. Simplified40.6%

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

    if -3.4999999999999999e26 < z < 6.40000000000000059e57

    1. Initial program 93.3%

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

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

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

Alternative 17: 62.4% accurate, 1.0× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \begin{array}{l} \mathbf{if}\;z \leq -4.2 \cdot 10^{-9} \lor \neg \left(z \leq 4 \cdot 10^{+16}\right):\\ \;\;\;\;\frac{x}{z \cdot z}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{t \cdot y}\\ \end{array} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
 :precision binary64
 (if (or (<= z -4.2e-9) (not (<= z 4e+16))) (/ x (* z z)) (/ x (* t y))))
assert(y < t);
double code(double x, double y, double z, double t) {
	double tmp;
	if ((z <= -4.2e-9) || !(z <= 4e+16)) {
		tmp = x / (z * z);
	} else {
		tmp = x / (t * y);
	}
	return tmp;
}
NOTE: y and t should be sorted in increasing order before calling this function.
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 <= (-4.2d-9)) .or. (.not. (z <= 4d+16))) then
        tmp = x / (z * z)
    else
        tmp = x / (t * y)
    end if
    code = tmp
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	double tmp;
	if ((z <= -4.2e-9) || !(z <= 4e+16)) {
		tmp = x / (z * z);
	} else {
		tmp = x / (t * y);
	}
	return tmp;
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	tmp = 0
	if (z <= -4.2e-9) or not (z <= 4e+16):
		tmp = x / (z * z)
	else:
		tmp = x / (t * y)
	return tmp
y, t = sort([y, t])
function code(x, y, z, t)
	tmp = 0.0
	if ((z <= -4.2e-9) || !(z <= 4e+16))
		tmp = Float64(x / Float64(z * z));
	else
		tmp = Float64(x / Float64(t * y));
	end
	return tmp
end
y, t = num2cell(sort([y, t])){:}
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if ((z <= -4.2e-9) || ~((z <= 4e+16)))
		tmp = x / (z * z);
	else
		tmp = x / (t * y);
	end
	tmp_2 = tmp;
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := If[Or[LessEqual[z, -4.2e-9], N[Not[LessEqual[z, 4e+16]], $MachinePrecision]], N[(x / N[(z * z), $MachinePrecision]), $MachinePrecision], N[(x / N[(t * y), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -4.2 \cdot 10^{-9} \lor \neg \left(z \leq 4 \cdot 10^{+16}\right):\\
\;\;\;\;\frac{x}{z \cdot z}\\

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


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

    1. Initial program 87.8%

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

      \[\leadsto \color{blue}{\frac{x}{{z}^{2}}} \]
    3. Step-by-step derivation
      1. unpow269.7%

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

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

    if -4.20000000000000039e-9 < z < 4e16

    1. Initial program 92.2%

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

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

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

Alternative 18: 66.3% accurate, 1.0× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \begin{array}{l} \mathbf{if}\;z \leq -1.45 \cdot 10^{-9} \lor \neg \left(z \leq 34500000000000\right):\\ \;\;\;\;\frac{\frac{x}{z}}{z}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{t \cdot y}\\ \end{array} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t)
 :precision binary64
 (if (or (<= z -1.45e-9) (not (<= z 34500000000000.0)))
   (/ (/ x z) z)
   (/ x (* t y))))
assert(y < t);
double code(double x, double y, double z, double t) {
	double tmp;
	if ((z <= -1.45e-9) || !(z <= 34500000000000.0)) {
		tmp = (x / z) / z;
	} else {
		tmp = x / (t * y);
	}
	return tmp;
}
NOTE: y and t should be sorted in increasing order before calling this function.
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 <= (-1.45d-9)) .or. (.not. (z <= 34500000000000.0d0))) then
        tmp = (x / z) / z
    else
        tmp = x / (t * y)
    end if
    code = tmp
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	double tmp;
	if ((z <= -1.45e-9) || !(z <= 34500000000000.0)) {
		tmp = (x / z) / z;
	} else {
		tmp = x / (t * y);
	}
	return tmp;
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	tmp = 0
	if (z <= -1.45e-9) or not (z <= 34500000000000.0):
		tmp = (x / z) / z
	else:
		tmp = x / (t * y)
	return tmp
y, t = sort([y, t])
function code(x, y, z, t)
	tmp = 0.0
	if ((z <= -1.45e-9) || !(z <= 34500000000000.0))
		tmp = Float64(Float64(x / z) / z);
	else
		tmp = Float64(x / Float64(t * y));
	end
	return tmp
end
y, t = num2cell(sort([y, t])){:}
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if ((z <= -1.45e-9) || ~((z <= 34500000000000.0)))
		tmp = (x / z) / z;
	else
		tmp = x / (t * y);
	end
	tmp_2 = tmp;
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := If[Or[LessEqual[z, -1.45e-9], N[Not[LessEqual[z, 34500000000000.0]], $MachinePrecision]], N[(N[(x / z), $MachinePrecision] / z), $MachinePrecision], N[(x / N[(t * y), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.45 \cdot 10^{-9} \lor \neg \left(z \leq 34500000000000\right):\\
\;\;\;\;\frac{\frac{x}{z}}{z}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.44999999999999996e-9 or 3.45e13 < z

    1. Initial program 87.8%

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

      \[\leadsto \color{blue}{\frac{x}{{z}^{2}}} \]
    3. Step-by-step derivation
      1. unpow269.7%

        \[\leadsto \frac{x}{\color{blue}{z \cdot z}} \]
      2. associate-/r*72.9%

        \[\leadsto \color{blue}{\frac{\frac{x}{z}}{z}} \]
    4. Simplified72.9%

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

    if -1.44999999999999996e-9 < z < 3.45e13

    1. Initial program 92.2%

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

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

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

Alternative 19: 40.3% accurate, 1.8× speedup?

\[\begin{array}{l} [y, t] = \mathsf{sort}([y, t])\\ \\ \frac{x}{t \cdot y} \end{array} \]
NOTE: y and t should be sorted in increasing order before calling this function.
(FPCore (x y z t) :precision binary64 (/ x (* t y)))
assert(y < t);
double code(double x, double y, double z, double t) {
	return x / (t * y);
}
NOTE: y and t should be sorted in increasing order before calling this function.
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 * y)
end function
assert y < t;
public static double code(double x, double y, double z, double t) {
	return x / (t * y);
}
[y, t] = sort([y, t])
def code(x, y, z, t):
	return x / (t * y)
y, t = sort([y, t])
function code(x, y, z, t)
	return Float64(x / Float64(t * y))
end
y, t = num2cell(sort([y, t])){:}
function tmp = code(x, y, z, t)
	tmp = x / (t * y);
end
NOTE: y and t should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_] := N[(x / N[(t * y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[y, t] = \mathsf{sort}([y, t])\\
\\
\frac{x}{t \cdot y}
\end{array}
Derivation
  1. Initial program 89.7%

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

    \[\leadsto \color{blue}{\frac{x}{y \cdot t}} \]
  3. Final simplification41.0%

    \[\leadsto \frac{x}{t \cdot y} \]

Developer target: 87.6% accurate, 0.4× speedup?

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

\\
\begin{array}{l}
t_1 := \left(y - z\right) \cdot \left(t - z\right)\\
\mathbf{if}\;\frac{x}{t_1} < 0:\\
\;\;\;\;\frac{\frac{x}{y - z}}{t - z}\\

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


\end{array}
\end{array}

Reproduce

?
herbie shell --seed 2023279 
(FPCore (x y z t)
  :name "Data.Random.Distribution.Triangular:triangularCDF from random-fu-0.2.6.2, B"
  :precision binary64

  :herbie-target
  (if (< (/ x (* (- y z) (- t z))) 0.0) (/ (/ x (- y z)) (- t z)) (* x (/ 1.0 (* (- y z) (- t z)))))

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