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

Percentage Accurate: 68.0% → 88.0%
Time: 16.3s
Alternatives: 18
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 18 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.0% 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: 88.0% accurate, 0.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -4.9 \cdot 10^{+119} \lor \neg \left(t \leq 3.8 \cdot 10^{+264}\right):\\ \;\;\;\;y + \frac{-1}{\frac{\frac{t}{y - x}}{z - a}}\\ \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 -4.9e+119) (not (<= t 3.8e+264)))
   (+ y (/ -1.0 (/ (/ t (- y x)) (- z a))))
   (fma (- y x) (/ (- z t) (- a t)) x)))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if ((t <= -4.9e+119) || !(t <= 3.8e+264)) {
		tmp = y + (-1.0 / ((t / (y - x)) / (z - a)));
	} else {
		tmp = fma((y - x), ((z - t) / (a - t)), x);
	}
	return tmp;
}
function code(x, y, z, t, a)
	tmp = 0.0
	if ((t <= -4.9e+119) || !(t <= 3.8e+264))
		tmp = Float64(y + Float64(-1.0 / Float64(Float64(t / Float64(y - x)) / Float64(z - a))));
	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, -4.9e+119], N[Not[LessEqual[t, 3.8e+264]], $MachinePrecision]], N[(y + N[(-1.0 / N[(N[(t / N[(y - x), $MachinePrecision]), $MachinePrecision] / N[(z - a), $MachinePrecision]), $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 -4.9 \cdot 10^{+119} \lor \neg \left(t \leq 3.8 \cdot 10^{+264}\right):\\
\;\;\;\;y + \frac{-1}{\frac{\frac{t}{y - x}}{z - a}}\\

\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 < -4.89999999999999996e119 or 3.8000000000000001e264 < t

    1. Initial program 37.0%

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{fma}\left(y - x, \frac{z - t}{a - t}, x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in t around inf 75.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}} \]
    6. Step-by-step derivation
      1. associate--l+75.8%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto y - \frac{1}{\color{blue}{\frac{\frac{t}{y - x}}{z - a}}} \]
    11. Simplified92.4%

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

    if -4.89999999999999996e119 < t < 3.8000000000000001e264

    1. Initial program 82.7%

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

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

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

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

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

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

Alternative 2: 58.7% accurate, 0.5× speedup?

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

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

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

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

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


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

    1. Initial program 45.2%

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

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

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

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

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

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

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

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

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

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

    if -1.1600000000000001e107 < t < 2.39999999999999985e-30

    1. Initial program 91.2%

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

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

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

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

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

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

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

    if 2.39999999999999985e-30 < t < 7.10000000000000004e83

    1. Initial program 80.1%

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{fma}\left(y - x, \frac{z - t}{a - t}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. clear-num84.3%

        \[\leadsto \mathsf{fma}\left(y - x, \color{blue}{\frac{1}{\frac{a - t}{z - t}}}, x\right) \]
      2. associate-/r/84.4%

        \[\leadsto \mathsf{fma}\left(y - x, \color{blue}{\frac{1}{a - t} \cdot \left(z - t\right)}, x\right) \]
    6. Applied egg-rr84.4%

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

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

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

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

    if 7.10000000000000004e83 < t

    1. Initial program 36.4%

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

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

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

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

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

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

        \[\leadsto y \cdot \color{blue}{\frac{z - t}{a - t}} \]
      2. *-un-lft-identity75.4%

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -1.16 \cdot 10^{+107}:\\ \;\;\;\;y \cdot \left(1 - \frac{z}{t}\right)\\ \mathbf{elif}\;t \leq 2.4 \cdot 10^{-30}:\\ \;\;\;\;x + y \cdot \frac{z - t}{a}\\ \mathbf{elif}\;t \leq 7.1 \cdot 10^{+83}:\\ \;\;\;\;z \cdot \frac{y - x}{a - t}\\ \mathbf{else}:\\ \;\;\;\;y \cdot \frac{t}{t - a}\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 56.7% accurate, 0.5× speedup?

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

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

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

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

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


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

    1. Initial program 50.8%

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

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

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

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

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

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

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

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

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

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

    if -1.05e52 < t < 3.6999999999999998e-31

    1. Initial program 92.6%

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

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

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

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

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

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

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

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

        \[\leadsto x + \color{blue}{y \cdot \frac{z}{a}} \]
    11. Simplified68.0%

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

    if 3.6999999999999998e-31 < t < 7.8000000000000003e83

    1. Initial program 80.1%

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{fma}\left(y - x, \frac{z - t}{a - t}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. clear-num84.3%

        \[\leadsto \mathsf{fma}\left(y - x, \color{blue}{\frac{1}{\frac{a - t}{z - t}}}, x\right) \]
      2. associate-/r/84.4%

        \[\leadsto \mathsf{fma}\left(y - x, \color{blue}{\frac{1}{a - t} \cdot \left(z - t\right)}, x\right) \]
    6. Applied egg-rr84.4%

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

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

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

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

    if 7.8000000000000003e83 < t

    1. Initial program 36.4%

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

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

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

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

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

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

        \[\leadsto y \cdot \color{blue}{\frac{z - t}{a - t}} \]
      2. *-un-lft-identity75.4%

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

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

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

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

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

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

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

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

Alternative 4: 83.6% accurate, 0.6× speedup?

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

\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 < -5.1000000000000002e103 or 1.3500000000000001e117 < t

    1. Initial program 38.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -5.1000000000000002e103 < t < 1.3500000000000001e117

    1. Initial program 89.9%

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

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

Alternative 5: 78.1% accurate, 0.6× speedup?

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

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

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

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


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

    1. Initial program 43.8%

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{fma}\left(y - x, \frac{z - t}{a - t}, x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in t around inf 79.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}} \]
    6. Step-by-step derivation
      1. associate--l+79.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -3.20000000000000008e145 < t < 2.99999999999999989e82

    1. Initial program 88.5%

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

    if 2.99999999999999989e82 < t

    1. Initial program 37.7%

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

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

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

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

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

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

        \[\leadsto y \cdot \color{blue}{\frac{z - t}{a - t}} \]
      2. *-un-lft-identity75.9%

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

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

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

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

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

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{a - t}{z - t}}} \]
    9. Applied egg-rr75.9%

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

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

Alternative 6: 73.0% accurate, 0.6× speedup?

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if a < -3.8000000000000001e-104 or 8.1999999999999997e-19 < a

    1. Initial program 77.5%

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

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

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

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

    if -3.8000000000000001e-104 < a < 8.1999999999999997e-19

    1. Initial program 68.2%

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{fma}\left(y - x, \frac{z - t}{a - t}, x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in t around inf 79.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}} \]
    6. Step-by-step derivation
      1. associate--l+79.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 7: 73.1% accurate, 0.6× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if a < -1.5500000000000001e-103

    1. Initial program 81.6%

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

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

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

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

    if -1.5500000000000001e-103 < a < 1.35000000000000008e-25

    1. Initial program 67.9%

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{fma}\left(y - x, \frac{z - t}{a - t}, x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in t around inf 78.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}} \]
    6. Step-by-step derivation
      1. associate--l+78.8%

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

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

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

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

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

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

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

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

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

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

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

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

    if 1.35000000000000008e-25 < a

    1. Initial program 72.0%

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

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

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

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

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

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

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

Alternative 8: 73.5% accurate, 0.6× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if a < -3.15e-105

    1. Initial program 81.6%

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

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

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

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

    if -3.15e-105 < a < 3.49999999999999985e-26

    1. Initial program 67.9%

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{fma}\left(y - x, \frac{z - t}{a - t}, x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in t around inf 78.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}} \]
    6. Step-by-step derivation
      1. associate--l+78.8%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 3.49999999999999985e-26 < a

    1. Initial program 72.0%

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

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

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

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

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

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

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

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

Alternative 9: 69.3% accurate, 0.6× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -1500000:\\
\;\;\;\;y + z \cdot \frac{x - y}{t}\\

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

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


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

    1. Initial program 50.0%

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{fma}\left(y - x, \frac{z - t}{a - t}, x\right)} \]
    4. Add Preprocessing
    5. 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}} \]
    6. 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. associate-*r/68.8%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -1.5e6 < t < 3.9999999999999997e45

    1. Initial program 92.8%

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

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

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

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

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

    if 3.9999999999999997e45 < t

    1. Initial program 44.0%

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

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

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

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

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

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

        \[\leadsto y \cdot \color{blue}{\frac{z - t}{a - t}} \]
      2. *-un-lft-identity73.9%

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

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

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

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

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

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{a - t}{z - t}}} \]
    9. Applied egg-rr73.9%

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

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

Alternative 10: 69.3% accurate, 0.6× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -80000000000000:\\
\;\;\;\;y + z \cdot \frac{x - y}{t}\\

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

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


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

    1. Initial program 50.0%

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{fma}\left(y - x, \frac{z - t}{a - t}, x\right)} \]
    4. Add Preprocessing
    5. 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}} \]
    6. 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. associate-*r/68.8%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -8e13 < t < 2.3000000000000002e43

    1. Initial program 92.8%

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

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

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

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

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

    if 2.3000000000000002e43 < t

    1. Initial program 44.0%

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

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

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

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

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

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

        \[\leadsto y \cdot \color{blue}{\frac{z - t}{a - t}} \]
      2. *-un-lft-identity73.9%

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

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

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

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

Alternative 11: 71.4% accurate, 0.7× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -100000000000 \lor \neg \left(t \leq 4.5 \cdot 10^{-17}\right):\\
\;\;\;\;y + z \cdot \frac{x - y}{t}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -1e11 or 4.49999999999999978e-17 < t

    1. Initial program 49.6%

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{fma}\left(y - x, \frac{z - t}{a - t}, x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in t around inf 64.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}} \]
    6. Step-by-step derivation
      1. associate--l+64.8%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -1e11 < t < 4.49999999999999978e-17

    1. Initial program 94.4%

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

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

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

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

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

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

Alternative 12: 64.1% accurate, 0.7× speedup?

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -5.9999999999999998e54 or 2.74999999999999998e82 < t

    1. Initial program 44.3%

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

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

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

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

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

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

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

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

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

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

    if -5.9999999999999998e54 < t < 2.74999999999999998e82

    1. Initial program 90.9%

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

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

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

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

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

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

Alternative 13: 63.1% accurate, 0.7× speedup?

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -3.20000000000000029e57 or 2.29999999999999988e82 < t

    1. Initial program 44.3%

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

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

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

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

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

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

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

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

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

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

    if -3.20000000000000029e57 < t < 2.29999999999999988e82

    1. Initial program 90.9%

      \[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. Step-by-step derivation
      1. associate-/l*70.4%

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

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

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

Alternative 14: 64.5% accurate, 0.7× speedup?

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

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

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

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


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

    1. Initial program 48.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto y + \color{blue}{a \cdot \frac{y - x}{t}} \]
    10. Simplified70.1%

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

    if -8.60000000000000008e80 < t < 2.45e82

    1. Initial program 91.0%

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

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

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

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

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

    if 2.45e82 < t

    1. Initial program 37.7%

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

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

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

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

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

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

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

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

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

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

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

Alternative 15: 56.7% accurate, 0.8× speedup?

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -1.5000000000000001e58 or 2.1e82 < t

    1. Initial program 44.3%

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

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

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

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

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

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

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

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

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

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

    if -1.5000000000000001e58 < t < 2.1e82

    1. Initial program 90.9%

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

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

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

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

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

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

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

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

        \[\leadsto x + \color{blue}{y \cdot \frac{z}{a}} \]
    11. Simplified65.5%

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

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

Alternative 16: 54.0% accurate, 0.8× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -6.80000000000000038e113 or 2.5999999999999998e82 < t

    1. Initial program 41.0%

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{fma}\left(y - x, \frac{z - t}{a - t}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. clear-num70.4%

        \[\leadsto \mathsf{fma}\left(y - x, \color{blue}{\frac{1}{\frac{a - t}{z - t}}}, x\right) \]
      2. associate-/r/70.5%

        \[\leadsto \mathsf{fma}\left(y - x, \color{blue}{\frac{1}{a - t} \cdot \left(z - t\right)}, x\right) \]
    6. Applied egg-rr70.5%

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

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

    if -6.80000000000000038e113 < t < 2.5999999999999998e82

    1. Initial program 89.8%

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

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

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

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

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

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

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

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

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

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

Alternative 17: 38.9% accurate, 1.2× speedup?

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

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

\mathbf{elif}\;t \leq 4.2 \cdot 10^{+59}:\\
\;\;\;\;x\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -6.7999999999999997e72 or 4.19999999999999968e59 < t

    1. Initial program 45.0%

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{fma}\left(y - x, \frac{z - t}{a - t}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. clear-num72.4%

        \[\leadsto \mathsf{fma}\left(y - x, \color{blue}{\frac{1}{\frac{a - t}{z - t}}}, x\right) \]
      2. associate-/r/72.4%

        \[\leadsto \mathsf{fma}\left(y - x, \color{blue}{\frac{1}{a - t} \cdot \left(z - t\right)}, x\right) \]
    6. Applied egg-rr72.4%

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

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

    if -6.7999999999999997e72 < t < 4.19999999999999968e59

    1. Initial program 91.4%

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

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

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

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

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

      \[\leadsto \color{blue}{x} \]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 18: 25.2% 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.8%

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

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

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

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

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

    \[\leadsto \color{blue}{x} \]
  6. Add Preprocessing

Developer Target 1: 86.6% 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 2024157 
(FPCore (x y z t a)
  :name "Graphics.Rendering.Chart.Axis.Types:linMap from Chart-1.5.3"
  :precision binary64

  :alt
  (! :herbie-platform default (if (< a -646122513817703/4000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (+ x (* (/ (- y x) 1) (/ (- z t) (- a t)))) (if (< a 1887201585041587/50000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (- y (* (/ z t) (- y x))) (+ x (* (/ (- y x) 1) (/ (- z t) (- a t)))))))

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