Logo

Greetings from The On-Line Encyclopedia of Integer Sequences!

Hints

Search: id:A072820
Displaying 1-1 of 1 results found. page 1
     Format: long | short | internal | text      Sort: relevance | references | number      Highlight: on | off
A072820 Largest number of distinct primes to represent n as arithmetic mean. +0
2
1, 1, 3, 3, 5, 4, 5, 5, 7, 6, 9, 8, 9, 9, 11, 10, 11, 11, 13, 12, 13, 13, 15, 14, 17, 15, 17, 16, 17, 17, 19, 18, 19, 19, 21, 20, 23, 21, 23, 22, 23, 23, 25, 24, 25, 25, 27, 26, 27, 27, 29, 28, 29, 28, 29, 29, 31, 30, 31, 31, 33, 32, 33, 33, 35, 33, 35, 34, 37, 35, 37, 36, 37, 37 (list; graph; listen)
OFFSET

2,3

LINKS

Reinhard Zumkeller, Representing integers as arithmetic means of primes

EXAMPLE

a(20)=7: (2+3+5+23+29+31+47)/7 = 20.

MAPLE

Contribution from Alois P. Heinz (heinz(AT)hs-heilbronn.de), Aug 03 2009: (Start)

sp:= proc(i) option remember; `if` (i=1, 2, sp(i-1) +ithprime(i)) end:

b:= proc(n, i, t) local h; if n<0 then 0 elif n=0 then `if` (t=0, 1, 0) elif i=2 then `if` (n=2 and t=1, 1, 0) else h := b(n, prevprime(i), t); b(n, i, t):= `if` (h>0, h, b(n-i, prevprime(i), t-1)) fi end:

a:= proc(n) local i, k; if n<4 then 1 else for k from 2 while sp(k)/k<=n do od: do k:= k-1; if b(k*n, nextprime (k*n -sp(k-1)-1), k)>0 then break fi od; k fi end: seq (a(n), n=2..50); (End)

CROSSREFS

Cf. A072701.

Sequence in context: A094439 A122037 A008316 this_sequence A131950 A116192 A090104

Adjacent sequences: A072817 A072818 A072819 this_sequence A072821 A072822 A072823

KEYWORD

nonn

AUTHOR

Reinhard Zumkeller (reinhard.zumkeller(AT)gmail.com), Jul 15 2002

EXTENSIONS

More terms from Alois P. Heinz (heinz(AT)hs-heilbronn.de), Aug 03 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 December 18 21:37 EST 2009. Contains 171024 sequences.


AT&T Labs Research