Math Lab
Home/Class XI/Ch 2/Functions: definition and notation

Functions: definition and notation

A function is the most important kind of relation in all of mathematics. It captures the idea of a deterministic rule: feed in one input, get exactly one output. From here every later topic , limits, derivatives, integrals , is built.

Definitions

Let AA and BB be non-empty sets. A function ff from AA to BB is a relation fA×Bf \subseteq A \times B such that

  1. (Total) every aAa \in A appears as the first coordinate of some pair, and
  2. (Single-valued) if (a,b)f(a, b) \in f and (a,c)f(a, c) \in f, then b=cb = c.

We write f:ABf : A \to B and, for each aAa \in A, denote the unique bb paired with aa by f(a)f(a). So b=f(a)b = f(a) is just a short form of "(a,b)f(a, b) \in f".

  • AA is the domain of ff.
  • BB is the codomain of ff.
  • {f(a):aA}\{f(a) : a \in A\} is the range of ff , a subset of BB.

The two conditions say: "every input has an output" and "no input has two outputs".

Three ways to specify a function

1. By a formula. f(x)=x2f(x) = x^2, f:RRf : \mathbb{R} \to \mathbb{R}. The rule pairs each xx with x2x^2.

2. By a table or listing. For finite AA we can list f(a)f(a) for each aa.

3. By a graph. For real-valued functions, the graph {(x,f(x)):xA}\{(x, f(x)) : x \in A\} in R2\mathbb{R}^2.

The vertical line test

A subset SR2S \subseteq \mathbb{R}^2 is the graph of a function y=f(x)y = f(x) if and only if every vertical line x=cx = c meets SS in at most one point (and exactly one point if cc is in the domain). This is just the single-valued rule, picture-side.

Examples:

  • y=x2y = x^2: every vertical line cuts the parabola once. Function.
  • x2+y2=1x^2 + y^2 = 1: most vertical lines cut the circle in two points. Not a function.
  • y=xy = \sqrt{x} (taking the non-negative root): every vertical line in [0,)[0, \infty) meets it once. Function.

When two functions are equal

Two functions ff and gg are equal if and only if:

  1. They have the same domain.
  2. f(a)=g(a)f(a) = g(a) for every aa in the domain.

So f(x)=xf(x) = x on R\mathbb{R} and g(x)=xg(x) = x on Z\mathbb{Z} are different functions, even though their formulas look the same.

Examples of "function or not"

  • f:RRf : \mathbb{R} \to \mathbb{R}, f(x)=2x+3f(x) = 2x + 3: function.
  • f:RRf : \mathbb{R} \to \mathbb{R}, f(x)=1xf(x) = \frac{1}{x}: not a function from R\mathbb{R} to R\mathbb{R} , undefined at x=0x = 0. But it is a function from R{0}\mathbb{R} \setminus \{0\} to R\mathbb{R}.
  • f(x)=xf(x) = \sqrt{x}: function from [0,)[0, \infty) to R\mathbb{R}.
  • The "rule" f(x)=±xf(x) = \pm \sqrt{x} pairs x=4x = 4 with both 22 and 2-2 , not a function.

Worked examples

Example 1. Decide whether {(1,2),(2,3),(3,4)}\{(1, 2), (2, 3), (3, 4)\} is a function from {1,2,3}\{1, 2, 3\} to {2,3,4,5}\{2, 3, 4, 5\}. State its domain, codomain, range.

Every element of {1,2,3}\{1, 2, 3\} appears exactly once as a first coordinate, so this is a function. Domain ={1,2,3}= \{1, 2, 3\}, codomain ={2,3,4,5}= \{2, 3, 4, 5\}, range ={2,3,4}= \{2, 3, 4\}.

Example 2. Is {(1,2),(2,3),(1,4)}\{(1, 2), (2, 3), (1, 4)\} a function on {1,2}\{1, 2\}?

No , the input 11 is paired with two outputs 22 and 44. Single-valuedness fails.

Example 3. Is the curve y2=xy^2 = x in the plane the graph of a function y=f(x)y = f(x)?

No. For x=4x = 4, both y=2y = 2 and y=2y = -2 satisfy y2=xy^2 = x. The vertical line x=4x = 4 meets the curve at two points.

Example 4. Find f(0),f(1),f(2)f(0), f(1), f(-2) for f(x)=x23x+4f(x) = x^2 - 3x + 4.

f(0)=00+4=4f(0) = 0 - 0 + 4 = 4. f(1)=13+4=2f(1) = 1 - 3 + 4 = 2. f(2)=4+6+4=14f(-2) = 4 + 6 + 4 = 14.

Example 5 (harder). A function f:RRf : \mathbb{R} \to \mathbb{R} satisfies f(x+y)=f(x)+f(y)f(x + y) = f(x) + f(y) for all x,yRx, y \in \mathbb{R}, and f(1)=3f(1) = 3. Find f(0),f(2),f(1),f(5)f(0), f(2), f(-1), f(5).

Putting x=y=0x = y = 0: f(0)=2f(0)f(0) = 2 f(0), so f(0)=0f(0) = 0.

Putting y=xy = -x: f(0)=f(x)+f(x)=0f(0) = f(x) + f(-x) = 0, so f(x)=f(x)f(-x) = -f(x).

Now f(2)=f(1)+f(1)=6f(2) = f(1) + f(1) = 6, f(1)=3f(-1) = -3, f(5)=f(2)+f(2)+f(1)=6+6+3=15f(5) = f(2) + f(2) + f(1) = 6 + 6 + 3 = 15.

(In fact this forces f(n)=3nf(n) = 3n for every integer nn, and with mild extra assumptions, f(x)=3xf(x) = 3x for every real xx.)

Try it yourself

  1. Decide whether each is a function: (a) {(1,2),(2,4),(3,6)}\{(1, 2), (2, 4), (3, 6)\} from {1,2,3}\{1, 2, 3\} to N\mathbb{N}; (b) {(1,2),(1,3)}\{(1, 2), (1, 3)\} from {1,2}\{1, 2\} to N\mathbb{N}; (c) {(1,1),(2,1),(3,1)}\{(1, 1), (2, 1), (3, 1)\} from {1,2,3}\{1, 2, 3\} to N\mathbb{N}.
  2. Find f(2),f(3),f(0)f(2), f(-3), f(0) for f(x)=x32x+1f(x) = x^3 - 2x + 1.
  3. Does y=xy = |x| define a function from R\mathbb{R} to R\mathbb{R}?
  4. Does the circle x2+y2=25x^2 + y^2 = 25 define yy as a function of xx?
  5. Are f(x)=xf(x) = x on R\mathbb{R} and g(x)=x2xg(x) = \frac{x^2}{x} on R{0}\mathbb{R} \setminus \{0\} equal functions? Explain.
  6. State the codomain and find the range of f:RRf : \mathbb{R} \to \mathbb{R}, f(x)=x2f(x) = x^2.
  7. If f(x)=ax+bf(x) = ax + b with f(1)=5,f(2)=7f(1) = 5, f(2) = 7, find aa and bb.
  8. Plot the graph of f(x)=2x1f(x) = 2x - 1 for x[1,2]x \in [-1, 2]. State its range.
  9. Show that f(x)=x1+x2f(x) = \frac{x}{1 + x^2} is a function from R\mathbb{R} to R\mathbb{R} and find its value at x=0,1,1x = 0, 1, -1.
  10. If f(x+1)=x23x+2f(x + 1) = x^2 - 3x + 2, find f(x)f(x).
  11. If f(x)=x2f(x) = x^2, evaluate f(x+h)f(x)h\frac{f(x+h) - f(x)}{h} for h0h \ne 0 and simplify.
  12. Sketch a curve that satisfies the vertical line test on [2,2][-2, 2] but is not a polynomial.

Pitfalls / Tricks

  • A function must be defined for every input in the domain. Always state the domain explicitly: f(x)=1/xf(x) = 1/x "on R\mathbb{R}" is incorrect; "on R{0}\mathbb{R} \setminus \{0\}" is correct.
  • Two functions can have the same formula yet be unequal if their domains differ.
  • The range is a subset of the codomain , never confuse them.
  • Insight. A function is a machine: one input, one output, no exceptions. If a rule sometimes returns multiple values, sometimes none, it is a relation, not a function. Beginning with this distinction prevents endless confusion later.

Practice quiz

Quick check on this topic.

Quiz
Quick check : Functions: definition
6 questions · pick the best answer
Q1

Q2

Q3

Q4

Q5

Q6