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

Percentage Accurate: 76.9% → 88.0%
Time: 11.5s
Alternatives: 11
Speedup: 1.0×

Specification

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

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

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

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

Accuracy vs Speed?

Herbie found 11 alternatives:

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

Initial Program: 76.9% accurate, 1.0× speedup?

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

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

Alternative 1: 88.0% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -9.5 \cdot 10^{+45}:\\ \;\;\;\;\mathsf{fma}\left(\frac{1}{\frac{t}{y}}, z - a, x\right)\\ \mathbf{elif}\;t \leq 4 \cdot 10^{-21}:\\ \;\;\;\;\left(y + x\right) + \frac{y \cdot \left(z - t\right)}{t - a}\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(y, \frac{z - t}{t - a} + 1, x\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= t -9.5e+45)
   (fma (/ 1.0 (/ t y)) (- z a) x)
   (if (<= t 4e-21)
     (+ (+ y x) (/ (* y (- z t)) (- t a)))
     (fma y (+ (/ (- z t) (- t a)) 1.0) x))))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (t <= -9.5e+45) {
		tmp = fma((1.0 / (t / y)), (z - a), x);
	} else if (t <= 4e-21) {
		tmp = (y + x) + ((y * (z - t)) / (t - a));
	} else {
		tmp = fma(y, (((z - t) / (t - a)) + 1.0), x);
	}
	return tmp;
}
function code(x, y, z, t, a)
	tmp = 0.0
	if (t <= -9.5e+45)
		tmp = fma(Float64(1.0 / Float64(t / y)), Float64(z - a), x);
	elseif (t <= 4e-21)
		tmp = Float64(Float64(y + x) + Float64(Float64(y * Float64(z - t)) / Float64(t - a)));
	else
		tmp = fma(y, Float64(Float64(Float64(z - t) / Float64(t - a)) + 1.0), x);
	end
	return tmp
end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -9.5e+45], N[(N[(1.0 / N[(t / y), $MachinePrecision]), $MachinePrecision] * N[(z - a), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[t, 4e-21], N[(N[(y + x), $MachinePrecision] + N[(N[(y * N[(z - t), $MachinePrecision]), $MachinePrecision] / N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y * N[(N[(N[(z - t), $MachinePrecision] / N[(t - a), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision] + x), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -9.5 \cdot 10^{+45}:\\
\;\;\;\;\mathsf{fma}\left(\frac{1}{\frac{t}{y}}, z - a, x\right)\\

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

\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(y, \frac{z - t}{t - a} + 1, x\right)\\


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

    1. Initial program 52.9%

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

      \[\leadsto \color{blue}{\left(x + -1 \cdot \frac{a \cdot y}{t}\right) - -1 \cdot \frac{y \cdot z}{t}} \]
    4. Step-by-step derivation
      1. cancel-sign-sub-invN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y}{t}, z - a, x\right)} \]
    6. Step-by-step derivation
      1. clear-numN/A

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

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

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

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

    if -9.4999999999999998e45 < t < 3.99999999999999963e-21

    1. Initial program 97.3%

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

    if 3.99999999999999963e-21 < t

    1. Initial program 64.2%

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \mathsf{fma}\left(y, 1 + \color{blue}{\left(\mathsf{neg}\left(\frac{z - t}{a - t}\right)\right)}, x\right) \]
      11. unsub-negN/A

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

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

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

        \[\leadsto \mathsf{fma}\left(y, 1 - \frac{\color{blue}{z - t}}{a - t}, x\right) \]
      15. --lowering--.f6488.5

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

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

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

Alternative 2: 88.0% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -1.8 \cdot 10^{+46}:\\ \;\;\;\;\mathsf{fma}\left(\frac{y}{t}, z - a, x\right)\\ \mathbf{elif}\;t \leq 2.9 \cdot 10^{-24}:\\ \;\;\;\;\left(y + x\right) + \frac{y \cdot \left(z - t\right)}{t - a}\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(y, \frac{z - t}{t - a} + 1, x\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= t -1.8e+46)
   (fma (/ y t) (- z a) x)
   (if (<= t 2.9e-24)
     (+ (+ y x) (/ (* y (- z t)) (- t a)))
     (fma y (+ (/ (- z t) (- t a)) 1.0) x))))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (t <= -1.8e+46) {
		tmp = fma((y / t), (z - a), x);
	} else if (t <= 2.9e-24) {
		tmp = (y + x) + ((y * (z - t)) / (t - a));
	} else {
		tmp = fma(y, (((z - t) / (t - a)) + 1.0), x);
	}
	return tmp;
}
function code(x, y, z, t, a)
	tmp = 0.0
	if (t <= -1.8e+46)
		tmp = fma(Float64(y / t), Float64(z - a), x);
	elseif (t <= 2.9e-24)
		tmp = Float64(Float64(y + x) + Float64(Float64(y * Float64(z - t)) / Float64(t - a)));
	else
		tmp = fma(y, Float64(Float64(Float64(z - t) / Float64(t - a)) + 1.0), x);
	end
	return tmp
end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -1.8e+46], N[(N[(y / t), $MachinePrecision] * N[(z - a), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[t, 2.9e-24], N[(N[(y + x), $MachinePrecision] + N[(N[(y * N[(z - t), $MachinePrecision]), $MachinePrecision] / N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y * N[(N[(N[(z - t), $MachinePrecision] / N[(t - a), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision] + x), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.8 \cdot 10^{+46}:\\
\;\;\;\;\mathsf{fma}\left(\frac{y}{t}, z - a, x\right)\\

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

\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(y, \frac{z - t}{t - a} + 1, x\right)\\


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

    1. Initial program 52.9%

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

      \[\leadsto \color{blue}{\left(x + -1 \cdot \frac{a \cdot y}{t}\right) - -1 \cdot \frac{y \cdot z}{t}} \]
    4. Step-by-step derivation
      1. cancel-sign-sub-invN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -1.7999999999999999e46 < t < 2.8999999999999999e-24

    1. Initial program 97.3%

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

    if 2.8999999999999999e-24 < t

    1. Initial program 64.2%

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \mathsf{fma}\left(y, 1 + \color{blue}{\left(\mathsf{neg}\left(\frac{z - t}{a - t}\right)\right)}, x\right) \]
      11. unsub-negN/A

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

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

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

        \[\leadsto \mathsf{fma}\left(y, 1 - \frac{\color{blue}{z - t}}{a - t}, x\right) \]
      15. --lowering--.f6488.5

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

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

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

Alternative 3: 88.5% accurate, 0.8× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -1.20000000000000004e46 or 1.25999999999999994e141 < t

    1. Initial program 55.5%

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

      \[\leadsto \color{blue}{\left(x + -1 \cdot \frac{a \cdot y}{t}\right) - -1 \cdot \frac{y \cdot z}{t}} \]
    4. Step-by-step derivation
      1. cancel-sign-sub-invN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -1.20000000000000004e46 < t < 1.25999999999999994e141

    1. Initial program 94.8%

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \mathsf{fma}\left(y, 1 + \color{blue}{\left(\mathsf{neg}\left(\frac{z - t}{a - t}\right)\right)}, x\right) \]
      11. unsub-negN/A

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

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

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

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

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

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

      \[\leadsto \mathsf{fma}\left(y, 1 - \color{blue}{\frac{z}{a - t}}, x\right) \]
    7. Step-by-step derivation
      1. /-lowering-/.f64N/A

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

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

      \[\leadsto \mathsf{fma}\left(y, 1 - \color{blue}{\frac{z}{a - t}}, x\right) \]
  3. Recombined 2 regimes into one program.
  4. Final simplification91.2%

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

Alternative 4: 83.1% accurate, 0.9× speedup?

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

\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(y, 1 - \frac{z}{a}, x\right)\\
\mathbf{if}\;a \leq -4.6 \cdot 10^{-73}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;a \leq 5.6 \cdot 10^{+20}:\\
\;\;\;\;\mathsf{fma}\left(\frac{y}{t}, z, x\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if a < -4.59999999999999977e-73 or 5.6e20 < a

    1. Initial program 84.5%

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

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

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

        \[\leadsto \color{blue}{\left(y - \frac{y \cdot z}{a}\right) + x} \]
      3. *-rgt-identityN/A

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

        \[\leadsto \left(y \cdot 1 - \color{blue}{y \cdot \frac{z}{a}}\right) + x \]
      5. distribute-lft-out--N/A

        \[\leadsto \color{blue}{y \cdot \left(1 - \frac{z}{a}\right)} + x \]
      6. accelerator-lowering-fma.f64N/A

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

        \[\leadsto \mathsf{fma}\left(y, \color{blue}{1 - \frac{z}{a}}, x\right) \]
      8. /-lowering-/.f6487.4

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

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

    if -4.59999999999999977e-73 < a < 5.6e20

    1. Initial program 77.8%

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

      \[\leadsto \color{blue}{\left(x + -1 \cdot \frac{a \cdot y}{t}\right) - -1 \cdot \frac{y \cdot z}{t}} \]
    4. Step-by-step derivation
      1. cancel-sign-sub-invN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \mathsf{fma}\left(\frac{y}{t}, \color{blue}{z}, x\right) \]
    7. Step-by-step derivation
      1. Simplified85.3%

        \[\leadsto \mathsf{fma}\left(\frac{y}{t}, \color{blue}{z}, x\right) \]
    8. Recombined 2 regimes into one program.
    9. Add Preprocessing

    Alternative 5: 89.9% accurate, 0.9× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -2.25 \cdot 10^{+110}:\\ \;\;\;\;\mathsf{fma}\left(\frac{y}{t}, z - a, x\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(y, \frac{z - t}{t - a} + 1, x\right)\\ \end{array} \end{array} \]
    (FPCore (x y z t a)
     :precision binary64
     (if (<= t -2.25e+110)
       (fma (/ y t) (- z a) x)
       (fma y (+ (/ (- z t) (- t a)) 1.0) x)))
    double code(double x, double y, double z, double t, double a) {
    	double tmp;
    	if (t <= -2.25e+110) {
    		tmp = fma((y / t), (z - a), x);
    	} else {
    		tmp = fma(y, (((z - t) / (t - a)) + 1.0), x);
    	}
    	return tmp;
    }
    
    function code(x, y, z, t, a)
    	tmp = 0.0
    	if (t <= -2.25e+110)
    		tmp = fma(Float64(y / t), Float64(z - a), x);
    	else
    		tmp = fma(y, Float64(Float64(Float64(z - t) / Float64(t - a)) + 1.0), x);
    	end
    	return tmp
    end
    
    code[x_, y_, z_, t_, a_] := If[LessEqual[t, -2.25e+110], N[(N[(y / t), $MachinePrecision] * N[(z - a), $MachinePrecision] + x), $MachinePrecision], N[(y * N[(N[(N[(z - t), $MachinePrecision] / N[(t - a), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision] + x), $MachinePrecision]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;t \leq -2.25 \cdot 10^{+110}:\\
    \;\;\;\;\mathsf{fma}\left(\frac{y}{t}, z - a, x\right)\\
    
    \mathbf{else}:\\
    \;\;\;\;\mathsf{fma}\left(y, \frac{z - t}{t - a} + 1, x\right)\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if t < -2.2500000000000001e110

      1. Initial program 42.2%

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

        \[\leadsto \color{blue}{\left(x + -1 \cdot \frac{a \cdot y}{t}\right) - -1 \cdot \frac{y \cdot z}{t}} \]
      4. Step-by-step derivation
        1. cancel-sign-sub-invN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      if -2.2500000000000001e110 < t

      1. Initial program 88.5%

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto \mathsf{fma}\left(y, 1 + \color{blue}{\left(\mathsf{neg}\left(\frac{z - t}{a - t}\right)\right)}, x\right) \]
        11. unsub-negN/A

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

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

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

          \[\leadsto \mathsf{fma}\left(y, 1 - \frac{\color{blue}{z - t}}{a - t}, x\right) \]
        15. --lowering--.f6493.2

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

        \[\leadsto \color{blue}{\mathsf{fma}\left(y, 1 - \frac{z - t}{a - t}, x\right)} \]
    3. Recombined 2 regimes into one program.
    4. Final simplification92.5%

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

    Alternative 6: 77.4% accurate, 1.0× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;a \leq -1.3 \cdot 10^{-72}:\\ \;\;\;\;y + x\\ \mathbf{elif}\;a \leq 32000000000:\\ \;\;\;\;\mathsf{fma}\left(\frac{y}{t}, z, x\right)\\ \mathbf{else}:\\ \;\;\;\;y + x\\ \end{array} \end{array} \]
    (FPCore (x y z t a)
     :precision binary64
     (if (<= a -1.3e-72)
       (+ y x)
       (if (<= a 32000000000.0) (fma (/ y t) z x) (+ y x))))
    double code(double x, double y, double z, double t, double a) {
    	double tmp;
    	if (a <= -1.3e-72) {
    		tmp = y + x;
    	} else if (a <= 32000000000.0) {
    		tmp = fma((y / t), z, x);
    	} else {
    		tmp = y + x;
    	}
    	return tmp;
    }
    
    function code(x, y, z, t, a)
    	tmp = 0.0
    	if (a <= -1.3e-72)
    		tmp = Float64(y + x);
    	elseif (a <= 32000000000.0)
    		tmp = fma(Float64(y / t), z, x);
    	else
    		tmp = Float64(y + x);
    	end
    	return tmp
    end
    
    code[x_, y_, z_, t_, a_] := If[LessEqual[a, -1.3e-72], N[(y + x), $MachinePrecision], If[LessEqual[a, 32000000000.0], N[(N[(y / t), $MachinePrecision] * z + x), $MachinePrecision], N[(y + x), $MachinePrecision]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;a \leq -1.3 \cdot 10^{-72}:\\
    \;\;\;\;y + x\\
    
    \mathbf{elif}\;a \leq 32000000000:\\
    \;\;\;\;\mathsf{fma}\left(\frac{y}{t}, z, x\right)\\
    
    \mathbf{else}:\\
    \;\;\;\;y + x\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if a < -1.29999999999999998e-72 or 3.2e10 < a

      1. Initial program 84.0%

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

        \[\leadsto \color{blue}{x + y} \]
      4. Step-by-step derivation
        1. +-commutativeN/A

          \[\leadsto \color{blue}{y + x} \]
        2. +-lowering-+.f6476.1

          \[\leadsto \color{blue}{y + x} \]
      5. Simplified76.1%

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

      if -1.29999999999999998e-72 < a < 3.2e10

      1. Initial program 78.3%

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

        \[\leadsto \color{blue}{\left(x + -1 \cdot \frac{a \cdot y}{t}\right) - -1 \cdot \frac{y \cdot z}{t}} \]
      4. Step-by-step derivation
        1. cancel-sign-sub-invN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \mathsf{fma}\left(\frac{y}{t}, \color{blue}{z}, x\right) \]
      7. Step-by-step derivation
        1. Simplified85.9%

          \[\leadsto \mathsf{fma}\left(\frac{y}{t}, \color{blue}{z}, x\right) \]
      8. Recombined 2 regimes into one program.
      9. Add Preprocessing

      Alternative 7: 60.5% accurate, 1.0× speedup?

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

        1. Initial program 80.6%

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

          \[\leadsto \color{blue}{\left(x + -1 \cdot \frac{a \cdot y}{t}\right) - -1 \cdot \frac{y \cdot z}{t}} \]
        4. Step-by-step derivation
          1. cancel-sign-sub-invN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

            \[\leadsto \color{blue}{\frac{y \cdot z}{t}} \]
          2. *-lowering-*.f6458.8

            \[\leadsto \frac{\color{blue}{y \cdot z}}{t} \]
        8. Simplified58.8%

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

        if -3.2000000000000001e223 < z < 4.80000000000000003e266

        1. Initial program 81.3%

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

          \[\leadsto \color{blue}{x + y} \]
        4. Step-by-step derivation
          1. +-commutativeN/A

            \[\leadsto \color{blue}{y + x} \]
          2. +-lowering-+.f6469.6

            \[\leadsto \color{blue}{y + x} \]
        5. Simplified69.6%

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

      Alternative 8: 63.0% accurate, 1.8× speedup?

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

        1. Initial program 82.1%

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

          \[\leadsto \color{blue}{x + y} \]
        4. Step-by-step derivation
          1. +-commutativeN/A

            \[\leadsto \color{blue}{y + x} \]
          2. +-lowering-+.f6470.3

            \[\leadsto \color{blue}{y + x} \]
        5. Simplified70.3%

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

        if -5.20000000000000005e-104 < a < 8.0000000000000003e-202

        1. Initial program 79.3%

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

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

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

        Alternative 9: 53.5% accurate, 2.2× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -2.45 \cdot 10^{+194}:\\ \;\;\;\;y\\ \mathbf{elif}\;y \leq 5.5 \cdot 10^{+147}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \end{array} \]
        (FPCore (x y z t a)
         :precision binary64
         (if (<= y -2.45e+194) y (if (<= y 5.5e+147) x y)))
        double code(double x, double y, double z, double t, double a) {
        	double tmp;
        	if (y <= -2.45e+194) {
        		tmp = y;
        	} else if (y <= 5.5e+147) {
        		tmp = x;
        	} else {
        		tmp = y;
        	}
        	return tmp;
        }
        
        real(8) function code(x, y, z, t, a)
            real(8), intent (in) :: x
            real(8), intent (in) :: y
            real(8), intent (in) :: z
            real(8), intent (in) :: t
            real(8), intent (in) :: a
            real(8) :: tmp
            if (y <= (-2.45d+194)) then
                tmp = y
            else if (y <= 5.5d+147) then
                tmp = x
            else
                tmp = y
            end if
            code = tmp
        end function
        
        public static double code(double x, double y, double z, double t, double a) {
        	double tmp;
        	if (y <= -2.45e+194) {
        		tmp = y;
        	} else if (y <= 5.5e+147) {
        		tmp = x;
        	} else {
        		tmp = y;
        	}
        	return tmp;
        }
        
        def code(x, y, z, t, a):
        	tmp = 0
        	if y <= -2.45e+194:
        		tmp = y
        	elif y <= 5.5e+147:
        		tmp = x
        	else:
        		tmp = y
        	return tmp
        
        function code(x, y, z, t, a)
        	tmp = 0.0
        	if (y <= -2.45e+194)
        		tmp = y;
        	elseif (y <= 5.5e+147)
        		tmp = x;
        	else
        		tmp = y;
        	end
        	return tmp
        end
        
        function tmp_2 = code(x, y, z, t, a)
        	tmp = 0.0;
        	if (y <= -2.45e+194)
        		tmp = y;
        	elseif (y <= 5.5e+147)
        		tmp = x;
        	else
        		tmp = y;
        	end
        	tmp_2 = tmp;
        end
        
        code[x_, y_, z_, t_, a_] := If[LessEqual[y, -2.45e+194], y, If[LessEqual[y, 5.5e+147], x, y]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        \mathbf{if}\;y \leq -2.45 \cdot 10^{+194}:\\
        \;\;\;\;y\\
        
        \mathbf{elif}\;y \leq 5.5 \cdot 10^{+147}:\\
        \;\;\;\;x\\
        
        \mathbf{else}:\\
        \;\;\;\;y\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 2 regimes
        2. if y < -2.45000000000000013e194 or 5.4999999999999997e147 < y

          1. Initial program 59.8%

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

            \[\leadsto \color{blue}{x + y} \]
          4. Step-by-step derivation
            1. +-commutativeN/A

              \[\leadsto \color{blue}{y + x} \]
            2. +-lowering-+.f6447.5

              \[\leadsto \color{blue}{y + x} \]
          5. Simplified47.5%

            \[\leadsto \color{blue}{y + x} \]
          6. Taylor expanded in y around inf

            \[\leadsto \color{blue}{y} \]
          7. Step-by-step derivation
            1. Simplified43.9%

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

            if -2.45000000000000013e194 < y < 5.4999999999999997e147

            1. Initial program 86.2%

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

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

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

            Alternative 10: 50.8% accurate, 29.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 81.3%

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

              \[\leadsto \color{blue}{x} \]
            4. Step-by-step derivation
              1. Simplified51.1%

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

              Alternative 11: 2.7% accurate, 29.0× speedup?

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

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

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

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

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

                  \[\leadsto \color{blue}{\left(\mathsf{neg}\left(\left(z - t\right) \cdot y\right)\right) \cdot \frac{1}{a - t}} + \left(x + y\right) \]
                5. accelerator-lowering-fma.f64N/A

                  \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{neg}\left(\left(z - t\right) \cdot y\right), \frac{1}{a - t}, x + y\right)} \]
                6. distribute-rgt-neg-inN/A

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

                  \[\leadsto \mathsf{fma}\left(\color{blue}{\left(z - t\right) \cdot \left(\mathsf{neg}\left(y\right)\right)}, \frac{1}{a - t}, x + y\right) \]
                8. --lowering--.f64N/A

                  \[\leadsto \mathsf{fma}\left(\color{blue}{\left(z - t\right)} \cdot \left(\mathsf{neg}\left(y\right)\right), \frac{1}{a - t}, x + y\right) \]
                9. neg-lowering-neg.f64N/A

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

                  \[\leadsto \mathsf{fma}\left(\left(z - t\right) \cdot \left(\mathsf{neg}\left(y\right)\right), \color{blue}{\frac{1}{a - t}}, x + y\right) \]
                11. --lowering--.f64N/A

                  \[\leadsto \mathsf{fma}\left(\left(z - t\right) \cdot \left(\mathsf{neg}\left(y\right)\right), \frac{1}{\color{blue}{a - t}}, x + y\right) \]
                12. +-lowering-+.f6481.2

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

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

                \[\leadsto \color{blue}{y \cdot \left(1 + -1 \cdot \frac{z - t}{a - t}\right)} \]
              6. Step-by-step derivation
                1. +-commutativeN/A

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

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

                  \[\leadsto y \cdot \left(-1 \cdot \frac{z - t}{a - t}\right) + \color{blue}{y} \]
                4. accelerator-lowering-fma.f64N/A

                  \[\leadsto \color{blue}{\mathsf{fma}\left(y, -1 \cdot \frac{z - t}{a - t}, y\right)} \]
                5. associate-*r/N/A

                  \[\leadsto \mathsf{fma}\left(y, \color{blue}{\frac{-1 \cdot \left(z - t\right)}{a - t}}, y\right) \]
                6. /-lowering-/.f64N/A

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

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

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

                  \[\leadsto \mathsf{fma}\left(y, \frac{\mathsf{neg}\left(\left(z + \color{blue}{-1 \cdot t}\right)\right)}{a - t}, y\right) \]
                10. +-commutativeN/A

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

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

                  \[\leadsto \mathsf{fma}\left(y, \frac{\left(\mathsf{neg}\left(\color{blue}{\left(\mathsf{neg}\left(t\right)\right)}\right)\right) + \left(\mathsf{neg}\left(z\right)\right)}{a - t}, y\right) \]
                13. remove-double-negN/A

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

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

                  \[\leadsto \mathsf{fma}\left(y, \frac{\color{blue}{t - z}}{a - t}, y\right) \]
                16. --lowering--.f6442.0

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

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

                \[\leadsto \color{blue}{y + -1 \cdot y} \]
              9. Step-by-step derivation
                1. distribute-rgt1-inN/A

                  \[\leadsto \color{blue}{\left(-1 + 1\right) \cdot y} \]
                2. metadata-evalN/A

                  \[\leadsto \color{blue}{0} \cdot y \]
                3. mul0-lft2.7

                  \[\leadsto \color{blue}{0} \]
              10. Simplified2.7%

                \[\leadsto \color{blue}{0} \]
              11. Add Preprocessing

              Developer Target 1: 87.3% accurate, 0.3× speedup?

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

              Reproduce

              ?
              herbie shell --seed 2024198 
              (FPCore (x y z t a)
                :name "Graphics.Rendering.Plot.Render.Plot.Axis:renderAxisTick from plot-0.2.3.4, B"
                :precision binary64
              
                :alt
                (! :herbie-platform default (if (< (- (+ x y) (/ (* (- z t) y) (- a t))) -13664970889390727/100000000000000000000000) (- (+ y x) (* (* (- z t) (/ 1 (- a t))) y)) (if (< (- (+ x y) (/ (* (- z t) y) (- a t))) 14754293444577233/1000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (/ (- (* y (- a z)) (* x t)) (- a t)) (- (+ y x) (* (* (- z t) (/ 1 (- a t))) y)))))
              
                (- (+ x y) (/ (* (- z t) y) (- a t))))