
(FPCore (t l k) :precision binary64 (/ 2.0 (* (* (* (/ (pow t 3.0) (* l l)) (sin k)) (tan k)) (+ (+ 1.0 (pow (/ k t) 2.0)) 1.0))))
double code(double t, double l, double k) {
return 2.0 / ((((pow(t, 3.0) / (l * l)) * sin(k)) * tan(k)) * ((1.0 + pow((k / t), 2.0)) + 1.0));
}
real(8) function code(t, l, k)
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: k
code = 2.0d0 / (((((t ** 3.0d0) / (l * l)) * sin(k)) * tan(k)) * ((1.0d0 + ((k / t) ** 2.0d0)) + 1.0d0))
end function
public static double code(double t, double l, double k) {
return 2.0 / ((((Math.pow(t, 3.0) / (l * l)) * Math.sin(k)) * Math.tan(k)) * ((1.0 + Math.pow((k / t), 2.0)) + 1.0));
}
def code(t, l, k): return 2.0 / ((((math.pow(t, 3.0) / (l * l)) * math.sin(k)) * math.tan(k)) * ((1.0 + math.pow((k / t), 2.0)) + 1.0))
function code(t, l, k) return Float64(2.0 / Float64(Float64(Float64(Float64((t ^ 3.0) / Float64(l * l)) * sin(k)) * tan(k)) * Float64(Float64(1.0 + (Float64(k / t) ^ 2.0)) + 1.0))) end
function tmp = code(t, l, k) tmp = 2.0 / (((((t ^ 3.0) / (l * l)) * sin(k)) * tan(k)) * ((1.0 + ((k / t) ^ 2.0)) + 1.0)); end
code[t_, l_, k_] := N[(2.0 / N[(N[(N[(N[(N[Power[t, 3.0], $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision] * N[Sin[k], $MachinePrecision]), $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * N[(N[(1.0 + N[Power[N[(k / t), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 18 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (t l k) :precision binary64 (/ 2.0 (* (* (* (/ (pow t 3.0) (* l l)) (sin k)) (tan k)) (+ (+ 1.0 (pow (/ k t) 2.0)) 1.0))))
double code(double t, double l, double k) {
return 2.0 / ((((pow(t, 3.0) / (l * l)) * sin(k)) * tan(k)) * ((1.0 + pow((k / t), 2.0)) + 1.0));
}
real(8) function code(t, l, k)
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: k
code = 2.0d0 / (((((t ** 3.0d0) / (l * l)) * sin(k)) * tan(k)) * ((1.0d0 + ((k / t) ** 2.0d0)) + 1.0d0))
end function
public static double code(double t, double l, double k) {
return 2.0 / ((((Math.pow(t, 3.0) / (l * l)) * Math.sin(k)) * Math.tan(k)) * ((1.0 + Math.pow((k / t), 2.0)) + 1.0));
}
def code(t, l, k): return 2.0 / ((((math.pow(t, 3.0) / (l * l)) * math.sin(k)) * math.tan(k)) * ((1.0 + math.pow((k / t), 2.0)) + 1.0))
function code(t, l, k) return Float64(2.0 / Float64(Float64(Float64(Float64((t ^ 3.0) / Float64(l * l)) * sin(k)) * tan(k)) * Float64(Float64(1.0 + (Float64(k / t) ^ 2.0)) + 1.0))) end
function tmp = code(t, l, k) tmp = 2.0 / (((((t ^ 3.0) / (l * l)) * sin(k)) * tan(k)) * ((1.0 + ((k / t) ^ 2.0)) + 1.0)); end
code[t_, l_, k_] := N[(2.0 / N[(N[(N[(N[(N[Power[t, 3.0], $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision] * N[Sin[k], $MachinePrecision]), $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * N[(N[(1.0 + N[Power[N[(k / t), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)}
\end{array}
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(let* ((t_2 (/ l (hypot 1.0 (hypot 1.0 (/ k t_m))))))
(*
t_s
(if (<= t_m 1.65e-61)
(* (/ (cos k) t_m) (pow (* l (/ (/ (sqrt 2.0) (sin k)) k)) 2.0))
(if (<= t_m 8.2e+15)
(* t_2 (* (/ (/ 2.0 (pow t_m 3.0)) (* (sin k) (tan k))) t_2))
(/
2.0
(pow
(*
t_m
(*
(pow (cbrt l) -2.0)
(* (cbrt (sin k)) (cbrt (* (tan k) (+ 2.0 (pow (/ k t_m) 2.0)))))))
3.0)))))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double t_2 = l / hypot(1.0, hypot(1.0, (k / t_m)));
double tmp;
if (t_m <= 1.65e-61) {
tmp = (cos(k) / t_m) * pow((l * ((sqrt(2.0) / sin(k)) / k)), 2.0);
} else if (t_m <= 8.2e+15) {
tmp = t_2 * (((2.0 / pow(t_m, 3.0)) / (sin(k) * tan(k))) * t_2);
} else {
tmp = 2.0 / pow((t_m * (pow(cbrt(l), -2.0) * (cbrt(sin(k)) * cbrt((tan(k) * (2.0 + pow((k / t_m), 2.0))))))), 3.0);
}
return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double t_2 = l / Math.hypot(1.0, Math.hypot(1.0, (k / t_m)));
double tmp;
if (t_m <= 1.65e-61) {
tmp = (Math.cos(k) / t_m) * Math.pow((l * ((Math.sqrt(2.0) / Math.sin(k)) / k)), 2.0);
} else if (t_m <= 8.2e+15) {
tmp = t_2 * (((2.0 / Math.pow(t_m, 3.0)) / (Math.sin(k) * Math.tan(k))) * t_2);
} else {
tmp = 2.0 / Math.pow((t_m * (Math.pow(Math.cbrt(l), -2.0) * (Math.cbrt(Math.sin(k)) * Math.cbrt((Math.tan(k) * (2.0 + Math.pow((k / t_m), 2.0))))))), 3.0);
}
return t_s * tmp;
}
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) t_2 = Float64(l / hypot(1.0, hypot(1.0, Float64(k / t_m)))) tmp = 0.0 if (t_m <= 1.65e-61) tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(Float64(sqrt(2.0) / sin(k)) / k)) ^ 2.0)); elseif (t_m <= 8.2e+15) tmp = Float64(t_2 * Float64(Float64(Float64(2.0 / (t_m ^ 3.0)) / Float64(sin(k) * tan(k))) * t_2)); else tmp = Float64(2.0 / (Float64(t_m * Float64((cbrt(l) ^ -2.0) * Float64(cbrt(sin(k)) * cbrt(Float64(tan(k) * Float64(2.0 + (Float64(k / t_m) ^ 2.0))))))) ^ 3.0)); end return Float64(t_s * tmp) end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := Block[{t$95$2 = N[(l / N[Sqrt[1.0 ^ 2 + N[Sqrt[1.0 ^ 2 + N[(k / t$95$m), $MachinePrecision] ^ 2], $MachinePrecision] ^ 2], $MachinePrecision]), $MachinePrecision]}, N[(t$95$s * If[LessEqual[t$95$m, 1.65e-61], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[(N[Sqrt[2.0], $MachinePrecision] / N[Sin[k], $MachinePrecision]), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 8.2e+15], N[(t$95$2 * N[(N[(N[(2.0 / N[Power[t$95$m, 3.0], $MachinePrecision]), $MachinePrecision] / N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * t$95$2), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[Power[N[(t$95$m * N[(N[Power[N[Power[l, 1/3], $MachinePrecision], -2.0], $MachinePrecision] * N[(N[Power[N[Sin[k], $MachinePrecision], 1/3], $MachinePrecision] * N[Power[N[(N[Tan[k], $MachinePrecision] * N[(2.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
\begin{array}{l}
t_2 := \frac{\ell}{\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t\_m}\right)\right)}\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 1.65 \cdot 10^{-61}:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\frac{\sqrt{2}}{\sin k}}{k}\right)}^{2}\\
\mathbf{elif}\;t\_m \leq 8.2 \cdot 10^{+15}:\\
\;\;\;\;t\_2 \cdot \left(\frac{\frac{2}{{t\_m}^{3}}}{\sin k \cdot \tan k} \cdot t\_2\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{{\left(t\_m \cdot \left({\left(\sqrt[3]{\ell}\right)}^{-2} \cdot \left(\sqrt[3]{\sin k} \cdot \sqrt[3]{\tan k \cdot \left(2 + {\left(\frac{k}{t\_m}\right)}^{2}\right)}\right)\right)\right)}^{3}}\\
\end{array}
\end{array}
\end{array}
if t < 1.64999999999999998e-61Initial program 52.2%
Simplified51.6%
add-sqr-sqrt33.4%
sqrt-div32.8%
sqrt-div32.8%
Applied egg-rr32.9%
unpow232.9%
Simplified33.4%
Taylor expanded in t around 0 32.0%
*-commutative32.0%
times-frac32.1%
Simplified32.1%
unpow-prod-down31.5%
pow231.5%
add-sqr-sqrt74.7%
Applied egg-rr74.7%
associate-*l/74.7%
associate-/l*74.7%
Simplified74.7%
if 1.64999999999999998e-61 < t < 8.2e15Initial program 73.1%
Simplified63.2%
associate-*r*69.5%
add-sqr-sqrt69.4%
times-frac79.4%
associate-/l/79.4%
Applied egg-rr79.4%
Simplified94.4%
if 8.2e15 < t Initial program 64.7%
Simplified66.7%
associate-*l/69.6%
Applied egg-rr69.6%
associate-*r*69.6%
Simplified69.6%
Applied egg-rr84.9%
unpow284.9%
unpow384.9%
associate-*l*84.9%
associate-*r*84.9%
Simplified84.9%
pow1/363.1%
associate-*l*63.1%
unpow-prod-down36.6%
pow1/348.3%
Applied egg-rr48.3%
unpow1/397.0%
Simplified97.0%
Final simplification81.5%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(let* ((t_2 (+ 1.0 (+ 1.0 (pow (/ k t_m) 2.0)))))
(*
t_s
(if (<=
(/ 2.0 (* t_2 (* (tan k) (* (sin k) (/ (pow t_m 3.0) (* l l))))))
1e+295)
(/ 2.0 (* t_2 (* (tan k) (* (sin k) (* (/ (pow t_m 2.0) l) (/ t_m l))))))
(* (/ (cos k) t_m) (pow (* l (/ (/ (sqrt 2.0) (sin k)) k)) 2.0))))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double t_2 = 1.0 + (1.0 + pow((k / t_m), 2.0));
double tmp;
if ((2.0 / (t_2 * (tan(k) * (sin(k) * (pow(t_m, 3.0) / (l * l)))))) <= 1e+295) {
tmp = 2.0 / (t_2 * (tan(k) * (sin(k) * ((pow(t_m, 2.0) / l) * (t_m / l)))));
} else {
tmp = (cos(k) / t_m) * pow((l * ((sqrt(2.0) / sin(k)) / k)), 2.0);
}
return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
real(8), intent (in) :: t_s
real(8), intent (in) :: t_m
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: t_2
real(8) :: tmp
t_2 = 1.0d0 + (1.0d0 + ((k / t_m) ** 2.0d0))
if ((2.0d0 / (t_2 * (tan(k) * (sin(k) * ((t_m ** 3.0d0) / (l * l)))))) <= 1d+295) then
tmp = 2.0d0 / (t_2 * (tan(k) * (sin(k) * (((t_m ** 2.0d0) / l) * (t_m / l)))))
else
tmp = (cos(k) / t_m) * ((l * ((sqrt(2.0d0) / sin(k)) / k)) ** 2.0d0)
end if
code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double t_2 = 1.0 + (1.0 + Math.pow((k / t_m), 2.0));
double tmp;
if ((2.0 / (t_2 * (Math.tan(k) * (Math.sin(k) * (Math.pow(t_m, 3.0) / (l * l)))))) <= 1e+295) {
tmp = 2.0 / (t_2 * (Math.tan(k) * (Math.sin(k) * ((Math.pow(t_m, 2.0) / l) * (t_m / l)))));
} else {
tmp = (Math.cos(k) / t_m) * Math.pow((l * ((Math.sqrt(2.0) / Math.sin(k)) / k)), 2.0);
}
return t_s * tmp;
}
t\_m = math.fabs(t) t\_s = math.copysign(1.0, t) def code(t_s, t_m, l, k): t_2 = 1.0 + (1.0 + math.pow((k / t_m), 2.0)) tmp = 0 if (2.0 / (t_2 * (math.tan(k) * (math.sin(k) * (math.pow(t_m, 3.0) / (l * l)))))) <= 1e+295: tmp = 2.0 / (t_2 * (math.tan(k) * (math.sin(k) * ((math.pow(t_m, 2.0) / l) * (t_m / l))))) else: tmp = (math.cos(k) / t_m) * math.pow((l * ((math.sqrt(2.0) / math.sin(k)) / k)), 2.0) return t_s * tmp
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) t_2 = Float64(1.0 + Float64(1.0 + (Float64(k / t_m) ^ 2.0))) tmp = 0.0 if (Float64(2.0 / Float64(t_2 * Float64(tan(k) * Float64(sin(k) * Float64((t_m ^ 3.0) / Float64(l * l)))))) <= 1e+295) tmp = Float64(2.0 / Float64(t_2 * Float64(tan(k) * Float64(sin(k) * Float64(Float64((t_m ^ 2.0) / l) * Float64(t_m / l)))))); else tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(Float64(sqrt(2.0) / sin(k)) / k)) ^ 2.0)); end return Float64(t_s * tmp) end
t\_m = abs(t); t\_s = sign(t) * abs(1.0); function tmp_2 = code(t_s, t_m, l, k) t_2 = 1.0 + (1.0 + ((k / t_m) ^ 2.0)); tmp = 0.0; if ((2.0 / (t_2 * (tan(k) * (sin(k) * ((t_m ^ 3.0) / (l * l)))))) <= 1e+295) tmp = 2.0 / (t_2 * (tan(k) * (sin(k) * (((t_m ^ 2.0) / l) * (t_m / l))))); else tmp = (cos(k) / t_m) * ((l * ((sqrt(2.0) / sin(k)) / k)) ^ 2.0); end tmp_2 = t_s * tmp; end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := Block[{t$95$2 = N[(1.0 + N[(1.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, N[(t$95$s * If[LessEqual[N[(2.0 / N[(t$95$2 * N[(N[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[(N[Power[t$95$m, 3.0], $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 1e+295], N[(2.0 / N[(t$95$2 * N[(N[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[(N[(N[Power[t$95$m, 2.0], $MachinePrecision] / l), $MachinePrecision] * N[(t$95$m / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[(N[Sqrt[2.0], $MachinePrecision] / N[Sin[k], $MachinePrecision]), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
\begin{array}{l}
t_2 := 1 + \left(1 + {\left(\frac{k}{t\_m}\right)}^{2}\right)\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;\frac{2}{t\_2 \cdot \left(\tan k \cdot \left(\sin k \cdot \frac{{t\_m}^{3}}{\ell \cdot \ell}\right)\right)} \leq 10^{+295}:\\
\;\;\;\;\frac{2}{t\_2 \cdot \left(\tan k \cdot \left(\sin k \cdot \left(\frac{{t\_m}^{2}}{\ell} \cdot \frac{t\_m}{\ell}\right)\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\frac{\sqrt{2}}{\sin k}}{k}\right)}^{2}\\
\end{array}
\end{array}
\end{array}
if (/.f64 #s(literal 2 binary64) (*.f64 (*.f64 (*.f64 (/.f64 (pow.f64 t #s(literal 3 binary64)) (*.f64 l l)) (sin.f64 k)) (tan.f64 k)) (+.f64 (+.f64 #s(literal 1 binary64) (pow.f64 (/.f64 k t) #s(literal 2 binary64))) #s(literal 1 binary64)))) < 9.9999999999999998e294Initial program 82.2%
unpow382.2%
times-frac88.6%
pow288.6%
Applied egg-rr88.6%
if 9.9999999999999998e294 < (/.f64 #s(literal 2 binary64) (*.f64 (*.f64 (*.f64 (/.f64 (pow.f64 t #s(literal 3 binary64)) (*.f64 l l)) (sin.f64 k)) (tan.f64 k)) (+.f64 (+.f64 #s(literal 1 binary64) (pow.f64 (/.f64 k t) #s(literal 2 binary64))) #s(literal 1 binary64)))) Initial program 19.5%
Simplified19.5%
add-sqr-sqrt19.5%
sqrt-div19.5%
sqrt-div19.5%
Applied egg-rr30.6%
unpow230.6%
Simplified39.9%
Taylor expanded in t around 0 49.9%
*-commutative49.9%
times-frac50.0%
Simplified50.0%
unpow-prod-down49.1%
pow249.1%
add-sqr-sqrt79.3%
Applied egg-rr79.3%
associate-*l/79.3%
associate-/l*79.3%
Simplified79.3%
Final simplification84.9%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(let* ((t_2 (pow (/ k t_m) 2.0)))
(*
t_s
(if (<=
(/
2.0
(*
(+ 1.0 (+ 1.0 t_2))
(* (tan k) (* (sin k) (/ (pow t_m 3.0) (* l l))))))
1e+295)
(* (* l (/ 2.0 (* (tan k) (* (sin k) (pow t_m 3.0))))) (/ l (+ 2.0 t_2)))
(* (/ (cos k) t_m) (pow (* l (/ (/ (sqrt 2.0) (sin k)) k)) 2.0))))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double t_2 = pow((k / t_m), 2.0);
double tmp;
if ((2.0 / ((1.0 + (1.0 + t_2)) * (tan(k) * (sin(k) * (pow(t_m, 3.0) / (l * l)))))) <= 1e+295) {
tmp = (l * (2.0 / (tan(k) * (sin(k) * pow(t_m, 3.0))))) * (l / (2.0 + t_2));
} else {
tmp = (cos(k) / t_m) * pow((l * ((sqrt(2.0) / sin(k)) / k)), 2.0);
}
return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
real(8), intent (in) :: t_s
real(8), intent (in) :: t_m
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: t_2
real(8) :: tmp
t_2 = (k / t_m) ** 2.0d0
if ((2.0d0 / ((1.0d0 + (1.0d0 + t_2)) * (tan(k) * (sin(k) * ((t_m ** 3.0d0) / (l * l)))))) <= 1d+295) then
tmp = (l * (2.0d0 / (tan(k) * (sin(k) * (t_m ** 3.0d0))))) * (l / (2.0d0 + t_2))
else
tmp = (cos(k) / t_m) * ((l * ((sqrt(2.0d0) / sin(k)) / k)) ** 2.0d0)
end if
code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double t_2 = Math.pow((k / t_m), 2.0);
double tmp;
if ((2.0 / ((1.0 + (1.0 + t_2)) * (Math.tan(k) * (Math.sin(k) * (Math.pow(t_m, 3.0) / (l * l)))))) <= 1e+295) {
tmp = (l * (2.0 / (Math.tan(k) * (Math.sin(k) * Math.pow(t_m, 3.0))))) * (l / (2.0 + t_2));
} else {
tmp = (Math.cos(k) / t_m) * Math.pow((l * ((Math.sqrt(2.0) / Math.sin(k)) / k)), 2.0);
}
return t_s * tmp;
}
t\_m = math.fabs(t) t\_s = math.copysign(1.0, t) def code(t_s, t_m, l, k): t_2 = math.pow((k / t_m), 2.0) tmp = 0 if (2.0 / ((1.0 + (1.0 + t_2)) * (math.tan(k) * (math.sin(k) * (math.pow(t_m, 3.0) / (l * l)))))) <= 1e+295: tmp = (l * (2.0 / (math.tan(k) * (math.sin(k) * math.pow(t_m, 3.0))))) * (l / (2.0 + t_2)) else: tmp = (math.cos(k) / t_m) * math.pow((l * ((math.sqrt(2.0) / math.sin(k)) / k)), 2.0) return t_s * tmp
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) t_2 = Float64(k / t_m) ^ 2.0 tmp = 0.0 if (Float64(2.0 / Float64(Float64(1.0 + Float64(1.0 + t_2)) * Float64(tan(k) * Float64(sin(k) * Float64((t_m ^ 3.0) / Float64(l * l)))))) <= 1e+295) tmp = Float64(Float64(l * Float64(2.0 / Float64(tan(k) * Float64(sin(k) * (t_m ^ 3.0))))) * Float64(l / Float64(2.0 + t_2))); else tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(Float64(sqrt(2.0) / sin(k)) / k)) ^ 2.0)); end return Float64(t_s * tmp) end
t\_m = abs(t); t\_s = sign(t) * abs(1.0); function tmp_2 = code(t_s, t_m, l, k) t_2 = (k / t_m) ^ 2.0; tmp = 0.0; if ((2.0 / ((1.0 + (1.0 + t_2)) * (tan(k) * (sin(k) * ((t_m ^ 3.0) / (l * l)))))) <= 1e+295) tmp = (l * (2.0 / (tan(k) * (sin(k) * (t_m ^ 3.0))))) * (l / (2.0 + t_2)); else tmp = (cos(k) / t_m) * ((l * ((sqrt(2.0) / sin(k)) / k)) ^ 2.0); end tmp_2 = t_s * tmp; end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := Block[{t$95$2 = N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]}, N[(t$95$s * If[LessEqual[N[(2.0 / N[(N[(1.0 + N[(1.0 + t$95$2), $MachinePrecision]), $MachinePrecision] * N[(N[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[(N[Power[t$95$m, 3.0], $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 1e+295], N[(N[(l * N[(2.0 / N[(N[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[Power[t$95$m, 3.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / N[(2.0 + t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[(N[Sqrt[2.0], $MachinePrecision] / N[Sin[k], $MachinePrecision]), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
\begin{array}{l}
t_2 := {\left(\frac{k}{t\_m}\right)}^{2}\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;\frac{2}{\left(1 + \left(1 + t\_2\right)\right) \cdot \left(\tan k \cdot \left(\sin k \cdot \frac{{t\_m}^{3}}{\ell \cdot \ell}\right)\right)} \leq 10^{+295}:\\
\;\;\;\;\left(\ell \cdot \frac{2}{\tan k \cdot \left(\sin k \cdot {t\_m}^{3}\right)}\right) \cdot \frac{\ell}{2 + t\_2}\\
\mathbf{else}:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\frac{\sqrt{2}}{\sin k}}{k}\right)}^{2}\\
\end{array}
\end{array}
\end{array}
if (/.f64 #s(literal 2 binary64) (*.f64 (*.f64 (*.f64 (/.f64 (pow.f64 t #s(literal 3 binary64)) (*.f64 l l)) (sin.f64 k)) (tan.f64 k)) (+.f64 (+.f64 #s(literal 1 binary64) (pow.f64 (/.f64 k t) #s(literal 2 binary64))) #s(literal 1 binary64)))) < 9.9999999999999998e294Initial program 82.2%
Simplified80.9%
associate-*r*83.5%
*-un-lft-identity83.5%
times-frac85.3%
associate-/l/85.3%
Applied egg-rr85.3%
if 9.9999999999999998e294 < (/.f64 #s(literal 2 binary64) (*.f64 (*.f64 (*.f64 (/.f64 (pow.f64 t #s(literal 3 binary64)) (*.f64 l l)) (sin.f64 k)) (tan.f64 k)) (+.f64 (+.f64 #s(literal 1 binary64) (pow.f64 (/.f64 k t) #s(literal 2 binary64))) #s(literal 1 binary64)))) Initial program 19.5%
Simplified19.5%
add-sqr-sqrt19.5%
sqrt-div19.5%
sqrt-div19.5%
Applied egg-rr30.6%
unpow230.6%
Simplified39.9%
Taylor expanded in t around 0 49.9%
*-commutative49.9%
times-frac50.0%
Simplified50.0%
unpow-prod-down49.1%
pow249.1%
add-sqr-sqrt79.3%
Applied egg-rr79.3%
associate-*l/79.3%
associate-/l*79.3%
Simplified79.3%
Final simplification82.9%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(let* ((t_2 (pow (cbrt l) -2.0)))
(*
t_s
(if (<= k 9.5e-69)
(/ 2.0 (pow (* t_m (* t_2 (* (cbrt (sin k)) (cbrt (* k 2.0))))) 3.0))
(if (<= k 1.1e+94)
(/
2.0
(pow
(*
t_m
(* t_2 (cbrt (* (* (sin k) (tan k)) (+ 2.0 (pow (/ k t_m) 2.0))))))
3.0))
(* (/ (cos k) t_m) (pow (* (/ (sqrt 2.0) (sin k)) (/ l k)) 2.0)))))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double t_2 = pow(cbrt(l), -2.0);
double tmp;
if (k <= 9.5e-69) {
tmp = 2.0 / pow((t_m * (t_2 * (cbrt(sin(k)) * cbrt((k * 2.0))))), 3.0);
} else if (k <= 1.1e+94) {
tmp = 2.0 / pow((t_m * (t_2 * cbrt(((sin(k) * tan(k)) * (2.0 + pow((k / t_m), 2.0)))))), 3.0);
} else {
tmp = (cos(k) / t_m) * pow(((sqrt(2.0) / sin(k)) * (l / k)), 2.0);
}
return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double t_2 = Math.pow(Math.cbrt(l), -2.0);
double tmp;
if (k <= 9.5e-69) {
tmp = 2.0 / Math.pow((t_m * (t_2 * (Math.cbrt(Math.sin(k)) * Math.cbrt((k * 2.0))))), 3.0);
} else if (k <= 1.1e+94) {
tmp = 2.0 / Math.pow((t_m * (t_2 * Math.cbrt(((Math.sin(k) * Math.tan(k)) * (2.0 + Math.pow((k / t_m), 2.0)))))), 3.0);
} else {
tmp = (Math.cos(k) / t_m) * Math.pow(((Math.sqrt(2.0) / Math.sin(k)) * (l / k)), 2.0);
}
return t_s * tmp;
}
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) t_2 = cbrt(l) ^ -2.0 tmp = 0.0 if (k <= 9.5e-69) tmp = Float64(2.0 / (Float64(t_m * Float64(t_2 * Float64(cbrt(sin(k)) * cbrt(Float64(k * 2.0))))) ^ 3.0)); elseif (k <= 1.1e+94) tmp = Float64(2.0 / (Float64(t_m * Float64(t_2 * cbrt(Float64(Float64(sin(k) * tan(k)) * Float64(2.0 + (Float64(k / t_m) ^ 2.0)))))) ^ 3.0)); else tmp = Float64(Float64(cos(k) / t_m) * (Float64(Float64(sqrt(2.0) / sin(k)) * Float64(l / k)) ^ 2.0)); end return Float64(t_s * tmp) end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := Block[{t$95$2 = N[Power[N[Power[l, 1/3], $MachinePrecision], -2.0], $MachinePrecision]}, N[(t$95$s * If[LessEqual[k, 9.5e-69], N[(2.0 / N[Power[N[(t$95$m * N[(t$95$2 * N[(N[Power[N[Sin[k], $MachinePrecision], 1/3], $MachinePrecision] * N[Power[N[(k * 2.0), $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 1.1e+94], N[(2.0 / N[Power[N[(t$95$m * N[(t$95$2 * N[Power[N[(N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * N[(2.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(N[(N[Sqrt[2.0], $MachinePrecision] / N[Sin[k], $MachinePrecision]), $MachinePrecision] * N[(l / k), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
\begin{array}{l}
t_2 := {\left(\sqrt[3]{\ell}\right)}^{-2}\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 9.5 \cdot 10^{-69}:\\
\;\;\;\;\frac{2}{{\left(t\_m \cdot \left(t\_2 \cdot \left(\sqrt[3]{\sin k} \cdot \sqrt[3]{k \cdot 2}\right)\right)\right)}^{3}}\\
\mathbf{elif}\;k \leq 1.1 \cdot 10^{+94}:\\
\;\;\;\;\frac{2}{{\left(t\_m \cdot \left(t\_2 \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t\_m}\right)}^{2}\right)}\right)\right)}^{3}}\\
\mathbf{else}:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\frac{\sqrt{2}}{\sin k} \cdot \frac{\ell}{k}\right)}^{2}\\
\end{array}
\end{array}
\end{array}
if k < 9.50000000000000094e-69Initial program 58.2%
Simplified60.5%
associate-*l/62.4%
Applied egg-rr62.4%
associate-*r*62.4%
Simplified62.4%
Applied egg-rr78.0%
unpow278.0%
unpow378.0%
associate-*l*78.0%
associate-*r*78.0%
Simplified78.0%
pow1/365.7%
associate-*l*65.7%
unpow-prod-down35.1%
pow1/344.9%
Applied egg-rr44.9%
unpow1/389.5%
Simplified89.5%
Taylor expanded in k around 0 78.4%
*-commutative78.4%
Simplified78.4%
if 9.50000000000000094e-69 < k < 1.10000000000000006e94Initial program 61.1%
Simplified66.5%
associate-*l/68.4%
Applied egg-rr68.4%
associate-*r*68.5%
Simplified68.5%
Applied egg-rr81.0%
unpow281.0%
unpow381.0%
associate-*l*81.2%
associate-*r*81.2%
Simplified81.2%
if 1.10000000000000006e94 < k Initial program 46.9%
Simplified44.6%
add-sqr-sqrt42.2%
sqrt-div42.1%
sqrt-div42.1%
Applied egg-rr39.9%
unpow239.9%
Simplified44.2%
Taylor expanded in t around 0 39.2%
*-commutative39.2%
times-frac39.4%
Simplified39.4%
*-commutative39.4%
unpow-prod-down37.3%
pow237.3%
add-sqr-sqrt93.0%
Applied egg-rr93.0%
Final simplification81.3%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= k 2.2e-68)
(/
2.0
(pow
(* t_m (* (pow (cbrt l) -2.0) (* (cbrt (sin k)) (cbrt (* k 2.0)))))
3.0))
(if (<= k 3.55e+93)
(/
2.0
(*
(* (tan k) (* (sin k) (pow (/ (pow t_m 1.5) l) 2.0)))
(+ 1.0 (+ 1.0 (pow (/ k t_m) 2.0)))))
(* (/ (cos k) t_m) (pow (* (/ (sqrt 2.0) (sin k)) (/ l k)) 2.0))))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double tmp;
if (k <= 2.2e-68) {
tmp = 2.0 / pow((t_m * (pow(cbrt(l), -2.0) * (cbrt(sin(k)) * cbrt((k * 2.0))))), 3.0);
} else if (k <= 3.55e+93) {
tmp = 2.0 / ((tan(k) * (sin(k) * pow((pow(t_m, 1.5) / l), 2.0))) * (1.0 + (1.0 + pow((k / t_m), 2.0))));
} else {
tmp = (cos(k) / t_m) * pow(((sqrt(2.0) / sin(k)) * (l / k)), 2.0);
}
return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double tmp;
if (k <= 2.2e-68) {
tmp = 2.0 / Math.pow((t_m * (Math.pow(Math.cbrt(l), -2.0) * (Math.cbrt(Math.sin(k)) * Math.cbrt((k * 2.0))))), 3.0);
} else if (k <= 3.55e+93) {
tmp = 2.0 / ((Math.tan(k) * (Math.sin(k) * Math.pow((Math.pow(t_m, 1.5) / l), 2.0))) * (1.0 + (1.0 + Math.pow((k / t_m), 2.0))));
} else {
tmp = (Math.cos(k) / t_m) * Math.pow(((Math.sqrt(2.0) / Math.sin(k)) * (l / k)), 2.0);
}
return t_s * tmp;
}
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) tmp = 0.0 if (k <= 2.2e-68) tmp = Float64(2.0 / (Float64(t_m * Float64((cbrt(l) ^ -2.0) * Float64(cbrt(sin(k)) * cbrt(Float64(k * 2.0))))) ^ 3.0)); elseif (k <= 3.55e+93) tmp = Float64(2.0 / Float64(Float64(tan(k) * Float64(sin(k) * (Float64((t_m ^ 1.5) / l) ^ 2.0))) * Float64(1.0 + Float64(1.0 + (Float64(k / t_m) ^ 2.0))))); else tmp = Float64(Float64(cos(k) / t_m) * (Float64(Float64(sqrt(2.0) / sin(k)) * Float64(l / k)) ^ 2.0)); end return Float64(t_s * tmp) end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[k, 2.2e-68], N[(2.0 / N[Power[N[(t$95$m * N[(N[Power[N[Power[l, 1/3], $MachinePrecision], -2.0], $MachinePrecision] * N[(N[Power[N[Sin[k], $MachinePrecision], 1/3], $MachinePrecision] * N[Power[N[(k * 2.0), $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 3.55e+93], N[(2.0 / N[(N[(N[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[Power[N[(N[Power[t$95$m, 1.5], $MachinePrecision] / l), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(1.0 + N[(1.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(N[(N[Sqrt[2.0], $MachinePrecision] / N[Sin[k], $MachinePrecision]), $MachinePrecision] * N[(l / k), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 2.2 \cdot 10^{-68}:\\
\;\;\;\;\frac{2}{{\left(t\_m \cdot \left({\left(\sqrt[3]{\ell}\right)}^{-2} \cdot \left(\sqrt[3]{\sin k} \cdot \sqrt[3]{k \cdot 2}\right)\right)\right)}^{3}}\\
\mathbf{elif}\;k \leq 3.55 \cdot 10^{+93}:\\
\;\;\;\;\frac{2}{\left(\tan k \cdot \left(\sin k \cdot {\left(\frac{{t\_m}^{1.5}}{\ell}\right)}^{2}\right)\right) \cdot \left(1 + \left(1 + {\left(\frac{k}{t\_m}\right)}^{2}\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\frac{\sqrt{2}}{\sin k} \cdot \frac{\ell}{k}\right)}^{2}\\
\end{array}
\end{array}
if k < 2.20000000000000002e-68Initial program 58.2%
Simplified60.5%
associate-*l/62.4%
Applied egg-rr62.4%
associate-*r*62.4%
Simplified62.4%
Applied egg-rr78.0%
unpow278.0%
unpow378.0%
associate-*l*78.0%
associate-*r*78.0%
Simplified78.0%
pow1/365.7%
associate-*l*65.7%
unpow-prod-down35.1%
pow1/344.9%
Applied egg-rr44.9%
unpow1/389.5%
Simplified89.5%
Taylor expanded in k around 0 78.4%
*-commutative78.4%
Simplified78.4%
if 2.20000000000000002e-68 < k < 3.5500000000000002e93Initial program 61.1%
add-sqr-sqrt29.0%
pow229.0%
sqrt-div29.0%
sqrt-pow129.0%
metadata-eval29.0%
sqrt-prod13.1%
add-sqr-sqrt34.1%
Applied egg-rr34.1%
if 3.5500000000000002e93 < k Initial program 46.9%
Simplified44.6%
add-sqr-sqrt42.2%
sqrt-div42.1%
sqrt-div42.1%
Applied egg-rr39.9%
unpow239.9%
Simplified44.2%
Taylor expanded in t around 0 39.2%
*-commutative39.2%
times-frac39.4%
Simplified39.4%
*-commutative39.4%
unpow-prod-down37.3%
pow237.3%
add-sqr-sqrt93.0%
Applied egg-rr93.0%
Final simplification74.3%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(let* ((t_2 (pow (/ k t_m) 2.0)))
(*
t_s
(if (<= t_m 20000000000.0)
(* (/ (cos k) t_m) (pow (* (/ (sqrt 2.0) (sin k)) (/ l k)) 2.0))
(if (<= t_m 5.2e+102)
(*
(* l (/ 2.0 (* (tan k) (* (sin k) (pow t_m 3.0)))))
(/ l (+ 2.0 t_2)))
(/
2.0
(*
(* (tan k) (* (sin k) (pow (/ (pow t_m 1.5) l) 2.0)))
(+ 1.0 (+ 1.0 t_2)))))))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double t_2 = pow((k / t_m), 2.0);
double tmp;
if (t_m <= 20000000000.0) {
tmp = (cos(k) / t_m) * pow(((sqrt(2.0) / sin(k)) * (l / k)), 2.0);
} else if (t_m <= 5.2e+102) {
tmp = (l * (2.0 / (tan(k) * (sin(k) * pow(t_m, 3.0))))) * (l / (2.0 + t_2));
} else {
tmp = 2.0 / ((tan(k) * (sin(k) * pow((pow(t_m, 1.5) / l), 2.0))) * (1.0 + (1.0 + t_2)));
}
return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
real(8), intent (in) :: t_s
real(8), intent (in) :: t_m
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: t_2
real(8) :: tmp
t_2 = (k / t_m) ** 2.0d0
if (t_m <= 20000000000.0d0) then
tmp = (cos(k) / t_m) * (((sqrt(2.0d0) / sin(k)) * (l / k)) ** 2.0d0)
else if (t_m <= 5.2d+102) then
tmp = (l * (2.0d0 / (tan(k) * (sin(k) * (t_m ** 3.0d0))))) * (l / (2.0d0 + t_2))
else
tmp = 2.0d0 / ((tan(k) * (sin(k) * (((t_m ** 1.5d0) / l) ** 2.0d0))) * (1.0d0 + (1.0d0 + t_2)))
end if
code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double t_2 = Math.pow((k / t_m), 2.0);
double tmp;
if (t_m <= 20000000000.0) {
tmp = (Math.cos(k) / t_m) * Math.pow(((Math.sqrt(2.0) / Math.sin(k)) * (l / k)), 2.0);
} else if (t_m <= 5.2e+102) {
tmp = (l * (2.0 / (Math.tan(k) * (Math.sin(k) * Math.pow(t_m, 3.0))))) * (l / (2.0 + t_2));
} else {
tmp = 2.0 / ((Math.tan(k) * (Math.sin(k) * Math.pow((Math.pow(t_m, 1.5) / l), 2.0))) * (1.0 + (1.0 + t_2)));
}
return t_s * tmp;
}
t\_m = math.fabs(t) t\_s = math.copysign(1.0, t) def code(t_s, t_m, l, k): t_2 = math.pow((k / t_m), 2.0) tmp = 0 if t_m <= 20000000000.0: tmp = (math.cos(k) / t_m) * math.pow(((math.sqrt(2.0) / math.sin(k)) * (l / k)), 2.0) elif t_m <= 5.2e+102: tmp = (l * (2.0 / (math.tan(k) * (math.sin(k) * math.pow(t_m, 3.0))))) * (l / (2.0 + t_2)) else: tmp = 2.0 / ((math.tan(k) * (math.sin(k) * math.pow((math.pow(t_m, 1.5) / l), 2.0))) * (1.0 + (1.0 + t_2))) return t_s * tmp
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) t_2 = Float64(k / t_m) ^ 2.0 tmp = 0.0 if (t_m <= 20000000000.0) tmp = Float64(Float64(cos(k) / t_m) * (Float64(Float64(sqrt(2.0) / sin(k)) * Float64(l / k)) ^ 2.0)); elseif (t_m <= 5.2e+102) tmp = Float64(Float64(l * Float64(2.0 / Float64(tan(k) * Float64(sin(k) * (t_m ^ 3.0))))) * Float64(l / Float64(2.0 + t_2))); else tmp = Float64(2.0 / Float64(Float64(tan(k) * Float64(sin(k) * (Float64((t_m ^ 1.5) / l) ^ 2.0))) * Float64(1.0 + Float64(1.0 + t_2)))); end return Float64(t_s * tmp) end
t\_m = abs(t); t\_s = sign(t) * abs(1.0); function tmp_2 = code(t_s, t_m, l, k) t_2 = (k / t_m) ^ 2.0; tmp = 0.0; if (t_m <= 20000000000.0) tmp = (cos(k) / t_m) * (((sqrt(2.0) / sin(k)) * (l / k)) ^ 2.0); elseif (t_m <= 5.2e+102) tmp = (l * (2.0 / (tan(k) * (sin(k) * (t_m ^ 3.0))))) * (l / (2.0 + t_2)); else tmp = 2.0 / ((tan(k) * (sin(k) * (((t_m ^ 1.5) / l) ^ 2.0))) * (1.0 + (1.0 + t_2))); end tmp_2 = t_s * tmp; end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := Block[{t$95$2 = N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]}, N[(t$95$s * If[LessEqual[t$95$m, 20000000000.0], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(N[(N[Sqrt[2.0], $MachinePrecision] / N[Sin[k], $MachinePrecision]), $MachinePrecision] * N[(l / k), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 5.2e+102], N[(N[(l * N[(2.0 / N[(N[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[Power[t$95$m, 3.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / N[(2.0 + t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(N[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[Power[N[(N[Power[t$95$m, 1.5], $MachinePrecision] / l), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(1.0 + N[(1.0 + t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
\begin{array}{l}
t_2 := {\left(\frac{k}{t\_m}\right)}^{2}\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 20000000000:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\frac{\sqrt{2}}{\sin k} \cdot \frac{\ell}{k}\right)}^{2}\\
\mathbf{elif}\;t\_m \leq 5.2 \cdot 10^{+102}:\\
\;\;\;\;\left(\ell \cdot \frac{2}{\tan k \cdot \left(\sin k \cdot {t\_m}^{3}\right)}\right) \cdot \frac{\ell}{2 + t\_2}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(\tan k \cdot \left(\sin k \cdot {\left(\frac{{t\_m}^{1.5}}{\ell}\right)}^{2}\right)\right) \cdot \left(1 + \left(1 + t\_2\right)\right)}\\
\end{array}
\end{array}
\end{array}
if t < 2e10Initial program 53.8%
Simplified52.2%
add-sqr-sqrt35.1%
sqrt-div33.5%
sqrt-div33.5%
Applied egg-rr34.7%
unpow234.7%
Simplified36.7%
Taylor expanded in t around 0 33.5%
*-commutative33.5%
times-frac33.5%
Simplified33.5%
*-commutative33.5%
unpow-prod-down33.1%
pow233.1%
add-sqr-sqrt74.5%
Applied egg-rr74.5%
if 2e10 < t < 5.20000000000000013e102Initial program 74.0%
Simplified78.8%
associate-*r*89.3%
*-un-lft-identity89.3%
times-frac94.3%
associate-/l/94.4%
Applied egg-rr94.4%
if 5.20000000000000013e102 < t Initial program 62.6%
add-sqr-sqrt62.6%
pow262.6%
sqrt-div62.6%
sqrt-pow171.6%
metadata-eval71.6%
sqrt-prod40.3%
add-sqr-sqrt89.1%
Applied egg-rr89.1%
Final simplification78.5%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= t_m 51000000000.0)
(* (/ (cos k) t_m) (pow (* (/ (sqrt 2.0) (sin k)) (/ l k)) 2.0))
(if (<= t_m 3.8e+93)
(*
(/ l (+ 2.0 (pow (/ k t_m) 2.0)))
(/ (* l 2.0) (* (pow t_m 3.0) (* (sin k) (tan k)))))
(/
2.0
(/ (pow (* (/ t_m (cbrt l)) (cbrt (* 2.0 (pow k 2.0)))) 3.0) l))))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double tmp;
if (t_m <= 51000000000.0) {
tmp = (cos(k) / t_m) * pow(((sqrt(2.0) / sin(k)) * (l / k)), 2.0);
} else if (t_m <= 3.8e+93) {
tmp = (l / (2.0 + pow((k / t_m), 2.0))) * ((l * 2.0) / (pow(t_m, 3.0) * (sin(k) * tan(k))));
} else {
tmp = 2.0 / (pow(((t_m / cbrt(l)) * cbrt((2.0 * pow(k, 2.0)))), 3.0) / l);
}
return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double tmp;
if (t_m <= 51000000000.0) {
tmp = (Math.cos(k) / t_m) * Math.pow(((Math.sqrt(2.0) / Math.sin(k)) * (l / k)), 2.0);
} else if (t_m <= 3.8e+93) {
tmp = (l / (2.0 + Math.pow((k / t_m), 2.0))) * ((l * 2.0) / (Math.pow(t_m, 3.0) * (Math.sin(k) * Math.tan(k))));
} else {
tmp = 2.0 / (Math.pow(((t_m / Math.cbrt(l)) * Math.cbrt((2.0 * Math.pow(k, 2.0)))), 3.0) / l);
}
return t_s * tmp;
}
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) tmp = 0.0 if (t_m <= 51000000000.0) tmp = Float64(Float64(cos(k) / t_m) * (Float64(Float64(sqrt(2.0) / sin(k)) * Float64(l / k)) ^ 2.0)); elseif (t_m <= 3.8e+93) tmp = Float64(Float64(l / Float64(2.0 + (Float64(k / t_m) ^ 2.0))) * Float64(Float64(l * 2.0) / Float64((t_m ^ 3.0) * Float64(sin(k) * tan(k))))); else tmp = Float64(2.0 / Float64((Float64(Float64(t_m / cbrt(l)) * cbrt(Float64(2.0 * (k ^ 2.0)))) ^ 3.0) / l)); end return Float64(t_s * tmp) end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[t$95$m, 51000000000.0], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(N[(N[Sqrt[2.0], $MachinePrecision] / N[Sin[k], $MachinePrecision]), $MachinePrecision] * N[(l / k), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 3.8e+93], N[(N[(l / N[(2.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(l * 2.0), $MachinePrecision] / N[(N[Power[t$95$m, 3.0], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[Power[N[(N[(t$95$m / N[Power[l, 1/3], $MachinePrecision]), $MachinePrecision] * N[Power[N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 51000000000:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\frac{\sqrt{2}}{\sin k} \cdot \frac{\ell}{k}\right)}^{2}\\
\mathbf{elif}\;t\_m \leq 3.8 \cdot 10^{+93}:\\
\;\;\;\;\frac{\ell}{2 + {\left(\frac{k}{t\_m}\right)}^{2}} \cdot \frac{\ell \cdot 2}{{t\_m}^{3} \cdot \left(\sin k \cdot \tan k\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\frac{{\left(\frac{t\_m}{\sqrt[3]{\ell}} \cdot \sqrt[3]{2 \cdot {k}^{2}}\right)}^{3}}{\ell}}\\
\end{array}
\end{array}
if t < 5.1e10Initial program 53.8%
Simplified52.2%
add-sqr-sqrt35.1%
sqrt-div33.5%
sqrt-div33.5%
Applied egg-rr34.7%
unpow234.7%
Simplified36.7%
Taylor expanded in t around 0 33.5%
*-commutative33.5%
times-frac33.5%
Simplified33.5%
*-commutative33.5%
unpow-prod-down33.1%
pow233.1%
add-sqr-sqrt74.5%
Applied egg-rr74.5%
if 5.1e10 < t < 3.7999999999999998e93Initial program 76.6%
Simplified81.9%
associate-*r*88.1%
*-un-lft-identity88.1%
times-frac93.6%
associate-/l/93.8%
Applied egg-rr93.8%
/-rgt-identity93.8%
associate-*l/93.8%
associate-*l*81.9%
Simplified81.9%
if 3.7999999999999998e93 < t Initial program 62.2%
Simplified66.7%
Taylor expanded in k around 0 66.7%
associate-*l/66.7%
Applied egg-rr66.7%
add-cube-cbrt66.7%
pow366.7%
cbrt-prod66.7%
cbrt-div66.7%
unpow366.7%
add-cbrt-cube79.3%
Applied egg-rr79.3%
Final simplification75.9%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= t_m 17500000000.0)
(* (/ (cos k) t_m) (pow (* (/ (sqrt 2.0) (sin k)) (/ l k)) 2.0))
(if (<= t_m 2.2e+93)
(*
l
(/
2.0
(*
(+ 2.0 (pow (/ k t_m) 2.0))
(* (* (sin k) (tan k)) (/ (pow t_m 3.0) l)))))
(/
2.0
(/ (pow (* (/ t_m (cbrt l)) (cbrt (* 2.0 (pow k 2.0)))) 3.0) l))))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double tmp;
if (t_m <= 17500000000.0) {
tmp = (cos(k) / t_m) * pow(((sqrt(2.0) / sin(k)) * (l / k)), 2.0);
} else if (t_m <= 2.2e+93) {
tmp = l * (2.0 / ((2.0 + pow((k / t_m), 2.0)) * ((sin(k) * tan(k)) * (pow(t_m, 3.0) / l))));
} else {
tmp = 2.0 / (pow(((t_m / cbrt(l)) * cbrt((2.0 * pow(k, 2.0)))), 3.0) / l);
}
return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double tmp;
if (t_m <= 17500000000.0) {
tmp = (Math.cos(k) / t_m) * Math.pow(((Math.sqrt(2.0) / Math.sin(k)) * (l / k)), 2.0);
} else if (t_m <= 2.2e+93) {
tmp = l * (2.0 / ((2.0 + Math.pow((k / t_m), 2.0)) * ((Math.sin(k) * Math.tan(k)) * (Math.pow(t_m, 3.0) / l))));
} else {
tmp = 2.0 / (Math.pow(((t_m / Math.cbrt(l)) * Math.cbrt((2.0 * Math.pow(k, 2.0)))), 3.0) / l);
}
return t_s * tmp;
}
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) tmp = 0.0 if (t_m <= 17500000000.0) tmp = Float64(Float64(cos(k) / t_m) * (Float64(Float64(sqrt(2.0) / sin(k)) * Float64(l / k)) ^ 2.0)); elseif (t_m <= 2.2e+93) tmp = Float64(l * Float64(2.0 / Float64(Float64(2.0 + (Float64(k / t_m) ^ 2.0)) * Float64(Float64(sin(k) * tan(k)) * Float64((t_m ^ 3.0) / l))))); else tmp = Float64(2.0 / Float64((Float64(Float64(t_m / cbrt(l)) * cbrt(Float64(2.0 * (k ^ 2.0)))) ^ 3.0) / l)); end return Float64(t_s * tmp) end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[t$95$m, 17500000000.0], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(N[(N[Sqrt[2.0], $MachinePrecision] / N[Sin[k], $MachinePrecision]), $MachinePrecision] * N[(l / k), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 2.2e+93], N[(l * N[(2.0 / N[(N[(2.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * N[(N[Power[t$95$m, 3.0], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[Power[N[(N[(t$95$m / N[Power[l, 1/3], $MachinePrecision]), $MachinePrecision] * N[Power[N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 17500000000:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\frac{\sqrt{2}}{\sin k} \cdot \frac{\ell}{k}\right)}^{2}\\
\mathbf{elif}\;t\_m \leq 2.2 \cdot 10^{+93}:\\
\;\;\;\;\ell \cdot \frac{2}{\left(2 + {\left(\frac{k}{t\_m}\right)}^{2}\right) \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \frac{{t\_m}^{3}}{\ell}\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\frac{{\left(\frac{t\_m}{\sqrt[3]{\ell}} \cdot \sqrt[3]{2 \cdot {k}^{2}}\right)}^{3}}{\ell}}\\
\end{array}
\end{array}
if t < 1.75e10Initial program 53.8%
Simplified52.2%
add-sqr-sqrt35.1%
sqrt-div33.5%
sqrt-div33.5%
Applied egg-rr34.7%
unpow234.7%
Simplified36.7%
Taylor expanded in t around 0 33.5%
*-commutative33.5%
times-frac33.5%
Simplified33.5%
*-commutative33.5%
unpow-prod-down33.1%
pow233.1%
add-sqr-sqrt74.5%
Applied egg-rr74.5%
if 1.75e10 < t < 2.20000000000000021e93Initial program 76.6%
Simplified70.7%
associate-*l/82.0%
Applied egg-rr82.0%
associate-*r*82.0%
Simplified82.0%
associate-/r/81.8%
Applied egg-rr81.8%
if 2.20000000000000021e93 < t Initial program 62.2%
Simplified66.7%
Taylor expanded in k around 0 66.7%
associate-*l/66.7%
Applied egg-rr66.7%
add-cube-cbrt66.7%
pow366.7%
cbrt-prod66.7%
cbrt-div66.7%
unpow366.7%
add-cbrt-cube79.3%
Applied egg-rr79.3%
Final simplification75.9%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= t_m 9e+89)
(* (/ (cos k) t_m) (pow (* l (/ (/ (sqrt 2.0) (sin k)) k)) 2.0))
(/ 2.0 (/ (pow (* (/ t_m (cbrt l)) (cbrt (* 2.0 (pow k 2.0)))) 3.0) l)))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double tmp;
if (t_m <= 9e+89) {
tmp = (cos(k) / t_m) * pow((l * ((sqrt(2.0) / sin(k)) / k)), 2.0);
} else {
tmp = 2.0 / (pow(((t_m / cbrt(l)) * cbrt((2.0 * pow(k, 2.0)))), 3.0) / l);
}
return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double tmp;
if (t_m <= 9e+89) {
tmp = (Math.cos(k) / t_m) * Math.pow((l * ((Math.sqrt(2.0) / Math.sin(k)) / k)), 2.0);
} else {
tmp = 2.0 / (Math.pow(((t_m / Math.cbrt(l)) * Math.cbrt((2.0 * Math.pow(k, 2.0)))), 3.0) / l);
}
return t_s * tmp;
}
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) tmp = 0.0 if (t_m <= 9e+89) tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(Float64(sqrt(2.0) / sin(k)) / k)) ^ 2.0)); else tmp = Float64(2.0 / Float64((Float64(Float64(t_m / cbrt(l)) * cbrt(Float64(2.0 * (k ^ 2.0)))) ^ 3.0) / l)); end return Float64(t_s * tmp) end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[t$95$m, 9e+89], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[(N[Sqrt[2.0], $MachinePrecision] / N[Sin[k], $MachinePrecision]), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[Power[N[(N[(t$95$m / N[Power[l, 1/3], $MachinePrecision]), $MachinePrecision] * N[Power[N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 9 \cdot 10^{+89}:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\frac{\sqrt{2}}{\sin k}}{k}\right)}^{2}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\frac{{\left(\frac{t\_m}{\sqrt[3]{\ell}} \cdot \sqrt[3]{2 \cdot {k}^{2}}\right)}^{3}}{\ell}}\\
\end{array}
\end{array}
if t < 9e89Initial program 55.5%
Simplified54.5%
add-sqr-sqrt38.2%
sqrt-div36.7%
sqrt-div36.7%
Applied egg-rr36.8%
unpow236.8%
Simplified38.1%
Taylor expanded in t around 0 33.5%
*-commutative33.5%
times-frac33.5%
Simplified33.5%
unpow-prod-down33.1%
pow233.1%
add-sqr-sqrt73.3%
Applied egg-rr73.3%
associate-*l/73.3%
associate-/l*73.3%
Simplified73.3%
if 9e89 < t Initial program 62.2%
Simplified66.7%
Taylor expanded in k around 0 66.7%
associate-*l/66.7%
Applied egg-rr66.7%
add-cube-cbrt66.7%
pow366.7%
cbrt-prod66.7%
cbrt-div66.7%
unpow366.7%
add-cbrt-cube79.3%
Applied egg-rr79.3%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= t_m 7.5e+101)
(* (/ (cos k) t_m) (pow (* l (/ (/ (sqrt 2.0) (sin k)) k)) 2.0))
(/ 2.0 (* (* 2.0 (pow k 2.0)) (pow (* t_m (pow (cbrt l) -2.0)) 3.0))))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double tmp;
if (t_m <= 7.5e+101) {
tmp = (cos(k) / t_m) * pow((l * ((sqrt(2.0) / sin(k)) / k)), 2.0);
} else {
tmp = 2.0 / ((2.0 * pow(k, 2.0)) * pow((t_m * pow(cbrt(l), -2.0)), 3.0));
}
return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double tmp;
if (t_m <= 7.5e+101) {
tmp = (Math.cos(k) / t_m) * Math.pow((l * ((Math.sqrt(2.0) / Math.sin(k)) / k)), 2.0);
} else {
tmp = 2.0 / ((2.0 * Math.pow(k, 2.0)) * Math.pow((t_m * Math.pow(Math.cbrt(l), -2.0)), 3.0));
}
return t_s * tmp;
}
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) tmp = 0.0 if (t_m <= 7.5e+101) tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(Float64(sqrt(2.0) / sin(k)) / k)) ^ 2.0)); else tmp = Float64(2.0 / Float64(Float64(2.0 * (k ^ 2.0)) * (Float64(t_m * (cbrt(l) ^ -2.0)) ^ 3.0))); end return Float64(t_s * tmp) end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[t$95$m, 7.5e+101], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[(N[Sqrt[2.0], $MachinePrecision] / N[Sin[k], $MachinePrecision]), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[Power[N[(t$95$m * N[Power[N[Power[l, 1/3], $MachinePrecision], -2.0], $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 7.5 \cdot 10^{+101}:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\frac{\sqrt{2}}{\sin k}}{k}\right)}^{2}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(2 \cdot {k}^{2}\right) \cdot {\left(t\_m \cdot {\left(\sqrt[3]{\ell}\right)}^{-2}\right)}^{3}}\\
\end{array}
\end{array}
if t < 7.4999999999999995e101Initial program 55.5%
Simplified54.5%
add-sqr-sqrt38.3%
sqrt-div36.9%
sqrt-div36.9%
Applied egg-rr37.0%
unpow237.0%
Simplified37.8%
Taylor expanded in t around 0 33.2%
*-commutative33.2%
times-frac33.2%
Simplified33.2%
unpow-prod-down32.8%
pow232.8%
add-sqr-sqrt73.1%
Applied egg-rr73.1%
associate-*l/73.1%
associate-/l*73.1%
Simplified73.1%
if 7.4999999999999995e101 < t Initial program 62.6%
Simplified67.4%
Taylor expanded in k around 0 67.4%
add-cube-cbrt67.4%
pow367.4%
associate-/l/58.0%
pow258.0%
cbrt-div58.0%
unpow358.0%
add-cbrt-cube67.1%
pow267.1%
cbrt-unprod80.3%
unpow280.3%
div-inv80.3%
unpow-prod-down58.3%
pow-flip58.3%
metadata-eval58.3%
Applied egg-rr58.3%
cube-prod80.3%
Simplified80.3%
Final simplification74.4%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= t_m 5e+101)
(* (/ (cos k) t_m) (pow (* l (/ (/ (sqrt 2.0) (sin k)) k)) 2.0))
(/
2.0
(* (* 2.0 (pow k 2.0)) (* (pow t_m 1.5) (/ (/ (pow t_m 1.5) l) l)))))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double tmp;
if (t_m <= 5e+101) {
tmp = (cos(k) / t_m) * pow((l * ((sqrt(2.0) / sin(k)) / k)), 2.0);
} else {
tmp = 2.0 / ((2.0 * pow(k, 2.0)) * (pow(t_m, 1.5) * ((pow(t_m, 1.5) / l) / l)));
}
return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
real(8), intent (in) :: t_s
real(8), intent (in) :: t_m
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: tmp
if (t_m <= 5d+101) then
tmp = (cos(k) / t_m) * ((l * ((sqrt(2.0d0) / sin(k)) / k)) ** 2.0d0)
else
tmp = 2.0d0 / ((2.0d0 * (k ** 2.0d0)) * ((t_m ** 1.5d0) * (((t_m ** 1.5d0) / l) / l)))
end if
code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double tmp;
if (t_m <= 5e+101) {
tmp = (Math.cos(k) / t_m) * Math.pow((l * ((Math.sqrt(2.0) / Math.sin(k)) / k)), 2.0);
} else {
tmp = 2.0 / ((2.0 * Math.pow(k, 2.0)) * (Math.pow(t_m, 1.5) * ((Math.pow(t_m, 1.5) / l) / l)));
}
return t_s * tmp;
}
t\_m = math.fabs(t) t\_s = math.copysign(1.0, t) def code(t_s, t_m, l, k): tmp = 0 if t_m <= 5e+101: tmp = (math.cos(k) / t_m) * math.pow((l * ((math.sqrt(2.0) / math.sin(k)) / k)), 2.0) else: tmp = 2.0 / ((2.0 * math.pow(k, 2.0)) * (math.pow(t_m, 1.5) * ((math.pow(t_m, 1.5) / l) / l))) return t_s * tmp
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) tmp = 0.0 if (t_m <= 5e+101) tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(Float64(sqrt(2.0) / sin(k)) / k)) ^ 2.0)); else tmp = Float64(2.0 / Float64(Float64(2.0 * (k ^ 2.0)) * Float64((t_m ^ 1.5) * Float64(Float64((t_m ^ 1.5) / l) / l)))); end return Float64(t_s * tmp) end
t\_m = abs(t); t\_s = sign(t) * abs(1.0); function tmp_2 = code(t_s, t_m, l, k) tmp = 0.0; if (t_m <= 5e+101) tmp = (cos(k) / t_m) * ((l * ((sqrt(2.0) / sin(k)) / k)) ^ 2.0); else tmp = 2.0 / ((2.0 * (k ^ 2.0)) * ((t_m ^ 1.5) * (((t_m ^ 1.5) / l) / l))); end tmp_2 = t_s * tmp; end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[t$95$m, 5e+101], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[(N[Sqrt[2.0], $MachinePrecision] / N[Sin[k], $MachinePrecision]), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[(N[Power[t$95$m, 1.5], $MachinePrecision] * N[(N[(N[Power[t$95$m, 1.5], $MachinePrecision] / l), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 5 \cdot 10^{+101}:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\frac{\sqrt{2}}{\sin k}}{k}\right)}^{2}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(2 \cdot {k}^{2}\right) \cdot \left({t\_m}^{1.5} \cdot \frac{\frac{{t\_m}^{1.5}}{\ell}}{\ell}\right)}\\
\end{array}
\end{array}
if t < 4.99999999999999989e101Initial program 55.5%
Simplified54.5%
add-sqr-sqrt38.3%
sqrt-div36.9%
sqrt-div36.9%
Applied egg-rr37.0%
unpow237.0%
Simplified37.8%
Taylor expanded in t around 0 33.2%
*-commutative33.2%
times-frac33.2%
Simplified33.2%
unpow-prod-down32.8%
pow232.8%
add-sqr-sqrt73.1%
Applied egg-rr73.1%
associate-*l/73.1%
associate-/l*73.1%
Simplified73.1%
if 4.99999999999999989e101 < t Initial program 62.6%
Simplified67.4%
Taylor expanded in k around 0 67.4%
metadata-eval67.4%
pow-prod-up67.4%
associate-*r/76.1%
associate-/l*78.4%
Applied egg-rr78.4%
Final simplification74.0%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= t_m 1.8e-46)
(pow (* (/ (* l (sqrt 2.0)) (pow k 2.0)) (sqrt (/ 1.0 t_m))) 2.0)
(/
2.0
(* (* 2.0 (pow k 2.0)) (* (pow t_m 1.5) (/ (/ (pow t_m 1.5) l) l)))))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double tmp;
if (t_m <= 1.8e-46) {
tmp = pow((((l * sqrt(2.0)) / pow(k, 2.0)) * sqrt((1.0 / t_m))), 2.0);
} else {
tmp = 2.0 / ((2.0 * pow(k, 2.0)) * (pow(t_m, 1.5) * ((pow(t_m, 1.5) / l) / l)));
}
return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
real(8), intent (in) :: t_s
real(8), intent (in) :: t_m
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: tmp
if (t_m <= 1.8d-46) then
tmp = (((l * sqrt(2.0d0)) / (k ** 2.0d0)) * sqrt((1.0d0 / t_m))) ** 2.0d0
else
tmp = 2.0d0 / ((2.0d0 * (k ** 2.0d0)) * ((t_m ** 1.5d0) * (((t_m ** 1.5d0) / l) / l)))
end if
code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double tmp;
if (t_m <= 1.8e-46) {
tmp = Math.pow((((l * Math.sqrt(2.0)) / Math.pow(k, 2.0)) * Math.sqrt((1.0 / t_m))), 2.0);
} else {
tmp = 2.0 / ((2.0 * Math.pow(k, 2.0)) * (Math.pow(t_m, 1.5) * ((Math.pow(t_m, 1.5) / l) / l)));
}
return t_s * tmp;
}
t\_m = math.fabs(t) t\_s = math.copysign(1.0, t) def code(t_s, t_m, l, k): tmp = 0 if t_m <= 1.8e-46: tmp = math.pow((((l * math.sqrt(2.0)) / math.pow(k, 2.0)) * math.sqrt((1.0 / t_m))), 2.0) else: tmp = 2.0 / ((2.0 * math.pow(k, 2.0)) * (math.pow(t_m, 1.5) * ((math.pow(t_m, 1.5) / l) / l))) return t_s * tmp
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) tmp = 0.0 if (t_m <= 1.8e-46) tmp = Float64(Float64(Float64(l * sqrt(2.0)) / (k ^ 2.0)) * sqrt(Float64(1.0 / t_m))) ^ 2.0; else tmp = Float64(2.0 / Float64(Float64(2.0 * (k ^ 2.0)) * Float64((t_m ^ 1.5) * Float64(Float64((t_m ^ 1.5) / l) / l)))); end return Float64(t_s * tmp) end
t\_m = abs(t); t\_s = sign(t) * abs(1.0); function tmp_2 = code(t_s, t_m, l, k) tmp = 0.0; if (t_m <= 1.8e-46) tmp = (((l * sqrt(2.0)) / (k ^ 2.0)) * sqrt((1.0 / t_m))) ^ 2.0; else tmp = 2.0 / ((2.0 * (k ^ 2.0)) * ((t_m ^ 1.5) * (((t_m ^ 1.5) / l) / l))); end tmp_2 = t_s * tmp; end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[t$95$m, 1.8e-46], N[Power[N[(N[(N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] / N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(1.0 / t$95$m), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision], N[(2.0 / N[(N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[(N[Power[t$95$m, 1.5], $MachinePrecision] * N[(N[(N[Power[t$95$m, 1.5], $MachinePrecision] / l), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 1.8 \cdot 10^{-46}:\\
\;\;\;\;{\left(\frac{\ell \cdot \sqrt{2}}{{k}^{2}} \cdot \sqrt{\frac{1}{t\_m}}\right)}^{2}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(2 \cdot {k}^{2}\right) \cdot \left({t\_m}^{1.5} \cdot \frac{\frac{{t\_m}^{1.5}}{\ell}}{\ell}\right)}\\
\end{array}
\end{array}
if t < 1.8e-46Initial program 52.2%
Simplified51.6%
add-sqr-sqrt33.8%
sqrt-div33.2%
sqrt-div33.2%
Applied egg-rr33.8%
unpow233.8%
Simplified34.9%
Taylor expanded in t around 0 33.0%
*-commutative33.0%
times-frac33.0%
Simplified33.0%
Taylor expanded in k around 0 18.6%
if 1.8e-46 < t Initial program 67.6%
Simplified68.2%
Taylor expanded in k around 0 64.3%
metadata-eval64.3%
pow-prod-up64.3%
associate-*r/69.5%
associate-/l*70.8%
Applied egg-rr70.8%
Final simplification34.1%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= k 7.2e+111)
(/ 2.0 (* (* 2.0 (pow k 2.0)) (* (pow t_m 1.5) (/ (/ (pow t_m 1.5) l) l))))
(/ (* 2.0 (pow l 2.0)) (* t_m (pow k 4.0))))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double tmp;
if (k <= 7.2e+111) {
tmp = 2.0 / ((2.0 * pow(k, 2.0)) * (pow(t_m, 1.5) * ((pow(t_m, 1.5) / l) / l)));
} else {
tmp = (2.0 * pow(l, 2.0)) / (t_m * pow(k, 4.0));
}
return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
real(8), intent (in) :: t_s
real(8), intent (in) :: t_m
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: tmp
if (k <= 7.2d+111) then
tmp = 2.0d0 / ((2.0d0 * (k ** 2.0d0)) * ((t_m ** 1.5d0) * (((t_m ** 1.5d0) / l) / l)))
else
tmp = (2.0d0 * (l ** 2.0d0)) / (t_m * (k ** 4.0d0))
end if
code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double tmp;
if (k <= 7.2e+111) {
tmp = 2.0 / ((2.0 * Math.pow(k, 2.0)) * (Math.pow(t_m, 1.5) * ((Math.pow(t_m, 1.5) / l) / l)));
} else {
tmp = (2.0 * Math.pow(l, 2.0)) / (t_m * Math.pow(k, 4.0));
}
return t_s * tmp;
}
t\_m = math.fabs(t) t\_s = math.copysign(1.0, t) def code(t_s, t_m, l, k): tmp = 0 if k <= 7.2e+111: tmp = 2.0 / ((2.0 * math.pow(k, 2.0)) * (math.pow(t_m, 1.5) * ((math.pow(t_m, 1.5) / l) / l))) else: tmp = (2.0 * math.pow(l, 2.0)) / (t_m * math.pow(k, 4.0)) return t_s * tmp
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) tmp = 0.0 if (k <= 7.2e+111) tmp = Float64(2.0 / Float64(Float64(2.0 * (k ^ 2.0)) * Float64((t_m ^ 1.5) * Float64(Float64((t_m ^ 1.5) / l) / l)))); else tmp = Float64(Float64(2.0 * (l ^ 2.0)) / Float64(t_m * (k ^ 4.0))); end return Float64(t_s * tmp) end
t\_m = abs(t); t\_s = sign(t) * abs(1.0); function tmp_2 = code(t_s, t_m, l, k) tmp = 0.0; if (k <= 7.2e+111) tmp = 2.0 / ((2.0 * (k ^ 2.0)) * ((t_m ^ 1.5) * (((t_m ^ 1.5) / l) / l))); else tmp = (2.0 * (l ^ 2.0)) / (t_m * (k ^ 4.0)); end tmp_2 = t_s * tmp; end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[k, 7.2e+111], N[(2.0 / N[(N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[(N[Power[t$95$m, 1.5], $MachinePrecision] * N[(N[(N[Power[t$95$m, 1.5], $MachinePrecision] / l), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(2.0 * N[Power[l, 2.0], $MachinePrecision]), $MachinePrecision] / N[(t$95$m * N[Power[k, 4.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 7.2 \cdot 10^{+111}:\\
\;\;\;\;\frac{2}{\left(2 \cdot {k}^{2}\right) \cdot \left({t\_m}^{1.5} \cdot \frac{\frac{{t\_m}^{1.5}}{\ell}}{\ell}\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2 \cdot {\ell}^{2}}{t\_m \cdot {k}^{4}}\\
\end{array}
\end{array}
if k < 7.2000000000000004e111Initial program 57.7%
Simplified60.4%
Taylor expanded in k around 0 58.3%
metadata-eval58.3%
pow-prod-up29.6%
associate-*r/31.9%
associate-/l*32.9%
Applied egg-rr32.9%
if 7.2000000000000004e111 < k Initial program 51.4%
Simplified51.3%
add-sqr-sqrt48.6%
sqrt-div48.6%
sqrt-div48.6%
Applied egg-rr41.0%
unpow241.0%
Simplified46.0%
Taylor expanded in t around 0 40.3%
*-commutative40.3%
times-frac40.4%
Simplified40.4%
Taylor expanded in k around 0 57.8%
*-commutative57.8%
unpow257.8%
rem-square-sqrt57.8%
*-commutative57.8%
Simplified57.8%
Final simplification36.5%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= k 7.5e+111)
(/ 2.0 (* (* t_m (/ (pow t_m 2.0) l)) (/ (* 2.0 (pow k 2.0)) l)))
(/ (* 2.0 (pow l 2.0)) (* t_m (pow k 4.0))))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double tmp;
if (k <= 7.5e+111) {
tmp = 2.0 / ((t_m * (pow(t_m, 2.0) / l)) * ((2.0 * pow(k, 2.0)) / l));
} else {
tmp = (2.0 * pow(l, 2.0)) / (t_m * pow(k, 4.0));
}
return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
real(8), intent (in) :: t_s
real(8), intent (in) :: t_m
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: tmp
if (k <= 7.5d+111) then
tmp = 2.0d0 / ((t_m * ((t_m ** 2.0d0) / l)) * ((2.0d0 * (k ** 2.0d0)) / l))
else
tmp = (2.0d0 * (l ** 2.0d0)) / (t_m * (k ** 4.0d0))
end if
code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double tmp;
if (k <= 7.5e+111) {
tmp = 2.0 / ((t_m * (Math.pow(t_m, 2.0) / l)) * ((2.0 * Math.pow(k, 2.0)) / l));
} else {
tmp = (2.0 * Math.pow(l, 2.0)) / (t_m * Math.pow(k, 4.0));
}
return t_s * tmp;
}
t\_m = math.fabs(t) t\_s = math.copysign(1.0, t) def code(t_s, t_m, l, k): tmp = 0 if k <= 7.5e+111: tmp = 2.0 / ((t_m * (math.pow(t_m, 2.0) / l)) * ((2.0 * math.pow(k, 2.0)) / l)) else: tmp = (2.0 * math.pow(l, 2.0)) / (t_m * math.pow(k, 4.0)) return t_s * tmp
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) tmp = 0.0 if (k <= 7.5e+111) tmp = Float64(2.0 / Float64(Float64(t_m * Float64((t_m ^ 2.0) / l)) * Float64(Float64(2.0 * (k ^ 2.0)) / l))); else tmp = Float64(Float64(2.0 * (l ^ 2.0)) / Float64(t_m * (k ^ 4.0))); end return Float64(t_s * tmp) end
t\_m = abs(t); t\_s = sign(t) * abs(1.0); function tmp_2 = code(t_s, t_m, l, k) tmp = 0.0; if (k <= 7.5e+111) tmp = 2.0 / ((t_m * ((t_m ^ 2.0) / l)) * ((2.0 * (k ^ 2.0)) / l)); else tmp = (2.0 * (l ^ 2.0)) / (t_m * (k ^ 4.0)); end tmp_2 = t_s * tmp; end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[k, 7.5e+111], N[(2.0 / N[(N[(t$95$m * N[(N[Power[t$95$m, 2.0], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision] * N[(N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(2.0 * N[Power[l, 2.0], $MachinePrecision]), $MachinePrecision] / N[(t$95$m * N[Power[k, 4.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 7.5 \cdot 10^{+111}:\\
\;\;\;\;\frac{2}{\left(t\_m \cdot \frac{{t\_m}^{2}}{\ell}\right) \cdot \frac{2 \cdot {k}^{2}}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2 \cdot {\ell}^{2}}{t\_m \cdot {k}^{4}}\\
\end{array}
\end{array}
if k < 7.49999999999999948e111Initial program 57.7%
Simplified60.4%
Taylor expanded in k around 0 58.3%
associate-*l/58.6%
Applied egg-rr58.6%
associate-/l*59.1%
Simplified59.1%
cube-mult59.1%
*-un-lft-identity59.1%
times-frac61.0%
pow261.0%
Applied egg-rr61.0%
if 7.49999999999999948e111 < k Initial program 51.4%
Simplified51.3%
add-sqr-sqrt48.6%
sqrt-div48.6%
sqrt-div48.6%
Applied egg-rr41.0%
unpow241.0%
Simplified46.0%
Taylor expanded in t around 0 40.3%
*-commutative40.3%
times-frac40.4%
Simplified40.4%
Taylor expanded in k around 0 57.8%
*-commutative57.8%
unpow257.8%
rem-square-sqrt57.8%
*-commutative57.8%
Simplified57.8%
Final simplification60.5%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= k 4.7e+111)
(/ 2.0 (* (/ (* 2.0 (pow k 2.0)) l) (* (pow t_m 3.0) (/ 1.0 l))))
(/ (* 2.0 (pow l 2.0)) (* t_m (pow k 4.0))))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double tmp;
if (k <= 4.7e+111) {
tmp = 2.0 / (((2.0 * pow(k, 2.0)) / l) * (pow(t_m, 3.0) * (1.0 / l)));
} else {
tmp = (2.0 * pow(l, 2.0)) / (t_m * pow(k, 4.0));
}
return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
real(8), intent (in) :: t_s
real(8), intent (in) :: t_m
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: tmp
if (k <= 4.7d+111) then
tmp = 2.0d0 / (((2.0d0 * (k ** 2.0d0)) / l) * ((t_m ** 3.0d0) * (1.0d0 / l)))
else
tmp = (2.0d0 * (l ** 2.0d0)) / (t_m * (k ** 4.0d0))
end if
code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double tmp;
if (k <= 4.7e+111) {
tmp = 2.0 / (((2.0 * Math.pow(k, 2.0)) / l) * (Math.pow(t_m, 3.0) * (1.0 / l)));
} else {
tmp = (2.0 * Math.pow(l, 2.0)) / (t_m * Math.pow(k, 4.0));
}
return t_s * tmp;
}
t\_m = math.fabs(t) t\_s = math.copysign(1.0, t) def code(t_s, t_m, l, k): tmp = 0 if k <= 4.7e+111: tmp = 2.0 / (((2.0 * math.pow(k, 2.0)) / l) * (math.pow(t_m, 3.0) * (1.0 / l))) else: tmp = (2.0 * math.pow(l, 2.0)) / (t_m * math.pow(k, 4.0)) return t_s * tmp
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) tmp = 0.0 if (k <= 4.7e+111) tmp = Float64(2.0 / Float64(Float64(Float64(2.0 * (k ^ 2.0)) / l) * Float64((t_m ^ 3.0) * Float64(1.0 / l)))); else tmp = Float64(Float64(2.0 * (l ^ 2.0)) / Float64(t_m * (k ^ 4.0))); end return Float64(t_s * tmp) end
t\_m = abs(t); t\_s = sign(t) * abs(1.0); function tmp_2 = code(t_s, t_m, l, k) tmp = 0.0; if (k <= 4.7e+111) tmp = 2.0 / (((2.0 * (k ^ 2.0)) / l) * ((t_m ^ 3.0) * (1.0 / l))); else tmp = (2.0 * (l ^ 2.0)) / (t_m * (k ^ 4.0)); end tmp_2 = t_s * tmp; end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[k, 4.7e+111], N[(2.0 / N[(N[(N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision] * N[(N[Power[t$95$m, 3.0], $MachinePrecision] * N[(1.0 / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(2.0 * N[Power[l, 2.0], $MachinePrecision]), $MachinePrecision] / N[(t$95$m * N[Power[k, 4.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 4.7 \cdot 10^{+111}:\\
\;\;\;\;\frac{2}{\frac{2 \cdot {k}^{2}}{\ell} \cdot \left({t\_m}^{3} \cdot \frac{1}{\ell}\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2 \cdot {\ell}^{2}}{t\_m \cdot {k}^{4}}\\
\end{array}
\end{array}
if k < 4.70000000000000008e111Initial program 57.7%
Simplified60.4%
Taylor expanded in k around 0 58.3%
associate-*l/58.6%
Applied egg-rr58.6%
associate-/l*59.1%
Simplified59.1%
div-inv59.1%
Applied egg-rr59.1%
if 4.70000000000000008e111 < k Initial program 51.4%
Simplified51.3%
add-sqr-sqrt48.6%
sqrt-div48.6%
sqrt-div48.6%
Applied egg-rr41.0%
unpow241.0%
Simplified46.0%
Taylor expanded in t around 0 40.3%
*-commutative40.3%
times-frac40.4%
Simplified40.4%
Taylor expanded in k around 0 57.8%
*-commutative57.8%
unpow257.8%
rem-square-sqrt57.8%
*-commutative57.8%
Simplified57.8%
Final simplification58.9%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= k 7.4e+111)
(/ 2.0 (* (/ (pow t_m 3.0) l) (/ (* 2.0 (pow k 2.0)) l)))
(/ (* 2.0 (pow l 2.0)) (* t_m (pow k 4.0))))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double tmp;
if (k <= 7.4e+111) {
tmp = 2.0 / ((pow(t_m, 3.0) / l) * ((2.0 * pow(k, 2.0)) / l));
} else {
tmp = (2.0 * pow(l, 2.0)) / (t_m * pow(k, 4.0));
}
return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
real(8), intent (in) :: t_s
real(8), intent (in) :: t_m
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: tmp
if (k <= 7.4d+111) then
tmp = 2.0d0 / (((t_m ** 3.0d0) / l) * ((2.0d0 * (k ** 2.0d0)) / l))
else
tmp = (2.0d0 * (l ** 2.0d0)) / (t_m * (k ** 4.0d0))
end if
code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double tmp;
if (k <= 7.4e+111) {
tmp = 2.0 / ((Math.pow(t_m, 3.0) / l) * ((2.0 * Math.pow(k, 2.0)) / l));
} else {
tmp = (2.0 * Math.pow(l, 2.0)) / (t_m * Math.pow(k, 4.0));
}
return t_s * tmp;
}
t\_m = math.fabs(t) t\_s = math.copysign(1.0, t) def code(t_s, t_m, l, k): tmp = 0 if k <= 7.4e+111: tmp = 2.0 / ((math.pow(t_m, 3.0) / l) * ((2.0 * math.pow(k, 2.0)) / l)) else: tmp = (2.0 * math.pow(l, 2.0)) / (t_m * math.pow(k, 4.0)) return t_s * tmp
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) tmp = 0.0 if (k <= 7.4e+111) tmp = Float64(2.0 / Float64(Float64((t_m ^ 3.0) / l) * Float64(Float64(2.0 * (k ^ 2.0)) / l))); else tmp = Float64(Float64(2.0 * (l ^ 2.0)) / Float64(t_m * (k ^ 4.0))); end return Float64(t_s * tmp) end
t\_m = abs(t); t\_s = sign(t) * abs(1.0); function tmp_2 = code(t_s, t_m, l, k) tmp = 0.0; if (k <= 7.4e+111) tmp = 2.0 / (((t_m ^ 3.0) / l) * ((2.0 * (k ^ 2.0)) / l)); else tmp = (2.0 * (l ^ 2.0)) / (t_m * (k ^ 4.0)); end tmp_2 = t_s * tmp; end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[k, 7.4e+111], N[(2.0 / N[(N[(N[Power[t$95$m, 3.0], $MachinePrecision] / l), $MachinePrecision] * N[(N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(2.0 * N[Power[l, 2.0], $MachinePrecision]), $MachinePrecision] / N[(t$95$m * N[Power[k, 4.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 7.4 \cdot 10^{+111}:\\
\;\;\;\;\frac{2}{\frac{{t\_m}^{3}}{\ell} \cdot \frac{2 \cdot {k}^{2}}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2 \cdot {\ell}^{2}}{t\_m \cdot {k}^{4}}\\
\end{array}
\end{array}
if k < 7.4000000000000005e111Initial program 57.7%
Simplified60.4%
Taylor expanded in k around 0 58.3%
associate-*l/58.6%
Applied egg-rr58.6%
associate-/l*59.1%
Simplified59.1%
if 7.4000000000000005e111 < k Initial program 51.4%
Simplified51.3%
add-sqr-sqrt48.6%
sqrt-div48.6%
sqrt-div48.6%
Applied egg-rr41.0%
unpow241.0%
Simplified46.0%
Taylor expanded in t around 0 40.3%
*-commutative40.3%
times-frac40.4%
Simplified40.4%
Taylor expanded in k around 0 57.8%
*-commutative57.8%
unpow257.8%
rem-square-sqrt57.8%
*-commutative57.8%
Simplified57.8%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= k 7e+36)
(* l (/ 2.0 (* (* 2.0 (pow k 2.0)) (/ (pow t_m 3.0) l))))
(/ (* 2.0 (pow l 2.0)) (* t_m (pow k 4.0))))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double tmp;
if (k <= 7e+36) {
tmp = l * (2.0 / ((2.0 * pow(k, 2.0)) * (pow(t_m, 3.0) / l)));
} else {
tmp = (2.0 * pow(l, 2.0)) / (t_m * pow(k, 4.0));
}
return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
real(8), intent (in) :: t_s
real(8), intent (in) :: t_m
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: tmp
if (k <= 7d+36) then
tmp = l * (2.0d0 / ((2.0d0 * (k ** 2.0d0)) * ((t_m ** 3.0d0) / l)))
else
tmp = (2.0d0 * (l ** 2.0d0)) / (t_m * (k ** 4.0d0))
end if
code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double tmp;
if (k <= 7e+36) {
tmp = l * (2.0 / ((2.0 * Math.pow(k, 2.0)) * (Math.pow(t_m, 3.0) / l)));
} else {
tmp = (2.0 * Math.pow(l, 2.0)) / (t_m * Math.pow(k, 4.0));
}
return t_s * tmp;
}
t\_m = math.fabs(t) t\_s = math.copysign(1.0, t) def code(t_s, t_m, l, k): tmp = 0 if k <= 7e+36: tmp = l * (2.0 / ((2.0 * math.pow(k, 2.0)) * (math.pow(t_m, 3.0) / l))) else: tmp = (2.0 * math.pow(l, 2.0)) / (t_m * math.pow(k, 4.0)) return t_s * tmp
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) tmp = 0.0 if (k <= 7e+36) tmp = Float64(l * Float64(2.0 / Float64(Float64(2.0 * (k ^ 2.0)) * Float64((t_m ^ 3.0) / l)))); else tmp = Float64(Float64(2.0 * (l ^ 2.0)) / Float64(t_m * (k ^ 4.0))); end return Float64(t_s * tmp) end
t\_m = abs(t); t\_s = sign(t) * abs(1.0); function tmp_2 = code(t_s, t_m, l, k) tmp = 0.0; if (k <= 7e+36) tmp = l * (2.0 / ((2.0 * (k ^ 2.0)) * ((t_m ^ 3.0) / l))); else tmp = (2.0 * (l ^ 2.0)) / (t_m * (k ^ 4.0)); end tmp_2 = t_s * tmp; end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[k, 7e+36], N[(l * N[(2.0 / N[(N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[(N[Power[t$95$m, 3.0], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(2.0 * N[Power[l, 2.0], $MachinePrecision]), $MachinePrecision] / N[(t$95$m * N[Power[k, 4.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 7 \cdot 10^{+36}:\\
\;\;\;\;\ell \cdot \frac{2}{\left(2 \cdot {k}^{2}\right) \cdot \frac{{t\_m}^{3}}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2 \cdot {\ell}^{2}}{t\_m \cdot {k}^{4}}\\
\end{array}
\end{array}
if k < 6.9999999999999996e36Initial program 59.1%
Simplified62.0%
Taylor expanded in k around 0 60.2%
associate-*l/61.0%
Applied egg-rr61.0%
associate-/r/61.0%
Applied egg-rr61.0%
if 6.9999999999999996e36 < k Initial program 47.6%
Simplified45.8%
add-sqr-sqrt41.9%
sqrt-div38.1%
sqrt-div38.1%
Applied egg-rr34.5%
unpow234.5%
Simplified40.0%
Taylor expanded in t around 0 37.6%
*-commutative37.6%
times-frac37.7%
Simplified37.7%
Taylor expanded in k around 0 52.1%
*-commutative52.1%
unpow252.1%
rem-square-sqrt52.1%
*-commutative52.1%
Simplified52.1%
Final simplification59.1%
t\_m = (fabs.f64 t) t\_s = (copysign.f64 #s(literal 1 binary64) t) (FPCore (t_s t_m l k) :precision binary64 (* t_s (/ (* 2.0 (pow l 2.0)) (* t_m (pow k 4.0)))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
return t_s * ((2.0 * pow(l, 2.0)) / (t_m * pow(k, 4.0)));
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
real(8), intent (in) :: t_s
real(8), intent (in) :: t_m
real(8), intent (in) :: l
real(8), intent (in) :: k
code = t_s * ((2.0d0 * (l ** 2.0d0)) / (t_m * (k ** 4.0d0)))
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
return t_s * ((2.0 * Math.pow(l, 2.0)) / (t_m * Math.pow(k, 4.0)));
}
t\_m = math.fabs(t) t\_s = math.copysign(1.0, t) def code(t_s, t_m, l, k): return t_s * ((2.0 * math.pow(l, 2.0)) / (t_m * math.pow(k, 4.0)))
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) return Float64(t_s * Float64(Float64(2.0 * (l ^ 2.0)) / Float64(t_m * (k ^ 4.0)))) end
t\_m = abs(t); t\_s = sign(t) * abs(1.0); function tmp = code(t_s, t_m, l, k) tmp = t_s * ((2.0 * (l ^ 2.0)) / (t_m * (k ^ 4.0))); end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * N[(N[(2.0 * N[Power[l, 2.0], $MachinePrecision]), $MachinePrecision] / N[(t$95$m * N[Power[k, 4.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \frac{2 \cdot {\ell}^{2}}{t\_m \cdot {k}^{4}}
\end{array}
Initial program 56.7%
Simplified55.9%
add-sqr-sqrt42.6%
sqrt-div41.4%
sqrt-div41.4%
Applied egg-rr43.1%
unpow243.1%
Simplified43.0%
Taylor expanded in t around 0 32.9%
*-commutative32.9%
times-frac33.0%
Simplified33.0%
Taylor expanded in k around 0 48.4%
*-commutative48.4%
unpow248.4%
rem-square-sqrt48.4%
*-commutative48.4%
Simplified48.4%
herbie shell --seed 2024132
(FPCore (t l k)
:name "Toniolo and Linder, Equation (10+)"
:precision binary64
(/ 2.0 (* (* (* (/ (pow t 3.0) (* l l)) (sin k)) (tan k)) (+ (+ 1.0 (pow (/ k t) 2.0)) 1.0))))