A091892 Numbers k having only one partition into parts which are a sum of exactly as many distinct powers of 2 as there are 1's in the binary representation of k.
0, 1, 3, 5, 7, 11, 13, 15, 19, 23, 27, 29, 31, 39, 43, 47, 51, 55, 59, 61, 63, 79, 87, 91, 95, 103, 107, 111, 115, 119, 123, 125, 127, 143, 159, 175, 183, 187, 191, 207, 215, 219, 223, 231, 235, 239, 243, 247, 251, 253, 255, 287, 303, 319, 335, 351, 367, 375, 379, 383, 399
Offset: 1
Keywords
Examples
From _David A. Corneth_, Oct 03 2022: (Start) 11 is in the sequence as numbers with 3 bits and are <= 11 are 7, 11. The only partition of 11 into parts of size 7 and 11 are 11. 9 is not in the sequence as numbers with 2 bits, like 9, are 3, 5, 6, 9. 9 can be partitioned as 3+3+3 = 3+6 = 9 into these parts. As these are 3 > 1 partitions, 9 is not here. (End)
Links
- David A. Corneth, Table of n, a(n) for n = 1..2053 (first 375 terms from Andrew Howroyd, n = 376..764 from Alois P. Heinz)
Programs
-
Mathematica
etr[p_] := Module[{b}, b[n_] := b[n] = If[n == 0, 1, Sum[Sum[d*p[d], {d, Divisors[j]}] b[n - j], {j, 1, n}]/n]; b]; EulerT[v_List] := With[{q = etr[v[[#]]&]}, q /@ Range[Length[v]]]; okQ[k_] := If[k == 0, True, If[EvenQ[k], False, EulerT[Table[DigitCount[j, 2, 1] == DigitCount[k, 2, 1] // Boole, {j, 1, k}]][[k]] == 1]]; Reap[For[k = 0, k <= 1000, k++, If[okQ[k], Print[k]; Sow[k]]]][[2, 1]] (* Jean-François Alcover, Dec 17 2021 *)
-
PARI
EulerT(v)={Vec(exp(x*Ser(dirmul(v,vector(#v,n,1/n))))-1, -#v)} upto(n)={Set(concat(vector(logint(n,2)+1, k, my(u=vector(n,i,hammingweight(i)==k), v=EulerT(u)); select(i->u[i]&&v[i]==1, [1..n], 1))))} \\ Andrew Howroyd, Apr 20 2021
Formula
A091891(a(n)) = 1.
Extensions
Terms a(40) and beyond from Andrew Howroyd, Apr 20 2021
a(1)=0 inserted by Alois P. Heinz, Dec 12 2021
Comments