Functions: The Engine Room of Algebra

Welcome to the chapter on Functions! Don't let the formal mathematical language scare you. Functions are simply the rules that govern relationships between numbers. Think of them as precise, dependable machines: you put something in, and the machine always gives you a predictable result out.

Understanding functions is crucial because they form the foundation for calculus, graphs, and complex modeling. If you can master how these "machines" work, you've unlocked a huge part of higher mathematics!


1. What is a Function? (The Vending Machine Analogy)

Defining Relations and Functions

In mathematics, a relationship between two sets of numbers is called a relation. A function is a very special type of relation.

A function is a rule that assigns exactly one output for every single input.

  • If it’s a function: Input 5 always gives Output 10.
  • If it’s NOT a function: Input 5 could sometimes give Output 10, and sometimes give Output 7. (This is messy and unreliable!)

Analogy: Imagine a specialized vending machine.


Input (Money/Selection) \(\rightarrow\) Function (The Vending Process) \(\rightarrow\) Output (Snack)

If you put in $2.00 and press 'A1', you MUST get the exact same chocolate bar every time. If sometimes you got a chocolate bar and sometimes you got a soda, the machine wouldn't be reliable—it wouldn't be a mathematical function!

Key Takeaway

The Golden Rule of Functions: Every input maps to only one output.


2. Function Notation: \(f(x)\)

Speaking the Language of Functions

Instead of writing "Let y be defined by the rule 2 times x plus 1", mathematicians use function notation for efficiency:

$$f(x) = 2x + 1$$

This is read as "f of x equals 2x plus 1".

  • The letter \(f\) is the name of the function (you might see \(g\), \(h\), or others too).
  • The variable inside the bracket, \(x\), is the input variable.
  • The expression, \(2x + 1\), is the rule.
  • Remember: \(f(x)\) is just another way of writing \(y\).
Step-by-Step: Finding the Value of a Function

To find the value of the function for a specific input, you simply substitute that input into the rule.

Example: If the function is \(f(x) = x^2 - 3x\), find \(f(5)\).

  1. Step 1: Write down the rule.
    $$f(x) = x^2 - 3x$$
  2. Step 2: Replace every \(x\) with the input value (5).
    $$f(5) = (5)^2 - 3(5)$$
  3. Step 3: Calculate the result.
    $$f(5) = 25 - 15$$ $$f(5) = 10$$

Therefore, when the input is 5, the output of function \(f\) is 10.

🛑 Common Mistake to Avoid!

Do NOT confuse \(f(x)\) with multiplication \(f \times x\). \(f(x)\) means "the function rule applied to x."


3. Domain and Range (The Boundaries)

Every function has boundaries that define which inputs are allowed and which outputs are possible. These boundaries are called the Domain and the Range.

The Domain (Inputs)

The Domain is the set of all possible input values (\(x\)) for which the function is defined.

  • Think of the Domain as the "fuel" the machine is allowed to use.
  • If a function is defined for "all real numbers," the domain is often written as \(\mathbb{R}\).
Important Domain Restrictions (What is NOT Allowed?)

When defining the domain, you must look out for two main situations that cause mathematical problems:

  1. Restriction 1: Division by Zero
    If you have a fraction, the denominator cannot equal zero.
    Example: For \(f(x) = \frac{1}{x-3}\), the denominator is zero if \(x-3 = 0\), so \(x\) cannot be 3. The domain is \(x \ne 3\).
  2. Restriction 2: Square Root of a Negative Number
    You cannot take the square root (or any even root) of a negative number if the domain must be real numbers.
    Example: For \(g(x) = \sqrt{x+4}\), we must have \(x+4 \ge 0\), so \(x \ge -4\).
The Range (Outputs)

The Range is the set of all possible output values (\(f(x)\) or \(y\)) that the function can produce.

Finding the range can sometimes be trickier and often requires sketching the graph or considering the function’s minimum/maximum values.

Did you know? For a function like \(h(x) = x^2\), even if the domain is all real numbers, the range is restricted. Since any number squared is zero or positive, the range is \(h(x) \ge 0\).

Key Takeaway

Domain: What numbers can I put in? (Look out for dividing by zero and square rooting negatives!)
Range: What numbers come out?


4. The Inverse Function: Undoing the Rule

What is the Inverse?

The Inverse Function, denoted \(f^{-1}(x)\), is the function that reverses the effect of the original function \(f(x)\).

If function \(f\) takes Input A and gives Output B, then the inverse function \(f^{-1}\) takes Output B and gives back Input A.

Analogy: If \(f(x)\) is putting on your socks, \(f^{-1}(x)\) is taking them off. The inverse undoes the action!

Step-by-Step: Finding the Inverse Function \(f^{-1}(x)\)

This process is essential for exams. Follow these four steps precisely:

Example: Find the inverse of the function \(f(x) = 5x - 7\).

  1. Step 1: Replace \(f(x)\) with \(y\). (This makes the algebra easier.)
    $$y = 5x - 7$$
  2. Step 2: Swap the positions of \(x\) and \(y\). (This is the crucial step that reverses the relationship.)
    $$x = 5y - 7$$
  3. Step 3: Rearrange the equation to make \(y\) the subject again. (Isolate \(y\).)
    $$x + 7 = 5y$$ $$\frac{x + 7}{5} = y$$
  4. Step 4: Replace \(y\) with \(f^{-1}(x)\). (Use the correct notation.)
    $$f^{-1}(x) = \frac{x + 7}{5}$$

Memory Aid: To find the inverse, you Swap the variables and Solve for y.

Checking Your Answer (Optional but Recommended)

You can always check if your inverse is correct.

  1. Try an easy input for \(f(x)\): If \(x=2\), \(f(2) = 5(2) - 7 = 3\).
  2. Now, input the output (3) into your inverse function \(f^{-1}(x)\):
    $$f^{-1}(3) = \frac{3 + 7}{5} = \frac{10}{5} = 2$$
  3. Since the input (2) resulted from the output (3) in the inverse, the inverse is correct!

5. Composite Functions: Function Chains

Sometimes, the output of one function becomes the input for a second function. This chain of functions is called a Composite Function.

Notation and Order

Suppose we have two functions, \(f(x)\) and \(g(x)\).

The notation \(fg(x)\) means: apply function \(g\) first, and then apply function \(f\) to the result.

$$fg(x) = f(g(x))$$

Always work from the inside bracket outwards!

  • For \(fg(x)\): The input \(x\) goes into \(g\).
  • For \(gf(x)\): The input \(x\) goes into \(f\).
Step-by-Step: Combining Functions

Example: Let \(f(x) = 2x + 1\) and \(g(x) = x^2\). Find the expression for \(fg(x)\).

  1. Step 1: Identify the inside function (\(g(x)\)).
    $$fg(x) = f(g(x))$$ $$g(x) = x^2$$
  2. Step 2: Substitute the whole expression for \(g(x)\) into the rule for \(f(x)\).
    The rule for \(f\) is \(f(\text{stuff}) = 2(\text{stuff}) + 1\).
    We replace 'stuff' with \(x^2\). $$fg(x) = 2(x^2) + 1$$
  3. Step 3: Simplify.
    $$fg(x) = 2x^2 + 1$$

Quick Check: Find \(gf(x)\) using the same functions.

$$gf(x) = g(f(x))$$ $$f(x) = 2x + 1$$
The rule for \(g\) is \(g(\text{stuff}) = (\text{stuff})^2\).
$$gf(x) = (2x + 1)^2$$

💡 Important Note:

In general, \(fg(x) \ne gf(x)\). The order in which you apply the functions matters! Think of it like putting on a coat and then a hat—it’s very different from putting on a hat and then trying to squeeze a coat over it.


Quick Review Box: Essential Function Concepts

Summary of Key Terms
  • Function: A rule where every input (x) yields exactly one output (y or \(f(x)\)).
  • Domain: The set of allowed inputs.
  • Range: The set of resulting outputs.
  • Inverse (\(f^{-1}(x)\)): Found by swapping \(x\) and \(y\) and solving for \(y\). It undoes the original function.
  • Composite (\(fg(x)\)): Applying \(g\) first, then applying \(f\) to the result (\(f(g(x))\)).

Keep practicing those substitutions and rearrangement techniques. You’ve got this! Functions are logical and predictable—once you learn the rules, they rarely change.