Combination Question

Batarang96

New member
Joined
Sep 11, 2015
Messages
5
Forgive me if I have placed this in the wrong sub-forum.

I'm creating an army-building game. Armies are made up of soldiers with distinct point values. There are 4 different soldiers that you may use to build your Army:

General (G) -- 4 points
Captain (C) -- 3 points
Sergeant (S) -- 2 points
Private (P) -- 1 point

For example, in a 10 point game, you could play 2 Generals and 1 Sergeant, 3 Captains and 1 Private, 4 Sergeants and 2 Privates, etc.

What I would like to know is how to determine how many distinct Armies that one can build, based on the game's point total.

Thank you!
 
I'm creating an army-building game. Armies are made up of soldiers with distinct point values. There are 4 different soldiers that you may use to build your Army:
General (G) -- 4 points
Captain (C) -- 3 points
Sergeant (S) -- 2 points
Private (P) -- 1 point
What I would like to know is how to determine how many distinct Armies that one can build, based on the game's point total.
I can guarantee this is not the answer you want. This topic is known as Partitions of an Integer. Whole text books and college courses exist on this topic. It takes extensive lectures on generating polynomials to work out the answer your question.
Look at the partitions of five using your numbers:
\begin{array}{*{20}{c}} {4 + 1}&{3 + 1 + 1}&{2 + 1 + 1 + 1} \\ {3 + 2}&{2 + 2 + 1}&{1 + 1 + 1 + 1 + 1} \end{array}
Sorry I have n control over the awful LaTeX rending on this site. I don't understand why it cannot be repaired.
In any case there are six partitions of five using \(1,2,3,4\).
You can find tables of these partitions. The book THE MATHEMATICS OF CHOICE by Ivan Niven is a standard.(Buy used)
 
Thanks for your response. What I’m looking for is akin to the “money-changing problem”, I discovered. I went ahead and found the formula, plus a partition generator that does the math for me. So, I’m good to go! :)
 
Top