[go: up one dir, main page]

login
A352960
The successive digits of the sequence are the successive digital roots of a(n) + a(n+1).
1
1, 9, 18, 19, 7, 3, 6, 28, 2, 4, 16, 37, 46, 12, 25, 8, 13, 21, 55, 5, 14, 15, 23, 27, 17, 11, 64, 73, 36, 32, 45, 41, 59, 26, 29, 39, 35, 22, 34, 54, 82, 24, 31, 33, 63, 49, 48, 72, 57, 66, 81, 38, 47, 75, 91, 99, 68, 58, 43, 44, 84, 42, 51, 93, 117, 77, 69, 86, 52, 78, 53, 95, 111, 62, 129, 118, 56
OFFSET
1,2
COMMENTS
This is the lexicographically earliest sequence of distinct positive terms with the property.
No zero is in the sequence as zero cannot be a digital root (DR in short hereunder).
LINKS
EXAMPLE
a(1) + a(2) = 1 + 9 = 10 with DR = 1;
a(2) + a(3) = 9 + 18 = 27 with DR = 9;
a(3) + a(4) = 18 + 19 = 37 with DR = 1;
a(4) + a(5) = 19 + 7 = 26 with DR = 8;
a(5) + a(6) = 7 + 3 = 10 with DR = 1;
a(6) + a(7) = 3 + 6 = 9 with DR = 9;
a(7) + a(8) = 6 + 28 = 34 with DR = 7;
a(8) + a(9) = 28 + 2 = 30 with DR = 3;
a(9) + a(10) = 2 + 4 = 6 with DR = 6;
a(10) + a(11) = 4 + 16 = 20 with DR = 2;
a(11) + a(12) = 16 + 37 = 53 with DR = 8; etc.
We see that the succession of the above DRs is the succession of the digits of the sequence (1, 9, 1, 8, 1, 9, 7, 3, 6, 2, 8, ...)
PROG
(MATLAB)
function a = A352960( max_n )
ad(1) = 1;
a(1) = 1;
for n = 2:max_n
k = 1;
while 0 == check_k(a(n-1), k, a, ad(n-1))
k = k + 1;
end
a(n) = k;
s = num2str(k);
for m = 1:length(s)
ad = [ad str2num(s(m))];
end
end
end
function ok = check_k(m, k, a, d)
dr = 1+mod(m+k-1, 9);
ok = (d == dr) && isempty(find(a==k, 1)) ...
&& isempty(find(num2str(k)=='0', 1));
end % Thomas Scheuerle, Apr 11 2022
CROSSREFS
Cf. A010888.
Sequence in context: A250769 A158908 A202188 * A060993 A352380 A297267
KEYWORD
base,nonn
AUTHOR
Eric Angelini and Carole Dubois, Apr 11 2022
STATUS
approved