[go: up one dir, main page]

login
A107433
Slowest increasing sequence where some digit of a(n) and some digit of a(n+1) add up to 9.
2
0, 9, 10, 18, 19, 20, 27, 28, 31, 36, 37, 42, 45, 46, 50, 54, 55, 64, 65, 73, 76, 82, 87, 91, 98, 100, 108, 109, 110, 118, 119, 120, 127, 128, 129, 130, 136, 137, 138, 139, 140, 145, 146, 148, 149, 150, 154, 155, 158, 159, 160, 163, 164, 165, 168, 169, 170, 172, 173
OFFSET
0,2
COMMENTS
Starting with another "seed" than 0 would produce another sequence.
LINKS
EXAMPLE
After 28 we must have an integer containing a "7" (2+"7"=9) or a "1" (8+"1"=9). The smallest integer satisfying this constraint is 31 (and not 37 or 41 or any other containing a "7" or a "1")
MAPLE
f:= proc(n) local S, k;
S:= map(t -> 9-t, convert(convert(n, base, 10), set));
for k from n+1 do
if convert(convert(k, base, 10), set) intersect S <> {} then return k fi
od
end proc:
a[0]:= 0:
for n from 1 to 100 do a[n]:= f(a[n-1]) od:
seq(a[n], n=0..100); # Robert Israel, Feb 24 2017
CROSSREFS
Sequence in context: A088036 A217935 A100595 * A090570 A131417 A268135
KEYWORD
base,easy,nonn
AUTHOR
Eric Angelini, Jun 09 2005
EXTENSIONS
Corrected and extended by Zak Seidov, Jun 10 2005
STATUS
approved