

A103683


a(1)=1, a(2)=2, a(3)=3, a(n) = smallest positive integer not occurring earlier in sequence and coprime to a(n1), a(n2) and a(n3).


6



1, 2, 3, 5, 7, 4, 9, 11, 13, 8, 15, 17, 19, 14, 23, 25, 27, 16, 29, 31, 21, 10, 37, 41, 33, 20, 43, 47, 39, 22, 35, 53, 51, 26, 49, 55, 57, 32, 59, 61, 45, 28, 67, 71, 65, 6, 73, 77, 79, 12, 83, 85, 89, 18, 91, 95, 97, 24, 101, 103, 107, 30, 109, 113, 119, 36, 115, 121, 127, 34
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

1,2


COMMENTS

Conjectured to be not a permutation of the natural numbers.
Charles R Greathouse IV extended this, and confirms that primes occur in natural order.  Jonathan Vos Post and M. F. Hasler, Jan 18 2011
Conjecture: for n >= 67, a(n) is even if and only if n == 2 mod 4 and divisible by 3 if and only if n == 3 mod 4. In particular, this implies the last value divisible by 6 is a(66) = 36.  Robert Israel, May 12 2015


LINKS

Alois P. Heinz, Table of n, a(n) for n = 1..10000


MAPLE

ina:= proc(n) false end:
a:= proc(n) option remember; local k;
if n<4 then k:= n
else for k from 4 while ina(k) or igcd(k, a(n1))<>1 or
igcd(k, a(n2))<>1 or igcd(k, a(n3))<>1
do od
fi; ina(k):= true; k
end:
seq(a(n), n=1..120); # Alois P. Heinz, Jan 19 2011


MATHEMATICA

f[s_] := Block[{k = 1, l = Take[s, 3]}, While[ Union[ GCD[k, l]] != {1}  MemberQ[s, k], k++]; Append[s, k]]; Nest[f, {1, 2, 3}, 70] (* Robert G. Wilson v, Jun 26 2011 *)


CROSSREFS

Cf. A084937, A105214.
Sequence in context: A140528 A065037 A101438 * A284145 A284189 A125151
Adjacent sequences: A103680 A103681 A103682 * A103684 A103685 A103686


KEYWORD

nonn


AUTHOR

Leroy Quet, Mar 26 2005


EXTENSIONS

More terms from Robert G. Wilson v, Mar 30 2005


STATUS

approved



