login
Heptagonal numbers (or 7-gonal numbers): n*(5*n-3)/2 which are products of five distinct primes.
0

%I #31 May 28 2022 18:23:51

%S 32890,48790,102718,167314,236698,239785,260338,330694,360430,389470,

%T 455182,749938,884170,932386,960070,1007110,1104565,1334806,1397638,

%U 1423930,1488802,1515934,1610818,1679770,1721005,1741810,1952314,2046205,2312167,2365363,2473570,2503501,2513518,2558842

%N Heptagonal numbers (or 7-gonal numbers): n*(5*n-3)/2 which are products of five distinct primes.

%C A squarefree subsequence of heptagonal numbers.

%e 32890 = 2*5*11*13*23 = 115(5*115-3)/2.

%e 48790 = 2*5*7*17*41 = 140(5*140-3)/2.

%e 102718 = 2*7*11*23*29 = 203(5*203-3)/2.

%e 167314 = 2*7*17*19*37 = 259(5*259-3)/2.

%t Select[Table[n*(5*n - 3)/2, {n, 1, 1000}], FactorInteger[#][[;; , 2]] == {1, 1, 1, 1, 1} &] (* _Amiram Eldar_, Apr 17 2022 *)

%o (Python)

%o from sympy import factorint

%o from itertools import count, islice

%o def agen():

%o for h in (n*(5*n-3)//2 for n in count(1)):

%o f = factorint(h, multiple=True)

%o if len(f) == len(set(f)) == 5: yield h

%o print(list(islice(agen(), 34))) # _Michael S. Branicky_, May 28 2022

%Y Intersection of A000566 and A046387.

%K nonn

%O 1,1

%A _Massimo Kofler_, Apr 17 2022