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

Percentage Accurate: 68.3% → 90.9%
Time: 18.6s
Alternatives: 21
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 21 alternatives:

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

Initial Program: 68.3% accurate, 1.0× speedup?

\[\begin{array}{l} \\ x + \frac{\left(y - 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: 90.9% accurate, 0.3× speedup?

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < -9.99999999999999963e-272 or 0.0 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t)))

    1. Initial program 68.5%

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

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

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

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

    1. Initial program 3.8%

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

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

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

      \[\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+99.8%

        \[\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/99.8%

        \[\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/99.8%

        \[\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-sub99.8%

        \[\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--99.8%

        \[\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/99.8%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 2: 60.8% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := y \cdot \frac{z - t}{a - t}\\ t_2 := x + \frac{y}{\frac{a}{z}}\\ t_3 := \left(y - x\right) \cdot \frac{z}{a - t}\\ \mathbf{if}\;a \leq -3.3 \cdot 10^{+103}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;a \leq -1.45 \cdot 10^{+78}:\\ \;\;\;\;y - a \cdot \frac{x}{t}\\ \mathbf{elif}\;a \leq -1.3 \cdot 10^{+46}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;a \leq -1 \cdot 10^{-24}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq -2.65 \cdot 10^{-133}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;a \leq -4.2 \cdot 10^{-171}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq 1.65 \cdot 10^{-296}:\\ \;\;\;\;y - \frac{x}{\frac{-t}{z}}\\ \mathbf{elif}\;a \leq 2.35 \cdot 10^{-116}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq 2.3 \cdot 10^{+112}:\\ \;\;\;\;t_3\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (* y (/ (- z t) (- a t))))
        (t_2 (+ x (/ y (/ a z))))
        (t_3 (* (- y x) (/ z (- a t)))))
   (if (<= a -3.3e+103)
     t_2
     (if (<= a -1.45e+78)
       (- y (* a (/ x t)))
       (if (<= a -1.3e+46)
         t_3
         (if (<= a -1e-24)
           t_1
           (if (<= a -2.65e-133)
             t_3
             (if (<= a -4.2e-171)
               t_1
               (if (<= a 1.65e-296)
                 (- y (/ x (/ (- t) z)))
                 (if (<= a 2.35e-116)
                   t_1
                   (if (<= a 2.3e+112) t_3 t_2)))))))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = y * ((z - t) / (a - t));
	double t_2 = x + (y / (a / z));
	double t_3 = (y - x) * (z / (a - t));
	double tmp;
	if (a <= -3.3e+103) {
		tmp = t_2;
	} else if (a <= -1.45e+78) {
		tmp = y - (a * (x / t));
	} else if (a <= -1.3e+46) {
		tmp = t_3;
	} else if (a <= -1e-24) {
		tmp = t_1;
	} else if (a <= -2.65e-133) {
		tmp = t_3;
	} else if (a <= -4.2e-171) {
		tmp = t_1;
	} else if (a <= 1.65e-296) {
		tmp = y - (x / (-t / z));
	} else if (a <= 2.35e-116) {
		tmp = t_1;
	} else if (a <= 2.3e+112) {
		tmp = t_3;
	} 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) :: t_3
    real(8) :: tmp
    t_1 = y * ((z - t) / (a - t))
    t_2 = x + (y / (a / z))
    t_3 = (y - x) * (z / (a - t))
    if (a <= (-3.3d+103)) then
        tmp = t_2
    else if (a <= (-1.45d+78)) then
        tmp = y - (a * (x / t))
    else if (a <= (-1.3d+46)) then
        tmp = t_3
    else if (a <= (-1d-24)) then
        tmp = t_1
    else if (a <= (-2.65d-133)) then
        tmp = t_3
    else if (a <= (-4.2d-171)) then
        tmp = t_1
    else if (a <= 1.65d-296) then
        tmp = y - (x / (-t / z))
    else if (a <= 2.35d-116) then
        tmp = t_1
    else if (a <= 2.3d+112) then
        tmp = t_3
    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 * ((z - t) / (a - t));
	double t_2 = x + (y / (a / z));
	double t_3 = (y - x) * (z / (a - t));
	double tmp;
	if (a <= -3.3e+103) {
		tmp = t_2;
	} else if (a <= -1.45e+78) {
		tmp = y - (a * (x / t));
	} else if (a <= -1.3e+46) {
		tmp = t_3;
	} else if (a <= -1e-24) {
		tmp = t_1;
	} else if (a <= -2.65e-133) {
		tmp = t_3;
	} else if (a <= -4.2e-171) {
		tmp = t_1;
	} else if (a <= 1.65e-296) {
		tmp = y - (x / (-t / z));
	} else if (a <= 2.35e-116) {
		tmp = t_1;
	} else if (a <= 2.3e+112) {
		tmp = t_3;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = y * ((z - t) / (a - t))
	t_2 = x + (y / (a / z))
	t_3 = (y - x) * (z / (a - t))
	tmp = 0
	if a <= -3.3e+103:
		tmp = t_2
	elif a <= -1.45e+78:
		tmp = y - (a * (x / t))
	elif a <= -1.3e+46:
		tmp = t_3
	elif a <= -1e-24:
		tmp = t_1
	elif a <= -2.65e-133:
		tmp = t_3
	elif a <= -4.2e-171:
		tmp = t_1
	elif a <= 1.65e-296:
		tmp = y - (x / (-t / z))
	elif a <= 2.35e-116:
		tmp = t_1
	elif a <= 2.3e+112:
		tmp = t_3
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(y * Float64(Float64(z - t) / Float64(a - t)))
	t_2 = Float64(x + Float64(y / Float64(a / z)))
	t_3 = Float64(Float64(y - x) * Float64(z / Float64(a - t)))
	tmp = 0.0
	if (a <= -3.3e+103)
		tmp = t_2;
	elseif (a <= -1.45e+78)
		tmp = Float64(y - Float64(a * Float64(x / t)));
	elseif (a <= -1.3e+46)
		tmp = t_3;
	elseif (a <= -1e-24)
		tmp = t_1;
	elseif (a <= -2.65e-133)
		tmp = t_3;
	elseif (a <= -4.2e-171)
		tmp = t_1;
	elseif (a <= 1.65e-296)
		tmp = Float64(y - Float64(x / Float64(Float64(-t) / z)));
	elseif (a <= 2.35e-116)
		tmp = t_1;
	elseif (a <= 2.3e+112)
		tmp = t_3;
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = y * ((z - t) / (a - t));
	t_2 = x + (y / (a / z));
	t_3 = (y - x) * (z / (a - t));
	tmp = 0.0;
	if (a <= -3.3e+103)
		tmp = t_2;
	elseif (a <= -1.45e+78)
		tmp = y - (a * (x / t));
	elseif (a <= -1.3e+46)
		tmp = t_3;
	elseif (a <= -1e-24)
		tmp = t_1;
	elseif (a <= -2.65e-133)
		tmp = t_3;
	elseif (a <= -4.2e-171)
		tmp = t_1;
	elseif (a <= 1.65e-296)
		tmp = y - (x / (-t / z));
	elseif (a <= 2.35e-116)
		tmp = t_1;
	elseif (a <= 2.3e+112)
		tmp = t_3;
	else
		tmp = t_2;
	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]}, Block[{t$95$2 = N[(x + N[(y / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(y - x), $MachinePrecision] * N[(z / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -3.3e+103], t$95$2, If[LessEqual[a, -1.45e+78], N[(y - N[(a * N[(x / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, -1.3e+46], t$95$3, If[LessEqual[a, -1e-24], t$95$1, If[LessEqual[a, -2.65e-133], t$95$3, If[LessEqual[a, -4.2e-171], t$95$1, If[LessEqual[a, 1.65e-296], N[(y - N[(x / N[((-t) / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 2.35e-116], t$95$1, If[LessEqual[a, 2.3e+112], t$95$3, t$95$2]]]]]]]]]]]]
\begin{array}{l}

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

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

\mathbf{elif}\;a \leq -1.3 \cdot 10^{+46}:\\
\;\;\;\;t_3\\

\mathbf{elif}\;a \leq -1 \cdot 10^{-24}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;a \leq -2.65 \cdot 10^{-133}:\\
\;\;\;\;t_3\\

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

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

\mathbf{elif}\;a \leq 2.35 \cdot 10^{-116}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;a \leq 2.3 \cdot 10^{+112}:\\
\;\;\;\;t_3\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if a < -3.30000000000000009e103 or 2.3e112 < a

    1. Initial program 70.2%

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

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

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

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

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

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

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

    if -3.30000000000000009e103 < a < -1.45000000000000008e78

    1. Initial program 17.7%

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

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

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

      \[\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+30.0%

        \[\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/30.0%

        \[\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/30.0%

        \[\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-sub30.0%

        \[\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--30.0%

        \[\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/30.0%

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

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

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

        \[\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}}} \]
    7. Taylor expanded in y around 0 64.1%

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

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

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

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

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

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

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

        \[\leadsto y - \color{blue}{a \cdot \frac{x}{t}} \]
    12. Simplified63.5%

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

    if -1.45000000000000008e78 < a < -1.30000000000000007e46 or -9.99999999999999924e-25 < a < -2.64999999999999992e-133 or 2.34999999999999997e-116 < a < 2.3e112

    1. Initial program 63.4%

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

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

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

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

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

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

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

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

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

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

    if -1.30000000000000007e46 < a < -9.99999999999999924e-25 or -2.64999999999999992e-133 < a < -4.2e-171 or 1.65e-296 < a < 2.34999999999999997e-116

    1. Initial program 58.8%

      \[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 x around 0 61.2%

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

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

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

    if -4.2e-171 < a < 1.65e-296

    1. Initial program 61.0%

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

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

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

      \[\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+91.4%

        \[\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/91.4%

        \[\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/91.4%

        \[\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-sub91.4%

        \[\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--91.4%

        \[\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/91.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -3.3 \cdot 10^{+103}:\\ \;\;\;\;x + \frac{y}{\frac{a}{z}}\\ \mathbf{elif}\;a \leq -1.45 \cdot 10^{+78}:\\ \;\;\;\;y - a \cdot \frac{x}{t}\\ \mathbf{elif}\;a \leq -1.3 \cdot 10^{+46}:\\ \;\;\;\;\left(y - x\right) \cdot \frac{z}{a - t}\\ \mathbf{elif}\;a \leq -1 \cdot 10^{-24}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;a \leq -2.65 \cdot 10^{-133}:\\ \;\;\;\;\left(y - x\right) \cdot \frac{z}{a - t}\\ \mathbf{elif}\;a \leq -4.2 \cdot 10^{-171}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;a \leq 1.65 \cdot 10^{-296}:\\ \;\;\;\;y - \frac{x}{\frac{-t}{z}}\\ \mathbf{elif}\;a \leq 2.35 \cdot 10^{-116}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;a \leq 2.3 \cdot 10^{+112}:\\ \;\;\;\;\left(y - x\right) \cdot \frac{z}{a - t}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{\frac{a}{z}}\\ \end{array} \]

Alternative 3: 73.0% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := y + \left(y - x\right) \cdot \frac{a - z}{t}\\ t_2 := x + \frac{y - x}{\frac{a}{z}}\\ t_3 := x - \frac{y}{a - t} \cdot \left(t - z\right)\\ \mathbf{if}\;a \leq -3.3 \cdot 10^{+103}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;a \leq -2.25 \cdot 10^{+19}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq -2.7 \cdot 10^{-45}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;a \leq 9 \cdot 10^{-38}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq 12.5:\\ \;\;\;\;t_2\\ \mathbf{elif}\;a \leq 4.7 \cdot 10^{+108}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_3\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (+ y (* (- y x) (/ (- a z) t))))
        (t_2 (+ x (/ (- y x) (/ a z))))
        (t_3 (- x (* (/ y (- a t)) (- t z)))))
   (if (<= a -3.3e+103)
     t_2
     (if (<= a -2.25e+19)
       t_1
       (if (<= a -2.7e-45)
         t_3
         (if (<= a 9e-38)
           t_1
           (if (<= a 12.5) t_2 (if (<= a 4.7e+108) t_1 t_3))))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = y + ((y - x) * ((a - z) / t));
	double t_2 = x + ((y - x) / (a / z));
	double t_3 = x - ((y / (a - t)) * (t - z));
	double tmp;
	if (a <= -3.3e+103) {
		tmp = t_2;
	} else if (a <= -2.25e+19) {
		tmp = t_1;
	} else if (a <= -2.7e-45) {
		tmp = t_3;
	} else if (a <= 9e-38) {
		tmp = t_1;
	} else if (a <= 12.5) {
		tmp = t_2;
	} else if (a <= 4.7e+108) {
		tmp = t_1;
	} else {
		tmp = t_3;
	}
	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) :: t_3
    real(8) :: tmp
    t_1 = y + ((y - x) * ((a - z) / t))
    t_2 = x + ((y - x) / (a / z))
    t_3 = x - ((y / (a - t)) * (t - z))
    if (a <= (-3.3d+103)) then
        tmp = t_2
    else if (a <= (-2.25d+19)) then
        tmp = t_1
    else if (a <= (-2.7d-45)) then
        tmp = t_3
    else if (a <= 9d-38) then
        tmp = t_1
    else if (a <= 12.5d0) then
        tmp = t_2
    else if (a <= 4.7d+108) then
        tmp = t_1
    else
        tmp = t_3
    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 - x) * ((a - z) / t));
	double t_2 = x + ((y - x) / (a / z));
	double t_3 = x - ((y / (a - t)) * (t - z));
	double tmp;
	if (a <= -3.3e+103) {
		tmp = t_2;
	} else if (a <= -2.25e+19) {
		tmp = t_1;
	} else if (a <= -2.7e-45) {
		tmp = t_3;
	} else if (a <= 9e-38) {
		tmp = t_1;
	} else if (a <= 12.5) {
		tmp = t_2;
	} else if (a <= 4.7e+108) {
		tmp = t_1;
	} else {
		tmp = t_3;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = y + ((y - x) * ((a - z) / t))
	t_2 = x + ((y - x) / (a / z))
	t_3 = x - ((y / (a - t)) * (t - z))
	tmp = 0
	if a <= -3.3e+103:
		tmp = t_2
	elif a <= -2.25e+19:
		tmp = t_1
	elif a <= -2.7e-45:
		tmp = t_3
	elif a <= 9e-38:
		tmp = t_1
	elif a <= 12.5:
		tmp = t_2
	elif a <= 4.7e+108:
		tmp = t_1
	else:
		tmp = t_3
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(y + Float64(Float64(y - x) * Float64(Float64(a - z) / t)))
	t_2 = Float64(x + Float64(Float64(y - x) / Float64(a / z)))
	t_3 = Float64(x - Float64(Float64(y / Float64(a - t)) * Float64(t - z)))
	tmp = 0.0
	if (a <= -3.3e+103)
		tmp = t_2;
	elseif (a <= -2.25e+19)
		tmp = t_1;
	elseif (a <= -2.7e-45)
		tmp = t_3;
	elseif (a <= 9e-38)
		tmp = t_1;
	elseif (a <= 12.5)
		tmp = t_2;
	elseif (a <= 4.7e+108)
		tmp = t_1;
	else
		tmp = t_3;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = y + ((y - x) * ((a - z) / t));
	t_2 = x + ((y - x) / (a / z));
	t_3 = x - ((y / (a - t)) * (t - z));
	tmp = 0.0;
	if (a <= -3.3e+103)
		tmp = t_2;
	elseif (a <= -2.25e+19)
		tmp = t_1;
	elseif (a <= -2.7e-45)
		tmp = t_3;
	elseif (a <= 9e-38)
		tmp = t_1;
	elseif (a <= 12.5)
		tmp = t_2;
	elseif (a <= 4.7e+108)
		tmp = t_1;
	else
		tmp = t_3;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y + N[(N[(y - x), $MachinePrecision] * N[(N[(a - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(N[(y - x), $MachinePrecision] / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(x - N[(N[(y / N[(a - t), $MachinePrecision]), $MachinePrecision] * N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -3.3e+103], t$95$2, If[LessEqual[a, -2.25e+19], t$95$1, If[LessEqual[a, -2.7e-45], t$95$3, If[LessEqual[a, 9e-38], t$95$1, If[LessEqual[a, 12.5], t$95$2, If[LessEqual[a, 4.7e+108], t$95$1, t$95$3]]]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;a \leq -2.25 \cdot 10^{+19}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;a \leq -2.7 \cdot 10^{-45}:\\
\;\;\;\;t_3\\

\mathbf{elif}\;a \leq 9 \cdot 10^{-38}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;a \leq 12.5:\\
\;\;\;\;t_2\\

\mathbf{elif}\;a \leq 4.7 \cdot 10^{+108}:\\
\;\;\;\;t_1\\

\mathbf{else}:\\
\;\;\;\;t_3\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if a < -3.30000000000000009e103 or 9.00000000000000018e-38 < a < 12.5

    1. Initial program 73.2%

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

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

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

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

    if -3.30000000000000009e103 < a < -2.25e19 or -2.69999999999999985e-45 < a < 9.00000000000000018e-38 or 12.5 < a < 4.6999999999999996e108

    1. Initial program 55.5%

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

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

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

      \[\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+72.8%

        \[\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/72.8%

        \[\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/72.8%

        \[\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-sub72.8%

        \[\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--72.8%

        \[\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/72.8%

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

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

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

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

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

      \[\leadsto \color{blue}{y - \frac{y - x}{\frac{t}{z - a}}} \]
    7. Step-by-step derivation
      1. clear-num83.6%

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

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

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

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

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

        \[\leadsto y - \color{blue}{\frac{y - x}{1} \cdot \frac{z - a}{t}} \]
      2. /-rgt-identity83.6%

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

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

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

    if -2.25e19 < a < -2.69999999999999985e-45 or 4.6999999999999996e108 < a

    1. Initial program 72.1%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -3.3 \cdot 10^{+103}:\\ \;\;\;\;x + \frac{y - x}{\frac{a}{z}}\\ \mathbf{elif}\;a \leq -2.25 \cdot 10^{+19}:\\ \;\;\;\;y + \left(y - x\right) \cdot \frac{a - z}{t}\\ \mathbf{elif}\;a \leq -2.7 \cdot 10^{-45}:\\ \;\;\;\;x - \frac{y}{a - t} \cdot \left(t - z\right)\\ \mathbf{elif}\;a \leq 9 \cdot 10^{-38}:\\ \;\;\;\;y + \left(y - x\right) \cdot \frac{a - z}{t}\\ \mathbf{elif}\;a \leq 12.5:\\ \;\;\;\;x + \frac{y - x}{\frac{a}{z}}\\ \mathbf{elif}\;a \leq 4.7 \cdot 10^{+108}:\\ \;\;\;\;y + \left(y - x\right) \cdot \frac{a - z}{t}\\ \mathbf{else}:\\ \;\;\;\;x - \frac{y}{a - t} \cdot \left(t - z\right)\\ \end{array} \]

Alternative 4: 72.9% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := y + \left(y - x\right) \cdot \frac{a - z}{t}\\ t_2 := x + \frac{y - x}{\frac{a}{z}}\\ t_3 := x - \frac{y}{a - t} \cdot \left(t - z\right)\\ \mathbf{if}\;a \leq -3.3 \cdot 10^{+105}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;a \leq -2.1 \cdot 10^{+19}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq -1.12 \cdot 10^{-43}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;a \leq 6.2 \cdot 10^{-38}:\\ \;\;\;\;y + \frac{x - y}{\frac{t}{z - a}}\\ \mathbf{elif}\;a \leq 49:\\ \;\;\;\;t_2\\ \mathbf{elif}\;a \leq 1.05 \cdot 10^{+108}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_3\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (+ y (* (- y x) (/ (- a z) t))))
        (t_2 (+ x (/ (- y x) (/ a z))))
        (t_3 (- x (* (/ y (- a t)) (- t z)))))
   (if (<= a -3.3e+105)
     t_2
     (if (<= a -2.1e+19)
       t_1
       (if (<= a -1.12e-43)
         t_3
         (if (<= a 6.2e-38)
           (+ y (/ (- x y) (/ t (- z a))))
           (if (<= a 49.0) t_2 (if (<= a 1.05e+108) t_1 t_3))))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = y + ((y - x) * ((a - z) / t));
	double t_2 = x + ((y - x) / (a / z));
	double t_3 = x - ((y / (a - t)) * (t - z));
	double tmp;
	if (a <= -3.3e+105) {
		tmp = t_2;
	} else if (a <= -2.1e+19) {
		tmp = t_1;
	} else if (a <= -1.12e-43) {
		tmp = t_3;
	} else if (a <= 6.2e-38) {
		tmp = y + ((x - y) / (t / (z - a)));
	} else if (a <= 49.0) {
		tmp = t_2;
	} else if (a <= 1.05e+108) {
		tmp = t_1;
	} else {
		tmp = t_3;
	}
	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) :: t_3
    real(8) :: tmp
    t_1 = y + ((y - x) * ((a - z) / t))
    t_2 = x + ((y - x) / (a / z))
    t_3 = x - ((y / (a - t)) * (t - z))
    if (a <= (-3.3d+105)) then
        tmp = t_2
    else if (a <= (-2.1d+19)) then
        tmp = t_1
    else if (a <= (-1.12d-43)) then
        tmp = t_3
    else if (a <= 6.2d-38) then
        tmp = y + ((x - y) / (t / (z - a)))
    else if (a <= 49.0d0) then
        tmp = t_2
    else if (a <= 1.05d+108) then
        tmp = t_1
    else
        tmp = t_3
    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 - x) * ((a - z) / t));
	double t_2 = x + ((y - x) / (a / z));
	double t_3 = x - ((y / (a - t)) * (t - z));
	double tmp;
	if (a <= -3.3e+105) {
		tmp = t_2;
	} else if (a <= -2.1e+19) {
		tmp = t_1;
	} else if (a <= -1.12e-43) {
		tmp = t_3;
	} else if (a <= 6.2e-38) {
		tmp = y + ((x - y) / (t / (z - a)));
	} else if (a <= 49.0) {
		tmp = t_2;
	} else if (a <= 1.05e+108) {
		tmp = t_1;
	} else {
		tmp = t_3;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = y + ((y - x) * ((a - z) / t))
	t_2 = x + ((y - x) / (a / z))
	t_3 = x - ((y / (a - t)) * (t - z))
	tmp = 0
	if a <= -3.3e+105:
		tmp = t_2
	elif a <= -2.1e+19:
		tmp = t_1
	elif a <= -1.12e-43:
		tmp = t_3
	elif a <= 6.2e-38:
		tmp = y + ((x - y) / (t / (z - a)))
	elif a <= 49.0:
		tmp = t_2
	elif a <= 1.05e+108:
		tmp = t_1
	else:
		tmp = t_3
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(y + Float64(Float64(y - x) * Float64(Float64(a - z) / t)))
	t_2 = Float64(x + Float64(Float64(y - x) / Float64(a / z)))
	t_3 = Float64(x - Float64(Float64(y / Float64(a - t)) * Float64(t - z)))
	tmp = 0.0
	if (a <= -3.3e+105)
		tmp = t_2;
	elseif (a <= -2.1e+19)
		tmp = t_1;
	elseif (a <= -1.12e-43)
		tmp = t_3;
	elseif (a <= 6.2e-38)
		tmp = Float64(y + Float64(Float64(x - y) / Float64(t / Float64(z - a))));
	elseif (a <= 49.0)
		tmp = t_2;
	elseif (a <= 1.05e+108)
		tmp = t_1;
	else
		tmp = t_3;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = y + ((y - x) * ((a - z) / t));
	t_2 = x + ((y - x) / (a / z));
	t_3 = x - ((y / (a - t)) * (t - z));
	tmp = 0.0;
	if (a <= -3.3e+105)
		tmp = t_2;
	elseif (a <= -2.1e+19)
		tmp = t_1;
	elseif (a <= -1.12e-43)
		tmp = t_3;
	elseif (a <= 6.2e-38)
		tmp = y + ((x - y) / (t / (z - a)));
	elseif (a <= 49.0)
		tmp = t_2;
	elseif (a <= 1.05e+108)
		tmp = t_1;
	else
		tmp = t_3;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y + N[(N[(y - x), $MachinePrecision] * N[(N[(a - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(N[(y - x), $MachinePrecision] / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(x - N[(N[(y / N[(a - t), $MachinePrecision]), $MachinePrecision] * N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -3.3e+105], t$95$2, If[LessEqual[a, -2.1e+19], t$95$1, If[LessEqual[a, -1.12e-43], t$95$3, If[LessEqual[a, 6.2e-38], N[(y + N[(N[(x - y), $MachinePrecision] / N[(t / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 49.0], t$95$2, If[LessEqual[a, 1.05e+108], t$95$1, t$95$3]]]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;a \leq -2.1 \cdot 10^{+19}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;a \leq -1.12 \cdot 10^{-43}:\\
\;\;\;\;t_3\\

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

\mathbf{elif}\;a \leq 49:\\
\;\;\;\;t_2\\

\mathbf{elif}\;a \leq 1.05 \cdot 10^{+108}:\\
\;\;\;\;t_1\\

\mathbf{else}:\\
\;\;\;\;t_3\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if a < -3.29999999999999997e105 or 6.19999999999999966e-38 < a < 49

    1. Initial program 73.2%

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

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

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

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

    if -3.29999999999999997e105 < a < -2.1e19 or 49 < a < 1.05000000000000005e108

    1. Initial program 52.2%

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

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

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

      \[\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+58.3%

        \[\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/58.3%

        \[\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/58.3%

        \[\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-sub58.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--58.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/58.3%

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

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

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

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

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

      \[\leadsto \color{blue}{y - \frac{y - x}{\frac{t}{z - a}}} \]
    7. Step-by-step derivation
      1. clear-num79.1%

        \[\leadsto y - \frac{y - x}{\color{blue}{\frac{1}{\frac{z - a}{t}}}} \]
      2. inv-pow79.1%

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

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

        \[\leadsto y - \frac{y - x}{\color{blue}{\frac{1}{\frac{z - a}{t}}}} \]
    10. Simplified79.1%

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

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

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

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

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

    if -2.1e19 < a < -1.12e-43 or 1.05000000000000005e108 < a

    1. Initial program 72.1%

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

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

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

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

    if -1.12e-43 < a < 6.19999999999999966e-38

    1. Initial program 56.2%

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

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

      \[\leadsto \color{blue}{x + \frac{y - x}{\frac{a - t}{z - t}}} \]
    4. Taylor expanded in t around inf 76.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+76.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/76.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/76.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-sub76.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--76.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/76.2%

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -3.3 \cdot 10^{+105}:\\ \;\;\;\;x + \frac{y - x}{\frac{a}{z}}\\ \mathbf{elif}\;a \leq -2.1 \cdot 10^{+19}:\\ \;\;\;\;y + \left(y - x\right) \cdot \frac{a - z}{t}\\ \mathbf{elif}\;a \leq -1.12 \cdot 10^{-43}:\\ \;\;\;\;x - \frac{y}{a - t} \cdot \left(t - z\right)\\ \mathbf{elif}\;a \leq 6.2 \cdot 10^{-38}:\\ \;\;\;\;y + \frac{x - y}{\frac{t}{z - a}}\\ \mathbf{elif}\;a \leq 49:\\ \;\;\;\;x + \frac{y - x}{\frac{a}{z}}\\ \mathbf{elif}\;a \leq 1.05 \cdot 10^{+108}:\\ \;\;\;\;y + \left(y - x\right) \cdot \frac{a - z}{t}\\ \mathbf{else}:\\ \;\;\;\;x - \frac{y}{a - t} \cdot \left(t - z\right)\\ \end{array} \]

Alternative 5: 57.7% accurate, 0.7× speedup?

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

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

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

\mathbf{elif}\;a \leq 1.35 \cdot 10^{-113}:\\
\;\;\;\;t_2\\

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

\mathbf{elif}\;a \leq 1.12 \cdot 10^{+129}:\\
\;\;\;\;t_2\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if a < -2.80000000000000013e119 or 1.11999999999999993e129 < a

    1. Initial program 72.4%

      \[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}{a - t} \cdot \left(z - t\right)} \]
    3. Simplified92.9%

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

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

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

        \[\leadsto x + \color{blue}{\frac{y}{\frac{a}{z}}} \]
    7. Simplified76.4%

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

    if -2.80000000000000013e119 < a < 3.39999999999999997e-296

    1. Initial program 60.5%

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

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

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

      \[\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+66.4%

        \[\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/66.4%

        \[\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/66.4%

        \[\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-sub66.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--66.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/66.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 3.39999999999999997e-296 < a < 1.34999999999999998e-113 or 4.30000000000000014e-10 < a < 1.11999999999999993e129

    1. Initial program 56.4%

      \[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 x around 0 57.7%

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

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

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

    if 1.34999999999999998e-113 < a < 4.30000000000000014e-10

    1. Initial program 57.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -2.8 \cdot 10^{+119}:\\ \;\;\;\;x + \frac{y}{\frac{a}{z}}\\ \mathbf{elif}\;a \leq 3.4 \cdot 10^{-296}:\\ \;\;\;\;y + x \cdot \frac{z}{t}\\ \mathbf{elif}\;a \leq 1.35 \cdot 10^{-113}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;a \leq 4.3 \cdot 10^{-10}:\\ \;\;\;\;\frac{-x}{\frac{a - t}{z}}\\ \mathbf{elif}\;a \leq 1.12 \cdot 10^{+129}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{\frac{a}{z}}\\ \end{array} \]

Alternative 6: 73.4% accurate, 0.7× speedup?

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

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

\mathbf{elif}\;a \leq 3.5 \cdot 10^{-41}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;a \leq 7.2:\\
\;\;\;\;x + \frac{y - x}{\frac{a}{z}}\\

\mathbf{elif}\;a \leq 1.05 \cdot 10^{+108}:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if a < -6.3999999999999998e-46 or 1.05000000000000005e108 < a

    1. Initial program 69.7%

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

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

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

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

    if -6.3999999999999998e-46 < a < 3.5e-41 or 7.20000000000000018 < a < 1.05000000000000005e108

    1. Initial program 55.8%

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

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

      \[\leadsto \color{blue}{x + \frac{y - x}{\frac{a - t}{z - t}}} \]
    4. Taylor expanded in t around inf 75.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+75.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/75.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/75.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-sub75.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--75.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/75.5%

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

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

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

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

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

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

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

    if 3.5e-41 < a < 7.20000000000000018

    1. Initial program 77.5%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -6.4 \cdot 10^{-46}:\\ \;\;\;\;x - \frac{y}{a - t} \cdot \left(t - z\right)\\ \mathbf{elif}\;a \leq 3.5 \cdot 10^{-41}:\\ \;\;\;\;y - \frac{y - x}{\frac{t}{z}}\\ \mathbf{elif}\;a \leq 7.2:\\ \;\;\;\;x + \frac{y - x}{\frac{a}{z}}\\ \mathbf{elif}\;a \leq 1.05 \cdot 10^{+108}:\\ \;\;\;\;y - \frac{y - x}{\frac{t}{z}}\\ \mathbf{else}:\\ \;\;\;\;x - \frac{y}{a - t} \cdot \left(t - z\right)\\ \end{array} \]

Alternative 7: 63.0% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
t_1 := x + \frac{y - x}{\frac{a}{z}}\\
\mathbf{if}\;a \leq -22:\\
\;\;\;\;t_1\\

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if a < -22 or 4.90000000000000002e110 < a

    1. Initial program 68.8%

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

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

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

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

    if -22 < a < 2.30000000000000004e-296

    1. Initial program 61.0%

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

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

      \[\leadsto \color{blue}{x + \frac{y - x}{\frac{a - t}{z - t}}} \]
    4. Taylor expanded in t around inf 72.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+72.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/72.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/72.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-sub72.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--72.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/72.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 2.30000000000000004e-296 < a < 2.54999999999999989e-113

    1. Initial program 57.6%

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

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

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

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

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

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

    if 2.54999999999999989e-113 < a < 4.90000000000000002e110

    1. Initial program 57.2%

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

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

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

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

        \[\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*60.7%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -22:\\ \;\;\;\;x + \frac{y - x}{\frac{a}{z}}\\ \mathbf{elif}\;a \leq 2.3 \cdot 10^{-296}:\\ \;\;\;\;y + x \cdot \frac{z}{t}\\ \mathbf{elif}\;a \leq 2.55 \cdot 10^{-113}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;a \leq 4.9 \cdot 10^{+110}:\\ \;\;\;\;\left(y - x\right) \cdot \frac{z}{a - t}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y - x}{\frac{a}{z}}\\ \end{array} \]

Alternative 8: 85.6% accurate, 0.8× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -1.44999999999999995e59

    1. Initial program 28.0%

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

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

      \[\leadsto \color{blue}{x + \frac{y - x}{\frac{a - t}{z - t}}} \]
    4. Taylor expanded in t around inf 59.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+59.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/59.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/59.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-sub59.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--59.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/59.2%

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

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

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

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

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

      \[\leadsto \color{blue}{y - \frac{y - x}{\frac{t}{z - a}}} \]
    7. Step-by-step derivation
      1. clear-num87.2%

        \[\leadsto y - \frac{y - x}{\color{blue}{\frac{1}{\frac{z - a}{t}}}} \]
      2. inv-pow87.2%

        \[\leadsto y - \frac{y - x}{\color{blue}{{\left(\frac{z - a}{t}\right)}^{-1}}} \]
    8. Applied egg-rr87.2%

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

        \[\leadsto y - \frac{y - x}{\color{blue}{\frac{1}{\frac{z - a}{t}}}} \]
    10. Simplified87.2%

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

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

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

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

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

    if -1.44999999999999995e59 < t < 4.00000000000000039e199

    1. Initial program 80.2%

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

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

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

    if 4.00000000000000039e199 < t

    1. Initial program 25.9%

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

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

      \[\leadsto \color{blue}{x + \frac{y - x}{\frac{a - t}{z - t}}} \]
    4. Taylor expanded in t around inf 67.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+67.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/67.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/67.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-sub67.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--67.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/67.2%

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -1.45 \cdot 10^{+59}:\\ \;\;\;\;y + \left(y - x\right) \cdot \frac{a - z}{t}\\ \mathbf{elif}\;t \leq 4 \cdot 10^{+199}:\\ \;\;\;\;x - \left(z - t\right) \cdot \frac{x - y}{a - t}\\ \mathbf{else}:\\ \;\;\;\;y + \left(z - a\right) \cdot \frac{x}{t}\\ \end{array} \]

Alternative 9: 56.9% accurate, 0.9× speedup?

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

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

\mathbf{elif}\;a \leq 7.6 \cdot 10^{-248}:\\
\;\;\;\;t_1\\

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

\mathbf{elif}\;a \leq 1.12 \cdot 10^{+129}:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if a < -2.80000000000000013e119 or 1.11999999999999993e129 < a

    1. Initial program 72.4%

      \[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}{a - t} \cdot \left(z - t\right)} \]
    3. Simplified92.9%

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

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

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

        \[\leadsto x + \color{blue}{\frac{y}{\frac{a}{z}}} \]
    7. Simplified76.4%

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

    if -2.80000000000000013e119 < a < 7.5999999999999998e-248 or 2.49999999999999989e-213 < a < 1.11999999999999993e129

    1. Initial program 58.0%

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

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

      \[\leadsto \color{blue}{x + \frac{y - x}{\frac{a - t}{z - t}}} \]
    4. Taylor expanded in t around inf 67.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+67.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/67.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/67.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-sub67.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--67.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/67.2%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 7.5999999999999998e-248 < a < 2.49999999999999989e-213

    1. Initial program 71.7%

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -2.8 \cdot 10^{+119}:\\ \;\;\;\;x + \frac{y}{\frac{a}{z}}\\ \mathbf{elif}\;a \leq 7.6 \cdot 10^{-248}:\\ \;\;\;\;y + x \cdot \frac{z}{t}\\ \mathbf{elif}\;a \leq 2.5 \cdot 10^{-213}:\\ \;\;\;\;\frac{z}{\frac{a - t}{y}}\\ \mathbf{elif}\;a \leq 1.12 \cdot 10^{+129}:\\ \;\;\;\;y + x \cdot \frac{z}{t}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{\frac{a}{z}}\\ \end{array} \]

Alternative 10: 56.6% accurate, 0.9× speedup?

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

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

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if a < -3.05e119 or 1.2500000000000001e129 < a

    1. Initial program 72.4%

      \[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}{a - t} \cdot \left(z - t\right)} \]
    3. Simplified92.9%

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

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

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

        \[\leadsto x + \color{blue}{\frac{y}{\frac{a}{z}}} \]
    7. Simplified76.4%

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

    if -3.05e119 < a < 7.5999999999999998e-248

    1. Initial program 60.6%

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

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

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

      \[\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+70.9%

        \[\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/70.9%

        \[\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/70.9%

        \[\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-sub71.0%

        \[\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--71.0%

        \[\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/71.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto y - \color{blue}{-1 \cdot \frac{x \cdot z}{t}} \]
    14. Step-by-step derivation
      1. mul-1-neg57.4%

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

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

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

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

    if 7.5999999999999998e-248 < a < 2.49999999999999989e-213

    1. Initial program 71.7%

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

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

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

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

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

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

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

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

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

    if 2.49999999999999989e-213 < a < 1.2500000000000001e129

    1. Initial program 54.0%

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

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

      \[\leadsto \color{blue}{x + \frac{y - x}{\frac{a - t}{z - t}}} \]
    4. Taylor expanded in t around inf 61.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+61.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/61.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/61.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-sub61.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--61.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/61.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto y - z \cdot \color{blue}{\frac{-x}{t}} \]
    12. Simplified54.1%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -3.05 \cdot 10^{+119}:\\ \;\;\;\;x + \frac{y}{\frac{a}{z}}\\ \mathbf{elif}\;a \leq 7.6 \cdot 10^{-248}:\\ \;\;\;\;y + x \cdot \frac{z}{t}\\ \mathbf{elif}\;a \leq 2.5 \cdot 10^{-213}:\\ \;\;\;\;\frac{z}{\frac{a - t}{y}}\\ \mathbf{elif}\;a \leq 1.25 \cdot 10^{+129}:\\ \;\;\;\;y + z \cdot \frac{x}{t}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{\frac{a}{z}}\\ \end{array} \]

Alternative 11: 65.9% accurate, 0.9× speedup?

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

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < -1.49999999999999996e95

    1. Initial program 25.4%

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

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

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

      \[\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+58.1%

        \[\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/58.1%

        \[\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/58.1%

        \[\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-sub58.1%

        \[\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--58.1%

        \[\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/58.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -1.49999999999999996e95 < t < -5.0000000000000003e-116

    1. Initial program 77.9%

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

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

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

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

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

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

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

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

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

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

    if -5.0000000000000003e-116 < t < 3.99999999999999966e29

    1. Initial program 89.7%

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

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

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

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

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

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

    if 3.99999999999999966e29 < t

    1. Initial program 41.1%

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

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

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

      \[\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+67.7%

        \[\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/67.7%

        \[\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/67.7%

        \[\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-sub67.7%

        \[\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--67.7%

        \[\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/67.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto y - z \cdot \color{blue}{\frac{-x}{t}} \]
    12. Simplified64.5%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -1.5 \cdot 10^{+95}:\\ \;\;\;\;y - \frac{x}{\frac{-t}{z}}\\ \mathbf{elif}\;t \leq -5 \cdot 10^{-116}:\\ \;\;\;\;\left(y - x\right) \cdot \frac{z}{a - t}\\ \mathbf{elif}\;t \leq 4 \cdot 10^{+29}:\\ \;\;\;\;x + \frac{z}{\frac{a}{y - x}}\\ \mathbf{else}:\\ \;\;\;\;y + z \cdot \frac{x}{t}\\ \end{array} \]

Alternative 12: 69.2% accurate, 0.9× speedup?

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

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -8.6e94 or 9.2000000000000002e27 < t

    1. Initial program 33.4%

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

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

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

      \[\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+63.0%

        \[\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/63.0%

        \[\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/63.0%

        \[\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-sub63.0%

        \[\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--63.0%

        \[\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/63.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -8.6e94 < t < -1.05000000000000001e-115

    1. Initial program 77.9%

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

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

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

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

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

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

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

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

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

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

    if -1.05000000000000001e-115 < t < 9.2000000000000002e27

    1. Initial program 89.7%

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -8.6 \cdot 10^{+94}:\\ \;\;\;\;y - \frac{x}{\frac{t}{a - z}}\\ \mathbf{elif}\;t \leq -1.05 \cdot 10^{-115}:\\ \;\;\;\;\left(y - x\right) \cdot \frac{z}{a - t}\\ \mathbf{elif}\;t \leq 9.2 \cdot 10^{+27}:\\ \;\;\;\;x + \frac{z}{\frac{a}{y - x}}\\ \mathbf{else}:\\ \;\;\;\;y - \frac{x}{\frac{t}{a - z}}\\ \end{array} \]

Alternative 13: 67.3% accurate, 0.9× speedup?

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

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < -2.1e95

    1. Initial program 25.4%

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

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

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

      \[\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+58.1%

        \[\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/58.1%

        \[\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/58.1%

        \[\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-sub58.1%

        \[\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--58.1%

        \[\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/58.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -2.1e95 < t < -1.05000000000000001e-115

    1. Initial program 77.9%

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

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

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

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

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

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

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

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

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

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

    if -1.05000000000000001e-115 < t < 4.9999999999999996e22

    1. Initial program 89.7%

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

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

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

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

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

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

    if 4.9999999999999996e22 < t

    1. Initial program 41.1%

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

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

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

      \[\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+67.7%

        \[\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/67.7%

        \[\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/67.7%

        \[\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-sub67.7%

        \[\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--67.7%

        \[\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/67.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -2.1 \cdot 10^{+95}:\\ \;\;\;\;y - \frac{x}{\frac{t}{a - z}}\\ \mathbf{elif}\;t \leq -1.05 \cdot 10^{-115}:\\ \;\;\;\;\left(y - x\right) \cdot \frac{z}{a - t}\\ \mathbf{elif}\;t \leq 5 \cdot 10^{+22}:\\ \;\;\;\;x + \frac{z}{\frac{a}{y - x}}\\ \mathbf{else}:\\ \;\;\;\;y + \frac{x \cdot \left(z - a\right)}{t}\\ \end{array} \]

Alternative 14: 69.7% accurate, 1.0× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -2 \cdot 10^{-71} \lor \neg \left(t \leq 1.55 \cdot 10^{+23}\right):\\
\;\;\;\;y + \frac{x - y}{\frac{t}{z}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -1.9999999999999998e-71 or 1.54999999999999985e23 < t

    1. Initial program 44.3%

      \[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 t around inf 62.3%

      \[\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+62.3%

        \[\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/62.3%

        \[\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/62.3%

        \[\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-sub62.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--62.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/62.3%

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

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

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

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

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

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

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

    if -1.9999999999999998e-71 < t < 1.54999999999999985e23

    1. Initial program 89.5%

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

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

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

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

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

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

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

Alternative 15: 56.1% accurate, 1.2× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -8 \cdot 10^{+93} \lor \neg \left(t \leq 1.2 \cdot 10^{+26}\right):\\
\;\;\;\;y - a \cdot \frac{x}{t}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -8.00000000000000035e93 or 1.20000000000000002e26 < t

    1. Initial program 34.0%

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

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

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

      \[\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+63.4%

        \[\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/63.4%

        \[\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/63.4%

        \[\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-sub63.4%

        \[\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--63.4%

        \[\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/63.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -8.00000000000000035e93 < t < 1.20000000000000002e26

    1. Initial program 85.7%

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

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

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

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

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

        \[\leadsto x + \color{blue}{\frac{y}{\frac{a}{z}}} \]
    7. Simplified54.6%

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

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

Alternative 16: 48.5% accurate, 1.2× speedup?

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

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

\mathbf{elif}\;t \leq 1.65 \cdot 10^{+111}:\\
\;\;\;\;x \cdot \left(1 - \frac{z}{a}\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -8.99999999999999944e94 or 1.6500000000000001e111 < t

    1. Initial program 30.1%

      \[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 50.8%

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

    if -8.99999999999999944e94 < t < 1.6500000000000001e111

    1. Initial program 81.9%

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -9 \cdot 10^{+94}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 1.65 \cdot 10^{+111}:\\ \;\;\;\;x \cdot \left(1 - \frac{z}{a}\right)\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]

Alternative 17: 52.9% accurate, 1.2× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -2.6999999999999999e93 or 1.4000000000000001e25 < t

    1. Initial program 34.0%

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

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

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

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

    if -2.6999999999999999e93 < t < 1.4000000000000001e25

    1. Initial program 85.7%

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

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

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

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

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

        \[\leadsto x + \color{blue}{\frac{y}{\frac{a}{z}}} \]
    7. Simplified54.6%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -2.7 \cdot 10^{+93}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 1.4 \cdot 10^{+25}:\\ \;\;\;\;x + \frac{y}{\frac{a}{z}}\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]

Alternative 18: 56.1% accurate, 1.2× speedup?

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

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

\mathbf{elif}\;t \leq 4 \cdot 10^{+25}:\\
\;\;\;\;x + \frac{y}{\frac{a}{z}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -2.39999999999999983e94

    1. Initial program 26.7%

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

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

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

      \[\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+58.9%

        \[\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/58.9%

        \[\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/58.9%

        \[\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-sub58.9%

        \[\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--58.9%

        \[\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/58.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -2.39999999999999983e94 < t < 4.00000000000000036e25

    1. Initial program 85.7%

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

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

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

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

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

        \[\leadsto x + \color{blue}{\frac{y}{\frac{a}{z}}} \]
    7. Simplified54.6%

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

    if 4.00000000000000036e25 < t

    1. Initial program 41.1%

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

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

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

      \[\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+67.7%

        \[\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/67.7%

        \[\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/67.7%

        \[\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-sub67.7%

        \[\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--67.7%

        \[\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/67.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto y - \color{blue}{\frac{x}{\frac{t}{a - z}}} \]
    12. Simplified67.0%

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

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

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

        \[\leadsto y - \color{blue}{\frac{a}{t} \cdot x} \]
    15. Simplified48.4%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -2.4 \cdot 10^{+94}:\\ \;\;\;\;y - a \cdot \frac{x}{t}\\ \mathbf{elif}\;t \leq 4 \cdot 10^{+25}:\\ \;\;\;\;x + \frac{y}{\frac{a}{z}}\\ \mathbf{else}:\\ \;\;\;\;y - x \cdot \frac{a}{t}\\ \end{array} \]

Alternative 19: 55.7% accurate, 1.2× speedup?

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

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

\mathbf{elif}\;t \leq 2.5 \cdot 10^{+29}:\\
\;\;\;\;x + \frac{y}{\frac{a}{z}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -1.9e92

    1. Initial program 26.7%

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

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

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

      \[\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+58.9%

        \[\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/58.9%

        \[\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/58.9%

        \[\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-sub58.9%

        \[\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--58.9%

        \[\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/58.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -1.9e92 < t < 2.5e29

    1. Initial program 85.7%

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

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

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

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

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

        \[\leadsto x + \color{blue}{\frac{y}{\frac{a}{z}}} \]
    7. Simplified54.6%

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

    if 2.5e29 < t

    1. Initial program 41.1%

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

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

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

      \[\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+67.7%

        \[\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/67.7%

        \[\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/67.7%

        \[\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-sub67.7%

        \[\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--67.7%

        \[\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/67.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -1.9 \cdot 10^{+92}:\\ \;\;\;\;y - a \cdot \frac{x}{t}\\ \mathbf{elif}\;t \leq 2.5 \cdot 10^{+29}:\\ \;\;\;\;x + \frac{y}{\frac{a}{z}}\\ \mathbf{else}:\\ \;\;\;\;y - \frac{x \cdot a}{t}\\ \end{array} \]

Alternative 20: 37.8% accurate, 2.5× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;a \leq -2.85 \cdot 10^{+119}:\\
\;\;\;\;x\\

\mathbf{elif}\;a \leq 1.22 \cdot 10^{+129}:\\
\;\;\;\;y\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if a < -2.8500000000000001e119 or 1.2200000000000001e129 < a

    1. Initial program 72.4%

      \[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 62.0%

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

    if -2.8500000000000001e119 < a < 1.2200000000000001e129

    1. Initial program 58.6%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -2.85 \cdot 10^{+119}:\\ \;\;\;\;x\\ \mathbf{elif}\;a \leq 1.22 \cdot 10^{+129}:\\ \;\;\;\;y\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 21: 25.1% 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 62.7%

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

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

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

    \[\leadsto \color{blue}{x} \]
  5. Final simplification24.0%

    \[\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 2023318 
(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))))