Back to homeMathematics · AP Calculus AB · Change subject
Start for free
AP Calc AB · Mathematics
Limits and Continuity · Revision

Functions of a Real Variable and Types of Functions

Before you start, make sure you know: Inequalities (Algebra 2)
Before you start, make sure you know: Composite functions (Algebra 2)

Your calculator happily computes $\sqrt{4}$ but throws an ERROR on $\sqrt{-4}$ and on $\ln(0)$. Every limit problem in AP Calculus starts with a function, and before you ask "what happens near $x = a$?" you have to know where the function is even defined, what family it belongs to, and how functions combine. This page reviews all of that, so you can tell in advance which inputs are allowed.

Types of functions and domain

The domain of a function is the set of all inputs $x$ for which the formula gives a real number. The range is the set of all outputs. Unless a problem says otherwise, the domain is the widest set of real numbers for which the formula makes sense.

The curve $\sqrt{3x + 12}$ starts at $x = -4$ and the curve $\ln(x - 1)$ only exists to the right of $x = 1$. Each curve stops exactly where its restriction says it must.

When a function has several restrictions at once (a log, a fraction and a root), every condition must hold at the same time. You intersect the solution sets.

A sum of squares such as $x^2 + k^2$ with $k \ne 0$ is always positive, so a denominator like that never causes trouble.

Functions are also classified by how they are built. A function like $\sqrt[3]{x - 4}$ is radical (and, because the index is odd, defined for every real $x$). A function like $\log_{10}(x^2)$ is logarithmic, and its domain is $x \ne 0$, not $\mathbb{R}$.

Practice★★★Not started
Classify the following functions according to their type (polynomial, rational, radical, exponential or logarithmic): a) $f(x) = 3^x - 1$ b)…

Classify the following functions according to their type (polynomial, rational, radical, exponential or logarithmic):

  1. a) $f(x) = 3^x - 1$
  1. b) $g(x) = \frac{x^2 + 1}{x - 2}$
  1. c) $h(x) = \log_{10}(x^2)$
  1. d) $i(x) = x^3 - 5x + 2$
  1. e) $j(x) = \sqrt[3]{x - 4}$
Solve
Practice★★★Not started
Determine the domain of definition of the following functions of a real variable based on the restrictions of the operations that form them: a)…

Determine the domain of definition of the following functions of a real variable based on the restrictions of the operations that form them:

  1. a) $f(x) = \frac{2x - 5}{x^2 - 9}$
  1. b) $g(x) = \sqrt{3x + 12}$
  1. c) $h(x) = \ln(x - 1)$
Solve
Practice★★★Not started
Find the widest possible domain of definition for the following real function of a real variable, expressing the result as a union of intervals: $$f(x) =…

Find the widest possible domain of definition for the following real function of a real variable, expressing the result as a union of intervals:

$$f(x) = \sqrt{\frac{\ln(x^2 - 8)}{|x| - 4}}$$

To solve it, you must simultaneously consider the restrictions imposed by the square root, the natural logarithm and the denominator of the fraction.

Solve

Piecewise and absolute value functions

An online store charges $\$5$ to ship any package up to $2$ lb. Heavier packages cost a flat $\$3$ plus $\$1.50$ per pound. One formula can't describe both rules, so we use two.

$$S(w) = \begin{cases} 5 & 0 < w \le 2 \\ 1.5w + 3 & w > 2 \end{cases}$$

At $w = 2$ the left piece gives $\$5$ but the right piece gives $1.5(2) + 3 = \$6$. The graph jumps up by $\$1$.

To test continuity at the break point $c$, compare three numbers: the value from the left piece, the value from the right piece, and $f(c)$.

Absolute value is a piecewise function in disguise: $|u| = u$ if $u \ge 0$ and $|u| = -u$ if $u < 0$. To rewrite $|\text{expression}|$ as a piecewise function, find where the inside equals $0$. That is the break point.

Practice★★★Not started
Given the absolute value function $f(x) = |x - 3|$, represent it as a piecewise function and calculate its value for $x = 0$ and $x = 5$.

Given the absolute value function $f(x) = |x - 3|$, represent it as a piecewise function and calculate its value for $x = 0$ and $x = 5$.

Solve
Practice★★★Not started
A telephone company offers a data plan where the first $10$ GB cost a fixed $\$15$. From then on, each extra GB is charged at $\$2$. The function representing the total…

A telephone company offers a data plan where the first $10$ GB cost a fixed $\$15$. From then on, each extra GB is charged at $\$2$. The function representing the total cost $C(x)$ in terms of the GB consumed $x$ is:

$C(x) = \begin{cases} 15 & \text{if } 0 \le x \le 10 \\ 15 + 2(x - 10) & \text{if } x > 10 \end{cases}$

Study whether the function is continuous at the critical point $x = 10$.

Solve
Practice★★★Not started
A new video game streaming service applies a monthly rate based on high-speed data consumption. The first $20$ GB are included in a fixed fee of $\$15…

A new video game streaming service applies a monthly rate based on high-speed data consumption. The first $20$ GB are included in a fixed fee of $\$15$. From then on, the price for each additional GB increases linearly according to the function $P(x) = 15 + 0,5(x - 20)$, where $x$ is the total number of GB consumed.

However, if the user exceeds $100$ GB, the company applies a penalty for excess traffic and the function becomes $P(x) = 0,1x^2 - 45$.

Write the analytical expression of the total cost function $C(x)$ as a piecewise function and check if the price "jumps" or is continuous exactly at the moment of consuming $100$ GB.

Solve

Operations and composition

For instance, if $f(x) = \sqrt{x}$ and $g(x) = x - 4$, then $\left(\dfrac{f}{g}\right)(x) = \dfrac{\sqrt{x}}{x - 4}$ has domain $x \ge 0$ with $x \ne 4$, that is, $[0, 4) \cup (4, \infty)$.

Block diagram of the composition f of g of x: the input x goes into g, producing g of x, which becomes the input of f, producing f of g of x. x g g(x) g(x) f f(g(x)) (f∘g)(x) = f(g(x)): first g, then f

To find the range of a composite or a messy formula, rewrite it in terms of the inner expression. For example, let $u \ge 0$ and $F(u) = \dfrac{u+1}{u+2} = 1 - \dfrac{1}{u+2}$. Since $u + 2 \ge 2$, we get $0 < \dfrac{1}{u+2} \le \dfrac12$. So $F$ takes values in $\left[\dfrac12, 1\right)$ and never reaches $1$.

Practice★★★Not started
Given the functions $f(x) = x + 3$ and $g(x) = x^2 - 1$, perform the following operations and determine the domain of the resulting function: a) $(f + g)(x)$ b)…

Given the functions $f(x) = x + 3$ and $g(x) = x^2 - 1$, perform the following operations and determine the domain of the resulting function:

  1. a) $(f + g)(x)$
  1. b) $(f \cdot g)(x)$
  1. c) $(\frac{f}{g})(x)$
Solve
Practice★★★Not started
Consider the functions $f(x) = \sqrt{x + 2}$ and $g(x) = \frac{1}{x^2 - 1}$. 1. Find the expression of the composite function $(g \circ f)(x)$. 2. Determine the domain…

Consider the functions $f(x) = \sqrt{x + 2}$ and $g(x) = \frac{1}{x^2 - 1}$.

  1. Find the expression of the composite function $(g \circ f)(x)$.

  2. Determine the domain of $(g \circ f)(x)$.

  3. Does this domain coincide with that of the function $h(x) = \frac{1}{x+1}$? Justify your answer.

Solve
Practice★★★Not started
An aerospace engineering company is designing the ascent trajectory of a probe. The height $h$ in miles, measured from a reference level (negative below it), with…

An aerospace engineering company is designing the ascent trajectory of a probe. The height $h$ in miles, measured from a reference level (negative below it), with respect to time $t$ in minutes is given by a composite function. It is known that the outer function is $f(x) = \frac{x-2}{x+3}$ and the inner function is $g(t) = \sqrt{t^2 - 1}$.

Calculate the analytical expression of the total height function $H(t) = (f \circ g)(t)$ and determine its domain and range with reasoning in the physical context of the problem, knowing that the probe begins its mission at $t = 1$.

Solve

Inverse functions

A function is one-to-one if different inputs always give different outputs. Graphically, every horizontal line crosses the graph at most once (the horizontal line test). Algebraically: if $f(a) = f(b)$, then you can show $a = b$.

Only one-to-one functions have an inverse. The inverse $f^{-1}$ undoes $f$: $f^{-1}(f(x)) = x$.

Exponential expressions are always positive, and that is what limits the range. For an S-shaped (logistic) function like $\dfrac{10}{1 + e^{-0.5x}}$, the positive quantity $e^{-0.5x}$ squeezes the outputs between two horizontal lines. Those bounds are the domain of the inverse.

Practice★★★Not started
Find the inverse function $f^{-1}(x)$ of the function $f(x) = \frac{e^x + 3}{2}$. State the domain and range of both functions and graphically verify their symmetry with…

Find the inverse function $f^{-1}(x)$ of the function $f(x) = \frac{e^x + 3}{2}$. State the domain and range of both functions and graphically verify their symmetry with respect to the line $y = x$.

Solve
Practice★★★Not started
An artificial intelligence algorithm processes input data $x$ using a modified logistic activation function: $$A(x) = \frac{10}{1 + e^{-0.5x}}$$ We want to find the…

An artificial intelligence algorithm processes input data $x$ using a modified logistic activation function:

$$A(x) = \frac{10}{1 + e^{-0.5x}}$$

We want to find the inverse function $A^{-1}(x)$ so that the system can perform the reverse process (decoding). Find this inverse and determine for which values of the output $y$ decoding is possible (range of the original function).

x y 0 −10 10 10 (0, 5) (5, 0) y = 10 x = 10 y = x A(x) A⁻¹(x) Range y ∈ (0, 10) Domain x ∈ (0, 10)
Solve
Practice★★★Not started
Let the function be $f(x) = \frac{3^x - 1}{3^x + 1}$. Prove analytically that the function is one-to-one in its entire domain. Then, find the expression of its inverse…

Let the function be $f(x) = \frac{3^x - 1}{3^x + 1}$. Prove analytically that the function is one-to-one in its entire domain. Then, find the expression of its inverse function $f^{-1}(x)$ and clearly specify the domain and range of this inverse.

y = x x y 0 1 −1 1 −1 f(x) f⁻¹(x) y = 1 y = −1 x = 1 x = −1
Solve

Even and odd functions

For $f(x) = 3x^2 + 5x$: $f(-x) = 3x^2 - 5x$, so the even part is $\dfrac{6x^2}{2} = 3x^2$ and the odd part is $\dfrac{10x}{2} = 5x$.

Practice★★★Not started
Study the symmetry (even, odd or asymmetrical) of the following functions, justifying the steps by calculating $f(-x)$: 1. $f(x) = \frac{x^3}{x^2 + 1}$ 2.…

Study the symmetry (even, odd or asymmetrical) of the following functions, justifying the steps by calculating $f(-x)$:

  1. $f(x) = \frac{x^3}{x^2 + 1}$

  2. $g(x) = x \cdot \cos(x)$

  3. $h(x) = \frac{e^x + e^{-x}}{2}$ (Hyperbolic cosine function)

Symmetry Study What is the relationship between f(x) and f(-x)? x -x h(x) h(-x) = ? h(x) = (ex+ e-x)/2 x -x f(x) f(-x) = ? f(x) = x3/ (x2 + 1)
Solve
Practice★★★Not started
Consider the family of functions $f_k(x) = \frac{x^2 - k^2}{x^2 + k^2}$ where $k \in \mathbb{R}, k \neq 0$. 1. Prove that for any value of $k$, the function is even. 2.…

Consider the family of functions $f_k(x) = \frac{x^2 - k^2}{x^2 + k^2}$ where $k \in \mathbb{R}, k \neq 0$.

  1. Prove that for any value of $k$, the function is even.

  2. Find the points of intersection with the axes in terms of $k$.

  3. Find the value of $k$ so that the function takes the value $y = 1/2$ when $x = 3$.

  4. Discuss whether there is any value of $k$ for which the function has vertical asymptotes.

Solve
Practice★★★Not started
Every function $f(x)$ can be uniquely decomposed, at the points $x$ where both $f(x)$ and $f(-x)$ exist, as the sum of an even function $g(x)$ and an odd function…

Every function $f(x)$ can be uniquely decomposed, at the points $x$ where both $f(x)$ and $f(-x)$ exist, as the sum of an even function $g(x)$ and an odd function $h(x)$, such that:

$$g(x) = \frac{f(x) + f(-x)}{2} \quad \text{and} \quad h(x) = \frac{f(x) - f(-x)}{2}$$

Given the function $f(x) = \frac{x+2}{x-1}$, find its even and odd components. Prove analytically that, indeed, $g(x)$ is an even function and $h(x)$ is an odd function. What are the domains of each of these three functions?

f(x) = g(x) + h(x) f(x) = x + 2 x - 1 Dom(f) = ? g(x) = ½[f(x) + f(-x)] g(x) = ? Even Dom(g) = ? h(x) = ½[f(x) - f(-x)] h(x) = ? Odd Dom(h) = ?
Solve

Graph transformations

You can build the graph of a complicated function from a basic one, like $x^2$, $\sqrt{x}$, $e^x$ or $\ln x$, one change at a time.

Move the sliders: the second curve is the absolute value of the first, so wherever the parabola dips below the $x$-axis, the other curve bounces back up.

Some problems call the absolute value the modulus. It is the same operation.

Practice★★★Not started
In the study of sound signals, the function $s(t) = \ln(t)$ is used to represent the intensity of a primary signal. Due to interference, the resulting signal is…

In the study of sound signals, the function $s(t) = \ln(t)$ is used to represent the intensity of a primary signal. Due to interference, the resulting signal is transformed according to the rule $g(t) = |s(|t-2|)-1|$.

Graphically represent the final function $g(t)$ starting from the elementary function $\ln(t)$ and explaining in detail each of the geometric transformations (translations, reflections and moduli) that take place.

Solve

Reading graphs, asymptotes and direct substitution

One-sided values

The notation $\lim_{x \to 2^-} f(x)$ means "the value $f(x)$ is heading toward as $x$ approaches $2$ from the left" and $\lim_{x \to 2^+} f(x)$ is the same from the right. These are separate from $f(2)$, the actual output at $x = 2$ (some problems call it the image of $2$). An open circle shows a point the graph approaches but doesn't include, and a filled dot shows the real value.

Graph with a jump at x = 2: the left piece approaches height 1, the right piece starts near height 3, and the filled point (2, 2) is the actual function value. 1 2 3 2 x y left side → 1 right side → 3 f(2) = 2

Here the left-hand value is $1$, the right-hand value is $3$, and $f(2) = 2$. All three are different, so the graph has a jump at $x = 2$. If the two one-sided values were equal but the dot were missing or elsewhere, the discontinuity would be removable (a hole).

Asymptotes from a graph

A vertical asymptote $x = a$ is a vertical line that the graph hugs as $f(x)$ grows without bound near $x = a$. A horizontal asymptote $y = L$ is a horizontal line the graph approaches as $x$ goes far to the right or left.

For $f(x) = \dfrac{2x}{x - 1}$ the graph shoots off near $x = 1$ (the denominator is $0$ and the numerator isn't), so $x = 1$ is a vertical asymptote. Far to the left and right the curve levels off at $y = 2$, the horizontal asymptote. On a graph, read vertical asymptotes from where the curve disappears up or down, and horizontal ones from the height where it flattens out.

Direct substitution

If a function is defined at $x = a$ and is a polynomial, rational (with nonzero denominator), exponential, or a root or log with a valid input, you can find $\lim_{x \to a} f(x)$ simply by computing $f(a)$.

Practice★★★Not started
From the following graph of the function $f(x)$, identify the values of the one-sided limits and the image of the function at the point of discontinuity $x = 1$: a)…

From the following graph of the function $f(x)$, identify the values of the one-sided limits and the image of the function at the point of discontinuity $x = 1$:

  1. a) $\lim_{x \to 1^-} f(x)$
  1. b) $\lim_{x \to 1^+} f(x)$
  1. c) $f(1)$
−1 0 1 2 3 4 5 −1 2 4 1 3 x y f(x) f(1) x→1⁻ x→1⁺
Solve
Practice★★★Not started
Observe the following graph and visually identify the equations of its vertical and horizontal asymptotes:

Observe the following graph and visually identify the equations of its vertical and horizontal asymptotes:

0 1 2 3 4 5 1 2 3 4 −1 x y V.A. H.A.
Solve
Practice★★★Not started
Calculate the following direct limits by substitution, checking if the value obtained is finite: a) $\lim_{x \to 2} (x^2 - 3x + 1)$ b)…

Calculate the following direct limits by substitution, checking if the value obtained is finite:

  1. a) $\lim_{x \to 2} (x^2 - 3x + 1)$
  1. b) $\lim_{x \to 0} \frac{e^x + 1}{x + 3}$
  1. c) $\lim_{x \to -1} \sqrt{x + 5}$
Solve

Putting it together: rational functions, parameters and models

Rational functions: holes, asymptotes, intercepts

Factor numerator and denominator. A factor that cancels gives a hole (removable discontinuity). A factor that stays in the denominator gives a vertical asymptote. For intercepts, set $y = 0$ (the numerator) for $x$-intercepts, and compute $f(0)$ for the $y$-intercept.

Finding parameters

Each condition on the function gives one equation. "The graph passes through $(x_0, y_0)$" means plug in: $f(x_0) = y_0$. "The function is continuous at $c$" means the one-sided values must be equal.

When a piecewise function is defined on an interval like $[1, \infty)$ that is not symmetric about $0$, remember that even and odd don't apply.

Quadratic models and physical context

For $y = ax^2 + bx + c$ the vertex is at $x = -\dfrac{b}{2a}$. If $a < 0$ the vertex is the maximum. When a formula models a real situation, the domain must also make sense physically.

Practice★★★Not started
Given the rational function $f(x) = \frac{2x^2 - 8}{x^2 - x - 2}$: 1. Calculate its domain. 2. Identify if there is any point where the function has a "removable…

Given the rational function $f(x) = \frac{2x^2 - 8}{x^2 - x - 2}$:

  1. Calculate its domain.

  2. Identify if there is any point where the function has a "removable discontinuity" (a point where the numerator and denominator are simultaneously zero).

  3. Calculate the points of intersection with the coordinate axes.

Solve
Practice★★★Not started
A surveillance drone carries out a test flight following a trajectory whose height in feet with respect to time in seconds is given by the function: $$H(t) = -t^2 + 20t…

A surveillance drone carries out a test flight following a trajectory whose height in feet with respect to time in seconds is given by the function:

$$H(t) = -t^2 + 20t + 5$$
  1. From what height does the drone take off?

  2. What is the maximum height it reaches and in which second does this occur?

  3. If the drone must land when its battery reaches $5\%$ (which happens at $21$ seconds), at what height will it be at that moment? Explain whether the result makes physical sense.

Collision zone (H < 0) 5 10 15 20 25 120 100 80 60 40 20 −20 Time t (s) Height H (ft) H(t) = -t² + 20t + 5 Take-off: H(0) = 5 ft Max height (10 s, 105 ft) t = 21 s, H = −16 ft
Solve
Practice★★★Not started
Given the piecewise function: $$f(x) = \begin{cases} \frac{ax + b}{x - 2} & \text{if } x < 1 \\ \sqrt{x^2 + 3} & \text{if } x \ge 1 \end{cases}$$ Find the values of the…

Given the piecewise function:

$$f(x) = \begin{cases} \frac{ax + b}{x - 2} & \text{if } x < 1 \\ \sqrt{x^2 + 3} & \text{if } x \ge 1 \end{cases}$$

Find the values of the real parameters $a$ and $b$ knowing that the function passes through the point $(-2, 0)$ and has a removable discontinuity at the point with x-coordinate $x = 1$. Once found, study the symmetry of the function in the interval $[1, +\infty)$.

Solve

Summary

Back to the start: the ERROR on $\sqrt{-4}$ and $\ln 0$ happens because an even root needs a radicand $\ge 0$ and a logarithm needs an input $> 0$. Checking those restrictions before you plug in tells you which inputs are allowed.

See all the exercises in this section