9.3 Sets, Venn Relations & Functions

Key Takeaways

  • Sets and Functions is a named item in the NTS Algebra block and also underpins the Venn-diagram word problems in the arithmetic block.
  • The two-set counting rule subtracts the overlap once: n(A union B) equals n(A) plus n(B) minus n(A intersection B).
  • De Morgan's laws convert the complement of a union into an intersection of complements, and vice versa.
  • A relation is a function only when every element of the domain maps to exactly one element of the range.
  • Composition applies the inner function first, so fg(x) means f evaluated at g of x, and reversing the order usually changes the answer.
Last updated: August 2026

Sets, Venn Relations & Functions

Sets and Functions closes the eight-item NTS Algebra block. It earns its place twice: the notation appears throughout the quantitative paper, and the inclusion-exclusion counting rules solve the survey word problems that NTS places in the arithmetic block as well.


Set Notation and Operations

SymbolNameMeaning
$\in$membership$x$ is an element of the set
$\subseteq$subsetevery element of the first set lies in the second
$\cup$unioneverything in either set
$\cap$intersectiononly what lies in both
$A'$ or $A^{c}$complementeverything in the universal set not in $A$
$A - B$differencein $A$ but not in $B$
$\varnothing$empty setcontains no elements

With $U = {1,2,3,4,5,6,7,8}$, $A = {1,2,3,4}$, $B = {3,4,5,6}$:

  • $A \cup B = {1,2,3,4,5,6}$
  • $A \cap B = {3,4}$
  • $A - B = {1,2}$
  • $A' = {5,6,7,8}$

Power set: a set with $n$ elements has $2^{n}$ subsets, of which $2^{n} - 1$ are proper subsets. A set of 5 elements therefore has 32 subsets. This is asked directly and is a free mark.

De Morgan's Laws

(AB)=AB(AB)=AB(A \cup B)' = A' \cap B' \qquad\qquad (A \cap B)' = A' \cup B'

The operation flips when the complement is distributed. Candidates who keep the union as a union lose the item.


Inclusion-Exclusion Counting

Two Sets

n(AB)=n(A)+n(B)n(AB)n(A \cup B) = n(A) + n(B) - n(A \cap B)

The overlap is counted once in each set, so it must be removed once.

Worked example. In a class of 90 students, 52 study Statistics, 45 study Economics, and 18 study both. How many study neither?

n(SE)=52+4518=79neither=9079=11n(S \cup E) = 52 + 45 - 18 = 79 \qquad\Rightarrow\qquad \text{neither} = 90 - 79 = 11

Three Sets

n(ABC)=n(A)+n(B)+n(C)n(AB)n(BC)n(AC)+n(ABC)n(A \cup B \cup C) = n(A) + n(B) + n(C) - n(A\cap B) - n(B\cap C) - n(A\cap C) + n(A\cap B\cap C)

The triple overlap is subtracted three times by the pairwise terms, so it must be added back once.

Worked example. Of 120 candidates, 70 revised Verbal, 60 revised Quantitative, 50 revised Analytical; 30 revised Verbal and Quantitative, 25 Quantitative and Analytical, 20 Verbal and Analytical, and 10 revised all three.

70+60+50302520+10=11570 + 60 + 50 - 30 - 25 - 20 + 10 = 115

So 115 revised at least one segment and 5 revised none.

Filling a Venn diagram correctly: always start from the centre and work outward, subtracting as you go. With 10 in all three, the Verbal-and-Quantitative-only region is $30 - 10 = 20$, and the Verbal-only region is $70 - 20 - 10 - 10 = 30$. Working inward from the outside is where sign errors creep in.


Functions

A relation pairs elements of a domain with elements of a range. It is a function only when every domain element has exactly one image.

RelationFunction?Why
${(1,3),(2,5),(3,7)}$Yeseach input used once
${(1,3),(1,5),(2,7)}$Nothe input 1 has two images
${(1,4),(2,4),(3,4)}$Yesrepeated outputs are permitted

The vertical line test states this graphically: if any vertical line meets the graph more than once, the relation is not a function. A circle fails; a parabola opening upward passes.

Domain and Range

  • $f(x) = \dfrac{1}{x-3}$ — the domain excludes $x = 3$, since division by zero is undefined.
  • $f(x) = \sqrt{x-5}$ — the domain requires $x \ge 5$, since a real square root needs a non-negative radicand.
  • $f(x) = x^{2}$ — the domain is all real numbers but the range is $y \ge 0$.

Types of Function

TypeCondition
One-to-one (injective)different inputs always give different outputs
Onto (surjective)every element of the codomain is used
Bijectiveboth, and therefore invertible

Composition

(fg)(x)=f(g(x))(f \circ g)(x) = f\bigl(g(x)\bigr)

The inner function is applied first. With $f(x) = 2x + 1$ and $g(x) = x^{2}$:

(fg)(3)=f(9)=19(gf)(3)=g(7)=49(f \circ g)(3) = f(9) = 19 \qquad\qquad (g \circ f)(3) = g(7) = 49

Composition is not commutative, and NTS builds an item on exactly that asymmetry almost every sitting.

Inverse Functions

To invert, swap $x$ and $y$ and solve. For $f(x) = 3x - 6$:

y=3x6    x=3y6    y=x+63    f1(x)=x+63y = 3x - 6 \;\Rightarrow\; x = 3y - 6 \;\Rightarrow\; y = \frac{x + 6}{3} \;\Rightarrow\; f^{-1}(x) = \frac{x+6}{3}

Check: $f(4) = 6$ and $f^{-1}(6) = 4$ ✓. Only one-to-one functions have inverses, which is why $f(x) = x^{2}$ has no inverse over all real numbers but does have one when restricted to $x \ge 0$.

Test Your Knowledge

In a group of 150 candidates, 88 have taken the GAT before, 64 have taken the NAT before, and 27 have taken both. How many have taken neither?

A
B
C
D
Test Your Knowledge

If f(x) = 4x - 3 and g(x) = x squared + 1, what is the value of the composition f(g(2))?

A
B
C
D
Test Your Knowledge

How many subsets does a set with 6 elements have?

A
B
C
D
Test Your Knowledge

Which expression is equivalent to the complement of (A intersection B)?

A
B
C
D