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!)
A338495 Least number of hexagonal pyramidal numbers needed to represent n. 5
1, 2, 3, 4, 5, 6, 1, 2, 3, 4, 5, 6, 7, 2, 3, 4, 5, 6, 7, 8, 3, 1, 2, 3, 4, 5, 6, 4, 2, 3, 4, 5, 6, 7, 5, 3, 4, 5, 6, 7, 8, 6, 4, 2, 3, 4, 5, 6, 7, 1, 2, 3, 4, 5, 6, 7, 2, 3, 4, 5, 6, 7, 8, 3, 4, 3, 4, 5, 6, 7, 4, 2, 3, 4, 5, 6, 7, 5, 3, 4, 5, 6, 7, 8, 6, 4, 5, 4, 5, 6, 7, 7, 5, 3, 1, 2, 3, 4, 5, 2, 3 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
LINKS
Eric Weisstein's World of Mathematics, Hexagonal Pyramidal Number
MAPLE
N:= 200: # for a(1)..a(N)
V:= Vector(N):
S:= {seq(n*(n+1)*(4*n-1)/6, n=1..floor((N*3/2)^(1/3)))}:
V[convert(S, list)]:= 1:
T:= S:
for m from 2 do
Tn:= select(`<=`, map(t -> op(t +~ S), T), N) minus T;
if nops(Tn) = 0 then break fi;
T:= T union Tn;
V[convert(Tn, list)]:= m
od:
convert(V, list); # Robert Israel, Nov 02 2020
CROSSREFS
Sequence in context: A010885 A338480 A234533 * A053828 A033927 A104414
KEYWORD
nonn
AUTHOR
Ilya Gutkovskiy, Oct 30 2020
STATUS
approved

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 06:24 EDT 2024. Contains 371918 sequences. (Running on oeis4.)