We are now given a new task, and a new scenario to model (yay! right). The next concept I will cover is r-combinations, meaning combinations with repeats. I will explain what this means with an example:

You are going to the grocery store in order to pick up three 2-liters of soda. Once you arrive at the store you have five different types of soda to choose from (pepsi, coca-cola, sprite, a&w root beer, and 7-up for example). Now you want to figure out the number of different combinations of soda you can bring home only this time your allowed to group the same type of item together. As an example {pepsi, pepsi, pepsi} would be a valid choice.

The best way to derive a formula for this type of problem is to envision your choices (5 types of sodas) as categories and the number of sodas you need (3) as being placed in one of those categories if selected. So if you pick 2 pepsi’s and 1 7-up (and if pepsi and 7-up are categories #1 and #4 respectively) it could be represented by the following string

xx| | |x|

In order to get the total number of possibilities you must find the total number of unique strings of the form above with 4 bars and 3 x’s. This is a simple permutation with repeats problem. Note that there is one less vertical bar than there are categories because we omit the end bars. I know there are two end bars but you only subtract one because if you subtracted two from our equation we would not be simulating the correct string permutations. Our final answer becomes:

= 35

### Like this:

Like Loading...

*Related*