login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A083956 a(n) = sum of all cyclic permutation of concatenation of first n numbers. In each case the digits of a number are kept together for n>9. 12

%I #12 Aug 07 2015 03:02:34

%S 1,33,666,11110,166665,2333331,31111108,399999996,4999999995,

%T 509876543215,52098641976336,5331076296399558,546238942849832881,

%U 56038035699304276305,5755318721445859729830,591693488306202516193456

%N a(n) = sum of all cyclic permutation of concatenation of first n numbers. In each case the digits of a number are kept together for n>9.

%C Initial terms are {n(n+1)/2}*{A000042(n)}.

%e a(1) = 1, a(2) = 12 + 21, a(3) = 123 + 231 + 312 = 666.

%e a(11) = 1234567891011 + 2345678910111 + ... + 1011123456789 + 1112345678910.

%p # count digits in positive integer digs := proc(inp::integer) local resul,shiftinp : resul := 1 : shiftinp := iquo(inp,10) : while shiftinp > 0 do resul := resul+1 : shiftinp := iquo(shiftinp,10) : od : RETURN(resul) : end: # provide number of concatenation up to lst, permuted by cycl newnum := proc(lst::integer,cycl::integer) local resul,i,insrt : resul := 0 : for i from 1 to lst do insrt := ((i+cycl-1) mod lst) +1 : resul := resul*10^digs(insrt)+insrt : od : RETURN(resul) ; end : n := 2 : while n < 13 do su := 0 : for cycl from 0 to n-1 do # print(n," add ",newnum(n,cycl)) ; su := su + newnum(n,cycl) : od : printf("%a,",su) : n := n+1 : od : # _R. J. Mathar_, Mar 13 2006

%p A083956 := n -> add( convert( cat( 'modp(j+i,n)+1' $ j=1..n ),decimal,10), i=1..n ); # _M. F. Hasler_, Nov 08 2006

%Y Cf. A083957.

%K base,nonn

%O 1,2

%A _Amarnath Murthy_, May 10 2003

%E More terms from _R. J. Mathar_, Mar 13 2006

%E Further terms from _M. F. Hasler_, Nov 08 2006

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 24 20:08 EDT 2024. Contains 371963 sequences. (Running on oeis4.)