login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A193298 Gica-Panaitopol recursion: a(1) = 1; a(n+1) = 2*a(n) if a(n) <= n; otherwise a(n+1) = a(n) - 1. 5
1, 2, 4, 3, 6, 5, 10, 9, 8, 16, 15, 14, 13, 26, 25, 24, 23, 22, 21, 20, 40, 39, 38, 37, 36, 35, 34, 33, 32, 31, 30, 60, 59, 58, 57, 56, 55, 54, 53, 52, 51, 50, 49, 48, 47, 46, 92, 91, 90, 89, 88, 87, 86, 85, 84, 83, 82, 81, 80, 79, 78, 77, 76, 75, 74, 73, 72, 71, 70, 69 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
Using the Prime Number Theorem, Gica and Panaitopol show that the sequence contains infinitely many primes.
REFERENCES
A. Gica and L. Panaitopol, An application of the prime element theorem, Gazeta Matematica 21(100), No. 2 (2003), 113-115.
LINKS
EXAMPLE
The terms occur in disjoint blocks of decreasing consecutive numbers: 1; 2; 4, 3; 6, 5; 10, 9, 8; 16, 15, 14, 13; 26, 25, 24, 23, 22, 21, 20; . . .
MATHEMATICA
a[1] = 1; a[n_] := a[n] = If[a[n-1] <= n-1, 2*a[n-1], a[n-1]-1]; Table[a[n], {n, 100}]
CROSSREFS
Cf. A193299 (sorted sequence), A193300 (subset of primes), A193301 (complement of sorted sequence).
Sequence in context: A132666 A116533 A087559 * A168007 A359114 A328108
KEYWORD
nonn
AUTHOR
Jonathan Sondow, Jul 21 2011
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 19 19:02 EDT 2024. Contains 371798 sequences. (Running on oeis4.)