login
A279610
a(n) = concatenate n consecutive integers, starting with the last number of the previous batch.
3
1, 12, 234, 4567, 7891011, 111213141516, 16171819202122, 2223242526272829, 293031323334353637, 37383940414243444546, 4647484950515253545556, 565758596061626364656667, 67686970717273747576777879, 7980818283848586878889909192
OFFSET
1,2
COMMENTS
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.
The fourth term, 4567, is a prime. When is the next prime, if there is another? - N. J. A. Sloane, Dec 16 2016
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
LINKS
FORMULA
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)))).
EXAMPLE
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.
For n = 3, n^2/2 - n/2 + 1 = 4; a(3) = 4 + 3*10^1 + 2*10^(1+1) = 234.
MATHEMATICA
Table[FromDigits[Flatten[IntegerDigits /@ Range[(n(n - 1))/2 + 1, (n(n + 1))/2 + 1 ]]], {n, 0, 20}]
PROG
(Python)
from __future__ import division
def A279610(n):
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
CROSSREFS
A subsequence of A035333. For primes in latter, see A052087.
Sequence in context: A089343 A303487 A280071 * A222702 A352700 A012351
KEYWORD
nonn,base
AUTHOR
José de Jesús Camacho Medina, Dec 09 2016, and Paolo Iachia, Dec 15 2016
STATUS
approved