Graphics.Rendering.Chart.Plot.AreaSpots:renderAreaSpots4D from Chart-1.5.3

Percentage Accurate: 84.1% → 96.8%
Time: 7.2s
Alternatives: 10
Speedup: 1.0×

Specification

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

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

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

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

Alternative 1: 96.8% accurate, 0.8× speedup?

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

\\
\frac{x}{\frac{t - z}{y - z}}
\end{array}
Derivation
  1. Initial program 83.6%

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

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

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

      \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    4. clear-numN/A

      \[\leadsto x \cdot \color{blue}{\frac{1}{\frac{t - z}{y - z}}} \]
    5. un-div-invN/A

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

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

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

    \[\leadsto \color{blue}{\frac{x}{\frac{t - z}{y - z}}} \]
  5. Add Preprocessing

Alternative 2: 86.4% accurate, 0.3× speedup?

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

\\
\begin{array}{l}
t_1 := \frac{x \cdot \left(y - z\right)}{t - z}\\
\mathbf{if}\;t\_1 \leq 0 \lor \neg \left(t\_1 \leq 2 \cdot 10^{-94}\right):\\
\;\;\;\;\frac{x}{t - z} \cdot \left(y - z\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (/.f64 (*.f64 x (-.f64 y z)) (-.f64 t z)) < -0.0 or 1.9999999999999999e-94 < (/.f64 (*.f64 x (-.f64 y z)) (-.f64 t z))

    1. Initial program 81.4%

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

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{x}{t - z} \cdot \left(y - z\right)} \]
      7. lower-/.f6492.0

        \[\leadsto \color{blue}{\frac{x}{t - z}} \cdot \left(y - z\right) \]
    4. Applied rewrites92.0%

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

    if -0.0 < (/.f64 (*.f64 x (-.f64 y z)) (-.f64 t z)) < 1.9999999999999999e-94

    1. Initial program 99.3%

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

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

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

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
      4. clear-numN/A

        \[\leadsto x \cdot \color{blue}{\frac{1}{\frac{t - z}{y - z}}} \]
      5. un-div-invN/A

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

        \[\leadsto \color{blue}{\frac{x}{\frac{t - z}{y - z}}} \]
      7. lower-/.f6499.9

        \[\leadsto \frac{x}{\color{blue}{\frac{t - z}{y - z}}} \]
    4. Applied rewrites99.9%

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

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

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

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

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

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

        \[\leadsto \frac{\color{blue}{z \cdot x}}{-1 \cdot \left(t - z\right)} \]
      6. lower-*.f64N/A

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

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

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

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

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

        \[\leadsto \frac{z \cdot x}{\color{blue}{\left(\mathsf{neg}\left(\left(\mathsf{neg}\left(z\right)\right)\right)\right) - t}} \]
      12. remove-double-negN/A

        \[\leadsto \frac{z \cdot x}{\color{blue}{z} - t} \]
      13. lower--.f6477.9

        \[\leadsto \frac{z \cdot x}{\color{blue}{z - t}} \]
    7. Applied rewrites77.9%

      \[\leadsto \color{blue}{\frac{z \cdot x}{z - t}} \]
    8. Step-by-step derivation
      1. Applied rewrites78.2%

        \[\leadsto x \cdot \color{blue}{\frac{z}{z - t}} \]
    9. Recombined 2 regimes into one program.
    10. Final simplification90.3%

      \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{x \cdot \left(y - z\right)}{t - z} \leq 0 \lor \neg \left(\frac{x \cdot \left(y - z\right)}{t - z} \leq 2 \cdot 10^{-94}\right):\\ \;\;\;\;\frac{x}{t - z} \cdot \left(y - z\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot \frac{z}{z - t}\\ \end{array} \]
    11. Add Preprocessing

    Alternative 3: 75.5% accurate, 0.6× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -2.05 \cdot 10^{+35}:\\ \;\;\;\;\mathsf{fma}\left(\frac{y}{-z}, x, x\right)\\ \mathbf{elif}\;z \leq -5.4 \cdot 10^{-146}:\\ \;\;\;\;x \cdot \frac{y - z}{t}\\ \mathbf{elif}\;z \leq 0.85:\\ \;\;\;\;\frac{x}{t - z} \cdot y\\ \mathbf{else}:\\ \;\;\;\;x \cdot \frac{z}{z - t}\\ \end{array} \end{array} \]
    (FPCore (x y z t)
     :precision binary64
     (if (<= z -2.05e+35)
       (fma (/ y (- z)) x x)
       (if (<= z -5.4e-146)
         (* x (/ (- y z) t))
         (if (<= z 0.85) (* (/ x (- t z)) y) (* x (/ z (- z t)))))))
    double code(double x, double y, double z, double t) {
    	double tmp;
    	if (z <= -2.05e+35) {
    		tmp = fma((y / -z), x, x);
    	} else if (z <= -5.4e-146) {
    		tmp = x * ((y - z) / t);
    	} else if (z <= 0.85) {
    		tmp = (x / (t - z)) * y;
    	} else {
    		tmp = x * (z / (z - t));
    	}
    	return tmp;
    }
    
    function code(x, y, z, t)
    	tmp = 0.0
    	if (z <= -2.05e+35)
    		tmp = fma(Float64(y / Float64(-z)), x, x);
    	elseif (z <= -5.4e-146)
    		tmp = Float64(x * Float64(Float64(y - z) / t));
    	elseif (z <= 0.85)
    		tmp = Float64(Float64(x / Float64(t - z)) * y);
    	else
    		tmp = Float64(x * Float64(z / Float64(z - t)));
    	end
    	return tmp
    end
    
    code[x_, y_, z_, t_] := If[LessEqual[z, -2.05e+35], N[(N[(y / (-z)), $MachinePrecision] * x + x), $MachinePrecision], If[LessEqual[z, -5.4e-146], N[(x * N[(N[(y - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 0.85], N[(N[(x / N[(t - z), $MachinePrecision]), $MachinePrecision] * y), $MachinePrecision], N[(x * N[(z / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;z \leq -2.05 \cdot 10^{+35}:\\
    \;\;\;\;\mathsf{fma}\left(\frac{y}{-z}, x, x\right)\\
    
    \mathbf{elif}\;z \leq -5.4 \cdot 10^{-146}:\\
    \;\;\;\;x \cdot \frac{y - z}{t}\\
    
    \mathbf{elif}\;z \leq 0.85:\\
    \;\;\;\;\frac{x}{t - z} \cdot y\\
    
    \mathbf{else}:\\
    \;\;\;\;x \cdot \frac{z}{z - t}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 4 regimes
    2. if z < -2.0499999999999999e35

      1. Initial program 72.6%

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

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

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

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

          \[\leadsto 0 - \color{blue}{x \cdot \frac{y - z}{z}} \]
        4. div-subN/A

          \[\leadsto 0 - x \cdot \color{blue}{\left(\frac{y}{z} - \frac{z}{z}\right)} \]
        5. sub-negN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      if -2.0499999999999999e35 < z < -5.3999999999999999e-146

      1. Initial program 91.1%

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

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

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

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

          \[\leadsto \frac{\color{blue}{\left(y - z\right) \cdot x}}{t} \]
        4. lower--.f6470.1

          \[\leadsto \frac{\color{blue}{\left(y - z\right)} \cdot x}{t} \]
      5. Applied rewrites70.1%

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

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

        if -5.3999999999999999e-146 < z < 0.849999999999999978

        1. Initial program 93.4%

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

          \[\leadsto \color{blue}{\frac{x \cdot y}{t - z}} \]
        4. Step-by-step derivation
          1. associate-*l/N/A

            \[\leadsto \color{blue}{\frac{x}{t - z} \cdot y} \]
          2. lower-*.f64N/A

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

            \[\leadsto \color{blue}{\frac{x}{t - z}} \cdot y \]
          4. lower--.f6487.5

            \[\leadsto \frac{x}{\color{blue}{t - z}} \cdot y \]
        5. Applied rewrites87.5%

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

        if 0.849999999999999978 < z

        1. Initial program 77.2%

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

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

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

            \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
          4. clear-numN/A

            \[\leadsto x \cdot \color{blue}{\frac{1}{\frac{t - z}{y - z}}} \]
          5. un-div-invN/A

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

            \[\leadsto \color{blue}{\frac{x}{\frac{t - z}{y - z}}} \]
          7. lower-/.f6499.9

            \[\leadsto \frac{x}{\color{blue}{\frac{t - z}{y - z}}} \]
        4. Applied rewrites99.9%

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

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

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

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

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

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

            \[\leadsto \frac{\color{blue}{z \cdot x}}{-1 \cdot \left(t - z\right)} \]
          6. lower-*.f64N/A

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

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

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

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

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

            \[\leadsto \frac{z \cdot x}{\color{blue}{\left(\mathsf{neg}\left(\left(\mathsf{neg}\left(z\right)\right)\right)\right) - t}} \]
          12. remove-double-negN/A

            \[\leadsto \frac{z \cdot x}{\color{blue}{z} - t} \]
          13. lower--.f6464.6

            \[\leadsto \frac{z \cdot x}{\color{blue}{z - t}} \]
        7. Applied rewrites64.6%

          \[\leadsto \color{blue}{\frac{z \cdot x}{z - t}} \]
        8. Step-by-step derivation
          1. Applied rewrites81.8%

            \[\leadsto x \cdot \color{blue}{\frac{z}{z - t}} \]
        9. Recombined 4 regimes into one program.
        10. Final simplification83.4%

          \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.05 \cdot 10^{+35}:\\ \;\;\;\;\mathsf{fma}\left(\frac{y}{-z}, x, x\right)\\ \mathbf{elif}\;z \leq -5.4 \cdot 10^{-146}:\\ \;\;\;\;x \cdot \frac{y - z}{t}\\ \mathbf{elif}\;z \leq 0.85:\\ \;\;\;\;\frac{x}{t - z} \cdot y\\ \mathbf{else}:\\ \;\;\;\;x \cdot \frac{z}{z - t}\\ \end{array} \]
        11. Add Preprocessing

        Alternative 4: 73.0% accurate, 0.6× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} t_1 := x \cdot \frac{z}{z - t}\\ \mathbf{if}\;z \leq -5.8 \cdot 10^{+98}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq -3.8 \cdot 10^{+37}:\\ \;\;\;\;\left(-y\right) \cdot \frac{x}{z}\\ \mathbf{elif}\;z \leq 10500:\\ \;\;\;\;x \cdot \frac{y - z}{t}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
        (FPCore (x y z t)
         :precision binary64
         (let* ((t_1 (* x (/ z (- z t)))))
           (if (<= z -5.8e+98)
             t_1
             (if (<= z -3.8e+37)
               (* (- y) (/ x z))
               (if (<= z 10500.0) (* x (/ (- y z) t)) t_1)))))
        double code(double x, double y, double z, double t) {
        	double t_1 = x * (z / (z - t));
        	double tmp;
        	if (z <= -5.8e+98) {
        		tmp = t_1;
        	} else if (z <= -3.8e+37) {
        		tmp = -y * (x / z);
        	} else if (z <= 10500.0) {
        		tmp = x * ((y - z) / t);
        	} else {
        		tmp = t_1;
        	}
        	return tmp;
        }
        
        real(8) function code(x, y, z, t)
            real(8), intent (in) :: x
            real(8), intent (in) :: y
            real(8), intent (in) :: z
            real(8), intent (in) :: t
            real(8) :: t_1
            real(8) :: tmp
            t_1 = x * (z / (z - t))
            if (z <= (-5.8d+98)) then
                tmp = t_1
            else if (z <= (-3.8d+37)) then
                tmp = -y * (x / z)
            else if (z <= 10500.0d0) then
                tmp = x * ((y - z) / t)
            else
                tmp = t_1
            end if
            code = tmp
        end function
        
        public static double code(double x, double y, double z, double t) {
        	double t_1 = x * (z / (z - t));
        	double tmp;
        	if (z <= -5.8e+98) {
        		tmp = t_1;
        	} else if (z <= -3.8e+37) {
        		tmp = -y * (x / z);
        	} else if (z <= 10500.0) {
        		tmp = x * ((y - z) / t);
        	} else {
        		tmp = t_1;
        	}
        	return tmp;
        }
        
        def code(x, y, z, t):
        	t_1 = x * (z / (z - t))
        	tmp = 0
        	if z <= -5.8e+98:
        		tmp = t_1
        	elif z <= -3.8e+37:
        		tmp = -y * (x / z)
        	elif z <= 10500.0:
        		tmp = x * ((y - z) / t)
        	else:
        		tmp = t_1
        	return tmp
        
        function code(x, y, z, t)
        	t_1 = Float64(x * Float64(z / Float64(z - t)))
        	tmp = 0.0
        	if (z <= -5.8e+98)
        		tmp = t_1;
        	elseif (z <= -3.8e+37)
        		tmp = Float64(Float64(-y) * Float64(x / z));
        	elseif (z <= 10500.0)
        		tmp = Float64(x * Float64(Float64(y - z) / t));
        	else
        		tmp = t_1;
        	end
        	return tmp
        end
        
        function tmp_2 = code(x, y, z, t)
        	t_1 = x * (z / (z - t));
        	tmp = 0.0;
        	if (z <= -5.8e+98)
        		tmp = t_1;
        	elseif (z <= -3.8e+37)
        		tmp = -y * (x / z);
        	elseif (z <= 10500.0)
        		tmp = x * ((y - z) / t);
        	else
        		tmp = t_1;
        	end
        	tmp_2 = tmp;
        end
        
        code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x * N[(z / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -5.8e+98], t$95$1, If[LessEqual[z, -3.8e+37], N[((-y) * N[(x / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 10500.0], N[(x * N[(N[(y - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        t_1 := x \cdot \frac{z}{z - t}\\
        \mathbf{if}\;z \leq -5.8 \cdot 10^{+98}:\\
        \;\;\;\;t\_1\\
        
        \mathbf{elif}\;z \leq -3.8 \cdot 10^{+37}:\\
        \;\;\;\;\left(-y\right) \cdot \frac{x}{z}\\
        
        \mathbf{elif}\;z \leq 10500:\\
        \;\;\;\;x \cdot \frac{y - z}{t}\\
        
        \mathbf{else}:\\
        \;\;\;\;t\_1\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 3 regimes
        2. if z < -5.8000000000000002e98 or 10500 < z

          1. Initial program 73.3%

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

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

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

              \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
            4. clear-numN/A

              \[\leadsto x \cdot \color{blue}{\frac{1}{\frac{t - z}{y - z}}} \]
            5. un-div-invN/A

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

              \[\leadsto \color{blue}{\frac{x}{\frac{t - z}{y - z}}} \]
            7. lower-/.f6499.9

              \[\leadsto \frac{x}{\color{blue}{\frac{t - z}{y - z}}} \]
          4. Applied rewrites99.9%

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

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

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

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

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

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

              \[\leadsto \frac{\color{blue}{z \cdot x}}{-1 \cdot \left(t - z\right)} \]
            6. lower-*.f64N/A

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

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

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

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

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

              \[\leadsto \frac{z \cdot x}{\color{blue}{\left(\mathsf{neg}\left(\left(\mathsf{neg}\left(z\right)\right)\right)\right) - t}} \]
            12. remove-double-negN/A

              \[\leadsto \frac{z \cdot x}{\color{blue}{z} - t} \]
            13. lower--.f6463.3

              \[\leadsto \frac{z \cdot x}{\color{blue}{z - t}} \]
          7. Applied rewrites63.3%

            \[\leadsto \color{blue}{\frac{z \cdot x}{z - t}} \]
          8. Step-by-step derivation
            1. Applied rewrites84.5%

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

            if -5.8000000000000002e98 < z < -3.7999999999999999e37

            1. Initial program 86.5%

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

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

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

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

                \[\leadsto 0 - \color{blue}{x \cdot \frac{y - z}{z}} \]
              4. div-subN/A

                \[\leadsto 0 - x \cdot \color{blue}{\left(\frac{y}{z} - \frac{z}{z}\right)} \]
              5. sub-negN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto -1 \cdot \color{blue}{\frac{x \cdot y}{z}} \]
            7. Step-by-step derivation
              1. Applied rewrites72.8%

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

              if -3.7999999999999999e37 < z < 10500

              1. Initial program 92.8%

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

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

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

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

                  \[\leadsto \frac{\color{blue}{\left(y - z\right) \cdot x}}{t} \]
                4. lower--.f6475.5

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

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

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

                \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -5.8 \cdot 10^{+98}:\\ \;\;\;\;x \cdot \frac{z}{z - t}\\ \mathbf{elif}\;z \leq -3.8 \cdot 10^{+37}:\\ \;\;\;\;\left(-y\right) \cdot \frac{x}{z}\\ \mathbf{elif}\;z \leq 10500:\\ \;\;\;\;x \cdot \frac{y - z}{t}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \frac{z}{z - t}\\ \end{array} \]
              9. Add Preprocessing

              Alternative 5: 61.0% accurate, 0.7× speedup?

              \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -5.8 \cdot 10^{+98}:\\ \;\;\;\;\frac{x}{1}\\ \mathbf{elif}\;z \leq -2.5 \cdot 10^{+37}:\\ \;\;\;\;\left(-y\right) \cdot \frac{x}{z}\\ \mathbf{elif}\;z \leq 2200000000:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{1}\\ \end{array} \end{array} \]
              (FPCore (x y z t)
               :precision binary64
               (if (<= z -5.8e+98)
                 (/ x 1.0)
                 (if (<= z -2.5e+37)
                   (* (- y) (/ x z))
                   (if (<= z 2200000000.0) (* x (/ y t)) (/ x 1.0)))))
              double code(double x, double y, double z, double t) {
              	double tmp;
              	if (z <= -5.8e+98) {
              		tmp = x / 1.0;
              	} else if (z <= -2.5e+37) {
              		tmp = -y * (x / z);
              	} else if (z <= 2200000000.0) {
              		tmp = x * (y / t);
              	} else {
              		tmp = x / 1.0;
              	}
              	return tmp;
              }
              
              real(8) function code(x, y, z, t)
                  real(8), intent (in) :: x
                  real(8), intent (in) :: y
                  real(8), intent (in) :: z
                  real(8), intent (in) :: t
                  real(8) :: tmp
                  if (z <= (-5.8d+98)) then
                      tmp = x / 1.0d0
                  else if (z <= (-2.5d+37)) then
                      tmp = -y * (x / z)
                  else if (z <= 2200000000.0d0) then
                      tmp = x * (y / t)
                  else
                      tmp = x / 1.0d0
                  end if
                  code = tmp
              end function
              
              public static double code(double x, double y, double z, double t) {
              	double tmp;
              	if (z <= -5.8e+98) {
              		tmp = x / 1.0;
              	} else if (z <= -2.5e+37) {
              		tmp = -y * (x / z);
              	} else if (z <= 2200000000.0) {
              		tmp = x * (y / t);
              	} else {
              		tmp = x / 1.0;
              	}
              	return tmp;
              }
              
              def code(x, y, z, t):
              	tmp = 0
              	if z <= -5.8e+98:
              		tmp = x / 1.0
              	elif z <= -2.5e+37:
              		tmp = -y * (x / z)
              	elif z <= 2200000000.0:
              		tmp = x * (y / t)
              	else:
              		tmp = x / 1.0
              	return tmp
              
              function code(x, y, z, t)
              	tmp = 0.0
              	if (z <= -5.8e+98)
              		tmp = Float64(x / 1.0);
              	elseif (z <= -2.5e+37)
              		tmp = Float64(Float64(-y) * Float64(x / z));
              	elseif (z <= 2200000000.0)
              		tmp = Float64(x * Float64(y / t));
              	else
              		tmp = Float64(x / 1.0);
              	end
              	return tmp
              end
              
              function tmp_2 = code(x, y, z, t)
              	tmp = 0.0;
              	if (z <= -5.8e+98)
              		tmp = x / 1.0;
              	elseif (z <= -2.5e+37)
              		tmp = -y * (x / z);
              	elseif (z <= 2200000000.0)
              		tmp = x * (y / t);
              	else
              		tmp = x / 1.0;
              	end
              	tmp_2 = tmp;
              end
              
              code[x_, y_, z_, t_] := If[LessEqual[z, -5.8e+98], N[(x / 1.0), $MachinePrecision], If[LessEqual[z, -2.5e+37], N[((-y) * N[(x / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2200000000.0], N[(x * N[(y / t), $MachinePrecision]), $MachinePrecision], N[(x / 1.0), $MachinePrecision]]]]
              
              \begin{array}{l}
              
              \\
              \begin{array}{l}
              \mathbf{if}\;z \leq -5.8 \cdot 10^{+98}:\\
              \;\;\;\;\frac{x}{1}\\
              
              \mathbf{elif}\;z \leq -2.5 \cdot 10^{+37}:\\
              \;\;\;\;\left(-y\right) \cdot \frac{x}{z}\\
              
              \mathbf{elif}\;z \leq 2200000000:\\
              \;\;\;\;x \cdot \frac{y}{t}\\
              
              \mathbf{else}:\\
              \;\;\;\;\frac{x}{1}\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 3 regimes
              2. if z < -5.8000000000000002e98 or 2.2e9 < z

                1. Initial program 72.9%

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

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

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

                    \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
                  4. clear-numN/A

                    \[\leadsto x \cdot \color{blue}{\frac{1}{\frac{t - z}{y - z}}} \]
                  5. un-div-invN/A

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

                    \[\leadsto \color{blue}{\frac{x}{\frac{t - z}{y - z}}} \]
                  7. lower-/.f6499.9

                    \[\leadsto \frac{x}{\color{blue}{\frac{t - z}{y - z}}} \]
                4. Applied rewrites99.9%

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

                  \[\leadsto \frac{x}{\color{blue}{1}} \]
                6. Step-by-step derivation
                  1. Applied rewrites68.9%

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

                  if -5.8000000000000002e98 < z < -2.49999999999999994e37

                  1. Initial program 86.5%

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

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

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

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

                      \[\leadsto 0 - \color{blue}{x \cdot \frac{y - z}{z}} \]
                    4. div-subN/A

                      \[\leadsto 0 - x \cdot \color{blue}{\left(\frac{y}{z} - \frac{z}{z}\right)} \]
                    5. sub-negN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto -1 \cdot \color{blue}{\frac{x \cdot y}{z}} \]
                  7. Step-by-step derivation
                    1. Applied rewrites72.8%

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

                    if -2.49999999999999994e37 < z < 2.2e9

                    1. Initial program 92.9%

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

                      \[\leadsto \color{blue}{\frac{x \cdot y}{t}} \]
                    4. Step-by-step derivation
                      1. lower-/.f64N/A

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

                        \[\leadsto \frac{\color{blue}{y \cdot x}}{t} \]
                      3. lower-*.f6465.6

                        \[\leadsto \frac{\color{blue}{y \cdot x}}{t} \]
                    5. Applied rewrites65.6%

                      \[\leadsto \color{blue}{\frac{y \cdot x}{t}} \]
                    6. Step-by-step derivation
                      1. Applied rewrites67.3%

                        \[\leadsto x \cdot \color{blue}{\frac{y}{t}} \]
                    7. Recombined 3 regimes into one program.
                    8. Add Preprocessing

                    Alternative 6: 74.5% accurate, 0.7× speedup?

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

                      1. Initial program 73.3%

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

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

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

                          \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
                        4. clear-numN/A

                          \[\leadsto x \cdot \color{blue}{\frac{1}{\frac{t - z}{y - z}}} \]
                        5. un-div-invN/A

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

                          \[\leadsto \color{blue}{\frac{x}{\frac{t - z}{y - z}}} \]
                        7. lower-/.f6499.9

                          \[\leadsto \frac{x}{\color{blue}{\frac{t - z}{y - z}}} \]
                      4. Applied rewrites99.9%

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

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

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

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

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

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

                          \[\leadsto \frac{\color{blue}{z \cdot x}}{-1 \cdot \left(t - z\right)} \]
                        6. lower-*.f64N/A

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

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

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

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

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

                          \[\leadsto \frac{z \cdot x}{\color{blue}{\left(\mathsf{neg}\left(\left(\mathsf{neg}\left(z\right)\right)\right)\right) - t}} \]
                        12. remove-double-negN/A

                          \[\leadsto \frac{z \cdot x}{\color{blue}{z} - t} \]
                        13. lower--.f6463.3

                          \[\leadsto \frac{z \cdot x}{\color{blue}{z - t}} \]
                      7. Applied rewrites63.3%

                        \[\leadsto \color{blue}{\frac{z \cdot x}{z - t}} \]
                      8. Step-by-step derivation
                        1. Applied rewrites84.5%

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

                        if -5.8000000000000002e98 < z < 0.849999999999999978

                        1. Initial program 92.2%

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

                          \[\leadsto \color{blue}{\frac{x \cdot y}{t - z}} \]
                        4. Step-by-step derivation
                          1. associate-*l/N/A

                            \[\leadsto \color{blue}{\frac{x}{t - z} \cdot y} \]
                          2. lower-*.f64N/A

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

                            \[\leadsto \color{blue}{\frac{x}{t - z}} \cdot y \]
                          4. lower--.f6479.2

                            \[\leadsto \frac{x}{\color{blue}{t - z}} \cdot y \]
                        5. Applied rewrites79.2%

                          \[\leadsto \color{blue}{\frac{x}{t - z} \cdot y} \]
                      9. Recombined 2 regimes into one program.
                      10. Final simplification81.6%

                        \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -5.8 \cdot 10^{+98} \lor \neg \left(z \leq 0.85\right):\\ \;\;\;\;x \cdot \frac{z}{z - t}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{t - z} \cdot y\\ \end{array} \]
                      11. Add Preprocessing

                      Alternative 7: 70.5% accurate, 0.7× speedup?

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

                        1. Initial program 77.9%

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

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

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

                            \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
                          4. clear-numN/A

                            \[\leadsto x \cdot \color{blue}{\frac{1}{\frac{t - z}{y - z}}} \]
                          5. un-div-invN/A

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

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

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

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

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

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

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

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

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

                            \[\leadsto \frac{\color{blue}{z \cdot x}}{-1 \cdot \left(t - z\right)} \]
                          6. lower-*.f64N/A

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

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

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

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

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

                            \[\leadsto \frac{z \cdot x}{\color{blue}{\left(\mathsf{neg}\left(\left(\mathsf{neg}\left(z\right)\right)\right)\right) - t}} \]
                          12. remove-double-negN/A

                            \[\leadsto \frac{z \cdot x}{\color{blue}{z} - t} \]
                          13. lower--.f6459.7

                            \[\leadsto \frac{z \cdot x}{\color{blue}{z - t}} \]
                        7. Applied rewrites59.7%

                          \[\leadsto \color{blue}{\frac{z \cdot x}{z - t}} \]
                        8. Step-by-step derivation
                          1. Applied rewrites76.4%

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

                          if -2.09999999999999998e-84 < z < 0.27000000000000002

                          1. Initial program 92.2%

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

                            \[\leadsto \color{blue}{\frac{x \cdot y}{t}} \]
                          4. Step-by-step derivation
                            1. lower-/.f64N/A

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

                              \[\leadsto \frac{\color{blue}{y \cdot x}}{t} \]
                            3. lower-*.f6471.4

                              \[\leadsto \frac{\color{blue}{y \cdot x}}{t} \]
                          5. Applied rewrites71.4%

                            \[\leadsto \color{blue}{\frac{y \cdot x}{t}} \]
                          6. Step-by-step derivation
                            1. Applied rewrites72.6%

                              \[\leadsto x \cdot \color{blue}{\frac{y}{t}} \]
                          7. Recombined 2 regimes into one program.
                          8. Final simplification74.9%

                            \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.1 \cdot 10^{-84} \lor \neg \left(z \leq 0.27\right):\\ \;\;\;\;x \cdot \frac{z}{z - t}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \end{array} \]
                          9. Add Preprocessing

                          Alternative 8: 61.6% accurate, 0.8× speedup?

                          \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -2.1 \cdot 10^{+35} \lor \neg \left(z \leq 2200000000\right):\\ \;\;\;\;\frac{x}{1}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \end{array} \end{array} \]
                          (FPCore (x y z t)
                           :precision binary64
                           (if (or (<= z -2.1e+35) (not (<= z 2200000000.0))) (/ x 1.0) (* x (/ y t))))
                          double code(double x, double y, double z, double t) {
                          	double tmp;
                          	if ((z <= -2.1e+35) || !(z <= 2200000000.0)) {
                          		tmp = x / 1.0;
                          	} else {
                          		tmp = x * (y / t);
                          	}
                          	return tmp;
                          }
                          
                          real(8) function code(x, y, z, t)
                              real(8), intent (in) :: x
                              real(8), intent (in) :: y
                              real(8), intent (in) :: z
                              real(8), intent (in) :: t
                              real(8) :: tmp
                              if ((z <= (-2.1d+35)) .or. (.not. (z <= 2200000000.0d0))) then
                                  tmp = x / 1.0d0
                              else
                                  tmp = x * (y / t)
                              end if
                              code = tmp
                          end function
                          
                          public static double code(double x, double y, double z, double t) {
                          	double tmp;
                          	if ((z <= -2.1e+35) || !(z <= 2200000000.0)) {
                          		tmp = x / 1.0;
                          	} else {
                          		tmp = x * (y / t);
                          	}
                          	return tmp;
                          }
                          
                          def code(x, y, z, t):
                          	tmp = 0
                          	if (z <= -2.1e+35) or not (z <= 2200000000.0):
                          		tmp = x / 1.0
                          	else:
                          		tmp = x * (y / t)
                          	return tmp
                          
                          function code(x, y, z, t)
                          	tmp = 0.0
                          	if ((z <= -2.1e+35) || !(z <= 2200000000.0))
                          		tmp = Float64(x / 1.0);
                          	else
                          		tmp = Float64(x * Float64(y / t));
                          	end
                          	return tmp
                          end
                          
                          function tmp_2 = code(x, y, z, t)
                          	tmp = 0.0;
                          	if ((z <= -2.1e+35) || ~((z <= 2200000000.0)))
                          		tmp = x / 1.0;
                          	else
                          		tmp = x * (y / t);
                          	end
                          	tmp_2 = tmp;
                          end
                          
                          code[x_, y_, z_, t_] := If[Or[LessEqual[z, -2.1e+35], N[Not[LessEqual[z, 2200000000.0]], $MachinePrecision]], N[(x / 1.0), $MachinePrecision], N[(x * N[(y / t), $MachinePrecision]), $MachinePrecision]]
                          
                          \begin{array}{l}
                          
                          \\
                          \begin{array}{l}
                          \mathbf{if}\;z \leq -2.1 \cdot 10^{+35} \lor \neg \left(z \leq 2200000000\right):\\
                          \;\;\;\;\frac{x}{1}\\
                          
                          \mathbf{else}:\\
                          \;\;\;\;x \cdot \frac{y}{t}\\
                          
                          
                          \end{array}
                          \end{array}
                          
                          Derivation
                          1. Split input into 2 regimes
                          2. if z < -2.0999999999999999e35 or 2.2e9 < z

                            1. Initial program 74.4%

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

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

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

                                \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
                              4. clear-numN/A

                                \[\leadsto x \cdot \color{blue}{\frac{1}{\frac{t - z}{y - z}}} \]
                              5. un-div-invN/A

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

                                \[\leadsto \color{blue}{\frac{x}{\frac{t - z}{y - z}}} \]
                              7. lower-/.f6499.9

                                \[\leadsto \frac{x}{\color{blue}{\frac{t - z}{y - z}}} \]
                            4. Applied rewrites99.9%

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

                              \[\leadsto \frac{x}{\color{blue}{1}} \]
                            6. Step-by-step derivation
                              1. Applied rewrites64.1%

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

                              if -2.0999999999999999e35 < z < 2.2e9

                              1. Initial program 92.9%

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

                                \[\leadsto \color{blue}{\frac{x \cdot y}{t}} \]
                              4. Step-by-step derivation
                                1. lower-/.f64N/A

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

                                  \[\leadsto \frac{\color{blue}{y \cdot x}}{t} \]
                                3. lower-*.f6465.6

                                  \[\leadsto \frac{\color{blue}{y \cdot x}}{t} \]
                              5. Applied rewrites65.6%

                                \[\leadsto \color{blue}{\frac{y \cdot x}{t}} \]
                              6. Step-by-step derivation
                                1. Applied rewrites67.3%

                                  \[\leadsto x \cdot \color{blue}{\frac{y}{t}} \]
                              7. Recombined 2 regimes into one program.
                              8. Final simplification65.7%

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

                              Alternative 9: 96.8% accurate, 1.0× speedup?

                              \[\begin{array}{l} \\ \frac{y - z}{t - z} \cdot x \end{array} \]
                              (FPCore (x y z t) :precision binary64 (* (/ (- y z) (- t z)) x))
                              double code(double x, double y, double z, double t) {
                              	return ((y - z) / (t - z)) * x;
                              }
                              
                              real(8) function code(x, y, z, t)
                                  real(8), intent (in) :: x
                                  real(8), intent (in) :: y
                                  real(8), intent (in) :: z
                                  real(8), intent (in) :: t
                                  code = ((y - z) / (t - z)) * x
                              end function
                              
                              public static double code(double x, double y, double z, double t) {
                              	return ((y - z) / (t - z)) * x;
                              }
                              
                              def code(x, y, z, t):
                              	return ((y - z) / (t - z)) * x
                              
                              function code(x, y, z, t)
                              	return Float64(Float64(Float64(y - z) / Float64(t - z)) * x)
                              end
                              
                              function tmp = code(x, y, z, t)
                              	tmp = ((y - z) / (t - z)) * x;
                              end
                              
                              code[x_, y_, z_, t_] := N[(N[(N[(y - z), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision] * x), $MachinePrecision]
                              
                              \begin{array}{l}
                              
                              \\
                              \frac{y - z}{t - z} \cdot x
                              \end{array}
                              
                              Derivation
                              1. Initial program 83.6%

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

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

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

                                  \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
                                4. *-commutativeN/A

                                  \[\leadsto \color{blue}{\frac{y - z}{t - z} \cdot x} \]
                                5. lower-*.f64N/A

                                  \[\leadsto \color{blue}{\frac{y - z}{t - z} \cdot x} \]
                                6. lower-/.f6498.0

                                  \[\leadsto \color{blue}{\frac{y - z}{t - z}} \cdot x \]
                              4. Applied rewrites98.0%

                                \[\leadsto \color{blue}{\frac{y - z}{t - z} \cdot x} \]
                              5. Add Preprocessing

                              Alternative 10: 35.6% accurate, 1.9× speedup?

                              \[\begin{array}{l} \\ \frac{x}{1} \end{array} \]
                              (FPCore (x y z t) :precision binary64 (/ x 1.0))
                              double code(double x, double y, double z, double t) {
                              	return x / 1.0;
                              }
                              
                              real(8) function code(x, y, z, t)
                                  real(8), intent (in) :: x
                                  real(8), intent (in) :: y
                                  real(8), intent (in) :: z
                                  real(8), intent (in) :: t
                                  code = x / 1.0d0
                              end function
                              
                              public static double code(double x, double y, double z, double t) {
                              	return x / 1.0;
                              }
                              
                              def code(x, y, z, t):
                              	return x / 1.0
                              
                              function code(x, y, z, t)
                              	return Float64(x / 1.0)
                              end
                              
                              function tmp = code(x, y, z, t)
                              	tmp = x / 1.0;
                              end
                              
                              code[x_, y_, z_, t_] := N[(x / 1.0), $MachinePrecision]
                              
                              \begin{array}{l}
                              
                              \\
                              \frac{x}{1}
                              \end{array}
                              
                              Derivation
                              1. Initial program 83.6%

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

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

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

                                  \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
                                4. clear-numN/A

                                  \[\leadsto x \cdot \color{blue}{\frac{1}{\frac{t - z}{y - z}}} \]
                                5. un-div-invN/A

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

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

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

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

                                \[\leadsto \frac{x}{\color{blue}{1}} \]
                              6. Step-by-step derivation
                                1. Applied rewrites37.6%

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

                                Developer Target 1: 96.8% accurate, 0.8× speedup?

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

                                Reproduce

                                ?
                                herbie shell --seed 2024324 
                                (FPCore (x y z t)
                                  :name "Graphics.Rendering.Chart.Plot.AreaSpots:renderAreaSpots4D from Chart-1.5.3"
                                  :precision binary64
                                
                                  :alt
                                  (! :herbie-platform default (/ x (/ (- t z) (- y z))))
                                
                                  (/ (* x (- y z)) (- t z)))