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 A307534 #12 Oct 20 2024 13:01:09 %S A307534 110,170,230,310,374,410,470,506,590,670,682,730,782,830,902,935,970, %T A307534 1030,1034,1054,1090,1265,1270,1298,1370,1394,1426,1474,1490,1570, %U A307534 1598,1606,1670,1705,1790,1826,1886,1910,1955,1970,2006,2110,2134,2162,2255,2266 %N A307534 Heinz numbers of strict integer partitions with 3 parts, all of which are odd. %C A307534 The enumeration of these partitions by sum is given by A001399. %C A307534 The Heinz number of an integer partition (y_1,...,y_k) is prime(y_1)*...*prime(y_k). %e A307534 The sequence of terms together with their prime indices begins: %e A307534 110: {1,3,5} %e A307534 170: {1,3,7} %e A307534 230: {1,3,9} %e A307534 310: {1,3,11} %e A307534 374: {1,5,7} %e A307534 410: {1,3,13} %e A307534 470: {1,3,15} %e A307534 506: {1,5,9} %e A307534 590: {1,3,17} %e A307534 670: {1,3,19} %e A307534 682: {1,5,11} %e A307534 730: {1,3,21} %e A307534 782: {1,7,9} %e A307534 830: {1,3,23} %e A307534 902: {1,5,13} %e A307534 935: {3,5,7} %e A307534 970: {1,3,25} %e A307534 1030: {1,3,27} %e A307534 1034: {1,5,15} %e A307534 1054: {1,7,11} %t A307534 Select[Range[1000],SquareFreeQ[#]&&PrimeNu[#]==3&&OddQ[Times@@PrimePi/@First/@FactorInteger[#]]&] %o A307534 (Python) %o A307534 from math import isqrt %o A307534 from sympy import primepi, primerange, integer_nthroot, nextprime %o A307534 def A307534(n): %o A307534 def bisection(f,kmin=0,kmax=1): %o A307534 while f(kmax) > kmax: kmax <<= 1 %o A307534 while kmax-kmin > 1: %o A307534 kmid = kmax+kmin>>1 %o A307534 if f(kmid) <= kmid: %o A307534 kmax = kmid %o A307534 else: %o A307534 kmin = kmid %o A307534 return kmax %o A307534 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)))) %o A307534 return bisection(f,n,n) # _Chai Wah Wu_, Oct 20 2024 %Y A307534 Cf. A001221, A001222, A001399, A005117, A007304, A014612, A037144, A051037, A056239, A080193, A080257, A112798, A143207, A304636. %K A307534 nonn %O A307534 1,1 %A A307534 _Gus Wiseman_, Apr 13 2019