Rosa's DopplerBench

Percentage Accurate: 73.4% → 98.0%
Time: 18.2s
Alternatives: 19
Speedup: 1.1×

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 19 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.4% 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, 1.1× speedup?

\[\begin{array}{l} \\ \frac{\frac{v}{-1 - \frac{u}{t1}}}{u + t1} \end{array} \]
(FPCore (u v t1) :precision binary64 (/ (/ v (- -1.0 (/ u t1))) (+ u t1)))
double code(double u, double v, double t1) {
	return (v / (-1.0 - (u / t1))) / (u + 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 / ((-1.0d0) - (u / t1))) / (u + t1)
end function
public static double code(double u, double v, double t1) {
	return (v / (-1.0 - (u / t1))) / (u + t1);
}
def code(u, v, t1):
	return (v / (-1.0 - (u / t1))) / (u + t1)
function code(u, v, t1)
	return Float64(Float64(v / Float64(-1.0 - Float64(u / t1))) / Float64(u + t1))
end
function tmp = code(u, v, t1)
	tmp = (v / (-1.0 - (u / t1))) / (u + t1);
end
code[u_, v_, t1_] := N[(N[(v / N[(-1.0 - N[(u / t1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(u + t1), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{\frac{v}{-1 - \frac{u}{t1}}}{u + t1}
\end{array}
Derivation
  1. Initial program 70.4%

    \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
  2. Step-by-step derivation
    1. times-frac98.7%

      \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
    2. distribute-frac-neg98.7%

      \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
    3. distribute-neg-frac298.7%

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

      \[\leadsto \frac{t1}{-\color{blue}{\left(u + t1\right)}} \cdot \frac{v}{t1 + u} \]
    5. distribute-neg-in98.7%

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

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

    \[\leadsto \color{blue}{\frac{t1}{\left(-u\right) - t1} \cdot \frac{v}{t1 + u}} \]
  4. Add Preprocessing
  5. Step-by-step derivation
    1. frac-2neg98.7%

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

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

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

      \[\leadsto \frac{\left(-t1\right) \cdot \left(-v\right)}{\left(-\color{blue}{\left(\left(-u\right) + \left(-t1\right)\right)}\right) \cdot \left(-\left(t1 + u\right)\right)} \]
    5. distribute-neg-in70.4%

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

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

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

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

      \[\leadsto \color{blue}{\frac{\frac{-t1}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)}} \]
    10. add-sqr-sqrt48.2%

      \[\leadsto \frac{\frac{\color{blue}{\sqrt{-t1} \cdot \sqrt{-t1}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
    11. sqrt-unprod42.8%

      \[\leadsto \frac{\frac{\color{blue}{\sqrt{\left(-t1\right) \cdot \left(-t1\right)}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
    12. sqr-neg42.8%

      \[\leadsto \frac{\frac{\sqrt{\color{blue}{t1 \cdot t1}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
    13. sqrt-unprod17.0%

      \[\leadsto \frac{\frac{\color{blue}{\sqrt{t1} \cdot \sqrt{t1}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
    14. add-sqr-sqrt37.2%

      \[\leadsto \frac{\frac{\color{blue}{t1}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
    15. add-sqr-sqrt19.4%

      \[\leadsto \frac{\frac{t1}{t1 + u} \cdot \left(-v\right)}{\color{blue}{\sqrt{-\left(t1 + u\right)} \cdot \sqrt{-\left(t1 + u\right)}}} \]
    16. sqrt-unprod58.4%

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

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

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

    \[\leadsto \frac{\color{blue}{-1 \cdot \frac{v}{1 + \frac{u}{t1}}}}{t1 + u} \]
  9. Step-by-step derivation
    1. associate-*r/99.1%

      \[\leadsto \frac{\color{blue}{\frac{-1 \cdot v}{1 + \frac{u}{t1}}}}{t1 + u} \]
    2. mul-1-neg99.1%

      \[\leadsto \frac{\frac{\color{blue}{-v}}{1 + \frac{u}{t1}}}{t1 + u} \]
  10. Simplified99.1%

    \[\leadsto \frac{\color{blue}{\frac{-v}{1 + \frac{u}{t1}}}}{t1 + u} \]
  11. Final simplification99.1%

    \[\leadsto \frac{\frac{v}{-1 - \frac{u}{t1}}}{u + t1} \]
  12. Add Preprocessing

Alternative 2: 90.1% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(-u\right) - t1\\ \mathbf{if}\;t1 \leq -3.7 \cdot 10^{+118}:\\ \;\;\;\;\frac{v}{t\_1}\\ \mathbf{elif}\;t1 \leq 1.35 \cdot 10^{+93}:\\ \;\;\;\;t1 \cdot \frac{\frac{v}{u + t1}}{t\_1}\\ \mathbf{else}:\\ \;\;\;\;\frac{v \cdot \frac{u}{t1} - v}{u + t1}\\ \end{array} \end{array} \]
(FPCore (u v t1)
 :precision binary64
 (let* ((t_1 (- (- u) t1)))
   (if (<= t1 -3.7e+118)
     (/ v t_1)
     (if (<= t1 1.35e+93)
       (* t1 (/ (/ v (+ u t1)) t_1))
       (/ (- (* v (/ u t1)) v) (+ u t1))))))
double code(double u, double v, double t1) {
	double t_1 = -u - t1;
	double tmp;
	if (t1 <= -3.7e+118) {
		tmp = v / t_1;
	} else if (t1 <= 1.35e+93) {
		tmp = t1 * ((v / (u + t1)) / t_1);
	} else {
		tmp = ((v * (u / t1)) - v) / (u + 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) :: t_1
    real(8) :: tmp
    t_1 = -u - t1
    if (t1 <= (-3.7d+118)) then
        tmp = v / t_1
    else if (t1 <= 1.35d+93) then
        tmp = t1 * ((v / (u + t1)) / t_1)
    else
        tmp = ((v * (u / t1)) - v) / (u + t1)
    end if
    code = tmp
end function
public static double code(double u, double v, double t1) {
	double t_1 = -u - t1;
	double tmp;
	if (t1 <= -3.7e+118) {
		tmp = v / t_1;
	} else if (t1 <= 1.35e+93) {
		tmp = t1 * ((v / (u + t1)) / t_1);
	} else {
		tmp = ((v * (u / t1)) - v) / (u + t1);
	}
	return tmp;
}
def code(u, v, t1):
	t_1 = -u - t1
	tmp = 0
	if t1 <= -3.7e+118:
		tmp = v / t_1
	elif t1 <= 1.35e+93:
		tmp = t1 * ((v / (u + t1)) / t_1)
	else:
		tmp = ((v * (u / t1)) - v) / (u + t1)
	return tmp
function code(u, v, t1)
	t_1 = Float64(Float64(-u) - t1)
	tmp = 0.0
	if (t1 <= -3.7e+118)
		tmp = Float64(v / t_1);
	elseif (t1 <= 1.35e+93)
		tmp = Float64(t1 * Float64(Float64(v / Float64(u + t1)) / t_1));
	else
		tmp = Float64(Float64(Float64(v * Float64(u / t1)) - v) / Float64(u + t1));
	end
	return tmp
end
function tmp_2 = code(u, v, t1)
	t_1 = -u - t1;
	tmp = 0.0;
	if (t1 <= -3.7e+118)
		tmp = v / t_1;
	elseif (t1 <= 1.35e+93)
		tmp = t1 * ((v / (u + t1)) / t_1);
	else
		tmp = ((v * (u / t1)) - v) / (u + t1);
	end
	tmp_2 = tmp;
end
code[u_, v_, t1_] := Block[{t$95$1 = N[((-u) - t1), $MachinePrecision]}, If[LessEqual[t1, -3.7e+118], N[(v / t$95$1), $MachinePrecision], If[LessEqual[t1, 1.35e+93], N[(t1 * N[(N[(v / N[(u + t1), $MachinePrecision]), $MachinePrecision] / t$95$1), $MachinePrecision]), $MachinePrecision], N[(N[(N[(v * N[(u / t1), $MachinePrecision]), $MachinePrecision] - v), $MachinePrecision] / N[(u + t1), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \left(-u\right) - t1\\
\mathbf{if}\;t1 \leq -3.7 \cdot 10^{+118}:\\
\;\;\;\;\frac{v}{t\_1}\\

\mathbf{elif}\;t1 \leq 1.35 \cdot 10^{+93}:\\
\;\;\;\;t1 \cdot \frac{\frac{v}{u + t1}}{t\_1}\\

\mathbf{else}:\\
\;\;\;\;\frac{v \cdot \frac{u}{t1} - v}{u + t1}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t1 < -3.69999999999999987e118

    1. Initial program 45.8%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. times-frac99.9%

        \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
      2. distribute-frac-neg99.9%

        \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
      3. distribute-neg-frac299.9%

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

        \[\leadsto \frac{t1}{-\color{blue}{\left(u + t1\right)}} \cdot \frac{v}{t1 + u} \]
      5. distribute-neg-in99.9%

        \[\leadsto \frac{t1}{\color{blue}{\left(-u\right) + \left(-t1\right)}} \cdot \frac{v}{t1 + u} \]
      6. unsub-neg99.9%

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

      \[\leadsto \color{blue}{\frac{t1}{\left(-u\right) - t1} \cdot \frac{v}{t1 + u}} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. frac-2neg99.9%

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

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

        \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot \left(-v\right)}{\left(-\left(\left(-u\right) - t1\right)\right) \cdot \left(-\left(t1 + u\right)\right)}} \]
      4. sub-neg45.8%

        \[\leadsto \frac{\left(-t1\right) \cdot \left(-v\right)}{\left(-\color{blue}{\left(\left(-u\right) + \left(-t1\right)\right)}\right) \cdot \left(-\left(t1 + u\right)\right)} \]
      5. distribute-neg-in45.8%

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

        \[\leadsto \frac{\left(-t1\right) \cdot \left(-v\right)}{\left(-\left(-\color{blue}{\left(t1 + u\right)}\right)\right) \cdot \left(-\left(t1 + u\right)\right)} \]
      7. remove-double-neg45.8%

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

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

        \[\leadsto \color{blue}{\frac{\frac{-t1}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)}} \]
      10. add-sqr-sqrt99.2%

        \[\leadsto \frac{\frac{\color{blue}{\sqrt{-t1} \cdot \sqrt{-t1}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
      11. sqrt-unprod12.6%

        \[\leadsto \frac{\frac{\color{blue}{\sqrt{\left(-t1\right) \cdot \left(-t1\right)}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
      12. sqr-neg12.6%

        \[\leadsto \frac{\frac{\sqrt{\color{blue}{t1 \cdot t1}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
      13. sqrt-unprod0.0%

        \[\leadsto \frac{\frac{\color{blue}{\sqrt{t1} \cdot \sqrt{t1}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
      14. add-sqr-sqrt41.3%

        \[\leadsto \frac{\frac{\color{blue}{t1}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
      15. add-sqr-sqrt38.6%

        \[\leadsto \frac{\frac{t1}{t1 + u} \cdot \left(-v\right)}{\color{blue}{\sqrt{-\left(t1 + u\right)} \cdot \sqrt{-\left(t1 + u\right)}}} \]
      16. sqrt-unprod42.2%

        \[\leadsto \frac{\frac{t1}{t1 + u} \cdot \left(-v\right)}{\color{blue}{\sqrt{\left(-\left(t1 + u\right)\right) \cdot \left(-\left(t1 + u\right)\right)}}} \]
    6. Applied egg-rr99.9%

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

      \[\leadsto \frac{\color{blue}{-1 \cdot v}}{t1 + u} \]
    8. Step-by-step derivation
      1. mul-1-neg92.8%

        \[\leadsto \frac{\color{blue}{-v}}{t1 + u} \]
    9. Simplified92.8%

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

    if -3.69999999999999987e118 < t1 < 1.35e93

    1. Initial program 81.5%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. associate-/l*83.8%

        \[\leadsto \color{blue}{\left(-t1\right) \cdot \frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      2. distribute-lft-neg-out83.8%

        \[\leadsto \color{blue}{-t1 \cdot \frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      3. distribute-rgt-neg-in83.8%

        \[\leadsto \color{blue}{t1 \cdot \left(-\frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}\right)} \]
      4. associate-/r*90.3%

        \[\leadsto t1 \cdot \left(-\color{blue}{\frac{\frac{v}{t1 + u}}{t1 + u}}\right) \]
      5. distribute-neg-frac290.3%

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

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

    if 1.35e93 < t1

    1. Initial program 44.6%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. times-frac99.9%

        \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
      2. distribute-frac-neg99.9%

        \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
      3. distribute-neg-frac299.9%

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

        \[\leadsto \frac{t1}{-\color{blue}{\left(u + t1\right)}} \cdot \frac{v}{t1 + u} \]
      5. distribute-neg-in99.9%

        \[\leadsto \frac{t1}{\color{blue}{\left(-u\right) + \left(-t1\right)}} \cdot \frac{v}{t1 + u} \]
      6. unsub-neg99.9%

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

      \[\leadsto \color{blue}{\frac{t1}{\left(-u\right) - t1} \cdot \frac{v}{t1 + u}} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. frac-2neg99.9%

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

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

        \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot \left(-v\right)}{\left(-\left(\left(-u\right) - t1\right)\right) \cdot \left(-\left(t1 + u\right)\right)}} \]
      4. sub-neg44.6%

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{\frac{-t1}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)}} \]
      10. add-sqr-sqrt0.0%

        \[\leadsto \frac{\frac{\color{blue}{\sqrt{-t1} \cdot \sqrt{-t1}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
      11. sqrt-unprod8.4%

        \[\leadsto \frac{\frac{\color{blue}{\sqrt{\left(-t1\right) \cdot \left(-t1\right)}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
      12. sqr-neg8.4%

        \[\leadsto \frac{\frac{\sqrt{\color{blue}{t1 \cdot t1}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
      13. sqrt-unprod31.9%

        \[\leadsto \frac{\frac{\color{blue}{\sqrt{t1} \cdot \sqrt{t1}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
      14. add-sqr-sqrt31.9%

        \[\leadsto \frac{\frac{\color{blue}{t1}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
      15. add-sqr-sqrt0.1%

        \[\leadsto \frac{\frac{t1}{t1 + u} \cdot \left(-v\right)}{\color{blue}{\sqrt{-\left(t1 + u\right)} \cdot \sqrt{-\left(t1 + u\right)}}} \]
      16. sqrt-unprod47.9%

        \[\leadsto \frac{\frac{t1}{t1 + u} \cdot \left(-v\right)}{\color{blue}{\sqrt{\left(-\left(t1 + u\right)\right) \cdot \left(-\left(t1 + u\right)\right)}}} \]
    6. Applied egg-rr99.9%

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

      \[\leadsto \frac{\color{blue}{-1 \cdot v + \frac{u \cdot v}{t1}}}{t1 + u} \]
    8. Step-by-step derivation
      1. +-commutative78.0%

        \[\leadsto \frac{\color{blue}{\frac{u \cdot v}{t1} + -1 \cdot v}}{t1 + u} \]
      2. mul-1-neg78.0%

        \[\leadsto \frac{\frac{u \cdot v}{t1} + \color{blue}{\left(-v\right)}}{t1 + u} \]
      3. sub-neg78.0%

        \[\leadsto \frac{\color{blue}{\frac{u \cdot v}{t1} - v}}{t1 + u} \]
      4. *-commutative78.0%

        \[\leadsto \frac{\frac{\color{blue}{v \cdot u}}{t1} - v}{t1 + u} \]
      5. *-lft-identity78.0%

        \[\leadsto \frac{\frac{v \cdot u}{\color{blue}{1 \cdot t1}} - v}{t1 + u} \]
      6. times-frac87.8%

        \[\leadsto \frac{\color{blue}{\frac{v}{1} \cdot \frac{u}{t1}} - v}{t1 + u} \]
      7. /-rgt-identity87.8%

        \[\leadsto \frac{\color{blue}{v} \cdot \frac{u}{t1} - v}{t1 + u} \]
    9. Simplified87.8%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t1 \leq -3.7 \cdot 10^{+118}:\\ \;\;\;\;\frac{v}{\left(-u\right) - t1}\\ \mathbf{elif}\;t1 \leq 1.35 \cdot 10^{+93}:\\ \;\;\;\;t1 \cdot \frac{\frac{v}{u + t1}}{\left(-u\right) - t1}\\ \mathbf{else}:\\ \;\;\;\;\frac{v \cdot \frac{u}{t1} - v}{u + t1}\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 77.6% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{v}{u + t1}\\ \mathbf{if}\;u \leq -1.25 \cdot 10^{-11} \lor \neg \left(u \leq 7.2 \cdot 10^{-68}\right):\\ \;\;\;\;t\_1 \cdot \frac{-t1}{u}\\ \mathbf{else}:\\ \;\;\;\;t\_1 \cdot \left(\frac{u}{t1} + -1\right)\\ \end{array} \end{array} \]
(FPCore (u v t1)
 :precision binary64
 (let* ((t_1 (/ v (+ u t1))))
   (if (or (<= u -1.25e-11) (not (<= u 7.2e-68)))
     (* t_1 (/ (- t1) u))
     (* t_1 (+ (/ u t1) -1.0)))))
double code(double u, double v, double t1) {
	double t_1 = v / (u + t1);
	double tmp;
	if ((u <= -1.25e-11) || !(u <= 7.2e-68)) {
		tmp = t_1 * (-t1 / u);
	} else {
		tmp = t_1 * ((u / t1) + -1.0);
	}
	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) :: t_1
    real(8) :: tmp
    t_1 = v / (u + t1)
    if ((u <= (-1.25d-11)) .or. (.not. (u <= 7.2d-68))) then
        tmp = t_1 * (-t1 / u)
    else
        tmp = t_1 * ((u / t1) + (-1.0d0))
    end if
    code = tmp
end function
public static double code(double u, double v, double t1) {
	double t_1 = v / (u + t1);
	double tmp;
	if ((u <= -1.25e-11) || !(u <= 7.2e-68)) {
		tmp = t_1 * (-t1 / u);
	} else {
		tmp = t_1 * ((u / t1) + -1.0);
	}
	return tmp;
}
def code(u, v, t1):
	t_1 = v / (u + t1)
	tmp = 0
	if (u <= -1.25e-11) or not (u <= 7.2e-68):
		tmp = t_1 * (-t1 / u)
	else:
		tmp = t_1 * ((u / t1) + -1.0)
	return tmp
function code(u, v, t1)
	t_1 = Float64(v / Float64(u + t1))
	tmp = 0.0
	if ((u <= -1.25e-11) || !(u <= 7.2e-68))
		tmp = Float64(t_1 * Float64(Float64(-t1) / u));
	else
		tmp = Float64(t_1 * Float64(Float64(u / t1) + -1.0));
	end
	return tmp
end
function tmp_2 = code(u, v, t1)
	t_1 = v / (u + t1);
	tmp = 0.0;
	if ((u <= -1.25e-11) || ~((u <= 7.2e-68)))
		tmp = t_1 * (-t1 / u);
	else
		tmp = t_1 * ((u / t1) + -1.0);
	end
	tmp_2 = tmp;
end
code[u_, v_, t1_] := Block[{t$95$1 = N[(v / N[(u + t1), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[u, -1.25e-11], N[Not[LessEqual[u, 7.2e-68]], $MachinePrecision]], N[(t$95$1 * N[((-t1) / u), $MachinePrecision]), $MachinePrecision], N[(t$95$1 * N[(N[(u / t1), $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{v}{u + t1}\\
\mathbf{if}\;u \leq -1.25 \cdot 10^{-11} \lor \neg \left(u \leq 7.2 \cdot 10^{-68}\right):\\
\;\;\;\;t\_1 \cdot \frac{-t1}{u}\\

\mathbf{else}:\\
\;\;\;\;t\_1 \cdot \left(\frac{u}{t1} + -1\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if u < -1.25000000000000005e-11 or 7.20000000000000015e-68 < u

    1. Initial program 76.3%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. times-frac99.1%

        \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
      2. distribute-frac-neg99.1%

        \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
      3. distribute-neg-frac299.1%

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

        \[\leadsto \frac{t1}{-\color{blue}{\left(u + t1\right)}} \cdot \frac{v}{t1 + u} \]
      5. distribute-neg-in99.1%

        \[\leadsto \frac{t1}{\color{blue}{\left(-u\right) + \left(-t1\right)}} \cdot \frac{v}{t1 + u} \]
      6. unsub-neg99.1%

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

      \[\leadsto \color{blue}{\frac{t1}{\left(-u\right) - t1} \cdot \frac{v}{t1 + u}} \]
    4. Add Preprocessing
    5. Taylor expanded in t1 around 0 83.2%

      \[\leadsto \color{blue}{\left(-1 \cdot \frac{t1}{u}\right)} \cdot \frac{v}{t1 + u} \]
    6. Step-by-step derivation
      1. associate-*r/83.2%

        \[\leadsto \color{blue}{\frac{-1 \cdot t1}{u}} \cdot \frac{v}{t1 + u} \]
      2. mul-1-neg83.2%

        \[\leadsto \frac{\color{blue}{-t1}}{u} \cdot \frac{v}{t1 + u} \]
    7. Simplified83.2%

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

    if -1.25000000000000005e-11 < u < 7.20000000000000015e-68

    1. Initial program 64.1%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. times-frac98.4%

        \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
      2. distribute-frac-neg98.4%

        \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
      3. distribute-neg-frac298.4%

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

        \[\leadsto \frac{t1}{-\color{blue}{\left(u + t1\right)}} \cdot \frac{v}{t1 + u} \]
      5. distribute-neg-in98.4%

        \[\leadsto \frac{t1}{\color{blue}{\left(-u\right) + \left(-t1\right)}} \cdot \frac{v}{t1 + u} \]
      6. unsub-neg98.4%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;u \leq -1.25 \cdot 10^{-11} \lor \neg \left(u \leq 7.2 \cdot 10^{-68}\right):\\ \;\;\;\;\frac{v}{u + t1} \cdot \frac{-t1}{u}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{u + t1} \cdot \left(\frac{u}{t1} + -1\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 78.2% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;u \leq -3.7 \cdot 10^{-10} \lor \neg \left(u \leq 3.25 \cdot 10^{-62}\right):\\ \;\;\;\;\frac{v}{u + t1} \cdot \frac{-t1}{u}\\ \mathbf{else}:\\ \;\;\;\;v \cdot \frac{\frac{u}{t1} \cdot 2 + -1}{t1}\\ \end{array} \end{array} \]
(FPCore (u v t1)
 :precision binary64
 (if (or (<= u -3.7e-10) (not (<= u 3.25e-62)))
   (* (/ v (+ u t1)) (/ (- t1) u))
   (* v (/ (+ (* (/ u t1) 2.0) -1.0) t1))))
double code(double u, double v, double t1) {
	double tmp;
	if ((u <= -3.7e-10) || !(u <= 3.25e-62)) {
		tmp = (v / (u + t1)) * (-t1 / u);
	} else {
		tmp = v * ((((u / t1) * 2.0) + -1.0) / 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 <= (-3.7d-10)) .or. (.not. (u <= 3.25d-62))) then
        tmp = (v / (u + t1)) * (-t1 / u)
    else
        tmp = v * ((((u / t1) * 2.0d0) + (-1.0d0)) / t1)
    end if
    code = tmp
end function
public static double code(double u, double v, double t1) {
	double tmp;
	if ((u <= -3.7e-10) || !(u <= 3.25e-62)) {
		tmp = (v / (u + t1)) * (-t1 / u);
	} else {
		tmp = v * ((((u / t1) * 2.0) + -1.0) / t1);
	}
	return tmp;
}
def code(u, v, t1):
	tmp = 0
	if (u <= -3.7e-10) or not (u <= 3.25e-62):
		tmp = (v / (u + t1)) * (-t1 / u)
	else:
		tmp = v * ((((u / t1) * 2.0) + -1.0) / t1)
	return tmp
function code(u, v, t1)
	tmp = 0.0
	if ((u <= -3.7e-10) || !(u <= 3.25e-62))
		tmp = Float64(Float64(v / Float64(u + t1)) * Float64(Float64(-t1) / u));
	else
		tmp = Float64(v * Float64(Float64(Float64(Float64(u / t1) * 2.0) + -1.0) / t1));
	end
	return tmp
end
function tmp_2 = code(u, v, t1)
	tmp = 0.0;
	if ((u <= -3.7e-10) || ~((u <= 3.25e-62)))
		tmp = (v / (u + t1)) * (-t1 / u);
	else
		tmp = v * ((((u / t1) * 2.0) + -1.0) / t1);
	end
	tmp_2 = tmp;
end
code[u_, v_, t1_] := If[Or[LessEqual[u, -3.7e-10], N[Not[LessEqual[u, 3.25e-62]], $MachinePrecision]], N[(N[(v / N[(u + t1), $MachinePrecision]), $MachinePrecision] * N[((-t1) / u), $MachinePrecision]), $MachinePrecision], N[(v * N[(N[(N[(N[(u / t1), $MachinePrecision] * 2.0), $MachinePrecision] + -1.0), $MachinePrecision] / t1), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;u \leq -3.7 \cdot 10^{-10} \lor \neg \left(u \leq 3.25 \cdot 10^{-62}\right):\\
\;\;\;\;\frac{v}{u + t1} \cdot \frac{-t1}{u}\\

\mathbf{else}:\\
\;\;\;\;v \cdot \frac{\frac{u}{t1} \cdot 2 + -1}{t1}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if u < -3.70000000000000015e-10 or 3.25000000000000013e-62 < u

    1. Initial program 76.0%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. times-frac99.0%

        \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
      2. distribute-frac-neg99.0%

        \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
      3. distribute-neg-frac299.0%

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

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

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

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

      \[\leadsto \color{blue}{\frac{t1}{\left(-u\right) - t1} \cdot \frac{v}{t1 + u}} \]
    4. Add Preprocessing
    5. Taylor expanded in t1 around 0 83.7%

      \[\leadsto \color{blue}{\left(-1 \cdot \frac{t1}{u}\right)} \cdot \frac{v}{t1 + u} \]
    6. Step-by-step derivation
      1. associate-*r/83.7%

        \[\leadsto \color{blue}{\frac{-1 \cdot t1}{u}} \cdot \frac{v}{t1 + u} \]
      2. mul-1-neg83.7%

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

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

    if -3.70000000000000015e-10 < u < 3.25000000000000013e-62

    1. Initial program 64.6%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. associate-*l/72.6%

        \[\leadsto \color{blue}{\frac{-t1}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \cdot v} \]
      2. *-commutative72.6%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;u \leq -3.7 \cdot 10^{-10} \lor \neg \left(u \leq 3.25 \cdot 10^{-62}\right):\\ \;\;\;\;\frac{v}{u + t1} \cdot \frac{-t1}{u}\\ \mathbf{else}:\\ \;\;\;\;v \cdot \frac{\frac{u}{t1} \cdot 2 + -1}{t1}\\ \end{array} \]
  5. Add Preprocessing

Alternative 5: 79.0% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;u \leq -0.0031 \lor \neg \left(u \leq 1.25 \cdot 10^{-62}\right):\\ \;\;\;\;\frac{v}{u + t1} \cdot \frac{-t1}{u}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{-t1}\\ \end{array} \end{array} \]
(FPCore (u v t1)
 :precision binary64
 (if (or (<= u -0.0031) (not (<= u 1.25e-62)))
   (* (/ v (+ u t1)) (/ (- t1) u))
   (/ v (- t1))))
double code(double u, double v, double t1) {
	double tmp;
	if ((u <= -0.0031) || !(u <= 1.25e-62)) {
		tmp = (v / (u + t1)) * (-t1 / 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 <= (-0.0031d0)) .or. (.not. (u <= 1.25d-62))) then
        tmp = (v / (u + t1)) * (-t1 / 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 <= -0.0031) || !(u <= 1.25e-62)) {
		tmp = (v / (u + t1)) * (-t1 / u);
	} else {
		tmp = v / -t1;
	}
	return tmp;
}
def code(u, v, t1):
	tmp = 0
	if (u <= -0.0031) or not (u <= 1.25e-62):
		tmp = (v / (u + t1)) * (-t1 / u)
	else:
		tmp = v / -t1
	return tmp
function code(u, v, t1)
	tmp = 0.0
	if ((u <= -0.0031) || !(u <= 1.25e-62))
		tmp = Float64(Float64(v / Float64(u + t1)) * Float64(Float64(-t1) / u));
	else
		tmp = Float64(v / Float64(-t1));
	end
	return tmp
end
function tmp_2 = code(u, v, t1)
	tmp = 0.0;
	if ((u <= -0.0031) || ~((u <= 1.25e-62)))
		tmp = (v / (u + t1)) * (-t1 / u);
	else
		tmp = v / -t1;
	end
	tmp_2 = tmp;
end
code[u_, v_, t1_] := If[Or[LessEqual[u, -0.0031], N[Not[LessEqual[u, 1.25e-62]], $MachinePrecision]], N[(N[(v / N[(u + t1), $MachinePrecision]), $MachinePrecision] * N[((-t1) / u), $MachinePrecision]), $MachinePrecision], N[(v / (-t1)), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;u \leq -0.0031 \lor \neg \left(u \leq 1.25 \cdot 10^{-62}\right):\\
\;\;\;\;\frac{v}{u + t1} \cdot \frac{-t1}{u}\\

\mathbf{else}:\\
\;\;\;\;\frac{v}{-t1}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if u < -0.00309999999999999989 or 1.25e-62 < u

    1. Initial program 76.0%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. times-frac99.0%

        \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
      2. distribute-frac-neg99.0%

        \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
      3. distribute-neg-frac299.0%

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

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

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

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

      \[\leadsto \color{blue}{\frac{t1}{\left(-u\right) - t1} \cdot \frac{v}{t1 + u}} \]
    4. Add Preprocessing
    5. Taylor expanded in t1 around 0 83.7%

      \[\leadsto \color{blue}{\left(-1 \cdot \frac{t1}{u}\right)} \cdot \frac{v}{t1 + u} \]
    6. Step-by-step derivation
      1. associate-*r/83.7%

        \[\leadsto \color{blue}{\frac{-1 \cdot t1}{u}} \cdot \frac{v}{t1 + u} \]
      2. mul-1-neg83.7%

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

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

    if -0.00309999999999999989 < u < 1.25e-62

    1. Initial program 64.6%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. times-frac98.4%

        \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
      2. distribute-frac-neg98.4%

        \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
      3. distribute-neg-frac298.4%

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

        \[\leadsto \frac{t1}{-\color{blue}{\left(u + t1\right)}} \cdot \frac{v}{t1 + u} \]
      5. distribute-neg-in98.4%

        \[\leadsto \frac{t1}{\color{blue}{\left(-u\right) + \left(-t1\right)}} \cdot \frac{v}{t1 + u} \]
      6. unsub-neg98.4%

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{v}{t1}} \]
    6. Step-by-step derivation
      1. associate-*r/81.7%

        \[\leadsto \color{blue}{\frac{-1 \cdot v}{t1}} \]
      2. neg-mul-181.7%

        \[\leadsto \frac{\color{blue}{-v}}{t1} \]
    7. Simplified81.7%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;u \leq -0.0031 \lor \neg \left(u \leq 1.25 \cdot 10^{-62}\right):\\ \;\;\;\;\frac{v}{u + t1} \cdot \frac{-t1}{u}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{-t1}\\ \end{array} \]
  5. Add Preprocessing

Alternative 6: 77.7% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;u \leq -1.3 \cdot 10^{-11}:\\ \;\;\;\;\frac{\frac{-t1}{u}}{\frac{u}{v}}\\ \mathbf{elif}\;u \leq 3.3 \cdot 10^{-62}:\\ \;\;\;\;\frac{v}{-t1}\\ \mathbf{else}:\\ \;\;\;\;t1 \cdot \frac{\frac{v}{u + t1}}{-u}\\ \end{array} \end{array} \]
(FPCore (u v t1)
 :precision binary64
 (if (<= u -1.3e-11)
   (/ (/ (- t1) u) (/ u v))
   (if (<= u 3.3e-62) (/ v (- t1)) (* t1 (/ (/ v (+ u t1)) (- u))))))
double code(double u, double v, double t1) {
	double tmp;
	if (u <= -1.3e-11) {
		tmp = (-t1 / u) / (u / v);
	} else if (u <= 3.3e-62) {
		tmp = v / -t1;
	} else {
		tmp = t1 * ((v / (u + t1)) / -u);
	}
	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.3d-11)) then
        tmp = (-t1 / u) / (u / v)
    else if (u <= 3.3d-62) then
        tmp = v / -t1
    else
        tmp = t1 * ((v / (u + t1)) / -u)
    end if
    code = tmp
end function
public static double code(double u, double v, double t1) {
	double tmp;
	if (u <= -1.3e-11) {
		tmp = (-t1 / u) / (u / v);
	} else if (u <= 3.3e-62) {
		tmp = v / -t1;
	} else {
		tmp = t1 * ((v / (u + t1)) / -u);
	}
	return tmp;
}
def code(u, v, t1):
	tmp = 0
	if u <= -1.3e-11:
		tmp = (-t1 / u) / (u / v)
	elif u <= 3.3e-62:
		tmp = v / -t1
	else:
		tmp = t1 * ((v / (u + t1)) / -u)
	return tmp
function code(u, v, t1)
	tmp = 0.0
	if (u <= -1.3e-11)
		tmp = Float64(Float64(Float64(-t1) / u) / Float64(u / v));
	elseif (u <= 3.3e-62)
		tmp = Float64(v / Float64(-t1));
	else
		tmp = Float64(t1 * Float64(Float64(v / Float64(u + t1)) / Float64(-u)));
	end
	return tmp
end
function tmp_2 = code(u, v, t1)
	tmp = 0.0;
	if (u <= -1.3e-11)
		tmp = (-t1 / u) / (u / v);
	elseif (u <= 3.3e-62)
		tmp = v / -t1;
	else
		tmp = t1 * ((v / (u + t1)) / -u);
	end
	tmp_2 = tmp;
end
code[u_, v_, t1_] := If[LessEqual[u, -1.3e-11], N[(N[((-t1) / u), $MachinePrecision] / N[(u / v), $MachinePrecision]), $MachinePrecision], If[LessEqual[u, 3.3e-62], N[(v / (-t1)), $MachinePrecision], N[(t1 * N[(N[(v / N[(u + t1), $MachinePrecision]), $MachinePrecision] / (-u)), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;u \leq -1.3 \cdot 10^{-11}:\\
\;\;\;\;\frac{\frac{-t1}{u}}{\frac{u}{v}}\\

\mathbf{elif}\;u \leq 3.3 \cdot 10^{-62}:\\
\;\;\;\;\frac{v}{-t1}\\

\mathbf{else}:\\
\;\;\;\;t1 \cdot \frac{\frac{v}{u + t1}}{-u}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if u < -1.3e-11

    1. Initial program 80.8%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. associate-/l*78.0%

        \[\leadsto \color{blue}{\left(-t1\right) \cdot \frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      2. distribute-lft-neg-out78.0%

        \[\leadsto \color{blue}{-t1 \cdot \frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      3. distribute-rgt-neg-in78.0%

        \[\leadsto \color{blue}{t1 \cdot \left(-\frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}\right)} \]
      4. associate-/r*90.3%

        \[\leadsto t1 \cdot \left(-\color{blue}{\frac{\frac{v}{t1 + u}}{t1 + u}}\right) \]
      5. distribute-neg-frac290.3%

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

      \[\leadsto \color{blue}{t1 \cdot \frac{\frac{v}{t1 + u}}{-\left(t1 + u\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in t1 around 0 83.5%

      \[\leadsto t1 \cdot \frac{\frac{v}{t1 + u}}{-\color{blue}{u}} \]
    6. Applied egg-rr83.6%

      \[\leadsto \color{blue}{\frac{-t1}{\frac{u}{v} \cdot \left(t1 + u\right)}} \]
    7. Step-by-step derivation
      1. *-commutative83.6%

        \[\leadsto \frac{-t1}{\color{blue}{\left(t1 + u\right) \cdot \frac{u}{v}}} \]
      2. associate-/r*84.4%

        \[\leadsto \color{blue}{\frac{\frac{-t1}{t1 + u}}{\frac{u}{v}}} \]
    8. Simplified84.4%

      \[\leadsto \color{blue}{\frac{\frac{-t1}{t1 + u}}{\frac{u}{v}}} \]
    9. Taylor expanded in t1 around 0 84.6%

      \[\leadsto \frac{\color{blue}{-1 \cdot \frac{t1}{u}}}{\frac{u}{v}} \]
    10. Step-by-step derivation
      1. associate-*r/84.6%

        \[\leadsto \frac{\color{blue}{\frac{-1 \cdot t1}{u}}}{\frac{u}{v}} \]
      2. mul-1-neg84.6%

        \[\leadsto \frac{\frac{\color{blue}{-t1}}{u}}{\frac{u}{v}} \]
    11. Simplified84.6%

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

    if -1.3e-11 < u < 3.30000000000000004e-62

    1. Initial program 64.6%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. times-frac98.4%

        \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
      2. distribute-frac-neg98.4%

        \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
      3. distribute-neg-frac298.4%

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

        \[\leadsto \frac{t1}{-\color{blue}{\left(u + t1\right)}} \cdot \frac{v}{t1 + u} \]
      5. distribute-neg-in98.4%

        \[\leadsto \frac{t1}{\color{blue}{\left(-u\right) + \left(-t1\right)}} \cdot \frac{v}{t1 + u} \]
      6. unsub-neg98.4%

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{v}{t1}} \]
    6. Step-by-step derivation
      1. associate-*r/81.7%

        \[\leadsto \color{blue}{\frac{-1 \cdot v}{t1}} \]
      2. neg-mul-181.7%

        \[\leadsto \frac{\color{blue}{-v}}{t1} \]
    7. Simplified81.7%

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

    if 3.30000000000000004e-62 < u

    1. Initial program 71.6%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. associate-/l*74.4%

        \[\leadsto \color{blue}{\left(-t1\right) \cdot \frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      2. distribute-lft-neg-out74.4%

        \[\leadsto \color{blue}{-t1 \cdot \frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      3. distribute-rgt-neg-in74.4%

        \[\leadsto \color{blue}{t1 \cdot \left(-\frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}\right)} \]
      4. associate-/r*88.4%

        \[\leadsto t1 \cdot \left(-\color{blue}{\frac{\frac{v}{t1 + u}}{t1 + u}}\right) \]
      5. distribute-neg-frac288.4%

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

      \[\leadsto \color{blue}{t1 \cdot \frac{\frac{v}{t1 + u}}{-\left(t1 + u\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in t1 around 0 78.6%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;u \leq -1.3 \cdot 10^{-11}:\\ \;\;\;\;\frac{\frac{-t1}{u}}{\frac{u}{v}}\\ \mathbf{elif}\;u \leq 3.3 \cdot 10^{-62}:\\ \;\;\;\;\frac{v}{-t1}\\ \mathbf{else}:\\ \;\;\;\;t1 \cdot \frac{\frac{v}{u + t1}}{-u}\\ \end{array} \]
  5. Add Preprocessing

Alternative 7: 76.8% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;u \leq -2 \cdot 10^{-11} \lor \neg \left(u \leq 5.8 \cdot 10^{-51}\right):\\ \;\;\;\;\frac{\frac{-t1}{u}}{\frac{u}{v}}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{-t1}\\ \end{array} \end{array} \]
(FPCore (u v t1)
 :precision binary64
 (if (or (<= u -2e-11) (not (<= u 5.8e-51)))
   (/ (/ (- t1) u) (/ u v))
   (/ v (- t1))))
double code(double u, double v, double t1) {
	double tmp;
	if ((u <= -2e-11) || !(u <= 5.8e-51)) {
		tmp = (-t1 / u) / (u / v);
	} 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 <= (-2d-11)) .or. (.not. (u <= 5.8d-51))) then
        tmp = (-t1 / u) / (u / v)
    else
        tmp = v / -t1
    end if
    code = tmp
end function
public static double code(double u, double v, double t1) {
	double tmp;
	if ((u <= -2e-11) || !(u <= 5.8e-51)) {
		tmp = (-t1 / u) / (u / v);
	} else {
		tmp = v / -t1;
	}
	return tmp;
}
def code(u, v, t1):
	tmp = 0
	if (u <= -2e-11) or not (u <= 5.8e-51):
		tmp = (-t1 / u) / (u / v)
	else:
		tmp = v / -t1
	return tmp
function code(u, v, t1)
	tmp = 0.0
	if ((u <= -2e-11) || !(u <= 5.8e-51))
		tmp = Float64(Float64(Float64(-t1) / u) / Float64(u / v));
	else
		tmp = Float64(v / Float64(-t1));
	end
	return tmp
end
function tmp_2 = code(u, v, t1)
	tmp = 0.0;
	if ((u <= -2e-11) || ~((u <= 5.8e-51)))
		tmp = (-t1 / u) / (u / v);
	else
		tmp = v / -t1;
	end
	tmp_2 = tmp;
end
code[u_, v_, t1_] := If[Or[LessEqual[u, -2e-11], N[Not[LessEqual[u, 5.8e-51]], $MachinePrecision]], N[(N[((-t1) / u), $MachinePrecision] / N[(u / v), $MachinePrecision]), $MachinePrecision], N[(v / (-t1)), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;u \leq -2 \cdot 10^{-11} \lor \neg \left(u \leq 5.8 \cdot 10^{-51}\right):\\
\;\;\;\;\frac{\frac{-t1}{u}}{\frac{u}{v}}\\

\mathbf{else}:\\
\;\;\;\;\frac{v}{-t1}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if u < -1.99999999999999988e-11 or 5.79999999999999945e-51 < u

    1. Initial program 76.3%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. associate-/l*75.7%

        \[\leadsto \color{blue}{\left(-t1\right) \cdot \frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      2. distribute-lft-neg-out75.7%

        \[\leadsto \color{blue}{-t1 \cdot \frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      3. distribute-rgt-neg-in75.7%

        \[\leadsto \color{blue}{t1 \cdot \left(-\frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}\right)} \]
      4. associate-/r*89.1%

        \[\leadsto t1 \cdot \left(-\color{blue}{\frac{\frac{v}{t1 + u}}{t1 + u}}\right) \]
      5. distribute-neg-frac289.1%

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

      \[\leadsto \color{blue}{t1 \cdot \frac{\frac{v}{t1 + u}}{-\left(t1 + u\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in t1 around 0 80.6%

      \[\leadsto t1 \cdot \frac{\frac{v}{t1 + u}}{-\color{blue}{u}} \]
    6. Applied egg-rr80.7%

      \[\leadsto \color{blue}{\frac{-t1}{\frac{u}{v} \cdot \left(t1 + u\right)}} \]
    7. Step-by-step derivation
      1. *-commutative80.7%

        \[\leadsto \frac{-t1}{\color{blue}{\left(t1 + u\right) \cdot \frac{u}{v}}} \]
      2. associate-/r*81.7%

        \[\leadsto \color{blue}{\frac{\frac{-t1}{t1 + u}}{\frac{u}{v}}} \]
    8. Simplified81.7%

      \[\leadsto \color{blue}{\frac{\frac{-t1}{t1 + u}}{\frac{u}{v}}} \]
    9. Taylor expanded in t1 around 0 81.7%

      \[\leadsto \frac{\color{blue}{-1 \cdot \frac{t1}{u}}}{\frac{u}{v}} \]
    10. Step-by-step derivation
      1. associate-*r/81.7%

        \[\leadsto \frac{\color{blue}{\frac{-1 \cdot t1}{u}}}{\frac{u}{v}} \]
      2. mul-1-neg81.7%

        \[\leadsto \frac{\frac{\color{blue}{-t1}}{u}}{\frac{u}{v}} \]
    11. Simplified81.7%

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

    if -1.99999999999999988e-11 < u < 5.79999999999999945e-51

    1. Initial program 64.5%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. times-frac98.4%

        \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
      2. distribute-frac-neg98.4%

        \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
      3. distribute-neg-frac298.4%

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

        \[\leadsto \frac{t1}{-\color{blue}{\left(u + t1\right)}} \cdot \frac{v}{t1 + u} \]
      5. distribute-neg-in98.4%

        \[\leadsto \frac{t1}{\color{blue}{\left(-u\right) + \left(-t1\right)}} \cdot \frac{v}{t1 + u} \]
      6. unsub-neg98.4%

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{v}{t1}} \]
    6. Step-by-step derivation
      1. associate-*r/81.3%

        \[\leadsto \color{blue}{\frac{-1 \cdot v}{t1}} \]
      2. neg-mul-181.3%

        \[\leadsto \frac{\color{blue}{-v}}{t1} \]
    7. Simplified81.3%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;u \leq -2 \cdot 10^{-11} \lor \neg \left(u \leq 5.8 \cdot 10^{-51}\right):\\ \;\;\;\;\frac{\frac{-t1}{u}}{\frac{u}{v}}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{-t1}\\ \end{array} \]
  5. Add Preprocessing

Alternative 8: 76.6% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;u \leq -1.15 \cdot 10^{-10} \lor \neg \left(u \leq 5.2 \cdot 10^{-51}\right):\\ \;\;\;\;\frac{-t1}{u} \cdot \frac{v}{u}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{-t1}\\ \end{array} \end{array} \]
(FPCore (u v t1)
 :precision binary64
 (if (or (<= u -1.15e-10) (not (<= u 5.2e-51)))
   (* (/ (- t1) u) (/ v u))
   (/ v (- t1))))
double code(double u, double v, double t1) {
	double tmp;
	if ((u <= -1.15e-10) || !(u <= 5.2e-51)) {
		tmp = (-t1 / u) * (v / 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.15d-10)) .or. (.not. (u <= 5.2d-51))) then
        tmp = (-t1 / u) * (v / 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.15e-10) || !(u <= 5.2e-51)) {
		tmp = (-t1 / u) * (v / u);
	} else {
		tmp = v / -t1;
	}
	return tmp;
}
def code(u, v, t1):
	tmp = 0
	if (u <= -1.15e-10) or not (u <= 5.2e-51):
		tmp = (-t1 / u) * (v / u)
	else:
		tmp = v / -t1
	return tmp
function code(u, v, t1)
	tmp = 0.0
	if ((u <= -1.15e-10) || !(u <= 5.2e-51))
		tmp = Float64(Float64(Float64(-t1) / u) * Float64(v / u));
	else
		tmp = Float64(v / Float64(-t1));
	end
	return tmp
end
function tmp_2 = code(u, v, t1)
	tmp = 0.0;
	if ((u <= -1.15e-10) || ~((u <= 5.2e-51)))
		tmp = (-t1 / u) * (v / u);
	else
		tmp = v / -t1;
	end
	tmp_2 = tmp;
end
code[u_, v_, t1_] := If[Or[LessEqual[u, -1.15e-10], N[Not[LessEqual[u, 5.2e-51]], $MachinePrecision]], N[(N[((-t1) / u), $MachinePrecision] * N[(v / u), $MachinePrecision]), $MachinePrecision], N[(v / (-t1)), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;u \leq -1.15 \cdot 10^{-10} \lor \neg \left(u \leq 5.2 \cdot 10^{-51}\right):\\
\;\;\;\;\frac{-t1}{u} \cdot \frac{v}{u}\\

\mathbf{else}:\\
\;\;\;\;\frac{v}{-t1}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if u < -1.15000000000000004e-10 or 5.2e-51 < u

    1. Initial program 76.3%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. times-frac99.0%

        \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
      2. distribute-frac-neg99.0%

        \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
      3. distribute-neg-frac299.0%

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

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

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

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

      \[\leadsto \color{blue}{\frac{t1}{\left(-u\right) - t1} \cdot \frac{v}{t1 + u}} \]
    4. Add Preprocessing
    5. Taylor expanded in t1 around 0 81.2%

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

      \[\leadsto \color{blue}{\left(-1 \cdot \frac{t1}{u}\right)} \cdot \frac{v}{u} \]
    7. Step-by-step derivation
      1. associate-*r/83.4%

        \[\leadsto \color{blue}{\frac{-1 \cdot t1}{u}} \cdot \frac{v}{t1 + u} \]
      2. mul-1-neg83.4%

        \[\leadsto \frac{\color{blue}{-t1}}{u} \cdot \frac{v}{t1 + u} \]
    8. Simplified81.2%

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

    if -1.15000000000000004e-10 < u < 5.2e-51

    1. Initial program 64.5%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. times-frac98.4%

        \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
      2. distribute-frac-neg98.4%

        \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
      3. distribute-neg-frac298.4%

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

        \[\leadsto \frac{t1}{-\color{blue}{\left(u + t1\right)}} \cdot \frac{v}{t1 + u} \]
      5. distribute-neg-in98.4%

        \[\leadsto \frac{t1}{\color{blue}{\left(-u\right) + \left(-t1\right)}} \cdot \frac{v}{t1 + u} \]
      6. unsub-neg98.4%

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{v}{t1}} \]
    6. Step-by-step derivation
      1. associate-*r/81.3%

        \[\leadsto \color{blue}{\frac{-1 \cdot v}{t1}} \]
      2. neg-mul-181.3%

        \[\leadsto \frac{\color{blue}{-v}}{t1} \]
    7. Simplified81.3%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;u \leq -1.15 \cdot 10^{-10} \lor \neg \left(u \leq 5.2 \cdot 10^{-51}\right):\\ \;\;\;\;\frac{-t1}{u} \cdot \frac{v}{u}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{-t1}\\ \end{array} \]
  5. Add Preprocessing

Alternative 9: 76.9% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;u \leq -1.56 \cdot 10^{-9} \lor \neg \left(u \leq 6.2 \cdot 10^{-52}\right):\\ \;\;\;\;t1 \cdot \frac{\frac{v}{u}}{-u}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{-t1}\\ \end{array} \end{array} \]
(FPCore (u v t1)
 :precision binary64
 (if (or (<= u -1.56e-9) (not (<= u 6.2e-52)))
   (* t1 (/ (/ v u) (- u)))
   (/ v (- t1))))
double code(double u, double v, double t1) {
	double tmp;
	if ((u <= -1.56e-9) || !(u <= 6.2e-52)) {
		tmp = t1 * ((v / u) / -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.56d-9)) .or. (.not. (u <= 6.2d-52))) then
        tmp = t1 * ((v / u) / -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.56e-9) || !(u <= 6.2e-52)) {
		tmp = t1 * ((v / u) / -u);
	} else {
		tmp = v / -t1;
	}
	return tmp;
}
def code(u, v, t1):
	tmp = 0
	if (u <= -1.56e-9) or not (u <= 6.2e-52):
		tmp = t1 * ((v / u) / -u)
	else:
		tmp = v / -t1
	return tmp
function code(u, v, t1)
	tmp = 0.0
	if ((u <= -1.56e-9) || !(u <= 6.2e-52))
		tmp = Float64(t1 * Float64(Float64(v / u) / Float64(-u)));
	else
		tmp = Float64(v / Float64(-t1));
	end
	return tmp
end
function tmp_2 = code(u, v, t1)
	tmp = 0.0;
	if ((u <= -1.56e-9) || ~((u <= 6.2e-52)))
		tmp = t1 * ((v / u) / -u);
	else
		tmp = v / -t1;
	end
	tmp_2 = tmp;
end
code[u_, v_, t1_] := If[Or[LessEqual[u, -1.56e-9], N[Not[LessEqual[u, 6.2e-52]], $MachinePrecision]], N[(t1 * N[(N[(v / u), $MachinePrecision] / (-u)), $MachinePrecision]), $MachinePrecision], N[(v / (-t1)), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;u \leq -1.56 \cdot 10^{-9} \lor \neg \left(u \leq 6.2 \cdot 10^{-52}\right):\\
\;\;\;\;t1 \cdot \frac{\frac{v}{u}}{-u}\\

\mathbf{else}:\\
\;\;\;\;\frac{v}{-t1}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if u < -1.56e-9 or 6.1999999999999998e-52 < u

    1. Initial program 76.3%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. associate-/l*75.7%

        \[\leadsto \color{blue}{\left(-t1\right) \cdot \frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      2. distribute-lft-neg-out75.7%

        \[\leadsto \color{blue}{-t1 \cdot \frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      3. distribute-rgt-neg-in75.7%

        \[\leadsto \color{blue}{t1 \cdot \left(-\frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}\right)} \]
      4. associate-/r*89.1%

        \[\leadsto t1 \cdot \left(-\color{blue}{\frac{\frac{v}{t1 + u}}{t1 + u}}\right) \]
      5. distribute-neg-frac289.1%

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

      \[\leadsto \color{blue}{t1 \cdot \frac{\frac{v}{t1 + u}}{-\left(t1 + u\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in t1 around 0 80.6%

      \[\leadsto t1 \cdot \frac{\frac{v}{t1 + u}}{-\color{blue}{u}} \]
    6. Taylor expanded in t1 around 0 78.6%

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

    if -1.56e-9 < u < 6.1999999999999998e-52

    1. Initial program 64.5%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. times-frac98.4%

        \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
      2. distribute-frac-neg98.4%

        \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
      3. distribute-neg-frac298.4%

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

        \[\leadsto \frac{t1}{-\color{blue}{\left(u + t1\right)}} \cdot \frac{v}{t1 + u} \]
      5. distribute-neg-in98.4%

        \[\leadsto \frac{t1}{\color{blue}{\left(-u\right) + \left(-t1\right)}} \cdot \frac{v}{t1 + u} \]
      6. unsub-neg98.4%

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{v}{t1}} \]
    6. Step-by-step derivation
      1. associate-*r/81.3%

        \[\leadsto \color{blue}{\frac{-1 \cdot v}{t1}} \]
      2. neg-mul-181.3%

        \[\leadsto \frac{\color{blue}{-v}}{t1} \]
    7. Simplified81.3%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;u \leq -1.56 \cdot 10^{-9} \lor \neg \left(u \leq 6.2 \cdot 10^{-52}\right):\\ \;\;\;\;t1 \cdot \frac{\frac{v}{u}}{-u}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{-t1}\\ \end{array} \]
  5. Add Preprocessing

Alternative 10: 68.6% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;u \leq -3.2 \cdot 10^{+63} \lor \neg \left(u \leq 1.35 \cdot 10^{+59}\right):\\ \;\;\;\;t1 \cdot \frac{\frac{v}{u}}{u}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{-t1}\\ \end{array} \end{array} \]
(FPCore (u v t1)
 :precision binary64
 (if (or (<= u -3.2e+63) (not (<= u 1.35e+59)))
   (* t1 (/ (/ v u) u))
   (/ v (- t1))))
double code(double u, double v, double t1) {
	double tmp;
	if ((u <= -3.2e+63) || !(u <= 1.35e+59)) {
		tmp = t1 * ((v / u) / 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 <= (-3.2d+63)) .or. (.not. (u <= 1.35d+59))) then
        tmp = t1 * ((v / u) / 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 <= -3.2e+63) || !(u <= 1.35e+59)) {
		tmp = t1 * ((v / u) / u);
	} else {
		tmp = v / -t1;
	}
	return tmp;
}
def code(u, v, t1):
	tmp = 0
	if (u <= -3.2e+63) or not (u <= 1.35e+59):
		tmp = t1 * ((v / u) / u)
	else:
		tmp = v / -t1
	return tmp
function code(u, v, t1)
	tmp = 0.0
	if ((u <= -3.2e+63) || !(u <= 1.35e+59))
		tmp = Float64(t1 * Float64(Float64(v / u) / u));
	else
		tmp = Float64(v / Float64(-t1));
	end
	return tmp
end
function tmp_2 = code(u, v, t1)
	tmp = 0.0;
	if ((u <= -3.2e+63) || ~((u <= 1.35e+59)))
		tmp = t1 * ((v / u) / u);
	else
		tmp = v / -t1;
	end
	tmp_2 = tmp;
end
code[u_, v_, t1_] := If[Or[LessEqual[u, -3.2e+63], N[Not[LessEqual[u, 1.35e+59]], $MachinePrecision]], N[(t1 * N[(N[(v / u), $MachinePrecision] / u), $MachinePrecision]), $MachinePrecision], N[(v / (-t1)), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;u \leq -3.2 \cdot 10^{+63} \lor \neg \left(u \leq 1.35 \cdot 10^{+59}\right):\\
\;\;\;\;t1 \cdot \frac{\frac{v}{u}}{u}\\

\mathbf{else}:\\
\;\;\;\;\frac{v}{-t1}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if u < -3.20000000000000011e63 or 1.3500000000000001e59 < u

    1. Initial program 76.4%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. associate-/l*75.9%

        \[\leadsto \color{blue}{\left(-t1\right) \cdot \frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      2. distribute-lft-neg-out75.9%

        \[\leadsto \color{blue}{-t1 \cdot \frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      3. distribute-rgt-neg-in75.9%

        \[\leadsto \color{blue}{t1 \cdot \left(-\frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}\right)} \]
      4. associate-/r*91.3%

        \[\leadsto t1 \cdot \left(-\color{blue}{\frac{\frac{v}{t1 + u}}{t1 + u}}\right) \]
      5. distribute-neg-frac291.3%

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

      \[\leadsto \color{blue}{t1 \cdot \frac{\frac{v}{t1 + u}}{-\left(t1 + u\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in t1 around 0 83.6%

      \[\leadsto t1 \cdot \frac{\frac{v}{t1 + u}}{-\color{blue}{u}} \]
    6. Taylor expanded in t1 around 0 83.1%

      \[\leadsto t1 \cdot \frac{\frac{v}{\color{blue}{u}}}{-u} \]
    7. Step-by-step derivation
      1. associate-*r/86.2%

        \[\leadsto \color{blue}{\frac{t1 \cdot \frac{v}{u}}{-u}} \]
      2. add-sqr-sqrt45.0%

        \[\leadsto \frac{t1 \cdot \frac{v}{u}}{\color{blue}{\sqrt{-u} \cdot \sqrt{-u}}} \]
      3. sqrt-unprod69.6%

        \[\leadsto \frac{t1 \cdot \frac{v}{u}}{\color{blue}{\sqrt{\left(-u\right) \cdot \left(-u\right)}}} \]
      4. sqr-neg69.6%

        \[\leadsto \frac{t1 \cdot \frac{v}{u}}{\sqrt{\color{blue}{u \cdot u}}} \]
      5. sqrt-unprod28.6%

        \[\leadsto \frac{t1 \cdot \frac{v}{u}}{\color{blue}{\sqrt{u} \cdot \sqrt{u}}} \]
      6. add-sqr-sqrt62.5%

        \[\leadsto \frac{t1 \cdot \frac{v}{u}}{\color{blue}{u}} \]
    8. Applied egg-rr62.5%

      \[\leadsto \color{blue}{\frac{t1 \cdot \frac{v}{u}}{u}} \]
    9. Step-by-step derivation
      1. associate-/l*64.0%

        \[\leadsto \color{blue}{t1 \cdot \frac{\frac{v}{u}}{u}} \]
    10. Simplified64.0%

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

    if -3.20000000000000011e63 < u < 1.3500000000000001e59

    1. Initial program 66.2%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. times-frac98.0%

        \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
      2. distribute-frac-neg98.0%

        \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
      3. distribute-neg-frac298.0%

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

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

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

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{v}{t1}} \]
    6. Step-by-step derivation
      1. associate-*r/75.3%

        \[\leadsto \color{blue}{\frac{-1 \cdot v}{t1}} \]
      2. neg-mul-175.3%

        \[\leadsto \frac{\color{blue}{-v}}{t1} \]
    7. Simplified75.3%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;u \leq -3.2 \cdot 10^{+63} \lor \neg \left(u \leq 1.35 \cdot 10^{+59}\right):\\ \;\;\;\;t1 \cdot \frac{\frac{v}{u}}{u}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{-t1}\\ \end{array} \]
  5. Add Preprocessing

Alternative 11: 68.6% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;u \leq -6.8 \cdot 10^{+56}:\\ \;\;\;\;\frac{t1}{u \cdot \frac{u}{v}}\\ \mathbf{elif}\;u \leq 9.4 \cdot 10^{+58}:\\ \;\;\;\;\frac{v}{-t1}\\ \mathbf{else}:\\ \;\;\;\;t1 \cdot \frac{\frac{v}{u}}{u}\\ \end{array} \end{array} \]
(FPCore (u v t1)
 :precision binary64
 (if (<= u -6.8e+56)
   (/ t1 (* u (/ u v)))
   (if (<= u 9.4e+58) (/ v (- t1)) (* t1 (/ (/ v u) u)))))
double code(double u, double v, double t1) {
	double tmp;
	if (u <= -6.8e+56) {
		tmp = t1 / (u * (u / v));
	} else if (u <= 9.4e+58) {
		tmp = v / -t1;
	} else {
		tmp = t1 * ((v / u) / u);
	}
	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 <= (-6.8d+56)) then
        tmp = t1 / (u * (u / v))
    else if (u <= 9.4d+58) then
        tmp = v / -t1
    else
        tmp = t1 * ((v / u) / u)
    end if
    code = tmp
end function
public static double code(double u, double v, double t1) {
	double tmp;
	if (u <= -6.8e+56) {
		tmp = t1 / (u * (u / v));
	} else if (u <= 9.4e+58) {
		tmp = v / -t1;
	} else {
		tmp = t1 * ((v / u) / u);
	}
	return tmp;
}
def code(u, v, t1):
	tmp = 0
	if u <= -6.8e+56:
		tmp = t1 / (u * (u / v))
	elif u <= 9.4e+58:
		tmp = v / -t1
	else:
		tmp = t1 * ((v / u) / u)
	return tmp
function code(u, v, t1)
	tmp = 0.0
	if (u <= -6.8e+56)
		tmp = Float64(t1 / Float64(u * Float64(u / v)));
	elseif (u <= 9.4e+58)
		tmp = Float64(v / Float64(-t1));
	else
		tmp = Float64(t1 * Float64(Float64(v / u) / u));
	end
	return tmp
end
function tmp_2 = code(u, v, t1)
	tmp = 0.0;
	if (u <= -6.8e+56)
		tmp = t1 / (u * (u / v));
	elseif (u <= 9.4e+58)
		tmp = v / -t1;
	else
		tmp = t1 * ((v / u) / u);
	end
	tmp_2 = tmp;
end
code[u_, v_, t1_] := If[LessEqual[u, -6.8e+56], N[(t1 / N[(u * N[(u / v), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[u, 9.4e+58], N[(v / (-t1)), $MachinePrecision], N[(t1 * N[(N[(v / u), $MachinePrecision] / u), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;u \leq -6.8 \cdot 10^{+56}:\\
\;\;\;\;\frac{t1}{u \cdot \frac{u}{v}}\\

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

\mathbf{else}:\\
\;\;\;\;t1 \cdot \frac{\frac{v}{u}}{u}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if u < -6.80000000000000002e56

    1. Initial program 79.9%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. associate-/l*78.3%

        \[\leadsto \color{blue}{\left(-t1\right) \cdot \frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      2. distribute-lft-neg-out78.3%

        \[\leadsto \color{blue}{-t1 \cdot \frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      3. distribute-rgt-neg-in78.3%

        \[\leadsto \color{blue}{t1 \cdot \left(-\frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}\right)} \]
      4. associate-/r*92.4%

        \[\leadsto t1 \cdot \left(-\color{blue}{\frac{\frac{v}{t1 + u}}{t1 + u}}\right) \]
      5. distribute-neg-frac292.4%

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

      \[\leadsto \color{blue}{t1 \cdot \frac{\frac{v}{t1 + u}}{-\left(t1 + u\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in t1 around 0 84.7%

      \[\leadsto t1 \cdot \frac{\frac{v}{t1 + u}}{-\color{blue}{u}} \]
    6. Taylor expanded in t1 around 0 83.7%

      \[\leadsto t1 \cdot \frac{\frac{v}{\color{blue}{u}}}{-u} \]
    7. Step-by-step derivation
      1. clear-num85.0%

        \[\leadsto t1 \cdot \color{blue}{\frac{1}{\frac{-u}{\frac{v}{u}}}} \]
      2. un-div-inv85.0%

        \[\leadsto \color{blue}{\frac{t1}{\frac{-u}{\frac{v}{u}}}} \]
      3. div-inv85.0%

        \[\leadsto \frac{t1}{\color{blue}{\left(-u\right) \cdot \frac{1}{\frac{v}{u}}}} \]
      4. clear-num85.0%

        \[\leadsto \frac{t1}{\left(-u\right) \cdot \color{blue}{\frac{u}{v}}} \]
      5. add-sqr-sqrt85.0%

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

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

        \[\leadsto \frac{t1}{\sqrt{\color{blue}{u \cdot u}} \cdot \frac{u}{v}} \]
      8. sqrt-unprod0.0%

        \[\leadsto \frac{t1}{\color{blue}{\left(\sqrt{u} \cdot \sqrt{u}\right)} \cdot \frac{u}{v}} \]
      9. add-sqr-sqrt67.4%

        \[\leadsto \frac{t1}{\color{blue}{u} \cdot \frac{u}{v}} \]
    8. Applied egg-rr67.4%

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

    if -6.80000000000000002e56 < u < 9.39999999999999944e58

    1. Initial program 66.2%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. times-frac98.0%

        \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
      2. distribute-frac-neg98.0%

        \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
      3. distribute-neg-frac298.0%

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

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

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

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{v}{t1}} \]
    6. Step-by-step derivation
      1. associate-*r/75.3%

        \[\leadsto \color{blue}{\frac{-1 \cdot v}{t1}} \]
      2. neg-mul-175.3%

        \[\leadsto \frac{\color{blue}{-v}}{t1} \]
    7. Simplified75.3%

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

    if 9.39999999999999944e58 < u

    1. Initial program 72.8%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. associate-/l*73.3%

        \[\leadsto \color{blue}{\left(-t1\right) \cdot \frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      2. distribute-lft-neg-out73.3%

        \[\leadsto \color{blue}{-t1 \cdot \frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      3. distribute-rgt-neg-in73.3%

        \[\leadsto \color{blue}{t1 \cdot \left(-\frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}\right)} \]
      4. associate-/r*90.2%

        \[\leadsto t1 \cdot \left(-\color{blue}{\frac{\frac{v}{t1 + u}}{t1 + u}}\right) \]
      5. distribute-neg-frac290.2%

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

      \[\leadsto \color{blue}{t1 \cdot \frac{\frac{v}{t1 + u}}{-\left(t1 + u\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in t1 around 0 82.4%

      \[\leadsto t1 \cdot \frac{\frac{v}{t1 + u}}{-\color{blue}{u}} \]
    6. Taylor expanded in t1 around 0 82.4%

      \[\leadsto t1 \cdot \frac{\frac{v}{\color{blue}{u}}}{-u} \]
    7. Step-by-step derivation
      1. associate-*r/84.8%

        \[\leadsto \color{blue}{\frac{t1 \cdot \frac{v}{u}}{-u}} \]
      2. add-sqr-sqrt0.0%

        \[\leadsto \frac{t1 \cdot \frac{v}{u}}{\color{blue}{\sqrt{-u} \cdot \sqrt{-u}}} \]
      3. sqrt-unprod61.8%

        \[\leadsto \frac{t1 \cdot \frac{v}{u}}{\color{blue}{\sqrt{\left(-u\right) \cdot \left(-u\right)}}} \]
      4. sqr-neg61.8%

        \[\leadsto \frac{t1 \cdot \frac{v}{u}}{\sqrt{\color{blue}{u \cdot u}}} \]
      5. sqrt-unprod58.9%

        \[\leadsto \frac{t1 \cdot \frac{v}{u}}{\color{blue}{\sqrt{u} \cdot \sqrt{u}}} \]
      6. add-sqr-sqrt58.9%

        \[\leadsto \frac{t1 \cdot \frac{v}{u}}{\color{blue}{u}} \]
    8. Applied egg-rr58.9%

      \[\leadsto \color{blue}{\frac{t1 \cdot \frac{v}{u}}{u}} \]
    9. Step-by-step derivation
      1. associate-/l*61.8%

        \[\leadsto \color{blue}{t1 \cdot \frac{\frac{v}{u}}{u}} \]
    10. Simplified61.8%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;u \leq -6.8 \cdot 10^{+56}:\\ \;\;\;\;\frac{t1}{u \cdot \frac{u}{v}}\\ \mathbf{elif}\;u \leq 9.4 \cdot 10^{+58}:\\ \;\;\;\;\frac{v}{-t1}\\ \mathbf{else}:\\ \;\;\;\;t1 \cdot \frac{\frac{v}{u}}{u}\\ \end{array} \]
  5. Add Preprocessing

Alternative 12: 58.6% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;u \leq -1.22 \cdot 10^{+91}:\\ \;\;\;\;\frac{v}{u}\\ \mathbf{elif}\;u \leq 9.5 \cdot 10^{+160}:\\ \;\;\;\;\frac{v}{-t1}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{u + t1}\\ \end{array} \end{array} \]
(FPCore (u v t1)
 :precision binary64
 (if (<= u -1.22e+91)
   (/ v u)
   (if (<= u 9.5e+160) (/ v (- t1)) (/ v (+ u t1)))))
double code(double u, double v, double t1) {
	double tmp;
	if (u <= -1.22e+91) {
		tmp = v / u;
	} else if (u <= 9.5e+160) {
		tmp = v / -t1;
	} else {
		tmp = v / (u + 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.22d+91)) then
        tmp = v / u
    else if (u <= 9.5d+160) then
        tmp = v / -t1
    else
        tmp = v / (u + t1)
    end if
    code = tmp
end function
public static double code(double u, double v, double t1) {
	double tmp;
	if (u <= -1.22e+91) {
		tmp = v / u;
	} else if (u <= 9.5e+160) {
		tmp = v / -t1;
	} else {
		tmp = v / (u + t1);
	}
	return tmp;
}
def code(u, v, t1):
	tmp = 0
	if u <= -1.22e+91:
		tmp = v / u
	elif u <= 9.5e+160:
		tmp = v / -t1
	else:
		tmp = v / (u + t1)
	return tmp
function code(u, v, t1)
	tmp = 0.0
	if (u <= -1.22e+91)
		tmp = Float64(v / u);
	elseif (u <= 9.5e+160)
		tmp = Float64(v / Float64(-t1));
	else
		tmp = Float64(v / Float64(u + t1));
	end
	return tmp
end
function tmp_2 = code(u, v, t1)
	tmp = 0.0;
	if (u <= -1.22e+91)
		tmp = v / u;
	elseif (u <= 9.5e+160)
		tmp = v / -t1;
	else
		tmp = v / (u + t1);
	end
	tmp_2 = tmp;
end
code[u_, v_, t1_] := If[LessEqual[u, -1.22e+91], N[(v / u), $MachinePrecision], If[LessEqual[u, 9.5e+160], N[(v / (-t1)), $MachinePrecision], N[(v / N[(u + t1), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;u \leq -1.22 \cdot 10^{+91}:\\
\;\;\;\;\frac{v}{u}\\

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

\mathbf{else}:\\
\;\;\;\;\frac{v}{u + t1}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if u < -1.2199999999999999e91

    1. Initial program 78.3%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. associate-/l*77.1%

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

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

      \[\leadsto \left(-t1\right) \cdot \frac{v}{\left(t1 + u\right) \cdot \color{blue}{t1}} \]
    6. Step-by-step derivation
      1. associate-*r/32.9%

        \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot t1}} \]
      2. *-commutative32.9%

        \[\leadsto \frac{\left(-t1\right) \cdot v}{\color{blue}{t1 \cdot \left(t1 + u\right)}} \]
      3. times-frac38.7%

        \[\leadsto \color{blue}{\frac{-t1}{t1} \cdot \frac{v}{t1 + u}} \]
      4. add-sqr-sqrt16.6%

        \[\leadsto \frac{\color{blue}{\sqrt{-t1} \cdot \sqrt{-t1}}}{t1} \cdot \frac{v}{t1 + u} \]
      5. sqrt-unprod44.6%

        \[\leadsto \frac{\color{blue}{\sqrt{\left(-t1\right) \cdot \left(-t1\right)}}}{t1} \cdot \frac{v}{t1 + u} \]
      6. sqr-neg44.6%

        \[\leadsto \frac{\sqrt{\color{blue}{t1 \cdot t1}}}{t1} \cdot \frac{v}{t1 + u} \]
      7. sqrt-unprod15.9%

        \[\leadsto \frac{\color{blue}{\sqrt{t1} \cdot \sqrt{t1}}}{t1} \cdot \frac{v}{t1 + u} \]
      8. add-sqr-sqrt32.1%

        \[\leadsto \frac{\color{blue}{t1}}{t1} \cdot \frac{v}{t1 + u} \]
      9. *-inverses32.1%

        \[\leadsto \color{blue}{1} \cdot \frac{v}{t1 + u} \]
      10. *-un-lft-identity32.1%

        \[\leadsto \color{blue}{\frac{v}{t1 + u}} \]
      11. clear-num32.1%

        \[\leadsto \color{blue}{\frac{1}{\frac{t1 + u}{v}}} \]
    7. Applied egg-rr32.1%

      \[\leadsto \color{blue}{\frac{1}{\frac{t1 + u}{v}}} \]
    8. Step-by-step derivation
      1. associate-/r/32.1%

        \[\leadsto \color{blue}{\frac{1}{t1 + u} \cdot v} \]
    9. Simplified32.1%

      \[\leadsto \color{blue}{\frac{1}{t1 + u} \cdot v} \]
    10. Taylor expanded in t1 around 0 32.7%

      \[\leadsto \color{blue}{\frac{v}{u}} \]

    if -1.2199999999999999e91 < u < 9.5000000000000006e160

    1. Initial program 68.0%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. times-frac98.3%

        \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
      2. distribute-frac-neg98.3%

        \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
      3. distribute-neg-frac298.3%

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

        \[\leadsto \frac{t1}{-\color{blue}{\left(u + t1\right)}} \cdot \frac{v}{t1 + u} \]
      5. distribute-neg-in98.3%

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

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{v}{t1}} \]
    6. Step-by-step derivation
      1. associate-*r/68.2%

        \[\leadsto \color{blue}{\frac{-1 \cdot v}{t1}} \]
      2. neg-mul-168.2%

        \[\leadsto \frac{\color{blue}{-v}}{t1} \]
    7. Simplified68.2%

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

    if 9.5000000000000006e160 < u

    1. Initial program 71.8%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. associate-/l*72.4%

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

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

      \[\leadsto \left(-t1\right) \cdot \frac{v}{\left(t1 + u\right) \cdot \color{blue}{t1}} \]
    6. Step-by-step derivation
      1. associate-*r/44.8%

        \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot t1}} \]
      2. *-commutative44.8%

        \[\leadsto \frac{\left(-t1\right) \cdot v}{\color{blue}{t1 \cdot \left(t1 + u\right)}} \]
      3. times-frac46.7%

        \[\leadsto \color{blue}{\frac{-t1}{t1} \cdot \frac{v}{t1 + u}} \]
      4. add-sqr-sqrt29.3%

        \[\leadsto \frac{\color{blue}{\sqrt{-t1} \cdot \sqrt{-t1}}}{t1} \cdot \frac{v}{t1 + u} \]
      5. sqrt-unprod49.2%

        \[\leadsto \frac{\color{blue}{\sqrt{\left(-t1\right) \cdot \left(-t1\right)}}}{t1} \cdot \frac{v}{t1 + u} \]
      6. sqr-neg49.2%

        \[\leadsto \frac{\sqrt{\color{blue}{t1 \cdot t1}}}{t1} \cdot \frac{v}{t1 + u} \]
      7. sqrt-unprod14.6%

        \[\leadsto \frac{\color{blue}{\sqrt{t1} \cdot \sqrt{t1}}}{t1} \cdot \frac{v}{t1 + u} \]
      8. add-sqr-sqrt44.2%

        \[\leadsto \frac{\color{blue}{t1}}{t1} \cdot \frac{v}{t1 + u} \]
      9. *-inverses44.2%

        \[\leadsto \color{blue}{1} \cdot \frac{v}{t1 + u} \]
      10. *-un-lft-identity44.2%

        \[\leadsto \color{blue}{\frac{v}{t1 + u}} \]
    7. Applied egg-rr44.2%

      \[\leadsto \color{blue}{\frac{v}{t1 + u}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification58.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;u \leq -1.22 \cdot 10^{+91}:\\ \;\;\;\;\frac{v}{u}\\ \mathbf{elif}\;u \leq 9.5 \cdot 10^{+160}:\\ \;\;\;\;\frac{v}{-t1}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{u + t1}\\ \end{array} \]
  5. Add Preprocessing

Alternative 13: 58.5% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;u \leq -1.2 \cdot 10^{+91} \lor \neg \left(u \leq 7.2 \cdot 10^{+164}\right):\\ \;\;\;\;\frac{v}{u}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{-t1}\\ \end{array} \end{array} \]
(FPCore (u v t1)
 :precision binary64
 (if (or (<= u -1.2e+91) (not (<= u 7.2e+164))) (/ v u) (/ v (- t1))))
double code(double u, double v, double t1) {
	double tmp;
	if ((u <= -1.2e+91) || !(u <= 7.2e+164)) {
		tmp = v / 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.2d+91)) .or. (.not. (u <= 7.2d+164))) then
        tmp = v / 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.2e+91) || !(u <= 7.2e+164)) {
		tmp = v / u;
	} else {
		tmp = v / -t1;
	}
	return tmp;
}
def code(u, v, t1):
	tmp = 0
	if (u <= -1.2e+91) or not (u <= 7.2e+164):
		tmp = v / u
	else:
		tmp = v / -t1
	return tmp
function code(u, v, t1)
	tmp = 0.0
	if ((u <= -1.2e+91) || !(u <= 7.2e+164))
		tmp = Float64(v / u);
	else
		tmp = Float64(v / Float64(-t1));
	end
	return tmp
end
function tmp_2 = code(u, v, t1)
	tmp = 0.0;
	if ((u <= -1.2e+91) || ~((u <= 7.2e+164)))
		tmp = v / u;
	else
		tmp = v / -t1;
	end
	tmp_2 = tmp;
end
code[u_, v_, t1_] := If[Or[LessEqual[u, -1.2e+91], N[Not[LessEqual[u, 7.2e+164]], $MachinePrecision]], N[(v / u), $MachinePrecision], N[(v / (-t1)), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;u \leq -1.2 \cdot 10^{+91} \lor \neg \left(u \leq 7.2 \cdot 10^{+164}\right):\\
\;\;\;\;\frac{v}{u}\\

\mathbf{else}:\\
\;\;\;\;\frac{v}{-t1}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if u < -1.19999999999999991e91 or 7.19999999999999981e164 < u

    1. Initial program 76.1%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. associate-/l*75.5%

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

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

      \[\leadsto \left(-t1\right) \cdot \frac{v}{\left(t1 + u\right) \cdot \color{blue}{t1}} \]
    6. Step-by-step derivation
      1. associate-*r/36.9%

        \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot t1}} \]
      2. *-commutative36.9%

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

        \[\leadsto \color{blue}{\frac{-t1}{t1} \cdot \frac{v}{t1 + u}} \]
      4. add-sqr-sqrt20.8%

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

        \[\leadsto \frac{\color{blue}{\sqrt{\left(-t1\right) \cdot \left(-t1\right)}}}{t1} \cdot \frac{v}{t1 + u} \]
      6. sqr-neg46.1%

        \[\leadsto \frac{\sqrt{\color{blue}{t1 \cdot t1}}}{t1} \cdot \frac{v}{t1 + u} \]
      7. sqrt-unprod15.5%

        \[\leadsto \frac{\color{blue}{\sqrt{t1} \cdot \sqrt{t1}}}{t1} \cdot \frac{v}{t1 + u} \]
      8. add-sqr-sqrt36.1%

        \[\leadsto \frac{\color{blue}{t1}}{t1} \cdot \frac{v}{t1 + u} \]
      9. *-inverses36.1%

        \[\leadsto \color{blue}{1} \cdot \frac{v}{t1 + u} \]
      10. *-un-lft-identity36.1%

        \[\leadsto \color{blue}{\frac{v}{t1 + u}} \]
      11. clear-num36.1%

        \[\leadsto \color{blue}{\frac{1}{\frac{t1 + u}{v}}} \]
    7. Applied egg-rr36.1%

      \[\leadsto \color{blue}{\frac{1}{\frac{t1 + u}{v}}} \]
    8. Step-by-step derivation
      1. associate-/r/36.1%

        \[\leadsto \color{blue}{\frac{1}{t1 + u} \cdot v} \]
    9. Simplified36.1%

      \[\leadsto \color{blue}{\frac{1}{t1 + u} \cdot v} \]
    10. Taylor expanded in t1 around 0 34.8%

      \[\leadsto \color{blue}{\frac{v}{u}} \]

    if -1.19999999999999991e91 < u < 7.19999999999999981e164

    1. Initial program 68.0%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. times-frac98.3%

        \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
      2. distribute-frac-neg98.3%

        \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
      3. distribute-neg-frac298.3%

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

        \[\leadsto \frac{t1}{-\color{blue}{\left(u + t1\right)}} \cdot \frac{v}{t1 + u} \]
      5. distribute-neg-in98.3%

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

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{v}{t1}} \]
    6. Step-by-step derivation
      1. associate-*r/68.2%

        \[\leadsto \color{blue}{\frac{-1 \cdot v}{t1}} \]
      2. neg-mul-168.2%

        \[\leadsto \frac{\color{blue}{-v}}{t1} \]
    7. Simplified68.2%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;u \leq -1.2 \cdot 10^{+91} \lor \neg \left(u \leq 7.2 \cdot 10^{+164}\right):\\ \;\;\;\;\frac{v}{u}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{-t1}\\ \end{array} \]
  5. Add Preprocessing

Alternative 14: 58.5% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;u \leq -1.22 \cdot 10^{+91}:\\ \;\;\;\;\frac{v}{u}\\ \mathbf{elif}\;u \leq 9.2 \cdot 10^{+149}:\\ \;\;\;\;\frac{v}{-t1}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{-u}\\ \end{array} \end{array} \]
(FPCore (u v t1)
 :precision binary64
 (if (<= u -1.22e+91) (/ v u) (if (<= u 9.2e+149) (/ v (- t1)) (/ v (- u)))))
double code(double u, double v, double t1) {
	double tmp;
	if (u <= -1.22e+91) {
		tmp = v / u;
	} else if (u <= 9.2e+149) {
		tmp = v / -t1;
	} else {
		tmp = v / -u;
	}
	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.22d+91)) then
        tmp = v / u
    else if (u <= 9.2d+149) then
        tmp = v / -t1
    else
        tmp = v / -u
    end if
    code = tmp
end function
public static double code(double u, double v, double t1) {
	double tmp;
	if (u <= -1.22e+91) {
		tmp = v / u;
	} else if (u <= 9.2e+149) {
		tmp = v / -t1;
	} else {
		tmp = v / -u;
	}
	return tmp;
}
def code(u, v, t1):
	tmp = 0
	if u <= -1.22e+91:
		tmp = v / u
	elif u <= 9.2e+149:
		tmp = v / -t1
	else:
		tmp = v / -u
	return tmp
function code(u, v, t1)
	tmp = 0.0
	if (u <= -1.22e+91)
		tmp = Float64(v / u);
	elseif (u <= 9.2e+149)
		tmp = Float64(v / Float64(-t1));
	else
		tmp = Float64(v / Float64(-u));
	end
	return tmp
end
function tmp_2 = code(u, v, t1)
	tmp = 0.0;
	if (u <= -1.22e+91)
		tmp = v / u;
	elseif (u <= 9.2e+149)
		tmp = v / -t1;
	else
		tmp = v / -u;
	end
	tmp_2 = tmp;
end
code[u_, v_, t1_] := If[LessEqual[u, -1.22e+91], N[(v / u), $MachinePrecision], If[LessEqual[u, 9.2e+149], N[(v / (-t1)), $MachinePrecision], N[(v / (-u)), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;u \leq -1.22 \cdot 10^{+91}:\\
\;\;\;\;\frac{v}{u}\\

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

\mathbf{else}:\\
\;\;\;\;\frac{v}{-u}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if u < -1.2199999999999999e91

    1. Initial program 78.3%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. associate-/l*77.1%

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

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

      \[\leadsto \left(-t1\right) \cdot \frac{v}{\left(t1 + u\right) \cdot \color{blue}{t1}} \]
    6. Step-by-step derivation
      1. associate-*r/32.9%

        \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot t1}} \]
      2. *-commutative32.9%

        \[\leadsto \frac{\left(-t1\right) \cdot v}{\color{blue}{t1 \cdot \left(t1 + u\right)}} \]
      3. times-frac38.7%

        \[\leadsto \color{blue}{\frac{-t1}{t1} \cdot \frac{v}{t1 + u}} \]
      4. add-sqr-sqrt16.6%

        \[\leadsto \frac{\color{blue}{\sqrt{-t1} \cdot \sqrt{-t1}}}{t1} \cdot \frac{v}{t1 + u} \]
      5. sqrt-unprod44.6%

        \[\leadsto \frac{\color{blue}{\sqrt{\left(-t1\right) \cdot \left(-t1\right)}}}{t1} \cdot \frac{v}{t1 + u} \]
      6. sqr-neg44.6%

        \[\leadsto \frac{\sqrt{\color{blue}{t1 \cdot t1}}}{t1} \cdot \frac{v}{t1 + u} \]
      7. sqrt-unprod15.9%

        \[\leadsto \frac{\color{blue}{\sqrt{t1} \cdot \sqrt{t1}}}{t1} \cdot \frac{v}{t1 + u} \]
      8. add-sqr-sqrt32.1%

        \[\leadsto \frac{\color{blue}{t1}}{t1} \cdot \frac{v}{t1 + u} \]
      9. *-inverses32.1%

        \[\leadsto \color{blue}{1} \cdot \frac{v}{t1 + u} \]
      10. *-un-lft-identity32.1%

        \[\leadsto \color{blue}{\frac{v}{t1 + u}} \]
      11. clear-num32.1%

        \[\leadsto \color{blue}{\frac{1}{\frac{t1 + u}{v}}} \]
    7. Applied egg-rr32.1%

      \[\leadsto \color{blue}{\frac{1}{\frac{t1 + u}{v}}} \]
    8. Step-by-step derivation
      1. associate-/r/32.1%

        \[\leadsto \color{blue}{\frac{1}{t1 + u} \cdot v} \]
    9. Simplified32.1%

      \[\leadsto \color{blue}{\frac{1}{t1 + u} \cdot v} \]
    10. Taylor expanded in t1 around 0 32.7%

      \[\leadsto \color{blue}{\frac{v}{u}} \]

    if -1.2199999999999999e91 < u < 9.1999999999999993e149

    1. Initial program 68.4%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. times-frac98.3%

        \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
      2. distribute-frac-neg98.3%

        \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
      3. distribute-neg-frac298.3%

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

        \[\leadsto \frac{t1}{-\color{blue}{\left(u + t1\right)}} \cdot \frac{v}{t1 + u} \]
      5. distribute-neg-in98.3%

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

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{v}{t1}} \]
    6. Step-by-step derivation
      1. associate-*r/69.6%

        \[\leadsto \color{blue}{\frac{-1 \cdot v}{t1}} \]
      2. neg-mul-169.6%

        \[\leadsto \frac{\color{blue}{-v}}{t1} \]
    7. Simplified69.6%

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

    if 9.1999999999999993e149 < u

    1. Initial program 68.9%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. associate-/l*69.6%

        \[\leadsto \color{blue}{\left(-t1\right) \cdot \frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      2. distribute-lft-neg-out69.6%

        \[\leadsto \color{blue}{-t1 \cdot \frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}} \]
      3. distribute-rgt-neg-in69.6%

        \[\leadsto \color{blue}{t1 \cdot \left(-\frac{v}{\left(t1 + u\right) \cdot \left(t1 + u\right)}\right)} \]
      4. associate-/r*89.2%

        \[\leadsto t1 \cdot \left(-\color{blue}{\frac{\frac{v}{t1 + u}}{t1 + u}}\right) \]
      5. distribute-neg-frac289.2%

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

      \[\leadsto \color{blue}{t1 \cdot \frac{\frac{v}{t1 + u}}{-\left(t1 + u\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in t1 around 0 85.6%

      \[\leadsto t1 \cdot \frac{\frac{v}{t1 + u}}{-\color{blue}{u}} \]
    6. Taylor expanded in t1 around inf 34.9%

      \[\leadsto \color{blue}{-1 \cdot \frac{v}{u}} \]
    7. Step-by-step derivation
      1. associate-*r/34.9%

        \[\leadsto \color{blue}{\frac{-1 \cdot v}{u}} \]
      2. mul-1-neg34.9%

        \[\leadsto \frac{\color{blue}{-v}}{u} \]
    8. Simplified34.9%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;u \leq -1.22 \cdot 10^{+91}:\\ \;\;\;\;\frac{v}{u}\\ \mathbf{elif}\;u \leq 9.2 \cdot 10^{+149}:\\ \;\;\;\;\frac{v}{-t1}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{-u}\\ \end{array} \]
  5. Add Preprocessing

Alternative 15: 23.5% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t1 \leq -1.9 \cdot 10^{+130} \lor \neg \left(t1 \leq 2.5 \cdot 10^{+50}\right):\\ \;\;\;\;\frac{v}{t1}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{u}\\ \end{array} \end{array} \]
(FPCore (u v t1)
 :precision binary64
 (if (or (<= t1 -1.9e+130) (not (<= t1 2.5e+50))) (/ v t1) (/ v u)))
double code(double u, double v, double t1) {
	double tmp;
	if ((t1 <= -1.9e+130) || !(t1 <= 2.5e+50)) {
		tmp = v / t1;
	} else {
		tmp = v / u;
	}
	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 ((t1 <= (-1.9d+130)) .or. (.not. (t1 <= 2.5d+50))) then
        tmp = v / t1
    else
        tmp = v / u
    end if
    code = tmp
end function
public static double code(double u, double v, double t1) {
	double tmp;
	if ((t1 <= -1.9e+130) || !(t1 <= 2.5e+50)) {
		tmp = v / t1;
	} else {
		tmp = v / u;
	}
	return tmp;
}
def code(u, v, t1):
	tmp = 0
	if (t1 <= -1.9e+130) or not (t1 <= 2.5e+50):
		tmp = v / t1
	else:
		tmp = v / u
	return tmp
function code(u, v, t1)
	tmp = 0.0
	if ((t1 <= -1.9e+130) || !(t1 <= 2.5e+50))
		tmp = Float64(v / t1);
	else
		tmp = Float64(v / u);
	end
	return tmp
end
function tmp_2 = code(u, v, t1)
	tmp = 0.0;
	if ((t1 <= -1.9e+130) || ~((t1 <= 2.5e+50)))
		tmp = v / t1;
	else
		tmp = v / u;
	end
	tmp_2 = tmp;
end
code[u_, v_, t1_] := If[Or[LessEqual[t1, -1.9e+130], N[Not[LessEqual[t1, 2.5e+50]], $MachinePrecision]], N[(v / t1), $MachinePrecision], N[(v / u), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t1 \leq -1.9 \cdot 10^{+130} \lor \neg \left(t1 \leq 2.5 \cdot 10^{+50}\right):\\
\;\;\;\;\frac{v}{t1}\\

\mathbf{else}:\\
\;\;\;\;\frac{v}{u}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t1 < -1.9000000000000001e130 or 2.5e50 < t1

    1. Initial program 47.6%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. times-frac99.9%

        \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
      2. distribute-frac-neg99.9%

        \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
      3. distribute-neg-frac299.9%

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

        \[\leadsto \frac{t1}{-\color{blue}{\left(u + t1\right)}} \cdot \frac{v}{t1 + u} \]
      5. distribute-neg-in99.9%

        \[\leadsto \frac{t1}{\color{blue}{\left(-u\right) + \left(-t1\right)}} \cdot \frac{v}{t1 + u} \]
      6. unsub-neg99.9%

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{v}{t1}} \]
    6. Step-by-step derivation
      1. associate-*r/84.2%

        \[\leadsto \color{blue}{\frac{-1 \cdot v}{t1}} \]
      2. neg-mul-184.2%

        \[\leadsto \frac{\color{blue}{-v}}{t1} \]
    7. Simplified84.2%

      \[\leadsto \color{blue}{\frac{-v}{t1}} \]
    8. Step-by-step derivation
      1. add-sqr-sqrt39.4%

        \[\leadsto \frac{\color{blue}{\sqrt{-v} \cdot \sqrt{-v}}}{t1} \]
      2. sqrt-unprod50.5%

        \[\leadsto \frac{\color{blue}{\sqrt{\left(-v\right) \cdot \left(-v\right)}}}{t1} \]
      3. sqr-neg50.5%

        \[\leadsto \frac{\sqrt{\color{blue}{v \cdot v}}}{t1} \]
      4. sqrt-unprod16.4%

        \[\leadsto \frac{\color{blue}{\sqrt{v} \cdot \sqrt{v}}}{t1} \]
      5. add-sqr-sqrt33.6%

        \[\leadsto \frac{\color{blue}{v}}{t1} \]
      6. div-inv33.6%

        \[\leadsto \color{blue}{v \cdot \frac{1}{t1}} \]
    9. Applied egg-rr33.6%

      \[\leadsto \color{blue}{v \cdot \frac{1}{t1}} \]
    10. Step-by-step derivation
      1. associate-*r/33.6%

        \[\leadsto \color{blue}{\frac{v \cdot 1}{t1}} \]
      2. *-rgt-identity33.6%

        \[\leadsto \frac{\color{blue}{v}}{t1} \]
    11. Simplified33.6%

      \[\leadsto \color{blue}{\frac{v}{t1}} \]

    if -1.9000000000000001e130 < t1 < 2.5e50

    1. Initial program 82.6%

      \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
    2. Step-by-step derivation
      1. associate-/l*84.5%

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

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

      \[\leadsto \left(-t1\right) \cdot \frac{v}{\left(t1 + u\right) \cdot \color{blue}{t1}} \]
    6. Step-by-step derivation
      1. associate-*r/44.9%

        \[\leadsto \color{blue}{\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot t1}} \]
      2. *-commutative44.9%

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

        \[\leadsto \color{blue}{\frac{-t1}{t1} \cdot \frac{v}{t1 + u}} \]
      4. add-sqr-sqrt23.3%

        \[\leadsto \frac{\color{blue}{\sqrt{-t1} \cdot \sqrt{-t1}}}{t1} \cdot \frac{v}{t1 + u} \]
      5. sqrt-unprod42.7%

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

        \[\leadsto \frac{\sqrt{\color{blue}{t1 \cdot t1}}}{t1} \cdot \frac{v}{t1 + u} \]
      7. sqrt-unprod7.2%

        \[\leadsto \frac{\color{blue}{\sqrt{t1} \cdot \sqrt{t1}}}{t1} \cdot \frac{v}{t1 + u} \]
      8. add-sqr-sqrt15.3%

        \[\leadsto \frac{\color{blue}{t1}}{t1} \cdot \frac{v}{t1 + u} \]
      9. *-inverses15.3%

        \[\leadsto \color{blue}{1} \cdot \frac{v}{t1 + u} \]
      10. *-un-lft-identity15.3%

        \[\leadsto \color{blue}{\frac{v}{t1 + u}} \]
      11. clear-num15.3%

        \[\leadsto \color{blue}{\frac{1}{\frac{t1 + u}{v}}} \]
    7. Applied egg-rr15.3%

      \[\leadsto \color{blue}{\frac{1}{\frac{t1 + u}{v}}} \]
    8. Step-by-step derivation
      1. associate-/r/15.3%

        \[\leadsto \color{blue}{\frac{1}{t1 + u} \cdot v} \]
    9. Simplified15.3%

      \[\leadsto \color{blue}{\frac{1}{t1 + u} \cdot v} \]
    10. Taylor expanded in t1 around 0 17.9%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t1 \leq -1.9 \cdot 10^{+130} \lor \neg \left(t1 \leq 2.5 \cdot 10^{+50}\right):\\ \;\;\;\;\frac{v}{t1}\\ \mathbf{else}:\\ \;\;\;\;\frac{v}{u}\\ \end{array} \]
  5. Add Preprocessing

Alternative 16: 98.2% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \frac{v \cdot \frac{-t1}{u + t1}}{u + t1} \end{array} \]
(FPCore (u v t1) :precision binary64 (/ (* v (/ (- t1) (+ u t1))) (+ u t1)))
double code(double u, double v, double t1) {
	return (v * (-t1 / (u + t1))) / (u + 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 / (u + t1))) / (u + t1)
end function
public static double code(double u, double v, double t1) {
	return (v * (-t1 / (u + t1))) / (u + t1);
}
def code(u, v, t1):
	return (v * (-t1 / (u + t1))) / (u + t1)
function code(u, v, t1)
	return Float64(Float64(v * Float64(Float64(-t1) / Float64(u + t1))) / Float64(u + t1))
end
function tmp = code(u, v, t1)
	tmp = (v * (-t1 / (u + t1))) / (u + t1);
end
code[u_, v_, t1_] := N[(N[(v * N[((-t1) / N[(u + t1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(u + t1), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{v \cdot \frac{-t1}{u + t1}}{u + t1}
\end{array}
Derivation
  1. Initial program 70.4%

    \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
  2. Step-by-step derivation
    1. times-frac98.7%

      \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
    2. distribute-frac-neg98.7%

      \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
    3. distribute-neg-frac298.7%

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

      \[\leadsto \frac{t1}{-\color{blue}{\left(u + t1\right)}} \cdot \frac{v}{t1 + u} \]
    5. distribute-neg-in98.7%

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

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

    \[\leadsto \color{blue}{\frac{t1}{\left(-u\right) - t1} \cdot \frac{v}{t1 + u}} \]
  4. Add Preprocessing
  5. Step-by-step derivation
    1. frac-2neg98.7%

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

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

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

      \[\leadsto \frac{\left(-t1\right) \cdot \left(-v\right)}{\left(-\color{blue}{\left(\left(-u\right) + \left(-t1\right)\right)}\right) \cdot \left(-\left(t1 + u\right)\right)} \]
    5. distribute-neg-in70.4%

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

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

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

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

      \[\leadsto \color{blue}{\frac{\frac{-t1}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)}} \]
    10. add-sqr-sqrt48.2%

      \[\leadsto \frac{\frac{\color{blue}{\sqrt{-t1} \cdot \sqrt{-t1}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
    11. sqrt-unprod42.8%

      \[\leadsto \frac{\frac{\color{blue}{\sqrt{\left(-t1\right) \cdot \left(-t1\right)}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
    12. sqr-neg42.8%

      \[\leadsto \frac{\frac{\sqrt{\color{blue}{t1 \cdot t1}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
    13. sqrt-unprod17.0%

      \[\leadsto \frac{\frac{\color{blue}{\sqrt{t1} \cdot \sqrt{t1}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
    14. add-sqr-sqrt37.2%

      \[\leadsto \frac{\frac{\color{blue}{t1}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
    15. add-sqr-sqrt19.4%

      \[\leadsto \frac{\frac{t1}{t1 + u} \cdot \left(-v\right)}{\color{blue}{\sqrt{-\left(t1 + u\right)} \cdot \sqrt{-\left(t1 + u\right)}}} \]
    16. sqrt-unprod58.4%

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

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

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

Alternative 17: 97.9% accurate, 1.0× speedup?

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

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

    \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
  2. Step-by-step derivation
    1. times-frac98.7%

      \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
    2. distribute-frac-neg98.7%

      \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
    3. distribute-neg-frac298.7%

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

      \[\leadsto \frac{t1}{-\color{blue}{\left(u + t1\right)}} \cdot \frac{v}{t1 + u} \]
    5. distribute-neg-in98.7%

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

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

    \[\leadsto \color{blue}{\frac{t1}{\left(-u\right) - t1} \cdot \frac{v}{t1 + u}} \]
  4. Add Preprocessing
  5. Final simplification98.7%

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

Alternative 18: 62.0% accurate, 2.0× speedup?

\[\begin{array}{l} \\ \frac{v}{\left(-u\right) - t1} \end{array} \]
(FPCore (u v t1) :precision binary64 (/ v (- (- u) t1)))
double code(double u, double v, double t1) {
	return v / (-u - 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 / (-u - t1)
end function
public static double code(double u, double v, double t1) {
	return v / (-u - t1);
}
def code(u, v, t1):
	return v / (-u - t1)
function code(u, v, t1)
	return Float64(v / Float64(Float64(-u) - t1))
end
function tmp = code(u, v, t1)
	tmp = v / (-u - t1);
end
code[u_, v_, t1_] := N[(v / N[((-u) - t1), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

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

    \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
  2. Step-by-step derivation
    1. times-frac98.7%

      \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
    2. distribute-frac-neg98.7%

      \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
    3. distribute-neg-frac298.7%

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

      \[\leadsto \frac{t1}{-\color{blue}{\left(u + t1\right)}} \cdot \frac{v}{t1 + u} \]
    5. distribute-neg-in98.7%

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

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

    \[\leadsto \color{blue}{\frac{t1}{\left(-u\right) - t1} \cdot \frac{v}{t1 + u}} \]
  4. Add Preprocessing
  5. Step-by-step derivation
    1. frac-2neg98.7%

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

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

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

      \[\leadsto \frac{\left(-t1\right) \cdot \left(-v\right)}{\left(-\color{blue}{\left(\left(-u\right) + \left(-t1\right)\right)}\right) \cdot \left(-\left(t1 + u\right)\right)} \]
    5. distribute-neg-in70.4%

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

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

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

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

      \[\leadsto \color{blue}{\frac{\frac{-t1}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)}} \]
    10. add-sqr-sqrt48.2%

      \[\leadsto \frac{\frac{\color{blue}{\sqrt{-t1} \cdot \sqrt{-t1}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
    11. sqrt-unprod42.8%

      \[\leadsto \frac{\frac{\color{blue}{\sqrt{\left(-t1\right) \cdot \left(-t1\right)}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
    12. sqr-neg42.8%

      \[\leadsto \frac{\frac{\sqrt{\color{blue}{t1 \cdot t1}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
    13. sqrt-unprod17.0%

      \[\leadsto \frac{\frac{\color{blue}{\sqrt{t1} \cdot \sqrt{t1}}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
    14. add-sqr-sqrt37.2%

      \[\leadsto \frac{\frac{\color{blue}{t1}}{t1 + u} \cdot \left(-v\right)}{-\left(t1 + u\right)} \]
    15. add-sqr-sqrt19.4%

      \[\leadsto \frac{\frac{t1}{t1 + u} \cdot \left(-v\right)}{\color{blue}{\sqrt{-\left(t1 + u\right)} \cdot \sqrt{-\left(t1 + u\right)}}} \]
    16. sqrt-unprod58.4%

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

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

    \[\leadsto \frac{\color{blue}{-1 \cdot v}}{t1 + u} \]
  8. Step-by-step derivation
    1. mul-1-neg60.3%

      \[\leadsto \frac{\color{blue}{-v}}{t1 + u} \]
  9. Simplified60.3%

    \[\leadsto \frac{\color{blue}{-v}}{t1 + u} \]
  10. Final simplification60.3%

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

Alternative 19: 14.1% accurate, 4.0× 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(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 70.4%

    \[\frac{\left(-t1\right) \cdot v}{\left(t1 + u\right) \cdot \left(t1 + u\right)} \]
  2. Step-by-step derivation
    1. times-frac98.7%

      \[\leadsto \color{blue}{\frac{-t1}{t1 + u} \cdot \frac{v}{t1 + u}} \]
    2. distribute-frac-neg98.7%

      \[\leadsto \color{blue}{\left(-\frac{t1}{t1 + u}\right)} \cdot \frac{v}{t1 + u} \]
    3. distribute-neg-frac298.7%

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

      \[\leadsto \frac{t1}{-\color{blue}{\left(u + t1\right)}} \cdot \frac{v}{t1 + u} \]
    5. distribute-neg-in98.7%

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

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

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

    \[\leadsto \color{blue}{-1 \cdot \frac{v}{t1}} \]
  6. Step-by-step derivation
    1. associate-*r/52.7%

      \[\leadsto \color{blue}{\frac{-1 \cdot v}{t1}} \]
    2. neg-mul-152.7%

      \[\leadsto \frac{\color{blue}{-v}}{t1} \]
  7. Simplified52.7%

    \[\leadsto \color{blue}{\frac{-v}{t1}} \]
  8. Step-by-step derivation
    1. add-sqr-sqrt22.9%

      \[\leadsto \frac{\color{blue}{\sqrt{-v} \cdot \sqrt{-v}}}{t1} \]
    2. sqrt-unprod34.5%

      \[\leadsto \frac{\color{blue}{\sqrt{\left(-v\right) \cdot \left(-v\right)}}}{t1} \]
    3. sqr-neg34.5%

      \[\leadsto \frac{\sqrt{\color{blue}{v \cdot v}}}{t1} \]
    4. sqrt-unprod6.8%

      \[\leadsto \frac{\color{blue}{\sqrt{v} \cdot \sqrt{v}}}{t1} \]
    5. add-sqr-sqrt13.4%

      \[\leadsto \frac{\color{blue}{v}}{t1} \]
    6. div-inv13.4%

      \[\leadsto \color{blue}{v \cdot \frac{1}{t1}} \]
  9. Applied egg-rr13.4%

    \[\leadsto \color{blue}{v \cdot \frac{1}{t1}} \]
  10. Step-by-step derivation
    1. associate-*r/13.4%

      \[\leadsto \color{blue}{\frac{v \cdot 1}{t1}} \]
    2. *-rgt-identity13.4%

      \[\leadsto \frac{\color{blue}{v}}{t1} \]
  11. Simplified13.4%

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

Reproduce

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