
(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 28 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (t l k) :precision binary64 (/ 2.0 (* (* (* (/ (pow t 3.0) (* l l)) (sin k)) (tan k)) (+ (+ 1.0 (pow (/ k t) 2.0)) 1.0))))
double code(double t, double l, double k) {
return 2.0 / ((((pow(t, 3.0) / (l * l)) * sin(k)) * tan(k)) * ((1.0 + pow((k / t), 2.0)) + 1.0));
}
real(8) function code(t, l, k)
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: k
code = 2.0d0 / (((((t ** 3.0d0) / (l * l)) * sin(k)) * tan(k)) * ((1.0d0 + ((k / t) ** 2.0d0)) + 1.0d0))
end function
public static double code(double t, double l, double k) {
return 2.0 / ((((Math.pow(t, 3.0) / (l * l)) * Math.sin(k)) * Math.tan(k)) * ((1.0 + Math.pow((k / t), 2.0)) + 1.0));
}
def code(t, l, k): return 2.0 / ((((math.pow(t, 3.0) / (l * l)) * math.sin(k)) * math.tan(k)) * ((1.0 + math.pow((k / t), 2.0)) + 1.0))
function code(t, l, k) return Float64(2.0 / Float64(Float64(Float64(Float64((t ^ 3.0) / Float64(l * l)) * sin(k)) * tan(k)) * Float64(Float64(1.0 + (Float64(k / t) ^ 2.0)) + 1.0))) end
function tmp = code(t, l, k) tmp = 2.0 / (((((t ^ 3.0) / (l * l)) * sin(k)) * tan(k)) * ((1.0 + ((k / t) ^ 2.0)) + 1.0)); end
code[t_, l_, k_] := N[(2.0 / N[(N[(N[(N[(N[Power[t, 3.0], $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision] * N[Sin[k], $MachinePrecision]), $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * N[(N[(1.0 + N[Power[N[(k / t), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)}
\end{array}
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(let* ((t_2 (/ (pow t_m 1.5) l)))
(*
t_s
(if (<= t_m 2.3e-23)
(/ 2.0 (* (/ (* (* k k) t_m) (* (cos k) l)) (/ (pow (sin k) 2.0) l)))
(if (<= t_m 1.35e+205)
(/
2.0
(*
(* (* t_2 (* t_2 (sin k))) (tan k))
(+ (+ 1.0 (pow (/ k t_m) 2.0)) 1.0)))
(* (/ l (* (* k t_m) (* k t_m))) (/ 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 t_2 = pow(t_m, 1.5) / l;
double tmp;
if (t_m <= 2.3e-23) {
tmp = 2.0 / ((((k * k) * t_m) / (cos(k) * l)) * (pow(sin(k), 2.0) / l));
} else if (t_m <= 1.35e+205) {
tmp = 2.0 / (((t_2 * (t_2 * sin(k))) * tan(k)) * ((1.0 + pow((k / t_m), 2.0)) + 1.0));
} else {
tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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) :: t_2
real(8) :: tmp
t_2 = (t_m ** 1.5d0) / l
if (t_m <= 2.3d-23) then
tmp = 2.0d0 / ((((k * k) * t_m) / (cos(k) * l)) * ((sin(k) ** 2.0d0) / l))
else if (t_m <= 1.35d+205) then
tmp = 2.0d0 / (((t_2 * (t_2 * sin(k))) * tan(k)) * ((1.0d0 + ((k / t_m) ** 2.0d0)) + 1.0d0))
else
tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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 t_2 = Math.pow(t_m, 1.5) / l;
double tmp;
if (t_m <= 2.3e-23) {
tmp = 2.0 / ((((k * k) * t_m) / (Math.cos(k) * l)) * (Math.pow(Math.sin(k), 2.0) / l));
} else if (t_m <= 1.35e+205) {
tmp = 2.0 / (((t_2 * (t_2 * Math.sin(k))) * Math.tan(k)) * ((1.0 + Math.pow((k / t_m), 2.0)) + 1.0));
} else {
tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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): t_2 = math.pow(t_m, 1.5) / l tmp = 0 if t_m <= 2.3e-23: tmp = 2.0 / ((((k * k) * t_m) / (math.cos(k) * l)) * (math.pow(math.sin(k), 2.0) / l)) elif t_m <= 1.35e+205: tmp = 2.0 / (((t_2 * (t_2 * math.sin(k))) * math.tan(k)) * ((1.0 + math.pow((k / t_m), 2.0)) + 1.0)) else: tmp = (l / ((k * t_m) * (k * t_m))) * (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) t_2 = Float64((t_m ^ 1.5) / l) tmp = 0.0 if (t_m <= 2.3e-23) tmp = Float64(2.0 / Float64(Float64(Float64(Float64(k * k) * t_m) / Float64(cos(k) * l)) * Float64((sin(k) ^ 2.0) / l))); elseif (t_m <= 1.35e+205) tmp = Float64(2.0 / Float64(Float64(Float64(t_2 * Float64(t_2 * sin(k))) * tan(k)) * Float64(Float64(1.0 + (Float64(k / t_m) ^ 2.0)) + 1.0))); else tmp = Float64(Float64(l / Float64(Float64(k * t_m) * Float64(k * t_m))) * Float64(l / 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) t_2 = (t_m ^ 1.5) / l; tmp = 0.0; if (t_m <= 2.3e-23) tmp = 2.0 / ((((k * k) * t_m) / (cos(k) * l)) * ((sin(k) ^ 2.0) / l)); elseif (t_m <= 1.35e+205) tmp = 2.0 / (((t_2 * (t_2 * sin(k))) * tan(k)) * ((1.0 + ((k / t_m) ^ 2.0)) + 1.0)); else tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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_] := Block[{t$95$2 = N[(N[Power[t$95$m, 1.5], $MachinePrecision] / l), $MachinePrecision]}, N[(t$95$s * If[LessEqual[t$95$m, 2.3e-23], N[(2.0 / N[(N[(N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision] / N[(N[Cos[k], $MachinePrecision] * l), $MachinePrecision]), $MachinePrecision] * N[(N[Power[N[Sin[k], $MachinePrecision], 2.0], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 1.35e+205], N[(2.0 / N[(N[(N[(t$95$2 * N[(t$95$2 * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * N[(N[(1.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(l / N[(N[(k * t$95$m), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / t$95$m), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
\begin{array}{l}
t_2 := \frac{{t\_m}^{1.5}}{\ell}\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 2.3 \cdot 10^{-23}:\\
\;\;\;\;\frac{2}{\frac{\left(k \cdot k\right) \cdot t\_m}{\cos k \cdot \ell} \cdot \frac{{\sin k}^{2}}{\ell}}\\
\mathbf{elif}\;t\_m \leq 1.35 \cdot 10^{+205}:\\
\;\;\;\;\frac{2}{\left(\left(t\_2 \cdot \left(t\_2 \cdot \sin k\right)\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t\_m}\right)}^{2}\right) + 1\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{\ell}{\left(k \cdot t\_m\right) \cdot \left(k \cdot t\_m\right)} \cdot \frac{\ell}{t\_m}\\
\end{array}
\end{array}
\end{array}
if t < 2.3000000000000001e-23Initial program 49.7%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval22.5
Applied rewrites22.5%
Taylor expanded in t around 0
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
associate-*r/N/A
associate-/l*N/A
associate-*r*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
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-cos.f6464.8
Applied rewrites64.8%
Applied rewrites73.7%
if 2.3000000000000001e-23 < t < 1.35000000000000006e205Initial program 63.9%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval93.1
Applied rewrites93.1%
if 1.35000000000000006e205 < t Initial program 43.7%
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-*.f6450.3
Applied rewrites50.3%
Applied rewrites50.8%
Applied rewrites33.3%
Applied rewrites88.5%
Final simplification78.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 2.25e-23)
(/ 2.0 (* (/ (* (* k k) t_m) (* (cos k) l)) (/ (pow (sin k) 2.0) l)))
(if (<= t_m 8e+203)
(*
(/ (/ 2.0 t_m) (* (* (/ t_m l) t_m) (tan k)))
(/ l (* (+ (pow (/ k t_m) 2.0) 2.0) (sin k))))
(* (/ l (* (* k t_m) (* k t_m))) (/ 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 (t_m <= 2.25e-23) {
tmp = 2.0 / ((((k * k) * t_m) / (cos(k) * l)) * (pow(sin(k), 2.0) / l));
} else if (t_m <= 8e+203) {
tmp = ((2.0 / t_m) / (((t_m / l) * t_m) * tan(k))) * (l / ((pow((k / t_m), 2.0) + 2.0) * sin(k)));
} else {
tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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 <= 2.25d-23) then
tmp = 2.0d0 / ((((k * k) * t_m) / (cos(k) * l)) * ((sin(k) ** 2.0d0) / l))
else if (t_m <= 8d+203) then
tmp = ((2.0d0 / t_m) / (((t_m / l) * t_m) * tan(k))) * (l / ((((k / t_m) ** 2.0d0) + 2.0d0) * sin(k)))
else
tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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 <= 2.25e-23) {
tmp = 2.0 / ((((k * k) * t_m) / (Math.cos(k) * l)) * (Math.pow(Math.sin(k), 2.0) / l));
} else if (t_m <= 8e+203) {
tmp = ((2.0 / t_m) / (((t_m / l) * t_m) * Math.tan(k))) * (l / ((Math.pow((k / t_m), 2.0) + 2.0) * Math.sin(k)));
} else {
tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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 <= 2.25e-23: tmp = 2.0 / ((((k * k) * t_m) / (math.cos(k) * l)) * (math.pow(math.sin(k), 2.0) / l)) elif t_m <= 8e+203: tmp = ((2.0 / t_m) / (((t_m / l) * t_m) * math.tan(k))) * (l / ((math.pow((k / t_m), 2.0) + 2.0) * math.sin(k))) else: tmp = (l / ((k * t_m) * (k * t_m))) * (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 (t_m <= 2.25e-23) tmp = Float64(2.0 / Float64(Float64(Float64(Float64(k * k) * t_m) / Float64(cos(k) * l)) * Float64((sin(k) ^ 2.0) / l))); elseif (t_m <= 8e+203) tmp = Float64(Float64(Float64(2.0 / t_m) / Float64(Float64(Float64(t_m / l) * t_m) * tan(k))) * Float64(l / Float64(Float64((Float64(k / t_m) ^ 2.0) + 2.0) * sin(k)))); else tmp = Float64(Float64(l / Float64(Float64(k * t_m) * Float64(k * t_m))) * Float64(l / 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 <= 2.25e-23) tmp = 2.0 / ((((k * k) * t_m) / (cos(k) * l)) * ((sin(k) ^ 2.0) / l)); elseif (t_m <= 8e+203) tmp = ((2.0 / t_m) / (((t_m / l) * t_m) * tan(k))) * (l / ((((k / t_m) ^ 2.0) + 2.0) * sin(k))); else tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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, 2.25e-23], N[(2.0 / N[(N[(N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision] / N[(N[Cos[k], $MachinePrecision] * l), $MachinePrecision]), $MachinePrecision] * N[(N[Power[N[Sin[k], $MachinePrecision], 2.0], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 8e+203], N[(N[(N[(2.0 / t$95$m), $MachinePrecision] / N[(N[(N[(t$95$m / l), $MachinePrecision] * t$95$m), $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / N[(N[(N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision] + 2.0), $MachinePrecision] * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(l / N[(N[(k * t$95$m), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / t$95$m), $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.25 \cdot 10^{-23}:\\
\;\;\;\;\frac{2}{\frac{\left(k \cdot k\right) \cdot t\_m}{\cos k \cdot \ell} \cdot \frac{{\sin k}^{2}}{\ell}}\\
\mathbf{elif}\;t\_m \leq 8 \cdot 10^{+203}:\\
\;\;\;\;\frac{\frac{2}{t\_m}}{\left(\frac{t\_m}{\ell} \cdot t\_m\right) \cdot \tan k} \cdot \frac{\ell}{\left({\left(\frac{k}{t\_m}\right)}^{2} + 2\right) \cdot \sin k}\\
\mathbf{else}:\\
\;\;\;\;\frac{\ell}{\left(k \cdot t\_m\right) \cdot \left(k \cdot t\_m\right)} \cdot \frac{\ell}{t\_m}\\
\end{array}
\end{array}
if t < 2.24999999999999987e-23Initial program 49.7%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval22.5
Applied rewrites22.5%
Taylor expanded in t around 0
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
associate-*r/N/A
associate-/l*N/A
associate-*r*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
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-cos.f6464.8
Applied rewrites64.8%
Applied rewrites73.7%
if 2.24999999999999987e-23 < t < 7.9999999999999999e203Initial program 63.9%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval93.1
Applied rewrites93.1%
Applied rewrites91.0%
if 7.9999999999999999e203 < t Initial program 43.7%
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-*.f6450.3
Applied rewrites50.3%
Applied rewrites50.8%
Applied rewrites33.3%
Applied rewrites88.5%
Final simplification77.9%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= t_m 2.3e-23)
(/ 2.0 (* (/ (* (* k k) t_m) (* (cos k) l)) (/ (pow (sin k) 2.0) l)))
(if (<= t_m 5e+149)
(/
2.0
(*
(* (* (/ (* t_m t_m) l) (* (/ t_m l) (sin k))) (tan k))
(+ (+ 1.0 (pow (/ k t_m) 2.0)) 1.0)))
(/
2.0
(*
(* (* (* (/ t_m l) (* (/ t_m l) t_m)) (sin k)) (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 tmp;
if (t_m <= 2.3e-23) {
tmp = 2.0 / ((((k * k) * t_m) / (cos(k) * l)) * (pow(sin(k), 2.0) / l));
} else if (t_m <= 5e+149) {
tmp = 2.0 / (((((t_m * t_m) / l) * ((t_m / l) * sin(k))) * tan(k)) * ((1.0 + pow((k / t_m), 2.0)) + 1.0));
} else {
tmp = 2.0 / (((((t_m / l) * ((t_m / l) * t_m)) * sin(k)) * 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) tmp = 0.0 if (t_m <= 2.3e-23) tmp = Float64(2.0 / Float64(Float64(Float64(Float64(k * k) * t_m) / Float64(cos(k) * l)) * Float64((sin(k) ^ 2.0) / l))); elseif (t_m <= 5e+149) tmp = Float64(2.0 / Float64(Float64(Float64(Float64(Float64(t_m * t_m) / l) * Float64(Float64(t_m / l) * sin(k))) * tan(k)) * Float64(Float64(1.0 + (Float64(k / t_m) ^ 2.0)) + 1.0))); else tmp = Float64(2.0 / Float64(Float64(Float64(Float64(Float64(t_m / l) * Float64(Float64(t_m / l) * t_m)) * sin(k)) * 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_] := N[(t$95$s * If[LessEqual[t$95$m, 2.3e-23], N[(2.0 / N[(N[(N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision] / N[(N[Cos[k], $MachinePrecision] * l), $MachinePrecision]), $MachinePrecision] * N[(N[Power[N[Sin[k], $MachinePrecision], 2.0], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 5e+149], N[(2.0 / N[(N[(N[(N[(N[(t$95$m * t$95$m), $MachinePrecision] / l), $MachinePrecision] * N[(N[(t$95$m / l), $MachinePrecision] * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * N[(N[(1.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(N[(N[(N[(t$95$m / l), $MachinePrecision] * N[(N[(t$95$m / l), $MachinePrecision] * t$95$m), $MachinePrecision]), $MachinePrecision] * N[Sin[k], $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)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 2.3 \cdot 10^{-23}:\\
\;\;\;\;\frac{2}{\frac{\left(k \cdot k\right) \cdot t\_m}{\cos k \cdot \ell} \cdot \frac{{\sin k}^{2}}{\ell}}\\
\mathbf{elif}\;t\_m \leq 5 \cdot 10^{+149}:\\
\;\;\;\;\frac{2}{\left(\left(\frac{t\_m \cdot t\_m}{\ell} \cdot \left(\frac{t\_m}{\ell} \cdot \sin k\right)\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t\_m}\right)}^{2}\right) + 1\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(\left(\left(\frac{t\_m}{\ell} \cdot \left(\frac{t\_m}{\ell} \cdot t\_m\right)\right) \cdot \sin k\right) \cdot \tan k\right) \cdot \mathsf{fma}\left(\frac{k}{t\_m}, \frac{k}{t\_m}, 2\right)}\\
\end{array}
\end{array}
if t < 2.3000000000000001e-23Initial program 49.7%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval22.5
Applied rewrites22.5%
Taylor expanded in t around 0
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
associate-*r/N/A
associate-/l*N/A
associate-*r*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
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-cos.f6464.8
Applied rewrites64.8%
Applied rewrites73.7%
if 2.3000000000000001e-23 < t < 4.9999999999999999e149Initial program 65.1%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
unpow3N/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
lower-*.f64N/A
lower-/.f6491.0
Applied rewrites91.0%
if 4.9999999999999999e149 < t Initial program 49.0%
Taylor expanded in t around inf
Applied rewrites49.0%
lift-/.f64N/A
lift-pow.f64N/A
lift-*.f64N/A
cube-multN/A
lift-*.f64N/A
frac-timesN/A
lift-/.f64N/A
lift-/.f64N/A
lower-*.f6461.4
lift-/.f64N/A
lift-*.f64N/A
associate-/l*N/A
lift-/.f64N/A
*-commutativeN/A
lower-*.f6477.3
Applied rewrites77.3%
Taylor expanded in t around inf
+-commutativeN/A
unpow2N/A
unpow2N/A
times-fracN/A
lower-fma.f64N/A
lower-/.f64N/A
lower-/.f6486.1
Applied rewrites86.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 6.5e-23)
(/ 2.0 (* (/ (* (* k k) t_m) (* (cos k) l)) (/ (pow (sin k) 2.0) l)))
(/
2.0
(*
(* (* (* (/ t_m l) (* (/ t_m l) t_m)) (sin k)) (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 tmp;
if (t_m <= 6.5e-23) {
tmp = 2.0 / ((((k * k) * t_m) / (cos(k) * l)) * (pow(sin(k), 2.0) / l));
} else {
tmp = 2.0 / (((((t_m / l) * ((t_m / l) * t_m)) * sin(k)) * 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) tmp = 0.0 if (t_m <= 6.5e-23) tmp = Float64(2.0 / Float64(Float64(Float64(Float64(k * k) * t_m) / Float64(cos(k) * l)) * Float64((sin(k) ^ 2.0) / l))); else tmp = Float64(2.0 / Float64(Float64(Float64(Float64(Float64(t_m / l) * Float64(Float64(t_m / l) * t_m)) * sin(k)) * 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_] := N[(t$95$s * If[LessEqual[t$95$m, 6.5e-23], N[(2.0 / N[(N[(N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision] / N[(N[Cos[k], $MachinePrecision] * l), $MachinePrecision]), $MachinePrecision] * N[(N[Power[N[Sin[k], $MachinePrecision], 2.0], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(N[(N[(N[(t$95$m / l), $MachinePrecision] * N[(N[(t$95$m / l), $MachinePrecision] * t$95$m), $MachinePrecision]), $MachinePrecision] * N[Sin[k], $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)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 6.5 \cdot 10^{-23}:\\
\;\;\;\;\frac{2}{\frac{\left(k \cdot k\right) \cdot t\_m}{\cos k \cdot \ell} \cdot \frac{{\sin k}^{2}}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(\left(\left(\frac{t\_m}{\ell} \cdot \left(\frac{t\_m}{\ell} \cdot t\_m\right)\right) \cdot \sin k\right) \cdot \tan k\right) \cdot \mathsf{fma}\left(\frac{k}{t\_m}, \frac{k}{t\_m}, 2\right)}\\
\end{array}
\end{array}
if t < 6.5e-23Initial program 49.7%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval22.5
Applied rewrites22.5%
Taylor expanded in t around 0
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
associate-*r/N/A
associate-/l*N/A
associate-*r*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
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-cos.f6464.8
Applied rewrites64.8%
Applied rewrites73.7%
if 6.5e-23 < t Initial program 57.4%
Taylor expanded in t around inf
Applied rewrites54.6%
lift-/.f64N/A
lift-pow.f64N/A
lift-*.f64N/A
cube-multN/A
lift-*.f64N/A
frac-timesN/A
lift-/.f64N/A
lift-/.f64N/A
lower-*.f6463.8
lift-/.f64N/A
lift-*.f64N/A
associate-/l*N/A
lift-/.f64N/A
*-commutativeN/A
lower-*.f6471.3
Applied rewrites71.3%
Taylor expanded in t around inf
+-commutativeN/A
unpow2N/A
unpow2N/A
times-fracN/A
lower-fma.f64N/A
lower-/.f64N/A
lower-/.f6485.8
Applied rewrites85.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 2.25e-23)
(/ 2.0 (/ (* (* (/ (sin k) l) (tan k)) (* (* k k) t_m)) l))
(if (<= t_m 1.06e+207)
(/
(* 2.0 (/ l t_m))
(*
(* (/ t_m l) t_m)
(* (+ (/ (* k k) (* t_m t_m)) 2.0) (* (sin k) (tan k)))))
(pow (/ (* (* (* t_m k) k) t_m) (* l (/ l t_m))) -1.0)))))t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
double tmp;
if (t_m <= 2.25e-23) {
tmp = 2.0 / ((((sin(k) / l) * tan(k)) * ((k * k) * t_m)) / l);
} else if (t_m <= 1.06e+207) {
tmp = (2.0 * (l / t_m)) / (((t_m / l) * t_m) * ((((k * k) / (t_m * t_m)) + 2.0) * (sin(k) * tan(k))));
} else {
tmp = pow(((((t_m * k) * k) * t_m) / (l * (l / t_m))), -1.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 <= 2.25d-23) then
tmp = 2.0d0 / ((((sin(k) / l) * tan(k)) * ((k * k) * t_m)) / l)
else if (t_m <= 1.06d+207) then
tmp = (2.0d0 * (l / t_m)) / (((t_m / l) * t_m) * ((((k * k) / (t_m * t_m)) + 2.0d0) * (sin(k) * tan(k))))
else
tmp = ((((t_m * k) * k) * t_m) / (l * (l / t_m))) ** (-1.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 <= 2.25e-23) {
tmp = 2.0 / ((((Math.sin(k) / l) * Math.tan(k)) * ((k * k) * t_m)) / l);
} else if (t_m <= 1.06e+207) {
tmp = (2.0 * (l / t_m)) / (((t_m / l) * t_m) * ((((k * k) / (t_m * t_m)) + 2.0) * (Math.sin(k) * Math.tan(k))));
} else {
tmp = Math.pow(((((t_m * k) * k) * t_m) / (l * (l / t_m))), -1.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 <= 2.25e-23: tmp = 2.0 / ((((math.sin(k) / l) * math.tan(k)) * ((k * k) * t_m)) / l) elif t_m <= 1.06e+207: tmp = (2.0 * (l / t_m)) / (((t_m / l) * t_m) * ((((k * k) / (t_m * t_m)) + 2.0) * (math.sin(k) * math.tan(k)))) else: tmp = math.pow(((((t_m * k) * k) * t_m) / (l * (l / t_m))), -1.0) return t_s * tmp
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) tmp = 0.0 if (t_m <= 2.25e-23) tmp = Float64(2.0 / Float64(Float64(Float64(Float64(sin(k) / l) * tan(k)) * Float64(Float64(k * k) * t_m)) / l)); elseif (t_m <= 1.06e+207) tmp = Float64(Float64(2.0 * Float64(l / t_m)) / Float64(Float64(Float64(t_m / l) * t_m) * Float64(Float64(Float64(Float64(k * k) / Float64(t_m * t_m)) + 2.0) * Float64(sin(k) * tan(k))))); else tmp = Float64(Float64(Float64(Float64(t_m * k) * k) * t_m) / Float64(l * Float64(l / t_m))) ^ -1.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 <= 2.25e-23) tmp = 2.0 / ((((sin(k) / l) * tan(k)) * ((k * k) * t_m)) / l); elseif (t_m <= 1.06e+207) tmp = (2.0 * (l / t_m)) / (((t_m / l) * t_m) * ((((k * k) / (t_m * t_m)) + 2.0) * (sin(k) * tan(k)))); else tmp = ((((t_m * k) * k) * t_m) / (l * (l / t_m))) ^ -1.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, 2.25e-23], 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], If[LessEqual[t$95$m, 1.06e+207], N[(N[(2.0 * N[(l / t$95$m), $MachinePrecision]), $MachinePrecision] / N[(N[(N[(t$95$m / l), $MachinePrecision] * t$95$m), $MachinePrecision] * N[(N[(N[(N[(k * k), $MachinePrecision] / N[(t$95$m * t$95$m), $MachinePrecision]), $MachinePrecision] + 2.0), $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[Power[N[(N[(N[(N[(t$95$m * k), $MachinePrecision] * k), $MachinePrecision] * t$95$m), $MachinePrecision] / N[(l * N[(l / t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], -1.0], $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.25 \cdot 10^{-23}:\\
\;\;\;\;\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{elif}\;t\_m \leq 1.06 \cdot 10^{+207}:\\
\;\;\;\;\frac{2 \cdot \frac{\ell}{t\_m}}{\left(\frac{t\_m}{\ell} \cdot t\_m\right) \cdot \left(\left(\frac{k \cdot k}{t\_m \cdot t\_m} + 2\right) \cdot \left(\sin k \cdot \tan k\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;{\left(\frac{\left(\left(t\_m \cdot k\right) \cdot k\right) \cdot t\_m}{\ell \cdot \frac{\ell}{t\_m}}\right)}^{-1}\\
\end{array}
\end{array}
if t < 2.24999999999999987e-23Initial program 49.7%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval22.5
Applied rewrites22.5%
Taylor expanded in t around 0
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
associate-*r/N/A
associate-/l*N/A
associate-*r*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
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-cos.f6464.8
Applied rewrites64.8%
Applied rewrites73.7%
if 2.24999999999999987e-23 < t < 1.05999999999999998e207Initial program 62.5%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval91.1
Applied rewrites91.1%
Applied rewrites89.0%
lift-/.f64N/A
div-invN/A
lift-/.f64N/A
lift-/.f64N/A
clear-numN/A
associate-*l/N/A
lower-/.f64N/A
lower-*.f64N/A
lower-/.f6488.9
lift-*.f64N/A
*-commutativeN/A
lower-*.f6488.9
lift-*.f64N/A
*-commutativeN/A
Applied rewrites88.9%
lift-pow.f64N/A
unpow2N/A
lift-/.f64N/A
lift-/.f64N/A
frac-timesN/A
lift-*.f64N/A
lift-*.f64N/A
lower-/.f6480.2
Applied rewrites80.2%
if 1.05999999999999998e207 < t Initial program 45.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-*.f6452.8
Applied rewrites52.8%
Applied rewrites53.2%
Applied rewrites88.2%
Final simplification76.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 7.6e-23)
(/ 2.0 (/ (* (* (/ (sin k) l) (tan k)) (* (* k k) t_m)) l))
(/
2.0
(*
(* (* (* (/ t_m l) (* (/ t_m l) t_m)) (sin k)) (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 tmp;
if (t_m <= 7.6e-23) {
tmp = 2.0 / ((((sin(k) / l) * tan(k)) * ((k * k) * t_m)) / l);
} else {
tmp = 2.0 / (((((t_m / l) * ((t_m / l) * t_m)) * sin(k)) * 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) tmp = 0.0 if (t_m <= 7.6e-23) 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(Float64(Float64(Float64(Float64(t_m / l) * Float64(Float64(t_m / l) * t_m)) * sin(k)) * 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_] := N[(t$95$s * If[LessEqual[t$95$m, 7.6e-23], 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[(N[(N[(N[(N[(t$95$m / l), $MachinePrecision] * N[(N[(t$95$m / l), $MachinePrecision] * t$95$m), $MachinePrecision]), $MachinePrecision] * N[Sin[k], $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)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 7.6 \cdot 10^{-23}:\\
\;\;\;\;\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}{\left(\left(\left(\frac{t\_m}{\ell} \cdot \left(\frac{t\_m}{\ell} \cdot t\_m\right)\right) \cdot \sin k\right) \cdot \tan k\right) \cdot \mathsf{fma}\left(\frac{k}{t\_m}, \frac{k}{t\_m}, 2\right)}\\
\end{array}
\end{array}
if t < 7.60000000000000023e-23Initial program 49.7%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval22.5
Applied rewrites22.5%
Taylor expanded in t around 0
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
associate-*r/N/A
associate-/l*N/A
associate-*r*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
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-cos.f6464.8
Applied rewrites64.8%
Applied rewrites73.7%
if 7.60000000000000023e-23 < t Initial program 57.4%
Taylor expanded in t around inf
Applied rewrites54.6%
lift-/.f64N/A
lift-pow.f64N/A
lift-*.f64N/A
cube-multN/A
lift-*.f64N/A
frac-timesN/A
lift-/.f64N/A
lift-/.f64N/A
lower-*.f6463.8
lift-/.f64N/A
lift-*.f64N/A
associate-/l*N/A
lift-/.f64N/A
*-commutativeN/A
lower-*.f6471.3
Applied rewrites71.3%
Taylor expanded in t around inf
+-commutativeN/A
unpow2N/A
unpow2N/A
times-fracN/A
lower-fma.f64N/A
lower-/.f64N/A
lower-/.f6485.8
Applied rewrites85.8%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= k 2.3e-167)
(/ (/ (* (/ l k) (/ (/ l k) t_m)) t_m) t_m)
(if (<= k 1.96)
(/
(/
2.0
(*
(fma
(* (/ (fma 0.3333333333333333 (* t_m t_m) 1.0) l) k)
k
(* (/ (* t_m t_m) l) 2.0))
(* k k)))
(/ t_m l))
(if (<= k 5e+120)
(/ 2.0 (/ (* (* (/ (sin k) l) (tan k)) (* (* k k) t_m)) l))
(/ 2.0 (* (* (/ (* (tan k) (sin k)) (* l l)) (* k t_m)) 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.3e-167) {
tmp = (((l / k) * ((l / k) / t_m)) / t_m) / t_m;
} else if (k <= 1.96) {
tmp = (2.0 / (fma(((fma(0.3333333333333333, (t_m * t_m), 1.0) / l) * k), k, (((t_m * t_m) / l) * 2.0)) * (k * k))) / (t_m / l);
} else if (k <= 5e+120) {
tmp = 2.0 / ((((sin(k) / l) * tan(k)) * ((k * k) * t_m)) / l);
} else {
tmp = 2.0 / ((((tan(k) * sin(k)) / (l * l)) * (k * t_m)) * 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.3e-167) tmp = Float64(Float64(Float64(Float64(l / k) * Float64(Float64(l / k) / t_m)) / t_m) / t_m); elseif (k <= 1.96) tmp = Float64(Float64(2.0 / Float64(fma(Float64(Float64(fma(0.3333333333333333, Float64(t_m * t_m), 1.0) / l) * k), k, Float64(Float64(Float64(t_m * t_m) / l) * 2.0)) * Float64(k * k))) / Float64(t_m / l)); elseif (k <= 5e+120) 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(Float64(Float64(Float64(tan(k) * sin(k)) / Float64(l * l)) * Float64(k * t_m)) * 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.3e-167], N[(N[(N[(N[(l / k), $MachinePrecision] * N[(N[(l / k), $MachinePrecision] / t$95$m), $MachinePrecision]), $MachinePrecision] / t$95$m), $MachinePrecision] / t$95$m), $MachinePrecision], If[LessEqual[k, 1.96], N[(N[(2.0 / N[(N[(N[(N[(N[(0.3333333333333333 * N[(t$95$m * t$95$m), $MachinePrecision] + 1.0), $MachinePrecision] / l), $MachinePrecision] * k), $MachinePrecision] * k + N[(N[(N[(t$95$m * t$95$m), $MachinePrecision] / l), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision] * N[(k * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(t$95$m / l), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 5e+120], 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[(N[(N[(N[(N[Tan[k], $MachinePrecision] * N[Sin[k], $MachinePrecision]), $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]]]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 2.3 \cdot 10^{-167}:\\
\;\;\;\;\frac{\frac{\frac{\ell}{k} \cdot \frac{\frac{\ell}{k}}{t\_m}}{t\_m}}{t\_m}\\
\mathbf{elif}\;k \leq 1.96:\\
\;\;\;\;\frac{\frac{2}{\mathsf{fma}\left(\frac{\mathsf{fma}\left(0.3333333333333333, t\_m \cdot t\_m, 1\right)}{\ell} \cdot k, k, \frac{t\_m \cdot t\_m}{\ell} \cdot 2\right) \cdot \left(k \cdot k\right)}}{\frac{t\_m}{\ell}}\\
\mathbf{elif}\;k \leq 5 \cdot 10^{+120}:\\
\;\;\;\;\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}{\left(\frac{\tan k \cdot \sin k}{\ell \cdot \ell} \cdot \left(k \cdot t\_m\right)\right) \cdot k}\\
\end{array}
\end{array}
if k < 2.3000000000000001e-167Initial program 55.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.5
Applied rewrites55.5%
Applied rewrites57.8%
Applied rewrites49.6%
Applied rewrites72.8%
if 2.3000000000000001e-167 < k < 1.96Initial program 62.4%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval32.7
Applied rewrites32.7%
Applied rewrites86.3%
Taylor expanded in k around 0
*-commutativeN/A
lower-*.f64N/A
Applied rewrites89.4%
if 1.96 < k < 5.00000000000000019e120Initial program 34.0%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval19.8
Applied rewrites19.8%
Taylor expanded in t around 0
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
associate-*r/N/A
associate-/l*N/A
associate-*r*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
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-cos.f6468.1
Applied rewrites68.1%
Applied rewrites91.6%
if 5.00000000000000019e120 < k Initial program 32.1%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval37.7
Applied rewrites37.7%
Taylor expanded in t around 0
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
associate-*r/N/A
associate-/l*N/A
associate-*r*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
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-cos.f6461.9
Applied rewrites61.9%
Applied rewrites79.1%
Final simplification77.4%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= k 2.3e-167)
(/ (/ (* (/ l k) (/ (/ l k) t_m)) t_m) t_m)
(if (<= k 1.96)
(/
(/
2.0
(*
(fma
(* (/ (fma 0.3333333333333333 (* t_m t_m) 1.0) l) k)
k
(* (/ (* t_m t_m) l) 2.0))
(* k k)))
(/ t_m l))
(/ 2.0 (* (* (/ (* (tan k) (sin k)) (* l l)) (* k t_m)) 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.3e-167) {
tmp = (((l / k) * ((l / k) / t_m)) / t_m) / t_m;
} else if (k <= 1.96) {
tmp = (2.0 / (fma(((fma(0.3333333333333333, (t_m * t_m), 1.0) / l) * k), k, (((t_m * t_m) / l) * 2.0)) * (k * k))) / (t_m / l);
} else {
tmp = 2.0 / ((((tan(k) * sin(k)) / (l * l)) * (k * t_m)) * 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.3e-167) tmp = Float64(Float64(Float64(Float64(l / k) * Float64(Float64(l / k) / t_m)) / t_m) / t_m); elseif (k <= 1.96) tmp = Float64(Float64(2.0 / Float64(fma(Float64(Float64(fma(0.3333333333333333, Float64(t_m * t_m), 1.0) / l) * k), k, Float64(Float64(Float64(t_m * t_m) / l) * 2.0)) * Float64(k * k))) / Float64(t_m / l)); else tmp = Float64(2.0 / Float64(Float64(Float64(Float64(tan(k) * sin(k)) / Float64(l * l)) * Float64(k * t_m)) * 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.3e-167], N[(N[(N[(N[(l / k), $MachinePrecision] * N[(N[(l / k), $MachinePrecision] / t$95$m), $MachinePrecision]), $MachinePrecision] / t$95$m), $MachinePrecision] / t$95$m), $MachinePrecision], If[LessEqual[k, 1.96], N[(N[(2.0 / N[(N[(N[(N[(N[(0.3333333333333333 * N[(t$95$m * t$95$m), $MachinePrecision] + 1.0), $MachinePrecision] / l), $MachinePrecision] * k), $MachinePrecision] * k + N[(N[(N[(t$95$m * t$95$m), $MachinePrecision] / l), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision] * N[(k * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(t$95$m / l), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(N[(N[(N[Tan[k], $MachinePrecision] * N[Sin[k], $MachinePrecision]), $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 2.3 \cdot 10^{-167}:\\
\;\;\;\;\frac{\frac{\frac{\ell}{k} \cdot \frac{\frac{\ell}{k}}{t\_m}}{t\_m}}{t\_m}\\
\mathbf{elif}\;k \leq 1.96:\\
\;\;\;\;\frac{\frac{2}{\mathsf{fma}\left(\frac{\mathsf{fma}\left(0.3333333333333333, t\_m \cdot t\_m, 1\right)}{\ell} \cdot k, k, \frac{t\_m \cdot t\_m}{\ell} \cdot 2\right) \cdot \left(k \cdot k\right)}}{\frac{t\_m}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(\frac{\tan k \cdot \sin k}{\ell \cdot \ell} \cdot \left(k \cdot t\_m\right)\right) \cdot k}\\
\end{array}
\end{array}
if k < 2.3000000000000001e-167Initial program 55.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.5
Applied rewrites55.5%
Applied rewrites57.8%
Applied rewrites49.6%
Applied rewrites72.8%
if 2.3000000000000001e-167 < k < 1.96Initial program 62.4%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval32.7
Applied rewrites32.7%
Applied rewrites86.3%
Taylor expanded in k around 0
*-commutativeN/A
lower-*.f64N/A
Applied rewrites89.4%
if 1.96 < k Initial program 32.7%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval31.5
Applied rewrites31.5%
Taylor expanded in t around 0
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
associate-*r/N/A
associate-/l*N/A
associate-*r*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
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-cos.f6464.1
Applied rewrites64.1%
Applied rewrites74.6%
Final simplification75.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 2.3e-167)
(/ (/ (* (/ l k) (/ (/ l k) t_m)) t_m) t_m)
(if (<= k 1.96)
(/
(/
2.0
(*
(fma
(* (/ (fma 0.3333333333333333 (* t_m t_m) 1.0) l) k)
k
(* (/ (* t_m t_m) l) 2.0))
(* k k)))
(/ t_m l))
(/ 2.0 (* (* (/ (* (tan k) (sin k)) (* l l)) 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 (k <= 2.3e-167) {
tmp = (((l / k) * ((l / k) / t_m)) / t_m) / t_m;
} else if (k <= 1.96) {
tmp = (2.0 / (fma(((fma(0.3333333333333333, (t_m * t_m), 1.0) / l) * k), k, (((t_m * t_m) / l) * 2.0)) * (k * k))) / (t_m / l);
} else {
tmp = 2.0 / ((((tan(k) * sin(k)) / (l * l)) * 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 (k <= 2.3e-167) tmp = Float64(Float64(Float64(Float64(l / k) * Float64(Float64(l / k) / t_m)) / t_m) / t_m); elseif (k <= 1.96) tmp = Float64(Float64(2.0 / Float64(fma(Float64(Float64(fma(0.3333333333333333, Float64(t_m * t_m), 1.0) / l) * k), k, Float64(Float64(Float64(t_m * t_m) / l) * 2.0)) * Float64(k * k))) / Float64(t_m / l)); else tmp = Float64(2.0 / Float64(Float64(Float64(Float64(tan(k) * sin(k)) / Float64(l * l)) * k) * Float64(k * 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.3e-167], N[(N[(N[(N[(l / k), $MachinePrecision] * N[(N[(l / k), $MachinePrecision] / t$95$m), $MachinePrecision]), $MachinePrecision] / t$95$m), $MachinePrecision] / t$95$m), $MachinePrecision], If[LessEqual[k, 1.96], N[(N[(2.0 / N[(N[(N[(N[(N[(0.3333333333333333 * N[(t$95$m * t$95$m), $MachinePrecision] + 1.0), $MachinePrecision] / l), $MachinePrecision] * k), $MachinePrecision] * k + N[(N[(N[(t$95$m * t$95$m), $MachinePrecision] / l), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision] * N[(k * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(t$95$m / l), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(N[(N[(N[Tan[k], $MachinePrecision] * N[Sin[k], $MachinePrecision]), $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision] * k), $MachinePrecision] * N[(k * 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 2.3 \cdot 10^{-167}:\\
\;\;\;\;\frac{\frac{\frac{\ell}{k} \cdot \frac{\frac{\ell}{k}}{t\_m}}{t\_m}}{t\_m}\\
\mathbf{elif}\;k \leq 1.96:\\
\;\;\;\;\frac{\frac{2}{\mathsf{fma}\left(\frac{\mathsf{fma}\left(0.3333333333333333, t\_m \cdot t\_m, 1\right)}{\ell} \cdot k, k, \frac{t\_m \cdot t\_m}{\ell} \cdot 2\right) \cdot \left(k \cdot k\right)}}{\frac{t\_m}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(\frac{\tan k \cdot \sin k}{\ell \cdot \ell} \cdot k\right) \cdot \left(k \cdot t\_m\right)}\\
\end{array}
\end{array}
if k < 2.3000000000000001e-167Initial program 55.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.5
Applied rewrites55.5%
Applied rewrites57.8%
Applied rewrites49.6%
Applied rewrites72.8%
if 2.3000000000000001e-167 < k < 1.96Initial program 62.4%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval32.7
Applied rewrites32.7%
Applied rewrites86.3%
Taylor expanded in k around 0
*-commutativeN/A
lower-*.f64N/A
Applied rewrites89.4%
if 1.96 < k Initial program 32.7%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval31.5
Applied rewrites31.5%
Taylor expanded in t around 0
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
associate-*r/N/A
associate-/l*N/A
associate-*r*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
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-cos.f6464.1
Applied rewrites64.1%
Applied rewrites75.3%
Final simplification75.7%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= k 2.3e-167)
(/ (/ (* (/ l k) (/ (/ l k) t_m)) t_m) t_m)
(if (<= k 1.96)
(/
(/
2.0
(*
(fma
(* (/ (fma 0.3333333333333333 (* t_m t_m) 1.0) l) k)
k
(* (/ (* t_m t_m) l) 2.0))
(* k k)))
(/ t_m l))
(/ 2.0 (* (* t_m (* k 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.3e-167) {
tmp = (((l / k) * ((l / k) / t_m)) / t_m) / t_m;
} else if (k <= 1.96) {
tmp = (2.0 / (fma(((fma(0.3333333333333333, (t_m * t_m), 1.0) / l) * k), k, (((t_m * t_m) / l) * 2.0)) * (k * k))) / (t_m / l);
} else {
tmp = 2.0 / ((t_m * (k * 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.3e-167) tmp = Float64(Float64(Float64(Float64(l / k) * Float64(Float64(l / k) / t_m)) / t_m) / t_m); elseif (k <= 1.96) tmp = Float64(Float64(2.0 / Float64(fma(Float64(Float64(fma(0.3333333333333333, Float64(t_m * t_m), 1.0) / l) * k), k, Float64(Float64(Float64(t_m * t_m) / l) * 2.0)) * Float64(k * k))) / Float64(t_m / l)); else tmp = Float64(2.0 / Float64(Float64(t_m * Float64(k * 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.3e-167], N[(N[(N[(N[(l / k), $MachinePrecision] * N[(N[(l / k), $MachinePrecision] / t$95$m), $MachinePrecision]), $MachinePrecision] / t$95$m), $MachinePrecision] / t$95$m), $MachinePrecision], If[LessEqual[k, 1.96], N[(N[(2.0 / N[(N[(N[(N[(N[(0.3333333333333333 * N[(t$95$m * t$95$m), $MachinePrecision] + 1.0), $MachinePrecision] / l), $MachinePrecision] * k), $MachinePrecision] * k + N[(N[(N[(t$95$m * t$95$m), $MachinePrecision] / l), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision] * N[(k * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(t$95$m / l), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(t$95$m * N[(k * k), $MachinePrecision]), $MachinePrecision] * N[(N[Tan[k], $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 2.3 \cdot 10^{-167}:\\
\;\;\;\;\frac{\frac{\frac{\ell}{k} \cdot \frac{\frac{\ell}{k}}{t\_m}}{t\_m}}{t\_m}\\
\mathbf{elif}\;k \leq 1.96:\\
\;\;\;\;\frac{\frac{2}{\mathsf{fma}\left(\frac{\mathsf{fma}\left(0.3333333333333333, t\_m \cdot t\_m, 1\right)}{\ell} \cdot k, k, \frac{t\_m \cdot t\_m}{\ell} \cdot 2\right) \cdot \left(k \cdot k\right)}}{\frac{t\_m}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(t\_m \cdot \left(k \cdot k\right)\right) \cdot \left(\tan k \cdot \frac{\sin k}{\ell \cdot \ell}\right)}\\
\end{array}
\end{array}
if k < 2.3000000000000001e-167Initial program 55.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.5
Applied rewrites55.5%
Applied rewrites57.8%
Applied rewrites49.6%
Applied rewrites72.8%
if 2.3000000000000001e-167 < k < 1.96Initial program 62.4%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval32.7
Applied rewrites32.7%
Applied rewrites86.3%
Taylor expanded in k around 0
*-commutativeN/A
lower-*.f64N/A
Applied rewrites89.4%
if 1.96 < k Initial program 32.7%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval31.5
Applied rewrites31.5%
Taylor expanded in t around 0
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
associate-*r/N/A
associate-/l*N/A
associate-*r*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
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-cos.f6464.1
Applied rewrites64.1%
Applied rewrites64.1%
Final simplification73.4%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(let* ((t_2 (/ l (* (pow t_m 1.5) k))))
(*
t_s
(if (<= t_m 3.9e-50)
(/
2.0
(*
(/ t_m l)
(*
(fma
(* (/ (fma 0.3333333333333333 (* t_m t_m) 1.0) l) k)
k
(* (* t_m (/ t_m l)) 2.0))
(* k k))))
(if (<= t_m 3e+195)
(* t_2 t_2)
(* (/ l (* (* k t_m) (* k t_m))) (/ 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 t_2 = l / (pow(t_m, 1.5) * k);
double tmp;
if (t_m <= 3.9e-50) {
tmp = 2.0 / ((t_m / l) * (fma(((fma(0.3333333333333333, (t_m * t_m), 1.0) / l) * k), k, ((t_m * (t_m / l)) * 2.0)) * (k * k)));
} else if (t_m <= 3e+195) {
tmp = t_2 * t_2;
} else {
tmp = (l / ((k * t_m) * (k * t_m))) * (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) t_2 = Float64(l / Float64((t_m ^ 1.5) * k)) tmp = 0.0 if (t_m <= 3.9e-50) tmp = Float64(2.0 / Float64(Float64(t_m / l) * Float64(fma(Float64(Float64(fma(0.3333333333333333, Float64(t_m * t_m), 1.0) / l) * k), k, Float64(Float64(t_m * Float64(t_m / l)) * 2.0)) * Float64(k * k)))); elseif (t_m <= 3e+195) tmp = Float64(t_2 * t_2); else tmp = Float64(Float64(l / Float64(Float64(k * t_m) * Float64(k * t_m))) * Float64(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_] := Block[{t$95$2 = N[(l / N[(N[Power[t$95$m, 1.5], $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]}, N[(t$95$s * If[LessEqual[t$95$m, 3.9e-50], 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] / l), $MachinePrecision] * k), $MachinePrecision] * k + N[(N[(t$95$m * N[(t$95$m / l), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision] * N[(k * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 3e+195], N[(t$95$2 * t$95$2), $MachinePrecision], N[(N[(l / N[(N[(k * t$95$m), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / t$95$m), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
\begin{array}{l}
t_2 := \frac{\ell}{{t\_m}^{1.5} \cdot k}\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 3.9 \cdot 10^{-50}:\\
\;\;\;\;\frac{2}{\frac{t\_m}{\ell} \cdot \left(\mathsf{fma}\left(\frac{\mathsf{fma}\left(0.3333333333333333, t\_m \cdot t\_m, 1\right)}{\ell} \cdot k, k, \left(t\_m \cdot \frac{t\_m}{\ell}\right) \cdot 2\right) \cdot \left(k \cdot k\right)\right)}\\
\mathbf{elif}\;t\_m \leq 3 \cdot 10^{+195}:\\
\;\;\;\;t\_2 \cdot t\_2\\
\mathbf{else}:\\
\;\;\;\;\frac{\ell}{\left(k \cdot t\_m\right) \cdot \left(k \cdot t\_m\right)} \cdot \frac{\ell}{t\_m}\\
\end{array}
\end{array}
\end{array}
if t < 3.90000000000000021e-50Initial program 48.9%
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 rewrites58.8%
Taylor expanded in k around 0
*-commutativeN/A
lower-*.f64N/A
Applied rewrites70.1%
if 3.90000000000000021e-50 < t < 3.0000000000000001e195Initial program 64.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-*.f6455.6
Applied rewrites55.6%
Applied rewrites71.7%
if 3.0000000000000001e195 < t Initial program 46.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-*.f6452.6
Applied rewrites52.6%
Applied rewrites53.0%
Applied rewrites36.4%
Applied rewrites89.1%
Final simplification72.0%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= t_m 1.32e-49)
(/
2.0
(*
(/ t_m l)
(*
(fma
(* (/ (fma 0.3333333333333333 (* t_m t_m) 1.0) l) k)
k
(* (* t_m (/ t_m l)) 2.0))
(* k k))))
(if (<= t_m 6.5e+102)
(* (/ l (* (* t_m t_m) (* t_m k))) (/ l k))
(* (pow (/ t_m l) -2.0) (/ (pow (* k t_m) -1.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 <= 1.32e-49) {
tmp = 2.0 / ((t_m / l) * (fma(((fma(0.3333333333333333, (t_m * t_m), 1.0) / l) * k), k, ((t_m * (t_m / l)) * 2.0)) * (k * k)));
} else if (t_m <= 6.5e+102) {
tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k);
} else {
tmp = pow((t_m / l), -2.0) * (pow((k * t_m), -1.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 <= 1.32e-49) tmp = Float64(2.0 / Float64(Float64(t_m / l) * Float64(fma(Float64(Float64(fma(0.3333333333333333, Float64(t_m * t_m), 1.0) / l) * k), k, Float64(Float64(t_m * Float64(t_m / l)) * 2.0)) * Float64(k * k)))); elseif (t_m <= 6.5e+102) tmp = Float64(Float64(l / Float64(Float64(t_m * t_m) * Float64(t_m * k))) * Float64(l / k)); else tmp = Float64((Float64(t_m / l) ^ -2.0) * Float64((Float64(k * t_m) ^ -1.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, 1.32e-49], 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] / l), $MachinePrecision] * k), $MachinePrecision] * k + N[(N[(t$95$m * N[(t$95$m / l), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision] * N[(k * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 6.5e+102], N[(N[(l / N[(N[(t$95$m * t$95$m), $MachinePrecision] * N[(t$95$m * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / k), $MachinePrecision]), $MachinePrecision], N[(N[Power[N[(t$95$m / l), $MachinePrecision], -2.0], $MachinePrecision] * N[(N[Power[N[(k * t$95$m), $MachinePrecision], -1.0], $MachinePrecision] / k), $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.32 \cdot 10^{-49}:\\
\;\;\;\;\frac{2}{\frac{t\_m}{\ell} \cdot \left(\mathsf{fma}\left(\frac{\mathsf{fma}\left(0.3333333333333333, t\_m \cdot t\_m, 1\right)}{\ell} \cdot k, k, \left(t\_m \cdot \frac{t\_m}{\ell}\right) \cdot 2\right) \cdot \left(k \cdot k\right)\right)}\\
\mathbf{elif}\;t\_m \leq 6.5 \cdot 10^{+102}:\\
\;\;\;\;\frac{\ell}{\left(t\_m \cdot t\_m\right) \cdot \left(t\_m \cdot k\right)} \cdot \frac{\ell}{k}\\
\mathbf{else}:\\
\;\;\;\;{\left(\frac{t\_m}{\ell}\right)}^{-2} \cdot \frac{{\left(k \cdot t\_m\right)}^{-1}}{k}\\
\end{array}
\end{array}
if t < 1.3199999999999999e-49Initial program 48.9%
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 rewrites58.8%
Taylor expanded in k around 0
*-commutativeN/A
lower-*.f64N/A
Applied rewrites70.1%
if 1.3199999999999999e-49 < t < 6.5000000000000004e102Initial program 72.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-*.f6453.7
Applied rewrites53.7%
Applied rewrites68.7%
Applied rewrites68.8%
if 6.5000000000000004e102 < t Initial program 51.7%
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.2
Applied rewrites55.2%
Applied rewrites59.8%
Applied rewrites49.0%
Applied rewrites79.7%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= t_m 1.32e-49)
(/
2.0
(*
(/ t_m l)
(*
(fma
(* (/ (fma 0.3333333333333333 (* t_m t_m) 1.0) l) k)
k
(* (* t_m (/ t_m l)) 2.0))
(* k k))))
(if (<= t_m 1e+94)
(* (/ l (* (* t_m t_m) (* t_m k))) (/ l k))
(* (/ l (* (* k t_m) (* k t_m))) (/ 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 (t_m <= 1.32e-49) {
tmp = 2.0 / ((t_m / l) * (fma(((fma(0.3333333333333333, (t_m * t_m), 1.0) / l) * k), k, ((t_m * (t_m / l)) * 2.0)) * (k * k)));
} else if (t_m <= 1e+94) {
tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k);
} else {
tmp = (l / ((k * t_m) * (k * t_m))) * (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 (t_m <= 1.32e-49) tmp = Float64(2.0 / Float64(Float64(t_m / l) * Float64(fma(Float64(Float64(fma(0.3333333333333333, Float64(t_m * t_m), 1.0) / l) * k), k, Float64(Float64(t_m * Float64(t_m / l)) * 2.0)) * Float64(k * k)))); elseif (t_m <= 1e+94) tmp = Float64(Float64(l / Float64(Float64(t_m * t_m) * Float64(t_m * k))) * Float64(l / k)); else tmp = Float64(Float64(l / Float64(Float64(k * t_m) * Float64(k * t_m))) * Float64(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[t$95$m, 1.32e-49], 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] / l), $MachinePrecision] * k), $MachinePrecision] * k + N[(N[(t$95$m * N[(t$95$m / l), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision] * N[(k * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 1e+94], N[(N[(l / N[(N[(t$95$m * t$95$m), $MachinePrecision] * N[(t$95$m * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / k), $MachinePrecision]), $MachinePrecision], N[(N[(l / N[(N[(k * t$95$m), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / t$95$m), $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.32 \cdot 10^{-49}:\\
\;\;\;\;\frac{2}{\frac{t\_m}{\ell} \cdot \left(\mathsf{fma}\left(\frac{\mathsf{fma}\left(0.3333333333333333, t\_m \cdot t\_m, 1\right)}{\ell} \cdot k, k, \left(t\_m \cdot \frac{t\_m}{\ell}\right) \cdot 2\right) \cdot \left(k \cdot k\right)\right)}\\
\mathbf{elif}\;t\_m \leq 10^{+94}:\\
\;\;\;\;\frac{\ell}{\left(t\_m \cdot t\_m\right) \cdot \left(t\_m \cdot k\right)} \cdot \frac{\ell}{k}\\
\mathbf{else}:\\
\;\;\;\;\frac{\ell}{\left(k \cdot t\_m\right) \cdot \left(k \cdot t\_m\right)} \cdot \frac{\ell}{t\_m}\\
\end{array}
\end{array}
if t < 1.3199999999999999e-49Initial program 48.9%
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 rewrites58.8%
Taylor expanded in k around 0
*-commutativeN/A
lower-*.f64N/A
Applied rewrites70.1%
if 1.3199999999999999e-49 < t < 1e94Initial program 71.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-*.f6454.1
Applied rewrites54.1%
Applied rewrites72.0%
Applied rewrites72.1%
if 1e94 < t Initial program 53.7%
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.9
Applied rewrites54.9%
Applied rewrites59.1%
Applied rewrites49.2%
Applied rewrites79.3%
Final simplification72.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 (<= (* l l) 2e-11)
(/ (/ (* (/ l k) (/ (/ l k) t_m)) t_m) t_m)
(* (/ l (* (* k t_m) (* k t_m))) (/ 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 ((l * l) <= 2e-11) {
tmp = (((l / k) * ((l / k) / t_m)) / t_m) / t_m;
} else {
tmp = (l / ((k * t_m) * (k * t_m))) * (l / t_m);
}
return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
real(8), intent (in) :: t_s
real(8), intent (in) :: t_m
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: tmp
if ((l * l) <= 2d-11) then
tmp = (((l / k) * ((l / k) / t_m)) / t_m) / t_m
else
tmp = (l / ((k * t_m) * (k * t_m))) * (l / t_m)
end if
code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
double tmp;
if ((l * l) <= 2e-11) {
tmp = (((l / k) * ((l / k) / t_m)) / t_m) / t_m;
} else {
tmp = (l / ((k * t_m) * (k * t_m))) * (l / t_m);
}
return t_s * tmp;
}
t\_m = math.fabs(t) t\_s = math.copysign(1.0, t) def code(t_s, t_m, l, k): tmp = 0 if (l * l) <= 2e-11: tmp = (((l / k) * ((l / k) / t_m)) / t_m) / t_m else: tmp = (l / ((k * t_m) * (k * t_m))) * (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 (Float64(l * l) <= 2e-11) tmp = Float64(Float64(Float64(Float64(l / k) * Float64(Float64(l / k) / t_m)) / t_m) / t_m); else tmp = Float64(Float64(l / Float64(Float64(k * t_m) * Float64(k * t_m))) * Float64(l / t_m)); end return Float64(t_s * tmp) end
t\_m = abs(t); t\_s = sign(t) * abs(1.0); function tmp_2 = code(t_s, t_m, l, k) tmp = 0.0; if ((l * l) <= 2e-11) tmp = (((l / k) * ((l / k) / t_m)) / t_m) / t_m; else tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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[N[(l * l), $MachinePrecision], 2e-11], N[(N[(N[(N[(l / k), $MachinePrecision] * N[(N[(l / k), $MachinePrecision] / t$95$m), $MachinePrecision]), $MachinePrecision] / t$95$m), $MachinePrecision] / t$95$m), $MachinePrecision], N[(N[(l / N[(N[(k * t$95$m), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / t$95$m), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;\ell \cdot \ell \leq 2 \cdot 10^{-11}:\\
\;\;\;\;\frac{\frac{\frac{\ell}{k} \cdot \frac{\frac{\ell}{k}}{t\_m}}{t\_m}}{t\_m}\\
\mathbf{else}:\\
\;\;\;\;\frac{\ell}{\left(k \cdot t\_m\right) \cdot \left(k \cdot t\_m\right)} \cdot \frac{\ell}{t\_m}\\
\end{array}
\end{array}
if (*.f64 l l) < 1.99999999999999988e-11Initial program 59.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-*.f6462.3
Applied rewrites62.3%
Applied rewrites65.5%
Applied rewrites58.3%
Applied rewrites85.6%
if 1.99999999999999988e-11 < (*.f64 l l) Initial program 43.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-*.f6446.8
Applied rewrites46.8%
Applied rewrites50.9%
Applied rewrites45.1%
Applied rewrites60.8%
Final simplification73.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 2.25e-23)
(/ 2.0 (* (* t_m (* k k)) (* (/ k l) (/ k l))))
(if (<= t_m 1e+94)
(* (/ l (* (* t_m t_m) (* t_m k))) (/ l k))
(* (/ l (* (* k t_m) (* k t_m))) (/ 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 (t_m <= 2.25e-23) {
tmp = 2.0 / ((t_m * (k * k)) * ((k / l) * (k / l)));
} else if (t_m <= 1e+94) {
tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k);
} else {
tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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 <= 2.25d-23) then
tmp = 2.0d0 / ((t_m * (k * k)) * ((k / l) * (k / l)))
else if (t_m <= 1d+94) then
tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k)
else
tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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 <= 2.25e-23) {
tmp = 2.0 / ((t_m * (k * k)) * ((k / l) * (k / l)));
} else if (t_m <= 1e+94) {
tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k);
} else {
tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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 <= 2.25e-23: tmp = 2.0 / ((t_m * (k * k)) * ((k / l) * (k / l))) elif t_m <= 1e+94: tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k) else: tmp = (l / ((k * t_m) * (k * t_m))) * (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 (t_m <= 2.25e-23) tmp = Float64(2.0 / Float64(Float64(t_m * Float64(k * k)) * Float64(Float64(k / l) * Float64(k / l)))); elseif (t_m <= 1e+94) tmp = Float64(Float64(l / Float64(Float64(t_m * t_m) * Float64(t_m * k))) * Float64(l / k)); else tmp = Float64(Float64(l / Float64(Float64(k * t_m) * Float64(k * t_m))) * Float64(l / 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 <= 2.25e-23) tmp = 2.0 / ((t_m * (k * k)) * ((k / l) * (k / l))); elseif (t_m <= 1e+94) tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k); else tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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, 2.25e-23], N[(2.0 / N[(N[(t$95$m * N[(k * k), $MachinePrecision]), $MachinePrecision] * N[(N[(k / l), $MachinePrecision] * N[(k / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 1e+94], N[(N[(l / N[(N[(t$95$m * t$95$m), $MachinePrecision] * N[(t$95$m * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / k), $MachinePrecision]), $MachinePrecision], N[(N[(l / N[(N[(k * t$95$m), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / t$95$m), $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.25 \cdot 10^{-23}:\\
\;\;\;\;\frac{2}{\left(t\_m \cdot \left(k \cdot k\right)\right) \cdot \left(\frac{k}{\ell} \cdot \frac{k}{\ell}\right)}\\
\mathbf{elif}\;t\_m \leq 10^{+94}:\\
\;\;\;\;\frac{\ell}{\left(t\_m \cdot t\_m\right) \cdot \left(t\_m \cdot k\right)} \cdot \frac{\ell}{k}\\
\mathbf{else}:\\
\;\;\;\;\frac{\ell}{\left(k \cdot t\_m\right) \cdot \left(k \cdot t\_m\right)} \cdot \frac{\ell}{t\_m}\\
\end{array}
\end{array}
if t < 2.24999999999999987e-23Initial program 49.7%
lift-*.f64N/A
lift-/.f64N/A
lift-pow.f64N/A
sqr-powN/A
lift-*.f64N/A
times-fracN/A
associate-*l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-evalN/A
lower-*.f64N/A
lower-/.f64N/A
lower-pow.f64N/A
metadata-eval22.5
Applied rewrites22.5%
Taylor expanded in t around 0
*-commutativeN/A
associate-*l*N/A
*-commutativeN/A
associate-*r/N/A
associate-/l*N/A
associate-*r*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
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-cos.f6464.8
Applied rewrites64.8%
Taylor expanded in k around 0
Applied rewrites62.8%
if 2.24999999999999987e-23 < t < 1e94Initial program 68.7%
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-*.f6445.9
Applied rewrites45.9%
Applied rewrites69.5%
Applied rewrites69.7%
if 1e94 < t Initial program 53.7%
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.9
Applied rewrites54.9%
Applied rewrites59.1%
Applied rewrites49.2%
Applied rewrites79.3%
Final simplification66.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 2.25e-23)
(/ (/ (* (/ l (* (* k k) t_m)) l) t_m) t_m)
(if (<= t_m 1e+94)
(* (/ l (* (* t_m t_m) (* t_m k))) (/ l k))
(* (/ l (* (* k t_m) (* k t_m))) (/ 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 (t_m <= 2.25e-23) {
tmp = (((l / ((k * k) * t_m)) * l) / t_m) / t_m;
} else if (t_m <= 1e+94) {
tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k);
} else {
tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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 <= 2.25d-23) then
tmp = (((l / ((k * k) * t_m)) * l) / t_m) / t_m
else if (t_m <= 1d+94) then
tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k)
else
tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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 <= 2.25e-23) {
tmp = (((l / ((k * k) * t_m)) * l) / t_m) / t_m;
} else if (t_m <= 1e+94) {
tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k);
} else {
tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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 <= 2.25e-23: tmp = (((l / ((k * k) * t_m)) * l) / t_m) / t_m elif t_m <= 1e+94: tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k) else: tmp = (l / ((k * t_m) * (k * t_m))) * (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 (t_m <= 2.25e-23) tmp = Float64(Float64(Float64(Float64(l / Float64(Float64(k * k) * t_m)) * l) / t_m) / t_m); elseif (t_m <= 1e+94) tmp = Float64(Float64(l / Float64(Float64(t_m * t_m) * Float64(t_m * k))) * Float64(l / k)); else tmp = Float64(Float64(l / Float64(Float64(k * t_m) * Float64(k * t_m))) * Float64(l / 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 <= 2.25e-23) tmp = (((l / ((k * k) * t_m)) * l) / t_m) / t_m; elseif (t_m <= 1e+94) tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k); else tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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, 2.25e-23], N[(N[(N[(N[(l / N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision]), $MachinePrecision] * l), $MachinePrecision] / t$95$m), $MachinePrecision] / t$95$m), $MachinePrecision], If[LessEqual[t$95$m, 1e+94], N[(N[(l / N[(N[(t$95$m * t$95$m), $MachinePrecision] * N[(t$95$m * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / k), $MachinePrecision]), $MachinePrecision], N[(N[(l / N[(N[(k * t$95$m), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / t$95$m), $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.25 \cdot 10^{-23}:\\
\;\;\;\;\frac{\frac{\frac{\ell}{\left(k \cdot k\right) \cdot t\_m} \cdot \ell}{t\_m}}{t\_m}\\
\mathbf{elif}\;t\_m \leq 10^{+94}:\\
\;\;\;\;\frac{\ell}{\left(t\_m \cdot t\_m\right) \cdot \left(t\_m \cdot k\right)} \cdot \frac{\ell}{k}\\
\mathbf{else}:\\
\;\;\;\;\frac{\ell}{\left(k \cdot t\_m\right) \cdot \left(k \cdot t\_m\right)} \cdot \frac{\ell}{t\_m}\\
\end{array}
\end{array}
if t < 2.24999999999999987e-23Initial program 49.7%
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.6
Applied rewrites55.6%
Applied rewrites59.0%
Applied rewrites66.3%
if 2.24999999999999987e-23 < t < 1e94Initial program 68.7%
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-*.f6445.9
Applied rewrites45.9%
Applied rewrites69.5%
Applied rewrites69.7%
if 1e94 < t Initial program 53.7%
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.9
Applied rewrites54.9%
Applied rewrites59.1%
Applied rewrites49.2%
Applied rewrites79.3%
Final simplification69.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 3.7e-21)
(/ l (* (* (* k k) t_m) (* (/ t_m l) t_m)))
(if (<= t_m 1e+94)
(* (/ l (* (* t_m t_m) (* t_m k))) (/ l k))
(* (/ l (* (* k t_m) (* k t_m))) (/ 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 (t_m <= 3.7e-21) {
tmp = l / (((k * k) * t_m) * ((t_m / l) * t_m));
} else if (t_m <= 1e+94) {
tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k);
} else {
tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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 <= 3.7d-21) then
tmp = l / (((k * k) * t_m) * ((t_m / l) * t_m))
else if (t_m <= 1d+94) then
tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k)
else
tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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 <= 3.7e-21) {
tmp = l / (((k * k) * t_m) * ((t_m / l) * t_m));
} else if (t_m <= 1e+94) {
tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k);
} else {
tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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 <= 3.7e-21: tmp = l / (((k * k) * t_m) * ((t_m / l) * t_m)) elif t_m <= 1e+94: tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k) else: tmp = (l / ((k * t_m) * (k * t_m))) * (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 (t_m <= 3.7e-21) tmp = Float64(l / Float64(Float64(Float64(k * k) * t_m) * Float64(Float64(t_m / l) * t_m))); elseif (t_m <= 1e+94) tmp = Float64(Float64(l / Float64(Float64(t_m * t_m) * Float64(t_m * k))) * Float64(l / k)); else tmp = Float64(Float64(l / Float64(Float64(k * t_m) * Float64(k * t_m))) * Float64(l / 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 <= 3.7e-21) tmp = l / (((k * k) * t_m) * ((t_m / l) * t_m)); elseif (t_m <= 1e+94) tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k); else tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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, 3.7e-21], N[(l / N[(N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision] * N[(N[(t$95$m / l), $MachinePrecision] * t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 1e+94], N[(N[(l / N[(N[(t$95$m * t$95$m), $MachinePrecision] * N[(t$95$m * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / k), $MachinePrecision]), $MachinePrecision], N[(N[(l / N[(N[(k * t$95$m), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / t$95$m), $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 3.7 \cdot 10^{-21}:\\
\;\;\;\;\frac{\ell}{\left(\left(k \cdot k\right) \cdot t\_m\right) \cdot \left(\frac{t\_m}{\ell} \cdot t\_m\right)}\\
\mathbf{elif}\;t\_m \leq 10^{+94}:\\
\;\;\;\;\frac{\ell}{\left(t\_m \cdot t\_m\right) \cdot \left(t\_m \cdot k\right)} \cdot \frac{\ell}{k}\\
\mathbf{else}:\\
\;\;\;\;\frac{\ell}{\left(k \cdot t\_m\right) \cdot \left(k \cdot t\_m\right)} \cdot \frac{\ell}{t\_m}\\
\end{array}
\end{array}
if t < 3.7000000000000002e-21Initial program 49.7%
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.6
Applied rewrites55.6%
Applied rewrites59.0%
Applied rewrites65.3%
if 3.7000000000000002e-21 < t < 1e94Initial program 68.7%
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-*.f6445.9
Applied rewrites45.9%
Applied rewrites69.5%
Applied rewrites69.7%
if 1e94 < t Initial program 53.7%
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.9
Applied rewrites54.9%
Applied rewrites59.1%
Applied rewrites49.2%
Applied rewrites79.3%
Final simplification68.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 3.2e-52)
(/ (* (/ l t_m) l) (* t_m (* (* k k) t_m)))
(if (<= t_m 1e+94)
(* (/ l (* (* t_m t_m) (* t_m k))) (/ l k))
(* (/ l (* (* k t_m) (* k t_m))) (/ 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 (t_m <= 3.2e-52) {
tmp = ((l / t_m) * l) / (t_m * ((k * k) * t_m));
} else if (t_m <= 1e+94) {
tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k);
} else {
tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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 <= 3.2d-52) then
tmp = ((l / t_m) * l) / (t_m * ((k * k) * t_m))
else if (t_m <= 1d+94) then
tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k)
else
tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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 <= 3.2e-52) {
tmp = ((l / t_m) * l) / (t_m * ((k * k) * t_m));
} else if (t_m <= 1e+94) {
tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k);
} else {
tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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 <= 3.2e-52: tmp = ((l / t_m) * l) / (t_m * ((k * k) * t_m)) elif t_m <= 1e+94: tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k) else: tmp = (l / ((k * t_m) * (k * t_m))) * (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 (t_m <= 3.2e-52) tmp = Float64(Float64(Float64(l / t_m) * l) / Float64(t_m * Float64(Float64(k * k) * t_m))); elseif (t_m <= 1e+94) tmp = Float64(Float64(l / Float64(Float64(t_m * t_m) * Float64(t_m * k))) * Float64(l / k)); else tmp = Float64(Float64(l / Float64(Float64(k * t_m) * Float64(k * t_m))) * Float64(l / 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 <= 3.2e-52) tmp = ((l / t_m) * l) / (t_m * ((k * k) * t_m)); elseif (t_m <= 1e+94) tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / k); else tmp = (l / ((k * t_m) * (k * t_m))) * (l / 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, 3.2e-52], N[(N[(N[(l / t$95$m), $MachinePrecision] * l), $MachinePrecision] / N[(t$95$m * N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 1e+94], N[(N[(l / N[(N[(t$95$m * t$95$m), $MachinePrecision] * N[(t$95$m * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / k), $MachinePrecision]), $MachinePrecision], N[(N[(l / N[(N[(k * t$95$m), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / t$95$m), $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 3.2 \cdot 10^{-52}:\\
\;\;\;\;\frac{\frac{\ell}{t\_m} \cdot \ell}{t\_m \cdot \left(\left(k \cdot k\right) \cdot t\_m\right)}\\
\mathbf{elif}\;t\_m \leq 10^{+94}:\\
\;\;\;\;\frac{\ell}{\left(t\_m \cdot t\_m\right) \cdot \left(t\_m \cdot k\right)} \cdot \frac{\ell}{k}\\
\mathbf{else}:\\
\;\;\;\;\frac{\ell}{\left(k \cdot t\_m\right) \cdot \left(k \cdot t\_m\right)} \cdot \frac{\ell}{t\_m}\\
\end{array}
\end{array}
if t < 3.2000000000000001e-52Initial program 48.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-*.f6455.0
Applied rewrites55.0%
Applied rewrites58.4%
Applied rewrites62.7%
if 3.2000000000000001e-52 < t < 1e94Initial program 71.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-*.f6454.1
Applied rewrites54.1%
Applied rewrites72.0%
Applied rewrites72.1%
if 1e94 < t Initial program 53.7%
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.9
Applied rewrites54.9%
Applied rewrites59.1%
Applied rewrites49.2%
Applied rewrites79.3%
Final simplification66.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 (* (* k k) t_m)))
(*
t_s
(if (<= t_m 2.8e-163)
(/ (* l l) (* (* t_2 t_m) t_m))
(if (<= t_m 7.2e+163)
(* l (/ (/ l t_2) (* t_m t_m)))
(/ (* l l) (* (* (* k t_m) (* k 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 t_2 = (k * k) * t_m;
double tmp;
if (t_m <= 2.8e-163) {
tmp = (l * l) / ((t_2 * t_m) * t_m);
} else if (t_m <= 7.2e+163) {
tmp = l * ((l / t_2) / (t_m * t_m));
} else {
tmp = (l * l) / (((k * t_m) * (k * 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) :: t_2
real(8) :: tmp
t_2 = (k * k) * t_m
if (t_m <= 2.8d-163) then
tmp = (l * l) / ((t_2 * t_m) * t_m)
else if (t_m <= 7.2d+163) then
tmp = l * ((l / t_2) / (t_m * t_m))
else
tmp = (l * l) / (((k * t_m) * (k * 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 t_2 = (k * k) * t_m;
double tmp;
if (t_m <= 2.8e-163) {
tmp = (l * l) / ((t_2 * t_m) * t_m);
} else if (t_m <= 7.2e+163) {
tmp = l * ((l / t_2) / (t_m * t_m));
} else {
tmp = (l * l) / (((k * t_m) * (k * 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): t_2 = (k * k) * t_m tmp = 0 if t_m <= 2.8e-163: tmp = (l * l) / ((t_2 * t_m) * t_m) elif t_m <= 7.2e+163: tmp = l * ((l / t_2) / (t_m * t_m)) else: tmp = (l * l) / (((k * t_m) * (k * 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) t_2 = Float64(Float64(k * k) * t_m) tmp = 0.0 if (t_m <= 2.8e-163) tmp = Float64(Float64(l * l) / Float64(Float64(t_2 * t_m) * t_m)); elseif (t_m <= 7.2e+163) tmp = Float64(l * Float64(Float64(l / t_2) / Float64(t_m * t_m))); else tmp = Float64(Float64(l * l) / Float64(Float64(Float64(k * t_m) * Float64(k * 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) t_2 = (k * k) * t_m; tmp = 0.0; if (t_m <= 2.8e-163) tmp = (l * l) / ((t_2 * t_m) * t_m); elseif (t_m <= 7.2e+163) tmp = l * ((l / t_2) / (t_m * t_m)); else tmp = (l * l) / (((k * t_m) * (k * 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_] := Block[{t$95$2 = N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision]}, N[(t$95$s * If[LessEqual[t$95$m, 2.8e-163], N[(N[(l * l), $MachinePrecision] / N[(N[(t$95$2 * t$95$m), $MachinePrecision] * t$95$m), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 7.2e+163], N[(l * N[(N[(l / t$95$2), $MachinePrecision] / N[(t$95$m * t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(l * l), $MachinePrecision] / N[(N[(N[(k * t$95$m), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision] * t$95$m), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
\begin{array}{l}
t_2 := \left(k \cdot k\right) \cdot t\_m\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 2.8 \cdot 10^{-163}:\\
\;\;\;\;\frac{\ell \cdot \ell}{\left(t\_2 \cdot t\_m\right) \cdot t\_m}\\
\mathbf{elif}\;t\_m \leq 7.2 \cdot 10^{+163}:\\
\;\;\;\;\ell \cdot \frac{\frac{\ell}{t\_2}}{t\_m \cdot t\_m}\\
\mathbf{else}:\\
\;\;\;\;\frac{\ell \cdot \ell}{\left(\left(k \cdot t\_m\right) \cdot \left(k \cdot t\_m\right)\right) \cdot t\_m}\\
\end{array}
\end{array}
\end{array}
if t < 2.8e-163Initial program 50.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-*.f6454.2
Applied rewrites54.2%
Applied rewrites56.3%
Applied rewrites51.5%
Applied rewrites58.7%
if 2.8e-163 < t < 7.19999999999999955e163Initial program 55.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-*.f6456.1
Applied rewrites56.1%
Applied rewrites64.8%
Applied rewrites64.8%
if 7.19999999999999955e163 < t Initial program 50.7%
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.6
Applied rewrites55.6%
Applied rewrites56.1%
Applied rewrites42.9%
Applied rewrites54.5%
Final simplification59.9%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= k 1.42e-173)
(* (/ l (* (* k t_m) (* k t_m))) (/ l t_m))
(/ (/ l t_m) (* (/ (* (* k k) t_m) 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 <= 1.42e-173) {
tmp = (l / ((k * t_m) * (k * t_m))) * (l / t_m);
} else {
tmp = (l / t_m) / ((((k * k) * t_m) / l) * 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 <= 1.42d-173) then
tmp = (l / ((k * t_m) * (k * t_m))) * (l / t_m)
else
tmp = (l / t_m) / ((((k * k) * t_m) / l) * 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 <= 1.42e-173) {
tmp = (l / ((k * t_m) * (k * t_m))) * (l / t_m);
} else {
tmp = (l / t_m) / ((((k * k) * t_m) / l) * 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 <= 1.42e-173: tmp = (l / ((k * t_m) * (k * t_m))) * (l / t_m) else: tmp = (l / t_m) / ((((k * k) * t_m) / 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 <= 1.42e-173) tmp = Float64(Float64(l / Float64(Float64(k * t_m) * Float64(k * t_m))) * Float64(l / t_m)); else tmp = Float64(Float64(l / t_m) / Float64(Float64(Float64(Float64(k * k) * t_m) / l) * 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 <= 1.42e-173) tmp = (l / ((k * t_m) * (k * t_m))) * (l / t_m); else tmp = (l / t_m) / ((((k * k) * t_m) / l) * 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, 1.42e-173], N[(N[(l / N[(N[(k * t$95$m), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / t$95$m), $MachinePrecision]), $MachinePrecision], N[(N[(l / t$95$m), $MachinePrecision] / N[(N[(N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision] / l), $MachinePrecision] * t$95$m), $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.42 \cdot 10^{-173}:\\
\;\;\;\;\frac{\ell}{\left(k \cdot t\_m\right) \cdot \left(k \cdot t\_m\right)} \cdot \frac{\ell}{t\_m}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{\ell}{t\_m}}{\frac{\left(k \cdot k\right) \cdot t\_m}{\ell} \cdot t\_m}\\
\end{array}
\end{array}
if k < 1.42e-173Initial program 55.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-*.f6455.5
Applied rewrites55.5%
Applied rewrites57.9%
Applied rewrites49.6%
Applied rewrites67.4%
if 1.42e-173 < k Initial program 45.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-*.f6453.8
Applied rewrites53.8%
Applied rewrites59.8%
Applied rewrites68.5%
Final simplification67.8%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= k 2.3e-167)
(* (/ l (* (* k t_m) (* k t_m))) (/ l t_m))
(/ (/ l t_m) (* (* (/ t_m l) 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 <= 2.3e-167) {
tmp = (l / ((k * t_m) * (k * t_m))) * (l / t_m);
} else {
tmp = (l / t_m) / (((t_m / l) * 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 <= 2.3d-167) then
tmp = (l / ((k * t_m) * (k * t_m))) * (l / t_m)
else
tmp = (l / t_m) / (((t_m / l) * 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 <= 2.3e-167) {
tmp = (l / ((k * t_m) * (k * t_m))) * (l / t_m);
} else {
tmp = (l / t_m) / (((t_m / l) * 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 <= 2.3e-167: tmp = (l / ((k * t_m) * (k * t_m))) * (l / t_m) else: tmp = (l / t_m) / (((t_m / l) * 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 <= 2.3e-167) tmp = Float64(Float64(l / Float64(Float64(k * t_m) * Float64(k * t_m))) * Float64(l / t_m)); else tmp = Float64(Float64(l / t_m) / Float64(Float64(Float64(t_m / l) * 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 <= 2.3e-167) tmp = (l / ((k * t_m) * (k * t_m))) * (l / t_m); else tmp = (l / t_m) / (((t_m / l) * 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, 2.3e-167], N[(N[(l / N[(N[(k * t$95$m), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / t$95$m), $MachinePrecision]), $MachinePrecision], N[(N[(l / t$95$m), $MachinePrecision] / N[(N[(N[(t$95$m / l), $MachinePrecision] * t$95$m), $MachinePrecision] * N[(k * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 2.3 \cdot 10^{-167}:\\
\;\;\;\;\frac{\ell}{\left(k \cdot t\_m\right) \cdot \left(k \cdot t\_m\right)} \cdot \frac{\ell}{t\_m}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{\ell}{t\_m}}{\left(\frac{t\_m}{\ell} \cdot t\_m\right) \cdot \left(k \cdot k\right)}\\
\end{array}
\end{array}
if k < 2.3000000000000001e-167Initial program 55.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.5
Applied rewrites55.5%
Applied rewrites57.8%
Applied rewrites49.6%
Applied rewrites67.2%
if 2.3000000000000001e-167 < k Initial program 45.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-*.f6453.8
Applied rewrites53.8%
Applied rewrites60.0%
Applied rewrites68.9%
Final simplification67.8%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= k 3.25e-142)
(* (/ l (* (* k (* t_m t_m)) t_m)) (/ l k))
(/ (* (/ l t_m) l) (* 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 (k <= 3.25e-142) {
tmp = (l / ((k * (t_m * t_m)) * t_m)) * (l / k);
} else {
tmp = ((l / t_m) * l) / (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 (k <= 3.25d-142) then
tmp = (l / ((k * (t_m * t_m)) * t_m)) * (l / k)
else
tmp = ((l / t_m) * l) / (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 (k <= 3.25e-142) {
tmp = (l / ((k * (t_m * t_m)) * t_m)) * (l / k);
} else {
tmp = ((l / t_m) * l) / (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 k <= 3.25e-142: tmp = (l / ((k * (t_m * t_m)) * t_m)) * (l / k) else: tmp = ((l / t_m) * l) / (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 (k <= 3.25e-142) tmp = Float64(Float64(l / Float64(Float64(k * Float64(t_m * t_m)) * t_m)) * Float64(l / k)); else tmp = Float64(Float64(Float64(l / t_m) * l) / Float64(t_m * Float64(Float64(k * 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 (k <= 3.25e-142) tmp = (l / ((k * (t_m * t_m)) * t_m)) * (l / k); else tmp = ((l / t_m) * l) / (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[k, 3.25e-142], N[(N[(l / N[(N[(k * N[(t$95$m * t$95$m), $MachinePrecision]), $MachinePrecision] * t$95$m), $MachinePrecision]), $MachinePrecision] * N[(l / k), $MachinePrecision]), $MachinePrecision], N[(N[(N[(l / t$95$m), $MachinePrecision] * l), $MachinePrecision] / N[(t$95$m * N[(N[(k * k), $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 3.25 \cdot 10^{-142}:\\
\;\;\;\;\frac{\ell}{\left(k \cdot \left(t\_m \cdot t\_m\right)\right) \cdot t\_m} \cdot \frac{\ell}{k}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{\ell}{t\_m} \cdot \ell}{t\_m \cdot \left(\left(k \cdot k\right) \cdot t\_m\right)}\\
\end{array}
\end{array}
if k < 3.25000000000000013e-142Initial program 56.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.2
Applied rewrites56.2%
Applied rewrites64.5%
Applied rewrites65.7%
if 3.25000000000000013e-142 < k Initial program 43.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-*.f6452.2
Applied rewrites52.2%
Applied rewrites58.6%
Applied rewrites64.0%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= k 2.85e+156)
(* (/ l (* (* t_m t_m) (* t_m k))) (/ l 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 <= 2.85e+156) {
tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / 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 <= 2.85d+156) then
tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / 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 <= 2.85e+156) {
tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / 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 <= 2.85e+156: tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / 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 <= 2.85e+156) tmp = Float64(Float64(l / Float64(Float64(t_m * t_m) * Float64(t_m * k))) * Float64(l / k)); else tmp = Float64(Float64(l * 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 <= 2.85e+156) tmp = (l / ((t_m * t_m) * (t_m * k))) * (l / 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, 2.85e+156], N[(N[(l / N[(N[(t$95$m * t$95$m), $MachinePrecision] * N[(t$95$m * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l / k), $MachinePrecision]), $MachinePrecision], N[(N[(l * l), $MachinePrecision] / N[(N[(N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision] * t$95$m), $MachinePrecision] * t$95$m), $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^{+156}:\\
\;\;\;\;\frac{\ell}{\left(t\_m \cdot t\_m\right) \cdot \left(t\_m \cdot k\right)} \cdot \frac{\ell}{k}\\
\mathbf{else}:\\
\;\;\;\;\frac{\ell \cdot \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 < 2.84999999999999999e156Initial program 53.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-*.f6456.5
Applied rewrites56.5%
Applied rewrites63.2%
Applied rewrites64.1%
if 2.84999999999999999e156 < k Initial program 37.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-*.f6441.3
Applied rewrites41.3%
Applied rewrites52.9%
Applied rewrites52.6%
Applied rewrites67.5%
Final simplification64.5%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= k 2.85e+156)
(* (/ l (* (* k (* t_m t_m)) t_m)) (/ l 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 <= 2.85e+156) {
tmp = (l / ((k * (t_m * t_m)) * t_m)) * (l / 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 <= 2.85d+156) then
tmp = (l / ((k * (t_m * t_m)) * t_m)) * (l / 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 <= 2.85e+156) {
tmp = (l / ((k * (t_m * t_m)) * t_m)) * (l / 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 <= 2.85e+156: tmp = (l / ((k * (t_m * t_m)) * t_m)) * (l / 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 <= 2.85e+156) tmp = Float64(Float64(l / Float64(Float64(k * Float64(t_m * t_m)) * t_m)) * Float64(l / k)); else tmp = Float64(Float64(l * 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 <= 2.85e+156) tmp = (l / ((k * (t_m * t_m)) * t_m)) * (l / 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, 2.85e+156], N[(N[(l / N[(N[(k * N[(t$95$m * t$95$m), $MachinePrecision]), $MachinePrecision] * t$95$m), $MachinePrecision]), $MachinePrecision] * N[(l / k), $MachinePrecision]), $MachinePrecision], N[(N[(l * l), $MachinePrecision] / N[(N[(N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision] * t$95$m), $MachinePrecision] * t$95$m), $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^{+156}:\\
\;\;\;\;\frac{\ell}{\left(k \cdot \left(t\_m \cdot t\_m\right)\right) \cdot t\_m} \cdot \frac{\ell}{k}\\
\mathbf{else}:\\
\;\;\;\;\frac{\ell \cdot \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 < 2.84999999999999999e156Initial program 53.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-*.f6456.5
Applied rewrites56.5%
Applied rewrites63.2%
Applied rewrites64.1%
if 2.84999999999999999e156 < k Initial program 37.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-*.f6441.3
Applied rewrites41.3%
Applied rewrites52.9%
Applied rewrites52.6%
Applied rewrites67.5%
Final simplification64.5%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= k 2.85e+156)
(* (/ l (* t_m t_m)) (/ l (* (* t_m 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 <= 2.85e+156) {
tmp = (l / (t_m * t_m)) * (l / ((t_m * 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 <= 2.85d+156) then
tmp = (l / (t_m * t_m)) * (l / ((t_m * 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 <= 2.85e+156) {
tmp = (l / (t_m * t_m)) * (l / ((t_m * 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 <= 2.85e+156: tmp = (l / (t_m * t_m)) * (l / ((t_m * 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 <= 2.85e+156) tmp = Float64(Float64(l / Float64(t_m * t_m)) * Float64(l / Float64(Float64(t_m * k) * k))); else tmp = Float64(Float64(l * 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 <= 2.85e+156) tmp = (l / (t_m * t_m)) * (l / ((t_m * 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, 2.85e+156], N[(N[(l / N[(t$95$m * t$95$m), $MachinePrecision]), $MachinePrecision] * N[(l / N[(N[(t$95$m * k), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(l * l), $MachinePrecision] / N[(N[(N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision] * t$95$m), $MachinePrecision] * t$95$m), $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^{+156}:\\
\;\;\;\;\frac{\ell}{t\_m \cdot t\_m} \cdot \frac{\ell}{\left(t\_m \cdot k\right) \cdot k}\\
\mathbf{else}:\\
\;\;\;\;\frac{\ell \cdot \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 < 2.84999999999999999e156Initial program 53.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-*.f6456.5
Applied rewrites56.5%
Applied rewrites59.2%
Applied rewrites62.1%
if 2.84999999999999999e156 < k Initial program 37.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-*.f6441.3
Applied rewrites41.3%
Applied rewrites52.9%
Applied rewrites52.6%
Applied rewrites67.5%
Final simplification62.7%
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
:precision binary64
(*
t_s
(if (<= k 5.2e+166)
(/ (* l l) (* (* (* k t_m) (* k t_m)) t_m))
(/ (* 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 <= 5.2e+166) {
tmp = (l * l) / (((k * t_m) * (k * t_m)) * t_m);
} 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 <= 5.2d+166) then
tmp = (l * l) / (((k * t_m) * (k * t_m)) * t_m)
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 <= 5.2e+166) {
tmp = (l * l) / (((k * t_m) * (k * t_m)) * t_m);
} 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 <= 5.2e+166: tmp = (l * l) / (((k * t_m) * (k * t_m)) * t_m) 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 <= 5.2e+166) tmp = Float64(Float64(l * l) / Float64(Float64(Float64(k * t_m) * Float64(k * t_m)) * t_m)); else tmp = Float64(Float64(l * 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 <= 5.2e+166) tmp = (l * l) / (((k * t_m) * (k * t_m)) * t_m); 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, 5.2e+166], N[(N[(l * l), $MachinePrecision] / N[(N[(N[(k * t$95$m), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision] * t$95$m), $MachinePrecision]), $MachinePrecision], N[(N[(l * l), $MachinePrecision] / N[(N[(N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision] * t$95$m), $MachinePrecision] * t$95$m), $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.2 \cdot 10^{+166}:\\
\;\;\;\;\frac{\ell \cdot \ell}{\left(\left(k \cdot t\_m\right) \cdot \left(k \cdot t\_m\right)\right) \cdot t\_m}\\
\mathbf{else}:\\
\;\;\;\;\frac{\ell \cdot \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 < 5.1999999999999999e166Initial program 53.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-*.f6456.4
Applied rewrites56.4%
Applied rewrites59.1%
Applied rewrites51.9%
Applied rewrites57.7%
if 5.1999999999999999e166 < k Initial program 36.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-*.f6440.6
Applied rewrites40.6%
Applied rewrites53.1%
Applied rewrites52.8%
Applied rewrites64.9%
Final simplification58.4%
t\_m = (fabs.f64 t) t\_s = (copysign.f64 #s(literal 1 binary64) t) (FPCore (t_s t_m l k) :precision binary64 (* t_s (/ (* l l) (* (* (* k t_m) (* k 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) {
return t_s * ((l * l) / (((k * t_m) * (k * t_m)) * 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) / (((k * t_m) * (k * t_m)) * 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) / (((k * t_m) * (k * t_m)) * 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) / (((k * t_m) * (k * t_m)) * t_m))
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) return Float64(t_s * Float64(Float64(l * l) / Float64(Float64(Float64(k * t_m) * Float64(k * t_m)) * 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) / (((k * t_m) * (k * t_m)) * t_m)); end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * N[(N[(l * l), $MachinePrecision] / N[(N[(N[(k * t$95$m), $MachinePrecision] * N[(k * t$95$m), $MachinePrecision]), $MachinePrecision] * t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)
\\
t\_s \cdot \frac{\ell \cdot \ell}{\left(\left(k \cdot t\_m\right) \cdot \left(k \cdot t\_m\right)\right) \cdot t\_m}
\end{array}
Initial program 51.7%
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.9
Applied rewrites54.9%
Applied rewrites58.6%
Applied rewrites52.0%
Applied rewrites58.0%
Final simplification58.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 (/ (* 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) {
return t_s * ((l * l) / (((k * k) * t_m) * (t_m * 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) / (((k * k) * t_m) * (t_m * 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) / (((k * k) * t_m) * (t_m * 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) / (((k * k) * t_m) * (t_m * t_m)))
t\_m = abs(t) t\_s = copysign(1.0, t) function code(t_s, t_m, l, k) return Float64(t_s * Float64(Float64(l * l) / Float64(Float64(Float64(k * k) * t_m) * Float64(t_m * 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) / (((k * k) * t_m) * (t_m * t_m))); end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * N[(N[(l * l), $MachinePrecision] / N[(N[(N[(k * k), $MachinePrecision] * t$95$m), $MachinePrecision] * N[(t$95$m * 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 \frac{\ell \cdot \ell}{\left(\left(k \cdot k\right) \cdot t\_m\right) \cdot \left(t\_m \cdot t\_m\right)}
\end{array}
Initial program 51.7%
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.9
Applied rewrites54.9%
Applied rewrites58.6%
Applied rewrites52.0%
Applied rewrites52.0%
herbie shell --seed 2024322
(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))))