%I #102 Nov 24 2021 01:26:30
%S 17,20,24,27,31,33,35,40,41,42,44,49,50,54
%N Maximum k for which a partition of the product of the first k primes (the k-th primorial) into the sum of two products gives a sum that yields only n composites from that sum down to 1+1=2 by sequential deletion of the largest prime.
%C This is an extension of the solution of the maximum problem given at the beginning of the EXAMPLE section.
%C Number of ways the n-th primorial can be partitioned into two parts and summed to achieve a maximum number of primes (minimum number of composites), by a variant of the (main) linked program: 2, 5, 1, 3, 3, 2, 4, 1, 2, 7, 7, 1, 2 and 1. This program -- the longer of the ones actually linked to -- produces terms starting at a(1). a(0) is handled fully in the example. An auxiliary program also at the link gives the unique a(13) case in a decompression. - _James G. Merickel_, Aug 01 2015
%H James G. Merickel, <a href="/A187749/a187749.txt">PARI programs 1) for terms beyond a(0) and 2) for a(13) decompression (an auxiliary program)</a>
%e a(0): Both 2*5*11*23*37*41*43*59 + 3*7*13*17*19*29*31*47*53 and 2*3*5*11*13*19*29*41*43*47*53 + 7*17*23*31*37*59 are primes such that repeatedly removing the largest prime down to the sum 1 + 1 yields a prime, and these are the only examples for the primes through prime(17)=59. That is, for either of the above cases, neither portion may be multiplied by 61 to give a prime sum. Therefore, a(0) = 17, and this means -- identically -- that none of the primes counted in A103787(18) naturally link by deletion to primes counted in A103787(k) in a chain from k equals 17 down to 1, but that at least one of the primes counted in A103787(17) -- both of the above -- do link in such a way to primes counted in A103787(k) for k equals 16 down to 1.
%e a(2): 2*3*5*11*13*19*29*41*43*47*53*59*71*79*89 + 7*17*23*31*37*61*67*73*83 is prime and removing the primes sequentially yields a composite only after removal of 79 and then of 61. This twosome of composites is uniquely fewest for partitions of this many of the first primes (24), and no such sum that includes the next prime (97) yields fewer than 3 composites by deletion. So, a(2) = 24.
%Y Cf. A019565, A103787.
%K nonn,more,hard
%O 0,1
%A _James G. Merickel_, Jan 03 2013
%E Program expanded and moved to link by _James G. Merickel_, Aug 01 2015