A374252 Irregular triangle read by rows where T(n,k) is the number of permutations of the prime factors of n with k runs.
1, 1, 1, 0, 1, 0, 2, 1, 1, 0, 0, 1, 0, 0, 2, 1, 0, 2, 1, 1, 0, 2, 0, 2, 1, 0, 0, 0, 1, 0, 2, 1, 1, 0, 2, 1, 0, 2, 0, 2, 1, 0, 2, 2, 0, 1, 0, 0, 2, 1, 0, 0, 0, 2, 1, 1, 0, 0, 6, 1, 1, 0, 0, 0, 0, 0, 2, 0, 2, 0, 2, 0, 2, 2, 2, 1, 0, 2, 0, 2, 0, 2, 2, 0, 1
Offset: 2
Examples
The T(36,3) = 2 permutations are (2,3,3,2) and (3,2,2,3). Row n = 72 counts the following permutations: . (2,2,2,3,3) (2,2,3,3,2) (2,2,3,2,3) (2,3,2,3,2) (3,3,2,2,2) (2,3,3,2,2) (2,3,2,2,3) (3,2,2,2,3) (3,2,2,3,2) (3,2,3,2,2) Triangle begins: 1: 2: 1 3: 1 4: 1 0 5: 1 6: 0 2 7: 1 8: 1 0 0 9: 1 0 10: 0 2 11: 1 12: 0 2 1 13: 1 14: 0 2 15: 0 2 16: 1 0 0 0 17: 1 18: 0 2 1 19: 1 20: 0 2 1
Crossrefs
Row-lengths are A001222.
Row-sums are A008480 (number of permutations of prime factors).
Column k = 1 is A069513.
For compositions instead of permutations of prime factors we have A238130.
Position of the last positive term in row n is A373957(n).
The number of zeros at the end of row n is A374246(n).
The number of nonzero terms in row n is A374247(n).
A001221 counts distinct prime factors.
A003242 counts run-compressed compositions, i.e., anti-runs.
A333755 counts compositions by number of runs.
Programs
-
Mathematica
prifacs[n_]:=If[n==1,{},Flatten[ConstantArray@@@FactorInteger[n]]]; Table[Length[Select[Permutations[prifacs[n]], Length[Split[#]]==k&]],{n,100},{k,PrimeOmega[n]}]
Comments