0

Suppose we want to choose a certain number of objects, k, from a variety of choices, all limited. I'm confused about how to set up this problem. I'm pretty sure it's stars and bars, but I don't know how to incorporate the limited amount aspect of the problem.

For example, to explain what I mean, suppose we want a dozen doughnuts, and we're choosing from five chocolate doughnuts, three sprinkled doughnuts, six glazed doughnuts, and one vanilla doughnut. How many ways are there to choose one dozen doughnuts?

S.T.
  • 1
  • Check out https://math.stackexchange.com/questions/553960/extended-stars-and-bars-problemwhere-the-upper-limit-of-the-variable-is-bounded and https://math.stackexchange.com/questions/553730/computing-coefficients-for-generalized-combinatorial-sets. In general, there is no closed form. – Noah Singer Dec 03 '17 at 22:25

1 Answers1

0

Let $ n,k,x_i,y_i\in\mathbb{N}, \ x_i<y_i \ , 1\leq i\leq n$ . Here $x_i$ denotes how many you choose from a certain type and $y_i$ denotes the limititation for that type ,i.e , the maximum number you can choose of that type. Then what you ask is the number of the solutions of the equation:$$ x_1+x_2+x_3+\cdots+x_n=k$$