Combinations with Repetition Calculator

Count combinations when repeats are allowed.

How to use

  1. Enter your values in the fields above.
  2. Press Calculate to see your result instantly.
  3. Use the Share button to copy a link to your result.

About this calculator

This calculator counts combinations with repetition (also called multiset coefficients) — the number of ways to choose r items from n types when repeats are allowed and order doesn't matter — using the formula C(n+r−1, r) = (n+r−1)! / (r!·(n−1)!). The formula comes from the “stars and bars” technique: representing each selection as a row of r stars split into n groups by n−1 bars, which turns the counting problem into an ordinary combination C(n+r−1, r).

Students and instructors in combinatorics and discrete math courses use it to work through classic examples like choosing r scoops from n ice cream flavors with repeats allowed, or distributing identical objects into distinguishable bins; computer scientists use the same math to count multisets and evaluate generating functions; and statisticians use it when analyzing sampling schemes done with replacement. Enter the number of types (n) and the number chosen (r) to get the count.

Was this helpful?

Comments (0)

  • Be the first to comment.

Popular calculators

All Calculators