
(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 25 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
(*
t_s
(if (<= t_m 1.5e-125)
(/ 2.0 (* (* (* (tan k) (/ (sin k) (* l l))) k) (* t_m k)))
(/
2.0
(*
(* t_m (/ (* (sin k) t_m) l))
(/ (* (* (+ (pow (/ k t_m) 2.0) 2.0) (tan k)) t_m) l))))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double tmp;
if (t_m <= 1.5e-125) {
tmp = 2.0 / (((tan(k) * (sin(k) / (l * l))) * k) * (t_m * k));
} else {
tmp = 2.0 / ((t_m * ((sin(k) * t_m) / l)) * ((((pow((k / t_m), 2.0) + 2.0) * tan(k)) * t_m) / l));
}
return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
real(8), intent (in) :: t_s
real(8), intent (in) :: t_m
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: tmp
if (t_m <= 1.5d-125) then
tmp = 2.0d0 / (((tan(k) * (sin(k) / (l * l))) * k) * (t_m * k))
else
tmp = 2.0d0 / ((t_m * ((sin(k) * t_m) / l)) * ((((((k / t_m) ** 2.0d0) + 2.0d0) * tan(k)) * t_m) / l))
end if
code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double tmp;
if (t_m <= 1.5e-125) {
tmp = 2.0 / (((Math.tan(k) * (Math.sin(k) / (l * l))) * k) * (t_m * k));
} else {
tmp = 2.0 / ((t_m * ((Math.sin(k) * t_m) / l)) * ((((Math.pow((k / t_m), 2.0) + 2.0) * Math.tan(k)) * t_m) / l));
}
return t_s * tmp;
}
t\_m = math.fabs(t) t\_s = math.copysign(1.0, t) def code(t_s, t_m, l, k): tmp = 0 if t_m <= 1.5e-125: tmp = 2.0 / (((math.tan(k) * (math.sin(k) / (l * l))) * k) * (t_m * k)) else: tmp = 2.0 / ((t_m * ((math.sin(k) * t_m) / l)) * ((((math.pow((k / t_m), 2.0) + 2.0) * math.tan(k)) * t_m) / l)) return t_s * tmp
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) tmp = 0.0 if (t_m <= 1.5e-125) tmp = Float64(2.0 / Float64(Float64(Float64(tan(k) * Float64(sin(k) / Float64(l * l))) * k) * Float64(t_m * k))); else tmp = Float64(2.0 / Float64(Float64(t_m * Float64(Float64(sin(k) * t_m) / l)) * Float64(Float64(Float64(Float64((Float64(k / t_m) ^ 2.0) + 2.0) * tan(k)) * t_m) / l))); end return Float64(t_s * tmp) end
t\_m = abs(t); t\_s = sign(t) * abs(1.0); function tmp_2 = code(t_s, t_m, l, k) tmp = 0.0; if (t_m <= 1.5e-125) tmp = 2.0 / (((tan(k) * (sin(k) / (l * l))) * k) * (t_m * k)); else tmp = 2.0 / ((t_m * ((sin(k) * t_m) / l)) * ((((((k / t_m) ^ 2.0) + 2.0) * tan(k)) * t_m) / l)); end tmp_2 = t_s * tmp; end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[t$95$m, 1.5e-125], N[(2.0 / N[(N[(N[(N[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * k), $MachinePrecision] * N[(t$95$m * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(t$95$m * N[(N[(N[Sin[k], $MachinePrecision] * t$95$m), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision] * N[(N[(N[(N[(N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision] + 2.0), $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * t$95$m), $MachinePrecision] / l), $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.5 \cdot 10^{-125}:\\
\;\;\;\;\frac{2}{\left(\left(\tan k \cdot \frac{\sin k}{\ell \cdot \ell}\right) \cdot k\right) \cdot \left(t\_m \cdot k\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(t\_m \cdot \frac{\sin k \cdot t\_m}{\ell}\right) \cdot \frac{\left(\left({\left(\frac{k}{t\_m}\right)}^{2} + 2\right) \cdot \tan k\right) \cdot t\_m}{\ell}}\\
\end{array}
\end{array}
if t < 1.49999999999999995e-125Initial program 48.5%
Taylor expanded in t around 0
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-sin.f64N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-cos.f6466.5
Applied rewrites66.5%
Applied rewrites72.8%
if 1.49999999999999995e-125 < t Initial program 65.5%
lift-*.f64N/A
*-commutativeN/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-/.f6484.5
Applied rewrites84.5%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
lift-*.f64N/A
associate-*r*N/A
associate-*l*N/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lift-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites95.0%
lift-*.f64N/A
lift-/.f64N/A
associate-*l/N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f6495.0
lift-*.f64N/A
*-commutativeN/A
lower-*.f6495.0
Applied rewrites95.0%
lift-*.f64N/A
*-commutativeN/A
lift-/.f64N/A
frac-2negN/A
associate-*r/N/A
lower-/.f64N/A
Applied rewrites95.0%
Final simplification79.8%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= t_m 1.5e-125)
(/ 2.0 (* (* (* (tan k) (/ (sin k) (* l l))) k) (* t_m k)))
(if (<= t_m 1.9e+219)
(/
2.0
(*
(* t_m (* t_m (/ (sin k) l)))
(* (/ t_m l) (* (tan k) (+ (pow (/ k t_m) 2.0) 2.0)))))
(/
2.0
(*
(* t_m (/ (* (sin k) t_m) l))
(* (/ t_m l) (/ (* 2.0 (sin k)) (cos 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 (t_m <= 1.5e-125) {
tmp = 2.0 / (((tan(k) * (sin(k) / (l * l))) * k) * (t_m * k));
} else if (t_m <= 1.9e+219) {
tmp = 2.0 / ((t_m * (t_m * (sin(k) / l))) * ((t_m / l) * (tan(k) * (pow((k / t_m), 2.0) + 2.0))));
} else {
tmp = 2.0 / ((t_m * ((sin(k) * t_m) / l)) * ((t_m / l) * ((2.0 * sin(k)) / cos(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 (t_m <= 1.5d-125) then
tmp = 2.0d0 / (((tan(k) * (sin(k) / (l * l))) * k) * (t_m * k))
else if (t_m <= 1.9d+219) then
tmp = 2.0d0 / ((t_m * (t_m * (sin(k) / l))) * ((t_m / l) * (tan(k) * (((k / t_m) ** 2.0d0) + 2.0d0))))
else
tmp = 2.0d0 / ((t_m * ((sin(k) * t_m) / l)) * ((t_m / l) * ((2.0d0 * sin(k)) / cos(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 (t_m <= 1.5e-125) {
tmp = 2.0 / (((Math.tan(k) * (Math.sin(k) / (l * l))) * k) * (t_m * k));
} else if (t_m <= 1.9e+219) {
tmp = 2.0 / ((t_m * (t_m * (Math.sin(k) / l))) * ((t_m / l) * (Math.tan(k) * (Math.pow((k / t_m), 2.0) + 2.0))));
} else {
tmp = 2.0 / ((t_m * ((Math.sin(k) * t_m) / l)) * ((t_m / l) * ((2.0 * Math.sin(k)) / Math.cos(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 t_m <= 1.5e-125: tmp = 2.0 / (((math.tan(k) * (math.sin(k) / (l * l))) * k) * (t_m * k)) elif t_m <= 1.9e+219: tmp = 2.0 / ((t_m * (t_m * (math.sin(k) / l))) * ((t_m / l) * (math.tan(k) * (math.pow((k / t_m), 2.0) + 2.0)))) else: tmp = 2.0 / ((t_m * ((math.sin(k) * t_m) / l)) * ((t_m / l) * ((2.0 * math.sin(k)) / math.cos(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 (t_m <= 1.5e-125) tmp = Float64(2.0 / Float64(Float64(Float64(tan(k) * Float64(sin(k) / Float64(l * l))) * k) * Float64(t_m * k))); elseif (t_m <= 1.9e+219) tmp = Float64(2.0 / Float64(Float64(t_m * Float64(t_m * Float64(sin(k) / l))) * Float64(Float64(t_m / l) * Float64(tan(k) * Float64((Float64(k / t_m) ^ 2.0) + 2.0))))); else tmp = Float64(2.0 / Float64(Float64(t_m * Float64(Float64(sin(k) * t_m) / l)) * Float64(Float64(t_m / l) * Float64(Float64(2.0 * sin(k)) / cos(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 (t_m <= 1.5e-125) tmp = 2.0 / (((tan(k) * (sin(k) / (l * l))) * k) * (t_m * k)); elseif (t_m <= 1.9e+219) tmp = 2.0 / ((t_m * (t_m * (sin(k) / l))) * ((t_m / l) * (tan(k) * (((k / t_m) ^ 2.0) + 2.0)))); else tmp = 2.0 / ((t_m * ((sin(k) * t_m) / l)) * ((t_m / l) * ((2.0 * sin(k)) / cos(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[t$95$m, 1.5e-125], N[(2.0 / N[(N[(N[(N[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * k), $MachinePrecision] * N[(t$95$m * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 1.9e+219], N[(2.0 / N[(N[(t$95$m * N[(t$95$m * N[(N[Sin[k], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(t$95$m / l), $MachinePrecision] * N[(N[Tan[k], $MachinePrecision] * N[(N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision] + 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(t$95$m * N[(N[(N[Sin[k], $MachinePrecision] * t$95$m), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision] * N[(N[(t$95$m / l), $MachinePrecision] * N[(N[(2.0 * N[Sin[k], $MachinePrecision]), $MachinePrecision] / N[Cos[k], $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 1.5 \cdot 10^{-125}:\\
\;\;\;\;\frac{2}{\left(\left(\tan k \cdot \frac{\sin k}{\ell \cdot \ell}\right) \cdot k\right) \cdot \left(t\_m \cdot k\right)}\\
\mathbf{elif}\;t\_m \leq 1.9 \cdot 10^{+219}:\\
\;\;\;\;\frac{2}{\left(t\_m \cdot \left(t\_m \cdot \frac{\sin k}{\ell}\right)\right) \cdot \left(\frac{t\_m}{\ell} \cdot \left(\tan k \cdot \left({\left(\frac{k}{t\_m}\right)}^{2} + 2\right)\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(t\_m \cdot \frac{\sin k \cdot t\_m}{\ell}\right) \cdot \left(\frac{t\_m}{\ell} \cdot \frac{2 \cdot \sin k}{\cos k}\right)}\\
\end{array}
\end{array}
if t < 1.49999999999999995e-125Initial program 48.5%
Taylor expanded in t around 0
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-sin.f64N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-cos.f6466.5
Applied rewrites66.5%
Applied rewrites72.8%
if 1.49999999999999995e-125 < t < 1.89999999999999998e219Initial program 62.7%
lift-*.f64N/A
*-commutativeN/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-/.f6481.2
Applied rewrites81.2%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
lift-*.f64N/A
associate-*r*N/A
associate-*l*N/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lift-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites94.0%
lift-*.f64N/A
lift-/.f64N/A
associate-*l/N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f6494.0
lift-*.f64N/A
*-commutativeN/A
lower-*.f6494.0
Applied rewrites94.0%
lift-/.f64N/A
lift-*.f64N/A
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f6491.7
Applied rewrites91.7%
if 1.89999999999999998e219 < t Initial program 78.9%
lift-*.f64N/A
*-commutativeN/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-/.f6499.9
Applied rewrites99.9%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
lift-*.f64N/A
associate-*r*N/A
associate-*l*N/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lift-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites99.8%
lift-*.f64N/A
lift-/.f64N/A
associate-*l/N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f6499.8
lift-*.f64N/A
*-commutativeN/A
lower-*.f6499.8
Applied rewrites99.8%
Taylor expanded in t around inf
associate-*r/N/A
lower-/.f64N/A
lower-*.f64N/A
lower-sin.f64N/A
lower-cos.f6499.8
Applied rewrites99.8%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= t_m 7e-33)
(/ 2.0 (* k (* (* t_m k) (* (tan k) (/ (sin k) (* l l))))))
(if (<= t_m 1.15e+158)
(*
(/
(* (/ 2.0 (* (* (sin k) t_m) t_m)) l)
(* (* t_m (+ (pow (/ k t_m) 2.0) 2.0)) (tan k)))
l)
(/
2.0
(*
(* (/ t_m l) (* t_m (sin k)))
(* (/ t_m l) (/ (* 2.0 (sin k)) (cos 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 (t_m <= 7e-33) {
tmp = 2.0 / (k * ((t_m * k) * (tan(k) * (sin(k) / (l * l)))));
} else if (t_m <= 1.15e+158) {
tmp = (((2.0 / ((sin(k) * t_m) * t_m)) * l) / ((t_m * (pow((k / t_m), 2.0) + 2.0)) * tan(k))) * l;
} else {
tmp = 2.0 / (((t_m / l) * (t_m * sin(k))) * ((t_m / l) * ((2.0 * sin(k)) / cos(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 (t_m <= 7d-33) then
tmp = 2.0d0 / (k * ((t_m * k) * (tan(k) * (sin(k) / (l * l)))))
else if (t_m <= 1.15d+158) then
tmp = (((2.0d0 / ((sin(k) * t_m) * t_m)) * l) / ((t_m * (((k / t_m) ** 2.0d0) + 2.0d0)) * tan(k))) * l
else
tmp = 2.0d0 / (((t_m / l) * (t_m * sin(k))) * ((t_m / l) * ((2.0d0 * sin(k)) / cos(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 (t_m <= 7e-33) {
tmp = 2.0 / (k * ((t_m * k) * (Math.tan(k) * (Math.sin(k) / (l * l)))));
} else if (t_m <= 1.15e+158) {
tmp = (((2.0 / ((Math.sin(k) * t_m) * t_m)) * l) / ((t_m * (Math.pow((k / t_m), 2.0) + 2.0)) * Math.tan(k))) * l;
} else {
tmp = 2.0 / (((t_m / l) * (t_m * Math.sin(k))) * ((t_m / l) * ((2.0 * Math.sin(k)) / Math.cos(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 t_m <= 7e-33: tmp = 2.0 / (k * ((t_m * k) * (math.tan(k) * (math.sin(k) / (l * l))))) elif t_m <= 1.15e+158: tmp = (((2.0 / ((math.sin(k) * t_m) * t_m)) * l) / ((t_m * (math.pow((k / t_m), 2.0) + 2.0)) * math.tan(k))) * l else: tmp = 2.0 / (((t_m / l) * (t_m * math.sin(k))) * ((t_m / l) * ((2.0 * math.sin(k)) / math.cos(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 (t_m <= 7e-33) tmp = Float64(2.0 / Float64(k * Float64(Float64(t_m * k) * Float64(tan(k) * Float64(sin(k) / Float64(l * l)))))); elseif (t_m <= 1.15e+158) tmp = Float64(Float64(Float64(Float64(2.0 / Float64(Float64(sin(k) * t_m) * t_m)) * l) / Float64(Float64(t_m * Float64((Float64(k / t_m) ^ 2.0) + 2.0)) * tan(k))) * l); else tmp = Float64(2.0 / Float64(Float64(Float64(t_m / l) * Float64(t_m * sin(k))) * Float64(Float64(t_m / l) * Float64(Float64(2.0 * sin(k)) / cos(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 (t_m <= 7e-33) tmp = 2.0 / (k * ((t_m * k) * (tan(k) * (sin(k) / (l * l))))); elseif (t_m <= 1.15e+158) tmp = (((2.0 / ((sin(k) * t_m) * t_m)) * l) / ((t_m * (((k / t_m) ^ 2.0) + 2.0)) * tan(k))) * l; else tmp = 2.0 / (((t_m / l) * (t_m * sin(k))) * ((t_m / l) * ((2.0 * sin(k)) / cos(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[t$95$m, 7e-33], N[(2.0 / N[(k * N[(N[(t$95$m * k), $MachinePrecision] * N[(N[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 1.15e+158], N[(N[(N[(N[(2.0 / N[(N[(N[Sin[k], $MachinePrecision] * t$95$m), $MachinePrecision] * t$95$m), $MachinePrecision]), $MachinePrecision] * l), $MachinePrecision] / N[(N[(t$95$m * N[(N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision] + 2.0), $MachinePrecision]), $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * l), $MachinePrecision], N[(2.0 / N[(N[(N[(t$95$m / l), $MachinePrecision] * N[(t$95$m * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(t$95$m / l), $MachinePrecision] * N[(N[(2.0 * N[Sin[k], $MachinePrecision]), $MachinePrecision] / N[Cos[k], $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 7 \cdot 10^{-33}:\\
\;\;\;\;\frac{2}{k \cdot \left(\left(t\_m \cdot k\right) \cdot \left(\tan k \cdot \frac{\sin k}{\ell \cdot \ell}\right)\right)}\\
\mathbf{elif}\;t\_m \leq 1.15 \cdot 10^{+158}:\\
\;\;\;\;\frac{\frac{2}{\left(\sin k \cdot t\_m\right) \cdot t\_m} \cdot \ell}{\left(t\_m \cdot \left({\left(\frac{k}{t\_m}\right)}^{2} + 2\right)\right) \cdot \tan k} \cdot \ell\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(\frac{t\_m}{\ell} \cdot \left(t\_m \cdot \sin k\right)\right) \cdot \left(\frac{t\_m}{\ell} \cdot \frac{2 \cdot \sin k}{\cos k}\right)}\\
\end{array}
\end{array}
if t < 6.9999999999999997e-33Initial program 51.0%
Taylor expanded in t around 0
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-sin.f64N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-cos.f6467.6
Applied rewrites67.6%
Applied rewrites74.0%
if 6.9999999999999997e-33 < t < 1.14999999999999993e158Initial program 64.5%
lift-*.f64N/A
*-commutativeN/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-/.f6478.7
Applied rewrites78.7%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
lift-*.f64N/A
associate-*r*N/A
associate-*l*N/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lift-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites98.5%
lift-/.f64N/A
lift-*.f64N/A
associate-/r*N/A
lift-*.f64N/A
lift-/.f64N/A
associate-*l/N/A
associate-/r/N/A
lower-*.f64N/A
Applied rewrites96.8%
if 1.14999999999999993e158 < t Initial program 62.1%
lift-*.f64N/A
*-commutativeN/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-/.f6497.4
Applied rewrites97.4%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
lift-*.f64N/A
associate-*r*N/A
associate-*l*N/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lift-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites97.4%
Taylor expanded in t around inf
associate-*r/N/A
lower-/.f64N/A
lower-*.f64N/A
lower-sin.f64N/A
lower-cos.f6493.6
Applied rewrites93.6%
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) t_m)))
(*
t_s
(if (<= t_m 7e-33)
(/ 2.0 (* k (* (* t_m k) (* (tan k) (/ (sin k) (* l l))))))
(if (<= t_m 1.15e+158)
(*
(/
(* (/ 2.0 (* t_2 t_m)) l)
(* (* t_m (+ (pow (/ k t_m) 2.0) 2.0)) (tan k)))
l)
(/
2.0
(* (* t_m (/ t_2 l)) (* (/ t_m l) (/ (* 2.0 (sin k)) (cos k))))))))))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) * t_m;
double tmp;
if (t_m <= 7e-33) {
tmp = 2.0 / (k * ((t_m * k) * (tan(k) * (sin(k) / (l * l)))));
} else if (t_m <= 1.15e+158) {
tmp = (((2.0 / (t_2 * t_m)) * l) / ((t_m * (pow((k / t_m), 2.0) + 2.0)) * tan(k))) * l;
} else {
tmp = 2.0 / ((t_m * (t_2 / l)) * ((t_m / l) * ((2.0 * sin(k)) / cos(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) :: t_2
real(8) :: tmp
t_2 = sin(k) * t_m
if (t_m <= 7d-33) then
tmp = 2.0d0 / (k * ((t_m * k) * (tan(k) * (sin(k) / (l * l)))))
else if (t_m <= 1.15d+158) then
tmp = (((2.0d0 / (t_2 * t_m)) * l) / ((t_m * (((k / t_m) ** 2.0d0) + 2.0d0)) * tan(k))) * l
else
tmp = 2.0d0 / ((t_m * (t_2 / l)) * ((t_m / l) * ((2.0d0 * sin(k)) / cos(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 t_2 = Math.sin(k) * t_m;
double tmp;
if (t_m <= 7e-33) {
tmp = 2.0 / (k * ((t_m * k) * (Math.tan(k) * (Math.sin(k) / (l * l)))));
} else if (t_m <= 1.15e+158) {
tmp = (((2.0 / (t_2 * t_m)) * l) / ((t_m * (Math.pow((k / t_m), 2.0) + 2.0)) * Math.tan(k))) * l;
} else {
tmp = 2.0 / ((t_m * (t_2 / l)) * ((t_m / l) * ((2.0 * Math.sin(k)) / Math.cos(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): t_2 = math.sin(k) * t_m tmp = 0 if t_m <= 7e-33: tmp = 2.0 / (k * ((t_m * k) * (math.tan(k) * (math.sin(k) / (l * l))))) elif t_m <= 1.15e+158: tmp = (((2.0 / (t_2 * t_m)) * l) / ((t_m * (math.pow((k / t_m), 2.0) + 2.0)) * math.tan(k))) * l else: tmp = 2.0 / ((t_m * (t_2 / l)) * ((t_m / l) * ((2.0 * math.sin(k)) / math.cos(k)))) 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) * t_m) tmp = 0.0 if (t_m <= 7e-33) tmp = Float64(2.0 / Float64(k * Float64(Float64(t_m * k) * Float64(tan(k) * Float64(sin(k) / Float64(l * l)))))); elseif (t_m <= 1.15e+158) tmp = Float64(Float64(Float64(Float64(2.0 / Float64(t_2 * t_m)) * l) / Float64(Float64(t_m * Float64((Float64(k / t_m) ^ 2.0) + 2.0)) * tan(k))) * l); else tmp = Float64(2.0 / Float64(Float64(t_m * Float64(t_2 / l)) * Float64(Float64(t_m / l) * Float64(Float64(2.0 * sin(k)) / cos(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) t_2 = sin(k) * t_m; tmp = 0.0; if (t_m <= 7e-33) tmp = 2.0 / (k * ((t_m * k) * (tan(k) * (sin(k) / (l * l))))); elseif (t_m <= 1.15e+158) tmp = (((2.0 / (t_2 * t_m)) * l) / ((t_m * (((k / t_m) ^ 2.0) + 2.0)) * tan(k))) * l; else tmp = 2.0 / ((t_m * (t_2 / l)) * ((t_m / l) * ((2.0 * sin(k)) / cos(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_] := Block[{t$95$2 = N[(N[Sin[k], $MachinePrecision] * t$95$m), $MachinePrecision]}, N[(t$95$s * If[LessEqual[t$95$m, 7e-33], N[(2.0 / N[(k * N[(N[(t$95$m * k), $MachinePrecision] * N[(N[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 1.15e+158], N[(N[(N[(N[(2.0 / N[(t$95$2 * t$95$m), $MachinePrecision]), $MachinePrecision] * l), $MachinePrecision] / N[(N[(t$95$m * N[(N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision] + 2.0), $MachinePrecision]), $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * l), $MachinePrecision], N[(2.0 / N[(N[(t$95$m * N[(t$95$2 / l), $MachinePrecision]), $MachinePrecision] * N[(N[(t$95$m / l), $MachinePrecision] * N[(N[(2.0 * N[Sin[k], $MachinePrecision]), $MachinePrecision] / N[Cos[k], $MachinePrecision]), $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 := \sin k \cdot t\_m\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 7 \cdot 10^{-33}:\\
\;\;\;\;\frac{2}{k \cdot \left(\left(t\_m \cdot k\right) \cdot \left(\tan k \cdot \frac{\sin k}{\ell \cdot \ell}\right)\right)}\\
\mathbf{elif}\;t\_m \leq 1.15 \cdot 10^{+158}:\\
\;\;\;\;\frac{\frac{2}{t\_2 \cdot t\_m} \cdot \ell}{\left(t\_m \cdot \left({\left(\frac{k}{t\_m}\right)}^{2} + 2\right)\right) \cdot \tan k} \cdot \ell\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(t\_m \cdot \frac{t\_2}{\ell}\right) \cdot \left(\frac{t\_m}{\ell} \cdot \frac{2 \cdot \sin k}{\cos k}\right)}\\
\end{array}
\end{array}
\end{array}
if t < 6.9999999999999997e-33Initial program 51.0%
Taylor expanded in t around 0
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-sin.f64N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-cos.f6467.6
Applied rewrites67.6%
Applied rewrites74.0%
if 6.9999999999999997e-33 < t < 1.14999999999999993e158Initial program 64.5%
lift-*.f64N/A
*-commutativeN/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-/.f6478.7
Applied rewrites78.7%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
lift-*.f64N/A
associate-*r*N/A
associate-*l*N/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lift-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites98.5%
lift-/.f64N/A
lift-*.f64N/A
associate-/r*N/A
lift-*.f64N/A
lift-/.f64N/A
associate-*l/N/A
associate-/r/N/A
lower-*.f64N/A
Applied rewrites96.8%
if 1.14999999999999993e158 < t Initial program 62.1%
lift-*.f64N/A
*-commutativeN/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-/.f6497.4
Applied rewrites97.4%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
lift-*.f64N/A
associate-*r*N/A
associate-*l*N/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lift-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites97.4%
lift-*.f64N/A
lift-/.f64N/A
associate-*l/N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f6497.4
lift-*.f64N/A
*-commutativeN/A
lower-*.f6497.4
Applied rewrites97.4%
Taylor expanded in t around inf
associate-*r/N/A
lower-/.f64N/A
lower-*.f64N/A
lower-sin.f64N/A
lower-cos.f6493.6
Applied rewrites93.6%
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) t_m)))
(*
t_s
(if (<= t_m 7e-33)
(/ 2.0 (* k (* (* t_m k) (* (tan k) (/ (sin k) (* l l))))))
(if (<= t_m 1.4e+155)
(*
(/
(* (/ 2.0 (* t_2 t_m)) l)
(* (* t_m (+ (pow (/ k t_m) 2.0) 2.0)) (tan k)))
l)
(/
2.0
(*
(* (* t_2 (* (/ t_m l) (/ t_m l))) (tan k))
(fma (/ k t_m) (/ 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 t_2 = sin(k) * t_m;
double tmp;
if (t_m <= 7e-33) {
tmp = 2.0 / (k * ((t_m * k) * (tan(k) * (sin(k) / (l * l)))));
} else if (t_m <= 1.4e+155) {
tmp = (((2.0 / (t_2 * t_m)) * l) / ((t_m * (pow((k / t_m), 2.0) + 2.0)) * tan(k))) * l;
} else {
tmp = 2.0 / (((t_2 * ((t_m / l) * (t_m / l))) * tan(k)) * fma((k / t_m), (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) t_2 = Float64(sin(k) * t_m) tmp = 0.0 if (t_m <= 7e-33) tmp = Float64(2.0 / Float64(k * Float64(Float64(t_m * k) * Float64(tan(k) * Float64(sin(k) / Float64(l * l)))))); elseif (t_m <= 1.4e+155) tmp = Float64(Float64(Float64(Float64(2.0 / Float64(t_2 * t_m)) * l) / Float64(Float64(t_m * Float64((Float64(k / t_m) ^ 2.0) + 2.0)) * tan(k))) * l); else tmp = Float64(2.0 / Float64(Float64(Float64(t_2 * Float64(Float64(t_m / l) * Float64(t_m / l))) * tan(k)) * fma(Float64(k / t_m), 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_] := Block[{t$95$2 = N[(N[Sin[k], $MachinePrecision] * t$95$m), $MachinePrecision]}, N[(t$95$s * If[LessEqual[t$95$m, 7e-33], N[(2.0 / N[(k * N[(N[(t$95$m * k), $MachinePrecision] * N[(N[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 1.4e+155], N[(N[(N[(N[(2.0 / N[(t$95$2 * t$95$m), $MachinePrecision]), $MachinePrecision] * l), $MachinePrecision] / N[(N[(t$95$m * N[(N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision] + 2.0), $MachinePrecision]), $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * l), $MachinePrecision], N[(2.0 / N[(N[(N[(t$95$2 * N[(N[(t$95$m / l), $MachinePrecision] * N[(t$95$m / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * N[(N[(k / t$95$m), $MachinePrecision] * 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)
\\
\begin{array}{l}
t_2 := \sin k \cdot t\_m\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 7 \cdot 10^{-33}:\\
\;\;\;\;\frac{2}{k \cdot \left(\left(t\_m \cdot k\right) \cdot \left(\tan k \cdot \frac{\sin k}{\ell \cdot \ell}\right)\right)}\\
\mathbf{elif}\;t\_m \leq 1.4 \cdot 10^{+155}:\\
\;\;\;\;\frac{\frac{2}{t\_2 \cdot t\_m} \cdot \ell}{\left(t\_m \cdot \left({\left(\frac{k}{t\_m}\right)}^{2} + 2\right)\right) \cdot \tan k} \cdot \ell\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(\left(t\_2 \cdot \left(\frac{t\_m}{\ell} \cdot \frac{t\_m}{\ell}\right)\right) \cdot \tan k\right) \cdot \mathsf{fma}\left(\frac{k}{t\_m}, \frac{k}{t\_m}, 2\right)}\\
\end{array}
\end{array}
\end{array}
if t < 6.9999999999999997e-33Initial program 51.0%
Taylor expanded in t around 0
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-sin.f64N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-cos.f6467.6
Applied rewrites67.6%
Applied rewrites74.0%
if 6.9999999999999997e-33 < t < 1.40000000000000008e155Initial program 64.5%
lift-*.f64N/A
*-commutativeN/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-/.f6478.7
Applied rewrites78.7%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
lift-*.f64N/A
associate-*r*N/A
associate-*l*N/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lift-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites98.5%
lift-/.f64N/A
lift-*.f64N/A
associate-/r*N/A
lift-*.f64N/A
lift-/.f64N/A
associate-*l/N/A
associate-/r/N/A
lower-*.f64N/A
Applied rewrites96.8%
if 1.40000000000000008e155 < t Initial program 62.1%
lift-*.f64N/A
*-commutativeN/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-/.f6497.4
Applied rewrites97.4%
lift-+.f64N/A
lift-+.f64N/A
+-commutativeN/A
associate-+l+N/A
metadata-evalN/A
lift-pow.f64N/A
unpow2N/A
lower-fma.f6497.4
Applied rewrites97.4%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= t_m 1.5e-125)
(/ 2.0 (* (* (* (tan k) (/ (sin k) (* l l))) k) (* t_m k)))
(/
2.0
(*
(* t_m (/ (* (sin k) t_m) l))
(* (/ t_m l) (* (tan k) (+ (pow (/ k t_m) 2.0) 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 <= 1.5e-125) {
tmp = 2.0 / (((tan(k) * (sin(k) / (l * l))) * k) * (t_m * k));
} else {
tmp = 2.0 / ((t_m * ((sin(k) * t_m) / l)) * ((t_m / l) * (tan(k) * (pow((k / t_m), 2.0) + 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 <= 1.5d-125) then
tmp = 2.0d0 / (((tan(k) * (sin(k) / (l * l))) * k) * (t_m * k))
else
tmp = 2.0d0 / ((t_m * ((sin(k) * t_m) / l)) * ((t_m / l) * (tan(k) * (((k / t_m) ** 2.0d0) + 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 <= 1.5e-125) {
tmp = 2.0 / (((Math.tan(k) * (Math.sin(k) / (l * l))) * k) * (t_m * k));
} else {
tmp = 2.0 / ((t_m * ((Math.sin(k) * t_m) / l)) * ((t_m / l) * (Math.tan(k) * (Math.pow((k / t_m), 2.0) + 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 <= 1.5e-125: tmp = 2.0 / (((math.tan(k) * (math.sin(k) / (l * l))) * k) * (t_m * k)) else: tmp = 2.0 / ((t_m * ((math.sin(k) * t_m) / l)) * ((t_m / l) * (math.tan(k) * (math.pow((k / t_m), 2.0) + 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 <= 1.5e-125) tmp = Float64(2.0 / Float64(Float64(Float64(tan(k) * Float64(sin(k) / Float64(l * l))) * k) * Float64(t_m * k))); else tmp = Float64(2.0 / Float64(Float64(t_m * Float64(Float64(sin(k) * t_m) / l)) * Float64(Float64(t_m / l) * Float64(tan(k) * Float64((Float64(k / t_m) ^ 2.0) + 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 <= 1.5e-125) tmp = 2.0 / (((tan(k) * (sin(k) / (l * l))) * k) * (t_m * k)); else tmp = 2.0 / ((t_m * ((sin(k) * t_m) / l)) * ((t_m / l) * (tan(k) * (((k / t_m) ^ 2.0) + 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, 1.5e-125], N[(2.0 / N[(N[(N[(N[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * k), $MachinePrecision] * N[(t$95$m * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(t$95$m * N[(N[(N[Sin[k], $MachinePrecision] * t$95$m), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision] * N[(N[(t$95$m / l), $MachinePrecision] * N[(N[Tan[k], $MachinePrecision] * N[(N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision] + 2.0), $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 1.5 \cdot 10^{-125}:\\
\;\;\;\;\frac{2}{\left(\left(\tan k \cdot \frac{\sin k}{\ell \cdot \ell}\right) \cdot k\right) \cdot \left(t\_m \cdot k\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(t\_m \cdot \frac{\sin k \cdot t\_m}{\ell}\right) \cdot \left(\frac{t\_m}{\ell} \cdot \left(\tan k \cdot \left({\left(\frac{k}{t\_m}\right)}^{2} + 2\right)\right)\right)}\\
\end{array}
\end{array}
if t < 1.49999999999999995e-125Initial program 48.5%
Taylor expanded in t around 0
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-sin.f64N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-cos.f6466.5
Applied rewrites66.5%
Applied rewrites72.8%
if 1.49999999999999995e-125 < t Initial program 65.5%
lift-*.f64N/A
*-commutativeN/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-/.f6484.5
Applied rewrites84.5%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
lift-*.f64N/A
associate-*r*N/A
associate-*l*N/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lift-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites95.0%
lift-*.f64N/A
lift-/.f64N/A
associate-*l/N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f6495.0
lift-*.f64N/A
*-commutativeN/A
lower-*.f6495.0
Applied rewrites95.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 4.9e-135)
(/ 2.0 (* k (* k (* (/ (* k k) l) (/ t_m l)))))
(/
2.0
(*
(* (/ t_m l) (* t_m (sin k)))
(*
(/ t_m l)
(*
(fma (+ 0.6666666666666666 (pow (* t_m t_m) -1.0)) (* k k) 2.0)
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 (t_m <= 4.9e-135) {
tmp = 2.0 / (k * (k * (((k * k) / l) * (t_m / l))));
} else {
tmp = 2.0 / (((t_m / l) * (t_m * sin(k))) * ((t_m / l) * (fma((0.6666666666666666 + pow((t_m * t_m), -1.0)), (k * k), 2.0) * 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 (t_m <= 4.9e-135) tmp = Float64(2.0 / Float64(k * Float64(k * Float64(Float64(Float64(k * k) / l) * Float64(t_m / l))))); else tmp = Float64(2.0 / Float64(Float64(Float64(t_m / l) * Float64(t_m * sin(k))) * Float64(Float64(t_m / l) * Float64(fma(Float64(0.6666666666666666 + (Float64(t_m * t_m) ^ -1.0)), Float64(k * k), 2.0) * k)))); 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, 4.9e-135], N[(2.0 / N[(k * N[(k * N[(N[(N[(k * k), $MachinePrecision] / l), $MachinePrecision] * N[(t$95$m / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(N[(t$95$m / l), $MachinePrecision] * N[(t$95$m * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(t$95$m / l), $MachinePrecision] * N[(N[(N[(0.6666666666666666 + N[Power[N[(t$95$m * t$95$m), $MachinePrecision], -1.0], $MachinePrecision]), $MachinePrecision] * N[(k * k), $MachinePrecision] + 2.0), $MachinePrecision] * k), $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 4.9 \cdot 10^{-135}:\\
\;\;\;\;\frac{2}{k \cdot \left(k \cdot \left(\frac{k \cdot k}{\ell} \cdot \frac{t\_m}{\ell}\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(\frac{t\_m}{\ell} \cdot \left(t\_m \cdot \sin k\right)\right) \cdot \left(\frac{t\_m}{\ell} \cdot \left(\mathsf{fma}\left(0.6666666666666666 + {\left(t\_m \cdot t\_m\right)}^{-1}, k \cdot k, 2\right) \cdot k\right)\right)}\\
\end{array}
\end{array}
if t < 4.9000000000000003e-135Initial program 49.3%
Taylor expanded in t around 0
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-sin.f64N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-cos.f6467.1
Applied rewrites67.1%
Applied rewrites70.1%
Taylor expanded in k around 0
Applied rewrites61.2%
if 4.9000000000000003e-135 < t Initial program 63.2%
lift-*.f64N/A
*-commutativeN/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-/.f6482.7
Applied rewrites82.7%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
lift-*.f64N/A
associate-*r*N/A
associate-*l*N/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lift-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites92.8%
Taylor expanded in k around 0
*-commutativeN/A
lower-*.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower-+.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f64N/A
unpow2N/A
lower-*.f6480.1
Applied rewrites80.1%
Final simplification67.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 5.9e-108)
(/
2.0
(*
(* t_m (* k (/ t_m l)))
(* (/ t_m l) (* (tan k) (+ (pow (/ k t_m) 2.0) 2.0)))))
(if (<= k 1300.0)
(/
2.0
(*
(/ t_m l)
(*
(/
(fma
(* (fma 0.3333333333333333 (* t_m t_m) 1.0) k)
k
(* (* t_m t_m) 2.0))
l)
(* k k))))
(if (<= k 9e+153)
(/ 2.0 (/ (* (* (/ (sin k) l) (tan k)) (* (* k k) t_m)) l))
(/ 2.0 (* k (* (* t_m k) (* (tan k) (/ (sin k) (* 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 (k <= 5.9e-108) {
tmp = 2.0 / ((t_m * (k * (t_m / l))) * ((t_m / l) * (tan(k) * (pow((k / t_m), 2.0) + 2.0))));
} else if (k <= 1300.0) {
tmp = 2.0 / ((t_m / l) * ((fma((fma(0.3333333333333333, (t_m * t_m), 1.0) * k), k, ((t_m * t_m) * 2.0)) / l) * (k * k)));
} else if (k <= 9e+153) {
tmp = 2.0 / ((((sin(k) / l) * tan(k)) * ((k * k) * t_m)) / l);
} else {
tmp = 2.0 / (k * ((t_m * k) * (tan(k) * (sin(k) / (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 (k <= 5.9e-108) tmp = Float64(2.0 / Float64(Float64(t_m * Float64(k * Float64(t_m / l))) * Float64(Float64(t_m / l) * Float64(tan(k) * Float64((Float64(k / t_m) ^ 2.0) + 2.0))))); elseif (k <= 1300.0) tmp = Float64(2.0 / Float64(Float64(t_m / l) * Float64(Float64(fma(Float64(fma(0.3333333333333333, Float64(t_m * t_m), 1.0) * k), k, Float64(Float64(t_m * t_m) * 2.0)) / l) * Float64(k * k)))); elseif (k <= 9e+153) tmp = Float64(2.0 / Float64(Float64(Float64(Float64(sin(k) / l) * tan(k)) * Float64(Float64(k * k) * t_m)) / l)); else tmp = Float64(2.0 / Float64(k * Float64(Float64(t_m * k) * Float64(tan(k) * Float64(sin(k) / 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[k, 5.9e-108], N[(2.0 / N[(N[(t$95$m * N[(k * N[(t$95$m / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(t$95$m / l), $MachinePrecision] * N[(N[Tan[k], $MachinePrecision] * N[(N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision] + 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 1300.0], N[(2.0 / N[(N[(t$95$m / l), $MachinePrecision] * N[(N[(N[(N[(N[(0.3333333333333333 * N[(t$95$m * t$95$m), $MachinePrecision] + 1.0), $MachinePrecision] * k), $MachinePrecision] * k + N[(N[(t$95$m * t$95$m), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision] * N[(k * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 9e+153], N[(2.0 / N[(N[(N[(N[(N[Sin[k], $MachinePrecision] / l), $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(k * N[(N[(t$95$m * k), $MachinePrecision] * N[(N[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] / N[(l * l), $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}\;k \leq 5.9 \cdot 10^{-108}:\\
\;\;\;\;\frac{2}{\left(t\_m \cdot \left(k \cdot \frac{t\_m}{\ell}\right)\right) \cdot \left(\frac{t\_m}{\ell} \cdot \left(\tan k \cdot \left({\left(\frac{k}{t\_m}\right)}^{2} + 2\right)\right)\right)}\\
\mathbf{elif}\;k \leq 1300:\\
\;\;\;\;\frac{2}{\frac{t\_m}{\ell} \cdot \left(\frac{\mathsf{fma}\left(\mathsf{fma}\left(0.3333333333333333, t\_m \cdot t\_m, 1\right) \cdot k, k, \left(t\_m \cdot t\_m\right) \cdot 2\right)}{\ell} \cdot \left(k \cdot k\right)\right)}\\
\mathbf{elif}\;k \leq 9 \cdot 10^{+153}:\\
\;\;\;\;\frac{2}{\frac{\left(\frac{\sin k}{\ell} \cdot \tan k\right) \cdot \left(\left(k \cdot k\right) \cdot t\_m\right)}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{k \cdot \left(\left(t\_m \cdot k\right) \cdot \left(\tan k \cdot \frac{\sin k}{\ell \cdot \ell}\right)\right)}\\
\end{array}
\end{array}
if k < 5.89999999999999965e-108Initial program 54.1%
lift-*.f64N/A
*-commutativeN/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-/.f6475.1
Applied rewrites75.1%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
lift-*.f64N/A
associate-*r*N/A
associate-*l*N/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lift-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites83.1%
lift-*.f64N/A
lift-/.f64N/A
associate-*l/N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f6483.1
lift-*.f64N/A
*-commutativeN/A
lower-*.f6483.1
Applied rewrites83.1%
Taylor expanded in k around 0
associate-/l*N/A
lower-*.f64N/A
lower-/.f6476.5
Applied rewrites76.5%
if 5.89999999999999965e-108 < k < 1300Initial program 64.7%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
associate-*l*N/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
Applied rewrites81.6%
Taylor expanded in k around 0
*-commutativeN/A
lower-*.f64N/A
Applied rewrites99.7%
if 1300 < k < 9.0000000000000002e153Initial program 55.9%
Taylor expanded in t around 0
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-sin.f64N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-cos.f6495.5
Applied rewrites95.5%
Applied rewrites95.6%
if 9.0000000000000002e153 < k Initial program 41.2%
Taylor expanded in t around 0
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-sin.f64N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-cos.f6456.5
Applied rewrites56.5%
Applied rewrites78.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.85e-124)
(/ 2.0 (* (* t_m (/ (* (sin k) t_m) l)) (* (/ t_m l) (* 2.0 k))))
(if (<= k 1300.0)
(/
2.0
(*
(/ t_m l)
(*
(/
(fma
(* (fma 0.3333333333333333 (* t_m t_m) 1.0) k)
k
(* (* t_m t_m) 2.0))
l)
(* k k))))
(if (<= k 9e+153)
(/ 2.0 (/ (* (* (/ (sin k) l) (tan k)) (* (* k k) t_m)) l))
(/ 2.0 (* k (* (* t_m k) (* (tan k) (/ (sin k) (* 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 (k <= 2.85e-124) {
tmp = 2.0 / ((t_m * ((sin(k) * t_m) / l)) * ((t_m / l) * (2.0 * k)));
} else if (k <= 1300.0) {
tmp = 2.0 / ((t_m / l) * ((fma((fma(0.3333333333333333, (t_m * t_m), 1.0) * k), k, ((t_m * t_m) * 2.0)) / l) * (k * k)));
} else if (k <= 9e+153) {
tmp = 2.0 / ((((sin(k) / l) * tan(k)) * ((k * k) * t_m)) / l);
} else {
tmp = 2.0 / (k * ((t_m * k) * (tan(k) * (sin(k) / (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 (k <= 2.85e-124) tmp = Float64(2.0 / Float64(Float64(t_m * Float64(Float64(sin(k) * t_m) / l)) * Float64(Float64(t_m / l) * Float64(2.0 * k)))); elseif (k <= 1300.0) tmp = Float64(2.0 / Float64(Float64(t_m / l) * Float64(Float64(fma(Float64(fma(0.3333333333333333, Float64(t_m * t_m), 1.0) * k), k, Float64(Float64(t_m * t_m) * 2.0)) / l) * Float64(k * k)))); elseif (k <= 9e+153) tmp = Float64(2.0 / Float64(Float64(Float64(Float64(sin(k) / l) * tan(k)) * Float64(Float64(k * k) * t_m)) / l)); else tmp = Float64(2.0 / Float64(k * Float64(Float64(t_m * k) * Float64(tan(k) * Float64(sin(k) / 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[k, 2.85e-124], N[(2.0 / N[(N[(t$95$m * N[(N[(N[Sin[k], $MachinePrecision] * t$95$m), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision] * N[(N[(t$95$m / l), $MachinePrecision] * N[(2.0 * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 1300.0], N[(2.0 / N[(N[(t$95$m / l), $MachinePrecision] * N[(N[(N[(N[(N[(0.3333333333333333 * N[(t$95$m * t$95$m), $MachinePrecision] + 1.0), $MachinePrecision] * k), $MachinePrecision] * k + N[(N[(t$95$m * t$95$m), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision] * N[(k * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 9e+153], N[(2.0 / N[(N[(N[(N[(N[Sin[k], $MachinePrecision] / l), $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(k * N[(N[(t$95$m * k), $MachinePrecision] * N[(N[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] / N[(l * l), $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}\;k \leq 2.85 \cdot 10^{-124}:\\
\;\;\;\;\frac{2}{\left(t\_m \cdot \frac{\sin k \cdot t\_m}{\ell}\right) \cdot \left(\frac{t\_m}{\ell} \cdot \left(2 \cdot k\right)\right)}\\
\mathbf{elif}\;k \leq 1300:\\
\;\;\;\;\frac{2}{\frac{t\_m}{\ell} \cdot \left(\frac{\mathsf{fma}\left(\mathsf{fma}\left(0.3333333333333333, t\_m \cdot t\_m, 1\right) \cdot k, k, \left(t\_m \cdot t\_m\right) \cdot 2\right)}{\ell} \cdot \left(k \cdot k\right)\right)}\\
\mathbf{elif}\;k \leq 9 \cdot 10^{+153}:\\
\;\;\;\;\frac{2}{\frac{\left(\frac{\sin k}{\ell} \cdot \tan k\right) \cdot \left(\left(k \cdot k\right) \cdot t\_m\right)}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{k \cdot \left(\left(t\_m \cdot k\right) \cdot \left(\tan k \cdot \frac{\sin k}{\ell \cdot \ell}\right)\right)}\\
\end{array}
\end{array}
if k < 2.84999999999999988e-124Initial program 53.6%
lift-*.f64N/A
*-commutativeN/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-/.f6474.8
Applied rewrites74.8%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
lift-*.f64N/A
associate-*r*N/A
associate-*l*N/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lift-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites82.9%
lift-*.f64N/A
lift-/.f64N/A
associate-*l/N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f6482.9
lift-*.f64N/A
*-commutativeN/A
lower-*.f6482.9
Applied rewrites82.9%
Taylor expanded in k around 0
lower-*.f6471.0
Applied rewrites71.0%
if 2.84999999999999988e-124 < k < 1300Initial program 67.6%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
associate-*l*N/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
Applied rewrites83.2%
Taylor expanded in k around 0
*-commutativeN/A
lower-*.f64N/A
Applied rewrites99.7%
if 1300 < k < 9.0000000000000002e153Initial program 55.9%
Taylor expanded in t around 0
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-sin.f64N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-cos.f6495.5
Applied rewrites95.5%
Applied rewrites95.6%
if 9.0000000000000002e153 < k Initial program 41.2%
Taylor expanded in t around 0
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-sin.f64N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-cos.f6456.5
Applied rewrites56.5%
Applied rewrites78.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.85e-124)
(/ 2.0 (* (* t_m (/ (* (sin k) t_m) l)) (* (/ t_m l) (* 2.0 k))))
(if (<= k 1300.0)
(/
2.0
(*
(/ t_m l)
(*
(/
(fma
(* (fma 0.3333333333333333 (* t_m t_m) 1.0) k)
k
(* (* t_m t_m) 2.0))
l)
(* k k))))
(/ 2.0 (* k (* (* t_m k) (* (tan k) (/ (sin k) (* 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 (k <= 2.85e-124) {
tmp = 2.0 / ((t_m * ((sin(k) * t_m) / l)) * ((t_m / l) * (2.0 * k)));
} else if (k <= 1300.0) {
tmp = 2.0 / ((t_m / l) * ((fma((fma(0.3333333333333333, (t_m * t_m), 1.0) * k), k, ((t_m * t_m) * 2.0)) / l) * (k * k)));
} else {
tmp = 2.0 / (k * ((t_m * k) * (tan(k) * (sin(k) / (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 (k <= 2.85e-124) tmp = Float64(2.0 / Float64(Float64(t_m * Float64(Float64(sin(k) * t_m) / l)) * Float64(Float64(t_m / l) * Float64(2.0 * k)))); elseif (k <= 1300.0) tmp = Float64(2.0 / Float64(Float64(t_m / l) * Float64(Float64(fma(Float64(fma(0.3333333333333333, Float64(t_m * t_m), 1.0) * k), k, Float64(Float64(t_m * t_m) * 2.0)) / l) * Float64(k * k)))); else tmp = Float64(2.0 / Float64(k * Float64(Float64(t_m * k) * Float64(tan(k) * Float64(sin(k) / 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[k, 2.85e-124], N[(2.0 / N[(N[(t$95$m * N[(N[(N[Sin[k], $MachinePrecision] * t$95$m), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision] * N[(N[(t$95$m / l), $MachinePrecision] * N[(2.0 * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 1300.0], N[(2.0 / N[(N[(t$95$m / l), $MachinePrecision] * N[(N[(N[(N[(N[(0.3333333333333333 * N[(t$95$m * t$95$m), $MachinePrecision] + 1.0), $MachinePrecision] * k), $MachinePrecision] * k + N[(N[(t$95$m * t$95$m), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision] * N[(k * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(k * N[(N[(t$95$m * k), $MachinePrecision] * N[(N[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] / N[(l * l), $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}\;k \leq 2.85 \cdot 10^{-124}:\\
\;\;\;\;\frac{2}{\left(t\_m \cdot \frac{\sin k \cdot t\_m}{\ell}\right) \cdot \left(\frac{t\_m}{\ell} \cdot \left(2 \cdot k\right)\right)}\\
\mathbf{elif}\;k \leq 1300:\\
\;\;\;\;\frac{2}{\frac{t\_m}{\ell} \cdot \left(\frac{\mathsf{fma}\left(\mathsf{fma}\left(0.3333333333333333, t\_m \cdot t\_m, 1\right) \cdot k, k, \left(t\_m \cdot t\_m\right) \cdot 2\right)}{\ell} \cdot \left(k \cdot k\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{k \cdot \left(\left(t\_m \cdot k\right) \cdot \left(\tan k \cdot \frac{\sin k}{\ell \cdot \ell}\right)\right)}\\
\end{array}
\end{array}
if k < 2.84999999999999988e-124Initial program 53.6%
lift-*.f64N/A
*-commutativeN/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-/.f6474.8
Applied rewrites74.8%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
lift-*.f64N/A
associate-*r*N/A
associate-*l*N/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lift-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites82.9%
lift-*.f64N/A
lift-/.f64N/A
associate-*l/N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f6482.9
lift-*.f64N/A
*-commutativeN/A
lower-*.f6482.9
Applied rewrites82.9%
Taylor expanded in k around 0
lower-*.f6471.0
Applied rewrites71.0%
if 2.84999999999999988e-124 < k < 1300Initial program 67.6%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
associate-*l*N/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
Applied rewrites83.2%
Taylor expanded in k around 0
*-commutativeN/A
lower-*.f64N/A
Applied rewrites99.7%
if 1300 < k Initial program 48.6%
Taylor expanded in t around 0
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-sin.f64N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-cos.f6476.0
Applied rewrites76.0%
Applied rewrites83.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) t_m)))
(*
t_s
(if (<= k 2.85e-124)
(/ 2.0 (* (* t_m (/ t_2 l)) (* (/ t_m l) (* 2.0 k))))
(if (<= k 1300.0)
(/
2.0
(*
(/ t_m l)
(*
(/
(fma
(* (fma 0.3333333333333333 (* t_m t_m) 1.0) k)
k
(* (* t_m t_m) 2.0))
l)
(* k k))))
(/ 2.0 (* k (* k (/ (* t_2 (tan k)) (* 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 t_2 = sin(k) * t_m;
double tmp;
if (k <= 2.85e-124) {
tmp = 2.0 / ((t_m * (t_2 / l)) * ((t_m / l) * (2.0 * k)));
} else if (k <= 1300.0) {
tmp = 2.0 / ((t_m / l) * ((fma((fma(0.3333333333333333, (t_m * t_m), 1.0) * k), k, ((t_m * t_m) * 2.0)) / l) * (k * k)));
} else {
tmp = 2.0 / (k * (k * ((t_2 * tan(k)) / (l * l))));
}
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) * t_m) tmp = 0.0 if (k <= 2.85e-124) tmp = Float64(2.0 / Float64(Float64(t_m * Float64(t_2 / l)) * Float64(Float64(t_m / l) * Float64(2.0 * k)))); elseif (k <= 1300.0) tmp = Float64(2.0 / Float64(Float64(t_m / l) * Float64(Float64(fma(Float64(fma(0.3333333333333333, Float64(t_m * t_m), 1.0) * k), k, Float64(Float64(t_m * t_m) * 2.0)) / l) * Float64(k * k)))); else tmp = Float64(2.0 / Float64(k * Float64(k * Float64(Float64(t_2 * tan(k)) / 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_] := Block[{t$95$2 = N[(N[Sin[k], $MachinePrecision] * t$95$m), $MachinePrecision]}, N[(t$95$s * If[LessEqual[k, 2.85e-124], N[(2.0 / N[(N[(t$95$m * N[(t$95$2 / l), $MachinePrecision]), $MachinePrecision] * N[(N[(t$95$m / l), $MachinePrecision] * N[(2.0 * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 1300.0], N[(2.0 / N[(N[(t$95$m / l), $MachinePrecision] * N[(N[(N[(N[(N[(0.3333333333333333 * N[(t$95$m * t$95$m), $MachinePrecision] + 1.0), $MachinePrecision] * k), $MachinePrecision] * k + N[(N[(t$95$m * t$95$m), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision] * N[(k * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(k * N[(k * N[(N[(t$95$2 * N[Tan[k], $MachinePrecision]), $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)
\\
\begin{array}{l}
t_2 := \sin k \cdot t\_m\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 2.85 \cdot 10^{-124}:\\
\;\;\;\;\frac{2}{\left(t\_m \cdot \frac{t\_2}{\ell}\right) \cdot \left(\frac{t\_m}{\ell} \cdot \left(2 \cdot k\right)\right)}\\
\mathbf{elif}\;k \leq 1300:\\
\;\;\;\;\frac{2}{\frac{t\_m}{\ell} \cdot \left(\frac{\mathsf{fma}\left(\mathsf{fma}\left(0.3333333333333333, t\_m \cdot t\_m, 1\right) \cdot k, k, \left(t\_m \cdot t\_m\right) \cdot 2\right)}{\ell} \cdot \left(k \cdot k\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{k \cdot \left(k \cdot \frac{t\_2 \cdot \tan k}{\ell \cdot \ell}\right)}\\
\end{array}
\end{array}
\end{array}
if k < 2.84999999999999988e-124Initial program 53.6%
lift-*.f64N/A
*-commutativeN/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-/.f6474.8
Applied rewrites74.8%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
lift-*.f64N/A
associate-*r*N/A
associate-*l*N/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lift-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites82.9%
lift-*.f64N/A
lift-/.f64N/A
associate-*l/N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f6482.9
lift-*.f64N/A
*-commutativeN/A
lower-*.f6482.9
Applied rewrites82.9%
Taylor expanded in k around 0
lower-*.f6471.0
Applied rewrites71.0%
if 2.84999999999999988e-124 < k < 1300Initial program 67.6%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
associate-*l*N/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
Applied rewrites83.2%
Taylor expanded in k around 0
*-commutativeN/A
lower-*.f64N/A
Applied rewrites99.7%
if 1300 < k Initial program 48.6%
Taylor expanded in t around 0
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-sin.f64N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-cos.f6476.0
Applied rewrites76.0%
Applied rewrites78.2%
Applied rewrites78.3%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= k 2.85e-124)
(/ 2.0 (* (* t_m (/ (* (sin k) t_m) l)) (* (/ t_m l) (* 2.0 k))))
(if (<= k 1300.0)
(/
2.0
(*
(/ t_m l)
(*
(/
(fma
(* (fma 0.3333333333333333 (* t_m t_m) 1.0) k)
k
(* (* t_m t_m) 2.0))
l)
(* k k))))
(/ 2.0 (* k (* k (* (* (tan k) (/ (sin k) (* l l))) 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 <= 2.85e-124) {
tmp = 2.0 / ((t_m * ((sin(k) * t_m) / l)) * ((t_m / l) * (2.0 * k)));
} else if (k <= 1300.0) {
tmp = 2.0 / ((t_m / l) * ((fma((fma(0.3333333333333333, (t_m * t_m), 1.0) * k), k, ((t_m * t_m) * 2.0)) / l) * (k * k)));
} else {
tmp = 2.0 / (k * (k * ((tan(k) * (sin(k) / (l * l))) * 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 <= 2.85e-124) tmp = Float64(2.0 / Float64(Float64(t_m * Float64(Float64(sin(k) * t_m) / l)) * Float64(Float64(t_m / l) * Float64(2.0 * k)))); elseif (k <= 1300.0) tmp = Float64(2.0 / Float64(Float64(t_m / l) * Float64(Float64(fma(Float64(fma(0.3333333333333333, Float64(t_m * t_m), 1.0) * k), k, Float64(Float64(t_m * t_m) * 2.0)) / l) * Float64(k * k)))); else tmp = Float64(2.0 / Float64(k * Float64(k * Float64(Float64(tan(k) * Float64(sin(k) / Float64(l * l))) * t_m)))); 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.85e-124], N[(2.0 / N[(N[(t$95$m * N[(N[(N[Sin[k], $MachinePrecision] * t$95$m), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision] * N[(N[(t$95$m / l), $MachinePrecision] * N[(2.0 * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 1300.0], N[(2.0 / N[(N[(t$95$m / l), $MachinePrecision] * N[(N[(N[(N[(N[(0.3333333333333333 * N[(t$95$m * t$95$m), $MachinePrecision] + 1.0), $MachinePrecision] * k), $MachinePrecision] * k + N[(N[(t$95$m * t$95$m), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision] * N[(k * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(k * N[(k * N[(N[(N[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * t$95$m), $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.85 \cdot 10^{-124}:\\
\;\;\;\;\frac{2}{\left(t\_m \cdot \frac{\sin k \cdot t\_m}{\ell}\right) \cdot \left(\frac{t\_m}{\ell} \cdot \left(2 \cdot k\right)\right)}\\
\mathbf{elif}\;k \leq 1300:\\
\;\;\;\;\frac{2}{\frac{t\_m}{\ell} \cdot \left(\frac{\mathsf{fma}\left(\mathsf{fma}\left(0.3333333333333333, t\_m \cdot t\_m, 1\right) \cdot k, k, \left(t\_m \cdot t\_m\right) \cdot 2\right)}{\ell} \cdot \left(k \cdot k\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{k \cdot \left(k \cdot \left(\left(\tan k \cdot \frac{\sin k}{\ell \cdot \ell}\right) \cdot t\_m\right)\right)}\\
\end{array}
\end{array}
if k < 2.84999999999999988e-124Initial program 53.6%
lift-*.f64N/A
*-commutativeN/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-/.f6474.8
Applied rewrites74.8%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
lift-*.f64N/A
associate-*r*N/A
associate-*l*N/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lift-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites82.9%
lift-*.f64N/A
lift-/.f64N/A
associate-*l/N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f6482.9
lift-*.f64N/A
*-commutativeN/A
lower-*.f6482.9
Applied rewrites82.9%
Taylor expanded in k around 0
lower-*.f6471.0
Applied rewrites71.0%
if 2.84999999999999988e-124 < k < 1300Initial program 67.6%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
associate-*l*N/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
Applied rewrites83.2%
Taylor expanded in k around 0
*-commutativeN/A
lower-*.f64N/A
Applied rewrites99.7%
if 1300 < k Initial program 48.6%
Taylor expanded in t around 0
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-sin.f64N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-cos.f6476.0
Applied rewrites76.0%
Applied rewrites78.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 2.85e-124)
(/ 2.0 (* (* t_m (/ (* (sin k) t_m) l)) (* (/ t_m l) (* 2.0 k))))
(/
2.0
(*
(/ t_m l)
(*
(/
(fma
(* (fma 0.3333333333333333 (* t_m t_m) 1.0) k)
k
(* (* t_m t_m) 2.0))
l)
(* k 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 (k <= 2.85e-124) {
tmp = 2.0 / ((t_m * ((sin(k) * t_m) / l)) * ((t_m / l) * (2.0 * k)));
} else {
tmp = 2.0 / ((t_m / l) * ((fma((fma(0.3333333333333333, (t_m * t_m), 1.0) * k), k, ((t_m * t_m) * 2.0)) / l) * (k * 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 (k <= 2.85e-124) tmp = Float64(2.0 / Float64(Float64(t_m * Float64(Float64(sin(k) * t_m) / l)) * Float64(Float64(t_m / l) * Float64(2.0 * k)))); else tmp = Float64(2.0 / Float64(Float64(t_m / l) * Float64(Float64(fma(Float64(fma(0.3333333333333333, Float64(t_m * t_m), 1.0) * k), k, Float64(Float64(t_m * t_m) * 2.0)) / l) * Float64(k * k)))); 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.85e-124], N[(2.0 / N[(N[(t$95$m * N[(N[(N[Sin[k], $MachinePrecision] * t$95$m), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision] * N[(N[(t$95$m / l), $MachinePrecision] * N[(2.0 * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(t$95$m / l), $MachinePrecision] * N[(N[(N[(N[(N[(0.3333333333333333 * N[(t$95$m * t$95$m), $MachinePrecision] + 1.0), $MachinePrecision] * k), $MachinePrecision] * k + N[(N[(t$95$m * t$95$m), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision] * N[(k * k), $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.85 \cdot 10^{-124}:\\
\;\;\;\;\frac{2}{\left(t\_m \cdot \frac{\sin k \cdot t\_m}{\ell}\right) \cdot \left(\frac{t\_m}{\ell} \cdot \left(2 \cdot k\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\frac{t\_m}{\ell} \cdot \left(\frac{\mathsf{fma}\left(\mathsf{fma}\left(0.3333333333333333, t\_m \cdot t\_m, 1\right) \cdot k, k, \left(t\_m \cdot t\_m\right) \cdot 2\right)}{\ell} \cdot \left(k \cdot k\right)\right)}\\
\end{array}
\end{array}
if k < 2.84999999999999988e-124Initial program 53.6%
lift-*.f64N/A
*-commutativeN/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-/.f6474.8
Applied rewrites74.8%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
lift-*.f64N/A
associate-*r*N/A
associate-*l*N/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lift-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites82.9%
lift-*.f64N/A
lift-/.f64N/A
associate-*l/N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f6482.9
lift-*.f64N/A
*-commutativeN/A
lower-*.f6482.9
Applied rewrites82.9%
Taylor expanded in k around 0
lower-*.f6471.0
Applied rewrites71.0%
if 2.84999999999999988e-124 < k Initial program 54.4%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
associate-*l*N/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
Applied rewrites63.1%
Taylor expanded in k around 0
*-commutativeN/A
lower-*.f64N/A
Applied rewrites71.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 2.5e-29)
(/ (* (/ l (* t_m t_m)) (/ l k)) (* t_m k))
(/ 2.0 (* (* (* k k) t_m) (* (pow (* l l) -1.0) (* k 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 (k <= 2.5e-29) {
tmp = ((l / (t_m * t_m)) * (l / k)) / (t_m * k);
} else {
tmp = 2.0 / (((k * k) * t_m) * (pow((l * l), -1.0) * (k * 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 (k <= 2.5d-29) then
tmp = ((l / (t_m * t_m)) * (l / k)) / (t_m * k)
else
tmp = 2.0d0 / (((k * k) * t_m) * (((l * l) ** (-1.0d0)) * (k * 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 (k <= 2.5e-29) {
tmp = ((l / (t_m * t_m)) * (l / k)) / (t_m * k);
} else {
tmp = 2.0 / (((k * k) * t_m) * (Math.pow((l * l), -1.0) * (k * 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 k <= 2.5e-29: tmp = ((l / (t_m * t_m)) * (l / k)) / (t_m * k) else: tmp = 2.0 / (((k * k) * t_m) * (math.pow((l * l), -1.0) * (k * 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 (k <= 2.5e-29) tmp = Float64(Float64(Float64(l / Float64(t_m * t_m)) * Float64(l / k)) / Float64(t_m * k)); else tmp = Float64(2.0 / Float64(Float64(Float64(k * k) * t_m) * Float64((Float64(l * l) ^ -1.0) * Float64(k * 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 (k <= 2.5e-29) tmp = ((l / (t_m * t_m)) * (l / k)) / (t_m * k); else tmp = 2.0 / (((k * k) * t_m) * (((l * l) ^ -1.0) * (k * 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[k, 2.5e-29], N[(N[(N[(l / N[(t$95$m * t$95$m), $MachinePrecision]), $MachinePrecision] * N[(l / k), $MachinePrecision]), $MachinePrecision] / N[(t$95$m * k), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision] * N[(N[Power[N[(l * l), $MachinePrecision], -1.0], $MachinePrecision] * N[(k * k), $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.5 \cdot 10^{-29}:\\
\;\;\;\;\frac{\frac{\ell}{t\_m \cdot t\_m} \cdot \frac{\ell}{k}}{t\_m \cdot k}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(\left(k \cdot k\right) \cdot t\_m\right) \cdot \left({\left(\ell \cdot \ell\right)}^{-1} \cdot \left(k \cdot k\right)\right)}\\
\end{array}
\end{array}
if k < 2.49999999999999993e-29Initial program 54.2%
Taylor expanded in k around 0
unpow2N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6456.8
Applied rewrites56.8%
Applied rewrites56.8%
Applied rewrites63.5%
if 2.49999999999999993e-29 < k Initial program 52.7%
Taylor expanded in t around 0
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-sin.f64N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-cos.f6477.8
Applied rewrites77.8%
Taylor expanded in k around 0
Applied rewrites62.7%
Taylor expanded in k around 0
Applied rewrites62.8%
Final simplification63.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 1.05e+18)
(/
2.0
(*
(/ t_m l)
(*
(/
(fma
(* (fma 0.3333333333333333 (* t_m t_m) 1.0) k)
k
(* (* t_m t_m) 2.0))
l)
(* k k))))
(* (/ l t_m) (/ l (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 <= 1.05e+18) {
tmp = 2.0 / ((t_m / l) * ((fma((fma(0.3333333333333333, (t_m * t_m), 1.0) * k), k, ((t_m * t_m) * 2.0)) / l) * (k * k)));
} else {
tmp = (l / t_m) * (l / 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 <= 1.05e+18) tmp = Float64(2.0 / Float64(Float64(t_m / l) * Float64(Float64(fma(Float64(fma(0.3333333333333333, Float64(t_m * t_m), 1.0) * k), k, Float64(Float64(t_m * t_m) * 2.0)) / l) * Float64(k * k)))); else tmp = Float64(Float64(l / t_m) * Float64(l / (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, 1.05e+18], N[(2.0 / N[(N[(t$95$m / l), $MachinePrecision] * N[(N[(N[(N[(N[(0.3333333333333333 * N[(t$95$m * t$95$m), $MachinePrecision] + 1.0), $MachinePrecision] * k), $MachinePrecision] * k + N[(N[(t$95$m * t$95$m), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision] * N[(k * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(l / t$95$m), $MachinePrecision] * N[(l / 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 1.05 \cdot 10^{+18}:\\
\;\;\;\;\frac{2}{\frac{t\_m}{\ell} \cdot \left(\frac{\mathsf{fma}\left(\mathsf{fma}\left(0.3333333333333333, t\_m \cdot t\_m, 1\right) \cdot k, k, \left(t\_m \cdot t\_m\right) \cdot 2\right)}{\ell} \cdot \left(k \cdot k\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{\ell}{t\_m} \cdot \frac{\ell}{{\left(k \cdot t\_m\right)}^{2}}\\
\end{array}
\end{array}
if t < 1.05e18Initial program 51.6%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
associate-*l*N/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
Applied rewrites61.5%
Taylor expanded in k around 0
*-commutativeN/A
lower-*.f64N/A
Applied rewrites70.2%
if 1.05e18 < t Initial program 63.3%
Taylor expanded in k around 0
unpow2N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6451.8
Applied rewrites51.8%
Applied rewrites61.9%
Applied rewrites54.4%
Applied rewrites75.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 4e+17)
(/
2.0
(*
(/ t_m l)
(*
(/
(fma
(* (fma 0.3333333333333333 (* t_m t_m) 1.0) k)
k
(* (* t_m t_m) 2.0))
l)
(* k k))))
(* l (/ (/ l t_m) (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 <= 4e+17) {
tmp = 2.0 / ((t_m / l) * ((fma((fma(0.3333333333333333, (t_m * t_m), 1.0) * k), k, ((t_m * t_m) * 2.0)) / l) * (k * k)));
} else {
tmp = l * ((l / t_m) / 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 <= 4e+17) tmp = Float64(2.0 / Float64(Float64(t_m / l) * Float64(Float64(fma(Float64(fma(0.3333333333333333, Float64(t_m * t_m), 1.0) * k), k, Float64(Float64(t_m * t_m) * 2.0)) / l) * Float64(k * k)))); else tmp = Float64(l * Float64(Float64(l / t_m) / (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, 4e+17], N[(2.0 / N[(N[(t$95$m / l), $MachinePrecision] * N[(N[(N[(N[(N[(0.3333333333333333 * N[(t$95$m * t$95$m), $MachinePrecision] + 1.0), $MachinePrecision] * k), $MachinePrecision] * k + N[(N[(t$95$m * t$95$m), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision] * N[(k * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(l * N[(N[(l / t$95$m), $MachinePrecision] / 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 4 \cdot 10^{+17}:\\
\;\;\;\;\frac{2}{\frac{t\_m}{\ell} \cdot \left(\frac{\mathsf{fma}\left(\mathsf{fma}\left(0.3333333333333333, t\_m \cdot t\_m, 1\right) \cdot k, k, \left(t\_m \cdot t\_m\right) \cdot 2\right)}{\ell} \cdot \left(k \cdot k\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\ell \cdot \frac{\frac{\ell}{t\_m}}{{\left(k \cdot t\_m\right)}^{2}}\\
\end{array}
\end{array}
if t < 4e17Initial program 51.6%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
associate-*l*N/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
Applied rewrites61.5%
Taylor expanded in k around 0
*-commutativeN/A
lower-*.f64N/A
Applied rewrites70.2%
if 4e17 < t Initial program 63.3%
Taylor expanded in k around 0
unpow2N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6451.8
Applied rewrites51.8%
Applied rewrites61.9%
Applied rewrites54.4%
Applied rewrites75.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 2.1e-160)
(* l (/ l (* t_m (pow (* t_m k) 2.0))))
(/
2.0
(*
(/ t_m l)
(*
(/
(fma
(* (fma 0.3333333333333333 (* t_m t_m) 1.0) k)
k
(* (* t_m t_m) 2.0))
l)
(* k 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 (k <= 2.1e-160) {
tmp = l * (l / (t_m * pow((t_m * k), 2.0)));
} else {
tmp = 2.0 / ((t_m / l) * ((fma((fma(0.3333333333333333, (t_m * t_m), 1.0) * k), k, ((t_m * t_m) * 2.0)) / l) * (k * 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 (k <= 2.1e-160) tmp = Float64(l * Float64(l / Float64(t_m * (Float64(t_m * k) ^ 2.0)))); else tmp = Float64(2.0 / Float64(Float64(t_m / l) * Float64(Float64(fma(Float64(fma(0.3333333333333333, Float64(t_m * t_m), 1.0) * k), k, Float64(Float64(t_m * t_m) * 2.0)) / l) * Float64(k * k)))); 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.1e-160], N[(l * N[(l / N[(t$95$m * N[Power[N[(t$95$m * k), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(t$95$m / l), $MachinePrecision] * N[(N[(N[(N[(N[(0.3333333333333333 * N[(t$95$m * t$95$m), $MachinePrecision] + 1.0), $MachinePrecision] * k), $MachinePrecision] * k + N[(N[(t$95$m * t$95$m), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision] * N[(k * k), $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.1 \cdot 10^{-160}:\\
\;\;\;\;\ell \cdot \frac{\ell}{t\_m \cdot {\left(t\_m \cdot k\right)}^{2}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\frac{t\_m}{\ell} \cdot \left(\frac{\mathsf{fma}\left(\mathsf{fma}\left(0.3333333333333333, t\_m \cdot t\_m, 1\right) \cdot k, k, \left(t\_m \cdot t\_m\right) \cdot 2\right)}{\ell} \cdot \left(k \cdot k\right)\right)}\\
\end{array}
\end{array}
if k < 2.1e-160Initial program 54.6%
Taylor expanded in k around 0
unpow2N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6454.2
Applied rewrites54.2%
Applied rewrites57.7%
Applied rewrites64.8%
if 2.1e-160 < k Initial program 52.4%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
associate-*l*N/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
Applied rewrites65.5%
Taylor expanded in k around 0
*-commutativeN/A
lower-*.f64N/A
Applied rewrites72.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 1.45e-158)
(/ (* (/ l (* t_m t_m)) (/ l k)) (* t_m k))
(/
2.0
(*
(/ t_m l)
(*
(/
(fma
(* (fma 0.3333333333333333 (* t_m t_m) 1.0) k)
k
(* (* t_m t_m) 2.0))
l)
(* k 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 (k <= 1.45e-158) {
tmp = ((l / (t_m * t_m)) * (l / k)) / (t_m * k);
} else {
tmp = 2.0 / ((t_m / l) * ((fma((fma(0.3333333333333333, (t_m * t_m), 1.0) * k), k, ((t_m * t_m) * 2.0)) / l) * (k * 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 (k <= 1.45e-158) tmp = Float64(Float64(Float64(l / Float64(t_m * t_m)) * Float64(l / k)) / Float64(t_m * k)); else tmp = Float64(2.0 / Float64(Float64(t_m / l) * Float64(Float64(fma(Float64(fma(0.3333333333333333, Float64(t_m * t_m), 1.0) * k), k, Float64(Float64(t_m * t_m) * 2.0)) / l) * Float64(k * k)))); 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, 1.45e-158], N[(N[(N[(l / N[(t$95$m * t$95$m), $MachinePrecision]), $MachinePrecision] * N[(l / k), $MachinePrecision]), $MachinePrecision] / N[(t$95$m * k), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(t$95$m / l), $MachinePrecision] * N[(N[(N[(N[(N[(0.3333333333333333 * N[(t$95$m * t$95$m), $MachinePrecision] + 1.0), $MachinePrecision] * k), $MachinePrecision] * k + N[(N[(t$95$m * t$95$m), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision] * N[(k * k), $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.45 \cdot 10^{-158}:\\
\;\;\;\;\frac{\frac{\ell}{t\_m \cdot t\_m} \cdot \frac{\ell}{k}}{t\_m \cdot k}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\frac{t\_m}{\ell} \cdot \left(\frac{\mathsf{fma}\left(\mathsf{fma}\left(0.3333333333333333, t\_m \cdot t\_m, 1\right) \cdot k, k, \left(t\_m \cdot t\_m\right) \cdot 2\right)}{\ell} \cdot \left(k \cdot k\right)\right)}\\
\end{array}
\end{array}
if k < 1.4499999999999999e-158Initial program 54.0%
Taylor expanded in k around 0
unpow2N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6454.2
Applied rewrites54.2%
Applied rewrites54.2%
Applied rewrites61.1%
if 1.4499999999999999e-158 < k Initial program 53.6%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
associate-*l*N/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
Applied rewrites65.8%
Taylor expanded in k around 0
*-commutativeN/A
lower-*.f64N/A
Applied rewrites73.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 (<= t_m 2e-37)
(/ 2.0 (* k (* k (* (/ (* k k) l) (/ t_m l)))))
(* l (/ l (* (* (* t_m t_m) k) (* k 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 (t_m <= 2e-37) {
tmp = 2.0 / (k * (k * (((k * k) / l) * (t_m / l))));
} else {
tmp = l * (l / (((t_m * t_m) * k) * (k * 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 (t_m <= 2d-37) then
tmp = 2.0d0 / (k * (k * (((k * k) / l) * (t_m / l))))
else
tmp = l * (l / (((t_m * t_m) * k) * (k * 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 (t_m <= 2e-37) {
tmp = 2.0 / (k * (k * (((k * k) / l) * (t_m / l))));
} else {
tmp = l * (l / (((t_m * t_m) * k) * (k * 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 t_m <= 2e-37: tmp = 2.0 / (k * (k * (((k * k) / l) * (t_m / l)))) else: tmp = l * (l / (((t_m * t_m) * k) * (k * 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 (t_m <= 2e-37) tmp = Float64(2.0 / Float64(k * Float64(k * Float64(Float64(Float64(k * k) / l) * Float64(t_m / l))))); else tmp = Float64(l * Float64(l / Float64(Float64(Float64(t_m * t_m) * k) * Float64(k * 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 (t_m <= 2e-37) tmp = 2.0 / (k * (k * (((k * k) / l) * (t_m / l)))); else tmp = l * (l / (((t_m * t_m) * k) * (k * 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[t$95$m, 2e-37], N[(2.0 / N[(k * N[(k * N[(N[(N[(k * k), $MachinePrecision] / l), $MachinePrecision] * N[(t$95$m / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(l * N[(l / N[(N[(N[(t$95$m * t$95$m), $MachinePrecision] * k), $MachinePrecision] * N[(k * t$95$m), $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 \cdot 10^{-37}:\\
\;\;\;\;\frac{2}{k \cdot \left(k \cdot \left(\frac{k \cdot k}{\ell} \cdot \frac{t\_m}{\ell}\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\ell \cdot \frac{\ell}{\left(\left(t\_m \cdot t\_m\right) \cdot k\right) \cdot \left(k \cdot t\_m\right)}\\
\end{array}
\end{array}
if t < 2.00000000000000013e-37Initial program 51.0%
Taylor expanded in t around 0
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-sin.f64N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-cos.f6467.6
Applied rewrites67.6%
Applied rewrites71.2%
Taylor expanded in k around 0
Applied rewrites62.5%
if 2.00000000000000013e-37 < t Initial program 63.5%
Taylor expanded in k around 0
unpow2N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6457.6
Applied rewrites57.6%
Applied rewrites65.5%
Applied rewrites59.0%
Applied rewrites69.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 1e+19)
(/ (* (/ l (* t_m t_m)) (/ l k)) (* t_m k))
(if (<= k 7e+137)
(* (/ l (* (* (- t_m) t_m) t_m)) (/ l (* k k)))
(* l (/ l (* (* (* (* k k) t_m) t_m) 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 <= 1e+19) {
tmp = ((l / (t_m * t_m)) * (l / k)) / (t_m * k);
} else if (k <= 7e+137) {
tmp = (l / ((-t_m * t_m) * t_m)) * (l / (k * k));
} else {
tmp = l * (l / ((((k * k) * t_m) * t_m) * 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 <= 1d+19) then
tmp = ((l / (t_m * t_m)) * (l / k)) / (t_m * k)
else if (k <= 7d+137) then
tmp = (l / ((-t_m * t_m) * t_m)) * (l / (k * k))
else
tmp = l * (l / ((((k * k) * t_m) * t_m) * 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 <= 1e+19) {
tmp = ((l / (t_m * t_m)) * (l / k)) / (t_m * k);
} else if (k <= 7e+137) {
tmp = (l / ((-t_m * t_m) * t_m)) * (l / (k * k));
} else {
tmp = l * (l / ((((k * k) * t_m) * t_m) * 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 <= 1e+19: tmp = ((l / (t_m * t_m)) * (l / k)) / (t_m * k) elif k <= 7e+137: tmp = (l / ((-t_m * t_m) * t_m)) * (l / (k * k)) else: tmp = l * (l / ((((k * k) * t_m) * t_m) * 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 <= 1e+19) tmp = Float64(Float64(Float64(l / Float64(t_m * t_m)) * Float64(l / k)) / Float64(t_m * k)); elseif (k <= 7e+137) tmp = Float64(Float64(l / Float64(Float64(Float64(-t_m) * t_m) * t_m)) * Float64(l / Float64(k * k))); else tmp = Float64(l * Float64(l / Float64(Float64(Float64(Float64(k * k) * t_m) * t_m) * 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 <= 1e+19) tmp = ((l / (t_m * t_m)) * (l / k)) / (t_m * k); elseif (k <= 7e+137) tmp = (l / ((-t_m * t_m) * t_m)) * (l / (k * k)); else tmp = l * (l / ((((k * k) * t_m) * t_m) * 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, 1e+19], N[(N[(N[(l / N[(t$95$m * t$95$m), $MachinePrecision]), $MachinePrecision] * N[(l / k), $MachinePrecision]), $MachinePrecision] / N[(t$95$m * k), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 7e+137], N[(N[(l / N[(N[((-t$95$m) * t$95$m), $MachinePrecision] * t$95$m), $MachinePrecision]), $MachinePrecision] * N[(l / N[(k * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(l * N[(l / N[(N[(N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision] * t$95$m), $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 10^{+19}:\\
\;\;\;\;\frac{\frac{\ell}{t\_m \cdot t\_m} \cdot \frac{\ell}{k}}{t\_m \cdot k}\\
\mathbf{elif}\;k \leq 7 \cdot 10^{+137}:\\
\;\;\;\;\frac{\ell}{\left(\left(-t\_m\right) \cdot t\_m\right) \cdot t\_m} \cdot \frac{\ell}{k \cdot k}\\
\mathbf{else}:\\
\;\;\;\;\ell \cdot \frac{\ell}{\left(\left(\left(k \cdot k\right) \cdot t\_m\right) \cdot t\_m\right) \cdot t\_m}\\
\end{array}
\end{array}
if k < 1e19Initial program 55.0%
Taylor expanded in k around 0
unpow2N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6456.7
Applied rewrites56.7%
Applied rewrites56.7%
Applied rewrites63.3%
if 1e19 < k < 7.0000000000000002e137Initial program 52.8%
Taylor expanded in k around 0
unpow2N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6444.2
Applied rewrites44.2%
Applied rewrites49.1%
if 7.0000000000000002e137 < k Initial program 47.1%
Taylor expanded in k around 0
unpow2N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6447.3
Applied rewrites47.3%
Applied rewrites44.9%
Applied rewrites47.5%
Applied rewrites61.4%
Final simplification61.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 1e+19)
(* l (/ l (* (* (* t_m t_m) k) (* k t_m))))
(if (<= k 7e+137)
(* (/ l (* (* (- t_m) t_m) t_m)) (/ l (* k k)))
(* l (/ l (* (* (* (* k k) t_m) t_m) 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 <= 1e+19) {
tmp = l * (l / (((t_m * t_m) * k) * (k * t_m)));
} else if (k <= 7e+137) {
tmp = (l / ((-t_m * t_m) * t_m)) * (l / (k * k));
} else {
tmp = l * (l / ((((k * k) * t_m) * t_m) * 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 <= 1d+19) then
tmp = l * (l / (((t_m * t_m) * k) * (k * t_m)))
else if (k <= 7d+137) then
tmp = (l / ((-t_m * t_m) * t_m)) * (l / (k * k))
else
tmp = l * (l / ((((k * k) * t_m) * t_m) * 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 <= 1e+19) {
tmp = l * (l / (((t_m * t_m) * k) * (k * t_m)));
} else if (k <= 7e+137) {
tmp = (l / ((-t_m * t_m) * t_m)) * (l / (k * k));
} else {
tmp = l * (l / ((((k * k) * t_m) * t_m) * 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 <= 1e+19: tmp = l * (l / (((t_m * t_m) * k) * (k * t_m))) elif k <= 7e+137: tmp = (l / ((-t_m * t_m) * t_m)) * (l / (k * k)) else: tmp = l * (l / ((((k * k) * t_m) * t_m) * 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 <= 1e+19) tmp = Float64(l * Float64(l / Float64(Float64(Float64(t_m * t_m) * k) * Float64(k * t_m)))); elseif (k <= 7e+137) tmp = Float64(Float64(l / Float64(Float64(Float64(-t_m) * t_m) * t_m)) * Float64(l / Float64(k * k))); else tmp = Float64(l * Float64(l / Float64(Float64(Float64(Float64(k * k) * t_m) * t_m) * 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 <= 1e+19) tmp = l * (l / (((t_m * t_m) * k) * (k * t_m))); elseif (k <= 7e+137) tmp = (l / ((-t_m * t_m) * t_m)) * (l / (k * k)); else tmp = l * (l / ((((k * k) * t_m) * t_m) * 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, 1e+19], N[(l * N[(l / N[(N[(N[(t$95$m * t$95$m), $MachinePrecision] * k), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 7e+137], N[(N[(l / N[(N[((-t$95$m) * t$95$m), $MachinePrecision] * t$95$m), $MachinePrecision]), $MachinePrecision] * N[(l / N[(k * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(l * N[(l / N[(N[(N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision] * t$95$m), $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 10^{+19}:\\
\;\;\;\;\ell \cdot \frac{\ell}{\left(\left(t\_m \cdot t\_m\right) \cdot k\right) \cdot \left(k \cdot t\_m\right)}\\
\mathbf{elif}\;k \leq 7 \cdot 10^{+137}:\\
\;\;\;\;\frac{\ell}{\left(\left(-t\_m\right) \cdot t\_m\right) \cdot t\_m} \cdot \frac{\ell}{k \cdot k}\\
\mathbf{else}:\\
\;\;\;\;\ell \cdot \frac{\ell}{\left(\left(\left(k \cdot k\right) \cdot t\_m\right) \cdot t\_m\right) \cdot t\_m}\\
\end{array}
\end{array}
if k < 1e19Initial program 55.0%
Taylor expanded in k around 0
unpow2N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6456.7
Applied rewrites56.7%
Applied rewrites59.2%
Applied rewrites57.6%
Applied rewrites61.7%
if 1e19 < k < 7.0000000000000002e137Initial program 52.8%
Taylor expanded in k around 0
unpow2N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6444.2
Applied rewrites44.2%
Applied rewrites49.1%
if 7.0000000000000002e137 < k Initial program 47.1%
Taylor expanded in k around 0
unpow2N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6447.3
Applied rewrites47.3%
Applied rewrites44.9%
Applied rewrites47.5%
Applied rewrites61.4%
Final simplification60.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 1e+19)
(* l (/ l (* (* (* t_m t_m) k) (* k t_m))))
(* l (/ (- l) (* (* t_m t_m) (* t_m (* k 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 (k <= 1e+19) {
tmp = l * (l / (((t_m * t_m) * k) * (k * t_m)));
} else {
tmp = l * (-l / ((t_m * t_m) * (t_m * (k * 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 (k <= 1d+19) then
tmp = l * (l / (((t_m * t_m) * k) * (k * t_m)))
else
tmp = l * (-l / ((t_m * t_m) * (t_m * (k * 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 (k <= 1e+19) {
tmp = l * (l / (((t_m * t_m) * k) * (k * t_m)));
} else {
tmp = l * (-l / ((t_m * t_m) * (t_m * (k * 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 k <= 1e+19: tmp = l * (l / (((t_m * t_m) * k) * (k * t_m))) else: tmp = l * (-l / ((t_m * t_m) * (t_m * (k * 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 (k <= 1e+19) tmp = Float64(l * Float64(l / Float64(Float64(Float64(t_m * t_m) * k) * Float64(k * t_m)))); else tmp = Float64(l * Float64(Float64(-l) / Float64(Float64(t_m * t_m) * Float64(t_m * Float64(k * 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 (k <= 1e+19) tmp = l * (l / (((t_m * t_m) * k) * (k * t_m))); else tmp = l * (-l / ((t_m * t_m) * (t_m * (k * 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[k, 1e+19], N[(l * N[(l / N[(N[(N[(t$95$m * t$95$m), $MachinePrecision] * k), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(l * N[((-l) / N[(N[(t$95$m * t$95$m), $MachinePrecision] * N[(t$95$m * N[(k * k), $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}\;k \leq 10^{+19}:\\
\;\;\;\;\ell \cdot \frac{\ell}{\left(\left(t\_m \cdot t\_m\right) \cdot k\right) \cdot \left(k \cdot t\_m\right)}\\
\mathbf{else}:\\
\;\;\;\;\ell \cdot \frac{-\ell}{\left(t\_m \cdot t\_m\right) \cdot \left(t\_m \cdot \left(k \cdot k\right)\right)}\\
\end{array}
\end{array}
if k < 1e19Initial program 55.0%
Taylor expanded in k around 0
unpow2N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6456.7
Applied rewrites56.7%
Applied rewrites59.2%
Applied rewrites57.6%
Applied rewrites61.7%
if 1e19 < k Initial program 49.4%
Taylor expanded in k around 0
unpow2N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6446.0
Applied rewrites46.0%
Applied rewrites44.6%
Applied rewrites48.2%
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 1e-127)
(* l (/ l (* (* (* t_m t_m) (* k t_m)) k)))
(* l (/ l (* (* (* (* k k) t_m) t_m) 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 <= 1e-127) {
tmp = l * (l / (((t_m * t_m) * (k * t_m)) * k));
} else {
tmp = l * (l / ((((k * k) * t_m) * t_m) * 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 <= 1d-127) then
tmp = l * (l / (((t_m * t_m) * (k * t_m)) * k))
else
tmp = l * (l / ((((k * k) * t_m) * t_m) * 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 <= 1e-127) {
tmp = l * (l / (((t_m * t_m) * (k * t_m)) * k));
} else {
tmp = l * (l / ((((k * k) * t_m) * t_m) * 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 <= 1e-127: tmp = l * (l / (((t_m * t_m) * (k * t_m)) * k)) else: tmp = l * (l / ((((k * k) * t_m) * t_m) * 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 <= 1e-127) tmp = Float64(l * Float64(l / Float64(Float64(Float64(t_m * t_m) * Float64(k * t_m)) * k))); else tmp = Float64(l * Float64(l / Float64(Float64(Float64(Float64(k * k) * t_m) * t_m) * 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 <= 1e-127) tmp = l * (l / (((t_m * t_m) * (k * t_m)) * k)); else tmp = l * (l / ((((k * k) * t_m) * t_m) * 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, 1e-127], N[(l * N[(l / N[(N[(N[(t$95$m * t$95$m), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(l * N[(l / N[(N[(N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision] * t$95$m), $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 10^{-127}:\\
\;\;\;\;\ell \cdot \frac{\ell}{\left(\left(t\_m \cdot t\_m\right) \cdot \left(k \cdot t\_m\right)\right) \cdot k}\\
\mathbf{else}:\\
\;\;\;\;\ell \cdot \frac{\ell}{\left(\left(\left(k \cdot k\right) \cdot t\_m\right) \cdot t\_m\right) \cdot t\_m}\\
\end{array}
\end{array}
if k < 1e-127Initial program 54.2%
Taylor expanded in k around 0
unpow2N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6455.4
Applied rewrites55.4%
Applied rewrites58.2%
Applied rewrites55.9%
Applied rewrites60.4%
if 1e-127 < k Initial program 53.2%
Taylor expanded in k around 0
unpow2N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6452.8
Applied rewrites52.8%
Applied rewrites52.0%
Applied rewrites54.2%
Applied rewrites60.6%
Final simplification60.5%
t\_m = (fabs.f64 t) t\_s = (copysign.f64 #s(literal 1 binary64) t) (FPCore (t_s t_m l k) :precision binary64 (* t_s (* l (/ l (* (* (* t_m t_m) k) (* k 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 / (((t_m * t_m) * k) * (k * 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 / (((t_m * t_m) * k) * (k * 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 / (((t_m * t_m) * k) * (k * 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 / (((t_m * t_m) * k) * (k * 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(l * Float64(l / Float64(Float64(Float64(t_m * t_m) * k) * Float64(k * 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 / (((t_m * t_m) * k) * (k * 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[(l * N[(l / N[(N[(N[(t$95$m * t$95$m), $MachinePrecision] * k), $MachinePrecision] * N[(k * t$95$m), $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 \cdot \frac{\ell}{\left(\left(t\_m \cdot t\_m\right) \cdot k\right) \cdot \left(k \cdot t\_m\right)}\right)
\end{array}
Initial program 53.9%
Taylor expanded in k around 0
unpow2N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6454.6
Applied rewrites54.6%
Applied rewrites56.3%
Applied rewrites55.3%
Applied rewrites58.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 (* l (/ l (* (* t_m t_m) (* t_m (* k k)))))))
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 / ((t_m * t_m) * (t_m * (k * k)))));
}
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 / ((t_m * t_m) * (t_m * (k * k)))))
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 / ((t_m * t_m) * (t_m * (k * k)))));
}
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 / ((t_m * t_m) * (t_m * (k * k)))))
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) return Float64(t_s * Float64(l * Float64(l / Float64(Float64(t_m * t_m) * Float64(t_m * Float64(k * k)))))) 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 / ((t_m * t_m) * (t_m * (k * k))))); 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[(l * N[(l / N[(N[(t$95$m * t$95$m), $MachinePrecision] * N[(t$95$m * N[(k * k), $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 \left(\ell \cdot \frac{\ell}{\left(t\_m \cdot t\_m\right) \cdot \left(t\_m \cdot \left(k \cdot k\right)\right)}\right)
\end{array}
Initial program 53.9%
Taylor expanded in k around 0
unpow2N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6454.6
Applied rewrites54.6%
Applied rewrites56.3%
Applied rewrites55.3%
herbie shell --seed 2024328
(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))))