Number of combinations of integers \leq n which sum to n

  • Thread starter mapkan
  • Start date
  • #1
3
0
Hi all,
I'm new to the forum, this is my problem:

given a positive integer n, i want to find how many combinations of integers smaller than n but larger than 0 sum to n. E.g.

n=3:
{3},{2,1},{1,1,1}

n=4:
{4},{3,1},{2,2},{2,1,1},{1,1,1}

it might just be that i'm tired, but i've been thinking about this for a while.

Thank you very much!
 

Answers and Replies

  • #2
459
0
http://en.wikipedia.org/wiki/Partition_%28number_theory%29" [Broken].
 
Last edited by a moderator:
  • #3
3
0
http://en.wikipedia.org/wiki/Partition_%28number_theory%29" [Broken].
Thank you very much!
Perfect!
 
Last edited by a moderator:

Related Threads on Number of combinations of integers \leq n which sum to n

  • Last Post
Replies
3
Views
3K
Replies
3
Views
5K
  • Last Post
Replies
5
Views
912
Replies
2
Views
648
Replies
2
Views
518
  • Last Post
Replies
12
Views
41K
Replies
1
Views
2K
  • Last Post
Replies
2
Views
2K
Replies
16
Views
8K
  • Last Post
Replies
22
Views
22K
Top