
(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 24 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.95e-115)
(* (/ (cos k) t_m) (pow (* l (/ (sqrt 2.0) (* k (sin k)))) 2.0))
(if (<= t_m 1.5e+98)
(* 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 (* (tan k) (+ 2.0 (pow (/ k t_m) 2.0)))) (cbrt (sin k)))))
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.95e-115) {
tmp = (cos(k) / t_m) * pow((l * (sqrt(2.0) / (k * sin(k)))), 2.0);
} else if (t_m <= 1.5e+98) {
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((tan(k) * (2.0 + pow((k / t_m), 2.0)))) * cbrt(sin(k))))), 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.95e-115) {
tmp = (Math.cos(k) / t_m) * Math.pow((l * (Math.sqrt(2.0) / (k * Math.sin(k)))), 2.0);
} else if (t_m <= 1.5e+98) {
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.tan(k) * (2.0 + Math.pow((k / t_m), 2.0)))) * Math.cbrt(Math.sin(k))))), 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.95e-115) tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(sqrt(2.0) / Float64(k * sin(k)))) ^ 2.0)); elseif (t_m <= 1.5e+98) tmp = Float64(t_2 * Float64(Float64(2.0 / Float64((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(Float64(tan(k) * Float64(2.0 + (Float64(k / t_m) ^ 2.0)))) * cbrt(sin(k))))) ^ 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.95e-115], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[Sqrt[2.0], $MachinePrecision] / N[(k * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 1.5e+98], N[(t$95$2 * N[(N[(2.0 / N[(N[Power[t$95$m, 3.0], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $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[(N[Tan[k], $MachinePrecision] * N[(2.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 1/3], $MachinePrecision] * N[Power[N[Sin[k], $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.95 \cdot 10^{-115}:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\sqrt{2}}{k \cdot \sin k}\right)}^{2}\\
\mathbf{elif}\;t\_m \leq 1.5 \cdot 10^{+98}:\\
\;\;\;\;t\_2 \cdot \left(\frac{2}{{t\_m}^{3} \cdot \left(\sin k \cdot \tan k\right)} \cdot t\_2\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{{\left(t\_m \cdot \left({\left(\sqrt[3]{\ell}\right)}^{-2} \cdot \left(\sqrt[3]{\tan k \cdot \left(2 + {\left(\frac{k}{t\_m}\right)}^{2}\right)} \cdot \sqrt[3]{\sin k}\right)\right)\right)}^{3}}\\
\end{array}
\end{array}
\end{array}
if t < 1.9499999999999999e-115Initial program 49.6%
Simplified50.1%
add-sqr-sqrt31.3%
pow231.3%
Applied egg-rr34.7%
Taylor expanded in t around 0 32.9%
*-commutative32.9%
unpow-prod-down30.8%
pow230.8%
add-sqr-sqrt74.0%
times-frac74.0%
Applied egg-rr74.0%
times-frac74.0%
associate-*r/74.0%
Simplified74.0%
if 1.9499999999999999e-115 < t < 1.5000000000000001e98Initial program 82.0%
Simplified82.1%
associate-*r*86.4%
add-sqr-sqrt86.2%
times-frac86.5%
Applied egg-rr97.3%
associate-/l*97.4%
associate-*l*97.4%
Simplified97.4%
if 1.5000000000000001e98 < t Initial program 63.3%
Simplified48.1%
add-cube-cbrt48.1%
pow348.1%
cbrt-div48.1%
rem-cbrt-cube64.6%
Applied egg-rr64.6%
add-cube-cbrt64.6%
pow364.6%
Applied egg-rr68.1%
associate-*l*68.3%
Simplified68.3%
*-commutative68.3%
metadata-eval68.3%
associate-+r+68.3%
cbrt-prod95.1%
associate-+r+95.1%
metadata-eval95.1%
Applied egg-rr95.1%
Final simplification81.4%
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.95e-115)
(* (/ (cos k) t_m) (pow (* l (/ (sqrt 2.0) (* k (sin k)))) 2.0))
(if (<= t_m 4.3e+98)
(* 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 (* k 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.95e-115) {
tmp = (cos(k) / t_m) * pow((l * (sqrt(2.0) / (k * sin(k)))), 2.0);
} else if (t_m <= 4.3e+98) {
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((k * 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.95e-115) {
tmp = (Math.cos(k) / t_m) * Math.pow((l * (Math.sqrt(2.0) / (k * Math.sin(k)))), 2.0);
} else if (t_m <= 4.3e+98) {
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((k * 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.95e-115) tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(sqrt(2.0) / Float64(k * sin(k)))) ^ 2.0)); elseif (t_m <= 4.3e+98) tmp = Float64(t_2 * Float64(Float64(2.0 / Float64((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(k * 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.95e-115], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[Sqrt[2.0], $MachinePrecision] / N[(k * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 4.3e+98], N[(t$95$2 * N[(N[(2.0 / N[(N[Power[t$95$m, 3.0], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $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[(k * 2.0), $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.95 \cdot 10^{-115}:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\sqrt{2}}{k \cdot \sin k}\right)}^{2}\\
\mathbf{elif}\;t\_m \leq 4.3 \cdot 10^{+98}:\\
\;\;\;\;t\_2 \cdot \left(\frac{2}{{t\_m}^{3} \cdot \left(\sin k \cdot \tan k\right)} \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]{k \cdot 2}\right)\right)\right)}^{3}}\\
\end{array}
\end{array}
\end{array}
if t < 1.9499999999999999e-115Initial program 49.6%
Simplified50.1%
add-sqr-sqrt31.3%
pow231.3%
Applied egg-rr34.7%
Taylor expanded in t around 0 32.9%
*-commutative32.9%
unpow-prod-down30.8%
pow230.8%
add-sqr-sqrt74.0%
times-frac74.0%
Applied egg-rr74.0%
times-frac74.0%
associate-*r/74.0%
Simplified74.0%
if 1.9499999999999999e-115 < t < 4.3000000000000001e98Initial program 82.0%
Simplified82.1%
associate-*r*86.4%
add-sqr-sqrt86.2%
times-frac86.5%
Applied egg-rr97.3%
associate-/l*97.4%
associate-*l*97.4%
Simplified97.4%
if 4.3000000000000001e98 < t Initial program 63.3%
Simplified48.1%
add-cube-cbrt48.1%
pow348.1%
cbrt-div48.1%
rem-cbrt-cube64.6%
Applied egg-rr64.6%
add-cube-cbrt64.6%
pow364.6%
Applied egg-rr68.1%
associate-*l*68.3%
Simplified68.3%
*-commutative68.3%
metadata-eval68.3%
associate-+r+68.3%
cbrt-prod95.1%
associate-+r+95.1%
metadata-eval95.1%
Applied egg-rr95.1%
Taylor expanded in k around 0 90.7%
*-commutative90.7%
Simplified90.7%
Final simplification80.7%
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 125000.0)
(* (/ (cos k) t_m) (pow (* l (/ (sqrt 2.0) (* k (sin k)))) 2.0))
(/
2.0
(*
(pow (* (cbrt (sin k)) (/ t_m (pow (cbrt l) 2.0))) 3.0)
(* (tan k) (+ 1.0 (+ 1.0 (pow (/ k t_m) 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 (t_m <= 125000.0) {
tmp = (cos(k) / t_m) * pow((l * (sqrt(2.0) / (k * sin(k)))), 2.0);
} else {
tmp = 2.0 / (pow((cbrt(sin(k)) * (t_m / pow(cbrt(l), 2.0))), 3.0) * (tan(k) * (1.0 + (1.0 + pow((k / t_m), 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 (t_m <= 125000.0) {
tmp = (Math.cos(k) / t_m) * Math.pow((l * (Math.sqrt(2.0) / (k * Math.sin(k)))), 2.0);
} else {
tmp = 2.0 / (Math.pow((Math.cbrt(Math.sin(k)) * (t_m / Math.pow(Math.cbrt(l), 2.0))), 3.0) * (Math.tan(k) * (1.0 + (1.0 + Math.pow((k / t_m), 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 (t_m <= 125000.0) tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(sqrt(2.0) / Float64(k * sin(k)))) ^ 2.0)); else tmp = Float64(2.0 / Float64((Float64(cbrt(sin(k)) * Float64(t_m / (cbrt(l) ^ 2.0))) ^ 3.0) * Float64(tan(k) * Float64(1.0 + Float64(1.0 + (Float64(k / t_m) ^ 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[t$95$m, 125000.0], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[Sqrt[2.0], $MachinePrecision] / N[(k * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[Power[N[(N[Power[N[Sin[k], $MachinePrecision], 1/3], $MachinePrecision] * N[(t$95$m / N[Power[N[Power[l, 1/3], $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision] * N[(N[Tan[k], $MachinePrecision] * N[(1.0 + N[(1.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $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 125000:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\sqrt{2}}{k \cdot \sin k}\right)}^{2}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{{\left(\sqrt[3]{\sin k} \cdot \frac{t\_m}{{\left(\sqrt[3]{\ell}\right)}^{2}}\right)}^{3} \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t\_m}\right)}^{2}\right)\right)\right)}\\
\end{array}
\end{array}
if t < 125000Initial program 53.1%
Simplified53.5%
add-sqr-sqrt37.0%
pow237.0%
Applied egg-rr37.3%
Taylor expanded in t around 0 35.7%
*-commutative35.7%
unpow-prod-down33.4%
pow233.4%
add-sqr-sqrt76.1%
times-frac76.1%
Applied egg-rr76.1%
times-frac76.1%
associate-*r/76.1%
Simplified76.1%
if 125000 < t Initial program 70.5%
Simplified70.5%
add-cube-cbrt70.3%
pow370.3%
*-commutative70.3%
cbrt-prod70.3%
cbrt-div70.4%
rem-cbrt-cube78.8%
cbrt-prod89.0%
pow289.0%
Applied egg-rr89.0%
Final simplification79.2%
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 27000.0)
(* (/ (cos k) t_m) (pow (* l (/ (sqrt 2.0) (* k (sin k)))) 2.0))
(if (<= t_m 2.65e+106)
(*
(pow (/ (cbrt (* l 2.0)) (* t_m (cbrt (* (sin k) (tan k))))) 3.0)
(/ l (+ 2.0 (pow (/ k t_m) 2.0))))
(if (<= t_m 2.5e+272)
(/
2.0
(pow
(* t_m (* (pow (cbrt l) -2.0) (* (cbrt (sin k)) (cbrt (* k 2.0)))))
3.0))
(/
2.0
(* (* k 2.0) (* (sin k) (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 <= 27000.0) {
tmp = (cos(k) / t_m) * pow((l * (sqrt(2.0) / (k * sin(k)))), 2.0);
} else if (t_m <= 2.65e+106) {
tmp = pow((cbrt((l * 2.0)) / (t_m * cbrt((sin(k) * tan(k))))), 3.0) * (l / (2.0 + pow((k / t_m), 2.0)));
} else if (t_m <= 2.5e+272) {
tmp = 2.0 / pow((t_m * (pow(cbrt(l), -2.0) * (cbrt(sin(k)) * cbrt((k * 2.0))))), 3.0);
} else {
tmp = 2.0 / ((k * 2.0) * (sin(k) * 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 <= 27000.0) {
tmp = (Math.cos(k) / t_m) * Math.pow((l * (Math.sqrt(2.0) / (k * Math.sin(k)))), 2.0);
} else if (t_m <= 2.65e+106) {
tmp = Math.pow((Math.cbrt((l * 2.0)) / (t_m * Math.cbrt((Math.sin(k) * Math.tan(k))))), 3.0) * (l / (2.0 + Math.pow((k / t_m), 2.0)));
} else if (t_m <= 2.5e+272) {
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 {
tmp = 2.0 / ((k * 2.0) * (Math.sin(k) * 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 <= 27000.0) tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(sqrt(2.0) / Float64(k * sin(k)))) ^ 2.0)); elseif (t_m <= 2.65e+106) tmp = Float64((Float64(cbrt(Float64(l * 2.0)) / Float64(t_m * cbrt(Float64(sin(k) * tan(k))))) ^ 3.0) * Float64(l / Float64(2.0 + (Float64(k / t_m) ^ 2.0)))); elseif (t_m <= 2.5e+272) tmp = Float64(2.0 / (Float64(t_m * Float64((cbrt(l) ^ -2.0) * Float64(cbrt(sin(k)) * cbrt(Float64(k * 2.0))))) ^ 3.0)); else tmp = Float64(2.0 / Float64(Float64(k * 2.0) * Float64(sin(k) * (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, 27000.0], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[Sqrt[2.0], $MachinePrecision] / N[(k * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 2.65e+106], N[(N[Power[N[(N[Power[N[(l * 2.0), $MachinePrecision], 1/3], $MachinePrecision] / N[(t$95$m * N[Power[N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision] * N[(l / N[(2.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 2.5e+272], 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], N[(2.0 / N[(N[(k * 2.0), $MachinePrecision] * N[(N[Sin[k], $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]]]]), $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 27000:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\sqrt{2}}{k \cdot \sin k}\right)}^{2}\\
\mathbf{elif}\;t\_m \leq 2.65 \cdot 10^{+106}:\\
\;\;\;\;{\left(\frac{\sqrt[3]{\ell \cdot 2}}{t\_m \cdot \sqrt[3]{\sin k \cdot \tan k}}\right)}^{3} \cdot \frac{\ell}{2 + {\left(\frac{k}{t\_m}\right)}^{2}}\\
\mathbf{elif}\;t\_m \leq 2.5 \cdot 10^{+272}:\\
\;\;\;\;\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{else}:\\
\;\;\;\;\frac{2}{\left(k \cdot 2\right) \cdot \left(\sin k \cdot {\left(\frac{t\_m}{{\left(\sqrt[3]{\ell}\right)}^{2}}\right)}^{3}\right)}\\
\end{array}
\end{array}
if t < 27000Initial program 53.1%
Simplified53.5%
add-sqr-sqrt37.0%
pow237.0%
Applied egg-rr37.3%
Taylor expanded in t around 0 35.7%
*-commutative35.7%
unpow-prod-down33.4%
pow233.4%
add-sqr-sqrt76.1%
times-frac76.1%
Applied egg-rr76.1%
times-frac76.1%
associate-*r/76.1%
Simplified76.1%
if 27000 < t < 2.65e106Initial program 80.3%
Simplified80.5%
associate-*r*87.8%
*-un-lft-identity87.8%
times-frac87.9%
associate-/l/88.0%
Applied egg-rr88.0%
/-rgt-identity88.0%
associate-*l/87.9%
associate-*l*87.8%
Simplified87.8%
add-cube-cbrt87.6%
pow387.6%
cbrt-div87.5%
*-commutative87.5%
cbrt-prod87.2%
unpow387.2%
add-cbrt-cube95.3%
Applied egg-rr95.3%
if 2.65e106 < t < 2.49999999999999986e272Initial program 60.0%
Simplified39.4%
add-cube-cbrt39.4%
pow339.4%
cbrt-div39.4%
rem-cbrt-cube55.2%
Applied egg-rr55.2%
add-cube-cbrt55.2%
pow355.2%
Applied egg-rr59.7%
associate-*l*60.0%
Simplified60.0%
*-commutative60.0%
metadata-eval60.0%
associate-+r+60.0%
cbrt-prod96.4%
associate-+r+96.4%
metadata-eval96.4%
Applied egg-rr96.4%
Taylor expanded in k around 0 90.3%
*-commutative90.3%
Simplified90.3%
if 2.49999999999999986e272 < t Initial program 83.3%
Simplified83.3%
add-cube-cbrt83.3%
pow383.3%
cbrt-div83.3%
rem-cbrt-cube84.6%
cbrt-prod100.0%
pow2100.0%
Applied egg-rr100.0%
Taylor expanded in k around 0 100.0%
*-commutative83.3%
Simplified100.0%
Final simplification80.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 0.28)
(* (/ (cos k) t_m) (pow (* l (/ (sqrt 2.0) (* k (sin k)))) 2.0))
(if (<= t_m 4.1e+99)
(*
(/ l (+ 2.0 (pow (/ k t_m) 2.0)))
(/ (* l 2.0) (* (tan k) (* (sin k) (pow t_m 3.0)))))
(/
2.0
(pow
(* t_m (* (pow (cbrt l) -2.0) (* (cbrt (sin k)) (cbrt (* k 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 <= 0.28) {
tmp = (cos(k) / t_m) * pow((l * (sqrt(2.0) / (k * sin(k)))), 2.0);
} else if (t_m <= 4.1e+99) {
tmp = (l / (2.0 + pow((k / t_m), 2.0))) * ((l * 2.0) / (tan(k) * (sin(k) * pow(t_m, 3.0))));
} else {
tmp = 2.0 / pow((t_m * (pow(cbrt(l), -2.0) * (cbrt(sin(k)) * cbrt((k * 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 <= 0.28) {
tmp = (Math.cos(k) / t_m) * Math.pow((l * (Math.sqrt(2.0) / (k * Math.sin(k)))), 2.0);
} else if (t_m <= 4.1e+99) {
tmp = (l / (2.0 + Math.pow((k / t_m), 2.0))) * ((l * 2.0) / (Math.tan(k) * (Math.sin(k) * Math.pow(t_m, 3.0))));
} else {
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);
}
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 <= 0.28) tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(sqrt(2.0) / Float64(k * sin(k)))) ^ 2.0)); elseif (t_m <= 4.1e+99) tmp = Float64(Float64(l / Float64(2.0 + (Float64(k / t_m) ^ 2.0))) * Float64(Float64(l * 2.0) / Float64(tan(k) * Float64(sin(k) * (t_m ^ 3.0))))); else tmp = Float64(2.0 / (Float64(t_m * Float64((cbrt(l) ^ -2.0) * Float64(cbrt(sin(k)) * cbrt(Float64(k * 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, 0.28], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[Sqrt[2.0], $MachinePrecision] / N[(k * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 4.1e+99], 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[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[Power[t$95$m, 3.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $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[(k * 2.0), $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)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 0.28:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\sqrt{2}}{k \cdot \sin k}\right)}^{2}\\
\mathbf{elif}\;t\_m \leq 4.1 \cdot 10^{+99}:\\
\;\;\;\;\frac{\ell}{2 + {\left(\frac{k}{t\_m}\right)}^{2}} \cdot \frac{\ell \cdot 2}{\tan k \cdot \left(\sin k \cdot {t\_m}^{3}\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]{k \cdot 2}\right)\right)\right)}^{3}}\\
\end{array}
\end{array}
if t < 0.28000000000000003Initial program 53.1%
Simplified53.5%
add-sqr-sqrt37.0%
pow237.0%
Applied egg-rr37.3%
Taylor expanded in t around 0 35.7%
*-commutative35.7%
unpow-prod-down33.4%
pow233.4%
add-sqr-sqrt76.1%
times-frac76.1%
Applied egg-rr76.1%
times-frac76.1%
associate-*r/76.1%
Simplified76.1%
if 0.28000000000000003 < t < 4.09999999999999979e99Initial program 85.4%
Simplified85.6%
associate-*r*94.6%
*-un-lft-identity94.6%
times-frac94.7%
associate-/l/94.8%
Applied egg-rr94.8%
/-rgt-identity94.8%
associate-*l/94.7%
associate-*l*94.7%
Simplified94.7%
associate-*r*94.7%
pow194.7%
*-commutative94.7%
*-commutative94.7%
Applied egg-rr94.7%
unpow194.7%
*-commutative94.7%
Simplified94.7%
if 4.09999999999999979e99 < t Initial program 63.3%
Simplified48.1%
add-cube-cbrt48.1%
pow348.1%
cbrt-div48.1%
rem-cbrt-cube64.6%
Applied egg-rr64.6%
add-cube-cbrt64.6%
pow364.6%
Applied egg-rr68.1%
associate-*l*68.3%
Simplified68.3%
*-commutative68.3%
metadata-eval68.3%
associate-+r+68.3%
cbrt-prod95.1%
associate-+r+95.1%
metadata-eval95.1%
Applied egg-rr95.1%
Taylor expanded in k around 0 90.7%
*-commutative90.7%
Simplified90.7%
Final simplification80.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 82.0)
(* (/ (cos k) t_m) (pow (* l (/ (sqrt 2.0) (* k (sin k)))) 2.0))
(/
2.0
(*
(* (tan k) (+ 1.0 (+ 1.0 (pow (/ k t_m) 2.0))))
(* (sin k) (pow (/ (pow t_m 1.5) l) 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 (t_m <= 82.0) {
tmp = (cos(k) / t_m) * pow((l * (sqrt(2.0) / (k * sin(k)))), 2.0);
} else {
tmp = 2.0 / ((tan(k) * (1.0 + (1.0 + pow((k / t_m), 2.0)))) * (sin(k) * pow((pow(t_m, 1.5) / l), 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) :: tmp
if (t_m <= 82.0d0) then
tmp = (cos(k) / t_m) * ((l * (sqrt(2.0d0) / (k * sin(k)))) ** 2.0d0)
else
tmp = 2.0d0 / ((tan(k) * (1.0d0 + (1.0d0 + ((k / t_m) ** 2.0d0)))) * (sin(k) * (((t_m ** 1.5d0) / l) ** 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 tmp;
if (t_m <= 82.0) {
tmp = (Math.cos(k) / t_m) * Math.pow((l * (Math.sqrt(2.0) / (k * Math.sin(k)))), 2.0);
} else {
tmp = 2.0 / ((Math.tan(k) * (1.0 + (1.0 + Math.pow((k / t_m), 2.0)))) * (Math.sin(k) * Math.pow((Math.pow(t_m, 1.5) / l), 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): tmp = 0 if t_m <= 82.0: tmp = (math.cos(k) / t_m) * math.pow((l * (math.sqrt(2.0) / (k * math.sin(k)))), 2.0) else: tmp = 2.0 / ((math.tan(k) * (1.0 + (1.0 + math.pow((k / t_m), 2.0)))) * (math.sin(k) * math.pow((math.pow(t_m, 1.5) / l), 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 (t_m <= 82.0) tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(sqrt(2.0) / Float64(k * sin(k)))) ^ 2.0)); else tmp = Float64(2.0 / Float64(Float64(tan(k) * Float64(1.0 + Float64(1.0 + (Float64(k / t_m) ^ 2.0)))) * Float64(sin(k) * (Float64((t_m ^ 1.5) / l) ^ 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) tmp = 0.0; if (t_m <= 82.0) tmp = (cos(k) / t_m) * ((l * (sqrt(2.0) / (k * sin(k)))) ^ 2.0); else tmp = 2.0 / ((tan(k) * (1.0 + (1.0 + ((k / t_m) ^ 2.0)))) * (sin(k) * (((t_m ^ 1.5) / l) ^ 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_] := N[(t$95$s * If[LessEqual[t$95$m, 82.0], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[Sqrt[2.0], $MachinePrecision] / N[(k * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(N[Tan[k], $MachinePrecision] * N[(1.0 + N[(1.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[Power[N[(N[Power[t$95$m, 1.5], $MachinePrecision] / l), $MachinePrecision], 2.0], $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 82:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\sqrt{2}}{k \cdot \sin k}\right)}^{2}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t\_m}\right)}^{2}\right)\right)\right) \cdot \left(\sin k \cdot {\left(\frac{{t\_m}^{1.5}}{\ell}\right)}^{2}\right)}\\
\end{array}
\end{array}
if t < 82Initial program 53.1%
Simplified53.5%
add-sqr-sqrt37.0%
pow237.0%
Applied egg-rr37.3%
Taylor expanded in t around 0 35.7%
*-commutative35.7%
unpow-prod-down33.4%
pow233.4%
add-sqr-sqrt76.1%
times-frac76.1%
Applied egg-rr76.1%
times-frac76.1%
associate-*r/76.1%
Simplified76.1%
if 82 < t Initial program 70.5%
Simplified70.5%
add-sqr-sqrt70.4%
pow270.4%
sqrt-div70.4%
sqrt-pow178.7%
metadata-eval78.7%
sqrt-prod48.8%
add-sqr-sqrt86.3%
Applied egg-rr86.3%
Final simplification78.6%
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.05)
(* (/ (cos k) t_m) (pow (* l (/ (sqrt 2.0) (* k (sin k)))) 2.0))
(if (<= t_m 2.35e+134)
(/
2.0
(*
(* (tan k) (+ 1.0 (+ 1.0 (pow (/ k t_m) 2.0))))
(* (sin k) (* (/ (pow t_m 2.0) l) (/ t_m l)))))
(/
2.0
(*
(* k 2.0)
(pow (* (cbrt (sin k)) (/ 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 <= 1.05) {
tmp = (cos(k) / t_m) * pow((l * (sqrt(2.0) / (k * sin(k)))), 2.0);
} else if (t_m <= 2.35e+134) {
tmp = 2.0 / ((tan(k) * (1.0 + (1.0 + pow((k / t_m), 2.0)))) * (sin(k) * ((pow(t_m, 2.0) / l) * (t_m / l))));
} else {
tmp = 2.0 / ((k * 2.0) * pow((cbrt(sin(k)) * (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 <= 1.05) {
tmp = (Math.cos(k) / t_m) * Math.pow((l * (Math.sqrt(2.0) / (k * Math.sin(k)))), 2.0);
} else if (t_m <= 2.35e+134) {
tmp = 2.0 / ((Math.tan(k) * (1.0 + (1.0 + Math.pow((k / t_m), 2.0)))) * (Math.sin(k) * ((Math.pow(t_m, 2.0) / l) * (t_m / l))));
} else {
tmp = 2.0 / ((k * 2.0) * Math.pow((Math.cbrt(Math.sin(k)) * (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 <= 1.05) tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(sqrt(2.0) / Float64(k * sin(k)))) ^ 2.0)); elseif (t_m <= 2.35e+134) tmp = Float64(2.0 / Float64(Float64(tan(k) * Float64(1.0 + Float64(1.0 + (Float64(k / t_m) ^ 2.0)))) * Float64(sin(k) * Float64(Float64((t_m ^ 2.0) / l) * Float64(t_m / l))))); else tmp = Float64(2.0 / Float64(Float64(k * 2.0) * (Float64(cbrt(sin(k)) * 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, 1.05], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[Sqrt[2.0], $MachinePrecision] / N[(k * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 2.35e+134], N[(2.0 / N[(N[(N[Tan[k], $MachinePrecision] * N[(1.0 + N[(1.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $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], N[(2.0 / N[(N[(k * 2.0), $MachinePrecision] * N[Power[N[(N[Power[N[Sin[k], $MachinePrecision], 1/3], $MachinePrecision] * N[(t$95$m / N[Power[N[Power[l, 1/3], $MachinePrecision], 2.0], $MachinePrecision]), $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 1.05:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\sqrt{2}}{k \cdot \sin k}\right)}^{2}\\
\mathbf{elif}\;t\_m \leq 2.35 \cdot 10^{+134}:\\
\;\;\;\;\frac{2}{\left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t\_m}\right)}^{2}\right)\right)\right) \cdot \left(\sin k \cdot \left(\frac{{t\_m}^{2}}{\ell} \cdot \frac{t\_m}{\ell}\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(k \cdot 2\right) \cdot {\left(\sqrt[3]{\sin k} \cdot \frac{t\_m}{{\left(\sqrt[3]{\ell}\right)}^{2}}\right)}^{3}}\\
\end{array}
\end{array}
if t < 1.05000000000000004Initial program 53.1%
Simplified53.5%
add-sqr-sqrt37.0%
pow237.0%
Applied egg-rr37.3%
Taylor expanded in t around 0 35.7%
*-commutative35.7%
unpow-prod-down33.4%
pow233.4%
add-sqr-sqrt76.1%
times-frac76.1%
Applied egg-rr76.1%
times-frac76.1%
associate-*r/76.1%
Simplified76.1%
if 1.05000000000000004 < t < 2.35000000000000013e134Initial program 72.9%
Simplified72.9%
unpow372.9%
times-frac92.9%
pow292.9%
Applied egg-rr92.9%
if 2.35000000000000013e134 < t Initial program 68.3%
Simplified68.3%
add-cube-cbrt68.3%
pow368.3%
*-commutative68.3%
cbrt-prod68.3%
cbrt-div68.3%
rem-cbrt-cube74.9%
cbrt-prod86.1%
pow286.1%
Applied egg-rr86.1%
Taylor expanded in k around 0 83.3%
*-commutative68.3%
Simplified83.3%
Final simplification78.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 280.0)
(* (/ (cos k) t_m) (pow (* l (/ (sqrt 2.0) (* k (sin k)))) 2.0))
(if (<= t_m 6.2e+135)
(/
2.0
(*
(* (tan k) (+ 1.0 (+ 1.0 (pow (/ k t_m) 2.0))))
(* (sin k) (* (/ (pow t_m 2.0) l) (/ t_m l)))))
(/
2.0
(* (* k 2.0) (* (sin k) (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 <= 280.0) {
tmp = (cos(k) / t_m) * pow((l * (sqrt(2.0) / (k * sin(k)))), 2.0);
} else if (t_m <= 6.2e+135) {
tmp = 2.0 / ((tan(k) * (1.0 + (1.0 + pow((k / t_m), 2.0)))) * (sin(k) * ((pow(t_m, 2.0) / l) * (t_m / l))));
} else {
tmp = 2.0 / ((k * 2.0) * (sin(k) * 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 <= 280.0) {
tmp = (Math.cos(k) / t_m) * Math.pow((l * (Math.sqrt(2.0) / (k * Math.sin(k)))), 2.0);
} else if (t_m <= 6.2e+135) {
tmp = 2.0 / ((Math.tan(k) * (1.0 + (1.0 + Math.pow((k / t_m), 2.0)))) * (Math.sin(k) * ((Math.pow(t_m, 2.0) / l) * (t_m / l))));
} else {
tmp = 2.0 / ((k * 2.0) * (Math.sin(k) * 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 <= 280.0) tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(sqrt(2.0) / Float64(k * sin(k)))) ^ 2.0)); elseif (t_m <= 6.2e+135) tmp = Float64(2.0 / Float64(Float64(tan(k) * Float64(1.0 + Float64(1.0 + (Float64(k / t_m) ^ 2.0)))) * Float64(sin(k) * Float64(Float64((t_m ^ 2.0) / l) * Float64(t_m / l))))); else tmp = Float64(2.0 / Float64(Float64(k * 2.0) * Float64(sin(k) * (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, 280.0], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[Sqrt[2.0], $MachinePrecision] / N[(k * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 6.2e+135], N[(2.0 / N[(N[(N[Tan[k], $MachinePrecision] * N[(1.0 + N[(1.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $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], N[(2.0 / N[(N[(k * 2.0), $MachinePrecision] * N[(N[Sin[k], $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]]]), $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 280:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\sqrt{2}}{k \cdot \sin k}\right)}^{2}\\
\mathbf{elif}\;t\_m \leq 6.2 \cdot 10^{+135}:\\
\;\;\;\;\frac{2}{\left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t\_m}\right)}^{2}\right)\right)\right) \cdot \left(\sin k \cdot \left(\frac{{t\_m}^{2}}{\ell} \cdot \frac{t\_m}{\ell}\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(k \cdot 2\right) \cdot \left(\sin k \cdot {\left(\frac{t\_m}{{\left(\sqrt[3]{\ell}\right)}^{2}}\right)}^{3}\right)}\\
\end{array}
\end{array}
if t < 280Initial program 53.1%
Simplified53.5%
add-sqr-sqrt37.0%
pow237.0%
Applied egg-rr37.3%
Taylor expanded in t around 0 35.7%
*-commutative35.7%
unpow-prod-down33.4%
pow233.4%
add-sqr-sqrt76.1%
times-frac76.1%
Applied egg-rr76.1%
times-frac76.1%
associate-*r/76.1%
Simplified76.1%
if 280 < t < 6.20000000000000044e135Initial program 72.9%
Simplified72.9%
unpow372.9%
times-frac92.9%
pow292.9%
Applied egg-rr92.9%
if 6.20000000000000044e135 < t Initial program 68.3%
Simplified68.3%
add-cube-cbrt68.3%
pow368.3%
cbrt-div68.3%
rem-cbrt-cube74.9%
cbrt-prod86.4%
pow286.4%
Applied egg-rr86.4%
Taylor expanded in k around 0 83.5%
*-commutative68.3%
Simplified83.5%
Final simplification79.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.35)
(* (/ (cos k) t_m) (pow (* l (/ (sqrt 2.0) (* k (sin k)))) 2.0))
(if (<= t_m 4.1e+99)
(*
(/ l (+ 2.0 (pow (/ k t_m) 2.0)))
(* l (/ (/ 2.0 (tan k)) (* (sin k) (pow t_m 3.0)))))
(/
2.0
(* (* k 2.0) (* (sin k) (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 <= 1.35) {
tmp = (cos(k) / t_m) * pow((l * (sqrt(2.0) / (k * sin(k)))), 2.0);
} else if (t_m <= 4.1e+99) {
tmp = (l / (2.0 + pow((k / t_m), 2.0))) * (l * ((2.0 / tan(k)) / (sin(k) * pow(t_m, 3.0))));
} else {
tmp = 2.0 / ((k * 2.0) * (sin(k) * 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 <= 1.35) {
tmp = (Math.cos(k) / t_m) * Math.pow((l * (Math.sqrt(2.0) / (k * Math.sin(k)))), 2.0);
} else if (t_m <= 4.1e+99) {
tmp = (l / (2.0 + Math.pow((k / t_m), 2.0))) * (l * ((2.0 / Math.tan(k)) / (Math.sin(k) * Math.pow(t_m, 3.0))));
} else {
tmp = 2.0 / ((k * 2.0) * (Math.sin(k) * 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 <= 1.35) tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(sqrt(2.0) / Float64(k * sin(k)))) ^ 2.0)); elseif (t_m <= 4.1e+99) tmp = Float64(Float64(l / Float64(2.0 + (Float64(k / t_m) ^ 2.0))) * Float64(l * Float64(Float64(2.0 / tan(k)) / Float64(sin(k) * (t_m ^ 3.0))))); else tmp = Float64(2.0 / Float64(Float64(k * 2.0) * Float64(sin(k) * (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, 1.35], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[Sqrt[2.0], $MachinePrecision] / N[(k * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 4.1e+99], N[(N[(l / N[(2.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l * N[(N[(2.0 / N[Tan[k], $MachinePrecision]), $MachinePrecision] / N[(N[Sin[k], $MachinePrecision] * N[Power[t$95$m, 3.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(k * 2.0), $MachinePrecision] * N[(N[Sin[k], $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]]]), $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.35:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\sqrt{2}}{k \cdot \sin k}\right)}^{2}\\
\mathbf{elif}\;t\_m \leq 4.1 \cdot 10^{+99}:\\
\;\;\;\;\frac{\ell}{2 + {\left(\frac{k}{t\_m}\right)}^{2}} \cdot \left(\ell \cdot \frac{\frac{2}{\tan k}}{\sin k \cdot {t\_m}^{3}}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(k \cdot 2\right) \cdot \left(\sin k \cdot {\left(\frac{t\_m}{{\left(\sqrt[3]{\ell}\right)}^{2}}\right)}^{3}\right)}\\
\end{array}
\end{array}
if t < 1.3500000000000001Initial program 53.1%
Simplified53.5%
add-sqr-sqrt37.0%
pow237.0%
Applied egg-rr37.3%
Taylor expanded in t around 0 35.7%
*-commutative35.7%
unpow-prod-down33.4%
pow233.4%
add-sqr-sqrt76.1%
times-frac76.1%
Applied egg-rr76.1%
times-frac76.1%
associate-*r/76.1%
Simplified76.1%
if 1.3500000000000001 < t < 4.09999999999999979e99Initial program 85.4%
Simplified85.6%
associate-*r*94.6%
*-un-lft-identity94.6%
times-frac94.7%
associate-/l/94.8%
Applied egg-rr94.8%
/-rgt-identity94.8%
*-commutative94.8%
metadata-eval94.8%
distribute-neg-frac94.8%
associate-/l/94.7%
distribute-neg-frac94.7%
distribute-neg-frac94.7%
metadata-eval94.7%
*-commutative94.7%
Simplified94.7%
if 4.09999999999999979e99 < t Initial program 63.3%
Simplified63.3%
add-cube-cbrt63.3%
pow363.3%
cbrt-div63.3%
rem-cbrt-cube75.8%
cbrt-prod87.0%
pow287.0%
Applied egg-rr87.0%
Taylor expanded in k around 0 82.5%
*-commutative63.3%
Simplified82.5%
Final simplification78.6%
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 0.32)
(* (/ (cos k) t_m) (pow (* l (/ (sqrt 2.0) (* k (sin k)))) 2.0))
(if (<= t_m 4.1e+99)
(*
(/ l (+ 2.0 (pow (/ k t_m) 2.0)))
(/ (* l 2.0) (* (tan k) (* (sin k) (pow t_m 3.0)))))
(/
2.0
(* (* k 2.0) (* (sin k) (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 <= 0.32) {
tmp = (cos(k) / t_m) * pow((l * (sqrt(2.0) / (k * sin(k)))), 2.0);
} else if (t_m <= 4.1e+99) {
tmp = (l / (2.0 + pow((k / t_m), 2.0))) * ((l * 2.0) / (tan(k) * (sin(k) * pow(t_m, 3.0))));
} else {
tmp = 2.0 / ((k * 2.0) * (sin(k) * 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 <= 0.32) {
tmp = (Math.cos(k) / t_m) * Math.pow((l * (Math.sqrt(2.0) / (k * Math.sin(k)))), 2.0);
} else if (t_m <= 4.1e+99) {
tmp = (l / (2.0 + Math.pow((k / t_m), 2.0))) * ((l * 2.0) / (Math.tan(k) * (Math.sin(k) * Math.pow(t_m, 3.0))));
} else {
tmp = 2.0 / ((k * 2.0) * (Math.sin(k) * 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 <= 0.32) tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(sqrt(2.0) / Float64(k * sin(k)))) ^ 2.0)); elseif (t_m <= 4.1e+99) tmp = Float64(Float64(l / Float64(2.0 + (Float64(k / t_m) ^ 2.0))) * Float64(Float64(l * 2.0) / Float64(tan(k) * Float64(sin(k) * (t_m ^ 3.0))))); else tmp = Float64(2.0 / Float64(Float64(k * 2.0) * Float64(sin(k) * (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, 0.32], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[Sqrt[2.0], $MachinePrecision] / N[(k * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 4.1e+99], 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[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[Power[t$95$m, 3.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(k * 2.0), $MachinePrecision] * N[(N[Sin[k], $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]]]), $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 0.32:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\sqrt{2}}{k \cdot \sin k}\right)}^{2}\\
\mathbf{elif}\;t\_m \leq 4.1 \cdot 10^{+99}:\\
\;\;\;\;\frac{\ell}{2 + {\left(\frac{k}{t\_m}\right)}^{2}} \cdot \frac{\ell \cdot 2}{\tan k \cdot \left(\sin k \cdot {t\_m}^{3}\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(k \cdot 2\right) \cdot \left(\sin k \cdot {\left(\frac{t\_m}{{\left(\sqrt[3]{\ell}\right)}^{2}}\right)}^{3}\right)}\\
\end{array}
\end{array}
if t < 0.320000000000000007Initial program 53.1%
Simplified53.5%
add-sqr-sqrt37.0%
pow237.0%
Applied egg-rr37.3%
Taylor expanded in t around 0 35.7%
*-commutative35.7%
unpow-prod-down33.4%
pow233.4%
add-sqr-sqrt76.1%
times-frac76.1%
Applied egg-rr76.1%
times-frac76.1%
associate-*r/76.1%
Simplified76.1%
if 0.320000000000000007 < t < 4.09999999999999979e99Initial program 85.4%
Simplified85.6%
associate-*r*94.6%
*-un-lft-identity94.6%
times-frac94.7%
associate-/l/94.8%
Applied egg-rr94.8%
/-rgt-identity94.8%
associate-*l/94.7%
associate-*l*94.7%
Simplified94.7%
associate-*r*94.7%
pow194.7%
*-commutative94.7%
*-commutative94.7%
Applied egg-rr94.7%
unpow194.7%
*-commutative94.7%
Simplified94.7%
if 4.09999999999999979e99 < t Initial program 63.3%
Simplified63.3%
add-cube-cbrt63.3%
pow363.3%
cbrt-div63.3%
rem-cbrt-cube75.8%
cbrt-prod87.0%
pow287.0%
Applied egg-rr87.0%
Taylor expanded in k around 0 82.5%
*-commutative63.3%
Simplified82.5%
Final simplification78.6%
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 6.6e+70)
(* (/ (cos k) t_m) (pow (* l (/ (sqrt 2.0) (* k (sin k)))) 2.0))
(if (<= t_m 1.15e+103)
(* (/ (* l 2.0) (* (pow t_m 3.0) (* (sin k) (tan k)))) (* l 0.5))
(if (<= t_m 4e+125)
(/ 2.0 (* (pow (* t_m (pow (cbrt l) -2.0)) 3.0) (* 2.0 (pow k 2.0))))
(/ 2.0 (* (* k 2.0) (* (sin k) (/ (pow t_m 3.0) (* 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 <= 6.6e+70) {
tmp = (cos(k) / t_m) * pow((l * (sqrt(2.0) / (k * sin(k)))), 2.0);
} else if (t_m <= 1.15e+103) {
tmp = ((l * 2.0) / (pow(t_m, 3.0) * (sin(k) * tan(k)))) * (l * 0.5);
} else if (t_m <= 4e+125) {
tmp = 2.0 / (pow((t_m * pow(cbrt(l), -2.0)), 3.0) * (2.0 * pow(k, 2.0)));
} else {
tmp = 2.0 / ((k * 2.0) * (sin(k) * (pow(t_m, 3.0) / (l * 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 <= 6.6e+70) {
tmp = (Math.cos(k) / t_m) * Math.pow((l * (Math.sqrt(2.0) / (k * Math.sin(k)))), 2.0);
} else if (t_m <= 1.15e+103) {
tmp = ((l * 2.0) / (Math.pow(t_m, 3.0) * (Math.sin(k) * Math.tan(k)))) * (l * 0.5);
} else if (t_m <= 4e+125) {
tmp = 2.0 / (Math.pow((t_m * Math.pow(Math.cbrt(l), -2.0)), 3.0) * (2.0 * Math.pow(k, 2.0)));
} else {
tmp = 2.0 / ((k * 2.0) * (Math.sin(k) * (Math.pow(t_m, 3.0) / (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 <= 6.6e+70) tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(sqrt(2.0) / Float64(k * sin(k)))) ^ 2.0)); elseif (t_m <= 1.15e+103) tmp = Float64(Float64(Float64(l * 2.0) / Float64((t_m ^ 3.0) * Float64(sin(k) * tan(k)))) * Float64(l * 0.5)); elseif (t_m <= 4e+125) tmp = Float64(2.0 / Float64((Float64(t_m * (cbrt(l) ^ -2.0)) ^ 3.0) * Float64(2.0 * (k ^ 2.0)))); else tmp = Float64(2.0 / Float64(Float64(k * 2.0) * Float64(sin(k) * Float64((t_m ^ 3.0) / Float64(l * 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, 6.6e+70], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[Sqrt[2.0], $MachinePrecision] / N[(k * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 1.15e+103], N[(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] * N[(l * 0.5), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 4e+125], N[(2.0 / N[(N[Power[N[(t$95$m * N[Power[N[Power[l, 1/3], $MachinePrecision], -2.0], $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision] * N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(k * 2.0), $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[(N[Power[t$95$m, 3.0], $MachinePrecision] / N[(l * l), $MachinePrecision]), $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 6.6 \cdot 10^{+70}:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\sqrt{2}}{k \cdot \sin k}\right)}^{2}\\
\mathbf{elif}\;t\_m \leq 1.15 \cdot 10^{+103}:\\
\;\;\;\;\frac{\ell \cdot 2}{{t\_m}^{3} \cdot \left(\sin k \cdot \tan k\right)} \cdot \left(\ell \cdot 0.5\right)\\
\mathbf{elif}\;t\_m \leq 4 \cdot 10^{+125}:\\
\;\;\;\;\frac{2}{{\left(t\_m \cdot {\left(\sqrt[3]{\ell}\right)}^{-2}\right)}^{3} \cdot \left(2 \cdot {k}^{2}\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(k \cdot 2\right) \cdot \left(\sin k \cdot \frac{{t\_m}^{3}}{\ell \cdot \ell}\right)}\\
\end{array}
\end{array}
if t < 6.60000000000000033e70Initial program 55.3%
Simplified55.7%
add-sqr-sqrt39.7%
pow239.7%
Applied egg-rr39.5%
Taylor expanded in t around 0 37.5%
*-commutative37.5%
unpow-prod-down35.3%
pow235.3%
add-sqr-sqrt77.0%
times-frac77.0%
Applied egg-rr77.0%
times-frac77.0%
associate-*r/77.0%
Simplified77.0%
if 6.60000000000000033e70 < t < 1.15000000000000004e103Initial program 83.0%
Simplified83.1%
associate-*r*99.7%
*-un-lft-identity99.7%
times-frac99.6%
associate-/l/99.6%
Applied egg-rr99.6%
/-rgt-identity99.6%
associate-*l/99.4%
associate-*l*99.6%
Simplified99.6%
Taylor expanded in k around 0 82.0%
*-commutative82.0%
Simplified82.0%
if 1.15000000000000004e103 < t < 3.9999999999999997e125Initial program 1.6%
Simplified0.0%
Taylor expanded in k around 0 0.0%
add-cube-cbrt0.0%
pow30.0%
associate-/l/0.0%
cbrt-div0.0%
unpow30.0%
add-cbrt-cube75.0%
cbrt-unprod75.0%
unpow275.0%
div-inv75.0%
unpow-prod-down0.0%
pow-flip0.0%
metadata-eval0.0%
Applied egg-rr0.0%
cube-prod75.0%
Simplified75.0%
if 3.9999999999999997e125 < t Initial program 67.2%
Simplified67.2%
Taylor expanded in k around 0 67.2%
*-commutative67.2%
Simplified67.2%
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 2.8e+86)
(* (/ (cos k) t_m) (pow (* l (/ (sqrt 2.0) (* k (sin k)))) 2.0))
(/ 2.0 (* (* k 2.0) (* (sin k) (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 <= 2.8e+86) {
tmp = (cos(k) / t_m) * pow((l * (sqrt(2.0) / (k * sin(k)))), 2.0);
} else {
tmp = 2.0 / ((k * 2.0) * (sin(k) * 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 <= 2.8e+86) {
tmp = (Math.cos(k) / t_m) * Math.pow((l * (Math.sqrt(2.0) / (k * Math.sin(k)))), 2.0);
} else {
tmp = 2.0 / ((k * 2.0) * (Math.sin(k) * 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 <= 2.8e+86) tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(sqrt(2.0) / Float64(k * sin(k)))) ^ 2.0)); else tmp = Float64(2.0 / Float64(Float64(k * 2.0) * Float64(sin(k) * (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, 2.8e+86], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[Sqrt[2.0], $MachinePrecision] / N[(k * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(k * 2.0), $MachinePrecision] * N[(N[Sin[k], $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]]), $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 2.8 \cdot 10^{+86}:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\sqrt{2}}{k \cdot \sin k}\right)}^{2}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(k \cdot 2\right) \cdot \left(\sin k \cdot {\left(\frac{t\_m}{{\left(\sqrt[3]{\ell}\right)}^{2}}\right)}^{3}\right)}\\
\end{array}
\end{array}
if t < 2.80000000000000004e86Initial program 55.9%
Simplified56.3%
add-sqr-sqrt40.7%
pow240.7%
Applied egg-rr41.0%
Taylor expanded in t around 0 38.2%
*-commutative38.2%
unpow-prod-down36.1%
pow236.1%
add-sqr-sqrt76.4%
times-frac76.4%
Applied egg-rr76.4%
times-frac76.4%
associate-*r/76.5%
Simplified76.5%
if 2.80000000000000004e86 < t Initial program 64.2%
Simplified64.2%
add-cube-cbrt64.2%
pow364.2%
cbrt-div64.2%
rem-cbrt-cube76.3%
cbrt-prod87.3%
pow287.3%
Applied egg-rr87.3%
Taylor expanded in k around 0 82.9%
*-commutative64.2%
Simplified82.9%
Final simplification77.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 6.2e+70)
(* (/ (cos k) t_m) (pow (* l (/ (sqrt 2.0) (* k (sin k)))) 2.0))
(if (<= t_m 1.15e+103)
(* (/ (* l 2.0) (* (pow t_m 3.0) (* (sin k) (tan k)))) (* l 0.5))
(if (<= t_m 3.6e+125)
(/ 2.0 (* (* 2.0 (pow k 2.0)) (/ (* (pow t_m 2.0) (/ t_m l)) l)))
(/ 2.0 (* (* k 2.0) (* (sin k) (/ (pow t_m 3.0) (* 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 <= 6.2e+70) {
tmp = (cos(k) / t_m) * pow((l * (sqrt(2.0) / (k * sin(k)))), 2.0);
} else if (t_m <= 1.15e+103) {
tmp = ((l * 2.0) / (pow(t_m, 3.0) * (sin(k) * tan(k)))) * (l * 0.5);
} else if (t_m <= 3.6e+125) {
tmp = 2.0 / ((2.0 * pow(k, 2.0)) * ((pow(t_m, 2.0) * (t_m / l)) / l));
} else {
tmp = 2.0 / ((k * 2.0) * (sin(k) * (pow(t_m, 3.0) / (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 <= 6.2d+70) then
tmp = (cos(k) / t_m) * ((l * (sqrt(2.0d0) / (k * sin(k)))) ** 2.0d0)
else if (t_m <= 1.15d+103) then
tmp = ((l * 2.0d0) / ((t_m ** 3.0d0) * (sin(k) * tan(k)))) * (l * 0.5d0)
else if (t_m <= 3.6d+125) then
tmp = 2.0d0 / ((2.0d0 * (k ** 2.0d0)) * (((t_m ** 2.0d0) * (t_m / l)) / l))
else
tmp = 2.0d0 / ((k * 2.0d0) * (sin(k) * ((t_m ** 3.0d0) / (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 <= 6.2e+70) {
tmp = (Math.cos(k) / t_m) * Math.pow((l * (Math.sqrt(2.0) / (k * Math.sin(k)))), 2.0);
} else if (t_m <= 1.15e+103) {
tmp = ((l * 2.0) / (Math.pow(t_m, 3.0) * (Math.sin(k) * Math.tan(k)))) * (l * 0.5);
} else if (t_m <= 3.6e+125) {
tmp = 2.0 / ((2.0 * Math.pow(k, 2.0)) * ((Math.pow(t_m, 2.0) * (t_m / l)) / l));
} else {
tmp = 2.0 / ((k * 2.0) * (Math.sin(k) * (Math.pow(t_m, 3.0) / (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 <= 6.2e+70: tmp = (math.cos(k) / t_m) * math.pow((l * (math.sqrt(2.0) / (k * math.sin(k)))), 2.0) elif t_m <= 1.15e+103: tmp = ((l * 2.0) / (math.pow(t_m, 3.0) * (math.sin(k) * math.tan(k)))) * (l * 0.5) elif t_m <= 3.6e+125: tmp = 2.0 / ((2.0 * math.pow(k, 2.0)) * ((math.pow(t_m, 2.0) * (t_m / l)) / l)) else: tmp = 2.0 / ((k * 2.0) * (math.sin(k) * (math.pow(t_m, 3.0) / (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 <= 6.2e+70) tmp = Float64(Float64(cos(k) / t_m) * (Float64(l * Float64(sqrt(2.0) / Float64(k * sin(k)))) ^ 2.0)); elseif (t_m <= 1.15e+103) tmp = Float64(Float64(Float64(l * 2.0) / Float64((t_m ^ 3.0) * Float64(sin(k) * tan(k)))) * Float64(l * 0.5)); elseif (t_m <= 3.6e+125) tmp = Float64(2.0 / Float64(Float64(2.0 * (k ^ 2.0)) * Float64(Float64((t_m ^ 2.0) * Float64(t_m / l)) / l))); else tmp = Float64(2.0 / Float64(Float64(k * 2.0) * Float64(sin(k) * Float64((t_m ^ 3.0) / Float64(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 <= 6.2e+70) tmp = (cos(k) / t_m) * ((l * (sqrt(2.0) / (k * sin(k)))) ^ 2.0); elseif (t_m <= 1.15e+103) tmp = ((l * 2.0) / ((t_m ^ 3.0) * (sin(k) * tan(k)))) * (l * 0.5); elseif (t_m <= 3.6e+125) tmp = 2.0 / ((2.0 * (k ^ 2.0)) * (((t_m ^ 2.0) * (t_m / l)) / l)); else tmp = 2.0 / ((k * 2.0) * (sin(k) * ((t_m ^ 3.0) / (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, 6.2e+70], N[(N[(N[Cos[k], $MachinePrecision] / t$95$m), $MachinePrecision] * N[Power[N[(l * N[(N[Sqrt[2.0], $MachinePrecision] / N[(k * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 1.15e+103], N[(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] * N[(l * 0.5), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 3.6e+125], N[(2.0 / N[(N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[(N[(N[Power[t$95$m, 2.0], $MachinePrecision] * N[(t$95$m / l), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(k * 2.0), $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[(N[Power[t$95$m, 3.0], $MachinePrecision] / N[(l * l), $MachinePrecision]), $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 6.2 \cdot 10^{+70}:\\
\;\;\;\;\frac{\cos k}{t\_m} \cdot {\left(\ell \cdot \frac{\sqrt{2}}{k \cdot \sin k}\right)}^{2}\\
\mathbf{elif}\;t\_m \leq 1.15 \cdot 10^{+103}:\\
\;\;\;\;\frac{\ell \cdot 2}{{t\_m}^{3} \cdot \left(\sin k \cdot \tan k\right)} \cdot \left(\ell \cdot 0.5\right)\\
\mathbf{elif}\;t\_m \leq 3.6 \cdot 10^{+125}:\\
\;\;\;\;\frac{2}{\left(2 \cdot {k}^{2}\right) \cdot \frac{{t\_m}^{2} \cdot \frac{t\_m}{\ell}}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(k \cdot 2\right) \cdot \left(\sin k \cdot \frac{{t\_m}^{3}}{\ell \cdot \ell}\right)}\\
\end{array}
\end{array}
if t < 6.2000000000000006e70Initial program 55.3%
Simplified55.7%
add-sqr-sqrt39.7%
pow239.7%
Applied egg-rr39.5%
Taylor expanded in t around 0 37.5%
*-commutative37.5%
unpow-prod-down35.3%
pow235.3%
add-sqr-sqrt77.0%
times-frac77.0%
Applied egg-rr77.0%
times-frac77.0%
associate-*r/77.0%
Simplified77.0%
if 6.2000000000000006e70 < t < 1.15000000000000004e103Initial program 83.0%
Simplified83.1%
associate-*r*99.7%
*-un-lft-identity99.7%
times-frac99.6%
associate-/l/99.6%
Applied egg-rr99.6%
/-rgt-identity99.6%
associate-*l/99.4%
associate-*l*99.6%
Simplified99.6%
Taylor expanded in k around 0 82.0%
*-commutative82.0%
Simplified82.0%
if 1.15000000000000004e103 < t < 3.6000000000000003e125Initial program 1.6%
Simplified0.0%
Taylor expanded in k around 0 0.0%
unpow30.0%
*-un-lft-identity0.0%
times-frac75.0%
pow275.0%
Applied egg-rr75.0%
if 3.6000000000000003e125 < t Initial program 67.2%
Simplified67.2%
Taylor expanded in k around 0 67.2%
*-commutative67.2%
Simplified67.2%
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 0.28)
(pow (* (pow t_m -0.5) (/ (* l (sqrt 2.0)) (pow k 2.0))) 2.0)
(/
(* (* l l) (/ (/ 2.0 (tan k)) (* k (pow t_m 3.0))))
(+ 2.0 (pow (/ k t_m) 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 (t_m <= 0.28) {
tmp = pow((pow(t_m, -0.5) * ((l * sqrt(2.0)) / pow(k, 2.0))), 2.0);
} else {
tmp = ((l * l) * ((2.0 / tan(k)) / (k * pow(t_m, 3.0)))) / (2.0 + pow((k / t_m), 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) :: tmp
if (t_m <= 0.28d0) then
tmp = ((t_m ** (-0.5d0)) * ((l * sqrt(2.0d0)) / (k ** 2.0d0))) ** 2.0d0
else
tmp = ((l * l) * ((2.0d0 / tan(k)) / (k * (t_m ** 3.0d0)))) / (2.0d0 + ((k / t_m) ** 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 tmp;
if (t_m <= 0.28) {
tmp = Math.pow((Math.pow(t_m, -0.5) * ((l * Math.sqrt(2.0)) / Math.pow(k, 2.0))), 2.0);
} else {
tmp = ((l * l) * ((2.0 / Math.tan(k)) / (k * Math.pow(t_m, 3.0)))) / (2.0 + Math.pow((k / t_m), 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): tmp = 0 if t_m <= 0.28: tmp = math.pow((math.pow(t_m, -0.5) * ((l * math.sqrt(2.0)) / math.pow(k, 2.0))), 2.0) else: tmp = ((l * l) * ((2.0 / math.tan(k)) / (k * math.pow(t_m, 3.0)))) / (2.0 + math.pow((k / t_m), 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 (t_m <= 0.28) tmp = Float64((t_m ^ -0.5) * Float64(Float64(l * sqrt(2.0)) / (k ^ 2.0))) ^ 2.0; else tmp = Float64(Float64(Float64(l * l) * Float64(Float64(2.0 / tan(k)) / Float64(k * (t_m ^ 3.0)))) / Float64(2.0 + (Float64(k / t_m) ^ 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) tmp = 0.0; if (t_m <= 0.28) tmp = ((t_m ^ -0.5) * ((l * sqrt(2.0)) / (k ^ 2.0))) ^ 2.0; else tmp = ((l * l) * ((2.0 / tan(k)) / (k * (t_m ^ 3.0)))) / (2.0 + ((k / t_m) ^ 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_] := N[(t$95$s * If[LessEqual[t$95$m, 0.28], N[Power[N[(N[Power[t$95$m, -0.5], $MachinePrecision] * N[(N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] / N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision], N[(N[(N[(l * l), $MachinePrecision] * N[(N[(2.0 / N[Tan[k], $MachinePrecision]), $MachinePrecision] / N[(k * N[Power[t$95$m, 3.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(2.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.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 0.28:\\
\;\;\;\;{\left({t\_m}^{-0.5} \cdot \frac{\ell \cdot \sqrt{2}}{{k}^{2}}\right)}^{2}\\
\mathbf{else}:\\
\;\;\;\;\frac{\left(\ell \cdot \ell\right) \cdot \frac{\frac{2}{\tan k}}{k \cdot {t\_m}^{3}}}{2 + {\left(\frac{k}{t\_m}\right)}^{2}}\\
\end{array}
\end{array}
if t < 0.28000000000000003Initial program 53.1%
Simplified53.5%
add-sqr-sqrt37.0%
pow237.0%
Applied egg-rr37.3%
Taylor expanded in t around 0 35.7%
Taylor expanded in k around 0 23.8%
pow123.8%
associate-/l*23.8%
pow1/223.8%
inv-pow23.8%
pow-pow23.8%
metadata-eval23.8%
Applied egg-rr23.8%
unpow123.8%
associate-*r/23.8%
Simplified23.8%
if 0.28000000000000003 < t Initial program 70.5%
Simplified70.5%
Taylor expanded in k around 0 66.0%
Final simplification34.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 0.3)
(pow (/ (* (* l (sqrt 2.0)) (pow t_m -0.5)) (pow k 2.0)) 2.0)
(/
(* (* l l) (/ (/ 2.0 (tan k)) (* k (pow t_m 3.0))))
(+ 2.0 (pow (/ k t_m) 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 (t_m <= 0.3) {
tmp = pow((((l * sqrt(2.0)) * pow(t_m, -0.5)) / pow(k, 2.0)), 2.0);
} else {
tmp = ((l * l) * ((2.0 / tan(k)) / (k * pow(t_m, 3.0)))) / (2.0 + pow((k / t_m), 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) :: tmp
if (t_m <= 0.3d0) then
tmp = (((l * sqrt(2.0d0)) * (t_m ** (-0.5d0))) / (k ** 2.0d0)) ** 2.0d0
else
tmp = ((l * l) * ((2.0d0 / tan(k)) / (k * (t_m ** 3.0d0)))) / (2.0d0 + ((k / t_m) ** 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 tmp;
if (t_m <= 0.3) {
tmp = Math.pow((((l * Math.sqrt(2.0)) * Math.pow(t_m, -0.5)) / Math.pow(k, 2.0)), 2.0);
} else {
tmp = ((l * l) * ((2.0 / Math.tan(k)) / (k * Math.pow(t_m, 3.0)))) / (2.0 + Math.pow((k / t_m), 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): tmp = 0 if t_m <= 0.3: tmp = math.pow((((l * math.sqrt(2.0)) * math.pow(t_m, -0.5)) / math.pow(k, 2.0)), 2.0) else: tmp = ((l * l) * ((2.0 / math.tan(k)) / (k * math.pow(t_m, 3.0)))) / (2.0 + math.pow((k / t_m), 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 (t_m <= 0.3) tmp = Float64(Float64(Float64(l * sqrt(2.0)) * (t_m ^ -0.5)) / (k ^ 2.0)) ^ 2.0; else tmp = Float64(Float64(Float64(l * l) * Float64(Float64(2.0 / tan(k)) / Float64(k * (t_m ^ 3.0)))) / Float64(2.0 + (Float64(k / t_m) ^ 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) tmp = 0.0; if (t_m <= 0.3) tmp = (((l * sqrt(2.0)) * (t_m ^ -0.5)) / (k ^ 2.0)) ^ 2.0; else tmp = ((l * l) * ((2.0 / tan(k)) / (k * (t_m ^ 3.0)))) / (2.0 + ((k / t_m) ^ 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_] := N[(t$95$s * If[LessEqual[t$95$m, 0.3], N[Power[N[(N[(N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] * N[Power[t$95$m, -0.5], $MachinePrecision]), $MachinePrecision] / N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision], N[(N[(N[(l * l), $MachinePrecision] * N[(N[(2.0 / N[Tan[k], $MachinePrecision]), $MachinePrecision] / N[(k * N[Power[t$95$m, 3.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(2.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.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 0.3:\\
\;\;\;\;{\left(\frac{\left(\ell \cdot \sqrt{2}\right) \cdot {t\_m}^{-0.5}}{{k}^{2}}\right)}^{2}\\
\mathbf{else}:\\
\;\;\;\;\frac{\left(\ell \cdot \ell\right) \cdot \frac{\frac{2}{\tan k}}{k \cdot {t\_m}^{3}}}{2 + {\left(\frac{k}{t\_m}\right)}^{2}}\\
\end{array}
\end{array}
if t < 0.299999999999999989Initial program 53.1%
Simplified53.5%
add-sqr-sqrt37.0%
pow237.0%
Applied egg-rr37.3%
Taylor expanded in t around 0 35.7%
Taylor expanded in k around 0 23.8%
associate-*l/23.8%
pow1/223.8%
inv-pow23.8%
pow-pow23.8%
metadata-eval23.8%
Applied egg-rr23.8%
if 0.299999999999999989 < t Initial program 70.5%
Simplified70.5%
Taylor expanded in k around 0 66.0%
Final simplification34.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 (<= k 2.3e-119)
(/ 2.0 (* (* 2.0 (pow k 2.0)) (/ (pow (/ t_m (cbrt l)) 3.0) l)))
(if (<= k 1.55e+142)
(* (/ (* l 2.0) (* (pow t_m 3.0) (* (sin k) (tan k)))) (* l 0.5))
(* (pow l 2.0) (/ 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 <= 2.3e-119) {
tmp = 2.0 / ((2.0 * pow(k, 2.0)) * (pow((t_m / cbrt(l)), 3.0) / l));
} else if (k <= 1.55e+142) {
tmp = ((l * 2.0) / (pow(t_m, 3.0) * (sin(k) * tan(k)))) * (l * 0.5);
} else {
tmp = pow(l, 2.0) * (2.0 / (t_m * pow(k, 4.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.3e-119) {
tmp = 2.0 / ((2.0 * Math.pow(k, 2.0)) * (Math.pow((t_m / Math.cbrt(l)), 3.0) / l));
} else if (k <= 1.55e+142) {
tmp = ((l * 2.0) / (Math.pow(t_m, 3.0) * (Math.sin(k) * Math.tan(k)))) * (l * 0.5);
} else {
tmp = Math.pow(l, 2.0) * (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 <= 2.3e-119) tmp = Float64(2.0 / Float64(Float64(2.0 * (k ^ 2.0)) * Float64((Float64(t_m / cbrt(l)) ^ 3.0) / l))); elseif (k <= 1.55e+142) tmp = Float64(Float64(Float64(l * 2.0) / Float64((t_m ^ 3.0) * Float64(sin(k) * tan(k)))) * Float64(l * 0.5)); else tmp = Float64((l ^ 2.0) * Float64(2.0 / Float64(t_m * (k ^ 4.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.3e-119], N[(2.0 / N[(N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[(N[Power[N[(t$95$m / N[Power[l, 1/3], $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 1.55e+142], N[(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] * N[(l * 0.5), $MachinePrecision]), $MachinePrecision], N[(N[Power[l, 2.0], $MachinePrecision] * N[(2.0 / N[(t$95$m * N[Power[k, 4.0], $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}\;k \leq 2.3 \cdot 10^{-119}:\\
\;\;\;\;\frac{2}{\left(2 \cdot {k}^{2}\right) \cdot \frac{{\left(\frac{t\_m}{\sqrt[3]{\ell}}\right)}^{3}}{\ell}}\\
\mathbf{elif}\;k \leq 1.55 \cdot 10^{+142}:\\
\;\;\;\;\frac{\ell \cdot 2}{{t\_m}^{3} \cdot \left(\sin k \cdot \tan k\right)} \cdot \left(\ell \cdot 0.5\right)\\
\mathbf{else}:\\
\;\;\;\;{\ell}^{2} \cdot \frac{2}{t\_m \cdot {k}^{4}}\\
\end{array}
\end{array}
if k < 2.29999999999999993e-119Initial program 57.2%
Simplified59.2%
Taylor expanded in k around 0 56.2%
add-cube-cbrt59.0%
pow359.1%
cbrt-div59.0%
rem-cbrt-cube65.3%
Applied egg-rr59.6%
if 2.29999999999999993e-119 < k < 1.55e142Initial program 66.2%
Simplified66.3%
associate-*r*69.7%
*-un-lft-identity69.7%
times-frac69.5%
associate-/l/69.6%
Applied egg-rr69.6%
/-rgt-identity69.6%
associate-*l/69.6%
associate-*l*69.6%
Simplified69.6%
Taylor expanded in k around 0 72.6%
*-commutative72.6%
Simplified72.6%
if 1.55e142 < k Initial program 38.5%
Simplified38.5%
add-sqr-sqrt38.5%
pow238.5%
Applied egg-rr26.8%
Taylor expanded in t around 0 34.3%
Taylor expanded in k around 0 55.7%
associate-/l*55.7%
unpow255.7%
rem-square-sqrt55.7%
*-commutative55.7%
Simplified55.7%
Final simplification62.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 3.2e-15)
(/ 2.0 (* (* 2.0 (pow k 2.0)) (/ (pow (/ t_m (cbrt l)) 3.0) l)))
(* (pow l 2.0) (/ 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 <= 3.2e-15) {
tmp = 2.0 / ((2.0 * pow(k, 2.0)) * (pow((t_m / cbrt(l)), 3.0) / l));
} else {
tmp = pow(l, 2.0) * (2.0 / (t_m * pow(k, 4.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 <= 3.2e-15) {
tmp = 2.0 / ((2.0 * Math.pow(k, 2.0)) * (Math.pow((t_m / Math.cbrt(l)), 3.0) / l));
} else {
tmp = Math.pow(l, 2.0) * (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 <= 3.2e-15) tmp = Float64(2.0 / Float64(Float64(2.0 * (k ^ 2.0)) * Float64((Float64(t_m / cbrt(l)) ^ 3.0) / l))); else tmp = Float64((l ^ 2.0) * Float64(2.0 / Float64(t_m * (k ^ 4.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, 3.2e-15], N[(2.0 / N[(N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[(N[Power[N[(t$95$m / N[Power[l, 1/3], $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[Power[l, 2.0], $MachinePrecision] * N[(2.0 / N[(t$95$m * N[Power[k, 4.0], $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}\;k \leq 3.2 \cdot 10^{-15}:\\
\;\;\;\;\frac{2}{\left(2 \cdot {k}^{2}\right) \cdot \frac{{\left(\frac{t\_m}{\sqrt[3]{\ell}}\right)}^{3}}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;{\ell}^{2} \cdot \frac{2}{t\_m \cdot {k}^{4}}\\
\end{array}
\end{array}
if k < 3.1999999999999999e-15Initial program 59.5%
Simplified61.2%
Taylor expanded in k around 0 59.6%
add-cube-cbrt61.1%
pow361.1%
cbrt-div61.1%
rem-cbrt-cube66.7%
Applied egg-rr62.7%
if 3.1999999999999999e-15 < k Initial program 50.2%
Simplified50.2%
add-sqr-sqrt46.6%
pow246.6%
Applied egg-rr36.6%
Taylor expanded in t around 0 38.4%
Taylor expanded in k around 0 56.8%
associate-/l*56.8%
unpow256.8%
rem-square-sqrt56.8%
*-commutative56.8%
Simplified56.8%
Final simplification61.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 9e+142)
(/ 2.0 (* (pow (/ t_m (cbrt l)) 3.0) (/ (* 2.0 (pow k 2.0)) l)))
(* (pow l 2.0) (/ 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 <= 9e+142) {
tmp = 2.0 / (pow((t_m / cbrt(l)), 3.0) * ((2.0 * pow(k, 2.0)) / l));
} else {
tmp = pow(l, 2.0) * (2.0 / (t_m * pow(k, 4.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 <= 9e+142) {
tmp = 2.0 / (Math.pow((t_m / Math.cbrt(l)), 3.0) * ((2.0 * Math.pow(k, 2.0)) / l));
} else {
tmp = Math.pow(l, 2.0) * (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 <= 9e+142) tmp = Float64(2.0 / Float64((Float64(t_m / cbrt(l)) ^ 3.0) * Float64(Float64(2.0 * (k ^ 2.0)) / l))); else tmp = Float64((l ^ 2.0) * Float64(2.0 / Float64(t_m * (k ^ 4.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, 9e+142], N[(2.0 / N[(N[Power[N[(t$95$m / N[Power[l, 1/3], $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision] * N[(N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[Power[l, 2.0], $MachinePrecision] * N[(2.0 / N[(t$95$m * N[Power[k, 4.0], $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}\;k \leq 9 \cdot 10^{+142}:\\
\;\;\;\;\frac{2}{{\left(\frac{t\_m}{\sqrt[3]{\ell}}\right)}^{3} \cdot \frac{2 \cdot {k}^{2}}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;{\ell}^{2} \cdot \frac{2}{t\_m \cdot {k}^{4}}\\
\end{array}
\end{array}
if k < 8.9999999999999998e142Initial program 59.4%
Simplified61.7%
Taylor expanded in k around 0 58.9%
associate-*l/59.7%
Applied egg-rr59.7%
associate-/l*59.6%
Simplified59.6%
add-cube-cbrt61.6%
pow361.6%
cbrt-div61.6%
rem-cbrt-cube67.2%
Applied egg-rr62.7%
if 8.9999999999999998e142 < k Initial program 38.5%
Simplified38.5%
add-sqr-sqrt38.5%
pow238.5%
Applied egg-rr26.8%
Taylor expanded in t around 0 34.3%
Taylor expanded in k around 0 55.7%
associate-/l*55.7%
unpow255.7%
rem-square-sqrt55.7%
*-commutative55.7%
Simplified55.7%
Final simplification62.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 (<= k 7.2e-207)
(/ 2.0 (* (* k 2.0) (* (sin k) (/ (pow t_m 3.0) (* l l)))))
(if (<= k 2.5e-15)
(/ 2.0 (/ (* (* 2.0 (pow k 2.0)) (/ (pow t_m 3.0) l)) l))
(* (pow l 2.0) (/ 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-207) {
tmp = 2.0 / ((k * 2.0) * (sin(k) * (pow(t_m, 3.0) / (l * l))));
} else if (k <= 2.5e-15) {
tmp = 2.0 / (((2.0 * pow(k, 2.0)) * (pow(t_m, 3.0) / l)) / l);
} else {
tmp = pow(l, 2.0) * (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-207) then
tmp = 2.0d0 / ((k * 2.0d0) * (sin(k) * ((t_m ** 3.0d0) / (l * l))))
else if (k <= 2.5d-15) then
tmp = 2.0d0 / (((2.0d0 * (k ** 2.0d0)) * ((t_m ** 3.0d0) / l)) / l)
else
tmp = (l ** 2.0d0) * (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-207) {
tmp = 2.0 / ((k * 2.0) * (Math.sin(k) * (Math.pow(t_m, 3.0) / (l * l))));
} else if (k <= 2.5e-15) {
tmp = 2.0 / (((2.0 * Math.pow(k, 2.0)) * (Math.pow(t_m, 3.0) / l)) / l);
} else {
tmp = Math.pow(l, 2.0) * (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-207: tmp = 2.0 / ((k * 2.0) * (math.sin(k) * (math.pow(t_m, 3.0) / (l * l)))) elif k <= 2.5e-15: tmp = 2.0 / (((2.0 * math.pow(k, 2.0)) * (math.pow(t_m, 3.0) / l)) / l) else: tmp = math.pow(l, 2.0) * (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-207) tmp = Float64(2.0 / Float64(Float64(k * 2.0) * Float64(sin(k) * Float64((t_m ^ 3.0) / Float64(l * l))))); elseif (k <= 2.5e-15) tmp = Float64(2.0 / Float64(Float64(Float64(2.0 * (k ^ 2.0)) * Float64((t_m ^ 3.0) / l)) / l)); else tmp = Float64((l ^ 2.0) * Float64(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-207) tmp = 2.0 / ((k * 2.0) * (sin(k) * ((t_m ^ 3.0) / (l * l)))); elseif (k <= 2.5e-15) tmp = 2.0 / (((2.0 * (k ^ 2.0)) * ((t_m ^ 3.0) / l)) / l); else tmp = (l ^ 2.0) * (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-207], N[(2.0 / N[(N[(k * 2.0), $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[(N[Power[t$95$m, 3.0], $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 2.5e-15], N[(2.0 / N[(N[(N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[(N[Power[t$95$m, 3.0], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision], N[(N[Power[l, 2.0], $MachinePrecision] * N[(2.0 / N[(t$95$m * N[Power[k, 4.0], $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}\;k \leq 7.2 \cdot 10^{-207}:\\
\;\;\;\;\frac{2}{\left(k \cdot 2\right) \cdot \left(\sin k \cdot \frac{{t\_m}^{3}}{\ell \cdot \ell}\right)}\\
\mathbf{elif}\;k \leq 2.5 \cdot 10^{-15}:\\
\;\;\;\;\frac{2}{\frac{\left(2 \cdot {k}^{2}\right) \cdot \frac{{t\_m}^{3}}{\ell}}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;{\ell}^{2} \cdot \frac{2}{t\_m \cdot {k}^{4}}\\
\end{array}
\end{array}
if k < 7.1999999999999993e-207Initial program 56.7%
Simplified56.7%
Taylor expanded in k around 0 54.9%
*-commutative54.9%
Simplified54.9%
if 7.1999999999999993e-207 < k < 2.5e-15Initial program 67.7%
Simplified70.1%
Taylor expanded in k around 0 74.3%
associate-*l/76.2%
Applied egg-rr76.2%
if 2.5e-15 < k Initial program 50.2%
Simplified50.2%
add-sqr-sqrt46.6%
pow246.6%
Applied egg-rr36.6%
Taylor expanded in t around 0 38.4%
Taylor expanded in k around 0 56.8%
associate-/l*56.8%
unpow256.8%
rem-square-sqrt56.8%
*-commutative56.8%
Simplified56.8%
Final simplification59.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 (<= k 2.3e-15)
(/ 2.0 (* (* 2.0 (pow k 2.0)) (/ (* (pow t_m 2.0) (/ t_m l)) l)))
(* (pow l 2.0) (/ 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 <= 2.3e-15) {
tmp = 2.0 / ((2.0 * pow(k, 2.0)) * ((pow(t_m, 2.0) * (t_m / l)) / l));
} else {
tmp = pow(l, 2.0) * (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 <= 2.3d-15) then
tmp = 2.0d0 / ((2.0d0 * (k ** 2.0d0)) * (((t_m ** 2.0d0) * (t_m / l)) / l))
else
tmp = (l ** 2.0d0) * (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 <= 2.3e-15) {
tmp = 2.0 / ((2.0 * Math.pow(k, 2.0)) * ((Math.pow(t_m, 2.0) * (t_m / l)) / l));
} else {
tmp = Math.pow(l, 2.0) * (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 <= 2.3e-15: tmp = 2.0 / ((2.0 * math.pow(k, 2.0)) * ((math.pow(t_m, 2.0) * (t_m / l)) / l)) else: tmp = math.pow(l, 2.0) * (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 <= 2.3e-15) tmp = Float64(2.0 / Float64(Float64(2.0 * (k ^ 2.0)) * Float64(Float64((t_m ^ 2.0) * Float64(t_m / l)) / l))); else tmp = Float64((l ^ 2.0) * Float64(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 <= 2.3e-15) tmp = 2.0 / ((2.0 * (k ^ 2.0)) * (((t_m ^ 2.0) * (t_m / l)) / l)); else tmp = (l ^ 2.0) * (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, 2.3e-15], N[(2.0 / N[(N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[(N[(N[Power[t$95$m, 2.0], $MachinePrecision] * N[(t$95$m / l), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[Power[l, 2.0], $MachinePrecision] * N[(2.0 / N[(t$95$m * N[Power[k, 4.0], $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}\;k \leq 2.3 \cdot 10^{-15}:\\
\;\;\;\;\frac{2}{\left(2 \cdot {k}^{2}\right) \cdot \frac{{t\_m}^{2} \cdot \frac{t\_m}{\ell}}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;{\ell}^{2} \cdot \frac{2}{t\_m \cdot {k}^{4}}\\
\end{array}
\end{array}
if k < 2.2999999999999999e-15Initial program 59.5%
Simplified61.2%
Taylor expanded in k around 0 59.6%
unpow359.6%
*-un-lft-identity59.6%
times-frac62.1%
pow262.1%
Applied egg-rr62.1%
if 2.2999999999999999e-15 < k Initial program 50.2%
Simplified50.2%
add-sqr-sqrt46.6%
pow246.6%
Applied egg-rr36.6%
Taylor expanded in t around 0 38.4%
Taylor expanded in k around 0 56.8%
associate-/l*56.8%
unpow256.8%
rem-square-sqrt56.8%
*-commutative56.8%
Simplified56.8%
Final simplification60.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 1.75e-15)
(/ 2.0 (* (* 2.0 (pow k 2.0)) (/ (/ (pow t_m 3.0) l) l)))
(* (pow l 2.0) (/ 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 <= 1.75e-15) {
tmp = 2.0 / ((2.0 * pow(k, 2.0)) * ((pow(t_m, 3.0) / l) / l));
} else {
tmp = pow(l, 2.0) * (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 <= 1.75d-15) then
tmp = 2.0d0 / ((2.0d0 * (k ** 2.0d0)) * (((t_m ** 3.0d0) / l) / l))
else
tmp = (l ** 2.0d0) * (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 <= 1.75e-15) {
tmp = 2.0 / ((2.0 * Math.pow(k, 2.0)) * ((Math.pow(t_m, 3.0) / l) / l));
} else {
tmp = Math.pow(l, 2.0) * (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 <= 1.75e-15: tmp = 2.0 / ((2.0 * math.pow(k, 2.0)) * ((math.pow(t_m, 3.0) / l) / l)) else: tmp = math.pow(l, 2.0) * (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 <= 1.75e-15) tmp = Float64(2.0 / Float64(Float64(2.0 * (k ^ 2.0)) * Float64(Float64((t_m ^ 3.0) / l) / l))); else tmp = Float64((l ^ 2.0) * Float64(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 <= 1.75e-15) tmp = 2.0 / ((2.0 * (k ^ 2.0)) * (((t_m ^ 3.0) / l) / l)); else tmp = (l ^ 2.0) * (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, 1.75e-15], N[(2.0 / N[(N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[(N[(N[Power[t$95$m, 3.0], $MachinePrecision] / l), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[Power[l, 2.0], $MachinePrecision] * N[(2.0 / N[(t$95$m * N[Power[k, 4.0], $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}\;k \leq 1.75 \cdot 10^{-15}:\\
\;\;\;\;\frac{2}{\left(2 \cdot {k}^{2}\right) \cdot \frac{\frac{{t\_m}^{3}}{\ell}}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;{\ell}^{2} \cdot \frac{2}{t\_m \cdot {k}^{4}}\\
\end{array}
\end{array}
if k < 1.75e-15Initial program 59.5%
Simplified61.2%
Taylor expanded in k around 0 59.6%
if 1.75e-15 < k Initial program 50.2%
Simplified50.2%
add-sqr-sqrt46.6%
pow246.6%
Applied egg-rr36.6%
Taylor expanded in t around 0 38.4%
Taylor expanded in k around 0 56.8%
associate-/l*56.8%
unpow256.8%
rem-square-sqrt56.8%
*-commutative56.8%
Simplified56.8%
Final simplification59.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 (<= k 5.5e+142)
(/ 2.0 (* (/ (* 2.0 (pow k 2.0)) l) (/ (pow t_m 3.0) l)))
(* (pow l 2.0) (/ 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 <= 5.5e+142) {
tmp = 2.0 / (((2.0 * pow(k, 2.0)) / l) * (pow(t_m, 3.0) / l));
} else {
tmp = pow(l, 2.0) * (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 <= 5.5d+142) then
tmp = 2.0d0 / (((2.0d0 * (k ** 2.0d0)) / l) * ((t_m ** 3.0d0) / l))
else
tmp = (l ** 2.0d0) * (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 <= 5.5e+142) {
tmp = 2.0 / (((2.0 * Math.pow(k, 2.0)) / l) * (Math.pow(t_m, 3.0) / l));
} else {
tmp = Math.pow(l, 2.0) * (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 <= 5.5e+142: tmp = 2.0 / (((2.0 * math.pow(k, 2.0)) / l) * (math.pow(t_m, 3.0) / l)) else: tmp = math.pow(l, 2.0) * (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 <= 5.5e+142) tmp = Float64(2.0 / Float64(Float64(Float64(2.0 * (k ^ 2.0)) / l) * Float64((t_m ^ 3.0) / l))); else tmp = Float64((l ^ 2.0) * Float64(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 <= 5.5e+142) tmp = 2.0 / (((2.0 * (k ^ 2.0)) / l) * ((t_m ^ 3.0) / l)); else tmp = (l ^ 2.0) * (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, 5.5e+142], 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] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[Power[l, 2.0], $MachinePrecision] * N[(2.0 / N[(t$95$m * N[Power[k, 4.0], $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}\;k \leq 5.5 \cdot 10^{+142}:\\
\;\;\;\;\frac{2}{\frac{2 \cdot {k}^{2}}{\ell} \cdot \frac{{t\_m}^{3}}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;{\ell}^{2} \cdot \frac{2}{t\_m \cdot {k}^{4}}\\
\end{array}
\end{array}
if k < 5.50000000000000035e142Initial program 59.4%
Simplified61.7%
Taylor expanded in k around 0 58.9%
associate-*l/59.7%
Applied egg-rr59.7%
associate-/l*59.6%
Simplified59.6%
if 5.50000000000000035e142 < k Initial program 38.5%
Simplified38.5%
add-sqr-sqrt38.5%
pow238.5%
Applied egg-rr26.8%
Taylor expanded in t around 0 34.3%
Taylor expanded in k around 0 55.7%
associate-/l*55.7%
unpow255.7%
rem-square-sqrt55.7%
*-commutative55.7%
Simplified55.7%
Final simplification59.2%
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 3.2e-15)
(/ 2.0 (/ (* (* 2.0 (pow k 2.0)) (/ (pow t_m 3.0) l)) l))
(* (pow l 2.0) (/ 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 <= 3.2e-15) {
tmp = 2.0 / (((2.0 * pow(k, 2.0)) * (pow(t_m, 3.0) / l)) / l);
} else {
tmp = pow(l, 2.0) * (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 <= 3.2d-15) then
tmp = 2.0d0 / (((2.0d0 * (k ** 2.0d0)) * ((t_m ** 3.0d0) / l)) / l)
else
tmp = (l ** 2.0d0) * (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 <= 3.2e-15) {
tmp = 2.0 / (((2.0 * Math.pow(k, 2.0)) * (Math.pow(t_m, 3.0) / l)) / l);
} else {
tmp = Math.pow(l, 2.0) * (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 <= 3.2e-15: tmp = 2.0 / (((2.0 * math.pow(k, 2.0)) * (math.pow(t_m, 3.0) / l)) / l) else: tmp = math.pow(l, 2.0) * (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 <= 3.2e-15) tmp = Float64(2.0 / Float64(Float64(Float64(2.0 * (k ^ 2.0)) * Float64((t_m ^ 3.0) / l)) / l)); else tmp = Float64((l ^ 2.0) * Float64(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 <= 3.2e-15) tmp = 2.0 / (((2.0 * (k ^ 2.0)) * ((t_m ^ 3.0) / l)) / l); else tmp = (l ^ 2.0) * (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, 3.2e-15], N[(2.0 / N[(N[(N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[(N[Power[t$95$m, 3.0], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision], N[(N[Power[l, 2.0], $MachinePrecision] * N[(2.0 / N[(t$95$m * N[Power[k, 4.0], $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}\;k \leq 3.2 \cdot 10^{-15}:\\
\;\;\;\;\frac{2}{\frac{\left(2 \cdot {k}^{2}\right) \cdot \frac{{t\_m}^{3}}{\ell}}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;{\ell}^{2} \cdot \frac{2}{t\_m \cdot {k}^{4}}\\
\end{array}
\end{array}
if k < 3.1999999999999999e-15Initial program 59.5%
Simplified61.2%
Taylor expanded in k around 0 59.6%
associate-*l/60.6%
Applied egg-rr60.6%
if 3.1999999999999999e-15 < k Initial program 50.2%
Simplified50.2%
add-sqr-sqrt46.6%
pow246.6%
Applied egg-rr36.6%
Taylor expanded in t around 0 38.4%
Taylor expanded in k around 0 56.8%
associate-/l*56.8%
unpow256.8%
rem-square-sqrt56.8%
*-commutative56.8%
Simplified56.8%
Final simplification59.7%
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 (* (pow l 2.0) (/ 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 * (pow(l, 2.0) * (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 * ((l ** 2.0d0) * (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 * (Math.pow(l, 2.0) * (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 * (math.pow(l, 2.0) * (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((l ^ 2.0) * Float64(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 * ((l ^ 2.0) * (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[Power[l, 2.0], $MachinePrecision] * N[(2.0 / N[(t$95$m * N[Power[k, 4.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \left({\ell}^{2} \cdot \frac{2}{t\_m \cdot {k}^{4}}\right)
\end{array}
Initial program 57.3%
Simplified57.6%
add-sqr-sqrt44.7%
pow244.7%
Applied egg-rr45.0%
Taylor expanded in t around 0 38.2%
Taylor expanded in k around 0 54.7%
associate-/l*54.7%
unpow254.7%
rem-square-sqrt54.7%
*-commutative54.7%
Simplified54.7%
Final simplification54.7%
herbie shell --seed 2024112
(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))))