Set Operations and Venn Diagram
Find the union, intersection, difference, symmetric difference or complement of two finite sets. Compare the element lists, counts and highlighted Venn regions.
YOUR CALCULATION
Result
—
Calculation steps
Work through one step at a time or reveal the complete calculation. The steps use your current inputs.
How to calculate
Remove duplicate elements, compare membership in A and B, and partition their union into A-only, overlap and B-only regions. A complement requires an explicit universe; take all its elements that are not in A.
A∪B: either set; A∩B: both; A∖B: A only; A△B: exactly one set; Aᶜ=U∖A
Worked example
A={1,2,3,4}, B={3,4,5} gives union {1,2,3,4,5}, intersection {3,4}, A-only {1,2}, B-only {5} and symmetric difference {1,2,5}. With U={1,…,8}, the complement of A is {5,6,7,8}.
Assumptions and input details
Separate elements with commas, spaces, semicolons or newlines; optional outer braces are accepted. Numeric mode normalizes fractions and decimals, so 0.5 and 1/2 are one element. Numeric inputs use the same magnitude/denominator bounds as the fraction tools. Text mode is case-sensitive and treats numeric-looking labels literally. Empty input means an empty set. A and B allow 50 distinct elements each; U allows 100. Each label is at most 40 characters and each input at most 4000 characters. Duplicates are ignored and input order is preserved. A complement requires U to contain both A and B. Diagram regions show counts and membership, not proportional areas.
Using this calculator
Can I enter my own problem?
Yes. Replace the example values with your own inputs. The result, calculation steps, tables and applicable diagrams update from those inputs. Blank or invalid values clear the result; example values are never silently substituted for missing inputs.
Are the results exact?
Membership and counts are exact. Numeric elements are normalized using exact fractions; text labels match exactly and are case-sensitive.
Is my input uploaded?
The calculation runs in your browser. No account, file upload or external AI service is required. Inputs are not saved between page reloads.
Calculate a two-draw color event with or without replacement. Follow a probability tree, multiply along each path and add the matching outcomes.
Count ordered or unordered selections, with or without repetition. Read the exact integer result, compare all four cases and list examples for small problems.
Calculate exactly k, at most k and at least k successes in independent trials. Explore the binomial distribution, expected value and standard deviation.
Reserved advertising space.