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!)
A338666 a(1)=1 and a(2)=2. For all n > 2, a(n) is the smallest number > a(n-1) by a number > the difference between a(n-1) and a(n-2) so that consecutive terms of sequence are always relatively prime. 2
1, 2, 5, 9, 14, 23, 33, 46, 61, 77, 94, 113, 133, 155, 178, 203, 229, 256, 285, 316, 349, 383, 418, 455, 493, 532, 573, 616, 661, 707, 754, 803, 853, 904, 957, 1013, 1070, 1129, 1189, 1250, 1313, 1377, 1442, 1509, 1577, 1646, 1717, 1789, 1862, 1937, 2013, 2092, 2173, 2256, 2341 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,2

LINKS

Giovanni Resta, Table of n, a(n) for n = 1..10000

EXAMPLE

Term after 33 cannot be 44 because 33 and 44 have a common factor of 11.

MATHEMATICA

a[1]=1; a[2]=2; a[n_]:=a[n]=Module[{d=a[n-1]-a[n-2]+1}, While[!CoprimeQ[a[n-1]+d, a[n-1]], d++]; a[n-1]+d]; a/@Range[70] (* Ivan N. Ianakiev, Apr 23 2021 *)

CROSSREFS

Sequence in context: A123690 A199935 A090937 * A325717 A291942 A071609

Adjacent sequences:  A338663 A338664 A338665 * A338667 A338668 A338669

KEYWORD

nonn

AUTHOR

J. Lowell, Apr 22 2021

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 October 3 14:34 EDT 2022. Contains 357237 sequences. (Running on oeis4.)