2.2: Basic Classes of Functions
- Page ID
- 149859
\( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)
\( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)
\( \newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\)
( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\)
\( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)
\( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\)
\( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)
\( \newcommand{\Span}{\mathrm{span}}\)
\( \newcommand{\id}{\mathrm{id}}\)
\( \newcommand{\Span}{\mathrm{span}}\)
\( \newcommand{\kernel}{\mathrm{null}\,}\)
\( \newcommand{\range}{\mathrm{range}\,}\)
\( \newcommand{\RealPart}{\mathrm{Re}}\)
\( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)
\( \newcommand{\Argument}{\mathrm{Arg}}\)
\( \newcommand{\norm}[1]{\| #1 \|}\)
\( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)
\( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\AA}{\unicode[.8,0]{x212B}}\)
\( \newcommand{\vectorA}[1]{\vec{#1}} % arrow\)
\( \newcommand{\vectorAt}[1]{\vec{\text{#1}}} % arrow\)
\( \newcommand{\vectorB}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)
\( \newcommand{\vectorC}[1]{\textbf{#1}} \)
\( \newcommand{\vectorD}[1]{\overrightarrow{#1}} \)
\( \newcommand{\vectorDt}[1]{\overrightarrow{\text{#1}}} \)
\( \newcommand{\vectE}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash{\mathbf {#1}}}} \)
\( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)
\( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)
\(\newcommand{\avec}{\mathbf a}\) \(\newcommand{\bvec}{\mathbf b}\) \(\newcommand{\cvec}{\mathbf c}\) \(\newcommand{\dvec}{\mathbf d}\) \(\newcommand{\dtil}{\widetilde{\mathbf d}}\) \(\newcommand{\evec}{\mathbf e}\) \(\newcommand{\fvec}{\mathbf f}\) \(\newcommand{\nvec}{\mathbf n}\) \(\newcommand{\pvec}{\mathbf p}\) \(\newcommand{\qvec}{\mathbf q}\) \(\newcommand{\svec}{\mathbf s}\) \(\newcommand{\tvec}{\mathbf t}\) \(\newcommand{\uvec}{\mathbf u}\) \(\newcommand{\vvec}{\mathbf v}\) \(\newcommand{\wvec}{\mathbf w}\) \(\newcommand{\xvec}{\mathbf x}\) \(\newcommand{\yvec}{\mathbf y}\) \(\newcommand{\zvec}{\mathbf z}\) \(\newcommand{\rvec}{\mathbf r}\) \(\newcommand{\mvec}{\mathbf m}\) \(\newcommand{\zerovec}{\mathbf 0}\) \(\newcommand{\onevec}{\mathbf 1}\) \(\newcommand{\real}{\mathbb R}\) \(\newcommand{\twovec}[2]{\left[\begin{array}{r}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\ctwovec}[2]{\left[\begin{array}{c}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\threevec}[3]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\cthreevec}[3]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\fourvec}[4]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\cfourvec}[4]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\fivevec}[5]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\cfivevec}[5]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\mattwo}[4]{\left[\begin{array}{rr}#1 \amp #2 \\ #3 \amp #4 \\ \end{array}\right]}\) \(\newcommand{\laspan}[1]{\text{Span}\{#1\}}\) \(\newcommand{\bcal}{\cal B}\) \(\newcommand{\ccal}{\cal C}\) \(\newcommand{\scal}{\cal S}\) \(\newcommand{\wcal}{\cal W}\) \(\newcommand{\ecal}{\cal E}\) \(\newcommand{\coords}[2]{\left\{#1\right\}_{#2}}\) \(\newcommand{\gray}[1]{\color{gray}{#1}}\) \(\newcommand{\lgray}[1]{\color{lightgray}{#1}}\) \(\newcommand{\rank}{\operatorname{rank}}\) \(\newcommand{\row}{\text{Row}}\) \(\newcommand{\col}{\text{Col}}\) \(\renewcommand{\row}{\text{Row}}\) \(\newcommand{\nul}{\text{Nul}}\) \(\newcommand{\var}{\text{Var}}\) \(\newcommand{\corr}{\text{corr}}\) \(\newcommand{\len}[1]{\left|#1\right|}\) \(\newcommand{\bbar}{\overline{\bvec}}\) \(\newcommand{\bhat}{\widehat{\bvec}}\) \(\newcommand{\bperp}{\bvec^\perp}\) \(\newcommand{\xhat}{\widehat{\xvec}}\) \(\newcommand{\vhat}{\widehat{\vvec}}\) \(\newcommand{\uhat}{\widehat{\uvec}}\) \(\newcommand{\what}{\widehat{\wvec}}\) \(\newcommand{\Sighat}{\widehat{\Sigma}}\) \(\newcommand{\lt}{<}\) \(\newcommand{\gt}{>}\) \(\newcommand{\amp}{&}\) \(\definecolor{fillinmathshade}{gray}{0.9}\)- Calculate the slope of a linear function and interpret its meaning.
- Recognize the degree of a polynomial.
- Find the roots of a quadratic polynomial.
- Describe the graphs of basic odd and even polynomial functions.
- Identify a rational function.
- Describe the graphs of power and root functions.
- Graph a piecewise-defined function.
- Sketch the graph of a function that has been shifted, stretched, or reflected from its initial graph position.
We have studied the general characteristics of functions, so now let’s examine some specific classes of functions. We begin by reviewing the basic properties of linear and quadratic functions, and then generalize to include higher-degree polynomials. By combining root functions with polynomials, we can define general algebraic functions and distinguish them from the transcendental functions we examine later in this chapter. We finish the section with examples of piecewise-defined functions and take a look at how to sketch the graph of a function that has been shifted, stretched, or reflected from its initial form.
Linear Functions and Slope
The easiest type of function to consider is a linear function. Linear functions have the form \(f(x)=ax+b\), where \(a\) and \(b\) are constants. In Figure \(\PageIndex{1}\), we see examples of linear functions when a is positive, negative, and zero. Note that if \(a>0\), the graph of the line rises as \(x\) increases. In other words, \(f(x)=ax+b\) is increasing on \((−∞, ∞)\). If \(a<0\), the graph of the line falls as \(x\) increases. In this case, \(f(x)=ax+b\) is decreasing on \((−∞, ∞)\). If \(a=0\), the line is horizontal.
![An image of a graph. The y axis runs from -2 to 5 and the x axis runs from -2 to 5. The graph is of the 3 functions. The first function is “f(x) = 3x + 1”, which is an increasing straight line with an x intercept at ((-1/3), 0) and a y intercept at (0, 1). The second function is “g(x) = 2”, which is a horizontal line with a y intercept at (0, 2) and no x intercept. The third function is “h(x) = (-1/2)x”, which is a decreasing straight line with an x intercept and y intercept both at the origin. The function f(x) is increasing at a higher rate than the function h(x) is decreasing.](https://math.libretexts.org/@api/deki/files/1702/CNX_Calc_Figure_01_02_001.jpeg?revision=1&size=bestfit&width=325&height=312)
As suggested by Figure \(\PageIndex{1}\), the graph of any linear function is a line. One of the distinguishing features of a line is its slope. The slope is the change in \(y\) for each unit change in \(x\). The slope measures both the steepness and the direction of a line. If the slope is positive, the line points upward when moving from left to right. If the slope is negative, the line points downward when moving from left to right. If the slope is zero, the line is horizontal. To calculate the slope of a line, we need to determine the ratio of the change in \(y\) versus the change in \(x\). To do so, we choose any two points \((x_1,y_1)\) and \((x_2,y_2)\) on the line and calculate \(\dfrac{y_2−y_1}{x_2−x_1}\). In Figure \(\PageIndex{2}\), we see this ratio is independent of the points chosen.
![An image of a graph. The y axis runs from -1 to 10 and the x axis runs from -1 to 6. The graph is of a function that is an increasing straight line. There are four points labeled on the function at (1, 1), (2, 3), (3, 5), and (5, 9). There is a dotted horizontal line from the labeled function point (1, 1) to the unlabeled point (3, 1) which is not on the function, and then dotted vertical line from the unlabeled point (3, 1), which is not on the function, to the labeled function point (3, 5). These two dotted have the label “(y2 - y1)/(x2 - x1) = (5 -1)/(3 - 1) = 2”. There is a dotted horizontal line from the labeled function point (2, 3) to the unlabeled point (5, 3) which is not on the function, and then dotted vertical line from the unlabeled point (5, 3), which is not on the function, to the labeled function point (5, 9). These two dotted have the label “(y2 - y1)/(x2 - x1) = (9 -3)/(5 - 2) = 2”.](https://math.libretexts.org/@api/deki/files/1703/CNX_Calc_Figure_01_02_021.jpeg?revision=2&size=bestfit&width=465&height=459)
Consider line \(L\) passing through points \((x_1,y_1)\) and \((x_2,y_2)\). Let \(Δy=y_2−y_1\) and \(Δx=x_2−x_1\) denote the changes in \(y\) and \(x\),respectively. The slope of the line is
\[m=\dfrac{y_2−y_1}{x_2−x_1}=\dfrac{Δy}{Δx} \nonumber \]
We now examine the relationship between slope and the formula for a linear function. Consider the linear function given by the formula \(f(x)=ax+b\). As discussed earlier, we know the graph of a linear function is given by a line. We can use our definition of slope to calculate the slope of this line. As shown, we can determine the slope by calculating \((y_2−y_1)/(x_2−x_1)\) for any points \((x_1,y_1)\) and \((x_2,y_2)\) on the line. Evaluating the function \(f\) at \(x=0\), we see that \((0,b)\) is a point on this line. Evaluating this function at \(x=1\), we see that \((1,a+b)\) is also a point on this line. Therefore, the slope of this line is
\[\dfrac{(a+b)−b}{1−0}=a. \nonumber \]
We have shown that the coefficient \(a\) is the slope of the line. We can conclude that the formula \(f(x)=ax+b\) describes a line with slope \(a\). Furthermore, because this line intersects the \(y\)-axis at the point \((0,b)\), we see that the \(y\)-intercept for this linear function is \((0,b)\). We conclude that the formula \(f(x)=ax+b\) tells us the slope, \(a\), and the \(y\)-intercept, \((0,b)\), for this line. Since we often use the symbol \(m\) to denote the slope of a line, we can write
\[\underbrace{f(x)=mx+b}_{\text{slope-intercept form}} \nonumber \]
to denote the slope-intercept form of a linear function.
Sometimes it is convenient to express a linear function in different ways. For example, suppose the graph of a linear function passes through the point \((x_1,y_1)\) and the slope of the line is \(m\). Since any other point \((x,f(x))\) on the graph of \(f\) must satisfy the equation
\[m=\dfrac{f(x)−y_1}{x−x_1}, \nonumber \]
this linear function can be expressed by writing
\[\underbrace{f(x)−y_1=m(x−x_1)}_{\text{point-slope equation}}. \nonumber \]
We call this equation the point-slope equation for that linear function.
Since every nonvertical line is the graph of a linear function, the points on a nonvertical line can be described using the slope-intercept or point-slope equations. However, a vertical line does not represent the graph of a function and cannot be expressed in either of these forms. Instead, a vertical line is described by the equation \(x=k\) for some constant \(k\). Since neither the slope-intercept form nor the point-slope form allows for vertical lines, we use the notation
\[\underbrace{ax+by=c}_{\text{standard form}}, \nonumber \]
where \(a,b\) are both not zero, to denote the standard form of a line.
Consider a line passing through the point \((x_1,y_1)\) with slope \(m\). The equation
\[y−y_1=m(x−x_1) \nonumber \]
is the point-slope equation for that line.
Consider a line with slope \(m\) and \(y\)-intercept \((0,b).\) The equation
\[y=mx+b \nonumber \]
is an equation for that line in slope-intercept form.
The standard form of a line is given by the equation
\[ax+by=c, \nonumber \]
where \(a\) and \(b\) are both not zero. This form is more general because it allows for a vertical line, \(x=k\).
Consider the line passing through the points \((11,−4)\) and \((−4,5)\), as shown in Figure \(\PageIndex{3}\).
![An image of a graph. The x axis runs from -5 to 12 and the y axis runs from -5 to 6. The graph is of the function that is a decreasing straight line. The function has two points plotted, at (-4, 5) and (11, 4).](https://math.libretexts.org/@api/deki/files/7829/imageedit_2_6502522226.png?revision=1)
- Find the slope of the line.
- Find an equation for this linear function in point-slope form.
- Find an equation for this linear function in slope-intercept form.
Solution
1. The slope of the line is
\[m=\dfrac{y_2−y_1}{x_2−x_1}=\dfrac{5−(−4)}{−4−11}=−\dfrac{9}{15}=−\dfrac{3}{5}. \nonumber \]
2. To find an equation for the linear function in point-slope form, use the slope \(m=−3/5\) and choose any point on the line. If we choose the point \((11,−4)\), we get the equation
\[f(x)+4=−\dfrac{3}{5}(x−11). \nonumber \]
3. To find an equation for the linear function in slope-intercept form, solve the equation in part b. for \(f(x)\). When we do this, we get the equation
\[f(x)=−\dfrac{3}{5}x+\dfrac{13}{5}. \nonumber \]
Consider the line passing through points \((−3,2)\) and \((1,4)\).
- Find the slope of the line.
- Find an equation of that line in point-slope form.
- Find an equation of that line in slope-intercept form.
- Hint
-
The slope \(m=Δy/Δx\).
- Answer a
-
\(m=1/2\).
- Answer b
-
The point-slope form is \(y−4=\dfrac{1}{2}(x−1)\).
- Answer c
-
The slope-intercept form is \(y=\dfrac{1}{2}x+\dfrac{7}{2}\).
Jessica leaves her house at 5:50 a.m. and goes for a 9-mile run. She returns to her house at 7:08 a.m. Answer the following questions, assuming Jessica runs at a constant pace.
- Describe the distance \(D\) (in miles) Jessica runs as a linear function of her run time \(t\) (in minutes).
- Sketch a graph of \(D\).
- Interpret the meaning of the slope.
Solution
a. At time \(t=0\), Jessica is at her house, so \(D(0)=0\). At time \(t=78\) minutes, Jessica has finished running \(9\) mi, so \(D(78)=9\). The slope of the linear function is
\[m=\dfrac{9−0}{78−0}=\dfrac{3}{26}.\nonumber \]
The \(y\)-intercept is \((0,0)\), so the equation for this linear function is
\[D(t)=\dfrac{3}{26}t. \nonumber \]
b. To graph \(D\), use the fact that the graph passes through the origin and has slope \(m=3/26.\)
c. The slope \(m=3/26≈0.115\) describes the distance (in miles) Jessica runs per minute, or her average velocity.
Polynomials
A linear function is a special type of a more general class of functions: polynomials. A polynomial function is any function that can be written in the form
\[f(x)=a_nx^n+a_{n−1}x^{n−1}+…+a_1x+a_0 \nonumber \]
for some integer \(n≥0\) and constants \(a_n,a_{n−1},…,a_0\), where \(a_n≠0\). In the case when \(n=0\), we allow for \(a_0=0\); if \(a_0=0\), the function \(f(x)=0\) is called the zero function. The value \(n\) is called the degree of the polynomial; the constant \(a_n\) is called the leading coefficient. A linear function of the form \(f(x)=mx+b\) is a polynomial of degree 1 if \(m≠0\) and degree 0 if \(m=0\). A polynomial of degree 0 is also called a constant function. A polynomial function of degree 2 is called a quadratic function. In particular, a quadratic function has the form
\[f(x)=ax^2+bx+c, \nonumber \]
where \(a≠0\). A polynomial function of degree \(3\) is called a cubic function.
Power Functions
Some polynomial functions are power functions. A power function is any function of the form \(f(x)=ax^b\), where \(a\) and \(b\) are any real numbers. The exponent in a power function can be any real number, but here we consider the case when the exponent is a positive integer. (We consider other cases later.) If the exponent is a positive integer, then \(f(x)=ax^n\) is a polynomial. If \(n\) is even, then \(f(x)=ax^n\) is an even function because \(f(−x)=a(−x)^n=ax^n\) if \(n\) is even. If \(n\) is odd, then \(f(x)=ax^n\) is an odd function because \(f(−x)=a(−x)^n=−ax^n\) if \(n\) is odd (Figure \(\PageIndex{4}\)).
![An image of two graphs. Both graphs have an x axis that runs from -4 to 4 and a y axis that runs from -6 to 7. The first graph is labeled “a” and is of two functions. The first function is “f(x) = x to the 4th”, which is a parabola that decreases until the origin and then increases again after the origin. The second function is “f(x) = x squared”, which is a parabola that decreases until the origin and then increases again after the origin, but increases and decreases at a slower rate than the first function. The second graph is labeled “b” and is of two functions. The first function is “f(x) = x to the 5th”, which is a curved function that increases until the origin, becomes even at the origin, and then increases again after the origin. The second function is “f(x) = x cubed”, which is a curved function that increases until the origin, becomes even at the origin, and then increases again after the origin, but increases at a slower rate than the first function.](https://math.libretexts.org/@api/deki/files/1706/CNX_Calc_Figure_01_02_004.jpeg?revision=1&size=bestfit&width=707&height=599)
Behavior at Infinity
To determine the behavior of a function \(f\) as the inputs approach infinity, we look at the values \(f(x)\) as the inputs, \(x\), become larger. For some functions, the values of \(f(x)\) approach a finite number. For example, for the function \(f(x)=2+1/x\), the values \(1/x\) become closer and closer to zero for all values of \(x\) as they get larger and larger. For this function, we say “\(f(x)\) approaches two as \(x\) goes to infinity,” and we write \(f(x)→2\) as \(x→∞\). The line \(y=2\) is a horizontal asymptote for the function \(f(x)=2+1/x\) because the graph of the function gets closer to the line as \(x\) gets larger.
For other functions, the values \(f(x)\) may not approach a finite number but instead may become larger for all values of \(x\) as they get larger. In that case, we say “\(f(x)\) approaches infinity as \(x\) approaches infinity,” and we write \(f(x)→∞\) as \(x→∞\). For example, for the function \(f(x)=3x^2\), the outputs \(f(x)\) become larger as the inputs \(x\) get larger. We can conclude that the function \(f(x)=3x^2\) approaches infinity as \(x\) approaches infinity, and we write \(3x^2→∞\) as \(x→∞\). The behavior as \(x→−∞\) and the meaning of \(f(x)→−∞\) as \(x→∞\) or \(x→−∞\) can be defined similarly. We can describe what happens to the values of \(f(x)\) as \(x→∞\) and as \(x→−∞\) as the end behavior of the function.
To understand the end behavior for polynomial functions, we can focus on quadratic and cubic functions. The behavior for higher-degree polynomials can be analyzed similarly. Consider a quadratic function \(f(x)=ax^2+bx+c\). If \(a>0\), the values \(f(x)→∞\) as \(x→±∞\). If \(a<0\), the values \(f(x)→−∞\) as \(x→±∞\). Since the graph of a quadratic function is a parabola, the parabola opens upward if \(a>0\).; the parabola opens downward if \(a<0\) (Figure \(\PageIndex{5a}\)).
Now consider a cubic function \(f(x)=ax^3+bx^2+cx+d\). If \(a>0\), then \(f(x)→∞\) as \(x→∞\) and \(f(x)→−∞\) as \(x→−∞\). If \(a<0\), then \(f(x)→−∞\) as \(x→∞\) and \(f(x)→∞\) as \(x→−∞\). As we can see from both of these graphs, the leading term of the polynomial determines the end behavior (Figure \(\PageIndex{5b}\)).
![An image of two graphs. The first graph is labeled “a” and has an x axis that runs from -4 to 5 and a y axis that runs from -4 to 6. The graph contains two functions. The first function is “f(x) = -(x squared) - 4x -4”, which is a parabola. The function increasing until it hits the maximum at the point (-2, 0) and then begins decreasing. The x intercept is at (-2, 0) and the y intercept is at (0, -4). The second function is “f(x) = 2(x squared) -12x + 16”, which is a parabola. The function decreases until it hits the minimum point at (3, -2) and then begins increasing. The x intercepts are at (2, 0) and (4, 0) and the y intercept is not shown. The second graph is labeled “b” and has an x axis that runs from -4 to 3 and a y axis that runs from -4 to 6. The graph contains two functions. The first function is “f(x) = -(x cubed) - 3(x squared) + x + 3”. The graph decreases until the approximate point at (-2.2, -3.1), then increases until the approximate point at (0.2, 3.1), then begins decreasing again. The x intercepts are at (-3, 0), (-1, 0), and (1, 0). The y intercept is at (0, 3). The second function is “f(x) = (x cubed) -3(x squared) + 3x - 1”. It is a curved function that increases until the point (1, 0), where it levels out. After this point, the function begins increasing again. It has an x intercept at (1, 0) and a y intercept at (0, -1).](https://math.libretexts.org/@api/deki/files/84840/CNX_Calc_Figure_01_02_005New.jpg?revision=1&size=bestfit&width=731&height=469)
Zeros of Polynomial Functions
Another characteristic of the graph of a polynomial function is where it intersects the \(x\)-axis. To determine where a function \(f\) intersects the \(x\)-axis, we need to solve the equation \(f(x)=0\) for \(x\). In the case of the linear function \(f(x)=mx+b\), the \(x\)-intercept is given by solving the equation \(mx+b=0\). In this case, we see that the \(x\)-intercept is given by \((−b/m,0)\). In the case of a quadratic function, finding the \(x\)-intercept(s) requires finding the zeros of a quadratic equation: \(ax^2+bx+c=0\). In some cases, it is easy to factor the polynomial \(ax^2+bx+c\) to find the zeros. If not, we make use of the quadratic formula.
Consider the quadratic equation
\[ax^2+bx+c=0, \nonumber \]
where \(a≠0\). The solutions of this equation are given by the quadratic formula
\[x=\dfrac{−b±\sqrt{b^2−4ac}}{2a}. \label{quad} \]
If the discriminant \(b^2−4ac>0\), Equation \ref{quad} tells us there are two real numbers that satisfy the quadratic equation. If \(b^2−4ac=0\), this formula tells us there is only one solution, and it is a real number. If \(b^2−4ac<0\), no real numbers satisfy the quadratic equation.
In the case of higher-degree polynomials, it may be more complicated to determine where the graph intersects the \(x\)-axis. In some instances, it is possible to find the \(x\)-intercepts by factoring the polynomial to find its zeros. In other cases, it is impossible to calculate the exact values of the \(x\)-intercepts. However, as we see later in the text, in cases such as this, we can use analytical tools to approximate (to a very high degree) where the \(x\)-intercepts are located. Here we focus on the graphs of polynomials for which we can calculate their zeros explicitly.
For the following functions,
- \(f(x)=−2x^2+4x−1\)
- \(f(x)=x^3−3x^2−4x\)
- describe the behavior of \(f(x)\) as \(x→±∞\),
- find all zeros of \(f\), and
- sketch a graph of \(f\).
Solution
1. The function \(f(x)=−2x^2+4x−1\) is a quadratic function.
1. Because \(a=−2<0\), as \(x→±∞,f(x)→−∞.\)
2. To find the zeros of \(f\), use the quadratic formula. The zeros are
\(x=\dfrac{−4±\sqrt{4^2−4(−2)(−1)}}{2(−2)}=\dfrac{−4±\sqrt{8}}{−4}=\dfrac{−4±2\sqrt{2}}{−4}=\dfrac{2±\sqrt{2}}{2}.\)
3. To sketch the graph of \(f\),use the information from your previous answers and combine it with the fact that the graph is a parabola opening downward.
2. The function \(f(x)=x^3−3x^2−4x\) is a cubic function.
1. Because \(a=1>0\), as \(x→∞\), \(f(x)→∞\). As \(x→−∞\), \(f(x)→−∞\).
2. To find the zeros of \(f\), we need to factor the polynomial. First, when we factor \(x\) out of all the terms, we find
\(f(x)=x(x^2−3x−4).\)
Then, when we factor the quadratic function \(x^2−3x−4\), we find
\(f(x)=x(x−4)(x+1).\)
Therefore, the zeros of \(f\) are \(x=0,4,−1\).
3. Combining the results from parts i. and ii., draw a rough sketch of \(f\).
Consider the quadratic function \(f(x)=3x^2−6x+2.\) Find the zeros of \(f\). Does the parabola open upward or downward?
- Hint
-
Use the quadratic formula.
- Answer
-
The zeros are \(x=1±\sqrt{3}/3\). The parabola opens upward.
Mathematical Models
A large variety of real-world situations can be described using mathematical models. A mathematical model is a method of simulating real-life situations with mathematical equations. Physicists, engineers, economists, and other researchers develop models by combining observation with quantitative data to develop equations, functions, graphs, and other mathematical tools to describe the behavior of various systems accurately. Models are useful because they help predict future outcomes. Examples of mathematical models include the study of population dynamics, investigations of weather patterns, and predictions of product sales.
As an example, let’s consider a mathematical model that a company could use to describe its revenue for the sale of a particular item. The amount of revenue \(R\) a company receives for the sale of \(n\) items sold at a price of \(p\) dollars per item is described by the equation \(R=p⋅n\). The company is interested in how the sales change as the price of the item changes. Suppose the data in Table \(\PageIndex{1}\) show the number of units a company sells as a function of the price per item.
\(p\) | 6 | 8 | 10 | 12 | 14 |
---|---|---|---|---|---|
\(n\) | 19.4 | 18.5 | 16.2 | 13.8 | 12.2 |
In Figure \(\PageIndex{6}\), we see the graph the number of units sold (in thousands) as a function of price (in dollars). We note from the shape of the graph that the number of units sold is likely a linear function of price per item, and the data can be closely approximated by the linear function \(n= −1.04p+26\) for \(0≤p≤25\), where \(n\) predicts the number of units sold in thousands. Using this linear function, the revenue (in thousands of dollars) can be estimated by the quadratic function
\[R(p)=p⋅ (−1.04p+26)=−1.04p^2+26p \text{ for }0≤p≤25. \nonumber \]
In Example \(\PageIndex{4}\), we use this quadratic function to predict the amount of revenue the company receives depending on the price the company charges per item. Note that we cannot conclude definitively the actual number of units sold for values of \(p\), for which no data are collected. However, given the other data values and the graph shown, it seems reasonable that the number of units sold (in thousands) if the price charged is \(p\) dollars may be close to the values predicted by the linear function \(n=−1.04p+26.\)
![An image of a graph. The y axis runs from 0 to 28 and is labeled “n, units sold in thousands”. The x axis runs from 0 to 28 and is labeled “p, price in dollars”. The graph is of the function “n = -1.04p + 26”, which is a decreasing line function that starts at the y intercept point (0, 26). There are 5 points plotted on the graph at (6, 19.4), (8, 18.5), (10, 16.2), (12, 13.8), and (14, 12.2). The points are not on the graph of the function line, but are very close to it. The function has an x intercept at the point (25, 0).](https://math.libretexts.org/@api/deki/files/1710/CNX_Calc_Figure_01_02_008.jpeg?revision=1&size=bestfit&width=576&height=569)
A company is interested in predicting the amount of revenue it will receive depending on the price it charges for a particular item. Using the data from Table \(\PageIndex{1}\), the company arrives at the following quadratic function to model revenue \(R\) as a function of price per item \(p:\)
\[R(p)=p⋅(−1.04p+26)=−1.04p^2+26p \nonumber \]
for \(0≤p≤25\).
- Predict the revenue if the company sells the item at a price of \(p=$5\) and \(p=$17\).
- Find the zeros of this function and interpret the meaning of the zeros.
- Sketch a graph of \(R\).
- Use the graph to determine the value of \(p\) that maximizes revenue. Find the maximum revenue.
Solution
a. Evaluating the revenue function at \(p=5\) and \(p=17\), we can conclude that
\(R(5)=−1.04(5)^2+26(5)=104,\text{ so revenue}=$104,000;\)
\(R(17)=−1.04(17)^2+26(17)=141.44,\text{ so revenue}=$141,440.\)
b. The zeros of this function can be found by solving the equation \(−1.04p^2+26p=0\). When we factor the quadratic expression, we get \(p(−1.04p+26)=0\). The solutions to this equation are given by \(p=0,25\). For these values of \(p\), the revenue is zero. When \(p=$0\), the revenue is zero because the company is giving away its merchandise for free. When \(p=$25\),the revenue is zero because the price is too high, and no one will buy any items.
c. Knowing the fact that the function is quadratic, we also know the graph is a parabola. Since the leading coefficient is negative, the parabola opens downward. One property of parabolas is that they are symmetric about the axis of symmetry, so since the zeros are at \(p=0\) and \(p=25\), the parabola must be symmetric about the line halfway between them, or \(p=12.5\).
d. The function is a parabola with zeros at \(p=0\) and \(p=25\), and it is symmetric about the line \(p=12.5\), so the maximum revenue occurs at a price of \(p=$12.50\) per item. At that price, the revenue is \(R(p)=−1.04(12.5)^2+26(12.5)=$162,500.\)
Algebraic Functions
By allowing for quotients and fractional powers in polynomial functions, we create a larger class of functions. An algebraic function is one that involves addition, subtraction, multiplication, division, rational powers, and roots. Two types of algebraic functions are rational functions and root functions.
Just as rational numbers are quotients of integers, rational functions are quotients of polynomials. In particular, a rational function is any function of the form \(f(x)=p(x)/q(x)\),where \(p(x)\) and \(q(x)\) are polynomials. For example,
\(f(x)=\dfrac{3x−1}{5x+2}\) and \(g(x)=\dfrac{4}{x^2+1}\)
are rational functions. A root function is a power function of the form \(f(x)=x^{1/n}\), where \(n\) is a positive integer greater than one. For example, \(f(x)=x^{1/2}=\sqrt{x}\) is the square-root function and \(g(x)=x^{1/3}=\sqrt[3]{x}\) is the cube-root function. By allowing for compositions of root functions and rational functions, we can create other algebraic functions. For example, \(f(x)=\sqrt{4−x^2}\) is an algebraic function.
For each of the following functions, find the domain and range.
- \(f(x)=\dfrac{3x−1}{5x+2}\)
- \(f(x)=\sqrt{4−x^2}\)
Solution
1. It is not possible to divide by zero, so the domain is the set of real numbers \(x\) such that \(x≠−2/5\). To find the range, we need to find the values \(y\) for which there exists a real number \(x\) such that
\(y=\dfrac{3x−1}{5x+2}\)
When we multiply both sides of this equation by \(5x+2\), we see that \(x\) must satisfy the equation
\(5xy+2y=3x−1.\)
From this equation, we can see that \(x\) must satisfy
\(2y+1=x(3−5y).\)
If y=\(3/5\), this equation has no solution. On the other hand, as long as \(y≠3/5\),
\(x=\dfrac{2y+1}{3−5y}\)
satisfies this equation. We can conclude that the range of \(f\) is \(\{y\,|\,y≠3/5\}\).
2. To find the domain of \(f\), we need \(4−x^2≥0\). When we factor, we write \(4−x^2=(2−x)(2+x)≥0\). This inequality holds if and only if both terms are positive or both terms are negative. For both terms to be positive, we need to find \(x\) such that
\(2−x≥0\) and \(2+x≥0.\)
These two inequalities reduce to \(2≥x\) and \(x≥−2\). Therefore, the set \(\{x\,|\,−2≤x≤2\}\) must be part of the domain. For both terms to be negative, we need
\(2−x≤0\) and \(2+x\le 0.\)
These two inequalities also reduce to \(2≤x\) and \(x\le −2\). There are no values of \(x\) that satisfy both of these inequalities. Thus, we can conclude the domain of this function is \(\{x\,|\,−2≤x≤2\}.\)
If \(−2≤x≤2\), then \(0≤4−x^2≤4\). Therefore, \(0≤\sqrt{4−x2}≤2\), and the range of \(f\) is \(\{y\,|\,0≤y≤2\}.\)
Find the domain and range for the function \(f(x)=(5x+2)/(2x−1).\)
- Hint
-
The denominator cannot be zero. Solve the equation \(y=(5x+2)/(2x−1)\) for \(x\) to find the range.
- Answer
-
The domain is the set of real numbers \(x\) such that \(x≠1/2\). The range is the set \(\{y\,|\,y≠5/2\}\).
The root functions \(f(x)=x^{1/n}\) have defining characteristics depending on whether \(n\) is odd or even. For all even integers \(n≥2\), the domain of \(f(x)=x^{1/n}\) is the interval \([0,∞)\). For all odd integers \(n≥1\), the domain of \(f(x)=x^{1/n}\) is the set of all real numbers. Since \(x^{1/n}=(−x)^{1/n}\) for odd integers \(n\),\(f(x)=x^{1/n}\) is an odd function if\(n\) is odd. See the graphs of root functions for different values of \(n\) in Figure \(\PageIndex{7}\).
![An image of two graphs. The first graph is labeled “a” and has an x axis that runs from -2 to 9 and a y axis that runs from -4 to 4. The first graph is of two functions. The first function is “f(x) = square root of x”, which is a curved function that begins at the origin and increases. The second function is “f(x) = x to the 4th root”, which is a curved function that begins at the origin and increases, but increases at a slower rate than the first function. The second graph is labeled “b” and has an x axis that runs from -8 to 8 and a y axis that runs from -4 to 4. The second graph is of two functions. The first function is “f(x) = cube root of x”, which is a curved function that increases until the origin, becomes vertical at the origin, and then increases again after the origin. The second function is “f(x) = x to the 5th root”, which is a curved function that increases until the origin, becomes vertical at the origin, and then increases again after the origin, but increases at a slower rate than the first function.](https://math.libretexts.org/@api/deki/files/1712/CNX_Calc_Figure_01_02_022.jpeg?revision=1)
For each of the following functions, determine the domain of the function.
- \(f(x)=\dfrac{3}{x^2−1}\)
- \(f(x)=\dfrac{2x+5}{3x^2+4}\)
- \(f(x)=\sqrt{4−3x}\)
- \(f(x)=\sqrt[3]{2x−1}\)
Solution
- You cannot divide by zero, so the domain is the set of values \(x\) such that \(x^2−1≠0\). Therefore, the domain is \(\{x\,|\,x≠±1\}\).
- You need to determine the values of \(x\) for which the denominator is zero. Since \(3x^2+4≥4\) for all real numbers \(x\), the denominator is never zero. Therefore, the domain is \((−∞,∞).\)
- Since the square root of a negative number is not a real number, the domain is the set of values \(x\) for which \(4−3x≥0\). Therefore, the domain is \(\{x\,|\,x≤4/3\}.\)
- The cube root is defined for all real numbers, so the domain is the interval \((−∞, ∞).\)
Find the domain for each of the following functions: \(f(x)=(5−2x)/(x^2+2)\) and \(g(x)=\sqrt{5x−1}\).
- Hint
-
Determine the values of \(x\) when the expression in the denominator of \(f\) is nonzero, and find the values of \(x\) when the expression inside the radical of \(g\) is nonnegative.
- Answer
-
The domain of \(f\) is \((−∞, ∞)\). The domain of \(g\) is \(\{x\,|\,x≥1/5\}.\)
Piecewise-Defined Functions
Sometimes a function is defined by different formulas on different parts of its domain. A function with this property is known as a piecewise-defined function. The absolute value function is an example of a piecewise-defined function because the formula changes with the sign of \(x\):
\[f(x)=\begin{cases}−x, & \text{if } x<0\\x, & \text{if } x≥0\end{cases}. \nonumber \]
Other piecewise-defined functions may be represented by completely different formulas, depending on the part of the domain in which a point falls. To graph a piecewise-defined function, we graph each part of the function in its respective domain, on the same coordinate system. If the formula for a function is different for \(x<a\) and \(x>a\), we need to pay special attention to what happens at \(x=a\) when we graph the function. Sometimes the graph needs to include an open or closed circle to indicate the value of the function at \(x=a\). We examine this in the next example.
Sketch a graph of the following piecewise-defined function:
\[f(x)=\begin{cases}x+3, & \text{if } x<1\\(x−2)^2, & \text{if } x≥1\end{cases} \nonumber \]
Solution
Graph the linear function \(y=x+3\) on the interval \((−∞,1)\) and graph the quadratic function \(y=(x−2)^2\) on the interval \([1,∞)\). Since the value of the function at \(x=1\) is given by the formula \(f(x)=(x−2)^2\), we see that \(f(1)=1\). To indicate this on the graph, we draw a closed circle at the point \((1,1)\). The value of the function is given by \(f(x)=x+3\) for all \(x<1\), but not at \(x=1\). To indicate this on the graph, we draw an open circle at \((1,4)\).
![An image of a graph. The x axis runs from -7 to 5 and the y axis runs from -4 to 6. The graph is of a function that has two pieces. The first piece is an increasing line that ends at the open circle point (1, 4) and has the label “f(x) = x + 3, for x < 1”. The second piece is parabolic and begins at the closed circle point (1, 1). After the point (1, 1), the piece begins to decrease until the point (2, 0) then begins to increase. This piece has the label “f(x) = (x - 2) squared, for x >= 1”.The function has x intercepts at (-3, 0) and (2, 0) and a y intercept at (0, 3).](https://math.libretexts.org/@api/deki/files/7834/imageedit_22_5976625651.png?revision=1)
2) Sketch a graph of the function
\(f(x)=\begin{cases}2−x, & \text{if } x≤2\\x+2, & \text{if } x>2\end{cases}.\)
Solution:
In a big city, drivers are charged variable rates for parking in a parking garage. They are charged $10 for the first hour or any part of the first hour and an additional $2 for each hour or part thereof up to a maximum of $30 for the day. The parking garage is open from 6 a.m. to 12 midnight.
- Write a piecewise-defined function that describes the cost \(C\) to park in the parking garage as a function of hours parked \(x\).
- Sketch a graph of this function \(C(x).\)
Solution
1.Since the parking garage is open 18 hours each day, the domain for this function is \(\{x\,|\,0<x≤18\}\). The cost to park a car at this parking garage can be described piecewise by the function
\[C(x)=\begin{cases}10, & \text{for } 0<x≤1\\12, & \text{for } 1<x≤2\\14, & \text{for } 2<x≤3\\16, & \text{for } 3<x≤4\\ ⋮\\30, & \text{for } 10<x≤18\end{cases}. \nonumber \]
2.The graph of the function consists of several horizontal line segments.
The cost of mailing a letter is a function of the weight of the letter. Suppose the cost of mailing a letter is \(49¢\) for the first ounce and \(21¢\) for each additional ounce. Write a piecewise-defined function describing the cost \(C\) as a function of the weight \(x\) for \(0<x≤3\), where \(C\) is measured in cents and \(x\) is measured in ounces.
- Hint
-
The piecewise-defined function is constant on the intervals \((0,1],\,(1,2],\,….\)
- Answer
-
\[C(x)=\begin{cases}49, 0<x≤1\\70, 1<x≤2\\91, 2<x≤3\end{cases} \nonumber \]
Transformations of Functions
We have seen several cases in which we have added, subtracted, or multiplied constants to form variations of simple functions. In the previous example, for instance, we subtracted 2 from the argument of the function \(y=x^2\) to get the function \(f(x)=(x−2)^2\). This subtraction represents a shift of the function \(y=x^2\) two units to the right. A shift, horizontally or vertically, is a type of transformation of a function. Other transformations include horizontal and vertical scalings, and reflections about the axes.
A vertical shift of a function occurs if we add or subtract the same constant to each output \(y\). For \(c>0\), the graph of \(f(x)+c\) is a shift of the graph of \(f(x)\) up \(c\) units, whereas the graph of \(f(x)−c\) is a shift of the graph of \(f(x)\) down \(c\) units. For example, the graph of the function \(f(x)=x^3+4\) is the graph of \(y=x^3\) shifted up \(4\) units; the graph of the function \(f(x)=x^3−4\) is the graph of \(y=x^3\) shifted down \(4\) units (Figure \(\PageIndex{9}\)).
![An image of two graphs. The first graph is labeled “a” and has an x axis that runs from -4 to 4 and a y axis that runs from -1 to 10. The graph is of two functions. The first function is “f(x) = x squared”, which is a parabola that decreases until the origin and then increases again after the origin. The second function is “f(x) = (x squared) + 4”, which is a parabola that decreases until the point (0, 4) and then increases again after the origin. The two functions are the same in shape, but the second function is shifted up 4 units. The second graph is labeled “b” and has an x axis that runs from -4 to 4 and a y axis that runs from -5 to 6. The graph is of two functions. The first function is “f(x) = x squared”, which is a parabola that decreases until the origin and then increases again after the origin. The second function is “f(x) = (x squared) - 4”, which is a parabola that decreases until the point (0, -4) and then increases again after the origin. The two functions are the same in shape, but the second function is shifted down 4 units.](https://math.libretexts.org/@api/deki/files/1716/CNX_Calc_Figure_01_02_023.jpeg?revision=1)
A horizontal shift of a function occurs if we add or subtract the same constant to each input \(x\). For \(c>0\), the graph of \(f(x+c)\) is a shift of the graph of \(f(x)\) to the left \(c\) units; the graph of \(f(x−c)\) is a shift of the graph of \(f(x)\) to the right \(c\) units. Why does the graph shift left when adding a constant and shift right when subtracting a constant? To answer this question, let’s look at an example.
Consider the function \(f(x)=|x+3|\) and evaluate this function at \(x−3\). Since \(f(x−3)=|x|\) and \(x−3<x\), the graph of \(f(x)=|x+3|\) is the graph of \(y=|x|\) shifted left \(3\) units. Similarly, the graph of \(f(x)=|x−3|\) is the graph of \(y=|x|\) shifted right \(3\) units (Figure \(\PageIndex{10}\)).
![An image of two graphs. The first graph is labeled “a” and has an x axis that runs from -8 to 5 and a y axis that runs from -3 to 5. The graph is of two functions. The first function is “f(x) = absolute value of x”, which decreases in a straight line until the origin and then increases in a straight line again after the origin. The second function is “f(x) = absolute value of (x + 3)”, which decreases in a straight line until the point (-3, 0) and then increases in a straight line again after the point (-3, 0). The two functions are the same in shape, but the second function is shifted left 3 units. The second graph is labeled “b” and has an x axis that runs from -5 to 8 and a y axis that runs from -3 to 5. The graph is of two functions. The first function is “f(x) = absolute value of x”, which decreases in a straight line until the origin and then increases in a straight line again after the origin. The second function is “f(x) = absolute value of (x - 3)”, which decreases in a straight line until the point (3, 0) and then increases in a straight line again after the point (3, 0). The two functions are the same in shape, but the second function is shifted right 3 units.](https://math.libretexts.org/@api/deki/files/1717/CNX_Calc_Figure_01_02_015.jpeg?revision=1)
A vertical scaling of a graph occurs if we multiply all outputs \(y\) of a function by the same positive constant. For \(c>0\), the graph of the function \(cf(x)\) is the graph of \(f(x)\) scaled vertically by a factor of \(c\). If \(c>1\), the values of the outputs for the function \(cf(x)\) are larger than the values of the outputs for the function \(f(x)\); therefore, the graph has been stretched vertically. If \(0<c<1\), then the outputs of the function \(cf(x)\) are smaller, so the graph has been compressed. For example, the graph of the function \(f(x)=3x^2\) is the graph of \(y=x^2\) stretched vertically by a factor of 3, whereas the graph of \(f(x)=x^2/3\) is the graph of \(y=x^2\) compressed vertically by a factor of \(3\) (Figure \(\PageIndex{11b}\)).
![An image of two graphs. The first graph is labeled “a” and has an x axis that runs from -3 to 3 and a y axis that runs from -2 to 9. The graph is of two functions. The first function is “f(x) = x squared”, which is a parabola that decreases until the origin and then increases again after the origin. The second function is “f(x) = 3(x squared)”, which is a parabola that decreases until the origin and then increases again after the origin, but is vertically stretched and thus increases at a quicker rate than the first function. The second graph is labeled “b” and has an x axis that runs from -4 to 4 and a y axis that runs from -2 to 9. The graph is of two functions. The first function is “f(x) = x squared”, which is a parabola that decreases until the origin and then increases again after the origin. The second function is “f(x) = (1/3)(x squared)”, which is a parabola that decreases until the origin and then increases again after the origin, but is vertically compressed and thus increases at a slower rate than the first function.](https://math.libretexts.org/@api/deki/files/1718/CNX_Calc_Figure_01_02_024.jpeg?revision=1&size=bestfit&width=662&height=507)
The horizontal scaling of a function occurs if we multiply the inputs \(x\) by the same positive constant. For \(c>0\), the graph of the function \(f(cx)\) is the graph of \(f(x)\) scaled horizontally by a factor of \(c\). If \(c>1\), the graph of \(f(cx)\) is the graph of \(f(x)\) compressed horizontally. If \(0<c<1\), the graph of \(f(cx)\) is the graph of \(f(x)\) stretched horizontally. For example, consider the function \(f(x)=\sqrt{2x}\) and evaluate \(f\) at \(x/2\). Since \(f(x/2)=\sqrt{x}\), the graph of \(f(x)=\sqrt{2x}\) is the graph of \(y=\sqrt{x}\) compressed horizontally. The graph of \(y=\sqrt{x/2}\) is a horizontal stretch of the graph of \(y=\sqrt{x}\) (Figure \(\PageIndex{12}\)).
![An image of two graphs. Both graphs have an x axis that runs from -2 to 4 and a y axis that runs from -2 to 5. The first graph is labeled “a” and is of two functions. The first graph is of two functions. The first function is “f(x) = square root of x”, which is a curved function that begins at the origin and increases. The second function is “f(x) = square root of 2x”, which is a curved function that begins at the origin and increases, but increases at a faster rate than the first function. The second graph is labeled “b” and is of two functions. The first function is “f(x) = square root of x”, which is a curved function that begins at the origin and increases. The second function is “f(x) = square root of (x/2)”, which is a curved function that begins at the origin and increases, but increases at a slower rate than the first function.](https://math.libretexts.org/@api/deki/files/1719/CNX_Calc_Figure_01_02_017.jpeg?revision=1)
We have explored what happens to the graph of a function \(f\) when we multiply \(f\) by a constant \(c>0\) to get a new function \(cf(x)\). We have also discussed what happens to the graph of a function \(f\)when we multiply the independent variable \(x\) by \(c>0\) to get a new function \(f(cx)\). However, we have not addressed what happens to the graph of the function if the constant \(c\) is negative. If we have a constant \(c<0\), we can write \(c\) as a positive number multiplied by \(−1\); but, what kind of transformation do we get when we multiply the function or its argument by \(−1?\) When we multiply all the outputs by \(−1\), we get a reflection about the \(x\)-axis. When we multiply all inputs by \(−1\), we get a reflection about the \(y\)-axis. For example, the graph of \(f(x)=−(x^3+1)\) is the graph of \(y=(x^3+1)\) reflected about the \(x\)-axis. The graph of \(f(x)=(−x)^3+1\) is the graph of \(y=x^3+1\) reflected about the \(y\)-axis (Figure \(\PageIndex{13}\)).
![An image of two graphs. Both graphs have an x axis that runs from -3 to 3 and a y axis that runs from -5 to 6. The first graph is labeled “a” and is of two functions. The first graph is of two functions. The first function is “f(x) = x cubed + 1”, which is a curved increasing function that has an x intercept at (-1, 0) and a y intercept at (0, 1). The second function is “f(x) = -(x cubed + 1)”, which is a curved decreasing function that has an x intercept at (-1, 0) and a y intercept at (0, -1). The second graph is labeled “b” and is of two functions. The first function is “f(x) = x cubed + 1”, which is a curved increasing function that has an x intercept at (-1, 0) and a y intercept at (0, 1). The second function is “f(x) = (-x) cubed + 1”, which is a curved decreasing function that has an x intercept at (1, 0) and a y intercept at (0, 1). The first function increases at the same rate the second function decreases for the same values of x.](https://math.libretexts.org/@api/deki/files/1720/CNX_Calc_Figure_01_02_018.jpeg?revision=1&size=bestfit&width=487&height=434)
If the graph of a function consists of more than one transformation of another graph, it is important to transform the graph in the correct order. Given a function \(f(x)\), the graph of the related function \(y=cf(a(x+b))+d\) can be obtained from the graph of \(y=f(x)\)by performing the transformations in the following order.
- Horizontal shift of the graph of \(y=f(x)\). If \(b>0\), shift left. If \(b<0\) shift right.
- Horizontal scaling of the graph of \(y=f(x+b)\) by a factor of \(|a|\). If \(a<0\), reflect the graph about the \(y\)-axis.
- Vertical scaling of the graph of \(y=f(a(x+b))\) by a factor of \(|c|\). If \(c<0\), reflect the graph about the \(x\) -axis.
- Vertical shift of the graph of \(y=cf(a(x+b))\). If \(d>0\), shift up. If \(d<0\), shift down.
We can summarize the different transformations and their related effects on the graph of a function in the following table.
Transformation of \(f (c>0)\) | Effect of the graph of \(f\) |
---|---|
\(f(x)+c\) | Vertical shift up \(c\) units |
\(f(x)-c\) | Vertical shift down \(c\) units |
\(f(x+c)\) | Shift left by \(c\) units |
\(f(x-c)\) | Shift right by \(c\) units |
\(cf(x)\) |
Vertical stretch if \(c>1\); vertical compression if \(0<c<1\) |
\(f(cx)\) |
Horizontal stretch if \(0<c<1\); horizontal compression if \(c>1\) |
\(-f(x)\) | Reflection about the \(x\)-axis |
\(f(-x)\) | Reflection about the \(y\)-axis |
For each of the following functions, a. and b., sketch a graph by using a sequence of transformations of a well-known function.
- \(f(x)=−|x+2|−3\)
- \(f(x)=3\sqrt{-x}+1\)
Solution
1.Starting with the graph of \(y=|x|\), shift \(2\) units to the left, reflect about the \(x\)-axis, and then shift down \(3\) units.
![An image of a graph. The x axis runs from -7 to 7 and a y axis runs from -7 to 7. The graph contains four functions. The first function is “f(x) = absolute value of x” and is labeled starting function. It decreases in a straight line until the origin and then increases in a straight line again after the origin. The second function is “f(x) = absolute value of (x + 2)”, which decreases in a straight line until the point (-2, 0) and then increases in a straight line again after the point (-2, 0). The second function is the same shape as the first function, but is shifted left 2 units. The third function is “f(x) = -(absolute value of (x + 2))”, which increases in a straight line until the point (-2, 0) and then decreases in a straight line again after the point (-2, 0). The third function is the second function reflected about the x axis. The fourth function is “f(x) = -(absolute value of (x + 2)) - 3” and is labeled “transformed function”. It increases in a straight line until the point (-2, -3) and then decreases in a straight line again after the point (-2, -3). The fourth function is the third function shifted down 3 units.](https://math.libretexts.org/@api/deki/files/7837/imageedit_35_3765237707.png?revision=1)
2. Starting with the graph of \(y=\sqrt{x},\) reflect about the \(y\)-axis, stretch the graph vertically by a factor of 3, and move up 1 unit.
![An image of a graph. The x axis runs from -7 to 7 and a y axis runs from -2 to 10. The graph contains four functions. The first function is “f(x) = square root of x” and is labeled starting function. It is a curved function that begins at the origin and increases. The second function is “f(x) = square root of -x”, which is a curved function that decreases until it reaches the origin, where it stops. The second function is the first function reflected about the y axis. The third function is “f(x) = 3(square root of -x)”, which is a curved function that decreases until it reaches the origin, where it stops. The third function decreases at a quicker rate than the second function. The fourth function is “f(x) = 3(square root of -x) + 1” and is labeled “transformed function”. Itis a curved function that decreases until it reaches the point (0, 1), where it stops. The fourth function is the third function shifted up 1 unit.](https://math.libretexts.org/@api/deki/files/7838/imageedit_39_5995546184.png?revision=1)
Describe how the function \(f(x)=−(x+1)^2−4\) can be graphed using the graph of \(y=x^2\) and a sequence of transformations
- Answer
-
Shift the graph \(y=x^2\) to the left 1 unit, reflect about the \(x\)-axis, then shift down 4 units.
Key Concepts
- The power function \(f(x)=x^n\) is an even function if n is even and \(n≠0\), and it is an odd function if \(n\) is odd.
- The root function \(f(x)=x^{1/n}\) has the domain \([0,∞)\) if n is even and the domain \((−∞,∞)\) if \(n\) is odd. If \(n\) is odd, then \(f(x)=x^{1/n}\) is an odd function.
- The domain of the rational function \(f(x)=p(x)/q(x)\), where \(p(x)\) and \(q(x)\) are polynomial functions, is the set of \(x\) such that \(q(x)≠0\).
- Functions that involve the basic operations of addition, subtraction, multiplication, division, and powers are algebraic functions.
- A polynomial function \(f\) with degree \(n≥1\) satisfies \(f(x)→±∞\) as \(x→±∞\). The sign of the output as \(x→∞\) depends on the sign of the leading coefficient only and on whether \(n\) is even or odd.
- Vertical and horizontal shifts, vertical and horizontal scalings, and reflections about the \(x\)- and \(y\)-axes are examples of transformations of functions.
Key Equations
- Point-slope equation of a line \[y−y_1=m(x−x_1)\nonumber \]
- Slope-intercept form of a line \[y=mx+b\nonumber \]
- Standard form of a line \[ax+by=c\nonumber \]
- Polynomial function \[f(x)=a_n{x^n}+a_{n−1}x^{n−1}+⋯+a_1x+a_0\nonumber \]
Glossary
- algebraic function
- a function involving any combination of only the basic operations of addition, subtraction, multiplication, division, powers, and roots applied to an input variable \(x\)
- cubic function
- a polynomial of degree 3; that is, a function of the form \(f(x)=ax^3+bx^2+cx+d\), where \(a≠0\)
- degree
- for a polynomial function, the value of the largest exponent of any term
- linear function
- a function that can be written in the form \(f(x)=mx+b\)
- mathematical model
- A method of simulating real-life situations with mathematical equations
- piecewise-defined function
- a function that is defined differently on different parts of its domain
- point-slope equation
- equation of a linear function indicating its slope and a point on the graph of the function
- polynomial function
- a function of the form \(f(x)=a_nx^n+a_{n−1}x^{n−1}+…+a_1x+a_0\)
- power function
- a function of the form \(f(x)=x^n\) for any positive integer \(n≥1\)
- quadratic function
- a polynomial of degree 2; that is, a function of the form \(f(x)=ax^2+bx+c\) where \(a≠0\)
- rational function
- a function of the form \(f(x)=p(x)/q(x)\), where \(p(x)\) and \(q(x)\) are polynomials
- root function
- a function of the form \(f(x)=x^{1/n}\) for any integer \(n≥2\)
- slope
- the change in \(y\) for each unit change in \(x\)
- slope-intercept form
- equation of a linear function indicating its slope and \(y\)-intercept
- transformation of a function
- a shift, scaling, or reflection of a function