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

Percentage Accurate: 68.2% → 89.1%
Time: 27.0s
Alternatives: 23
Speedup: 1.0×

Specification

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

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

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

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

Accuracy vs Speed?

Herbie found 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.2% accurate, 1.0× speedup?

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

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

Alternative 1: 89.1% accurate, 0.8× speedup?

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -1.24999999999999994e123 or 1.84999999999999999e92 < t

    1. Initial program 39.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto y - \color{blue}{\frac{y - x}{\frac{t}{z - a}}} \]
    6. Simplified87.4%

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

    if -1.24999999999999994e123 < t < 1.84999999999999999e92

    1. Initial program 88.0%

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

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

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

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

Alternative 2: 48.4% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := y - y \cdot \frac{z}{t}\\ t_2 := x - \frac{t \cdot y}{a}\\ \mathbf{if}\;a \leq -1.24 \cdot 10^{+107}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;a \leq -1.55 \cdot 10^{+47}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq -16000000000:\\ \;\;\;\;t_2\\ \mathbf{elif}\;a \leq 4 \cdot 10^{-192}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq 2.9 \cdot 10^{-177}:\\ \;\;\;\;\frac{z}{\frac{t}{x}}\\ \mathbf{elif}\;a \leq 6.3 \cdot 10^{-111}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq 1.56 \cdot 10^{+97}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (- y (* y (/ z t)))) (t_2 (- x (/ (* t y) a))))
   (if (<= a -1.24e+107)
     t_2
     (if (<= a -1.55e+47)
       t_1
       (if (<= a -16000000000.0)
         t_2
         (if (<= a 4e-192)
           t_1
           (if (<= a 2.9e-177)
             (/ z (/ t x))
             (if (<= a 6.3e-111)
               t_1
               (if (<= a 1.56e+97) (* z (/ (- y x) a)) t_2)))))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = y - (y * (z / t));
	double t_2 = x - ((t * y) / a);
	double tmp;
	if (a <= -1.24e+107) {
		tmp = t_2;
	} else if (a <= -1.55e+47) {
		tmp = t_1;
	} else if (a <= -16000000000.0) {
		tmp = t_2;
	} else if (a <= 4e-192) {
		tmp = t_1;
	} else if (a <= 2.9e-177) {
		tmp = z / (t / x);
	} else if (a <= 6.3e-111) {
		tmp = t_1;
	} else if (a <= 1.56e+97) {
		tmp = z * ((y - x) / a);
	} else {
		tmp = t_2;
	}
	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) :: t_2
    real(8) :: tmp
    t_1 = y - (y * (z / t))
    t_2 = x - ((t * y) / a)
    if (a <= (-1.24d+107)) then
        tmp = t_2
    else if (a <= (-1.55d+47)) then
        tmp = t_1
    else if (a <= (-16000000000.0d0)) then
        tmp = t_2
    else if (a <= 4d-192) then
        tmp = t_1
    else if (a <= 2.9d-177) then
        tmp = z / (t / x)
    else if (a <= 6.3d-111) then
        tmp = t_1
    else if (a <= 1.56d+97) then
        tmp = z * ((y - x) / a)
    else
        tmp = t_2
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = y - (y * (z / t));
	double t_2 = x - ((t * y) / a);
	double tmp;
	if (a <= -1.24e+107) {
		tmp = t_2;
	} else if (a <= -1.55e+47) {
		tmp = t_1;
	} else if (a <= -16000000000.0) {
		tmp = t_2;
	} else if (a <= 4e-192) {
		tmp = t_1;
	} else if (a <= 2.9e-177) {
		tmp = z / (t / x);
	} else if (a <= 6.3e-111) {
		tmp = t_1;
	} else if (a <= 1.56e+97) {
		tmp = z * ((y - x) / a);
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = y - (y * (z / t))
	t_2 = x - ((t * y) / a)
	tmp = 0
	if a <= -1.24e+107:
		tmp = t_2
	elif a <= -1.55e+47:
		tmp = t_1
	elif a <= -16000000000.0:
		tmp = t_2
	elif a <= 4e-192:
		tmp = t_1
	elif a <= 2.9e-177:
		tmp = z / (t / x)
	elif a <= 6.3e-111:
		tmp = t_1
	elif a <= 1.56e+97:
		tmp = z * ((y - x) / a)
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(y - Float64(y * Float64(z / t)))
	t_2 = Float64(x - Float64(Float64(t * y) / a))
	tmp = 0.0
	if (a <= -1.24e+107)
		tmp = t_2;
	elseif (a <= -1.55e+47)
		tmp = t_1;
	elseif (a <= -16000000000.0)
		tmp = t_2;
	elseif (a <= 4e-192)
		tmp = t_1;
	elseif (a <= 2.9e-177)
		tmp = Float64(z / Float64(t / x));
	elseif (a <= 6.3e-111)
		tmp = t_1;
	elseif (a <= 1.56e+97)
		tmp = Float64(z * Float64(Float64(y - x) / a));
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = y - (y * (z / t));
	t_2 = x - ((t * y) / a);
	tmp = 0.0;
	if (a <= -1.24e+107)
		tmp = t_2;
	elseif (a <= -1.55e+47)
		tmp = t_1;
	elseif (a <= -16000000000.0)
		tmp = t_2;
	elseif (a <= 4e-192)
		tmp = t_1;
	elseif (a <= 2.9e-177)
		tmp = z / (t / x);
	elseif (a <= 6.3e-111)
		tmp = t_1;
	elseif (a <= 1.56e+97)
		tmp = z * ((y - x) / a);
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y - N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x - N[(N[(t * y), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -1.24e+107], t$95$2, If[LessEqual[a, -1.55e+47], t$95$1, If[LessEqual[a, -16000000000.0], t$95$2, If[LessEqual[a, 4e-192], t$95$1, If[LessEqual[a, 2.9e-177], N[(z / N[(t / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 6.3e-111], t$95$1, If[LessEqual[a, 1.56e+97], N[(z * N[(N[(y - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], t$95$2]]]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;a \leq -1.55 \cdot 10^{+47}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;a \leq -16000000000:\\
\;\;\;\;t_2\\

\mathbf{elif}\;a \leq 4 \cdot 10^{-192}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;a \leq 2.9 \cdot 10^{-177}:\\
\;\;\;\;\frac{z}{\frac{t}{x}}\\

\mathbf{elif}\;a \leq 6.3 \cdot 10^{-111}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;a \leq 1.56 \cdot 10^{+97}:\\
\;\;\;\;z \cdot \frac{y - x}{a}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if a < -1.24e107 or -1.55e47 < a < -1.6e10 or 1.56e97 < a

    1. Initial program 79.1%

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

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

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

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

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

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

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

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

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

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

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

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

    if -1.24e107 < a < -1.55e47 or -1.6e10 < a < 4.0000000000000004e-192 or 2.89999999999999997e-177 < a < 6.3000000000000004e-111

    1. Initial program 64.2%

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

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

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

        \[\leadsto \color{blue}{\frac{z - t}{\frac{a - t}{y - x}}} + x \]
      4. associate-/r/74.1%

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

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

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

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

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

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

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

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

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

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

        \[\leadsto y - \color{blue}{y \cdot \frac{z}{t}} \]
    10. Simplified62.6%

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

    if 4.0000000000000004e-192 < a < 2.89999999999999997e-177

    1. Initial program 61.6%

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

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

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

        \[\leadsto \color{blue}{\frac{z - t}{\frac{a - t}{y - x}}} + x \]
      4. associate-/r/61.0%

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

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

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{z}{\frac{t}{x}}} \]
    10. Applied egg-rr61.4%

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

    if 6.3000000000000004e-111 < a < 1.56e97

    1. Initial program 86.9%

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

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

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

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

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

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

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

        \[\leadsto z \cdot \color{blue}{\frac{y - x}{a}} \]
    9. Simplified46.6%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -1.24 \cdot 10^{+107}:\\ \;\;\;\;x - \frac{t \cdot y}{a}\\ \mathbf{elif}\;a \leq -1.55 \cdot 10^{+47}:\\ \;\;\;\;y - y \cdot \frac{z}{t}\\ \mathbf{elif}\;a \leq -16000000000:\\ \;\;\;\;x - \frac{t \cdot y}{a}\\ \mathbf{elif}\;a \leq 4 \cdot 10^{-192}:\\ \;\;\;\;y - y \cdot \frac{z}{t}\\ \mathbf{elif}\;a \leq 2.9 \cdot 10^{-177}:\\ \;\;\;\;\frac{z}{\frac{t}{x}}\\ \mathbf{elif}\;a \leq 6.3 \cdot 10^{-111}:\\ \;\;\;\;y - y \cdot \frac{z}{t}\\ \mathbf{elif}\;a \leq 1.56 \cdot 10^{+97}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \mathbf{else}:\\ \;\;\;\;x - \frac{t \cdot y}{a}\\ \end{array} \]

Alternative 3: 48.6% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := y - y \cdot \frac{z}{t}\\ t_2 := x - \frac{t \cdot y}{a}\\ \mathbf{if}\;a \leq -2.4 \cdot 10^{+106}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;a \leq -1.7 \cdot 10^{+47}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq -8 \cdot 10^{+14}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;a \leq 4.2 \cdot 10^{-192}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq 2.9 \cdot 10^{-177}:\\ \;\;\;\;\frac{z}{\frac{t}{x}}\\ \mathbf{elif}\;a \leq 4.8 \cdot 10^{-111}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq 1.55 \cdot 10^{+97}:\\ \;\;\;\;\frac{z}{\frac{a}{y - x}}\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (- y (* y (/ z t)))) (t_2 (- x (/ (* t y) a))))
   (if (<= a -2.4e+106)
     t_2
     (if (<= a -1.7e+47)
       t_1
       (if (<= a -8e+14)
         t_2
         (if (<= a 4.2e-192)
           t_1
           (if (<= a 2.9e-177)
             (/ z (/ t x))
             (if (<= a 4.8e-111)
               t_1
               (if (<= a 1.55e+97) (/ z (/ a (- y x))) t_2)))))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = y - (y * (z / t));
	double t_2 = x - ((t * y) / a);
	double tmp;
	if (a <= -2.4e+106) {
		tmp = t_2;
	} else if (a <= -1.7e+47) {
		tmp = t_1;
	} else if (a <= -8e+14) {
		tmp = t_2;
	} else if (a <= 4.2e-192) {
		tmp = t_1;
	} else if (a <= 2.9e-177) {
		tmp = z / (t / x);
	} else if (a <= 4.8e-111) {
		tmp = t_1;
	} else if (a <= 1.55e+97) {
		tmp = z / (a / (y - x));
	} else {
		tmp = t_2;
	}
	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) :: t_2
    real(8) :: tmp
    t_1 = y - (y * (z / t))
    t_2 = x - ((t * y) / a)
    if (a <= (-2.4d+106)) then
        tmp = t_2
    else if (a <= (-1.7d+47)) then
        tmp = t_1
    else if (a <= (-8d+14)) then
        tmp = t_2
    else if (a <= 4.2d-192) then
        tmp = t_1
    else if (a <= 2.9d-177) then
        tmp = z / (t / x)
    else if (a <= 4.8d-111) then
        tmp = t_1
    else if (a <= 1.55d+97) then
        tmp = z / (a / (y - x))
    else
        tmp = t_2
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = y - (y * (z / t));
	double t_2 = x - ((t * y) / a);
	double tmp;
	if (a <= -2.4e+106) {
		tmp = t_2;
	} else if (a <= -1.7e+47) {
		tmp = t_1;
	} else if (a <= -8e+14) {
		tmp = t_2;
	} else if (a <= 4.2e-192) {
		tmp = t_1;
	} else if (a <= 2.9e-177) {
		tmp = z / (t / x);
	} else if (a <= 4.8e-111) {
		tmp = t_1;
	} else if (a <= 1.55e+97) {
		tmp = z / (a / (y - x));
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = y - (y * (z / t))
	t_2 = x - ((t * y) / a)
	tmp = 0
	if a <= -2.4e+106:
		tmp = t_2
	elif a <= -1.7e+47:
		tmp = t_1
	elif a <= -8e+14:
		tmp = t_2
	elif a <= 4.2e-192:
		tmp = t_1
	elif a <= 2.9e-177:
		tmp = z / (t / x)
	elif a <= 4.8e-111:
		tmp = t_1
	elif a <= 1.55e+97:
		tmp = z / (a / (y - x))
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(y - Float64(y * Float64(z / t)))
	t_2 = Float64(x - Float64(Float64(t * y) / a))
	tmp = 0.0
	if (a <= -2.4e+106)
		tmp = t_2;
	elseif (a <= -1.7e+47)
		tmp = t_1;
	elseif (a <= -8e+14)
		tmp = t_2;
	elseif (a <= 4.2e-192)
		tmp = t_1;
	elseif (a <= 2.9e-177)
		tmp = Float64(z / Float64(t / x));
	elseif (a <= 4.8e-111)
		tmp = t_1;
	elseif (a <= 1.55e+97)
		tmp = Float64(z / Float64(a / Float64(y - x)));
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = y - (y * (z / t));
	t_2 = x - ((t * y) / a);
	tmp = 0.0;
	if (a <= -2.4e+106)
		tmp = t_2;
	elseif (a <= -1.7e+47)
		tmp = t_1;
	elseif (a <= -8e+14)
		tmp = t_2;
	elseif (a <= 4.2e-192)
		tmp = t_1;
	elseif (a <= 2.9e-177)
		tmp = z / (t / x);
	elseif (a <= 4.8e-111)
		tmp = t_1;
	elseif (a <= 1.55e+97)
		tmp = z / (a / (y - x));
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y - N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x - N[(N[(t * y), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -2.4e+106], t$95$2, If[LessEqual[a, -1.7e+47], t$95$1, If[LessEqual[a, -8e+14], t$95$2, If[LessEqual[a, 4.2e-192], t$95$1, If[LessEqual[a, 2.9e-177], N[(z / N[(t / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 4.8e-111], t$95$1, If[LessEqual[a, 1.55e+97], N[(z / N[(a / N[(y - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$2]]]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;a \leq -1.7 \cdot 10^{+47}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;a \leq -8 \cdot 10^{+14}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;a \leq 4.2 \cdot 10^{-192}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;a \leq 2.9 \cdot 10^{-177}:\\
\;\;\;\;\frac{z}{\frac{t}{x}}\\

\mathbf{elif}\;a \leq 4.8 \cdot 10^{-111}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;a \leq 1.55 \cdot 10^{+97}:\\
\;\;\;\;\frac{z}{\frac{a}{y - x}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if a < -2.4000000000000001e106 or -1.6999999999999999e47 < a < -8e14 or 1.54999999999999991e97 < a

    1. Initial program 79.1%

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

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

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

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

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

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

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

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

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

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

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

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

    if -2.4000000000000001e106 < a < -1.6999999999999999e47 or -8e14 < a < 4.19999999999999986e-192 or 2.89999999999999997e-177 < a < 4.8000000000000001e-111

    1. Initial program 64.2%

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

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

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

        \[\leadsto \color{blue}{\frac{z - t}{\frac{a - t}{y - x}}} + x \]
      4. associate-/r/74.1%

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

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

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

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

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

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

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

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

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

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

        \[\leadsto y - \color{blue}{y \cdot \frac{z}{t}} \]
    10. Simplified62.6%

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

    if 4.19999999999999986e-192 < a < 2.89999999999999997e-177

    1. Initial program 61.6%

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

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

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

        \[\leadsto \color{blue}{\frac{z - t}{\frac{a - t}{y - x}}} + x \]
      4. associate-/r/61.0%

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

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

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{z}{\frac{t}{x}}} \]
    10. Applied egg-rr61.4%

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

    if 4.8000000000000001e-111 < a < 1.54999999999999991e97

    1. Initial program 86.9%

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -2.4 \cdot 10^{+106}:\\ \;\;\;\;x - \frac{t \cdot y}{a}\\ \mathbf{elif}\;a \leq -1.7 \cdot 10^{+47}:\\ \;\;\;\;y - y \cdot \frac{z}{t}\\ \mathbf{elif}\;a \leq -8 \cdot 10^{+14}:\\ \;\;\;\;x - \frac{t \cdot y}{a}\\ \mathbf{elif}\;a \leq 4.2 \cdot 10^{-192}:\\ \;\;\;\;y - y \cdot \frac{z}{t}\\ \mathbf{elif}\;a \leq 2.9 \cdot 10^{-177}:\\ \;\;\;\;\frac{z}{\frac{t}{x}}\\ \mathbf{elif}\;a \leq 4.8 \cdot 10^{-111}:\\ \;\;\;\;y - y \cdot \frac{z}{t}\\ \mathbf{elif}\;a \leq 1.55 \cdot 10^{+97}:\\ \;\;\;\;\frac{z}{\frac{a}{y - x}}\\ \mathbf{else}:\\ \;\;\;\;x - \frac{t \cdot y}{a}\\ \end{array} \]

Alternative 4: 73.6% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x - \frac{x - y}{\frac{a}{z - t}}\\ \mathbf{if}\;a \leq -1.85 \cdot 10^{+89}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq -1.75 \cdot 10^{+47}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;a \leq -120 \lor \neg \left(a \leq 1.6 \cdot 10^{-64}\right):\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;y + \frac{z}{t} \cdot \left(x - y\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (- x (/ (- x y) (/ a (- z t))))))
   (if (<= a -1.85e+89)
     t_1
     (if (<= a -1.75e+47)
       (* y (/ (- z t) (- a t)))
       (if (or (<= a -120.0) (not (<= a 1.6e-64)))
         t_1
         (+ y (* (/ z t) (- x y))))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = x - ((x - y) / (a / (z - t)));
	double tmp;
	if (a <= -1.85e+89) {
		tmp = t_1;
	} else if (a <= -1.75e+47) {
		tmp = y * ((z - t) / (a - t));
	} else if ((a <= -120.0) || !(a <= 1.6e-64)) {
		tmp = t_1;
	} else {
		tmp = y + ((z / t) * (x - 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) :: t_1
    real(8) :: tmp
    t_1 = x - ((x - y) / (a / (z - t)))
    if (a <= (-1.85d+89)) then
        tmp = t_1
    else if (a <= (-1.75d+47)) then
        tmp = y * ((z - t) / (a - t))
    else if ((a <= (-120.0d0)) .or. (.not. (a <= 1.6d-64))) then
        tmp = t_1
    else
        tmp = y + ((z / t) * (x - y))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = x - ((x - y) / (a / (z - t)));
	double tmp;
	if (a <= -1.85e+89) {
		tmp = t_1;
	} else if (a <= -1.75e+47) {
		tmp = y * ((z - t) / (a - t));
	} else if ((a <= -120.0) || !(a <= 1.6e-64)) {
		tmp = t_1;
	} else {
		tmp = y + ((z / t) * (x - y));
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = x - ((x - y) / (a / (z - t)))
	tmp = 0
	if a <= -1.85e+89:
		tmp = t_1
	elif a <= -1.75e+47:
		tmp = y * ((z - t) / (a - t))
	elif (a <= -120.0) or not (a <= 1.6e-64):
		tmp = t_1
	else:
		tmp = y + ((z / t) * (x - y))
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(x - Float64(Float64(x - y) / Float64(a / Float64(z - t))))
	tmp = 0.0
	if (a <= -1.85e+89)
		tmp = t_1;
	elseif (a <= -1.75e+47)
		tmp = Float64(y * Float64(Float64(z - t) / Float64(a - t)));
	elseif ((a <= -120.0) || !(a <= 1.6e-64))
		tmp = t_1;
	else
		tmp = Float64(y + Float64(Float64(z / t) * Float64(x - y)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = x - ((x - y) / (a / (z - t)));
	tmp = 0.0;
	if (a <= -1.85e+89)
		tmp = t_1;
	elseif (a <= -1.75e+47)
		tmp = y * ((z - t) / (a - t));
	elseif ((a <= -120.0) || ~((a <= 1.6e-64)))
		tmp = t_1;
	else
		tmp = y + ((z / t) * (x - y));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x - N[(N[(x - y), $MachinePrecision] / N[(a / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -1.85e+89], t$95$1, If[LessEqual[a, -1.75e+47], N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[a, -120.0], N[Not[LessEqual[a, 1.6e-64]], $MachinePrecision]], t$95$1, N[(y + N[(N[(z / t), $MachinePrecision] * N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}

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

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

\mathbf{elif}\;a \leq -120 \lor \neg \left(a \leq 1.6 \cdot 10^{-64}\right):\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if a < -1.8499999999999999e89 or -1.75000000000000008e47 < a < -120 or 1.59999999999999988e-64 < a

    1. Initial program 79.9%

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

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

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

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

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

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

    if -1.8499999999999999e89 < a < -1.75000000000000008e47

    1. Initial program 63.0%

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

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

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

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

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

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

    if -120 < a < 1.59999999999999988e-64

    1. Initial program 66.9%

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

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

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

        \[\leadsto \color{blue}{\frac{z - t}{\frac{a - t}{y - x}}} + x \]
      4. associate-/r/73.5%

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -1.85 \cdot 10^{+89}:\\ \;\;\;\;x - \frac{x - y}{\frac{a}{z - t}}\\ \mathbf{elif}\;a \leq -1.75 \cdot 10^{+47}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;a \leq -120 \lor \neg \left(a \leq 1.6 \cdot 10^{-64}\right):\\ \;\;\;\;x - \frac{x - y}{\frac{a}{z - t}}\\ \mathbf{else}:\\ \;\;\;\;y + \frac{z}{t} \cdot \left(x - y\right)\\ \end{array} \]

Alternative 5: 75.2% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x - \frac{x - y}{\frac{a}{z - t}}\\ \mathbf{if}\;a \leq -1.7 \cdot 10^{+88}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq -3.1 \cdot 10^{+47}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;a \leq -750 \lor \neg \left(a \leq 2.4 \cdot 10^{-64}\right):\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;y + \frac{x - y}{\frac{t}{z - a}}\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (- x (/ (- x y) (/ a (- z t))))))
   (if (<= a -1.7e+88)
     t_1
     (if (<= a -3.1e+47)
       (* y (/ (- z t) (- a t)))
       (if (or (<= a -750.0) (not (<= a 2.4e-64)))
         t_1
         (+ y (/ (- x y) (/ t (- z a)))))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = x - ((x - y) / (a / (z - t)));
	double tmp;
	if (a <= -1.7e+88) {
		tmp = t_1;
	} else if (a <= -3.1e+47) {
		tmp = y * ((z - t) / (a - t));
	} else if ((a <= -750.0) || !(a <= 2.4e-64)) {
		tmp = t_1;
	} else {
		tmp = y + ((x - y) / (t / (z - 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) :: t_1
    real(8) :: tmp
    t_1 = x - ((x - y) / (a / (z - t)))
    if (a <= (-1.7d+88)) then
        tmp = t_1
    else if (a <= (-3.1d+47)) then
        tmp = y * ((z - t) / (a - t))
    else if ((a <= (-750.0d0)) .or. (.not. (a <= 2.4d-64))) then
        tmp = t_1
    else
        tmp = y + ((x - y) / (t / (z - a)))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = x - ((x - y) / (a / (z - t)));
	double tmp;
	if (a <= -1.7e+88) {
		tmp = t_1;
	} else if (a <= -3.1e+47) {
		tmp = y * ((z - t) / (a - t));
	} else if ((a <= -750.0) || !(a <= 2.4e-64)) {
		tmp = t_1;
	} else {
		tmp = y + ((x - y) / (t / (z - a)));
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = x - ((x - y) / (a / (z - t)))
	tmp = 0
	if a <= -1.7e+88:
		tmp = t_1
	elif a <= -3.1e+47:
		tmp = y * ((z - t) / (a - t))
	elif (a <= -750.0) or not (a <= 2.4e-64):
		tmp = t_1
	else:
		tmp = y + ((x - y) / (t / (z - a)))
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(x - Float64(Float64(x - y) / Float64(a / Float64(z - t))))
	tmp = 0.0
	if (a <= -1.7e+88)
		tmp = t_1;
	elseif (a <= -3.1e+47)
		tmp = Float64(y * Float64(Float64(z - t) / Float64(a - t)));
	elseif ((a <= -750.0) || !(a <= 2.4e-64))
		tmp = t_1;
	else
		tmp = Float64(y + Float64(Float64(x - y) / Float64(t / Float64(z - a))));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = x - ((x - y) / (a / (z - t)));
	tmp = 0.0;
	if (a <= -1.7e+88)
		tmp = t_1;
	elseif (a <= -3.1e+47)
		tmp = y * ((z - t) / (a - t));
	elseif ((a <= -750.0) || ~((a <= 2.4e-64)))
		tmp = t_1;
	else
		tmp = y + ((x - y) / (t / (z - a)));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x - N[(N[(x - y), $MachinePrecision] / N[(a / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -1.7e+88], t$95$1, If[LessEqual[a, -3.1e+47], N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[a, -750.0], N[Not[LessEqual[a, 2.4e-64]], $MachinePrecision]], t$95$1, N[(y + N[(N[(x - y), $MachinePrecision] / N[(t / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}

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

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

\mathbf{elif}\;a \leq -750 \lor \neg \left(a \leq 2.4 \cdot 10^{-64}\right):\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if a < -1.70000000000000002e88 or -3.1000000000000001e47 < a < -750 or 2.39999999999999998e-64 < a

    1. Initial program 79.9%

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

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

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

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

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

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

    if -1.70000000000000002e88 < a < -3.1000000000000001e47

    1. Initial program 63.0%

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

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

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

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

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

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

    if -750 < a < 2.39999999999999998e-64

    1. Initial program 66.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto y - \color{blue}{\frac{y - x}{\frac{t}{z - a}}} \]
    6. Simplified86.4%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -1.7 \cdot 10^{+88}:\\ \;\;\;\;x - \frac{x - y}{\frac{a}{z - t}}\\ \mathbf{elif}\;a \leq -3.1 \cdot 10^{+47}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;a \leq -750 \lor \neg \left(a \leq 2.4 \cdot 10^{-64}\right):\\ \;\;\;\;x - \frac{x - y}{\frac{a}{z - t}}\\ \mathbf{else}:\\ \;\;\;\;y + \frac{x - y}{\frac{t}{z - a}}\\ \end{array} \]

Alternative 6: 32.2% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -4.3 \cdot 10^{+167}:\\ \;\;\;\;y \cdot \frac{z}{a}\\ \mathbf{elif}\;z \leq -9.6 \cdot 10^{+78}:\\ \;\;\;\;y\\ \mathbf{elif}\;z \leq -4.6 \cdot 10^{-10}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq 2.85 \cdot 10^{-219}:\\ \;\;\;\;y\\ \mathbf{elif}\;z \leq 5.2 \cdot 10^{+38}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;x \cdot \frac{z - a}{t}\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= z -4.3e+167)
   (* y (/ z a))
   (if (<= z -9.6e+78)
     y
     (if (<= z -4.6e-10)
       x
       (if (<= z 2.85e-219) y (if (<= z 5.2e+38) x (* x (/ (- z a) t))))))))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (z <= -4.3e+167) {
		tmp = y * (z / a);
	} else if (z <= -9.6e+78) {
		tmp = y;
	} else if (z <= -4.6e-10) {
		tmp = x;
	} else if (z <= 2.85e-219) {
		tmp = y;
	} else if (z <= 5.2e+38) {
		tmp = x;
	} else {
		tmp = x * ((z - a) / 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 <= (-4.3d+167)) then
        tmp = y * (z / a)
    else if (z <= (-9.6d+78)) then
        tmp = y
    else if (z <= (-4.6d-10)) then
        tmp = x
    else if (z <= 2.85d-219) then
        tmp = y
    else if (z <= 5.2d+38) then
        tmp = x
    else
        tmp = x * ((z - a) / 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 <= -4.3e+167) {
		tmp = y * (z / a);
	} else if (z <= -9.6e+78) {
		tmp = y;
	} else if (z <= -4.6e-10) {
		tmp = x;
	} else if (z <= 2.85e-219) {
		tmp = y;
	} else if (z <= 5.2e+38) {
		tmp = x;
	} else {
		tmp = x * ((z - a) / t);
	}
	return tmp;
}
def code(x, y, z, t, a):
	tmp = 0
	if z <= -4.3e+167:
		tmp = y * (z / a)
	elif z <= -9.6e+78:
		tmp = y
	elif z <= -4.6e-10:
		tmp = x
	elif z <= 2.85e-219:
		tmp = y
	elif z <= 5.2e+38:
		tmp = x
	else:
		tmp = x * ((z - a) / t)
	return tmp
function code(x, y, z, t, a)
	tmp = 0.0
	if (z <= -4.3e+167)
		tmp = Float64(y * Float64(z / a));
	elseif (z <= -9.6e+78)
		tmp = y;
	elseif (z <= -4.6e-10)
		tmp = x;
	elseif (z <= 2.85e-219)
		tmp = y;
	elseif (z <= 5.2e+38)
		tmp = x;
	else
		tmp = Float64(x * Float64(Float64(z - a) / t));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	tmp = 0.0;
	if (z <= -4.3e+167)
		tmp = y * (z / a);
	elseif (z <= -9.6e+78)
		tmp = y;
	elseif (z <= -4.6e-10)
		tmp = x;
	elseif (z <= 2.85e-219)
		tmp = y;
	elseif (z <= 5.2e+38)
		tmp = x;
	else
		tmp = x * ((z - a) / t);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -4.3e+167], N[(y * N[(z / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -9.6e+78], y, If[LessEqual[z, -4.6e-10], x, If[LessEqual[z, 2.85e-219], y, If[LessEqual[z, 5.2e+38], x, N[(x * N[(N[(z - a), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;z \leq -9.6 \cdot 10^{+78}:\\
\;\;\;\;y\\

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

\mathbf{elif}\;z \leq 2.85 \cdot 10^{-219}:\\
\;\;\;\;y\\

\mathbf{elif}\;z \leq 5.2 \cdot 10^{+38}:\\
\;\;\;\;x\\

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


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

    1. Initial program 78.2%

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{y \cdot \frac{z - t}{a}} \]
    10. Taylor expanded in z around inf 58.3%

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

    if -4.3000000000000002e167 < z < -9.5999999999999994e78 or -4.60000000000000014e-10 < z < 2.85000000000000003e-219

    1. Initial program 64.4%

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

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

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

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

    if -9.5999999999999994e78 < z < -4.60000000000000014e-10 or 2.85000000000000003e-219 < z < 5.1999999999999998e38

    1. Initial program 84.0%

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

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

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

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

    if 5.1999999999999998e38 < z

    1. Initial program 76.2%

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

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

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

        \[\leadsto \color{blue}{\frac{z - t}{\frac{a - t}{y - x}}} + x \]
      4. associate-/r/87.4%

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -4.3 \cdot 10^{+167}:\\ \;\;\;\;y \cdot \frac{z}{a}\\ \mathbf{elif}\;z \leq -9.6 \cdot 10^{+78}:\\ \;\;\;\;y\\ \mathbf{elif}\;z \leq -4.6 \cdot 10^{-10}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq 2.85 \cdot 10^{-219}:\\ \;\;\;\;y\\ \mathbf{elif}\;z \leq 5.2 \cdot 10^{+38}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;x \cdot \frac{z - a}{t}\\ \end{array} \]

Alternative 7: 41.3% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x - \frac{t \cdot y}{a}\\ t_2 := z \cdot \frac{y - x}{a}\\ \mathbf{if}\;z \leq -2.1 \cdot 10^{-27}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;z \leq -1.9 \cdot 10^{-143}:\\ \;\;\;\;y\\ \mathbf{elif}\;z \leq -6.5 \cdot 10^{-273}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 9.2 \cdot 10^{-245}:\\ \;\;\;\;y\\ \mathbf{elif}\;z \leq 15500000:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (- x (/ (* t y) a))) (t_2 (* z (/ (- y x) a))))
   (if (<= z -2.1e-27)
     t_2
     (if (<= z -1.9e-143)
       y
       (if (<= z -6.5e-273)
         t_1
         (if (<= z 9.2e-245) y (if (<= z 15500000.0) t_1 t_2)))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = x - ((t * y) / a);
	double t_2 = z * ((y - x) / a);
	double tmp;
	if (z <= -2.1e-27) {
		tmp = t_2;
	} else if (z <= -1.9e-143) {
		tmp = y;
	} else if (z <= -6.5e-273) {
		tmp = t_1;
	} else if (z <= 9.2e-245) {
		tmp = y;
	} else if (z <= 15500000.0) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	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) :: t_2
    real(8) :: tmp
    t_1 = x - ((t * y) / a)
    t_2 = z * ((y - x) / a)
    if (z <= (-2.1d-27)) then
        tmp = t_2
    else if (z <= (-1.9d-143)) then
        tmp = y
    else if (z <= (-6.5d-273)) then
        tmp = t_1
    else if (z <= 9.2d-245) then
        tmp = y
    else if (z <= 15500000.0d0) then
        tmp = t_1
    else
        tmp = t_2
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = x - ((t * y) / a);
	double t_2 = z * ((y - x) / a);
	double tmp;
	if (z <= -2.1e-27) {
		tmp = t_2;
	} else if (z <= -1.9e-143) {
		tmp = y;
	} else if (z <= -6.5e-273) {
		tmp = t_1;
	} else if (z <= 9.2e-245) {
		tmp = y;
	} else if (z <= 15500000.0) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = x - ((t * y) / a)
	t_2 = z * ((y - x) / a)
	tmp = 0
	if z <= -2.1e-27:
		tmp = t_2
	elif z <= -1.9e-143:
		tmp = y
	elif z <= -6.5e-273:
		tmp = t_1
	elif z <= 9.2e-245:
		tmp = y
	elif z <= 15500000.0:
		tmp = t_1
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(x - Float64(Float64(t * y) / a))
	t_2 = Float64(z * Float64(Float64(y - x) / a))
	tmp = 0.0
	if (z <= -2.1e-27)
		tmp = t_2;
	elseif (z <= -1.9e-143)
		tmp = y;
	elseif (z <= -6.5e-273)
		tmp = t_1;
	elseif (z <= 9.2e-245)
		tmp = y;
	elseif (z <= 15500000.0)
		tmp = t_1;
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = x - ((t * y) / a);
	t_2 = z * ((y - x) / a);
	tmp = 0.0;
	if (z <= -2.1e-27)
		tmp = t_2;
	elseif (z <= -1.9e-143)
		tmp = y;
	elseif (z <= -6.5e-273)
		tmp = t_1;
	elseif (z <= 9.2e-245)
		tmp = y;
	elseif (z <= 15500000.0)
		tmp = t_1;
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x - N[(N[(t * y), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(z * N[(N[(y - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2.1e-27], t$95$2, If[LessEqual[z, -1.9e-143], y, If[LessEqual[z, -6.5e-273], t$95$1, If[LessEqual[z, 9.2e-245], y, If[LessEqual[z, 15500000.0], t$95$1, t$95$2]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x - \frac{t \cdot y}{a}\\
t_2 := z \cdot \frac{y - x}{a}\\
\mathbf{if}\;z \leq -2.1 \cdot 10^{-27}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;z \leq -1.9 \cdot 10^{-143}:\\
\;\;\;\;y\\

\mathbf{elif}\;z \leq -6.5 \cdot 10^{-273}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq 9.2 \cdot 10^{-245}:\\
\;\;\;\;y\\

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

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


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

    1. Initial program 75.8%

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

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

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

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

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

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

      \[\leadsto \color{blue}{z \cdot \left(\frac{y}{a} - \frac{x}{a}\right)} \]
    8. Step-by-step derivation
      1. div-sub49.0%

        \[\leadsto z \cdot \color{blue}{\frac{y - x}{a}} \]
    9. Simplified49.0%

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

    if -2.10000000000000015e-27 < z < -1.89999999999999991e-143 or -6.49999999999999979e-273 < z < 9.2000000000000007e-245

    1. Initial program 53.9%

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

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

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

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

    if -1.89999999999999991e-143 < z < -6.49999999999999979e-273 or 9.2000000000000007e-245 < z < 1.55e7

    1. Initial program 82.1%

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.1 \cdot 10^{-27}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \mathbf{elif}\;z \leq -1.9 \cdot 10^{-143}:\\ \;\;\;\;y\\ \mathbf{elif}\;z \leq -6.5 \cdot 10^{-273}:\\ \;\;\;\;x - \frac{t \cdot y}{a}\\ \mathbf{elif}\;z \leq 9.2 \cdot 10^{-245}:\\ \;\;\;\;y\\ \mathbf{elif}\;z \leq 15500000:\\ \;\;\;\;x - \frac{t \cdot y}{a}\\ \mathbf{else}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \end{array} \]

Alternative 8: 42.0% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -1.25 \cdot 10^{+169}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \mathbf{elif}\;z \leq -8 \cdot 10^{-128}:\\ \;\;\;\;y - y \cdot \frac{z}{t}\\ \mathbf{elif}\;z \leq 3.5 \cdot 10^{-236}:\\ \;\;\;\;y \cdot \frac{-t}{a - t}\\ \mathbf{elif}\;z \leq 54000000:\\ \;\;\;\;x - \frac{t \cdot y}{a}\\ \mathbf{elif}\;z \leq 7.5 \cdot 10^{+165}:\\ \;\;\;\;\frac{z}{\frac{a}{y - x}}\\ \mathbf{else}:\\ \;\;\;\;z \cdot \frac{x - y}{t}\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= z -1.25e+169)
   (* z (/ (- y x) a))
   (if (<= z -8e-128)
     (- y (* y (/ z t)))
     (if (<= z 3.5e-236)
       (* y (/ (- t) (- a t)))
       (if (<= z 54000000.0)
         (- x (/ (* t y) a))
         (if (<= z 7.5e+165) (/ z (/ a (- y x))) (* z (/ (- x y) t))))))))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (z <= -1.25e+169) {
		tmp = z * ((y - x) / a);
	} else if (z <= -8e-128) {
		tmp = y - (y * (z / t));
	} else if (z <= 3.5e-236) {
		tmp = y * (-t / (a - t));
	} else if (z <= 54000000.0) {
		tmp = x - ((t * y) / a);
	} else if (z <= 7.5e+165) {
		tmp = z / (a / (y - x));
	} else {
		tmp = z * ((x - y) / 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.25d+169)) then
        tmp = z * ((y - x) / a)
    else if (z <= (-8d-128)) then
        tmp = y - (y * (z / t))
    else if (z <= 3.5d-236) then
        tmp = y * (-t / (a - t))
    else if (z <= 54000000.0d0) then
        tmp = x - ((t * y) / a)
    else if (z <= 7.5d+165) then
        tmp = z / (a / (y - x))
    else
        tmp = z * ((x - y) / 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.25e+169) {
		tmp = z * ((y - x) / a);
	} else if (z <= -8e-128) {
		tmp = y - (y * (z / t));
	} else if (z <= 3.5e-236) {
		tmp = y * (-t / (a - t));
	} else if (z <= 54000000.0) {
		tmp = x - ((t * y) / a);
	} else if (z <= 7.5e+165) {
		tmp = z / (a / (y - x));
	} else {
		tmp = z * ((x - y) / t);
	}
	return tmp;
}
def code(x, y, z, t, a):
	tmp = 0
	if z <= -1.25e+169:
		tmp = z * ((y - x) / a)
	elif z <= -8e-128:
		tmp = y - (y * (z / t))
	elif z <= 3.5e-236:
		tmp = y * (-t / (a - t))
	elif z <= 54000000.0:
		tmp = x - ((t * y) / a)
	elif z <= 7.5e+165:
		tmp = z / (a / (y - x))
	else:
		tmp = z * ((x - y) / t)
	return tmp
function code(x, y, z, t, a)
	tmp = 0.0
	if (z <= -1.25e+169)
		tmp = Float64(z * Float64(Float64(y - x) / a));
	elseif (z <= -8e-128)
		tmp = Float64(y - Float64(y * Float64(z / t)));
	elseif (z <= 3.5e-236)
		tmp = Float64(y * Float64(Float64(-t) / Float64(a - t)));
	elseif (z <= 54000000.0)
		tmp = Float64(x - Float64(Float64(t * y) / a));
	elseif (z <= 7.5e+165)
		tmp = Float64(z / Float64(a / Float64(y - x)));
	else
		tmp = Float64(z * Float64(Float64(x - y) / t));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	tmp = 0.0;
	if (z <= -1.25e+169)
		tmp = z * ((y - x) / a);
	elseif (z <= -8e-128)
		tmp = y - (y * (z / t));
	elseif (z <= 3.5e-236)
		tmp = y * (-t / (a - t));
	elseif (z <= 54000000.0)
		tmp = x - ((t * y) / a);
	elseif (z <= 7.5e+165)
		tmp = z / (a / (y - x));
	else
		tmp = z * ((x - y) / t);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.25e+169], N[(z * N[(N[(y - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -8e-128], N[(y - N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 3.5e-236], N[(y * N[((-t) / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 54000000.0], N[(x - N[(N[(t * y), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 7.5e+165], N[(z / N[(a / N[(y - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(z * N[(N[(x - y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.25 \cdot 10^{+169}:\\
\;\;\;\;z \cdot \frac{y - x}{a}\\

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

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

\mathbf{elif}\;z \leq 54000000:\\
\;\;\;\;x - \frac{t \cdot y}{a}\\

\mathbf{elif}\;z \leq 7.5 \cdot 10^{+165}:\\
\;\;\;\;\frac{z}{\frac{a}{y - x}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 6 regimes
  2. if z < -1.25000000000000004e169

    1. Initial program 78.2%

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

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

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

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

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

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

      \[\leadsto \color{blue}{z \cdot \left(\frac{y}{a} - \frac{x}{a}\right)} \]
    8. Step-by-step derivation
      1. div-sub77.2%

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

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

    if -1.25000000000000004e169 < z < -8.00000000000000043e-128

    1. Initial program 66.1%

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

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

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

        \[\leadsto \color{blue}{\frac{z - t}{\frac{a - t}{y - x}}} + x \]
      4. associate-/r/77.6%

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

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

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

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

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

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

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

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

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

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

        \[\leadsto y - \color{blue}{y \cdot \frac{z}{t}} \]
    10. Simplified47.8%

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

    if -8.00000000000000043e-128 < z < 3.49999999999999994e-236

    1. Initial program 69.2%

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

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

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

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

        \[\leadsto \color{blue}{y \cdot \frac{z - t}{a - t}} \]
    6. Simplified67.4%

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

      \[\leadsto y \cdot \color{blue}{\left(-1 \cdot \frac{t}{a - t}\right)} \]
    8. Step-by-step derivation
      1. neg-mul-163.7%

        \[\leadsto y \cdot \color{blue}{\left(-\frac{t}{a - t}\right)} \]
      2. distribute-neg-frac63.7%

        \[\leadsto y \cdot \color{blue}{\frac{-t}{a - t}} \]
    9. Simplified63.7%

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

    if 3.49999999999999994e-236 < z < 5.4e7

    1. Initial program 82.6%

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

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

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

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

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

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

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

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

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

        \[\leadsto x - \frac{\color{blue}{\left(y - x\right) \cdot t}}{a} \]
    9. Simplified56.0%

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

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

    if 5.4e7 < z < 7.49999999999999996e165

    1. Initial program 64.9%

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

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{z}{\frac{a - t}{y - x}}} \]
    6. Simplified57.4%

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

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

    if 7.49999999999999996e165 < z

    1. Initial program 83.3%

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

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

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

        \[\leadsto \color{blue}{\frac{z - t}{\frac{a - t}{y - x}}} + x \]
      4. associate-/r/93.4%

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.25 \cdot 10^{+169}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \mathbf{elif}\;z \leq -8 \cdot 10^{-128}:\\ \;\;\;\;y - y \cdot \frac{z}{t}\\ \mathbf{elif}\;z \leq 3.5 \cdot 10^{-236}:\\ \;\;\;\;y \cdot \frac{-t}{a - t}\\ \mathbf{elif}\;z \leq 54000000:\\ \;\;\;\;x - \frac{t \cdot y}{a}\\ \mathbf{elif}\;z \leq 7.5 \cdot 10^{+165}:\\ \;\;\;\;\frac{z}{\frac{a}{y - x}}\\ \mathbf{else}:\\ \;\;\;\;z \cdot \frac{x - y}{t}\\ \end{array} \]

Alternative 9: 42.5% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -4.3 \cdot 10^{+167}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \mathbf{elif}\;z \leq -1.8 \cdot 10^{-127}:\\ \;\;\;\;y - y \cdot \frac{z}{t}\\ \mathbf{elif}\;z \leq 2 \cdot 10^{-244}:\\ \;\;\;\;y \cdot \frac{-t}{a - t}\\ \mathbf{elif}\;z \leq 75000000:\\ \;\;\;\;x - \frac{t \cdot y}{a}\\ \mathbf{elif}\;z \leq 8.5 \cdot 10^{+160}:\\ \;\;\;\;\frac{z}{\frac{a}{y - x}}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{t} \cdot \left(x - y\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= z -4.3e+167)
   (* z (/ (- y x) a))
   (if (<= z -1.8e-127)
     (- y (* y (/ z t)))
     (if (<= z 2e-244)
       (* y (/ (- t) (- a t)))
       (if (<= z 75000000.0)
         (- x (/ (* t y) a))
         (if (<= z 8.5e+160) (/ z (/ a (- y x))) (* (/ z t) (- x y))))))))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (z <= -4.3e+167) {
		tmp = z * ((y - x) / a);
	} else if (z <= -1.8e-127) {
		tmp = y - (y * (z / t));
	} else if (z <= 2e-244) {
		tmp = y * (-t / (a - t));
	} else if (z <= 75000000.0) {
		tmp = x - ((t * y) / a);
	} else if (z <= 8.5e+160) {
		tmp = z / (a / (y - x));
	} else {
		tmp = (z / t) * (x - 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 <= (-4.3d+167)) then
        tmp = z * ((y - x) / a)
    else if (z <= (-1.8d-127)) then
        tmp = y - (y * (z / t))
    else if (z <= 2d-244) then
        tmp = y * (-t / (a - t))
    else if (z <= 75000000.0d0) then
        tmp = x - ((t * y) / a)
    else if (z <= 8.5d+160) then
        tmp = z / (a / (y - x))
    else
        tmp = (z / t) * (x - 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 <= -4.3e+167) {
		tmp = z * ((y - x) / a);
	} else if (z <= -1.8e-127) {
		tmp = y - (y * (z / t));
	} else if (z <= 2e-244) {
		tmp = y * (-t / (a - t));
	} else if (z <= 75000000.0) {
		tmp = x - ((t * y) / a);
	} else if (z <= 8.5e+160) {
		tmp = z / (a / (y - x));
	} else {
		tmp = (z / t) * (x - y);
	}
	return tmp;
}
def code(x, y, z, t, a):
	tmp = 0
	if z <= -4.3e+167:
		tmp = z * ((y - x) / a)
	elif z <= -1.8e-127:
		tmp = y - (y * (z / t))
	elif z <= 2e-244:
		tmp = y * (-t / (a - t))
	elif z <= 75000000.0:
		tmp = x - ((t * y) / a)
	elif z <= 8.5e+160:
		tmp = z / (a / (y - x))
	else:
		tmp = (z / t) * (x - y)
	return tmp
function code(x, y, z, t, a)
	tmp = 0.0
	if (z <= -4.3e+167)
		tmp = Float64(z * Float64(Float64(y - x) / a));
	elseif (z <= -1.8e-127)
		tmp = Float64(y - Float64(y * Float64(z / t)));
	elseif (z <= 2e-244)
		tmp = Float64(y * Float64(Float64(-t) / Float64(a - t)));
	elseif (z <= 75000000.0)
		tmp = Float64(x - Float64(Float64(t * y) / a));
	elseif (z <= 8.5e+160)
		tmp = Float64(z / Float64(a / Float64(y - x)));
	else
		tmp = Float64(Float64(z / t) * Float64(x - y));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	tmp = 0.0;
	if (z <= -4.3e+167)
		tmp = z * ((y - x) / a);
	elseif (z <= -1.8e-127)
		tmp = y - (y * (z / t));
	elseif (z <= 2e-244)
		tmp = y * (-t / (a - t));
	elseif (z <= 75000000.0)
		tmp = x - ((t * y) / a);
	elseif (z <= 8.5e+160)
		tmp = z / (a / (y - x));
	else
		tmp = (z / t) * (x - y);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -4.3e+167], N[(z * N[(N[(y - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -1.8e-127], N[(y - N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2e-244], N[(y * N[((-t) / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 75000000.0], N[(x - N[(N[(t * y), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 8.5e+160], N[(z / N[(a / N[(y - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(z / t), $MachinePrecision] * N[(x - y), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -4.3 \cdot 10^{+167}:\\
\;\;\;\;z \cdot \frac{y - x}{a}\\

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

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

\mathbf{elif}\;z \leq 75000000:\\
\;\;\;\;x - \frac{t \cdot y}{a}\\

\mathbf{elif}\;z \leq 8.5 \cdot 10^{+160}:\\
\;\;\;\;\frac{z}{\frac{a}{y - x}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 6 regimes
  2. if z < -4.3000000000000002e167

    1. Initial program 78.2%

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

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

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

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

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

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

      \[\leadsto \color{blue}{z \cdot \left(\frac{y}{a} - \frac{x}{a}\right)} \]
    8. Step-by-step derivation
      1. div-sub77.2%

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

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

    if -4.3000000000000002e167 < z < -1.8e-127

    1. Initial program 66.1%

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

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

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

        \[\leadsto \color{blue}{\frac{z - t}{\frac{a - t}{y - x}}} + x \]
      4. associate-/r/77.6%

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

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

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

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

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

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

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

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

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

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

        \[\leadsto y - \color{blue}{y \cdot \frac{z}{t}} \]
    10. Simplified47.8%

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

    if -1.8e-127 < z < 1.9999999999999999e-244

    1. Initial program 69.2%

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

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

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

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

        \[\leadsto \color{blue}{y \cdot \frac{z - t}{a - t}} \]
    6. Simplified67.4%

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

      \[\leadsto y \cdot \color{blue}{\left(-1 \cdot \frac{t}{a - t}\right)} \]
    8. Step-by-step derivation
      1. neg-mul-163.7%

        \[\leadsto y \cdot \color{blue}{\left(-\frac{t}{a - t}\right)} \]
      2. distribute-neg-frac63.7%

        \[\leadsto y \cdot \color{blue}{\frac{-t}{a - t}} \]
    9. Simplified63.7%

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

    if 1.9999999999999999e-244 < z < 7.5e7

    1. Initial program 82.6%

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

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

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

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

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

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

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

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

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

        \[\leadsto x - \frac{\color{blue}{\left(y - x\right) \cdot t}}{a} \]
    9. Simplified56.0%

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

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

    if 7.5e7 < z < 8.49999999999999982e160

    1. Initial program 64.9%

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

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{z}{\frac{a - t}{y - x}}} \]
    6. Simplified57.4%

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

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

    if 8.49999999999999982e160 < z

    1. Initial program 83.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -4.3 \cdot 10^{+167}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \mathbf{elif}\;z \leq -1.8 \cdot 10^{-127}:\\ \;\;\;\;y - y \cdot \frac{z}{t}\\ \mathbf{elif}\;z \leq 2 \cdot 10^{-244}:\\ \;\;\;\;y \cdot \frac{-t}{a - t}\\ \mathbf{elif}\;z \leq 75000000:\\ \;\;\;\;x - \frac{t \cdot y}{a}\\ \mathbf{elif}\;z \leq 8.5 \cdot 10^{+160}:\\ \;\;\;\;\frac{z}{\frac{a}{y - x}}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{t} \cdot \left(x - y\right)\\ \end{array} \]

Alternative 10: 43.1% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -3.25 \cdot 10^{+165}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \mathbf{elif}\;z \leq -9.2 \cdot 10^{-137}:\\ \;\;\;\;y + \frac{x \cdot z}{t}\\ \mathbf{elif}\;z \leq 1.1 \cdot 10^{-240}:\\ \;\;\;\;y \cdot \frac{-t}{a - t}\\ \mathbf{elif}\;z \leq 92000000:\\ \;\;\;\;x - \frac{t \cdot y}{a}\\ \mathbf{elif}\;z \leq 1.3 \cdot 10^{+167}:\\ \;\;\;\;\frac{z}{\frac{a}{y - x}}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{t} \cdot \left(x - y\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= z -3.25e+165)
   (* z (/ (- y x) a))
   (if (<= z -9.2e-137)
     (+ y (/ (* x z) t))
     (if (<= z 1.1e-240)
       (* y (/ (- t) (- a t)))
       (if (<= z 92000000.0)
         (- x (/ (* t y) a))
         (if (<= z 1.3e+167) (/ z (/ a (- y x))) (* (/ z t) (- x y))))))))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (z <= -3.25e+165) {
		tmp = z * ((y - x) / a);
	} else if (z <= -9.2e-137) {
		tmp = y + ((x * z) / t);
	} else if (z <= 1.1e-240) {
		tmp = y * (-t / (a - t));
	} else if (z <= 92000000.0) {
		tmp = x - ((t * y) / a);
	} else if (z <= 1.3e+167) {
		tmp = z / (a / (y - x));
	} else {
		tmp = (z / t) * (x - 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 <= (-3.25d+165)) then
        tmp = z * ((y - x) / a)
    else if (z <= (-9.2d-137)) then
        tmp = y + ((x * z) / t)
    else if (z <= 1.1d-240) then
        tmp = y * (-t / (a - t))
    else if (z <= 92000000.0d0) then
        tmp = x - ((t * y) / a)
    else if (z <= 1.3d+167) then
        tmp = z / (a / (y - x))
    else
        tmp = (z / t) * (x - 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 <= -3.25e+165) {
		tmp = z * ((y - x) / a);
	} else if (z <= -9.2e-137) {
		tmp = y + ((x * z) / t);
	} else if (z <= 1.1e-240) {
		tmp = y * (-t / (a - t));
	} else if (z <= 92000000.0) {
		tmp = x - ((t * y) / a);
	} else if (z <= 1.3e+167) {
		tmp = z / (a / (y - x));
	} else {
		tmp = (z / t) * (x - y);
	}
	return tmp;
}
def code(x, y, z, t, a):
	tmp = 0
	if z <= -3.25e+165:
		tmp = z * ((y - x) / a)
	elif z <= -9.2e-137:
		tmp = y + ((x * z) / t)
	elif z <= 1.1e-240:
		tmp = y * (-t / (a - t))
	elif z <= 92000000.0:
		tmp = x - ((t * y) / a)
	elif z <= 1.3e+167:
		tmp = z / (a / (y - x))
	else:
		tmp = (z / t) * (x - y)
	return tmp
function code(x, y, z, t, a)
	tmp = 0.0
	if (z <= -3.25e+165)
		tmp = Float64(z * Float64(Float64(y - x) / a));
	elseif (z <= -9.2e-137)
		tmp = Float64(y + Float64(Float64(x * z) / t));
	elseif (z <= 1.1e-240)
		tmp = Float64(y * Float64(Float64(-t) / Float64(a - t)));
	elseif (z <= 92000000.0)
		tmp = Float64(x - Float64(Float64(t * y) / a));
	elseif (z <= 1.3e+167)
		tmp = Float64(z / Float64(a / Float64(y - x)));
	else
		tmp = Float64(Float64(z / t) * Float64(x - y));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	tmp = 0.0;
	if (z <= -3.25e+165)
		tmp = z * ((y - x) / a);
	elseif (z <= -9.2e-137)
		tmp = y + ((x * z) / t);
	elseif (z <= 1.1e-240)
		tmp = y * (-t / (a - t));
	elseif (z <= 92000000.0)
		tmp = x - ((t * y) / a);
	elseif (z <= 1.3e+167)
		tmp = z / (a / (y - x));
	else
		tmp = (z / t) * (x - y);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -3.25e+165], N[(z * N[(N[(y - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -9.2e-137], N[(y + N[(N[(x * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.1e-240], N[(y * N[((-t) / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 92000000.0], N[(x - N[(N[(t * y), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.3e+167], N[(z / N[(a / N[(y - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(z / t), $MachinePrecision] * N[(x - y), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.25 \cdot 10^{+165}:\\
\;\;\;\;z \cdot \frac{y - x}{a}\\

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

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

\mathbf{elif}\;z \leq 92000000:\\
\;\;\;\;x - \frac{t \cdot y}{a}\\

\mathbf{elif}\;z \leq 1.3 \cdot 10^{+167}:\\
\;\;\;\;\frac{z}{\frac{a}{y - x}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 6 regimes
  2. if z < -3.2499999999999999e165

    1. Initial program 75.7%

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

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

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

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

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

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

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

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

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

    if -3.2499999999999999e165 < z < -9.20000000000000032e-137

    1. Initial program 66.2%

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

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

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

        \[\leadsto \color{blue}{\frac{z - t}{\frac{a - t}{y - x}}} + x \]
      4. associate-/r/77.2%

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto y - \frac{\color{blue}{-z \cdot x}}{t} \]
      4. distribute-lft-neg-in49.9%

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

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

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

    if -9.20000000000000032e-137 < z < 1.1e-240

    1. Initial program 70.6%

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

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

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

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

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

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

      \[\leadsto y \cdot \color{blue}{\left(-1 \cdot \frac{t}{a - t}\right)} \]
    8. Step-by-step derivation
      1. neg-mul-164.6%

        \[\leadsto y \cdot \color{blue}{\left(-\frac{t}{a - t}\right)} \]
      2. distribute-neg-frac64.6%

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

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

    if 1.1e-240 < z < 9.2e7

    1. Initial program 82.6%

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

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

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

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

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

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

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

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

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

        \[\leadsto x - \frac{\color{blue}{\left(y - x\right) \cdot t}}{a} \]
    9. Simplified56.0%

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

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

    if 9.2e7 < z < 1.3000000000000001e167

    1. Initial program 64.9%

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

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{z}{\frac{a - t}{y - x}}} \]
    6. Simplified57.4%

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

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

    if 1.3000000000000001e167 < z

    1. Initial program 83.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3.25 \cdot 10^{+165}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \mathbf{elif}\;z \leq -9.2 \cdot 10^{-137}:\\ \;\;\;\;y + \frac{x \cdot z}{t}\\ \mathbf{elif}\;z \leq 1.1 \cdot 10^{-240}:\\ \;\;\;\;y \cdot \frac{-t}{a - t}\\ \mathbf{elif}\;z \leq 92000000:\\ \;\;\;\;x - \frac{t \cdot y}{a}\\ \mathbf{elif}\;z \leq 1.3 \cdot 10^{+167}:\\ \;\;\;\;\frac{z}{\frac{a}{y - x}}\\ \mathbf{else}:\\ \;\;\;\;\frac{z}{t} \cdot \left(x - y\right)\\ \end{array} \]

Alternative 11: 63.7% accurate, 0.8× speedup?

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

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

\mathbf{elif}\;t \leq 1.45 \cdot 10^{-173}:\\
\;\;\;\;t_1\\

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

\mathbf{elif}\;t \leq 1.25 \cdot 10^{+54}:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -8.4999999999999996e46 or 1.25000000000000001e54 < t

    1. Initial program 47.9%

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

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

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

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

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

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

    if -8.4999999999999996e46 < t < 1.4499999999999999e-173 or 1.4600000000000001e-29 < t < 1.25000000000000001e54

    1. Initial program 92.5%

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

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

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

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

    if 1.4499999999999999e-173 < t < 1.4600000000000001e-29

    1. Initial program 86.9%

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -8.5 \cdot 10^{+46}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;t \leq 1.45 \cdot 10^{-173}:\\ \;\;\;\;x - \frac{z \cdot \left(x - y\right)}{a}\\ \mathbf{elif}\;t \leq 1.46 \cdot 10^{-29}:\\ \;\;\;\;\left(y - x\right) \cdot \frac{z}{a - t}\\ \mathbf{elif}\;t \leq 1.25 \cdot 10^{+54}:\\ \;\;\;\;x - \frac{z \cdot \left(x - y\right)}{a}\\ \mathbf{else}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \end{array} \]

Alternative 12: 87.1% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -9 \cdot 10^{+122} \lor \neg \left(t \leq 2.4 \cdot 10^{+90}\right):\\
\;\;\;\;y + \frac{x - y}{\frac{t}{z - a}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -8.99999999999999995e122 or 2.4000000000000001e90 < t

    1. Initial program 39.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto y - \color{blue}{\frac{y - x}{\frac{t}{z - a}}} \]
    6. Simplified87.4%

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

    if -8.99999999999999995e122 < t < 2.4000000000000001e90

    1. Initial program 88.0%

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

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

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

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

Alternative 13: 37.2% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -7.5 \cdot 10^{+52}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq -4.9 \cdot 10^{-107}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq 1.9 \cdot 10^{-297}:\\ \;\;\;\;y \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq 9 \cdot 10^{-170}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq 3 \cdot 10^{-20}:\\ \;\;\;\;x \cdot \frac{z}{t}\\ \mathbf{elif}\;t \leq 1.3 \cdot 10^{+54}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= t -7.5e+52)
   y
   (if (<= t -4.9e-107)
     x
     (if (<= t 1.9e-297)
       (* y (/ z a))
       (if (<= t 9e-170)
         x
         (if (<= t 3e-20) (* x (/ z t)) (if (<= t 1.3e+54) x y)))))))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (t <= -7.5e+52) {
		tmp = y;
	} else if (t <= -4.9e-107) {
		tmp = x;
	} else if (t <= 1.9e-297) {
		tmp = y * (z / a);
	} else if (t <= 9e-170) {
		tmp = x;
	} else if (t <= 3e-20) {
		tmp = x * (z / t);
	} else if (t <= 1.3e+54) {
		tmp = x;
	} else {
		tmp = 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 (t <= (-7.5d+52)) then
        tmp = y
    else if (t <= (-4.9d-107)) then
        tmp = x
    else if (t <= 1.9d-297) then
        tmp = y * (z / a)
    else if (t <= 9d-170) then
        tmp = x
    else if (t <= 3d-20) then
        tmp = x * (z / t)
    else if (t <= 1.3d+54) then
        tmp = x
    else
        tmp = y
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (t <= -7.5e+52) {
		tmp = y;
	} else if (t <= -4.9e-107) {
		tmp = x;
	} else if (t <= 1.9e-297) {
		tmp = y * (z / a);
	} else if (t <= 9e-170) {
		tmp = x;
	} else if (t <= 3e-20) {
		tmp = x * (z / t);
	} else if (t <= 1.3e+54) {
		tmp = x;
	} else {
		tmp = y;
	}
	return tmp;
}
def code(x, y, z, t, a):
	tmp = 0
	if t <= -7.5e+52:
		tmp = y
	elif t <= -4.9e-107:
		tmp = x
	elif t <= 1.9e-297:
		tmp = y * (z / a)
	elif t <= 9e-170:
		tmp = x
	elif t <= 3e-20:
		tmp = x * (z / t)
	elif t <= 1.3e+54:
		tmp = x
	else:
		tmp = y
	return tmp
function code(x, y, z, t, a)
	tmp = 0.0
	if (t <= -7.5e+52)
		tmp = y;
	elseif (t <= -4.9e-107)
		tmp = x;
	elseif (t <= 1.9e-297)
		tmp = Float64(y * Float64(z / a));
	elseif (t <= 9e-170)
		tmp = x;
	elseif (t <= 3e-20)
		tmp = Float64(x * Float64(z / t));
	elseif (t <= 1.3e+54)
		tmp = x;
	else
		tmp = y;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	tmp = 0.0;
	if (t <= -7.5e+52)
		tmp = y;
	elseif (t <= -4.9e-107)
		tmp = x;
	elseif (t <= 1.9e-297)
		tmp = y * (z / a);
	elseif (t <= 9e-170)
		tmp = x;
	elseif (t <= 3e-20)
		tmp = x * (z / t);
	elseif (t <= 1.3e+54)
		tmp = x;
	else
		tmp = y;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -7.5e+52], y, If[LessEqual[t, -4.9e-107], x, If[LessEqual[t, 1.9e-297], N[(y * N[(z / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 9e-170], x, If[LessEqual[t, 3e-20], N[(x * N[(z / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.3e+54], x, y]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -7.5 \cdot 10^{+52}:\\
\;\;\;\;y\\

\mathbf{elif}\;t \leq -4.9 \cdot 10^{-107}:\\
\;\;\;\;x\\

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

\mathbf{elif}\;t \leq 9 \cdot 10^{-170}:\\
\;\;\;\;x\\

\mathbf{elif}\;t \leq 3 \cdot 10^{-20}:\\
\;\;\;\;x \cdot \frac{z}{t}\\

\mathbf{elif}\;t \leq 1.3 \cdot 10^{+54}:\\
\;\;\;\;x\\

\mathbf{else}:\\
\;\;\;\;y\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < -7.49999999999999995e52 or 1.30000000000000003e54 < t

    1. Initial program 47.3%

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

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

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

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

    if -7.49999999999999995e52 < t < -4.8999999999999998e-107 or 1.90000000000000002e-297 < t < 9.00000000000000003e-170 or 3.00000000000000029e-20 < t < 1.30000000000000003e54

    1. Initial program 90.6%

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

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

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

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

    if -4.8999999999999998e-107 < t < 1.90000000000000002e-297

    1. Initial program 93.9%

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

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

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

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

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

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

      \[\leadsto \color{blue}{y \cdot \left(\frac{z}{a} - \frac{t}{a}\right)} \]
    8. Step-by-step derivation
      1. div-sub44.2%

        \[\leadsto y \cdot \color{blue}{\frac{z - t}{a}} \]
    9. Simplified44.2%

      \[\leadsto \color{blue}{y \cdot \frac{z - t}{a}} \]
    10. Taylor expanded in z around inf 41.7%

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

    if 9.00000000000000003e-170 < t < 3.00000000000000029e-20

    1. Initial program 88.1%

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

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

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

        \[\leadsto \color{blue}{\frac{z - t}{\frac{a - t}{y - x}}} + x \]
      4. associate-/r/93.4%

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -7.5 \cdot 10^{+52}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq -4.9 \cdot 10^{-107}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq 1.9 \cdot 10^{-297}:\\ \;\;\;\;y \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq 9 \cdot 10^{-170}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq 3 \cdot 10^{-20}:\\ \;\;\;\;x \cdot \frac{z}{t}\\ \mathbf{elif}\;t \leq 1.3 \cdot 10^{+54}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]

Alternative 14: 42.3% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := z \cdot \frac{y - x}{a}\\ \mathbf{if}\;z \leq -4.6 \cdot 10^{+167}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -1.12 \cdot 10^{-128}:\\ \;\;\;\;y - y \cdot \frac{z}{t}\\ \mathbf{elif}\;z \leq 3.2 \cdot 10^{-236}:\\ \;\;\;\;y \cdot \frac{-t}{a - t}\\ \mathbf{elif}\;z \leq 30000000:\\ \;\;\;\;x - \frac{t \cdot y}{a}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (* z (/ (- y x) a))))
   (if (<= z -4.6e+167)
     t_1
     (if (<= z -1.12e-128)
       (- y (* y (/ z t)))
       (if (<= z 3.2e-236)
         (* y (/ (- t) (- a t)))
         (if (<= z 30000000.0) (- x (/ (* t y) a)) t_1))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = z * ((y - x) / a);
	double tmp;
	if (z <= -4.6e+167) {
		tmp = t_1;
	} else if (z <= -1.12e-128) {
		tmp = y - (y * (z / t));
	} else if (z <= 3.2e-236) {
		tmp = y * (-t / (a - t));
	} else if (z <= 30000000.0) {
		tmp = x - ((t * y) / a);
	} 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 = z * ((y - x) / a)
    if (z <= (-4.6d+167)) then
        tmp = t_1
    else if (z <= (-1.12d-128)) then
        tmp = y - (y * (z / t))
    else if (z <= 3.2d-236) then
        tmp = y * (-t / (a - t))
    else if (z <= 30000000.0d0) then
        tmp = x - ((t * y) / a)
    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 = z * ((y - x) / a);
	double tmp;
	if (z <= -4.6e+167) {
		tmp = t_1;
	} else if (z <= -1.12e-128) {
		tmp = y - (y * (z / t));
	} else if (z <= 3.2e-236) {
		tmp = y * (-t / (a - t));
	} else if (z <= 30000000.0) {
		tmp = x - ((t * y) / a);
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = z * ((y - x) / a)
	tmp = 0
	if z <= -4.6e+167:
		tmp = t_1
	elif z <= -1.12e-128:
		tmp = y - (y * (z / t))
	elif z <= 3.2e-236:
		tmp = y * (-t / (a - t))
	elif z <= 30000000.0:
		tmp = x - ((t * y) / a)
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(z * Float64(Float64(y - x) / a))
	tmp = 0.0
	if (z <= -4.6e+167)
		tmp = t_1;
	elseif (z <= -1.12e-128)
		tmp = Float64(y - Float64(y * Float64(z / t)));
	elseif (z <= 3.2e-236)
		tmp = Float64(y * Float64(Float64(-t) / Float64(a - t)));
	elseif (z <= 30000000.0)
		tmp = Float64(x - Float64(Float64(t * y) / a));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = z * ((y - x) / a);
	tmp = 0.0;
	if (z <= -4.6e+167)
		tmp = t_1;
	elseif (z <= -1.12e-128)
		tmp = y - (y * (z / t));
	elseif (z <= 3.2e-236)
		tmp = y * (-t / (a - t));
	elseif (z <= 30000000.0)
		tmp = x - ((t * y) / a);
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(z * N[(N[(y - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -4.6e+167], t$95$1, If[LessEqual[z, -1.12e-128], N[(y - N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 3.2e-236], N[(y * N[((-t) / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 30000000.0], N[(x - N[(N[(t * y), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}

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

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

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

\mathbf{elif}\;z \leq 30000000:\\
\;\;\;\;x - \frac{t \cdot y}{a}\\

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


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

    1. Initial program 76.4%

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

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

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

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

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

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

      \[\leadsto \color{blue}{z \cdot \left(\frac{y}{a} - \frac{x}{a}\right)} \]
    8. Step-by-step derivation
      1. div-sub57.0%

        \[\leadsto z \cdot \color{blue}{\frac{y - x}{a}} \]
    9. Simplified57.0%

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

    if -4.59999999999999976e167 < z < -1.12e-128

    1. Initial program 66.1%

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

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

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

        \[\leadsto \color{blue}{\frac{z - t}{\frac{a - t}{y - x}}} + x \]
      4. associate-/r/77.6%

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

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

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

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

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

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

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

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

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

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

        \[\leadsto y - \color{blue}{y \cdot \frac{z}{t}} \]
    10. Simplified47.8%

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

    if -1.12e-128 < z < 3.2e-236

    1. Initial program 69.2%

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

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

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

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

        \[\leadsto \color{blue}{y \cdot \frac{z - t}{a - t}} \]
    6. Simplified67.4%

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

      \[\leadsto y \cdot \color{blue}{\left(-1 \cdot \frac{t}{a - t}\right)} \]
    8. Step-by-step derivation
      1. neg-mul-163.7%

        \[\leadsto y \cdot \color{blue}{\left(-\frac{t}{a - t}\right)} \]
      2. distribute-neg-frac63.7%

        \[\leadsto y \cdot \color{blue}{\frac{-t}{a - t}} \]
    9. Simplified63.7%

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

    if 3.2e-236 < z < 3e7

    1. Initial program 82.6%

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

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

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

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

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

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

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

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

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

        \[\leadsto x - \frac{\color{blue}{\left(y - x\right) \cdot t}}{a} \]
    9. Simplified56.0%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -4.6 \cdot 10^{+167}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \mathbf{elif}\;z \leq -1.12 \cdot 10^{-128}:\\ \;\;\;\;y - y \cdot \frac{z}{t}\\ \mathbf{elif}\;z \leq 3.2 \cdot 10^{-236}:\\ \;\;\;\;y \cdot \frac{-t}{a - t}\\ \mathbf{elif}\;z \leq 30000000:\\ \;\;\;\;x - \frac{t \cdot y}{a}\\ \mathbf{else}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \end{array} \]

Alternative 15: 56.7% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := y \cdot \frac{z - t}{a - t}\\ \mathbf{if}\;y \leq -3.3 \cdot 10^{-155}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;y \leq -2 \cdot 10^{-233}:\\ \;\;\;\;x + \frac{t \cdot x}{a}\\ \mathbf{elif}\;y \leq 3.4 \cdot 10^{-148}:\\ \;\;\;\;\frac{-x}{\frac{a - t}{z}}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (* y (/ (- z t) (- a t)))))
   (if (<= y -3.3e-155)
     t_1
     (if (<= y -2e-233)
       (+ x (/ (* t x) a))
       (if (<= y 3.4e-148) (/ (- x) (/ (- a t) z)) t_1)))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = y * ((z - t) / (a - t));
	double tmp;
	if (y <= -3.3e-155) {
		tmp = t_1;
	} else if (y <= -2e-233) {
		tmp = x + ((t * x) / a);
	} else if (y <= 3.4e-148) {
		tmp = -x / ((a - t) / 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 = y * ((z - t) / (a - t))
    if (y <= (-3.3d-155)) then
        tmp = t_1
    else if (y <= (-2d-233)) then
        tmp = x + ((t * x) / a)
    else if (y <= 3.4d-148) then
        tmp = -x / ((a - t) / 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 = y * ((z - t) / (a - t));
	double tmp;
	if (y <= -3.3e-155) {
		tmp = t_1;
	} else if (y <= -2e-233) {
		tmp = x + ((t * x) / a);
	} else if (y <= 3.4e-148) {
		tmp = -x / ((a - t) / z);
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = y * ((z - t) / (a - t))
	tmp = 0
	if y <= -3.3e-155:
		tmp = t_1
	elif y <= -2e-233:
		tmp = x + ((t * x) / a)
	elif y <= 3.4e-148:
		tmp = -x / ((a - t) / z)
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(y * Float64(Float64(z - t) / Float64(a - t)))
	tmp = 0.0
	if (y <= -3.3e-155)
		tmp = t_1;
	elseif (y <= -2e-233)
		tmp = Float64(x + Float64(Float64(t * x) / a));
	elseif (y <= 3.4e-148)
		tmp = Float64(Float64(-x) / Float64(Float64(a - t) / z));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = y * ((z - t) / (a - t));
	tmp = 0.0;
	if (y <= -3.3e-155)
		tmp = t_1;
	elseif (y <= -2e-233)
		tmp = x + ((t * x) / a);
	elseif (y <= 3.4e-148)
		tmp = -x / ((a - t) / z);
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -3.3e-155], t$95$1, If[LessEqual[y, -2e-233], N[(x + N[(N[(t * x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3.4e-148], N[((-x) / N[(N[(a - t), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := y \cdot \frac{z - t}{a - t}\\
\mathbf{if}\;y \leq -3.3 \cdot 10^{-155}:\\
\;\;\;\;t_1\\

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -3.29999999999999986e-155 or 3.4000000000000002e-148 < y

    1. Initial program 73.1%

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

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

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

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

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

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

    if -3.29999999999999986e-155 < y < -1.99999999999999992e-233

    1. Initial program 84.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto x - \frac{\color{blue}{\left(-1 \cdot t\right) \cdot x}}{a} \]
      3. neg-mul-167.2%

        \[\leadsto x - \frac{\color{blue}{\left(-t\right)} \cdot x}{a} \]
    12. Simplified67.2%

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

    if -1.99999999999999992e-233 < y < 3.4000000000000002e-148

    1. Initial program 71.2%

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

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

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

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

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

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

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

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

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

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

        \[\leadsto -\color{blue}{\frac{x}{\frac{a - t}{z}}} \]
      3. distribute-neg-frac49.0%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -3.3 \cdot 10^{-155}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;y \leq -2 \cdot 10^{-233}:\\ \;\;\;\;x + \frac{t \cdot x}{a}\\ \mathbf{elif}\;y \leq 3.4 \cdot 10^{-148}:\\ \;\;\;\;\frac{-x}{\frac{a - t}{z}}\\ \mathbf{else}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \end{array} \]

Alternative 16: 56.7% accurate, 0.9× speedup?

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

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

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

\mathbf{elif}\;z \leq 7200000:\\
\;\;\;\;x - \frac{t \cdot y}{a}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -5.8999999999999999e196 or 7.2e6 < z

    1. Initial program 76.6%

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

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

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

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

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

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

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

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

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

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

    if -5.8999999999999999e196 < z < 1.75000000000000008e-245

    1. Initial program 67.6%

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

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

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

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

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

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

    if 1.75000000000000008e-245 < z < 7.2e6

    1. Initial program 82.6%

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

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

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

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

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

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

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

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

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

        \[\leadsto x - \frac{\color{blue}{\left(y - x\right) \cdot t}}{a} \]
    9. Simplified56.0%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -5.9 \cdot 10^{+196}:\\ \;\;\;\;\left(y - x\right) \cdot \frac{z}{a - t}\\ \mathbf{elif}\;z \leq 1.75 \cdot 10^{-245}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;z \leq 7200000:\\ \;\;\;\;x - \frac{t \cdot y}{a}\\ \mathbf{else}:\\ \;\;\;\;\left(y - x\right) \cdot \frac{z}{a - t}\\ \end{array} \]

Alternative 17: 34.9% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -2.1 \cdot 10^{-26}:\\ \;\;\;\;y \cdot \frac{z}{a - t}\\ \mathbf{elif}\;z \leq 1.56 \cdot 10^{-214}:\\ \;\;\;\;y\\ \mathbf{elif}\;z \leq 9.5 \cdot 10^{+38}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;x \cdot \frac{z - a}{t}\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= z -2.1e-26)
   (* y (/ z (- a t)))
   (if (<= z 1.56e-214) y (if (<= z 9.5e+38) x (* x (/ (- z a) t))))))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (z <= -2.1e-26) {
		tmp = y * (z / (a - t));
	} else if (z <= 1.56e-214) {
		tmp = y;
	} else if (z <= 9.5e+38) {
		tmp = x;
	} else {
		tmp = x * ((z - a) / 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.1d-26)) then
        tmp = y * (z / (a - t))
    else if (z <= 1.56d-214) then
        tmp = y
    else if (z <= 9.5d+38) then
        tmp = x
    else
        tmp = x * ((z - a) / 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.1e-26) {
		tmp = y * (z / (a - t));
	} else if (z <= 1.56e-214) {
		tmp = y;
	} else if (z <= 9.5e+38) {
		tmp = x;
	} else {
		tmp = x * ((z - a) / t);
	}
	return tmp;
}
def code(x, y, z, t, a):
	tmp = 0
	if z <= -2.1e-26:
		tmp = y * (z / (a - t))
	elif z <= 1.56e-214:
		tmp = y
	elif z <= 9.5e+38:
		tmp = x
	else:
		tmp = x * ((z - a) / t)
	return tmp
function code(x, y, z, t, a)
	tmp = 0.0
	if (z <= -2.1e-26)
		tmp = Float64(y * Float64(z / Float64(a - t)));
	elseif (z <= 1.56e-214)
		tmp = y;
	elseif (z <= 9.5e+38)
		tmp = x;
	else
		tmp = Float64(x * Float64(Float64(z - a) / t));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	tmp = 0.0;
	if (z <= -2.1e-26)
		tmp = y * (z / (a - t));
	elseif (z <= 1.56e-214)
		tmp = y;
	elseif (z <= 9.5e+38)
		tmp = x;
	else
		tmp = x * ((z - a) / t);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -2.1e-26], N[(y * N[(z / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.56e-214], y, If[LessEqual[z, 9.5e+38], x, N[(x * N[(N[(z - a), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}

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

\mathbf{elif}\;z \leq 1.56 \cdot 10^{-214}:\\
\;\;\;\;y\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -2.10000000000000008e-26

    1. Initial program 76.1%

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

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

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

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

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

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

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

    if -2.10000000000000008e-26 < z < 1.56e-214

    1. Initial program 65.2%

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

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

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

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

    if 1.56e-214 < z < 9.4999999999999995e38

    1. Initial program 80.3%

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

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

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

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

    if 9.4999999999999995e38 < z

    1. Initial program 76.2%

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

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

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

        \[\leadsto \color{blue}{\frac{z - t}{\frac{a - t}{y - x}}} + x \]
      4. associate-/r/87.4%

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.1 \cdot 10^{-26}:\\ \;\;\;\;y \cdot \frac{z}{a - t}\\ \mathbf{elif}\;z \leq 1.56 \cdot 10^{-214}:\\ \;\;\;\;y\\ \mathbf{elif}\;z \leq 9.5 \cdot 10^{+38}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;x \cdot \frac{z - a}{t}\\ \end{array} \]

Alternative 18: 38.9% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := z \cdot \frac{y - x}{a}\\ \mathbf{if}\;z \leq -9.5 \cdot 10^{-27}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 1.02 \cdot 10^{-216}:\\ \;\;\;\;y\\ \mathbf{elif}\;z \leq 50000000:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (* z (/ (- y x) a))))
   (if (<= z -9.5e-27)
     t_1
     (if (<= z 1.02e-216) y (if (<= z 50000000.0) x t_1)))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = z * ((y - x) / a);
	double tmp;
	if (z <= -9.5e-27) {
		tmp = t_1;
	} else if (z <= 1.02e-216) {
		tmp = y;
	} else if (z <= 50000000.0) {
		tmp = 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 = z * ((y - x) / a)
    if (z <= (-9.5d-27)) then
        tmp = t_1
    else if (z <= 1.02d-216) then
        tmp = y
    else if (z <= 50000000.0d0) then
        tmp = 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 = z * ((y - x) / a);
	double tmp;
	if (z <= -9.5e-27) {
		tmp = t_1;
	} else if (z <= 1.02e-216) {
		tmp = y;
	} else if (z <= 50000000.0) {
		tmp = x;
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = z * ((y - x) / a)
	tmp = 0
	if z <= -9.5e-27:
		tmp = t_1
	elif z <= 1.02e-216:
		tmp = y
	elif z <= 50000000.0:
		tmp = x
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(z * Float64(Float64(y - x) / a))
	tmp = 0.0
	if (z <= -9.5e-27)
		tmp = t_1;
	elseif (z <= 1.02e-216)
		tmp = y;
	elseif (z <= 50000000.0)
		tmp = x;
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = z * ((y - x) / a);
	tmp = 0.0;
	if (z <= -9.5e-27)
		tmp = t_1;
	elseif (z <= 1.02e-216)
		tmp = y;
	elseif (z <= 50000000.0)
		tmp = x;
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(z * N[(N[(y - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -9.5e-27], t$95$1, If[LessEqual[z, 1.02e-216], y, If[LessEqual[z, 50000000.0], x, t$95$1]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := z \cdot \frac{y - x}{a}\\
\mathbf{if}\;z \leq -9.5 \cdot 10^{-27}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq 1.02 \cdot 10^{-216}:\\
\;\;\;\;y\\

\mathbf{elif}\;z \leq 50000000:\\
\;\;\;\;x\\

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


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

    1. Initial program 75.8%

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

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

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

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

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

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

      \[\leadsto \color{blue}{z \cdot \left(\frac{y}{a} - \frac{x}{a}\right)} \]
    8. Step-by-step derivation
      1. div-sub49.0%

        \[\leadsto z \cdot \color{blue}{\frac{y - x}{a}} \]
    9. Simplified49.0%

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

    if -9.50000000000000037e-27 < z < 1.0199999999999999e-216

    1. Initial program 65.2%

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

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

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

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

    if 1.0199999999999999e-216 < z < 5e7

    1. Initial program 81.8%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -9.5 \cdot 10^{-27}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \mathbf{elif}\;z \leq 1.02 \cdot 10^{-216}:\\ \;\;\;\;y\\ \mathbf{elif}\;z \leq 50000000:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \end{array} \]

Alternative 19: 68.3% accurate, 1.0× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.2 \cdot 10^{+43} \lor \neg \left(t \leq 8.2 \cdot 10^{+53}\right):\\
\;\;\;\;y \cdot \frac{z - t}{a - t}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -4.20000000000000003e43 or 8.20000000000000037e53 < t

    1. Initial program 47.9%

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

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

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

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

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

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

    if -4.20000000000000003e43 < t < 8.20000000000000037e53

    1. Initial program 91.3%

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

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

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

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

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

Alternative 20: 71.2% accurate, 1.0× speedup?

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -2.80000000000000005e51 or 5e52 < t

    1. Initial program 48.3%

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

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

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

        \[\leadsto \color{blue}{\frac{z - t}{\frac{a - t}{y - x}}} + x \]
      4. associate-/r/66.1%

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

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

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

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

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

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

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

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

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

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

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

    if -2.80000000000000005e51 < t < 5e52

    1. Initial program 90.8%

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

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

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

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

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

Alternative 21: 37.3% accurate, 1.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -7.4 \cdot 10^{+52}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 9 \cdot 10^{-170}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq 2.9 \cdot 10^{-20}:\\ \;\;\;\;x \cdot \frac{z}{t}\\ \mathbf{elif}\;t \leq 1.95 \cdot 10^{+55}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= t -7.4e+52)
   y
   (if (<= t 9e-170)
     x
     (if (<= t 2.9e-20) (* x (/ z t)) (if (<= t 1.95e+55) x y)))))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (t <= -7.4e+52) {
		tmp = y;
	} else if (t <= 9e-170) {
		tmp = x;
	} else if (t <= 2.9e-20) {
		tmp = x * (z / t);
	} else if (t <= 1.95e+55) {
		tmp = x;
	} else {
		tmp = 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 (t <= (-7.4d+52)) then
        tmp = y
    else if (t <= 9d-170) then
        tmp = x
    else if (t <= 2.9d-20) then
        tmp = x * (z / t)
    else if (t <= 1.95d+55) then
        tmp = x
    else
        tmp = y
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (t <= -7.4e+52) {
		tmp = y;
	} else if (t <= 9e-170) {
		tmp = x;
	} else if (t <= 2.9e-20) {
		tmp = x * (z / t);
	} else if (t <= 1.95e+55) {
		tmp = x;
	} else {
		tmp = y;
	}
	return tmp;
}
def code(x, y, z, t, a):
	tmp = 0
	if t <= -7.4e+52:
		tmp = y
	elif t <= 9e-170:
		tmp = x
	elif t <= 2.9e-20:
		tmp = x * (z / t)
	elif t <= 1.95e+55:
		tmp = x
	else:
		tmp = y
	return tmp
function code(x, y, z, t, a)
	tmp = 0.0
	if (t <= -7.4e+52)
		tmp = y;
	elseif (t <= 9e-170)
		tmp = x;
	elseif (t <= 2.9e-20)
		tmp = Float64(x * Float64(z / t));
	elseif (t <= 1.95e+55)
		tmp = x;
	else
		tmp = y;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	tmp = 0.0;
	if (t <= -7.4e+52)
		tmp = y;
	elseif (t <= 9e-170)
		tmp = x;
	elseif (t <= 2.9e-20)
		tmp = x * (z / t);
	elseif (t <= 1.95e+55)
		tmp = x;
	else
		tmp = y;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -7.4e+52], y, If[LessEqual[t, 9e-170], x, If[LessEqual[t, 2.9e-20], N[(x * N[(z / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.95e+55], x, y]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -7.4 \cdot 10^{+52}:\\
\;\;\;\;y\\

\mathbf{elif}\;t \leq 9 \cdot 10^{-170}:\\
\;\;\;\;x\\

\mathbf{elif}\;t \leq 2.9 \cdot 10^{-20}:\\
\;\;\;\;x \cdot \frac{z}{t}\\

\mathbf{elif}\;t \leq 1.95 \cdot 10^{+55}:\\
\;\;\;\;x\\

\mathbf{else}:\\
\;\;\;\;y\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -7.3999999999999999e52 or 1.95000000000000014e55 < t

    1. Initial program 47.3%

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

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

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

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

    if -7.3999999999999999e52 < t < 9.00000000000000003e-170 or 2.9e-20 < t < 1.95000000000000014e55

    1. Initial program 91.7%

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

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

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

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

    if 9.00000000000000003e-170 < t < 2.9e-20

    1. Initial program 88.1%

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

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

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

        \[\leadsto \color{blue}{\frac{z - t}{\frac{a - t}{y - x}}} + x \]
      4. associate-/r/93.4%

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -7.4 \cdot 10^{+52}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 9 \cdot 10^{-170}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq 2.9 \cdot 10^{-20}:\\ \;\;\;\;x \cdot \frac{z}{t}\\ \mathbf{elif}\;t \leq 1.95 \cdot 10^{+55}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]

Alternative 22: 38.5% accurate, 2.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -5.5 \cdot 10^{+51}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 2.5 \cdot 10^{+56}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= t -5.5e+51) y (if (<= t 2.5e+56) x y)))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (t <= -5.5e+51) {
		tmp = y;
	} else if (t <= 2.5e+56) {
		tmp = x;
	} else {
		tmp = 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 (t <= (-5.5d+51)) then
        tmp = y
    else if (t <= 2.5d+56) then
        tmp = x
    else
        tmp = y
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (t <= -5.5e+51) {
		tmp = y;
	} else if (t <= 2.5e+56) {
		tmp = x;
	} else {
		tmp = y;
	}
	return tmp;
}
def code(x, y, z, t, a):
	tmp = 0
	if t <= -5.5e+51:
		tmp = y
	elif t <= 2.5e+56:
		tmp = x
	else:
		tmp = y
	return tmp
function code(x, y, z, t, a)
	tmp = 0.0
	if (t <= -5.5e+51)
		tmp = y;
	elseif (t <= 2.5e+56)
		tmp = x;
	else
		tmp = y;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	tmp = 0.0;
	if (t <= -5.5e+51)
		tmp = y;
	elseif (t <= 2.5e+56)
		tmp = x;
	else
		tmp = y;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -5.5e+51], y, If[LessEqual[t, 2.5e+56], x, y]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -5.5 \cdot 10^{+51}:\\
\;\;\;\;y\\

\mathbf{elif}\;t \leq 2.5 \cdot 10^{+56}:\\
\;\;\;\;x\\

\mathbf{else}:\\
\;\;\;\;y\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -5.5e51 or 2.50000000000000012e56 < t

    1. Initial program 47.3%

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

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

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

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

    if -5.5e51 < t < 2.50000000000000012e56

    1. Initial program 90.9%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -5.5 \cdot 10^{+51}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 2.5 \cdot 10^{+56}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]

Alternative 23: 24.7% accurate, 13.0× speedup?

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

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

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

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

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

    \[\leadsto \color{blue}{x} \]
  5. Final simplification24.4%

    \[\leadsto x \]

Developer target: 87.1% accurate, 0.7× speedup?

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

\\
\begin{array}{l}
t_1 := x + \frac{y - x}{1} \cdot \frac{z - t}{a - t}\\
\mathbf{if}\;a < -1.6153062845442575 \cdot 10^{-142}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;a < 3.774403170083174 \cdot 10^{-182}:\\
\;\;\;\;y - \frac{z}{t} \cdot \left(y - x\right)\\

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


\end{array}
\end{array}

Reproduce

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

  :herbie-target
  (if (< a -1.6153062845442575e-142) (+ x (* (/ (- y x) 1.0) (/ (- z t) (- a t)))) (if (< a 3.774403170083174e-182) (- y (* (/ z t) (- y x))) (+ x (* (/ (- y x) 1.0) (/ (- z t) (- a t))))))

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