Optimisation.CirclePacking:place from circle-packing-0.1.0.4, E

Percentage Accurate: 93.1% → 97.6%
Time: 9.8s
Alternatives: 10
Speedup: 1.0×

Specification

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

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

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

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

Alternative 1: 97.6% accurate, 0.3× speedup?

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

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

\mathbf{elif}\;t\_1 \leq 4 \cdot 10^{+274}:\\
\;\;\;\;x + t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (/.f64 (*.f64 y (-.f64 z t)) a) < -2.00000000000000006e257 or 3.99999999999999969e274 < (/.f64 (*.f64 y (-.f64 z t)) a)

    1. Initial program 74.2%

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

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

        \[\leadsto x + \left(z - t\right) \cdot \color{blue}{\frac{y}{a}} \]
      3. cancel-sign-subN/A

        \[\leadsto x - \color{blue}{\left(\mathsf{neg}\left(\left(z - t\right)\right)\right) \cdot \frac{y}{a}} \]
      4. sub0-negN/A

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

        \[\leadsto x - \left(\left(0 - z\right) + t\right) \cdot \frac{\color{blue}{y}}{a} \]
      6. neg-sub0N/A

        \[\leadsto x - \left(\left(\mathsf{neg}\left(z\right)\right) + t\right) \cdot \frac{y}{a} \]
      7. +-commutativeN/A

        \[\leadsto x - \left(t + \left(\mathsf{neg}\left(z\right)\right)\right) \cdot \frac{\color{blue}{y}}{a} \]
      8. sub-negN/A

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

        \[\leadsto x - \frac{y}{a} \cdot \color{blue}{\left(t - z\right)} \]
      10. --lowering--.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{a} \cdot \left(t - z\right)\right)}\right) \]
      11. associate-*l/N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y \cdot \left(t - z\right)}{\color{blue}{a}}\right)\right) \]
      12. /-lowering-/.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(y \cdot \left(t - z\right)\right), \color{blue}{a}\right)\right) \]
      13. *-lowering-*.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(t - z\right)\right), a\right)\right) \]
      14. --lowering--.f6474.2%

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{\_.f64}\left(t, z\right)\right), a\right)\right) \]
    3. Simplified74.2%

      \[\leadsto \color{blue}{x - \frac{y \cdot \left(t - z\right)}{a}} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. *-commutativeN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{\left(t - z\right) \cdot y}{a}\right)\right) \]
      2. associate-/l*N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \color{blue}{\frac{y}{a}}\right)\right) \]
      3. *-commutativeN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y}{a} \cdot \color{blue}{\left(t - z\right)}\right)\right) \]
      4. *-lowering-*.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\left(\frac{y}{a}\right), \color{blue}{\left(t - z\right)}\right)\right) \]
      5. /-lowering-/.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, a\right), \left(\color{blue}{t} - z\right)\right)\right) \]
      6. --lowering--.f6499.9%

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, a\right), \mathsf{\_.f64}\left(t, \color{blue}{z}\right)\right)\right) \]
    6. Applied egg-rr99.9%

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

        \[\leadsto x - \frac{y}{\color{blue}{\frac{a}{t - z}}} \]
      2. --lowering--.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{\frac{a}{t - z}}\right)}\right) \]
      3. associate-/r/N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y}{a} \cdot \color{blue}{\left(t - z\right)}\right)\right) \]
      4. *-commutativeN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \color{blue}{\frac{y}{a}}\right)\right) \]
      5. clear-numN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \frac{1}{\color{blue}{\frac{a}{y}}}\right)\right) \]
      6. un-div-invN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{t - z}{\color{blue}{\frac{a}{y}}}\right)\right) \]
      7. /-lowering-/.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(t - z\right), \color{blue}{\left(\frac{a}{y}\right)}\right)\right) \]
      8. --lowering--.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{\_.f64}\left(t, z\right), \left(\frac{\color{blue}{a}}{y}\right)\right)\right) \]
      9. /-lowering-/.f6499.9%

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{\_.f64}\left(t, z\right), \mathsf{/.f64}\left(a, \color{blue}{y}\right)\right)\right) \]
    8. Applied egg-rr99.9%

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

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

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

        \[\leadsto \frac{\mathsf{neg}\left(y \cdot \left(t - z\right)\right)}{a} \]
      3. sub-negN/A

        \[\leadsto \frac{\mathsf{neg}\left(y \cdot \left(t + \left(\mathsf{neg}\left(z\right)\right)\right)\right)}{a} \]
      4. mul-1-negN/A

        \[\leadsto \frac{\mathsf{neg}\left(y \cdot \left(t + -1 \cdot z\right)\right)}{a} \]
      5. distribute-rgt-inN/A

        \[\leadsto \frac{\mathsf{neg}\left(\left(t \cdot y + \left(-1 \cdot z\right) \cdot y\right)\right)}{a} \]
      6. associate-*r*N/A

        \[\leadsto \frac{\mathsf{neg}\left(\left(t \cdot y + -1 \cdot \left(z \cdot y\right)\right)\right)}{a} \]
      7. *-commutativeN/A

        \[\leadsto \frac{\mathsf{neg}\left(\left(t \cdot y + -1 \cdot \left(y \cdot z\right)\right)\right)}{a} \]
      8. distribute-neg-inN/A

        \[\leadsto \frac{\left(\mathsf{neg}\left(t \cdot y\right)\right) + \left(\mathsf{neg}\left(-1 \cdot \left(y \cdot z\right)\right)\right)}{a} \]
      9. sub-negN/A

        \[\leadsto \frac{\left(\mathsf{neg}\left(t \cdot y\right)\right) - -1 \cdot \left(y \cdot z\right)}{a} \]
      10. div-subN/A

        \[\leadsto \frac{\mathsf{neg}\left(t \cdot y\right)}{a} - \color{blue}{\frac{-1 \cdot \left(y \cdot z\right)}{a}} \]
      11. distribute-lft-neg-inN/A

        \[\leadsto \frac{\left(\mathsf{neg}\left(t\right)\right) \cdot y}{a} - \frac{\color{blue}{-1} \cdot \left(y \cdot z\right)}{a} \]
      12. neg-mul-1N/A

        \[\leadsto \frac{\left(-1 \cdot t\right) \cdot y}{a} - \frac{-1 \cdot \left(y \cdot z\right)}{a} \]
      13. associate-*r/N/A

        \[\leadsto \left(-1 \cdot t\right) \cdot \frac{y}{a} - \frac{\color{blue}{-1 \cdot \left(y \cdot z\right)}}{a} \]
      14. *-commutativeN/A

        \[\leadsto \left(-1 \cdot t\right) \cdot \frac{y}{a} - \frac{-1 \cdot \left(z \cdot y\right)}{a} \]
      15. associate-*r*N/A

        \[\leadsto \left(-1 \cdot t\right) \cdot \frac{y}{a} - \frac{\left(-1 \cdot z\right) \cdot y}{a} \]
      16. associate-*r/N/A

        \[\leadsto \left(-1 \cdot t\right) \cdot \frac{y}{a} - \left(-1 \cdot z\right) \cdot \color{blue}{\frac{y}{a}} \]
      17. distribute-rgt-out--N/A

        \[\leadsto \frac{y}{a} \cdot \color{blue}{\left(-1 \cdot t - -1 \cdot z\right)} \]
      18. sub-negN/A

        \[\leadsto \frac{y}{a} \cdot \left(-1 \cdot t + \color{blue}{\left(\mathsf{neg}\left(-1 \cdot z\right)\right)}\right) \]
      19. mul-1-negN/A

        \[\leadsto \frac{y}{a} \cdot \left(-1 \cdot t + -1 \cdot \color{blue}{\left(-1 \cdot z\right)}\right) \]
      20. distribute-lft-inN/A

        \[\leadsto \frac{y}{a} \cdot \left(-1 \cdot \color{blue}{\left(t + -1 \cdot z\right)}\right) \]
      21. mul-1-negN/A

        \[\leadsto \frac{y}{a} \cdot \left(-1 \cdot \left(t + \left(\mathsf{neg}\left(z\right)\right)\right)\right) \]
    11. Simplified93.4%

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

    if -2.00000000000000006e257 < (/.f64 (*.f64 y (-.f64 z t)) a) < 3.99999999999999969e274

    1. Initial program 99.2%

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

Alternative 2: 85.8% accurate, 0.3× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (/.f64 (*.f64 y (-.f64 z t)) a) < -1.00000000000000005e32 or 9.99999999999999944e57 < (/.f64 (*.f64 y (-.f64 z t)) a)

    1. Initial program 84.9%

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

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

        \[\leadsto x + \left(z - t\right) \cdot \color{blue}{\frac{y}{a}} \]
      3. cancel-sign-subN/A

        \[\leadsto x - \color{blue}{\left(\mathsf{neg}\left(\left(z - t\right)\right)\right) \cdot \frac{y}{a}} \]
      4. sub0-negN/A

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

        \[\leadsto x - \left(\left(0 - z\right) + t\right) \cdot \frac{\color{blue}{y}}{a} \]
      6. neg-sub0N/A

        \[\leadsto x - \left(\left(\mathsf{neg}\left(z\right)\right) + t\right) \cdot \frac{y}{a} \]
      7. +-commutativeN/A

        \[\leadsto x - \left(t + \left(\mathsf{neg}\left(z\right)\right)\right) \cdot \frac{\color{blue}{y}}{a} \]
      8. sub-negN/A

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

        \[\leadsto x - \frac{y}{a} \cdot \color{blue}{\left(t - z\right)} \]
      10. --lowering--.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{a} \cdot \left(t - z\right)\right)}\right) \]
      11. associate-*l/N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y \cdot \left(t - z\right)}{\color{blue}{a}}\right)\right) \]
      12. /-lowering-/.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(y \cdot \left(t - z\right)\right), \color{blue}{a}\right)\right) \]
      13. *-lowering-*.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(t - z\right)\right), a\right)\right) \]
      14. --lowering--.f6484.9%

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{\_.f64}\left(t, z\right)\right), a\right)\right) \]
    3. Simplified84.9%

      \[\leadsto \color{blue}{x - \frac{y \cdot \left(t - z\right)}{a}} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. *-commutativeN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{\left(t - z\right) \cdot y}{a}\right)\right) \]
      2. associate-/l*N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \color{blue}{\frac{y}{a}}\right)\right) \]
      3. *-commutativeN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y}{a} \cdot \color{blue}{\left(t - z\right)}\right)\right) \]
      4. *-lowering-*.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\left(\frac{y}{a}\right), \color{blue}{\left(t - z\right)}\right)\right) \]
      5. /-lowering-/.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, a\right), \left(\color{blue}{t} - z\right)\right)\right) \]
      6. --lowering--.f6497.3%

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, a\right), \mathsf{\_.f64}\left(t, \color{blue}{z}\right)\right)\right) \]
    6. Applied egg-rr97.3%

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

        \[\leadsto x - \frac{y}{\color{blue}{\frac{a}{t - z}}} \]
      2. --lowering--.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{\frac{a}{t - z}}\right)}\right) \]
      3. associate-/r/N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y}{a} \cdot \color{blue}{\left(t - z\right)}\right)\right) \]
      4. *-commutativeN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \color{blue}{\frac{y}{a}}\right)\right) \]
      5. clear-numN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \frac{1}{\color{blue}{\frac{a}{y}}}\right)\right) \]
      6. un-div-invN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{t - z}{\color{blue}{\frac{a}{y}}}\right)\right) \]
      7. /-lowering-/.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(t - z\right), \color{blue}{\left(\frac{a}{y}\right)}\right)\right) \]
      8. --lowering--.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{\_.f64}\left(t, z\right), \left(\frac{\color{blue}{a}}{y}\right)\right)\right) \]
      9. /-lowering-/.f6497.5%

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{\_.f64}\left(t, z\right), \mathsf{/.f64}\left(a, \color{blue}{y}\right)\right)\right) \]
    8. Applied egg-rr97.5%

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

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

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

        \[\leadsto \frac{\mathsf{neg}\left(y \cdot \left(t - z\right)\right)}{a} \]
      3. sub-negN/A

        \[\leadsto \frac{\mathsf{neg}\left(y \cdot \left(t + \left(\mathsf{neg}\left(z\right)\right)\right)\right)}{a} \]
      4. mul-1-negN/A

        \[\leadsto \frac{\mathsf{neg}\left(y \cdot \left(t + -1 \cdot z\right)\right)}{a} \]
      5. distribute-rgt-inN/A

        \[\leadsto \frac{\mathsf{neg}\left(\left(t \cdot y + \left(-1 \cdot z\right) \cdot y\right)\right)}{a} \]
      6. associate-*r*N/A

        \[\leadsto \frac{\mathsf{neg}\left(\left(t \cdot y + -1 \cdot \left(z \cdot y\right)\right)\right)}{a} \]
      7. *-commutativeN/A

        \[\leadsto \frac{\mathsf{neg}\left(\left(t \cdot y + -1 \cdot \left(y \cdot z\right)\right)\right)}{a} \]
      8. distribute-neg-inN/A

        \[\leadsto \frac{\left(\mathsf{neg}\left(t \cdot y\right)\right) + \left(\mathsf{neg}\left(-1 \cdot \left(y \cdot z\right)\right)\right)}{a} \]
      9. sub-negN/A

        \[\leadsto \frac{\left(\mathsf{neg}\left(t \cdot y\right)\right) - -1 \cdot \left(y \cdot z\right)}{a} \]
      10. div-subN/A

        \[\leadsto \frac{\mathsf{neg}\left(t \cdot y\right)}{a} - \color{blue}{\frac{-1 \cdot \left(y \cdot z\right)}{a}} \]
      11. distribute-lft-neg-inN/A

        \[\leadsto \frac{\left(\mathsf{neg}\left(t\right)\right) \cdot y}{a} - \frac{\color{blue}{-1} \cdot \left(y \cdot z\right)}{a} \]
      12. neg-mul-1N/A

        \[\leadsto \frac{\left(-1 \cdot t\right) \cdot y}{a} - \frac{-1 \cdot \left(y \cdot z\right)}{a} \]
      13. associate-*r/N/A

        \[\leadsto \left(-1 \cdot t\right) \cdot \frac{y}{a} - \frac{\color{blue}{-1 \cdot \left(y \cdot z\right)}}{a} \]
      14. *-commutativeN/A

        \[\leadsto \left(-1 \cdot t\right) \cdot \frac{y}{a} - \frac{-1 \cdot \left(z \cdot y\right)}{a} \]
      15. associate-*r*N/A

        \[\leadsto \left(-1 \cdot t\right) \cdot \frac{y}{a} - \frac{\left(-1 \cdot z\right) \cdot y}{a} \]
      16. associate-*r/N/A

        \[\leadsto \left(-1 \cdot t\right) \cdot \frac{y}{a} - \left(-1 \cdot z\right) \cdot \color{blue}{\frac{y}{a}} \]
      17. distribute-rgt-out--N/A

        \[\leadsto \frac{y}{a} \cdot \color{blue}{\left(-1 \cdot t - -1 \cdot z\right)} \]
      18. sub-negN/A

        \[\leadsto \frac{y}{a} \cdot \left(-1 \cdot t + \color{blue}{\left(\mathsf{neg}\left(-1 \cdot z\right)\right)}\right) \]
      19. mul-1-negN/A

        \[\leadsto \frac{y}{a} \cdot \left(-1 \cdot t + -1 \cdot \color{blue}{\left(-1 \cdot z\right)}\right) \]
      20. distribute-lft-inN/A

        \[\leadsto \frac{y}{a} \cdot \left(-1 \cdot \color{blue}{\left(t + -1 \cdot z\right)}\right) \]
      21. mul-1-negN/A

        \[\leadsto \frac{y}{a} \cdot \left(-1 \cdot \left(t + \left(\mathsf{neg}\left(z\right)\right)\right)\right) \]
    11. Simplified86.5%

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

    if -1.00000000000000005e32 < (/.f64 (*.f64 y (-.f64 z t)) a) < 9.99999999999999944e57

    1. Initial program 99.0%

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

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

        \[\leadsto x + \left(z - t\right) \cdot \color{blue}{\frac{y}{a}} \]
      3. cancel-sign-subN/A

        \[\leadsto x - \color{blue}{\left(\mathsf{neg}\left(\left(z - t\right)\right)\right) \cdot \frac{y}{a}} \]
      4. sub0-negN/A

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

        \[\leadsto x - \left(\left(0 - z\right) + t\right) \cdot \frac{\color{blue}{y}}{a} \]
      6. neg-sub0N/A

        \[\leadsto x - \left(\left(\mathsf{neg}\left(z\right)\right) + t\right) \cdot \frac{y}{a} \]
      7. +-commutativeN/A

        \[\leadsto x - \left(t + \left(\mathsf{neg}\left(z\right)\right)\right) \cdot \frac{\color{blue}{y}}{a} \]
      8. sub-negN/A

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

        \[\leadsto x - \frac{y}{a} \cdot \color{blue}{\left(t - z\right)} \]
      10. --lowering--.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{a} \cdot \left(t - z\right)\right)}\right) \]
      11. associate-*l/N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y \cdot \left(t - z\right)}{\color{blue}{a}}\right)\right) \]
      12. /-lowering-/.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(y \cdot \left(t - z\right)\right), \color{blue}{a}\right)\right) \]
      13. *-lowering-*.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(t - z\right)\right), a\right)\right) \]
      14. --lowering--.f6499.0%

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{\_.f64}\left(t, z\right)\right), a\right)\right) \]
    3. Simplified99.0%

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

      \[\leadsto \color{blue}{x - -1 \cdot \frac{y \cdot z}{a}} \]
    6. Step-by-step derivation
      1. sub-negN/A

        \[\leadsto x + \color{blue}{\left(\mathsf{neg}\left(-1 \cdot \frac{y \cdot z}{a}\right)\right)} \]
      2. mul-1-negN/A

        \[\leadsto x + \left(\mathsf{neg}\left(\left(\mathsf{neg}\left(\frac{y \cdot z}{a}\right)\right)\right)\right) \]
      3. remove-double-negN/A

        \[\leadsto x + \frac{y \cdot z}{\color{blue}{a}} \]
      4. +-lowering-+.f64N/A

        \[\leadsto \mathsf{+.f64}\left(x, \color{blue}{\left(\frac{y \cdot z}{a}\right)}\right) \]
      5. /-lowering-/.f64N/A

        \[\leadsto \mathsf{+.f64}\left(x, \mathsf{/.f64}\left(\left(y \cdot z\right), \color{blue}{a}\right)\right) \]
      6. *-lowering-*.f6490.6%

        \[\leadsto \mathsf{+.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, z\right), a\right)\right) \]
    7. Simplified90.6%

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

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

Alternative 3: 78.4% accurate, 0.5× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -7.1999999999999996e225 or 4.39999999999999992e60 < t

    1. Initial program 85.9%

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

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

        \[\leadsto x + \left(z - t\right) \cdot \color{blue}{\frac{y}{a}} \]
      3. cancel-sign-subN/A

        \[\leadsto x - \color{blue}{\left(\mathsf{neg}\left(\left(z - t\right)\right)\right) \cdot \frac{y}{a}} \]
      4. sub0-negN/A

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

        \[\leadsto x - \left(\left(0 - z\right) + t\right) \cdot \frac{\color{blue}{y}}{a} \]
      6. neg-sub0N/A

        \[\leadsto x - \left(\left(\mathsf{neg}\left(z\right)\right) + t\right) \cdot \frac{y}{a} \]
      7. +-commutativeN/A

        \[\leadsto x - \left(t + \left(\mathsf{neg}\left(z\right)\right)\right) \cdot \frac{\color{blue}{y}}{a} \]
      8. sub-negN/A

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

        \[\leadsto x - \frac{y}{a} \cdot \color{blue}{\left(t - z\right)} \]
      10. --lowering--.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{a} \cdot \left(t - z\right)\right)}\right) \]
      11. associate-*l/N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y \cdot \left(t - z\right)}{\color{blue}{a}}\right)\right) \]
      12. /-lowering-/.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(y \cdot \left(t - z\right)\right), \color{blue}{a}\right)\right) \]
      13. *-lowering-*.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(t - z\right)\right), a\right)\right) \]
      14. --lowering--.f6485.9%

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{\_.f64}\left(t, z\right)\right), a\right)\right) \]
    3. Simplified85.9%

      \[\leadsto \color{blue}{x - \frac{y \cdot \left(t - z\right)}{a}} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. *-commutativeN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{\left(t - z\right) \cdot y}{a}\right)\right) \]
      2. associate-/l*N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \color{blue}{\frac{y}{a}}\right)\right) \]
      3. *-commutativeN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y}{a} \cdot \color{blue}{\left(t - z\right)}\right)\right) \]
      4. *-lowering-*.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\left(\frac{y}{a}\right), \color{blue}{\left(t - z\right)}\right)\right) \]
      5. /-lowering-/.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, a\right), \left(\color{blue}{t} - z\right)\right)\right) \]
      6. --lowering--.f6497.9%

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, a\right), \mathsf{\_.f64}\left(t, \color{blue}{z}\right)\right)\right) \]
    6. Applied egg-rr97.9%

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

        \[\leadsto x - \frac{y}{\color{blue}{\frac{a}{t - z}}} \]
      2. --lowering--.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{\frac{a}{t - z}}\right)}\right) \]
      3. associate-/r/N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y}{a} \cdot \color{blue}{\left(t - z\right)}\right)\right) \]
      4. *-commutativeN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \color{blue}{\frac{y}{a}}\right)\right) \]
      5. clear-numN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \frac{1}{\color{blue}{\frac{a}{y}}}\right)\right) \]
      6. un-div-invN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{t - z}{\color{blue}{\frac{a}{y}}}\right)\right) \]
      7. /-lowering-/.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(t - z\right), \color{blue}{\left(\frac{a}{y}\right)}\right)\right) \]
      8. --lowering--.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{\_.f64}\left(t, z\right), \left(\frac{\color{blue}{a}}{y}\right)\right)\right) \]
      9. /-lowering-/.f6497.7%

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{\_.f64}\left(t, z\right), \mathsf{/.f64}\left(a, \color{blue}{y}\right)\right)\right) \]
    8. Applied egg-rr97.7%

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

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

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

        \[\leadsto \frac{\mathsf{neg}\left(y \cdot \left(t - z\right)\right)}{a} \]
      3. sub-negN/A

        \[\leadsto \frac{\mathsf{neg}\left(y \cdot \left(t + \left(\mathsf{neg}\left(z\right)\right)\right)\right)}{a} \]
      4. mul-1-negN/A

        \[\leadsto \frac{\mathsf{neg}\left(y \cdot \left(t + -1 \cdot z\right)\right)}{a} \]
      5. distribute-rgt-inN/A

        \[\leadsto \frac{\mathsf{neg}\left(\left(t \cdot y + \left(-1 \cdot z\right) \cdot y\right)\right)}{a} \]
      6. associate-*r*N/A

        \[\leadsto \frac{\mathsf{neg}\left(\left(t \cdot y + -1 \cdot \left(z \cdot y\right)\right)\right)}{a} \]
      7. *-commutativeN/A

        \[\leadsto \frac{\mathsf{neg}\left(\left(t \cdot y + -1 \cdot \left(y \cdot z\right)\right)\right)}{a} \]
      8. distribute-neg-inN/A

        \[\leadsto \frac{\left(\mathsf{neg}\left(t \cdot y\right)\right) + \left(\mathsf{neg}\left(-1 \cdot \left(y \cdot z\right)\right)\right)}{a} \]
      9. sub-negN/A

        \[\leadsto \frac{\left(\mathsf{neg}\left(t \cdot y\right)\right) - -1 \cdot \left(y \cdot z\right)}{a} \]
      10. div-subN/A

        \[\leadsto \frac{\mathsf{neg}\left(t \cdot y\right)}{a} - \color{blue}{\frac{-1 \cdot \left(y \cdot z\right)}{a}} \]
      11. distribute-lft-neg-inN/A

        \[\leadsto \frac{\left(\mathsf{neg}\left(t\right)\right) \cdot y}{a} - \frac{\color{blue}{-1} \cdot \left(y \cdot z\right)}{a} \]
      12. neg-mul-1N/A

        \[\leadsto \frac{\left(-1 \cdot t\right) \cdot y}{a} - \frac{-1 \cdot \left(y \cdot z\right)}{a} \]
      13. associate-*r/N/A

        \[\leadsto \left(-1 \cdot t\right) \cdot \frac{y}{a} - \frac{\color{blue}{-1 \cdot \left(y \cdot z\right)}}{a} \]
      14. *-commutativeN/A

        \[\leadsto \left(-1 \cdot t\right) \cdot \frac{y}{a} - \frac{-1 \cdot \left(z \cdot y\right)}{a} \]
      15. associate-*r*N/A

        \[\leadsto \left(-1 \cdot t\right) \cdot \frac{y}{a} - \frac{\left(-1 \cdot z\right) \cdot y}{a} \]
      16. associate-*r/N/A

        \[\leadsto \left(-1 \cdot t\right) \cdot \frac{y}{a} - \left(-1 \cdot z\right) \cdot \color{blue}{\frac{y}{a}} \]
      17. distribute-rgt-out--N/A

        \[\leadsto \frac{y}{a} \cdot \color{blue}{\left(-1 \cdot t - -1 \cdot z\right)} \]
      18. sub-negN/A

        \[\leadsto \frac{y}{a} \cdot \left(-1 \cdot t + \color{blue}{\left(\mathsf{neg}\left(-1 \cdot z\right)\right)}\right) \]
      19. mul-1-negN/A

        \[\leadsto \frac{y}{a} \cdot \left(-1 \cdot t + -1 \cdot \color{blue}{\left(-1 \cdot z\right)}\right) \]
      20. distribute-lft-inN/A

        \[\leadsto \frac{y}{a} \cdot \left(-1 \cdot \color{blue}{\left(t + -1 \cdot z\right)}\right) \]
      21. mul-1-negN/A

        \[\leadsto \frac{y}{a} \cdot \left(-1 \cdot \left(t + \left(\mathsf{neg}\left(z\right)\right)\right)\right) \]
    11. Simplified82.3%

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

    if -7.1999999999999996e225 < t < 4.39999999999999992e60

    1. Initial program 92.4%

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

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

        \[\leadsto x + \left(z - t\right) \cdot \color{blue}{\frac{y}{a}} \]
      3. cancel-sign-subN/A

        \[\leadsto x - \color{blue}{\left(\mathsf{neg}\left(\left(z - t\right)\right)\right) \cdot \frac{y}{a}} \]
      4. sub0-negN/A

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

        \[\leadsto x - \left(\left(0 - z\right) + t\right) \cdot \frac{\color{blue}{y}}{a} \]
      6. neg-sub0N/A

        \[\leadsto x - \left(\left(\mathsf{neg}\left(z\right)\right) + t\right) \cdot \frac{y}{a} \]
      7. +-commutativeN/A

        \[\leadsto x - \left(t + \left(\mathsf{neg}\left(z\right)\right)\right) \cdot \frac{\color{blue}{y}}{a} \]
      8. sub-negN/A

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

        \[\leadsto x - \frac{y}{a} \cdot \color{blue}{\left(t - z\right)} \]
      10. --lowering--.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{a} \cdot \left(t - z\right)\right)}\right) \]
      11. associate-*l/N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y \cdot \left(t - z\right)}{\color{blue}{a}}\right)\right) \]
      12. /-lowering-/.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(y \cdot \left(t - z\right)\right), \color{blue}{a}\right)\right) \]
      13. *-lowering-*.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(t - z\right)\right), a\right)\right) \]
      14. --lowering--.f6492.4%

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{\_.f64}\left(t, z\right)\right), a\right)\right) \]
    3. Simplified92.4%

      \[\leadsto \color{blue}{x - \frac{y \cdot \left(t - z\right)}{a}} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. *-commutativeN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{\left(t - z\right) \cdot y}{a}\right)\right) \]
      2. associate-/l*N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \color{blue}{\frac{y}{a}}\right)\right) \]
      3. *-commutativeN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y}{a} \cdot \color{blue}{\left(t - z\right)}\right)\right) \]
      4. *-lowering-*.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\left(\frac{y}{a}\right), \color{blue}{\left(t - z\right)}\right)\right) \]
      5. /-lowering-/.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, a\right), \left(\color{blue}{t} - z\right)\right)\right) \]
      6. --lowering--.f6496.7%

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, a\right), \mathsf{\_.f64}\left(t, \color{blue}{z}\right)\right)\right) \]
    6. Applied egg-rr96.7%

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

        \[\leadsto x - \frac{y}{\color{blue}{\frac{a}{t - z}}} \]
      2. --lowering--.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{\frac{a}{t - z}}\right)}\right) \]
      3. associate-/r/N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y}{a} \cdot \color{blue}{\left(t - z\right)}\right)\right) \]
      4. *-commutativeN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \color{blue}{\frac{y}{a}}\right)\right) \]
      5. clear-numN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \frac{1}{\color{blue}{\frac{a}{y}}}\right)\right) \]
      6. un-div-invN/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{t - z}{\color{blue}{\frac{a}{y}}}\right)\right) \]
      7. /-lowering-/.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(t - z\right), \color{blue}{\left(\frac{a}{y}\right)}\right)\right) \]
      8. --lowering--.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{\_.f64}\left(t, z\right), \left(\frac{\color{blue}{a}}{y}\right)\right)\right) \]
      9. /-lowering-/.f6497.0%

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{\_.f64}\left(t, z\right), \mathsf{/.f64}\left(a, \color{blue}{y}\right)\right)\right) \]
    8. Applied egg-rr97.0%

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

      \[\leadsto \color{blue}{x - -1 \cdot \frac{y \cdot z}{a}} \]
    10. Step-by-step derivation
      1. cancel-sign-sub-invN/A

        \[\leadsto x + \color{blue}{\left(\mathsf{neg}\left(-1\right)\right) \cdot \frac{y \cdot z}{a}} \]
      2. metadata-evalN/A

        \[\leadsto x + 1 \cdot \frac{\color{blue}{y \cdot z}}{a} \]
      3. *-lft-identityN/A

        \[\leadsto x + \frac{y \cdot z}{\color{blue}{a}} \]
      4. +-lowering-+.f64N/A

        \[\leadsto \mathsf{+.f64}\left(x, \color{blue}{\left(\frac{y \cdot z}{a}\right)}\right) \]
      5. *-commutativeN/A

        \[\leadsto \mathsf{+.f64}\left(x, \left(\frac{z \cdot y}{a}\right)\right) \]
      6. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(x, \left(z \cdot \color{blue}{\frac{y}{a}}\right)\right) \]
      7. *-lowering-*.f64N/A

        \[\leadsto \mathsf{+.f64}\left(x, \mathsf{*.f64}\left(z, \color{blue}{\left(\frac{y}{a}\right)}\right)\right) \]
      8. /-lowering-/.f6482.8%

        \[\leadsto \mathsf{+.f64}\left(x, \mathsf{*.f64}\left(z, \mathsf{/.f64}\left(y, \color{blue}{a}\right)\right)\right) \]
    11. Simplified82.8%

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

Alternative 4: 69.1% accurate, 0.5× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if a < -1.3600000000000001e90 or 1.65000000000000016e107 < a

    1. Initial program 77.8%

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

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

        \[\leadsto x + \left(z - t\right) \cdot \color{blue}{\frac{y}{a}} \]
      3. cancel-sign-subN/A

        \[\leadsto x - \color{blue}{\left(\mathsf{neg}\left(\left(z - t\right)\right)\right) \cdot \frac{y}{a}} \]
      4. sub0-negN/A

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

        \[\leadsto x - \left(\left(0 - z\right) + t\right) \cdot \frac{\color{blue}{y}}{a} \]
      6. neg-sub0N/A

        \[\leadsto x - \left(\left(\mathsf{neg}\left(z\right)\right) + t\right) \cdot \frac{y}{a} \]
      7. +-commutativeN/A

        \[\leadsto x - \left(t + \left(\mathsf{neg}\left(z\right)\right)\right) \cdot \frac{\color{blue}{y}}{a} \]
      8. sub-negN/A

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

        \[\leadsto x - \frac{y}{a} \cdot \color{blue}{\left(t - z\right)} \]
      10. --lowering--.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{a} \cdot \left(t - z\right)\right)}\right) \]
      11. associate-*l/N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y \cdot \left(t - z\right)}{\color{blue}{a}}\right)\right) \]
      12. /-lowering-/.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(y \cdot \left(t - z\right)\right), \color{blue}{a}\right)\right) \]
      13. *-lowering-*.f64N/A

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(t - z\right)\right), a\right)\right) \]
      14. --lowering--.f6477.8%

        \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{\_.f64}\left(t, z\right)\right), a\right)\right) \]
    3. Simplified77.8%

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

      \[\leadsto \color{blue}{x} \]
    6. Step-by-step derivation
      1. Simplified68.2%

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

      if -1.3600000000000001e90 < a < 1.65000000000000016e107

      1. Initial program 97.1%

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

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

          \[\leadsto x + \left(z - t\right) \cdot \color{blue}{\frac{y}{a}} \]
        3. cancel-sign-subN/A

          \[\leadsto x - \color{blue}{\left(\mathsf{neg}\left(\left(z - t\right)\right)\right) \cdot \frac{y}{a}} \]
        4. sub0-negN/A

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

          \[\leadsto x - \left(\left(0 - z\right) + t\right) \cdot \frac{\color{blue}{y}}{a} \]
        6. neg-sub0N/A

          \[\leadsto x - \left(\left(\mathsf{neg}\left(z\right)\right) + t\right) \cdot \frac{y}{a} \]
        7. +-commutativeN/A

          \[\leadsto x - \left(t + \left(\mathsf{neg}\left(z\right)\right)\right) \cdot \frac{\color{blue}{y}}{a} \]
        8. sub-negN/A

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

          \[\leadsto x - \frac{y}{a} \cdot \color{blue}{\left(t - z\right)} \]
        10. --lowering--.f64N/A

          \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{a} \cdot \left(t - z\right)\right)}\right) \]
        11. associate-*l/N/A

          \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y \cdot \left(t - z\right)}{\color{blue}{a}}\right)\right) \]
        12. /-lowering-/.f64N/A

          \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(y \cdot \left(t - z\right)\right), \color{blue}{a}\right)\right) \]
        13. *-lowering-*.f64N/A

          \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(t - z\right)\right), a\right)\right) \]
        14. --lowering--.f6497.1%

          \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{\_.f64}\left(t, z\right)\right), a\right)\right) \]
      3. Simplified97.1%

        \[\leadsto \color{blue}{x - \frac{y \cdot \left(t - z\right)}{a}} \]
      4. Add Preprocessing
      5. Step-by-step derivation
        1. *-commutativeN/A

          \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{\left(t - z\right) \cdot y}{a}\right)\right) \]
        2. associate-/l*N/A

          \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \color{blue}{\frac{y}{a}}\right)\right) \]
        3. *-commutativeN/A

          \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y}{a} \cdot \color{blue}{\left(t - z\right)}\right)\right) \]
        4. *-lowering-*.f64N/A

          \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\left(\frac{y}{a}\right), \color{blue}{\left(t - z\right)}\right)\right) \]
        5. /-lowering-/.f64N/A

          \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, a\right), \left(\color{blue}{t} - z\right)\right)\right) \]
        6. --lowering--.f6497.5%

          \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, a\right), \mathsf{\_.f64}\left(t, \color{blue}{z}\right)\right)\right) \]
      6. Applied egg-rr97.5%

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

          \[\leadsto x - \frac{y}{\color{blue}{\frac{a}{t - z}}} \]
        2. --lowering--.f64N/A

          \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{\frac{a}{t - z}}\right)}\right) \]
        3. associate-/r/N/A

          \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y}{a} \cdot \color{blue}{\left(t - z\right)}\right)\right) \]
        4. *-commutativeN/A

          \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \color{blue}{\frac{y}{a}}\right)\right) \]
        5. clear-numN/A

          \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \frac{1}{\color{blue}{\frac{a}{y}}}\right)\right) \]
        6. un-div-invN/A

          \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{t - z}{\color{blue}{\frac{a}{y}}}\right)\right) \]
        7. /-lowering-/.f64N/A

          \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(t - z\right), \color{blue}{\left(\frac{a}{y}\right)}\right)\right) \]
        8. --lowering--.f64N/A

          \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{\_.f64}\left(t, z\right), \left(\frac{\color{blue}{a}}{y}\right)\right)\right) \]
        9. /-lowering-/.f6497.8%

          \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{\_.f64}\left(t, z\right), \mathsf{/.f64}\left(a, \color{blue}{y}\right)\right)\right) \]
      8. Applied egg-rr97.8%

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

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

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

          \[\leadsto \frac{\mathsf{neg}\left(y \cdot \left(t - z\right)\right)}{a} \]
        3. sub-negN/A

          \[\leadsto \frac{\mathsf{neg}\left(y \cdot \left(t + \left(\mathsf{neg}\left(z\right)\right)\right)\right)}{a} \]
        4. mul-1-negN/A

          \[\leadsto \frac{\mathsf{neg}\left(y \cdot \left(t + -1 \cdot z\right)\right)}{a} \]
        5. distribute-rgt-inN/A

          \[\leadsto \frac{\mathsf{neg}\left(\left(t \cdot y + \left(-1 \cdot z\right) \cdot y\right)\right)}{a} \]
        6. associate-*r*N/A

          \[\leadsto \frac{\mathsf{neg}\left(\left(t \cdot y + -1 \cdot \left(z \cdot y\right)\right)\right)}{a} \]
        7. *-commutativeN/A

          \[\leadsto \frac{\mathsf{neg}\left(\left(t \cdot y + -1 \cdot \left(y \cdot z\right)\right)\right)}{a} \]
        8. distribute-neg-inN/A

          \[\leadsto \frac{\left(\mathsf{neg}\left(t \cdot y\right)\right) + \left(\mathsf{neg}\left(-1 \cdot \left(y \cdot z\right)\right)\right)}{a} \]
        9. sub-negN/A

          \[\leadsto \frac{\left(\mathsf{neg}\left(t \cdot y\right)\right) - -1 \cdot \left(y \cdot z\right)}{a} \]
        10. div-subN/A

          \[\leadsto \frac{\mathsf{neg}\left(t \cdot y\right)}{a} - \color{blue}{\frac{-1 \cdot \left(y \cdot z\right)}{a}} \]
        11. distribute-lft-neg-inN/A

          \[\leadsto \frac{\left(\mathsf{neg}\left(t\right)\right) \cdot y}{a} - \frac{\color{blue}{-1} \cdot \left(y \cdot z\right)}{a} \]
        12. neg-mul-1N/A

          \[\leadsto \frac{\left(-1 \cdot t\right) \cdot y}{a} - \frac{-1 \cdot \left(y \cdot z\right)}{a} \]
        13. associate-*r/N/A

          \[\leadsto \left(-1 \cdot t\right) \cdot \frac{y}{a} - \frac{\color{blue}{-1 \cdot \left(y \cdot z\right)}}{a} \]
        14. *-commutativeN/A

          \[\leadsto \left(-1 \cdot t\right) \cdot \frac{y}{a} - \frac{-1 \cdot \left(z \cdot y\right)}{a} \]
        15. associate-*r*N/A

          \[\leadsto \left(-1 \cdot t\right) \cdot \frac{y}{a} - \frac{\left(-1 \cdot z\right) \cdot y}{a} \]
        16. associate-*r/N/A

          \[\leadsto \left(-1 \cdot t\right) \cdot \frac{y}{a} - \left(-1 \cdot z\right) \cdot \color{blue}{\frac{y}{a}} \]
        17. distribute-rgt-out--N/A

          \[\leadsto \frac{y}{a} \cdot \color{blue}{\left(-1 \cdot t - -1 \cdot z\right)} \]
        18. sub-negN/A

          \[\leadsto \frac{y}{a} \cdot \left(-1 \cdot t + \color{blue}{\left(\mathsf{neg}\left(-1 \cdot z\right)\right)}\right) \]
        19. mul-1-negN/A

          \[\leadsto \frac{y}{a} \cdot \left(-1 \cdot t + -1 \cdot \color{blue}{\left(-1 \cdot z\right)}\right) \]
        20. distribute-lft-inN/A

          \[\leadsto \frac{y}{a} \cdot \left(-1 \cdot \color{blue}{\left(t + -1 \cdot z\right)}\right) \]
        21. mul-1-negN/A

          \[\leadsto \frac{y}{a} \cdot \left(-1 \cdot \left(t + \left(\mathsf{neg}\left(z\right)\right)\right)\right) \]
      11. Simplified75.5%

        \[\leadsto \color{blue}{\frac{y}{a} \cdot \left(z - t\right)} \]
    7. Recombined 2 regimes into one program.
    8. Add Preprocessing

    Alternative 5: 50.4% accurate, 0.6× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;a \leq -2.3 \cdot 10^{+35}:\\ \;\;\;\;x\\ \mathbf{elif}\;a \leq 4.4 \cdot 10^{-62}:\\ \;\;\;\;\frac{z \cdot y}{a}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
    (FPCore (x y z t a)
     :precision binary64
     (if (<= a -2.3e+35) x (if (<= a 4.4e-62) (/ (* z y) a) x)))
    double code(double x, double y, double z, double t, double a) {
    	double tmp;
    	if (a <= -2.3e+35) {
    		tmp = x;
    	} else if (a <= 4.4e-62) {
    		tmp = (z * y) / a;
    	} else {
    		tmp = x;
    	}
    	return tmp;
    }
    
    real(8) function code(x, y, z, t, a)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        real(8), intent (in) :: z
        real(8), intent (in) :: t
        real(8), intent (in) :: a
        real(8) :: tmp
        if (a <= (-2.3d+35)) then
            tmp = x
        else if (a <= 4.4d-62) then
            tmp = (z * y) / a
        else
            tmp = x
        end if
        code = tmp
    end function
    
    public static double code(double x, double y, double z, double t, double a) {
    	double tmp;
    	if (a <= -2.3e+35) {
    		tmp = x;
    	} else if (a <= 4.4e-62) {
    		tmp = (z * y) / a;
    	} else {
    		tmp = x;
    	}
    	return tmp;
    }
    
    def code(x, y, z, t, a):
    	tmp = 0
    	if a <= -2.3e+35:
    		tmp = x
    	elif a <= 4.4e-62:
    		tmp = (z * y) / a
    	else:
    		tmp = x
    	return tmp
    
    function code(x, y, z, t, a)
    	tmp = 0.0
    	if (a <= -2.3e+35)
    		tmp = x;
    	elseif (a <= 4.4e-62)
    		tmp = Float64(Float64(z * y) / a);
    	else
    		tmp = x;
    	end
    	return tmp
    end
    
    function tmp_2 = code(x, y, z, t, a)
    	tmp = 0.0;
    	if (a <= -2.3e+35)
    		tmp = x;
    	elseif (a <= 4.4e-62)
    		tmp = (z * y) / a;
    	else
    		tmp = x;
    	end
    	tmp_2 = tmp;
    end
    
    code[x_, y_, z_, t_, a_] := If[LessEqual[a, -2.3e+35], x, If[LessEqual[a, 4.4e-62], N[(N[(z * y), $MachinePrecision] / a), $MachinePrecision], x]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;a \leq -2.3 \cdot 10^{+35}:\\
    \;\;\;\;x\\
    
    \mathbf{elif}\;a \leq 4.4 \cdot 10^{-62}:\\
    \;\;\;\;\frac{z \cdot y}{a}\\
    
    \mathbf{else}:\\
    \;\;\;\;x\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if a < -2.2999999999999998e35 or 4.40000000000000035e-62 < a

      1. Initial program 83.5%

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

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

          \[\leadsto x + \left(z - t\right) \cdot \color{blue}{\frac{y}{a}} \]
        3. cancel-sign-subN/A

          \[\leadsto x - \color{blue}{\left(\mathsf{neg}\left(\left(z - t\right)\right)\right) \cdot \frac{y}{a}} \]
        4. sub0-negN/A

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

          \[\leadsto x - \left(\left(0 - z\right) + t\right) \cdot \frac{\color{blue}{y}}{a} \]
        6. neg-sub0N/A

          \[\leadsto x - \left(\left(\mathsf{neg}\left(z\right)\right) + t\right) \cdot \frac{y}{a} \]
        7. +-commutativeN/A

          \[\leadsto x - \left(t + \left(\mathsf{neg}\left(z\right)\right)\right) \cdot \frac{\color{blue}{y}}{a} \]
        8. sub-negN/A

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

          \[\leadsto x - \frac{y}{a} \cdot \color{blue}{\left(t - z\right)} \]
        10. --lowering--.f64N/A

          \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{a} \cdot \left(t - z\right)\right)}\right) \]
        11. associate-*l/N/A

          \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y \cdot \left(t - z\right)}{\color{blue}{a}}\right)\right) \]
        12. /-lowering-/.f64N/A

          \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(y \cdot \left(t - z\right)\right), \color{blue}{a}\right)\right) \]
        13. *-lowering-*.f64N/A

          \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(t - z\right)\right), a\right)\right) \]
        14. --lowering--.f6483.5%

          \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{\_.f64}\left(t, z\right)\right), a\right)\right) \]
      3. Simplified83.5%

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

        \[\leadsto \color{blue}{x} \]
      6. Step-by-step derivation
        1. Simplified56.0%

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

        if -2.2999999999999998e35 < a < 4.40000000000000035e-62

        1. Initial program 99.0%

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

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

            \[\leadsto x + \left(z - t\right) \cdot \color{blue}{\frac{y}{a}} \]
          3. cancel-sign-subN/A

            \[\leadsto x - \color{blue}{\left(\mathsf{neg}\left(\left(z - t\right)\right)\right) \cdot \frac{y}{a}} \]
          4. sub0-negN/A

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

            \[\leadsto x - \left(\left(0 - z\right) + t\right) \cdot \frac{\color{blue}{y}}{a} \]
          6. neg-sub0N/A

            \[\leadsto x - \left(\left(\mathsf{neg}\left(z\right)\right) + t\right) \cdot \frac{y}{a} \]
          7. +-commutativeN/A

            \[\leadsto x - \left(t + \left(\mathsf{neg}\left(z\right)\right)\right) \cdot \frac{\color{blue}{y}}{a} \]
          8. sub-negN/A

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

            \[\leadsto x - \frac{y}{a} \cdot \color{blue}{\left(t - z\right)} \]
          10. --lowering--.f64N/A

            \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{a} \cdot \left(t - z\right)\right)}\right) \]
          11. associate-*l/N/A

            \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y \cdot \left(t - z\right)}{\color{blue}{a}}\right)\right) \]
          12. /-lowering-/.f64N/A

            \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(y \cdot \left(t - z\right)\right), \color{blue}{a}\right)\right) \]
          13. *-lowering-*.f64N/A

            \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(t - z\right)\right), a\right)\right) \]
          14. --lowering--.f6499.0%

            \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{\_.f64}\left(t, z\right)\right), a\right)\right) \]
        3. Simplified99.0%

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

          \[\leadsto \color{blue}{\frac{y \cdot z}{a}} \]
        6. Step-by-step derivation
          1. /-lowering-/.f64N/A

            \[\leadsto \mathsf{/.f64}\left(\left(y \cdot z\right), \color{blue}{a}\right) \]
          2. *-lowering-*.f6454.1%

            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, z\right), a\right) \]
        7. Simplified54.1%

          \[\leadsto \color{blue}{\frac{y \cdot z}{a}} \]
      7. Recombined 2 regimes into one program.
      8. Final simplification55.1%

        \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -2.3 \cdot 10^{+35}:\\ \;\;\;\;x\\ \mathbf{elif}\;a \leq 4.4 \cdot 10^{-62}:\\ \;\;\;\;\frac{z \cdot y}{a}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]
      9. Add Preprocessing

      Alternative 6: 51.2% accurate, 0.6× speedup?

      \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;a \leq -1.2 \cdot 10^{+32}:\\ \;\;\;\;x\\ \mathbf{elif}\;a \leq 5.5 \cdot 10^{-62}:\\ \;\;\;\;\frac{z}{\frac{a}{y}}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
      (FPCore (x y z t a)
       :precision binary64
       (if (<= a -1.2e+32) x (if (<= a 5.5e-62) (/ z (/ a y)) x)))
      double code(double x, double y, double z, double t, double a) {
      	double tmp;
      	if (a <= -1.2e+32) {
      		tmp = x;
      	} else if (a <= 5.5e-62) {
      		tmp = z / (a / 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.2d+32)) then
              tmp = x
          else if (a <= 5.5d-62) then
              tmp = z / (a / 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.2e+32) {
      		tmp = x;
      	} else if (a <= 5.5e-62) {
      		tmp = z / (a / y);
      	} else {
      		tmp = x;
      	}
      	return tmp;
      }
      
      def code(x, y, z, t, a):
      	tmp = 0
      	if a <= -1.2e+32:
      		tmp = x
      	elif a <= 5.5e-62:
      		tmp = z / (a / y)
      	else:
      		tmp = x
      	return tmp
      
      function code(x, y, z, t, a)
      	tmp = 0.0
      	if (a <= -1.2e+32)
      		tmp = x;
      	elseif (a <= 5.5e-62)
      		tmp = Float64(z / Float64(a / y));
      	else
      		tmp = x;
      	end
      	return tmp
      end
      
      function tmp_2 = code(x, y, z, t, a)
      	tmp = 0.0;
      	if (a <= -1.2e+32)
      		tmp = x;
      	elseif (a <= 5.5e-62)
      		tmp = z / (a / y);
      	else
      		tmp = x;
      	end
      	tmp_2 = tmp;
      end
      
      code[x_, y_, z_, t_, a_] := If[LessEqual[a, -1.2e+32], x, If[LessEqual[a, 5.5e-62], N[(z / N[(a / y), $MachinePrecision]), $MachinePrecision], x]]
      
      \begin{array}{l}
      
      \\
      \begin{array}{l}
      \mathbf{if}\;a \leq -1.2 \cdot 10^{+32}:\\
      \;\;\;\;x\\
      
      \mathbf{elif}\;a \leq 5.5 \cdot 10^{-62}:\\
      \;\;\;\;\frac{z}{\frac{a}{y}}\\
      
      \mathbf{else}:\\
      \;\;\;\;x\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 2 regimes
      2. if a < -1.19999999999999996e32 or 5.50000000000000022e-62 < a

        1. Initial program 83.5%

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

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

            \[\leadsto x + \left(z - t\right) \cdot \color{blue}{\frac{y}{a}} \]
          3. cancel-sign-subN/A

            \[\leadsto x - \color{blue}{\left(\mathsf{neg}\left(\left(z - t\right)\right)\right) \cdot \frac{y}{a}} \]
          4. sub0-negN/A

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

            \[\leadsto x - \left(\left(0 - z\right) + t\right) \cdot \frac{\color{blue}{y}}{a} \]
          6. neg-sub0N/A

            \[\leadsto x - \left(\left(\mathsf{neg}\left(z\right)\right) + t\right) \cdot \frac{y}{a} \]
          7. +-commutativeN/A

            \[\leadsto x - \left(t + \left(\mathsf{neg}\left(z\right)\right)\right) \cdot \frac{\color{blue}{y}}{a} \]
          8. sub-negN/A

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

            \[\leadsto x - \frac{y}{a} \cdot \color{blue}{\left(t - z\right)} \]
          10. --lowering--.f64N/A

            \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{a} \cdot \left(t - z\right)\right)}\right) \]
          11. associate-*l/N/A

            \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y \cdot \left(t - z\right)}{\color{blue}{a}}\right)\right) \]
          12. /-lowering-/.f64N/A

            \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(y \cdot \left(t - z\right)\right), \color{blue}{a}\right)\right) \]
          13. *-lowering-*.f64N/A

            \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(t - z\right)\right), a\right)\right) \]
          14. --lowering--.f6483.5%

            \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{\_.f64}\left(t, z\right)\right), a\right)\right) \]
        3. Simplified83.5%

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

          \[\leadsto \color{blue}{x} \]
        6. Step-by-step derivation
          1. Simplified56.0%

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

          if -1.19999999999999996e32 < a < 5.50000000000000022e-62

          1. Initial program 99.0%

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

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

              \[\leadsto x + \left(z - t\right) \cdot \color{blue}{\frac{y}{a}} \]
            3. cancel-sign-subN/A

              \[\leadsto x - \color{blue}{\left(\mathsf{neg}\left(\left(z - t\right)\right)\right) \cdot \frac{y}{a}} \]
            4. sub0-negN/A

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

              \[\leadsto x - \left(\left(0 - z\right) + t\right) \cdot \frac{\color{blue}{y}}{a} \]
            6. neg-sub0N/A

              \[\leadsto x - \left(\left(\mathsf{neg}\left(z\right)\right) + t\right) \cdot \frac{y}{a} \]
            7. +-commutativeN/A

              \[\leadsto x - \left(t + \left(\mathsf{neg}\left(z\right)\right)\right) \cdot \frac{\color{blue}{y}}{a} \]
            8. sub-negN/A

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

              \[\leadsto x - \frac{y}{a} \cdot \color{blue}{\left(t - z\right)} \]
            10. --lowering--.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{a} \cdot \left(t - z\right)\right)}\right) \]
            11. associate-*l/N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y \cdot \left(t - z\right)}{\color{blue}{a}}\right)\right) \]
            12. /-lowering-/.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(y \cdot \left(t - z\right)\right), \color{blue}{a}\right)\right) \]
            13. *-lowering-*.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(t - z\right)\right), a\right)\right) \]
            14. --lowering--.f6499.0%

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{\_.f64}\left(t, z\right)\right), a\right)\right) \]
          3. Simplified99.0%

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

            \[\leadsto \color{blue}{\frac{y \cdot z}{a}} \]
          6. Step-by-step derivation
            1. /-lowering-/.f64N/A

              \[\leadsto \mathsf{/.f64}\left(\left(y \cdot z\right), \color{blue}{a}\right) \]
            2. *-lowering-*.f6454.1%

              \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, z\right), a\right) \]
          7. Simplified54.1%

            \[\leadsto \color{blue}{\frac{y \cdot z}{a}} \]
          8. Step-by-step derivation
            1. clear-numN/A

              \[\leadsto \frac{1}{\color{blue}{\frac{a}{y \cdot z}}} \]
            2. associate-/r*N/A

              \[\leadsto \frac{1}{\frac{\frac{a}{y}}{\color{blue}{z}}} \]
            3. clear-numN/A

              \[\leadsto \frac{z}{\color{blue}{\frac{a}{y}}} \]
            4. /-lowering-/.f64N/A

              \[\leadsto \mathsf{/.f64}\left(z, \color{blue}{\left(\frac{a}{y}\right)}\right) \]
            5. /-lowering-/.f6453.1%

              \[\leadsto \mathsf{/.f64}\left(z, \mathsf{/.f64}\left(a, \color{blue}{y}\right)\right) \]
          9. Applied egg-rr53.1%

            \[\leadsto \color{blue}{\frac{z}{\frac{a}{y}}} \]
        7. Recombined 2 regimes into one program.
        8. Add Preprocessing

        Alternative 7: 51.2% accurate, 0.6× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;a \leq -2.5 \cdot 10^{+32}:\\ \;\;\;\;x\\ \mathbf{elif}\;a \leq 1.05 \cdot 10^{-61}:\\ \;\;\;\;z \cdot \frac{y}{a}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
        (FPCore (x y z t a)
         :precision binary64
         (if (<= a -2.5e+32) x (if (<= a 1.05e-61) (* z (/ y a)) x)))
        double code(double x, double y, double z, double t, double a) {
        	double tmp;
        	if (a <= -2.5e+32) {
        		tmp = x;
        	} else if (a <= 1.05e-61) {
        		tmp = z * (y / a);
        	} else {
        		tmp = x;
        	}
        	return tmp;
        }
        
        real(8) function code(x, y, z, t, a)
            real(8), intent (in) :: x
            real(8), intent (in) :: y
            real(8), intent (in) :: z
            real(8), intent (in) :: t
            real(8), intent (in) :: a
            real(8) :: tmp
            if (a <= (-2.5d+32)) then
                tmp = x
            else if (a <= 1.05d-61) then
                tmp = z * (y / a)
            else
                tmp = x
            end if
            code = tmp
        end function
        
        public static double code(double x, double y, double z, double t, double a) {
        	double tmp;
        	if (a <= -2.5e+32) {
        		tmp = x;
        	} else if (a <= 1.05e-61) {
        		tmp = z * (y / a);
        	} else {
        		tmp = x;
        	}
        	return tmp;
        }
        
        def code(x, y, z, t, a):
        	tmp = 0
        	if a <= -2.5e+32:
        		tmp = x
        	elif a <= 1.05e-61:
        		tmp = z * (y / a)
        	else:
        		tmp = x
        	return tmp
        
        function code(x, y, z, t, a)
        	tmp = 0.0
        	if (a <= -2.5e+32)
        		tmp = x;
        	elseif (a <= 1.05e-61)
        		tmp = Float64(z * Float64(y / a));
        	else
        		tmp = x;
        	end
        	return tmp
        end
        
        function tmp_2 = code(x, y, z, t, a)
        	tmp = 0.0;
        	if (a <= -2.5e+32)
        		tmp = x;
        	elseif (a <= 1.05e-61)
        		tmp = z * (y / a);
        	else
        		tmp = x;
        	end
        	tmp_2 = tmp;
        end
        
        code[x_, y_, z_, t_, a_] := If[LessEqual[a, -2.5e+32], x, If[LessEqual[a, 1.05e-61], N[(z * N[(y / a), $MachinePrecision]), $MachinePrecision], x]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        \mathbf{if}\;a \leq -2.5 \cdot 10^{+32}:\\
        \;\;\;\;x\\
        
        \mathbf{elif}\;a \leq 1.05 \cdot 10^{-61}:\\
        \;\;\;\;z \cdot \frac{y}{a}\\
        
        \mathbf{else}:\\
        \;\;\;\;x\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 2 regimes
        2. if a < -2.4999999999999999e32 or 1.05e-61 < a

          1. Initial program 83.5%

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

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

              \[\leadsto x + \left(z - t\right) \cdot \color{blue}{\frac{y}{a}} \]
            3. cancel-sign-subN/A

              \[\leadsto x - \color{blue}{\left(\mathsf{neg}\left(\left(z - t\right)\right)\right) \cdot \frac{y}{a}} \]
            4. sub0-negN/A

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

              \[\leadsto x - \left(\left(0 - z\right) + t\right) \cdot \frac{\color{blue}{y}}{a} \]
            6. neg-sub0N/A

              \[\leadsto x - \left(\left(\mathsf{neg}\left(z\right)\right) + t\right) \cdot \frac{y}{a} \]
            7. +-commutativeN/A

              \[\leadsto x - \left(t + \left(\mathsf{neg}\left(z\right)\right)\right) \cdot \frac{\color{blue}{y}}{a} \]
            8. sub-negN/A

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

              \[\leadsto x - \frac{y}{a} \cdot \color{blue}{\left(t - z\right)} \]
            10. --lowering--.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{a} \cdot \left(t - z\right)\right)}\right) \]
            11. associate-*l/N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y \cdot \left(t - z\right)}{\color{blue}{a}}\right)\right) \]
            12. /-lowering-/.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(y \cdot \left(t - z\right)\right), \color{blue}{a}\right)\right) \]
            13. *-lowering-*.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(t - z\right)\right), a\right)\right) \]
            14. --lowering--.f6483.5%

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{\_.f64}\left(t, z\right)\right), a\right)\right) \]
          3. Simplified83.5%

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

            \[\leadsto \color{blue}{x} \]
          6. Step-by-step derivation
            1. Simplified56.0%

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

            if -2.4999999999999999e32 < a < 1.05e-61

            1. Initial program 99.0%

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

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

                \[\leadsto x + \left(z - t\right) \cdot \color{blue}{\frac{y}{a}} \]
              3. cancel-sign-subN/A

                \[\leadsto x - \color{blue}{\left(\mathsf{neg}\left(\left(z - t\right)\right)\right) \cdot \frac{y}{a}} \]
              4. sub0-negN/A

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

                \[\leadsto x - \left(\left(0 - z\right) + t\right) \cdot \frac{\color{blue}{y}}{a} \]
              6. neg-sub0N/A

                \[\leadsto x - \left(\left(\mathsf{neg}\left(z\right)\right) + t\right) \cdot \frac{y}{a} \]
              7. +-commutativeN/A

                \[\leadsto x - \left(t + \left(\mathsf{neg}\left(z\right)\right)\right) \cdot \frac{\color{blue}{y}}{a} \]
              8. sub-negN/A

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

                \[\leadsto x - \frac{y}{a} \cdot \color{blue}{\left(t - z\right)} \]
              10. --lowering--.f64N/A

                \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{a} \cdot \left(t - z\right)\right)}\right) \]
              11. associate-*l/N/A

                \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y \cdot \left(t - z\right)}{\color{blue}{a}}\right)\right) \]
              12. /-lowering-/.f64N/A

                \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(y \cdot \left(t - z\right)\right), \color{blue}{a}\right)\right) \]
              13. *-lowering-*.f64N/A

                \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(t - z\right)\right), a\right)\right) \]
              14. --lowering--.f6499.0%

                \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{\_.f64}\left(t, z\right)\right), a\right)\right) \]
            3. Simplified99.0%

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

              \[\leadsto \color{blue}{\frac{y \cdot z}{a}} \]
            6. Step-by-step derivation
              1. /-lowering-/.f64N/A

                \[\leadsto \mathsf{/.f64}\left(\left(y \cdot z\right), \color{blue}{a}\right) \]
              2. *-lowering-*.f6454.1%

                \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, z\right), a\right) \]
            7. Simplified54.1%

              \[\leadsto \color{blue}{\frac{y \cdot z}{a}} \]
            8. Step-by-step derivation
              1. *-commutativeN/A

                \[\leadsto \frac{z \cdot y}{a} \]
              2. associate-/l*N/A

                \[\leadsto z \cdot \color{blue}{\frac{y}{a}} \]
              3. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(z, \color{blue}{\left(\frac{y}{a}\right)}\right) \]
              4. /-lowering-/.f6452.8%

                \[\leadsto \mathsf{*.f64}\left(z, \mathsf{/.f64}\left(y, \color{blue}{a}\right)\right) \]
            9. Applied egg-rr52.8%

              \[\leadsto \color{blue}{z \cdot \frac{y}{a}} \]
          7. Recombined 2 regimes into one program.
          8. Add Preprocessing

          Alternative 8: 97.4% accurate, 1.0× speedup?

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

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

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

              \[\leadsto x + \left(z - t\right) \cdot \color{blue}{\frac{y}{a}} \]
            3. cancel-sign-subN/A

              \[\leadsto x - \color{blue}{\left(\mathsf{neg}\left(\left(z - t\right)\right)\right) \cdot \frac{y}{a}} \]
            4. sub0-negN/A

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

              \[\leadsto x - \left(\left(0 - z\right) + t\right) \cdot \frac{\color{blue}{y}}{a} \]
            6. neg-sub0N/A

              \[\leadsto x - \left(\left(\mathsf{neg}\left(z\right)\right) + t\right) \cdot \frac{y}{a} \]
            7. +-commutativeN/A

              \[\leadsto x - \left(t + \left(\mathsf{neg}\left(z\right)\right)\right) \cdot \frac{\color{blue}{y}}{a} \]
            8. sub-negN/A

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

              \[\leadsto x - \frac{y}{a} \cdot \color{blue}{\left(t - z\right)} \]
            10. --lowering--.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{a} \cdot \left(t - z\right)\right)}\right) \]
            11. associate-*l/N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y \cdot \left(t - z\right)}{\color{blue}{a}}\right)\right) \]
            12. /-lowering-/.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(y \cdot \left(t - z\right)\right), \color{blue}{a}\right)\right) \]
            13. *-lowering-*.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(t - z\right)\right), a\right)\right) \]
            14. --lowering--.f6490.7%

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{\_.f64}\left(t, z\right)\right), a\right)\right) \]
          3. Simplified90.7%

            \[\leadsto \color{blue}{x - \frac{y \cdot \left(t - z\right)}{a}} \]
          4. Add Preprocessing
          5. Step-by-step derivation
            1. *-commutativeN/A

              \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{\left(t - z\right) \cdot y}{a}\right)\right) \]
            2. associate-/l*N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \color{blue}{\frac{y}{a}}\right)\right) \]
            3. *-commutativeN/A

              \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y}{a} \cdot \color{blue}{\left(t - z\right)}\right)\right) \]
            4. *-lowering-*.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\left(\frac{y}{a}\right), \color{blue}{\left(t - z\right)}\right)\right) \]
            5. /-lowering-/.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, a\right), \left(\color{blue}{t} - z\right)\right)\right) \]
            6. --lowering--.f6497.0%

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, a\right), \mathsf{\_.f64}\left(t, \color{blue}{z}\right)\right)\right) \]
          6. Applied egg-rr97.0%

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

              \[\leadsto x - \frac{y}{\color{blue}{\frac{a}{t - z}}} \]
            2. --lowering--.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{\frac{a}{t - z}}\right)}\right) \]
            3. associate-/r/N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y}{a} \cdot \color{blue}{\left(t - z\right)}\right)\right) \]
            4. *-commutativeN/A

              \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \color{blue}{\frac{y}{a}}\right)\right) \]
            5. clear-numN/A

              \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \frac{1}{\color{blue}{\frac{a}{y}}}\right)\right) \]
            6. un-div-invN/A

              \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{t - z}{\color{blue}{\frac{a}{y}}}\right)\right) \]
            7. /-lowering-/.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(t - z\right), \color{blue}{\left(\frac{a}{y}\right)}\right)\right) \]
            8. --lowering--.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{\_.f64}\left(t, z\right), \left(\frac{\color{blue}{a}}{y}\right)\right)\right) \]
            9. /-lowering-/.f6497.1%

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{\_.f64}\left(t, z\right), \mathsf{/.f64}\left(a, \color{blue}{y}\right)\right)\right) \]
          8. Applied egg-rr97.1%

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

            \[\leadsto x + \frac{z - t}{\frac{a}{y}} \]
          10. Add Preprocessing

          Alternative 9: 97.3% accurate, 1.0× speedup?

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

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

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

              \[\leadsto x + \left(z - t\right) \cdot \color{blue}{\frac{y}{a}} \]
            3. cancel-sign-subN/A

              \[\leadsto x - \color{blue}{\left(\mathsf{neg}\left(\left(z - t\right)\right)\right) \cdot \frac{y}{a}} \]
            4. sub0-negN/A

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

              \[\leadsto x - \left(\left(0 - z\right) + t\right) \cdot \frac{\color{blue}{y}}{a} \]
            6. neg-sub0N/A

              \[\leadsto x - \left(\left(\mathsf{neg}\left(z\right)\right) + t\right) \cdot \frac{y}{a} \]
            7. +-commutativeN/A

              \[\leadsto x - \left(t + \left(\mathsf{neg}\left(z\right)\right)\right) \cdot \frac{\color{blue}{y}}{a} \]
            8. sub-negN/A

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

              \[\leadsto x - \frac{y}{a} \cdot \color{blue}{\left(t - z\right)} \]
            10. --lowering--.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{a} \cdot \left(t - z\right)\right)}\right) \]
            11. associate-*l/N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y \cdot \left(t - z\right)}{\color{blue}{a}}\right)\right) \]
            12. /-lowering-/.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(y \cdot \left(t - z\right)\right), \color{blue}{a}\right)\right) \]
            13. *-lowering-*.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(t - z\right)\right), a\right)\right) \]
            14. --lowering--.f6490.7%

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{\_.f64}\left(t, z\right)\right), a\right)\right) \]
          3. Simplified90.7%

            \[\leadsto \color{blue}{x - \frac{y \cdot \left(t - z\right)}{a}} \]
          4. Add Preprocessing
          5. Step-by-step derivation
            1. *-commutativeN/A

              \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{\left(t - z\right) \cdot y}{a}\right)\right) \]
            2. associate-/l*N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \left(\left(t - z\right) \cdot \color{blue}{\frac{y}{a}}\right)\right) \]
            3. *-commutativeN/A

              \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y}{a} \cdot \color{blue}{\left(t - z\right)}\right)\right) \]
            4. *-lowering-*.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\left(\frac{y}{a}\right), \color{blue}{\left(t - z\right)}\right)\right) \]
            5. /-lowering-/.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, a\right), \left(\color{blue}{t} - z\right)\right)\right) \]
            6. --lowering--.f6497.0%

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, a\right), \mathsf{\_.f64}\left(t, \color{blue}{z}\right)\right)\right) \]
          6. Applied egg-rr97.0%

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

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

          Alternative 10: 39.7% accurate, 9.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 90.7%

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

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

              \[\leadsto x + \left(z - t\right) \cdot \color{blue}{\frac{y}{a}} \]
            3. cancel-sign-subN/A

              \[\leadsto x - \color{blue}{\left(\mathsf{neg}\left(\left(z - t\right)\right)\right) \cdot \frac{y}{a}} \]
            4. sub0-negN/A

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

              \[\leadsto x - \left(\left(0 - z\right) + t\right) \cdot \frac{\color{blue}{y}}{a} \]
            6. neg-sub0N/A

              \[\leadsto x - \left(\left(\mathsf{neg}\left(z\right)\right) + t\right) \cdot \frac{y}{a} \]
            7. +-commutativeN/A

              \[\leadsto x - \left(t + \left(\mathsf{neg}\left(z\right)\right)\right) \cdot \frac{\color{blue}{y}}{a} \]
            8. sub-negN/A

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

              \[\leadsto x - \frac{y}{a} \cdot \color{blue}{\left(t - z\right)} \]
            10. --lowering--.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{a} \cdot \left(t - z\right)\right)}\right) \]
            11. associate-*l/N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y \cdot \left(t - z\right)}{\color{blue}{a}}\right)\right) \]
            12. /-lowering-/.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(y \cdot \left(t - z\right)\right), \color{blue}{a}\right)\right) \]
            13. *-lowering-*.f64N/A

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \left(t - z\right)\right), a\right)\right) \]
            14. --lowering--.f6490.7%

              \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \mathsf{\_.f64}\left(t, z\right)\right), a\right)\right) \]
          3. Simplified90.7%

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

            \[\leadsto \color{blue}{x} \]
          6. Step-by-step derivation
            1. Simplified38.7%

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

            Developer Target 1: 99.3% accurate, 0.5× speedup?

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

            Reproduce

            ?
            herbie shell --seed 2024149 
            (FPCore (x y z t a)
              :name "Optimisation.CirclePacking:place from circle-packing-0.1.0.4, E"
              :precision binary64
            
              :alt
              (! :herbie-platform default (if (< y -430450648655599/4000000000000000000000000) (+ x (/ 1 (/ (/ a (- z t)) y))) (if (< y 2894426862792089/10000000000000000000000000000000000000000000000000000000000000000) (+ x (/ (* y (- z t)) a)) (+ x (/ y (/ a (- z t)))))))
            
              (+ x (/ (* y (- z t)) a)))