Smart Systems for Home

Plain how-to guides for smart home, security and home Wi-Fi

Google Sheets PERMUT function: How to Use It

· 6 min read · Home Tech

In this article
  1. What You'll Need
  2. Step-by-Step
  3. Common Mistakes
  4. Tips
  5. Troubleshooting
  6. Frequently Asked Questions

The PERMUT function in Google Sheets calculates the number of possible permutations for a given set of objects. A permutation is a mathematical calculation used to find the number of ways to 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 or two specific numbers: the total number of items in your set (n) and the number of items you are selecting (k).
  • A basic understanding of the difference between permutations (order matters) and combinations (order does not matter).

Step-by-Step

  1. Open your Google Sheet: Launch your browser and open the specific spreadsheet where you want to perform the calculation. Ensure you are signed into the correct Google account.
  2. Identify your variables: Before typing the formula, determine your two necessary values. The first value is the total number of items available (referred to as 'n'). The second value is the number of items you are choosing from that set (referred to as 'k'). 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.
  3. Select the target cell: Click on the empty cell where you want the result of the permutation to appear.
  4. Enter the function name: Type =PERMUT( into the cell. This tells Google Sheets that you are calling the permutation function.
  5. Input the total set (n): Immediately after the opening parenthesis, type the total number of items or click on a cell that contains this number. For example, if your total set is 10, type 10. Then, type a comma to separate the arguments.
  6. Input the selection size (k): After the comma, type the number of items being selected or click on the cell containing that value. For example, if you are selecting 3 items, type 3.
  7. Close the parenthesis and execute: Type the closing parenthesis ) and press the Enter key on your keyboard. The cell will now display the total number of permutations. The formula should look like =PERMUT(10, 3).
  8. Verify the result: Double-check the math. The PERMUT function calculates the result using the formula n! / (n - k)!. In the case of 10 items chosen 3 at a time, the math is 10 * 9 * 8, which equals 720.

Common Mistakes

One of the most frequent errors is confusing the PERMUT function with the COMBIN function. In a combination, the order of the items does not matter (e.g., picking a committee of three people from a group of ten). In a permutation, the order is the defining factor (e.g., picking a President, Vice President, and Secretary from a group of ten). If you use PERMUT when you should have used COMBIN, your result will be significantly higher than it should be because the function counts every different ordering of the same items as a unique event.

Another common mistake is reversing the order of the arguments. The function requires the total set (n) first and the selection size (k) second. If you enter the smaller number first, Google Sheets will likely return a #NUM! error because it is mathematically impossible to choose a larger number of items from a smaller set without repetition.

Users also sometimes attempt to use the PERMUT function for scenarios involving repetition. The standard PERMUT function assumes that once an item is selected, it cannot be selected again (sampling without replacement). If your scenario allows for the same item to be picked multiple times—such as a 3-digit PIN code where the number 5 can appear three times—the PERMUT function is not the correct tool. In those cases, you would simply use the exponentiation operator (e.g., 10^3).

Tips

To make your spreadsheet more dynamic and professional, avoid hard-coding numbers directly into the formula. Instead, place your 'n' value in cell A2 and your 'k' value in cell B2. Then, write your formula as =PERMUT(A2, B2). This allows you to change the numbers in the cells and see the result update instantly without having to edit the formula itself.

If you are dealing with very large sets of data, be aware that the results of permutation calculations grow exponentially. Very large numbers may be displayed in scientific notation (e.g., 1.23E+10). To change this to a standard number, go to Format > Number > Number and adjust the decimal places as needed.

When documenting your work, it is helpful to label your columns clearly. Label the first column "Total Pool (n)" and the second "Items Selected (k)" so that anyone else viewing the sheet understands the logic behind the calculation.

Troubleshooting

If the function does not go to plan, first check for the #NUM! error. This occurs if the second argument (k) is larger than the first argument (n), or if either argument is a negative number. Ensure that your total pool is always the larger of the two numbers and that both are positive integers.

If you see a #VALUE! error, it means that one of the arguments is not a number. Check the cells you are referencing to ensure they do not contain text, hidden spaces, or special characters. If the number is formatted as text, the PERMUT function will not be able to process it. You can fix this by selecting the cells and going to Format > Number > Number.

If the result seems incorrectly high, re-evaluate whether the order of your items actually matters. If you are simply grouping items together and the sequence of those items is irrelevant, delete the PERMUT function and replace it with =COMBIN(n, k).

If the formula is not calculating at all and just appearing as text in the cell, check to see if you forgot the equals sign (=) at the beginning. Without the equals sign, Google Sheets treats the entry as a standard text string rather than a mathematical command.

Frequently Asked Questions

What is the difference between PERMUT and PERMUTATION?

In Google Sheets, the official function name is PERMUT. There is no function named "PERMUTATION." If you type the full word, the spreadsheet will not recognize it as a formula.

Can I use PERMUT for lists of names instead of numbers?

The PERMUT function only accepts numbers as arguments. It calculates the number of possible arrangements, not the arrangements themselves. If you have a list of names and want to see every possible combination of them, you would need to use a complex script or a third-party add-on, as there is no native function to generate a list of all permutations.

What happens if n and k are the same number?

If n and k are identical, the function is calculating the total number of ways to arrange the entire set. This is mathematically equivalent to calculating the factorial of n (n!). For example, =PERMUT(5, 5) will give the same result as =FACT(5), which is 120.

Does PERMUT allow for repetition of items?

No, the PERMUT function is designed for sampling without replacement. It assumes that each item in the set is unique and can only be used once in the arrangement. For sampling with replacement, use the formula =n^k.

Is there a limit to how large the numbers can be?

Google Sheets can handle very large numbers, but there is a limit to the precision of floating-point numbers. If your permutation result is astronomically large, it may be rounded or displayed in scientific notation. For most practical business or academic applications, this is rarely an issue.

Can I nest the PERMUT function inside other formulas?

Yes, you can use the result of a PERMUT function as an argument in another formula. For example, you could divide a PERMUT result by another number to find a probability, or use it within an IF statement to trigger a specific alert if the number of possibilities exceeds a certain threshold.