cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A260857 Base-7 representation of a(n) is the concatenation of the base-7 representations of 1, 2, ..., n, n-1, ..., 1.

Original entry on oeis.org

0, 1, 64, 3249, 160000, 7845601, 384473664, 131870760799, 316621469105950, 760208147660763999, 1825259762561514314050, 4382448689911580334132199, 10522259304477772232578647150, 25263944590051134455098854865399, 60658730960712773989601560650105250
Offset: 0

Views

Author

M. F. Hasler, Aug 01 2015

Keywords

Comments

Base-7 variant of A173426 (base 10) and A173427 (base 2). See A260853 - A260866 for variants in other bases.
The base 7 is not listed in A260343, because a(7) = A260851(7) = 131870760799 = 12345610654321_7 is not prime and therefore not in A260852. See these sequences for more information.

Examples

			a(0) = 0 is the result of the empty sum corresponding to 0 digits.
a(2) = 64 = (7+1)^2 = 7^2 + 2*7 + 1 = 121_7 is the concatenation of (1, 2, 1).
a(8) = 316621469105950 = 123456101110654321_7 is the concatenation of (1, 2, 3, 4, 5, 6, 10, 11, 10, 6, 5, 4, 3, 2, 1), where the middle "10, 11, 10" are the base-7 representations of 7, 8, 7.
		

Programs

  • Mathematica
    Table[FromDigits[Flatten[Join[IntegerDigits[Range[n],7], IntegerDigits[ Range[ n-1,1,-1],7]]],7],{n,0,20}] (* Harvey P. Dale, Nov 02 2017 *)
  • PARI
    a(n,b=7)=sum(i=1,#n=concat(vector(n*2-1,k,digits(min(k,n*2-k),b))),n[i]*b^(#n-i))