For example, if I have one cat, one dog, one guinea pig and two separate beds, I could achieve 3 different scenarios: cat and dog, cat and guinea pig, dog and guinea pig, or 6 scenarios if I allow for same animals but different ordering. In this case x=3 and n=2, so are there formulas to calculate the number of combinations for different values of x and n? Are other formulas possible in which repeated elements in the slots at the same time are not allowed? That is, I cannot have for n=3 and x=10 the same three elements together more than once.
How do I calculate the number of different combinations of x elements in n slots?
0
$\begingroup$
sequences-and-series
-
1While the distinctiveness of the animals is clear, you introduce an idea of "the same three elements together more than once". It is unclear what causes you to consider having elements more than once. Perhaps a less colorful and more mathematical example would clarify what it is you want to count. – 2017-01-26
-
0Using my example, what I meant was if n=3, then combinations are 6 (dog, cat, pig; dog, pig, cat; cat, dog, pig; cat, pig, dog; pig, dog, cat; pig, cat, dog), but if I do not allow the same elements together more than once, then the number of combinations is 1 (cat, dog, pig, in any order). – 2017-01-26
-
1Notice that $\binom{3}{3}=1$ and that $3\frac{3}{~}=3!=6$. Similarly $\binom{3}{2}=3$ and $3\frac{2}{~}=6$ It looks like you are asking about the difference between [combinations](https://en.wikipedia.org/wiki/Binomial_coefficient) and [permutations](https://en.wikipedia.org/wiki/Falling_factorial). The short answer is that there are $\binom{n}{k}=\frac{n!}{k!(n-k)!}$ ways to select $k$ elements out of $n$ total distinct elements where order doesn't matter and there are $n\frac{k}{~}=\frac{n!}{(n-k)!}$ ways to select $k$ elements out of $n$ total distinct where order does matter. – 2017-01-26
-
0@JMoravitz I believe this is it! I was indeed wondering if there was a significant difference between both cases. – 2017-01-26