login
This site is supported by donations to The OEIS Foundation.
Logo

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A039634 Fixed point of "n -> n/2 or (n-1)/2 until result is prime". 12
1, 2, 3, 2, 5, 3, 7, 2, 2, 5, 11, 3, 13, 7, 7, 2, 17, 2, 19, 5, 5, 11, 23, 3, 3, 13, 13, 7, 29, 7, 31, 2, 2, 17, 17, 2, 37, 19, 19, 5, 41, 5, 43, 11, 11, 23, 47, 3, 3, 3, 3, 13, 53, 13, 13, 7, 7, 29, 59, 7, 61, 31, 31, 2, 2, 2, 67, 17, 17, 17, 71, 2, 73, 37, 37, 19, 19, 19, 79, 5, 5 (list; graph; refs; listen; history; internal format)
OFFSET

0,2

MATHEMATICA

ner[ n_Integer ] := FixedPoint[ If[ EvenQ[ # ]&&#>2, #/2, If[ PrimeQ[ # ]||(#=== 1), #, (#-1)/2 ] ]&, n, 20 ]

CROSSREFS

Cf. A039635-A039645.

Sequence in context: A097975 A130088 A078834 * A078833 A109674 A067629

Adjacent sequences:  A039631 A039632 A039633 * A039635 A039636 A039637

KEYWORD

nonn,easy,nice

AUTHOR

Wouter Meeussen (wouter.meeussen(AT)pandora.be)

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
Recent Additions | More pages | Superseeker | Maintained by The OEIS Foundation Inc.

Content is available under The OEIS End-User License Agreement .

Last modified February 17 11:46 EST 2012. Contains 206011 sequences.