login
A334082
a(n) is the number of binomial coefficients C(n,k), with 0<=k<=n, that are not practical.
3
0, 0, 2, 0, 4, 2, 6, 1, 2, 4, 6, 2, 8, 10, 14, 0, 6, 2, 8, 5, 10, 10, 20, 2, 8, 14, 14, 6, 16, 14, 30, 0, 2, 4, 6, 2, 6, 10, 16, 4, 10, 10, 24, 16, 14, 20, 36, 4, 8, 10, 16, 12, 30, 14, 30, 6, 14, 18, 34, 14, 34, 38, 62, 0, 2, 2, 6, 10, 12, 10, 24, 2, 8, 14, 14
OFFSET
1,3
LINKS
Paolo Leonetti and Carlo Sanna, Practical numbers among the binomial coefficients, arXiv:1905.12023 [math.NT], 2019.
MAPLE
A334082 := proc(n)
local a, k ;
a := 0 ;
for k from 0 to n do
if not isA005153(binomial(n, k)) then # reuses code of A005153
a := a+1 ;
end if;
end do:
a ;
end proc:
seq(A334082(n), n=1..100) ; # R. J. Mathar, Jul 07 2023
MATHEMATICA
PracticalQ[n_] := Module[{f, p, e, prod = 1, ok = True}, If[n < 1 || (n > 1 && OddQ[n]), False, If[n == 1, True, f = FactorInteger[n]; {p, e} = Transpose[f]; Do[If[p[[i]] > 1 + DivisorSigma[1, prod], ok = False; Break[]]; prod = prod*p[[i]]^e[[i]], {i, Length[p]}]; ok]]];
a[n_] := Select[Table[Binomial[n, k], {k, 0, n}], !PracticalQ[#]&] // Length;
Table[a[n], {n, 1, 100}] (* Jean-François Alcover, Aug 11 2023, after T. D. Noe in A005153 *)
PROG
(PARI) a(n) = sum(k=0, n, !is_A005153(binomial(n, k)));
(Python)
from math import comb
from sympy import factorint
def A334082(n):
m = 0
for k in range(1, n):
c = comb(n, k)
l = (~c & c-1).bit_length()
if l>0:
P = (1<<l+1)-1
for p, e in factorint(c>>l).items():
if p > 1+P:
break
P *= (p**(e+1)-1)//(p-1)
else:
continue
m += 1
else:
m += 1
return m # Chai Wah Wu, Jul 05 2023
CROSSREFS
Cf. A005153 (practical numbers), A007318 (binomial coefficients).
Sequence in context: A153733 A083218 A203908 * A346612 A352528 A307704
KEYWORD
nonn
AUTHOR
Michel Marcus, Apr 14 2020
STATUS
approved