Math

Permutation Calculator

Calculate permutations P(n,r) — the number of ordered arrangements of r items chosen from n items.

Quick Answer

P(n,r) = n! / (n−r)!. For example, P(5,3) = 5! / 2! = 120 / 2 = 60 ordered arrangements.

Enter Values

Examples:

Results

Enter n and r values (r ≤ n, n ≤ 170) to calculate permutations.

About This Tool

The Permutation Calculator computes P(n,r) — the number of ways to arrange r items from a set of n items where the order of arrangement matters. This differs from combinations, where order is irrelevant. Permutations are fundamental to probability, cryptography, and counting problems.

The Permutation Formula

P(n,r) = n! / (n−r)!. The numerator counts all possible orderings of n items. The denominator removes the orderings of the (n−r) items that were not selected. The result gives you only the arrangements of the r selected items.

Permutations vs. Combinations

The key difference: in permutations, ABC and CBA are different arrangements. In combinations, they count as the same group. P(n,r) is always greater than or equal to C(n,r), with P(n,r) = C(n,r) × r!. Use permutations when the position or order of the selection matters.

Real-World Applications

PIN codes, passwords, race finishing orders, phone numbers, and license plates all involve permutations. A 4-digit PIN from digits 0–9 has P(10,4) = 5,040 possibilities (without repetition). With repetition allowed, it becomes 10^4 = 10,000. Understanding which model applies is crucial for security analysis.

Permutations with Repetition

This calculator handles permutations without repetition. When items can repeat (like digits in a PIN), the formula is n^r instead. A 4-character password from 26 letters with repetition has 26^4 = 456,976 possibilities, compared to P(26,4) = 358,800 without repetition.

Frequently Asked Questions

What is a permutation?
A permutation is an ordered arrangement of items. ABC, ACB, BAC, BCA, CAB, and CBA are all different permutations of the same three items. Order matters in permutations.
How do permutations differ from combinations?
Permutations count ordered arrangements; combinations count unordered groups. Choosing a president and VP from 10 people (P(10,2)=90) differs from choosing a 2-person committee (C(10,2)=45).
What is P(n,n)?
P(n,n) = n!, which is the total number of ways to arrange all n items. For example, P(4,4) = 4! = 24 ways to arrange 4 items.
How do I calculate permutations with repetition?
When items can repeat, use n^r instead of P(n,r). For a 3-digit code using digits 0-9: 10^3 = 1,000 possibilities instead of P(10,3) = 720.
Why is P(n,r) always larger than C(n,r)?
Because P(n,r) counts each ordering separately. P(n,r) = C(n,r) × r!. The extra factor of r! accounts for all the ways to arrange each combination.

Was this tool helpful?