
(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 15 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 (/ (sqrt 2.0) k))
(t_3 (* (sin k) (tan k)))
(t_4 (cbrt t_3))
(t_5 (pow (cbrt l) -2.0)))
(*
t_s
(if (<= (* l l) 1e-317)
(pow (* (/ (* l (sqrt 2.0)) (pow k 2.0)) (sqrt (/ 1.0 t_m))) 2.0)
(if (<= (* l l) 1e+307)
(* (* l l) (/ 2.0 (* t_3 (pow (* k (sqrt t_m)) 2.0))))
(*
(pow (cbrt (* t_2 (* t_m (pow (* t_4 (* t_m t_5)) -2.0)))) 3.0)
(* t_2 (/ (/ 1.0 t_5) t_4))))))))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 = sqrt(2.0) / k;
double t_3 = sin(k) * tan(k);
double t_4 = cbrt(t_3);
double t_5 = pow(cbrt(l), -2.0);
double tmp;
if ((l * l) <= 1e-317) {
tmp = pow((((l * sqrt(2.0)) / pow(k, 2.0)) * sqrt((1.0 / t_m))), 2.0);
} else if ((l * l) <= 1e+307) {
tmp = (l * l) * (2.0 / (t_3 * pow((k * sqrt(t_m)), 2.0)));
} else {
tmp = pow(cbrt((t_2 * (t_m * pow((t_4 * (t_m * t_5)), -2.0)))), 3.0) * (t_2 * ((1.0 / t_5) / t_4));
}
return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double t_2 = Math.sqrt(2.0) / k;
double t_3 = Math.sin(k) * Math.tan(k);
double t_4 = Math.cbrt(t_3);
double t_5 = Math.pow(Math.cbrt(l), -2.0);
double tmp;
if ((l * l) <= 1e-317) {
tmp = Math.pow((((l * Math.sqrt(2.0)) / Math.pow(k, 2.0)) * Math.sqrt((1.0 / t_m))), 2.0);
} else if ((l * l) <= 1e+307) {
tmp = (l * l) * (2.0 / (t_3 * Math.pow((k * Math.sqrt(t_m)), 2.0)));
} else {
tmp = Math.pow(Math.cbrt((t_2 * (t_m * Math.pow((t_4 * (t_m * t_5)), -2.0)))), 3.0) * (t_2 * ((1.0 / t_5) / t_4));
}
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(sqrt(2.0) / k) t_3 = Float64(sin(k) * tan(k)) t_4 = cbrt(t_3) t_5 = cbrt(l) ^ -2.0 tmp = 0.0 if (Float64(l * l) <= 1e-317) tmp = Float64(Float64(Float64(l * sqrt(2.0)) / (k ^ 2.0)) * sqrt(Float64(1.0 / t_m))) ^ 2.0; elseif (Float64(l * l) <= 1e+307) tmp = Float64(Float64(l * l) * Float64(2.0 / Float64(t_3 * (Float64(k * sqrt(t_m)) ^ 2.0)))); else tmp = Float64((cbrt(Float64(t_2 * Float64(t_m * (Float64(t_4 * Float64(t_m * t_5)) ^ -2.0)))) ^ 3.0) * Float64(t_2 * Float64(Float64(1.0 / t_5) / t_4))); 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[(N[Sqrt[2.0], $MachinePrecision] / k), $MachinePrecision]}, Block[{t$95$3 = N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[Power[t$95$3, 1/3], $MachinePrecision]}, Block[{t$95$5 = N[Power[N[Power[l, 1/3], $MachinePrecision], -2.0], $MachinePrecision]}, N[(t$95$s * If[LessEqual[N[(l * l), $MachinePrecision], 1e-317], N[Power[N[(N[(N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] / N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(1.0 / t$95$m), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision], If[LessEqual[N[(l * l), $MachinePrecision], 1e+307], N[(N[(l * l), $MachinePrecision] * N[(2.0 / N[(t$95$3 * N[Power[N[(k * N[Sqrt[t$95$m], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[Power[N[Power[N[(t$95$2 * N[(t$95$m * N[Power[N[(t$95$4 * N[(t$95$m * t$95$5), $MachinePrecision]), $MachinePrecision], -2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 1/3], $MachinePrecision], 3.0], $MachinePrecision] * N[(t$95$2 * N[(N[(1.0 / t$95$5), $MachinePrecision] / t$95$4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]]]]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
\begin{array}{l}
t_2 := \frac{\sqrt{2}}{k}\\
t_3 := \sin k \cdot \tan k\\
t_4 := \sqrt[3]{t\_3}\\
t_5 := {\left(\sqrt[3]{\ell}\right)}^{-2}\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;\ell \cdot \ell \leq 10^{-317}:\\
\;\;\;\;{\left(\frac{\ell \cdot \sqrt{2}}{{k}^{2}} \cdot \sqrt{\frac{1}{t\_m}}\right)}^{2}\\
\mathbf{elif}\;\ell \cdot \ell \leq 10^{+307}:\\
\;\;\;\;\left(\ell \cdot \ell\right) \cdot \frac{2}{t\_3 \cdot {\left(k \cdot \sqrt{t\_m}\right)}^{2}}\\
\mathbf{else}:\\
\;\;\;\;{\left(\sqrt[3]{t\_2 \cdot \left(t\_m \cdot {\left(t\_4 \cdot \left(t\_m \cdot t\_5\right)\right)}^{-2}\right)}\right)}^{3} \cdot \left(t\_2 \cdot \frac{\frac{1}{t\_5}}{t\_4}\right)\\
\end{array}
\end{array}
\end{array}
if (*.f64 l l) < 1.00000023e-317Initial program 31.1%
Simplified42.0%
add-sqr-sqrt42.0%
pow242.0%
Applied egg-rr29.2%
associate-/r*29.8%
Simplified29.8%
Taylor expanded in k around 0 43.0%
if 1.00000023e-317 < (*.f64 l l) < 9.99999999999999986e306Initial program 44.8%
Simplified54.9%
add-sqr-sqrt28.3%
pow228.3%
*-commutative28.3%
sqrt-prod26.0%
associate-*r*26.0%
sqrt-prod28.1%
sqrt-pow130.5%
metadata-eval30.5%
pow130.5%
sqrt-pow132.0%
metadata-eval32.0%
Applied egg-rr32.0%
associate-*l*32.7%
associate-*l/33.5%
Simplified33.5%
unpow233.5%
associate-/l*33.5%
pow133.5%
pow-div33.5%
metadata-eval33.5%
pow1/233.5%
associate-/l*33.5%
pow133.5%
pow-div37.8%
metadata-eval37.8%
pow1/237.8%
Applied egg-rr37.8%
swap-sqr37.9%
rem-square-sqrt47.8%
unpow147.8%
pow-plus47.8%
metadata-eval47.8%
Simplified47.8%
if 9.99999999999999986e306 < (*.f64 l l) Initial program 20.4%
Simplified20.4%
Applied egg-rr82.3%
associate-/r/82.3%
associate-/r*82.2%
associate-/r/83.7%
Simplified83.7%
associate-*r/83.8%
Applied egg-rr83.8%
associate-/l*83.8%
associate-*l*91.2%
associate-*l*91.1%
associate-/l*91.2%
associate-/r*91.2%
*-inverses91.2%
Simplified91.2%
associate-*r*83.8%
associate-*r*83.8%
add-cube-cbrt83.9%
pow383.9%
Applied egg-rr91.2%
Final simplification58.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 (/ (sqrt 2.0) k))
(t_3 (pow (cbrt l) -2.0))
(t_4 (* (sin k) (tan k)))
(t_5 (cbrt t_4)))
(*
t_s
(if (<= (* l l) 1e-317)
(pow (* (/ (* l (sqrt 2.0)) (pow k 2.0)) (sqrt (/ 1.0 t_m))) 2.0)
(if (<= (* l l) 1e+307)
(* (* l l) (/ 2.0 (* t_4 (pow (* k (sqrt t_m)) 2.0))))
(*
(* t_2 (/ (/ 1.0 t_3) t_5))
(* t_2 (* t_m (pow (* t_m (* t_5 t_3)) -2.0)))))))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double t_2 = sqrt(2.0) / k;
double t_3 = pow(cbrt(l), -2.0);
double t_4 = sin(k) * tan(k);
double t_5 = cbrt(t_4);
double tmp;
if ((l * l) <= 1e-317) {
tmp = pow((((l * sqrt(2.0)) / pow(k, 2.0)) * sqrt((1.0 / t_m))), 2.0);
} else if ((l * l) <= 1e+307) {
tmp = (l * l) * (2.0 / (t_4 * pow((k * sqrt(t_m)), 2.0)));
} else {
tmp = (t_2 * ((1.0 / t_3) / t_5)) * (t_2 * (t_m * pow((t_m * (t_5 * t_3)), -2.0)));
}
return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double t_2 = Math.sqrt(2.0) / k;
double t_3 = Math.pow(Math.cbrt(l), -2.0);
double t_4 = Math.sin(k) * Math.tan(k);
double t_5 = Math.cbrt(t_4);
double tmp;
if ((l * l) <= 1e-317) {
tmp = Math.pow((((l * Math.sqrt(2.0)) / Math.pow(k, 2.0)) * Math.sqrt((1.0 / t_m))), 2.0);
} else if ((l * l) <= 1e+307) {
tmp = (l * l) * (2.0 / (t_4 * Math.pow((k * Math.sqrt(t_m)), 2.0)));
} else {
tmp = (t_2 * ((1.0 / t_3) / t_5)) * (t_2 * (t_m * Math.pow((t_m * (t_5 * t_3)), -2.0)));
}
return t_s * tmp;
}
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) t_2 = Float64(sqrt(2.0) / k) t_3 = cbrt(l) ^ -2.0 t_4 = Float64(sin(k) * tan(k)) t_5 = cbrt(t_4) tmp = 0.0 if (Float64(l * l) <= 1e-317) tmp = Float64(Float64(Float64(l * sqrt(2.0)) / (k ^ 2.0)) * sqrt(Float64(1.0 / t_m))) ^ 2.0; elseif (Float64(l * l) <= 1e+307) tmp = Float64(Float64(l * l) * Float64(2.0 / Float64(t_4 * (Float64(k * sqrt(t_m)) ^ 2.0)))); else tmp = Float64(Float64(t_2 * Float64(Float64(1.0 / t_3) / t_5)) * Float64(t_2 * Float64(t_m * (Float64(t_m * Float64(t_5 * t_3)) ^ -2.0)))); end return Float64(t_s * tmp) end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := Block[{t$95$2 = N[(N[Sqrt[2.0], $MachinePrecision] / k), $MachinePrecision]}, Block[{t$95$3 = N[Power[N[Power[l, 1/3], $MachinePrecision], -2.0], $MachinePrecision]}, Block[{t$95$4 = N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[Power[t$95$4, 1/3], $MachinePrecision]}, N[(t$95$s * If[LessEqual[N[(l * l), $MachinePrecision], 1e-317], N[Power[N[(N[(N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] / N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(1.0 / t$95$m), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision], If[LessEqual[N[(l * l), $MachinePrecision], 1e+307], N[(N[(l * l), $MachinePrecision] * N[(2.0 / N[(t$95$4 * N[Power[N[(k * N[Sqrt[t$95$m], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(t$95$2 * N[(N[(1.0 / t$95$3), $MachinePrecision] / t$95$5), $MachinePrecision]), $MachinePrecision] * N[(t$95$2 * N[(t$95$m * N[Power[N[(t$95$m * N[(t$95$5 * t$95$3), $MachinePrecision]), $MachinePrecision], -2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]]]]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
\begin{array}{l}
t_2 := \frac{\sqrt{2}}{k}\\
t_3 := {\left(\sqrt[3]{\ell}\right)}^{-2}\\
t_4 := \sin k \cdot \tan k\\
t_5 := \sqrt[3]{t\_4}\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;\ell \cdot \ell \leq 10^{-317}:\\
\;\;\;\;{\left(\frac{\ell \cdot \sqrt{2}}{{k}^{2}} \cdot \sqrt{\frac{1}{t\_m}}\right)}^{2}\\
\mathbf{elif}\;\ell \cdot \ell \leq 10^{+307}:\\
\;\;\;\;\left(\ell \cdot \ell\right) \cdot \frac{2}{t\_4 \cdot {\left(k \cdot \sqrt{t\_m}\right)}^{2}}\\
\mathbf{else}:\\
\;\;\;\;\left(t\_2 \cdot \frac{\frac{1}{t\_3}}{t\_5}\right) \cdot \left(t\_2 \cdot \left(t\_m \cdot {\left(t\_m \cdot \left(t\_5 \cdot t\_3\right)\right)}^{-2}\right)\right)\\
\end{array}
\end{array}
\end{array}
if (*.f64 l l) < 1.00000023e-317Initial program 31.1%
Simplified42.0%
add-sqr-sqrt42.0%
pow242.0%
Applied egg-rr29.2%
associate-/r*29.8%
Simplified29.8%
Taylor expanded in k around 0 43.0%
if 1.00000023e-317 < (*.f64 l l) < 9.99999999999999986e306Initial program 44.8%
Simplified54.9%
add-sqr-sqrt28.3%
pow228.3%
*-commutative28.3%
sqrt-prod26.0%
associate-*r*26.0%
sqrt-prod28.1%
sqrt-pow130.5%
metadata-eval30.5%
pow130.5%
sqrt-pow132.0%
metadata-eval32.0%
Applied egg-rr32.0%
associate-*l*32.7%
associate-*l/33.5%
Simplified33.5%
unpow233.5%
associate-/l*33.5%
pow133.5%
pow-div33.5%
metadata-eval33.5%
pow1/233.5%
associate-/l*33.5%
pow133.5%
pow-div37.8%
metadata-eval37.8%
pow1/237.8%
Applied egg-rr37.8%
swap-sqr37.9%
rem-square-sqrt47.8%
unpow147.8%
pow-plus47.8%
metadata-eval47.8%
Simplified47.8%
if 9.99999999999999986e306 < (*.f64 l l) Initial program 20.4%
Simplified20.4%
Applied egg-rr82.3%
associate-/r/82.3%
associate-/r*82.2%
associate-/r/83.7%
Simplified83.7%
associate-*r/83.8%
Applied egg-rr83.8%
associate-/l*83.8%
associate-*l*91.2%
associate-*l*91.1%
associate-/l*91.2%
associate-/r*91.2%
*-inverses91.2%
Simplified91.2%
Final simplification58.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 (* (sin k) (tan k))) (t_3 (cbrt t_2)))
(*
t_s
(if (<= (* l l) 1e-317)
(pow (* (/ (* l (sqrt 2.0)) (pow k 2.0)) (sqrt (/ 1.0 t_m))) 2.0)
(if (<= (* l l) 1e+307)
(* (* l l) (/ 2.0 (* t_2 (pow (* k (sqrt t_m)) 2.0))))
(*
(*
(/ (sqrt 2.0) k)
(* t_m (pow (* t_m (* t_3 (pow (cbrt l) -2.0))) -2.0)))
(/ (* (sqrt 2.0) (pow (cbrt l) 2.0)) (* k t_3))))))))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 = sin(k) * tan(k);
double t_3 = cbrt(t_2);
double tmp;
if ((l * l) <= 1e-317) {
tmp = pow((((l * sqrt(2.0)) / pow(k, 2.0)) * sqrt((1.0 / t_m))), 2.0);
} else if ((l * l) <= 1e+307) {
tmp = (l * l) * (2.0 / (t_2 * pow((k * sqrt(t_m)), 2.0)));
} else {
tmp = ((sqrt(2.0) / k) * (t_m * pow((t_m * (t_3 * pow(cbrt(l), -2.0))), -2.0))) * ((sqrt(2.0) * pow(cbrt(l), 2.0)) / (k * t_3));
}
return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double t_2 = Math.sin(k) * Math.tan(k);
double t_3 = Math.cbrt(t_2);
double tmp;
if ((l * l) <= 1e-317) {
tmp = Math.pow((((l * Math.sqrt(2.0)) / Math.pow(k, 2.0)) * Math.sqrt((1.0 / t_m))), 2.0);
} else if ((l * l) <= 1e+307) {
tmp = (l * l) * (2.0 / (t_2 * Math.pow((k * Math.sqrt(t_m)), 2.0)));
} else {
tmp = ((Math.sqrt(2.0) / k) * (t_m * Math.pow((t_m * (t_3 * Math.pow(Math.cbrt(l), -2.0))), -2.0))) * ((Math.sqrt(2.0) * Math.pow(Math.cbrt(l), 2.0)) / (k * t_3));
}
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(sin(k) * tan(k)) t_3 = cbrt(t_2) tmp = 0.0 if (Float64(l * l) <= 1e-317) tmp = Float64(Float64(Float64(l * sqrt(2.0)) / (k ^ 2.0)) * sqrt(Float64(1.0 / t_m))) ^ 2.0; elseif (Float64(l * l) <= 1e+307) tmp = Float64(Float64(l * l) * Float64(2.0 / Float64(t_2 * (Float64(k * sqrt(t_m)) ^ 2.0)))); else tmp = Float64(Float64(Float64(sqrt(2.0) / k) * Float64(t_m * (Float64(t_m * Float64(t_3 * (cbrt(l) ^ -2.0))) ^ -2.0))) * Float64(Float64(sqrt(2.0) * (cbrt(l) ^ 2.0)) / Float64(k * t_3))); 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[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[Power[t$95$2, 1/3], $MachinePrecision]}, N[(t$95$s * If[LessEqual[N[(l * l), $MachinePrecision], 1e-317], N[Power[N[(N[(N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] / N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(1.0 / t$95$m), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision], If[LessEqual[N[(l * l), $MachinePrecision], 1e+307], N[(N[(l * l), $MachinePrecision] * N[(2.0 / N[(t$95$2 * N[Power[N[(k * N[Sqrt[t$95$m], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[Sqrt[2.0], $MachinePrecision] / k), $MachinePrecision] * N[(t$95$m * N[Power[N[(t$95$m * N[(t$95$3 * N[Power[N[Power[l, 1/3], $MachinePrecision], -2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], -2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(N[Sqrt[2.0], $MachinePrecision] * N[Power[N[Power[l, 1/3], $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] / N[(k * t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
\begin{array}{l}
t_2 := \sin k \cdot \tan k\\
t_3 := \sqrt[3]{t\_2}\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;\ell \cdot \ell \leq 10^{-317}:\\
\;\;\;\;{\left(\frac{\ell \cdot \sqrt{2}}{{k}^{2}} \cdot \sqrt{\frac{1}{t\_m}}\right)}^{2}\\
\mathbf{elif}\;\ell \cdot \ell \leq 10^{+307}:\\
\;\;\;\;\left(\ell \cdot \ell\right) \cdot \frac{2}{t\_2 \cdot {\left(k \cdot \sqrt{t\_m}\right)}^{2}}\\
\mathbf{else}:\\
\;\;\;\;\left(\frac{\sqrt{2}}{k} \cdot \left(t\_m \cdot {\left(t\_m \cdot \left(t\_3 \cdot {\left(\sqrt[3]{\ell}\right)}^{-2}\right)\right)}^{-2}\right)\right) \cdot \frac{\sqrt{2} \cdot {\left(\sqrt[3]{\ell}\right)}^{2}}{k \cdot t\_3}\\
\end{array}
\end{array}
\end{array}
if (*.f64 l l) < 1.00000023e-317Initial program 31.1%
Simplified42.0%
add-sqr-sqrt42.0%
pow242.0%
Applied egg-rr29.2%
associate-/r*29.8%
Simplified29.8%
Taylor expanded in k around 0 43.0%
if 1.00000023e-317 < (*.f64 l l) < 9.99999999999999986e306Initial program 44.8%
Simplified54.9%
add-sqr-sqrt28.3%
pow228.3%
*-commutative28.3%
sqrt-prod26.0%
associate-*r*26.0%
sqrt-prod28.1%
sqrt-pow130.5%
metadata-eval30.5%
pow130.5%
sqrt-pow132.0%
metadata-eval32.0%
Applied egg-rr32.0%
associate-*l*32.7%
associate-*l/33.5%
Simplified33.5%
unpow233.5%
associate-/l*33.5%
pow133.5%
pow-div33.5%
metadata-eval33.5%
pow1/233.5%
associate-/l*33.5%
pow133.5%
pow-div37.8%
metadata-eval37.8%
pow1/237.8%
Applied egg-rr37.8%
swap-sqr37.9%
rem-square-sqrt47.8%
unpow147.8%
pow-plus47.8%
metadata-eval47.8%
Simplified47.8%
if 9.99999999999999986e306 < (*.f64 l l) Initial program 20.4%
Simplified20.4%
Applied egg-rr82.3%
associate-/r/82.3%
associate-/r*82.2%
associate-/r/83.7%
Simplified83.7%
associate-*r/83.8%
Applied egg-rr83.8%
associate-/l*83.8%
associate-*l*91.2%
associate-*l*91.1%
associate-/l*91.2%
associate-/r*91.2%
*-inverses91.2%
Simplified91.2%
frac-times91.2%
pow-flip91.1%
metadata-eval91.1%
Applied egg-rr91.1%
Final simplification58.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 (* (sin k) (tan k))) (t_3 (cbrt t_2)) (t_4 (/ (sqrt 2.0) k)))
(*
t_s
(if (<= l 4.5e-146)
(pow (* (/ (* l (sqrt 2.0)) (pow k 2.0)) (sqrt (/ 1.0 t_m))) 2.0)
(if (<= l 5.9e+153)
(* (* l l) (/ 2.0 (* t_2 (pow (* k (sqrt t_m)) 2.0))))
(/
(*
(* (pow (* t_3 (* t_m (pow (cbrt l) -2.0))) -2.0) (* t_m t_4))
(* t_4 (pow l 0.6666666666666666)))
t_3))))))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 = sin(k) * tan(k);
double t_3 = cbrt(t_2);
double t_4 = sqrt(2.0) / k;
double tmp;
if (l <= 4.5e-146) {
tmp = pow((((l * sqrt(2.0)) / pow(k, 2.0)) * sqrt((1.0 / t_m))), 2.0);
} else if (l <= 5.9e+153) {
tmp = (l * l) * (2.0 / (t_2 * pow((k * sqrt(t_m)), 2.0)));
} else {
tmp = ((pow((t_3 * (t_m * pow(cbrt(l), -2.0))), -2.0) * (t_m * t_4)) * (t_4 * pow(l, 0.6666666666666666))) / t_3;
}
return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double t_2 = Math.sin(k) * Math.tan(k);
double t_3 = Math.cbrt(t_2);
double t_4 = Math.sqrt(2.0) / k;
double tmp;
if (l <= 4.5e-146) {
tmp = Math.pow((((l * Math.sqrt(2.0)) / Math.pow(k, 2.0)) * Math.sqrt((1.0 / t_m))), 2.0);
} else if (l <= 5.9e+153) {
tmp = (l * l) * (2.0 / (t_2 * Math.pow((k * Math.sqrt(t_m)), 2.0)));
} else {
tmp = ((Math.pow((t_3 * (t_m * Math.pow(Math.cbrt(l), -2.0))), -2.0) * (t_m * t_4)) * (t_4 * Math.pow(l, 0.6666666666666666))) / t_3;
}
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(sin(k) * tan(k)) t_3 = cbrt(t_2) t_4 = Float64(sqrt(2.0) / k) tmp = 0.0 if (l <= 4.5e-146) tmp = Float64(Float64(Float64(l * sqrt(2.0)) / (k ^ 2.0)) * sqrt(Float64(1.0 / t_m))) ^ 2.0; elseif (l <= 5.9e+153) tmp = Float64(Float64(l * l) * Float64(2.0 / Float64(t_2 * (Float64(k * sqrt(t_m)) ^ 2.0)))); else tmp = Float64(Float64(Float64((Float64(t_3 * Float64(t_m * (cbrt(l) ^ -2.0))) ^ -2.0) * Float64(t_m * t_4)) * Float64(t_4 * (l ^ 0.6666666666666666))) / t_3); 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[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[Power[t$95$2, 1/3], $MachinePrecision]}, Block[{t$95$4 = N[(N[Sqrt[2.0], $MachinePrecision] / k), $MachinePrecision]}, N[(t$95$s * If[LessEqual[l, 4.5e-146], N[Power[N[(N[(N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] / N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(1.0 / t$95$m), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision], If[LessEqual[l, 5.9e+153], N[(N[(l * l), $MachinePrecision] * N[(2.0 / N[(t$95$2 * N[Power[N[(k * N[Sqrt[t$95$m], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[Power[N[(t$95$3 * N[(t$95$m * N[Power[N[Power[l, 1/3], $MachinePrecision], -2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], -2.0], $MachinePrecision] * N[(t$95$m * t$95$4), $MachinePrecision]), $MachinePrecision] * N[(t$95$4 * N[Power[l, 0.6666666666666666], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / t$95$3), $MachinePrecision]]]), $MachinePrecision]]]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
\begin{array}{l}
t_2 := \sin k \cdot \tan k\\
t_3 := \sqrt[3]{t\_2}\\
t_4 := \frac{\sqrt{2}}{k}\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;\ell \leq 4.5 \cdot 10^{-146}:\\
\;\;\;\;{\left(\frac{\ell \cdot \sqrt{2}}{{k}^{2}} \cdot \sqrt{\frac{1}{t\_m}}\right)}^{2}\\
\mathbf{elif}\;\ell \leq 5.9 \cdot 10^{+153}:\\
\;\;\;\;\left(\ell \cdot \ell\right) \cdot \frac{2}{t\_2 \cdot {\left(k \cdot \sqrt{t\_m}\right)}^{2}}\\
\mathbf{else}:\\
\;\;\;\;\frac{\left({\left(t\_3 \cdot \left(t\_m \cdot {\left(\sqrt[3]{\ell}\right)}^{-2}\right)\right)}^{-2} \cdot \left(t\_m \cdot t\_4\right)\right) \cdot \left(t\_4 \cdot {\ell}^{0.6666666666666666}\right)}{t\_3}\\
\end{array}
\end{array}
\end{array}
if l < 4.5000000000000001e-146Initial program 34.7%
Simplified40.0%
add-sqr-sqrt29.5%
pow229.5%
Applied egg-rr25.4%
associate-/r*25.6%
Simplified25.6%
Taylor expanded in k around 0 36.8%
if 4.5000000000000001e-146 < l < 5.9000000000000002e153Initial program 41.5%
Simplified57.7%
add-sqr-sqrt35.0%
pow235.0%
*-commutative35.0%
sqrt-prod31.9%
associate-*r*32.0%
sqrt-prod34.7%
sqrt-pow134.9%
metadata-eval34.9%
pow134.9%
sqrt-pow136.4%
metadata-eval36.4%
Applied egg-rr36.4%
associate-*l*38.0%
associate-*l/39.5%
Simplified39.5%
unpow239.5%
associate-/l*39.5%
pow139.5%
pow-div39.5%
metadata-eval39.5%
pow1/239.5%
associate-/l*39.5%
pow139.5%
pow-div46.8%
metadata-eval46.8%
pow1/246.8%
Applied egg-rr46.8%
swap-sqr46.8%
rem-square-sqrt54.4%
unpow154.4%
pow-plus54.4%
metadata-eval54.4%
Simplified54.4%
if 5.9000000000000002e153 < l Initial program 23.1%
Simplified23.1%
Applied egg-rr77.4%
associate-/r/77.4%
associate-/r*77.4%
associate-/r/77.4%
Simplified77.4%
associate-*r/77.4%
Applied egg-rr77.3%
associate-/r*77.3%
pow177.3%
pow177.3%
pow-div77.3%
metadata-eval77.3%
metadata-eval77.3%
pow-flip77.3%
pow1/376.5%
metadata-eval76.5%
pow-pow76.5%
metadata-eval76.5%
Applied egg-rr76.5%
Final simplification45.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-18)
(pow (* (/ (* l (sqrt 2.0)) (pow k 2.0)) (sqrt (/ 1.0 t_m))) 2.0)
(* (* l l) (/ 2.0 (* (* (sin k) (tan k)) (pow (* k (sqrt 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 (k <= 9e-18) {
tmp = pow((((l * sqrt(2.0)) / pow(k, 2.0)) * sqrt((1.0 / t_m))), 2.0);
} else {
tmp = (l * l) * (2.0 / ((sin(k) * tan(k)) * pow((k * sqrt(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 (k <= 9d-18) then
tmp = (((l * sqrt(2.0d0)) / (k ** 2.0d0)) * sqrt((1.0d0 / t_m))) ** 2.0d0
else
tmp = (l * l) * (2.0d0 / ((sin(k) * tan(k)) * ((k * sqrt(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 (k <= 9e-18) {
tmp = Math.pow((((l * Math.sqrt(2.0)) / Math.pow(k, 2.0)) * Math.sqrt((1.0 / t_m))), 2.0);
} else {
tmp = (l * l) * (2.0 / ((Math.sin(k) * Math.tan(k)) * Math.pow((k * Math.sqrt(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 k <= 9e-18: tmp = math.pow((((l * math.sqrt(2.0)) / math.pow(k, 2.0)) * math.sqrt((1.0 / t_m))), 2.0) else: tmp = (l * l) * (2.0 / ((math.sin(k) * math.tan(k)) * math.pow((k * math.sqrt(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 (k <= 9e-18) tmp = Float64(Float64(Float64(l * sqrt(2.0)) / (k ^ 2.0)) * sqrt(Float64(1.0 / t_m))) ^ 2.0; else tmp = Float64(Float64(l * l) * Float64(2.0 / Float64(Float64(sin(k) * tan(k)) * (Float64(k * sqrt(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 (k <= 9e-18) tmp = (((l * sqrt(2.0)) / (k ^ 2.0)) * sqrt((1.0 / t_m))) ^ 2.0; else tmp = (l * l) * (2.0 / ((sin(k) * tan(k)) * ((k * sqrt(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[k, 9e-18], N[Power[N[(N[(N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] / N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(1.0 / t$95$m), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision], N[(N[(l * l), $MachinePrecision] * N[(2.0 / N[(N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * N[Power[N[(k * N[Sqrt[t$95$m], $MachinePrecision]), $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}\;k \leq 9 \cdot 10^{-18}:\\
\;\;\;\;{\left(\frac{\ell \cdot \sqrt{2}}{{k}^{2}} \cdot \sqrt{\frac{1}{t\_m}}\right)}^{2}\\
\mathbf{else}:\\
\;\;\;\;\left(\ell \cdot \ell\right) \cdot \frac{2}{\left(\sin k \cdot \tan k\right) \cdot {\left(k \cdot \sqrt{t\_m}\right)}^{2}}\\
\end{array}
\end{array}
if k < 8.99999999999999987e-18Initial program 37.7%
Simplified43.0%
add-sqr-sqrt28.1%
pow228.1%
Applied egg-rr31.1%
associate-/r*31.3%
Simplified31.3%
Taylor expanded in k around 0 41.6%
if 8.99999999999999987e-18 < k Initial program 30.1%
Simplified42.4%
add-sqr-sqrt21.3%
pow221.3%
*-commutative21.3%
sqrt-prod12.6%
associate-*r*12.6%
sqrt-prod12.6%
sqrt-pow114.0%
metadata-eval14.0%
pow114.0%
sqrt-pow115.1%
metadata-eval15.1%
Applied egg-rr15.1%
associate-*l*15.2%
associate-*l/16.5%
Simplified16.5%
unpow216.5%
associate-/l*16.5%
pow116.5%
pow-div16.5%
metadata-eval16.5%
pow1/216.5%
associate-/l*16.5%
pow116.5%
pow-div21.2%
metadata-eval21.2%
pow1/221.2%
Applied egg-rr21.2%
swap-sqr21.2%
rem-square-sqrt36.1%
unpow136.1%
pow-plus36.1%
metadata-eval36.1%
Simplified36.1%
Final simplification39.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 9e-18)
(pow (* (/ (* l (sqrt 2.0)) (pow k 2.0)) (sqrt (/ 1.0 t_m))) 2.0)
(/ (* 2.0 (pow l 2.0)) (* (* (sin k) (tan k)) (* (pow k 2.0) t_m))))))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-18) {
tmp = pow((((l * sqrt(2.0)) / pow(k, 2.0)) * sqrt((1.0 / t_m))), 2.0);
} else {
tmp = (2.0 * pow(l, 2.0)) / ((sin(k) * tan(k)) * (pow(k, 2.0) * t_m));
}
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 <= 9d-18) then
tmp = (((l * sqrt(2.0d0)) / (k ** 2.0d0)) * sqrt((1.0d0 / t_m))) ** 2.0d0
else
tmp = (2.0d0 * (l ** 2.0d0)) / ((sin(k) * tan(k)) * ((k ** 2.0d0) * t_m))
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 <= 9e-18) {
tmp = Math.pow((((l * Math.sqrt(2.0)) / Math.pow(k, 2.0)) * Math.sqrt((1.0 / t_m))), 2.0);
} else {
tmp = (2.0 * Math.pow(l, 2.0)) / ((Math.sin(k) * Math.tan(k)) * (Math.pow(k, 2.0) * t_m));
}
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 <= 9e-18: tmp = math.pow((((l * math.sqrt(2.0)) / math.pow(k, 2.0)) * math.sqrt((1.0 / t_m))), 2.0) else: tmp = (2.0 * math.pow(l, 2.0)) / ((math.sin(k) * math.tan(k)) * (math.pow(k, 2.0) * t_m)) 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-18) tmp = Float64(Float64(Float64(l * sqrt(2.0)) / (k ^ 2.0)) * sqrt(Float64(1.0 / t_m))) ^ 2.0; else tmp = Float64(Float64(2.0 * (l ^ 2.0)) / Float64(Float64(sin(k) * tan(k)) * Float64((k ^ 2.0) * t_m))); 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 <= 9e-18) tmp = (((l * sqrt(2.0)) / (k ^ 2.0)) * sqrt((1.0 / t_m))) ^ 2.0; else tmp = (2.0 * (l ^ 2.0)) / ((sin(k) * tan(k)) * ((k ^ 2.0) * t_m)); 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, 9e-18], N[Power[N[(N[(N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] / N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(1.0 / t$95$m), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision], N[(N[(2.0 * N[Power[l, 2.0], $MachinePrecision]), $MachinePrecision] / N[(N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * N[(N[Power[k, 2.0], $MachinePrecision] * t$95$m), $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^{-18}:\\
\;\;\;\;{\left(\frac{\ell \cdot \sqrt{2}}{{k}^{2}} \cdot \sqrt{\frac{1}{t\_m}}\right)}^{2}\\
\mathbf{else}:\\
\;\;\;\;\frac{2 \cdot {\ell}^{2}}{\left(\sin k \cdot \tan k\right) \cdot \left({k}^{2} \cdot t\_m\right)}\\
\end{array}
\end{array}
if k < 8.99999999999999987e-18Initial program 37.7%
Simplified43.0%
add-sqr-sqrt28.1%
pow228.1%
Applied egg-rr31.1%
associate-/r*31.3%
Simplified31.3%
Taylor expanded in k around 0 41.6%
if 8.99999999999999987e-18 < k Initial program 30.1%
Simplified42.4%
add-sqr-sqrt21.3%
pow221.3%
*-commutative21.3%
sqrt-prod12.6%
associate-*r*12.6%
sqrt-prod12.6%
sqrt-pow114.0%
metadata-eval14.0%
pow114.0%
sqrt-pow115.1%
metadata-eval15.1%
Applied egg-rr15.1%
associate-*l*15.2%
associate-*l/16.5%
Simplified16.5%
associate-*l/16.5%
pow216.5%
unpow-prod-down16.5%
pow216.5%
add-sqr-sqrt30.2%
associate-/l*30.2%
unpow-prod-down30.0%
pow130.0%
pow-div34.9%
metadata-eval34.9%
pow1/234.9%
pow234.9%
add-sqr-sqrt73.3%
Applied egg-rr73.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-18)
(pow (* (/ (* l (sqrt 2.0)) (pow k 2.0)) (sqrt (/ 1.0 t_m))) 2.0)
(* (* l l) (/ (/ (/ 2.0 (sin k)) (tan k)) (* (pow k 2.0) t_m))))))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-18) {
tmp = pow((((l * sqrt(2.0)) / pow(k, 2.0)) * sqrt((1.0 / t_m))), 2.0);
} else {
tmp = (l * l) * (((2.0 / sin(k)) / tan(k)) / (pow(k, 2.0) * t_m));
}
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 <= 9d-18) then
tmp = (((l * sqrt(2.0d0)) / (k ** 2.0d0)) * sqrt((1.0d0 / t_m))) ** 2.0d0
else
tmp = (l * l) * (((2.0d0 / sin(k)) / tan(k)) / ((k ** 2.0d0) * t_m))
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 <= 9e-18) {
tmp = Math.pow((((l * Math.sqrt(2.0)) / Math.pow(k, 2.0)) * Math.sqrt((1.0 / t_m))), 2.0);
} else {
tmp = (l * l) * (((2.0 / Math.sin(k)) / Math.tan(k)) / (Math.pow(k, 2.0) * t_m));
}
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 <= 9e-18: tmp = math.pow((((l * math.sqrt(2.0)) / math.pow(k, 2.0)) * math.sqrt((1.0 / t_m))), 2.0) else: tmp = (l * l) * (((2.0 / math.sin(k)) / math.tan(k)) / (math.pow(k, 2.0) * t_m)) 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-18) tmp = Float64(Float64(Float64(l * sqrt(2.0)) / (k ^ 2.0)) * sqrt(Float64(1.0 / t_m))) ^ 2.0; else tmp = Float64(Float64(l * l) * Float64(Float64(Float64(2.0 / sin(k)) / tan(k)) / Float64((k ^ 2.0) * t_m))); 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 <= 9e-18) tmp = (((l * sqrt(2.0)) / (k ^ 2.0)) * sqrt((1.0 / t_m))) ^ 2.0; else tmp = (l * l) * (((2.0 / sin(k)) / tan(k)) / ((k ^ 2.0) * t_m)); 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, 9e-18], N[Power[N[(N[(N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] / N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(1.0 / t$95$m), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision], N[(N[(l * l), $MachinePrecision] * N[(N[(N[(2.0 / N[Sin[k], $MachinePrecision]), $MachinePrecision] / N[Tan[k], $MachinePrecision]), $MachinePrecision] / N[(N[Power[k, 2.0], $MachinePrecision] * t$95$m), $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^{-18}:\\
\;\;\;\;{\left(\frac{\ell \cdot \sqrt{2}}{{k}^{2}} \cdot \sqrt{\frac{1}{t\_m}}\right)}^{2}\\
\mathbf{else}:\\
\;\;\;\;\left(\ell \cdot \ell\right) \cdot \frac{\frac{\frac{2}{\sin k}}{\tan k}}{{k}^{2} \cdot t\_m}\\
\end{array}
\end{array}
if k < 8.99999999999999987e-18Initial program 37.7%
Simplified43.0%
add-sqr-sqrt28.1%
pow228.1%
Applied egg-rr31.1%
associate-/r*31.3%
Simplified31.3%
Taylor expanded in k around 0 41.6%
if 8.99999999999999987e-18 < k Initial program 30.1%
Simplified42.4%
add-sqr-sqrt21.3%
pow221.3%
*-commutative21.3%
sqrt-prod12.6%
associate-*r*12.6%
sqrt-prod12.6%
sqrt-pow114.0%
metadata-eval14.0%
pow114.0%
sqrt-pow115.1%
metadata-eval15.1%
Applied egg-rr15.1%
associate-*l*15.2%
associate-*l/16.5%
Simplified16.5%
unpow216.5%
associate-/l*16.5%
pow116.5%
pow-div16.5%
metadata-eval16.5%
pow1/216.5%
associate-/l*16.5%
pow116.5%
pow-div21.2%
metadata-eval21.2%
pow1/221.2%
Applied egg-rr21.2%
swap-sqr21.2%
rem-square-sqrt36.1%
unpow136.1%
pow-plus36.1%
metadata-eval36.1%
Simplified36.1%
div-inv36.1%
*-commutative36.1%
unpow-prod-down34.9%
pow234.9%
add-sqr-sqrt73.2%
Applied egg-rr73.2%
associate-*r/73.2%
metadata-eval73.2%
associate-/r*73.3%
associate-/r*73.3%
Simplified73.3%
Final simplification51.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 (<= k 9e-18)
(pow (* l (* (sqrt 2.0) (/ (sqrt (/ 1.0 t_m)) (pow k 2.0)))) 2.0)
(* (* l l) (/ (/ (/ 2.0 (sin k)) (tan k)) (* (pow k 2.0) t_m))))))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-18) {
tmp = pow((l * (sqrt(2.0) * (sqrt((1.0 / t_m)) / pow(k, 2.0)))), 2.0);
} else {
tmp = (l * l) * (((2.0 / sin(k)) / tan(k)) / (pow(k, 2.0) * t_m));
}
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 <= 9d-18) then
tmp = (l * (sqrt(2.0d0) * (sqrt((1.0d0 / t_m)) / (k ** 2.0d0)))) ** 2.0d0
else
tmp = (l * l) * (((2.0d0 / sin(k)) / tan(k)) / ((k ** 2.0d0) * t_m))
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 <= 9e-18) {
tmp = Math.pow((l * (Math.sqrt(2.0) * (Math.sqrt((1.0 / t_m)) / Math.pow(k, 2.0)))), 2.0);
} else {
tmp = (l * l) * (((2.0 / Math.sin(k)) / Math.tan(k)) / (Math.pow(k, 2.0) * t_m));
}
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 <= 9e-18: tmp = math.pow((l * (math.sqrt(2.0) * (math.sqrt((1.0 / t_m)) / math.pow(k, 2.0)))), 2.0) else: tmp = (l * l) * (((2.0 / math.sin(k)) / math.tan(k)) / (math.pow(k, 2.0) * t_m)) 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-18) tmp = Float64(l * Float64(sqrt(2.0) * Float64(sqrt(Float64(1.0 / t_m)) / (k ^ 2.0)))) ^ 2.0; else tmp = Float64(Float64(l * l) * Float64(Float64(Float64(2.0 / sin(k)) / tan(k)) / Float64((k ^ 2.0) * t_m))); 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 <= 9e-18) tmp = (l * (sqrt(2.0) * (sqrt((1.0 / t_m)) / (k ^ 2.0)))) ^ 2.0; else tmp = (l * l) * (((2.0 / sin(k)) / tan(k)) / ((k ^ 2.0) * t_m)); 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, 9e-18], N[Power[N[(l * N[(N[Sqrt[2.0], $MachinePrecision] * N[(N[Sqrt[N[(1.0 / t$95$m), $MachinePrecision]], $MachinePrecision] / N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision], N[(N[(l * l), $MachinePrecision] * N[(N[(N[(2.0 / N[Sin[k], $MachinePrecision]), $MachinePrecision] / N[Tan[k], $MachinePrecision]), $MachinePrecision] / N[(N[Power[k, 2.0], $MachinePrecision] * t$95$m), $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^{-18}:\\
\;\;\;\;{\left(\ell \cdot \left(\sqrt{2} \cdot \frac{\sqrt{\frac{1}{t\_m}}}{{k}^{2}}\right)\right)}^{2}\\
\mathbf{else}:\\
\;\;\;\;\left(\ell \cdot \ell\right) \cdot \frac{\frac{\frac{2}{\sin k}}{\tan k}}{{k}^{2} \cdot t\_m}\\
\end{array}
\end{array}
if k < 8.99999999999999987e-18Initial program 37.7%
Simplified43.0%
add-sqr-sqrt28.1%
pow228.1%
Applied egg-rr31.1%
associate-/r*31.3%
Simplified31.3%
Taylor expanded in k around 0 41.6%
associate-*l/41.1%
associate-*l*41.1%
*-commutative41.1%
associate-/l*41.2%
*-commutative41.2%
associate-/l*41.2%
Simplified41.2%
if 8.99999999999999987e-18 < k Initial program 30.1%
Simplified42.4%
add-sqr-sqrt21.3%
pow221.3%
*-commutative21.3%
sqrt-prod12.6%
associate-*r*12.6%
sqrt-prod12.6%
sqrt-pow114.0%
metadata-eval14.0%
pow114.0%
sqrt-pow115.1%
metadata-eval15.1%
Applied egg-rr15.1%
associate-*l*15.2%
associate-*l/16.5%
Simplified16.5%
unpow216.5%
associate-/l*16.5%
pow116.5%
pow-div16.5%
metadata-eval16.5%
pow1/216.5%
associate-/l*16.5%
pow116.5%
pow-div21.2%
metadata-eval21.2%
pow1/221.2%
Applied egg-rr21.2%
swap-sqr21.2%
rem-square-sqrt36.1%
unpow136.1%
pow-plus36.1%
metadata-eval36.1%
Simplified36.1%
div-inv36.1%
*-commutative36.1%
unpow-prod-down34.9%
pow234.9%
add-sqr-sqrt73.2%
Applied egg-rr73.2%
associate-*r/73.2%
metadata-eval73.2%
associate-/r*73.3%
associate-/r*73.3%
Simplified73.3%
Final simplification51.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 (<= l 5.4e-177)
(pow (* l (/ (/ (sqrt (/ 2.0 (pow t_m 3.0))) k) (/ k t_m))) 2.0)
(* (* l l) (/ (/ (/ 2.0 (sin k)) (tan k)) (* (pow k 2.0) t_m))))))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 (l <= 5.4e-177) {
tmp = pow((l * ((sqrt((2.0 / pow(t_m, 3.0))) / k) / (k / t_m))), 2.0);
} else {
tmp = (l * l) * (((2.0 / sin(k)) / tan(k)) / (pow(k, 2.0) * t_m));
}
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 (l <= 5.4d-177) then
tmp = (l * ((sqrt((2.0d0 / (t_m ** 3.0d0))) / k) / (k / t_m))) ** 2.0d0
else
tmp = (l * l) * (((2.0d0 / sin(k)) / tan(k)) / ((k ** 2.0d0) * t_m))
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 (l <= 5.4e-177) {
tmp = Math.pow((l * ((Math.sqrt((2.0 / Math.pow(t_m, 3.0))) / k) / (k / t_m))), 2.0);
} else {
tmp = (l * l) * (((2.0 / Math.sin(k)) / Math.tan(k)) / (Math.pow(k, 2.0) * t_m));
}
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 l <= 5.4e-177: tmp = math.pow((l * ((math.sqrt((2.0 / math.pow(t_m, 3.0))) / k) / (k / t_m))), 2.0) else: tmp = (l * l) * (((2.0 / math.sin(k)) / math.tan(k)) / (math.pow(k, 2.0) * t_m)) 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 (l <= 5.4e-177) tmp = Float64(l * Float64(Float64(sqrt(Float64(2.0 / (t_m ^ 3.0))) / k) / Float64(k / t_m))) ^ 2.0; else tmp = Float64(Float64(l * l) * Float64(Float64(Float64(2.0 / sin(k)) / tan(k)) / Float64((k ^ 2.0) * t_m))); 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 (l <= 5.4e-177) tmp = (l * ((sqrt((2.0 / (t_m ^ 3.0))) / k) / (k / t_m))) ^ 2.0; else tmp = (l * l) * (((2.0 / sin(k)) / tan(k)) / ((k ^ 2.0) * t_m)); 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[l, 5.4e-177], N[Power[N[(l * N[(N[(N[Sqrt[N[(2.0 / N[Power[t$95$m, 3.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / k), $MachinePrecision] / N[(k / t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision], N[(N[(l * l), $MachinePrecision] * N[(N[(N[(2.0 / N[Sin[k], $MachinePrecision]), $MachinePrecision] / N[Tan[k], $MachinePrecision]), $MachinePrecision] / N[(N[Power[k, 2.0], $MachinePrecision] * t$95$m), $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}\;\ell \leq 5.4 \cdot 10^{-177}:\\
\;\;\;\;{\left(\ell \cdot \frac{\frac{\sqrt{\frac{2}{{t\_m}^{3}}}}{k}}{\frac{k}{t\_m}}\right)}^{2}\\
\mathbf{else}:\\
\;\;\;\;\left(\ell \cdot \ell\right) \cdot \frac{\frac{\frac{2}{\sin k}}{\tan k}}{{k}^{2} \cdot t\_m}\\
\end{array}
\end{array}
if l < 5.4000000000000004e-177Initial program 33.7%
Simplified39.1%
add-sqr-sqrt28.4%
pow228.4%
Applied egg-rr25.4%
associate-/r*25.6%
Simplified25.6%
Taylor expanded in k around 0 34.6%
if 5.4000000000000004e-177 < l Initial program 37.9%
Simplified49.1%
add-sqr-sqrt28.2%
pow228.2%
*-commutative28.2%
sqrt-prod25.1%
associate-*r*25.1%
sqrt-prod27.0%
sqrt-pow129.2%
metadata-eval29.2%
pow129.2%
sqrt-pow131.3%
metadata-eval31.3%
Applied egg-rr31.3%
associate-*l*32.4%
associate-*l/33.4%
Simplified33.4%
unpow233.4%
associate-/l*33.4%
pow133.4%
pow-div33.4%
metadata-eval33.4%
pow1/233.4%
associate-/l*33.4%
pow133.4%
pow-div40.5%
metadata-eval40.5%
pow1/240.5%
Applied egg-rr40.5%
swap-sqr40.5%
rem-square-sqrt48.9%
unpow148.9%
pow-plus48.9%
metadata-eval48.9%
Simplified48.9%
div-inv48.9%
*-commutative48.9%
unpow-prod-down45.9%
pow245.9%
add-sqr-sqrt84.6%
Applied egg-rr84.6%
associate-*r/84.6%
metadata-eval84.6%
associate-/r*84.6%
associate-/r*84.6%
Simplified84.6%
Final simplification53.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 (<= l 1.65e-178)
(pow (* l (/ (/ (sqrt (/ 2.0 (pow t_m 3.0))) k) (/ k t_m))) 2.0)
(* (* l l) (/ (/ 2.0 (* (sin k) (tan k))) (* (pow k 2.0) t_m))))))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 (l <= 1.65e-178) {
tmp = pow((l * ((sqrt((2.0 / pow(t_m, 3.0))) / k) / (k / t_m))), 2.0);
} else {
tmp = (l * l) * ((2.0 / (sin(k) * tan(k))) / (pow(k, 2.0) * t_m));
}
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 (l <= 1.65d-178) then
tmp = (l * ((sqrt((2.0d0 / (t_m ** 3.0d0))) / k) / (k / t_m))) ** 2.0d0
else
tmp = (l * l) * ((2.0d0 / (sin(k) * tan(k))) / ((k ** 2.0d0) * t_m))
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 (l <= 1.65e-178) {
tmp = Math.pow((l * ((Math.sqrt((2.0 / Math.pow(t_m, 3.0))) / k) / (k / t_m))), 2.0);
} else {
tmp = (l * l) * ((2.0 / (Math.sin(k) * Math.tan(k))) / (Math.pow(k, 2.0) * t_m));
}
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 l <= 1.65e-178: tmp = math.pow((l * ((math.sqrt((2.0 / math.pow(t_m, 3.0))) / k) / (k / t_m))), 2.0) else: tmp = (l * l) * ((2.0 / (math.sin(k) * math.tan(k))) / (math.pow(k, 2.0) * t_m)) 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 (l <= 1.65e-178) tmp = Float64(l * Float64(Float64(sqrt(Float64(2.0 / (t_m ^ 3.0))) / k) / Float64(k / t_m))) ^ 2.0; else tmp = Float64(Float64(l * l) * Float64(Float64(2.0 / Float64(sin(k) * tan(k))) / Float64((k ^ 2.0) * t_m))); 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 (l <= 1.65e-178) tmp = (l * ((sqrt((2.0 / (t_m ^ 3.0))) / k) / (k / t_m))) ^ 2.0; else tmp = (l * l) * ((2.0 / (sin(k) * tan(k))) / ((k ^ 2.0) * t_m)); 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[l, 1.65e-178], N[Power[N[(l * N[(N[(N[Sqrt[N[(2.0 / N[Power[t$95$m, 3.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / k), $MachinePrecision] / N[(k / t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision], N[(N[(l * l), $MachinePrecision] * N[(N[(2.0 / N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[Power[k, 2.0], $MachinePrecision] * t$95$m), $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}\;\ell \leq 1.65 \cdot 10^{-178}:\\
\;\;\;\;{\left(\ell \cdot \frac{\frac{\sqrt{\frac{2}{{t\_m}^{3}}}}{k}}{\frac{k}{t\_m}}\right)}^{2}\\
\mathbf{else}:\\
\;\;\;\;\left(\ell \cdot \ell\right) \cdot \frac{\frac{2}{\sin k \cdot \tan k}}{{k}^{2} \cdot t\_m}\\
\end{array}
\end{array}
if l < 1.6500000000000001e-178Initial program 33.7%
Simplified39.1%
add-sqr-sqrt28.4%
pow228.4%
Applied egg-rr25.4%
associate-/r*25.6%
Simplified25.6%
Taylor expanded in k around 0 34.6%
if 1.6500000000000001e-178 < l Initial program 37.9%
Simplified49.1%
add-log-exp29.8%
exp-prod37.5%
Applied egg-rr37.5%
Taylor expanded in k around inf 84.6%
associate-*r*84.6%
*-commutative84.6%
associate-/r*84.6%
*-commutative84.6%
Simplified84.6%
Final simplification53.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 (<= l 1.5e-178)
(pow (* l (/ (/ (sqrt (/ 2.0 (pow t_m 3.0))) k) (/ k t_m))) 2.0)
(* (* l l) (/ 2.0 (* (pow k 2.0) (* t_m (* (sin k) (tan k)))))))))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 (l <= 1.5e-178) {
tmp = pow((l * ((sqrt((2.0 / pow(t_m, 3.0))) / k) / (k / t_m))), 2.0);
} else {
tmp = (l * l) * (2.0 / (pow(k, 2.0) * (t_m * (sin(k) * tan(k)))));
}
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 (l <= 1.5d-178) then
tmp = (l * ((sqrt((2.0d0 / (t_m ** 3.0d0))) / k) / (k / t_m))) ** 2.0d0
else
tmp = (l * l) * (2.0d0 / ((k ** 2.0d0) * (t_m * (sin(k) * tan(k)))))
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 (l <= 1.5e-178) {
tmp = Math.pow((l * ((Math.sqrt((2.0 / Math.pow(t_m, 3.0))) / k) / (k / t_m))), 2.0);
} else {
tmp = (l * l) * (2.0 / (Math.pow(k, 2.0) * (t_m * (Math.sin(k) * Math.tan(k)))));
}
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 l <= 1.5e-178: tmp = math.pow((l * ((math.sqrt((2.0 / math.pow(t_m, 3.0))) / k) / (k / t_m))), 2.0) else: tmp = (l * l) * (2.0 / (math.pow(k, 2.0) * (t_m * (math.sin(k) * math.tan(k))))) 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 (l <= 1.5e-178) tmp = Float64(l * Float64(Float64(sqrt(Float64(2.0 / (t_m ^ 3.0))) / k) / Float64(k / t_m))) ^ 2.0; else tmp = Float64(Float64(l * l) * Float64(2.0 / Float64((k ^ 2.0) * Float64(t_m * Float64(sin(k) * tan(k)))))); 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 (l <= 1.5e-178) tmp = (l * ((sqrt((2.0 / (t_m ^ 3.0))) / k) / (k / t_m))) ^ 2.0; else tmp = (l * l) * (2.0 / ((k ^ 2.0) * (t_m * (sin(k) * tan(k))))); 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[l, 1.5e-178], N[Power[N[(l * N[(N[(N[Sqrt[N[(2.0 / N[Power[t$95$m, 3.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / k), $MachinePrecision] / N[(k / t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision], N[(N[(l * l), $MachinePrecision] * N[(2.0 / N[(N[Power[k, 2.0], $MachinePrecision] * N[(t$95$m * N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $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}\;\ell \leq 1.5 \cdot 10^{-178}:\\
\;\;\;\;{\left(\ell \cdot \frac{\frac{\sqrt{\frac{2}{{t\_m}^{3}}}}{k}}{\frac{k}{t\_m}}\right)}^{2}\\
\mathbf{else}:\\
\;\;\;\;\left(\ell \cdot \ell\right) \cdot \frac{2}{{k}^{2} \cdot \left(t\_m \cdot \left(\sin k \cdot \tan k\right)\right)}\\
\end{array}
\end{array}
if l < 1.4999999999999999e-178Initial program 33.7%
Simplified39.1%
add-sqr-sqrt28.4%
pow228.4%
Applied egg-rr25.4%
associate-/r*25.6%
Simplified25.6%
Taylor expanded in k around 0 34.6%
if 1.4999999999999999e-178 < l Initial program 37.9%
Simplified49.1%
add-log-exp29.8%
exp-prod37.5%
Applied egg-rr37.5%
Taylor expanded in k around inf 84.6%
Final simplification53.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 (<= l 1.45e-178)
(pow (* l (/ (/ (sqrt (/ 2.0 (pow t_m 3.0))) k) (/ k t_m))) 2.0)
(* (* l l) (/ (/ 2.0 (pow k 2.0)) (* (pow k 2.0) t_m))))))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 (l <= 1.45e-178) {
tmp = pow((l * ((sqrt((2.0 / pow(t_m, 3.0))) / k) / (k / t_m))), 2.0);
} else {
tmp = (l * l) * ((2.0 / pow(k, 2.0)) / (pow(k, 2.0) * t_m));
}
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 (l <= 1.45d-178) then
tmp = (l * ((sqrt((2.0d0 / (t_m ** 3.0d0))) / k) / (k / t_m))) ** 2.0d0
else
tmp = (l * l) * ((2.0d0 / (k ** 2.0d0)) / ((k ** 2.0d0) * t_m))
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 (l <= 1.45e-178) {
tmp = Math.pow((l * ((Math.sqrt((2.0 / Math.pow(t_m, 3.0))) / k) / (k / t_m))), 2.0);
} else {
tmp = (l * l) * ((2.0 / Math.pow(k, 2.0)) / (Math.pow(k, 2.0) * t_m));
}
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 l <= 1.45e-178: tmp = math.pow((l * ((math.sqrt((2.0 / math.pow(t_m, 3.0))) / k) / (k / t_m))), 2.0) else: tmp = (l * l) * ((2.0 / math.pow(k, 2.0)) / (math.pow(k, 2.0) * t_m)) 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 (l <= 1.45e-178) tmp = Float64(l * Float64(Float64(sqrt(Float64(2.0 / (t_m ^ 3.0))) / k) / Float64(k / t_m))) ^ 2.0; else tmp = Float64(Float64(l * l) * Float64(Float64(2.0 / (k ^ 2.0)) / Float64((k ^ 2.0) * t_m))); 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 (l <= 1.45e-178) tmp = (l * ((sqrt((2.0 / (t_m ^ 3.0))) / k) / (k / t_m))) ^ 2.0; else tmp = (l * l) * ((2.0 / (k ^ 2.0)) / ((k ^ 2.0) * t_m)); 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[l, 1.45e-178], N[Power[N[(l * N[(N[(N[Sqrt[N[(2.0 / N[Power[t$95$m, 3.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / k), $MachinePrecision] / N[(k / t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision], N[(N[(l * l), $MachinePrecision] * N[(N[(2.0 / N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] / N[(N[Power[k, 2.0], $MachinePrecision] * t$95$m), $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}\;\ell \leq 1.45 \cdot 10^{-178}:\\
\;\;\;\;{\left(\ell \cdot \frac{\frac{\sqrt{\frac{2}{{t\_m}^{3}}}}{k}}{\frac{k}{t\_m}}\right)}^{2}\\
\mathbf{else}:\\
\;\;\;\;\left(\ell \cdot \ell\right) \cdot \frac{\frac{2}{{k}^{2}}}{{k}^{2} \cdot t\_m}\\
\end{array}
\end{array}
if l < 1.4499999999999999e-178Initial program 33.7%
Simplified39.1%
add-sqr-sqrt28.4%
pow228.4%
Applied egg-rr25.4%
associate-/r*25.6%
Simplified25.6%
Taylor expanded in k around 0 34.6%
if 1.4499999999999999e-178 < l Initial program 37.9%
Simplified49.1%
add-log-exp29.8%
exp-prod37.5%
Applied egg-rr37.5%
Taylor expanded in k around inf 84.6%
associate-*r*84.6%
*-commutative84.6%
associate-/r*84.6%
*-commutative84.6%
Simplified84.6%
Taylor expanded in k around 0 65.5%
Final simplification46.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 (* (* l l) (/ (/ 2.0 (pow k 2.0)) (* (pow k 2.0) t_m)))))
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 * ((l * l) * ((2.0 / pow(k, 2.0)) / (pow(k, 2.0) * t_m)));
}
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 * l) * ((2.0d0 / (k ** 2.0d0)) / ((k ** 2.0d0) * t_m)))
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 * ((l * l) * ((2.0 / Math.pow(k, 2.0)) / (Math.pow(k, 2.0) * t_m)));
}
t\_m = math.fabs(t) t\_s = math.copysign(1.0, t) def code(t_s, t_m, l, k): return t_s * ((l * l) * ((2.0 / math.pow(k, 2.0)) / (math.pow(k, 2.0) * t_m)))
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) return Float64(t_s * Float64(Float64(l * l) * Float64(Float64(2.0 / (k ^ 2.0)) / Float64((k ^ 2.0) * t_m)))) 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 * l) * ((2.0 / (k ^ 2.0)) / ((k ^ 2.0) * t_m))); 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[(l * l), $MachinePrecision] * N[(N[(2.0 / N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] / N[(N[Power[k, 2.0], $MachinePrecision] * t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \left(\left(\ell \cdot \ell\right) \cdot \frac{\frac{2}{{k}^{2}}}{{k}^{2} \cdot t\_m}\right)
\end{array}
Initial program 35.3%
Simplified42.8%
add-log-exp29.0%
exp-prod34.3%
Applied egg-rr34.3%
Taylor expanded in k around inf 77.1%
associate-*r*77.1%
*-commutative77.1%
associate-/r*77.1%
*-commutative77.1%
Simplified77.1%
Taylor expanded in k around 0 65.9%
Final simplification65.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 (* (* l l) (/ 2.0 (* t_m (pow k 4.0))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
return t_s * ((l * l) * (2.0 / (t_m * pow(k, 4.0))));
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
real(8), intent (in) :: t_s
real(8), intent (in) :: t_m
real(8), intent (in) :: l
real(8), intent (in) :: k
code = t_s * ((l * l) * (2.0d0 / (t_m * (k ** 4.0d0))))
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
return t_s * ((l * l) * (2.0 / (t_m * Math.pow(k, 4.0))));
}
t\_m = math.fabs(t) t\_s = math.copysign(1.0, t) def code(t_s, t_m, l, k): return t_s * ((l * l) * (2.0 / (t_m * math.pow(k, 4.0))))
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) return Float64(t_s * Float64(Float64(l * l) * 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 * l) * (2.0 / (t_m * (k ^ 4.0)))); end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * N[(N[(l * l), $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(\left(\ell \cdot \ell\right) \cdot \frac{2}{t\_m \cdot {k}^{4}}\right)
\end{array}
Initial program 35.3%
Simplified42.8%
Taylor expanded in k around 0 62.9%
Final simplification62.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 (* (* l l) (* (/ 2.0 t_m) (pow k -4.0)))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
return t_s * ((l * l) * ((2.0 / t_m) * pow(k, -4.0)));
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
real(8), intent (in) :: t_s
real(8), intent (in) :: t_m
real(8), intent (in) :: l
real(8), intent (in) :: k
code = t_s * ((l * l) * ((2.0d0 / t_m) * (k ** (-4.0d0))))
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
return t_s * ((l * l) * ((2.0 / t_m) * Math.pow(k, -4.0)));
}
t\_m = math.fabs(t) t\_s = math.copysign(1.0, t) def code(t_s, t_m, l, k): return t_s * ((l * l) * ((2.0 / t_m) * math.pow(k, -4.0)))
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) return Float64(t_s * Float64(Float64(l * l) * Float64(Float64(2.0 / 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 * l) * ((2.0 / t_m) * (k ^ -4.0))); end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * N[(N[(l * l), $MachinePrecision] * N[(N[(2.0 / t$95$m), $MachinePrecision] * N[Power[k, -4.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \left(\left(\ell \cdot \ell\right) \cdot \left(\frac{2}{t\_m} \cdot {k}^{-4}\right)\right)
\end{array}
Initial program 35.3%
Simplified42.8%
Taylor expanded in k around 0 62.9%
*-commutative62.9%
associate-/r*62.8%
Simplified62.8%
div-inv62.8%
pow-flip62.8%
metadata-eval62.8%
Applied egg-rr62.8%
Final simplification62.8%
herbie shell --seed 2024172
(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))))