Sub topic 12
Reflections and Even or Odd Symmetry
This chapter assumes you know function notation, the graphs of x, x², x³, |x| and √x, and how to read domain and range from a graph. It also assumes you have seen the shift and stretch rules from earlier chapters. Here you will look closely at reflections, then use them to define even and odd functions. You will learn to test for each kind of symmetry, and to see how other transformations keep or break it.
The two reflections
A reflection flips a graph across an axis. Each flip comes from changing either the output or the input.
| Change | New function | Point mapping | Axis of reflection |
|---|---|---|---|
| Negate the output | g(x) = −f(x) | (x, y) → (x, −y) | x-axis |
| Negate the input | g(x) = f(−x) | (x, y) → (−x, y) | y-axis |
| Negate both | g(x) = −f(−x) | (x, y) → (−x, −y) | origin (a 180° rotation) |
The sign of the change tells you which direction the flip happens. A minus sign outside the function (−f(x)) acts on the outputs, so the graph flips over the x-axis. A minus sign inside (f(−x)) acts on the inputs, so the graph flips over the y-axis.
Reflection is the special case of a stretch with a negative factor. In g(x) = a·f(b(x − h)) + k, setting a = −1 gives the x-axis flip and setting b = −1 gives the y-axis flip. The general mapping rule (x, y) → (x/b + h, a·y + k) agrees with the table: with b = −1 and h = 0, x/b is −x.
A worked example with a one-sided function
Take f(x) = √x. It has domain [0, ∞) and range [0, ∞), and passes through (0, 0), (1, 1) and (4, 2).
- −f(x) = −√x. The points become (0, 0), (1, −1), (4, −2). The domain stays [0, ∞). The range becomes (−∞, 0].
- f(−x) = √(−x). The points become (0, 0), (−1, 1), (−4, 2). The domain becomes (−∞, 0], because you need −x ≥ 0. The range stays [0, ∞).
The rule to remember is that an x-axis reflection changes the range and a y-axis reflection changes the domain. For an interval [p, q], the reflected interval is [−q, −p]. The endpoints swap and change sign.
What symmetry means
Some graphs are unchanged by a reflection. That property is called symmetry, and it gives two named families of functions.
An even function satisfies f(−x) = f(x) for every x in its domain. Reflecting its graph across the y-axis gives the same graph, so the graph is symmetric about the y-axis. Examples are x², |x|, x⁴ and cos x.
An odd function satisfies f(−x) = −f(x) for every x in its domain. Reflecting across the y-axis gives the same result as reflecting across the x-axis. Doing both reflections together returns the original graph, so the graph is symmetric about the origin: rotating it 180° leaves it unchanged. Examples are x, x³, 1/x and sin x.
Most functions are neither. The names come from polynomials. xⁿ is even when n is even and odd when n is odd.
A consequence of the odd definition is that if 0 is in the domain, f(0) = −f(0), so f(0) = 0. An odd function with 0 in its domain must pass through the origin. The converse is false, because passing through the origin does not make a function odd.
Testing algebraically
The first step in the flowchart is easy to forget. The definitions say "for every x in its domain", and they use both x and −x. So if x is in the domain, −x must be too. The domain must be symmetric about 0. The function f(x) = √x has domain [0, ∞), so −1 is never an input, and the function is neither even nor odd. Likewise, x² restricted to [0, 3] is neither even nor odd, though x² on all real numbers is even.
When the domain is symmetric, substitute −x, simplify, and compare.
Example 1: f(x) = x⁴ − 3x² + 1. f(−x) = (−x)⁴ − 3(−x)² + 1 = x⁴ − 3x² + 1 = f(x). The function is even.
Example 2: f(x) = x³ − x. f(−x) = (−x)³ − (−x) = −x³ + x = −(x³ − x) = −f(x). The function is odd.
Example 3: f(x) = x² + x. f(−x) = x² − x. This is not f(x), and it is not −f(x) = −x² − x. The function is neither.
Example 3 shows a pattern for polynomials. Even functions contain only even powers, and odd functions contain only odd powers. A mix of the two kinds of power gives neither. The constant term counts as an even power, since 1 = x⁰.
Testing in code
Code can check the definition at sample points. This is evidence, not a proof. A function can pass at every sampled point and still fail somewhere else. Integer inputs keep the comparisons exact.
def classify(f, xs):
"""Classify f as even, odd, both, or neither on the sample points xs."""
even = all(f(-x) == f(x) for x in xs)
odd = all(f(-x) == -f(x) for x in xs)
if even and odd:
return "both"
if even:
return "even"
if odd:
return "odd"
return "neither"
xs = range(-5, 6) # symmetric sample: -5 ... 5
tests = {
"x**3": lambda x: x ** 3,
"x**2": lambda x: x ** 2,
"x**2 + x": lambda x: x ** 2 + x,
"abs(x)": abs,
"x**3 - x": lambda x: x ** 3 - x,
"x + 1": lambda x: x + 1,
"0": lambda x: 0,
}
for name, f in tests.items():
print(f"{name:10} {classify(f, xs)}")The output is:
x**3 odd
x**2 even
x**2 + x neither
abs(x) even
x**3 - x odd
x + 1 neither
0 bothNote that x + 1 is neither. It is a shifted copy of the odd function x, and the vertical shift moved its graph off the origin.
How other transformations affect symmetry
Transformations from earlier chapters can keep or destroy symmetry. Suppose f is even.
- Vertical stretch or reflection, a·f(x). Still even. If f is odd, it is still odd.
- Vertical shift, f(x) + k. Still even. If f is odd and k ≠ 0, the result is neither, because the graph no longer passes through the origin.
- Horizontal shift, f(x − h) with h ≠ 0. Generally neither. The axis of symmetry moves to x = h, and the graph is symmetric about that line, but not about the y-axis. For example, (x − 1)² is neither even nor odd.
- Horizontal stretch, f(bx). Preserves both even and odd, because (−x) scales the same way as x.
This explains vertex form. The graph of a(x − h)² + k is symmetric about the vertical line x = h, which is the y-axis shifted by h. The function x² is even, and the horizontal shift moves its axis of symmetry.
Combining even and odd functions
Symmetry follows sign rules like those for positive and negative numbers.
| Operation | Result |
|---|---|
| even + even | even |
| odd + odd | odd |
| even × even | even |
| odd × odd | even |
| even × odd | odd |
| even + odd (both nonzero) | neither |
The last row leads to a useful fact. Any function whose domain is symmetric about 0 splits into an even part and an odd part:
- even part: (f(x) + f(−x)) / 2
- odd part: (f(x) − f(−x)) / 2
The two parts add up to f(x). The code below checks this for f(x) = x³ + x² + x + 1, where the even part should be x² + 1 and the odd part x³ + x.
f = lambda x: x ** 3 + x ** 2 + x + 1
even_part = lambda x: (f(x) + f(-x)) / 2
odd_part = lambda x: (f(x) - f(-x)) / 2
xs = range(-5, 6)
print(all(even_part(x) == x ** 2 + 1 for x in xs)) # True
print(all(odd_part(x) == x ** 3 + x for x in xs)) # True
print(all(even_part(x) + odd_part(x) == f(x) for x in xs)) # TrueCommon errors
- Skipping the domain check. Substituting −x into √x gives √(−x), which is not even a real number for positive x. Check the domain first.
- Calling a graph odd because it passes through the origin. The function x² passes through the origin and is even. Oddness needs f(−x) = −f(x) at every point.
- Calling x² + x or x + 1 "almost odd". There is no such category. If any sampled x breaks both tests, the function is neither.
- Reading the sign inside as an x-axis flip. A minus sign next to x flips across the y-axis.
- Forgetting that the constant term is even. Adding a nonzero constant to an odd function destroys its oddness.
Exercise
Classify each function as even, odd, or neither, and give a reason: (a) f(x) = x⁵ − 2x, (b) g(x) = |x| + 3, (c) h(x) = x² on the domain [−2, 5].
Show answer
(a) Odd: f(−x) = −x⁵ + 2x = −f(x), and all powers are odd. (b) Even: g(−x) = |−x| + 3 = |x| + 3 = g(x). The constant 3 is an even term. (c) Neither: the domain [−2, 5] is not symmetric about 0 (for example, 5 is allowed but −5 is not), so the definitions cannot hold for every x in the domain.
Exercise
The graph of f contains the points (1, 4), (−3, 2) and (0, 5). State the images of these points on the graph of y = −f(−x), and say what symmetry would make this graph identical to the graph of f.
Show answer
The mapping is (x, y) → (−x, −y), so the images are (−1, −4), (3, −2) and (0, −5). The graph of −f(−x) is identical to the graph of f exactly when f is odd, because −f(−x) = f(x) is the same as f(−x) = −f(x).
Exercise
f is an odd function with f(2) = 7. g(x) = f(x) + 1. Find g(−2), and decide whether g is odd.
Show answer
Since f is odd, f(−2) = −7, so g(−2) = −7 + 1 = −6. Now g(2) = 8, and −g(2) = −8, which is not −6. So g(−2) ≠ −g(2), and g is not odd. The vertical shift of 1 moved the graph off the origin.