Logo

Greetings from The On-Line Encyclopedia of Integer Sequences!

Hints

Search: id:A117504
Displaying 1-1 of 1 results found. page 1
     Format: long | short | internal | text      Sort: relevance | references | number      Highlight: on | off
A117504 Prime at which the cumulative sum in A117503 is prime. +0
3
37, 137, 151, 173, 409, 467, 503, 677, 937, 1091, 1153, 1229, 1303, 1409, 1453, 1471, 1531, 2137, 2221, 2251, 2393, 2503, 2593, 2633, 2671, 2797, 2837, 3001, 3023, 3089, 3163 (list; graph; listen)
OFFSET

1,1

FORMULA

Multiply consecutive primes by pi, take integer, sum until a prime sum is reached.

EXAMPLE

In a(1)=37, the cumulative sum of primes 1-12 in A117503 has risen to 613, a prime -- 37 being the 12th prime to be multiplied by pi, with integer of result added to previous results.

MAPLE

Digits := 30 ; A117504 := proc(nmax) local a, pisum, p ; a := [] ; pisum := 0 ; p :=1 ; while nops(a) <=nmax do while true do pisum := pisum+floor(Pi*ithprime(p)) ; p := p+1 ; if isprime(pisum) then a := [op(a), ithprime(p-1)] ; break ; fi ; od : od : RETURN(a) ; end: a := A117504(30) ; (R. J. Mathar)

PROGRAM

UBASIC 10 Ct=1 20 B=nxtprm(B) 30 C=int(pi(B)) 40 D=D+C 41 print Ct, B, C, D 50 if D=prmdiv(D) then print D:stop 55 Ct=Ct+1 60 goto 20

CROSSREFS

Cf. A117503.

Sequence in context: A142331 A139734 A142388 this_sequence A055783 A044369 A044750

Adjacent sequences: A117501 A117502 A117503 this_sequence A117505 A117506 A117507

KEYWORD

easy,nonn

AUTHOR

Enoch Haga (Enokh(AT)comcast.net), Mar 25 2006

EXTENSIONS

Corrected by R. J. Mathar, Oct 26 2006

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 August 29 17:54 EDT 2008. Contains 143238 sequences.


AT&T Labs Research