Graphics.Rendering.Chart.Axis.Types:invLinMap from Chart-1.5.3

Percentage Accurate: 68.3% → 90.4%
Time: 29.2s
Alternatives: 23
Speedup: 0.6×

Specification

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

\\
x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - 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 23 alternatives:

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

Initial Program: 68.3% accurate, 1.0× speedup?

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

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

Alternative 1: 90.4% accurate, 0.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{t}{\frac{a - z}{y - z}}\\ \mathbf{if}\;z \leq -1.5 \cdot 10^{+80}:\\ \;\;\;\;t\_1 - \frac{x}{\frac{z}{a - y}}\\ \mathbf{elif}\;z \leq 1.4 \cdot 10^{-116}:\\ \;\;\;\;\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1 + x \cdot \left(\frac{z}{a - z} + \left(1 - \frac{y}{a - z}\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (/ t (/ (- a z) (- y z)))))
   (if (<= z -1.5e+80)
     (- t_1 (/ x (/ z (- a y))))
     (if (<= z 1.4e-116)
       (fma (/ (- y z) (- a z)) (- t x) x)
       (+ t_1 (* x (+ (/ z (- a z)) (- 1.0 (/ y (- a z))))))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = t / ((a - z) / (y - z));
	double tmp;
	if (z <= -1.5e+80) {
		tmp = t_1 - (x / (z / (a - y)));
	} else if (z <= 1.4e-116) {
		tmp = fma(((y - z) / (a - z)), (t - x), x);
	} else {
		tmp = t_1 + (x * ((z / (a - z)) + (1.0 - (y / (a - z)))));
	}
	return tmp;
}
function code(x, y, z, t, a)
	t_1 = Float64(t / Float64(Float64(a - z) / Float64(y - z)))
	tmp = 0.0
	if (z <= -1.5e+80)
		tmp = Float64(t_1 - Float64(x / Float64(z / Float64(a - y))));
	elseif (z <= 1.4e-116)
		tmp = fma(Float64(Float64(y - z) / Float64(a - z)), Float64(t - x), x);
	else
		tmp = Float64(t_1 + Float64(x * Float64(Float64(z / Float64(a - z)) + Float64(1.0 - Float64(y / Float64(a - z))))));
	end
	return tmp
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t / N[(N[(a - z), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.5e+80], N[(t$95$1 - N[(x / N[(z / N[(a - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.4e-116], N[(N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision] * N[(t - x), $MachinePrecision] + x), $MachinePrecision], N[(t$95$1 + N[(x * N[(N[(z / N[(a - z), $MachinePrecision]), $MachinePrecision] + N[(1.0 - N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}

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

\mathbf{elif}\;z \leq 1.4 \cdot 10^{-116}:\\
\;\;\;\;\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.49999999999999993e80

    1. Initial program 34.6%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in x around -inf 48.1%

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \frac{t}{\frac{a - z}{y - z}} - \frac{x}{\frac{z}{a + \color{blue}{\left(-y\right)}}} \]
      3. unsub-neg94.8%

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

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

    if -1.49999999999999993e80 < z < 1.3999999999999999e-116

    1. Initial program 89.0%

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

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

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

        \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
    3. Simplified94.2%

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

    if 1.3999999999999999e-116 < z

    1. Initial program 56.3%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in x around -inf 75.1%

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

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

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

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

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

        \[\leadsto \frac{t}{\frac{a - z}{y - z}} - x \cdot \color{blue}{\left(\left(\frac{y}{a - z} - 1\right) - \frac{z}{a - z}\right)} \]
      6. sub-neg88.2%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.5 \cdot 10^{+80}:\\ \;\;\;\;\frac{t}{\frac{a - z}{y - z}} - \frac{x}{\frac{z}{a - y}}\\ \mathbf{elif}\;z \leq 1.4 \cdot 10^{-116}:\\ \;\;\;\;\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{\frac{a - z}{y - z}} + x \cdot \left(\frac{z}{a - z} + \left(1 - \frac{y}{a - z}\right)\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 91.6% accurate, 0.2× speedup?

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

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

\mathbf{elif}\;t\_2 \leq -2 \cdot 10^{-295}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;t\_2 \leq 0:\\
\;\;\;\;t + \frac{\left(y - a\right) \cdot \left(x - t\right)}{z}\\

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

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


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

    1. Initial program 34.3%

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

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

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

    if -inf.0 < (+.f64 x (/.f64 (*.f64 (-.f64 y z) (-.f64 t x)) (-.f64 a z))) < -2.00000000000000012e-295 or 0.0 < (+.f64 x (/.f64 (*.f64 (-.f64 y z) (-.f64 t x)) (-.f64 a z))) < 1.9999999999999999e305

    1. Initial program 95.3%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing

    if -2.00000000000000012e-295 < (+.f64 x (/.f64 (*.f64 (-.f64 y z) (-.f64 t x)) (-.f64 a z))) < 0.0

    1. Initial program 3.5%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 99.8%

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

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

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

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

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

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

        \[\leadsto t + \color{blue}{-1 \cdot \frac{y \cdot \left(t - x\right) - a \cdot \left(t - x\right)}{z}} \]
      7. mul-1-neg99.8%

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

        \[\leadsto \color{blue}{t - \frac{y \cdot \left(t - x\right) - a \cdot \left(t - x\right)}{z}} \]
      9. distribute-rgt-out--99.8%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;x - \frac{\left(y - z\right) \cdot \left(x - t\right)}{a - z} \leq -\infty:\\ \;\;\;\;x + \frac{y - z}{\frac{a - z}{t - x}}\\ \mathbf{elif}\;x - \frac{\left(y - z\right) \cdot \left(x - t\right)}{a - z} \leq -2 \cdot 10^{-295}:\\ \;\;\;\;x - \frac{\left(y - z\right) \cdot \left(x - t\right)}{a - z}\\ \mathbf{elif}\;x - \frac{\left(y - z\right) \cdot \left(x - t\right)}{a - z} \leq 0:\\ \;\;\;\;t + \frac{\left(y - a\right) \cdot \left(x - t\right)}{z}\\ \mathbf{elif}\;x - \frac{\left(y - z\right) \cdot \left(x - t\right)}{a - z} \leq 2 \cdot 10^{+305}:\\ \;\;\;\;x - \frac{\left(y - z\right) \cdot \left(x - t\right)}{a - z}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y - z}{\frac{a - z}{t - x}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 47.2% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t \cdot \left(1 - \frac{y}{z}\right)\\ \mathbf{if}\;a \leq -2.4 \cdot 10^{+160}:\\ \;\;\;\;x\\ \mathbf{elif}\;a \leq -3.2 \cdot 10^{+138}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;a \leq -4.7 \cdot 10^{+99}:\\ \;\;\;\;x\\ \mathbf{elif}\;a \leq -4.8 \cdot 10^{-94}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;a \leq -3.4 \cdot 10^{-174}:\\ \;\;\;\;\frac{x}{\frac{z}{y}}\\ \mathbf{elif}\;a \leq 3.2 \cdot 10^{+48}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (* t (- 1.0 (/ y z)))))
   (if (<= a -2.4e+160)
     x
     (if (<= a -3.2e+138)
       t_1
       (if (<= a -4.7e+99)
         x
         (if (<= a -4.8e-94)
           t_1
           (if (<= a -3.4e-174) (/ x (/ z y)) (if (<= a 3.2e+48) t_1 x))))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = t * (1.0 - (y / z));
	double tmp;
	if (a <= -2.4e+160) {
		tmp = x;
	} else if (a <= -3.2e+138) {
		tmp = t_1;
	} else if (a <= -4.7e+99) {
		tmp = x;
	} else if (a <= -4.8e-94) {
		tmp = t_1;
	} else if (a <= -3.4e-174) {
		tmp = x / (z / y);
	} else if (a <= 3.2e+48) {
		tmp = t_1;
	} else {
		tmp = x;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: t_1
    real(8) :: tmp
    t_1 = t * (1.0d0 - (y / z))
    if (a <= (-2.4d+160)) then
        tmp = x
    else if (a <= (-3.2d+138)) then
        tmp = t_1
    else if (a <= (-4.7d+99)) then
        tmp = x
    else if (a <= (-4.8d-94)) then
        tmp = t_1
    else if (a <= (-3.4d-174)) then
        tmp = x / (z / y)
    else if (a <= 3.2d+48) 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 a) {
	double t_1 = t * (1.0 - (y / z));
	double tmp;
	if (a <= -2.4e+160) {
		tmp = x;
	} else if (a <= -3.2e+138) {
		tmp = t_1;
	} else if (a <= -4.7e+99) {
		tmp = x;
	} else if (a <= -4.8e-94) {
		tmp = t_1;
	} else if (a <= -3.4e-174) {
		tmp = x / (z / y);
	} else if (a <= 3.2e+48) {
		tmp = t_1;
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = t * (1.0 - (y / z))
	tmp = 0
	if a <= -2.4e+160:
		tmp = x
	elif a <= -3.2e+138:
		tmp = t_1
	elif a <= -4.7e+99:
		tmp = x
	elif a <= -4.8e-94:
		tmp = t_1
	elif a <= -3.4e-174:
		tmp = x / (z / y)
	elif a <= 3.2e+48:
		tmp = t_1
	else:
		tmp = x
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(t * Float64(1.0 - Float64(y / z)))
	tmp = 0.0
	if (a <= -2.4e+160)
		tmp = x;
	elseif (a <= -3.2e+138)
		tmp = t_1;
	elseif (a <= -4.7e+99)
		tmp = x;
	elseif (a <= -4.8e-94)
		tmp = t_1;
	elseif (a <= -3.4e-174)
		tmp = Float64(x / Float64(z / y));
	elseif (a <= 3.2e+48)
		tmp = t_1;
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = t * (1.0 - (y / z));
	tmp = 0.0;
	if (a <= -2.4e+160)
		tmp = x;
	elseif (a <= -3.2e+138)
		tmp = t_1;
	elseif (a <= -4.7e+99)
		tmp = x;
	elseif (a <= -4.8e-94)
		tmp = t_1;
	elseif (a <= -3.4e-174)
		tmp = x / (z / y);
	elseif (a <= 3.2e+48)
		tmp = t_1;
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t * N[(1.0 - N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -2.4e+160], x, If[LessEqual[a, -3.2e+138], t$95$1, If[LessEqual[a, -4.7e+99], x, If[LessEqual[a, -4.8e-94], t$95$1, If[LessEqual[a, -3.4e-174], N[(x / N[(z / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 3.2e+48], t$95$1, x]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;a \leq -3.2 \cdot 10^{+138}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;a \leq -4.7 \cdot 10^{+99}:\\
\;\;\;\;x\\

\mathbf{elif}\;a \leq -4.8 \cdot 10^{-94}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;a \leq -3.4 \cdot 10^{-174}:\\
\;\;\;\;\frac{x}{\frac{z}{y}}\\

\mathbf{elif}\;a \leq 3.2 \cdot 10^{+48}:\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if a < -2.4000000000000001e160 or -3.2000000000000001e138 < a < -4.69999999999999982e99 or 3.2000000000000001e48 < a

    1. Initial program 72.8%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in a around inf 57.2%

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

    if -2.4000000000000001e160 < a < -3.2000000000000001e138 or -4.69999999999999982e99 < a < -4.8e-94 or -3.4000000000000002e-174 < a < 3.2000000000000001e48

    1. Initial program 63.2%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 42.1%

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

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

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

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

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

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

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

    if -4.8e-94 < a < -3.4000000000000002e-174

    1. Initial program 55.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 38.5%

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{x}{\frac{z}{y}}} \]
    8. Simplified65.0%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -2.4 \cdot 10^{+160}:\\ \;\;\;\;x\\ \mathbf{elif}\;a \leq -3.2 \cdot 10^{+138}:\\ \;\;\;\;t \cdot \left(1 - \frac{y}{z}\right)\\ \mathbf{elif}\;a \leq -4.7 \cdot 10^{+99}:\\ \;\;\;\;x\\ \mathbf{elif}\;a \leq -4.8 \cdot 10^{-94}:\\ \;\;\;\;t \cdot \left(1 - \frac{y}{z}\right)\\ \mathbf{elif}\;a \leq -3.4 \cdot 10^{-174}:\\ \;\;\;\;\frac{x}{\frac{z}{y}}\\ \mathbf{elif}\;a \leq 3.2 \cdot 10^{+48}:\\ \;\;\;\;t \cdot \left(1 - \frac{y}{z}\right)\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 87.3% accurate, 0.4× speedup?

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if a < -4.14999999999999987e-75 or 3.9499999999999999e-168 < a

    1. Initial program 65.2%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in x around -inf 76.9%

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

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

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

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

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

        \[\leadsto \frac{t}{\frac{a - z}{y - z}} - x \cdot \color{blue}{\left(\left(\frac{y}{a - z} - 1\right) - \frac{z}{a - z}\right)} \]
      6. sub-neg92.0%

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

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

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

    if -4.14999999999999987e-75 < a < 3.9499999999999999e-168

    1. Initial program 70.8%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 90.4%

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

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{t - \frac{y \cdot \left(t - x\right) - a \cdot \left(t - x\right)}{z}} \]
      9. distribute-rgt-out--90.4%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -4.15 \cdot 10^{-75} \lor \neg \left(a \leq 3.95 \cdot 10^{-168}\right):\\ \;\;\;\;\frac{t}{\frac{a - z}{y - z}} + x \cdot \left(\frac{z}{a - z} + \left(1 - \frac{y}{a - z}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t + \frac{\left(y - a\right) \cdot \left(x - t\right)}{z}\\ \end{array} \]
  5. Add Preprocessing

Alternative 5: 63.2% accurate, 0.4× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -8.5 \cdot 10^{-68} \lor \neg \left(t \leq 4.5 \cdot 10^{-135} \lor \neg \left(t \leq 3.5 \cdot 10^{-79}\right) \land t \leq 135000\right):\\
\;\;\;\;\frac{t}{\frac{a - z}{y - z}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -8.50000000000000026e-68 or 4.49999999999999987e-135 < t < 3.5000000000000003e-79 or 135000 < t

    1. Initial program 61.5%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 58.9%

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

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

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

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

        \[\leadsto \color{blue}{\frac{t}{\frac{a - z}{y - z}}} \]
    8. Simplified73.2%

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

    if -8.50000000000000026e-68 < t < 4.49999999999999987e-135 or 3.5000000000000003e-79 < t < 135000

    1. Initial program 74.5%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 72.8%

      \[\leadsto \color{blue}{x \cdot \left(1 + -1 \cdot \frac{y - z}{a - z}\right)} \]
    4. Step-by-step derivation
      1. mul-1-neg72.8%

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

        \[\leadsto x \cdot \color{blue}{\left(1 - \frac{y - z}{a - z}\right)} \]
    5. Simplified72.8%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -8.5 \cdot 10^{-68} \lor \neg \left(t \leq 4.5 \cdot 10^{-135} \lor \neg \left(t \leq 3.5 \cdot 10^{-79}\right) \land t \leq 135000\right):\\ \;\;\;\;\frac{t}{\frac{a - z}{y - z}}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(1 - \frac{y - z}{a - z}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 6: 76.4% accurate, 0.5× speedup?

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

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if a < -2.9e26 or 3.90000000000000026e-15 < a

    1. Initial program 64.2%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 66.0%

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

        \[\leadsto x + \color{blue}{\frac{t}{\frac{a - z}{y - z}}} \]
    5. Simplified80.1%

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

    if -2.9e26 < a < 4.09999999999999999e-138

    1. Initial program 66.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 87.2%

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

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

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

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

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

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

        \[\leadsto t + \color{blue}{-1 \cdot \frac{y \cdot \left(t - x\right) - a \cdot \left(t - x\right)}{z}} \]
      7. mul-1-neg87.2%

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

        \[\leadsto \color{blue}{t - \frac{y \cdot \left(t - x\right) - a \cdot \left(t - x\right)}{z}} \]
      9. distribute-rgt-out--87.2%

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

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

    if 4.09999999999999999e-138 < a < 3.90000000000000026e-15

    1. Initial program 93.5%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -2.9 \cdot 10^{+26}:\\ \;\;\;\;\frac{t}{\frac{a - z}{y - z}} + x\\ \mathbf{elif}\;a \leq 4.1 \cdot 10^{-138}:\\ \;\;\;\;t + \frac{\left(y - a\right) \cdot \left(x - t\right)}{z}\\ \mathbf{elif}\;a \leq 3.9 \cdot 10^{-15}:\\ \;\;\;\;x - \frac{\left(y - z\right) \cdot \left(x - t\right)}{a - z}\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{\frac{a - z}{y - z}} + x\\ \end{array} \]
  5. Add Preprocessing

Alternative 7: 88.9% accurate, 0.5× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -5.2 \cdot 10^{+78} \lor \neg \left(z \leq 3.3 \cdot 10^{+139}\right):\\
\;\;\;\;\frac{t}{\frac{a - z}{y - z}} - \frac{x}{\frac{z}{a - y}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -5.2e78 or 3.3000000000000002e139 < z

    1. Initial program 29.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in x around -inf 47.1%

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

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

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

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

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

        \[\leadsto \frac{t}{\frac{a - z}{y - z}} - x \cdot \color{blue}{\left(\left(\frac{y}{a - z} - 1\right) - \frac{z}{a - z}\right)} \]
      6. sub-neg79.5%

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

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

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

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

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

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

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

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

    if -5.2e78 < z < 3.3000000000000002e139

    1. Initial program 84.3%

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

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

      \[\leadsto \color{blue}{x + \frac{y - z}{\frac{a - z}{t - x}}} \]
    4. Add Preprocessing
  3. Recombined 2 regimes into one program.
  4. Final simplification89.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -5.2 \cdot 10^{+78} \lor \neg \left(z \leq 3.3 \cdot 10^{+139}\right):\\ \;\;\;\;\frac{t}{\frac{a - z}{y - z}} - \frac{x}{\frac{z}{a - y}}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y - z}{\frac{a - z}{t - x}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 8: 74.6% accurate, 0.5× speedup?

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

\\
\begin{array}{l}
t_1 := \frac{t}{\frac{a - z}{y - z}}\\
\mathbf{if}\;z \leq -2.25 \cdot 10^{+104}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;z \leq 2 \cdot 10^{-24}:\\
\;\;\;\;x + y \cdot \frac{t - x}{a - z}\\

\mathbf{elif}\;z \leq 3.8 \cdot 10^{+198}:\\
\;\;\;\;t\_1 + x\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -2.2499999999999999e104

    1. Initial program 34.5%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 27.7%

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

        \[\leadsto x + \color{blue}{\frac{t}{\frac{a - z}{y - z}}} \]
    5. Simplified68.0%

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

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

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

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

    if -2.2499999999999999e104 < z < 1.99999999999999985e-24

    1. Initial program 85.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 80.6%

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

        \[\leadsto x + \color{blue}{y \cdot \frac{t - x}{a - z}} \]
    5. Simplified84.6%

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

    if 1.99999999999999985e-24 < z < 3.79999999999999988e198

    1. Initial program 55.9%

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

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

        \[\leadsto x + \color{blue}{\frac{t}{\frac{a - z}{y - z}}} \]
    5. Simplified72.3%

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

    if 3.79999999999999988e198 < z

    1. Initial program 27.5%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0 22.9%

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

        \[\leadsto \color{blue}{-1 \cdot \frac{z \cdot \left(t - x\right)}{a - z} + x} \]
      2. mul-1-neg22.9%

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

        \[\leadsto \left(-\color{blue}{z \cdot \frac{t - x}{a - z}}\right) + x \]
      4. distribute-lft-neg-in41.1%

        \[\leadsto \color{blue}{\left(-z\right) \cdot \frac{t - x}{a - z}} + x \]
      5. fma-define41.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(-z, \frac{t - x}{a - z}, x\right)} \]
    5. Simplified41.5%

      \[\leadsto \color{blue}{\mathsf{fma}\left(-z, \frac{t - x}{a - z}, x\right)} \]
    6. Taylor expanded in a around 0 74.6%

      \[\leadsto \color{blue}{t + -1 \cdot \left(a \cdot \left(\frac{x}{z} - \frac{t}{z}\right)\right)} \]
    7. Step-by-step derivation
      1. mul-1-neg74.6%

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

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

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

      \[\leadsto t - \color{blue}{\frac{a \cdot \left(x - t\right)}{z}} \]
    10. Step-by-step derivation
      1. *-rgt-identity70.5%

        \[\leadsto t - \frac{a \cdot \left(x - t\right)}{\color{blue}{z \cdot 1}} \]
      2. times-frac79.0%

        \[\leadsto t - \color{blue}{\frac{a}{z} \cdot \frac{x - t}{1}} \]
      3. /-rgt-identity79.0%

        \[\leadsto t - \frac{a}{z} \cdot \color{blue}{\left(x - t\right)} \]
    11. Simplified79.0%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.25 \cdot 10^{+104}:\\ \;\;\;\;\frac{t}{\frac{a - z}{y - z}}\\ \mathbf{elif}\;z \leq 2 \cdot 10^{-24}:\\ \;\;\;\;x + y \cdot \frac{t - x}{a - z}\\ \mathbf{elif}\;z \leq 3.8 \cdot 10^{+198}:\\ \;\;\;\;\frac{t}{\frac{a - z}{y - z}} + x\\ \mathbf{else}:\\ \;\;\;\;t - \frac{a}{z} \cdot \left(x - t\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 9: 74.6% accurate, 0.5× speedup?

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

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if a < -1.75e26 or 1.48e-15 < a

    1. Initial program 64.2%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 66.0%

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

        \[\leadsto x + \color{blue}{\frac{t}{\frac{a - z}{y - z}}} \]
    5. Simplified80.1%

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

    if -1.75e26 < a < 3.60000000000000025e-128

    1. Initial program 66.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 87.2%

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

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

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

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

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

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

        \[\leadsto t + \color{blue}{-1 \cdot \frac{y \cdot \left(t - x\right) - a \cdot \left(t - x\right)}{z}} \]
      7. mul-1-neg87.2%

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

        \[\leadsto \color{blue}{t - \frac{y \cdot \left(t - x\right) - a \cdot \left(t - x\right)}{z}} \]
      9. distribute-rgt-out--87.2%

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

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

    if 3.60000000000000025e-128 < a < 1.48e-15

    1. Initial program 93.5%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 81.4%

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

        \[\leadsto x + \color{blue}{y \cdot \frac{t - x}{a - z}} \]
    5. Simplified81.6%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -1.75 \cdot 10^{+26}:\\ \;\;\;\;\frac{t}{\frac{a - z}{y - z}} + x\\ \mathbf{elif}\;a \leq 3.6 \cdot 10^{-128}:\\ \;\;\;\;t + \frac{\left(y - a\right) \cdot \left(x - t\right)}{z}\\ \mathbf{elif}\;a \leq 1.48 \cdot 10^{-15}:\\ \;\;\;\;x + y \cdot \frac{t - x}{a - z}\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{\frac{a - z}{y - z}} + x\\ \end{array} \]
  5. Add Preprocessing

Alternative 10: 63.4% accurate, 0.5× speedup?

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

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

\mathbf{elif}\;z \leq 6.8 \cdot 10^{-91}:\\
\;\;\;\;x + \frac{y}{\frac{a}{t - x}}\\

\mathbf{elif}\;z \leq 9 \cdot 10^{+139}:\\
\;\;\;\;x + \frac{t}{\frac{a}{y - z}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.60000000000000001e79 or 8.9999999999999999e139 < z

    1. Initial program 29.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0 22.3%

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

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

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

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

        \[\leadsto \color{blue}{\left(-z\right) \cdot \frac{t - x}{a - z}} + x \]
      5. fma-define45.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(-z, \frac{t - x}{a - z}, x\right)} \]
    5. Simplified45.5%

      \[\leadsto \color{blue}{\mathsf{fma}\left(-z, \frac{t - x}{a - z}, x\right)} \]
    6. Taylor expanded in z around inf 53.1%

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

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

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

    if -1.60000000000000001e79 < z < 6.80000000000000053e-91

    1. Initial program 87.9%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 66.6%

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

        \[\leadsto x + \color{blue}{\frac{y}{\frac{a}{t - x}}} \]
    5. Simplified71.6%

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

    if 6.80000000000000053e-91 < z < 8.9999999999999999e139

    1. Initial program 76.8%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 75.0%

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

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

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

        \[\leadsto \color{blue}{\frac{t}{\frac{a}{y - z}}} + x \]
    6. Simplified62.0%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.6 \cdot 10^{+79}:\\ \;\;\;\;t + \frac{a}{\frac{z}{t - x}}\\ \mathbf{elif}\;z \leq 6.8 \cdot 10^{-91}:\\ \;\;\;\;x + \frac{y}{\frac{a}{t - x}}\\ \mathbf{elif}\;z \leq 9 \cdot 10^{+139}:\\ \;\;\;\;x + \frac{t}{\frac{a}{y - z}}\\ \mathbf{else}:\\ \;\;\;\;t + \frac{a}{\frac{z}{t - x}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 11: 63.5% accurate, 0.5× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.7 \cdot 10^{+79}:\\
\;\;\;\;t + \frac{a}{\frac{z}{t - x}}\\

\mathbf{elif}\;z \leq 1.35 \cdot 10^{-90}:\\
\;\;\;\;x + \frac{y}{\frac{a}{t - x}}\\

\mathbf{elif}\;z \leq 9 \cdot 10^{+139}:\\
\;\;\;\;x + \frac{t}{\frac{a}{y - z}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -2.7e79

    1. Initial program 34.6%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0 22.8%

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

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

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

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

        \[\leadsto \color{blue}{\left(-z\right) \cdot \frac{t - x}{a - z}} + x \]
      5. fma-define43.3%

        \[\leadsto \color{blue}{\mathsf{fma}\left(-z, \frac{t - x}{a - z}, x\right)} \]
    5. Simplified43.3%

      \[\leadsto \color{blue}{\mathsf{fma}\left(-z, \frac{t - x}{a - z}, x\right)} \]
    6. Taylor expanded in z around inf 51.7%

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

        \[\leadsto t + \color{blue}{\frac{a}{\frac{z}{t - x}}} \]
    8. Simplified62.9%

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

    if -2.7e79 < z < 1.34999999999999998e-90

    1. Initial program 87.9%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 66.6%

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

        \[\leadsto x + \color{blue}{\frac{y}{\frac{a}{t - x}}} \]
    5. Simplified71.6%

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

    if 1.34999999999999998e-90 < z < 8.9999999999999999e139

    1. Initial program 76.8%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 75.0%

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

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

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

        \[\leadsto \color{blue}{\frac{t}{\frac{a}{y - z}}} + x \]
    6. Simplified62.0%

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

    if 8.9999999999999999e139 < z

    1. Initial program 24.3%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0 21.7%

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

        \[\leadsto \color{blue}{-1 \cdot \frac{z \cdot \left(t - x\right)}{a - z} + x} \]
      2. mul-1-neg21.7%

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

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

        \[\leadsto \color{blue}{\left(-z\right) \cdot \frac{t - x}{a - z}} + x \]
      5. fma-define47.9%

        \[\leadsto \color{blue}{\mathsf{fma}\left(-z, \frac{t - x}{a - z}, x\right)} \]
    5. Simplified47.9%

      \[\leadsto \color{blue}{\mathsf{fma}\left(-z, \frac{t - x}{a - z}, x\right)} \]
    6. Taylor expanded in a around 0 66.5%

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

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

        \[\leadsto \color{blue}{t - a \cdot \left(\frac{x}{z} - \frac{t}{z}\right)} \]
    8. Simplified66.5%

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

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

        \[\leadsto t - \frac{a \cdot \left(x - t\right)}{\color{blue}{z \cdot 1}} \]
      2. times-frac69.0%

        \[\leadsto t - \color{blue}{\frac{a}{z} \cdot \frac{x - t}{1}} \]
      3. /-rgt-identity69.0%

        \[\leadsto t - \frac{a}{z} \cdot \color{blue}{\left(x - t\right)} \]
    11. Simplified69.0%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.7 \cdot 10^{+79}:\\ \;\;\;\;t + \frac{a}{\frac{z}{t - x}}\\ \mathbf{elif}\;z \leq 1.35 \cdot 10^{-90}:\\ \;\;\;\;x + \frac{y}{\frac{a}{t - x}}\\ \mathbf{elif}\;z \leq 9 \cdot 10^{+139}:\\ \;\;\;\;x + \frac{t}{\frac{a}{y - z}}\\ \mathbf{else}:\\ \;\;\;\;t - \frac{a}{z} \cdot \left(x - t\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 12: 65.0% accurate, 0.5× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -34000000000000:\\
\;\;\;\;\frac{t}{\frac{a - z}{y - z}}\\

\mathbf{elif}\;z \leq 5.5 \cdot 10^{-91}:\\
\;\;\;\;x + \frac{y}{\frac{a}{t - x}}\\

\mathbf{elif}\;z \leq 1.4 \cdot 10^{+137}:\\
\;\;\;\;x + \frac{t}{\frac{a}{y - z}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -3.4e13

    1. Initial program 44.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 36.2%

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

        \[\leadsto x + \color{blue}{\frac{t}{\frac{a - z}{y - z}}} \]
    5. Simplified65.6%

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

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

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

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

    if -3.4e13 < z < 5.49999999999999965e-91

    1. Initial program 88.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 68.7%

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

        \[\leadsto x + \color{blue}{\frac{y}{\frac{a}{t - x}}} \]
    5. Simplified74.2%

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

    if 5.49999999999999965e-91 < z < 1.4e137

    1. Initial program 76.8%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 75.0%

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

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

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

        \[\leadsto \color{blue}{\frac{t}{\frac{a}{y - z}}} + x \]
    6. Simplified62.0%

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

    if 1.4e137 < z

    1. Initial program 24.3%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0 21.7%

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

        \[\leadsto \color{blue}{-1 \cdot \frac{z \cdot \left(t - x\right)}{a - z} + x} \]
      2. mul-1-neg21.7%

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

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

        \[\leadsto \color{blue}{\left(-z\right) \cdot \frac{t - x}{a - z}} + x \]
      5. fma-define47.9%

        \[\leadsto \color{blue}{\mathsf{fma}\left(-z, \frac{t - x}{a - z}, x\right)} \]
    5. Simplified47.9%

      \[\leadsto \color{blue}{\mathsf{fma}\left(-z, \frac{t - x}{a - z}, x\right)} \]
    6. Taylor expanded in a around 0 66.5%

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

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

        \[\leadsto \color{blue}{t - a \cdot \left(\frac{x}{z} - \frac{t}{z}\right)} \]
    8. Simplified66.5%

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

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

        \[\leadsto t - \frac{a \cdot \left(x - t\right)}{\color{blue}{z \cdot 1}} \]
      2. times-frac69.0%

        \[\leadsto t - \color{blue}{\frac{a}{z} \cdot \frac{x - t}{1}} \]
      3. /-rgt-identity69.0%

        \[\leadsto t - \frac{a}{z} \cdot \color{blue}{\left(x - t\right)} \]
    11. Simplified69.0%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -34000000000000:\\ \;\;\;\;\frac{t}{\frac{a - z}{y - z}}\\ \mathbf{elif}\;z \leq 5.5 \cdot 10^{-91}:\\ \;\;\;\;x + \frac{y}{\frac{a}{t - x}}\\ \mathbf{elif}\;z \leq 1.4 \cdot 10^{+137}:\\ \;\;\;\;x + \frac{t}{\frac{a}{y - z}}\\ \mathbf{else}:\\ \;\;\;\;t - \frac{a}{z} \cdot \left(x - t\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 13: 72.6% accurate, 0.6× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.3 \cdot 10^{+96}:\\
\;\;\;\;\frac{t}{\frac{a - z}{y - z}}\\

\mathbf{elif}\;z \leq 3.3 \cdot 10^{+140}:\\
\;\;\;\;x + y \cdot \frac{t - x}{a - z}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.3e96

    1. Initial program 34.5%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 27.7%

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

        \[\leadsto x + \color{blue}{\frac{t}{\frac{a - z}{y - z}}} \]
    5. Simplified68.0%

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

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

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

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

    if -1.3e96 < z < 3.3000000000000002e140

    1. Initial program 82.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 77.2%

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

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

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

    if 3.3000000000000002e140 < z

    1. Initial program 24.3%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0 21.7%

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

        \[\leadsto \color{blue}{-1 \cdot \frac{z \cdot \left(t - x\right)}{a - z} + x} \]
      2. mul-1-neg21.7%

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

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

        \[\leadsto \color{blue}{\left(-z\right) \cdot \frac{t - x}{a - z}} + x \]
      5. fma-define47.9%

        \[\leadsto \color{blue}{\mathsf{fma}\left(-z, \frac{t - x}{a - z}, x\right)} \]
    5. Simplified47.9%

      \[\leadsto \color{blue}{\mathsf{fma}\left(-z, \frac{t - x}{a - z}, x\right)} \]
    6. Taylor expanded in a around 0 66.5%

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

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

        \[\leadsto \color{blue}{t - a \cdot \left(\frac{x}{z} - \frac{t}{z}\right)} \]
    8. Simplified66.5%

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

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

        \[\leadsto t - \frac{a \cdot \left(x - t\right)}{\color{blue}{z \cdot 1}} \]
      2. times-frac69.0%

        \[\leadsto t - \color{blue}{\frac{a}{z} \cdot \frac{x - t}{1}} \]
      3. /-rgt-identity69.0%

        \[\leadsto t - \frac{a}{z} \cdot \color{blue}{\left(x - t\right)} \]
    11. Simplified69.0%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.3 \cdot 10^{+96}:\\ \;\;\;\;\frac{t}{\frac{a - z}{y - z}}\\ \mathbf{elif}\;z \leq 3.3 \cdot 10^{+140}:\\ \;\;\;\;x + y \cdot \frac{t - x}{a - z}\\ \mathbf{else}:\\ \;\;\;\;t - \frac{a}{z} \cdot \left(x - t\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 14: 55.8% accurate, 0.7× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.35 \cdot 10^{+16} \lor \neg \left(z \leq 2.9 \cdot 10^{+139}\right):\\
\;\;\;\;t + \frac{a}{\frac{z}{t - x}}\\

\mathbf{else}:\\
\;\;\;\;x + \frac{t}{\frac{a}{y}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.35e16 or 2.8999999999999999e139 < z

    1. Initial program 36.0%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0 26.3%

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

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

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

        \[\leadsto \left(-\color{blue}{z \cdot \frac{t - x}{a - z}}\right) + x \]
      4. distribute-lft-neg-in46.2%

        \[\leadsto \color{blue}{\left(-z\right) \cdot \frac{t - x}{a - z}} + x \]
      5. fma-define46.9%

        \[\leadsto \color{blue}{\mathsf{fma}\left(-z, \frac{t - x}{a - z}, x\right)} \]
    5. Simplified46.9%

      \[\leadsto \color{blue}{\mathsf{fma}\left(-z, \frac{t - x}{a - z}, x\right)} \]
    6. Taylor expanded in z around inf 51.3%

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

        \[\leadsto t + \color{blue}{\frac{a}{\frac{z}{t - x}}} \]
    8. Simplified61.3%

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

    if -1.35e16 < z < 2.8999999999999999e139

    1. Initial program 84.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 70.0%

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

        \[\leadsto x + \color{blue}{\frac{t}{\frac{a - z}{y - z}}} \]
    5. Simplified71.6%

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

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

        \[\leadsto x + \color{blue}{\frac{t}{\frac{a}{y}}} \]
    8. Simplified57.4%

      \[\leadsto \color{blue}{x + \frac{t}{\frac{a}{y}}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification58.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.35 \cdot 10^{+16} \lor \neg \left(z \leq 2.9 \cdot 10^{+139}\right):\\ \;\;\;\;t + \frac{a}{\frac{z}{t - x}}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{t}{\frac{a}{y}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 15: 62.8% accurate, 0.7× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -9.5 \cdot 10^{+79} \lor \neg \left(z \leq 3.1 \cdot 10^{+137}\right):\\
\;\;\;\;t + \frac{a}{\frac{z}{t - x}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -9.49999999999999994e79 or 3.0999999999999999e137 < z

    1. Initial program 29.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0 22.3%

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

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

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

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

        \[\leadsto \color{blue}{\left(-z\right) \cdot \frac{t - x}{a - z}} + x \]
      5. fma-define45.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(-z, \frac{t - x}{a - z}, x\right)} \]
    5. Simplified45.5%

      \[\leadsto \color{blue}{\mathsf{fma}\left(-z, \frac{t - x}{a - z}, x\right)} \]
    6. Taylor expanded in z around inf 53.1%

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

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

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

    if -9.49999999999999994e79 < z < 3.0999999999999999e137

    1. Initial program 84.3%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 62.9%

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

        \[\leadsto x + \color{blue}{\frac{y}{\frac{a}{t - x}}} \]
    5. Simplified65.2%

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

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

Alternative 16: 51.6% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.4 \cdot 10^{+82} \lor \neg \left(z \leq 1.05 \cdot 10^{+137}\right):\\
\;\;\;\;t \cdot \left(1 - \frac{y}{z}\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.4e82 or 1.05e137 < z

    1. Initial program 30.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 26.2%

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

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

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

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

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

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

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

    if -1.4e82 < z < 1.05e137

    1. Initial program 83.3%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 62.3%

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

      \[\leadsto \color{blue}{x \cdot \left(1 + -1 \cdot \frac{y}{a}\right)} \]
    5. Step-by-step derivation
      1. mul-1-neg50.1%

        \[\leadsto x \cdot \left(1 + \color{blue}{\left(-\frac{y}{a}\right)}\right) \]
      2. unsub-neg50.1%

        \[\leadsto x \cdot \color{blue}{\left(1 - \frac{y}{a}\right)} \]
    6. Simplified50.1%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.4 \cdot 10^{+82} \lor \neg \left(z \leq 1.05 \cdot 10^{+137}\right):\\ \;\;\;\;t \cdot \left(1 - \frac{y}{z}\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(1 - \frac{y}{a}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 17: 55.4% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -5 \cdot 10^{+82} \lor \neg \left(z \leq 1.15 \cdot 10^{+139}\right):\\
\;\;\;\;t \cdot \left(1 - \frac{y}{z}\right)\\

\mathbf{else}:\\
\;\;\;\;x + \frac{t}{\frac{a}{y}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -5.00000000000000015e82 or 1.15e139 < z

    1. Initial program 30.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 26.2%

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

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

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

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

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

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

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

    if -5.00000000000000015e82 < z < 1.15e139

    1. Initial program 83.3%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 69.6%

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

        \[\leadsto x + \color{blue}{\frac{t}{\frac{a - z}{y - z}}} \]
    5. Simplified71.0%

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

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

        \[\leadsto x + \color{blue}{\frac{t}{\frac{a}{y}}} \]
    8. Simplified55.6%

      \[\leadsto \color{blue}{x + \frac{t}{\frac{a}{y}}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification56.8%

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

Alternative 18: 56.0% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.85 \cdot 10^{+78} \lor \neg \left(z \leq 9.5 \cdot 10^{+136}\right):\\
\;\;\;\;t - a \cdot \frac{x}{z}\\

\mathbf{else}:\\
\;\;\;\;x + \frac{t}{\frac{a}{y}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.84999999999999992e78 or 9.49999999999999907e136 < z

    1. Initial program 29.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0 22.3%

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

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

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

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

        \[\leadsto \color{blue}{\left(-z\right) \cdot \frac{t - x}{a - z}} + x \]
      5. fma-define45.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(-z, \frac{t - x}{a - z}, x\right)} \]
    5. Simplified45.5%

      \[\leadsto \color{blue}{\mathsf{fma}\left(-z, \frac{t - x}{a - z}, x\right)} \]
    6. Taylor expanded in a around 0 64.6%

      \[\leadsto \color{blue}{t + -1 \cdot \left(a \cdot \left(\frac{x}{z} - \frac{t}{z}\right)\right)} \]
    7. Step-by-step derivation
      1. mul-1-neg64.6%

        \[\leadsto t + \color{blue}{\left(-a \cdot \left(\frac{x}{z} - \frac{t}{z}\right)\right)} \]
      2. unsub-neg64.6%

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

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

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

    if -1.84999999999999992e78 < z < 9.49999999999999907e136

    1. Initial program 84.3%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 70.3%

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

        \[\leadsto x + \color{blue}{\frac{t}{\frac{a - z}{y - z}}} \]
    5. Simplified71.7%

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

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

        \[\leadsto x + \color{blue}{\frac{t}{\frac{a}{y}}} \]
    8. Simplified56.1%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.85 \cdot 10^{+78} \lor \neg \left(z \leq 9.5 \cdot 10^{+136}\right):\\ \;\;\;\;t - a \cdot \frac{x}{z}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{t}{\frac{a}{y}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 19: 36.2% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.08 \cdot 10^{-7}:\\
\;\;\;\;t\\

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

\mathbf{elif}\;z \leq 1.12 \cdot 10^{+138}:\\
\;\;\;\;x\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.08000000000000001e-7 or 1.12e138 < z

    1. Initial program 36.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 47.6%

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

    if -1.08000000000000001e-7 < z < 1.00000000000000004e-215

    1. Initial program 88.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 69.9%

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

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

        \[\leadsto y \cdot \color{blue}{\frac{t - x}{a}} \]
    6. Simplified51.6%

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

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

    if 1.00000000000000004e-215 < z < 1.12e138

    1. Initial program 80.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in a around inf 44.4%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.08 \cdot 10^{-7}:\\ \;\;\;\;t\\ \mathbf{elif}\;z \leq 10^{-215}:\\ \;\;\;\;y \cdot \frac{t}{a}\\ \mathbf{elif}\;z \leq 1.12 \cdot 10^{+138}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;t\\ \end{array} \]
  5. Add Preprocessing

Alternative 20: 36.3% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -0.003:\\
\;\;\;\;t\\

\mathbf{elif}\;z \leq -2.3 \cdot 10^{-304}:\\
\;\;\;\;\frac{t}{\frac{a}{y}}\\

\mathbf{elif}\;z \leq 9.5 \cdot 10^{+138}:\\
\;\;\;\;x\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -0.0030000000000000001 or 9.49999999999999998e138 < z

    1. Initial program 36.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 47.6%

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

    if -0.0030000000000000001 < z < -2.3e-304

    1. Initial program 89.2%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 67.3%

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

      \[\leadsto \color{blue}{y \cdot \left(\frac{t}{a} - \frac{x}{a}\right)} \]
    5. Step-by-step derivation
      1. div-sub51.7%

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

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

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

        \[\leadsto \color{blue}{\frac{t}{\frac{a}{y}}} \]
    9. Simplified36.0%

      \[\leadsto \color{blue}{\frac{t}{\frac{a}{y}}} \]

    if -2.3e-304 < z < 9.49999999999999998e138

    1. Initial program 81.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in a around inf 43.4%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -0.003:\\ \;\;\;\;t\\ \mathbf{elif}\;z \leq -2.3 \cdot 10^{-304}:\\ \;\;\;\;\frac{t}{\frac{a}{y}}\\ \mathbf{elif}\;z \leq 9.5 \cdot 10^{+138}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;t\\ \end{array} \]
  5. Add Preprocessing

Alternative 21: 38.1% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.7 \cdot 10^{+109}:\\
\;\;\;\;\frac{t}{\frac{a}{y}}\\

\mathbf{elif}\;y \leq 2.3 \cdot 10^{+147}:\\
\;\;\;\;t + x\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -3.7000000000000002e109

    1. Initial program 73.2%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 49.0%

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

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

        \[\leadsto y \cdot \color{blue}{\frac{t - x}{a}} \]
    6. Simplified53.1%

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

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

        \[\leadsto \color{blue}{\frac{t}{\frac{a}{y}}} \]
    9. Simplified40.6%

      \[\leadsto \color{blue}{\frac{t}{\frac{a}{y}}} \]

    if -3.7000000000000002e109 < y < 2.2999999999999999e147

    1. Initial program 64.1%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 57.7%

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

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

    if 2.2999999999999999e147 < y

    1. Initial program 78.3%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 59.5%

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

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

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

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

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

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

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

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

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

        \[\leadsto -\color{blue}{y \cdot \frac{t}{z}} \]
      4. distribute-rgt-neg-in36.4%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -3.7 \cdot 10^{+109}:\\ \;\;\;\;\frac{t}{\frac{a}{y}}\\ \mathbf{elif}\;y \leq 2.3 \cdot 10^{+147}:\\ \;\;\;\;t + x\\ \mathbf{else}:\\ \;\;\;\;y \cdot \left(-\frac{t}{z}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 22: 38.9% accurate, 1.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -3 \cdot 10^{+22}:\\ \;\;\;\;t\\ \mathbf{elif}\;z \leq 8.2 \cdot 10^{+136}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;t\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= z -3e+22) t (if (<= z 8.2e+136) x t)))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (z <= -3e+22) {
		tmp = t;
	} else if (z <= 8.2e+136) {
		tmp = x;
	} else {
		tmp = t;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: tmp
    if (z <= (-3d+22)) then
        tmp = t
    else if (z <= 8.2d+136) then
        tmp = x
    else
        tmp = t
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (z <= -3e+22) {
		tmp = t;
	} else if (z <= 8.2e+136) {
		tmp = x;
	} else {
		tmp = t;
	}
	return tmp;
}
def code(x, y, z, t, a):
	tmp = 0
	if z <= -3e+22:
		tmp = t
	elif z <= 8.2e+136:
		tmp = x
	else:
		tmp = t
	return tmp
function code(x, y, z, t, a)
	tmp = 0.0
	if (z <= -3e+22)
		tmp = t;
	elseif (z <= 8.2e+136)
		tmp = x;
	else
		tmp = t;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	tmp = 0.0;
	if (z <= -3e+22)
		tmp = t;
	elseif (z <= 8.2e+136)
		tmp = x;
	else
		tmp = t;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -3e+22], t, If[LessEqual[z, 8.2e+136], x, t]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3 \cdot 10^{+22}:\\
\;\;\;\;t\\

\mathbf{elif}\;z \leq 8.2 \cdot 10^{+136}:\\
\;\;\;\;x\\

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


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

    1. Initial program 34.6%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 49.1%

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

    if -3e22 < z < 8.1999999999999995e136

    1. Initial program 84.6%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Add Preprocessing
    3. Taylor expanded in a around inf 35.9%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3 \cdot 10^{+22}:\\ \;\;\;\;t\\ \mathbf{elif}\;z \leq 8.2 \cdot 10^{+136}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;t\\ \end{array} \]
  5. Add Preprocessing

Alternative 23: 25.0% accurate, 13.0× speedup?

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

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

    \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
  2. Add Preprocessing
  3. Taylor expanded in z around inf 22.8%

    \[\leadsto \color{blue}{t} \]
  4. Final simplification22.8%

    \[\leadsto t \]
  5. Add Preprocessing

Developer target: 84.2% accurate, 0.6× speedup?

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

\\
\begin{array}{l}
t_1 := t - \frac{y}{z} \cdot \left(t - x\right)\\
\mathbf{if}\;z < -1.2536131056095036 \cdot 10^{+188}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;z < 4.446702369113811 \cdot 10^{+64}:\\
\;\;\;\;x + \frac{y - z}{\frac{a - z}{t - x}}\\

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


\end{array}
\end{array}

Reproduce

?
herbie shell --seed 2024034 
(FPCore (x y z t a)
  :name "Graphics.Rendering.Chart.Axis.Types:invLinMap from Chart-1.5.3"
  :precision binary64

  :herbie-target
  (if (< z -1.2536131056095036e+188) (- t (* (/ y z) (- t x))) (if (< z 4.446702369113811e+64) (+ x (/ (- y z) (/ (- a z) (- t x)))) (- t (* (/ y z) (- t x)))))

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