Part \(1\). Introduction to functions

\(1.1\) What is a function?

A function is a rule that assigns exactly one output to every input in its domain.

Think of a function as a mathematical machine. You provide an input, the function performs a calculation, and it produces an output.

For example, consider the function:

\[ f(x)=2x+3 \]

This function tells us to multiply the input by \(2\) and then add \(3\).

Suppose the input is \(x=2\).

The calculation is:

\[ \begin{aligned} f(2)&=2(2)+3\\ &=4+3\\ &=\boxed{7} \end{aligned} \]

Therefore, the output corresponding to the input \(2\) is \(7\).

Input-output table

The following HTML table shows how the function works for different inputs.

Input \(x\) Calculation Output \(f(x)\)
\(0\) \(2(0)+3\) \(3\)
\(1\) \(2(1)+3\) \(5\)
\(2\) \(2(2)+3\) \(7\)
\(3\) \(2(3)+3\) \(9\)
\(4\) \(2(4)+3\) \(11\)

Notice that each input has exactly one output. This is the essential property of a function.

\(1.2\) Understanding function notation

Functions are usually represented by letters such as \(f\), \(g\), and \(h\).

Consider:

\[ f(x)=x^2+2 \]

The notation \(f(x)\) is read as “\(f\) of \(x\).”

  • \(f\) is the name of the function.

  • \(x\) represents the input.

  • \(f(x)\) represents the output corresponding to the input.

Important: \(f(x)\) does not mean \(f\) multiplied by \(x\). It represents the value of the function.

Worked example

Given:

\[ f(x)=x^2+2 \]

Find \(f(3)\).

Step one: Substitute the input.

\[ f(3)=3^2+2 \]

Step two: Calculate the power.

\[ f(3)=9+2 \]

Step three: Simplify.

\[ \boxed{f(3)=11} \]

\(1.3\) Evaluating functions with negative inputs

Negative inputs require careful substitution, especially when powers are involved.

Consider:

\[ f(x)=x^2-4x+1 \]

Find \(f(-2)\).

Step one: Substitute the input.

\[ f(-2)=(-2)^2-4(-2)+1 \]

Step two: Calculate the power and multiplication.

\[ f(-2)=4+8+1 \]

Step three: Simplify.

\[ \boxed{f(-2)=13} \]

Always use parentheses when substituting negative values.

\(1.4\) Can different inputs produce the same output?

Yes. Different inputs may produce the same output, and the relationship can still be a function.

Consider:

\[ f(x)=x^2 \]

For the input \(x=2\):

\[ f(2)=2^2=4 \]

For the input \(x=-2\):

\[ f(-2)=(-2)^2=4 \]

Both inputs produce the same output.

This is still a function because each individual input has exactly one output.

Part \(2\). Function mappings and ordered pairs

\(2.1\) Understanding function mappings

A mapping shows which output corresponds to each input.

Consider:

\[ f(x)=x^2 \]

Suppose the domain is:

\[ D=\{1,2,3\} \]

Calculate the outputs:

\[ \begin{aligned} f(1)&=1^2=1\\ f(2)&=2^2=4\\ f(3)&=3^2=9 \end{aligned} \]

The mapping can be written as:

\[ 1\mapsto1,\qquad 2\mapsto4,\qquad 3\mapsto9 \]

Every input has exactly one output, so this is a function.

\(2.2\) Ordered pairs

An ordered pair has the form:

\[ (x,y) \]

The first coordinate represents the input, and the second coordinate represents the output.

Consider:

\[ \{(1,3),(2,5),(3,7),(4,9)\} \]

This relation is a function because each input has exactly one output.

Now consider:

\[ \{(1,3),(2,5),(2,8),(4,9)\} \]

This relation is not a function because the input \(x=2\) corresponds to two different outputs.

Comparison table

Relation Is it a function? Explanation
\(\{(1,3),(2,5),(3,7)\}\) Yes Every input has exactly one output.
\(\{(1,4),(2,4),(3,4)\}\) Yes Different inputs may share the same output.
\(\{(1,3),(2,5),(2,8)\}\) No The input \(2\) has two different outputs.
\(\{(-1,2),(0,3),(1,2)\}\) Yes Every input has exactly one output.

Exam tip: Compare the first coordinates. If the same input is associated with different outputs, the relation is not a function.

 

Part \(3\). Domain, codomain, and range

\(3.1\) Domain

The domain is the set of all permitted input values for a function.

In simple terms, the domain answers this question:

Which values can we substitute into the function?

Consider:

\[ f(x)=\frac{1}{x} \]

We cannot substitute \(x=0\), because division by zero is undefined.

Therefore, the domain is all real numbers except zero:

\[ \boxed{D=\mathbb R\setminus\{0\}} \]

In interval notation:

\[ \boxed{D=(-\infty,0)\cup(0,\infty)} \]

\(3.2\) Codomain

The codomain is the declared set into which the function maps its outputs.

Consider:

\[ f:\mathbb R\to\mathbb R,\qquad f(x)=x^2 \]

The domain is \(\mathbb R\), and the codomain is also \(\mathbb R\).

However, the function cannot produce negative outputs because the square of a real number is never negative.

\(3.3\) Range

The range is the set of all actual output values produced by a function.

Consider:

\[ f(x)=x^2 \]

For every real input:

\[ x^2\geq0 \]

The minimum output is zero, achieved when \(x=0\). Every nonnegative real output is possible.

Therefore:

\[ \boxed{R=[0,\infty)} \]

Comparison table

Concept Meaning Example for \(f(x)=x^2\)
Domain All permitted inputs. \(\mathbb R\)
Codomain Declared output set. \(\mathbb R\)
Range All actual outputs. \([0,\infty)\)

The range is always a subset of the codomain:

\[ \boxed{\operatorname{Range}(f)\subseteq\operatorname{Codomain}(f)} \]

The range and codomain may be equal, but they do not have to be equal.

\(3.4\) Interval notation

Interval notation expresses sets of real numbers using parentheses and square brackets.

Interval Inequality Meaning
\((a,b)\) \(a<x<b\) Neither endpoint is included.
\([a,b]\) \(a\leq x\leq b\) Both endpoints are included.
\((a,b]\) \(a<x\leq b\) Only the right endpoint is included.
\([a,b)\) \(a\leq x<b\) Only the left endpoint is included.
\((-\infty,a)\) \(x<a\) All real numbers less than \(a\).
\([a,\infty)\) \(x\geq a\) All real numbers greater than or equal to \(a\).

Remember: Infinity always uses parentheses because infinity is not a real-number endpoint that can be included.

 

Part \(4\). Determining domains from algebraic expressions

The domain depends on which inputs make an expression mathematically valid.

For real-valued elementary functions, remember these rules:

  • Polynomial functions have no domain restrictions.

  • Rational functions cannot have a zero denominator.

  • Square roots require a nonnegative radicand.

  • Logarithms require a strictly positive argument.

\(4.1\) Polynomial functions

Polynomial functions include linear, quadratic, and cubic expressions.

Examples:

\[ f(x)=3x+5 \]
\[ g(x)=x^2-4x+7 \]
\[ h(x)=2x^3-x+1 \]

Every real number is permitted as an input.

Therefore:

\[ \boxed{D=\mathbb R=(-\infty,\infty)} \]

Worked example

Find the domain of:

\[ f(x)=4x^3-7x^2+2 \]

This is a polynomial, so every real input is allowed.

\[ \boxed{D=\mathbb R} \]

\(4.2\) Rational functions

A rational function contains a fraction. Its denominator must not equal zero.

The restriction is:

\[ \boxed{\text{Denominator}\neq0} \]

Consider:

\[ f(x)=\frac{3}{x-2} \]

Set the denominator unequal to zero:

\[ x-2\neq0 \]

Solve:

\[ x\neq2 \]

Therefore:

\[ \boxed{D=(-\infty,2)\cup(2,\infty)} \]

Worked example: Two excluded values

Find the domain of:

\[ f(x)=\frac{x+1}{x^2-9} \]

Factor the denominator:

\[ x^2-9=(x-3)(x+3) \]

The denominator must not equal zero:

\[ (x-3)(x+3)\neq0 \]

Therefore:

\[ x\neq3,\qquad x\neq-3 \]

The final answer is:

\[ \boxed{ D=(-\infty,-3)\cup(-3,3)\cup(3,\infty) } \]

Even if a factor cancels during simplification, an input excluded by the original denominator remains excluded from the original function’s domain.

\(4.3\) Square root functions

For a real-valued square root, the expression inside the root must be nonnegative.

\[ \boxed{\sqrt{A(x)}\text{ requires }A(x)\geq0} \]

Consider:

\[ f(x)=\sqrt{x-4} \]

Set the radicand greater than or equal to zero:

\[ x-4\geq0 \]

Solve:

\[ x\geq4 \]

Therefore:

\[ \boxed{D=[4,\infty)} \]

The endpoint is included because:

\[ \sqrt{4-4}=\sqrt0=0 \]

Worked example: Negative coefficient

Find the domain of:

\[ g(x)=\sqrt{10-2x} \]

Set the radicand nonnegative:

\[ 10-2x\geq0 \]

Rearrange:

\[ -2x\geq-10 \]

Divide by a negative number and reverse the inequality sign:

\[ x\leq5 \]

Therefore:

\[ \boxed{D=(-\infty,5]} \]

\(4.4\) Logarithmic functions

For a real logarithm, its argument must be strictly positive.

\[ \boxed{\log_b(A(x))\text{ requires }A(x)>0} \]

The base must also satisfy:

\[ b>0,\qquad b\neq1 \]

Consider:

\[ f(x)=\log_2(x-3) \]

The argument must be positive:

\[ x-3>0 \]

Solve:

\[ x>3 \]

Therefore:

\[ \boxed{D=(3,\infty)} \]

The endpoint is excluded because the logarithm of zero is undefined.

Worked example

Find the domain of:

\[ g(x)=\log_5(2x+6) \]

Require the argument to be positive:

\[ 2x+6>0 \]

Subtract