OFFSET
1,2
COMMENTS
The sequence starts with a(1) = 1 and is always extended with the smallest integer not yet present that does not lead to a contradiction.
This sequence is conjectured to be a permutation of the positive integers and is a variant of A275603 that shares with it the first 174 terms.
LINKS
Jean-Marc Falcoz, Table of n, a(n) for n = 1..10001
EXAMPLE
1,2,5,8,11,14,23,12,19,6,7,
|1-2| = 1 and 11 is prime; |2-5| = 3 and 23 is prime; |5-8| = 3 and 53 is prime; |8-11| = 3 and 83 is prime; |11-14| = 3 and 113 is prime; etc.
MATHEMATICA
a = {1}; Do[k = 1; While[Or[! PrimeQ@ FromDigits[IntegerDigits[a[[i - 1]]]~Join~IntegerDigits[Abs[a[[i - 1]] - k]]], MemberQ[a, k]], k++]; AppendTo[a, k], {i, 2, 80}]; a (* Michael De Vlieger, Nov 14 2016 *)
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Eric Angelini and Jean-Marc Falcoz, Nov 14 2016
STATUS
approved