login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A097889
Numbers that are products of (at least two) consecutive primes.
14
6, 15, 30, 35, 77, 105, 143, 210, 221, 323, 385, 437, 667, 899, 1001, 1147, 1155, 1517, 1763, 2021, 2310, 2431, 2491, 3127, 3599, 4087, 4199, 4757, 5005, 5183, 5767, 6557, 7387, 7429, 8633, 9797, 10403, 11021, 11663, 12317, 12673, 14351, 15015, 16637, 17017
OFFSET
1,1
COMMENTS
Subsequence of A073485; A073490(a(n)) = 0. - Reinhard Zumkeller, Nov 20 2004
A proper subset of A073485. - Robert G. Wilson v, Jun 11 2010
A192280(a(n)) * (1 - A010051(a(n))) = 1. - Reinhard Zumkeller, Aug 26 2011 [corrected by Jason Yuen, Aug 29 2024]
The Heinz numbers of the partitions into at least 2 consecutive parts. The Heinz number of an integer partition p = [p_1, p_2, ..., p_r] is defined as Product(p_j-th prime, j=1...r) (concept used by Alois P. Heinz in A215366 as an "encoding" of a partition). Examples: (i) 105 (=3*5*7) is in the sequence because it is the Heinz number of the partition [2,3,4]; (ii) 108 (= 2*2*3*3*3) is not in the sequence because it is the Heinz number of the partition [1,1,2,2,2]. - Emeric Deutsch, Oct 02 2015
LINKS
FORMULA
a(n) ~ n^2 log^2 n. - Charles R Greathouse IV, Oct 24 2012
EXAMPLE
1001 = 7 * 11 * 13.
MAPLE
isA097889 := proc(n)
local plist, p, i ;
plist := sort(convert(numtheory[factorset](n), list)) ;
if nops(plist) < 2 then
return false;
end if;
for i from 1 to nops(plist) do
p := op(i, plist) ;
if modp(n, p^2) = 0 then
return false;
end if;
if i > 1 then
if nextprime(op(i-1, plist)) <> p then
return false;
end if;
end if;
end do:
true;
end proc:
for n from 1 to 1000 do
if isA097889(n) then
printf("%d, ", n);
end if;
end do: # R. J. Mathar, Jan 12 2016
MATHEMATICA
a = {}; Do[ AppendTo[a, Apply[ Times, (Prime /@ Partition[ Range[30], n, i]), 1]], {n, 2, 6}, {i, n - 1}]; Take[ Union[ Flatten[ a]], 45] (* Robert G. Wilson v, Sep 24 2004 *)
PROG
(Haskell)
import Data.Set (singleton, deleteFindMin, insert)
a097889 n = a097889_list !! (n-1)
a097889_list = f $ singleton (6, 2, 3) where
f s = y : f (insert (w, p, q') $ insert (w `div` p, a151800 p, q') s')
where w = y * q'; q' = a151800 q
((y, p, q), s') = deleteFindMin s
-- Reinhard Zumkeller, May 12 2015, Aug 26 2011
(PARI) list(lim)=my(v=List(), p, t); for(e=2, log(lim+.5)\log(2), p=1; t=prod(i=1, e-1, prime(i)); forprime(q=prime(e), lim, t*=q/p; if(t>lim, next(2)); listput(v, t); p=nextprime(p+1))); vecsort(Vec(v)) \\ Charles R Greathouse IV, Oct 24 2012
(Python)
import heapq
from sympy import sieve
sieve.extend(10**6)
primes = list(sieve._list)
def prime(n): return primes[n-1]
def aupton(terms, verbose=False):
p = prime(1)*prime(2); h = [(p, 1, 2)]; nextcount = 3; alst = []
while len(alst) < terms:
(v, s, l) = heapq.heappop(h)
alst.append(v)
if verbose: print(f"{v}, [= Prod_{{i = {s}..{l}}} prime(i)]")
if v >= p:
p *= prime(nextcount)
heapq.heappush(h, (p, 1, nextcount))
nextcount += 1
v //= prime(s); s += 1; l += 1; v *= prime(l)
heapq.heappush(h, (v, s, l))
return alst
print(aupton(45)) # Michael S. Branicky, Jun 15 2021
CROSSREFS
Cf. A050936.
Intersection of A073485 and A002808.
Sequence in context: A048749 A355527 A336905 * A256874 A250121 A024802
KEYWORD
nonn,easy
AUTHOR
Bart la Bastide (bart(AT)xs4all.nl), Sep 21 2004
EXTENSIONS
More terms from Robert G. Wilson v, Sep 24 2004
Data corrected for n > 41 by Reinhard Zumkeller, Aug 26 2011
STATUS
approved