login
A140525
a(1)=2. For n >=2, a(n) = the least integer >= a(n-1) that is not coprime to both a(n-1)+1 and a(n-1).
1
2, 6, 14, 18, 38, 42, 86, 90, 98, 102, 206, 210, 422, 426, 434, 438, 878, 882, 1766, 1770, 1778, 1782, 3566, 3570, 7142, 7146, 7154, 7158, 14318, 14322, 28646, 28650, 28658, 28662, 57326, 57330, 114662, 114666, 114674, 114678, 229358, 229362, 229400
OFFSET
1,1
COMMENTS
Also: a(n+1) = a(n)+1 + least prime factor of (a(n)+1), according to an observation by Peter Pein, proved by M. F. Hasler, cf. link. - M. F. Hasler, Feb 09 2009
LINKS
Peter Pein and M. F. Hasler: Post to the SeqFan list, Feb 09 2009 [From M. F. Hasler, Feb 09 2009]
MATHEMATICA
a = {2}; Do[ i = a[ [ -1 ] ] + 1; While[ Min[ GCD[ a[ [ -1 ] ], i ], GCD[ a[ [ -1 ] ] + 1, i ] ] == 1, i++ ]; AppendTo[ a, i ], {40} ]; a (* Stefan Steinerberger, Aug 04 2008 *)
PROG
(PARI) print1(a=2); for(i=2, 99, print1(", "a+=1+factor(a+1)[1, 1])) \\ M. F. Hasler, Feb 09 2009
CROSSREFS
Equals A144751 - 1.
Sequence in context: A163777 A215807 A373437 * A189804 A308394 A246068
KEYWORD
nonn
AUTHOR
Leroy Quet, Jul 02 2008
EXTENSIONS
More terms from Stefan Steinerberger, Aug 04 2008
a(42)-a(43) from Ray Chandler, Jun 25 2009
STATUS
approved