rearrangement calculator

Rearrangement Calculator

Use this tool to compute common permutation and rearrangement counts in one click.

Enter comma-separated positive integers that add up to n. Example for BALLOON: 1,1,2,2,1
Enter values and click Calculate.

What is a rearrangement?

A rearrangement is a way of ordering items. In combinatorics, this usually means permutations: counting how many distinct orders are possible under different rules.

This calculator handles three common cases:

  • All items distinct: number of full rearrangements is n!.
  • Choose and order r items: count is nPr = n!/(n-r)!.
  • Some items repeated: count is n!/(a!b!c!...) where each letter count appears in the denominator.

How to use this calculator

1) Full rearrangements

Enter only n. The calculator returns how many ways to arrange all n distinct items.

2) Partial rearrangements (nPr)

Enter both n and r. This answers: “How many ordered selections of size r can be made from n items?”

3) Rearrangements with repeated items

If some items are identical, enter their group counts (comma-separated) in the duplicate field. The counts must sum to n. For example, the letters in “BALLOON” have counts 1,1,2,2,1.

Worked examples

Example A: Distinct objects

Suppose you have 5 unique books. Number of shelf orders: 5! = 120.

Example B: Race medals

From 10 runners, choose gold/silver/bronze (order matters): 10P3 = 10 × 9 × 8 = 720.

Example C: Word with repeated letters

For “BALLOON” (n=7, repeated counts 2 and 2): 7!/(2!2!) = 1260 distinct arrangements.

Common mistakes to avoid

  • Using combinations when order matters. Rearrangements are order-sensitive.
  • For repeated items, forgetting to divide by factorials of duplicate counts.
  • Using decimal or negative values. These formulas require whole numbers.
  • Entering duplicate counts that do not total n.

Why this matters in real life

Rearrangement counting appears in password analysis, tournament scheduling, data science feature ordering, seating plans, cryptography puzzles, and probability questions. A fast calculator helps you validate homework, test intuition, and avoid arithmetic errors with large factorials.

Quick reference formulas

  • 0! = 1
  • n! = n × (n-1) × ... × 2 × 1
  • nPr = n!/(n-r)!
  • Multiset permutations = n!/(a!b!c!...)

🔗 Related Calculators