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

Percentage Accurate: 68.3% → 91.0%
Time: 9.5s
Alternatives: 10
Speedup: 0.9×

Specification

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

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

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

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

Alternative 1: 91.0% accurate, 0.2× speedup?

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

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

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

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

\mathbf{elif}\;t\_2 \leq 10^{+270}:\\
\;\;\;\;t\_2\\

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


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

    1. Initial program 40.6%

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

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

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

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

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

        \[\leadsto x + \color{blue}{\frac{y - z}{\frac{a - z}{t - x}}} \]
      6. lower-/.f64N/A

        \[\leadsto x + \color{blue}{\frac{y - z}{\frac{a - z}{t - x}}} \]
      7. lower-/.f6485.7

        \[\leadsto x + \frac{y - z}{\color{blue}{\frac{a - z}{t - x}}} \]
    4. Applied rewrites85.7%

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

    if -inf.0 < (+.f64 x (/.f64 (*.f64 (-.f64 y z) (-.f64 t x)) (-.f64 a z))) < -2.00000000000000015e-285 or 1.0000000000000001e-293 < (+.f64 x (/.f64 (*.f64 (-.f64 y z) (-.f64 t x)) (-.f64 a z))) < 1e270

    1. Initial program 96.1%

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

    if -2.00000000000000015e-285 < (+.f64 x (/.f64 (*.f64 (-.f64 y z) (-.f64 t x)) (-.f64 a z))) < 1.0000000000000001e-293

    1. Initial program 10.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 2: 83.7% accurate, 0.7× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.7e91 or 1.7999999999999999e68 < z

    1. Initial program 38.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      if -1.7e91 < z < 1.7999999999999999e68

      1. Initial program 90.3%

        \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
      2. Add Preprocessing
    8. Recombined 2 regimes into one program.
    9. Final simplification87.0%

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

    Alternative 3: 76.7% accurate, 0.8× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_1 := \mathsf{fma}\left(\frac{y - z}{a}, t - x, x\right)\\ \mathbf{if}\;a \leq -1.15 \cdot 10^{+47}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;a \leq 4 \cdot 10^{-38}:\\ \;\;\;\;\mathsf{fma}\left(x - t, \frac{y - a}{z}, t\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
    (FPCore (x y z t a)
     :precision binary64
     (let* ((t_1 (fma (/ (- y z) a) (- t x) x)))
       (if (<= a -1.15e+47)
         t_1
         (if (<= a 4e-38) (fma (- x t) (/ (- y a) z) t) t_1))))
    double code(double x, double y, double z, double t, double a) {
    	double t_1 = fma(((y - z) / a), (t - x), x);
    	double tmp;
    	if (a <= -1.15e+47) {
    		tmp = t_1;
    	} else if (a <= 4e-38) {
    		tmp = fma((x - t), ((y - a) / z), t);
    	} else {
    		tmp = t_1;
    	}
    	return tmp;
    }
    
    function code(x, y, z, t, a)
    	t_1 = fma(Float64(Float64(y - z) / a), Float64(t - x), x)
    	tmp = 0.0
    	if (a <= -1.15e+47)
    		tmp = t_1;
    	elseif (a <= 4e-38)
    		tmp = fma(Float64(x - t), Float64(Float64(y - a) / z), t);
    	else
    		tmp = t_1;
    	end
    	return tmp
    end
    
    code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(N[(y - z), $MachinePrecision] / a), $MachinePrecision] * N[(t - x), $MachinePrecision] + x), $MachinePrecision]}, If[LessEqual[a, -1.15e+47], t$95$1, If[LessEqual[a, 4e-38], N[(N[(x - t), $MachinePrecision] * N[(N[(y - a), $MachinePrecision] / z), $MachinePrecision] + t), $MachinePrecision], t$95$1]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_1 := \mathsf{fma}\left(\frac{y - z}{a}, t - x, x\right)\\
    \mathbf{if}\;a \leq -1.15 \cdot 10^{+47}:\\
    \;\;\;\;t\_1\\
    
    \mathbf{elif}\;a \leq 4 \cdot 10^{-38}:\\
    \;\;\;\;\mathsf{fma}\left(x - t, \frac{y - a}{z}, t\right)\\
    
    \mathbf{else}:\\
    \;\;\;\;t\_1\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if a < -1.1499999999999999e47 or 3.9999999999999998e-38 < a

      1. Initial program 73.4%

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

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

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

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

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

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

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

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

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

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

      if -1.1499999999999999e47 < a < 3.9999999999999998e-38

      1. Initial program 66.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      Alternative 4: 72.1% accurate, 0.8× speedup?

      \[\begin{array}{l} \\ \begin{array}{l} t_1 := \mathsf{fma}\left(\frac{t - x}{a}, y, x\right)\\ \mathbf{if}\;a \leq -1.15 \cdot 10^{+47}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;a \leq 4 \cdot 10^{-38}:\\ \;\;\;\;\mathsf{fma}\left(x - t, \frac{y - a}{z}, t\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
      (FPCore (x y z t a)
       :precision binary64
       (let* ((t_1 (fma (/ (- t x) a) y x)))
         (if (<= a -1.15e+47)
           t_1
           (if (<= a 4e-38) (fma (- x t) (/ (- y a) z) t) t_1))))
      double code(double x, double y, double z, double t, double a) {
      	double t_1 = fma(((t - x) / a), y, x);
      	double tmp;
      	if (a <= -1.15e+47) {
      		tmp = t_1;
      	} else if (a <= 4e-38) {
      		tmp = fma((x - t), ((y - a) / z), t);
      	} else {
      		tmp = t_1;
      	}
      	return tmp;
      }
      
      function code(x, y, z, t, a)
      	t_1 = fma(Float64(Float64(t - x) / a), y, x)
      	tmp = 0.0
      	if (a <= -1.15e+47)
      		tmp = t_1;
      	elseif (a <= 4e-38)
      		tmp = fma(Float64(x - t), Float64(Float64(y - a) / z), t);
      	else
      		tmp = t_1;
      	end
      	return tmp
      end
      
      code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(N[(t - x), $MachinePrecision] / a), $MachinePrecision] * y + x), $MachinePrecision]}, If[LessEqual[a, -1.15e+47], t$95$1, If[LessEqual[a, 4e-38], N[(N[(x - t), $MachinePrecision] * N[(N[(y - a), $MachinePrecision] / z), $MachinePrecision] + t), $MachinePrecision], t$95$1]]]
      
      \begin{array}{l}
      
      \\
      \begin{array}{l}
      t_1 := \mathsf{fma}\left(\frac{t - x}{a}, y, x\right)\\
      \mathbf{if}\;a \leq -1.15 \cdot 10^{+47}:\\
      \;\;\;\;t\_1\\
      
      \mathbf{elif}\;a \leq 4 \cdot 10^{-38}:\\
      \;\;\;\;\mathsf{fma}\left(x - t, \frac{y - a}{z}, t\right)\\
      
      \mathbf{else}:\\
      \;\;\;\;t\_1\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 2 regimes
      2. if a < -1.1499999999999999e47 or 3.9999999999999998e-38 < a

        1. Initial program 73.4%

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

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

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

            \[\leadsto \color{blue}{y \cdot \frac{t - x}{a}} + x \]
          3. *-commutativeN/A

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

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

            \[\leadsto \mathsf{fma}\left(\color{blue}{\frac{t - x}{a}}, y, x\right) \]
          6. lower--.f6470.4

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

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

        if -1.1499999999999999e47 < a < 3.9999999999999998e-38

        1. Initial program 66.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        Alternative 5: 69.0% accurate, 0.9× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} t_1 := \mathsf{fma}\left(\frac{t - x}{a}, y, x\right)\\ \mathbf{if}\;a \leq -5.3 \cdot 10^{+56}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;a \leq 2.7 \cdot 10^{-38}:\\ \;\;\;\;\mathsf{fma}\left(y, \frac{x - t}{z}, t\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
        (FPCore (x y z t a)
         :precision binary64
         (let* ((t_1 (fma (/ (- t x) a) y x)))
           (if (<= a -5.3e+56) t_1 (if (<= a 2.7e-38) (fma y (/ (- x t) z) t) t_1))))
        double code(double x, double y, double z, double t, double a) {
        	double t_1 = fma(((t - x) / a), y, x);
        	double tmp;
        	if (a <= -5.3e+56) {
        		tmp = t_1;
        	} else if (a <= 2.7e-38) {
        		tmp = fma(y, ((x - t) / z), t);
        	} else {
        		tmp = t_1;
        	}
        	return tmp;
        }
        
        function code(x, y, z, t, a)
        	t_1 = fma(Float64(Float64(t - x) / a), y, x)
        	tmp = 0.0
        	if (a <= -5.3e+56)
        		tmp = t_1;
        	elseif (a <= 2.7e-38)
        		tmp = fma(y, Float64(Float64(x - t) / z), t);
        	else
        		tmp = t_1;
        	end
        	return tmp
        end
        
        code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(N[(t - x), $MachinePrecision] / a), $MachinePrecision] * y + x), $MachinePrecision]}, If[LessEqual[a, -5.3e+56], t$95$1, If[LessEqual[a, 2.7e-38], N[(y * N[(N[(x - t), $MachinePrecision] / z), $MachinePrecision] + t), $MachinePrecision], t$95$1]]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        t_1 := \mathsf{fma}\left(\frac{t - x}{a}, y, x\right)\\
        \mathbf{if}\;a \leq -5.3 \cdot 10^{+56}:\\
        \;\;\;\;t\_1\\
        
        \mathbf{elif}\;a \leq 2.7 \cdot 10^{-38}:\\
        \;\;\;\;\mathsf{fma}\left(y, \frac{x - t}{z}, t\right)\\
        
        \mathbf{else}:\\
        \;\;\;\;t\_1\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 2 regimes
        2. if a < -5.3000000000000002e56 or 2.70000000000000005e-38 < a

          1. Initial program 73.1%

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

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

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

              \[\leadsto \color{blue}{y \cdot \frac{t - x}{a}} + x \]
            3. *-commutativeN/A

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

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

              \[\leadsto \mathsf{fma}\left(\color{blue}{\frac{t - x}{a}}, y, x\right) \]
            6. lower--.f6471.0

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

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

          if -5.3000000000000002e56 < a < 2.70000000000000005e-38

          1. Initial program 67.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          Alternative 6: 65.3% accurate, 0.9× speedup?

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

            1. Initial program 73.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \color{blue}{y \cdot \frac{t - x}{a}} + x \]
              3. lower-fma.f64N/A

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

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

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

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

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

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

              if -6.1000000000000001e56 < a < 3.19999999999999977e-38

              1. Initial program 67.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

              Alternative 7: 46.4% accurate, 1.0× speedup?

              \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(t - x\right) + x\\ \mathbf{if}\;z \leq -4.5 \cdot 10^{+91}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 5.2 \cdot 10^{+38}:\\ \;\;\;\;\mathsf{fma}\left(y, \frac{t}{a}, x\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
              (FPCore (x y z t a)
               :precision binary64
               (let* ((t_1 (+ (- t x) x)))
                 (if (<= z -4.5e+91) t_1 (if (<= z 5.2e+38) (fma y (/ t a) x) t_1))))
              double code(double x, double y, double z, double t, double a) {
              	double t_1 = (t - x) + x;
              	double tmp;
              	if (z <= -4.5e+91) {
              		tmp = t_1;
              	} else if (z <= 5.2e+38) {
              		tmp = fma(y, (t / a), x);
              	} else {
              		tmp = t_1;
              	}
              	return tmp;
              }
              
              function code(x, y, z, t, a)
              	t_1 = Float64(Float64(t - x) + x)
              	tmp = 0.0
              	if (z <= -4.5e+91)
              		tmp = t_1;
              	elseif (z <= 5.2e+38)
              		tmp = fma(y, Float64(t / a), x);
              	else
              		tmp = t_1;
              	end
              	return tmp
              end
              
              code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(t - x), $MachinePrecision] + x), $MachinePrecision]}, If[LessEqual[z, -4.5e+91], t$95$1, If[LessEqual[z, 5.2e+38], N[(y * N[(t / a), $MachinePrecision] + x), $MachinePrecision], t$95$1]]]
              
              \begin{array}{l}
              
              \\
              \begin{array}{l}
              t_1 := \left(t - x\right) + x\\
              \mathbf{if}\;z \leq -4.5 \cdot 10^{+91}:\\
              \;\;\;\;t\_1\\
              
              \mathbf{elif}\;z \leq 5.2 \cdot 10^{+38}:\\
              \;\;\;\;\mathsf{fma}\left(y, \frac{t}{a}, x\right)\\
              
              \mathbf{else}:\\
              \;\;\;\;t\_1\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 2 regimes
              2. if z < -4.5e91 or 5.1999999999999998e38 < z

                1. Initial program 40.6%

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

                  \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                4. Step-by-step derivation
                  1. lower--.f6445.7

                    \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                5. Applied rewrites45.7%

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

                if -4.5e91 < z < 5.1999999999999998e38

                1. Initial program 90.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto \color{blue}{y \cdot \frac{t - x}{a}} + x \]
                  3. lower-fma.f64N/A

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

                    \[\leadsto \mathsf{fma}\left(y, \color{blue}{\frac{t - x}{a}}, x\right) \]
                  5. lower--.f6465.7

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

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

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

                    \[\leadsto \mathsf{fma}\left(y, \frac{t}{\color{blue}{a}}, x\right) \]
                10. Recombined 2 regimes into one program.
                11. Final simplification51.1%

                  \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -4.5 \cdot 10^{+91}:\\ \;\;\;\;\left(t - x\right) + x\\ \mathbf{elif}\;z \leq 5.2 \cdot 10^{+38}:\\ \;\;\;\;\mathsf{fma}\left(y, \frac{t}{a}, x\right)\\ \mathbf{else}:\\ \;\;\;\;\left(t - x\right) + x\\ \end{array} \]
                12. Add Preprocessing

                Alternative 8: 29.4% accurate, 1.0× speedup?

                \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(t - x\right) + x\\ \mathbf{if}\;z \leq -9.2 \cdot 10^{-27}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 6.8 \cdot 10^{+19}:\\ \;\;\;\;\frac{y}{a} \cdot t\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
                (FPCore (x y z t a)
                 :precision binary64
                 (let* ((t_1 (+ (- t x) x)))
                   (if (<= z -9.2e-27) t_1 (if (<= z 6.8e+19) (* (/ y a) t) t_1))))
                double code(double x, double y, double z, double t, double a) {
                	double t_1 = (t - x) + x;
                	double tmp;
                	if (z <= -9.2e-27) {
                		tmp = t_1;
                	} else if (z <= 6.8e+19) {
                		tmp = (y / 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) :: tmp
                    t_1 = (t - x) + x
                    if (z <= (-9.2d-27)) then
                        tmp = t_1
                    else if (z <= 6.8d+19) then
                        tmp = (y / 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 = (t - x) + x;
                	double tmp;
                	if (z <= -9.2e-27) {
                		tmp = t_1;
                	} else if (z <= 6.8e+19) {
                		tmp = (y / a) * t;
                	} else {
                		tmp = t_1;
                	}
                	return tmp;
                }
                
                def code(x, y, z, t, a):
                	t_1 = (t - x) + x
                	tmp = 0
                	if z <= -9.2e-27:
                		tmp = t_1
                	elif z <= 6.8e+19:
                		tmp = (y / a) * t
                	else:
                		tmp = t_1
                	return tmp
                
                function code(x, y, z, t, a)
                	t_1 = Float64(Float64(t - x) + x)
                	tmp = 0.0
                	if (z <= -9.2e-27)
                		tmp = t_1;
                	elseif (z <= 6.8e+19)
                		tmp = Float64(Float64(y / a) * t);
                	else
                		tmp = t_1;
                	end
                	return tmp
                end
                
                function tmp_2 = code(x, y, z, t, a)
                	t_1 = (t - x) + x;
                	tmp = 0.0;
                	if (z <= -9.2e-27)
                		tmp = t_1;
                	elseif (z <= 6.8e+19)
                		tmp = (y / a) * t;
                	else
                		tmp = t_1;
                	end
                	tmp_2 = tmp;
                end
                
                code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(t - x), $MachinePrecision] + x), $MachinePrecision]}, If[LessEqual[z, -9.2e-27], t$95$1, If[LessEqual[z, 6.8e+19], N[(N[(y / a), $MachinePrecision] * t), $MachinePrecision], t$95$1]]]
                
                \begin{array}{l}
                
                \\
                \begin{array}{l}
                t_1 := \left(t - x\right) + x\\
                \mathbf{if}\;z \leq -9.2 \cdot 10^{-27}:\\
                \;\;\;\;t\_1\\
                
                \mathbf{elif}\;z \leq 6.8 \cdot 10^{+19}:\\
                \;\;\;\;\frac{y}{a} \cdot t\\
                
                \mathbf{else}:\\
                \;\;\;\;t\_1\\
                
                
                \end{array}
                \end{array}
                
                Derivation
                1. Split input into 2 regimes
                2. if z < -9.1999999999999998e-27 or 6.8e19 < z

                  1. Initial program 46.4%

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

                    \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                  4. Step-by-step derivation
                    1. lower--.f6442.2

                      \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                  5. Applied rewrites42.2%

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

                  if -9.1999999999999998e-27 < z < 6.8e19

                  1. Initial program 91.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                      \[\leadsto \color{blue}{y \cdot \frac{t - x}{a}} + x \]
                    3. lower-fma.f64N/A

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

                      \[\leadsto \mathsf{fma}\left(y, \color{blue}{\frac{t - x}{a}}, x\right) \]
                    5. lower--.f6467.9

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

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

                    \[\leadsto \frac{t \cdot y}{\color{blue}{a}} \]
                  9. Step-by-step derivation
                    1. Applied rewrites28.2%

                      \[\leadsto t \cdot \color{blue}{\frac{y}{a}} \]
                  10. Recombined 2 regimes into one program.
                  11. Final simplification35.0%

                    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -9.2 \cdot 10^{-27}:\\ \;\;\;\;\left(t - x\right) + x\\ \mathbf{elif}\;z \leq 6.8 \cdot 10^{+19}:\\ \;\;\;\;\frac{y}{a} \cdot t\\ \mathbf{else}:\\ \;\;\;\;\left(t - x\right) + x\\ \end{array} \]
                  12. Add Preprocessing

                  Alternative 9: 19.1% accurate, 4.1× speedup?

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

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

                    \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                  4. Step-by-step derivation
                    1. lower--.f6425.0

                      \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                  5. Applied rewrites25.0%

                    \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                  6. Final simplification25.0%

                    \[\leadsto \left(t - x\right) + x \]
                  7. Add Preprocessing

                  Alternative 10: 2.8% 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 69.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                      \[\leadsto \mathsf{fma}\left(z - y, \color{blue}{\frac{x}{a - z}}, x\right) \]
                    16. lower--.f6441.9

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

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

                    \[\leadsto x + \color{blue}{-1 \cdot x} \]
                  7. Step-by-step derivation
                    1. Applied rewrites3.0%

                      \[\leadsto 0 \]
                    2. Add Preprocessing

                    Developer Target 1: 83.9% accurate, 0.6× speedup?

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

                    Reproduce

                    ?
                    herbie shell --seed 2024268 
                    (FPCore (x y z t a)
                      :name "Graphics.Rendering.Chart.Axis.Types:invLinMap from Chart-1.5.3"
                      :precision binary64
                    
                      :alt
                      (! :herbie-platform default (if (< z -125361310560950360000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (- t (* (/ y z) (- t x))) (if (< z 44467023691138110000000000000000000000000000000000000000000000000) (+ x (/ (- y z) (/ (- a z) (- t x)))) (- t (* (/ y z) (- t x))))))
                    
                      (+ x (/ (* (- y z) (- t x)) (- a z))))