Logo

Greetings from The On-Line Encyclopedia of Integer Sequences!

Hints

Search: id:A107379
Displaying 1-1 of 1 results found. page 1
     Format: long | short | internal | text      Sort: relevance | references | number      Highlight: on | off
A107379 Number of ways to write n^2 as the sum of n odd numbers, disregarding order. +0
4
1, 1, 3, 9, 30, 110, 436, 1801, 7657, 33401, 148847, 674585, 3100410, 14422567, 67792847, 321546251, 1537241148, 7400926549, 35854579015, 174677578889, 855312650751, 4207291811538, 20782253017825, 103048079556241 (list; graph; listen)
OFFSET

0,3

COMMENT

Motivated by the fact that the nth square is equal to the sum of the first n odd numbers.

FORMULA

a(n) = A008284((n^2+n)/2,n) = A008284(A000217(n),n). - Max Alekseyev, Sep 25 2009

EXAMPLE

For example, 9 can be written as a sum of three odd numbers in 3 ways: 1+1+7, 1+3+5 and 3+3+3.

MAPLE

f := proc (n, k) option remember;

if n = 0 and k = 0 then return 1 end if;

if n <= 0 or n < k then return 0 end if;

if `mod`(n+k, 2) = 1 then return 0 end if;

if k = 1 then return 1 end if;

return f(n-1, k-1) + f(n-2*k, k)

end proc;

seq(f(k^2, k), k=1..20);

CROSSREFS

Cf. A152140.

Sequence in context: A091699 A129167 A151472 this_sequence A117428 A134168 A124427

Adjacent sequences: A107376 A107377 A107378 this_sequence A107380 A107381 A107382

KEYWORD

nonn,easy

AUTHOR

David Radcliffe (dradcliffe(AT)gmail.com), Sep 25 2009

EXTENSIONS

Arguments in the Maple program swapped and 4 terms added by R. J. Mathar (mathar(AT)strw.leidenuniv.nl), Oct 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 23 17:09 EST 2009. Contains 167438 sequences.


AT&T Labs Research