login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Lexicographically earliest sequence of distinct terms such that a(n) is not divisible by any digit of a(n+1).
6

%I #11 Jun 07 2019 11:10:50

%S 1,2,3,4,5,6,7,8,9,20,30,40,33,22,34,35,23,24,50,36,55,26,37,25,27,28,

%T 38,39,29,32,53,42,44,56,59,43,45,46,47,48,57,49,52,58,54,70,60,77,62,

%U 63,64,65,66,74,67,68,69,72,75,76,73,78,79,80,90,84,85,82,83,86,87,88,93,89,92,95,94,96,97,98,99,200,300,700,303

%N Lexicographically earliest sequence of distinct terms such that a(n) is not divisible by any digit of a(n+1).

%C The sequence ends with the LCM of {1, 2, 3, 4, 5, 6, 7, 8, 9} which is 2520 and we have a(1422) = 2520.

%H Carole Dubois, <a href="/A326106/b326106.txt">Table of n, a(n) for n = 1..1422</a>

%e The sequence starts with 1, 2, 3, 4, 5, 6, 7, 8, 9, 20, 30, 40, 33,... and we see indeed that a(10) cannot be 10 as the digit 1 of 10 would divide 9; in the same manner, a(10) = 11 is forbidden, as are 12, 13, 14, 15, 16, 17, 18, and 19; thus a(10) = 20; etc.

%t Nest[Append[#, Block[{k = 2, n = #[[-1]]}, While[Nand[FreeQ[#, k], NoneTrue[DeleteCases[IntegerDigits@ k, 0], Mod[n, #] == 0 &]], k++]; k]] &, {1}, 84] (* _Michael De Vlieger_, Jun 06 2019 *)

%Y Cf. A326107, A326108, A326109, A326110 for related sequences where a(n) is divisible by exactly 1 (resp. 2, 3, 4) digit of a(n+1).

%K base,nonn,fini

%O 1,2

%A _Eric Angelini_ and _Carole Dubois_, Jun 06 2019