%I #6 Jul 08 2024 16:41:37
%S 0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,
%T 0,2,0,0,0,1,0,0,0,1,1,0,0,1,0,1,0,1,0,1,0,1,0,0,0,1,0,0,1,0,0,0,0,1,
%U 0,0,0,3,0,0,1,1,0,0,0,1,0,0,0,1,0,0,0
%N The greatest number of runs possible in a permutation of the prime factors of n (A373957) minus the number of distinct such factors (A001221).
%C If n has separable prime factors (A335433), then a(n) = A001222(n) - A001221(n) = A046660(n). A multiset is separable iff it has an anti-run permutation (meaning there are no adjacent equal parts).
%F a(n) = A373957(n) - A001221(n).
%e The runs of the 6 permutations of the prime factors of 36 are:
%e ((2,2),(3,3))
%e ((2),(3),(2),(3))
%e ((2),(3,3),(2))
%e ((3),(2,2),(3))
%e ((3),(2),(3),(2))
%e ((3,3),(2,2))
%e The longest length is 4, so a(36) = 4 - 2 = 2.
%t prifacs[n_]:=If[n==1,{},Flatten[ConstantArray@@@FactorInteger[n]]];
%t Table[Max@@Table[Length[Split[y]], {y,Permutations[prifacs[n]]}]-PrimeNu[n],{n,100}]
%Y Positions of first appearances appear to be A026549.
%Y Positions of nonzero terms are A126706, complement A303554.
%Y This is an opposite version of A373957.
%Y The sister-sequence A374246 uses A001222 instead of A001221.
%Y This is the number of nonzero terms in row n of A374252.
%Y A003242 counts run-compressed compositions, i.e., anti-runs.
%Y A008480 counts permutations of prime factors, by number of runs A374252.
%Y A027746 lists prime factors, row-sums A001414.
%Y A027748 is run-compression of prime factors, row-sums A008472.
%Y A304038 is run-compression of prime indices, row-sums A066328.
%Y A333755 counts compositions by number of runs.
%Y A335433 lists separable numbers, complement A335448.
%Y A374250 maximizes sum of run-compression, for indices A373956.
%Y Cf. A007947, A046660, A124767, A151821, A238130, A373951, A374251.
%K nonn
%O 1,36
%A _Gus Wiseman_, Jul 07 2024