Graphing Functions and Relations
Overview
Graphing a function involves plotting its input-output pairs on a coordinate plane. The graph visually represents the relationship between variables in the function. Understanding how to graph different functions and relations helps us to visualize mathematical concepts and interpret their behavior.
Graphing Linear Functions
Linear functions have the form \( f(x) = mx + b \), where \( m \) is the slope, and \( b \) is the y-intercept. To graph a linear function:
- Start by plotting the y-intercept, \( b \), on the y-axis.
- Use the slope, \( m \), to determine the rise over run (change in y over change in x). From the y-intercept, move according to the slope to plot the second point.
- Draw a straight line through the two points.
Graphing Quadratic Functions
Quadratic functions have the form \( f(x) = ax^2 + bx + c \), and their graphs are parabolas. To graph a quadratic function:
- Find the vertex, which is the minimum or maximum point of the parabola. The vertex occurs at \( x = \frac{-b}{2a} \).
- Plot the vertex on the graph.
- Choose a few values of \( x \) near the vertex to find corresponding \( y \)-values and plot additional points.
- Sketch the parabola, ensuring it opens upwards (if \( a > 0 \)) or downwards (if \( a < 0 \)).
Graphing Other Functions
Other functions, such as cubic, exponential, and logarithmic, each have distinct shapes:
- Cubic functions have the form \( f(x) = ax^3 + bx^2 + cx + d \) and often have one or two turning points.
- Exponential functions of the form \( f(x) = a^x \) have rapid growth or decay, depending on whether \( a > 1 \) or \( 0 < a < 1 \).
- Logarithmic functions of the form \( f(x) = \log_a(x) \) have a vertical asymptote at \( x = 0 \) and increase slowly for large values of \( x \).
Practice Questions
- Graph the linear function \( f(x) = 2x + 3 \).
Solution
Start by plotting the y-intercept at \( (0, 3) \). Then, use the slope \( m = 2 \), which means you move up 2 units and right 1 unit to plot the next point at \( (1, 5) \). Draw a line through these points.
- Graph the quadratic function \( f(x) = x^2 - 4x + 3 \).
Solution
The vertex occurs at \( x = \frac{-(-4)}{2(1)} = 2 \). Calculate \( f(2) = 2^2 - 4(2) + 3 = -1 \). Plot the vertex at \( (2, -1) \) and plot a few other points like \( f(1) = 0 \), \( f(3) = 0 \), and sketch the parabola opening upwards.
- Graph the cubic function \( f(x) = x^3 - 2x^2 \).
Solution
Find the critical points by setting the derivative equal to zero. In this case, the graph has turning points at \( x = 0 \) and \( x = 2 \). Plot points for several values of \( x \), such as \( f(-2) = -4 \), \( f(0) = 0 \), and \( f(2) = -8 \), and sketch the cubic curve.
- Graph the exponential function \( f(x) = 2^x \).
Solution
Plot the point at \( (0, 1) \) because \( 2^0 = 1 \). For \( x = 1 \), \( f(1) = 2 \), and for \( x = -1 \), \( f(-1) = 0.5 \). Sketch the graph, which rapidly increases as \( x \) becomes positive.
- Graph the logarithmic function \( f(x) = \log_2(x) \).
Solution
Plot the point at \( (1, 0) \) because \( \log_2(1) = 0 \). As \( x \) approaches zero from the positive side, \( f(x) \) approaches negative infinity. Sketch the curve passing through \( (1, 0) \) and increasing slowly.
- Graph the absolute value function \( f(x) = |x-2| \).
Solution
The vertex of the absolute value function is at \( (2, 0) \). For \( x > 2 \), the function behaves like a linear function with slope 1. For \( x < 2 \), the function behaves like a linear function with slope -1. Sketch the V-shaped graph.
- Graph the function \( f(x) = \frac{1}{x} \).
Solution
The function has two vertical asymptotes at \( x = 0 \). As \( x \) approaches zero from the positive side, \( f(x) \) approaches infinity. As \( x \) approaches zero from the negative side, \( f(x) \) approaches negative infinity. Sketch the hyperbolic curve with these asymptotes.
- Graph the piecewise function \( f(x) = \begin{cases}
2x + 3 & \text{if } x \leq 1 \\
-x + 4 & \text{if } x > 1
\end{cases} \).
Solution
For \( x \leq 1 \), graph the line \( 2x + 3 \) and plot the points for values like \( (0, 3) \), \( (1, 5) \). For \( x > 1 \), graph the line \( -x + 4 \) and plot the points for values like \( (2, 2) \), \( (3, 1) \). Connect the two pieces with a discontinuity at \( x = 1 \).
- Graph the rational function \( f(x) = \frac{x+1}{x-1} \).
Solution
There is a vertical asymptote at \( x = 1 \) because the denominator is zero at this point. Plot points for values like \( x = 0 \), \( f(0) = -1 \), and sketch the graph, noting the behavior near the asymptote.