login
A307534
Heinz numbers of strict integer partitions with 3 parts, all of which are odd.
10
110, 170, 230, 310, 374, 410, 470, 506, 590, 670, 682, 730, 782, 830, 902, 935, 970, 1030, 1034, 1054, 1090, 1265, 1270, 1298, 1370, 1394, 1426, 1474, 1490, 1570, 1598, 1606, 1670, 1705, 1790, 1826, 1886, 1910, 1955, 1970, 2006, 2110, 2134, 2162, 2255, 2266
OFFSET
1,1
COMMENTS
The enumeration of these partitions by sum is given by A001399.
The Heinz number of an integer partition (y_1,...,y_k) is prime(y_1)*...*prime(y_k).
EXAMPLE
The sequence of terms together with their prime indices begins:
110: {1,3,5}
170: {1,3,7}
230: {1,3,9}
310: {1,3,11}
374: {1,5,7}
410: {1,3,13}
470: {1,3,15}
506: {1,5,9}
590: {1,3,17}
670: {1,3,19}
682: {1,5,11}
730: {1,3,21}
782: {1,7,9}
830: {1,3,23}
902: {1,5,13}
935: {3,5,7}
970: {1,3,25}
1030: {1,3,27}
1034: {1,5,15}
1054: {1,7,11}
MATHEMATICA
Select[Range[1000], SquareFreeQ[#]&&PrimeNu[#]==3&&OddQ[Times@@PrimePi/@First/@FactorInteger[#]]&]
PROG
(Python)
from math import isqrt
from sympy import primepi, primerange, integer_nthroot, nextprime
def A307534(n):
def bisection(f, kmin=0, kmax=1):
while f(kmax) > kmax: kmax <<= 1
while kmax-kmin > 1:
kmid = kmax+kmin>>1
if f(kmid) <= kmid:
kmax = kmid
else:
kmin = kmid
return kmax
def f(x): return int(n+x-sum((primepi(x//(k*m))+1>>1)-(b+1>>1) for a, k in filter(lambda x:x[0]&1, enumerate(primerange(2, integer_nthroot(x, 3)[0]+1), 1)) for b, m in filter(lambda x:x[0]&1, enumerate(primerange(nextprime(k)+1, isqrt(x//k)+1), a+2))))
return bisection(f, n, n) # Chai Wah Wu, Oct 20 2024
KEYWORD
nonn,changed
AUTHOR
Gus Wiseman, Apr 13 2019
STATUS
approved