OFFSET
1,2
COMMENTS
EXAMPLE
The terms together with their prime indices begin:
1: {}
2: {1}
4: {1,1}
8: {1,1,1}
10: {1,3}
16: {1,1,1,1}
20: {1,1,3}
32: {1,1,1,1,1}
40: {1,1,1,3}
50: {1,3,3}
64: {1,1,1,1,1,1}
80: {1,1,1,1,3}
100: {1,1,3,3}
110: {1,3,5}
128: {1,1,1,1,1,1,1}
160: {1,1,1,1,1,3}
200: {1,1,1,3,3}
220: {1,1,3,5}
250: {1,3,3,3}
256: {1,1,1,1,1,1,1,1}
320: {1,1,1,1,1,1,3}
400: {1,1,1,1,3,3}
MATHEMATICA
primeMS[n_]:=If[n==1, {}, Flatten[Cases[FactorInteger[n], {p_, k_}:>Table[PrimePi[p], {k}]]]];
normQ[m_]:=Or[m=={}, Union[m]==Range[Max[m]]];
Select[Range[1000], normQ[(primeMS[#]+1)/2]&]
PROG
(Python)
from itertools import count
from functools import lru_cache
from sympy import prime, integer_log
from oeis_sequences.OEISsequences import bisection
def A356232(n):
@lru_cache(maxsize=None)
def g(x, m): return sum(g(x//(prime((m<<1)+1)**i), m-1) for i in range(1, integer_log(x, prime((m<<1)+1))[0]+1)) if m else x.bit_length()-1
def f(x):
c, p = n-1+x, 1
for k in count(0):
p *= prime((k<<1)+1)
if p>x:
break
c -= g(x, k)
return c
return bisection(f, n, n) # Chai Wah Wu, Mar 21 2026
(Python)
from itertools import islice
from heapq import heappop, heappush
from sympy import primefactors, nextprime
def A356232_gen(): # generator of terms if first n terms of sequence is desired
h, hset = [2], {2}
yield 1
while True:
yield (m:=heappop(h))
ps = primefactors(m)
ps.append(nextprime(max(ps), 2))
for p in ps:
mp = m*p
if mp not in hset:
heappush(h, mp)
hset.add(mp)
CROSSREFS
The partitions with these Heinz numbers are counted by A053251.
This is the odd restriction of A055932.
A subset of A066208 (numbers with all odd prime indices).
This is the sorted version of A356603.
These are the positions of first appearances of rows in A356226. Other statistics are:
- minimum: A356227
- maximum: A356228
- bisected length: A356229
- standard composition: A356230
- Heinz number: A356231
- positions of first appearances: A356232 (this sequence)
A003963 multiplies together the prime indices.
KEYWORD
nonn
AUTHOR
Gus Wiseman, Aug 20 2022
STATUS
approved
