Subset Calculator
Enter the elements of your set (separated by commas) to instantly count all subsets, proper subsets, and see the full power set listed. Switch to cardinality mode if you just need the counts for a set of a given size. The calculator shows every step of the math so you can follow along.
What is a subset?
A set A is a subset of set B (written A ⊆ B) if every element of A is also an element of B. For example, {1, 2} is a subset of {1, 2, 3} because both 1 and 2 appear in the larger set. The empty set (denoted by the symbol similar to a zero with a slash) is a subset of every set, including itself. The full set is always a subset of itself too. When A is a subset of B but A and B are not identical, A is called a proper subset (written A ⊂ B or A ⊊ B, depending on the convention used).
How many subsets does a set have?
If a set has n distinct elements, it has exactly 2^n subsets in total. This is because each element is either included or excluded from a subset, giving two independent choices per element, and 2 x 2 x ... x 2 (n times) = 2^n. Of those, exactly 2^n - 1 are proper subsets, because you subtract the one subset that equals the full set. A set with 3 elements has 2^3 = 8 subsets: the empty set, three single-element subsets, three two-element subsets, and the full three-element set. To count subsets of a specific size k, use the binomial coefficient C(n, k) = n! / (k! x (n-k)!). For example, C(5, 2) = 10 tells you there are 10 two-element subsets of a five-element set.
The power set
The collection of all subsets of a set S is called the power set of S, written P(S) or 2^S. If S = {a, b, c}, then P(S) = {empty set, {a}, {b}, {c}, {a,b}, {a,c}, {b,c}, {a,b,c}}, which has 2^3 = 8 members. The power set always includes the empty set and the original set itself. Power sets appear throughout mathematics and computer science: in logic they encode all possible truth assignments, in combinatorics they underpin counting arguments, and in database theory they relate to the set of possible index keys.
Proper subsets vs. improper subsets
An improper subset of S is S itself (every set is a subset of itself). All other subsets - including the empty set - are proper subsets. If you have a set with n elements, there is exactly 1 improper subset and 2^n - 1 proper subsets. Some textbooks also count the empty set separately as an improper subset, giving a total of 2 improper subsets (the empty set and the full set) and 2^n - 2 proper subsets, but the most common convention is that the empty set is a proper subset. This calculator follows the common convention: proper subsets = 2^n - 1.
Subsets by set size (n)
| n (elements) | Total subsets (2^n) | Proper subsets (2^n - 1) | Subsets of size 1 | Subsets of size 2 |
|---|---|---|---|---|
| 0 | 1 | 0 | 0 | 0 |
| 1 | 2 | 1 | 1 | 0 |
| 2 | 4 | 3 | 2 | 1 |
| 3 | 8 | 7 | 3 | 3 |
| 4 | 16 | 15 | 4 | 6 |
| 5 | 32 | 31 | 5 | 10 |
| 6 | 64 | 63 | 6 | 15 |
| 7 | 128 | 127 | 7 | 21 |
| 8 | 256 | 255 | 8 | 28 |
| 9 | 512 | 511 | 9 | 36 |
| 10 | 1024 | 1023 | 10 | 45 |
Total and proper subsets for common set sizes, using 2^n and 2^n - 1.
Frequently asked questions
What is the formula for the number of subsets?
A set with n elements has 2^n subsets in total. The exponent n is the number of distinct elements (the cardinality). So a set with 4 elements has 2^4 = 16 subsets, and a set with 10 elements has 2^10 = 1,024 subsets. The formula follows from the fact that each element is either included or excluded, giving 2 choices per element.
How many proper subsets does a set have?
A set with n elements has 2^n - 1 proper subsets. This equals the total number of subsets minus 1, because the full set is the only subset that is not proper. For example, {1, 2, 3} has 2^3 - 1 = 7 proper subsets.
Is the empty set a subset of every set?
Yes. By definition, A is a subset of B if every element of A is also in B. Since the empty set has no elements, there is nothing to check, so the condition is vacuously true for any set B. The empty set is a proper subset of every non-empty set, and an improper subset of itself.
How do I count subsets of a specific size?
Use the binomial coefficient C(n, k) = n! / (k! x (n-k)!), where n is the total number of elements and k is the desired subset size. For instance, to count 3-element subsets of a 5-element set: C(5, 3) = 5! / (3! x 2!) = 120 / 12 = 10. The "Subsets of size k" input on this calculator computes this for you.
What is the difference between a subset and a proper subset?
A subset A of B can equal B (every set is a subset of itself). A proper subset must be strictly smaller: A is a proper subset of B if A ⊆ B and A is not equal to B. In other words, proper subsets exclude the set itself. For a set with n elements there are 2^n subsets total and 2^n - 1 proper subsets.
How many subsets does the empty set have?
Exactly 1: the empty set itself. Using the formula: 2^0 = 1. That one subset is also the empty set, which is an improper subset of itself. There are 0 proper subsets of the empty set.