# Greetings from The On-Line Encyclopedia of Integer Sequences! http://oeis.org/
Search: id:a371906
Showing 1-1 of 1
%I A371906 #7 Apr 16 2024 13:55:22
%S A371906 0,1,3,2,6,5,13,12,14,11,27,24,56,49,55,54,118,117,245,240,250,235,
%T A371906 491,488,492,461,463,454,966,961,1985,1984,2002,1939,1951,1948,3996,
%U A371906 3869,3903,3898,7994,7985,16177,16160,16166,15911,32295,32292,32300,32297,32363
%N A371906 a(n) = sum of 2^(k-1) such that floor(n/prime(k)) is odd.
%C A371906 The only powers of 2 in the sequence are likely 1 and 2.
%H A371906 Michael De Vlieger, Table of n, a(n) for n = 1..10000
%H A371906 Michael De Vlieger, Plot powers 2^(i-1) that sum to a(n) at (x,y) = (n,i) for n = 1..2048.
%e A371906 a(1) = 0 since n = 1 is the empty product.
%e A371906 a(2) = 1 since for n = prime(1) = 2, floor(2/2) = 1 is odd. Therefore a(2) = 2^(1-1) = 1.
%e A371906 a(3) = 3 since for n = 3 and prime(1) = 2, floor(3/2) = 1 is odd, and for prime(2) = 3, floor(3/3) = 1 is odd. Hence a(3) = 2^(1-1) + 2^(2-1) = 1 + 2 = 3.
%e A371906 a(4) = 2 since for n = 4 and prime(1) = 2, floor(4/2) = 2 is even, but for prime(2) = 3, floor(4/3) = 1 is odd. Therefore, a(n) = 2^(2-1) = 2.
%e A371906 a(5) = 6 since for n = 5, though floor(5/2) = 2 is even, floor(5/3) and floor(5/5) are both odd. Therefore, a(n) = 2^(2-1) + 2^(3-1) = 2 + 4 = 6, etc.
%e A371906 Table relating a(n) with b(n), diagramming powers of 2 with "x" that sum to a(n), or prime factors with "x" that produce b(n), where b(n) = A372000(n).
%e A371906 Power of 2
%e A371906 n a(n) 01234567 b(n)
%e A371906 ----------------------------
%e A371906 1 0 . 1
%e A371906 2 1 x 2
%e A371906 3 3 xx 6
%e A371906 4 2 .x 3
%e A371906 5 6 .xx 15
%e A371906 6 5 x.x 10
%e A371906 7 13 x.xx 70
%e A371906 8 12 ..xx 35
%e A371906 9 14 .xxx 105
%e A371906 10 11 xx.x 42
%e A371906 11 27 xx.xx 462
%e A371906 12 24 ...xx 77
%e A371906 13 56 ...xxx 1001
%e A371906 14 49 x...xx 286
%e A371906 15 55 xxx.xx 4290
%e A371906 16 54 .xx.xx 2145
%e A371906 17 118 .xx.xxx 36465
%e A371906 18 117 x.x.xxx 24310
%e A371906 19 245 x.x.xxxx 461890
%e A371906 20 240 ....xxxx 46189
%e A371906 ----------------------------
%e A371906 1111
%e A371906 23571379
%e A371906 Prime factor
%t A371906 Table[Total[2^(-1 + Select[Range@ PrimePi[n], OddQ@ Quotient[n, Prime[#]] &])], {n, 50}]
%o A371906 (PARI) a(n) = sum(k=1, primepi(n), if (n\prime(k) % 2, 2^(k-1))); \\ _Michel Marcus_, Apr 16 2024
%Y A371906 Cf. A008336, A260850, A372000.
%K A371906 nonn,easy
%O A371906 1,3
%A A371906 _Michael De Vlieger_, Apr 15 2024
# Content is available under The OEIS End-User License Agreement: http://oeis.org/LICENSE