login

Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.

a(n) = concatenate n consecutive integers, starting with the last number of the previous batch.
3

%I #32 Dec 17 2016 12:05:44

%S 1,12,234,4567,7891011,111213141516,16171819202122,2223242526272829,

%T 293031323334353637,37383940414243444546,4647484950515253545556,

%U 565758596061626364656667,67686970717273747576777879,7980818283848586878889909192

%N a(n) = concatenate n consecutive integers, starting with the last number of the previous batch.

%C A variant of A053067. The first number of the concatenation a(n) is A152947(n) = (n-2)*(n-1)/2+1 and the last is (n-1)*n/2+1.

%C The fourth term, 4567, is a prime. When is the next prime, if there is another? - _N. J. A. Sloane_, Dec 16 2016

%C a(n) is the concatenation of the terms of the n-th row of A122797 when seen as a triangle. - _Michel Marcus_, Dec 17 2016

%H Chai Wah Wu, <a href="/A279610/b279610.txt">Table of n, a(n) for n = 1..200</a>

%F a(n) = n^2/2 - n/2 + 1 + Sum{k=1..n-1} ((n^2/2 - n/2 + 1 - k)*10^Sum{j=0..k-1} (floor(1+log_10(n^2/2 - n/2 + 1 - j)))).

%e a(4) is the concatenation of 4 numbers beginning with the last number (4) that was used to build a(3), so a(4) = 4 5 6 7 = 4567. Then a(5) is the concatenation of 5 numbers beginning with the last number of a(4), which is 7, so a(5) = 7 8 9 10 11 = 7891011. And so on.

%e For n = 3, n^2/2 - n/2 + 1 = 4; a(3) = 4 + 3*10^1 + 2*10^(1+1) = 234.

%t Table[FromDigits[Flatten[IntegerDigits /@ Range[(n(n - 1))/2 + 1, (n(n + 1))/2 + 1 ]]], {n, 0, 20}]

%o (Python)

%o from __future__ import division

%o def A279610(n):

%o return int(''.join(str(d) for d in range((n-1)*(n-2)//2+1,n*(n-1)//2+2))) # _Chai Wah Wu_, Dec 17 2016

%Y Cf. A053067, A122797, A152947.

%Y A subsequence of A035333. For primes in latter, see A052087.

%K nonn,base

%O 1,2

%A _José de Jesús Camacho Medina_, Dec 09 2016, and _Paolo Iachia_, Dec 15 2016