OFFSET
1,1
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.
A mode in a multiset is an element that appears at least as many times as each of the others. For example, the modes in {a,a,b,b,b,c,d,d,d} are {b,d}.
The median of a multiset is either the middle part (for odd length), or the average of the two middle parts (for even length).
FORMULA
EXAMPLE
The terms together with their prime indices begin:
2: {1} 29: {10} 79: {22}
3: {2} 31: {11} 81: {2,2,2,2}
4: {1,1} 32: {1,1,1,1,1} 83: {23}
5: {3} 37: {12} 89: {24}
7: {4} 41: {13} 90: {1,2,2,3}
8: {1,1,1} 43: {14} 97: {25}
9: {2,2} 47: {15} 101: {26}
11: {5} 49: {4,4} 103: {27}
13: {6} 53: {16} 107: {28}
16: {1,1,1,1} 59: {17} 109: {29}
17: {7} 61: {18} 113: {30}
19: {8} 64: {1,1,1,1,1,1} 121: {5,5}
23: {9} 67: {19} 125: {3,3,3}
25: {3,3} 71: {20} 127: {31}
27: {2,2,2} 73: {21} 128: {1,1,1,1,1,1,1}
MATHEMATICA
prix[n_]:=If[n==1, {}, Flatten[Cases[FactorInteger[n], {p_, k_}:>Table[PrimePi[p], {k}]]]];
modes[ms_]:=Select[Union[ms], Count[ms, #]>=Max@@Length/@Split[ms]&];
Select[Range[100], {Mean[prix[#]]}=={Median[prix[#]]}==modes[prix[#]]&]
CROSSREFS
KEYWORD
nonn
AUTHOR
Gus Wiseman, Jun 23 2023
STATUS
approved