This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A333259 #21 Aug 29 2021 01:56:23 %S A333259 0,0,1,2,1,5,3,9,3,3,7,19,7,35,11,7,7,71,15,135,15,15,23,263,31,15,47, %T A333259 15,31,527,63,1039,47,31,95,31,111,2079,143,63,95,4127,191,8255,63,63, %U A333259 351,16447,223,63,191,127,319,32895,383,127,191,255,639,65663 %N A333259 a(n) = Sum_{p in L(n)} 2^(pi(p) - 1) where L(n) is the set of all least primes in partitions of n into prime parts. %C A333259 In other words, convert the indices of primes p_i in row n of A333238 to 1s in the (i - 1)-th place to create a binary number m; convert m to decimal. %C A333259 The number of prime partitions of n is shown by A000607(n), which in terms of this sequence equates to the number of 1s in a(n), written in binary. %C A333259 For prime p, row p of A333238 includes p itself as the largest term, since p is the sum of (p); here we find a(p) >= 2^(p - 1). More specifically, a(2) = 1, a(p) > 2^(p - 1) for p odd. %C A333259 For n = A330507(m), a(n) = 2^m - 1, the smallest n with this value in this sequence. %H A333259 Alois P. Heinz, <a href="/A333259/b333259.txt">Table of n, a(n) for n = 0..10000</a> %e A333259 The least primes among the prime partitions of 5 are 2 and 5, cf. the 2 prime partitions of 5: (5) and (3, 2), thus row 5 of A333238 lists {2, 5}. Convert these to their indices gives us {1, 3}, take the sum of 2^(1 - 1) and 2^(3 - 1) = 2^0 + 2^2 = 1 + 4 = 5, thus a(5) = 5. %e A333259 The least primes among the prime partitions of 6 are 2 and 3, cf. the two prime partitions of 6, (3, 3), and (2, 2, 2), thus row 6 of A333238 lists {2, 3}. Convert these to their indices: {1, 2}, take the sum of 2^(1 - 1) and 2^(2 - 1) = 2^0 + 2^1 = 1 + 2 = 3, thus a(6) = 3. %e A333259 Row 7 of A333238 contains {2, 7} because there are 3 prime partitions of 7: (7), (5, 2), (3, 2, 2). Note that 2 is the smallest part of the latter two partitions, thus only 2 and 7 are distinct. Convert to indices: {1, 4}, sum 2^(1 - 1) and 2^(4 - 1) = 2^0 + 2^3 = 1 + 8 = 9, therefore a(7) = 9. %e A333259 Table plotting prime p in row n of A333238 at pi(p) place, intervening primes missing from row n are shown by "." as a place holder. We convert the indices of these primes into a binary number to obtain the terms of this sequence: %e A333259 n Row n of A333238 binary a(n) %e A333259 --------------------------------------- %e A333259 2: 2 => 1 => 1 %e A333259 3: . 3 => 10 => 2 %e A333259 4: 2 => 1 => 1 %e A333259 5: 2 . 5 => 101 => 5 %e A333259 6: 2 3 => 11 => 3 %e A333259 7: 2 . . 7 => 1001 => 9 %e A333259 8: 2 3 => 11 => 3 %e A333259 9: 2 3 => 11 => 3 %e A333259 10: 2 3 5 => 111 => 7 %e A333259 11: 2 3 . . 11 => 10011 => 19 %e A333259 12: 2 3 5 => 111 => 7 %e A333259 ... %p A333259 b:= proc(n, p, t) option remember; `if`(n=0, 1, `if`(p>n, 0, (q-> %p A333259 add(b(n-p*j, q, 1), j=1..n/p)*t^p+b(n, q, t))(nextprime(p)))) %p A333259 end: %p A333259 a:= proc(n) option remember; (p-> add(`if`(isprime(i) and coeff(p, x, %p A333259 i)>0, 2^(numtheory[pi](i)-1), 0), i=2..degree(p)))(b(n, 2, x)) %p A333259 end: %p A333259 seq(a(n), n=0..63); # _Alois P. Heinz_, Mar 16 2020 %t A333259 Block[{a, m = 59, s}, a = ConstantArray[{}, m]; s = {Prime@ PrimePi@ m}; Do[If[# <= m, If[FreeQ[a[[#]], Last@ s], a = ReplacePart[a, # -> Append[a[[#]], Last@ s]], Nothing]; AppendTo[s, Last@ s], If[Last@ s == 2, s = DeleteCases[s, 2]; If[Length@ s == 0, Break[], s = MapAt[Prime[PrimePi[#] - 1] &, s, -1]], s = MapAt[Prime[PrimePi[#] - 1] &, s, -1]]] &@ Total[s], {i, Infinity}]; {0, 0}~Join~Map[Total[2^(-1 + PrimePi@ #)] &, Rest[Union /@ a]]] %Y A333259 Cf. A000607, A000720, A330507, A333129, A333238. %K A333259 nonn,look %O A333259 0,4 %A A333259 _Michael De Vlieger_, Mar 16 2020