login
A329747
Runs-resistance of the sequence of prime indices of n.
26
0, 0, 0, 1, 0, 2, 0, 1, 1, 2, 0, 3, 0, 2, 2, 1, 0, 3, 0, 3, 2, 2, 0, 3, 1, 2, 1, 3, 0, 2, 0, 1, 2, 2, 2, 2, 0, 2, 2, 3, 0, 2, 0, 3, 3, 2, 0, 3, 1, 3, 2, 3, 0, 3, 2, 3, 2, 2, 0, 4, 0, 2, 3, 1, 2, 2, 0, 3, 2, 2, 0, 3, 0, 2, 3, 3, 2, 2, 0, 3, 1, 2, 0, 4, 2, 2, 2, 3, 0, 3
OFFSET
1,6
COMMENTS
First differs from A304455 at a(90) = 3, A304455(90) = 4.
For the operation of taking the sequence of run-lengths of a finite sequence, runs-resistance is defined as the number of applications required to reach a singleton.
A prime index of n is a number m such that prime(m) divides n. The sequence of prime indices of n is row n of A112798.
LINKS
Claude Lenormand, Deux transformations sur les mots, Preprint, 5 pages, Nov 17 2003.
EXAMPLE
We have (1,2,2,3) -> (1,2,1) -> (1,1,1) -> (3), so a(90) = 3.
MATHEMATICA
primeMS[n_]:=If[n==1, {}, Flatten[Cases[FactorInteger[n], {p_, k_}:>Table[PrimePi[p], {k}]]]];
runsres[q_]:=Length[NestWhileList[Length/@Split[#]&, q, Length[#]>1&]]-1;
Table[runsres[primeMS[n]], {n, 50}]
CROSSREFS
The version for partitions is A329746.
The version for compositions is A329744.
The version for binary words is A329767.
The version for binary expansion is A318928.
Sequence in context: A337541 A185279 A088432 * A304455 A345354 A238951
KEYWORD
nonn
AUTHOR
Gus Wiseman, Nov 21 2019
STATUS
approved