-5

Day -5

Prep Function Bootcamp


Number Systems & Logical Symbols

Before diving into Calculus, we must speak the language of mathematics. This includes identifying different sets of numbers and understanding logical quantifiers.

Core Theorem
Common Notation:
- ℕ: Natural Numbers (positive integers)
- ℤ: Integers
- ℚ: Rational Numbers
- ℝ: Real Numbers
- ℂ: Complex Numbers

Logical Quantifiers:
- ∀: 'For all'
- ∃: 'There exists'
- ∃!: 'There exists a unique'
Common Pitfalls
  • Natural Numbers AmbiguityIn some contexts, ℕ includes zero. However, in this curriculum (as per the notes), ℕ refers strictly to positive integers. Always check the boundary conditions!

Defining a Function

A function is a specific type of relationship between two sets where every input has exactly one output.

Core Theorem
A function f:ABf: A → B is a correspondence such that:
a in A, ! ∃! b in B such that f(a)=bf(a) = b.
- Domain (
AA): The set of all possible inputs.
- Codomain (
BB): The set where outputs land.
- Range (
f(A)f(A)): The actual set of values produced by the function
(
f(A)f(B)f(A) ⊆ f(B)).

Worked Examples

Read these first — the full solution is shown, with the reasoning behind each move.

Worked Example 01Easy
A rectangular box with no lid has a volume of 10m310 m^3. The length of the base is twice its width. The material for the base costs 10/m210/m^2, and the side material costs 6/m26/m^2.
Express the total cost
CC as a function of the base width ww.
How to think about it

Key idea: Volume V=lwhV = l * w * h. Use the volume to replace hh in the cost equation.

Full solution

1. Establish Variables

Let width be ww, then length l=2wl = 2w. Let height be hh. Volume V=w(2w)hV = w(2w)h= 2w2h=102w^2 * h = 10, h=10/2w2h = 10/2w^2.

2. Calculate Areas

Base area Abase=2w2A_{base} = 2w^2. Side areas consist of two whw * h faces and two 2wh2w * h faces. Asides=2(wh)+2(2wh)=6whA_{sides} = 2(wh) + 2(2wh) = 6wh.

3. Formulate Cost Function

C(w)=10(2w2)+6(6wh)C(w) = 10(2w^2) + 6(6wh)。Substitute h=5w2h = \frac{5}{w^2}:
C(w)=20w2+36w(5w2)=20w2+180wC(w) = 20w^2 + 36w(\frac{5}{w^2}) = 20w^2 + \frac{180}{w}
Worked Example 02Hard
A right triangle has an area of 25. Express the length of the hypotenuse hh as a function of the perimeter pp.
How to think about it

Key idea: Use a2+b2=h2a^2 + b^2 = h^2 and Area=12ab=25Area = \frac{1}{2}ab = 25. Remember p=a+b+hp = a + b + h.

Full solution

1. Establish System of Equations

From the area: 12ab=25    ab=50\frac{1}{2}ab = 25 \implies ab = 50. From the Pythagorean theorem: a2+b2=h2a^2 + b^2 = h^2. From the perimeter: a+b+h=p    a+b=pha + b + h = p \implies a + b = p - h.

2. Algebraic Substitution

Square the perimeter relation: (a+b)2=(ph)2(a + b)^2 = (p - h)^2. Expanding gives a2+b2+2ab=(ph)2a^2 + b^2 + 2ab = (p - h)^2. Substitute a2+b2=h2a^2 + b^2 = h^2 and ab=50ab = 50: h2+2(50)=(ph)2h^2 + 2(50) = (p - h)^2.

3. Solve for h

Expand the right side: h2+100=p22ph+h2h^2 + 100 = p^2 - 2ph + h^2. Subtract h2h^2 from both sides: 100=p22ph100 = p^2 - 2ph. Rearrange to isolate hh: 2ph=p21002ph = p^2 - 100. Final function: h(p)=p21002ph(p) = \frac{p^2 - 100}{2p}.
Step-by-Step SOP
  1. 1

    Testing for a Function

    Check if any xx in the domain maps to more than one yy. If it does, it's a relation, not a function.

Practice — Your Turn

Try each one before opening the hint or the solution.

Practice 01Medium
A taxi fare is 7575 for the first 2 km2\text{ km}, and 55 for every additional 500 m500\text{ m}. Express the fare CC as a function of distance dd (in km).
Need a hint?
This is a step function (piecewise). Note that 500 m=0.5 km500\text{ m} = 0.5\text{ km}. Use the ceiling function x\lceil x \rceil to account for any partial segments.
Show solution

1. Define the Step Logic

For the first 2 km2\text{ km}, the cost is fixed: if 0<d20 < d \leq 2, then C=75C = 75. For d>2d > 2, we only charge for the distance exceeding 2 km2\text{ km}, which is d2d - 2.

2. Formulate the Piecewise Function

The number of 0.5 km0.5\text{ km} segments is calculated using the ceiling function d20.5\lceil \frac{d-2}{0.5} \rceil. The complete function is:
C(d)={75,0<d275+5d20.5,d>2C(d) = \begin{cases} 75, & 0 < d \leq 2 \\ 75 + 5 \lceil \frac{d-2}{0.5} \rceil, & d > 2 \end{cases}
Practice 02Medium
If a function f(x)f(x) is defined by an algebraic expression but the domain is not specified, how do we find it?
Need a hint?
Think about where the expression is mathematically 'meaningful'.
Show solution

1. The Natural Domain

The domain is the set of all real xx values for which the expression is defined. Common restrictions: denominators cannot be zero, and values under an even root must be non-negative.
Common Pitfalls
  • Range vs. CodomainThe codomain is the 'target' set (usually ℝ), while the range is the set of values the function *actually* hits. They are not always the same!

Finding Domain and Range

The domain of a real-valued function f(x) is the set of all x for which the expression is mathematically defined and results in a real number.

Core Theorem
Key Restrictions:
1. Even Roots: Inside must be
0≥0 .
2. Denominators: Must be
0≠ 0.
3. Logarithms: Inside must be
>0> 0.
4. Trig: Specific domains for
tan(x),sec(x)tan(x),sec(x), etc.

Worked Examples

Read these first — the full solution is shown, with the reasoning behind each move.

Worked Example 01Medium
Find the domain and range of f(x)=2+xx2f(x) = \sqrt{2 + x - x^2}.
How to think about it

Key idea: The expression inside the square root must be greater than or equal to zero, and the square root function itself always yields a non-negative result.

Full solution

1. Domain Calculation

Solve 2+xx202 + x - x^2 \ge 0. Multiplying by 1-1 gives x2x20x^2 - x - 2 \le 0. Factoring the quadratic: (x2)(x+1)0(x-2)(x+1) \le 0. The domain is [1,2][-1, 2].

2. Range Calculation

The expression g(x)=x2+x+2g(x) = -x^2 + x + 2 is a downward parabola. Its maximum occurs at x=b2a=12x = -\frac{b}{2a} = \frac{1}{2}. The maximum value is g(0.5)=2.25=94g(0.5) = 2.25 = \frac{9}{4}. Since the minimum value of g(x)g(x) within the domain is 00, the range of f(x)=g(x)f(x) = \sqrt{g(x)} is [0,94]=[0,1.5][0, \sqrt{\frac{9}{4}}] = [0, 1.5].
Step-by-Step SOP
  1. 1

    System of Inequalities

    If a function is a sum of multiple parts, find the domain of each part separately and then find the intersection (common values) of all sets.

Practice — Your Turn

Try each one before opening the hint or the solution.

Practice 01Hard
Find the domain of f(x)=x21+14x2f(x) = \sqrt{x^2 - 1} + \frac{1}{\sqrt{4 - x^2}}.
Need a hint?
The domain must satisfy all conditions simultaneously: expressions inside square roots must be 0\ge 0, and denominators cannot be 00.
Show solution

1. Analyze the First Term

For x21\sqrt{x^2 - 1}, we require x210    x21x^2 - 1 \ge 0 \implies x^2 \ge 1. Taking the square root gives x1|x| \ge 1, which means x(,1][1,)x \in (-\infty, -1] \cup [1, \infty).

2. Analyze the Second Term

For 14x2\frac{1}{\sqrt{4 - x^2}}, the expression inside the root must be positive and non-zero: 4x2>0    x2<44 - x^2 > 0 \implies x^2 < 4. This gives x<2|x| < 2, which means x(2,2)x \in (-2, 2).

3. Find the Intersection

The domain is the intersection of both conditions: x(x1 or x1) and (2<x<2){x \mid (x \le -1 \text{ or } x \ge 1) \text{ and } (-2 < x < 2)}. This results in (2,1][1,2)(-2, -1] \cup [1, 2).
Practice 02Hard
Find the domain of f(x)=sinxf(x) = \sqrt{\sin\sqrt{x}}.
Need a hint?
Work from the innermost function to the outermost. Consider the periodicity of the sine function.
Show solution

1. Inner Root Condition

For the innermost square root x\sqrt{x} to be defined, the radicand must be non-negative: x0x \ge 0.

2. Outer Root and Trigonometric Logic

For the outer square root to be defined, we need sinx0\sin\sqrt{x} \ge 0. The sine function sinθ\sin \theta is non-negative when its argument θ\theta falls in the intervals [2kπ,(2k+1)π][2k\pi, (2k+1)\pi] for any integer kk.

3. Combine and Solve for x

Since we already know x0\sqrt{x} \ge 0, we only consider k=0,1,2,k = 0, 1, 2, \dots. The condition becomes 2kπx(2k+1)π2k\pi \le \sqrt{x} \le (2k+1)\pi. Squaring all sides gives the domain: (2kπ)2x((2k+1)π)2(2k\pi)^2 \le x \le ((2k+1)\pi)^2 for k{0,1,2,}k \in \{0, 1, 2, \dots\}.
Common Pitfalls
  • The Denominator vs. Root TrapWhen a square root is in the denominator, remember that the inner value must be strictly GREATER than zero (>0>0), not 0\ge 0.

One-to-One and Onto Functions

We classify functions based on how they map elements between the domain and the codomain.

Core Theorem
1. One-to-One (Injective): If x1x2x_1 \neq x_2, then f(x1)f(x2)f(x_1) \neq f(x_2).
2. Onto (Surjective): If the Range equals the Codomain (
f(A)=Bf(A) = B).

Worked Examples

Read these first — the full solution is shown, with the reasoning behind each move.

Worked Example 01Medium
Prove y=x3y = x^3 is one-to-one using algebraic factorization.
How to think about it

Key idea: Use the difference of cubes formula: a3b3=(ab)(a2+ab+b2)a^3 - b^3 = (a-b)(a^2 + ab + b^2).

Full solution

1. Factorization

Assume x13=x23x_1^3 = x_2^3. Moving terms to one side: x13x23=0x_1^3 - x_2^3 = 0. By factoring, we get (x1x2)(x12+x1x2+x22)=0(x_1 - x_2)(x_1^2 + x_1x_2 + x_2^2) = 0.

2. Analyzing the Quadratic Factor

For the second factor, we use 'completing the square': x12+x1x2+x22=(x1+12x2)2+34x22x_1^2 + x_1x_2 + x_2^2 = (x_1 + \frac{1}{2}x_2)^2 + \frac{3}{4}x_2^2. This expression is only zero if x1=0x_1 = 0 and x2=0x_2 = 0.

3. Conclusion

Otherwise, we must have x1x2=0x_1 - x_2 = 0, which means x1=x2x_1 = x_2. Thus, the function is one-to-one.
Step-by-Step SOP
  1. 1

    Horizontal Line Test

    Use this to visually check if a function is one-to-one (the line should hit the graph at most once).

Operations and Composition of Functions

Functions can be combined using arithmetic operations or by nesting one within another (composition). A critical aspect is determining the resulting domain.

Core Theorem
1. Arithmetic Operations:
-
(f±g)(x)=f(x)±g(x)(f \pm g)(x) = f(x) \pm g(x), Domain: Dom(f)Dom(g)Dom(f) \cap Dom(g)
-
(fg)(x)=f(x)g(x)(f \cdot g)(x) = f(x)g(x), Domain: Dom(f)Dom(g)Dom(f) \cap Dom(g)
-
(fg)(x)=f(x)g(x)(\frac{f}{g})(x) = \frac{f(x)}{g(x)}, Domain: Dom(f)Dom(g){xg(x)0}Dom(f) \cap Dom(g) \cap \{x \mid g(x) \neq 0\}

2. Composition:
-
(fg)(x)=f(g(x))(f \circ g)(x) = f(g(x)), Domain: \{x \in Dom(g) \mid g(x) \in Dom(f)\}

Worked Examples

Read these first — the full solution is shown, with the reasoning behind each move.

Worked Example 01Medium
Why is the domain of h(x)=x1xh(x) = x \cdot \frac{1}{x} not all real numbers?
Find the domain of
f(x)=x+11+1x+1f(x) = \frac{x+1}{1+\frac{1}{x+1}}.
How to think about it

Key idea: The domain is determined by the *original* expression before simplification.

Full solution

1. Simplification Trap

For h(x)=x1xh(x) = x \cdot \frac{1}{x}, even though it simplifies to 11 for x0x \neq 0, the original term 1x\frac{1}{x} is undefined at x=0x=0. Thus, Dom(h)=R{0}Dom(h) = \mathbb{R} - \{0\}.

2. Nested Fractions

For f(x)f(x), we must ensure:
1)
x+10    x1x+1 \neq 0 \implies x \neq -1.
2) The entire denominator
1+1x+101+\frac{1}{x+1} \neq 0.
Solving
1+1x+1=0    1x+1=1    x+1=1    x=21+\frac{1}{x+1} = 0 \implies \frac{1}{x+1} = -1 \implies x+1 = -1 \implies x = -2.
Domain:
R{1,2}\mathbb{R} - \{-1, -2\}.
Worked Example 02Easy
Decompose F(x)=cos2(x+9)F(x) = \cos^2(x+9) into F=fghF = f \circ g \circ h.
How to think about it

Key idea: Identify the 'inner', 'middle', and 'outer' layers of the operation.

Full solution

1. Layer Identification

Inner layer: h(x)=x+9h(x) = x+9. Middle layer: g(x)=cos(x)g(x) = \cos(x). Outer layer: f(x)=x2f(x) = x^2. Then f(g(h(x)))=(cos(x+9))2=cos2(x+9)f(g(h(x))) = (\cos(x+9))^2 = \cos^2(x+9).

Practice — Your Turn

Try each one before opening the hint or the solution.

Practice 01Medium
Given f0(x)=xx+1f_0(x) = \frac{x}{x+1} and fn+1=f0fnf_{n+1} = f_0 \circ f_n, find a general formula for fn(x)f_n(x).
Need a hint?
Compute the first few terms (f1,f2f_1, f_2) and look for a pattern.
Show solution

1. Pattern Recognition

f1(x)=f0(f0(x))=xx+1xx+1+1=xx+(x+1)=x2x+1f_1(x) = f_0(f_0(x)) = \frac{\frac{x}{x+1}}{\frac{x}{x+1} + 1} = \frac{x}{x + (x+1)} = \frac{x}{2x+1}.

2. Inductive Step

f2(x)=f0(f1(x))=x2x+1x2x+1+1=xx+(2x+1)=x3x+1f_2(x) = f_0(f_1(x)) = \frac{\frac{x}{2x+1}}{\frac{x}{2x+1} + 1} = \frac{x}{x + (2x+1)} = \frac{x}{3x+1}.
By observation,
fn(x)=x(n+1)x+1f_n(x) = \frac{x}{(n+1)x + 1}.
Practice 02Medium
Given g(x)=2x+1g(x) = 2x+1 and (fg)(x)=4x2+4x+7(f \circ g)(x) = 4x^2 + 4x + 7, find f(x)f(x).
Need a hint?
Use substitution: let u=g(x)u = g(x).
Show solution

1. Variable Substitution

Let u=2x+1u = 2x + 1, which means x=u12x = \frac{u-1}{2}.

2. Solve for f(u)

f(u)=4(u12)2+4(u12)+7=(u1)2+2(u1)+7=u22u+1+2u2+7=u2+6f(u) = 4(\frac{u-1}{2})^2 + 4(\frac{u-1}{2}) + 7 = (u-1)^2 + 2(u-1) + 7 = u^2 - 2u + 1 + 2u - 2 + 7 = u^2 + 6. Thus, f(x)=x2+6f(x) = x^2 + 6.
Common Pitfalls
  • Domain of Composite FunctionsDo not just look at the final simplified form of f(g(x))f(g(x)). You must exclude any values that make g(x)g(x) undefined, even if they seem 'fine' after plugging into ff.

Symmetry and Inverse Functions

Understanding the symmetry of functions (Even/Odd) and the conditions for the existence of inverses is fundamental for sketching graphs and solving equations in Calculus.

Core Theorem
1. Parity (Even/Odd):
- Even Function:
f(x)=f(x)f(-x) = f(x), symmetric about the yy-axis.
- Odd Function:
f(x)=f(x)f(-x) = -f(x), symmetric about the origin.

2. Inverse Functions (
f1f^{-1}):
- Exists if
ff is one-to-one.
-
f1(y)=x    f(x)=yf^{-1}(y) = x \iff f(x) = y.
- The domain of
f1f^{-1} is the range of ff, and vice versa.
- Graphs of
ff and f1f^{-1} are reflections across the line y=xy = x.

Worked Examples

Read these first — the full solution is shown, with the reasoning behind each move.

Worked Example 01Easy
If g(x)g(x) is an odd function, what can we conclude about g(0)g(0)? What if g(x)g(x) is an even function?
How to think about it

Key idea: Plug x=0x = 0 into the definitions g(x)=g(x)g(-x) = -g(x) and g(x)=g(x)g(-x) = g(x).

Full solution

1. Odd Function Case

g(0)=g(0)    g(0)=g(0)    2g(0)=0g(-0) = -g(0) \implies g(0) = -g(0) \implies 2g(0) = 0. Therefore, if 0Dom(g)0 \in Dom(g), then g(0)=0g(0) = 0.

2. Even Function Case

g(0)=g(0)impliesg(0)=g(0)g(-0) = g(0) implies g(0) = g(0). This is always true, so g(0)g(0) can be any value in the range.
Worked Example 02Medium
Determine the parity of f(x)=xxf(x) = x|x|.
How to think about it

Key idea: Test f(x)f(-x) and see if it equals f(x)f(x) or f(x)-f(x).

Full solution

1. Substitution

f(x)=(x)xf(-x) = (-x)|-x|.

2. Simplification

Since x=x|-x| = |x|, we have f(x)=xx=f(x)f(-x) = -x|x| = -f(x).

3. Conclusion

Since f(x)=f(x)f(-x) = -f(x), the function is an odd function.
Step-by-Step SOP
  1. 1

    Determining Parity

    Always start by replacing xx with (x)(-x) in the original expression and simplify.
  2. 2

    Finding Inverse Algebraically

    1. Set y=f(x)y = f(x). 2. Exchange xx and yy. 3. Solve for yy. 4. Replace yy with f1(x)f^{-1}(x).

Practice — Your Turn

Try each one before opening the hint or the solution.

Practice 01Medium
Find the inverse of f(x)=x3+2f(x) = x^3 + 2.
Need a hint?
Swap xx and yy, then solve for the new yy.
Show solution

1. Swap Variables

Let x=y3+2x = y^3 + 2.

2. Isolate y

y3=x2    y=x23y^3 = x - 2 \implies y = \sqrt[3]{x-2}.

3. Result

f1(x)=x23f^{-1}(x) = \sqrt[3]{x-2}.
Practice 02Hard
Under what condition does sin(x)sin(x) have an inverse?
Need a hint?
A function must be one-to-one to have an inverse.
Show solution

1. Analyze Domain

On [0,π][0, \pi], sin(x)\sin(x) is not one-to-one (e.g., sin(π/6)=sin(5π/6)\sin(\pi/6) = \sin(5\pi/6)).

2. Restrict Domain

On [π/2,π/2][-\pi/2, \pi/2], sin(x)\sin(x) is strictly increasing and therefore one-to-one.

3. Define Inverse

We can define sin1:[1,1][π/2,π/2]\sin^{-1}: [-1, 1] \to [-\pi/2, \pi/2].
Common Pitfalls
  • Inverse Notation Confusionf1(x)f^{-1}(x) is NOT the same as 1f(x)\frac{1}{f(x)}. The former is the inverse function, while the latter is the reciprocal.
  • Parity is not BinaryA function can be neither even nor odd (e.g., f(x)=x33x2f(x) = x^3 - 3x^2). Don't assume every function must fall into one of these categories.
Gary Chang

Gary Chang

Calculus Educator

5+ Years of Calculus Teaching Experience | AP Calculus Specialist. Dedicated to helping students master calculus through step-by-step logic and clear visualizations.