Search: a292257 -id:a292257
|
|
|
|
1, 1, 1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 1, 0, 1, 0, 0, 0, 0, 0, 1, 0, 1
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1
|
|
LINKS
|
|
|
FORMULA
|
a(n) = 1 if A192895(n) <= 0, and 0 otherwise.
|
|
EXAMPLE
|
For n=25, its proper divisors are 1 and 5, in binary "1" and "101", so the total number of 1's in them is 3, while 25 in binary is "11001", with binary weight 3, thus as A292257(25) <= A000120(25), a(25) = 1.
For n=55, its proper divisors are 1, 5 and 11, in binary "1", "101" and "1011", so the total number of 1's in them is 6, while 55 in binary is "110111", with binary weight 5, thus as A292257(55) > A000120(55), a(55) = 0.
|
|
MATHEMATICA
|
a[n_] := If[DivisorSum[n, DigitCount[#, 2, 1] &] > 2 * DigitCount[n, 2, 1], 0, 1]; Array[a, 100] (* Amiram Eldar, Jul 20 2023 *)
|
|
PROG
|
(PARI)
A292257(n) = sumdiv(n, d, (d<n)*hammingweight(d));
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,base
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|
|
A093653
|
|
Total number of 1's in binary expansion of all divisors of n.
|
|
+10
34
|
|
|
1, 2, 3, 3, 3, 6, 4, 4, 5, 6, 4, 9, 4, 8, 9, 5, 3, 10, 4, 9, 9, 8, 5, 12, 6, 8, 9, 12, 5, 18, 6, 6, 8, 6, 9, 15, 4, 8, 10, 12, 4, 18, 5, 12, 15, 10, 6, 15, 7, 12, 9, 12, 5, 18, 11, 16, 10, 10, 6, 27, 6, 12, 17, 7, 8, 16, 4, 9, 10, 18, 5, 20, 4, 8, 16, 12, 11, 20, 6, 15, 12, 8, 5, 27, 9, 10, 12
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
LINKS
|
|
|
FORMULA
|
a(2^n) = n+1 (End)
|
|
EXAMPLE
|
a(8) = 4 because the divisors of 8 are [1, 2, 4, 8] and in binary: 1, 10, 100, 1000, so four 1's.
|
|
MAPLE
|
a:= n-> add(add(i, i=Bits[Split](d)), d=numtheory[divisors](n)):
|
|
MATHEMATICA
|
Table[Plus@@DigitCount[Divisors[n], 2, 1], {n, 75}] (* Alonso del Arte, Sep 01 2013 *)
|
|
PROG
|
(PARI) a(n) = {my(v = valuation(n, 2), n = (n>>v)); sumdiv(n, d, hammingweight(d)) * (v + 1)} \\ David A. Corneth, Feb 15 2023
(Python)
from sympy import divisors
def a(n): return sum(bin(d).count("1") for d in divisors(n))
(Python)
from sympy import divisors
def A093653(n): return sum(d.bit_count() for d in divisors(n, generator=True))
|
|
CROSSREFS
|
Cf. A226590 (number of 0's in binary expansion of all divisors of n).
Cf. A182627 (number of digits in binary expansion of all divisors of n).
Cf. A034690 (a decimal equivalent).
|
|
KEYWORD
|
base,easy,nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|
|
|
|
1, 2, 2, 6, 2, 36, 2, 30, 12, 60, 2, 2700, 2, 180, 120, 210, 2, 7560, 2, 6300, 360, 252, 2, 661500, 20, 420, 168, 94500, 2, 23814000, 2, 2310, 504, 132, 600, 43659000, 2, 396, 840, 2425500, 2, 187110000, 2, 207900, 352800, 1980, 2, 560290500, 60, 194040, 264, 485100, 2, 115259760, 840, 254677500, 792, 4620, 2, 264737261250000, 2, 13860
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
LINKS
|
|
|
FORMULA
|
a(n) = Product_{d|n, d<n} A019565(d).
Other identities.
For n >= 1:
|
|
PROG
|
(PARI)
A019565(n) = {my(j, v); factorback(Mat(vector(if(n, #n=vecextract(binary(n), "-1..1")), j, [prime(j), n[j]])~))}; \\ From A019565
A293214(n) = { my(m=1); fordiv(n, d, if(d < n, m *= A019565(d))); m; };
|
|
CROSSREFS
|
Cf. also A293216, A293221, A293222, A293225, A293231, A293442, A300830, A300831, A300832, A300833, A300834.
|
|
KEYWORD
|
nonn,base
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|
|
|
|
-1, 0, -1, 1, -1, 2, -2, 2, 1, 2, -2, 5, -2, 2, 1, 3, -1, 6, -2, 5, 3, 2, -3, 8, 0, 2, 1, 6, -3, 10, -4, 4, 4, 2, 3, 11, -2, 2, 2, 8, -2, 12, -3, 6, 7, 2, -4, 11, 1, 6, 1, 6, -3, 10, 1, 10, 2, 2, -4, 19, -4, 2, 5, 5, 4, 12, -2, 5, 4, 12, -3, 16, -2, 2, 8, 6
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,6
|
|
LINKS
|
|
|
FORMULA
|
a(n) = Sum(A000120(d): 1 <= d < n and n mod d = 0) - A000120(n); see A175522 for motivation and more information;
|
|
MATHEMATICA
|
a[n_] := DivisorSum[n, Total[IntegerDigits[#, 2]]*(-1)^Boole[# == n]&]; Array[a, 80] (* Jean-François Alcover, Dec 05 2015, adapted from PARI *)
|
|
PROG
|
(Haskell)
a192895 n =
sum (map a000120 $ filter ((== 0) . (mod n)) [1..n-1]) - a000120 n
a192895_list = map a192895 [1..]
(Python)
from sympy import divisors
def A192895(n): return sum((d.bit_count() if d<n else -d.bit_count()) for d in divisors(n, generator=True)) # Chai Wah Wu, Jul 25 2023
|
|
CROSSREFS
|
|
|
KEYWORD
|
sign
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|
|
|
|
0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 2, 0, 0, 0, 2, 0, 2, 0, 2, 0, 0, 0, 4, 0, 0, 1, 2, 0, 3, 0, 3, 0, 0, 0, 5, 0, 0, 0, 4, 0, 3, 0, 2, 2, 0, 0, 6, 0, 1, 0, 2, 0, 4, 0, 4, 0, 0, 0, 7, 0, 0, 2, 4, 0, 3, 0, 2, 0, 3, 0, 8, 0, 0, 1, 2, 0, 3, 0, 6, 2, 0, 0, 7, 0, 0, 0, 4, 0, 7, 0, 2, 0, 0, 0, 8, 0, 2, 2, 4, 0, 3, 0, 4, 3, 0, 0, 8, 0, 3, 0, 6, 0, 3, 0, 2, 2, 0, 0, 11
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,12
|
|
LINKS
|
|
|
FORMULA
|
a(n) = Sum_{d|n, d<n} (1-A294905(d)).
|
|
MATHEMATICA
|
q[n_] := DivisorSum[n, DigitCount[#, 2, 1] &] > 2 * DigitCount[n, 2, 1]; a[n_] := DivisorSum[n, 1 &, # < n && q[#] &]; Array[a, 100] (* Amiram Eldar, Jul 20 2023 *)
|
|
PROG
|
(PARI)
A292257(n) = sumdiv(n, d, (d<n)*hammingweight(d));
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,base
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|
|
A305793
|
|
Restricted growth sequence transform of A305792, a filter sequence constructed from binary expansions of the proper divisors of n.
|
|
+10
9
|
|
|
1, 2, 2, 3, 2, 4, 2, 5, 6, 7, 2, 8, 2, 9, 10, 11, 2, 12, 2, 13, 14, 15, 2, 16, 17, 15, 10, 18, 2, 19, 2, 20, 21, 7, 22, 23, 2, 15, 21, 24, 2, 25, 2, 26, 27, 28, 2, 29, 30, 31, 10, 26, 2, 32, 33, 34, 21, 28, 2, 35, 2, 36, 37, 38, 33, 39, 2, 13, 40, 41, 2, 42, 2, 43, 44, 26, 45, 46, 2, 47, 48, 43, 2, 49, 50, 51, 40, 52, 2, 53, 45, 54, 55, 56, 33, 57, 2, 58, 59
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
LINKS
|
|
|
FORMULA
|
For all i, j:
|
|
PROG
|
(PARI)
up_to = 65537;
rgs_transform(invec) = { my(om = Map(), outvec = vector(length(invec)), u=1); for(i=1, length(invec), if(mapisdefined(om, invec[i]), my(pp = mapget(om, invec[i])); outvec[i] = outvec[pp] , mapput(om, invec[i], i); outvec[i] = u; u++ )); outvec; };
A305792(n) = { my(m=1); fordiv(n, d, if(d<n, m *= prime(A286622(d)-1))); (m); };
v305793 = rgs_transform(vector(up_to, n, A305792(n)));
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|
|
A300836
|
|
a(n) is the total number of terms (1-digits) in Zeckendorf representation of all proper divisors of n.
|
|
+10
8
|
|
|
0, 1, 1, 2, 1, 3, 1, 4, 2, 3, 1, 7, 1, 4, 3, 5, 1, 7, 1, 7, 4, 4, 1, 11, 2, 3, 4, 8, 1, 10, 1, 7, 4, 5, 4, 14, 1, 5, 3, 11, 1, 10, 1, 8, 7, 4, 1, 15, 3, 8, 5, 7, 1, 12, 4, 12, 5, 4, 1, 21, 1, 5, 7, 10, 3, 13, 1, 8, 4, 11, 1, 19, 1, 4, 8, 10, 5, 10, 1, 16, 7, 5, 1, 20, 5, 5, 4, 12, 1, 20, 4, 10, 5, 4, 5, 21, 1, 9, 10, 16, 1, 13, 1, 11, 10
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,4
|
|
LINKS
|
|
|
FORMULA
|
|
|
EXAMPLE
|
For n=12, its proper divisors are 1, 2, 3, 4 and 6. Zeckendorf-representations (A014417) of these numbers are 1, 10, 100, 101 and 1001. Total number of 1's present is 7, thus a(12) = 7.
|
|
PROG
|
(PARI)
A072649(n) = { my(m); if(n<1, 0, m=0; until(fibonacci(m)>n, m++); m-2); }; \\ From A072649
A007895(n) = { my(s=0); while(n>0, s++; n -= fibonacci(1+A072649(n))); (s); }
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|
|
|
|
0, 1, 1, 2, 1, 3, 1, 2, 2, 3, 1, 3, 1, 3, 3, 2, 1, 3, 1, 3, 3, 3, 1, 3, 2, 3, 2, 3, 1, 4, 1, 2, 3, 3, 3, 3, 1, 3, 3, 3, 1, 4, 1, 3, 3, 3, 1, 3, 2, 4, 3, 3, 1, 3, 3, 3, 3, 3, 1, 4, 1, 3, 3, 2, 3, 4, 1, 3, 3, 4, 1, 3, 1, 3, 4, 3, 3, 4, 1, 3, 2, 3, 1, 4, 3, 3, 3, 3, 1, 4, 3, 3, 3, 3, 3, 3, 1, 3, 3, 4, 1, 4, 1, 3, 4, 3, 1, 3, 1, 4, 3, 3, 1, 4, 3, 3, 3, 3, 3, 4
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,4
|
|
LINKS
|
|
|
FORMULA
|
|
|
MATHEMATICA
|
q[n_] := DivisorSum[n, DigitCount[#, 2, 1] &] <= 2*DigitCount[n, 2, 1]; a[n_] := DivisorSum[n, 1 &, # < n && q[#] &]; Array[a, 100] (* Amiram Eldar, Jul 20 2023 *)
|
|
PROG
|
(PARI)
A292257(n) = sumdiv(n, d, (d<n)*hammingweight(d));
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,base
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|
|
|
|
0, 0, 0, 1, 0, 1, 0, 2, 1, 1, 0, 3, 0, 1, 1, 3, 0, 3, 0, 3, 1, 1, 0, 5, 0, 1, 2, 3, 0, 4, 0, 4, 1, 1, 1, 6, 0, 1, 1, 5, 0, 4, 0, 3, 3, 1, 0, 7, 1, 2, 1, 3, 0, 5, 1, 5, 1, 1, 0, 8, 0, 1, 3, 5, 1, 4, 0, 3, 1, 4, 0, 9, 0, 1, 2, 3, 1, 4, 0, 7, 3, 1, 0, 8, 1, 1, 1, 5, 0, 8, 1, 3, 1, 1, 0, 9, 0, 3, 3, 5, 0, 4, 0, 5, 4, 1, 0, 9, 0, 4, 0, 7, 0, 4, 1, 3, 3, 1, 0, 12
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,8
|
|
COMMENTS
|
Number of terms of A175526 that divide n.
|
|
LINKS
|
|
|
FORMULA
|
|
|
MATHEMATICA
|
q[n_] := DivisorSum[n, DigitCount[#, 2, 1] &] > 2 * DigitCount[n, 2, 1]; a[n_] := DivisorSum[n, 1 &, q[#] &]; Array[a, 100] (* Amiram Eldar, Jul 20 2023 *)
|
|
PROG
|
(PARI)
A292257(n) = sumdiv(n, d, (d<n)*hammingweight(d));
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,base
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|
|
|
|
1, 2, 2, 2, 2, 3, 2, 2, 2, 3, 2, 3, 2, 3, 3, 2, 2, 3, 2, 3, 3, 3, 2, 3, 3, 3, 2, 3, 2, 4, 2, 2, 3, 3, 3, 3, 2, 3, 3, 3, 2, 4, 2, 3, 3, 3, 2, 3, 2, 4, 3, 3, 2, 3, 3, 3, 3, 3, 2, 4, 2, 3, 3, 2, 3, 4, 2, 3, 3, 4, 2, 3, 2, 3, 4, 3, 3, 4, 2, 3, 2, 3, 2, 4, 3, 3, 3, 3, 2, 4, 3, 3, 3, 3, 4, 3, 2, 3, 3, 4, 2, 4, 2, 3, 4, 3, 2, 3, 2, 4, 4, 3, 2, 4, 3, 3, 3, 3, 4, 4
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
COMMENTS
|
Number of terms of A257691 that divide n.
|
|
LINKS
|
|
|
FORMULA
|
|
|
MATHEMATICA
|
q[n_] := DivisorSum[n, DigitCount[#, 2, 1] &] <= 2*DigitCount[n, 2, 1]; a[n_] := DivisorSum[n, 1 &, q[#] &]; Array[a, 100] (* Amiram Eldar, Jul 20 2023 *)
|
|
PROG
|
(PARI)
A292257(n) = sumdiv(n, d, (d<n)*hammingweight(d));
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,base
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
Search completed in 0.010 seconds
|