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

Percentage Accurate: 86.2% → 98.2%
Time: 9.7s
Alternatives: 11
Speedup: 1.0×

Specification

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

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

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

The average percentage accuracy by input value. Horizontal axis shows value of an input variable; the variable is choosen in the title. Vertical axis is accuracy; higher is better. Red represent the original program, while blue represents Herbie's suggestion. These can be toggled with buttons below the plot. The line is an average while dots represent individual samples.

Accuracy vs Speed?

Herbie found 11 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: 86.2% accurate, 1.0× speedup?

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

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

Alternative 1: 98.2% accurate, 1.0× speedup?

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

\\
x + \frac{z - t}{a - t} \cdot y
\end{array}
Derivation
  1. Initial program 84.4%

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

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

      \[\leadsto x + \color{blue}{\frac{z - t}{\frac{a - t}{y}}} \]
    3. associate-/r/99.2%

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

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

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

Alternative 2: 87.6% accurate, 0.8× speedup?

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.51999999999999998e57 or 8.40000000000000061e-27 < z

    1. Initial program 83.1%

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

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

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

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

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

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

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

    if -1.51999999999999998e57 < z < 8.40000000000000061e-27

    1. Initial program 85.8%

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

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

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

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

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

        \[\leadsto x + \frac{\color{blue}{-t \cdot y}}{a - t} \]
      3. *-commutative79.6%

        \[\leadsto x + \frac{-\color{blue}{y \cdot t}}{a - t} \]
      4. distribute-rgt-neg-out79.6%

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

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

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

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

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

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

        \[\leadsto x + \frac{y}{\frac{\color{blue}{0 - \left(a - t\right)}}{-\left(-t\right)}} \]
      5. associate-+l-92.9%

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

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

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

        \[\leadsto x + \frac{y}{\frac{\color{blue}{t - a}}{-\left(-t\right)}} \]
      9. remove-double-neg92.9%

        \[\leadsto x + \frac{y}{\frac{t - a}{\color{blue}{t}}} \]
    8. Applied egg-rr92.9%

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

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

Alternative 3: 84.5% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.5 \cdot 10^{+79}:\\
\;\;\;\;x + y\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -4.49999999999999994e79 or 2.79999999999999989e88 < t

    1. Initial program 63.5%

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

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

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

      \[\leadsto \color{blue}{x + y} \]
    5. Step-by-step derivation
      1. +-commutative90.2%

        \[\leadsto \color{blue}{y + x} \]
    6. Simplified90.2%

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

    if -4.49999999999999994e79 < t < 2.79999999999999989e88

    1. Initial program 96.5%

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -4.5 \cdot 10^{+79}:\\ \;\;\;\;x + y\\ \mathbf{elif}\;t \leq 2.8 \cdot 10^{+88}:\\ \;\;\;\;x + z \cdot \frac{y}{a - t}\\ \mathbf{else}:\\ \;\;\;\;x + y\\ \end{array} \]

Alternative 4: 87.4% accurate, 0.8× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.6500000000000001e57

    1. Initial program 91.8%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto x - \color{blue}{\frac{y}{\frac{-\left(a - t\right)}{z - t}}} \]
      14. neg-sub099.9%

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

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

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

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

        \[\leadsto x - \frac{y}{\frac{\color{blue}{\left(-\left(-t\right)\right)} - a}{z - t}} \]
      19. remove-double-neg99.9%

        \[\leadsto x - \frac{y}{\frac{\color{blue}{t} - a}{z - t}} \]
    5. Applied egg-rr99.9%

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

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

    if -1.6500000000000001e57 < z < 2.55e-27

    1. Initial program 85.8%

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

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

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

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

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

        \[\leadsto x + \frac{\color{blue}{-t \cdot y}}{a - t} \]
      3. *-commutative79.6%

        \[\leadsto x + \frac{-\color{blue}{y \cdot t}}{a - t} \]
      4. distribute-rgt-neg-out79.6%

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

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

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

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

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

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

        \[\leadsto x + \frac{y}{\frac{\color{blue}{0 - \left(a - t\right)}}{-\left(-t\right)}} \]
      5. associate-+l-92.9%

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

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

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

        \[\leadsto x + \frac{y}{\frac{\color{blue}{t - a}}{-\left(-t\right)}} \]
      9. remove-double-neg92.9%

        \[\leadsto x + \frac{y}{\frac{t - a}{\color{blue}{t}}} \]
    8. Applied egg-rr92.9%

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

    if 2.55e-27 < z

    1. Initial program 78.4%

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.65 \cdot 10^{+57}:\\ \;\;\;\;x - \frac{y}{\frac{t - a}{z}}\\ \mathbf{elif}\;z \leq 2.55 \cdot 10^{-27}:\\ \;\;\;\;x + \frac{y}{\frac{t - a}{t}}\\ \mathbf{else}:\\ \;\;\;\;x + z \cdot \frac{y}{a - t}\\ \end{array} \]

Alternative 5: 76.9% accurate, 1.0× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.32 \cdot 10^{+70}:\\
\;\;\;\;x + y\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -1.3199999999999999e70 or 1.94999999999999996 < t

    1. Initial program 69.6%

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

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

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

      \[\leadsto \color{blue}{x + y} \]
    5. Step-by-step derivation
      1. +-commutative87.1%

        \[\leadsto \color{blue}{y + x} \]
    6. Simplified87.1%

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

    if -1.3199999999999999e70 < t < 1.94999999999999996

    1. Initial program 96.6%

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

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

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

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

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

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

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

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

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

Alternative 6: 76.9% accurate, 1.0× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.5 \cdot 10^{+68}:\\
\;\;\;\;x + y\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -4.5000000000000003e68 or 1.3500000000000001 < t

    1. Initial program 69.6%

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

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

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

      \[\leadsto \color{blue}{x + y} \]
    5. Step-by-step derivation
      1. +-commutative87.1%

        \[\leadsto \color{blue}{y + x} \]
    6. Simplified87.1%

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

    if -4.5000000000000003e68 < t < 1.3500000000000001

    1. Initial program 96.6%

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

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

        \[\leadsto x + \color{blue}{\frac{z - t}{\frac{a - t}{y}}} \]
      3. associate-/r/98.6%

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

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

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

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

Alternative 7: 95.9% accurate, 1.0× speedup?

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

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

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

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

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

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

Alternative 8: 61.1% accurate, 1.1× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3 \cdot 10^{+186}:\\
\;\;\;\;y \cdot \frac{z}{a}\\

\mathbf{elif}\;z \leq 4.2 \cdot 10^{+250}:\\
\;\;\;\;x + y\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -2.99999999999999982e186

    1. Initial program 87.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto x - \color{blue}{\frac{y}{\frac{-\left(a - t\right)}{z - t}}} \]
      14. neg-sub099.9%

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

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

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

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

        \[\leadsto x - \frac{y}{\frac{\color{blue}{\left(-\left(-t\right)\right)} - a}{z - t}} \]
      19. remove-double-neg99.9%

        \[\leadsto x - \frac{y}{\frac{\color{blue}{t} - a}{z - t}} \]
    5. Applied egg-rr99.9%

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

      \[\leadsto \color{blue}{-1 \cdot \frac{y \cdot z}{t - a}} \]
    7. Step-by-step derivation
      1. mul-1-neg62.2%

        \[\leadsto \color{blue}{-\frac{y \cdot z}{t - a}} \]
      2. *-commutative62.2%

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

        \[\leadsto -\color{blue}{z \cdot \frac{y}{t - a}} \]
      4. sub0-neg62.3%

        \[\leadsto \color{blue}{0 - z \cdot \frac{y}{t - a}} \]
      5. cancel-sign-sub-inv62.3%

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

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{y \cdot z}{t - a}} \]
    10. Step-by-step derivation
      1. mul-1-neg62.2%

        \[\leadsto \color{blue}{-\frac{y \cdot z}{t - a}} \]
      2. distribute-frac-neg62.2%

        \[\leadsto \color{blue}{\frac{-y \cdot z}{t - a}} \]
      3. distribute-rgt-neg-out62.2%

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

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

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

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

    if -2.99999999999999982e186 < z < 4.2000000000000003e250

    1. Initial program 84.7%

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

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

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

      \[\leadsto \color{blue}{x + y} \]
    5. Step-by-step derivation
      1. +-commutative70.2%

        \[\leadsto \color{blue}{y + x} \]
    6. Simplified70.2%

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

    if 4.2000000000000003e250 < z

    1. Initial program 68.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto x - \color{blue}{\frac{y}{\frac{-\left(a - t\right)}{z - t}}} \]
      14. neg-sub078.8%

        \[\leadsto x - \frac{y}{\frac{\color{blue}{0 - \left(a - t\right)}}{z - t}} \]
      15. sub-neg78.8%

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

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

        \[\leadsto x - \frac{y}{\frac{\color{blue}{\left(0 - \left(-t\right)\right) - a}}{z - t}} \]
      18. neg-sub078.8%

        \[\leadsto x - \frac{y}{\frac{\color{blue}{\left(-\left(-t\right)\right)} - a}{z - t}} \]
      19. remove-double-neg78.8%

        \[\leadsto x - \frac{y}{\frac{\color{blue}{t} - a}{z - t}} \]
    5. Applied egg-rr78.8%

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

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

        \[\leadsto \color{blue}{-\frac{y \cdot z}{t - a}} \]
      2. *-commutative57.5%

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

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

        \[\leadsto \color{blue}{0 - z \cdot \frac{y}{t - a}} \]
      5. cancel-sign-sub-inv84.7%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3 \cdot 10^{+186}:\\ \;\;\;\;y \cdot \frac{z}{a}\\ \mathbf{elif}\;z \leq 4.2 \cdot 10^{+250}:\\ \;\;\;\;x + y\\ \mathbf{else}:\\ \;\;\;\;z \cdot \frac{-y}{t}\\ \end{array} \]

Alternative 9: 60.8% accurate, 1.6× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.7 \cdot 10^{+186}:\\
\;\;\;\;y \cdot \frac{z}{a}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -2.6999999999999999e186

    1. Initial program 87.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto x - \color{blue}{\frac{y}{\frac{-\left(a - t\right)}{z - t}}} \]
      14. neg-sub099.9%

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

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

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

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

        \[\leadsto x - \frac{y}{\frac{\color{blue}{\left(-\left(-t\right)\right)} - a}{z - t}} \]
      19. remove-double-neg99.9%

        \[\leadsto x - \frac{y}{\frac{\color{blue}{t} - a}{z - t}} \]
    5. Applied egg-rr99.9%

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

      \[\leadsto \color{blue}{-1 \cdot \frac{y \cdot z}{t - a}} \]
    7. Step-by-step derivation
      1. mul-1-neg62.2%

        \[\leadsto \color{blue}{-\frac{y \cdot z}{t - a}} \]
      2. *-commutative62.2%

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

        \[\leadsto -\color{blue}{z \cdot \frac{y}{t - a}} \]
      4. sub0-neg62.3%

        \[\leadsto \color{blue}{0 - z \cdot \frac{y}{t - a}} \]
      5. cancel-sign-sub-inv62.3%

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

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{y \cdot z}{t - a}} \]
    10. Step-by-step derivation
      1. mul-1-neg62.2%

        \[\leadsto \color{blue}{-\frac{y \cdot z}{t - a}} \]
      2. distribute-frac-neg62.2%

        \[\leadsto \color{blue}{\frac{-y \cdot z}{t - a}} \]
      3. distribute-rgt-neg-out62.2%

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

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

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

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

    if -2.6999999999999999e186 < z

    1. Initial program 84.1%

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

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

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

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

        \[\leadsto \color{blue}{y + x} \]
    6. Simplified68.1%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.7 \cdot 10^{+186}:\\ \;\;\;\;y \cdot \frac{z}{a}\\ \mathbf{else}:\\ \;\;\;\;x + y\\ \end{array} \]

Alternative 10: 62.6% accurate, 2.2× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;a \leq 1.02 \cdot 10^{+192}:\\
\;\;\;\;x + y\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if a < 1.01999999999999996e192

    1. Initial program 83.8%

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

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

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

      \[\leadsto \color{blue}{x + y} \]
    5. Step-by-step derivation
      1. +-commutative65.3%

        \[\leadsto \color{blue}{y + x} \]
    6. Simplified65.3%

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

    if 1.01999999999999996e192 < a

    1. Initial program 91.0%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq 1.02 \cdot 10^{+192}:\\ \;\;\;\;x + y\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 11: 50.7% accurate, 11.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 84.4%

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

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

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

    \[\leadsto \color{blue}{x} \]
  5. Final simplification51.0%

    \[\leadsto x \]

Developer target: 98.4% accurate, 1.0× speedup?

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

\\
x + \frac{y}{\frac{a - t}{z - t}}
\end{array}

Reproduce

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

  :herbie-target
  (+ x (/ y (/ (- a t) (- z t))))

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