Practice Discrete Math

Relations / Functions

Least You Need to Know: Functions

A function gives exactly one output for each input in its domain. The key is checking repeated inputs carefully.

Least you need to know

  • A function cannot assign two different outputs to the same input.
  • Different inputs are allowed to share the same output.
  • The domain is the set of allowed inputs.
  • One-to-one is stronger than being a function.

Key notation

  • f: A → B — function from A to B
  • f(x) — output at x
  • domain — allowed inputs

Worked example

  • Set of pairs: {(1,4),(2,4),(3,5)}.
  • This is a function because each input 1, 2, and 3 has exactly one output.
  • It is not one-to-one because both 1 and 2 map to 4.

Common mistakes

  • Students often think repeated outputs break the function rule.
  • Students often forget that the problem is about inputs, not outputs.
  • Students often confuse 'function' with 'one-to-one function'.

How to recognize it

  • If one input points to two outputs, it is not a function.
  • Repeated outputs are allowed unless the question asks about one-to-one.
  • On arrow diagrams, scan left-side nodes first.

Next recommended lesson

Continue through this topic with Least You Need to Know: Partial Orders.

Least You Need to Know: Partial Orders

Related lessons

Keep going with nearby lessons in the same topic.

More ways to explore

Start practice