The natural world is full of relationships between quantities that change. When we see these relationships, it is natural for us to ask, "If I know one quantity, can I then determine the other?" This establishes the idea of an input quantity, or independent variable, and a corresponding output quantity, or dependent variable. From this we get the notion of a functional relationship in which the output can be determined from the input.
For some quantities, like height and age, there are certainly relationships between these quantities. Given a specific person and any age, it is easy enough to determine their height, but if we tried to reverse that relationship and determine age from a given height, that would be problematic, since most people maintain the same height for many years.
A rule for a relationship between an input, or independent, quantity and an output, or dependent, quantity in which each input value uniquely determines one output value. We say, "the output is a function of the input."
In the height and age scenario above, it would be correct to say that height is a function of age, since each age uniquely determines a height. For example, on my 18th birthday, I had exactly one height of 69 inches.
However, age is not a function of height, since one height input might correspond with more than one output age. For example, for an input height of 70 inches, there is more than one output of age since I was 70 inches at the age of 20 and 21.
We could say that price is a function of the item, since each input of an item has one output of a price corresponding to it. We could not say that item is a function of price, since two items might have the same price.
In many classes the overall percentage you earn in the course corresponds to a decimal grade point. Is decimal grade a function of percentage? Is percentage a function of decimal grade?
For any percentage earned, there would be a decimal grade associated, so we could say that the decimal grade is a function of percentage. That is, if you input the percentage, your output would be a decimal grade. Percentage may or may not be a function of decimal grade, depending upon the teacherβs grading scheme. With some grading systems, there are a range of percentages that correspond to the same decimal grade.
Sometimes in a relationship each input corresponds to exactly one output, and every output corresponds to exactly one input. We call this kind of relationship a one-to-one function.
From Example 3, if each unique percentage corresponds to one unique decimal grade point and each unique decimal grade point corresponds to one unique percentage then it is a one-to-one function.
To simplify writing out expressions and equations involving functions, a simplified notation is often used. We also use descriptive variables to help us remember the meaning of the quantities in the problem.
Rather than write "height is a function of age", we could use the descriptive variable \(h\) to represent height and we could use the descriptive variable \(a\) to represent age.
Be careful - the parentheses indicate that age is input into the function (Note: do not confuse these parentheses with multiplication! It does not mean "\(f\) times \(a\)").
The number of days in a month is a function of the name of the month, so if we name the function \(f\text{,}\) we could write "\(\text{days}= f(\text{month})\)" or \(d = f(m)\text{.}\)
For example, \(f(\text{March}) = 31\text{,}\) since March has 31 days. The notation \(f(m)\) reminds us that the number of days, \(d\) (the output) is dependent on the name of the month, \(m\) (the input)
When we read \(f(2005) = 300\text{,}\) we see the input quantity is 2005, which is a value for the input quantity of the function, the year (\(y\)). The output value is 300, the number of police officers (\(N\)), a value for the output quantity. Remember \(N=f(y)\text{.}\) This tells us that in the year 2005 there were 300 police officers in the town.
Functions can be represented in many ways: Words (as we did in the last few examples), tables of values, graphs, or formulas. Represented as a table, we are presented with a list of input and output values.
In some cases, these values represent everything we know about the relationship, while in other cases the table is simply providing us a few select values from a more complete relationship.
Table 1: This table represents the input, number of the month (January = 1, February = 2, and so on) while the output is the number of days in that month. This represents everything we know about the months and days for a given year (that is not a leap year)
Table 2: The table below defines a function \(Q = g(n)\text{.}\) Remember this notation tells us \(g\) is the name of the function that takes the input \(n\) and gives the output \(Q\text{.}\)
Table 3: This table represents the age of children in years and their corresponding heights. This represents just some of the data available for height and ages of children.
The first and second tables define functions. In both, each input corresponds to exactly one output. The third table does not define a function since the input value of 5 corresponds with two different output values.
Only the first table is one-to-one; it is both a function, and each output corresponds to exactly one input. Although table 2 is a function, because each input corresponds to exactly one output, each output does not correspond to exactly one input so this function is not one-to-one. Table 3 is not even a function and so we donβt even need to consider if it is a one-to-one function.
When we work with functions, there are two typical things we do: evaluate and solve. Evaluating a function is what we do when we know an input, and use the function to determine the corresponding output. Evaluating will always produce one result, since each input of a function corresponds to exactly one output. When we have a formula for the function we are evaluating, we always want to make sure we are performing operations in the correct order, commonly known as the "Order of Operations". You have likely heard of or seen the order of operations in a previous class: Parenthesis, Exponents, Multiply, Divide, Addition, Subtraction. We also need to remember that sometimes these steps are nested within each other. For example, in the function \(f(x)=2(5x-3)+9\text{,}\) if I wanted to evaluate \(f(3)\text{,}\) I would need to first simplify the terms inside of the parenthesis, and I would need to follow proper order of operations INSIDE of the parenthesis. So, I would evaluate \(5(3)-3=15-3=12\) first, then move outside our parenthesis to simplify \(2(12)+9=24+9=33\text{.}\)
Solving equations involving a function is what we do when we know an output and use the function to determine the inputs that would produce that output. Solving a function could produce more than one solution, since different inputs can produce the same output. Since solving an equation is the "opposite" of evaluating an equation, it can be helpful to think of using the "opposite" order of operations. For example, using our function \(f(x)=2(5x-3)+9\) from above, if we wanted to solve \(f(x)=23\text{,}\) we would need to find the value of \(x\) that makes the equation \(23=2(5x-3)+9\) true. Since our goal is to get \(x\) by itself, we can follow the reverse order of operations to isolate \(x\text{.}\) First, we subtract the 9 to get \(14=2(5x-3)\text{,}\) then divide both sides of the equation by 2 to get \(7=5x-3\text{.}\) Now that we are inside of the parenthesis we can repeat the process by adding 3 and then dividing both sides by 5 to get our solution of \(x=2\text{.}\)
Evaluating \(g(3)\) (read: "\(g\) of 3") means that we need to determine the output value, \(Q\text{,}\) of the function \(g\) given the input value of \(n=3\text{.}\) Looking at the table, we see the output corresponding to \(n=3\) is \(Q=7\text{,}\) allowing us to conclude \(g(3) = 7\text{.}\)
Solving \(g(n) = 6\) means we need to determine what input values, \(n\text{,}\) produce an output value of 6. Looking at the table we see there are two solutions: \(n = 2\) and \(n = 4\text{.}\)
Oftentimes a graph of a relationship can be used to define a function. By convention, graphs are typically created with the input quantity along the horizontal axis and the output quantity along the vertical.
The most common graph has \(y\) on the vertical axis and \(x\) on the horizontal axis, and we say \(y\) is a function of \(x\text{,}\) or \(y = f(x)\) when the function is named \(f\text{.}\)
Looking at the three graphs above, the first two define a function \(y=f(x)\text{,}\) since for each input value along the horizontal axis there is exactly one output value corresponding, determined by the \(y\)-value of the graph. The 3rd graph does not define a function \(y=f(x)\) since some input values, such as \(x=2\text{,}\) correspond with more than one output value.
The vertical line test is a handy way to think about whether a graph defines the vertical output as a function of the horizontal input. Imagine drawing vertical lines through the graph. If any vertical line would cross the graph more than once, then the graph does not define only one vertical output for each horizontal input.
Once you have determined that a graph defines a function, an easy way to determine if it is a one-to-one function is to use the horizontal line test. Draw horizontal lines through the graph. If any horizontal line crosses the graph more than once, then the graph does not define a one-to-one function.
Evaluating a function using a graph requires taking the given input and using the graph to look up the corresponding output. Solving a function equation using a graph requires taking the given output and looking on the graph to determine the corresponding input.
a) To evaluate \(f(2)\text{,}\) we find the input of \(x=2\) on the horizontal axis. Moving up to the graph gives the point \((2, 1)\text{,}\) giving an output of \(y=1\text{.}\)\(f(2) = 1\text{.}\)
b) To solve \(f(x) = 4\text{,}\) we find the value 4 on the vertical axis because if \(f(x) = 4\) then 4 is the output. Moving horizontally across the graph gives two points with the output of 4: \((-1,4)\) and \((3,4)\text{.}\) These give the two solutions to \(f(x) = 4\text{:}\)\(x = -1\) or \(x = 3\text{.}\)
Notice that while the graph in the previous example is a function, getting two input values for the output value of 4 shows us that this function is not one-to-one.
When possible, it is very convenient to define relationships using formulas. If it is possible to express the output as a formula involving the input quantity, then we can define a function.
To express the relationship in this form, we need to be able to write the relationship where \(p\) is a function of \(n\text{,}\) which means writing it as \(p\) = [something involving \(n\)].
Note the important feature of an equation written as a function is that the output value can be determined directly from the input by doing evaluations - no further solving is required. This allows the relationship to act as a machine that takes an input, processes it, and returns an output. Modern technology and computers rely on these functional relationships, since the evaluation of the function can be programmed into machines, whereas solving things is much more challenging.
As with tables and graphs, it is common to evaluate and solve functions involving formulas. Evaluating will require replacing the input variable in the formula with the value provided and calculating. Solving will require replacing the output variable in the formula with the value provided and solving for the input(s) that would produce that output.
a) "Evaluate \(k(2)\)" means we want to find the output when the input is \(t = 2\text{.}\) We plug in the input value 2 into the formula wherever we see the input variable \(t\text{,}\) then simplify
b) "Solve \(k(t) = 1\)" means we want to find the input \(t\) that will give us an output of 1. We set the formula for \(k(t)\) equal to 1, and solve for the input. Starting with the given information:
\begin{equation*}
k(t) = 1,
\end{equation*}
we can then substitute the original formula \(k(t)=t^{3}+2\) to get
\begin{equation*}
t^{3}+2=1.
\end{equation*}
Then subtract 2 from each side to get
\begin{equation*}
t^{3}=-1,
\end{equation*}
and finally take the cube root of each side to get the solution
When solving an equation using formulas, you can check your answer by using your solution in the original equation to see if your calculated answer is correct.
b) Starting with \(h(p) = 3\text{,}\) we substitute the original function \(h(p)=p^{2}+2p\) to get
\begin{equation*}
p^{2}+2p=3.
\end{equation*}
This is quadratic, so we can rearrange the equation to get something equal to 0 by subtracting 3 from each side. So,
\begin{equation*}
p^{2}+2p-3=0.
\end{equation*}
This is factor-able, so we factor it
\begin{equation*}
(p+3)(p-1)=0.
\end{equation*}
By the zero-factor theorem since \((p+3)(p-1)=0\text{,}\) either \((p+3)=0\) or \((p-1)=0\) (or both equal 0) and so we solve both equations for \(p\text{,}\) finding \(p = -3\) from the first equation and \(p = 1\) from the second equation.
In this text, we will be exploring functions - the shapes of their graphs, their unique features, their equations, and how to solve problems with them. When learning to read, we start with the alphabet. When learning to do arithmetic, we start with numbers. When working with functions, it is similarly helpful to have a base set of elements to build from. We call these our "toolkit of functions" - a set of basic named functions for which we know the graph, equation, and special features.
You will see these toolkit functions, combinations of toolkit functions, their graphs and their transformations frequently throughout this book. In order to successfully follow along later in the book, it will be very helpful if you can recognize these toolkit functions and their features quickly by name, equation, graph and basic table values.
Not every important equation can be written as \(y = f(x)\text{.}\) An example of this is the equation of a circle. Recall the distance formula for the distance between two points:
A circle with radius \(r\) with center at \((h, k)\) can be described as all points \((x, y)\) a distance of \(r\) from the center, so using the distance formula, \(r=\sqrt{(x-h)^{2}+(y-k)^{2}}\text{,}\) giving: