Figure 2.1: Modulus Graph Transformations: $y = |f(x)|$ vs $y = f(|x|)$
1. Algebraic Definition & Piecewise Formulation
The modulus (or absolute value) $|x| = \sqrt{x^2}$ is defined piecewise as:
$$|x| = \begin{cases} x & \text{if } x \ge 0 \\ -x & \text{if } x < 0 \end{cases}$$For any composite expression $g(x)$, $|g(x)| = g(x)$ when $g(x) \ge 0$, and $-g(x)$ when $g(x) < 0$. The boundary points where $g(x) = 0$ create sharp corners (cusps) where the left-hand and right-hand gradients disagree, making the function non-differentiable at those roots.
2. Modulus Transformations: $y = |f(x)|$ vs $y = f(|x|)$
- $y = |f(x)|$ (External Modulus):
• The portion of $y = f(x)$ where $y \ge 0$ is preserved unaltered.
• The portion where $y < 0$ is reflected vertically across the $x$-axis ($y \to -y$).
• Range is strictly non-negative: $\text{Range} \subseteq [0, \infty)$.
• Sharp cusps form at all real roots where the original curve intersected the $x$-axis with non-zero slope. - $y = f(|x|)$ (Internal Modulus):
• The portion of $y = f(x)$ for $x < 0$ is completely deleted.
• The portion for $x \ge 0$ is retained and reflected horizontally across the $y$-axis ($x \to -x$).
• The resulting function is guaranteed to be an even function: $f(|-x|) = f(|x|)$, exhibiting bilateral symmetry across the $y$-axis. A cusp often appears at $(0, f(0))$.
3. Rigorous Methods for Solving Modulus Equations
- Case-by-Case Definition: For $|f(x)| = g(x)$, split into two branches: $$f(x) = g(x) \quad \text{and} \quad f(x) = -g(x)$$ Critical Constraint: Because $|f(x)| \ge 0$, any real solution must satisfy $g(x) \ge 0$. You must explicitly check all candidate solutions to discard extraneous roots!
- Squaring Both Sides: For $|f(x)| = |g(x)|$, since both sides are non-negative: $$[f(x)]^2 = [g(x)]^2 \iff [f(x)]^2 - [g(x)]^2 = 0 \iff (f(x) - g(x))(f(x) + g(x)) = 0$$ This avoids piecewise branches and automatically prevents extraneous solutions when both sides are enclosed in absolute values.
4. Solving Modulus Inequalities
- Bounded Form ($|f(x)| < k$, $k > 0$): Equivalent to the double inequality: $$-k < f(x) < k$$
- Disjoint Form ($|f(x)| > k$, $k > 0$): Equivalent to two separate infinite rays: $$f(x) > k \quad \text{or} \quad f(x) < -k$$
- Rational Modulus Inequalities: For $\left|\frac{P(x)}{Q(x)}\right| < k$, multiply by $[Q(x)]^2 > 0$ (for $Q(x) \neq 0$): $$[P(x)]^2 < k^2 [Q(x)]^2 \iff [P(x) - k Q(x)][P(x) + k Q(x)] < 0$$
Worked Examples
Worked Example 1: Solving Modulus Equation with Extraneous Root
Question: Solve the equation $|2x - 5| = x + 1$ algebraically, and verify graphically why only valid intersections occur. [5 marks]
Solution:
Step 1: Domain Restriction: Because the absolute value is non-negative ($|2x - 5| \ge 0$), any valid solution must satisfy: [M1]
$$x + 1 \ge 0 \implies x \ge -1$$Step 2: Split into Branches: [M1]
- Branch 1 ($2x - 5 \ge 0 \implies x \ge 2.5$): $$2x - 5 = x + 1 \implies x = 6 \quad [\text{A1}]$$ Check: $6 \ge 2.5$ and $6 \ge -1$. LHS: $|2(6)-5| = 7$; RHS: $6 + 1 = 7$. Valid!
- Branch 2 ($2x - 5 < 0 \implies x < 2.5$): $$-(2x - 5) = x + 1 \implies -2x + 5 = x + 1 \implies 3x = 4 \implies x = \frac{4}{3} \quad [\text{A1}]$$ Check: $\frac{4}{3} < 2.5$ and $\frac{4}{3} \ge -1$. LHS: $\left|2\left(\frac{4}{3}\right)-5\right| = \left|\frac{8-15}{3}\right| = \frac{7}{3}$; RHS: $\frac{4}{3} + 1 = \frac{7}{3}$. Valid!
Conclusion: The exact solutions are $x = \frac{4}{3}$ and $x = 6$. [A1]
(If the equation was $|2x - 3| = x - 5$, candidate solutions would yield $x - 5 < 0$, rejecting both as extraneous!).
Worked Example 2: Inequality with Modulus on Both Sides
Question: Solve the inequality $|3x - 2| \le |x + 4|$ algebraically. [4 marks]
Solution:
Because both sides are non-negative, we square both sides without introducing false sign reversals: [M1]
$$(3x - 2)^2 \le (x + 4)^2 \iff (3x - 2)^2 - (x + 4)^2 \le 0$$Factor using the difference of two squares $A^2 - B^2 = (A - B)(A + B)$: [M1]
$$[(3x - 2) - (x + 4)][(3x - 2) + (x + 4)] \le 0$$ $$(2x - 6)(4x + 2) \le 0$$Factor out scalars: $2(x - 3) \cdot 2(2x + 1) \le 0 \implies 4(x - 3)(2x + 1) \le 0$. [A1]
The boundary roots of the quadratic are $x = -\frac{1}{2}$ and $x = 3$.
Because the parabola opens upwards ($4(2)x^2 = 8x^2 > 0$), it is non-positive ($\le 0$) between the roots: [A1]
Worked Example 3: Rational Modulus Inequality
Question: Solve the inequality $\left|\frac{x + 2}{x - 1}\right| < 2$. [5 marks]
Solution:
Step 1: Domain Restriction: Denominator cannot be zero: $x \neq 1$. [A1]
Step 2: Clear Denominator by Squaring: Since $(x - 1)^2 > 0$ for all $x \neq 1$, multiply both sides by $(x - 1)^2$: [M1]
$$(x + 2)^2 < 4(x - 1)^2 \iff (x + 2)^2 - [2(x - 1)]^2 < 0$$Apply difference of squares $A^2 - B^2 = (A - B)(A + B) < 0$: [M1]
$$[(x + 2) - (2x - 2)][(x + 2) + (2x - 2)] < 0$$ $$(-x + 4)(3x) < 0 \iff -3x(x - 4) < 0 \iff 3x(x - 4) > 0 \quad [\text{A1}]$$The roots are $x = 0$ and $x = 4$. The inequality $> 0$ holds outside the roots: [A1]
$$x < 0 \quad \text{or} \quad x > 4$$Check restriction: $x = 1$ lies inside $[0, 4]$, so it is automatically excluded. Final answer: $x < 0$ or $x > 4$.
Worked Example 4: Multi-Modulus Parameter Analysis
Question: Consider the function $f(x) = |x - 2| + |x + 3|$ for $x \in \mathbb{R}$.
(a) Express $f(x)$ in piecewise linear form across three intervals. [3 marks]
(b) Sketch $y = f(x)$, stating the range of $f$. [2 marks]
(c) Hence determine the number of real solutions to $f(x) = k$ for all values of $k \in \mathbb{R}$. [3 marks]
Solution:
(a) Piecewise Definition: The critical transition points are $x = -3$ and $x = 2$: [M1]
- Interval 1 ($x < -3$): Both terms are negative: $$f(x) = -(x - 2) - (x + 3) = -x + 2 - x - 3 = -2x - 1 \quad [\text{A1}]$$
- Interval 2 ($-3 \le x \le 2$): $(x + 3) \ge 0$ while $(x - 2) \le 0$: $$f(x) = -(x - 2) + (x + 3) = -x + 2 + x + 3 = 5 \quad [\text{A1}]$$
- Interval 3 ($x > 2$): Both terms are positive: $$f(x) = (x - 2) + (x + 3) = 2x + 1 \quad [\text{A1}]$$
(b) Sketch & Range: The graph is a trough (bathtub shape) with a flat bottom of height $y = 5$ on $[-3, 2]$ and upward slopes of $\pm 2$ outside. Range is $[5, \infty)$. [A1]
(c) Number of Solutions to $f(x) = k$: [M1]
- If $k < 5$: 0 solutions (no intersection below the trough). [A1]
- If $k = 5$: infinitely many solutions (every $x \in [-3, 2]$ is a solution). [A1]
- If $k > 5$: exactly 2 distinct solutions (one on $x < -3$, one on $x > 2$). [A1]
Worked Example 5: Piecewise Differentiation & Integration
Question: Let $f(x) = x|x - 2|$.
(a) Express $f(x)$ without absolute value bars. [2 marks]
(b) Show that $f(x)$ is not differentiable at $x = 2$. [3 marks]
(c) Evaluate the exact value of $\int_{0}^{3} f(x) \, dx$. [3 marks]
Solution:
(a) Piecewise Form: [M1]
$$f(x) = \begin{cases} x(x - 2) = x^2 - 2x & \text{if } x \ge 2 \\ x(-(x - 2)) = -x^2 + 2x & \text{if } x < 2 \end{cases} \quad [\text{A1}]$$(b) Differentiability at $x = 2$: Compute one-sided derivatives: [M1]
$$f'_+(2) = \lim_{x \to 2^+} \frac{d}{dx}(x^2 - 2x) = \lim_{x \to 2^+} (2x - 2) = 2(2) - 2 = 2 \quad [\text{A1}]$$ $$f'_-(2) = \lim_{x \to 2^-} \frac{d}{dx}(-x^2 + 2x) = \lim_{x \to 2^-} (-2x + 2) = -2(2) + 2 = -2 \quad [\text{A1}]$$Because $f'_+(2) = 2 \neq -2 = f'_-(2)$, the derivative does not exist at $x = 2$. [AG] [A1]
(c) Definite Integral: Split the integral at the boundary $x = 2$: [M1]
$$\int_{0}^{3} f(x) \, dx = \int_{0}^{2} (-x^2 + 2x) \, dx + \int_{2}^{3} (x^2 - 2x) \, dx$$ $$\int_{0}^{2} (-x^2 + 2x) \, dx = \left[ -\frac{x^3}{3} + x^2 \right]_0^2 = -\frac{8}{3} + 4 = \frac{4}{3} \quad [\text{A1}]$$ $$\int_{2}^{3} (x^2 - 2x) \, dx = \left[ \frac{x^3}{3} - x^2 \right]_2^3 = (9 - 9) - \left(\frac{8}{3} - 4\right) = 0 - \left(-\frac{4}{3}\right) = \frac{4}{3} \quad [\text{A1}]$$ $$\text{Total} = \frac{4}{3} + \frac{4}{3} = \frac{8}{3} \quad [\text{A1}]$$Practice Exercises (10 Tiered Questions)
Try these 10 exam-style questions, from core skills to harder problems. Open each question to view its solution.
The point $P(-3, -5)$ lies on the curve $y = f(x)$. State the coordinates of the corresponding point on: (a) $y = |f(x)|$, (b) $y = f(|x|)$, (c) $y = -|f(x)|$.
Show Full Solution
(a) $y = |f(x)|$: $x$ stays $-3$, $y = |-5| = 5$. Point: $(-3, 5)$. [A1]
(b) $y = f(|x|)$: For $x = -3$, $|x| = 3$, so $y = f(3)$. The original point at $x=-3$ is deleted and replaced by the reflection of $(3, f(3))$. Point is $(-3, f(3))$. [A1]
(c) $y = -|f(x)|$: $x = -3$, $y = -|-5| = -5$. Point: $(-3, -5)$. [A1]
Solve $|4x - 1| = 11$.
Show Full Solution
Branch 1: $4x - 1 = 11 \implies 4x = 12 \implies x = 3$. [A1]
Branch 2: $4x - 1 = -11 \implies 4x = -10 \implies x = -\frac{5}{2}$. [A1]
Solutions: $x = -\frac{5}{2}, 3$.
Solve $|2x + 7| < 5$.
Show Full Solution
$-5 < 2x + 7 < 5$ [M1]
Subtract 7: $-12 < 2x < -2$
Divide by 2: $-6 < x < -1$. [A1]
Solve $|3x + 2| = 2x + 7$ algebraically.
Show Full Solution
Domain requires $2x + 7 \ge 0 \implies x \ge -3.5$. [M1]
Case 1: $3x + 2 = 2x + 7 \implies x = 5$. [A1]
Case 2: $3x + 2 = -(2x + 7) = -2x - 7 \implies 5x = -9 \implies x = -\frac{9}{5} = -1.8$. [A1]
Both satisfy $x \ge -3.5$. Solutions: $x = -\frac{9}{5}, 5$.
Solve $|2x - 1| = |x + 5|$ by squaring both sides.
Show Full Solution
$(2x - 1)^2 = (x + 5)^2 \implies (2x - 1)^2 - (x + 5)^2 = 0$. [M1]
$[(2x - 1) - (x + 5)][(2x - 1) + (x + 5)] = 0$
$(x - 6)(3x + 4) = 0$. [M1]
$x = 6$ or $x = -\frac{4}{3}$. [A1]
Solve $|2x - 3| \ge |x + 1|$.
Show Full Solution
$(2x - 3)^2 \ge (x + 1)^2 \iff (2x - 3)^2 - (x + 1)^2 \ge 0$. [M1]
$[(2x - 3) - (x + 1)][(2x - 3) + (x + 1)] \ge 0$
$(x - 4)(3x - 2) \ge 0$. [A1]
Parabola opens upwards, $\ge 0$ outside roots $x = \frac{2}{3}$ and $x = 4$:
$x \le \frac{2}{3}$ or $x \ge 4$. [A1]
Find all solutions to $|x^2 - 5x| = 6$.
Show Full Solution
Case 1: $x^2 - 5x = 6 \implies x^2 - 5x - 6 = 0 \implies (x - 6)(x + 1) = 0 \implies x = 6, -1$. [A1]
Case 2: $x^2 - 5x = -6 \implies x^2 - 5x + 6 = 0 \implies (x - 2)(x - 3) = 0 \implies x = 2, 3$. [A1]
All 4 solutions: $x = -1, 2, 3, 6$. [A1]
Solve the inequality $\left|\frac{x + 2}{x - 1}\right| < 2$.
Show Full Solution
Domain requires $x \neq 1$. Square both sides: [M1]
$\frac{(x + 2)^2}{(x - 1)^2} < 4 \implies (x + 2)^2 < 4(x - 1)^2$
$(x + 2)^2 - [2(x - 1)]^2 < 0$. [M1]
$[(x + 2) - (2x - 2)][(x + 2) + (2x - 2)] < 0$
$(-x + 4)(3x) < 0 \iff 3x(x - 4) > 0$. [A1]
Roots are $x = 0$ and $x = 4$. Solution is $x < 0$ or $x > 4$. [A1]
Find all values of $m \in \mathbb{R}$ such that the equation $|x - 2| + |x + 3| = m$ has: (a) no solutions, (b) infinitely many solutions, (c) exactly two solutions.
Show Full Solution
By the triangle inequality, $|x - 2| + |x + 3| \ge |(x - 2) - (x + 3)| = |-5| = 5$. [M1]
• For $-3 \le x \le 2$: $(2 - x) + (x + 3) = 5$ (constant value 5).
• For $x > 2$: $2x + 1 > 5$.
• For $x < -3$: $-2x - 1 > 5$.
(a) No solutions: $m < 5$. [A1]
(b) Infinitely many solutions: $m = 5$ (all $x \in [-3, 2]$). [A1]
(c) Exactly two solutions: $m > 5$. [A1]
Let $f(x) = x|x - 2|$.
(a) Express $f(x)$ in piecewise form.
(b) Determine whether $f$ is differentiable at $x = 2$.
(c) Find the stationary point of $f(x)$.
Show Full Solution
(a) Piecewise definition: [M1]
$f(x) = \begin{cases} x(x - 2) = x^2 - 2x & \text{if } x \ge 2 \\ x(-(x - 2)) = -x^2 + 2x & \text{if } x < 2 \end{cases}$ [A1]
(b) Differentiability at $x = 2$:
$f'(2^+) = \lim_{x \to 2^+} (2x - 2) = 2$. [M1]
$f'(2^-) = \lim_{x \to 2^-} (-2x + 2) = -2$. [M1]
Since $f'(2^+) \neq f'(2^-)$, $f(x)$ is not differentiable at $x = 2$ (a sharp cusp). [A1]
(c) Stationary point:
For $x < 2$: $f'(x) = -2x + 2 = 0 \implies x = 1$. At $x = 1$, $f(1) = 1(1) = 1$.
Stationary point is $(1, 1)$ (local maximum). [A1]
IB Formula Booklet References (Topic 2)
Syllabus AHL 2.12, 2.14: Modulus Function
The formula booklet does not contain a dedicated formula for the modulus function. Students must know the piecewise algebraic definition and graphical reflection rules:
$$|x| = \begin{cases} x, & x \ge 0 \\ -x, & x < 0 \end{cases}$$Key Formulas & Identities
1. Transformation Rules
- $y = |f(x)|$: reflect parts where $y < 0$ in the $x$-axis (cusps at real roots).
- $y = f(|x|)$: erase $x < 0$, reflect $x \ge 0$ in the $y$-axis (always even).
2. Inequalities
- $|f(x)| < k \iff -k < f(x) < k$ (for $k > 0$)
- $|f(x)| > k \iff f(x) > k \text{ or } f(x) < -k$
- $|f(x)| < |g(x)| \iff [f(x)]^2 - [g(x)]^2 < 0 \iff (f-g)(f+g) < 0$
3. Triangle Inequalities
$$|a + b| \le |a| + |b|, \quad \big||a| - |b|\big| \le |a - b|$$Common Exam Pitfalls
Failing to Check for Extraneous Solutions
When solving $|A| = B$, remember that $B$ cannot be negative. If substituting your candidate $x$ into $B$ gives a negative value, that root is extraneous and must be discarded.
Differentiability at Cusps
Curves with modulus reflections have sharp corners at their $x$-intercepts. The derivative does not exist at these points! Never set $f'(x) = 0$ across a cusp.
Rational Modulus Multiplication Trap
Never multiply by $(cx + d)$ directly when solving $\left|\frac{ax+b}{cx+d}\right| \le k$. Because $(cx+d)$ can be negative, the inequality sign would flip unpredictably. Always multiply by $(cx+d)^2 > 0$!
Topic Diagnostic Test
Complete this timed test to check your understanding and exam technique.
Section A: Diagnostic Multiple Choice Questions
The function $f(x) = x^3 - 3x$. How many local extrema (stationary points & cusps) does $y = f(|x|)$ have?
What are the real solutions to $|2x - 3| = x - 5$?
The solution set to the inequality $|x - 3| < 2x$ is:
If $g(x) = \ln x$, the domain of $y = g(|x|)$ is:
Section B: Examination-Style Free Response Questions
Consider the functions $f(x) = |2x - 4|$ and $g(x) = 6 - x$.
(a) Sketch both graphs on the same set of axes, clearly showing all intercepts. [3 marks]
(b) Find the exact coordinates of the two points of intersection. [2 marks]
(c) Hence write down the solution set to $|2x - 4| \le 6 - x$. [1 mark]
Show Full Markscheme
(a) Sketch: [3 marks]
• $f(x) = |2x - 4|$ has vertex (cusp) at $(2, 0)$ and $y$-intercept at $(0, 4)$ [A1].
• $g(x) = 6 - x$ has $y$-intercept $(0, 6)$ and $x$-intercept $(6, 0)$ [A1].
Both lines intersect in the first quadrant [A1].
(b) Points of intersection: [2 marks]
Case 1 ($x \ge 2$): $2x - 4 = 6 - x \implies 3x = 10 \implies x = \frac{10}{3}$. $y = 6 - \frac{10}{3} = \frac{8}{3}$. Point $\left(\frac{10}{3}, \frac{8}{3}\right)$ [A1].
Case 2 ($x < 2$): $-(2x - 4) = 6 - x \implies -2x + 4 = 6 - x \implies -x = 2 \implies x = -2$. $y = 6 - (-2) = 8$. Point $(-2, 8)$ [A1].
(c) Solution of inequality: [1 mark]
From the sketch, $f(x) \le g(x)$ between the intersection points: $-2 \le x \le \frac{10}{3}$ [A1].
Let $h(x) = \left|\frac{x^2 - 1}{x^2 + 1}\right|$.
(a) Show that $h(x)$ is an even function. [2 marks]
(b) Find the horizontal asymptote of $y = h(x)$. [2 marks]
(c) Find all stationary points of $h(x)$ and state the nature of each. [4 marks]
Show Full Markscheme
(a) Even function: [2 marks]
$h(-x) = \left|\frac{(-x)^2 - 1}{(-x)^2 + 1}\right| = \left|\frac{x^2 - 1}{x^2 + 1}\right| = h(x)$ [M1].
Since $h(-x) = h(x)$ for all $x \in \mathbb{R}$, $h(x)$ is an even function [A1].
(b) Horizontal asymptote: [2 marks]
$\lim_{x \to \pm\infty} h(x) = \lim_{x \to \pm\infty} \left|\frac{1 - 1/x^2}{1 + 1/x^2}\right| = |1| = 1$ [M1].
The horizontal asymptote is $y = 1$ [A1].
(c) Stationary points: [4 marks]
Let $u(x) = \frac{x^2 - 1}{x^2 + 1}$.
$u'(x) = \frac{2x(x^2 + 1) - 2x(x^2 - 1)}{(x^2 + 1)^2} = \frac{4x}{(x^2 + 1)^2}$ [M1].
$u'(x) = 0 \implies x = 0$. At $x = 0$, $u(0) = -1 \implies h(0) = |-1| = 1$ (local maximum) [A1].
At $x = \pm 1$, $u(x) = 0 \implies h(\pm 1) = 0$. These are sharp cusps where the modulus reflects from negative to positive, forming global minimum points $(1, 0)$ and $(-1, 0)$ [A1].
Stationary points: $(0, 1)$ (local maximum), and cusps at $(\pm 1, 0)$ (local/global minima) [A1].