OFFSET
1,2
COMMENTS
A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798, sum A056239, length A001222.
A number's prime signature is the sequence of positive exponents in its prime factorization, which is row n of A124010, length A001221, sum A001222.
Also Heinz numbers of integer partitions with all even parts and all odd multiplicities, counted by A055922 aerated.
All terms are odd. - Michael S. Branicky, Mar 12 2022
FORMULA
EXAMPLE
The terms together with their prime indices begin:
1 = 1
3 = prime(2)^1
7 = prime(4)^1
13 = prime(6)^1
19 = prime(8)^1
21 = prime(4)^1 prime(2)^1
27 = prime(2)^3
29 = prime(10)^1
37 = prime(12)^1
39 = prime(6)^1 prime(2)^1
43 = prime(14)^1
53 = prime(16)^1
57 = prime(8)^1 prime(2)^1
61 = prime(18)^1
71 = prime(20)^1
MATHEMATICA
Select[Range[100], And@@EvenQ/@PrimePi/@First/@FactorInteger[#]&&And@@OddQ/@Last/@FactorInteger[#]&]
PROG
(Python)
from sympy import factorint, primepi
def ok(n):
if n%2 == 0: return False
return all(primepi(p)%2==0 and e%2==1 for p, e in factorint(n).items())
print([k for k in range(318) if ok(k)]) # Michael S. Branicky, Mar 12 2022
CROSSREFS
KEYWORD
nonn
AUTHOR
Gus Wiseman, Mar 11 2022
STATUS
approved