Combinations Calculator (nCr) (2024)

Calculator Use

The Combinations Calculator will find the number of possible combinations that can be obtained by taking a sample of items from a larger set. Basically, it shows how many different possible subsets can be made from the larger set. For this calculator, the order of the items chosen in the subset does not matter.

Factorial
There are n! ways of arranging n distinct objects into an ordered sequence, permutations where n = r.
Combination
The number of ways to choose a sample of r elements from a set of n distinct objects where order does not matter and replacements are not allowed.
Permutation
The number of ways to choose a sample of r elements from a set of n distinct objects where order does matter and replacements are not allowed. When n = r this reduces to n!, a simple factorial of n.
Combination Replacement
The number of ways to choose a sample of r elements from a set of n distinct objects where order does not matter and replacements are allowed.
Permutation Replacement
The number of ways to choose a sample of r elements from a set of n distinct objects where order does matter and replacements are allowed.
n
the set or population
r
subset of n or sample set

Combinations Formula:

\( C(n,r) = \dfrac{n!}{( r! (n - r)! )} \)

For n ≥ r ≥ 0.

The formula show us the number of ways a sample of “r” elements can be obtained from a larger set of “n” distinguishable objects where order does not matter and repetitions are not allowed. [1] "The number of ways of picking r unordered outcomes from n possibilities." [2]

Also referred to as r-combination or "n choose r" or the binomial coefficient. In some resources the notation uses k instead of r so you may see these referred to as k-combination or "n choose k."

Combination Problem 1

Choose 2 Prizes from a Set of 6 Prizes

You have won first place in a contest and are allowed to choose 2 prizes from a table that has 6 prizes numbered 1 through 6. How many different combinations of 2 prizes could you possibly choose?

In this example, we are taking a subset of 2 prizes (r) from a larger set of 6 prizes (n). Looking at the formula, we must calculate “6 choose 2.”

C (6,2)= 6!/(2! * (6-2)!) = 6!/(2! * 4!) = 15 Possible Prize Combinations

The 15 potential combinations are {1,2}, {1,3}, {1,4}, {1,5}, {1,6}, {2,3}, {2,4}, {2,5}, {2,6}, {3,4}, {3,5}, {3,6}, {4,5}, {4,6}, {5,6}

Combination Problem 2

Choose 3 Students from a Class of 25

A teacher is going to choose 3 students from her class to compete in the spelling bee. She wants to figure out how many unique teams of 3 can be created from her class of 25.

In this example, we are taking a subset of 3 students (r) from a larger set of 25 students (n). Looking at the formula, we must calculate “25 choose 3.”

C (25,3)= 25!/(3! * (25-3)!)= 2,300 Possible Teams

Combination Problem 3

Choose 4 Menu Items from a Menu of 18 Items

A restaurant asks some of its frequent customers to choose their favorite 4 items on the menu. If the menu has 18 items to choose from, how many different answers could the customers give?

Here we take a 4 item subset (r) from the larger 18 item menu (n). Therefore, we must simply find “18 choose 4.”

C (18,4)= 18!/(4! * (18-4)!)= 3,060 Possible Answers

Handshake Problem

In a group of n people, how many different handshakes are possible?

First, let's find the total handshakes that are possible. That is to say, if each person shook hands once with every other person in the group, what is the total number of handshakes that occur?

A way of considering this is that each person in the group will make a total of n-1 handshakes.Since there are n people, there would be n times (n-1) total handshakes. In other words, the total number of people multiplied by the number of handshakes that each can make will be the total handshakes. A group of 3 would make a total of 3(3-1) = 3 * 2 = 6. Each person registers 2 handshakes with the other 2 people in the group; 3 * 2.

Total Handshakes = n(n-1)

However, this includes each handshake twice (1 with 2, 2 with 1, 1 with 3, 3 with 1, 2 with 3 and 3 with 2) and since the orginal question wants to know how many different handshakes are possible we must divide by 2 to get the correct answer.

Total Different Handshakes = n(n-1)/2

Handshake Problem as a Combinations Problem

We can also solve this Handshake Problem as a combinations problem as C(n,2).

n (objects) = number of people in the group
r (sample) = 2, the number of people involved in each different handshake

The order of the items chosen in the subset does not matter so for a group of 3 it will count 1 with 2, 1 with 3, and 2 with 3 but ignore 2 with 1, 3 with 1, and 3 with 2 because these last 3 are duplicates of the first 3 respectively.

\( C(n,r) = \dfrac{n!}{( r! (n - r)! )} \)

\( C(n,2) = \dfrac{n!}{( 2! (n - 2)! )} \)

expanding the factorials,

\( = \dfrac{1\times2\times3...\times(n-2)\times(n-1)\times(n)}{( 2\times1\times(1\times2\times3...\times(n-2)) )} \)

cancelling and simplifying,

\( = \dfrac{(n-1)\times(n)}{2} = \dfrac{n(n-1)}{2} \)

which is the same as the equation above.

Sandwich Combinations Problem

This is a classic math problem and asks something like How many sandwich combinations are possible? and this is how it generally goes.

Calculate the possible sandwich combinations if you can choose one item from each of the four categories:

  • 1 bread from 8 options
  • 1 meat from 5 options
  • 1 cheese from 5 options
  • 1 topping from 3 options

Often you will see the answer, without any reference to the combinations equation C(n,r), as the multiplication of the number possible options in each of the categories. In this case we calculate:

8 × 5 × 5 × 3 = 600
possible sandwich combinations

In terms of the combinations equation below, the number of possible options for each category is equal to the number of possible combinations for each category since we are only making 1 selection; for example C(8,1) = 8, C(5,1) = 5 and C(3,1) = 3 using the following equation:

C(n,r) = n! / ( r!(n - r)! )

We can use this combinations equation to calculate a more complex sandwich problem.

Sandwich Combinations Problem with Multiple Choices

Calculate the possible combinations if you can choose several items from each of the four categories:

  • 1 bread from 8 options
  • 3 meats from 5 options
  • 2 cheeses from 5 options
  • 0 to 3 toppings from 3 options

Applying the combinations equation, where order does not matter and replacements are not allowed, we calculate the number of possible combinations in each of the categories. You can use the calculator above to prove that each of these is true.

  • 1 bread from 8 options is C(8,1) = 8
  • 3 meats from 5 options C(5,3) = 10
  • 2 cheeses from 5 options C(5,2) = 10
  • 0 to 3 toppings from 3 options; we must calculate each possible number of choices from 0 to 3 and get C(3,0) + C(3,1) + C(3,2) + C(3,3) = 8

Multiplying the possible combinations for each category we calculate:

8 × 10 × 10 × 8 = 6,400
possible sandwich combinations

How many possible combinations are there if your customers are allowed to choose options like the following that still stay within the limits of the total number of portions allowed:

  • 2 portions of one meat and 1 portion of another?
  • 3 portions of one meat only?
  • 2 portions of one cheese only?

In the previous calculation, replacements were not allowed; customers had to choose 3 different meats and 2 different cheeses. Now replacements are allowed, customers can choose any item more than once when they select their portions. For meats and cheeses this is now a combinations replacement or multichoose problem using the combinations with replacements equation:

CR(n,r) = C(n+r-1, r) = (n+r-1)! / (r! (n - 1)!)

For meats, where the number of objects n = 5 and the number of choices r = 3, we can calculate either combinations replacement CR(5,3) = 35 or substitute terms and calculate combinations C(n+r-1, r) = C(5+3-1, 3) = C(7, 3) = 35.

Calculating cheese choices in the same way, we now have the total number of possible options for each category at

  • bread is 8
  • meat is 35
  • cheese is 15
  • toppings is 8

and finally we multiply to find the total

8 × 35 × 15 × 8 = 33,600
possible sandwich combinations!

How many combinations are possible if customers are also allowed replacements when choosing toppings?


References

[1] Zwillinger, Daniel (Editor-in-Chief). CRC Standard Mathematical Tables and Formulae, 31st Edition New York, NY: CRC Press, p.206, 2003.

For more information on combinations and binomial coefficients please see Wolfram MathWorld: Combination.

Combinations Calculator (nCr) (2024)

FAQs

What is the formula for combinations in NCR? ›

Remember that combinations are a way to calculate the total outcomes of an event where order of the outcomes does not matter. To calculate combinations, we will use the formula nCr = n! / r! * (n - r)!, where n represents the number of items, and r represents the number of items being chosen at a time.

How do I calculate the number of possible combinations? ›

So the formula for calculating the number of combinations is the number of permutations/k!. the number of permutations is equal to n!/(n-k)! so the number of combinations is equal to (n!/(n-k)!)/k! which is the same thing as n!/(k!*( n-k)!).

How many combinations of 18 items are there? ›

118! ways to select 18 items. But we don't care about order. If we pick 18 items it does not matter what order we seected them in.

How to calculate nCr without a calculator? ›

To calculate combinations, the order does not matter where we use the nCr formula: nCr = n! / r! * (n - r)!, where n = number of items, and r = number of items being chosen at a time.

What is the shortcut to calculate nCr? ›

Ans : When determining the total number of possible outcomes of an event, combinations are a useful tool to use when the sequence in which the possibilities occur is irrelevant. We utilise the nCr formula to compute combinations. This formula is as follows: nCr = n! / r!

What is the fastest way to calculate combinations? ›

To calculate the number of r-combinations from a set of n elements, we use the binomial coefficient notation C(n,r), which gives the formula C(n,r) = n! / (r!( n-r)!). This formula counts the number of ways to choose an unordered subset of r elements from a set of n elements.

What is the nPr and nCr formula? ›

The nPr and nCr formula are: Pr = n! / (n – r)! Cr = = n! / r! × (n – r)!

How many possible 4 digit combinations are there? ›

A 4 digit PIN number is selected. What is the probability that there are no repeated digits? There are 10 possible values for each digit of the PIN (namely: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9), so there are 10 · 10 · 10 · 10 = 104 = 10000 total possible PIN numbers.

What is the fastest way to calculate nCr? ›

= log(1) + log(2) + … + log(n) to express the numerator and denominator of the nCr in terms of sums of logarithms which allows to calculate the nCr using the Logarithmic operations. This approach is faster and very efficient.

What is the formula for combinations and permutations? ›

What is the formula for permutations and combinations? The formula for permutations is: nPr = n!/(n-r)! The formula for combinations is: nCr = n!/[r! (n-r)!]

How to calculate all possible combinations? ›

Combinations Formula:

C(n,r)=n!(r!(n−r)!) For n ≥ r ≥ 0. Also referred to as r-combination or "n choose r" or the binomial coefficient. In some resources the notation uses k instead of r so you may see these referred to as k-combination or "n choose k."

How many combinations of 20 objects are there? ›

Answer and Explanation:

To find the number of combinations that are possible with 20 numbers, we can use our formula for the number of possible combinations with n elements, where n = 20. Simplify. We get that there are 1,048,575 possible combinations that are possible with 20 numbers.

What is the formula for the combination rule? ›

The number of combinations of n objects taken r at a time is determined by the following formula: C(n,r)=n! (n−r)! r!

What is the formula for combinations permutations? ›

Derivation of Combinations Formula

C(n, r) = Total Number of Permutations /Number of ways to arrange r different objects. [Since by the fundamental theorem of counting, we know that number of ways to arrange r different objects in r ways = r!] C(n,r) = P (n, r)/ r!

What is the nPr formula for nCr? ›

The nPr and nCr formula are: Pr = n! / (n – r)! Cr = = n! / r! × (n – r)!

How many possible combinations of 4 numbers are there? ›

10 ⋅ 10 ⋅ 10 ⋅ 10 = 10 4 = 10 , 000 .

Top Articles
Latest Posts
Recommended Articles
Article information

Author: Otha Schamberger

Last Updated:

Views: 6116

Rating: 4.4 / 5 (75 voted)

Reviews: 82% of readers found this page helpful

Author information

Name: Otha Schamberger

Birthday: 1999-08-15

Address: Suite 490 606 Hammes Ferry, Carterhaven, IL 62290

Phone: +8557035444877

Job: Forward IT Agent

Hobby: Fishing, Flying, Jewelry making, Digital arts, Sand art, Parkour, tabletop games

Introduction: My name is Otha Schamberger, I am a vast, good, healthy, cheerful, energetic, gorgeous, magnificent person who loves writing and wants to share my knowledge and understanding with you.