Number of Subsets Calculator

Enter the number of elements to count all of its subsets.

How to use

  1. Enter your values in the fields above.
  2. Press Calculate to see your result instantly.
  3. Use the Share button to copy a link to your result.

About this calculator

A set with n elements has exactly 2ⁿ subsets in total, including the empty set and the set itself — this comes from the fact that building any subset means making an independent include-or-exclude decision for each of the n elements, giving 2 choices multiplied together n times. From that total, the number of proper subsets is 2ⁿ − 1 (every subset except the full set), the number of non-empty subsets is also 2ⁿ − 1 (every subset except the empty set), and the number of two-element subsets is given by the combination formula C(n,2) = n(n−1)/2.

This counting shows up throughout combinatorics and computer science: algorithms that enumerate all subsets of a collection — for example brute-force solutions to the knapsack problem or subset-sum problem — commonly represent each subset as a binary bitmask from 0 to 2ⁿ − 1, directly using this same 2ⁿ relationship. It is also one of the standard results taught in discrete math courses to introduce the power set.

Enter the number of elements in a set and the calculator returns the total number of subsets, along with the proper, non-empty and two-element subset counts.

Was this helpful?

Comments (0)

  • Be the first to comment.

Popular calculators

All Calculators