Logo

Greetings from The On-Line Encyclopedia of Integer Sequences!

Hints

Search: id:A163464
Displaying 1-1 of 1 results found. page 1
     Format: long | short | internal | text      Sort: relevance | references | number      Highlight: on | off
A163464 Cumulative sum of a repeated shift-and-add operation on the base-7 representation of prime(n). +0
1
0, 0, 0, 1, 1, 1, 2, 2, 3, 4, 4, 5, 5, 6, 6, 8, 9, 9, 10, 11, 11, 12, 12, 13, 14, 16, 16, 17, 17, 18, 20, 20, 21, 21, 24, 24, 25, 26, 26, 27, 28, 28, 30, 30, 32, 32, 34, 35, 36, 36, 37, 38, 38, 40, 41, 42, 43, 43, 44, 45, 45, 46, 49, 50, 50, 51, 53, 54, 57, 57, 58, 59, 60, 61, 62 (list; graph; listen)
OFFSET

1,7

COMMENT

Starting from the base-7 representation of prime(n) =

d_m*7^m +.. +d_3*7^3 +d_2*7^2 +d_1*7 +d_0, the least-significant digit is recursively

removed (a shift-right operation in base 7), and the intermediate numbers are all added up:

a(n) = (d_m*7^(m-1)+.. +d_3*7^2 +d_2*7 +d_1)

+(d_m*7^(m-2) +... +d_4*7^2+d_3*7+d_2)

+(d_m*7^(m-3) +... +d_4*7+d_3)

+ ... +d_m

= sum_{j=1..m} d_j*(7^j-1)/6.

MAPLE

shiftadd := proc(n, b) dgs := convert(n, base, b) ; add( op(i, dgs)*(b^(i-1)-1), i=2..nops(dgs))/(b-1) ; end:

A163464 := proc(n) shiftadd(ithprime(n), 7) ; end:

seq(A163464(n), n=1..40) ; # R. J. Mathar, Aug 02 2009

MATHEMATICA

lst={}; Do[p=Prime[n]; s=0; While[p>1, p=IntegerPart[p/7]; s+=p; ]; AppendTo[lst, s], {n, 6!}]; lst

CROSSREFS

Cf. A080085, A080086, A080087

Sequence in context: A057358 A038128 A097337 this_sequence A139327 A076905 A098295

Adjacent sequences: A163461 A163462 A163463 this_sequence A163465 A163466 A163467

KEYWORD

nonn,easy,base

AUTHOR

Vladimir Orlovsky (4vladimir(AT)gmail.com), Jul 28 2009

EXTENSIONS

Definition rewritten by R. J. Mathar (mathar(AT)strw.leidenuniv.nl), Aug 02 2009

page 1

Search completed in 0.002 seconds

Lookup | Welcome | Find friends | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
More pages | Superseeker | Maintained by N. J. A. Sloane (njas@research.att.com)

Last modified November 27 22:38 EST 2009. Contains 167602 sequences.


AT&T Labs Research