Google Sheets PERMUT Function: Usage and Examples
In this article
The PERMUT function in Google Sheets calculates the number of possible permutations for a given set of data. A permutation is a mathematical calculation used to find the number of ways to choose and arrange a specific number of items from a larger set where the order of selection matters. For example, if you are choosing a gold, silver, and bronze medalist from a group of ten athletes, the order is critical, making this a permutation problem rather than a combination problem.
What You'll Need
- A Google account with access to Google Sheets.
- A dataset consisting of a total number of items (n) and the number of items to be selected (k).
- Basic understanding of the difference between permutations (order matters) and combinations (order does not matter).
Step-by-Step
- Open your Google Sheet: Navigate to your browser and open the specific spreadsheet where you want to perform the calculation.
- Identify your variables: Determine your "n" value (the total number of items in the set) and your "k" value (the number of items you are choosing from that set). For instance, if you have 5 different colors of paint and want to know how many ways you can pick 3 of them to paint a striped wall in a specific order, n = 5 and k = 3.
- Select the target cell: Click on the cell where you want the result of the permutation calculation to appear.
- Enter the function start: Type
=PERMUT(into the cell. This tells Google Sheets that you are initiating the permutation formula. - Input the first argument (n): Type the total number of items. You can either enter a raw number (e.g.,
10) or click on a cell that contains that number (e.g.,A2). - Add the separator: Type a comma (
,) to separate the first argument from the second. - Input the second argument (k): Type the number of items to be selected. Again, you can enter a raw number (e.g.,
3) or reference a cell (e.g.,B2). - Close the function: Type a closing parenthesis
)to complete the formula. Your final formula should look something like=PERMUT(10, 3)or=PERMUT(A2, B2). - Execute the calculation: Press the Enter key on your keyboard. Google Sheets will immediately calculate the result and display the total number of permutations in the cell.
Common Mistakes
One of the most frequent errors is confusing the PERMUT function with the COMBIN function. In a combination, the order of items does not matter (e.g., picking three fruits for a salad). In a permutation, the order is the defining factor (e.g., assigning people to specific seats in a row). If you use PERMUT when you should have used COMBIN, your result will be significantly higher than it should be because the formula counts every different arrangement of the same items as a unique outcome.
Another common mistake is reversing the arguments. The formula requires the total set (n) to come first, followed by the selection size (k). If you enter =PERMUT(3, 10), Google Sheets will return a #NUM! error because it is mathematically impossible to choose 10 unique items from a set of only 3.
Users also occasionally attempt to use non-integer values. The PERMUT function is designed for discrete items. If you enter a decimal (e.g., 10.5), Google Sheets will truncate the value to the nearest integer, which may lead to unexpected results if you are not aware that the software is rounding down your input.
Tips
To make your spreadsheets more dynamic, avoid hard-coding numbers directly into the formula. Instead, place your "n" and "k" values in their own labeled cells (e.g., Cell A1: "Total Items", Cell B1: "Items to Pick"). Then, reference those cells in your formula: =PERMUT(A2, B2). This allows you to change the parameters of your calculation instantly without having to edit the formula itself.
When dealing with very large sets, be aware that permutation results grow exponentially. A set of 20 items picking 10 can result in a massive number that may be displayed in scientific notation (e.g., 6.7044257E+11). If you need to see the full number, you can change the cell formatting by going to Format > Number > Number and increasing the decimal places or removing them entirely.
If you are calculating permutations where the same item can be picked more than once (permutations with repetition), the PERMUT function cannot be used. The PERMUT function assumes "sampling without replacement." For permutations with repetition, the mathematical formula is n raised to the power of k. In Google Sheets, you would achieve this using the power operator: =A2^B2.
Troubleshooting
If your formula is not working as expected, first check for the #NUM! error. This almost always means that your second argument (k) is larger than your first argument (n), or that one of the numbers is negative. Ensure that n ≥ k ≥ 0.
If you see a #VALUE! error, it means that one of the arguments provided is not a number. Check the cells you are referencing to ensure they do not contain hidden spaces, text, or special characters. If the number is formatted as text, the formula may fail. You can fix this by selecting the cells and going to Format > Number > Number.
If the result seems incorrectly high, double-check your logic to ensure you actually need a permutation. Ask yourself: "If I swap the order of two selected items, does it count as a different result?" If the answer is no, replace PERMUT with COMBIN.
If the formula simply displays as text in the cell instead of the result, ensure that you started the entry with an equals sign (=). Additionally, check that the cell is not formatted as "Plain Text" via the Format menu, as this prevents Google Sheets from executing formulas.
Frequently Asked Questions
What is the difference between PERMUT and COMBIN?
PERMUT is used when the order of selection matters (e.g., first, second, and third place). COMBIN is used when the order does not matter (e.g., selecting a committee of three people from a group).
Can I use PERMUT for lists of names instead of numbers?
The PERMUT function only accepts numbers. If you have a list of names, you must first count the total number of names using the =COUNTA() function and use that resulting number as the "n" argument in your PERMUT formula.
Does PERMUT allow for duplicate items in the selection?
No, the PERMUT function calculates permutations without replacement. This means once an item is selected from the set, it cannot be selected again for that same arrangement.
What is the maximum number of items PERMUT can handle?
While there is no hard limit on the input number, Google Sheets has a maximum value it can display. If the result exceeds the capacity of a 64-bit float, the number will be rounded or displayed in scientific notation.
How do I calculate permutations of an entire set?
To find the total permutations of a set where you use every single item (n=k), you can use =PERMUT(n, n). This is mathematically equivalent to calculating the factorial of n (n!). You can also use the =FACT(n) function to achieve the same result.