Graphics.Rendering.Chart.SparkLine:renderSparkLine from Chart-1.5.3

Percentage Accurate: 96.7% → 99.7%
Time: 16.5s
Alternatives: 12
Speedup: 1.0×

Specification

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

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

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

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

Accuracy vs Speed?

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

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

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

Alternative 1: 99.7% accurate, 1.0× speedup?

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

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

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

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

    \[\leadsto \color{blue}{x - \frac{y - z}{\left(t - z\right) + 1} \cdot a} \]
  4. Add Preprocessing
  5. Final simplification99.6%

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

Alternative 2: 90.9% accurate, 0.6× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.8 \cdot 10^{+50} \lor \neg \left(t \leq 9 \cdot 10^{+110}\right):\\
\;\;\;\;x + a \cdot \frac{z - y}{t}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -4.8000000000000004e50 or 9.0000000000000005e110 < t

    1. Initial program 95.7%

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

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

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

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

    if -4.8000000000000004e50 < t < 9.0000000000000005e110

    1. Initial program 95.9%

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

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

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

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

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

Alternative 3: 73.3% accurate, 0.6× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.85 \cdot 10^{+49}:\\
\;\;\;\;x - a\\

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

\mathbf{elif}\;z \leq 1.1 \cdot 10^{-9}:\\
\;\;\;\;x - y \cdot a\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.85000000000000009e49 or 1.0999999999999999e-9 < z

    1. Initial program 92.0%

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

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

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

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

    if -1.85000000000000009e49 < z < -8.49999999999999968e-55

    1. Initial program 99.9%

      \[x - \frac{y - z}{\frac{\left(t - z\right) + 1}{a}} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. clear-num99.7%

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

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

        \[\leadsto x - \color{blue}{\frac{a}{\left(t - z\right) + 1}} \cdot \left(y - z\right) \]
    4. Applied egg-rr99.9%

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

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

    if -8.49999999999999968e-55 < z < 1.0999999999999999e-9

    1. Initial program 99.0%

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

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

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

      \[\leadsto x - \color{blue}{\frac{y}{1 + t}} \cdot a \]
    6. Taylor expanded in t around 0 76.2%

      \[\leadsto x - \color{blue}{y} \cdot a \]
  3. Recombined 3 regimes into one program.
  4. Final simplification78.3%

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

Alternative 4: 86.6% accurate, 0.7× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.25 \cdot 10^{+49} \lor \neg \left(z \leq 1.1 \cdot 10^{-9}\right):\\
\;\;\;\;x + \left(y - z\right) \cdot \frac{a}{z}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.2500000000000001e49 or 1.0999999999999999e-9 < z

    1. Initial program 92.1%

      \[x - \frac{y - z}{\frac{\left(t - z\right) + 1}{a}} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. clear-num92.0%

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

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

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

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

      \[\leadsto x - \color{blue}{\left(-1 \cdot \frac{a}{z}\right)} \cdot \left(y - z\right) \]
    6. Step-by-step derivation
      1. associate-*r/83.2%

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

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

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

    if -1.2500000000000001e49 < z < 1.0999999999999999e-9

    1. Initial program 99.1%

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

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

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

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

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

Alternative 5: 85.2% accurate, 0.7× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.25 \cdot 10^{+49} \lor \neg \left(z \leq 1.1 \cdot 10^{-9}\right):\\
\;\;\;\;\left(x + \frac{y \cdot a}{z}\right) - a\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.2500000000000001e49 or 1.0999999999999999e-9 < z

    1. Initial program 92.1%

      \[x - \frac{y - z}{\frac{\left(t - z\right) + 1}{a}} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. clear-num92.0%

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

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

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

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

      \[\leadsto x - \color{blue}{\left(-1 \cdot \frac{a}{z}\right)} \cdot \left(y - z\right) \]
    6. Step-by-step derivation
      1. associate-*r/83.2%

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

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

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

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

    if -1.2500000000000001e49 < z < 1.0999999999999999e-9

    1. Initial program 99.1%

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

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

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

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

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

Alternative 6: 84.2% accurate, 0.7× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.3 \cdot 10^{+49} \lor \neg \left(z \leq 1.1 \cdot 10^{-9}\right):\\
\;\;\;\;x - a\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.29999999999999994e49 or 1.0999999999999999e-9 < z

    1. Initial program 92.1%

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

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

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

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

    if -1.29999999999999994e49 < z < 1.0999999999999999e-9

    1. Initial program 99.1%

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

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

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

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

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

Alternative 7: 96.8% accurate, 0.7× speedup?

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < 4.89999999999999996e119

    1. Initial program 97.7%

      \[x - \frac{y - z}{\frac{\left(t - z\right) + 1}{a}} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. clear-num97.6%

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

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

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

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

    if 4.89999999999999996e119 < z

    1. Initial program 86.5%

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

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

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

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

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

Alternative 8: 73.1% accurate, 0.9× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.2 \cdot 10^{+26} \lor \neg \left(z \leq 1.1 \cdot 10^{-9}\right):\\
\;\;\;\;x - a\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -3.20000000000000029e26 or 1.0999999999999999e-9 < z

    1. Initial program 92.7%

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

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

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

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

    if -3.20000000000000029e26 < z < 1.0999999999999999e-9

    1. Initial program 99.1%

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

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

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

      \[\leadsto x - \color{blue}{\frac{y}{1 + t}} \cdot a \]
    6. Taylor expanded in t around 0 74.2%

      \[\leadsto x - \color{blue}{y} \cdot a \]
  3. Recombined 2 regimes into one program.
  4. Final simplification76.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3.2 \cdot 10^{+26} \lor \neg \left(z \leq 1.1 \cdot 10^{-9}\right):\\ \;\;\;\;x - a\\ \mathbf{else}:\\ \;\;\;\;x - y \cdot a\\ \end{array} \]
  5. Add Preprocessing

Alternative 9: 66.1% accurate, 1.0× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.4 \cdot 10^{+22} \lor \neg \left(z \leq 1.1 \cdot 10^{-9}\right):\\
\;\;\;\;x - a\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -3.4e22 or 1.0999999999999999e-9 < z

    1. Initial program 92.7%

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

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

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

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

    if -3.4e22 < z < 1.0999999999999999e-9

    1. Initial program 99.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3.4 \cdot 10^{+22} \lor \neg \left(z \leq 1.1 \cdot 10^{-9}\right):\\ \;\;\;\;x - a\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]
  5. Add Preprocessing

Alternative 10: 54.2% accurate, 1.1× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;a \leq -5.2 \cdot 10^{+249} \lor \neg \left(a \leq 6.8 \cdot 10^{+123}\right):\\
\;\;\;\;-a\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if a < -5.20000000000000038e249 or 6.80000000000000002e123 < a

    1. Initial program 99.8%

      \[x - \frac{y - z}{\frac{\left(t - z\right) + 1}{a}} \]
    2. Step-by-step derivation
      1. sub-neg99.8%

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \mathsf{fma}\left(y - z, \frac{a}{\left(-\color{blue}{\left(t + \left(-z\right)\right)}\right) + \left(-1\right)}, x\right) \]
      12. distribute-neg-in100.0%

        \[\leadsto \mathsf{fma}\left(y - z, \frac{a}{\color{blue}{\left(\left(-t\right) + \left(-\left(-z\right)\right)\right)} + \left(-1\right)}, x\right) \]
      13. remove-double-neg100.0%

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

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

        \[\leadsto \mathsf{fma}\left(y - z, \frac{a}{\color{blue}{\left(z - t\right)} + \left(-1\right)}, x\right) \]
      16. metadata-eval100.0%

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

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

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

      \[\leadsto \color{blue}{-1 \cdot a} \]
    7. Step-by-step derivation
      1. neg-mul-139.8%

        \[\leadsto \color{blue}{-a} \]
    8. Simplified39.8%

      \[\leadsto \color{blue}{-a} \]

    if -5.20000000000000038e249 < a < 6.80000000000000002e123

    1. Initial program 95.0%

      \[x - \frac{y - z}{\frac{\left(t - z\right) + 1}{a}} \]
    2. Step-by-step derivation
      1. sub-neg95.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -5.2 \cdot 10^{+249} \lor \neg \left(a \leq 6.8 \cdot 10^{+123}\right):\\ \;\;\;\;-a\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]
  5. Add Preprocessing

Alternative 11: 53.0% accurate, 13.0× speedup?

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

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

    \[x - \frac{y - z}{\frac{\left(t - z\right) + 1}{a}} \]
  2. Step-by-step derivation
    1. sub-neg95.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 12: 3.2% accurate, 13.0× speedup?

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

\\
a
\end{array}
Derivation
  1. Initial program 95.9%

    \[x - \frac{y - z}{\frac{\left(t - z\right) + 1}{a}} \]
  2. Step-by-step derivation
    1. sub-neg95.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \color{blue}{-1 \cdot a} \]
  7. Step-by-step derivation
    1. neg-mul-115.4%

      \[\leadsto \color{blue}{-a} \]
  8. Simplified15.4%

    \[\leadsto \color{blue}{-a} \]
  9. Step-by-step derivation
    1. neg-sub015.4%

      \[\leadsto \color{blue}{0 - a} \]
    2. sub-neg15.4%

      \[\leadsto \color{blue}{0 + \left(-a\right)} \]
    3. add-sqr-sqrt7.1%

      \[\leadsto 0 + \color{blue}{\sqrt{-a} \cdot \sqrt{-a}} \]
    4. sqrt-unprod7.1%

      \[\leadsto 0 + \color{blue}{\sqrt{\left(-a\right) \cdot \left(-a\right)}} \]
    5. sqr-neg7.1%

      \[\leadsto 0 + \sqrt{\color{blue}{a \cdot a}} \]
    6. sqrt-unprod1.6%

      \[\leadsto 0 + \color{blue}{\sqrt{a} \cdot \sqrt{a}} \]
    7. add-sqr-sqrt3.6%

      \[\leadsto 0 + \color{blue}{a} \]
  10. Applied egg-rr3.6%

    \[\leadsto \color{blue}{0 + a} \]
  11. Step-by-step derivation
    1. +-lft-identity3.6%

      \[\leadsto \color{blue}{a} \]
  12. Simplified3.6%

    \[\leadsto \color{blue}{a} \]
  13. Add Preprocessing

Developer Target 1: 99.7% accurate, 1.0× speedup?

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

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

Reproduce

?
herbie shell --seed 2024163 
(FPCore (x y z t a)
  :name "Graphics.Rendering.Chart.SparkLine:renderSparkLine from Chart-1.5.3"
  :precision binary64

  :alt
  (! :herbie-platform default (- x (* (/ (- y z) (+ (- t z) 1)) a)))

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