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

Percentage Accurate: 68.9% → 85.9%
Time: 16.8s
Alternatives: 26
Speedup: 0.6×

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

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

Initial Program: 68.9% accurate, 1.0× speedup?

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

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

Alternative 1: 85.9% accurate, 0.4× speedup?

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

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

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

\mathbf{elif}\;t \leq -3.2 \cdot 10^{+120} \lor \neg \left(t \leq 1.35 \cdot 10^{+138}\right):\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -1.75e258 or -1.05e186 < t < -3.19999999999999982e120 or 1.35000000000000004e138 < t

    1. Initial program 21.4%

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

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

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

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

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

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

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

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

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

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

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

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

    if -1.75e258 < t < -1.05e186

    1. Initial program 44.9%

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

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

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

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

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

    if -3.19999999999999982e120 < t < 1.35000000000000004e138

    1. Initial program 83.1%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr91.2%

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

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

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

        \[\leadsto x + \color{blue}{\frac{1 \cdot \left(z - t\right)}{\frac{\sqrt[3]{a - t}}{y - x} \cdot {\left(\sqrt[3]{a - t}\right)}^{2}}} \]
      4. *-un-lft-identity89.4%

        \[\leadsto x + \frac{\color{blue}{z - t}}{\frac{\sqrt[3]{a - t}}{y - x} \cdot {\left(\sqrt[3]{a - t}\right)}^{2}} \]
    6. Applied egg-rr89.4%

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -1.75 \cdot 10^{+258}:\\ \;\;\;\;y + \left(z - a\right) \cdot \frac{x - y}{t}\\ \mathbf{elif}\;t \leq -1.05 \cdot 10^{+186}:\\ \;\;\;\;x + \left(z - t\right) \cdot \left(\left(y - x\right) \cdot \frac{-1}{t - a}\right)\\ \mathbf{elif}\;t \leq -3.2 \cdot 10^{+120} \lor \neg \left(t \leq 1.35 \cdot 10^{+138}\right):\\ \;\;\;\;y + \left(z - a\right) \cdot \frac{x - y}{t}\\ \mathbf{else}:\\ \;\;\;\;x - \frac{z - t}{\frac{a - t}{x - y}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 90.5% accurate, 0.0× speedup?

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

\\
\begin{array}{l}
t_1 := x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}\\
t_2 := \sqrt[3]{a - t}\\
\mathbf{if}\;t\_1 \leq -2 \cdot 10^{-253}:\\
\;\;\;\;\mathsf{fma}\left(y - x, \frac{z - t}{a - t}, x\right)\\

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

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


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

    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*89.0%

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

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

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

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

    1. Initial program 4.7%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr5.2%

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

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

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

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

        \[\leadsto y + \left(\frac{-1 \cdot \left(z \cdot \left(y - x\right)\right)}{t} - \color{blue}{\frac{-1 \cdot \left(a \cdot \left(y - x\right)\right)}{t}}\right) \]
      4. mul-1-neg99.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-sub99.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-neg99.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--99.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/99.8%

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

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

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

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

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

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

    1. Initial program 72.3%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr87.6%

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

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

Alternative 3: 88.2% accurate, 0.1× speedup?

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

\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 < -2.4e258 or 2.45000000000000016e131 < t

    1. Initial program 16.3%

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

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

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

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

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

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

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

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

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

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

    if -2.4e258 < t < 2.45000000000000016e131

    1. Initial program 77.0%

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

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

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

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

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

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

Alternative 4: 85.9% accurate, 0.2× speedup?

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

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

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

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

\mathbf{elif}\;t\_2 \leq 5 \cdot 10^{+306}:\\
\;\;\;\;t\_2\\

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


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

    1. Initial program 39.0%

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

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

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

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

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

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

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

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

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

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

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

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

    if -inf.0 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < -2.0000000000000001e-253 or 9.9999999999999998e-201 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < 4.99999999999999993e306

    1. Initial program 98.4%

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

    if -2.0000000000000001e-253 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < 9.9999999999999998e-201

    1. Initial program 4.8%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr10.0%

      \[\leadsto x + \color{blue}{\frac{z - t}{{\left(\sqrt[3]{a - t}\right)}^{2}} \cdot \frac{y - x}{\sqrt[3]{a - t}}} \]
    5. Taylor expanded in t around inf 95.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+95.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/95.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/95.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-neg95.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-sub95.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-neg95.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--95.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/95.8%

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

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

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

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

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

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

Alternative 5: 76.4% accurate, 0.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x + y \cdot \frac{z - t}{a - t}\\ t_2 := y + \left(z - a\right) \cdot \frac{x - y}{t}\\ \mathbf{if}\;t \leq -1.9 \cdot 10^{+258}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;t \leq -1.7 \cdot 10^{+186}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t \leq -3.5 \cdot 10^{+77}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;t \leq 6.8 \cdot 10^{-84}:\\ \;\;\;\;x - z \cdot \frac{y - x}{t - a}\\ \mathbf{elif}\;t \leq 160 \lor \neg \left(t \leq 1.1 \cdot 10^{+134}\right):\\ \;\;\;\;t\_2\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (+ x (* y (/ (- z t) (- a t)))))
        (t_2 (+ y (* (- z a) (/ (- x y) t)))))
   (if (<= t -1.9e+258)
     t_2
     (if (<= t -1.7e+186)
       t_1
       (if (<= t -3.5e+77)
         t_2
         (if (<= t 6.8e-84)
           (- x (* z (/ (- y x) (- t a))))
           (if (or (<= t 160.0) (not (<= t 1.1e+134))) t_2 t_1)))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = x + (y * ((z - t) / (a - t)));
	double t_2 = y + ((z - a) * ((x - y) / t));
	double tmp;
	if (t <= -1.9e+258) {
		tmp = t_2;
	} else if (t <= -1.7e+186) {
		tmp = t_1;
	} else if (t <= -3.5e+77) {
		tmp = t_2;
	} else if (t <= 6.8e-84) {
		tmp = x - (z * ((y - x) / (t - a)));
	} else if ((t <= 160.0) || !(t <= 1.1e+134)) {
		tmp = t_2;
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = x + (y * ((z - t) / (a - t)))
    t_2 = y + ((z - a) * ((x - y) / t))
    if (t <= (-1.9d+258)) then
        tmp = t_2
    else if (t <= (-1.7d+186)) then
        tmp = t_1
    else if (t <= (-3.5d+77)) then
        tmp = t_2
    else if (t <= 6.8d-84) then
        tmp = x - (z * ((y - x) / (t - a)))
    else if ((t <= 160.0d0) .or. (.not. (t <= 1.1d+134))) then
        tmp = t_2
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = x + (y * ((z - t) / (a - t)));
	double t_2 = y + ((z - a) * ((x - y) / t));
	double tmp;
	if (t <= -1.9e+258) {
		tmp = t_2;
	} else if (t <= -1.7e+186) {
		tmp = t_1;
	} else if (t <= -3.5e+77) {
		tmp = t_2;
	} else if (t <= 6.8e-84) {
		tmp = x - (z * ((y - x) / (t - a)));
	} else if ((t <= 160.0) || !(t <= 1.1e+134)) {
		tmp = t_2;
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = x + (y * ((z - t) / (a - t)))
	t_2 = y + ((z - a) * ((x - y) / t))
	tmp = 0
	if t <= -1.9e+258:
		tmp = t_2
	elif t <= -1.7e+186:
		tmp = t_1
	elif t <= -3.5e+77:
		tmp = t_2
	elif t <= 6.8e-84:
		tmp = x - (z * ((y - x) / (t - a)))
	elif (t <= 160.0) or not (t <= 1.1e+134):
		tmp = t_2
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(x + Float64(y * Float64(Float64(z - t) / Float64(a - t))))
	t_2 = Float64(y + Float64(Float64(z - a) * Float64(Float64(x - y) / t)))
	tmp = 0.0
	if (t <= -1.9e+258)
		tmp = t_2;
	elseif (t <= -1.7e+186)
		tmp = t_1;
	elseif (t <= -3.5e+77)
		tmp = t_2;
	elseif (t <= 6.8e-84)
		tmp = Float64(x - Float64(z * Float64(Float64(y - x) / Float64(t - a))));
	elseif ((t <= 160.0) || !(t <= 1.1e+134))
		tmp = t_2;
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = x + (y * ((z - t) / (a - t)));
	t_2 = y + ((z - a) * ((x - y) / t));
	tmp = 0.0;
	if (t <= -1.9e+258)
		tmp = t_2;
	elseif (t <= -1.7e+186)
		tmp = t_1;
	elseif (t <= -3.5e+77)
		tmp = t_2;
	elseif (t <= 6.8e-84)
		tmp = x - (z * ((y - x) / (t - a)));
	elseif ((t <= 160.0) || ~((t <= 1.1e+134)))
		tmp = t_2;
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(y * N[(N[(z - t), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y + N[(N[(z - a), $MachinePrecision] * N[(N[(x - y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1.9e+258], t$95$2, If[LessEqual[t, -1.7e+186], t$95$1, If[LessEqual[t, -3.5e+77], t$95$2, If[LessEqual[t, 6.8e-84], N[(x - N[(z * N[(N[(y - x), $MachinePrecision] / N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[t, 160.0], N[Not[LessEqual[t, 1.1e+134]], $MachinePrecision]], t$95$2, t$95$1]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;t \leq -1.7 \cdot 10^{+186}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t \leq -3.5 \cdot 10^{+77}:\\
\;\;\;\;t\_2\\

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

\mathbf{elif}\;t \leq 160 \lor \neg \left(t \leq 1.1 \cdot 10^{+134}\right):\\
\;\;\;\;t\_2\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -1.90000000000000004e258 or -1.70000000000000003e186 < t < -3.5000000000000001e77 or 6.80000000000000042e-84 < t < 160 or 1.1e134 < t

    1. Initial program 34.9%

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

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

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

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

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

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

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

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

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

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

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

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

    if -1.90000000000000004e258 < t < -1.70000000000000003e186 or 160 < t < 1.1e134

    1. Initial program 56.8%

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

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

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

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

    if -3.5000000000000001e77 < t < 6.80000000000000042e-84

    1. Initial program 89.3%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -1.9 \cdot 10^{+258}:\\ \;\;\;\;y + \left(z - a\right) \cdot \frac{x - y}{t}\\ \mathbf{elif}\;t \leq -1.7 \cdot 10^{+186}:\\ \;\;\;\;x + y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;t \leq -3.5 \cdot 10^{+77}:\\ \;\;\;\;y + \left(z - a\right) \cdot \frac{x - y}{t}\\ \mathbf{elif}\;t \leq 6.8 \cdot 10^{-84}:\\ \;\;\;\;x - z \cdot \frac{y - x}{t - a}\\ \mathbf{elif}\;t \leq 160 \lor \neg \left(t \leq 1.1 \cdot 10^{+134}\right):\\ \;\;\;\;y + \left(z - a\right) \cdot \frac{x - y}{t}\\ \mathbf{else}:\\ \;\;\;\;x + y \cdot \frac{z - t}{a - t}\\ \end{array} \]
  5. Add Preprocessing

Alternative 6: 75.9% accurate, 0.3× speedup?

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

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

\mathbf{elif}\;t \leq -7 \cdot 10^{+183}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t \leq -7.4 \cdot 10^{+77}:\\
\;\;\;\;t\_2\\

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

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

\mathbf{elif}\;t \leq 1.1 \cdot 10^{+137}:\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < -4.00000000000000023e258 or -6.99999999999999974e183 < t < -7.3999999999999999e77 or 1.10000000000000008e137 < t

    1. Initial program 23.9%

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

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

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

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

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

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

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

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

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

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

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

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

    if -4.00000000000000023e258 < t < -6.99999999999999974e183 or 6.9999999999999994e66 < t < 1.10000000000000008e137

    1. Initial program 50.1%

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

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

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

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

    if -7.3999999999999999e77 < t < 6.80000000000000042e-84

    1. Initial program 89.3%

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

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

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

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

    if 6.80000000000000042e-84 < t < 6.9999999999999994e66

    1. Initial program 78.7%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr75.9%

      \[\leadsto x + \color{blue}{\frac{z - t}{{\left(\sqrt[3]{a - t}\right)}^{2}} \cdot \frac{y - x}{\sqrt[3]{a - t}}} \]
    5. Taylor expanded in t around inf 78.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+78.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/78.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/78.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-neg78.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-sub78.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-neg78.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--78.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/78.9%

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -4 \cdot 10^{+258}:\\ \;\;\;\;y + \left(z - a\right) \cdot \frac{x - y}{t}\\ \mathbf{elif}\;t \leq -7 \cdot 10^{+183}:\\ \;\;\;\;x + y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;t \leq -7.4 \cdot 10^{+77}:\\ \;\;\;\;y + \left(z - a\right) \cdot \frac{x - y}{t}\\ \mathbf{elif}\;t \leq 6.8 \cdot 10^{-84}:\\ \;\;\;\;x - z \cdot \frac{y - x}{t - a}\\ \mathbf{elif}\;t \leq 7 \cdot 10^{+66}:\\ \;\;\;\;y + \frac{\left(y - x\right) \cdot \left(a - z\right)}{t}\\ \mathbf{elif}\;t \leq 1.1 \cdot 10^{+137}:\\ \;\;\;\;x + y \cdot \frac{z - t}{a - t}\\ \mathbf{else}:\\ \;\;\;\;y + \left(z - a\right) \cdot \frac{x - y}{t}\\ \end{array} \]
  5. Add Preprocessing

Alternative 7: 50.3% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x + y \cdot \frac{z}{a}\\ \mathbf{if}\;t \leq -3 \cdot 10^{+77}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq -6.4 \cdot 10^{-291}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t \leq 1.95 \cdot 10^{-205}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \mathbf{elif}\;t \leq 1.75 \cdot 10^{-45}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t \leq 2.6 \cdot 10^{+59}:\\ \;\;\;\;y \cdot \frac{z}{a - t}\\ \mathbf{elif}\;t \leq 5.8 \cdot 10^{+125}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (+ x (* y (/ z a)))))
   (if (<= t -3e+77)
     y
     (if (<= t -6.4e-291)
       t_1
       (if (<= t 1.95e-205)
         (* z (/ (- y x) a))
         (if (<= t 1.75e-45)
           t_1
           (if (<= t 2.6e+59)
             (* y (/ z (- a t)))
             (if (<= t 5.8e+125) t_1 y))))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = x + (y * (z / a));
	double tmp;
	if (t <= -3e+77) {
		tmp = y;
	} else if (t <= -6.4e-291) {
		tmp = t_1;
	} else if (t <= 1.95e-205) {
		tmp = z * ((y - x) / a);
	} else if (t <= 1.75e-45) {
		tmp = t_1;
	} else if (t <= 2.6e+59) {
		tmp = y * (z / (a - t));
	} else if (t <= 5.8e+125) {
		tmp = t_1;
	} 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) :: t_1
    real(8) :: tmp
    t_1 = x + (y * (z / a))
    if (t <= (-3d+77)) then
        tmp = y
    else if (t <= (-6.4d-291)) then
        tmp = t_1
    else if (t <= 1.95d-205) then
        tmp = z * ((y - x) / a)
    else if (t <= 1.75d-45) then
        tmp = t_1
    else if (t <= 2.6d+59) then
        tmp = y * (z / (a - t))
    else if (t <= 5.8d+125) then
        tmp = t_1
    else
        tmp = y
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = x + (y * (z / a));
	double tmp;
	if (t <= -3e+77) {
		tmp = y;
	} else if (t <= -6.4e-291) {
		tmp = t_1;
	} else if (t <= 1.95e-205) {
		tmp = z * ((y - x) / a);
	} else if (t <= 1.75e-45) {
		tmp = t_1;
	} else if (t <= 2.6e+59) {
		tmp = y * (z / (a - t));
	} else if (t <= 5.8e+125) {
		tmp = t_1;
	} else {
		tmp = y;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = x + (y * (z / a))
	tmp = 0
	if t <= -3e+77:
		tmp = y
	elif t <= -6.4e-291:
		tmp = t_1
	elif t <= 1.95e-205:
		tmp = z * ((y - x) / a)
	elif t <= 1.75e-45:
		tmp = t_1
	elif t <= 2.6e+59:
		tmp = y * (z / (a - t))
	elif t <= 5.8e+125:
		tmp = t_1
	else:
		tmp = y
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(x + Float64(y * Float64(z / a)))
	tmp = 0.0
	if (t <= -3e+77)
		tmp = y;
	elseif (t <= -6.4e-291)
		tmp = t_1;
	elseif (t <= 1.95e-205)
		tmp = Float64(z * Float64(Float64(y - x) / a));
	elseif (t <= 1.75e-45)
		tmp = t_1;
	elseif (t <= 2.6e+59)
		tmp = Float64(y * Float64(z / Float64(a - t)));
	elseif (t <= 5.8e+125)
		tmp = t_1;
	else
		tmp = y;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = x + (y * (z / a));
	tmp = 0.0;
	if (t <= -3e+77)
		tmp = y;
	elseif (t <= -6.4e-291)
		tmp = t_1;
	elseif (t <= 1.95e-205)
		tmp = z * ((y - x) / a);
	elseif (t <= 1.75e-45)
		tmp = t_1;
	elseif (t <= 2.6e+59)
		tmp = y * (z / (a - t));
	elseif (t <= 5.8e+125)
		tmp = t_1;
	else
		tmp = y;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(y * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -3e+77], y, If[LessEqual[t, -6.4e-291], t$95$1, If[LessEqual[t, 1.95e-205], N[(z * N[(N[(y - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.75e-45], t$95$1, If[LessEqual[t, 2.6e+59], N[(y * N[(z / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 5.8e+125], t$95$1, y]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;t \leq -6.4 \cdot 10^{-291}:\\
\;\;\;\;t\_1\\

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

\mathbf{elif}\;t \leq 1.75 \cdot 10^{-45}:\\
\;\;\;\;t\_1\\

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

\mathbf{elif}\;t \leq 5.8 \cdot 10^{+125}:\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < -2.9999999999999998e77 or 5.79999999999999986e125 < t

    1. Initial program 28.9%

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

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

    if -2.9999999999999998e77 < t < -6.4000000000000003e-291 or 1.95000000000000009e-205 < t < 1.75e-45 or 2.59999999999999999e59 < t < 5.79999999999999986e125

    1. Initial program 82.4%

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

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

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

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

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

    if -6.4000000000000003e-291 < t < 1.95000000000000009e-205

    1. Initial program 89.3%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr99.3%

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

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

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

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

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

    if 1.75e-45 < t < 2.59999999999999999e59

    1. Initial program 81.5%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr78.4%

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -3 \cdot 10^{+77}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq -6.4 \cdot 10^{-291}:\\ \;\;\;\;x + y \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq 1.95 \cdot 10^{-205}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \mathbf{elif}\;t \leq 1.75 \cdot 10^{-45}:\\ \;\;\;\;x + y \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq 2.6 \cdot 10^{+59}:\\ \;\;\;\;y \cdot \frac{z}{a - t}\\ \mathbf{elif}\;t \leq 5.8 \cdot 10^{+125}:\\ \;\;\;\;x + y \cdot \frac{z}{a}\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]
  5. Add Preprocessing

Alternative 8: 50.2% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x + y \cdot \frac{z}{a}\\ \mathbf{if}\;t \leq -8.5 \cdot 10^{+77}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq -1.15 \cdot 10^{-290}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t \leq 4.3 \cdot 10^{-206}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \mathbf{elif}\;t \leq 2.65 \cdot 10^{-45}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t \leq 1.8 \cdot 10^{+62}:\\ \;\;\;\;y \cdot \frac{z}{a - t}\\ \mathbf{elif}\;t \leq 4 \cdot 10^{+126}:\\ \;\;\;\;x + \frac{y \cdot z}{a}\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (+ x (* y (/ z a)))))
   (if (<= t -8.5e+77)
     y
     (if (<= t -1.15e-290)
       t_1
       (if (<= t 4.3e-206)
         (* z (/ (- y x) a))
         (if (<= t 2.65e-45)
           t_1
           (if (<= t 1.8e+62)
             (* y (/ z (- a t)))
             (if (<= t 4e+126) (+ x (/ (* y z) a)) y))))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = x + (y * (z / a));
	double tmp;
	if (t <= -8.5e+77) {
		tmp = y;
	} else if (t <= -1.15e-290) {
		tmp = t_1;
	} else if (t <= 4.3e-206) {
		tmp = z * ((y - x) / a);
	} else if (t <= 2.65e-45) {
		tmp = t_1;
	} else if (t <= 1.8e+62) {
		tmp = y * (z / (a - t));
	} else if (t <= 4e+126) {
		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) :: t_1
    real(8) :: tmp
    t_1 = x + (y * (z / a))
    if (t <= (-8.5d+77)) then
        tmp = y
    else if (t <= (-1.15d-290)) then
        tmp = t_1
    else if (t <= 4.3d-206) then
        tmp = z * ((y - x) / a)
    else if (t <= 2.65d-45) then
        tmp = t_1
    else if (t <= 1.8d+62) then
        tmp = y * (z / (a - t))
    else if (t <= 4d+126) 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 t_1 = x + (y * (z / a));
	double tmp;
	if (t <= -8.5e+77) {
		tmp = y;
	} else if (t <= -1.15e-290) {
		tmp = t_1;
	} else if (t <= 4.3e-206) {
		tmp = z * ((y - x) / a);
	} else if (t <= 2.65e-45) {
		tmp = t_1;
	} else if (t <= 1.8e+62) {
		tmp = y * (z / (a - t));
	} else if (t <= 4e+126) {
		tmp = x + ((y * z) / a);
	} else {
		tmp = y;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = x + (y * (z / a))
	tmp = 0
	if t <= -8.5e+77:
		tmp = y
	elif t <= -1.15e-290:
		tmp = t_1
	elif t <= 4.3e-206:
		tmp = z * ((y - x) / a)
	elif t <= 2.65e-45:
		tmp = t_1
	elif t <= 1.8e+62:
		tmp = y * (z / (a - t))
	elif t <= 4e+126:
		tmp = x + ((y * z) / a)
	else:
		tmp = y
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(x + Float64(y * Float64(z / a)))
	tmp = 0.0
	if (t <= -8.5e+77)
		tmp = y;
	elseif (t <= -1.15e-290)
		tmp = t_1;
	elseif (t <= 4.3e-206)
		tmp = Float64(z * Float64(Float64(y - x) / a));
	elseif (t <= 2.65e-45)
		tmp = t_1;
	elseif (t <= 1.8e+62)
		tmp = Float64(y * Float64(z / Float64(a - t)));
	elseif (t <= 4e+126)
		tmp = Float64(x + Float64(Float64(y * z) / a));
	else
		tmp = y;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = x + (y * (z / a));
	tmp = 0.0;
	if (t <= -8.5e+77)
		tmp = y;
	elseif (t <= -1.15e-290)
		tmp = t_1;
	elseif (t <= 4.3e-206)
		tmp = z * ((y - x) / a);
	elseif (t <= 2.65e-45)
		tmp = t_1;
	elseif (t <= 1.8e+62)
		tmp = y * (z / (a - t));
	elseif (t <= 4e+126)
		tmp = x + ((y * z) / a);
	else
		tmp = y;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(y * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -8.5e+77], y, If[LessEqual[t, -1.15e-290], t$95$1, If[LessEqual[t, 4.3e-206], N[(z * N[(N[(y - x), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.65e-45], t$95$1, If[LessEqual[t, 1.8e+62], N[(y * N[(z / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 4e+126], N[(x + N[(N[(y * z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], y]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;t \leq -1.15 \cdot 10^{-290}:\\
\;\;\;\;t\_1\\

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

\mathbf{elif}\;t \leq 2.65 \cdot 10^{-45}:\\
\;\;\;\;t\_1\\

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if t < -8.50000000000000018e77 or 3.9999999999999997e126 < t

    1. Initial program 28.9%

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

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

    if -8.50000000000000018e77 < t < -1.15e-290 or 4.30000000000000025e-206 < t < 2.6499999999999999e-45

    1. Initial program 88.6%

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

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

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

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

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

    if -1.15e-290 < t < 4.30000000000000025e-206

    1. Initial program 89.3%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr99.3%

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

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

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

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

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

    if 2.6499999999999999e-45 < t < 1.8e62

    1. Initial program 81.5%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr78.4%

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

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

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

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

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

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

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

    if 1.8e62 < t < 3.9999999999999997e126

    1. Initial program 56.8%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -8.5 \cdot 10^{+77}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq -1.15 \cdot 10^{-290}:\\ \;\;\;\;x + y \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq 4.3 \cdot 10^{-206}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \mathbf{elif}\;t \leq 2.65 \cdot 10^{-45}:\\ \;\;\;\;x + y \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq 1.8 \cdot 10^{+62}:\\ \;\;\;\;y \cdot \frac{z}{a - t}\\ \mathbf{elif}\;t \leq 4 \cdot 10^{+126}:\\ \;\;\;\;x + \frac{y \cdot z}{a}\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]
  5. Add Preprocessing

Alternative 9: 50.7% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -2.7 \cdot 10^{+221}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq -8.2 \cdot 10^{+192}:\\ \;\;\;\;x - x \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq -1.3 \cdot 10^{+78}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 8.6 \cdot 10^{-49}:\\ \;\;\;\;x + y \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq 5.8 \cdot 10^{+60}:\\ \;\;\;\;y \cdot \frac{z}{a - t}\\ \mathbf{elif}\;t \leq 6.4 \cdot 10^{+125}:\\ \;\;\;\;x + \frac{y \cdot z}{a}\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= t -2.7e+221)
   y
   (if (<= t -8.2e+192)
     (- x (* x (/ z a)))
     (if (<= t -1.3e+78)
       y
       (if (<= t 8.6e-49)
         (+ x (* y (/ z a)))
         (if (<= t 5.8e+60)
           (* y (/ z (- a t)))
           (if (<= t 6.4e+125) (+ x (/ (* y z) a)) y)))))))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (t <= -2.7e+221) {
		tmp = y;
	} else if (t <= -8.2e+192) {
		tmp = x - (x * (z / a));
	} else if (t <= -1.3e+78) {
		tmp = y;
	} else if (t <= 8.6e-49) {
		tmp = x + (y * (z / a));
	} else if (t <= 5.8e+60) {
		tmp = y * (z / (a - t));
	} else if (t <= 6.4e+125) {
		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 <= (-2.7d+221)) then
        tmp = y
    else if (t <= (-8.2d+192)) then
        tmp = x - (x * (z / a))
    else if (t <= (-1.3d+78)) then
        tmp = y
    else if (t <= 8.6d-49) then
        tmp = x + (y * (z / a))
    else if (t <= 5.8d+60) then
        tmp = y * (z / (a - t))
    else if (t <= 6.4d+125) 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 <= -2.7e+221) {
		tmp = y;
	} else if (t <= -8.2e+192) {
		tmp = x - (x * (z / a));
	} else if (t <= -1.3e+78) {
		tmp = y;
	} else if (t <= 8.6e-49) {
		tmp = x + (y * (z / a));
	} else if (t <= 5.8e+60) {
		tmp = y * (z / (a - t));
	} else if (t <= 6.4e+125) {
		tmp = x + ((y * z) / a);
	} else {
		tmp = y;
	}
	return tmp;
}
def code(x, y, z, t, a):
	tmp = 0
	if t <= -2.7e+221:
		tmp = y
	elif t <= -8.2e+192:
		tmp = x - (x * (z / a))
	elif t <= -1.3e+78:
		tmp = y
	elif t <= 8.6e-49:
		tmp = x + (y * (z / a))
	elif t <= 5.8e+60:
		tmp = y * (z / (a - t))
	elif t <= 6.4e+125:
		tmp = x + ((y * z) / a)
	else:
		tmp = y
	return tmp
function code(x, y, z, t, a)
	tmp = 0.0
	if (t <= -2.7e+221)
		tmp = y;
	elseif (t <= -8.2e+192)
		tmp = Float64(x - Float64(x * Float64(z / a)));
	elseif (t <= -1.3e+78)
		tmp = y;
	elseif (t <= 8.6e-49)
		tmp = Float64(x + Float64(y * Float64(z / a)));
	elseif (t <= 5.8e+60)
		tmp = Float64(y * Float64(z / Float64(a - t)));
	elseif (t <= 6.4e+125)
		tmp = Float64(x + Float64(Float64(y * z) / a));
	else
		tmp = y;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	tmp = 0.0;
	if (t <= -2.7e+221)
		tmp = y;
	elseif (t <= -8.2e+192)
		tmp = x - (x * (z / a));
	elseif (t <= -1.3e+78)
		tmp = y;
	elseif (t <= 8.6e-49)
		tmp = x + (y * (z / a));
	elseif (t <= 5.8e+60)
		tmp = y * (z / (a - t));
	elseif (t <= 6.4e+125)
		tmp = x + ((y * z) / a);
	else
		tmp = y;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -2.7e+221], y, If[LessEqual[t, -8.2e+192], N[(x - N[(x * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, -1.3e+78], y, If[LessEqual[t, 8.6e-49], N[(x + N[(y * N[(z / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 5.8e+60], N[(y * N[(z / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 6.4e+125], N[(x + N[(N[(y * z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], y]]]]]]
\begin{array}{l}

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

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

\mathbf{elif}\;t \leq -1.3 \cdot 10^{+78}:\\
\;\;\;\;y\\

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if t < -2.7e221 or -8.20000000000000006e192 < t < -1.3e78 or 6.39999999999999967e125 < t

    1. Initial program 26.3%

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

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

    if -2.7e221 < t < -8.20000000000000006e192

    1. Initial program 58.6%

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

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

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

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

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

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

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

        \[\leadsto x + x \cdot \color{blue}{\frac{-1 \cdot z}{a}} \]
      6. mul-1-neg70.3%

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

      \[\leadsto x + \color{blue}{x \cdot \frac{-z}{a}} \]
    7. Step-by-step derivation
      1. *-commutative70.3%

        \[\leadsto x + \color{blue}{\frac{-z}{a} \cdot x} \]
      2. add-sqr-sqrt0.0%

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

        \[\leadsto x + \frac{\color{blue}{\sqrt{\left(-z\right) \cdot \left(-z\right)}}}{a} \cdot x \]
      4. sqr-neg43.9%

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

        \[\leadsto x + \frac{\color{blue}{\sqrt{z} \cdot \sqrt{z}}}{a} \cdot x \]
      6. add-sqr-sqrt55.4%

        \[\leadsto x + \frac{\color{blue}{z}}{a} \cdot x \]
      7. cancel-sign-sub55.4%

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

        \[\leadsto x - \color{blue}{\frac{-z}{a}} \cdot x \]
      9. *-commutative55.4%

        \[\leadsto x - \color{blue}{x \cdot \frac{-z}{a}} \]
      10. add-sqr-sqrt0.0%

        \[\leadsto x - x \cdot \frac{\color{blue}{\sqrt{-z} \cdot \sqrt{-z}}}{a} \]
      11. sqrt-unprod44.4%

        \[\leadsto x - x \cdot \frac{\color{blue}{\sqrt{\left(-z\right) \cdot \left(-z\right)}}}{a} \]
      12. sqr-neg44.4%

        \[\leadsto x - x \cdot \frac{\sqrt{\color{blue}{z \cdot z}}}{a} \]
      13. sqrt-unprod70.3%

        \[\leadsto x - x \cdot \frac{\color{blue}{\sqrt{z} \cdot \sqrt{z}}}{a} \]
      14. add-sqr-sqrt70.3%

        \[\leadsto x - x \cdot \frac{\color{blue}{z}}{a} \]
    8. Applied egg-rr70.3%

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

    if -1.3e78 < t < 8.60000000000000033e-49

    1. Initial program 88.8%

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

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

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

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

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

    if 8.60000000000000033e-49 < t < 5.79999999999999999e60

    1. Initial program 81.5%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr78.4%

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

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

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

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

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

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

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

    if 5.79999999999999999e60 < t < 6.39999999999999967e125

    1. Initial program 56.8%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -2.7 \cdot 10^{+221}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq -8.2 \cdot 10^{+192}:\\ \;\;\;\;x - x \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq -1.3 \cdot 10^{+78}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 8.6 \cdot 10^{-49}:\\ \;\;\;\;x + y \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq 5.8 \cdot 10^{+60}:\\ \;\;\;\;y \cdot \frac{z}{a - t}\\ \mathbf{elif}\;t \leq 6.4 \cdot 10^{+125}:\\ \;\;\;\;x + \frac{y \cdot z}{a}\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]
  5. Add Preprocessing

Alternative 10: 50.5% accurate, 0.4× speedup?

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

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

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

\mathbf{elif}\;t \leq -2.3 \cdot 10^{+77}:\\
\;\;\;\;y\\

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if t < -2.7e221 or -8.20000000000000006e192 < t < -2.29999999999999995e77 or 6.4999999999999999e125 < t

    1. Initial program 26.3%

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

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

    if -2.7e221 < t < -8.20000000000000006e192

    1. Initial program 58.6%

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

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

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

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

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

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

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

        \[\leadsto x + x \cdot \color{blue}{\frac{-1 \cdot z}{a}} \]
      6. mul-1-neg70.3%

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

      \[\leadsto x + \color{blue}{x \cdot \frac{-z}{a}} \]
    7. Step-by-step derivation
      1. *-commutative70.3%

        \[\leadsto x + \color{blue}{\frac{-z}{a} \cdot x} \]
      2. add-sqr-sqrt0.0%

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

        \[\leadsto x + \frac{\color{blue}{\sqrt{\left(-z\right) \cdot \left(-z\right)}}}{a} \cdot x \]
      4. sqr-neg43.9%

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

        \[\leadsto x + \frac{\color{blue}{\sqrt{z} \cdot \sqrt{z}}}{a} \cdot x \]
      6. add-sqr-sqrt55.4%

        \[\leadsto x + \frac{\color{blue}{z}}{a} \cdot x \]
      7. cancel-sign-sub55.4%

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

        \[\leadsto x - \color{blue}{\frac{-z}{a}} \cdot x \]
      9. *-commutative55.4%

        \[\leadsto x - \color{blue}{x \cdot \frac{-z}{a}} \]
      10. add-sqr-sqrt0.0%

        \[\leadsto x - x \cdot \frac{\color{blue}{\sqrt{-z} \cdot \sqrt{-z}}}{a} \]
      11. sqrt-unprod44.4%

        \[\leadsto x - x \cdot \frac{\color{blue}{\sqrt{\left(-z\right) \cdot \left(-z\right)}}}{a} \]
      12. sqr-neg44.4%

        \[\leadsto x - x \cdot \frac{\sqrt{\color{blue}{z \cdot z}}}{a} \]
      13. sqrt-unprod70.3%

        \[\leadsto x - x \cdot \frac{\color{blue}{\sqrt{z} \cdot \sqrt{z}}}{a} \]
      14. add-sqr-sqrt70.3%

        \[\leadsto x - x \cdot \frac{\color{blue}{z}}{a} \]
    8. Applied egg-rr70.3%

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

    if -2.29999999999999995e77 < t < 1.1e-46

    1. Initial program 88.8%

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

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

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

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

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

    if 1.1e-46 < t < 3.99999999999999989e59

    1. Initial program 81.5%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr78.4%

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

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

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

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

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

    if 3.99999999999999989e59 < t < 6.4999999999999999e125

    1. Initial program 56.8%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -2.7 \cdot 10^{+221}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq -8.2 \cdot 10^{+192}:\\ \;\;\;\;x - x \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq -2.3 \cdot 10^{+77}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 1.1 \cdot 10^{-46}:\\ \;\;\;\;x + y \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq 4 \cdot 10^{+59}:\\ \;\;\;\;\frac{y \cdot z}{a - t}\\ \mathbf{elif}\;t \leq 6.5 \cdot 10^{+125}:\\ \;\;\;\;x + \frac{y \cdot z}{a}\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]
  5. Add Preprocessing

Alternative 11: 86.3% accurate, 0.4× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -8 \cdot 10^{+237} \lor \neg \left(t \leq -1.55 \cdot 10^{+186} \lor \neg \left(t \leq -5.6 \cdot 10^{+116}\right) \land t \leq 9.2 \cdot 10^{+136}\right):\\
\;\;\;\;y + \left(z - a\right) \cdot \frac{x - y}{t}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -7.99999999999999952e237 or -1.5500000000000001e186 < t < -5.60000000000000009e116 or 9.2e136 < t

    1. Initial program 22.5%

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

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

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

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

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

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

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

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

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

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

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

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

    if -7.99999999999999952e237 < t < -1.5500000000000001e186 or -5.60000000000000009e116 < t < 9.2e136

    1. Initial program 81.1%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr91.2%

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

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

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

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

        \[\leadsto x + \frac{\color{blue}{z - t}}{\frac{\sqrt[3]{a - t}}{y - x} \cdot {\left(\sqrt[3]{a - t}\right)}^{2}} \]
    6. Applied egg-rr89.5%

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -8 \cdot 10^{+237} \lor \neg \left(t \leq -1.55 \cdot 10^{+186} \lor \neg \left(t \leq -5.6 \cdot 10^{+116}\right) \land t \leq 9.2 \cdot 10^{+136}\right):\\ \;\;\;\;y + \left(z - a\right) \cdot \frac{x - y}{t}\\ \mathbf{else}:\\ \;\;\;\;x - \frac{z - t}{\frac{a - t}{x - y}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 12: 50.4% accurate, 0.4× speedup?

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

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

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

\mathbf{elif}\;t \leq -5.3 \cdot 10^{+77}:\\
\;\;\;\;y\\

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < -2.7e221 or -7.5e192 < t < -5.3e77 or 7.49999999999999934e78 < t

    1. Initial program 29.0%

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

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

    if -2.7e221 < t < -7.5e192

    1. Initial program 58.6%

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

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

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

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

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

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

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

        \[\leadsto x + x \cdot \color{blue}{\frac{-1 \cdot z}{a}} \]
      6. mul-1-neg70.3%

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

      \[\leadsto x + \color{blue}{x \cdot \frac{-z}{a}} \]
    7. Step-by-step derivation
      1. *-commutative70.3%

        \[\leadsto x + \color{blue}{\frac{-z}{a} \cdot x} \]
      2. add-sqr-sqrt0.0%

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

        \[\leadsto x + \frac{\color{blue}{\sqrt{\left(-z\right) \cdot \left(-z\right)}}}{a} \cdot x \]
      4. sqr-neg43.9%

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

        \[\leadsto x + \frac{\color{blue}{\sqrt{z} \cdot \sqrt{z}}}{a} \cdot x \]
      6. add-sqr-sqrt55.4%

        \[\leadsto x + \frac{\color{blue}{z}}{a} \cdot x \]
      7. cancel-sign-sub55.4%

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

        \[\leadsto x - \color{blue}{\frac{-z}{a}} \cdot x \]
      9. *-commutative55.4%

        \[\leadsto x - \color{blue}{x \cdot \frac{-z}{a}} \]
      10. add-sqr-sqrt0.0%

        \[\leadsto x - x \cdot \frac{\color{blue}{\sqrt{-z} \cdot \sqrt{-z}}}{a} \]
      11. sqrt-unprod44.4%

        \[\leadsto x - x \cdot \frac{\color{blue}{\sqrt{\left(-z\right) \cdot \left(-z\right)}}}{a} \]
      12. sqr-neg44.4%

        \[\leadsto x - x \cdot \frac{\sqrt{\color{blue}{z \cdot z}}}{a} \]
      13. sqrt-unprod70.3%

        \[\leadsto x - x \cdot \frac{\color{blue}{\sqrt{z} \cdot \sqrt{z}}}{a} \]
      14. add-sqr-sqrt70.3%

        \[\leadsto x - x \cdot \frac{\color{blue}{z}}{a} \]
    8. Applied egg-rr70.3%

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

    if -5.3e77 < t < 6.80000000000000042e-84

    1. Initial program 89.3%

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

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

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

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

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

    if 6.80000000000000042e-84 < t < 7.49999999999999934e78

    1. Initial program 82.0%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr79.3%

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -2.7 \cdot 10^{+221}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq -7.5 \cdot 10^{+192}:\\ \;\;\;\;x - x \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq -5.3 \cdot 10^{+77}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 6.8 \cdot 10^{-84}:\\ \;\;\;\;x + y \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq 7.5 \cdot 10^{+78}:\\ \;\;\;\;x \cdot \frac{z}{t - a}\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]
  5. Add Preprocessing

Alternative 13: 36.5% accurate, 0.4× speedup?

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

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

\mathbf{elif}\;t \leq -5.9 \cdot 10^{-114}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t \leq -5.3 \cdot 10^{-114}:\\
\;\;\;\;y\\

\mathbf{elif}\;t \leq -1.4 \cdot 10^{-227}:\\
\;\;\;\;x\\

\mathbf{elif}\;t \leq 7.8 \cdot 10^{-210}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t \leq 4.4 \cdot 10^{+129}:\\
\;\;\;\;x\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -3.39999999999999997e77 or -5.9000000000000001e-114 < t < -5.29999999999999973e-114 or 4.3999999999999999e129 < t

    1. Initial program 29.3%

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

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

    if -3.39999999999999997e77 < t < -5.9000000000000001e-114 or -1.3999999999999999e-227 < t < 7.7999999999999995e-210

    1. Initial program 89.9%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr95.9%

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

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

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

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

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

    if -5.29999999999999973e-114 < t < -1.3999999999999999e-227 or 7.7999999999999995e-210 < t < 4.3999999999999999e129

    1. Initial program 77.0%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -3.4 \cdot 10^{+77}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq -5.9 \cdot 10^{-114}:\\ \;\;\;\;y \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq -5.3 \cdot 10^{-114}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq -1.4 \cdot 10^{-227}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq 7.8 \cdot 10^{-210}:\\ \;\;\;\;y \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq 4.4 \cdot 10^{+129}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]
  5. Add Preprocessing

Alternative 14: 36.5% accurate, 0.4× speedup?

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

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

\mathbf{elif}\;t \leq -1.65 \cdot 10^{-98}:\\
\;\;\;\;t\_1\\

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

\mathbf{elif}\;t \leq -3.3 \cdot 10^{-226}:\\
\;\;\;\;x\\

\mathbf{elif}\;t \leq 8.6 \cdot 10^{-210}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t \leq 1.08 \cdot 10^{+130}:\\
\;\;\;\;x\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < -7.2000000000000006e76 or 1.08e130 < t

    1. Initial program 28.4%

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

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

    if -7.2000000000000006e76 < t < -1.6500000000000001e-98 or -3.3e-226 < t < 8.6000000000000001e-210

    1. Initial program 89.8%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr95.9%

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

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

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

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

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

    if -1.6500000000000001e-98 < t < -2.00000000000000012e-122

    1. Initial program 99.2%

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

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

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

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

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

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

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

        \[\leadsto x + x \cdot \color{blue}{\frac{-1 \cdot z}{a}} \]
      6. mul-1-neg52.4%

        \[\leadsto x + x \cdot \frac{\color{blue}{-z}}{a} \]
    6. Simplified52.4%

      \[\leadsto x + \color{blue}{x \cdot \frac{-z}{a}} \]
    7. Step-by-step derivation
      1. *-commutative52.4%

        \[\leadsto x + \color{blue}{\frac{-z}{a} \cdot x} \]
      2. add-sqr-sqrt0.0%

        \[\leadsto x + \frac{\color{blue}{\sqrt{-z} \cdot \sqrt{-z}}}{a} \cdot x \]
      3. sqrt-unprod2.2%

        \[\leadsto x + \frac{\color{blue}{\sqrt{\left(-z\right) \cdot \left(-z\right)}}}{a} \cdot x \]
      4. sqr-neg2.2%

        \[\leadsto x + \frac{\sqrt{\color{blue}{z \cdot z}}}{a} \cdot x \]
      5. sqrt-unprod1.0%

        \[\leadsto x + \frac{\color{blue}{\sqrt{z} \cdot \sqrt{z}}}{a} \cdot x \]
      6. add-sqr-sqrt1.0%

        \[\leadsto x + \frac{\color{blue}{z}}{a} \cdot x \]
      7. cancel-sign-sub1.0%

        \[\leadsto \color{blue}{x - \left(-\frac{z}{a}\right) \cdot x} \]
      8. distribute-frac-neg1.0%

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

        \[\leadsto x - \color{blue}{x \cdot \frac{-z}{a}} \]
      10. add-sqr-sqrt0.0%

        \[\leadsto x - x \cdot \frac{\color{blue}{\sqrt{-z} \cdot \sqrt{-z}}}{a} \]
      11. sqrt-unprod52.2%

        \[\leadsto x - x \cdot \frac{\color{blue}{\sqrt{\left(-z\right) \cdot \left(-z\right)}}}{a} \]
      12. sqr-neg52.2%

        \[\leadsto x - x \cdot \frac{\sqrt{\color{blue}{z \cdot z}}}{a} \]
      13. sqrt-unprod52.4%

        \[\leadsto x - x \cdot \frac{\color{blue}{\sqrt{z} \cdot \sqrt{z}}}{a} \]
      14. add-sqr-sqrt52.4%

        \[\leadsto x - x \cdot \frac{\color{blue}{z}}{a} \]
    8. Applied egg-rr52.4%

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

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

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

        \[\leadsto -\color{blue}{x \cdot \frac{z}{a}} \]
      3. *-commutative52.4%

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

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

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

    if -2.00000000000000012e-122 < t < -3.3e-226 or 8.6000000000000001e-210 < t < 1.08e130

    1. Initial program 77.0%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -7.2 \cdot 10^{+76}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq -1.65 \cdot 10^{-98}:\\ \;\;\;\;y \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq -2 \cdot 10^{-122}:\\ \;\;\;\;x \cdot \frac{z}{-a}\\ \mathbf{elif}\;t \leq -3.3 \cdot 10^{-226}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq 8.6 \cdot 10^{-210}:\\ \;\;\;\;y \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq 1.08 \cdot 10^{+130}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]
  5. Add Preprocessing

Alternative 15: 65.4% accurate, 0.4× speedup?

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

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

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

\mathbf{elif}\;t \leq -1.42 \cdot 10^{-70} \lor \neg \left(t \leq 2.6 \cdot 10^{-45}\right):\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -2.7e221 or -8.20000000000000006e192 < t < -1.42000000000000002e-70 or 2.59999999999999987e-45 < t

    1. Initial program 50.3%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr71.8%

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

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

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

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

    if -2.7e221 < t < -8.20000000000000006e192

    1. Initial program 58.6%

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

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

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

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

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

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

    if -1.42000000000000002e-70 < t < 2.59999999999999987e-45

    1. Initial program 89.1%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -2.7 \cdot 10^{+221}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;t \leq -8.2 \cdot 10^{+192}:\\ \;\;\;\;x \cdot \left(\frac{z}{t - a} + 1\right)\\ \mathbf{elif}\;t \leq -1.42 \cdot 10^{-70} \lor \neg \left(t \leq 2.6 \cdot 10^{-45}\right):\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{else}:\\ \;\;\;\;x - z \cdot \frac{x - y}{a}\\ \end{array} \]
  5. Add Preprocessing

Alternative 16: 65.4% accurate, 0.4× speedup?

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

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

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

\mathbf{elif}\;t \leq -2.3 \cdot 10^{-70} \lor \neg \left(t \leq 2.3 \cdot 10^{-45}\right):\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -2.7e221 or -8.20000000000000006e192 < t < -2.30000000000000001e-70 or 2.29999999999999992e-45 < t

    1. Initial program 50.3%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr71.8%

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

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

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

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

    if -2.7e221 < t < -8.20000000000000006e192

    1. Initial program 58.6%

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

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

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

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

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

    if -2.30000000000000001e-70 < t < 2.29999999999999992e-45

    1. Initial program 89.1%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -2.7 \cdot 10^{+221}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;t \leq -8.2 \cdot 10^{+192}:\\ \;\;\;\;x \cdot \left(\frac{z - t}{t - a} + 1\right)\\ \mathbf{elif}\;t \leq -2.3 \cdot 10^{-70} \lor \neg \left(t \leq 2.3 \cdot 10^{-45}\right):\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{else}:\\ \;\;\;\;x - z \cdot \frac{x - y}{a}\\ \end{array} \]
  5. Add Preprocessing

Alternative 17: 38.1% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := y \cdot \frac{z}{a - t}\\ \mathbf{if}\;t \leq -1.55 \cdot 10^{+77}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 3.2 \cdot 10^{-207}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t \leq 1.76 \cdot 10^{-127}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq 2.6 \cdot 10^{+87}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (* y (/ z (- a t)))))
   (if (<= t -1.55e+77)
     y
     (if (<= t 3.2e-207)
       t_1
       (if (<= t 1.76e-127) x (if (<= t 2.6e+87) t_1 y))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = y * (z / (a - t));
	double tmp;
	if (t <= -1.55e+77) {
		tmp = y;
	} else if (t <= 3.2e-207) {
		tmp = t_1;
	} else if (t <= 1.76e-127) {
		tmp = x;
	} else if (t <= 2.6e+87) {
		tmp = t_1;
	} 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) :: t_1
    real(8) :: tmp
    t_1 = y * (z / (a - t))
    if (t <= (-1.55d+77)) then
        tmp = y
    else if (t <= 3.2d-207) then
        tmp = t_1
    else if (t <= 1.76d-127) then
        tmp = x
    else if (t <= 2.6d+87) then
        tmp = t_1
    else
        tmp = y
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = y * (z / (a - t));
	double tmp;
	if (t <= -1.55e+77) {
		tmp = y;
	} else if (t <= 3.2e-207) {
		tmp = t_1;
	} else if (t <= 1.76e-127) {
		tmp = x;
	} else if (t <= 2.6e+87) {
		tmp = t_1;
	} else {
		tmp = y;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = y * (z / (a - t))
	tmp = 0
	if t <= -1.55e+77:
		tmp = y
	elif t <= 3.2e-207:
		tmp = t_1
	elif t <= 1.76e-127:
		tmp = x
	elif t <= 2.6e+87:
		tmp = t_1
	else:
		tmp = y
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(y * Float64(z / Float64(a - t)))
	tmp = 0.0
	if (t <= -1.55e+77)
		tmp = y;
	elseif (t <= 3.2e-207)
		tmp = t_1;
	elseif (t <= 1.76e-127)
		tmp = x;
	elseif (t <= 2.6e+87)
		tmp = t_1;
	else
		tmp = y;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = y * (z / (a - t));
	tmp = 0.0;
	if (t <= -1.55e+77)
		tmp = y;
	elseif (t <= 3.2e-207)
		tmp = t_1;
	elseif (t <= 1.76e-127)
		tmp = x;
	elseif (t <= 2.6e+87)
		tmp = t_1;
	else
		tmp = y;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y * N[(z / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1.55e+77], y, If[LessEqual[t, 3.2e-207], t$95$1, If[LessEqual[t, 1.76e-127], x, If[LessEqual[t, 2.6e+87], t$95$1, y]]]]]
\begin{array}{l}

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

\mathbf{elif}\;t \leq 3.2 \cdot 10^{-207}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t \leq 1.76 \cdot 10^{-127}:\\
\;\;\;\;x\\

\mathbf{elif}\;t \leq 2.6 \cdot 10^{+87}:\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -1.54999999999999999e77 or 2.59999999999999998e87 < t

    1. Initial program 30.9%

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

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

    if -1.54999999999999999e77 < t < 3.2000000000000003e-207 or 1.76000000000000007e-127 < t < 2.59999999999999998e87

    1. Initial program 85.6%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr90.5%

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

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

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

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

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

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

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

    if 3.2000000000000003e-207 < t < 1.76000000000000007e-127

    1. Initial program 95.0%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -1.55 \cdot 10^{+77}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 3.2 \cdot 10^{-207}:\\ \;\;\;\;y \cdot \frac{z}{a - t}\\ \mathbf{elif}\;t \leq 1.76 \cdot 10^{-127}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq 2.6 \cdot 10^{+87}:\\ \;\;\;\;y \cdot \frac{z}{a - t}\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]
  5. Add Preprocessing

Alternative 18: 37.6% accurate, 0.5× speedup?

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

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

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

\mathbf{elif}\;t \leq 2.4 \cdot 10^{-125}:\\
\;\;\;\;x\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < -7.79999999999999979e76 or 3.4999999999999999e84 < t

    1. Initial program 30.9%

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

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

    if -7.79999999999999979e76 < t < 1.72000000000000002e-208

    1. Initial program 89.9%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr96.2%

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

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

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

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

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

    if 1.72000000000000002e-208 < t < 2.4000000000000001e-125

    1. Initial program 95.0%

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

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

    if 2.4000000000000001e-125 < t < 3.4999999999999999e84

    1. Initial program 77.2%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr79.3%

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -7.8 \cdot 10^{+76}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 1.72 \cdot 10^{-208}:\\ \;\;\;\;y \cdot \frac{z - t}{a}\\ \mathbf{elif}\;t \leq 2.4 \cdot 10^{-125}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq 3.5 \cdot 10^{+84}:\\ \;\;\;\;y \cdot \frac{z}{a - t}\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]
  5. Add Preprocessing

Alternative 19: 41.0% accurate, 0.5× speedup?

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

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

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

\mathbf{elif}\;t \leq 6.2 \cdot 10^{-127}:\\
\;\;\;\;x\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < -7.2000000000000006e76 or 3e85 < t

    1. Initial program 30.9%

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

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

    if -7.2000000000000006e76 < t < 6.2000000000000005e-206

    1. Initial program 89.1%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr96.2%

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

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

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

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

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

    if 6.2000000000000005e-206 < t < 6.2e-127

    1. Initial program 99.8%

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

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

    if 6.2e-127 < t < 3e85

    1. Initial program 77.2%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr79.3%

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -7.2 \cdot 10^{+76}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 6.2 \cdot 10^{-206}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \mathbf{elif}\;t \leq 6.2 \cdot 10^{-127}:\\ \;\;\;\;x\\ \mathbf{elif}\;t \leq 3 \cdot 10^{+85}:\\ \;\;\;\;y \cdot \frac{z}{a - t}\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]
  5. Add Preprocessing

Alternative 20: 41.1% accurate, 0.5× speedup?

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

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

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < -8.9999999999999995e76 or 7.0000000000000001e85 < t

    1. Initial program 30.9%

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

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

    if -8.9999999999999995e76 < t < 1.6200000000000001e-205

    1. Initial program 89.1%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr96.2%

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

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

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

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

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

    if 1.6200000000000001e-205 < t < 2.1e-125

    1. Initial program 99.8%

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

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

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

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

        \[\leadsto x + \left(-\color{blue}{x \cdot \frac{z}{a}}\right) \]
      3. distribute-rgt-neg-in65.2%

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

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

        \[\leadsto x + x \cdot \color{blue}{\frac{-1 \cdot z}{a}} \]
      6. mul-1-neg65.2%

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

      \[\leadsto x + \color{blue}{x \cdot \frac{-z}{a}} \]
    7. Step-by-step derivation
      1. *-commutative65.2%

        \[\leadsto x + \color{blue}{\frac{-z}{a} \cdot x} \]
      2. distribute-rgt1-in65.2%

        \[\leadsto \color{blue}{\left(\frac{-z}{a} + 1\right) \cdot x} \]
      3. add-sqr-sqrt35.3%

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

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

        \[\leadsto \left(\frac{\sqrt{\color{blue}{z \cdot z}}}{a} + 1\right) \cdot x \]
      6. sqrt-unprod25.3%

        \[\leadsto \left(\frac{\color{blue}{\sqrt{z} \cdot \sqrt{z}}}{a} + 1\right) \cdot x \]
      7. add-sqr-sqrt67.2%

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

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

    if 2.1e-125 < t < 7.0000000000000001e85

    1. Initial program 77.2%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr79.3%

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -9 \cdot 10^{+76}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 1.62 \cdot 10^{-205}:\\ \;\;\;\;z \cdot \frac{y - x}{a}\\ \mathbf{elif}\;t \leq 2.1 \cdot 10^{-125}:\\ \;\;\;\;x \cdot \left(\frac{z}{a} + 1\right)\\ \mathbf{elif}\;t \leq 7 \cdot 10^{+85}:\\ \;\;\;\;y \cdot \frac{z}{a - t}\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]
  5. Add Preprocessing

Alternative 21: 73.7% accurate, 0.5× speedup?

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

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

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

\mathbf{elif}\;t \leq 1.72 \cdot 10^{+161}:\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -5.29999999999999972e-22 or 38 < t < 1.71999999999999996e161

    1. Initial program 56.1%

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

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

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

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

    if -5.29999999999999972e-22 < t < 38

    1. Initial program 86.9%

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

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

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

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

    if 1.71999999999999996e161 < t

    1. Initial program 17.5%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr47.6%

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -5.3 \cdot 10^{-22}:\\ \;\;\;\;x + y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;t \leq 38:\\ \;\;\;\;x - z \cdot \frac{y - x}{t - a}\\ \mathbf{elif}\;t \leq 1.72 \cdot 10^{+161}:\\ \;\;\;\;x + y \cdot \frac{z - t}{a - t}\\ \mathbf{else}:\\ \;\;\;\;y \cdot \frac{t - z}{t}\\ \end{array} \]
  5. Add Preprocessing

Alternative 22: 73.9% accurate, 0.6× speedup?

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -2.80000000000000018e102 or 3.9999999999999997e112 < z

    1. Initial program 71.7%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr90.3%

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

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

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

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

    if -2.80000000000000018e102 < z < 3.9999999999999997e112

    1. Initial program 61.8%

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

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

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

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

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

Alternative 23: 62.8% accurate, 0.7× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;x \leq -4.6 \cdot 10^{-57} \lor \neg \left(x \leq 10^{+163}\right):\\
\;\;\;\;x \cdot \left(\frac{z}{t - a} + 1\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if x < -4.6e-57 or 9.9999999999999994e162 < x

    1. Initial program 56.0%

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

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

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

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

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

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

    if -4.6e-57 < x < 9.9999999999999994e162

    1. Initial program 72.1%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr88.2%

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

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

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

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

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

Alternative 24: 55.6% accurate, 0.8× speedup?

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if a < -1.8499999999999999e-31 or 1.15000000000000001e76 < a

    1. Initial program 61.7%

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

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

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

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

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

    if -1.8499999999999999e-31 < a < 1.15000000000000001e76

    1. Initial program 68.1%

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

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

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

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

        \[\leadsto x + \frac{z - t}{\color{blue}{{\left(\sqrt[3]{a - t}\right)}^{2}}} \cdot \frac{y - x}{\sqrt[3]{a - t}} \]
    4. Applied egg-rr77.7%

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

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

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

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

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

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

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

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

Alternative 25: 35.9% accurate, 1.2× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.1 \cdot 10^{-120}:\\
\;\;\;\;y\\

\mathbf{elif}\;t \leq 4.4 \cdot 10^{+129}:\\
\;\;\;\;x\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -4.10000000000000034e-120 or 4.3999999999999999e129 < t

    1. Initial program 45.0%

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

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

    if -4.10000000000000034e-120 < t < 4.3999999999999999e129

    1. Initial program 83.0%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -4.1 \cdot 10^{-120}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 4.4 \cdot 10^{+129}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]
  5. Add Preprocessing

Alternative 26: 25.0% 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 65.3%

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

    \[\leadsto \color{blue}{x} \]
  4. Final simplification21.1%

    \[\leadsto x \]
  5. Add Preprocessing

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

  :alt
  (if (< a -1.6153062845442575e-142) (+ x (* (/ (- y x) 1.0) (/ (- z t) (- a t)))) (if (< a 3.774403170083174e-182) (- y (* (/ z t) (- y x))) (+ x (* (/ (- y x) 1.0) (/ (- z t) (- a t))))))

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