
(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 13 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 (+ t1 u)) v) (- (- u) t1)))
double code(double u, double v, double t1) {
return ((t1 / (t1 + u)) * 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 / (t1 + u)) * v) / (-u - t1)
end function
public static double code(double u, double v, double t1) {
return ((t1 / (t1 + u)) * v) / (-u - t1);
}
def code(u, v, t1): return ((t1 / (t1 + u)) * v) / (-u - t1)
function code(u, v, t1) return Float64(Float64(Float64(t1 / Float64(t1 + u)) * v) / Float64(Float64(-u) - t1)) end
function tmp = code(u, v, t1) tmp = ((t1 / (t1 + u)) * v) / (-u - t1); end
code[u_, v_, t1_] := N[(N[(N[(t1 / N[(t1 + u), $MachinePrecision]), $MachinePrecision] * v), $MachinePrecision] / N[((-u) - t1), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{\frac{t1}{t1 + u} \cdot v}{\left(-u\right) - t1}
\end{array}
Initial program 77.0%
associate-/l*76.7%
distribute-lft-neg-out76.7%
distribute-rgt-neg-in76.7%
associate-/r*85.6%
distribute-neg-frac285.6%
Simplified85.6%
distribute-frac-neg285.6%
associate-/r*76.7%
distribute-rgt-neg-in76.7%
distribute-lft-neg-out76.7%
associate-*r/77.0%
times-frac97.2%
frac-2neg97.2%
associate-*r/99.0%
add-sqr-sqrt50.4%
sqrt-unprod51.7%
sqr-neg51.7%
sqrt-unprod19.9%
add-sqr-sqrt39.2%
add-sqr-sqrt21.3%
sqrt-unprod63.1%
sqr-neg63.1%
sqrt-prod50.0%
add-sqr-sqrt99.0%
Applied egg-rr99.0%
Final simplification99.0%
(FPCore (u v t1)
:precision binary64
(let* ((t_1 (* t1 (/ (/ v (+ t1 u)) (- (- u) t1)))))
(if (<= t1 -1.35e+104)
(/ v (- (* u (- 2.0)) t1))
(if (<= t1 -4.8e-154)
t_1
(if (<= t1 -2.1e-290)
(/ (/ (* t1 v) u) (- u))
(if (<= t1 5.1e+178) t_1 (/ v (- t1))))))))
double code(double u, double v, double t1) {
double t_1 = t1 * ((v / (t1 + u)) / (-u - t1));
double tmp;
if (t1 <= -1.35e+104) {
tmp = v / ((u * -2.0) - t1);
} else if (t1 <= -4.8e-154) {
tmp = t_1;
} else if (t1 <= -2.1e-290) {
tmp = ((t1 * v) / u) / -u;
} else if (t1 <= 5.1e+178) {
tmp = t_1;
} 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) :: t_1
real(8) :: tmp
t_1 = t1 * ((v / (t1 + u)) / (-u - t1))
if (t1 <= (-1.35d+104)) then
tmp = v / ((u * -2.0d0) - t1)
else if (t1 <= (-4.8d-154)) then
tmp = t_1
else if (t1 <= (-2.1d-290)) then
tmp = ((t1 * v) / u) / -u
else if (t1 <= 5.1d+178) then
tmp = t_1
else
tmp = v / -t1
end if
code = tmp
end function
public static double code(double u, double v, double t1) {
double t_1 = t1 * ((v / (t1 + u)) / (-u - t1));
double tmp;
if (t1 <= -1.35e+104) {
tmp = v / ((u * -2.0) - t1);
} else if (t1 <= -4.8e-154) {
tmp = t_1;
} else if (t1 <= -2.1e-290) {
tmp = ((t1 * v) / u) / -u;
} else if (t1 <= 5.1e+178) {
tmp = t_1;
} else {
tmp = v / -t1;
}
return tmp;
}
def code(u, v, t1): t_1 = t1 * ((v / (t1 + u)) / (-u - t1)) tmp = 0 if t1 <= -1.35e+104: tmp = v / ((u * -2.0) - t1) elif t1 <= -4.8e-154: tmp = t_1 elif t1 <= -2.1e-290: tmp = ((t1 * v) / u) / -u elif t1 <= 5.1e+178: tmp = t_1 else: tmp = v / -t1 return tmp
function code(u, v, t1) t_1 = Float64(t1 * Float64(Float64(v / Float64(t1 + u)) / Float64(Float64(-u) - t1))) tmp = 0.0 if (t1 <= -1.35e+104) tmp = Float64(v / Float64(Float64(u * Float64(-2.0)) - t1)); elseif (t1 <= -4.8e-154) tmp = t_1; elseif (t1 <= -2.1e-290) tmp = Float64(Float64(Float64(t1 * v) / u) / Float64(-u)); elseif (t1 <= 5.1e+178) tmp = t_1; else tmp = Float64(v / Float64(-t1)); end return tmp end
function tmp_2 = code(u, v, t1) t_1 = t1 * ((v / (t1 + u)) / (-u - t1)); tmp = 0.0; if (t1 <= -1.35e+104) tmp = v / ((u * -2.0) - t1); elseif (t1 <= -4.8e-154) tmp = t_1; elseif (t1 <= -2.1e-290) tmp = ((t1 * v) / u) / -u; elseif (t1 <= 5.1e+178) tmp = t_1; else tmp = v / -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[((-u) - t1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t1, -1.35e+104], N[(v / N[(N[(u * (-2.0)), $MachinePrecision] - t1), $MachinePrecision]), $MachinePrecision], If[LessEqual[t1, -4.8e-154], t$95$1, If[LessEqual[t1, -2.1e-290], N[(N[(N[(t1 * v), $MachinePrecision] / u), $MachinePrecision] / (-u)), $MachinePrecision], If[LessEqual[t1, 5.1e+178], t$95$1, N[(v / (-t1)), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := t1 \cdot \frac{\frac{v}{t1 + u}}{\left(-u\right) - t1}\\
\mathbf{if}\;t1 \leq -1.35 \cdot 10^{+104}:\\
\;\;\;\;\frac{v}{u \cdot \left(-2\right) - t1}\\
\mathbf{elif}\;t1 \leq -4.8 \cdot 10^{-154}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t1 \leq -2.1 \cdot 10^{-290}:\\
\;\;\;\;\frac{\frac{t1 \cdot v}{u}}{-u}\\
\mathbf{elif}\;t1 \leq 5.1 \cdot 10^{+178}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;\frac{v}{-t1}\\
\end{array}
\end{array}
if t1 < -1.34999999999999992e104Initial program 49.1%
associate-/l*43.4%
distribute-lft-neg-out43.4%
distribute-rgt-neg-in43.4%
associate-/r*66.9%
distribute-neg-frac266.9%
Simplified66.9%
associate-*r/100.0%
+-commutative100.0%
distribute-neg-in100.0%
sub-neg100.0%
associate-*l/100.0%
clear-num100.0%
frac-2neg100.0%
frac-times100.0%
*-un-lft-identity100.0%
add-sqr-sqrt93.9%
sqrt-unprod51.0%
sqr-neg51.0%
sqrt-prod2.9%
add-sqr-sqrt42.4%
Applied egg-rr100.0%
Taylor expanded in u around 0 97.5%
*-commutative97.5%
Simplified97.5%
if -1.34999999999999992e104 < t1 < -4.79999999999999974e-154 or -2.1000000000000001e-290 < t1 < 5.0999999999999997e178Initial program 85.9%
associate-/l*89.0%
distribute-lft-neg-out89.0%
distribute-rgt-neg-in89.0%
associate-/r*93.4%
distribute-neg-frac293.4%
Simplified93.4%
if -4.79999999999999974e-154 < t1 < -2.1000000000000001e-290Initial program 95.9%
times-frac84.6%
distribute-frac-neg84.6%
distribute-neg-frac284.6%
+-commutative84.6%
distribute-neg-in84.6%
unsub-neg84.6%
Simplified84.6%
Taylor expanded in t1 around 0 84.5%
associate-*r/84.5%
mul-1-neg84.5%
Simplified84.5%
associate-*l/88.3%
frac-2neg88.3%
add-sqr-sqrt88.3%
sqrt-unprod50.1%
sqr-neg50.1%
sqrt-unprod0.0%
add-sqr-sqrt42.7%
distribute-lft-neg-out42.7%
add-sqr-sqrt42.7%
sqrt-unprod43.2%
sqr-neg43.2%
sqrt-unprod0.0%
add-sqr-sqrt88.3%
Applied egg-rr88.3%
Taylor expanded in t1 around 0 99.7%
if 5.0999999999999997e178 < t1 Initial program 13.6%
associate-/l*16.1%
distribute-lft-neg-out16.1%
distribute-rgt-neg-in16.1%
associate-/r*54.6%
distribute-neg-frac254.6%
Simplified54.6%
Taylor expanded in t1 around inf 100.0%
associate-*r/100.0%
neg-mul-1100.0%
Simplified100.0%
Final simplification95.0%
(FPCore (u v t1)
:precision binary64
(if (or (<= t1 -5.9e+38)
(not
(or (<= t1 4.1e-125) (and (not (<= t1 8.4e-91)) (<= t1 4.5e-46)))))
(/ v (- (* u (- 2.0)) t1))
(* (/ v u) (/ t1 (- u)))))
double code(double u, double v, double t1) {
double tmp;
if ((t1 <= -5.9e+38) || !((t1 <= 4.1e-125) || (!(t1 <= 8.4e-91) && (t1 <= 4.5e-46)))) {
tmp = v / ((u * -2.0) - t1);
} else {
tmp = (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 ((t1 <= (-5.9d+38)) .or. (.not. (t1 <= 4.1d-125) .or. (.not. (t1 <= 8.4d-91)) .and. (t1 <= 4.5d-46))) then
tmp = v / ((u * -2.0d0) - t1)
else
tmp = (v / u) * (t1 / -u)
end if
code = tmp
end function
public static double code(double u, double v, double t1) {
double tmp;
if ((t1 <= -5.9e+38) || !((t1 <= 4.1e-125) || (!(t1 <= 8.4e-91) && (t1 <= 4.5e-46)))) {
tmp = v / ((u * -2.0) - t1);
} else {
tmp = (v / u) * (t1 / -u);
}
return tmp;
}
def code(u, v, t1): tmp = 0 if (t1 <= -5.9e+38) or not ((t1 <= 4.1e-125) or (not (t1 <= 8.4e-91) and (t1 <= 4.5e-46))): tmp = v / ((u * -2.0) - t1) else: tmp = (v / u) * (t1 / -u) return tmp
function code(u, v, t1) tmp = 0.0 if ((t1 <= -5.9e+38) || !((t1 <= 4.1e-125) || (!(t1 <= 8.4e-91) && (t1 <= 4.5e-46)))) tmp = Float64(v / Float64(Float64(u * Float64(-2.0)) - t1)); else tmp = Float64(Float64(v / u) * Float64(t1 / Float64(-u))); end return tmp end
function tmp_2 = code(u, v, t1) tmp = 0.0; if ((t1 <= -5.9e+38) || ~(((t1 <= 4.1e-125) || (~((t1 <= 8.4e-91)) && (t1 <= 4.5e-46))))) tmp = v / ((u * -2.0) - t1); else tmp = (v / u) * (t1 / -u); end tmp_2 = tmp; end
code[u_, v_, t1_] := If[Or[LessEqual[t1, -5.9e+38], N[Not[Or[LessEqual[t1, 4.1e-125], And[N[Not[LessEqual[t1, 8.4e-91]], $MachinePrecision], LessEqual[t1, 4.5e-46]]]], $MachinePrecision]], N[(v / N[(N[(u * (-2.0)), $MachinePrecision] - t1), $MachinePrecision]), $MachinePrecision], N[(N[(v / u), $MachinePrecision] * N[(t1 / (-u)), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t1 \leq -5.9 \cdot 10^{+38} \lor \neg \left(t1 \leq 4.1 \cdot 10^{-125} \lor \neg \left(t1 \leq 8.4 \cdot 10^{-91}\right) \land t1 \leq 4.5 \cdot 10^{-46}\right):\\
\;\;\;\;\frac{v}{u \cdot \left(-2\right) - t1}\\
\mathbf{else}:\\
\;\;\;\;\frac{v}{u} \cdot \frac{t1}{-u}\\
\end{array}
\end{array}
if t1 < -5.89999999999999981e38 or 4.0999999999999997e-125 < t1 < 8.3999999999999997e-91 or 4.50000000000000001e-46 < t1 Initial program 62.4%
associate-/l*63.4%
distribute-lft-neg-out63.4%
distribute-rgt-neg-in63.4%
associate-/r*77.3%
distribute-neg-frac277.3%
Simplified77.3%
associate-*r/99.3%
+-commutative99.3%
distribute-neg-in99.3%
sub-neg99.3%
associate-*l/99.2%
clear-num99.2%
frac-2neg99.2%
frac-times96.8%
*-un-lft-identity96.8%
add-sqr-sqrt44.8%
sqrt-unprod45.6%
sqr-neg45.6%
sqrt-prod13.7%
add-sqr-sqrt32.3%
Applied egg-rr96.8%
Taylor expanded in u around 0 87.5%
*-commutative87.5%
Simplified87.5%
if -5.89999999999999981e38 < t1 < 4.0999999999999997e-125 or 8.3999999999999997e-91 < t1 < 4.50000000000000001e-46Initial program 91.8%
times-frac95.2%
distribute-frac-neg95.2%
distribute-neg-frac295.2%
+-commutative95.2%
distribute-neg-in95.2%
unsub-neg95.2%
Simplified95.2%
Taylor expanded in t1 around 0 80.5%
associate-*r/80.5%
mul-1-neg80.5%
Simplified80.5%
Taylor expanded in t1 around 0 81.5%
Final simplification84.5%
(FPCore (u v t1)
:precision binary64
(if (or (<= t1 -7.4e+38)
(not
(or (<= t1 4.1e-125) (and (not (<= t1 1.3e-90)) (<= t1 2.9e-46)))))
(/ v (- (- u) t1))
(* (/ v u) (/ t1 (- u)))))
double code(double u, double v, double t1) {
double tmp;
if ((t1 <= -7.4e+38) || !((t1 <= 4.1e-125) || (!(t1 <= 1.3e-90) && (t1 <= 2.9e-46)))) {
tmp = v / (-u - t1);
} else {
tmp = (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 ((t1 <= (-7.4d+38)) .or. (.not. (t1 <= 4.1d-125) .or. (.not. (t1 <= 1.3d-90)) .and. (t1 <= 2.9d-46))) then
tmp = v / (-u - t1)
else
tmp = (v / u) * (t1 / -u)
end if
code = tmp
end function
public static double code(double u, double v, double t1) {
double tmp;
if ((t1 <= -7.4e+38) || !((t1 <= 4.1e-125) || (!(t1 <= 1.3e-90) && (t1 <= 2.9e-46)))) {
tmp = v / (-u - t1);
} else {
tmp = (v / u) * (t1 / -u);
}
return tmp;
}
def code(u, v, t1): tmp = 0 if (t1 <= -7.4e+38) or not ((t1 <= 4.1e-125) or (not (t1 <= 1.3e-90) and (t1 <= 2.9e-46))): tmp = v / (-u - t1) else: tmp = (v / u) * (t1 / -u) return tmp
function code(u, v, t1) tmp = 0.0 if ((t1 <= -7.4e+38) || !((t1 <= 4.1e-125) || (!(t1 <= 1.3e-90) && (t1 <= 2.9e-46)))) tmp = Float64(v / Float64(Float64(-u) - t1)); else tmp = Float64(Float64(v / u) * Float64(t1 / Float64(-u))); end return tmp end
function tmp_2 = code(u, v, t1) tmp = 0.0; if ((t1 <= -7.4e+38) || ~(((t1 <= 4.1e-125) || (~((t1 <= 1.3e-90)) && (t1 <= 2.9e-46))))) tmp = v / (-u - t1); else tmp = (v / u) * (t1 / -u); end tmp_2 = tmp; end
code[u_, v_, t1_] := If[Or[LessEqual[t1, -7.4e+38], N[Not[Or[LessEqual[t1, 4.1e-125], And[N[Not[LessEqual[t1, 1.3e-90]], $MachinePrecision], LessEqual[t1, 2.9e-46]]]], $MachinePrecision]], N[(v / N[((-u) - t1), $MachinePrecision]), $MachinePrecision], N[(N[(v / u), $MachinePrecision] * N[(t1 / (-u)), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t1 \leq -7.4 \cdot 10^{+38} \lor \neg \left(t1 \leq 4.1 \cdot 10^{-125} \lor \neg \left(t1 \leq 1.3 \cdot 10^{-90}\right) \land t1 \leq 2.9 \cdot 10^{-46}\right):\\
\;\;\;\;\frac{v}{\left(-u\right) - t1}\\
\mathbf{else}:\\
\;\;\;\;\frac{v}{u} \cdot \frac{t1}{-u}\\
\end{array}
\end{array}
if t1 < -7.4000000000000002e38 or 4.0999999999999997e-125 < t1 < 1.3e-90 or 2.90000000000000005e-46 < t1 Initial program 62.4%
associate-/l*63.4%
distribute-lft-neg-out63.4%
distribute-rgt-neg-in63.4%
associate-/r*77.3%
distribute-neg-frac277.3%
Simplified77.3%
distribute-frac-neg277.3%
associate-/r*63.4%
distribute-rgt-neg-in63.4%
distribute-lft-neg-out63.4%
associate-*r/62.4%
times-frac99.2%
frac-2neg99.2%
associate-*r/100.0%
add-sqr-sqrt44.7%
sqrt-unprod31.3%
sqr-neg31.3%
sqrt-unprod14.8%
add-sqr-sqrt32.3%
add-sqr-sqrt18.6%
sqrt-unprod58.0%
sqr-neg58.0%
sqrt-prod53.2%
add-sqr-sqrt100.0%
Applied egg-rr100.0%
Taylor expanded in t1 around inf 87.3%
mul-1-neg87.3%
Simplified87.3%
if -7.4000000000000002e38 < t1 < 4.0999999999999997e-125 or 1.3e-90 < t1 < 2.90000000000000005e-46Initial program 91.8%
times-frac95.2%
distribute-frac-neg95.2%
distribute-neg-frac295.2%
+-commutative95.2%
distribute-neg-in95.2%
unsub-neg95.2%
Simplified95.2%
Taylor expanded in t1 around 0 80.5%
associate-*r/80.5%
mul-1-neg80.5%
Simplified80.5%
Taylor expanded in t1 around 0 81.5%
Final simplification84.4%
(FPCore (u v t1)
:precision binary64
(let* ((t_1 (/ v (- (* u (- 2.0)) t1))))
(if (<= t1 -5.9e+38)
t_1
(if (<= t1 1.35e-126)
(/ (* t1 (/ v u)) (- u))
(if (or (<= t1 8.4e-91) (not (<= t1 5e-46)))
t_1
(* (/ v u) (/ t1 (- u))))))))
double code(double u, double v, double t1) {
double t_1 = v / ((u * -2.0) - t1);
double tmp;
if (t1 <= -5.9e+38) {
tmp = t_1;
} else if (t1 <= 1.35e-126) {
tmp = (t1 * (v / u)) / -u;
} else if ((t1 <= 8.4e-91) || !(t1 <= 5e-46)) {
tmp = t_1;
} else {
tmp = (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) :: t_1
real(8) :: tmp
t_1 = v / ((u * -2.0d0) - t1)
if (t1 <= (-5.9d+38)) then
tmp = t_1
else if (t1 <= 1.35d-126) then
tmp = (t1 * (v / u)) / -u
else if ((t1 <= 8.4d-91) .or. (.not. (t1 <= 5d-46))) then
tmp = t_1
else
tmp = (v / u) * (t1 / -u)
end if
code = tmp
end function
public static double code(double u, double v, double t1) {
double t_1 = v / ((u * -2.0) - t1);
double tmp;
if (t1 <= -5.9e+38) {
tmp = t_1;
} else if (t1 <= 1.35e-126) {
tmp = (t1 * (v / u)) / -u;
} else if ((t1 <= 8.4e-91) || !(t1 <= 5e-46)) {
tmp = t_1;
} else {
tmp = (v / u) * (t1 / -u);
}
return tmp;
}
def code(u, v, t1): t_1 = v / ((u * -2.0) - t1) tmp = 0 if t1 <= -5.9e+38: tmp = t_1 elif t1 <= 1.35e-126: tmp = (t1 * (v / u)) / -u elif (t1 <= 8.4e-91) or not (t1 <= 5e-46): tmp = t_1 else: tmp = (v / u) * (t1 / -u) return tmp
function code(u, v, t1) t_1 = Float64(v / Float64(Float64(u * Float64(-2.0)) - t1)) tmp = 0.0 if (t1 <= -5.9e+38) tmp = t_1; elseif (t1 <= 1.35e-126) tmp = Float64(Float64(t1 * Float64(v / u)) / Float64(-u)); elseif ((t1 <= 8.4e-91) || !(t1 <= 5e-46)) tmp = t_1; else tmp = Float64(Float64(v / u) * Float64(t1 / Float64(-u))); end return tmp end
function tmp_2 = code(u, v, t1) t_1 = v / ((u * -2.0) - t1); tmp = 0.0; if (t1 <= -5.9e+38) tmp = t_1; elseif (t1 <= 1.35e-126) tmp = (t1 * (v / u)) / -u; elseif ((t1 <= 8.4e-91) || ~((t1 <= 5e-46))) tmp = t_1; else tmp = (v / u) * (t1 / -u); end tmp_2 = tmp; end
code[u_, v_, t1_] := Block[{t$95$1 = N[(v / N[(N[(u * (-2.0)), $MachinePrecision] - t1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t1, -5.9e+38], t$95$1, If[LessEqual[t1, 1.35e-126], N[(N[(t1 * N[(v / u), $MachinePrecision]), $MachinePrecision] / (-u)), $MachinePrecision], If[Or[LessEqual[t1, 8.4e-91], N[Not[LessEqual[t1, 5e-46]], $MachinePrecision]], t$95$1, N[(N[(v / u), $MachinePrecision] * N[(t1 / (-u)), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{v}{u \cdot \left(-2\right) - t1}\\
\mathbf{if}\;t1 \leq -5.9 \cdot 10^{+38}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t1 \leq 1.35 \cdot 10^{-126}:\\
\;\;\;\;\frac{t1 \cdot \frac{v}{u}}{-u}\\
\mathbf{elif}\;t1 \leq 8.4 \cdot 10^{-91} \lor \neg \left(t1 \leq 5 \cdot 10^{-46}\right):\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;\frac{v}{u} \cdot \frac{t1}{-u}\\
\end{array}
\end{array}
if t1 < -5.89999999999999981e38 or 1.34999999999999998e-126 < t1 < 8.3999999999999997e-91 or 4.99999999999999992e-46 < t1 Initial program 62.4%
associate-/l*63.4%
distribute-lft-neg-out63.4%
distribute-rgt-neg-in63.4%
associate-/r*77.3%
distribute-neg-frac277.3%
Simplified77.3%
associate-*r/99.3%
+-commutative99.3%
distribute-neg-in99.3%
sub-neg99.3%
associate-*l/99.2%
clear-num99.2%
frac-2neg99.2%
frac-times96.8%
*-un-lft-identity96.8%
add-sqr-sqrt44.8%
sqrt-unprod45.6%
sqr-neg45.6%
sqrt-prod13.7%
add-sqr-sqrt32.3%
Applied egg-rr96.8%
Taylor expanded in u around 0 87.5%
*-commutative87.5%
Simplified87.5%
if -5.89999999999999981e38 < t1 < 1.34999999999999998e-126Initial program 91.0%
times-frac94.7%
distribute-frac-neg94.7%
distribute-neg-frac294.7%
+-commutative94.7%
distribute-neg-in94.7%
unsub-neg94.7%
Simplified94.7%
Taylor expanded in t1 around 0 79.3%
associate-*r/79.3%
mul-1-neg79.3%
Simplified79.3%
associate-*l/81.1%
frac-2neg81.1%
add-sqr-sqrt47.1%
sqrt-unprod60.1%
sqr-neg60.1%
sqrt-unprod21.7%
add-sqr-sqrt46.1%
distribute-lft-neg-out46.1%
add-sqr-sqrt24.5%
sqrt-unprod48.0%
sqr-neg48.0%
sqrt-unprod33.9%
add-sqr-sqrt81.1%
Applied egg-rr81.1%
Taylor expanded in t1 around 0 82.8%
associate-/l*82.2%
Simplified82.2%
if 8.3999999999999997e-91 < t1 < 4.99999999999999992e-46Initial program 99.7%
times-frac99.9%
distribute-frac-neg99.9%
distribute-neg-frac299.9%
+-commutative99.9%
distribute-neg-in99.9%
unsub-neg99.9%
Simplified99.9%
Taylor expanded in t1 around 0 91.9%
associate-*r/91.9%
mul-1-neg91.9%
Simplified91.9%
Taylor expanded in t1 around 0 91.8%
Final simplification85.4%
(FPCore (u v t1) :precision binary64 (if (or (<= t1 -5.9e+38) (not (<= t1 4.5e-46))) (/ v (- (* u (- 2.0)) t1)) (/ (/ (* t1 v) u) (- u))))
double code(double u, double v, double t1) {
double tmp;
if ((t1 <= -5.9e+38) || !(t1 <= 4.5e-46)) {
tmp = v / ((u * -2.0) - 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 ((t1 <= (-5.9d+38)) .or. (.not. (t1 <= 4.5d-46))) then
tmp = v / ((u * -2.0d0) - 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 ((t1 <= -5.9e+38) || !(t1 <= 4.5e-46)) {
tmp = v / ((u * -2.0) - t1);
} else {
tmp = ((t1 * v) / u) / -u;
}
return tmp;
}
def code(u, v, t1): tmp = 0 if (t1 <= -5.9e+38) or not (t1 <= 4.5e-46): tmp = v / ((u * -2.0) - t1) else: tmp = ((t1 * v) / u) / -u return tmp
function code(u, v, t1) tmp = 0.0 if ((t1 <= -5.9e+38) || !(t1 <= 4.5e-46)) tmp = Float64(v / Float64(Float64(u * Float64(-2.0)) - t1)); else tmp = Float64(Float64(Float64(t1 * v) / u) / Float64(-u)); end return tmp end
function tmp_2 = code(u, v, t1) tmp = 0.0; if ((t1 <= -5.9e+38) || ~((t1 <= 4.5e-46))) tmp = v / ((u * -2.0) - t1); else tmp = ((t1 * v) / u) / -u; end tmp_2 = tmp; end
code[u_, v_, t1_] := If[Or[LessEqual[t1, -5.9e+38], N[Not[LessEqual[t1, 4.5e-46]], $MachinePrecision]], N[(v / N[(N[(u * (-2.0)), $MachinePrecision] - t1), $MachinePrecision]), $MachinePrecision], N[(N[(N[(t1 * v), $MachinePrecision] / u), $MachinePrecision] / (-u)), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t1 \leq -5.9 \cdot 10^{+38} \lor \neg \left(t1 \leq 4.5 \cdot 10^{-46}\right):\\
\;\;\;\;\frac{v}{u \cdot \left(-2\right) - t1}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{t1 \cdot v}{u}}{-u}\\
\end{array}
\end{array}
if t1 < -5.89999999999999981e38 or 4.50000000000000001e-46 < t1 Initial program 60.4%
associate-/l*63.0%
distribute-lft-neg-out63.0%
distribute-rgt-neg-in63.0%
associate-/r*78.0%
distribute-neg-frac278.0%
Simplified78.0%
associate-*r/100.0%
+-commutative100.0%
distribute-neg-in100.0%
sub-neg100.0%
associate-*l/99.9%
clear-num99.9%
frac-2neg99.9%
frac-times96.6%
*-un-lft-identity96.6%
add-sqr-sqrt47.3%
sqrt-unprod48.2%
sqr-neg48.2%
sqrt-prod14.7%
add-sqr-sqrt33.9%
Applied egg-rr96.6%
Taylor expanded in u around 0 88.1%
*-commutative88.1%
Simplified88.1%
if -5.89999999999999981e38 < t1 < 4.50000000000000001e-46Initial program 91.6%
times-frac94.9%
distribute-frac-neg94.9%
distribute-neg-frac294.9%
+-commutative94.9%
distribute-neg-in94.9%
unsub-neg94.9%
Simplified94.9%
Taylor expanded in t1 around 0 76.9%
associate-*r/76.9%
mul-1-neg76.9%
Simplified76.9%
associate-*l/78.4%
frac-2neg78.4%
add-sqr-sqrt39.9%
sqrt-unprod57.0%
sqr-neg57.0%
sqrt-unprod24.5%
add-sqr-sqrt45.2%
distribute-lft-neg-out45.2%
add-sqr-sqrt20.7%
sqrt-unprod50.4%
sqr-neg50.4%
sqrt-unprod38.5%
add-sqr-sqrt78.4%
Applied egg-rr78.4%
Taylor expanded in t1 around 0 80.6%
Final simplification84.1%
(FPCore (u v t1) :precision binary64 (if (or (<= u -2.7e+51) (not (<= u 1.4e+75))) (* t1 (/ (/ v u) u)) (/ v (- t1))))
double code(double u, double v, double t1) {
double tmp;
if ((u <= -2.7e+51) || !(u <= 1.4e+75)) {
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 <= (-2.7d+51)) .or. (.not. (u <= 1.4d+75))) 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 <= -2.7e+51) || !(u <= 1.4e+75)) {
tmp = t1 * ((v / u) / u);
} else {
tmp = v / -t1;
}
return tmp;
}
def code(u, v, t1): tmp = 0 if (u <= -2.7e+51) or not (u <= 1.4e+75): tmp = t1 * ((v / u) / u) else: tmp = v / -t1 return tmp
function code(u, v, t1) tmp = 0.0 if ((u <= -2.7e+51) || !(u <= 1.4e+75)) 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 <= -2.7e+51) || ~((u <= 1.4e+75))) tmp = t1 * ((v / u) / u); else tmp = v / -t1; end tmp_2 = tmp; end
code[u_, v_, t1_] := If[Or[LessEqual[u, -2.7e+51], N[Not[LessEqual[u, 1.4e+75]], $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 -2.7 \cdot 10^{+51} \lor \neg \left(u \leq 1.4 \cdot 10^{+75}\right):\\
\;\;\;\;t1 \cdot \frac{\frac{v}{u}}{u}\\
\mathbf{else}:\\
\;\;\;\;\frac{v}{-t1}\\
\end{array}
\end{array}
if u < -2.69999999999999992e51 or 1.40000000000000006e75 < u Initial program 81.9%
times-frac97.8%
distribute-frac-neg97.8%
distribute-neg-frac297.8%
+-commutative97.8%
distribute-neg-in97.8%
unsub-neg97.8%
Simplified97.8%
Taylor expanded in t1 around 0 86.6%
associate-*r/86.6%
mul-1-neg86.6%
Simplified86.6%
Taylor expanded in t1 around 0 84.7%
clear-num83.5%
frac-times74.7%
*-un-lft-identity74.7%
add-sqr-sqrt32.9%
sqrt-unprod67.1%
sqr-neg67.1%
sqrt-unprod39.5%
add-sqr-sqrt69.0%
Applied egg-rr69.0%
clear-num69.0%
*-commutative69.0%
associate-/l*68.9%
associate-/r*68.7%
associate-/l/68.7%
clear-num68.7%
associate-/l*69.7%
associate-/l*70.8%
Applied egg-rr70.8%
if -2.69999999999999992e51 < u < 1.40000000000000006e75Initial program 73.9%
associate-/l*73.1%
distribute-lft-neg-out73.1%
distribute-rgt-neg-in73.1%
associate-/r*82.4%
distribute-neg-frac282.4%
Simplified82.4%
Taylor expanded in t1 around inf 71.6%
associate-*r/71.6%
neg-mul-171.6%
Simplified71.6%
Final simplification71.3%
(FPCore (u v t1) :precision binary64 (if (<= u -5.5e+50) (* t1 (/ (/ v u) u)) (if (<= u 2.55e+81) (/ v (- t1)) (/ t1 (* u (/ u v))))))
double code(double u, double v, double t1) {
double tmp;
if (u <= -5.5e+50) {
tmp = t1 * ((v / u) / u);
} else if (u <= 2.55e+81) {
tmp = v / -t1;
} else {
tmp = t1 / (u * (u / v));
}
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+50)) then
tmp = t1 * ((v / u) / u)
else if (u <= 2.55d+81) then
tmp = v / -t1
else
tmp = t1 / (u * (u / v))
end if
code = tmp
end function
public static double code(double u, double v, double t1) {
double tmp;
if (u <= -5.5e+50) {
tmp = t1 * ((v / u) / u);
} else if (u <= 2.55e+81) {
tmp = v / -t1;
} else {
tmp = t1 / (u * (u / v));
}
return tmp;
}
def code(u, v, t1): tmp = 0 if u <= -5.5e+50: tmp = t1 * ((v / u) / u) elif u <= 2.55e+81: tmp = v / -t1 else: tmp = t1 / (u * (u / v)) return tmp
function code(u, v, t1) tmp = 0.0 if (u <= -5.5e+50) tmp = Float64(t1 * Float64(Float64(v / u) / u)); elseif (u <= 2.55e+81) tmp = Float64(v / Float64(-t1)); else tmp = Float64(t1 / Float64(u * Float64(u / v))); end return tmp end
function tmp_2 = code(u, v, t1) tmp = 0.0; if (u <= -5.5e+50) tmp = t1 * ((v / u) / u); elseif (u <= 2.55e+81) tmp = v / -t1; else tmp = t1 / (u * (u / v)); end tmp_2 = tmp; end
code[u_, v_, t1_] := If[LessEqual[u, -5.5e+50], N[(t1 * N[(N[(v / u), $MachinePrecision] / u), $MachinePrecision]), $MachinePrecision], If[LessEqual[u, 2.55e+81], N[(v / (-t1)), $MachinePrecision], N[(t1 / N[(u * N[(u / v), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;u \leq -5.5 \cdot 10^{+50}:\\
\;\;\;\;t1 \cdot \frac{\frac{v}{u}}{u}\\
\mathbf{elif}\;u \leq 2.55 \cdot 10^{+81}:\\
\;\;\;\;\frac{v}{-t1}\\
\mathbf{else}:\\
\;\;\;\;\frac{t1}{u \cdot \frac{u}{v}}\\
\end{array}
\end{array}
if u < -5.4999999999999998e50Initial program 84.2%
times-frac98.1%
distribute-frac-neg98.1%
distribute-neg-frac298.1%
+-commutative98.1%
distribute-neg-in98.1%
unsub-neg98.1%
Simplified98.1%
Taylor expanded in t1 around 0 86.5%
associate-*r/86.5%
mul-1-neg86.5%
Simplified86.5%
Taylor expanded in t1 around 0 82.8%
clear-num82.8%
frac-times79.2%
*-un-lft-identity79.2%
add-sqr-sqrt40.6%
sqrt-unprod72.8%
sqr-neg72.8%
sqrt-unprod36.4%
add-sqr-sqrt73.0%
Applied egg-rr73.0%
clear-num73.0%
*-commutative73.0%
associate-/l*73.0%
associate-/r*72.8%
associate-/l/72.8%
clear-num72.8%
associate-/l*72.9%
associate-/l*74.9%
Applied egg-rr74.9%
if -5.4999999999999998e50 < u < 2.5500000000000001e81Initial program 73.9%
associate-/l*73.1%
distribute-lft-neg-out73.1%
distribute-rgt-neg-in73.1%
associate-/r*82.4%
distribute-neg-frac282.4%
Simplified82.4%
Taylor expanded in t1 around inf 71.6%
associate-*r/71.6%
neg-mul-171.6%
Simplified71.6%
if 2.5500000000000001e81 < u Initial program 79.5%
times-frac97.4%
distribute-frac-neg97.4%
distribute-neg-frac297.4%
+-commutative97.4%
distribute-neg-in97.4%
unsub-neg97.4%
Simplified97.4%
Taylor expanded in t1 around 0 86.7%
associate-*r/86.7%
mul-1-neg86.7%
Simplified86.7%
Taylor expanded in t1 around 0 86.7%
*-commutative86.7%
clear-num86.7%
frac-times84.7%
*-un-lft-identity84.7%
add-sqr-sqrt29.0%
sqrt-unprod66.8%
sqr-neg66.8%
sqrt-unprod44.5%
add-sqr-sqrt66.6%
Applied egg-rr66.6%
Final simplification71.3%
(FPCore (u v t1) :precision binary64 (* (/ t1 (+ t1 u)) (/ v (- (- u) t1))))
double code(double u, double v, double t1) {
return (t1 / (t1 + u)) * (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 / (t1 + u)) * (v / (-u - t1))
end function
public static double code(double u, double v, double t1) {
return (t1 / (t1 + u)) * (v / (-u - t1));
}
def code(u, v, t1): return (t1 / (t1 + u)) * (v / (-u - t1))
function code(u, v, t1) return Float64(Float64(t1 / Float64(t1 + u)) * Float64(v / Float64(Float64(-u) - t1))) end
function tmp = code(u, v, t1) tmp = (t1 / (t1 + u)) * (v / (-u - t1)); end
code[u_, v_, t1_] := N[(N[(t1 / N[(t1 + u), $MachinePrecision]), $MachinePrecision] * N[(v / N[((-u) - t1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{t1}{t1 + u} \cdot \frac{v}{\left(-u\right) - t1}
\end{array}
Initial program 77.0%
times-frac97.2%
distribute-frac-neg97.2%
distribute-neg-frac297.2%
+-commutative97.2%
distribute-neg-in97.2%
unsub-neg97.2%
Simplified97.2%
Final simplification97.2%
(FPCore (u v t1) :precision binary64 (if (<= u 6.1e+159) (/ v (- t1)) (/ v (- u))))
double code(double u, double v, double t1) {
double tmp;
if (u <= 6.1e+159) {
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 <= 6.1d+159) 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 <= 6.1e+159) {
tmp = v / -t1;
} else {
tmp = v / -u;
}
return tmp;
}
def code(u, v, t1): tmp = 0 if u <= 6.1e+159: tmp = v / -t1 else: tmp = v / -u return tmp
function code(u, v, t1) tmp = 0.0 if (u <= 6.1e+159) 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 <= 6.1e+159) tmp = v / -t1; else tmp = v / -u; end tmp_2 = tmp; end
code[u_, v_, t1_] := If[LessEqual[u, 6.1e+159], N[(v / (-t1)), $MachinePrecision], N[(v / (-u)), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;u \leq 6.1 \cdot 10^{+159}:\\
\;\;\;\;\frac{v}{-t1}\\
\mathbf{else}:\\
\;\;\;\;\frac{v}{-u}\\
\end{array}
\end{array}
if u < 6.1e159Initial program 76.8%
associate-/l*76.5%
distribute-lft-neg-out76.5%
distribute-rgt-neg-in76.5%
associate-/r*84.7%
distribute-neg-frac284.7%
Simplified84.7%
Taylor expanded in t1 around inf 57.5%
associate-*r/57.5%
neg-mul-157.5%
Simplified57.5%
if 6.1e159 < u Initial program 78.2%
associate-/l*78.5%
distribute-lft-neg-out78.5%
distribute-rgt-neg-in78.5%
associate-/r*92.1%
distribute-neg-frac292.1%
Simplified92.1%
Taylor expanded in t1 around 0 85.4%
Taylor expanded in t1 around inf 43.5%
associate-*r/43.5%
mul-1-neg43.5%
Simplified43.5%
Final simplification56.0%
(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 77.0%
associate-/l*76.7%
distribute-lft-neg-out76.7%
distribute-rgt-neg-in76.7%
associate-/r*85.6%
distribute-neg-frac285.6%
Simplified85.6%
distribute-frac-neg285.6%
associate-/r*76.7%
distribute-rgt-neg-in76.7%
distribute-lft-neg-out76.7%
associate-*r/77.0%
times-frac97.2%
frac-2neg97.2%
associate-*r/99.0%
add-sqr-sqrt50.4%
sqrt-unprod51.7%
sqr-neg51.7%
sqrt-unprod19.9%
add-sqr-sqrt39.2%
add-sqr-sqrt21.3%
sqrt-unprod63.1%
sqr-neg63.1%
sqrt-prod50.0%
add-sqr-sqrt99.0%
Applied egg-rr99.0%
Taylor expanded in t1 around inf 59.8%
mul-1-neg59.8%
Simplified59.8%
Final simplification59.8%
(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 / Float64(-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 77.0%
associate-/l*76.7%
distribute-lft-neg-out76.7%
distribute-rgt-neg-in76.7%
associate-/r*85.6%
distribute-neg-frac285.6%
Simplified85.6%
Taylor expanded in t1 around inf 53.3%
associate-*r/53.3%
neg-mul-153.3%
Simplified53.3%
Final simplification53.3%
(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 77.0%
times-frac97.2%
distribute-frac-neg97.2%
distribute-neg-frac297.2%
+-commutative97.2%
distribute-neg-in97.2%
unsub-neg97.2%
Simplified97.2%
Taylor expanded in t1 around inf 55.4%
Taylor expanded in u around inf 13.8%
herbie shell --seed 2024089
(FPCore (u v t1)
:name "Rosa's DopplerBench"
:precision binary64
(/ (* (- t1) v) (* (+ t1 u) (+ t1 u))))