Rosa's DopplerBench

Percentage Accurate: 73.2% → 98.0%
Time: 7.7s
Alternatives: 11
Speedup: 0.8×

Specification

?
\[\begin{array}{l} \\ \frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \end{array} \]
(FPCore (u v t1) :precision binary64 (/ (* (- t1) v) (* (+ t1 u) (+ t1 u))))
double code(double u, double v, double t1) {
	return (-t1 * v) / ((t1 + u) * (t1 + u));
}
real(8) function code(u, v, t1)
    real(8), intent (in) :: u
    real(8), intent (in) :: v
    real(8), intent (in) :: t1
    code = (-t1 * v) / ((t1 + u) * (t1 + u))
end function
public static double code(double u, double v, double t1) {
	return (-t1 * v) / ((t1 + u) * (t1 + u));
}
def code(u, v, t1):
	return (-t1 * v) / ((t1 + u) * (t1 + u))
function code(u, v, t1)
	return Float64(Float64(Float64(-t1) * v) / Float64(Float64(t1 + u) * Float64(t1 + u)))
end
function tmp = code(u, v, t1)
	tmp = (-t1 * v) / ((t1 + u) * (t1 + u));
end
code[u_, v_, t1_] := N[(N[((-t1) * v), $MachinePrecision] / N[(N[(t1 + u), $MachinePrecision] * N[(t1 + u), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}
\end{array}

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

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

Accuracy vs Speed?

Herbie found 11 alternatives:

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

Initial Program: 73.2% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \end{array} \]
(FPCore (u v t1) :precision binary64 (/ (* (- t1) v) (* (+ t1 u) (+ t1 u))))
double code(double u, double v, double t1) {
	return (-t1 * v) / ((t1 + u) * (t1 + u));
}
real(8) function code(u, v, t1)
    real(8), intent (in) :: u
    real(8), intent (in) :: v
    real(8), intent (in) :: t1
    code = (-t1 * v) / ((t1 + u) * (t1 + u))
end function
public static double code(double u, double v, double t1) {
	return (-t1 * v) / ((t1 + u) * (t1 + u));
}
def code(u, v, t1):
	return (-t1 * v) / ((t1 + u) * (t1 + u))
function code(u, v, t1)
	return Float64(Float64(Float64(-t1) * v) / Float64(Float64(t1 + u) * Float64(t1 + u)))
end
function tmp = code(u, v, t1)
	tmp = (-t1 * v) / ((t1 + u) * (t1 + u));
end
code[u_, v_, t1_] := N[(N[((-t1) * v), $MachinePrecision] / N[(N[(t1 + u), $MachinePrecision] * N[(t1 + u), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}
\end{array}

Alternative 1: 98.0% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \frac{\frac{v}{t1 + u} \cdot t1}{-\left(t1 + u\right)} \end{array} \]
(FPCore (u v t1) :precision binary64 (/ (* (/ v (+ t1 u)) t1) (- (+ t1 u))))
double code(double u, double v, double t1) {
	return ((v / (t1 + u)) * t1) / -(t1 + u);
}
real(8) function code(u, v, t1)
    real(8), intent (in) :: u
    real(8), intent (in) :: v
    real(8), intent (in) :: t1
    code = ((v / (t1 + u)) * t1) / -(t1 + u)
end function
public static double code(double u, double v, double t1) {
	return ((v / (t1 + u)) * t1) / -(t1 + u);
}
def code(u, v, t1):
	return ((v / (t1 + u)) * t1) / -(t1 + u)
function code(u, v, t1)
	return Float64(Float64(Float64(v / Float64(t1 + u)) * t1) / Float64(-Float64(t1 + u)))
end
function tmp = code(u, v, t1)
	tmp = ((v / (t1 + u)) * t1) / -(t1 + u);
end
code[u_, v_, t1_] := N[(N[(N[(v / N[(t1 + u), $MachinePrecision]), $MachinePrecision] * t1), $MachinePrecision] / (-N[(t1 + u), $MachinePrecision])), $MachinePrecision]
\begin{array}{l}

\\
\frac{\frac{v}{t1 + u} \cdot t1}{-\left(t1 + u\right)}
\end{array}
Derivation
  1. Initial program 72.0%

    \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
  2. Add Preprocessing
  3. Step-by-step derivation
    1. lift-/.f64N/A

      \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
    2. lift-*.f64N/A

      \[\leadsto \frac{\color{blue}{\left(-t1\right) \cdot v}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    3. *-commutativeN/A

      \[\leadsto \frac{\color{blue}{v \cdot \left(-t1\right)}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    4. lift-*.f64N/A

      \[\leadsto \frac{v \cdot \left(-t1\right)}{\color{blue}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
    5. times-fracN/A

      \[\leadsto \color{blue}{\frac{v}{t1 + u} \cdot \frac{-t1}{t1 + u}} \]
    6. lift-neg.f64N/A

      \[\leadsto \frac{v}{t1 + u} \cdot \frac{\color{blue}{\mathsf{neg}\left(t1\right)}}{t1 + u} \]
    7. distribute-frac-negN/A

      \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\left(\mathsf{neg}\left(\frac{t1}{t1 + u}\right)\right)} \]
    8. distribute-frac-neg2N/A

      \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\frac{t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
    9. associate-*r/N/A

      \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
    10. lower-/.f64N/A

      \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
    11. lower-*.f64N/A

      \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u} \cdot t1}}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
    12. lower-/.f64N/A

      \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
    13. lift-+.f64N/A

      \[\leadsto \frac{\frac{v}{\color{blue}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
    14. +-commutativeN/A

      \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
    15. lower-+.f64N/A

      \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
    16. lower-neg.f6499.0

      \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{\color{blue}{-\left(t1 + u\right)}} \]
    17. lift-+.f64N/A

      \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(t1 + u\right)}} \]
    18. +-commutativeN/A

      \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
    19. lower-+.f6499.0

      \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
  4. Applied rewrites99.0%

    \[\leadsto \color{blue}{\frac{\frac{v}{u + t1} \cdot t1}{-\left(u + t1\right)}} \]
  5. Final simplification99.0%

    \[\leadsto \frac{\frac{v}{t1 + u} \cdot t1}{-\left(t1 + u\right)} \]
  6. Add Preprocessing

Alternative 2: 95.6% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{\frac{v}{t1 + u} \cdot t1}{-u}\\ \mathbf{if}\;u \leq -1.02 \cdot 10^{+141}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;u \leq 1.05 \cdot 10^{+199}:\\ \;\;\;\;\frac{-v}{\mathsf{fma}\left(2 + \frac{u}{t1}, u, t1\right)}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (u v t1)
 :precision binary64
 (let* ((t_1 (/ (* (/ v (+ t1 u)) t1) (- u))))
   (if (<= u -1.02e+141)
     t_1
     (if (<= u 1.05e+199) (/ (- v) (fma (+ 2.0 (/ u t1)) u t1)) t_1))))
double code(double u, double v, double t1) {
	double t_1 = ((v / (t1 + u)) * t1) / -u;
	double tmp;
	if (u <= -1.02e+141) {
		tmp = t_1;
	} else if (u <= 1.05e+199) {
		tmp = -v / fma((2.0 + (u / t1)), u, t1);
	} else {
		tmp = t_1;
	}
	return tmp;
}
function code(u, v, t1)
	t_1 = Float64(Float64(Float64(v / Float64(t1 + u)) * t1) / Float64(-u))
	tmp = 0.0
	if (u <= -1.02e+141)
		tmp = t_1;
	elseif (u <= 1.05e+199)
		tmp = Float64(Float64(-v) / fma(Float64(2.0 + Float64(u / t1)), u, t1));
	else
		tmp = t_1;
	end
	return tmp
end
code[u_, v_, t1_] := Block[{t$95$1 = N[(N[(N[(v / N[(t1 + u), $MachinePrecision]), $MachinePrecision] * t1), $MachinePrecision] / (-u)), $MachinePrecision]}, If[LessEqual[u, -1.02e+141], t$95$1, If[LessEqual[u, 1.05e+199], N[((-v) / N[(N[(2.0 + N[(u / t1), $MachinePrecision]), $MachinePrecision] * u + t1), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{\frac{v}{t1 + u} \cdot t1}{-u}\\
\mathbf{if}\;u \leq -1.02 \cdot 10^{+141}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;u \leq 1.05 \cdot 10^{+199}:\\
\;\;\;\;\frac{-v}{\mathsf{fma}\left(2 + \frac{u}{t1}, u, t1\right)}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if u < -1.02e141 or 1.05e199 < u

    1. Initial program 77.7%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      2. lift-*.f64N/A

        \[\leadsto \frac{\color{blue}{\left(-t1\right) \cdot v}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
      3. *-commutativeN/A

        \[\leadsto \frac{\color{blue}{v \cdot \left(-t1\right)}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
      4. lift-*.f64N/A

        \[\leadsto \frac{v \cdot \left(-t1\right)}{\color{blue}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      5. times-fracN/A

        \[\leadsto \color{blue}{\frac{v}{t1 + u} \cdot \frac{-t1}{t1 + u}} \]
      6. lift-neg.f64N/A

        \[\leadsto \frac{v}{t1 + u} \cdot \frac{\color{blue}{\mathsf{neg}\left(t1\right)}}{t1 + u} \]
      7. distribute-frac-negN/A

        \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\left(\mathsf{neg}\left(\frac{t1}{t1 + u}\right)\right)} \]
      8. distribute-frac-neg2N/A

        \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\frac{t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
      9. associate-*r/N/A

        \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
      10. lower-/.f64N/A

        \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
      11. lower-*.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u} \cdot t1}}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      12. lower-/.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      13. lift-+.f64N/A

        \[\leadsto \frac{\frac{v}{\color{blue}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      14. +-commutativeN/A

        \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      15. lower-+.f64N/A

        \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      16. lower-neg.f6499.9

        \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{\color{blue}{-\left(t1 + u\right)}} \]
      17. lift-+.f64N/A

        \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(t1 + u\right)}} \]
      18. +-commutativeN/A

        \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
      19. lower-+.f6499.9

        \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
    4. Applied rewrites99.9%

      \[\leadsto \color{blue}{\frac{\frac{v}{u + t1} \cdot t1}{-\left(u + t1\right)}} \]
    5. Taylor expanded in u around inf

      \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{\color{blue}{-1 \cdot u}} \]
    6. Step-by-step derivation
      1. mul-1-negN/A

        \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{\color{blue}{\mathsf{neg}\left(u\right)}} \]
      2. lower-neg.f6497.0

        \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{\color{blue}{-u}} \]
    7. Applied rewrites97.0%

      \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{\color{blue}{-u}} \]

    if -1.02e141 < u < 1.05e199

    1. Initial program 70.2%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      2. lift-*.f64N/A

        \[\leadsto \frac{\color{blue}{\left(-t1\right) \cdot v}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
      3. *-commutativeN/A

        \[\leadsto \frac{\color{blue}{v \cdot \left(-t1\right)}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
      4. lift-*.f64N/A

        \[\leadsto \frac{v \cdot \left(-t1\right)}{\color{blue}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      5. times-fracN/A

        \[\leadsto \color{blue}{\frac{v}{t1 + u} \cdot \frac{-t1}{t1 + u}} \]
      6. lift-neg.f64N/A

        \[\leadsto \frac{v}{t1 + u} \cdot \frac{\color{blue}{\mathsf{neg}\left(t1\right)}}{t1 + u} \]
      7. distribute-frac-negN/A

        \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\left(\mathsf{neg}\left(\frac{t1}{t1 + u}\right)\right)} \]
      8. distribute-frac-neg2N/A

        \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\frac{t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
      9. associate-*r/N/A

        \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
      10. lower-/.f64N/A

        \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
      11. lower-*.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u} \cdot t1}}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      12. lower-/.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      13. lift-+.f64N/A

        \[\leadsto \frac{\frac{v}{\color{blue}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      14. +-commutativeN/A

        \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      15. lower-+.f64N/A

        \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      16. lower-neg.f6498.7

        \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{\color{blue}{-\left(t1 + u\right)}} \]
      17. lift-+.f64N/A

        \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(t1 + u\right)}} \]
      18. +-commutativeN/A

        \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
      19. lower-+.f6498.7

        \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
    4. Applied rewrites98.7%

      \[\leadsto \color{blue}{\frac{\frac{v}{u + t1} \cdot t1}{-\left(u + t1\right)}} \]
    5. Step-by-step derivation
      1. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{\frac{v}{u + t1} \cdot t1}{-\left(u + t1\right)}} \]
      2. lift-*.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{v}{u + t1} \cdot t1}}{-\left(u + t1\right)} \]
      3. associate-/l*N/A

        \[\leadsto \color{blue}{\frac{v}{u + t1} \cdot \frac{t1}{-\left(u + t1\right)}} \]
      4. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{v}{u + t1}} \cdot \frac{t1}{-\left(u + t1\right)} \]
      5. frac-timesN/A

        \[\leadsto \color{blue}{\frac{v \cdot t1}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)}} \]
      6. *-commutativeN/A

        \[\leadsto \frac{\color{blue}{t1 \cdot v}}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
      7. remove-double-negN/A

        \[\leadsto \frac{t1 \cdot \color{blue}{\left(\mathsf{neg}\left(\left(\mathsf{neg}\left(v\right)\right)\right)\right)}}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
      8. lift-neg.f64N/A

        \[\leadsto \frac{t1 \cdot \left(\mathsf{neg}\left(\color{blue}{\left(-v\right)}\right)\right)}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
      9. frac-timesN/A

        \[\leadsto \color{blue}{\frac{t1}{u + t1} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{-\left(u + t1\right)}} \]
      10. clear-numN/A

        \[\leadsto \color{blue}{\frac{1}{\frac{u + t1}{t1}}} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{-\left(u + t1\right)} \]
      11. lift-neg.f64N/A

        \[\leadsto \frac{1}{\frac{u + t1}{t1}} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{\color{blue}{\mathsf{neg}\left(\left(u + t1\right)\right)}} \]
      12. frac-2negN/A

        \[\leadsto \frac{1}{\frac{u + t1}{t1}} \cdot \color{blue}{\frac{-v}{u + t1}} \]
      13. frac-timesN/A

        \[\leadsto \color{blue}{\frac{1 \cdot \left(-v\right)}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
      14. *-lft-identityN/A

        \[\leadsto \frac{\color{blue}{-v}}{\frac{u + t1}{t1} \cdot \left(u + t1\right)} \]
      15. lower-/.f64N/A

        \[\leadsto \color{blue}{\frac{-v}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
      16. lower-*.f64N/A

        \[\leadsto \frac{-v}{\color{blue}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
      17. lower-/.f6496.5

        \[\leadsto \frac{-v}{\color{blue}{\frac{u + t1}{t1}} \cdot \left(u + t1\right)} \]
      18. lift-+.f64N/A

        \[\leadsto \frac{-v}{\frac{\color{blue}{u + t1}}{t1} \cdot \left(u + t1\right)} \]
      19. +-commutativeN/A

        \[\leadsto \frac{-v}{\frac{\color{blue}{t1 + u}}{t1} \cdot \left(u + t1\right)} \]
      20. lower-+.f6496.5

        \[\leadsto \frac{-v}{\frac{\color{blue}{t1 + u}}{t1} \cdot \left(u + t1\right)} \]
      21. lift-+.f64N/A

        \[\leadsto \frac{-v}{\frac{t1 + u}{t1} \cdot \color{blue}{\left(u + t1\right)}} \]
      22. +-commutativeN/A

        \[\leadsto \frac{-v}{\frac{t1 + u}{t1} \cdot \color{blue}{\left(t1 + u\right)}} \]
    6. Applied rewrites96.5%

      \[\leadsto \color{blue}{\frac{-v}{\frac{t1 + u}{t1} \cdot \left(t1 + u\right)}} \]
    7. Taylor expanded in u around 0

      \[\leadsto \frac{-v}{\color{blue}{t1 + u \cdot \left(2 + \frac{u}{t1}\right)}} \]
    8. Step-by-step derivation
      1. +-commutativeN/A

        \[\leadsto \frac{-v}{\color{blue}{u \cdot \left(2 + \frac{u}{t1}\right) + t1}} \]
      2. *-commutativeN/A

        \[\leadsto \frac{-v}{\color{blue}{\left(2 + \frac{u}{t1}\right) \cdot u} + t1} \]
      3. lower-fma.f64N/A

        \[\leadsto \frac{-v}{\color{blue}{\mathsf{fma}\left(2 + \frac{u}{t1}, u, t1\right)}} \]
      4. +-commutativeN/A

        \[\leadsto \frac{-v}{\mathsf{fma}\left(\color{blue}{\frac{u}{t1} + 2}, u, t1\right)} \]
      5. lower-+.f64N/A

        \[\leadsto \frac{-v}{\mathsf{fma}\left(\color{blue}{\frac{u}{t1} + 2}, u, t1\right)} \]
      6. lower-/.f6496.5

        \[\leadsto \frac{-v}{\mathsf{fma}\left(\color{blue}{\frac{u}{t1}} + 2, u, t1\right)} \]
    9. Applied rewrites96.5%

      \[\leadsto \frac{-v}{\color{blue}{\mathsf{fma}\left(\frac{u}{t1} + 2, u, t1\right)}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification96.6%

    \[\leadsto \begin{array}{l} \mathbf{if}\;u \leq -1.02 \cdot 10^{+141}:\\ \;\;\;\;\frac{\frac{v}{t1 + u} \cdot t1}{-u}\\ \mathbf{elif}\;u \leq 1.05 \cdot 10^{+199}:\\ \;\;\;\;\frac{-v}{\mathsf{fma}\left(2 + \frac{u}{t1}, u, t1\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{v}{t1 + u} \cdot t1}{-u}\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 86.6% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{-v}{\mathsf{fma}\left(u, 2, t1\right)}\\ \mathbf{if}\;t1 \leq -4.8 \cdot 10^{+140}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t1 \leq 4.4 \cdot 10^{+68}:\\ \;\;\;\;\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (u v t1)
 :precision binary64
 (let* ((t_1 (/ (- v) (fma u 2.0 t1))))
   (if (<= t1 -4.8e+140)
     t_1
     (if (<= t1 4.4e+68) (/ (* (- t1) v) (* (+ t1 u) (+ t1 u))) t_1))))
double code(double u, double v, double t1) {
	double t_1 = -v / fma(u, 2.0, t1);
	double tmp;
	if (t1 <= -4.8e+140) {
		tmp = t_1;
	} else if (t1 <= 4.4e+68) {
		tmp = (-t1 * v) / ((t1 + u) * (t1 + u));
	} else {
		tmp = t_1;
	}
	return tmp;
}
function code(u, v, t1)
	t_1 = Float64(Float64(-v) / fma(u, 2.0, t1))
	tmp = 0.0
	if (t1 <= -4.8e+140)
		tmp = t_1;
	elseif (t1 <= 4.4e+68)
		tmp = Float64(Float64(Float64(-t1) * v) / Float64(Float64(t1 + u) * Float64(t1 + u)));
	else
		tmp = t_1;
	end
	return tmp
end
code[u_, v_, t1_] := Block[{t$95$1 = N[((-v) / N[(u * 2.0 + t1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t1, -4.8e+140], t$95$1, If[LessEqual[t1, 4.4e+68], N[(N[((-t1) * v), $MachinePrecision] / N[(N[(t1 + u), $MachinePrecision] * N[(t1 + u), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{-v}{\mathsf{fma}\left(u, 2, t1\right)}\\
\mathbf{if}\;t1 \leq -4.8 \cdot 10^{+140}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t1 \leq 4.4 \cdot 10^{+68}:\\
\;\;\;\;\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t1 < -4.7999999999999999e140 or 4.39999999999999974e68 < t1

    1. Initial program 52.9%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      2. lift-*.f64N/A

        \[\leadsto \frac{\color{blue}{\left(-t1\right) \cdot v}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
      3. *-commutativeN/A

        \[\leadsto \frac{\color{blue}{v \cdot \left(-t1\right)}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
      4. lift-*.f64N/A

        \[\leadsto \frac{v \cdot \left(-t1\right)}{\color{blue}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      5. times-fracN/A

        \[\leadsto \color{blue}{\frac{v}{t1 + u} \cdot \frac{-t1}{t1 + u}} \]
      6. lift-neg.f64N/A

        \[\leadsto \frac{v}{t1 + u} \cdot \frac{\color{blue}{\mathsf{neg}\left(t1\right)}}{t1 + u} \]
      7. distribute-frac-negN/A

        \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\left(\mathsf{neg}\left(\frac{t1}{t1 + u}\right)\right)} \]
      8. distribute-frac-neg2N/A

        \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\frac{t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
      9. associate-*r/N/A

        \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
      10. lower-/.f64N/A

        \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
      11. lower-*.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u} \cdot t1}}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      12. lower-/.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      13. lift-+.f64N/A

        \[\leadsto \frac{\frac{v}{\color{blue}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      14. +-commutativeN/A

        \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      15. lower-+.f64N/A

        \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      16. lower-neg.f64100.0

        \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{\color{blue}{-\left(t1 + u\right)}} \]
      17. lift-+.f64N/A

        \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(t1 + u\right)}} \]
      18. +-commutativeN/A

        \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
      19. lower-+.f64100.0

        \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
    4. Applied rewrites100.0%

      \[\leadsto \color{blue}{\frac{\frac{v}{u + t1} \cdot t1}{-\left(u + t1\right)}} \]
    5. Step-by-step derivation
      1. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{\frac{v}{u + t1} \cdot t1}{-\left(u + t1\right)}} \]
      2. lift-*.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{v}{u + t1} \cdot t1}}{-\left(u + t1\right)} \]
      3. associate-/l*N/A

        \[\leadsto \color{blue}{\frac{v}{u + t1} \cdot \frac{t1}{-\left(u + t1\right)}} \]
      4. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{v}{u + t1}} \cdot \frac{t1}{-\left(u + t1\right)} \]
      5. frac-timesN/A

        \[\leadsto \color{blue}{\frac{v \cdot t1}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)}} \]
      6. *-commutativeN/A

        \[\leadsto \frac{\color{blue}{t1 \cdot v}}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
      7. remove-double-negN/A

        \[\leadsto \frac{t1 \cdot \color{blue}{\left(\mathsf{neg}\left(\left(\mathsf{neg}\left(v\right)\right)\right)\right)}}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
      8. lift-neg.f64N/A

        \[\leadsto \frac{t1 \cdot \left(\mathsf{neg}\left(\color{blue}{\left(-v\right)}\right)\right)}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
      9. frac-timesN/A

        \[\leadsto \color{blue}{\frac{t1}{u + t1} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{-\left(u + t1\right)}} \]
      10. clear-numN/A

        \[\leadsto \color{blue}{\frac{1}{\frac{u + t1}{t1}}} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{-\left(u + t1\right)} \]
      11. lift-neg.f64N/A

        \[\leadsto \frac{1}{\frac{u + t1}{t1}} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{\color{blue}{\mathsf{neg}\left(\left(u + t1\right)\right)}} \]
      12. frac-2negN/A

        \[\leadsto \frac{1}{\frac{u + t1}{t1}} \cdot \color{blue}{\frac{-v}{u + t1}} \]
      13. frac-timesN/A

        \[\leadsto \color{blue}{\frac{1 \cdot \left(-v\right)}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
      14. *-lft-identityN/A

        \[\leadsto \frac{\color{blue}{-v}}{\frac{u + t1}{t1} \cdot \left(u + t1\right)} \]
      15. lower-/.f64N/A

        \[\leadsto \color{blue}{\frac{-v}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
      16. lower-*.f64N/A

        \[\leadsto \frac{-v}{\color{blue}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
      17. lower-/.f6497.8

        \[\leadsto \frac{-v}{\color{blue}{\frac{u + t1}{t1}} \cdot \left(u + t1\right)} \]
      18. lift-+.f64N/A

        \[\leadsto \frac{-v}{\frac{\color{blue}{u + t1}}{t1} \cdot \left(u + t1\right)} \]
      19. +-commutativeN/A

        \[\leadsto \frac{-v}{\frac{\color{blue}{t1 + u}}{t1} \cdot \left(u + t1\right)} \]
      20. lower-+.f6497.8

        \[\leadsto \frac{-v}{\frac{\color{blue}{t1 + u}}{t1} \cdot \left(u + t1\right)} \]
      21. lift-+.f64N/A

        \[\leadsto \frac{-v}{\frac{t1 + u}{t1} \cdot \color{blue}{\left(u + t1\right)}} \]
      22. +-commutativeN/A

        \[\leadsto \frac{-v}{\frac{t1 + u}{t1} \cdot \color{blue}{\left(t1 + u\right)}} \]
    6. Applied rewrites97.8%

      \[\leadsto \color{blue}{\frac{-v}{\frac{t1 + u}{t1} \cdot \left(t1 + u\right)}} \]
    7. Taylor expanded in u around 0

      \[\leadsto \frac{-v}{\color{blue}{t1 + 2 \cdot u}} \]
    8. Step-by-step derivation
      1. +-commutativeN/A

        \[\leadsto \frac{-v}{\color{blue}{2 \cdot u + t1}} \]
      2. *-commutativeN/A

        \[\leadsto \frac{-v}{\color{blue}{u \cdot 2} + t1} \]
      3. lower-fma.f6495.5

        \[\leadsto \frac{-v}{\color{blue}{\mathsf{fma}\left(u, 2, t1\right)}} \]
    9. Applied rewrites95.5%

      \[\leadsto \frac{-v}{\color{blue}{\mathsf{fma}\left(u, 2, t1\right)}} \]

    if -4.7999999999999999e140 < t1 < 4.39999999999999974e68

    1. Initial program 81.9%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Add Preprocessing
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 4: 77.5% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{-v}{\mathsf{fma}\left(u, 2, t1\right)}\\ \mathbf{if}\;t1 \leq -3.4 \cdot 10^{-85}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t1 \leq 1.6 \cdot 10^{+68}:\\ \;\;\;\;\frac{-t1}{\frac{u}{v} \cdot u}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (u v t1)
 :precision binary64
 (let* ((t_1 (/ (- v) (fma u 2.0 t1))))
   (if (<= t1 -3.4e-85)
     t_1
     (if (<= t1 1.6e+68) (/ (- t1) (* (/ u v) u)) t_1))))
double code(double u, double v, double t1) {
	double t_1 = -v / fma(u, 2.0, t1);
	double tmp;
	if (t1 <= -3.4e-85) {
		tmp = t_1;
	} else if (t1 <= 1.6e+68) {
		tmp = -t1 / ((u / v) * u);
	} else {
		tmp = t_1;
	}
	return tmp;
}
function code(u, v, t1)
	t_1 = Float64(Float64(-v) / fma(u, 2.0, t1))
	tmp = 0.0
	if (t1 <= -3.4e-85)
		tmp = t_1;
	elseif (t1 <= 1.6e+68)
		tmp = Float64(Float64(-t1) / Float64(Float64(u / v) * u));
	else
		tmp = t_1;
	end
	return tmp
end
code[u_, v_, t1_] := Block[{t$95$1 = N[((-v) / N[(u * 2.0 + t1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t1, -3.4e-85], t$95$1, If[LessEqual[t1, 1.6e+68], N[((-t1) / N[(N[(u / v), $MachinePrecision] * u), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{-v}{\mathsf{fma}\left(u, 2, t1\right)}\\
\mathbf{if}\;t1 \leq -3.4 \cdot 10^{-85}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t1 \leq 1.6 \cdot 10^{+68}:\\
\;\;\;\;\frac{-t1}{\frac{u}{v} \cdot u}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t1 < -3.4e-85 or 1.59999999999999997e68 < t1

    1. Initial program 63.4%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      2. lift-*.f64N/A

        \[\leadsto \frac{\color{blue}{\left(-t1\right) \cdot v}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
      3. *-commutativeN/A

        \[\leadsto \frac{\color{blue}{v \cdot \left(-t1\right)}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
      4. lift-*.f64N/A

        \[\leadsto \frac{v \cdot \left(-t1\right)}{\color{blue}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      5. times-fracN/A

        \[\leadsto \color{blue}{\frac{v}{t1 + u} \cdot \frac{-t1}{t1 + u}} \]
      6. lift-neg.f64N/A

        \[\leadsto \frac{v}{t1 + u} \cdot \frac{\color{blue}{\mathsf{neg}\left(t1\right)}}{t1 + u} \]
      7. distribute-frac-negN/A

        \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\left(\mathsf{neg}\left(\frac{t1}{t1 + u}\right)\right)} \]
      8. distribute-frac-neg2N/A

        \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\frac{t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
      9. associate-*r/N/A

        \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
      10. lower-/.f64N/A

        \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
      11. lower-*.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u} \cdot t1}}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      12. lower-/.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      13. lift-+.f64N/A

        \[\leadsto \frac{\frac{v}{\color{blue}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      14. +-commutativeN/A

        \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      15. lower-+.f64N/A

        \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      16. lower-neg.f6499.9

        \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{\color{blue}{-\left(t1 + u\right)}} \]
      17. lift-+.f64N/A

        \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(t1 + u\right)}} \]
      18. +-commutativeN/A

        \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
      19. lower-+.f6499.9

        \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
    4. Applied rewrites99.9%

      \[\leadsto \color{blue}{\frac{\frac{v}{u + t1} \cdot t1}{-\left(u + t1\right)}} \]
    5. Step-by-step derivation
      1. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{\frac{v}{u + t1} \cdot t1}{-\left(u + t1\right)}} \]
      2. lift-*.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{v}{u + t1} \cdot t1}}{-\left(u + t1\right)} \]
      3. associate-/l*N/A

        \[\leadsto \color{blue}{\frac{v}{u + t1} \cdot \frac{t1}{-\left(u + t1\right)}} \]
      4. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{v}{u + t1}} \cdot \frac{t1}{-\left(u + t1\right)} \]
      5. frac-timesN/A

        \[\leadsto \color{blue}{\frac{v \cdot t1}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)}} \]
      6. *-commutativeN/A

        \[\leadsto \frac{\color{blue}{t1 \cdot v}}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
      7. remove-double-negN/A

        \[\leadsto \frac{t1 \cdot \color{blue}{\left(\mathsf{neg}\left(\left(\mathsf{neg}\left(v\right)\right)\right)\right)}}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
      8. lift-neg.f64N/A

        \[\leadsto \frac{t1 \cdot \left(\mathsf{neg}\left(\color{blue}{\left(-v\right)}\right)\right)}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
      9. frac-timesN/A

        \[\leadsto \color{blue}{\frac{t1}{u + t1} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{-\left(u + t1\right)}} \]
      10. clear-numN/A

        \[\leadsto \color{blue}{\frac{1}{\frac{u + t1}{t1}}} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{-\left(u + t1\right)} \]
      11. lift-neg.f64N/A

        \[\leadsto \frac{1}{\frac{u + t1}{t1}} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{\color{blue}{\mathsf{neg}\left(\left(u + t1\right)\right)}} \]
      12. frac-2negN/A

        \[\leadsto \frac{1}{\frac{u + t1}{t1}} \cdot \color{blue}{\frac{-v}{u + t1}} \]
      13. frac-timesN/A

        \[\leadsto \color{blue}{\frac{1 \cdot \left(-v\right)}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
      14. *-lft-identityN/A

        \[\leadsto \frac{\color{blue}{-v}}{\frac{u + t1}{t1} \cdot \left(u + t1\right)} \]
      15. lower-/.f64N/A

        \[\leadsto \color{blue}{\frac{-v}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
      16. lower-*.f64N/A

        \[\leadsto \frac{-v}{\color{blue}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
      17. lower-/.f6496.3

        \[\leadsto \frac{-v}{\color{blue}{\frac{u + t1}{t1}} \cdot \left(u + t1\right)} \]
      18. lift-+.f64N/A

        \[\leadsto \frac{-v}{\frac{\color{blue}{u + t1}}{t1} \cdot \left(u + t1\right)} \]
      19. +-commutativeN/A

        \[\leadsto \frac{-v}{\frac{\color{blue}{t1 + u}}{t1} \cdot \left(u + t1\right)} \]
      20. lower-+.f6496.3

        \[\leadsto \frac{-v}{\frac{\color{blue}{t1 + u}}{t1} \cdot \left(u + t1\right)} \]
      21. lift-+.f64N/A

        \[\leadsto \frac{-v}{\frac{t1 + u}{t1} \cdot \color{blue}{\left(u + t1\right)}} \]
      22. +-commutativeN/A

        \[\leadsto \frac{-v}{\frac{t1 + u}{t1} \cdot \color{blue}{\left(t1 + u\right)}} \]
    6. Applied rewrites96.3%

      \[\leadsto \color{blue}{\frac{-v}{\frac{t1 + u}{t1} \cdot \left(t1 + u\right)}} \]
    7. Taylor expanded in u around 0

      \[\leadsto \frac{-v}{\color{blue}{t1 + 2 \cdot u}} \]
    8. Step-by-step derivation
      1. +-commutativeN/A

        \[\leadsto \frac{-v}{\color{blue}{2 \cdot u + t1}} \]
      2. *-commutativeN/A

        \[\leadsto \frac{-v}{\color{blue}{u \cdot 2} + t1} \]
      3. lower-fma.f6487.2

        \[\leadsto \frac{-v}{\color{blue}{\mathsf{fma}\left(u, 2, t1\right)}} \]
    9. Applied rewrites87.2%

      \[\leadsto \frac{-v}{\color{blue}{\mathsf{fma}\left(u, 2, t1\right)}} \]

    if -3.4e-85 < t1 < 1.59999999999999997e68

    1. Initial program 80.6%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Add Preprocessing
    3. Taylor expanded in u around inf

      \[\leadsto \color{blue}{-1 \cdot \frac{t1 \cdot v}{{u}^{2}}} \]
    4. Step-by-step derivation
      1. mul-1-negN/A

        \[\leadsto \color{blue}{\mathsf{neg}\left(\frac{t1 \cdot v}{{u}^{2}}\right)} \]
      2. distribute-neg-frac2N/A

        \[\leadsto \color{blue}{\frac{t1 \cdot v}{\mathsf{neg}\left({u}^{2}\right)}} \]
      3. mul-1-negN/A

        \[\leadsto \frac{t1 \cdot v}{\color{blue}{-1 \cdot {u}^{2}}} \]
      4. unpow2N/A

        \[\leadsto \frac{t1 \cdot v}{-1 \cdot \color{blue}{\left(u \cdot u\right)}} \]
      5. associate-*r*N/A

        \[\leadsto \frac{t1 \cdot v}{\color{blue}{\left(-1 \cdot u\right) \cdot u}} \]
      6. times-fracN/A

        \[\leadsto \color{blue}{\frac{t1}{-1 \cdot u} \cdot \frac{v}{u}} \]
      7. neg-mul-1N/A

        \[\leadsto \frac{t1}{\color{blue}{\mathsf{neg}\left(u\right)}} \cdot \frac{v}{u} \]
      8. lower-*.f64N/A

        \[\leadsto \color{blue}{\frac{t1}{\mathsf{neg}\left(u\right)} \cdot \frac{v}{u}} \]
      9. lower-/.f64N/A

        \[\leadsto \color{blue}{\frac{t1}{\mathsf{neg}\left(u\right)}} \cdot \frac{v}{u} \]
      10. lower-neg.f64N/A

        \[\leadsto \frac{t1}{\color{blue}{-u}} \cdot \frac{v}{u} \]
      11. lower-/.f6481.2

        \[\leadsto \frac{t1}{-u} \cdot \color{blue}{\frac{v}{u}} \]
    5. Applied rewrites81.2%

      \[\leadsto \color{blue}{\frac{t1}{-u} \cdot \frac{v}{u}} \]
    6. Step-by-step derivation
      1. Applied rewrites81.4%

        \[\leadsto \frac{-t1}{\color{blue}{\frac{u}{v} \cdot u}} \]
    7. Recombined 2 regimes into one program.
    8. Add Preprocessing

    Alternative 5: 78.2% accurate, 0.7× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{-v}{\mathsf{fma}\left(u, 2, t1\right)}\\ \mathbf{if}\;t1 \leq -3.4 \cdot 10^{-85}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t1 \leq 1.6 \cdot 10^{+68}:\\ \;\;\;\;\frac{-v}{u} \cdot \frac{t1}{u}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
    (FPCore (u v t1)
     :precision binary64
     (let* ((t_1 (/ (- v) (fma u 2.0 t1))))
       (if (<= t1 -3.4e-85)
         t_1
         (if (<= t1 1.6e+68) (* (/ (- v) u) (/ t1 u)) t_1))))
    double code(double u, double v, double t1) {
    	double t_1 = -v / fma(u, 2.0, t1);
    	double tmp;
    	if (t1 <= -3.4e-85) {
    		tmp = t_1;
    	} else if (t1 <= 1.6e+68) {
    		tmp = (-v / u) * (t1 / u);
    	} else {
    		tmp = t_1;
    	}
    	return tmp;
    }
    
    function code(u, v, t1)
    	t_1 = Float64(Float64(-v) / fma(u, 2.0, t1))
    	tmp = 0.0
    	if (t1 <= -3.4e-85)
    		tmp = t_1;
    	elseif (t1 <= 1.6e+68)
    		tmp = Float64(Float64(Float64(-v) / u) * Float64(t1 / u));
    	else
    		tmp = t_1;
    	end
    	return tmp
    end
    
    code[u_, v_, t1_] := Block[{t$95$1 = N[((-v) / N[(u * 2.0 + t1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t1, -3.4e-85], t$95$1, If[LessEqual[t1, 1.6e+68], N[(N[((-v) / u), $MachinePrecision] * N[(t1 / u), $MachinePrecision]), $MachinePrecision], t$95$1]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_1 := \frac{-v}{\mathsf{fma}\left(u, 2, t1\right)}\\
    \mathbf{if}\;t1 \leq -3.4 \cdot 10^{-85}:\\
    \;\;\;\;t\_1\\
    
    \mathbf{elif}\;t1 \leq 1.6 \cdot 10^{+68}:\\
    \;\;\;\;\frac{-v}{u} \cdot \frac{t1}{u}\\
    
    \mathbf{else}:\\
    \;\;\;\;t\_1\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if t1 < -3.4e-85 or 1.59999999999999997e68 < t1

      1. Initial program 63.4%

        \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. lift-/.f64N/A

          \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
        2. lift-*.f64N/A

          \[\leadsto \frac{\color{blue}{\left(-t1\right) \cdot v}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
        3. *-commutativeN/A

          \[\leadsto \frac{\color{blue}{v \cdot \left(-t1\right)}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
        4. lift-*.f64N/A

          \[\leadsto \frac{v \cdot \left(-t1\right)}{\color{blue}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
        5. times-fracN/A

          \[\leadsto \color{blue}{\frac{v}{t1 + u} \cdot \frac{-t1}{t1 + u}} \]
        6. lift-neg.f64N/A

          \[\leadsto \frac{v}{t1 + u} \cdot \frac{\color{blue}{\mathsf{neg}\left(t1\right)}}{t1 + u} \]
        7. distribute-frac-negN/A

          \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\left(\mathsf{neg}\left(\frac{t1}{t1 + u}\right)\right)} \]
        8. distribute-frac-neg2N/A

          \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\frac{t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
        9. associate-*r/N/A

          \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
        10. lower-/.f64N/A

          \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
        11. lower-*.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u} \cdot t1}}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        12. lower-/.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        13. lift-+.f64N/A

          \[\leadsto \frac{\frac{v}{\color{blue}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        14. +-commutativeN/A

          \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        15. lower-+.f64N/A

          \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        16. lower-neg.f6499.9

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{\color{blue}{-\left(t1 + u\right)}} \]
        17. lift-+.f64N/A

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(t1 + u\right)}} \]
        18. +-commutativeN/A

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
        19. lower-+.f6499.9

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
      4. Applied rewrites99.9%

        \[\leadsto \color{blue}{\frac{\frac{v}{u + t1} \cdot t1}{-\left(u + t1\right)}} \]
      5. Step-by-step derivation
        1. lift-/.f64N/A

          \[\leadsto \color{blue}{\frac{\frac{v}{u + t1} \cdot t1}{-\left(u + t1\right)}} \]
        2. lift-*.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{v}{u + t1} \cdot t1}}{-\left(u + t1\right)} \]
        3. associate-/l*N/A

          \[\leadsto \color{blue}{\frac{v}{u + t1} \cdot \frac{t1}{-\left(u + t1\right)}} \]
        4. lift-/.f64N/A

          \[\leadsto \color{blue}{\frac{v}{u + t1}} \cdot \frac{t1}{-\left(u + t1\right)} \]
        5. frac-timesN/A

          \[\leadsto \color{blue}{\frac{v \cdot t1}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)}} \]
        6. *-commutativeN/A

          \[\leadsto \frac{\color{blue}{t1 \cdot v}}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
        7. remove-double-negN/A

          \[\leadsto \frac{t1 \cdot \color{blue}{\left(\mathsf{neg}\left(\left(\mathsf{neg}\left(v\right)\right)\right)\right)}}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
        8. lift-neg.f64N/A

          \[\leadsto \frac{t1 \cdot \left(\mathsf{neg}\left(\color{blue}{\left(-v\right)}\right)\right)}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
        9. frac-timesN/A

          \[\leadsto \color{blue}{\frac{t1}{u + t1} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{-\left(u + t1\right)}} \]
        10. clear-numN/A

          \[\leadsto \color{blue}{\frac{1}{\frac{u + t1}{t1}}} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{-\left(u + t1\right)} \]
        11. lift-neg.f64N/A

          \[\leadsto \frac{1}{\frac{u + t1}{t1}} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{\color{blue}{\mathsf{neg}\left(\left(u + t1\right)\right)}} \]
        12. frac-2negN/A

          \[\leadsto \frac{1}{\frac{u + t1}{t1}} \cdot \color{blue}{\frac{-v}{u + t1}} \]
        13. frac-timesN/A

          \[\leadsto \color{blue}{\frac{1 \cdot \left(-v\right)}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
        14. *-lft-identityN/A

          \[\leadsto \frac{\color{blue}{-v}}{\frac{u + t1}{t1} \cdot \left(u + t1\right)} \]
        15. lower-/.f64N/A

          \[\leadsto \color{blue}{\frac{-v}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
        16. lower-*.f64N/A

          \[\leadsto \frac{-v}{\color{blue}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
        17. lower-/.f6496.3

          \[\leadsto \frac{-v}{\color{blue}{\frac{u + t1}{t1}} \cdot \left(u + t1\right)} \]
        18. lift-+.f64N/A

          \[\leadsto \frac{-v}{\frac{\color{blue}{u + t1}}{t1} \cdot \left(u + t1\right)} \]
        19. +-commutativeN/A

          \[\leadsto \frac{-v}{\frac{\color{blue}{t1 + u}}{t1} \cdot \left(u + t1\right)} \]
        20. lower-+.f6496.3

          \[\leadsto \frac{-v}{\frac{\color{blue}{t1 + u}}{t1} \cdot \left(u + t1\right)} \]
        21. lift-+.f64N/A

          \[\leadsto \frac{-v}{\frac{t1 + u}{t1} \cdot \color{blue}{\left(u + t1\right)}} \]
        22. +-commutativeN/A

          \[\leadsto \frac{-v}{\frac{t1 + u}{t1} \cdot \color{blue}{\left(t1 + u\right)}} \]
      6. Applied rewrites96.3%

        \[\leadsto \color{blue}{\frac{-v}{\frac{t1 + u}{t1} \cdot \left(t1 + u\right)}} \]
      7. Taylor expanded in u around 0

        \[\leadsto \frac{-v}{\color{blue}{t1 + 2 \cdot u}} \]
      8. Step-by-step derivation
        1. +-commutativeN/A

          \[\leadsto \frac{-v}{\color{blue}{2 \cdot u + t1}} \]
        2. *-commutativeN/A

          \[\leadsto \frac{-v}{\color{blue}{u \cdot 2} + t1} \]
        3. lower-fma.f6487.2

          \[\leadsto \frac{-v}{\color{blue}{\mathsf{fma}\left(u, 2, t1\right)}} \]
      9. Applied rewrites87.2%

        \[\leadsto \frac{-v}{\color{blue}{\mathsf{fma}\left(u, 2, t1\right)}} \]

      if -3.4e-85 < t1 < 1.59999999999999997e68

      1. Initial program 80.6%

        \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
      2. Add Preprocessing
      3. Taylor expanded in u around inf

        \[\leadsto \color{blue}{-1 \cdot \frac{t1 \cdot v}{{u}^{2}}} \]
      4. Step-by-step derivation
        1. mul-1-negN/A

          \[\leadsto \color{blue}{\mathsf{neg}\left(\frac{t1 \cdot v}{{u}^{2}}\right)} \]
        2. distribute-neg-frac2N/A

          \[\leadsto \color{blue}{\frac{t1 \cdot v}{\mathsf{neg}\left({u}^{2}\right)}} \]
        3. mul-1-negN/A

          \[\leadsto \frac{t1 \cdot v}{\color{blue}{-1 \cdot {u}^{2}}} \]
        4. unpow2N/A

          \[\leadsto \frac{t1 \cdot v}{-1 \cdot \color{blue}{\left(u \cdot u\right)}} \]
        5. associate-*r*N/A

          \[\leadsto \frac{t1 \cdot v}{\color{blue}{\left(-1 \cdot u\right) \cdot u}} \]
        6. times-fracN/A

          \[\leadsto \color{blue}{\frac{t1}{-1 \cdot u} \cdot \frac{v}{u}} \]
        7. neg-mul-1N/A

          \[\leadsto \frac{t1}{\color{blue}{\mathsf{neg}\left(u\right)}} \cdot \frac{v}{u} \]
        8. lower-*.f64N/A

          \[\leadsto \color{blue}{\frac{t1}{\mathsf{neg}\left(u\right)} \cdot \frac{v}{u}} \]
        9. lower-/.f64N/A

          \[\leadsto \color{blue}{\frac{t1}{\mathsf{neg}\left(u\right)}} \cdot \frac{v}{u} \]
        10. lower-neg.f64N/A

          \[\leadsto \frac{t1}{\color{blue}{-u}} \cdot \frac{v}{u} \]
        11. lower-/.f6481.2

          \[\leadsto \frac{t1}{-u} \cdot \color{blue}{\frac{v}{u}} \]
      5. Applied rewrites81.2%

        \[\leadsto \color{blue}{\frac{t1}{-u} \cdot \frac{v}{u}} \]
    3. Recombined 2 regimes into one program.
    4. Final simplification84.2%

      \[\leadsto \begin{array}{l} \mathbf{if}\;t1 \leq -3.4 \cdot 10^{-85}:\\ \;\;\;\;\frac{-v}{\mathsf{fma}\left(u, 2, t1\right)}\\ \mathbf{elif}\;t1 \leq 1.6 \cdot 10^{+68}:\\ \;\;\;\;\frac{-v}{u} \cdot \frac{t1}{u}\\ \mathbf{else}:\\ \;\;\;\;\frac{-v}{\mathsf{fma}\left(u, 2, t1\right)}\\ \end{array} \]
    5. Add Preprocessing

    Alternative 6: 75.6% accurate, 0.8× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{-v}{\mathsf{fma}\left(u, 2, t1\right)}\\ \mathbf{if}\;t1 \leq -6.5 \cdot 10^{-86}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t1 \leq 1.6 \cdot 10^{+68}:\\ \;\;\;\;\frac{-v}{u \cdot u} \cdot t1\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
    (FPCore (u v t1)
     :precision binary64
     (let* ((t_1 (/ (- v) (fma u 2.0 t1))))
       (if (<= t1 -6.5e-86)
         t_1
         (if (<= t1 1.6e+68) (* (/ (- v) (* u u)) t1) t_1))))
    double code(double u, double v, double t1) {
    	double t_1 = -v / fma(u, 2.0, t1);
    	double tmp;
    	if (t1 <= -6.5e-86) {
    		tmp = t_1;
    	} else if (t1 <= 1.6e+68) {
    		tmp = (-v / (u * u)) * t1;
    	} else {
    		tmp = t_1;
    	}
    	return tmp;
    }
    
    function code(u, v, t1)
    	t_1 = Float64(Float64(-v) / fma(u, 2.0, t1))
    	tmp = 0.0
    	if (t1 <= -6.5e-86)
    		tmp = t_1;
    	elseif (t1 <= 1.6e+68)
    		tmp = Float64(Float64(Float64(-v) / Float64(u * u)) * t1);
    	else
    		tmp = t_1;
    	end
    	return tmp
    end
    
    code[u_, v_, t1_] := Block[{t$95$1 = N[((-v) / N[(u * 2.0 + t1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t1, -6.5e-86], t$95$1, If[LessEqual[t1, 1.6e+68], N[(N[((-v) / N[(u * u), $MachinePrecision]), $MachinePrecision] * t1), $MachinePrecision], t$95$1]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_1 := \frac{-v}{\mathsf{fma}\left(u, 2, t1\right)}\\
    \mathbf{if}\;t1 \leq -6.5 \cdot 10^{-86}:\\
    \;\;\;\;t\_1\\
    
    \mathbf{elif}\;t1 \leq 1.6 \cdot 10^{+68}:\\
    \;\;\;\;\frac{-v}{u \cdot u} \cdot t1\\
    
    \mathbf{else}:\\
    \;\;\;\;t\_1\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if t1 < -6.50000000000000028e-86 or 1.59999999999999997e68 < t1

      1. Initial program 63.4%

        \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. lift-/.f64N/A

          \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
        2. lift-*.f64N/A

          \[\leadsto \frac{\color{blue}{\left(-t1\right) \cdot v}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
        3. *-commutativeN/A

          \[\leadsto \frac{\color{blue}{v \cdot \left(-t1\right)}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
        4. lift-*.f64N/A

          \[\leadsto \frac{v \cdot \left(-t1\right)}{\color{blue}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
        5. times-fracN/A

          \[\leadsto \color{blue}{\frac{v}{t1 + u} \cdot \frac{-t1}{t1 + u}} \]
        6. lift-neg.f64N/A

          \[\leadsto \frac{v}{t1 + u} \cdot \frac{\color{blue}{\mathsf{neg}\left(t1\right)}}{t1 + u} \]
        7. distribute-frac-negN/A

          \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\left(\mathsf{neg}\left(\frac{t1}{t1 + u}\right)\right)} \]
        8. distribute-frac-neg2N/A

          \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\frac{t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
        9. associate-*r/N/A

          \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
        10. lower-/.f64N/A

          \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
        11. lower-*.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u} \cdot t1}}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        12. lower-/.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        13. lift-+.f64N/A

          \[\leadsto \frac{\frac{v}{\color{blue}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        14. +-commutativeN/A

          \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        15. lower-+.f64N/A

          \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        16. lower-neg.f6499.9

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{\color{blue}{-\left(t1 + u\right)}} \]
        17. lift-+.f64N/A

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(t1 + u\right)}} \]
        18. +-commutativeN/A

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
        19. lower-+.f6499.9

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
      4. Applied rewrites99.9%

        \[\leadsto \color{blue}{\frac{\frac{v}{u + t1} \cdot t1}{-\left(u + t1\right)}} \]
      5. Step-by-step derivation
        1. lift-/.f64N/A

          \[\leadsto \color{blue}{\frac{\frac{v}{u + t1} \cdot t1}{-\left(u + t1\right)}} \]
        2. lift-*.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{v}{u + t1} \cdot t1}}{-\left(u + t1\right)} \]
        3. associate-/l*N/A

          \[\leadsto \color{blue}{\frac{v}{u + t1} \cdot \frac{t1}{-\left(u + t1\right)}} \]
        4. lift-/.f64N/A

          \[\leadsto \color{blue}{\frac{v}{u + t1}} \cdot \frac{t1}{-\left(u + t1\right)} \]
        5. frac-timesN/A

          \[\leadsto \color{blue}{\frac{v \cdot t1}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)}} \]
        6. *-commutativeN/A

          \[\leadsto \frac{\color{blue}{t1 \cdot v}}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
        7. remove-double-negN/A

          \[\leadsto \frac{t1 \cdot \color{blue}{\left(\mathsf{neg}\left(\left(\mathsf{neg}\left(v\right)\right)\right)\right)}}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
        8. lift-neg.f64N/A

          \[\leadsto \frac{t1 \cdot \left(\mathsf{neg}\left(\color{blue}{\left(-v\right)}\right)\right)}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
        9. frac-timesN/A

          \[\leadsto \color{blue}{\frac{t1}{u + t1} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{-\left(u + t1\right)}} \]
        10. clear-numN/A

          \[\leadsto \color{blue}{\frac{1}{\frac{u + t1}{t1}}} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{-\left(u + t1\right)} \]
        11. lift-neg.f64N/A

          \[\leadsto \frac{1}{\frac{u + t1}{t1}} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{\color{blue}{\mathsf{neg}\left(\left(u + t1\right)\right)}} \]
        12. frac-2negN/A

          \[\leadsto \frac{1}{\frac{u + t1}{t1}} \cdot \color{blue}{\frac{-v}{u + t1}} \]
        13. frac-timesN/A

          \[\leadsto \color{blue}{\frac{1 \cdot \left(-v\right)}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
        14. *-lft-identityN/A

          \[\leadsto \frac{\color{blue}{-v}}{\frac{u + t1}{t1} \cdot \left(u + t1\right)} \]
        15. lower-/.f64N/A

          \[\leadsto \color{blue}{\frac{-v}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
        16. lower-*.f64N/A

          \[\leadsto \frac{-v}{\color{blue}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
        17. lower-/.f6496.3

          \[\leadsto \frac{-v}{\color{blue}{\frac{u + t1}{t1}} \cdot \left(u + t1\right)} \]
        18. lift-+.f64N/A

          \[\leadsto \frac{-v}{\frac{\color{blue}{u + t1}}{t1} \cdot \left(u + t1\right)} \]
        19. +-commutativeN/A

          \[\leadsto \frac{-v}{\frac{\color{blue}{t1 + u}}{t1} \cdot \left(u + t1\right)} \]
        20. lower-+.f6496.3

          \[\leadsto \frac{-v}{\frac{\color{blue}{t1 + u}}{t1} \cdot \left(u + t1\right)} \]
        21. lift-+.f64N/A

          \[\leadsto \frac{-v}{\frac{t1 + u}{t1} \cdot \color{blue}{\left(u + t1\right)}} \]
        22. +-commutativeN/A

          \[\leadsto \frac{-v}{\frac{t1 + u}{t1} \cdot \color{blue}{\left(t1 + u\right)}} \]
      6. Applied rewrites96.3%

        \[\leadsto \color{blue}{\frac{-v}{\frac{t1 + u}{t1} \cdot \left(t1 + u\right)}} \]
      7. Taylor expanded in u around 0

        \[\leadsto \frac{-v}{\color{blue}{t1 + 2 \cdot u}} \]
      8. Step-by-step derivation
        1. +-commutativeN/A

          \[\leadsto \frac{-v}{\color{blue}{2 \cdot u + t1}} \]
        2. *-commutativeN/A

          \[\leadsto \frac{-v}{\color{blue}{u \cdot 2} + t1} \]
        3. lower-fma.f6487.2

          \[\leadsto \frac{-v}{\color{blue}{\mathsf{fma}\left(u, 2, t1\right)}} \]
      9. Applied rewrites87.2%

        \[\leadsto \frac{-v}{\color{blue}{\mathsf{fma}\left(u, 2, t1\right)}} \]

      if -6.50000000000000028e-86 < t1 < 1.59999999999999997e68

      1. Initial program 80.6%

        \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
      2. Add Preprocessing
      3. Taylor expanded in u around inf

        \[\leadsto \frac{\left(-t1\right) \cdot v}{\color{blue}{{u}^{2}}} \]
      4. Step-by-step derivation
        1. unpow2N/A

          \[\leadsto \frac{\left(-t1\right) \cdot v}{\color{blue}{u \cdot u}} \]
        2. lower-*.f6471.7

          \[\leadsto \frac{\left(-t1\right) \cdot v}{\color{blue}{u \cdot u}} \]
      5. Applied rewrites71.7%

        \[\leadsto \frac{\left(-t1\right) \cdot v}{\color{blue}{u \cdot u}} \]
      6. Step-by-step derivation
        1. lift-/.f64N/A

          \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot v}{u \cdot u}} \]
        2. lift-*.f64N/A

          \[\leadsto \frac{\color{blue}{\left(-t1\right) \cdot v}}{u \cdot u} \]
        3. associate-/l*N/A

          \[\leadsto \color{blue}{\left(-t1\right) \cdot \frac{v}{u \cdot u}} \]
        4. *-commutativeN/A

          \[\leadsto \color{blue}{\frac{v}{u \cdot u} \cdot \left(-t1\right)} \]
        5. lower-*.f64N/A

          \[\leadsto \color{blue}{\frac{v}{u \cdot u} \cdot \left(-t1\right)} \]
        6. lower-/.f6475.6

          \[\leadsto \color{blue}{\frac{v}{u \cdot u}} \cdot \left(-t1\right) \]
      7. Applied rewrites75.6%

        \[\leadsto \color{blue}{\frac{v}{u \cdot u} \cdot \left(-t1\right)} \]
    3. Recombined 2 regimes into one program.
    4. Final simplification81.4%

      \[\leadsto \begin{array}{l} \mathbf{if}\;t1 \leq -6.5 \cdot 10^{-86}:\\ \;\;\;\;\frac{-v}{\mathsf{fma}\left(u, 2, t1\right)}\\ \mathbf{elif}\;t1 \leq 1.6 \cdot 10^{+68}:\\ \;\;\;\;\frac{-v}{u \cdot u} \cdot t1\\ \mathbf{else}:\\ \;\;\;\;\frac{-v}{\mathsf{fma}\left(u, 2, t1\right)}\\ \end{array} \]
    5. Add Preprocessing

    Alternative 7: 75.4% accurate, 0.8× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{-v}{\mathsf{fma}\left(u, 2, t1\right)}\\ \mathbf{if}\;t1 \leq -3.4 \cdot 10^{-85}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t1 \leq 1.6 \cdot 10^{+68}:\\ \;\;\;\;\frac{-t1}{u \cdot u} \cdot v\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
    (FPCore (u v t1)
     :precision binary64
     (let* ((t_1 (/ (- v) (fma u 2.0 t1))))
       (if (<= t1 -3.4e-85)
         t_1
         (if (<= t1 1.6e+68) (* (/ (- t1) (* u u)) v) t_1))))
    double code(double u, double v, double t1) {
    	double t_1 = -v / fma(u, 2.0, t1);
    	double tmp;
    	if (t1 <= -3.4e-85) {
    		tmp = t_1;
    	} else if (t1 <= 1.6e+68) {
    		tmp = (-t1 / (u * u)) * v;
    	} else {
    		tmp = t_1;
    	}
    	return tmp;
    }
    
    function code(u, v, t1)
    	t_1 = Float64(Float64(-v) / fma(u, 2.0, t1))
    	tmp = 0.0
    	if (t1 <= -3.4e-85)
    		tmp = t_1;
    	elseif (t1 <= 1.6e+68)
    		tmp = Float64(Float64(Float64(-t1) / Float64(u * u)) * v);
    	else
    		tmp = t_1;
    	end
    	return tmp
    end
    
    code[u_, v_, t1_] := Block[{t$95$1 = N[((-v) / N[(u * 2.0 + t1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t1, -3.4e-85], t$95$1, If[LessEqual[t1, 1.6e+68], N[(N[((-t1) / N[(u * u), $MachinePrecision]), $MachinePrecision] * v), $MachinePrecision], t$95$1]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_1 := \frac{-v}{\mathsf{fma}\left(u, 2, t1\right)}\\
    \mathbf{if}\;t1 \leq -3.4 \cdot 10^{-85}:\\
    \;\;\;\;t\_1\\
    
    \mathbf{elif}\;t1 \leq 1.6 \cdot 10^{+68}:\\
    \;\;\;\;\frac{-t1}{u \cdot u} \cdot v\\
    
    \mathbf{else}:\\
    \;\;\;\;t\_1\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if t1 < -3.4e-85 or 1.59999999999999997e68 < t1

      1. Initial program 63.4%

        \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. lift-/.f64N/A

          \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
        2. lift-*.f64N/A

          \[\leadsto \frac{\color{blue}{\left(-t1\right) \cdot v}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
        3. *-commutativeN/A

          \[\leadsto \frac{\color{blue}{v \cdot \left(-t1\right)}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
        4. lift-*.f64N/A

          \[\leadsto \frac{v \cdot \left(-t1\right)}{\color{blue}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
        5. times-fracN/A

          \[\leadsto \color{blue}{\frac{v}{t1 + u} \cdot \frac{-t1}{t1 + u}} \]
        6. lift-neg.f64N/A

          \[\leadsto \frac{v}{t1 + u} \cdot \frac{\color{blue}{\mathsf{neg}\left(t1\right)}}{t1 + u} \]
        7. distribute-frac-negN/A

          \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\left(\mathsf{neg}\left(\frac{t1}{t1 + u}\right)\right)} \]
        8. distribute-frac-neg2N/A

          \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\frac{t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
        9. associate-*r/N/A

          \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
        10. lower-/.f64N/A

          \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
        11. lower-*.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u} \cdot t1}}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        12. lower-/.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        13. lift-+.f64N/A

          \[\leadsto \frac{\frac{v}{\color{blue}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        14. +-commutativeN/A

          \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        15. lower-+.f64N/A

          \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        16. lower-neg.f6499.9

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{\color{blue}{-\left(t1 + u\right)}} \]
        17. lift-+.f64N/A

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(t1 + u\right)}} \]
        18. +-commutativeN/A

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
        19. lower-+.f6499.9

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
      4. Applied rewrites99.9%

        \[\leadsto \color{blue}{\frac{\frac{v}{u + t1} \cdot t1}{-\left(u + t1\right)}} \]
      5. Step-by-step derivation
        1. lift-/.f64N/A

          \[\leadsto \color{blue}{\frac{\frac{v}{u + t1} \cdot t1}{-\left(u + t1\right)}} \]
        2. lift-*.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{v}{u + t1} \cdot t1}}{-\left(u + t1\right)} \]
        3. associate-/l*N/A

          \[\leadsto \color{blue}{\frac{v}{u + t1} \cdot \frac{t1}{-\left(u + t1\right)}} \]
        4. lift-/.f64N/A

          \[\leadsto \color{blue}{\frac{v}{u + t1}} \cdot \frac{t1}{-\left(u + t1\right)} \]
        5. frac-timesN/A

          \[\leadsto \color{blue}{\frac{v \cdot t1}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)}} \]
        6. *-commutativeN/A

          \[\leadsto \frac{\color{blue}{t1 \cdot v}}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
        7. remove-double-negN/A

          \[\leadsto \frac{t1 \cdot \color{blue}{\left(\mathsf{neg}\left(\left(\mathsf{neg}\left(v\right)\right)\right)\right)}}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
        8. lift-neg.f64N/A

          \[\leadsto \frac{t1 \cdot \left(\mathsf{neg}\left(\color{blue}{\left(-v\right)}\right)\right)}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
        9. frac-timesN/A

          \[\leadsto \color{blue}{\frac{t1}{u + t1} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{-\left(u + t1\right)}} \]
        10. clear-numN/A

          \[\leadsto \color{blue}{\frac{1}{\frac{u + t1}{t1}}} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{-\left(u + t1\right)} \]
        11. lift-neg.f64N/A

          \[\leadsto \frac{1}{\frac{u + t1}{t1}} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{\color{blue}{\mathsf{neg}\left(\left(u + t1\right)\right)}} \]
        12. frac-2negN/A

          \[\leadsto \frac{1}{\frac{u + t1}{t1}} \cdot \color{blue}{\frac{-v}{u + t1}} \]
        13. frac-timesN/A

          \[\leadsto \color{blue}{\frac{1 \cdot \left(-v\right)}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
        14. *-lft-identityN/A

          \[\leadsto \frac{\color{blue}{-v}}{\frac{u + t1}{t1} \cdot \left(u + t1\right)} \]
        15. lower-/.f64N/A

          \[\leadsto \color{blue}{\frac{-v}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
        16. lower-*.f64N/A

          \[\leadsto \frac{-v}{\color{blue}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
        17. lower-/.f6496.3

          \[\leadsto \frac{-v}{\color{blue}{\frac{u + t1}{t1}} \cdot \left(u + t1\right)} \]
        18. lift-+.f64N/A

          \[\leadsto \frac{-v}{\frac{\color{blue}{u + t1}}{t1} \cdot \left(u + t1\right)} \]
        19. +-commutativeN/A

          \[\leadsto \frac{-v}{\frac{\color{blue}{t1 + u}}{t1} \cdot \left(u + t1\right)} \]
        20. lower-+.f6496.3

          \[\leadsto \frac{-v}{\frac{\color{blue}{t1 + u}}{t1} \cdot \left(u + t1\right)} \]
        21. lift-+.f64N/A

          \[\leadsto \frac{-v}{\frac{t1 + u}{t1} \cdot \color{blue}{\left(u + t1\right)}} \]
        22. +-commutativeN/A

          \[\leadsto \frac{-v}{\frac{t1 + u}{t1} \cdot \color{blue}{\left(t1 + u\right)}} \]
      6. Applied rewrites96.3%

        \[\leadsto \color{blue}{\frac{-v}{\frac{t1 + u}{t1} \cdot \left(t1 + u\right)}} \]
      7. Taylor expanded in u around 0

        \[\leadsto \frac{-v}{\color{blue}{t1 + 2 \cdot u}} \]
      8. Step-by-step derivation
        1. +-commutativeN/A

          \[\leadsto \frac{-v}{\color{blue}{2 \cdot u + t1}} \]
        2. *-commutativeN/A

          \[\leadsto \frac{-v}{\color{blue}{u \cdot 2} + t1} \]
        3. lower-fma.f6487.2

          \[\leadsto \frac{-v}{\color{blue}{\mathsf{fma}\left(u, 2, t1\right)}} \]
      9. Applied rewrites87.2%

        \[\leadsto \frac{-v}{\color{blue}{\mathsf{fma}\left(u, 2, t1\right)}} \]

      if -3.4e-85 < t1 < 1.59999999999999997e68

      1. Initial program 80.6%

        \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
      2. Add Preprocessing
      3. Taylor expanded in u around inf

        \[\leadsto \frac{\left(-t1\right) \cdot v}{\color{blue}{{u}^{2}}} \]
      4. Step-by-step derivation
        1. unpow2N/A

          \[\leadsto \frac{\left(-t1\right) \cdot v}{\color{blue}{u \cdot u}} \]
        2. lower-*.f6471.7

          \[\leadsto \frac{\left(-t1\right) \cdot v}{\color{blue}{u \cdot u}} \]
      5. Applied rewrites71.7%

        \[\leadsto \frac{\left(-t1\right) \cdot v}{\color{blue}{u \cdot u}} \]
      6. Step-by-step derivation
        1. lift-/.f64N/A

          \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot v}{u \cdot u}} \]
        2. lift-*.f64N/A

          \[\leadsto \frac{\color{blue}{\left(-t1\right) \cdot v}}{u \cdot u} \]
        3. *-commutativeN/A

          \[\leadsto \frac{\color{blue}{v \cdot \left(-t1\right)}}{u \cdot u} \]
        4. associate-/l*N/A

          \[\leadsto \color{blue}{v \cdot \frac{-t1}{u \cdot u}} \]
        5. lower-*.f64N/A

          \[\leadsto \color{blue}{v \cdot \frac{-t1}{u \cdot u}} \]
        6. lower-/.f6471.8

          \[\leadsto v \cdot \color{blue}{\frac{-t1}{u \cdot u}} \]
      7. Applied rewrites71.8%

        \[\leadsto \color{blue}{v \cdot \frac{-t1}{u \cdot u}} \]
    3. Recombined 2 regimes into one program.
    4. Final simplification79.5%

      \[\leadsto \begin{array}{l} \mathbf{if}\;t1 \leq -3.4 \cdot 10^{-85}:\\ \;\;\;\;\frac{-v}{\mathsf{fma}\left(u, 2, t1\right)}\\ \mathbf{elif}\;t1 \leq 1.6 \cdot 10^{+68}:\\ \;\;\;\;\frac{-t1}{u \cdot u} \cdot v\\ \mathbf{else}:\\ \;\;\;\;\frac{-v}{\mathsf{fma}\left(u, 2, t1\right)}\\ \end{array} \]
    5. Add Preprocessing

    Alternative 8: 97.9% accurate, 0.8× speedup?

    \[\begin{array}{l} \\ \frac{t1}{t1 + u} \cdot \frac{-v}{t1 + u} \end{array} \]
    (FPCore (u v t1) :precision binary64 (* (/ t1 (+ t1 u)) (/ (- v) (+ t1 u))))
    double code(double u, double v, double t1) {
    	return (t1 / (t1 + u)) * (-v / (t1 + u));
    }
    
    real(8) function code(u, v, t1)
        real(8), intent (in) :: u
        real(8), intent (in) :: v
        real(8), intent (in) :: t1
        code = (t1 / (t1 + u)) * (-v / (t1 + u))
    end function
    
    public static double code(double u, double v, double t1) {
    	return (t1 / (t1 + u)) * (-v / (t1 + u));
    }
    
    def code(u, v, t1):
    	return (t1 / (t1 + u)) * (-v / (t1 + u))
    
    function code(u, v, t1)
    	return Float64(Float64(t1 / Float64(t1 + u)) * Float64(Float64(-v) / Float64(t1 + u)))
    end
    
    function tmp = code(u, v, t1)
    	tmp = (t1 / (t1 + u)) * (-v / (t1 + u));
    end
    
    code[u_, v_, t1_] := N[(N[(t1 / N[(t1 + u), $MachinePrecision]), $MachinePrecision] * N[((-v) / N[(t1 + u), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
    
    \begin{array}{l}
    
    \\
    \frac{t1}{t1 + u} \cdot \frac{-v}{t1 + u}
    \end{array}
    
    Derivation
    1. Initial program 72.0%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      2. frac-2negN/A

        \[\leadsto \color{blue}{\frac{\mathsf{neg}\left(\left(-t1\right) \cdot v\right)}{\mathsf{neg}\left(\left(t1 + u\right) \cdot \left(t1 + u\right)\right)}} \]
      3. lift-*.f64N/A

        \[\leadsto \frac{\mathsf{neg}\left(\left(-t1\right) \cdot v\right)}{\mathsf{neg}\left(\color{blue}{\left(t1 + u\right) \cdot \left(t1 + u\right)}\right)} \]
      4. distribute-rgt-neg-inN/A

        \[\leadsto \frac{\mathsf{neg}\left(\left(-t1\right) \cdot v\right)}{\color{blue}{\left(t1 + u\right) \cdot \left(\mathsf{neg}\left(\left(t1 + u\right)\right)\right)}} \]
      5. lift-*.f64N/A

        \[\leadsto \frac{\mathsf{neg}\left(\color{blue}{\left(-t1\right) \cdot v}\right)}{\left(t1 + u\right) \cdot \left(\mathsf{neg}\left(\left(t1 + u\right)\right)\right)} \]
      6. *-commutativeN/A

        \[\leadsto \frac{\mathsf{neg}\left(\color{blue}{v \cdot \left(-t1\right)}\right)}{\left(t1 + u\right) \cdot \left(\mathsf{neg}\left(\left(t1 + u\right)\right)\right)} \]
      7. distribute-lft-neg-inN/A

        \[\leadsto \frac{\color{blue}{\left(\mathsf{neg}\left(v\right)\right) \cdot \left(-t1\right)}}{\left(t1 + u\right) \cdot \left(\mathsf{neg}\left(\left(t1 + u\right)\right)\right)} \]
      8. times-fracN/A

        \[\leadsto \color{blue}{\frac{\mathsf{neg}\left(v\right)}{t1 + u} \cdot \frac{-t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
      9. lift-neg.f64N/A

        \[\leadsto \frac{\mathsf{neg}\left(v\right)}{t1 + u} \cdot \frac{\color{blue}{\mathsf{neg}\left(t1\right)}}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
      10. frac-2negN/A

        \[\leadsto \frac{\mathsf{neg}\left(v\right)}{t1 + u} \cdot \color{blue}{\frac{t1}{t1 + u}} \]
      11. lower-*.f64N/A

        \[\leadsto \color{blue}{\frac{\mathsf{neg}\left(v\right)}{t1 + u} \cdot \frac{t1}{t1 + u}} \]
      12. lower-/.f64N/A

        \[\leadsto \color{blue}{\frac{\mathsf{neg}\left(v\right)}{t1 + u}} \cdot \frac{t1}{t1 + u} \]
      13. lower-neg.f64N/A

        \[\leadsto \frac{\color{blue}{-v}}{t1 + u} \cdot \frac{t1}{t1 + u} \]
      14. lift-+.f64N/A

        \[\leadsto \frac{-v}{\color{blue}{t1 + u}} \cdot \frac{t1}{t1 + u} \]
      15. +-commutativeN/A

        \[\leadsto \frac{-v}{\color{blue}{u + t1}} \cdot \frac{t1}{t1 + u} \]
      16. lower-+.f64N/A

        \[\leadsto \frac{-v}{\color{blue}{u + t1}} \cdot \frac{t1}{t1 + u} \]
      17. lower-/.f6498.1

        \[\leadsto \frac{-v}{u + t1} \cdot \color{blue}{\frac{t1}{t1 + u}} \]
      18. lift-+.f64N/A

        \[\leadsto \frac{-v}{u + t1} \cdot \frac{t1}{\color{blue}{t1 + u}} \]
      19. +-commutativeN/A

        \[\leadsto \frac{-v}{u + t1} \cdot \frac{t1}{\color{blue}{u + t1}} \]
      20. lower-+.f6498.1

        \[\leadsto \frac{-v}{u + t1} \cdot \frac{t1}{\color{blue}{u + t1}} \]
    4. Applied rewrites98.1%

      \[\leadsto \color{blue}{\frac{-v}{u + t1} \cdot \frac{t1}{u + t1}} \]
    5. Final simplification98.1%

      \[\leadsto \frac{t1}{t1 + u} \cdot \frac{-v}{t1 + u} \]
    6. Add Preprocessing

    Alternative 9: 56.2% accurate, 1.2× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;u \leq -1.4 \cdot 10^{+195}:\\ \;\;\;\;\frac{-v}{2 \cdot u}\\ \mathbf{else}:\\ \;\;\;\;\frac{-v}{t1}\\ \end{array} \end{array} \]
    (FPCore (u v t1)
     :precision binary64
     (if (<= u -1.4e+195) (/ (- v) (* 2.0 u)) (/ (- v) t1)))
    double code(double u, double v, double t1) {
    	double tmp;
    	if (u <= -1.4e+195) {
    		tmp = -v / (2.0 * u);
    	} else {
    		tmp = -v / t1;
    	}
    	return tmp;
    }
    
    real(8) function code(u, v, t1)
        real(8), intent (in) :: u
        real(8), intent (in) :: v
        real(8), intent (in) :: t1
        real(8) :: tmp
        if (u <= (-1.4d+195)) then
            tmp = -v / (2.0d0 * u)
        else
            tmp = -v / t1
        end if
        code = tmp
    end function
    
    public static double code(double u, double v, double t1) {
    	double tmp;
    	if (u <= -1.4e+195) {
    		tmp = -v / (2.0 * u);
    	} else {
    		tmp = -v / t1;
    	}
    	return tmp;
    }
    
    def code(u, v, t1):
    	tmp = 0
    	if u <= -1.4e+195:
    		tmp = -v / (2.0 * u)
    	else:
    		tmp = -v / t1
    	return tmp
    
    function code(u, v, t1)
    	tmp = 0.0
    	if (u <= -1.4e+195)
    		tmp = Float64(Float64(-v) / Float64(2.0 * u));
    	else
    		tmp = Float64(Float64(-v) / t1);
    	end
    	return tmp
    end
    
    function tmp_2 = code(u, v, t1)
    	tmp = 0.0;
    	if (u <= -1.4e+195)
    		tmp = -v / (2.0 * u);
    	else
    		tmp = -v / t1;
    	end
    	tmp_2 = tmp;
    end
    
    code[u_, v_, t1_] := If[LessEqual[u, -1.4e+195], N[((-v) / N[(2.0 * u), $MachinePrecision]), $MachinePrecision], N[((-v) / t1), $MachinePrecision]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;u \leq -1.4 \cdot 10^{+195}:\\
    \;\;\;\;\frac{-v}{2 \cdot u}\\
    
    \mathbf{else}:\\
    \;\;\;\;\frac{-v}{t1}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if u < -1.3999999999999999e195

      1. Initial program 72.6%

        \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. lift-/.f64N/A

          \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
        2. lift-*.f64N/A

          \[\leadsto \frac{\color{blue}{\left(-t1\right) \cdot v}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
        3. *-commutativeN/A

          \[\leadsto \frac{\color{blue}{v \cdot \left(-t1\right)}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
        4. lift-*.f64N/A

          \[\leadsto \frac{v \cdot \left(-t1\right)}{\color{blue}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
        5. times-fracN/A

          \[\leadsto \color{blue}{\frac{v}{t1 + u} \cdot \frac{-t1}{t1 + u}} \]
        6. lift-neg.f64N/A

          \[\leadsto \frac{v}{t1 + u} \cdot \frac{\color{blue}{\mathsf{neg}\left(t1\right)}}{t1 + u} \]
        7. distribute-frac-negN/A

          \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\left(\mathsf{neg}\left(\frac{t1}{t1 + u}\right)\right)} \]
        8. distribute-frac-neg2N/A

          \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\frac{t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
        9. associate-*r/N/A

          \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
        10. lower-/.f64N/A

          \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
        11. lower-*.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u} \cdot t1}}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        12. lower-/.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        13. lift-+.f64N/A

          \[\leadsto \frac{\frac{v}{\color{blue}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        14. +-commutativeN/A

          \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        15. lower-+.f64N/A

          \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        16. lower-neg.f6499.9

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{\color{blue}{-\left(t1 + u\right)}} \]
        17. lift-+.f64N/A

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(t1 + u\right)}} \]
        18. +-commutativeN/A

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
        19. lower-+.f6499.9

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
      4. Applied rewrites99.9%

        \[\leadsto \color{blue}{\frac{\frac{v}{u + t1} \cdot t1}{-\left(u + t1\right)}} \]
      5. Step-by-step derivation
        1. lift-/.f64N/A

          \[\leadsto \color{blue}{\frac{\frac{v}{u + t1} \cdot t1}{-\left(u + t1\right)}} \]
        2. lift-*.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{v}{u + t1} \cdot t1}}{-\left(u + t1\right)} \]
        3. associate-/l*N/A

          \[\leadsto \color{blue}{\frac{v}{u + t1} \cdot \frac{t1}{-\left(u + t1\right)}} \]
        4. lift-/.f64N/A

          \[\leadsto \color{blue}{\frac{v}{u + t1}} \cdot \frac{t1}{-\left(u + t1\right)} \]
        5. frac-timesN/A

          \[\leadsto \color{blue}{\frac{v \cdot t1}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)}} \]
        6. *-commutativeN/A

          \[\leadsto \frac{\color{blue}{t1 \cdot v}}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
        7. remove-double-negN/A

          \[\leadsto \frac{t1 \cdot \color{blue}{\left(\mathsf{neg}\left(\left(\mathsf{neg}\left(v\right)\right)\right)\right)}}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
        8. lift-neg.f64N/A

          \[\leadsto \frac{t1 \cdot \left(\mathsf{neg}\left(\color{blue}{\left(-v\right)}\right)\right)}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
        9. frac-timesN/A

          \[\leadsto \color{blue}{\frac{t1}{u + t1} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{-\left(u + t1\right)}} \]
        10. clear-numN/A

          \[\leadsto \color{blue}{\frac{1}{\frac{u + t1}{t1}}} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{-\left(u + t1\right)} \]
        11. lift-neg.f64N/A

          \[\leadsto \frac{1}{\frac{u + t1}{t1}} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{\color{blue}{\mathsf{neg}\left(\left(u + t1\right)\right)}} \]
        12. frac-2negN/A

          \[\leadsto \frac{1}{\frac{u + t1}{t1}} \cdot \color{blue}{\frac{-v}{u + t1}} \]
        13. frac-timesN/A

          \[\leadsto \color{blue}{\frac{1 \cdot \left(-v\right)}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
        14. *-lft-identityN/A

          \[\leadsto \frac{\color{blue}{-v}}{\frac{u + t1}{t1} \cdot \left(u + t1\right)} \]
        15. lower-/.f64N/A

          \[\leadsto \color{blue}{\frac{-v}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
        16. lower-*.f64N/A

          \[\leadsto \frac{-v}{\color{blue}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
        17. lower-/.f6481.7

          \[\leadsto \frac{-v}{\color{blue}{\frac{u + t1}{t1}} \cdot \left(u + t1\right)} \]
        18. lift-+.f64N/A

          \[\leadsto \frac{-v}{\frac{\color{blue}{u + t1}}{t1} \cdot \left(u + t1\right)} \]
        19. +-commutativeN/A

          \[\leadsto \frac{-v}{\frac{\color{blue}{t1 + u}}{t1} \cdot \left(u + t1\right)} \]
        20. lower-+.f6481.7

          \[\leadsto \frac{-v}{\frac{\color{blue}{t1 + u}}{t1} \cdot \left(u + t1\right)} \]
        21. lift-+.f64N/A

          \[\leadsto \frac{-v}{\frac{t1 + u}{t1} \cdot \color{blue}{\left(u + t1\right)}} \]
        22. +-commutativeN/A

          \[\leadsto \frac{-v}{\frac{t1 + u}{t1} \cdot \color{blue}{\left(t1 + u\right)}} \]
      6. Applied rewrites81.7%

        \[\leadsto \color{blue}{\frac{-v}{\frac{t1 + u}{t1} \cdot \left(t1 + u\right)}} \]
      7. Taylor expanded in u around 0

        \[\leadsto \frac{-v}{\color{blue}{t1 + 2 \cdot u}} \]
      8. Step-by-step derivation
        1. +-commutativeN/A

          \[\leadsto \frac{-v}{\color{blue}{2 \cdot u + t1}} \]
        2. *-commutativeN/A

          \[\leadsto \frac{-v}{\color{blue}{u \cdot 2} + t1} \]
        3. lower-fma.f6447.8

          \[\leadsto \frac{-v}{\color{blue}{\mathsf{fma}\left(u, 2, t1\right)}} \]
      9. Applied rewrites47.8%

        \[\leadsto \frac{-v}{\color{blue}{\mathsf{fma}\left(u, 2, t1\right)}} \]
      10. Taylor expanded in u around inf

        \[\leadsto \frac{-v}{2 \cdot \color{blue}{u}} \]
      11. Step-by-step derivation
        1. Applied rewrites43.7%

          \[\leadsto \frac{-v}{u \cdot \color{blue}{2}} \]

        if -1.3999999999999999e195 < u

        1. Initial program 72.0%

          \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
        2. Add Preprocessing
        3. Taylor expanded in u around 0

          \[\leadsto \color{blue}{-1 \cdot \frac{v}{t1}} \]
        4. Step-by-step derivation
          1. associate-*r/N/A

            \[\leadsto \color{blue}{\frac{-1 \cdot v}{t1}} \]
          2. lower-/.f64N/A

            \[\leadsto \color{blue}{\frac{-1 \cdot v}{t1}} \]
          3. mul-1-negN/A

            \[\leadsto \frac{\color{blue}{\mathsf{neg}\left(v\right)}}{t1} \]
          4. lower-neg.f6457.7

            \[\leadsto \frac{\color{blue}{-v}}{t1} \]
        5. Applied rewrites57.7%

          \[\leadsto \color{blue}{\frac{-v}{t1}} \]
      12. Recombined 2 regimes into one program.
      13. Final simplification56.5%

        \[\leadsto \begin{array}{l} \mathbf{if}\;u \leq -1.4 \cdot 10^{+195}:\\ \;\;\;\;\frac{-v}{2 \cdot u}\\ \mathbf{else}:\\ \;\;\;\;\frac{-v}{t1}\\ \end{array} \]
      14. Add Preprocessing

      Alternative 10: 61.9% accurate, 1.5× speedup?

      \[\begin{array}{l} \\ \frac{-v}{\mathsf{fma}\left(u, 2, t1\right)} \end{array} \]
      (FPCore (u v t1) :precision binary64 (/ (- v) (fma u 2.0 t1)))
      double code(double u, double v, double t1) {
      	return -v / fma(u, 2.0, t1);
      }
      
      function code(u, v, t1)
      	return Float64(Float64(-v) / fma(u, 2.0, t1))
      end
      
      code[u_, v_, t1_] := N[((-v) / N[(u * 2.0 + t1), $MachinePrecision]), $MachinePrecision]
      
      \begin{array}{l}
      
      \\
      \frac{-v}{\mathsf{fma}\left(u, 2, t1\right)}
      \end{array}
      
      Derivation
      1. Initial program 72.0%

        \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. lift-/.f64N/A

          \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
        2. lift-*.f64N/A

          \[\leadsto \frac{\color{blue}{\left(-t1\right) \cdot v}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
        3. *-commutativeN/A

          \[\leadsto \frac{\color{blue}{v \cdot \left(-t1\right)}}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
        4. lift-*.f64N/A

          \[\leadsto \frac{v \cdot \left(-t1\right)}{\color{blue}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
        5. times-fracN/A

          \[\leadsto \color{blue}{\frac{v}{t1 + u} \cdot \frac{-t1}{t1 + u}} \]
        6. lift-neg.f64N/A

          \[\leadsto \frac{v}{t1 + u} \cdot \frac{\color{blue}{\mathsf{neg}\left(t1\right)}}{t1 + u} \]
        7. distribute-frac-negN/A

          \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\left(\mathsf{neg}\left(\frac{t1}{t1 + u}\right)\right)} \]
        8. distribute-frac-neg2N/A

          \[\leadsto \frac{v}{t1 + u} \cdot \color{blue}{\frac{t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
        9. associate-*r/N/A

          \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
        10. lower-/.f64N/A

          \[\leadsto \color{blue}{\frac{\frac{v}{t1 + u} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)}} \]
        11. lower-*.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u} \cdot t1}}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        12. lower-/.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{v}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        13. lift-+.f64N/A

          \[\leadsto \frac{\frac{v}{\color{blue}{t1 + u}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        14. +-commutativeN/A

          \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        15. lower-+.f64N/A

          \[\leadsto \frac{\frac{v}{\color{blue}{u + t1}} \cdot t1}{\mathsf{neg}\left(\left(t1 + u\right)\right)} \]
        16. lower-neg.f6499.0

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{\color{blue}{-\left(t1 + u\right)}} \]
        17. lift-+.f64N/A

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(t1 + u\right)}} \]
        18. +-commutativeN/A

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
        19. lower-+.f6499.0

          \[\leadsto \frac{\frac{v}{u + t1} \cdot t1}{-\color{blue}{\left(u + t1\right)}} \]
      4. Applied rewrites99.0%

        \[\leadsto \color{blue}{\frac{\frac{v}{u + t1} \cdot t1}{-\left(u + t1\right)}} \]
      5. Step-by-step derivation
        1. lift-/.f64N/A

          \[\leadsto \color{blue}{\frac{\frac{v}{u + t1} \cdot t1}{-\left(u + t1\right)}} \]
        2. lift-*.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{v}{u + t1} \cdot t1}}{-\left(u + t1\right)} \]
        3. associate-/l*N/A

          \[\leadsto \color{blue}{\frac{v}{u + t1} \cdot \frac{t1}{-\left(u + t1\right)}} \]
        4. lift-/.f64N/A

          \[\leadsto \color{blue}{\frac{v}{u + t1}} \cdot \frac{t1}{-\left(u + t1\right)} \]
        5. frac-timesN/A

          \[\leadsto \color{blue}{\frac{v \cdot t1}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)}} \]
        6. *-commutativeN/A

          \[\leadsto \frac{\color{blue}{t1 \cdot v}}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
        7. remove-double-negN/A

          \[\leadsto \frac{t1 \cdot \color{blue}{\left(\mathsf{neg}\left(\left(\mathsf{neg}\left(v\right)\right)\right)\right)}}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
        8. lift-neg.f64N/A

          \[\leadsto \frac{t1 \cdot \left(\mathsf{neg}\left(\color{blue}{\left(-v\right)}\right)\right)}{\left(u + t1\right) \cdot \left(-\left(u + t1\right)\right)} \]
        9. frac-timesN/A

          \[\leadsto \color{blue}{\frac{t1}{u + t1} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{-\left(u + t1\right)}} \]
        10. clear-numN/A

          \[\leadsto \color{blue}{\frac{1}{\frac{u + t1}{t1}}} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{-\left(u + t1\right)} \]
        11. lift-neg.f64N/A

          \[\leadsto \frac{1}{\frac{u + t1}{t1}} \cdot \frac{\mathsf{neg}\left(\left(-v\right)\right)}{\color{blue}{\mathsf{neg}\left(\left(u + t1\right)\right)}} \]
        12. frac-2negN/A

          \[\leadsto \frac{1}{\frac{u + t1}{t1}} \cdot \color{blue}{\frac{-v}{u + t1}} \]
        13. frac-timesN/A

          \[\leadsto \color{blue}{\frac{1 \cdot \left(-v\right)}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
        14. *-lft-identityN/A

          \[\leadsto \frac{\color{blue}{-v}}{\frac{u + t1}{t1} \cdot \left(u + t1\right)} \]
        15. lower-/.f64N/A

          \[\leadsto \color{blue}{\frac{-v}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
        16. lower-*.f64N/A

          \[\leadsto \frac{-v}{\color{blue}{\frac{u + t1}{t1} \cdot \left(u + t1\right)}} \]
        17. lower-/.f6493.0

          \[\leadsto \frac{-v}{\color{blue}{\frac{u + t1}{t1}} \cdot \left(u + t1\right)} \]
        18. lift-+.f64N/A

          \[\leadsto \frac{-v}{\frac{\color{blue}{u + t1}}{t1} \cdot \left(u + t1\right)} \]
        19. +-commutativeN/A

          \[\leadsto \frac{-v}{\frac{\color{blue}{t1 + u}}{t1} \cdot \left(u + t1\right)} \]
        20. lower-+.f6493.0

          \[\leadsto \frac{-v}{\frac{\color{blue}{t1 + u}}{t1} \cdot \left(u + t1\right)} \]
        21. lift-+.f64N/A

          \[\leadsto \frac{-v}{\frac{t1 + u}{t1} \cdot \color{blue}{\left(u + t1\right)}} \]
        22. +-commutativeN/A

          \[\leadsto \frac{-v}{\frac{t1 + u}{t1} \cdot \color{blue}{\left(t1 + u\right)}} \]
      6. Applied rewrites93.0%

        \[\leadsto \color{blue}{\frac{-v}{\frac{t1 + u}{t1} \cdot \left(t1 + u\right)}} \]
      7. Taylor expanded in u around 0

        \[\leadsto \frac{-v}{\color{blue}{t1 + 2 \cdot u}} \]
      8. Step-by-step derivation
        1. +-commutativeN/A

          \[\leadsto \frac{-v}{\color{blue}{2 \cdot u + t1}} \]
        2. *-commutativeN/A

          \[\leadsto \frac{-v}{\color{blue}{u \cdot 2} + t1} \]
        3. lower-fma.f6459.3

          \[\leadsto \frac{-v}{\color{blue}{\mathsf{fma}\left(u, 2, t1\right)}} \]
      9. Applied rewrites59.3%

        \[\leadsto \frac{-v}{\color{blue}{\mathsf{fma}\left(u, 2, t1\right)}} \]
      10. Add Preprocessing

      Alternative 11: 53.9% accurate, 2.1× speedup?

      \[\begin{array}{l} \\ \frac{-v}{t1} \end{array} \]
      (FPCore (u v t1) :precision binary64 (/ (- v) t1))
      double code(double u, double v, double t1) {
      	return -v / t1;
      }
      
      real(8) function code(u, v, t1)
          real(8), intent (in) :: u
          real(8), intent (in) :: v
          real(8), intent (in) :: t1
          code = -v / t1
      end function
      
      public static double code(double u, double v, double t1) {
      	return -v / t1;
      }
      
      def code(u, v, t1):
      	return -v / t1
      
      function code(u, v, t1)
      	return Float64(Float64(-v) / t1)
      end
      
      function tmp = code(u, v, t1)
      	tmp = -v / t1;
      end
      
      code[u_, v_, t1_] := N[((-v) / t1), $MachinePrecision]
      
      \begin{array}{l}
      
      \\
      \frac{-v}{t1}
      \end{array}
      
      Derivation
      1. Initial program 72.0%

        \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
      2. Add Preprocessing
      3. Taylor expanded in u around 0

        \[\leadsto \color{blue}{-1 \cdot \frac{v}{t1}} \]
      4. Step-by-step derivation
        1. associate-*r/N/A

          \[\leadsto \color{blue}{\frac{-1 \cdot v}{t1}} \]
        2. lower-/.f64N/A

          \[\leadsto \color{blue}{\frac{-1 \cdot v}{t1}} \]
        3. mul-1-negN/A

          \[\leadsto \frac{\color{blue}{\mathsf{neg}\left(v\right)}}{t1} \]
        4. lower-neg.f6454.4

          \[\leadsto \frac{\color{blue}{-v}}{t1} \]
      5. Applied rewrites54.4%

        \[\leadsto \color{blue}{\frac{-v}{t1}} \]
      6. Add Preprocessing

      Reproduce

      ?
      herbie shell --seed 2024273 
      (FPCore (u v t1)
        :name "Rosa's DopplerBench"
        :precision binary64
        (/ (* (- t1) v) (* (+ t1 u) (+ t1 u))))