Sets and functions

NUST NET (Engineering) · Maths · Numbers, sets and functions. A short explanation of the idea, the rules to remember, the mistake to avoid, a worked example and practice questions with answers.

Test this topic freeAll NUST NET (Engineering) topics

The idea

Set questions are counting questions. A Venn diagram shows the union A ∪ B (in A or B or both), the intersection A ∩ B (in both) and the complement A′ (not in A). When two groups overlap, the overlap is counted twice unless you subtract it once.

A function gives each input exactly one output. Its domain is the set of allowed inputs and its range is the set of outputs it actually produces. To find a domain, look for what must be avoided: a zero denominator, or a negative number under a square root.

A composite f∘g means g acts first, then f. An inverse undoes the function and exists only when the function is one-one.

Rules to remember

Common mistake

Working out f∘g in the wrong order. (f∘g)(x) means f(g(x)), so g is applied first; f(x) × g(x) and g(f(x)) are different things.

Worked example

If f(x) = 2x + 3 and (f∘g)(x) = 6x − 1, then g(x) is

  1. (f∘g)(x) = f(g(x)) = 2g(x) + 3.
  2. Set this equal to 6x − 1: 2g(x) + 3 = 6x − 1, so 2g(x) = 6x − 4.
  3. Divide by 2: g(x) = 3x − 2. Check: 2(3x − 2) + 3 = 6x − 1.

Answer: g(x) = 3x − 2

Practice questions

Try each one, then open the answer.

1. A set A has 128 subsets. The number of elements in A is

  1. A
    64
  2. B
    7
  3. C
    8
  4. D
    6
Show answer

Answer: B. A set with n elements has 2n subsets, and 27 = 128, so n = 7. Halving 128 to get 64 confuses subsets with elements.

2. If f(x) = 3x − 1 and g(x) = x2 + 2, then (f∘g)(1) is

  1. A
    8
  2. B
    6
  3. C
    5
  4. D
    3
Show answer

Answer: A. (f∘g)(1) = f(g(1)) = f(3) = 3(3) − 1 = 8. Working out g(f(1)) = g(2) = 6 uses the wrong order.

3. U = {1, 2, 3, ..., 10}, A is the set of primes in U and B is the set of odd numbers in U. Then A ∩ B′ is

  1. A
    {3, 5, 7}
  2. B
    {1, 9}
  3. C
    {2}
  4. D
    {1, 2, 9}
Show answer

Answer: C. A = {2, 3, 5, 7} and B′ is the set of even numbers {2, 4, 6, 8, 10}. The only even prime is 2. {3, 5, 7} is A ∩ B and {1, 9} is B − A.

More questions on this topic

Read the full notes

Keep going

← Complex numbersMatrices and determinants →All rules on one pageStuck? Ask a question