Functions, Relations & Transformations

Study Sheet

Functions, Relations & Transformations

Everything you need for Topic 2, with worked examples and graphs

Relations, Functions & the Vertical Line Test

Concept
Big idea

A relation is any set of ordered pairs (x,y)(x,y). A function is a special relation in which every input xx is paired with exactly one output yy. In other words: no xx-value is allowed to repeat with two different yy-values.

  • The set of all allowed inputs is the domain.
  • The set of all resulting outputs is the range.

A function assigns exactly one output to each input (the vertical line test). Transformations move a graph without redrawing it: f(x)+kf(x) + k shifts up, f(x−h)f(x - h) shifts right, −f(x)-f(x) reflects, af(x)af(x) stretches vertically. Composition feeds one function into another; the inverse reverses the input–output pairs and exists only when the function is one-to-one.

The vertical line test is the definition of a function in pictures. A vertical line collects every point with one particular input; if it meets a graph twice, that input has two outputs. The sideways parabola x=y2x = y^2 fails at x=2.25x = 2.25, where y=1.5y = 1.5 and y=−1.5y = -1.5; the tilted line meets every vertical line exactly once.

Example
Example: is it a function?

Consider R={(−2,3),(0,1),(1,4),(0,5)}R=\{(-2,3),(0,1),(1,4),(0,5)\}.

The input 00 appears twice, paired with both 11 and 55. Since one input gives two outputs, RR is not a function.

Now S={(−2,3),(0,1),(1,4),(3,1)}S=\{(-2,3),(0,1),(1,4),(3,1)\} is a function: every input is used once. (It is fine for two inputs to share an output, as 00 and 33 both give 11.)

Side note
Where it goes wrong

Rejecting a relation because two inputs share an output: {(1,5),(2,5)}\{(1, 5), (2, 5)\} is a function. The rule forbids one input with two outputs, not two inputs with one output; a horizontal line may cross a function's graph many times.

Concept
The Vertical Line Test

A graph represents a function if and only if no vertical line crosses it more than once. A vertical line is a set of points with the same xx; hitting the graph twice would mean one xx has two yy's.

The tilted line and the sideways parabola x=y2x = y^2 from the tip below, on one set of axes.

Tip

Tip: The dashed vertical line on the right hits the sideways parabola twice, so that curve fails the test. A tilted straight line always passes.

Try it
Try it: function or not?

Which are functions: {(1,2),(2,2),(3,2)}\{(1, 2), (2, 2), (3, 2)\}; {(2,1),(2,3)}\{(2, 1), (2, 3)\}; x2+y2=25x^2 + y^2 = 25; y=∣x−4∣y = |x - 4|?

Show the answer

The first is: each input once (sharing an output is fine). The second is not: input 22 has two outputs. The circle is not: x=3x = 3 gives y=4y = 4 and y=−4y = -4. y=∣x−4∣y = |x - 4| is: each xx gives one value.

Function Notation, Evaluating, Discrete vs. Continuous

Concept
Function notation

We write f(x)f(x) (read “ff of xx”) for the output of function ff at input xx. The letter xx is a placeholder: to evaluate, substitute the given value everywhere xx appears and simplify.

Function notation keeps track of which input produced which output, so f(3)=10f(3) = 10 is a complete fact: the point (3,10)(3, 10) is on the graph. Evaluating at an expression like a+1a + 1 is the same substitution, done symbolically, and it is how new functions (shifts, compositions) are built from old ones.

Example
Example: evaluating
xy−2−1123246810(3, 10)(−1, 6)
Each evaluation is a point on y=2x2−3x+1y = 2x^2 - 3x + 1.

Let f(x)=2x2−3x+1f(x)=2x^2-3x+1. Then

f(3)=2(3)2−3(3)+1=18−9+1=10,f(−1)=2(−1)2−3(−1)+1=2+3+1=6.f(3)=2(3)^2-3(3)+1=18-9+1=10,\qquad f(-1)=2(-1)^2-3(-1)+1=2+3+1=6.

You can also evaluate at an expression: f(a+1)=2(a+1)2−3(a+1)+1=2a2+af(a+1)=2(a+1)^2-3(a+1)+1=2a^2+a.

Side note
Where it goes wrong

Evaluating f(a+1)f(a + 1) as f(a)+1f(a) + 1. For f(x)=2x2−3x+1f(x) = 2x^2 - 3x + 1, f(a)+1=2a2−3a+2f(a) + 1 = 2a^2 - 3a + 2, but f(a+1)=2(a+1)2−3(a+1)+1=2a2+af(a + 1) = 2(a + 1)^2 - 3(a + 1) + 1 = 2a^2 + a. The whole input replaces xx.

Concept
Discrete vs. continuous

A discrete function is defined only at separated points (draw dots), e.g. “number of students” vs. “number of pizzas.” A continuous function is defined on an unbroken interval (draw a solid curve), e.g. “temperature” vs. “time.”

Tip

Tip: f(x)f(x) does not mean ff times xx. It is a single output value.

Try it
Try it: notation

For g(x)=x2−4xg(x) = x^2 - 4x, find g(−3)g(-3), g(2t)g(2t), and all xx with g(x)=5g(x) = 5.

Show the answer

g(−3)=9+12=21g(-3) = 9 + 12 = 21. g(2t)=4t2−8tg(2t) = 4t^2 - 8t. x2−4x−5=0x^2 - 4x - 5 = 0 gives (x−5)(x+1)=0(x - 5)(x + 1) = 0, so x=5x = 5 or x=−1x = -1.

Parent Functions and Their Graphs

Concept
The six parents

Each family of functions is built from a simple “parent.” Memorize their shapes, domains, and ranges.

parentdomainrangey=xall realsall realsy=x2all realsy≥0y=x3all realsall realsy=∣x∣all realsy≥0y=xx≥0y≥0y=1xx≠0y≠0\begin{array}{l|l|l} \text{parent} & \text{domain} & \text{range} \\ \hline y = x & \text{all reals} & \text{all reals} \\ y = x^2 & \text{all reals} & y \ge 0 \\ y = x^3 & \text{all reals} & \text{all reals} \\ y = |x| & \text{all reals} & y \ge 0 \\ y = \sqrt{x} & x \ge 0 & y \ge 0 \\ y = \tfrac1x & x \ne 0 & y \ne 0 \end{array}

Every function in this course is one of these parents moved, stretched or flipped, so knowing six shapes lets you sketch hundreds of graphs. Their domains and ranges come from what the rule allows: x\sqrt x needs x≥0x \ge 0, 1x\tfrac1x forbids x=0x = 0 and never outputs 00, and an even power like x2x^2 never outputs a negative.

Each parent is drawn on the window −3≤x≤3-3 \le x \le 3, −3≤y≤3-3 \le y \le 3.

Tip

Tip: y=x2y=x^2 and y=∣x∣y=|x| both open upward with a minimum at the origin, but the parabola is curved while the absolute value is two straight rays meeting in a sharp corner.

Side note
Where it goes wrong

Giving y=x3y = x^3 the range y≥0y \ge 0 by analogy with x2x^2. An odd power keeps the sign: (−2)3=−8(-2)^3 = -8. The range of x3x^3 is all real numbers.

Try it
Try it: domain and range

Give the domain and range of y=xy = \sqrt{x}, y=1xy = \tfrac1x and y=∣x∣y = |x|.

Show the answer

x\sqrt x: domain [0,∞)[0, \infty), range [0,∞)[0, \infty). 1x\tfrac1x: domain and range all reals except 00. ∣x∣|x|: domain all reals, range [0,∞)[0, \infty).

Transformations: y=a f(x−h)+ky=a\,f(x-h)+k

Concept
Reading the transformation

Starting from a parent f(x)f(x), the graph of y=a f(x−h)+ky=a\,f(x-h)+k is transformed as follows:

  • kk: vertical shift — up if k>0k>0, down if k<0k<0.
  • hh: horizontal shift — right if h>0h>0, left if h<0h<0 (it moves opposite the sign inside).
  • aa: vertical stretch if ∣a∣>1|a|>1, vertical compression if 0<∣a∣<10<|a|<1.
  • a<0a<0: reflection over the xx-axis. Replacing xx with −x-x reflects over the yy-axis.

Why does f(x−h)f(x - h) move right? The new graph takes the value ff had at x−hx - h, so to reproduce what happened at 00 it must reach x=hx = h: every feature arrives hh units later, which is to the right. Outside changes act on outputs and move the graph the way they read: +k+k adds to every height, and aa multiplies every height, flipping it when a<0a < 0.

Example
Example: describe the transformation
xy−2−1123−4−3−2−11234(1, 3)(0, 0)
y=x2y = x^2 (dashed) becomes −2(x−1)2+3-2(x - 1)^2 + 3: vertex (0,0)(0, 0) moves to (1,3)(1, 3).

Compare g(x)=−2(x−1)2+3g(x)=-2(x-1)^2+3 to the parent f(x)=x2f(x)=x^2. Here a=−2a=-2, h=1h=1, k=3k=3, so gg is the parabola stretched vertically by 22, reflected over the xx-axis, shifted right 11 and up 33. Its vertex is (1,3)(1,3) and it opens downward.

Side note
Where it goes wrong

Shifting the wrong way: f(x−3)f(x - 3) moves the graph RIGHT by 33. The input must be 33 larger to produce the same output.

Tip

Tip (order of operations for graphs): apply horizontal shift and stretch/reflection first, then the vertical shift last. The vertex of y=a(x−h)2+ky=a(x-h)^2+k is always (h,k)(h,k).

Try it
Try it: build a transformation

Write the equation of y=∣x∣y = |x| reflected over the xx-axis, compressed by 12\tfrac12, shifted left 44 and up 22. Where is its corner?

Show the answer

y=−12∣x+4∣+2y = -\tfrac12|x + 4| + 2. The corner moves from (0,0)(0, 0) to (−4,2)(-4, 2), and the graph opens downward.

Operations on Functions

Concept
Combining functions

For two functions ff and gg:

(f+g)(x)=f(x)+g(x),(f−g)(x)=f(x)−g(x),(f+g)(x)=f(x)+g(x),\quad (f-g)(x)=f(x)-g(x),
(fg)(x)=f(x)⋅g(x),(fg)(x)=f(x)g(x)  (g(x)≠0).(fg)(x)=f(x)\cdot g(x),\quad \left(\tfrac{f}{g}\right)(x)=\frac{f(x)}{g(x)}\ \ (g(x)\ne 0).

The domain of the result is where both pieces are defined, and for the quotient we also exclude any xx with g(x)=0g(x)=0.

Functions add, subtract and multiply pointwise: at each input, combine the two outputs. So (f+g)(x)(f + g)(x) exists only where both f(x)f(x) and g(x)g(x) exist, which is why domains intersect, and a quotient loses any input where the denominator's output is 00.

Example
Example

Let f(x)=x2+1f(x)=x^2+1 and g(x)=x−2g(x)=x-2. Then

(f+g)(x)=x2+x−1,(fg)(x)=(x2+1)(x−2)=x3−2x2+x−2,(f+g)(x)=x^2+x-1,\qquad (fg)(x)=(x^2+1)(x-2)=x^3-2x^2+x-2,
(fg)(x)=x2+1x−2  (x≠2).\left(\tfrac{f}{g}\right)(x)=\frac{x^2+1}{x-2}\ \ (x\ne 2).
Side note
Where it goes wrong

Forgetting the quotient's domain after simplifying: for f(x)=x2−4f(x) = x^2 - 4 and g(x)=x−2g(x) = x - 2, (fg)(x)=x+2\left(\tfrac fg\right)(x) = x + 2, but x=2x = 2 is still excluded because g(2)=0g(2) = 0.

Tip

Tip: Operations happen at the same input. Only the quotient forces you to worry about a zero denominator.

Try it
Try it: combine

For f(x)=xf(x) = \sqrt{x} and g(x)=x−3g(x) = x - 3, find (f−g)(4)(f - g)(4), (fg)(9)(fg)(9) and the domain of fg\tfrac fg.

Show the answer

(f−g)(4)=2−1=1(f - g)(4) = 2 - 1 = 1. (fg)(9)=3⋅6=18(fg)(9) = 3 \cdot 6 = 18. fg\tfrac fg needs x≥0x \ge 0 (for x\sqrt x) and x≠3x \ne 3: [0,3)∪(3,∞)[0, 3) \cup (3, \infty).

Composition of Functions

Concept
Composition

The composition (f∘g)(x)=f(g(x))(f\circ g)(x)=f\bigl(g(x)\bigr) means: run gg first, then feed its output into ff. Composition is usually not commutative: (f∘g)(x)≠(g∘f)(x)(f\circ g)(x)\ne (g\circ f)(x) in general.

A composition is a chain of machines: the output of gg becomes the input of ff. The order matters because the machines do different things: subtracting 22 then squaring is not squaring then subtracting 22, which is why (f∘g)(x)=x2−4x+5(f \circ g)(x) = x^2 - 4x + 5 while (g∘f)(x)=x2−1(g \circ f)(x) = x^2 - 1.

Example
Example

Let f(x)=x2+1f(x)=x^2+1 and g(x)=x−2g(x)=x-2.

(f∘g)(x)=f(x−2)=(x−2)2+1=x2−4x+5,(f\circ g)(x)=f(x-2)=(x-2)^2+1=x^2-4x+5,
(g∘f)(x)=g(x2+1)=(x2+1)−2=x2−1.(g\circ f)(x)=g(x^2+1)=(x^2+1)-2=x^2-1.

And numerically (f∘g)(5)=f(3)=10(f\circ g)(5)=f(3)=10.

Side note
Where it goes wrong

Multiplying instead of composing: (f∘g)(x)=f(x)g(x)(f \circ g)(x) = f(x)g(x). The circle means substitute: f(g(x))f(g(x)).

Tip

Tip: Work from the inside out. Substitute the whole expression for g(x)g(x) into every xx of ff.

Try it
Try it: compose

For f(x)=3x+1f(x) = 3x + 1 and g(x)=x2g(x) = x^2, find (f∘g)(−2)(f \circ g)(-2), (g∘f)(−2)(g \circ f)(-2), and (f∘f)(x)(f \circ f)(x).

Show the answer

g(−2)=4g(-2) = 4, so f(4)=13f(4) = 13. f(−2)=−5f(-2) = -5, so g(−5)=25g(-5) = 25. (f∘f)(x)=3(3x+1)+1=9x+4(f \circ f)(x) = 3(3x + 1) + 1 = 9x + 4.

Inverse Functions

Concept
What an inverse does

The inverse f−1f^{-1} undoes ff: it swaps inputs and outputs, so if f(a)=bf(a)=b then f−1(b)=af^{-1}(b)=a. To find it: replace f(x)f(x) with yy, swap xx and yy, then solve for yy.

An inverse reverses every input-output pair, so the point (a,b)(a, b) on ff becomes (b,a)(b, a) on f−1f^{-1}. Swapping coordinates is reflecting across the line y=xy = x, which is why the two graphs are mirror images. A function has an inverse function only if no output repeats, because otherwise the reversed pairs would give one input two outputs.

Example
Example: find and verify
xy(5, 4)(4, 5)
f(x)=2x−6f(x) = 2x - 6 and its inverse (dashed) mirror each other across y=xy = x: (5,4)(5, 4) and (4,5)(4, 5).

Let f(x)=2x−6f(x)=2x-6. Swap and solve: x=2y−6⇒y=x+62x=2y-6\Rightarrow y=\dfrac{x+6}{2}, so f−1(x)=x+62f^{-1}(x)=\dfrac{x+6}{2}.

Verify by composition:

f(f−1(x))=2 ⁣(x+62)−6=x,f−1(f(x))=(2x−6)+62=x. ✓f\bigl(f^{-1}(x)\bigr)=2\!\left(\tfrac{x+6}{2}\right)-6=x,\qquad f^{-1}\bigl(f(x)\bigr)=\tfrac{(2x-6)+6}{2}=x.\ \checkmark

Both compositions give xx, confirming the inverse.

Side note
Where it goes wrong

Reading f−1(x)f^{-1}(x) as 1f(x)\tfrac{1}{f(x)}. For f(x)=2x−6f(x) = 2x - 6, 12x−6\tfrac{1}{2x - 6} is the reciprocal; the inverse is x+62\tfrac{x + 6}{2}. Check: f−1(f(5))=f−1(4)=5f^{-1}(f(5)) = f^{-1}(4) = 5.

Tip

Tip: The graph of f−1f^{-1} is the mirror image of ff across the line y=xy=x. If ff passes the vertical line test and its inverse must too, ff must be one-to-one (pass the horizontal line test).

Try it
Try it: invert

Find the inverse of f(x)=x−13f(x) = \dfrac{x - 1}{3} and verify with one number.

Show the answer

Swap and solve: x=y−13x = \tfrac{y - 1}{3}, so y=3x+1y = 3x + 1: f−1(x)=3x+1f^{-1}(x) = 3x + 1. Check: f(7)=2f(7) = 2 and f−1(2)=7f^{-1}(2) = 7.

Piecewise Functions

Concept
Reading a piecewise rule

A piecewise function uses different formulas on different parts of the domain. To evaluate, first decide which interval the input falls in, then use that piece.

f(x)={x+3,x<0x2,0≤x≤24,x>2f(x)=\begin{cases} x+3, & x<0\\ x^2, & 0\le x\le 2\\ 4, & x>2\end{cases}

A piecewise function is still one function: every input belongs to exactly one piece, so it has exactly one output. The inequalities attached to the pieces are the rules for which formula applies, and the open and closed dots on the graph show who owns each boundary.

Example
Example: evaluate the piecewise function above
xy−5−4−3−2−11234−3−2−112345(−4, −1)(1, 1)
Open dot at (0,3)(0, 3): 00 belongs to the x2x^2 piece, which gives f(0)=0f(0) = 0.
f(−4)=−4+3=−1  (use x+3),f(1)=12=1  (use x2),f(5)=4  (use the constant).f(-4)=-4+3=-1\ \ (\text{use }x+3),\quad f(1)=1^2=1\ \ (\text{use }x^2),\quad f(5)=4\ \ (\text{use the constant}).

Watch the endpoints: at x=0x=0 we use x2x^2 because that piece includes 00 (0≤x0\le x).

Side note
Where it goes wrong

Evaluating at a boundary with the wrong piece: f(0)=0+3=3f(0) = 0 + 3 = 3. The first piece is for x<0x < 0 only; 00 falls under 0≤x≤20 \le x \le 2, so f(0)=02=0f(0) = 0^2 = 0.

Tip

Tip: A filled dot means the endpoint is included (≤\le or ≥\ge); an open dot means it is not (<< or >>). Only one piece may own each xx.

Try it
Try it: a parking fee

Parking costs $4\$4 for up to 22 hours and $3\$3 for each additional hour or part of an hour, capped at $20\$20. Find the cost for 1.51.5, 3.23.2 and 99 hours.

Show the answer

1.51.5 h: $4\$4. 3.23.2 h: 22 extra started hours, 4+3⋅2=$104 + 3 \cdot 2 = \$10. 99 h: 4+3⋅7=254 + 3 \cdot 7 = 25, over the cap, so $20\$20.

Going Deeper: Advanced Function Ideas

Concept
Functional equations: solve for the rule, not a number

A functional equation constrains an unknown function ff instead of an unknown number. The classic trick: substitute a cleverly chosen input to generate a second equation, then treat f(x)f(x) and f(other)f(\text{other}) as two unknowns and eliminate. For equations mixing f(x)f(x) with f(1/x)f(1/x), the magic substitution is x↦1/xx\mapsto 1/x, which swaps the two terms.

Example
Worked example: solve f(x)+2f(1/x)=3xf(x)+2f(1/x)=3x

Write the given equation, then replace every xx with 1/x1/x (note 1/(1/x)=x1/(1/x)=x):

f(x)+2f ⁣(1x)=3x,(1)f ⁣(1x)+2f(x)=3x.(2)\begin{aligned} f(x)+2f\!\left(\tfrac1x\right) &= 3x, &&\text{(1)}\\ f\!\left(\tfrac1x\right)+2f(x) &= \tfrac{3}{x}. &&\text{(2)} \end{aligned}

Now eliminate f(1/x)f(1/x): multiply (2) by 22 and subtract (1):

(2f(1x)+4f(x))−(f(x)+2f(1x))=6x−3x  ⟹  3f(x)=6x−3x.\bigl(2f(\tfrac1x)+4f(x)\bigr)-\bigl(f(x)+2f(\tfrac1x)\bigr)=\tfrac{6}{x}-3x \;\Longrightarrow\; 3f(x)=\tfrac{6}{x}-3x.

So f(x)=2x−xf(x)=\dfrac{2}{x}-x. Check: f(x)+2f(1/x)=(2x−x)+2(2x−1x)=2x−x+4x−2x=3x.f(x)+2f(1/x)=\left(\tfrac2x-x\right)+2\left(2x-\tfrac1x\right)=\tfrac2x-x+4x-\tfrac2x=3x. ✓

Concept
Iterated composition and involutions

Composing ff with itself is written f[n]=f∘f∘⋯∘f⏟n copiesf^{[n]}=\underbrace{f\circ f\circ\cdots\circ f}_{n\text{ copies}}, so f[2](x)=f(f(x))f^{[2]}(x)=f(f(x)). Beware: this is iteration, not the power (f(x))n\bigl(f(x)\bigr)^n and not the inverse f−1f^{-1}.

  • If f[n]=idf^{[n]}=\mathrm{id} (the identity x↦xx\mapsto x) for some nn, then ff is periodic under iteration with period dividing nn, and f[m]f^{[m]} depends only on m mod nm \bmod n.
  • An involution is the special case n=2n=2: f(f(x))=xf(f(x))=x, so ff is its own inverse, f−1=ff^{-1}=f. Its graph is symmetric across y=xy=x.
Example
Worked example: a period-3 map and a self-inverse map

(a) Iteration. Let f(x)=11−xf(x)=\dfrac{1}{1-x}. Then

f[2](x)=f ⁣(11−x)=11−11−x=1−x−x=x−1x,f[3](x)=f ⁣(x−1x)=11−x−1x=x.f^{[2]}(x)=f\!\left(\tfrac{1}{1-x}\right)=\frac{1}{1-\frac{1}{1-x}}=\frac{1-x}{-x}=\frac{x-1}{x}, \qquad f^{[3]}(x)=f\!\left(\tfrac{x-1}{x}\right)=\frac{1}{1-\frac{x-1}{x}}=x.

So f[3]=idf^{[3]}=\mathrm{id}: the map has period 33. To find f[100]f^{[100]}, reduce the exponent: 100≡1(mod3)100\equiv 1\pmod 3, hence f[100]=f[1]=ff^{[100]}=f^{[1]}=f.

(b) Involution. Let g(x)=2x−3x−2g(x)=\dfrac{2x-3}{x-2}. Composing gg with itself,

g(g(x))=2⋅2x−3x−2−32x−3x−2−2=xx−21x−2=x,g(g(x))=\frac{2\cdot\frac{2x-3}{x-2}-3}{\frac{2x-3}{x-2}-2} =\frac{\frac{x}{x-2}}{\frac{1}{x-2}}=x,

so gg is an involution: g−1=gg^{-1}=g. Any g(x)=ax+bcx−ag(x)=\dfrac{ax+b}{cx-a} is self-inverse for the same reason.

Example
Worked example: the domain of a nasty composition

Let f(x)=1x−1f(x)=\dfrac{1}{x-1} and g(x)=4−x2g(x)=\sqrt{4-x^2}, and form h(x)=(f∘g)(x)=14−x2−1h(x)=(f\circ g)(x)=\dfrac{1}{\sqrt{4-x^2}-1}. The domain needs two conditions, checked in order:

  • xx must be legal for the inner gg:   4−x2≥0⇒−2≤x≤2\;4-x^2\ge 0\Rightarrow -2\le x\le 2.
  • The output g(x)g(x) must be legal for the outer ff, i.e. g(x)≠1g(x)\ne 1:   4−x2≠1⇒4−x2≠1⇒x≠±3\;\sqrt{4-x^2}\ne 1\Rightarrow 4-x^2\ne 1\Rightarrow x\ne\pm\sqrt{3}.

Domain: [−2,2][-2,2] with the two holes x=±3x=\pm\sqrt{3} removed. Moral: the domain of f∘gf\circ g is not just the domain of gg; you must also delete inputs whose output lands in a forbidden spot for ff.

Concept
Invertibility via monotonicity

A function is invertible exactly when it is one-to-one (passes the horizontal line test). You do not need an explicit formula for f−1f^{-1} to know it exists:

If ff is strictly increasing on its domain (or strictly decreasing), then ff is one-to-one, so f−1f^{-1} exists.

For example, f(x)=x5+x+1f(x)=x^5+x+1 is a sum of the strictly increasing pieces x5x^5, xx, and a constant, so it is strictly increasing and therefore invertible on all of R\mathbb{R} — even though solving y=x5+x+1y=x^5+x+1 for xx by hand is hopeless. Monotonicity is also how you restrict a non-injective parent (like y=x2y=x^2) to make it invertible: choose a branch, e.g. x≥0x\ge 0.

Concept
Exploiting even and odd symmetry

A function is even if f(−x)=f(x)f(-x)=f(x) (graph symmetric across the yy-axis) and odd if f(−x)=−f(x)f(-x)=-f(x) (symmetric through the origin). Symmetry halves your work: knowing ff on x≥0x\ge 0 determines it everywhere. Two facts worth memorizing:

  • Products behave like parity signs: even×even=even\text{even}\times\text{even}=\text{even}, odd×odd=even\text{odd}\times\text{odd}=\text{even}, even×odd=odd\text{even}\times\text{odd}=\text{odd}.
  • Every function splits uniquely into an even part plus an odd part: @@BLOCK0@@
Tip

Tip: If ff is odd then f(0)=0f(0)=0 (set x=0x=0 in f(−x)=−f(x)f(-x)=-f(x)). And if a problem asks for f(−a)f(-a) and you already know f(a)f(a), don't recompute — just flip the sign for odd, copy for even.

Example
Worked example: piecewise continuity with a parameter

Choose the constant aa so that

f(x)={x2+a,x≤13x−1,x>1f(x)=\begin{cases} x^2+a, & x\le 1\\[2pt] 3x-1, & x>1\end{cases}

is continuous. Continuity at the seam x=1x=1 requires the two pieces to agree there. The left piece gives f(1)=12+a=1+af(1)=1^2+a=1+a; the right piece approaches 3(1)−1=23(1)-1=2 as x→1+x\to 1^{+}. Set them equal:

1+a=2  ⟹  a=1.1+a=2\;\Longrightarrow\; a=1.

With a=1a=1 the graph joins with no jump. For any other aa there is a gap of height ∣1+a−2∣=∣a−1∣|1+a-2|=|a-1| at x=1x=1.

Concept
Composing several transformations into one mapping

A chain of transformations can always be collapsed into a single rule y=a f(b(x−h))+ky=a\,f\bigl(b(x-h)\bigr)+k. Track what happens to a generic point, applying inner (horizontal) changes to xx and outer (vertical) changes to the whole expression. Order matters, because a horizontal shift done before a horizontal stretch is not the same as after.

Example. Starting from ff, reflect over the yy-axis, then shift left 22, then stretch vertically by 33, then shift up 11. Building inside-out, the horizontal reflect-and-shift turns the input into −(x+2)-(x+2), and the outer stretch-and-shift wraps it:

y=3 f(−(x+2))+1.y=3\,f\bigl(-(x+2)\bigr)+1.

A single expression now encodes all four moves — feed in one xx, get the fully transformed yy.

Why It Works

Why does f(x−h)f(x - h) shift right? The point that used to be at x=ax = a on y=f(x)y = f(x) now appears where x−h=ax - h = a, i.e. at x=a+hx = a + h: every point moved hh to the right. Vertical changes act on the output directly, so they read the natural way; horizontal changes act on the input, so they read backwards. The inverse function swaps xx and yy, which reflects the graph across the line y=xy = x — and a graph that fails the horizontal line test would fail the vertical line test after the swap, hence "one-to-one".

Tip
Reading a proof

Do not read a proof the way you read a rule. Cover the last line, ask what the previous line forces, and only then uncover it. If a step feels like magic, that is the step to work by hand with a concrete number.

Formulas, Proofs & Tips

Tip
Function transformations
y=a f(b(x−h))+ky = a\,f\big(b(x-h)\big)+k

What it means. hh shifts right, kk shifts up, aa stretches vertically (flipping if negative), bb compresses horizontally.

Example. y=(x−2)2+3y=(x-2)^2+3 shifts y=x2y=x^2 right 22 and up 33.

Why it works. Inside changes act on the input before ff does, so they run backwards: replacing xx by x−hx-h means the graph reaches a given output hh units later, i.e. shifted right. Outside changes act after ff, so they behave as written.

Tip. Inside the function: opposite of what it looks like. Outside: exactly what it looks like.

Tip
Inverse functions
f(f−1(x))=xandf−1(f(x))=xf\big(f^{-1}(x)\big)=x \quad\text{and}\quad f^{-1}\big(f(x)\big)=x

What it means. The inverse undoes the function; their graphs are mirror images across y=xy=x.

Example. f(x)=2x+1f(x)=2x+1 has inverse f−1(x)=x−12f^{-1}(x)=\tfrac{x-1}{2}, and f(f−1(x))=xf(f^{-1}(x))=x.

Why it works. Swapping xx and yy in y=f(x)y=f(x) and solving for yy produces the rule that reverses each input–output pair. Reflecting across y=xy=x is exactly what swapping coordinates does geometrically.

Tip. Only one-to-one functions have inverses. If a horizontal line hits the graph twice, restrict the domain first.