Composite and Inverse Functions

Combining functions through composition and finding inverse functions

Composite and Inverse Functions

Function Composition

Definition: (fg)(x)=f(g(x))(f \circ g)(x) = f(g(x))

This means "apply gg first, then apply ff to the result."

Key Points

  • Order matters! (fg)(x)(gf)(x)(f \circ g)(x) \neq (g \circ f)(x) in general
  • Domain of fgf \circ g: all xx in domain of gg where g(x)g(x) is in domain of ff
  • Read right to left: fgf \circ g means "g then f"

Example

If f(x)=2x+1f(x) = 2x + 1 and g(x)=x2g(x) = x^2:

  • (fg)(x)=f(g(x))=f(x2)=2x2+1(f \circ g)(x) = f(g(x)) = f(x^2) = 2x^2 + 1
  • (gf)(x)=g(f(x))=g(2x+1)=(2x+1)2=4x2+4x+1(g \circ f)(x) = g(f(x)) = g(2x + 1) = (2x + 1)^2 = 4x^2 + 4x + 1

Inverse Functions

Definition: f1f^{-1} is the inverse of ff if:

  • f(f1(x))=xf(f^{-1}(x)) = x for all xx in domain of f1f^{-1}
  • f1(f(x))=xf^{-1}(f(x)) = x for all xx in domain of ff

One-to-One Requirement

A function must be one-to-one (injective) to have an inverse.

Horizontal Line Test: A function is one-to-one if no horizontal line intersects the graph more than once.

Finding Inverse Functions

  1. Replace f(x)f(x) with yy
  2. Swap xx and yy
  3. Solve for yy
  4. Replace yy with f1(x)f^{-1}(x)
  5. Verify: Check that f(f1(x))=xf(f^{-1}(x)) = x and f1(f(x))=xf^{-1}(f(x)) = x

Properties of Inverse Functions

  • Domain of ff = Range of f1f^{-1}
  • Range of ff = Domain of f1f^{-1}
  • Graphs of ff and f1f^{-1} are reflections across the line y=xy = x
  • If (a,b)(a, b) is on the graph of ff, then (b,a)(b, a) is on the graph of f1f^{-1}

📚 Practice Problems

1Problem 1easy

Question:

If f(x)=2x3f(x) = 2x - 3 and g(x)=x2+1g(x) = x^2 + 1, find (fg)(x)(f \circ g)(x) and (gf)(x)(g \circ f)(x).

💡 Show Solution

Find (fg)(x)=f(g(x))(f \circ g)(x) = f(g(x)):

Start with g(x)=x2+1g(x) = x^2 + 1

Then apply ff: f(g(x))=f(x2+1)f(g(x)) = f(x^2 + 1) =2(x2+1)3= 2(x^2 + 1) - 3 =2x2+23= 2x^2 + 2 - 3 =2x21= 2x^2 - 1

Find (gf)(x)=g(f(x))(g \circ f)(x) = g(f(x)):

Start with f(x)=2x3f(x) = 2x - 3

Then apply gg: g(f(x))=g(2x3)g(f(x)) = g(2x - 3) =(2x3)2+1= (2x - 3)^2 + 1 =4x212x+9+1= 4x^2 - 12x + 9 + 1 =4x212x+10= 4x^2 - 12x + 10

Answer:

  • (fg)(x)=2x21(f \circ g)(x) = 2x^2 - 1
  • (gf)(x)=4x212x+10(g \circ f)(x) = 4x^2 - 12x + 10

Note: They are different! Composition is not commutative.

2Problem 2medium

Question:

Given f(x)=2x+3f(x) = 2x + 3 and g(x)=x21g(x) = x^2 - 1:

a) Find (fg)(x)(f \circ g)(x) b) Find (gf)(x)(g \circ f)(x) c) Find (fg)(2)(f \circ g)(2)

💡 Show Solution

Solution:

Part (a): (fg)(x)=f(g(x))(f \circ g)(x) = f(g(x))

Substitute g(x)g(x) into ff:

f(g(x))=f(x21)=2(x21)+3=2x22+3=2x2+1f(g(x)) = f(x^2 - 1) = 2(x^2 - 1) + 3 = 2x^2 - 2 + 3 = 2x^2 + 1

Part (b): (gf)(x)=g(f(x))(g \circ f)(x) = g(f(x))

Substitute f(x)f(x) into gg:

g(f(x))=g(2x+3)=(2x+3)21g(f(x)) = g(2x + 3) = (2x + 3)^2 - 1

=4x2+12x+91=4x2+12x+8= 4x^2 + 12x + 9 - 1 = 4x^2 + 12x + 8

Part (c): (fg)(2)=2(2)2+1=2(4)+1=9(f \circ g)(2) = 2(2)^2 + 1 = 2(4) + 1 = 9

Alternatively: g(2)=221=3g(2) = 2^2 - 1 = 3, then f(3)=2(3)+3=9f(3) = 2(3) + 3 = 9

3Problem 3medium

Question:

Find the inverse function of f(x)=2x+1x3f(x) = \frac{2x + 1}{x - 3}. State the domain and range of both ff and f1f^{-1}.

💡 Show Solution

Find the inverse:

Step 1: Replace f(x)f(x) with yy: y=2x+1x3y = \frac{2x + 1}{x - 3}

Step 2: Swap xx and yy: x=2y+1y3x = \frac{2y + 1}{y - 3}

Step 3: Solve for yy: x(y3)=2y+1x(y - 3) = 2y + 1 xy3x=2y+1xy - 3x = 2y + 1 xy2y=3x+1xy - 2y = 3x + 1 y(x2)=3x+1y(x - 2) = 3x + 1 y=3x+1x2y = \frac{3x + 1}{x - 2}

Step 4: Write as f1(x)f^{-1}(x): f1(x)=3x+1x2f^{-1}(x) = \frac{3x + 1}{x - 2}

Domains and Ranges:

For f(x)=2x+1x3f(x) = \frac{2x + 1}{x - 3}:

  • Domain: x3x \neq 3, or (,3)(3,)(-\infty, 3) \cup (3, \infty)
  • Range: y2y \neq 2 (horizontal asymptote), or (,2)(2,)(-\infty, 2) \cup (2, \infty)

For f1(x)=3x+1x2f^{-1}(x) = \frac{3x + 1}{x - 2}:

  • Domain: x2x \neq 2 (which equals the range of ff) ✓
  • Range: y3y \neq 3 (which equals the domain of ff) ✓

4Problem 4medium

Question:

Find the inverse function of f(x)=3x2x+1f(x) = \frac{3x - 2}{x + 1}.

Verify that f(f1(x))=xf(f^{-1}(x)) = x.

💡 Show Solution

Solution:

Let y=f(x)=3x2x+1y = f(x) = \frac{3x - 2}{x + 1}

To find the inverse, swap xx and yy, then solve for yy:

x=3y2y+1x = \frac{3y - 2}{y + 1}

x(y+1)=3y2x(y + 1) = 3y - 2

xy+x=3y2xy + x = 3y - 2

xy3y=x2xy - 3y = -x - 2

y(x3)=x2y(x - 3) = -x - 2

y=x2x3=(x+2)x3y = \frac{-x - 2}{x - 3} = \frac{-(x + 2)}{x - 3}

Therefore: f1(x)=x2x3f^{-1}(x) = \frac{-x - 2}{x - 3} or (x+2)x3\frac{-(x+2)}{x-3}

Verification: f(f1(x))=f(x2x3)f(f^{-1}(x)) = f\left(\frac{-x-2}{x-3}\right)

=3(x2x3)2x2x3+1= \frac{3\left(\frac{-x-2}{x-3}\right) - 2}{\frac{-x-2}{x-3} + 1}

=3x6x32x2x3+1= \frac{\frac{-3x-6}{x-3} - 2}{\frac{-x-2}{x-3} + 1}

=3x62(x3)x3x2+(x3)x3= \frac{\frac{-3x-6-2(x-3)}{x-3}}{\frac{-x-2+(x-3)}{x-3}}

=3x62x+6x2+x3= \frac{-3x-6-2x+6}{-x-2+x-3}

=5x5=x= \frac{-5x}{-5} = x

5Problem 5hard

Question:

Given f(x)=x24x+3f(x) = x^2 - 4x + 3 for x2x \geq 2, find f1(x)f^{-1}(x) and determine f1(8)f^{-1}(8).

💡 Show Solution

Note: The domain restriction x2x \geq 2 makes ff one-to-one (right half of parabola).

Complete the square first: f(x)=x24x+3=(x2)24+3=(x2)21f(x) = x^2 - 4x + 3 = (x - 2)^2 - 4 + 3 = (x - 2)^2 - 1

With domain x2x \geq 2, the range is y1y \geq -1.

Find the inverse:

Start with y=(x2)21y = (x - 2)^2 - 1

Swap variables: x=(y2)21x = (y - 2)^2 - 1

Solve for yy: x+1=(y2)2x + 1 = (y - 2)^2 ±x+1=y2\pm\sqrt{x + 1} = y - 2 y=2±x+1y = 2 \pm \sqrt{x + 1}

Since original domain is x2x \geq 2, the range is y2y \geq 2, so we need the positive square root: f1(x)=2+x+1f^{-1}(x) = 2 + \sqrt{x + 1}

Domain of f1f^{-1}: x1x \geq -1 (the range of ff)

Find f1(8)f^{-1}(8): f1(8)=2+8+1=2+9=2+3=5f^{-1}(8) = 2 + \sqrt{8 + 1} = 2 + \sqrt{9} = 2 + 3 = 5

Verify: f(5)=524(5)+3=2520+3=8f(5) = 5^2 - 4(5) + 3 = 25 - 20 + 3 = 8

Answer: f1(x)=2+x+1f^{-1}(x) = 2 + \sqrt{x + 1} for x1x \geq -1, and f1(8)=5f^{-1}(8) = 5