Search: id:A138754 Results 1-1 of 1 results found. %I A138754 %S A138754 1,4,2,7,4,10,5,13,6,7,19,22,9,24,10,10,11,31,33,12,35,38,14,15,45,16, %T A138754 47,17,48,17,55,19,20,60,22,63,66,67,24,24,25,73,25,77,26,79,83,87,31, %U A138754 89,31,31,93,31,32,33,33,101,102,35,104,35,113,37,115,38,122,123,41,126 %N A138754 PrimePi(A138751(n)) - a variation of the Collatz (3n+1) map. %C A138754 This map is a variation of the Collatz (or 3n+1) map: %C A138754 Instead of considering the parity of the number, we look at %C A138754 prime(n) (mod 3) to decide if this prime should be halved or doubled, %C A138754 before going to the next prime (A007918) and finally back to the %C A138754 positive integers via PrimePi (A000720). %C A138754 Exactly like for the Collatz (3n+1) map (defined on nonnegative integers), %C A138754 the first element for which it is defined is its only fixed point, %C A138754 and all other starting values seem to end up in a cycle of length 3, %C A138754 here: 4 -> 7 -> 5 -> 4. %C A138754 Except for p=3, no prime yields a prime result under the %C A138754 map A138750 (as can be seen using p=6k+1 or p=6k-1). Therefore %C A138754 instead of applying primepi() after nextprime(), one could also simply use 1+primepi(). %C A138754 The prime p=3 is also the only case where n=2(mod 3) is not equivalent %C A138754 to n != 1 (mod 3). It might have been a better choice to define %C A138754 A138750(x)=2x if x=1 mod 3, =ceil(x/2) else. But since here it makes %C A138754 only a difference for p=3, we use the original definition (cf %C A138754 A124123). %H A138754 Index entries for sequences related to 3x+1 (or Collatz) problem %F A138754 A138754(n) = A000720(A138751(n)) = A000720(A007918(A138750(A000040(n)))) %e A138754 a(4) = 7 since prime(4) = 7 = 1 (mod 3), thus A138750(7) = %e A138754 2*7 = 14, nextprime(14) = 17, PrimePi(17) = 7 (i.e. 17 is the 7-th %e A138754 prime). %e A138754 a(5) = 4 since prime(5) = 11 = 2 (mod 3), thus A138750(11) %e A138754 = ceil(11/2) = 6, nextprime(6) = 7, PrimePi(7) = 4 (i.e. 7 is the 4-th %e A138754 prime). %o A138754 (PARI) A138754(n)=primepi(A138751(n)) /* see there */ %Y A138754 Cf. A124123, A138750-A138753, A000040, A000720, A007918. %Y A138754 Sequence in context: A123684 A002949 A130849 this_sequence A021963 A131914 A115302 %Y A138754 Adjacent sequences: A138751 A138752 A138753 this_sequence A138755 A138756 A138757 %K A138754 easy,nonn %O A138754 1,2 %A A138754 M. F. Hasler (www.univ-ag.fr/~mhasler), Apr 01 2008 Search completed in 0.001 seconds