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

Percentage Accurate: 68.9% → 89.5%
Time: 14.6s
Alternatives: 19
Speedup: 0.7×

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 19 alternatives:

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

Initial Program: 68.9% accurate, 1.0× speedup?

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

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

Alternative 1: 89.5% accurate, 0.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -3.4 \cdot 10^{+93} \lor \neg \left(t \leq 2.2 \cdot 10^{+145}\right):\\ \;\;\;\;y + \frac{y - x}{t} \cdot \left(a - z\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(y - x, \frac{z - t}{a - t}, x\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (or (<= t -3.4e+93) (not (<= t 2.2e+145)))
   (+ y (* (/ (- y x) t) (- a z)))
   (fma (- y x) (/ (- z t) (- a t)) x)))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if ((t <= -3.4e+93) || !(t <= 2.2e+145)) {
		tmp = y + (((y - x) / t) * (a - z));
	} else {
		tmp = fma((y - x), ((z - t) / (a - t)), x);
	}
	return tmp;
}
function code(x, y, z, t, a)
	tmp = 0.0
	if ((t <= -3.4e+93) || !(t <= 2.2e+145))
		tmp = Float64(y + Float64(Float64(Float64(y - x) / t) * Float64(a - z)));
	else
		tmp = fma(Float64(y - x), Float64(Float64(z - t) / Float64(a - t)), x);
	end
	return tmp
end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -3.4e+93], N[Not[LessEqual[t, 2.2e+145]], $MachinePrecision]], N[(y + N[(N[(N[(y - x), $MachinePrecision] / t), $MachinePrecision] * N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y - x), $MachinePrecision] * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision]]
\begin{array}{l}

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -3.4e93 or 2.20000000000000009e145 < t

    1. Initial program 37.5%

      \[x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 69.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}} \]
    4. Step-by-step derivation
      1. associate--l+69.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. distribute-lft-out--69.0%

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

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

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

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

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

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

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

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

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

    if -3.4e93 < t < 2.20000000000000009e145

    1. Initial program 85.6%

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{fma}\left(y - x, \frac{z - t}{a - t}, x\right)} \]
    4. Add Preprocessing
  3. Recombined 2 regimes into one program.
  4. Final simplification93.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -3.4 \cdot 10^{+93} \lor \neg \left(t \leq 2.2 \cdot 10^{+145}\right):\\ \;\;\;\;y + \frac{y - x}{t} \cdot \left(a - z\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(y - x, \frac{z - t}{a - t}, x\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 84.0% accurate, 0.3× speedup?

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

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

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < -2.19999999999999992e92 or 1.02e145 < t

    1. Initial program 37.5%

      \[x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 69.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}} \]
    4. Step-by-step derivation
      1. associate--l+69.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. distribute-lft-out--69.0%

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

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

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

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

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

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

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

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

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

    if -2.19999999999999992e92 < t < -2.7000000000000001e-164

    1. Initial program 81.1%

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

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

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

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

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

    if -2.7000000000000001e-164 < t < 0.26000000000000001

    1. Initial program 95.1%

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

    if 0.26000000000000001 < t < 1.02e145

    1. Initial program 63.4%

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

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

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

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

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

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

        \[\leadsto x + \color{blue}{\frac{1}{\frac{\frac{a - t}{z - t}}{y - x}}} \]
      2. associate-/l/63.5%

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -2.2 \cdot 10^{+92}:\\ \;\;\;\;y + \frac{y - x}{t} \cdot \left(a - z\right)\\ \mathbf{elif}\;t \leq -2.7 \cdot 10^{-164}:\\ \;\;\;\;x + x \cdot \left(\frac{z - t}{a - t} \cdot \left(-1 + \frac{y}{x}\right)\right)\\ \mathbf{elif}\;t \leq 0.26:\\ \;\;\;\;x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}\\ \mathbf{elif}\;t \leq 1.02 \cdot 10^{+145}:\\ \;\;\;\;y \cdot \left(\left(\left(\frac{z}{a - t} + \frac{x}{y}\right) + x \cdot \frac{t - z}{y \cdot \left(a - t\right)}\right) + \frac{t}{t - a}\right)\\ \mathbf{else}:\\ \;\;\;\;y + \frac{y - x}{t} \cdot \left(a - z\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 39.1% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x \cdot \frac{z}{-a}\\ t_2 := y \cdot \frac{z}{a}\\ \mathbf{if}\;z \leq -3.7 \cdot 10^{+178}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;z \leq -4.5 \cdot 10^{+152}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq -5 \cdot 10^{+124}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;z \leq -1.95 \cdot 10^{+96}:\\ \;\;\;\;y + x\\ \mathbf{elif}\;z \leq -2.85 \cdot 10^{+76}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 5.6 \cdot 10^{+59}:\\ \;\;\;\;y + x\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (* x (/ z (- a)))) (t_2 (* y (/ z a))))
   (if (<= z -3.7e+178)
     t_2
     (if (<= z -4.5e+152)
       t_1
       (if (<= z -5e+124)
         t_2
         (if (<= z -1.95e+96)
           (+ y x)
           (if (<= z -2.85e+76) t_1 (if (<= z 5.6e+59) (+ y x) t_2))))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = x * (z / -a);
	double t_2 = y * (z / a);
	double tmp;
	if (z <= -3.7e+178) {
		tmp = t_2;
	} else if (z <= -4.5e+152) {
		tmp = t_1;
	} else if (z <= -5e+124) {
		tmp = t_2;
	} else if (z <= -1.95e+96) {
		tmp = y + x;
	} else if (z <= -2.85e+76) {
		tmp = t_1;
	} else if (z <= 5.6e+59) {
		tmp = y + x;
	} else {
		tmp = t_2;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = x * (z / -a)
    t_2 = y * (z / a)
    if (z <= (-3.7d+178)) then
        tmp = t_2
    else if (z <= (-4.5d+152)) then
        tmp = t_1
    else if (z <= (-5d+124)) then
        tmp = t_2
    else if (z <= (-1.95d+96)) then
        tmp = y + x
    else if (z <= (-2.85d+76)) then
        tmp = t_1
    else if (z <= 5.6d+59) then
        tmp = y + x
    else
        tmp = t_2
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = x * (z / -a);
	double t_2 = y * (z / a);
	double tmp;
	if (z <= -3.7e+178) {
		tmp = t_2;
	} else if (z <= -4.5e+152) {
		tmp = t_1;
	} else if (z <= -5e+124) {
		tmp = t_2;
	} else if (z <= -1.95e+96) {
		tmp = y + x;
	} else if (z <= -2.85e+76) {
		tmp = t_1;
	} else if (z <= 5.6e+59) {
		tmp = y + x;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = x * (z / -a)
	t_2 = y * (z / a)
	tmp = 0
	if z <= -3.7e+178:
		tmp = t_2
	elif z <= -4.5e+152:
		tmp = t_1
	elif z <= -5e+124:
		tmp = t_2
	elif z <= -1.95e+96:
		tmp = y + x
	elif z <= -2.85e+76:
		tmp = t_1
	elif z <= 5.6e+59:
		tmp = y + x
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(x * Float64(z / Float64(-a)))
	t_2 = Float64(y * Float64(z / a))
	tmp = 0.0
	if (z <= -3.7e+178)
		tmp = t_2;
	elseif (z <= -4.5e+152)
		tmp = t_1;
	elseif (z <= -5e+124)
		tmp = t_2;
	elseif (z <= -1.95e+96)
		tmp = Float64(y + x);
	elseif (z <= -2.85e+76)
		tmp = t_1;
	elseif (z <= 5.6e+59)
		tmp = Float64(y + x);
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = x * (z / -a);
	t_2 = y * (z / a);
	tmp = 0.0;
	if (z <= -3.7e+178)
		tmp = t_2;
	elseif (z <= -4.5e+152)
		tmp = t_1;
	elseif (z <= -5e+124)
		tmp = t_2;
	elseif (z <= -1.95e+96)
		tmp = y + x;
	elseif (z <= -2.85e+76)
		tmp = t_1;
	elseif (z <= 5.6e+59)
		tmp = y + x;
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x * N[(z / (-a)), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y * N[(z / a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -3.7e+178], t$95$2, If[LessEqual[z, -4.5e+152], t$95$1, If[LessEqual[z, -5e+124], t$95$2, If[LessEqual[z, -1.95e+96], N[(y + x), $MachinePrecision], If[LessEqual[z, -2.85e+76], t$95$1, If[LessEqual[z, 5.6e+59], N[(y + x), $MachinePrecision], t$95$2]]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;z \leq -4.5 \cdot 10^{+152}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;z \leq -5 \cdot 10^{+124}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;z \leq -1.95 \cdot 10^{+96}:\\
\;\;\;\;y + x\\

\mathbf{elif}\;z \leq -2.85 \cdot 10^{+76}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;z \leq 5.6 \cdot 10^{+59}:\\
\;\;\;\;y + x\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -3.7000000000000002e178 or -4.5000000000000001e152 < z < -4.9999999999999996e124 or 5.5999999999999996e59 < z

    1. Initial program 71.5%

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

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

      \[\leadsto x + \color{blue}{\frac{y \cdot z}{a}} \]
    5. Taylor expanded in x around 0 34.5%

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

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

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

    if -3.7000000000000002e178 < z < -4.5000000000000001e152 or -1.95e96 < z < -2.85000000000000002e76

    1. Initial program 83.1%

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

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

      \[\leadsto \color{blue}{x + -1 \cdot \frac{x \cdot z}{a}} \]
    5. Step-by-step derivation
      1. mul-1-neg54.2%

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

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

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

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

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

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

        \[\leadsto \color{blue}{-x \cdot \frac{z}{a}} \]
      3. distribute-rgt-neg-in62.3%

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

        \[\leadsto x \cdot \color{blue}{\frac{-z}{a}} \]
    9. Simplified62.3%

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

    if -4.9999999999999996e124 < z < -1.95e96 or -2.85000000000000002e76 < z < 5.5999999999999996e59

    1. Initial program 73.1%

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

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

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

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

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

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

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

      \[\leadsto x - \color{blue}{-1 \cdot y} \]
    8. Step-by-step derivation
      1. mul-1-neg48.5%

        \[\leadsto x - \color{blue}{\left(-y\right)} \]
    9. Simplified48.5%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3.7 \cdot 10^{+178}:\\ \;\;\;\;y \cdot \frac{z}{a}\\ \mathbf{elif}\;z \leq -4.5 \cdot 10^{+152}:\\ \;\;\;\;x \cdot \frac{z}{-a}\\ \mathbf{elif}\;z \leq -5 \cdot 10^{+124}:\\ \;\;\;\;y \cdot \frac{z}{a}\\ \mathbf{elif}\;z \leq -1.95 \cdot 10^{+96}:\\ \;\;\;\;y + x\\ \mathbf{elif}\;z \leq -2.85 \cdot 10^{+76}:\\ \;\;\;\;x \cdot \frac{z}{-a}\\ \mathbf{elif}\;z \leq 5.6 \cdot 10^{+59}:\\ \;\;\;\;y + x\\ \mathbf{else}:\\ \;\;\;\;y \cdot \frac{z}{a}\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 65.7% accurate, 0.4× speedup?

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

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

\mathbf{elif}\;t \leq -2.2 \cdot 10^{+68} \lor \neg \left(t \leq -1.35 \cdot 10^{+33}\right) \land t \leq 1.9 \cdot 10^{+45}:\\
\;\;\;\;x + z \cdot \frac{y - x}{a}\\

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


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

    1. Initial program 40.7%

      \[x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 68.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}} \]
    4. Step-by-step derivation
      1. associate--l+68.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. distribute-lft-out--68.3%

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

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

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

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

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

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

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

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

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

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

    if -6.2e89 < t < -2.19999999999999987e68 or -1.34999999999999996e33 < t < 1.9000000000000001e45

    1. Initial program 87.6%

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

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

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

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

    if -2.19999999999999987e68 < t < -1.34999999999999996e33 or 1.9000000000000001e45 < t

    1. Initial program 55.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -6.2 \cdot 10^{+89}:\\ \;\;\;\;y + \frac{z \cdot \left(x - y\right)}{t}\\ \mathbf{elif}\;t \leq -2.2 \cdot 10^{+68} \lor \neg \left(t \leq -1.35 \cdot 10^{+33}\right) \land t \leq 1.9 \cdot 10^{+45}:\\ \;\;\;\;x + z \cdot \frac{y - x}{a}\\ \mathbf{else}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \end{array} \]
  5. Add Preprocessing

Alternative 5: 59.9% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := y \cdot \frac{z - t}{a - t}\\ t_2 := x + y \cdot \frac{z}{a}\\ \mathbf{if}\;a \leq -2.6 \cdot 10^{+89}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;a \leq 6.3 \cdot 10^{-59}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;a \leq 5.6 \cdot 10^{+74}:\\ \;\;\;\;x - x \cdot \frac{z}{a}\\ \mathbf{elif}\;a \leq 3.25 \cdot 10^{+128}:\\ \;\;\;\;t\_1\\ \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 (/ z a)))))
   (if (<= a -2.6e+89)
     t_2
     (if (<= a 6.3e-59)
       t_1
       (if (<= a 5.6e+74)
         (- x (* x (/ z a)))
         (if (<= a 3.25e+128) t_1 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 * (z / a));
	double tmp;
	if (a <= -2.6e+89) {
		tmp = t_2;
	} else if (a <= 6.3e-59) {
		tmp = t_1;
	} else if (a <= 5.6e+74) {
		tmp = x - (x * (z / a));
	} else if (a <= 3.25e+128) {
		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 * ((z - t) / (a - t))
    t_2 = x + (y * (z / a))
    if (a <= (-2.6d+89)) then
        tmp = t_2
    else if (a <= 6.3d-59) then
        tmp = t_1
    else if (a <= 5.6d+74) then
        tmp = x - (x * (z / a))
    else if (a <= 3.25d+128) 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 * ((z - t) / (a - t));
	double t_2 = x + (y * (z / a));
	double tmp;
	if (a <= -2.6e+89) {
		tmp = t_2;
	} else if (a <= 6.3e-59) {
		tmp = t_1;
	} else if (a <= 5.6e+74) {
		tmp = x - (x * (z / a));
	} else if (a <= 3.25e+128) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = y * ((z - t) / (a - t))
	t_2 = x + (y * (z / a))
	tmp = 0
	if a <= -2.6e+89:
		tmp = t_2
	elif a <= 6.3e-59:
		tmp = t_1
	elif a <= 5.6e+74:
		tmp = x - (x * (z / a))
	elif a <= 3.25e+128:
		tmp = t_1
	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(z / a)))
	tmp = 0.0
	if (a <= -2.6e+89)
		tmp = t_2;
	elseif (a <= 6.3e-59)
		tmp = t_1;
	elseif (a <= 5.6e+74)
		tmp = Float64(x - Float64(x * Float64(z / a)));
	elseif (a <= 3.25e+128)
		tmp = t_1;
	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 * (z / a));
	tmp = 0.0;
	if (a <= -2.6e+89)
		tmp = t_2;
	elseif (a <= 6.3e-59)
		tmp = t_1;
	elseif (a <= 5.6e+74)
		tmp = x - (x * (z / a));
	elseif (a <= 3.25e+128)
		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[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(y * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -2.6e+89], t$95$2, If[LessEqual[a, 6.3e-59], t$95$1, If[LessEqual[a, 5.6e+74], N[(x - N[(x * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 3.25e+128], t$95$1, t$95$2]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;a \leq 6.3 \cdot 10^{-59}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;a \leq 5.6 \cdot 10^{+74}:\\
\;\;\;\;x - x \cdot \frac{z}{a}\\

\mathbf{elif}\;a \leq 3.25 \cdot 10^{+128}:\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if a < -2.6000000000000001e89 or 3.25000000000000015e128 < a

    1. Initial program 74.9%

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

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

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

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

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

    if -2.6000000000000001e89 < a < 6.3000000000000003e-59 or 5.60000000000000003e74 < a < 3.25000000000000015e128

    1. Initial program 70.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 6.3000000000000003e-59 < a < 5.60000000000000003e74

    1. Initial program 84.1%

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

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

      \[\leadsto \color{blue}{x + -1 \cdot \frac{x \cdot z}{a}} \]
    5. Step-by-step derivation
      1. mul-1-neg64.2%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -2.6 \cdot 10^{+89}:\\ \;\;\;\;x + y \cdot \frac{z}{a}\\ \mathbf{elif}\;a \leq 6.3 \cdot 10^{-59}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;a \leq 5.6 \cdot 10^{+74}:\\ \;\;\;\;x - x \cdot \frac{z}{a}\\ \mathbf{elif}\;a \leq 3.25 \cdot 10^{+128}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{else}:\\ \;\;\;\;x + y \cdot \frac{z}{a}\\ \end{array} \]
  5. Add Preprocessing

Alternative 6: 73.8% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := y - \frac{x}{t} \cdot \left(a - z\right)\\ \mathbf{if}\;t \leq -6.2 \cdot 10^{+90}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t \leq 4.5 \cdot 10^{-177}:\\ \;\;\;\;x + \left(y - x\right) \cdot \frac{z - t}{a}\\ \mathbf{elif}\;t \leq 1.8 \cdot 10^{+45}:\\ \;\;\;\;x + \frac{\left(y - x\right) \cdot z}{a - t}\\ \mathbf{elif}\;t \leq 2.5 \cdot 10^{+158}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \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 -6.2e+90)
     t_1
     (if (<= t 4.5e-177)
       (+ x (* (- y x) (/ (- z t) a)))
       (if (<= t 1.8e+45)
         (+ x (/ (* (- y x) z) (- a t)))
         (if (<= t 2.5e+158) (* y (/ (- z t) (- a t))) 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 <= -6.2e+90) {
		tmp = t_1;
	} else if (t <= 4.5e-177) {
		tmp = x + ((y - x) * ((z - t) / a));
	} else if (t <= 1.8e+45) {
		tmp = x + (((y - x) * z) / (a - t));
	} else if (t <= 2.5e+158) {
		tmp = y * ((z - t) / (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 = y - ((x / t) * (a - z))
    if (t <= (-6.2d+90)) then
        tmp = t_1
    else if (t <= 4.5d-177) then
        tmp = x + ((y - x) * ((z - t) / a))
    else if (t <= 1.8d+45) then
        tmp = x + (((y - x) * z) / (a - t))
    else if (t <= 2.5d+158) then
        tmp = y * ((z - t) / (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 = y - ((x / t) * (a - z));
	double tmp;
	if (t <= -6.2e+90) {
		tmp = t_1;
	} else if (t <= 4.5e-177) {
		tmp = x + ((y - x) * ((z - t) / a));
	} else if (t <= 1.8e+45) {
		tmp = x + (((y - x) * z) / (a - t));
	} else if (t <= 2.5e+158) {
		tmp = y * ((z - t) / (a - t));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = y - ((x / t) * (a - z))
	tmp = 0
	if t <= -6.2e+90:
		tmp = t_1
	elif t <= 4.5e-177:
		tmp = x + ((y - x) * ((z - t) / a))
	elif t <= 1.8e+45:
		tmp = x + (((y - x) * z) / (a - t))
	elif t <= 2.5e+158:
		tmp = y * ((z - t) / (a - t))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(y - Float64(Float64(x / t) * Float64(a - z)))
	tmp = 0.0
	if (t <= -6.2e+90)
		tmp = t_1;
	elseif (t <= 4.5e-177)
		tmp = Float64(x + Float64(Float64(y - x) * Float64(Float64(z - t) / a)));
	elseif (t <= 1.8e+45)
		tmp = Float64(x + Float64(Float64(Float64(y - x) * z) / Float64(a - t)));
	elseif (t <= 2.5e+158)
		tmp = Float64(y * Float64(Float64(z - t) / Float64(a - t)));
	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 <= -6.2e+90)
		tmp = t_1;
	elseif (t <= 4.5e-177)
		tmp = x + ((y - x) * ((z - t) / a));
	elseif (t <= 1.8e+45)
		tmp = x + (((y - x) * z) / (a - t));
	elseif (t <= 2.5e+158)
		tmp = y * ((z - t) / (a - t));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y - N[(N[(x / t), $MachinePrecision] * N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -6.2e+90], t$95$1, If[LessEqual[t, 4.5e-177], N[(x + N[(N[(y - x), $MachinePrecision] * N[(N[(z - t), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.8e+45], N[(x + N[(N[(N[(y - x), $MachinePrecision] * z), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.5e+158], N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}

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

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < -6.19999999999999977e90 or 2.4999999999999998e158 < t

    1. Initial program 37.5%

      \[x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 69.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}} \]
    4. Step-by-step derivation
      1. associate--l+69.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. distribute-lft-out--69.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -6.19999999999999977e90 < t < 4.5000000000000003e-177

    1. Initial program 88.4%

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

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

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

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

    if 4.5000000000000003e-177 < t < 1.8e45

    1. Initial program 86.9%

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

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

    if 1.8e45 < t < 2.4999999999999998e158

    1. Initial program 62.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -6.2 \cdot 10^{+90}:\\ \;\;\;\;y - \frac{x}{t} \cdot \left(a - z\right)\\ \mathbf{elif}\;t \leq 4.5 \cdot 10^{-177}:\\ \;\;\;\;x + \left(y - x\right) \cdot \frac{z - t}{a}\\ \mathbf{elif}\;t \leq 1.8 \cdot 10^{+45}:\\ \;\;\;\;x + \frac{\left(y - x\right) \cdot z}{a - t}\\ \mathbf{elif}\;t \leq 2.5 \cdot 10^{+158}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{else}:\\ \;\;\;\;y - \frac{x}{t} \cdot \left(a - z\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 7: 83.6% accurate, 0.5× speedup?

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

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -2.6999999999999999e93 or 1.09999999999999999e83 < t

    1. Initial program 38.2%

      \[x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 68.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}} \]
    4. Step-by-step derivation
      1. associate--l+68.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. distribute-lft-out--68.8%

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

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

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

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

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

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

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

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

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

    if -2.6999999999999999e93 < t < -2e-160

    1. Initial program 81.1%

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

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

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

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

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

    if -2e-160 < t < 1.09999999999999999e83

    1. Initial program 91.1%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -2.7 \cdot 10^{+93}:\\ \;\;\;\;y + \frac{y - x}{t} \cdot \left(a - z\right)\\ \mathbf{elif}\;t \leq -2 \cdot 10^{-160}:\\ \;\;\;\;x + x \cdot \left(\frac{z - t}{a - t} \cdot \left(-1 + \frac{y}{x}\right)\right)\\ \mathbf{elif}\;t \leq 1.1 \cdot 10^{+83}:\\ \;\;\;\;x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}\\ \mathbf{else}:\\ \;\;\;\;y + \frac{y - x}{t} \cdot \left(a - z\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 8: 44.3% accurate, 0.5× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -9.8 \cdot 10^{+123} \lor \neg \left(z \leq -6.4 \cdot 10^{+95} \lor \neg \left(z \leq -1.2 \cdot 10^{+26}\right) \land z \leq 2.2 \cdot 10^{+52}\right):\\
\;\;\;\;z \cdot \frac{y - x}{a}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -9.79999999999999952e123 or -6.4000000000000001e95 < z < -1.20000000000000002e26 or 2.2e52 < z

    1. Initial program 73.1%

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

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

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

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

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

    if -9.79999999999999952e123 < z < -6.4000000000000001e95 or -1.20000000000000002e26 < z < 2.2e52

    1. Initial program 73.3%

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

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

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

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

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

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

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

      \[\leadsto x - \color{blue}{-1 \cdot y} \]
    8. Step-by-step derivation
      1. mul-1-neg49.8%

        \[\leadsto x - \color{blue}{\left(-y\right)} \]
    9. Simplified49.8%

      \[\leadsto x - \color{blue}{\left(-y\right)} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification51.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -9.8 \cdot 10^{+123} \lor \neg \left(z \leq -6.4 \cdot 10^{+95} \lor \neg \left(z \leq -1.2 \cdot 10^{+26}\right) \land z \leq 2.2 \cdot 10^{+52}\right):\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \mathbf{else}:\\ \;\;\;\;y + x\\ \end{array} \]
  5. Add Preprocessing

Alternative 9: 43.7% accurate, 0.5× speedup?

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

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

\mathbf{elif}\;z \leq -1.32 \cdot 10^{+95}:\\
\;\;\;\;y + x\\

\mathbf{elif}\;z \leq -8.4 \cdot 10^{+68}:\\
\;\;\;\;x \cdot \frac{z}{-a}\\

\mathbf{elif}\;z \leq 2.5 \cdot 10^{+55}:\\
\;\;\;\;y + x\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.9599999999999999e124 or 2.50000000000000023e55 < z

    1. Initial program 72.8%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -1.9599999999999999e124 < z < -1.32e95 or -8.40000000000000003e68 < z < 2.50000000000000023e55

    1. Initial program 73.1%

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

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

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

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

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

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

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

      \[\leadsto x - \color{blue}{-1 \cdot y} \]
    8. Step-by-step derivation
      1. mul-1-neg48.5%

        \[\leadsto x - \color{blue}{\left(-y\right)} \]
    9. Simplified48.5%

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

    if -1.32e95 < z < -8.40000000000000003e68

    1. Initial program 78.5%

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

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

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

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

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

        \[\leadsto x - \color{blue}{x \cdot \frac{z}{a}} \]
    6. Simplified55.2%

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

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

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

        \[\leadsto \color{blue}{-x \cdot \frac{z}{a}} \]
      3. distribute-rgt-neg-in50.3%

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

        \[\leadsto x \cdot \color{blue}{\frac{-z}{a}} \]
    9. Simplified50.3%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.96 \cdot 10^{+124}:\\ \;\;\;\;y \cdot \frac{z}{a - t}\\ \mathbf{elif}\;z \leq -1.32 \cdot 10^{+95}:\\ \;\;\;\;y + x\\ \mathbf{elif}\;z \leq -8.4 \cdot 10^{+68}:\\ \;\;\;\;x \cdot \frac{z}{-a}\\ \mathbf{elif}\;z \leq 2.5 \cdot 10^{+55}:\\ \;\;\;\;y + x\\ \mathbf{else}:\\ \;\;\;\;y \cdot \frac{z}{a - t}\\ \end{array} \]
  5. Add Preprocessing

Alternative 10: 53.4% accurate, 0.5× speedup?

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

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

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

\mathbf{elif}\;t \leq -4.2 \cdot 10^{+91}:\\
\;\;\;\;y\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -8.59999999999999943e181 or -2.39999999999999988e101 < t < -4.20000000000000015e91 or 3.09999999999999975e46 < t

    1. Initial program 43.3%

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

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

    if -8.59999999999999943e181 < t < -2.39999999999999988e101

    1. Initial program 42.1%

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

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

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

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

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

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

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

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

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

    if -4.20000000000000015e91 < t < 3.09999999999999975e46

    1. Initial program 88.1%

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -8.6 \cdot 10^{+181}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq -2.4 \cdot 10^{+101}:\\ \;\;\;\;x \cdot \frac{z - a}{t}\\ \mathbf{elif}\;t \leq -4.2 \cdot 10^{+91}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 3.1 \cdot 10^{+46}:\\ \;\;\;\;x + y \cdot \frac{z}{a}\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]
  5. Add Preprocessing

Alternative 11: 53.5% accurate, 0.5× speedup?

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

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

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

\mathbf{elif}\;t \leq -7.5 \cdot 10^{+89}:\\
\;\;\;\;y\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -7.00000000000000016e181 or -1.38e101 < t < -7.49999999999999947e89 or 2.60000000000000013e46 < t

    1. Initial program 43.3%

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

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

    if -7.00000000000000016e181 < t < -1.38e101

    1. Initial program 42.1%

      \[x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 63.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}} \]
    4. Step-by-step derivation
      1. associate--l+63.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. distribute-lft-out--63.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -7.49999999999999947e89 < t < 2.60000000000000013e46

    1. Initial program 88.1%

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -7 \cdot 10^{+181}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq -1.38 \cdot 10^{+101}:\\ \;\;\;\;z \cdot \frac{x - y}{t}\\ \mathbf{elif}\;t \leq -7.5 \cdot 10^{+89}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 2.6 \cdot 10^{+46}:\\ \;\;\;\;x + y \cdot \frac{z}{a}\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]
  5. Add Preprocessing

Alternative 12: 84.0% accurate, 0.6× speedup?

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -1.4e90 or 9.1999999999999995e81 < t

    1. Initial program 39.0%

      \[x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 69.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}} \]
    4. Step-by-step derivation
      1. associate--l+69.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. distribute-lft-out--69.2%

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

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

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

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

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

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

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

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

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

    if -1.4e90 < t < 9.1999999999999995e81

    1. Initial program 87.6%

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

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

Alternative 13: 72.4% accurate, 0.6× speedup?

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -7.6000000000000002e90 or 4.2e12 < t

    1. Initial program 46.1%

      \[x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 67.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}} \]
    4. Step-by-step derivation
      1. associate--l+67.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. distribute-lft-out--67.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -7.6000000000000002e90 < t < 4.2e12

    1. Initial program 89.2%

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

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

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

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

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

Alternative 14: 75.7% accurate, 0.6× speedup?

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -8.50000000000000045e89 or 3.3e11 < t

    1. Initial program 46.1%

      \[x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 67.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}} \]
    4. Step-by-step derivation
      1. associate--l+67.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. distribute-lft-out--67.4%

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

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

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

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

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

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

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

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

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

    if -8.50000000000000045e89 < t < 3.3e11

    1. Initial program 89.2%

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

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

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

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

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

Alternative 15: 67.1% accurate, 0.7× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -1 \cdot 10^{+33} \lor \neg \left(t \leq 1.18 \cdot 10^{+44}\right):\\
\;\;\;\;y \cdot \frac{z - t}{a - t}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -9.9999999999999995e32 or 1.17999999999999997e44 < t

    1. Initial program 50.8%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -9.9999999999999995e32 < t < 1.17999999999999997e44

    1. Initial program 88.5%

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

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

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

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

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

Alternative 16: 69.2% accurate, 0.7× speedup?

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -6.4999999999999996e89 or 3e11 < t

    1. Initial program 46.1%

      \[x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 67.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}} \]
    4. Step-by-step derivation
      1. associate--l+67.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. distribute-lft-out--67.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -6.4999999999999996e89 < t < 3e11

    1. Initial program 89.2%

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

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

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

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

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

Alternative 17: 39.6% accurate, 0.9× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.35 \cdot 10^{+124} \lor \neg \left(z \leq 8.5 \cdot 10^{+60}\right):\\
\;\;\;\;y \cdot \frac{z}{a}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.34999999999999989e124 or 8.50000000000000064e60 < z

    1. Initial program 72.8%

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

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

      \[\leadsto x + \color{blue}{\frac{y \cdot z}{a}} \]
    5. Taylor expanded in x around 0 33.8%

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

        \[\leadsto \color{blue}{y \cdot \frac{z}{a}} \]
    7. Simplified41.5%

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

    if -1.34999999999999989e124 < z < 8.50000000000000064e60

    1. Initial program 73.4%

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

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

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

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

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

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

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

      \[\leadsto x - \color{blue}{-1 \cdot y} \]
    8. Step-by-step derivation
      1. mul-1-neg46.0%

        \[\leadsto x - \color{blue}{\left(-y\right)} \]
    9. Simplified46.0%

      \[\leadsto x - \color{blue}{\left(-y\right)} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification44.3%

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

Alternative 18: 38.4% accurate, 1.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;a \leq -2.45 \cdot 10^{+89}:\\ \;\;\;\;x\\ \mathbf{elif}\;a \leq 4.5 \cdot 10^{-25}:\\ \;\;\;\;y\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= a -2.45e+89) x (if (<= a 4.5e-25) y x)))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (a <= -2.45e+89) {
		tmp = x;
	} else if (a <= 4.5e-25) {
		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.45d+89)) then
        tmp = x
    else if (a <= 4.5d-25) 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.45e+89) {
		tmp = x;
	} else if (a <= 4.5e-25) {
		tmp = y;
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z, t, a):
	tmp = 0
	if a <= -2.45e+89:
		tmp = x
	elif a <= 4.5e-25:
		tmp = y
	else:
		tmp = x
	return tmp
function code(x, y, z, t, a)
	tmp = 0.0
	if (a <= -2.45e+89)
		tmp = x;
	elseif (a <= 4.5e-25)
		tmp = y;
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	tmp = 0.0;
	if (a <= -2.45e+89)
		tmp = x;
	elseif (a <= 4.5e-25)
		tmp = y;
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -2.45e+89], x, If[LessEqual[a, 4.5e-25], y, x]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;a \leq -2.45 \cdot 10^{+89}:\\
\;\;\;\;x\\

\mathbf{elif}\;a \leq 4.5 \cdot 10^{-25}:\\
\;\;\;\;y\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if a < -2.44999999999999998e89 or 4.5000000000000001e-25 < a

    1. Initial program 73.0%

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

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

    if -2.44999999999999998e89 < a < 4.5000000000000001e-25

    1. Initial program 73.3%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -2.45 \cdot 10^{+89}:\\ \;\;\;\;x\\ \mathbf{elif}\;a \leq 4.5 \cdot 10^{-25}:\\ \;\;\;\;y\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]
  5. Add Preprocessing

Alternative 19: 25.5% accurate, 13.0× speedup?

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

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

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

    \[\leadsto \color{blue}{x} \]
  4. Final simplification26.8%

    \[\leadsto x \]
  5. Add Preprocessing

Developer target: 87.7% accurate, 0.5× 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 2024078 
(FPCore (x y z t a)
  :name "Graphics.Rendering.Chart.Axis.Types:linMap from Chart-1.5.3"
  :precision binary64

  :alt
  (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))))