%I #32 Oct 27 2017 21:37:14
%S 0,11,1,26,2,36,3,48,4,50,5,60,6,72,7,74,8,88,9,102,10,104,11,120,12,
%T 122,13,124,14,138,15,152,16,154,17,156,18,168,19,170,20,184,21,202,
%U 22,204,23,220,24,222,25,224,26,240,27,242,28,244,29,258,30,272,31,274,32,276,33,290,34,292,35,306,36,324,37,326,38,328,39,348,40,350,41,370,42
%N a(n) = n/2 if n is even, otherwise add to n the next three primes > n.
%C Related to the PrimeLatz conjecture, which states that if this map k -> a(k) is iterated, starting at any n >= 0, then the trajectory will eventually enter a loop.
%C Computations have shown that up to 10^8, there is only one loop (apart from the fixed point 0). It is given for example by terms 2 through 31 of A193230, the smallest of its 30 elements being 9.
%C See A293980 for the number of iterations required to reach an element of this loop, and for further study of trajectories under iterations of this map.
%D Eric Angelini, Posting to Math Fun Mailing List, Nov 26, 2010
%D Bill Thurston, Posting to Math Fun Mailing List, Nov 26, 2010
%H Michael De Vlieger, <a href="/A174221/b174221.txt">Table of n, a(n) for n = 0..10000</a>
%H E. Angelini, <a href="/A174221/a174221.pdf">The PrimeLatz Conjecture</a> [Cached copy, with permission]
%p f:=proc(n) local p; p:=nextprime;
%p if n mod 2 = 0 then n/2 else
%p n+p(n)+p(p(n))+p(p(p(n))); fi; end;
%t Array[If[EvenQ@ #, #/2, Total@ Prepend[NextPrime[#, {1, 2, 3}], #]] &, 85, 0] (* _Michael De Vlieger_, Oct 25 2017 *)
%o (PARI) A174221(n)=bittest(n,0)||return(n\2);n+sum(c=1,3,n=nextprime(n+1)) \\ _M. F. Hasler_, Oct 25 2017
%Y Bisection gives A174223.
%Y Cf. A193230 (trajectory of 1 under this map), A293979 (trajectory of 83), A293980.
%K nonn
%O 0,2
%A _N. J. A. Sloane_, Nov 26 2010
|