Graphics.Rendering.Chart.Plot.AreaSpots:renderAreaSpots4D from Chart-1.5.3

Percentage Accurate: 84.0% → 96.9%
Time: 12.4s
Alternatives: 17
Speedup: 1.0×

Specification

?
\[\begin{array}{l} \\ \frac{x \cdot \left(y - z\right)}{t - z} \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(Float64(x * 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[(N[(x * N[(y - z), $MachinePrecision]), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

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

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

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

Accuracy vs Speed?

Herbie found 17 alternatives:

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

Initial Program: 84.0% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \frac{x \cdot \left(y - z\right)}{t - z} \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(Float64(x * 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[(N[(x * N[(y - z), $MachinePrecision]), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

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

Alternative 1: 96.9% accurate, 1.0× speedup?

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

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

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

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

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

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

Alternative 2: 67.2% accurate, 0.5× speedup?

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

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

\mathbf{elif}\;z \leq -140000000:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq -1.9 \cdot 10^{-21}:\\
\;\;\;\;x\\

\mathbf{elif}\;z \leq 2 \cdot 10^{-239}:\\
\;\;\;\;t_1\\

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

\mathbf{elif}\;z \leq 8100000000:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -4.1000000000000001e114 or -1.4e8 < z < -1.8999999999999999e-21 or 8.1e9 < z

    1. Initial program 75.8%

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

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

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

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

    if -4.1000000000000001e114 < z < -1.4e8 or -1.8999999999999999e-21 < z < 2.0000000000000002e-239 or 1.28000000000000005e-95 < z < 8.1e9

    1. Initial program 93.9%

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

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

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

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

    if 2.0000000000000002e-239 < z < 1.28000000000000005e-95

    1. Initial program 90.4%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -4.1 \cdot 10^{+114}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq -140000000:\\ \;\;\;\;x \cdot \frac{y - z}{t}\\ \mathbf{elif}\;z \leq -1.9 \cdot 10^{-21}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq 2 \cdot 10^{-239}:\\ \;\;\;\;x \cdot \frac{y - z}{t}\\ \mathbf{elif}\;z \leq 1.28 \cdot 10^{-95}:\\ \;\;\;\;x \cdot \frac{y}{t - z}\\ \mathbf{elif}\;z \leq 8100000000:\\ \;\;\;\;x \cdot \frac{y - z}{t}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 3: 67.1% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x \cdot \frac{y - z}{t}\\ \mathbf{if}\;z \leq -1.55 \cdot 10^{+111}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq -165000000:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -3.1 \cdot 10^{-21}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq 1.9 \cdot 10^{-239}:\\ \;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\ \mathbf{elif}\;z \leq 8.5 \cdot 10^{-94}:\\ \;\;\;\;x \cdot \frac{y}{t - z}\\ \mathbf{elif}\;z \leq 5700000000:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (* x (/ (- y z) t))))
   (if (<= z -1.55e+111)
     x
     (if (<= z -165000000.0)
       t_1
       (if (<= z -3.1e-21)
         x
         (if (<= z 1.9e-239)
           (* (- y z) (/ x t))
           (if (<= z 8.5e-94)
             (* x (/ y (- t z)))
             (if (<= z 5700000000.0) t_1 x))))))))
double code(double x, double y, double z, double t) {
	double t_1 = x * ((y - z) / t);
	double tmp;
	if (z <= -1.55e+111) {
		tmp = x;
	} else if (z <= -165000000.0) {
		tmp = t_1;
	} else if (z <= -3.1e-21) {
		tmp = x;
	} else if (z <= 1.9e-239) {
		tmp = (y - z) * (x / t);
	} else if (z <= 8.5e-94) {
		tmp = x * (y / (t - z));
	} else if (z <= 5700000000.0) {
		tmp = t_1;
	} else {
		tmp = x;
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: t_1
    real(8) :: tmp
    t_1 = x * ((y - z) / t)
    if (z <= (-1.55d+111)) then
        tmp = x
    else if (z <= (-165000000.0d0)) then
        tmp = t_1
    else if (z <= (-3.1d-21)) then
        tmp = x
    else if (z <= 1.9d-239) then
        tmp = (y - z) * (x / t)
    else if (z <= 8.5d-94) then
        tmp = x * (y / (t - z))
    else if (z <= 5700000000.0d0) then
        tmp = t_1
    else
        tmp = x
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double t_1 = x * ((y - z) / t);
	double tmp;
	if (z <= -1.55e+111) {
		tmp = x;
	} else if (z <= -165000000.0) {
		tmp = t_1;
	} else if (z <= -3.1e-21) {
		tmp = x;
	} else if (z <= 1.9e-239) {
		tmp = (y - z) * (x / t);
	} else if (z <= 8.5e-94) {
		tmp = x * (y / (t - z));
	} else if (z <= 5700000000.0) {
		tmp = t_1;
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = x * ((y - z) / t)
	tmp = 0
	if z <= -1.55e+111:
		tmp = x
	elif z <= -165000000.0:
		tmp = t_1
	elif z <= -3.1e-21:
		tmp = x
	elif z <= 1.9e-239:
		tmp = (y - z) * (x / t)
	elif z <= 8.5e-94:
		tmp = x * (y / (t - z))
	elif z <= 5700000000.0:
		tmp = t_1
	else:
		tmp = x
	return tmp
function code(x, y, z, t)
	t_1 = Float64(x * Float64(Float64(y - z) / t))
	tmp = 0.0
	if (z <= -1.55e+111)
		tmp = x;
	elseif (z <= -165000000.0)
		tmp = t_1;
	elseif (z <= -3.1e-21)
		tmp = x;
	elseif (z <= 1.9e-239)
		tmp = Float64(Float64(y - z) * Float64(x / t));
	elseif (z <= 8.5e-94)
		tmp = Float64(x * Float64(y / Float64(t - z)));
	elseif (z <= 5700000000.0)
		tmp = t_1;
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = x * ((y - z) / t);
	tmp = 0.0;
	if (z <= -1.55e+111)
		tmp = x;
	elseif (z <= -165000000.0)
		tmp = t_1;
	elseif (z <= -3.1e-21)
		tmp = x;
	elseif (z <= 1.9e-239)
		tmp = (y - z) * (x / t);
	elseif (z <= 8.5e-94)
		tmp = x * (y / (t - z));
	elseif (z <= 5700000000.0)
		tmp = t_1;
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x * N[(N[(y - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.55e+111], x, If[LessEqual[z, -165000000.0], t$95$1, If[LessEqual[z, -3.1e-21], x, If[LessEqual[z, 1.9e-239], N[(N[(y - z), $MachinePrecision] * N[(x / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 8.5e-94], N[(x * N[(y / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5700000000.0], t$95$1, x]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;z \leq -165000000:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq -3.1 \cdot 10^{-21}:\\
\;\;\;\;x\\

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

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

\mathbf{elif}\;z \leq 5700000000:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -1.55e111 or -1.65e8 < z < -3.0999999999999998e-21 or 5.7e9 < z

    1. Initial program 75.8%

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

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

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

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

    if -1.55e111 < z < -1.65e8 or 8.50000000000000003e-94 < z < 5.7e9

    1. Initial program 95.5%

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

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

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

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

    if -3.0999999999999998e-21 < z < 1.9000000000000001e-239

    1. Initial program 92.7%

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

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

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

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

    if 1.9000000000000001e-239 < z < 8.50000000000000003e-94

    1. Initial program 90.4%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.55 \cdot 10^{+111}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq -165000000:\\ \;\;\;\;x \cdot \frac{y - z}{t}\\ \mathbf{elif}\;z \leq -3.1 \cdot 10^{-21}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq 1.9 \cdot 10^{-239}:\\ \;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\ \mathbf{elif}\;z \leq 8.5 \cdot 10^{-94}:\\ \;\;\;\;x \cdot \frac{y}{t - z}\\ \mathbf{elif}\;z \leq 5700000000:\\ \;\;\;\;x \cdot \frac{y - z}{t}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 4: 59.8% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -1.15 \cdot 10^{+68}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq -165000000:\\ \;\;\;\;\frac{x \cdot \left(-z\right)}{t}\\ \mathbf{elif}\;z \leq -6.2 \cdot 10^{-18}:\\ \;\;\;\;\frac{z}{\frac{z}{x}}\\ \mathbf{elif}\;z \leq 4.5 \cdot 10^{-156}:\\ \;\;\;\;\frac{x \cdot y}{t}\\ \mathbf{elif}\;z \leq 3.8 \cdot 10^{-120}:\\ \;\;\;\;x \cdot \frac{-y}{z}\\ \mathbf{elif}\;z \leq 4100:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (<= z -1.15e+68)
   x
   (if (<= z -165000000.0)
     (/ (* x (- z)) t)
     (if (<= z -6.2e-18)
       (/ z (/ z x))
       (if (<= z 4.5e-156)
         (/ (* x y) t)
         (if (<= z 3.8e-120)
           (* x (/ (- y) z))
           (if (<= z 4100.0) (* x (/ y t)) x)))))))
double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -1.15e+68) {
		tmp = x;
	} else if (z <= -165000000.0) {
		tmp = (x * -z) / t;
	} else if (z <= -6.2e-18) {
		tmp = z / (z / x);
	} else if (z <= 4.5e-156) {
		tmp = (x * y) / t;
	} else if (z <= 3.8e-120) {
		tmp = x * (-y / z);
	} else if (z <= 4100.0) {
		tmp = x * (y / t);
	} else {
		tmp = x;
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if (z <= (-1.15d+68)) then
        tmp = x
    else if (z <= (-165000000.0d0)) then
        tmp = (x * -z) / t
    else if (z <= (-6.2d-18)) then
        tmp = z / (z / x)
    else if (z <= 4.5d-156) then
        tmp = (x * y) / t
    else if (z <= 3.8d-120) then
        tmp = x * (-y / z)
    else if (z <= 4100.0d0) then
        tmp = x * (y / t)
    else
        tmp = x
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -1.15e+68) {
		tmp = x;
	} else if (z <= -165000000.0) {
		tmp = (x * -z) / t;
	} else if (z <= -6.2e-18) {
		tmp = z / (z / x);
	} else if (z <= 4.5e-156) {
		tmp = (x * y) / t;
	} else if (z <= 3.8e-120) {
		tmp = x * (-y / z);
	} else if (z <= 4100.0) {
		tmp = x * (y / t);
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if z <= -1.15e+68:
		tmp = x
	elif z <= -165000000.0:
		tmp = (x * -z) / t
	elif z <= -6.2e-18:
		tmp = z / (z / x)
	elif z <= 4.5e-156:
		tmp = (x * y) / t
	elif z <= 3.8e-120:
		tmp = x * (-y / z)
	elif z <= 4100.0:
		tmp = x * (y / t)
	else:
		tmp = x
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if (z <= -1.15e+68)
		tmp = x;
	elseif (z <= -165000000.0)
		tmp = Float64(Float64(x * Float64(-z)) / t);
	elseif (z <= -6.2e-18)
		tmp = Float64(z / Float64(z / x));
	elseif (z <= 4.5e-156)
		tmp = Float64(Float64(x * y) / t);
	elseif (z <= 3.8e-120)
		tmp = Float64(x * Float64(Float64(-y) / z));
	elseif (z <= 4100.0)
		tmp = Float64(x * Float64(y / t));
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (z <= -1.15e+68)
		tmp = x;
	elseif (z <= -165000000.0)
		tmp = (x * -z) / t;
	elseif (z <= -6.2e-18)
		tmp = z / (z / x);
	elseif (z <= 4.5e-156)
		tmp = (x * y) / t;
	elseif (z <= 3.8e-120)
		tmp = x * (-y / z);
	elseif (z <= 4100.0)
		tmp = x * (y / t);
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[LessEqual[z, -1.15e+68], x, If[LessEqual[z, -165000000.0], N[(N[(x * (-z)), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[z, -6.2e-18], N[(z / N[(z / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.5e-156], N[(N[(x * y), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[z, 3.8e-120], N[(x * N[((-y) / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4100.0], N[(x * N[(y / t), $MachinePrecision]), $MachinePrecision], x]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.15 \cdot 10^{+68}:\\
\;\;\;\;x\\

\mathbf{elif}\;z \leq -165000000:\\
\;\;\;\;\frac{x \cdot \left(-z\right)}{t}\\

\mathbf{elif}\;z \leq -6.2 \cdot 10^{-18}:\\
\;\;\;\;\frac{z}{\frac{z}{x}}\\

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 6 regimes
  2. if z < -1.15e68 or 4100 < z

    1. Initial program 75.6%

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

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

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

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

    if -1.15e68 < z < -1.65e8

    1. Initial program 93.6%

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

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

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

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

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

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

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

    if -1.65e8 < z < -6.20000000000000014e-18

    1. Initial program 99.7%

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

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

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

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

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

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

        \[\leadsto \frac{x}{\frac{\color{blue}{0 - \left(t - z\right)}}{z}} \]
      4. associate--r-84.1%

        \[\leadsto \frac{x}{\frac{\color{blue}{\left(0 - t\right) + z}}{z}} \]
      5. neg-sub084.1%

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

      \[\leadsto \frac{x}{\color{blue}{\frac{\left(-t\right) + z}{z}}} \]
    7. Taylor expanded in x around 0 83.9%

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

        \[\leadsto \color{blue}{\frac{z}{\frac{z - t}{x}}} \]
    9. Simplified83.9%

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

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

    if -6.20000000000000014e-18 < z < 4.49999999999999986e-156

    1. Initial program 92.4%

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

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

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

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

    if 4.49999999999999986e-156 < z < 3.7999999999999997e-120

    1. Initial program 84.6%

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

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

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

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

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

        \[\leadsto x \cdot \color{blue}{\frac{-1 \cdot y}{z}} \]
      2. neg-mul-153.1%

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

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

    if 3.7999999999999997e-120 < z < 4100

    1. Initial program 96.4%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.15 \cdot 10^{+68}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq -165000000:\\ \;\;\;\;\frac{x \cdot \left(-z\right)}{t}\\ \mathbf{elif}\;z \leq -6.2 \cdot 10^{-18}:\\ \;\;\;\;\frac{z}{\frac{z}{x}}\\ \mathbf{elif}\;z \leq 4.5 \cdot 10^{-156}:\\ \;\;\;\;\frac{x \cdot y}{t}\\ \mathbf{elif}\;z \leq 3.8 \cdot 10^{-120}:\\ \;\;\;\;x \cdot \frac{-y}{z}\\ \mathbf{elif}\;z \leq 4100:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 5: 59.7% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -2.3 \cdot 10^{+69}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq -180000000:\\ \;\;\;\;z \cdot \frac{-x}{t}\\ \mathbf{elif}\;z \leq -1.15 \cdot 10^{-17}:\\ \;\;\;\;\frac{z}{\frac{z}{x}}\\ \mathbf{elif}\;z \leq 4.5 \cdot 10^{-156}:\\ \;\;\;\;\frac{x \cdot y}{t}\\ \mathbf{elif}\;z \leq 3.8 \cdot 10^{-120}:\\ \;\;\;\;x \cdot \frac{-y}{z}\\ \mathbf{elif}\;z \leq 26500:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (<= z -2.3e+69)
   x
   (if (<= z -180000000.0)
     (* z (/ (- x) t))
     (if (<= z -1.15e-17)
       (/ z (/ z x))
       (if (<= z 4.5e-156)
         (/ (* x y) t)
         (if (<= z 3.8e-120)
           (* x (/ (- y) z))
           (if (<= z 26500.0) (* x (/ y t)) x)))))))
double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -2.3e+69) {
		tmp = x;
	} else if (z <= -180000000.0) {
		tmp = z * (-x / t);
	} else if (z <= -1.15e-17) {
		tmp = z / (z / x);
	} else if (z <= 4.5e-156) {
		tmp = (x * y) / t;
	} else if (z <= 3.8e-120) {
		tmp = x * (-y / z);
	} else if (z <= 26500.0) {
		tmp = x * (y / t);
	} else {
		tmp = x;
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if (z <= (-2.3d+69)) then
        tmp = x
    else if (z <= (-180000000.0d0)) then
        tmp = z * (-x / t)
    else if (z <= (-1.15d-17)) then
        tmp = z / (z / x)
    else if (z <= 4.5d-156) then
        tmp = (x * y) / t
    else if (z <= 3.8d-120) then
        tmp = x * (-y / z)
    else if (z <= 26500.0d0) then
        tmp = x * (y / t)
    else
        tmp = x
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -2.3e+69) {
		tmp = x;
	} else if (z <= -180000000.0) {
		tmp = z * (-x / t);
	} else if (z <= -1.15e-17) {
		tmp = z / (z / x);
	} else if (z <= 4.5e-156) {
		tmp = (x * y) / t;
	} else if (z <= 3.8e-120) {
		tmp = x * (-y / z);
	} else if (z <= 26500.0) {
		tmp = x * (y / t);
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if z <= -2.3e+69:
		tmp = x
	elif z <= -180000000.0:
		tmp = z * (-x / t)
	elif z <= -1.15e-17:
		tmp = z / (z / x)
	elif z <= 4.5e-156:
		tmp = (x * y) / t
	elif z <= 3.8e-120:
		tmp = x * (-y / z)
	elif z <= 26500.0:
		tmp = x * (y / t)
	else:
		tmp = x
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if (z <= -2.3e+69)
		tmp = x;
	elseif (z <= -180000000.0)
		tmp = Float64(z * Float64(Float64(-x) / t));
	elseif (z <= -1.15e-17)
		tmp = Float64(z / Float64(z / x));
	elseif (z <= 4.5e-156)
		tmp = Float64(Float64(x * y) / t);
	elseif (z <= 3.8e-120)
		tmp = Float64(x * Float64(Float64(-y) / z));
	elseif (z <= 26500.0)
		tmp = Float64(x * Float64(y / t));
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (z <= -2.3e+69)
		tmp = x;
	elseif (z <= -180000000.0)
		tmp = z * (-x / t);
	elseif (z <= -1.15e-17)
		tmp = z / (z / x);
	elseif (z <= 4.5e-156)
		tmp = (x * y) / t;
	elseif (z <= 3.8e-120)
		tmp = x * (-y / z);
	elseif (z <= 26500.0)
		tmp = x * (y / t);
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[LessEqual[z, -2.3e+69], x, If[LessEqual[z, -180000000.0], N[(z * N[((-x) / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -1.15e-17], N[(z / N[(z / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.5e-156], N[(N[(x * y), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[z, 3.8e-120], N[(x * N[((-y) / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 26500.0], N[(x * N[(y / t), $MachinePrecision]), $MachinePrecision], x]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.3 \cdot 10^{+69}:\\
\;\;\;\;x\\

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

\mathbf{elif}\;z \leq -1.15 \cdot 10^{-17}:\\
\;\;\;\;\frac{z}{\frac{z}{x}}\\

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 6 regimes
  2. if z < -2.30000000000000017e69 or 26500 < z

    1. Initial program 75.6%

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

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

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

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

    if -2.30000000000000017e69 < z < -1.8e8

    1. Initial program 93.6%

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

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

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

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

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

        \[\leadsto \color{blue}{-\frac{z \cdot x}{t}} \]
      2. distribute-neg-frac44.7%

        \[\leadsto \color{blue}{\frac{-z \cdot x}{t}} \]
      3. distribute-lft-neg-out44.7%

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

        \[\leadsto \color{blue}{\left(-z\right) \cdot \frac{x}{t}} \]
      5. distribute-lft-neg-out44.9%

        \[\leadsto \color{blue}{-z \cdot \frac{x}{t}} \]
      6. distribute-rgt-neg-in44.9%

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

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

    if -1.8e8 < z < -1.15000000000000004e-17

    1. Initial program 99.7%

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

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

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

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

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

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

        \[\leadsto \frac{x}{\frac{\color{blue}{0 - \left(t - z\right)}}{z}} \]
      4. associate--r-84.1%

        \[\leadsto \frac{x}{\frac{\color{blue}{\left(0 - t\right) + z}}{z}} \]
      5. neg-sub084.1%

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

      \[\leadsto \frac{x}{\color{blue}{\frac{\left(-t\right) + z}{z}}} \]
    7. Taylor expanded in x around 0 83.9%

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

        \[\leadsto \color{blue}{\frac{z}{\frac{z - t}{x}}} \]
    9. Simplified83.9%

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

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

    if -1.15000000000000004e-17 < z < 4.49999999999999986e-156

    1. Initial program 92.4%

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

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

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

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

    if 4.49999999999999986e-156 < z < 3.7999999999999997e-120

    1. Initial program 84.6%

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

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

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

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

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

        \[\leadsto x \cdot \color{blue}{\frac{-1 \cdot y}{z}} \]
      2. neg-mul-153.1%

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

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

    if 3.7999999999999997e-120 < z < 26500

    1. Initial program 96.4%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.3 \cdot 10^{+69}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq -180000000:\\ \;\;\;\;z \cdot \frac{-x}{t}\\ \mathbf{elif}\;z \leq -1.15 \cdot 10^{-17}:\\ \;\;\;\;\frac{z}{\frac{z}{x}}\\ \mathbf{elif}\;z \leq 4.5 \cdot 10^{-156}:\\ \;\;\;\;\frac{x \cdot y}{t}\\ \mathbf{elif}\;z \leq 3.8 \cdot 10^{-120}:\\ \;\;\;\;x \cdot \frac{-y}{z}\\ \mathbf{elif}\;z \leq 26500:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 6: 59.8% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -2.5 \cdot 10^{+68}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq -165000000:\\ \;\;\;\;\frac{x}{\frac{-t}{z}}\\ \mathbf{elif}\;z \leq -5.2 \cdot 10^{-17}:\\ \;\;\;\;\frac{z}{\frac{z}{x}}\\ \mathbf{elif}\;z \leq 4.5 \cdot 10^{-156}:\\ \;\;\;\;\frac{x \cdot y}{t}\\ \mathbf{elif}\;z \leq 3.8 \cdot 10^{-120}:\\ \;\;\;\;x \cdot \frac{-y}{z}\\ \mathbf{elif}\;z \leq 56000:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (<= z -2.5e+68)
   x
   (if (<= z -165000000.0)
     (/ x (/ (- t) z))
     (if (<= z -5.2e-17)
       (/ z (/ z x))
       (if (<= z 4.5e-156)
         (/ (* x y) t)
         (if (<= z 3.8e-120)
           (* x (/ (- y) z))
           (if (<= z 56000.0) (* x (/ y t)) x)))))))
double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -2.5e+68) {
		tmp = x;
	} else if (z <= -165000000.0) {
		tmp = x / (-t / z);
	} else if (z <= -5.2e-17) {
		tmp = z / (z / x);
	} else if (z <= 4.5e-156) {
		tmp = (x * y) / t;
	} else if (z <= 3.8e-120) {
		tmp = x * (-y / z);
	} else if (z <= 56000.0) {
		tmp = x * (y / t);
	} else {
		tmp = x;
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if (z <= (-2.5d+68)) then
        tmp = x
    else if (z <= (-165000000.0d0)) then
        tmp = x / (-t / z)
    else if (z <= (-5.2d-17)) then
        tmp = z / (z / x)
    else if (z <= 4.5d-156) then
        tmp = (x * y) / t
    else if (z <= 3.8d-120) then
        tmp = x * (-y / z)
    else if (z <= 56000.0d0) then
        tmp = x * (y / t)
    else
        tmp = x
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -2.5e+68) {
		tmp = x;
	} else if (z <= -165000000.0) {
		tmp = x / (-t / z);
	} else if (z <= -5.2e-17) {
		tmp = z / (z / x);
	} else if (z <= 4.5e-156) {
		tmp = (x * y) / t;
	} else if (z <= 3.8e-120) {
		tmp = x * (-y / z);
	} else if (z <= 56000.0) {
		tmp = x * (y / t);
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if z <= -2.5e+68:
		tmp = x
	elif z <= -165000000.0:
		tmp = x / (-t / z)
	elif z <= -5.2e-17:
		tmp = z / (z / x)
	elif z <= 4.5e-156:
		tmp = (x * y) / t
	elif z <= 3.8e-120:
		tmp = x * (-y / z)
	elif z <= 56000.0:
		tmp = x * (y / t)
	else:
		tmp = x
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if (z <= -2.5e+68)
		tmp = x;
	elseif (z <= -165000000.0)
		tmp = Float64(x / Float64(Float64(-t) / z));
	elseif (z <= -5.2e-17)
		tmp = Float64(z / Float64(z / x));
	elseif (z <= 4.5e-156)
		tmp = Float64(Float64(x * y) / t);
	elseif (z <= 3.8e-120)
		tmp = Float64(x * Float64(Float64(-y) / z));
	elseif (z <= 56000.0)
		tmp = Float64(x * Float64(y / t));
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (z <= -2.5e+68)
		tmp = x;
	elseif (z <= -165000000.0)
		tmp = x / (-t / z);
	elseif (z <= -5.2e-17)
		tmp = z / (z / x);
	elseif (z <= 4.5e-156)
		tmp = (x * y) / t;
	elseif (z <= 3.8e-120)
		tmp = x * (-y / z);
	elseif (z <= 56000.0)
		tmp = x * (y / t);
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[LessEqual[z, -2.5e+68], x, If[LessEqual[z, -165000000.0], N[(x / N[((-t) / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -5.2e-17], N[(z / N[(z / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.5e-156], N[(N[(x * y), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[z, 3.8e-120], N[(x * N[((-y) / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 56000.0], N[(x * N[(y / t), $MachinePrecision]), $MachinePrecision], x]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.5 \cdot 10^{+68}:\\
\;\;\;\;x\\

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

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

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 6 regimes
  2. if z < -2.5000000000000002e68 or 56000 < z

    1. Initial program 75.6%

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

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

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

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

    if -2.5000000000000002e68 < z < -1.65e8

    1. Initial program 93.6%

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

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

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

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

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

        \[\leadsto \frac{x}{\color{blue}{\frac{-1 \cdot t}{z}}} \]
      2. mul-1-neg50.6%

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

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

    if -1.65e8 < z < -5.20000000000000006e-17

    1. Initial program 99.7%

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

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

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

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

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

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

        \[\leadsto \frac{x}{\frac{\color{blue}{0 - \left(t - z\right)}}{z}} \]
      4. associate--r-84.1%

        \[\leadsto \frac{x}{\frac{\color{blue}{\left(0 - t\right) + z}}{z}} \]
      5. neg-sub084.1%

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

      \[\leadsto \frac{x}{\color{blue}{\frac{\left(-t\right) + z}{z}}} \]
    7. Taylor expanded in x around 0 83.9%

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

        \[\leadsto \color{blue}{\frac{z}{\frac{z - t}{x}}} \]
    9. Simplified83.9%

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

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

    if -5.20000000000000006e-17 < z < 4.49999999999999986e-156

    1. Initial program 92.4%

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

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

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

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

    if 4.49999999999999986e-156 < z < 3.7999999999999997e-120

    1. Initial program 84.6%

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

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

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

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

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

        \[\leadsto x \cdot \color{blue}{\frac{-1 \cdot y}{z}} \]
      2. neg-mul-153.1%

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

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

    if 3.7999999999999997e-120 < z < 56000

    1. Initial program 96.4%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.5 \cdot 10^{+68}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq -165000000:\\ \;\;\;\;\frac{x}{\frac{-t}{z}}\\ \mathbf{elif}\;z \leq -5.2 \cdot 10^{-17}:\\ \;\;\;\;\frac{z}{\frac{z}{x}}\\ \mathbf{elif}\;z \leq 4.5 \cdot 10^{-156}:\\ \;\;\;\;\frac{x \cdot y}{t}\\ \mathbf{elif}\;z \leq 3.8 \cdot 10^{-120}:\\ \;\;\;\;x \cdot \frac{-y}{z}\\ \mathbf{elif}\;z \leq 56000:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 7: 59.9% accurate, 0.5× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -5.8 \cdot 10^{+68}:\\
\;\;\;\;x\\

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

\mathbf{elif}\;z \leq -3.5 \cdot 10^{-16}:\\
\;\;\;\;\frac{z}{\frac{z}{x}}\\

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 6 regimes
  2. if z < -5.80000000000000023e68 or 8.2e8 < z

    1. Initial program 75.6%

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

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

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

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

    if -5.80000000000000023e68 < z < -1.8e8

    1. Initial program 93.6%

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

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

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

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

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

        \[\leadsto \frac{x}{\color{blue}{\frac{-1 \cdot t}{z}}} \]
      2. mul-1-neg50.6%

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

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

    if -1.8e8 < z < -3.50000000000000017e-16

    1. Initial program 99.7%

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

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

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

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

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

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

        \[\leadsto \frac{x}{\frac{\color{blue}{0 - \left(t - z\right)}}{z}} \]
      4. associate--r-84.1%

        \[\leadsto \frac{x}{\frac{\color{blue}{\left(0 - t\right) + z}}{z}} \]
      5. neg-sub084.1%

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

      \[\leadsto \frac{x}{\color{blue}{\frac{\left(-t\right) + z}{z}}} \]
    7. Taylor expanded in x around 0 83.9%

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

        \[\leadsto \color{blue}{\frac{z}{\frac{z - t}{x}}} \]
    9. Simplified83.9%

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

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

    if -3.50000000000000017e-16 < z < 4.49999999999999986e-156

    1. Initial program 92.4%

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

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

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

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

    if 4.49999999999999986e-156 < z < 3.7999999999999997e-120

    1. Initial program 84.6%

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{-y \cdot \left(-x\right)}{-z}} \]
      3. add-sqr-sqrt3.3%

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

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

        \[\leadsto \frac{-y \cdot \sqrt{\color{blue}{x \cdot x}}}{-z} \]
      6. sqrt-unprod1.0%

        \[\leadsto \frac{-y \cdot \color{blue}{\left(\sqrt{x} \cdot \sqrt{x}\right)}}{-z} \]
      7. add-sqr-sqrt3.8%

        \[\leadsto \frac{-y \cdot \color{blue}{x}}{-z} \]
      8. distribute-rgt-neg-out3.8%

        \[\leadsto \frac{\color{blue}{y \cdot \left(-x\right)}}{-z} \]
      9. add-sqr-sqrt2.8%

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

        \[\leadsto \frac{y \cdot \color{blue}{\sqrt{\left(-x\right) \cdot \left(-x\right)}}}{-z} \]
      11. sqr-neg36.6%

        \[\leadsto \frac{y \cdot \sqrt{\color{blue}{x \cdot x}}}{-z} \]
      12. sqrt-unprod41.8%

        \[\leadsto \frac{y \cdot \color{blue}{\left(\sqrt{x} \cdot \sqrt{x}\right)}}{-z} \]
      13. add-sqr-sqrt45.1%

        \[\leadsto \frac{y \cdot \color{blue}{x}}{-z} \]
    9. Applied egg-rr45.1%

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

        \[\leadsto \color{blue}{\frac{y}{\frac{-z}{x}}} \]
    11. Simplified53.2%

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

    if 3.7999999999999997e-120 < z < 8.2e8

    1. Initial program 96.4%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -5.8 \cdot 10^{+68}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq -180000000:\\ \;\;\;\;\frac{x}{\frac{-t}{z}}\\ \mathbf{elif}\;z \leq -3.5 \cdot 10^{-16}:\\ \;\;\;\;\frac{z}{\frac{z}{x}}\\ \mathbf{elif}\;z \leq 4.5 \cdot 10^{-156}:\\ \;\;\;\;\frac{x \cdot y}{t}\\ \mathbf{elif}\;z \leq 3.8 \cdot 10^{-120}:\\ \;\;\;\;\frac{y}{\frac{-z}{x}}\\ \mathbf{elif}\;z \leq 820000000:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 8: 68.7% accurate, 0.6× speedup?

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

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

\mathbf{elif}\;z \leq -39000000:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq -4.5 \cdot 10^{-16}:\\
\;\;\;\;\frac{z}{\frac{z}{x}}\\

\mathbf{elif}\;z \leq 3.3 \cdot 10^{+24}:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.90000000000000006e145 or 3.2999999999999999e24 < z

    1. Initial program 72.9%

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

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

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

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

    if -1.90000000000000006e145 < z < -3.9e7 or -4.5000000000000002e-16 < z < 3.2999999999999999e24

    1. Initial program 92.8%

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

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

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

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

    if -3.9e7 < z < -4.5000000000000002e-16

    1. Initial program 99.7%

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

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

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

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

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

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

        \[\leadsto \frac{x}{\frac{\color{blue}{0 - \left(t - z\right)}}{z}} \]
      4. associate--r-100.0%

        \[\leadsto \frac{x}{\frac{\color{blue}{\left(0 - t\right) + z}}{z}} \]
      5. neg-sub0100.0%

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

      \[\leadsto \frac{x}{\color{blue}{\frac{\left(-t\right) + z}{z}}} \]
    7. Taylor expanded in x around 0 99.7%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.9 \cdot 10^{+145}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq -39000000:\\ \;\;\;\;x \cdot \frac{y}{t - z}\\ \mathbf{elif}\;z \leq -4.5 \cdot 10^{-16}:\\ \;\;\;\;\frac{z}{\frac{z}{x}}\\ \mathbf{elif}\;z \leq 3.3 \cdot 10^{+24}:\\ \;\;\;\;x \cdot \frac{y}{t - z}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 9: 72.1% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -1.18 \cdot 10^{+36}:\\ \;\;\;\;\frac{x}{\frac{t}{y - z}}\\ \mathbf{elif}\;t \leq 1.56 \cdot 10^{-44}:\\ \;\;\;\;\frac{x}{\frac{z}{z - y}}\\ \mathbf{elif}\;t \leq 4.2 \cdot 10^{+56}:\\ \;\;\;\;x \cdot \frac{y}{t - z}\\ \mathbf{elif}\;t \leq 1.75 \cdot 10^{+152}:\\ \;\;\;\;\frac{x}{1 - \frac{t}{z}}\\ \mathbf{else}:\\ \;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (<= t -1.18e+36)
   (/ x (/ t (- y z)))
   (if (<= t 1.56e-44)
     (/ x (/ z (- z y)))
     (if (<= t 4.2e+56)
       (* x (/ y (- t z)))
       (if (<= t 1.75e+152) (/ x (- 1.0 (/ t z))) (* (- y z) (/ x t)))))))
double code(double x, double y, double z, double t) {
	double tmp;
	if (t <= -1.18e+36) {
		tmp = x / (t / (y - z));
	} else if (t <= 1.56e-44) {
		tmp = x / (z / (z - y));
	} else if (t <= 4.2e+56) {
		tmp = x * (y / (t - z));
	} else if (t <= 1.75e+152) {
		tmp = x / (1.0 - (t / z));
	} else {
		tmp = (y - z) * (x / t);
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if (t <= (-1.18d+36)) then
        tmp = x / (t / (y - z))
    else if (t <= 1.56d-44) then
        tmp = x / (z / (z - y))
    else if (t <= 4.2d+56) then
        tmp = x * (y / (t - z))
    else if (t <= 1.75d+152) then
        tmp = x / (1.0d0 - (t / z))
    else
        tmp = (y - z) * (x / t)
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (t <= -1.18e+36) {
		tmp = x / (t / (y - z));
	} else if (t <= 1.56e-44) {
		tmp = x / (z / (z - y));
	} else if (t <= 4.2e+56) {
		tmp = x * (y / (t - z));
	} else if (t <= 1.75e+152) {
		tmp = x / (1.0 - (t / z));
	} else {
		tmp = (y - z) * (x / t);
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if t <= -1.18e+36:
		tmp = x / (t / (y - z))
	elif t <= 1.56e-44:
		tmp = x / (z / (z - y))
	elif t <= 4.2e+56:
		tmp = x * (y / (t - z))
	elif t <= 1.75e+152:
		tmp = x / (1.0 - (t / z))
	else:
		tmp = (y - z) * (x / t)
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if (t <= -1.18e+36)
		tmp = Float64(x / Float64(t / Float64(y - z)));
	elseif (t <= 1.56e-44)
		tmp = Float64(x / Float64(z / Float64(z - y)));
	elseif (t <= 4.2e+56)
		tmp = Float64(x * Float64(y / Float64(t - z)));
	elseif (t <= 1.75e+152)
		tmp = Float64(x / Float64(1.0 - Float64(t / z)));
	else
		tmp = Float64(Float64(y - z) * Float64(x / t));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (t <= -1.18e+36)
		tmp = x / (t / (y - z));
	elseif (t <= 1.56e-44)
		tmp = x / (z / (z - y));
	elseif (t <= 4.2e+56)
		tmp = x * (y / (t - z));
	elseif (t <= 1.75e+152)
		tmp = x / (1.0 - (t / z));
	else
		tmp = (y - z) * (x / t);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[LessEqual[t, -1.18e+36], N[(x / N[(t / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.56e-44], N[(x / N[(z / N[(z - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 4.2e+56], N[(x * N[(y / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.75e+152], N[(x / N[(1.0 - N[(t / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y - z), $MachinePrecision] * N[(x / t), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.18 \cdot 10^{+36}:\\
\;\;\;\;\frac{x}{\frac{t}{y - z}}\\

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

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

\mathbf{elif}\;t \leq 1.75 \cdot 10^{+152}:\\
\;\;\;\;\frac{x}{1 - \frac{t}{z}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if t < -1.17999999999999997e36

    1. Initial program 82.6%

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

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

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

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

    if -1.17999999999999997e36 < t < 1.56e-44

    1. Initial program 83.8%

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

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

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

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

        \[\leadsto \frac{x}{\color{blue}{-\frac{z}{y - z}}} \]
      2. distribute-neg-frac83.5%

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

      \[\leadsto \frac{x}{\color{blue}{\frac{-z}{y - z}}} \]
    7. Step-by-step derivation
      1. frac-2neg83.5%

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \frac{x}{\frac{z}{\color{blue}{z - y}}} \]
    10. Simplified83.5%

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

    if 1.56e-44 < t < 4.20000000000000034e56

    1. Initial program 94.2%

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

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

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

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

    if 4.20000000000000034e56 < t < 1.74999999999999991e152

    1. Initial program 83.4%

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

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

      \[\leadsto \color{blue}{\frac{x}{\frac{t - z}{y - z}}} \]
    4. Step-by-step derivation
      1. div-sub99.9%

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

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot \frac{t}{z}}} \]
    7. Step-by-step derivation
      1. mul-1-neg72.2%

        \[\leadsto \frac{x}{1 + \color{blue}{\left(-\frac{t}{z}\right)}} \]
      2. unsub-neg72.2%

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

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

    if 1.74999999999999991e152 < t

    1. Initial program 91.8%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -1.18 \cdot 10^{+36}:\\ \;\;\;\;\frac{x}{\frac{t}{y - z}}\\ \mathbf{elif}\;t \leq 1.56 \cdot 10^{-44}:\\ \;\;\;\;\frac{x}{\frac{z}{z - y}}\\ \mathbf{elif}\;t \leq 4.2 \cdot 10^{+56}:\\ \;\;\;\;x \cdot \frac{y}{t - z}\\ \mathbf{elif}\;t \leq 1.75 \cdot 10^{+152}:\\ \;\;\;\;\frac{x}{1 - \frac{t}{z}}\\ \mathbf{else}:\\ \;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\ \end{array} \]

Alternative 10: 71.7% accurate, 0.6× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.6 \cdot 10^{+50}:\\
\;\;\;\;\frac{x}{\frac{t}{y - z}}\\

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

\mathbf{elif}\;t \leq 3.2 \cdot 10^{+54}:\\
\;\;\;\;\frac{x \cdot y}{t - z}\\

\mathbf{elif}\;t \leq 3.2 \cdot 10^{+152}:\\
\;\;\;\;\frac{x}{1 - \frac{t}{z}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if t < -4.59999999999999994e50

    1. Initial program 82.6%

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

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

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

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

    if -4.59999999999999994e50 < t < 2.69999999999999991e-43

    1. Initial program 83.8%

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

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

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

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

        \[\leadsto \frac{x}{\color{blue}{-\frac{z}{y - z}}} \]
      2. distribute-neg-frac83.5%

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

      \[\leadsto \frac{x}{\color{blue}{\frac{-z}{y - z}}} \]
    7. Step-by-step derivation
      1. frac-2neg83.5%

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \frac{x}{\frac{z}{\color{blue}{z - y}}} \]
    10. Simplified83.5%

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

    if 2.69999999999999991e-43 < t < 3.2e54

    1. Initial program 94.2%

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

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

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

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

    if 3.2e54 < t < 3.20000000000000005e152

    1. Initial program 83.4%

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

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

      \[\leadsto \color{blue}{\frac{x}{\frac{t - z}{y - z}}} \]
    4. Step-by-step derivation
      1. div-sub99.9%

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

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot \frac{t}{z}}} \]
    7. Step-by-step derivation
      1. mul-1-neg72.2%

        \[\leadsto \frac{x}{1 + \color{blue}{\left(-\frac{t}{z}\right)}} \]
      2. unsub-neg72.2%

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

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

    if 3.20000000000000005e152 < t

    1. Initial program 91.8%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -4.6 \cdot 10^{+50}:\\ \;\;\;\;\frac{x}{\frac{t}{y - z}}\\ \mathbf{elif}\;t \leq 2.7 \cdot 10^{-43}:\\ \;\;\;\;\frac{x}{\frac{z}{z - y}}\\ \mathbf{elif}\;t \leq 3.2 \cdot 10^{+54}:\\ \;\;\;\;\frac{x \cdot y}{t - z}\\ \mathbf{elif}\;t \leq 3.2 \cdot 10^{+152}:\\ \;\;\;\;\frac{x}{1 - \frac{t}{z}}\\ \mathbf{else}:\\ \;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\ \end{array} \]

Alternative 11: 71.6% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -3 \cdot 10^{+49}:\\ \;\;\;\;\frac{x}{\frac{t}{y - z}}\\ \mathbf{elif}\;t \leq 2.45 \cdot 10^{-43}:\\ \;\;\;\;x \cdot \frac{z - y}{z}\\ \mathbf{elif}\;t \leq 4.5 \cdot 10^{+54}:\\ \;\;\;\;\frac{x \cdot y}{t - z}\\ \mathbf{elif}\;t \leq 4.7 \cdot 10^{+150}:\\ \;\;\;\;\frac{x}{1 - \frac{t}{z}}\\ \mathbf{else}:\\ \;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (<= t -3e+49)
   (/ x (/ t (- y z)))
   (if (<= t 2.45e-43)
     (* x (/ (- z y) z))
     (if (<= t 4.5e+54)
       (/ (* x y) (- t z))
       (if (<= t 4.7e+150) (/ x (- 1.0 (/ t z))) (* (- y z) (/ x t)))))))
double code(double x, double y, double z, double t) {
	double tmp;
	if (t <= -3e+49) {
		tmp = x / (t / (y - z));
	} else if (t <= 2.45e-43) {
		tmp = x * ((z - y) / z);
	} else if (t <= 4.5e+54) {
		tmp = (x * y) / (t - z);
	} else if (t <= 4.7e+150) {
		tmp = x / (1.0 - (t / z));
	} else {
		tmp = (y - z) * (x / t);
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if (t <= (-3d+49)) then
        tmp = x / (t / (y - z))
    else if (t <= 2.45d-43) then
        tmp = x * ((z - y) / z)
    else if (t <= 4.5d+54) then
        tmp = (x * y) / (t - z)
    else if (t <= 4.7d+150) then
        tmp = x / (1.0d0 - (t / z))
    else
        tmp = (y - z) * (x / t)
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (t <= -3e+49) {
		tmp = x / (t / (y - z));
	} else if (t <= 2.45e-43) {
		tmp = x * ((z - y) / z);
	} else if (t <= 4.5e+54) {
		tmp = (x * y) / (t - z);
	} else if (t <= 4.7e+150) {
		tmp = x / (1.0 - (t / z));
	} else {
		tmp = (y - z) * (x / t);
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if t <= -3e+49:
		tmp = x / (t / (y - z))
	elif t <= 2.45e-43:
		tmp = x * ((z - y) / z)
	elif t <= 4.5e+54:
		tmp = (x * y) / (t - z)
	elif t <= 4.7e+150:
		tmp = x / (1.0 - (t / z))
	else:
		tmp = (y - z) * (x / t)
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if (t <= -3e+49)
		tmp = Float64(x / Float64(t / Float64(y - z)));
	elseif (t <= 2.45e-43)
		tmp = Float64(x * Float64(Float64(z - y) / z));
	elseif (t <= 4.5e+54)
		tmp = Float64(Float64(x * y) / Float64(t - z));
	elseif (t <= 4.7e+150)
		tmp = Float64(x / Float64(1.0 - Float64(t / z)));
	else
		tmp = Float64(Float64(y - z) * Float64(x / t));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (t <= -3e+49)
		tmp = x / (t / (y - z));
	elseif (t <= 2.45e-43)
		tmp = x * ((z - y) / z);
	elseif (t <= 4.5e+54)
		tmp = (x * y) / (t - z);
	elseif (t <= 4.7e+150)
		tmp = x / (1.0 - (t / z));
	else
		tmp = (y - z) * (x / t);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[LessEqual[t, -3e+49], N[(x / N[(t / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.45e-43], N[(x * N[(N[(z - y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 4.5e+54], N[(N[(x * y), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 4.7e+150], N[(x / N[(1.0 - N[(t / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y - z), $MachinePrecision] * N[(x / t), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -3 \cdot 10^{+49}:\\
\;\;\;\;\frac{x}{\frac{t}{y - z}}\\

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

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

\mathbf{elif}\;t \leq 4.7 \cdot 10^{+150}:\\
\;\;\;\;\frac{x}{1 - \frac{t}{z}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if t < -3.0000000000000002e49

    1. Initial program 82.6%

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

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

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

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

    if -3.0000000000000002e49 < t < 2.44999999999999994e-43

    1. Initial program 83.8%

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

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

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

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

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

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

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

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

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

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

    if 2.44999999999999994e-43 < t < 4.49999999999999984e54

    1. Initial program 94.2%

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

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

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

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

    if 4.49999999999999984e54 < t < 4.70000000000000004e150

    1. Initial program 83.4%

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

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

      \[\leadsto \color{blue}{\frac{x}{\frac{t - z}{y - z}}} \]
    4. Step-by-step derivation
      1. div-sub99.9%

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

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot \frac{t}{z}}} \]
    7. Step-by-step derivation
      1. mul-1-neg72.2%

        \[\leadsto \frac{x}{1 + \color{blue}{\left(-\frac{t}{z}\right)}} \]
      2. unsub-neg72.2%

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

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

    if 4.70000000000000004e150 < t

    1. Initial program 91.8%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -3 \cdot 10^{+49}:\\ \;\;\;\;\frac{x}{\frac{t}{y - z}}\\ \mathbf{elif}\;t \leq 2.45 \cdot 10^{-43}:\\ \;\;\;\;x \cdot \frac{z - y}{z}\\ \mathbf{elif}\;t \leq 4.5 \cdot 10^{+54}:\\ \;\;\;\;\frac{x \cdot y}{t - z}\\ \mathbf{elif}\;t \leq 4.7 \cdot 10^{+150}:\\ \;\;\;\;\frac{x}{1 - \frac{t}{z}}\\ \mathbf{else}:\\ \;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\ \end{array} \]

Alternative 12: 61.5% accurate, 0.7× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.7 \cdot 10^{+68}:\\
\;\;\;\;x\\

\mathbf{elif}\;z \leq -170000000:\\
\;\;\;\;\frac{x \cdot \left(-z\right)}{t}\\

\mathbf{elif}\;z \leq -4.5 \cdot 10^{-22}:\\
\;\;\;\;x\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.70000000000000008e68 or -1.7e8 < z < -4.49999999999999987e-22 or 9.5e7 < z

    1. Initial program 77.2%

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

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

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

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

    if -1.70000000000000008e68 < z < -1.7e8

    1. Initial program 93.6%

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

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

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

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

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

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

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

    if -4.49999999999999987e-22 < z < 9.5e7

    1. Initial program 92.4%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.7 \cdot 10^{+68}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq -170000000:\\ \;\;\;\;\frac{x \cdot \left(-z\right)}{t}\\ \mathbf{elif}\;z \leq -4.5 \cdot 10^{-22}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq 95000000:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 13: 72.4% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.3 \cdot 10^{+40} \lor \neg \left(t \leq 2.9 \cdot 10^{-43}\right):\\
\;\;\;\;x \cdot \frac{y - z}{t}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -2.29999999999999994e40 or 2.9000000000000001e-43 < t

    1. Initial program 86.0%

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

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

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

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

    if -2.29999999999999994e40 < t < 2.9000000000000001e-43

    1. Initial program 83.8%

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

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

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

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

        \[\leadsto \frac{x}{\color{blue}{-\frac{z}{y - z}}} \]
      2. distribute-neg-frac83.5%

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

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

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

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

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

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

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

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

Alternative 14: 76.1% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.9 \cdot 10^{-23} \lor \neg \left(z \leq 230\right):\\
\;\;\;\;\frac{x}{1 - \frac{t}{z}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -3.9e-23 or 230 < z

    1. Initial program 79.0%

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

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

      \[\leadsto \color{blue}{\frac{x}{\frac{t - z}{y - z}}} \]
    4. Step-by-step derivation
      1. div-sub99.9%

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

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot \frac{t}{z}}} \]
    7. Step-by-step derivation
      1. mul-1-neg78.4%

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

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

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

    if -3.9e-23 < z < 230

    1. Initial program 92.4%

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

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

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

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

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

Alternative 15: 61.9% accurate, 1.0× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.1 \cdot 10^{-21}:\\
\;\;\;\;x\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -3.0999999999999998e-21 or 7.8e9 < z

    1. Initial program 79.0%

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

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

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

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

    if -3.0999999999999998e-21 < z < 7.8e9

    1. Initial program 92.4%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3.1 \cdot 10^{-21}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq 7800000000:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 16: 96.9% accurate, 1.0× speedup?

\[\begin{array}{l} \\ x \cdot \frac{y - z}{t - z} \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}

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

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

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

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

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

Alternative 17: 34.8% accurate, 9.0× speedup?

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

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

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

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

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

    \[\leadsto \color{blue}{x} \]
  5. Final simplification40.2%

    \[\leadsto x \]

Developer target: 96.9% accurate, 1.0× speedup?

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

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

Reproduce

?
herbie shell --seed 2023192 
(FPCore (x y z t)
  :name "Graphics.Rendering.Chart.Plot.AreaSpots:renderAreaSpots4D from Chart-1.5.3"
  :precision binary64

  :herbie-target
  (/ x (/ (- t z) (- y z)))

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