Graphics.Rendering.Plot.Render.Plot.Axis:renderAxisTick from plot-0.2.3.4, B

Percentage Accurate: 76.4% → 91.4%
Time: 12.1s
Alternatives: 14
Speedup: 1.2×

Specification

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

\\
\left(x + y\right) - \frac{\left(z - t\right) \cdot y}{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 14 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: 76.4% accurate, 1.0× speedup?

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

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

Alternative 1: 91.4% accurate, 0.8× speedup?

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

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

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

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


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

    1. Initial program 32.5%

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

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

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

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

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

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

        \[\leadsto \color{blue}{x - \frac{y \cdot a - y \cdot z}{t}} \]
      4. distribute-lft-out--69.7%

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

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

        \[\leadsto x - \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\frac{y \cdot \left(a - z\right)}{t}\right)\right)} \]
      2. expm1-udef50.7%

        \[\leadsto x - \color{blue}{\left(e^{\mathsf{log1p}\left(\frac{y \cdot \left(a - z\right)}{t}\right)} - 1\right)} \]
    8. Applied egg-rr50.7%

      \[\leadsto x - \color{blue}{\left(e^{\mathsf{log1p}\left(\frac{y \cdot \left(a - z\right)}{t}\right)} - 1\right)} \]
    9. Step-by-step derivation
      1. expm1-def65.5%

        \[\leadsto x - \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\frac{y \cdot \left(a - z\right)}{t}\right)\right)} \]
      2. expm1-log1p69.7%

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

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

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

    if -8.99999999999999965e149 < t < 1.15e145

    1. Initial program 89.9%

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

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

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

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

    if 1.15e145 < t

    1. Initial program 47.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 2: 75.3% accurate, 0.8× speedup?

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

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

\mathbf{elif}\;a \leq -9.5 \cdot 10^{-83}:\\
\;\;\;\;t_1\\

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

\mathbf{elif}\;a \leq 9.2 \cdot 10^{+48}:\\
\;\;\;\;t_1\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if a < -3.80000000000000022e73 or 2.20000000000000001e70 < a

    1. Initial program 73.2%

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

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

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

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

    if -3.80000000000000022e73 < a < -9.50000000000000051e-83 or 6.6e-146 < a < 9.2000000000000001e48

    1. Initial program 79.1%

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

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

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

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

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

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

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

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

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

        \[\leadsto x + \mathsf{fma}\left(\frac{-\color{blue}{\left(\left(-t\right) + z\right)}}{a - t}, y, y\right) \]
      10. distribute-neg-in80.4%

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

        \[\leadsto x + \mathsf{fma}\left(\frac{\color{blue}{\left(-\left(-t\right)\right) - z}}{a - t}, y, y\right) \]
      12. remove-double-neg80.4%

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

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

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

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

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

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

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

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

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

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

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

    if -9.50000000000000051e-83 < a < 6.6e-146

    1. Initial program 82.5%

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

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

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

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

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

    if 9.2000000000000001e48 < a < 2.20000000000000001e70

    1. Initial program 65.4%

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{y}{t} \cdot z} + x \]
    9. Applied egg-rr74.7%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -3.8 \cdot 10^{+73}:\\ \;\;\;\;y + x\\ \mathbf{elif}\;a \leq -9.5 \cdot 10^{-83}:\\ \;\;\;\;x - \frac{y \cdot z}{a}\\ \mathbf{elif}\;a \leq 6.6 \cdot 10^{-146}:\\ \;\;\;\;x + y \cdot \frac{z}{t}\\ \mathbf{elif}\;a \leq 9.2 \cdot 10^{+48}:\\ \;\;\;\;x - \frac{y \cdot z}{a}\\ \mathbf{elif}\;a \leq 2.2 \cdot 10^{+70}:\\ \;\;\;\;x + z \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;y + x\\ \end{array} \]

Alternative 3: 91.6% accurate, 0.8× speedup?

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

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

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

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


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

    1. Initial program 32.5%

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

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

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

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

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

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

        \[\leadsto \color{blue}{x - \frac{y \cdot a - y \cdot z}{t}} \]
      4. distribute-lft-out--69.7%

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

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

        \[\leadsto x - \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\frac{y \cdot \left(a - z\right)}{t}\right)\right)} \]
      2. expm1-udef50.7%

        \[\leadsto x - \color{blue}{\left(e^{\mathsf{log1p}\left(\frac{y \cdot \left(a - z\right)}{t}\right)} - 1\right)} \]
    8. Applied egg-rr50.7%

      \[\leadsto x - \color{blue}{\left(e^{\mathsf{log1p}\left(\frac{y \cdot \left(a - z\right)}{t}\right)} - 1\right)} \]
    9. Step-by-step derivation
      1. expm1-def65.5%

        \[\leadsto x - \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\frac{y \cdot \left(a - z\right)}{t}\right)\right)} \]
      2. expm1-log1p69.7%

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

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

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

    if -1.1e150 < t < 3.20000000000000005e152

    1. Initial program 89.9%

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

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

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

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

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

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

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

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

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

        \[\leadsto x + \mathsf{fma}\left(\frac{-\color{blue}{\left(\left(-t\right) + z\right)}}{a - t}, y, y\right) \]
      10. distribute-neg-in94.8%

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

        \[\leadsto x + \mathsf{fma}\left(\frac{\color{blue}{\left(-\left(-t\right)\right) - z}}{a - t}, y, y\right) \]
      12. remove-double-neg94.8%

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

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

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

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

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

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

    if 3.20000000000000005e152 < t

    1. Initial program 47.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -1.1 \cdot 10^{+150}:\\ \;\;\;\;x - \frac{y}{\frac{t}{a - z}}\\ \mathbf{elif}\;t \leq 3.2 \cdot 10^{+152}:\\ \;\;\;\;x + y \cdot \left(\frac{t - z}{a - t} + 1\right)\\ \mathbf{else}:\\ \;\;\;\;x + \left(z - a\right) \cdot \frac{y}{t}\\ \end{array} \]

Alternative 4: 93.4% accurate, 0.8× speedup?

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

\\
y \cdot \left(\left(\frac{t}{a - t} + 1\right) - \frac{z}{a - t}\right) + x
\end{array}
Derivation
  1. Initial program 77.1%

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

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

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

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

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

Alternative 5: 86.1% accurate, 0.9× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if a < -1.74999999999999991e152

    1. Initial program 74.9%

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

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

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

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

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

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

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

    if -1.74999999999999991e152 < a < 9.7999999999999998e73

    1. Initial program 78.3%

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

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

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

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

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

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

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

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

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

        \[\leadsto x + \mathsf{fma}\left(\frac{-\color{blue}{\left(\left(-t\right) + z\right)}}{a - t}, y, y\right) \]
      10. distribute-neg-in85.9%

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

        \[\leadsto x + \mathsf{fma}\left(\frac{\color{blue}{\left(-\left(-t\right)\right) - z}}{a - t}, y, y\right) \]
      12. remove-double-neg85.9%

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

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

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

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

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

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

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

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

    if 9.7999999999999998e73 < a

    1. Initial program 75.0%

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -1.75 \cdot 10^{+152}:\\ \;\;\;\;y + \left(x - \frac{y}{\frac{a}{z}}\right)\\ \mathbf{elif}\;a \leq 9.8 \cdot 10^{+73}:\\ \;\;\;\;x - z \cdot \frac{y}{a - t}\\ \mathbf{else}:\\ \;\;\;\;x + y \cdot \left(\frac{t}{a - t} + 1\right)\\ \end{array} \]

Alternative 6: 88.9% accurate, 0.9× speedup?

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

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

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

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


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

    1. Initial program 33.6%

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

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{y \cdot a - y \cdot z}{t} + x} \]
    5. Step-by-step derivation
      1. +-commutative68.1%

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

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

        \[\leadsto \color{blue}{x - \frac{y \cdot a - y \cdot z}{t}} \]
      4. distribute-lft-out--68.6%

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

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

        \[\leadsto x - \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\frac{y \cdot \left(a - z\right)}{t}\right)\right)} \]
      2. expm1-udef50.4%

        \[\leadsto x - \color{blue}{\left(e^{\mathsf{log1p}\left(\frac{y \cdot \left(a - z\right)}{t}\right)} - 1\right)} \]
    8. Applied egg-rr50.4%

      \[\leadsto x - \color{blue}{\left(e^{\mathsf{log1p}\left(\frac{y \cdot \left(a - z\right)}{t}\right)} - 1\right)} \]
    9. Step-by-step derivation
      1. expm1-def64.4%

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

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

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

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

    if -1.52e140 < t < 4.4e141

    1. Initial program 90.3%

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

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

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

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

    if 4.4e141 < t

    1. Initial program 47.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 7: 76.8% accurate, 1.0× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;a \leq -5.2 \cdot 10^{+178}:\\
\;\;\;\;y + x\\

\mathbf{elif}\;a \leq -4.9 \cdot 10^{-14}:\\
\;\;\;\;x - \frac{y}{\frac{a}{z}}\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if a < -5.2000000000000001e178 or 9.99999999999999944e71 < a

    1. Initial program 75.2%

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

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

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

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

    if -5.2000000000000001e178 < a < -4.89999999999999995e-14

    1. Initial program 70.6%

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

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

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

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

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

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

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

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

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

        \[\leadsto x + \mathsf{fma}\left(\frac{-\color{blue}{\left(\left(-t\right) + z\right)}}{a - t}, y, y\right) \]
      10. distribute-neg-in83.2%

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

        \[\leadsto x + \mathsf{fma}\left(\frac{\color{blue}{\left(-\left(-t\right)\right) - z}}{a - t}, y, y\right) \]
      12. remove-double-neg83.2%

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

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

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

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

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

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

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

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

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

        \[\leadsto x + \left(-\color{blue}{\frac{y}{\frac{a}{z}}}\right) \]
      3. distribute-neg-frac72.6%

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

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

    if -4.89999999999999995e-14 < a < 9.99999999999999944e71

    1. Initial program 80.2%

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -5.2 \cdot 10^{+178}:\\ \;\;\;\;y + x\\ \mathbf{elif}\;a \leq -4.9 \cdot 10^{-14}:\\ \;\;\;\;x - \frac{y}{\frac{a}{z}}\\ \mathbf{elif}\;a \leq 10^{+72}:\\ \;\;\;\;x + y \cdot \frac{z}{t}\\ \mathbf{else}:\\ \;\;\;\;y + x\\ \end{array} \]

Alternative 8: 82.5% accurate, 1.0× speedup?

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -1.65000000000000002e-47 or 3.8499999999999999e77 < t

    1. Initial program 56.8%

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

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

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

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

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

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

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

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

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

        \[\leadsto \left(-\color{blue}{\left(a - z\right) \cdot \frac{y}{t}}\right) + x \]
      6. distribute-lft-neg-in81.0%

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

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

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

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

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

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

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

    if -1.65000000000000002e-47 < t < 3.8499999999999999e77

    1. Initial program 94.4%

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

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

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

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

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

        \[\leadsto y + \left(x - \color{blue}{\frac{y}{\frac{a}{z}}}\right) \]
    6. Simplified85.4%

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

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

Alternative 9: 87.0% accurate, 1.0× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.75 \cdot 10^{+152} \lor \neg \left(a \leq 4.4 \cdot 10^{+73}\right):\\
\;\;\;\;y + \left(x - \frac{y}{\frac{a}{z}}\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if a < -1.74999999999999991e152 or 4.4e73 < a

    1. Initial program 74.9%

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

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

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

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

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

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

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

    if -1.74999999999999991e152 < a < 4.4e73

    1. Initial program 78.3%

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

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

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

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

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

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

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

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

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

        \[\leadsto x + \mathsf{fma}\left(\frac{-\color{blue}{\left(\left(-t\right) + z\right)}}{a - t}, y, y\right) \]
      10. distribute-neg-in85.9%

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

        \[\leadsto x + \mathsf{fma}\left(\frac{\color{blue}{\left(-\left(-t\right)\right) - z}}{a - t}, y, y\right) \]
      12. remove-double-neg85.9%

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

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

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

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

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

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

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

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

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

Alternative 10: 79.7% accurate, 1.0× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -3.80000000000000015e-47

    1. Initial program 57.4%

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

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

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

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

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

    if -3.80000000000000015e-47 < t < 2.6999999999999998e77

    1. Initial program 94.4%

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

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

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

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

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

        \[\leadsto y + \left(x - \color{blue}{\frac{y}{\frac{a}{z}}}\right) \]
    6. Simplified85.4%

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

    if 2.6999999999999998e77 < t

    1. Initial program 55.7%

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{y}{t} \cdot z} + x \]
    9. Applied egg-rr72.7%

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

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

Alternative 11: 82.5% accurate, 1.0× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -3.80000000000000015e-47

    1. Initial program 57.4%

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

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{y \cdot a - y \cdot z}{t} + x} \]
    5. Step-by-step derivation
      1. +-commutative72.8%

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

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

        \[\leadsto \color{blue}{x - \frac{y \cdot a - y \cdot z}{t}} \]
      4. distribute-lft-out--73.0%

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

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

        \[\leadsto x - \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\frac{y \cdot \left(a - z\right)}{t}\right)\right)} \]
      2. expm1-udef43.7%

        \[\leadsto x - \color{blue}{\left(e^{\mathsf{log1p}\left(\frac{y \cdot \left(a - z\right)}{t}\right)} - 1\right)} \]
    8. Applied egg-rr43.7%

      \[\leadsto x - \color{blue}{\left(e^{\mathsf{log1p}\left(\frac{y \cdot \left(a - z\right)}{t}\right)} - 1\right)} \]
    9. Step-by-step derivation
      1. expm1-def51.8%

        \[\leadsto x - \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\frac{y \cdot \left(a - z\right)}{t}\right)\right)} \]
      2. expm1-log1p73.0%

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

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

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

    if -3.80000000000000015e-47 < t < 3.2000000000000002e77

    1. Initial program 94.4%

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

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

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

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

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

        \[\leadsto y + \left(x - \color{blue}{\frac{y}{\frac{a}{z}}}\right) \]
    6. Simplified85.4%

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

    if 3.2000000000000002e77 < t

    1. Initial program 55.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 12: 77.1% accurate, 1.2× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.9 \cdot 10^{+23}:\\
\;\;\;\;y + x\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if a < -1.89999999999999987e23 or 8.2000000000000004e71 < a

    1. Initial program 73.0%

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

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

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

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

    if -1.89999999999999987e23 < a < 8.2000000000000004e71

    1. Initial program 80.5%

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -1.9 \cdot 10^{+23}:\\ \;\;\;\;y + x\\ \mathbf{elif}\;a \leq 8.2 \cdot 10^{+71}:\\ \;\;\;\;x + y \cdot \frac{z}{t}\\ \mathbf{else}:\\ \;\;\;\;y + x\\ \end{array} \]

Alternative 13: 61.2% accurate, 2.6× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq 1.08 \cdot 10^{+214}:\\
\;\;\;\;y + x\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < 1.08e214

    1. Initial program 80.4%

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

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

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

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

    if 1.08e214 < t

    1. Initial program 46.2%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq 1.08 \cdot 10^{+214}:\\ \;\;\;\;y + x\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 14: 51.2% accurate, 13.0× speedup?

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

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

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

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

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

    \[\leadsto \color{blue}{x} \]
  5. Final simplification50.1%

    \[\leadsto x \]

Developer target: 87.3% accurate, 0.3× speedup?

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

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

\mathbf{elif}\;t_2 < 1.4754293444577233 \cdot 10^{-239}:\\
\;\;\;\;\frac{y \cdot \left(a - z\right) - x \cdot t}{a - t}\\

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


\end{array}
\end{array}

Reproduce

?
herbie shell --seed 2023171 
(FPCore (x y z t a)
  :name "Graphics.Rendering.Plot.Render.Plot.Axis:renderAxisTick from plot-0.2.3.4, B"
  :precision binary64

  :herbie-target
  (if (< (- (+ x y) (/ (* (- z t) y) (- a t))) -1.3664970889390727e-7) (- (+ y x) (* (* (- z t) (/ 1.0 (- a t))) y)) (if (< (- (+ x y) (/ (* (- z t) y) (- a t))) 1.4754293444577233e-239) (/ (- (* y (- a z)) (* x t)) (- a t)) (- (+ y x) (* (* (- z t) (/ 1.0 (- a t))) y))))

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