|
|
A299997
|
|
Lexicographic first sequence of positive integers such that a(n)*a(n+1) has a digit 7, and no term occurs twice.
|
|
10
|
|
|
1, 7, 10, 17, 11, 16, 36, 2, 35, 5, 14, 27, 21, 13, 6, 12, 23, 9, 3, 19, 4, 18, 15, 25, 28, 24, 30, 26, 22, 8, 34, 50, 54, 31, 37, 20, 38, 44, 29, 33, 39, 43, 32, 46, 45, 55, 65, 42, 41, 47, 51, 53, 49, 56, 62, 48, 57, 61, 52, 63, 59, 64, 58, 72, 66, 83, 69, 40, 68, 70, 71, 67, 81, 75, 73, 79, 60, 95, 74, 78, 86, 82, 85, 84, 80, 88, 77, 91, 87
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
COMMENTS
|
A permutation of the positive integers.
|
|
LINKS
|
|
|
EXAMPLE
|
a(1) = 1 is the least positive integer, and a(1) has no other constraint to satisfy.
a(2) = 7 is the least positive integer > a(1) = 1 such that a(2)*a(1) = 7 has a digit 7.
a(3) = 10 is the least positive integer not in {1, 7} such that a(3)*a(2) (= 70) has a digit 7: All smaller choices (2, ..., 6) do not satisfy this.
a(4) = 17 is the least positive integer not in {1, 7, 10} such that a(4)*a(3) (= 170) has a digit 7: All smaller choices 2,...,16 do not satisfy this.
|
|
PROG
|
(PARI) A299997(n, f=1, d=7, a=1, u=[a])={for(n=2, n, f&&if(f==1, print1(a", "), write(f, n-1, " "a)); for(k=u[1]+1, oo, setsearch(u, k)&&next; setsearch(Set(digits(a*k)), d)&&(a=k)&&break); u=setunion(u, [a]); while(#u>1&&u[2]==u[1]+1, u=u[^1])); a}
|
|
CROSSREFS
|
Cf. A299402, A299403, A298974, ..., A298979, A299996: analog with digit 2, 3, 4, ..., 9, 6.
Cf. A299957, A299969, ..., A299988 (analog with addition instead of multiplication, and different digits).
|
|
KEYWORD
|
nonn,base
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|