login
A086763
Count of complete evaluations of each mapping in the trajectory of n in the mapping n-> n*3+1 if n is prime, n+1 if n is odd composite, n/2 while n even.
1
17, 7, 2, 5, 8, 16, 3, 7, 6, 14, 9, 9, 17, 5, 4, 12, 8, 20, 7, 16, 15, 12, 10, 11, 10, 19, 18, 18, 6, 15, 5, 14, 13, 10, 9, 21, 21, 9, 8, 3, 17, 18, 16, 14, 13, 13, 11, 13, 12, 12, 11, 11, 20, 20, 19, 20, 19, 32, 7, 16, 1, 7, 6, 16, 15, 27, 14, 12, 11, 11, 10, 23, 22, 23, 22, 11, 10, 11
OFFSET
2,1
PROG
(PARI) countpxp(m, k) = { for(x=2, m, c=0; n=x; while(n > 1, if(isprime(n), n=n*k+1; c++, if(n%2<>0, n++; c++)); while(n%2==0, n/=2; c++); if(n==1 || n==31, break); ); print1(c", "); ) }
CROSSREFS
Cf. A086762.
Sequence in context: A145965 A040276 A166211 * A064545 A114032 A107807
KEYWORD
easy,nonn
AUTHOR
Cino Hilliard, Aug 02 2003
STATUS
approved