OFFSET
1,1
COMMENTS
The Heinz number of a partition (y_1,...,y_k) is prime(y_1)*...*prime(y_k). This gives a bijective correspondence between positive integers and integer partitions.
We define the alternating product of a sequence (y_1,...,y_k) to be Product_i y_i^((-1)^(i-1)).
Also numbers whose multiset of prime indices has odd length and integer alternating product, where a prime index of n is a number m such that prime(m) divides n.
EXAMPLE
The terms and their prime indices begin:
2: {1} 29: {10} 61: {18}
3: {2} 31: {11} 63: {2,2,4}
5: {3} 32: {1,1,1,1,1} 67: {19}
7: {4} 37: {12} 68: {1,1,7}
8: {1,1,1} 41: {13} 71: {20}
11: {5} 42: {1,2,4} 72: {1,1,1,2,2}
12: {1,1,2} 43: {14} 73: {21}
13: {6} 44: {1,1,5} 75: {2,3,3}
17: {7} 45: {2,2,3} 76: {1,1,8}
18: {1,2,2} 47: {15} 78: {1,2,6}
19: {8} 48: {1,1,1,1,2} 79: {22}
20: {1,1,3} 50: {1,3,3} 80: {1,1,1,1,3}
23: {9} 52: {1,1,6} 83: {23}
27: {2,2,2} 53: {16} 89: {24}
28: {1,1,4} 59: {17} 92: {1,1,9}
MATHEMATICA
primeMS[n_]:=If[n==1, {}, Flatten[Cases[FactorInteger[n], {p_, k_}:>Table[PrimePi[p], {k}]]]];
altprod[q_]:=Product[q[[i]]^(-1)^(i-1), {i, Length[q]}];
Select[Range[100], OddQ[PrimeOmega[#]]&&IntegerQ[altprod[primeMS[#]]]&]
CROSSREFS
The reciprocal version is A000290.
Allowing any alternating product <= 1 gives A001105.
Allowing any alternating product gives A026424.
Factorizations of this type are counted by A347441.
These partitions are counted by A347444.
Allowing any length gives A347454.
Allowing any alternating product > 1 gives A347465.
A027193 counts odd-length partitions.
A344606 counts alternating permutations of prime indices.
A347446 counts partitions with integer alternating product.
A347461 counts possible alternating products of partitions.
A347462 counts possible reverse-alternating products of partitions.
KEYWORD
nonn
AUTHOR
Gus Wiseman, Sep 24 2021
STATUS
approved