
(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:
Herbie found 20 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(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}
(FPCore (u v t1) :precision binary64 (/ (/ (* t1 (/ v (+ t1 u))) -1.0) (+ t1 u)))
double code(double u, double v, double t1) {
return ((t1 * (v / (t1 + u))) / -1.0) / (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))) / (-1.0d0)) / (t1 + u)
end function
public static double code(double u, double v, double t1) {
return ((t1 * (v / (t1 + u))) / -1.0) / (t1 + u);
}
def code(u, v, t1): return ((t1 * (v / (t1 + u))) / -1.0) / (t1 + u)
function code(u, v, t1) return Float64(Float64(Float64(t1 * Float64(v / Float64(t1 + u))) / -1.0) / Float64(t1 + u)) end
function tmp = code(u, v, t1) tmp = ((t1 * (v / (t1 + u))) / -1.0) / (t1 + u); end
code[u_, v_, t1_] := N[(N[(N[(t1 * N[(v / N[(t1 + u), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / -1.0), $MachinePrecision] / N[(t1 + u), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{\frac{t1 \cdot \frac{v}{t1 + u}}{-1}}{t1 + u}
\end{array}
Initial program 70.6%
associate-/l*70.5%
distribute-lft-neg-out70.5%
distribute-rgt-neg-in70.5%
associate-/r*80.5%
distribute-neg-frac280.5%
Simplified80.5%
associate-*r/97.9%
neg-mul-197.9%
associate-/r*97.9%
Applied egg-rr97.9%
Final simplification97.9%
(FPCore (u v t1)
:precision binary64
(let* ((t_1 (* (- t1) (/ (/ v (+ t1 u)) (+ t1 u)))))
(if (<= t1 -7.6e+59)
(/ v (- (- u) t1))
(if (<= t1 -6.6e-246)
t_1
(if (<= t1 7e-240)
(* (/ (* t1 v) u) (/ -1.0 (- u t1)))
(if (<= t1 1.65e+74) t_1 (/ v (- u t1))))))))
double code(double u, double v, double t1) {
double t_1 = -t1 * ((v / (t1 + u)) / (t1 + u));
double tmp;
if (t1 <= -7.6e+59) {
tmp = v / (-u - t1);
} else if (t1 <= -6.6e-246) {
tmp = t_1;
} else if (t1 <= 7e-240) {
tmp = ((t1 * v) / u) * (-1.0 / (u - t1));
} else if (t1 <= 1.65e+74) {
tmp = t_1;
} 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) :: t_1
real(8) :: tmp
t_1 = -t1 * ((v / (t1 + u)) / (t1 + u))
if (t1 <= (-7.6d+59)) then
tmp = v / (-u - t1)
else if (t1 <= (-6.6d-246)) then
tmp = t_1
else if (t1 <= 7d-240) then
tmp = ((t1 * v) / u) * ((-1.0d0) / (u - t1))
else if (t1 <= 1.65d+74) then
tmp = t_1
else
tmp = v / (u - t1)
end if
code = tmp
end function
public static double code(double u, double v, double t1) {
double t_1 = -t1 * ((v / (t1 + u)) / (t1 + u));
double tmp;
if (t1 <= -7.6e+59) {
tmp = v / (-u - t1);
} else if (t1 <= -6.6e-246) {
tmp = t_1;
} else if (t1 <= 7e-240) {
tmp = ((t1 * v) / u) * (-1.0 / (u - t1));
} else if (t1 <= 1.65e+74) {
tmp = t_1;
} else {
tmp = v / (u - t1);
}
return tmp;
}
def code(u, v, t1): t_1 = -t1 * ((v / (t1 + u)) / (t1 + u)) tmp = 0 if t1 <= -7.6e+59: tmp = v / (-u - t1) elif t1 <= -6.6e-246: tmp = t_1 elif t1 <= 7e-240: tmp = ((t1 * v) / u) * (-1.0 / (u - t1)) elif t1 <= 1.65e+74: tmp = t_1 else: tmp = v / (u - t1) return tmp
function code(u, v, t1) t_1 = Float64(Float64(-t1) * Float64(Float64(v / Float64(t1 + u)) / Float64(t1 + u))) tmp = 0.0 if (t1 <= -7.6e+59) tmp = Float64(v / Float64(Float64(-u) - t1)); elseif (t1 <= -6.6e-246) tmp = t_1; elseif (t1 <= 7e-240) tmp = Float64(Float64(Float64(t1 * v) / u) * Float64(-1.0 / Float64(u - t1))); elseif (t1 <= 1.65e+74) tmp = t_1; else tmp = Float64(v / Float64(u - t1)); end return tmp end
function tmp_2 = code(u, v, t1) t_1 = -t1 * ((v / (t1 + u)) / (t1 + u)); tmp = 0.0; if (t1 <= -7.6e+59) tmp = v / (-u - t1); elseif (t1 <= -6.6e-246) tmp = t_1; elseif (t1 <= 7e-240) tmp = ((t1 * v) / u) * (-1.0 / (u - t1)); elseif (t1 <= 1.65e+74) tmp = t_1; else tmp = v / (u - t1); end tmp_2 = tmp; end
code[u_, v_, t1_] := Block[{t$95$1 = N[((-t1) * N[(N[(v / N[(t1 + u), $MachinePrecision]), $MachinePrecision] / N[(t1 + u), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t1, -7.6e+59], N[(v / N[((-u) - t1), $MachinePrecision]), $MachinePrecision], If[LessEqual[t1, -6.6e-246], t$95$1, If[LessEqual[t1, 7e-240], N[(N[(N[(t1 * v), $MachinePrecision] / u), $MachinePrecision] * N[(-1.0 / N[(u - t1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t1, 1.65e+74], t$95$1, N[(v / N[(u - t1), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(-t1\right) \cdot \frac{\frac{v}{t1 + u}}{t1 + u}\\
\mathbf{if}\;t1 \leq -7.6 \cdot 10^{+59}:\\
\;\;\;\;\frac{v}{\left(-u\right) - t1}\\
\mathbf{elif}\;t1 \leq -6.6 \cdot 10^{-246}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t1 \leq 7 \cdot 10^{-240}:\\
\;\;\;\;\frac{t1 \cdot v}{u} \cdot \frac{-1}{u - t1}\\
\mathbf{elif}\;t1 \leq 1.65 \cdot 10^{+74}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;\frac{v}{u - t1}\\
\end{array}
\end{array}
if t1 < -7.6000000000000002e59Initial program 49.5%
times-frac100.0%
distribute-frac-neg100.0%
distribute-neg-frac2100.0%
+-commutative100.0%
distribute-neg-in100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in t1 around inf 94.7%
Taylor expanded in v around 0 94.7%
associate-*r/94.7%
neg-mul-194.7%
Simplified94.7%
if -7.6000000000000002e59 < t1 < -6.6000000000000002e-246 or 7.00000000000000032e-240 < t1 < 1.6500000000000001e74Initial program 86.7%
associate-/l*91.2%
distribute-lft-neg-out91.2%
distribute-rgt-neg-in91.2%
associate-/r*95.4%
distribute-neg-frac295.4%
Simplified95.4%
if -6.6000000000000002e-246 < t1 < 7.00000000000000032e-240Initial program 69.8%
associate-/l*61.3%
distribute-lft-neg-out61.3%
distribute-rgt-neg-in61.3%
associate-/r*61.3%
distribute-neg-frac261.3%
Simplified61.3%
associate-*r/89.5%
neg-mul-189.5%
associate-/r*89.5%
Applied egg-rr89.5%
div-inv89.2%
associate-*r/92.6%
associate-/l/92.6%
neg-mul-192.6%
+-commutative92.6%
distribute-neg-in92.6%
sub-neg92.6%
associate-*l/89.2%
clear-num89.1%
associate-*l/89.2%
*-un-lft-identity89.2%
add-sqr-sqrt51.8%
sqrt-unprod48.2%
sqr-neg48.2%
sqrt-unprod11.9%
add-sqr-sqrt41.9%
frac-2neg41.9%
metadata-eval41.9%
+-commutative41.9%
distribute-neg-in41.9%
sub-neg41.9%
Applied egg-rr89.2%
Taylor expanded in u around inf 92.6%
if 1.6500000000000001e74 < t1 Initial program 57.9%
times-frac100.0%
distribute-frac-neg100.0%
distribute-neg-frac2100.0%
+-commutative100.0%
distribute-neg-in100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in t1 around inf 92.1%
clear-num92.1%
frac-times92.1%
*-un-lft-identity92.1%
add-sqr-sqrt41.7%
sqrt-unprod90.5%
sqr-neg90.5%
sqrt-unprod50.3%
add-sqr-sqrt92.1%
Applied egg-rr92.1%
associate-/l/92.1%
associate-/r/69.2%
*-commutative69.2%
associate-/l/54.1%
*-commutative54.1%
associate-/l*57.8%
times-frac92.1%
*-inverses92.1%
associate-*r/92.1%
metadata-eval92.1%
associate-*r*92.1%
*-commutative92.1%
associate-*r*92.1%
*-commutative92.1%
associate-*l*92.1%
metadata-eval92.1%
*-rgt-identity92.1%
Simplified92.1%
Final simplification94.2%
(FPCore (u v t1)
:precision binary64
(let* ((t_1 (/ v (- u t1))))
(if (<= t1 -7.2e+116)
t_1
(if (<= t1 -4.4e-246)
(* (- v) (/ t1 (* (+ t1 u) (+ t1 u))))
(if (<= t1 4.2e-239)
(* (/ (* t1 v) u) (/ -1.0 (- u t1)))
(if (<= t1 1.65e+74) (* (- t1) (/ (/ v (+ t1 u)) (+ t1 u))) t_1))))))
double code(double u, double v, double t1) {
double t_1 = v / (u - t1);
double tmp;
if (t1 <= -7.2e+116) {
tmp = t_1;
} else if (t1 <= -4.4e-246) {
tmp = -v * (t1 / ((t1 + u) * (t1 + u)));
} else if (t1 <= 4.2e-239) {
tmp = ((t1 * v) / u) * (-1.0 / (u - t1));
} else if (t1 <= 1.65e+74) {
tmp = -t1 * ((v / (t1 + u)) / (t1 + u));
} else {
tmp = t_1;
}
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 (t1 <= (-7.2d+116)) then
tmp = t_1
else if (t1 <= (-4.4d-246)) then
tmp = -v * (t1 / ((t1 + u) * (t1 + u)))
else if (t1 <= 4.2d-239) then
tmp = ((t1 * v) / u) * ((-1.0d0) / (u - t1))
else if (t1 <= 1.65d+74) then
tmp = -t1 * ((v / (t1 + u)) / (t1 + u))
else
tmp = t_1
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 (t1 <= -7.2e+116) {
tmp = t_1;
} else if (t1 <= -4.4e-246) {
tmp = -v * (t1 / ((t1 + u) * (t1 + u)));
} else if (t1 <= 4.2e-239) {
tmp = ((t1 * v) / u) * (-1.0 / (u - t1));
} else if (t1 <= 1.65e+74) {
tmp = -t1 * ((v / (t1 + u)) / (t1 + u));
} else {
tmp = t_1;
}
return tmp;
}
def code(u, v, t1): t_1 = v / (u - t1) tmp = 0 if t1 <= -7.2e+116: tmp = t_1 elif t1 <= -4.4e-246: tmp = -v * (t1 / ((t1 + u) * (t1 + u))) elif t1 <= 4.2e-239: tmp = ((t1 * v) / u) * (-1.0 / (u - t1)) elif t1 <= 1.65e+74: tmp = -t1 * ((v / (t1 + u)) / (t1 + u)) else: tmp = t_1 return tmp
function code(u, v, t1) t_1 = Float64(v / Float64(u - t1)) tmp = 0.0 if (t1 <= -7.2e+116) tmp = t_1; elseif (t1 <= -4.4e-246) tmp = Float64(Float64(-v) * Float64(t1 / Float64(Float64(t1 + u) * Float64(t1 + u)))); elseif (t1 <= 4.2e-239) tmp = Float64(Float64(Float64(t1 * v) / u) * Float64(-1.0 / Float64(u - t1))); elseif (t1 <= 1.65e+74) tmp = Float64(Float64(-t1) * Float64(Float64(v / Float64(t1 + u)) / Float64(t1 + u))); else tmp = t_1; end return tmp end
function tmp_2 = code(u, v, t1) t_1 = v / (u - t1); tmp = 0.0; if (t1 <= -7.2e+116) tmp = t_1; elseif (t1 <= -4.4e-246) tmp = -v * (t1 / ((t1 + u) * (t1 + u))); elseif (t1 <= 4.2e-239) tmp = ((t1 * v) / u) * (-1.0 / (u - t1)); elseif (t1 <= 1.65e+74) tmp = -t1 * ((v / (t1 + u)) / (t1 + u)); else tmp = t_1; end tmp_2 = tmp; end
code[u_, v_, t1_] := Block[{t$95$1 = N[(v / N[(u - t1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t1, -7.2e+116], t$95$1, If[LessEqual[t1, -4.4e-246], N[((-v) * N[(t1 / N[(N[(t1 + u), $MachinePrecision] * N[(t1 + u), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t1, 4.2e-239], N[(N[(N[(t1 * v), $MachinePrecision] / u), $MachinePrecision] * N[(-1.0 / N[(u - t1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t1, 1.65e+74], N[((-t1) * N[(N[(v / N[(t1 + u), $MachinePrecision]), $MachinePrecision] / N[(t1 + u), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{v}{u - t1}\\
\mathbf{if}\;t1 \leq -7.2 \cdot 10^{+116}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t1 \leq -4.4 \cdot 10^{-246}:\\
\;\;\;\;\left(-v\right) \cdot \frac{t1}{\left(t1 + u\right) \cdot \left(t1 + u\right)}\\
\mathbf{elif}\;t1 \leq 4.2 \cdot 10^{-239}:\\
\;\;\;\;\frac{t1 \cdot v}{u} \cdot \frac{-1}{u - t1}\\
\mathbf{elif}\;t1 \leq 1.65 \cdot 10^{+74}:\\
\;\;\;\;\left(-t1\right) \cdot \frac{\frac{v}{t1 + u}}{t1 + u}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if t1 < -7.19999999999999941e116 or 1.6500000000000001e74 < t1 Initial program 48.4%
times-frac100.0%
distribute-frac-neg100.0%
distribute-neg-frac2100.0%
+-commutative100.0%
distribute-neg-in100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in t1 around inf 94.2%
clear-num94.2%
frac-times94.2%
*-un-lft-identity94.2%
add-sqr-sqrt42.7%
sqrt-unprod90.3%
sqr-neg90.3%
sqrt-unprod51.3%
add-sqr-sqrt94.2%
Applied egg-rr94.2%
associate-/l/94.2%
associate-/r/66.2%
*-commutative66.2%
associate-/l/46.7%
*-commutative46.7%
associate-/l*48.4%
times-frac94.2%
*-inverses94.2%
associate-*r/94.2%
metadata-eval94.2%
associate-*r*94.2%
*-commutative94.2%
associate-*r*94.2%
*-commutative94.2%
associate-*l*94.2%
metadata-eval94.2%
*-rgt-identity94.2%
Simplified94.2%
if -7.19999999999999941e116 < t1 < -4.39999999999999996e-246Initial program 89.3%
associate-*l/95.9%
*-commutative95.9%
Simplified95.9%
if -4.39999999999999996e-246 < t1 < 4.2000000000000004e-239Initial program 69.8%
associate-/l*61.3%
distribute-lft-neg-out61.3%
distribute-rgt-neg-in61.3%
associate-/r*61.3%
distribute-neg-frac261.3%
Simplified61.3%
associate-*r/89.5%
neg-mul-189.5%
associate-/r*89.5%
Applied egg-rr89.5%
div-inv89.2%
associate-*r/92.6%
associate-/l/92.6%
neg-mul-192.6%
+-commutative92.6%
distribute-neg-in92.6%
sub-neg92.6%
associate-*l/89.2%
clear-num89.1%
associate-*l/89.2%
*-un-lft-identity89.2%
add-sqr-sqrt51.8%
sqrt-unprod48.2%
sqr-neg48.2%
sqrt-unprod11.9%
add-sqr-sqrt41.9%
frac-2neg41.9%
metadata-eval41.9%
+-commutative41.9%
distribute-neg-in41.9%
sub-neg41.9%
Applied egg-rr89.2%
Taylor expanded in u around inf 92.6%
if 4.2000000000000004e-239 < t1 < 1.6500000000000001e74Initial program 83.7%
associate-/l*89.2%
distribute-lft-neg-out89.2%
distribute-rgt-neg-in89.2%
associate-/r*95.9%
distribute-neg-frac295.9%
Simplified95.9%
Final simplification94.9%
(FPCore (u v t1)
:precision binary64
(if (<= t1 -5.2e-51)
(/ -1.0 (/ (+ t1 u) v))
(if (<= t1 6e-76)
(* t1 (/ v (* u (- (- u) t1))))
(/ v (* t1 (/ (- u t1) t1))))))
double code(double u, double v, double t1) {
double tmp;
if (t1 <= -5.2e-51) {
tmp = -1.0 / ((t1 + u) / v);
} else if (t1 <= 6e-76) {
tmp = t1 * (v / (u * (-u - t1)));
} else {
tmp = v / (t1 * ((u - t1) / 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 (t1 <= (-5.2d-51)) then
tmp = (-1.0d0) / ((t1 + u) / v)
else if (t1 <= 6d-76) then
tmp = t1 * (v / (u * (-u - t1)))
else
tmp = v / (t1 * ((u - t1) / t1))
end if
code = tmp
end function
public static double code(double u, double v, double t1) {
double tmp;
if (t1 <= -5.2e-51) {
tmp = -1.0 / ((t1 + u) / v);
} else if (t1 <= 6e-76) {
tmp = t1 * (v / (u * (-u - t1)));
} else {
tmp = v / (t1 * ((u - t1) / t1));
}
return tmp;
}
def code(u, v, t1): tmp = 0 if t1 <= -5.2e-51: tmp = -1.0 / ((t1 + u) / v) elif t1 <= 6e-76: tmp = t1 * (v / (u * (-u - t1))) else: tmp = v / (t1 * ((u - t1) / t1)) return tmp
function code(u, v, t1) tmp = 0.0 if (t1 <= -5.2e-51) tmp = Float64(-1.0 / Float64(Float64(t1 + u) / v)); elseif (t1 <= 6e-76) tmp = Float64(t1 * Float64(v / Float64(u * Float64(Float64(-u) - t1)))); else tmp = Float64(v / Float64(t1 * Float64(Float64(u - t1) / t1))); end return tmp end
function tmp_2 = code(u, v, t1) tmp = 0.0; if (t1 <= -5.2e-51) tmp = -1.0 / ((t1 + u) / v); elseif (t1 <= 6e-76) tmp = t1 * (v / (u * (-u - t1))); else tmp = v / (t1 * ((u - t1) / t1)); end tmp_2 = tmp; end
code[u_, v_, t1_] := If[LessEqual[t1, -5.2e-51], N[(-1.0 / N[(N[(t1 + u), $MachinePrecision] / v), $MachinePrecision]), $MachinePrecision], If[LessEqual[t1, 6e-76], N[(t1 * N[(v / N[(u * N[((-u) - t1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(v / N[(t1 * N[(N[(u - t1), $MachinePrecision] / t1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t1 \leq -5.2 \cdot 10^{-51}:\\
\;\;\;\;\frac{-1}{\frac{t1 + u}{v}}\\
\mathbf{elif}\;t1 \leq 6 \cdot 10^{-76}:\\
\;\;\;\;t1 \cdot \frac{v}{u \cdot \left(\left(-u\right) - t1\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{v}{t1 \cdot \frac{u - t1}{t1}}\\
\end{array}
\end{array}
if t1 < -5.2e-51Initial program 60.6%
times-frac100.0%
distribute-frac-neg100.0%
distribute-neg-frac2100.0%
+-commutative100.0%
distribute-neg-in100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in t1 around inf 88.1%
clear-num88.8%
inv-pow88.8%
Applied egg-rr88.8%
unpow-188.8%
Simplified88.8%
if -5.2e-51 < t1 < 6.00000000000000048e-76Initial program 80.4%
associate-/l*82.0%
distribute-lft-neg-out82.0%
distribute-rgt-neg-in82.0%
associate-/r*84.1%
distribute-neg-frac284.1%
Simplified84.1%
Taylor expanded in t1 around 0 73.7%
Taylor expanded in v around 0 72.6%
associate-*r/72.6%
neg-mul-172.6%
Simplified72.6%
if 6.00000000000000048e-76 < t1 Initial program 68.4%
times-frac100.0%
distribute-frac-neg100.0%
distribute-neg-frac2100.0%
+-commutative100.0%
distribute-neg-in100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in t1 around inf 83.3%
clear-num83.3%
frac-times83.3%
*-un-lft-identity83.3%
add-sqr-sqrt38.2%
sqrt-unprod82.9%
sqr-neg82.9%
sqrt-unprod44.7%
add-sqr-sqrt83.3%
Applied egg-rr83.3%
Final simplification80.9%
(FPCore (u v t1)
:precision binary64
(if (<= t1 -1.2e-52)
(/ -1.0 (/ (+ t1 u) v))
(if (<= t1 1.2e+16)
(* t1 (/ (/ v u) (- (- u) t1)))
(/ v (* t1 (/ (- u t1) t1))))))
double code(double u, double v, double t1) {
double tmp;
if (t1 <= -1.2e-52) {
tmp = -1.0 / ((t1 + u) / v);
} else if (t1 <= 1.2e+16) {
tmp = t1 * ((v / u) / (-u - t1));
} else {
tmp = v / (t1 * ((u - t1) / 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 (t1 <= (-1.2d-52)) then
tmp = (-1.0d0) / ((t1 + u) / v)
else if (t1 <= 1.2d+16) then
tmp = t1 * ((v / u) / (-u - t1))
else
tmp = v / (t1 * ((u - t1) / t1))
end if
code = tmp
end function
public static double code(double u, double v, double t1) {
double tmp;
if (t1 <= -1.2e-52) {
tmp = -1.0 / ((t1 + u) / v);
} else if (t1 <= 1.2e+16) {
tmp = t1 * ((v / u) / (-u - t1));
} else {
tmp = v / (t1 * ((u - t1) / t1));
}
return tmp;
}
def code(u, v, t1): tmp = 0 if t1 <= -1.2e-52: tmp = -1.0 / ((t1 + u) / v) elif t1 <= 1.2e+16: tmp = t1 * ((v / u) / (-u - t1)) else: tmp = v / (t1 * ((u - t1) / t1)) return tmp
function code(u, v, t1) tmp = 0.0 if (t1 <= -1.2e-52) tmp = Float64(-1.0 / Float64(Float64(t1 + u) / v)); elseif (t1 <= 1.2e+16) tmp = Float64(t1 * Float64(Float64(v / u) / Float64(Float64(-u) - t1))); else tmp = Float64(v / Float64(t1 * Float64(Float64(u - t1) / t1))); end return tmp end
function tmp_2 = code(u, v, t1) tmp = 0.0; if (t1 <= -1.2e-52) tmp = -1.0 / ((t1 + u) / v); elseif (t1 <= 1.2e+16) tmp = t1 * ((v / u) / (-u - t1)); else tmp = v / (t1 * ((u - t1) / t1)); end tmp_2 = tmp; end
code[u_, v_, t1_] := If[LessEqual[t1, -1.2e-52], N[(-1.0 / N[(N[(t1 + u), $MachinePrecision] / v), $MachinePrecision]), $MachinePrecision], If[LessEqual[t1, 1.2e+16], N[(t1 * N[(N[(v / u), $MachinePrecision] / N[((-u) - t1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(v / N[(t1 * N[(N[(u - t1), $MachinePrecision] / t1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t1 \leq -1.2 \cdot 10^{-52}:\\
\;\;\;\;\frac{-1}{\frac{t1 + u}{v}}\\
\mathbf{elif}\;t1 \leq 1.2 \cdot 10^{+16}:\\
\;\;\;\;t1 \cdot \frac{\frac{v}{u}}{\left(-u\right) - t1}\\
\mathbf{else}:\\
\;\;\;\;\frac{v}{t1 \cdot \frac{u - t1}{t1}}\\
\end{array}
\end{array}
if t1 < -1.2000000000000001e-52Initial program 60.6%
times-frac100.0%
distribute-frac-neg100.0%
distribute-neg-frac2100.0%
+-commutative100.0%
distribute-neg-in100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in t1 around inf 88.1%
clear-num88.8%
inv-pow88.8%
Applied egg-rr88.8%
unpow-188.8%
Simplified88.8%
if -1.2000000000000001e-52 < t1 < 1.2e16Initial program 82.0%
associate-/l*83.3%
distribute-lft-neg-out83.3%
distribute-rgt-neg-in83.3%
associate-/r*86.7%
distribute-neg-frac286.7%
Simplified86.7%
Taylor expanded in t1 around 0 71.6%
if 1.2e16 < t1 Initial program 62.3%
times-frac100.0%
distribute-frac-neg100.0%
distribute-neg-frac2100.0%
+-commutative100.0%
distribute-neg-in100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in t1 around inf 90.3%
clear-num90.3%
frac-times90.3%
*-un-lft-identity90.3%
add-sqr-sqrt40.4%
sqrt-unprod90.0%
sqr-neg90.0%
sqrt-unprod49.8%
add-sqr-sqrt90.4%
Applied egg-rr90.4%
Final simplification81.5%
(FPCore (u v t1)
:precision binary64
(if (<= t1 -5e-51)
(/ -1.0 (/ (+ t1 u) v))
(if (<= t1 1.15e+16)
(* (/ t1 (- (- u) t1)) (/ v u))
(/ v (* t1 (/ (- u t1) t1))))))
double code(double u, double v, double t1) {
double tmp;
if (t1 <= -5e-51) {
tmp = -1.0 / ((t1 + u) / v);
} else if (t1 <= 1.15e+16) {
tmp = (t1 / (-u - t1)) * (v / u);
} else {
tmp = v / (t1 * ((u - t1) / 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 (t1 <= (-5d-51)) then
tmp = (-1.0d0) / ((t1 + u) / v)
else if (t1 <= 1.15d+16) then
tmp = (t1 / (-u - t1)) * (v / u)
else
tmp = v / (t1 * ((u - t1) / t1))
end if
code = tmp
end function
public static double code(double u, double v, double t1) {
double tmp;
if (t1 <= -5e-51) {
tmp = -1.0 / ((t1 + u) / v);
} else if (t1 <= 1.15e+16) {
tmp = (t1 / (-u - t1)) * (v / u);
} else {
tmp = v / (t1 * ((u - t1) / t1));
}
return tmp;
}
def code(u, v, t1): tmp = 0 if t1 <= -5e-51: tmp = -1.0 / ((t1 + u) / v) elif t1 <= 1.15e+16: tmp = (t1 / (-u - t1)) * (v / u) else: tmp = v / (t1 * ((u - t1) / t1)) return tmp
function code(u, v, t1) tmp = 0.0 if (t1 <= -5e-51) tmp = Float64(-1.0 / Float64(Float64(t1 + u) / v)); elseif (t1 <= 1.15e+16) tmp = Float64(Float64(t1 / Float64(Float64(-u) - t1)) * Float64(v / u)); else tmp = Float64(v / Float64(t1 * Float64(Float64(u - t1) / t1))); end return tmp end
function tmp_2 = code(u, v, t1) tmp = 0.0; if (t1 <= -5e-51) tmp = -1.0 / ((t1 + u) / v); elseif (t1 <= 1.15e+16) tmp = (t1 / (-u - t1)) * (v / u); else tmp = v / (t1 * ((u - t1) / t1)); end tmp_2 = tmp; end
code[u_, v_, t1_] := If[LessEqual[t1, -5e-51], N[(-1.0 / N[(N[(t1 + u), $MachinePrecision] / v), $MachinePrecision]), $MachinePrecision], If[LessEqual[t1, 1.15e+16], N[(N[(t1 / N[((-u) - t1), $MachinePrecision]), $MachinePrecision] * N[(v / u), $MachinePrecision]), $MachinePrecision], N[(v / N[(t1 * N[(N[(u - t1), $MachinePrecision] / t1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t1 \leq -5 \cdot 10^{-51}:\\
\;\;\;\;\frac{-1}{\frac{t1 + u}{v}}\\
\mathbf{elif}\;t1 \leq 1.15 \cdot 10^{+16}:\\
\;\;\;\;\frac{t1}{\left(-u\right) - t1} \cdot \frac{v}{u}\\
\mathbf{else}:\\
\;\;\;\;\frac{v}{t1 \cdot \frac{u - t1}{t1}}\\
\end{array}
\end{array}
if t1 < -5.00000000000000004e-51Initial program 60.6%
times-frac100.0%
distribute-frac-neg100.0%
distribute-neg-frac2100.0%
+-commutative100.0%
distribute-neg-in100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in t1 around inf 88.1%
clear-num88.8%
inv-pow88.8%
Applied egg-rr88.8%
unpow-188.8%
Simplified88.8%
if -5.00000000000000004e-51 < t1 < 1.15e16Initial program 82.0%
times-frac94.4%
distribute-frac-neg94.4%
distribute-neg-frac294.4%
+-commutative94.4%
distribute-neg-in94.4%
unsub-neg94.4%
Simplified94.4%
Taylor expanded in t1 around 0 76.9%
if 1.15e16 < t1 Initial program 62.3%
times-frac100.0%
distribute-frac-neg100.0%
distribute-neg-frac2100.0%
+-commutative100.0%
distribute-neg-in100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in t1 around inf 90.3%
clear-num90.3%
frac-times90.3%
*-un-lft-identity90.3%
add-sqr-sqrt40.4%
sqrt-unprod90.0%
sqr-neg90.0%
sqrt-unprod49.8%
add-sqr-sqrt90.4%
Applied egg-rr90.4%
Final simplification83.9%
(FPCore (u v t1)
:precision binary64
(if (<= t1 -3.1e-53)
(/ -1.0 (/ (+ t1 u) v))
(if (<= t1 1.15e+16)
(/ (* t1 (/ v (- u))) (+ t1 u))
(/ v (* t1 (/ (- u t1) t1))))))
double code(double u, double v, double t1) {
double tmp;
if (t1 <= -3.1e-53) {
tmp = -1.0 / ((t1 + u) / v);
} else if (t1 <= 1.15e+16) {
tmp = (t1 * (v / -u)) / (t1 + u);
} else {
tmp = v / (t1 * ((u - t1) / 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 (t1 <= (-3.1d-53)) then
tmp = (-1.0d0) / ((t1 + u) / v)
else if (t1 <= 1.15d+16) then
tmp = (t1 * (v / -u)) / (t1 + u)
else
tmp = v / (t1 * ((u - t1) / t1))
end if
code = tmp
end function
public static double code(double u, double v, double t1) {
double tmp;
if (t1 <= -3.1e-53) {
tmp = -1.0 / ((t1 + u) / v);
} else if (t1 <= 1.15e+16) {
tmp = (t1 * (v / -u)) / (t1 + u);
} else {
tmp = v / (t1 * ((u - t1) / t1));
}
return tmp;
}
def code(u, v, t1): tmp = 0 if t1 <= -3.1e-53: tmp = -1.0 / ((t1 + u) / v) elif t1 <= 1.15e+16: tmp = (t1 * (v / -u)) / (t1 + u) else: tmp = v / (t1 * ((u - t1) / t1)) return tmp
function code(u, v, t1) tmp = 0.0 if (t1 <= -3.1e-53) tmp = Float64(-1.0 / Float64(Float64(t1 + u) / v)); elseif (t1 <= 1.15e+16) tmp = Float64(Float64(t1 * Float64(v / Float64(-u))) / Float64(t1 + u)); else tmp = Float64(v / Float64(t1 * Float64(Float64(u - t1) / t1))); end return tmp end
function tmp_2 = code(u, v, t1) tmp = 0.0; if (t1 <= -3.1e-53) tmp = -1.0 / ((t1 + u) / v); elseif (t1 <= 1.15e+16) tmp = (t1 * (v / -u)) / (t1 + u); else tmp = v / (t1 * ((u - t1) / t1)); end tmp_2 = tmp; end
code[u_, v_, t1_] := If[LessEqual[t1, -3.1e-53], N[(-1.0 / N[(N[(t1 + u), $MachinePrecision] / v), $MachinePrecision]), $MachinePrecision], If[LessEqual[t1, 1.15e+16], N[(N[(t1 * N[(v / (-u)), $MachinePrecision]), $MachinePrecision] / N[(t1 + u), $MachinePrecision]), $MachinePrecision], N[(v / N[(t1 * N[(N[(u - t1), $MachinePrecision] / t1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t1 \leq -3.1 \cdot 10^{-53}:\\
\;\;\;\;\frac{-1}{\frac{t1 + u}{v}}\\
\mathbf{elif}\;t1 \leq 1.15 \cdot 10^{+16}:\\
\;\;\;\;\frac{t1 \cdot \frac{v}{-u}}{t1 + u}\\
\mathbf{else}:\\
\;\;\;\;\frac{v}{t1 \cdot \frac{u - t1}{t1}}\\
\end{array}
\end{array}
if t1 < -3.10000000000000015e-53Initial program 60.6%
times-frac100.0%
distribute-frac-neg100.0%
distribute-neg-frac2100.0%
+-commutative100.0%
distribute-neg-in100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in t1 around inf 88.1%
clear-num88.8%
inv-pow88.8%
Applied egg-rr88.8%
unpow-188.8%
Simplified88.8%
if -3.10000000000000015e-53 < t1 < 1.15e16Initial program 82.0%
associate-/l*83.3%
distribute-lft-neg-out83.3%
distribute-rgt-neg-in83.3%
associate-/r*86.7%
distribute-neg-frac286.7%
Simplified86.7%
Taylor expanded in t1 around 0 71.6%
*-commutative71.6%
distribute-frac-neg271.6%
distribute-frac-neg71.6%
associate-*l/77.8%
distribute-neg-frac277.8%
+-commutative77.8%
Applied egg-rr77.8%
if 1.15e16 < t1 Initial program 62.3%
times-frac100.0%
distribute-frac-neg100.0%
distribute-neg-frac2100.0%
+-commutative100.0%
distribute-neg-in100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in t1 around inf 90.3%
clear-num90.3%
frac-times90.3%
*-un-lft-identity90.3%
add-sqr-sqrt40.4%
sqrt-unprod90.0%
sqr-neg90.0%
sqrt-unprod49.8%
add-sqr-sqrt90.4%
Applied egg-rr90.4%
Final simplification84.3%
(FPCore (u v t1) :precision binary64 (if (or (<= u -2e+119) (not (<= u 4e+87))) (/ t1 (* (+ t1 u) (/ u v))) (/ v (- (- u) t1))))
double code(double u, double v, double t1) {
double tmp;
if ((u <= -2e+119) || !(u <= 4e+87)) {
tmp = t1 / ((t1 + u) * (u / v));
} 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 <= (-2d+119)) .or. (.not. (u <= 4d+87))) then
tmp = t1 / ((t1 + u) * (u / v))
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 <= -2e+119) || !(u <= 4e+87)) {
tmp = t1 / ((t1 + u) * (u / v));
} else {
tmp = v / (-u - t1);
}
return tmp;
}
def code(u, v, t1): tmp = 0 if (u <= -2e+119) or not (u <= 4e+87): tmp = t1 / ((t1 + u) * (u / v)) else: tmp = v / (-u - t1) return tmp
function code(u, v, t1) tmp = 0.0 if ((u <= -2e+119) || !(u <= 4e+87)) tmp = Float64(t1 / Float64(Float64(t1 + u) * Float64(u / v))); else tmp = Float64(v / Float64(Float64(-u) - t1)); end return tmp end
function tmp_2 = code(u, v, t1) tmp = 0.0; if ((u <= -2e+119) || ~((u <= 4e+87))) tmp = t1 / ((t1 + u) * (u / v)); else tmp = v / (-u - t1); end tmp_2 = tmp; end
code[u_, v_, t1_] := If[Or[LessEqual[u, -2e+119], N[Not[LessEqual[u, 4e+87]], $MachinePrecision]], N[(t1 / N[(N[(t1 + u), $MachinePrecision] * N[(u / v), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(v / N[((-u) - t1), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;u \leq -2 \cdot 10^{+119} \lor \neg \left(u \leq 4 \cdot 10^{+87}\right):\\
\;\;\;\;\frac{t1}{\left(t1 + u\right) \cdot \frac{u}{v}}\\
\mathbf{else}:\\
\;\;\;\;\frac{v}{\left(-u\right) - t1}\\
\end{array}
\end{array}
if u < -1.99999999999999989e119 or 3.9999999999999998e87 < u Initial program 78.4%
associate-/l*79.0%
distribute-lft-neg-out79.0%
distribute-rgt-neg-in79.0%
associate-/r*89.7%
distribute-neg-frac289.7%
Simplified89.7%
Taylor expanded in t1 around 0 86.5%
clear-num86.5%
un-div-inv86.5%
div-inv86.5%
add-sqr-sqrt34.9%
sqrt-unprod77.6%
sqr-neg77.6%
sqrt-unprod43.3%
add-sqr-sqrt73.3%
clear-num73.3%
+-commutative73.3%
Applied egg-rr73.3%
if -1.99999999999999989e119 < u < 3.9999999999999998e87Initial program 67.7%
times-frac97.3%
distribute-frac-neg97.3%
distribute-neg-frac297.3%
+-commutative97.3%
distribute-neg-in97.3%
unsub-neg97.3%
Simplified97.3%
Taylor expanded in t1 around inf 71.5%
Taylor expanded in v around 0 71.6%
associate-*r/71.6%
neg-mul-171.6%
Simplified71.6%
Final simplification72.1%
(FPCore (u v t1) :precision binary64 (if (or (<= u -5.5e+171) (not (<= u 1.6e+181))) (/ v u) (/ v (- t1))))
double code(double u, double v, double t1) {
double tmp;
if ((u <= -5.5e+171) || !(u <= 1.6e+181)) {
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 <= (-5.5d+171)) .or. (.not. (u <= 1.6d+181))) 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 <= -5.5e+171) || !(u <= 1.6e+181)) {
tmp = v / u;
} else {
tmp = v / -t1;
}
return tmp;
}
def code(u, v, t1): tmp = 0 if (u <= -5.5e+171) or not (u <= 1.6e+181): tmp = v / u else: tmp = v / -t1 return tmp
function code(u, v, t1) tmp = 0.0 if ((u <= -5.5e+171) || !(u <= 1.6e+181)) 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 <= -5.5e+171) || ~((u <= 1.6e+181))) tmp = v / u; else tmp = v / -t1; end tmp_2 = tmp; end
code[u_, v_, t1_] := If[Or[LessEqual[u, -5.5e+171], N[Not[LessEqual[u, 1.6e+181]], $MachinePrecision]], N[(v / u), $MachinePrecision], N[(v / (-t1)), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;u \leq -5.5 \cdot 10^{+171} \lor \neg \left(u \leq 1.6 \cdot 10^{+181}\right):\\
\;\;\;\;\frac{v}{u}\\
\mathbf{else}:\\
\;\;\;\;\frac{v}{-t1}\\
\end{array}
\end{array}
if u < -5.5000000000000003e171 or 1.6e181 < u Initial program 82.6%
times-frac98.6%
distribute-frac-neg98.6%
distribute-neg-frac298.6%
+-commutative98.6%
distribute-neg-in98.6%
unsub-neg98.6%
Simplified98.6%
Taylor expanded in t1 around inf 70.9%
clear-num70.8%
frac-times76.3%
*-un-lft-identity76.3%
add-sqr-sqrt32.6%
sqrt-unprod83.1%
sqr-neg83.1%
sqrt-unprod43.6%
add-sqr-sqrt76.2%
Applied egg-rr76.2%
Taylor expanded in u around inf 51.1%
if -5.5000000000000003e171 < u < 1.6e181Initial program 68.5%
associate-/l*68.3%
distribute-lft-neg-out68.3%
distribute-rgt-neg-in68.3%
associate-/r*79.2%
distribute-neg-frac279.2%
Simplified79.2%
Taylor expanded in t1 around inf 64.4%
associate-*r/64.4%
neg-mul-164.4%
Simplified64.4%
Final simplification62.4%
(FPCore (u v t1) :precision binary64 (if (or (<= u -7.8e+174) (not (<= u 1.16e+154))) (/ v (- u)) (/ v (- t1))))
double code(double u, double v, double t1) {
double tmp;
if ((u <= -7.8e+174) || !(u <= 1.16e+154)) {
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 <= (-7.8d+174)) .or. (.not. (u <= 1.16d+154))) 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 <= -7.8e+174) || !(u <= 1.16e+154)) {
tmp = v / -u;
} else {
tmp = v / -t1;
}
return tmp;
}
def code(u, v, t1): tmp = 0 if (u <= -7.8e+174) or not (u <= 1.16e+154): tmp = v / -u else: tmp = v / -t1 return tmp
function code(u, v, t1) tmp = 0.0 if ((u <= -7.8e+174) || !(u <= 1.16e+154)) tmp = Float64(v / Float64(-u)); else tmp = Float64(v / Float64(-t1)); end return tmp end
function tmp_2 = code(u, v, t1) tmp = 0.0; if ((u <= -7.8e+174) || ~((u <= 1.16e+154))) tmp = v / -u; else tmp = v / -t1; end tmp_2 = tmp; end
code[u_, v_, t1_] := If[Or[LessEqual[u, -7.8e+174], N[Not[LessEqual[u, 1.16e+154]], $MachinePrecision]], N[(v / (-u)), $MachinePrecision], N[(v / (-t1)), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;u \leq -7.8 \cdot 10^{+174} \lor \neg \left(u \leq 1.16 \cdot 10^{+154}\right):\\
\;\;\;\;\frac{v}{-u}\\
\mathbf{else}:\\
\;\;\;\;\frac{v}{-t1}\\
\end{array}
\end{array}
if u < -7.79999999999999962e174 or 1.16000000000000001e154 < u Initial program 75.8%
times-frac98.7%
distribute-frac-neg98.7%
distribute-neg-frac298.7%
+-commutative98.7%
distribute-neg-in98.7%
unsub-neg98.7%
Simplified98.7%
Taylor expanded in t1 around inf 67.7%
Taylor expanded in t1 around 0 48.3%
associate-*r/48.3%
neg-mul-148.3%
Simplified48.3%
if -7.79999999999999962e174 < u < 1.16000000000000001e154Initial program 69.6%
associate-/l*69.3%
distribute-lft-neg-out69.3%
distribute-rgt-neg-in69.3%
associate-/r*79.1%
distribute-neg-frac279.1%
Simplified79.1%
Taylor expanded in t1 around inf 65.3%
associate-*r/65.3%
neg-mul-165.3%
Simplified65.3%
Final simplification62.5%
(FPCore (u v t1) :precision binary64 (if (or (<= t1 -1.65e+57) (not (<= t1 7.6e+114))) (/ v t1) (/ v u)))
double code(double u, double v, double t1) {
double tmp;
if ((t1 <= -1.65e+57) || !(t1 <= 7.6e+114)) {
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.65d+57)) .or. (.not. (t1 <= 7.6d+114))) 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.65e+57) || !(t1 <= 7.6e+114)) {
tmp = v / t1;
} else {
tmp = v / u;
}
return tmp;
}
def code(u, v, t1): tmp = 0 if (t1 <= -1.65e+57) or not (t1 <= 7.6e+114): tmp = v / t1 else: tmp = v / u return tmp
function code(u, v, t1) tmp = 0.0 if ((t1 <= -1.65e+57) || !(t1 <= 7.6e+114)) 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.65e+57) || ~((t1 <= 7.6e+114))) tmp = v / t1; else tmp = v / u; end tmp_2 = tmp; end
code[u_, v_, t1_] := If[Or[LessEqual[t1, -1.65e+57], N[Not[LessEqual[t1, 7.6e+114]], $MachinePrecision]], N[(v / t1), $MachinePrecision], N[(v / u), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t1 \leq -1.65 \cdot 10^{+57} \lor \neg \left(t1 \leq 7.6 \cdot 10^{+114}\right):\\
\;\;\;\;\frac{v}{t1}\\
\mathbf{else}:\\
\;\;\;\;\frac{v}{u}\\
\end{array}
\end{array}
if t1 < -1.6500000000000001e57 or 7.6000000000000001e114 < t1 Initial program 51.4%
times-frac100.0%
distribute-frac-neg100.0%
distribute-neg-frac2100.0%
+-commutative100.0%
distribute-neg-in100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in t1 around inf 94.3%
Taylor expanded in u around inf 31.6%
if -1.6500000000000001e57 < t1 < 7.6000000000000001e114Initial program 83.4%
times-frac95.8%
distribute-frac-neg95.8%
distribute-neg-frac295.8%
+-commutative95.8%
distribute-neg-in95.8%
unsub-neg95.8%
Simplified95.8%
Taylor expanded in t1 around inf 52.4%
clear-num52.4%
frac-times54.5%
*-un-lft-identity54.5%
add-sqr-sqrt26.5%
sqrt-unprod57.8%
sqr-neg57.8%
sqrt-unprod27.7%
add-sqr-sqrt54.0%
Applied egg-rr54.0%
Taylor expanded in u around inf 17.1%
Final simplification22.9%
(FPCore (u v t1) :precision binary64 (if (<= u 1.7e+90) (/ v (- (- u) t1)) (/ (* v (/ t1 (- u))) t1)))
double code(double u, double v, double t1) {
double tmp;
if (u <= 1.7e+90) {
tmp = v / (-u - t1);
} else {
tmp = (v * (t1 / -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.7d+90) then
tmp = v / (-u - t1)
else
tmp = (v * (t1 / -u)) / t1
end if
code = tmp
end function
public static double code(double u, double v, double t1) {
double tmp;
if (u <= 1.7e+90) {
tmp = v / (-u - t1);
} else {
tmp = (v * (t1 / -u)) / t1;
}
return tmp;
}
def code(u, v, t1): tmp = 0 if u <= 1.7e+90: tmp = v / (-u - t1) else: tmp = (v * (t1 / -u)) / t1 return tmp
function code(u, v, t1) tmp = 0.0 if (u <= 1.7e+90) tmp = Float64(v / Float64(Float64(-u) - t1)); else tmp = Float64(Float64(v * Float64(t1 / Float64(-u))) / t1); end return tmp end
function tmp_2 = code(u, v, t1) tmp = 0.0; if (u <= 1.7e+90) tmp = v / (-u - t1); else tmp = (v * (t1 / -u)) / t1; end tmp_2 = tmp; end
code[u_, v_, t1_] := If[LessEqual[u, 1.7e+90], N[(v / N[((-u) - t1), $MachinePrecision]), $MachinePrecision], N[(N[(v * N[(t1 / (-u)), $MachinePrecision]), $MachinePrecision] / t1), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;u \leq 1.7 \cdot 10^{+90}:\\
\;\;\;\;\frac{v}{\left(-u\right) - t1}\\
\mathbf{else}:\\
\;\;\;\;\frac{v \cdot \frac{t1}{-u}}{t1}\\
\end{array}
\end{array}
if u < 1.70000000000000009e90Initial program 69.9%
times-frac97.3%
distribute-frac-neg97.3%
distribute-neg-frac297.3%
+-commutative97.3%
distribute-neg-in97.3%
unsub-neg97.3%
Simplified97.3%
Taylor expanded in t1 around inf 70.7%
Taylor expanded in v around 0 68.7%
associate-*r/68.7%
neg-mul-168.7%
Simplified68.7%
if 1.70000000000000009e90 < u Initial program 74.7%
times-frac98.7%
distribute-frac-neg98.7%
distribute-neg-frac298.7%
+-commutative98.7%
distribute-neg-in98.7%
unsub-neg98.7%
Simplified98.7%
Taylor expanded in t1 around inf 61.0%
Taylor expanded in t1 around 0 54.2%
associate-*r/54.2%
mul-1-neg54.2%
Simplified54.2%
frac-2neg54.2%
associate-*r/64.7%
add-sqr-sqrt24.8%
sqrt-unprod47.8%
sqr-neg47.8%
sqrt-unprod39.2%
add-sqr-sqrt64.0%
add-sqr-sqrt24.8%
sqrt-unprod51.1%
sqr-neg51.1%
sqrt-unprod39.8%
add-sqr-sqrt64.7%
Applied egg-rr64.7%
Final simplification68.0%
(FPCore (u v t1) :precision binary64 (if (<= u 8e+217) (/ v (- (- u) t1)) (* v (/ (/ t1 u) t1))))
double code(double u, double v, double t1) {
double tmp;
if (u <= 8e+217) {
tmp = v / (-u - t1);
} else {
tmp = v * ((t1 / 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 <= 8d+217) then
tmp = v / (-u - t1)
else
tmp = v * ((t1 / u) / t1)
end if
code = tmp
end function
public static double code(double u, double v, double t1) {
double tmp;
if (u <= 8e+217) {
tmp = v / (-u - t1);
} else {
tmp = v * ((t1 / u) / t1);
}
return tmp;
}
def code(u, v, t1): tmp = 0 if u <= 8e+217: tmp = v / (-u - t1) else: tmp = v * ((t1 / u) / t1) return tmp
function code(u, v, t1) tmp = 0.0 if (u <= 8e+217) tmp = Float64(v / Float64(Float64(-u) - t1)); else tmp = Float64(v * Float64(Float64(t1 / u) / t1)); end return tmp end
function tmp_2 = code(u, v, t1) tmp = 0.0; if (u <= 8e+217) tmp = v / (-u - t1); else tmp = v * ((t1 / u) / t1); end tmp_2 = tmp; end
code[u_, v_, t1_] := If[LessEqual[u, 8e+217], N[(v / N[((-u) - t1), $MachinePrecision]), $MachinePrecision], N[(v * N[(N[(t1 / u), $MachinePrecision] / t1), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;u \leq 8 \cdot 10^{+217}:\\
\;\;\;\;\frac{v}{\left(-u\right) - t1}\\
\mathbf{else}:\\
\;\;\;\;v \cdot \frac{\frac{t1}{u}}{t1}\\
\end{array}
\end{array}
if u < 7.99999999999999968e217Initial program 69.4%
times-frac97.3%
distribute-frac-neg97.3%
distribute-neg-frac297.3%
+-commutative97.3%
distribute-neg-in97.3%
unsub-neg97.3%
Simplified97.3%
Taylor expanded in t1 around inf 69.4%
Taylor expanded in v around 0 66.3%
associate-*r/66.3%
neg-mul-166.3%
Simplified66.3%
if 7.99999999999999968e217 < u Initial program 88.2%
times-frac100.0%
distribute-frac-neg100.0%
distribute-neg-frac2100.0%
+-commutative100.0%
distribute-neg-in100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in t1 around inf 66.7%
Taylor expanded in t1 around 0 66.7%
associate-*r/66.7%
mul-1-neg66.7%
Simplified66.7%
*-commutative66.7%
clear-num66.7%
frac-times60.6%
*-un-lft-identity60.6%
add-sqr-sqrt18.5%
sqrt-unprod36.4%
sqr-neg36.4%
sqrt-unprod41.9%
add-sqr-sqrt60.5%
Applied egg-rr60.5%
associate-/l/66.6%
associate-/r/78.3%
Simplified78.3%
Final simplification67.1%
(FPCore (u v t1) :precision binary64 (if (<= u 1.7e+90) (/ v (- (- u) t1)) (/ (* v (/ t1 u)) t1)))
double code(double u, double v, double t1) {
double tmp;
if (u <= 1.7e+90) {
tmp = v / (-u - t1);
} else {
tmp = (v * (t1 / 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.7d+90) then
tmp = v / (-u - t1)
else
tmp = (v * (t1 / u)) / t1
end if
code = tmp
end function
public static double code(double u, double v, double t1) {
double tmp;
if (u <= 1.7e+90) {
tmp = v / (-u - t1);
} else {
tmp = (v * (t1 / u)) / t1;
}
return tmp;
}
def code(u, v, t1): tmp = 0 if u <= 1.7e+90: tmp = v / (-u - t1) else: tmp = (v * (t1 / u)) / t1 return tmp
function code(u, v, t1) tmp = 0.0 if (u <= 1.7e+90) tmp = Float64(v / Float64(Float64(-u) - t1)); else tmp = Float64(Float64(v * Float64(t1 / u)) / t1); end return tmp end
function tmp_2 = code(u, v, t1) tmp = 0.0; if (u <= 1.7e+90) tmp = v / (-u - t1); else tmp = (v * (t1 / u)) / t1; end tmp_2 = tmp; end
code[u_, v_, t1_] := If[LessEqual[u, 1.7e+90], N[(v / N[((-u) - t1), $MachinePrecision]), $MachinePrecision], N[(N[(v * N[(t1 / u), $MachinePrecision]), $MachinePrecision] / t1), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;u \leq 1.7 \cdot 10^{+90}:\\
\;\;\;\;\frac{v}{\left(-u\right) - t1}\\
\mathbf{else}:\\
\;\;\;\;\frac{v \cdot \frac{t1}{u}}{t1}\\
\end{array}
\end{array}
if u < 1.70000000000000009e90Initial program 69.9%
times-frac97.3%
distribute-frac-neg97.3%
distribute-neg-frac297.3%
+-commutative97.3%
distribute-neg-in97.3%
unsub-neg97.3%
Simplified97.3%
Taylor expanded in t1 around inf 70.7%
Taylor expanded in v around 0 68.7%
associate-*r/68.7%
neg-mul-168.7%
Simplified68.7%
if 1.70000000000000009e90 < u Initial program 74.7%
times-frac98.7%
distribute-frac-neg98.7%
distribute-neg-frac298.7%
+-commutative98.7%
distribute-neg-in98.7%
unsub-neg98.7%
Simplified98.7%
Taylor expanded in t1 around inf 61.0%
Taylor expanded in t1 around 0 54.2%
associate-*r/54.2%
mul-1-neg54.2%
Simplified54.2%
*-commutative54.2%
associate-*l/64.7%
add-sqr-sqrt24.8%
sqrt-unprod47.8%
sqr-neg47.8%
sqrt-unprod39.2%
add-sqr-sqrt64.0%
Applied egg-rr64.0%
Final simplification67.9%
(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(t1 + u)) * Float64(t1 / Float64(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 + u), $MachinePrecision]), $MachinePrecision] * N[(t1 / N[((-u) - t1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{v}{t1 + u} \cdot \frac{t1}{\left(-u\right) - t1}
\end{array}
Initial program 70.6%
times-frac97.5%
distribute-frac-neg97.5%
distribute-neg-frac297.5%
+-commutative97.5%
distribute-neg-in97.5%
unsub-neg97.5%
Simplified97.5%
Final simplification97.5%
(FPCore (u v t1) :precision binary64 (/ v (* t1 (/ (- u t1) t1))))
double code(double u, double v, double t1) {
return v / (t1 * ((u - t1) / 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) / t1))
end function
public static double code(double u, double v, double t1) {
return v / (t1 * ((u - t1) / t1));
}
def code(u, v, t1): return v / (t1 * ((u - t1) / t1))
function code(u, v, t1) return Float64(v / Float64(t1 * Float64(Float64(u - t1) / t1))) end
function tmp = code(u, v, t1) tmp = v / (t1 * ((u - t1) / t1)); end
code[u_, v_, t1_] := N[(v / N[(t1 * N[(N[(u - t1), $MachinePrecision] / t1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{v}{t1 \cdot \frac{u - t1}{t1}}
\end{array}
Initial program 70.6%
times-frac97.5%
distribute-frac-neg97.5%
distribute-neg-frac297.5%
+-commutative97.5%
distribute-neg-in97.5%
unsub-neg97.5%
Simplified97.5%
Taylor expanded in t1 around inf 69.2%
clear-num69.2%
frac-times70.5%
*-un-lft-identity70.5%
add-sqr-sqrt32.8%
sqrt-unprod71.0%
sqr-neg71.0%
sqrt-unprod37.5%
add-sqr-sqrt70.2%
Applied egg-rr70.2%
Final simplification70.2%
(FPCore (u v t1) :precision binary64 (/ (/ v (/ (- u t1) t1)) t1))
double code(double u, double v, double t1) {
return (v / ((u - t1) / t1)) / 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) / t1)) / t1
end function
public static double code(double u, double v, double t1) {
return (v / ((u - t1) / t1)) / t1;
}
def code(u, v, t1): return (v / ((u - t1) / t1)) / t1
function code(u, v, t1) return Float64(Float64(v / Float64(Float64(u - t1) / t1)) / t1) end
function tmp = code(u, v, t1) tmp = (v / ((u - t1) / t1)) / t1; end
code[u_, v_, t1_] := N[(N[(v / N[(N[(u - t1), $MachinePrecision] / t1), $MachinePrecision]), $MachinePrecision] / t1), $MachinePrecision]
\begin{array}{l}
\\
\frac{\frac{v}{\frac{u - t1}{t1}}}{t1}
\end{array}
Initial program 70.6%
times-frac97.5%
distribute-frac-neg97.5%
distribute-neg-frac297.5%
+-commutative97.5%
distribute-neg-in97.5%
unsub-neg97.5%
Simplified97.5%
Taylor expanded in t1 around inf 69.2%
associate-*r/73.7%
clear-num73.7%
associate-*l/73.7%
*-un-lft-identity73.7%
add-sqr-sqrt34.7%
sqrt-unprod73.9%
sqr-neg73.9%
sqrt-unprod38.9%
add-sqr-sqrt73.4%
Applied egg-rr73.4%
Final simplification73.4%
(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}
Initial program 70.6%
times-frac97.5%
distribute-frac-neg97.5%
distribute-neg-frac297.5%
+-commutative97.5%
distribute-neg-in97.5%
unsub-neg97.5%
Simplified97.5%
Taylor expanded in t1 around inf 69.2%
Taylor expanded in v around 0 65.3%
associate-*r/65.3%
neg-mul-165.3%
Simplified65.3%
Final simplification65.3%
(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(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}{u - t1}
\end{array}
Initial program 70.6%
times-frac97.5%
distribute-frac-neg97.5%
distribute-neg-frac297.5%
+-commutative97.5%
distribute-neg-in97.5%
unsub-neg97.5%
Simplified97.5%
Taylor expanded in t1 around inf 69.2%
clear-num69.2%
frac-times70.5%
*-un-lft-identity70.5%
add-sqr-sqrt32.8%
sqrt-unprod71.0%
sqr-neg71.0%
sqrt-unprod37.5%
add-sqr-sqrt70.2%
Applied egg-rr70.2%
associate-/l/68.9%
associate-/r/52.7%
*-commutative52.7%
associate-/l/44.9%
*-commutative44.9%
associate-/l*47.3%
times-frac64.9%
*-inverses64.9%
associate-*r/64.9%
metadata-eval64.9%
associate-*r*64.9%
*-commutative64.9%
associate-*r*64.9%
*-commutative64.9%
associate-*l*64.9%
metadata-eval64.9%
*-rgt-identity64.9%
Simplified64.9%
Final simplification64.9%
(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}
Initial program 70.6%
times-frac97.5%
distribute-frac-neg97.5%
distribute-neg-frac297.5%
+-commutative97.5%
distribute-neg-in97.5%
unsub-neg97.5%
Simplified97.5%
Taylor expanded in t1 around inf 60.9%
Taylor expanded in u around inf 14.7%
Final simplification14.7%
herbie shell --seed 2024050
(FPCore (u v t1)
:name "Rosa's DopplerBench"
:precision binary64
(/ (* (- t1) v) (* (+ t1 u) (+ t1 u))))