To Learning Outcomes
- Determine if a graph is the graph of a function by using the Vertical Line Test.
- Find the value of a function from a graph.
- State the domain and range from the graph of a function in set-builder, inequality, and/or interval notation.
- Evaluate functions at a given input value using an equation. Also, determine inputs resulting in the given output value
- Using the equation of a function, state the domain in set-builder, inequality, and/or interval notation.
Functions
You should be familiar with functions from previous math courses. Here, we’ll do a quick review. Some people think of functions as “mathematical machines.” Imagine you have a machine that changes a number according to a specific rule such as “multiply by [latex]3[/latex] and add [latex]2[/latex]” or “divide by [latex]5[/latex], add [latex]25[/latex], and multiply by [latex]−1[/latex].” If you put a number into the machine, a new number will come out the other end having been changed according to the rule. The number that goes in is called the input, and the number that is produced is called the output.
You can also call the machine “$$f$$” for function. If you put $$x$$ into the machine, $$f(x)$$ (read “$$f$$ of $$x$$”), comes out. Mathematically speaking, $$x$$ is the input, or the independent variable, and $$f(x)$$ is the output, or the dependent variable, since it depends on the value of $$x$$.
Relations and Functions
In mathematics, a relation is a set of ordered pairs. The set of first components of the ordered pairs is called the domain and the set of second components of the ordered pairs is called the range. In a set of ordered pairs, you find the domain by listing all of the input values (the $$x$$-coordinates). To find the range, list all of the output values (the $$y$$-coordinates).
A function is a special type of relation in which each domain value corresponds to exactly one range value.
If you find that you need more help understanding functions, please click on the link to learn more about functions.
Consider the following relation: [latex]\{(−2,0),(0,6),(-2,12),(4,18)\}[/latex].
For this relation, the domain is [latex]\{−2,0,4\}[/latex] and the range is [latex]\{0,6,12,18\}[/latex].
Is the above relation a function or not?
This relation is NOT a function because the input values are not unique, in other words, there is a repeated $$x$$-value that corresponds to different $$y$$-values.
Example
List the domain and range for the following relation where $$x$$ is the input and $$f(x)$$ is the output and determine whether the relation given is a function. Remember each pair of $$x$$ and $$f(x)$$ exists as a point $$(x,f(x))$$ on the graph of the function .
$$x$$ | $$f(x)$$ |
---|---|
[latex]−3[/latex] | [latex]4[/latex] |
[latex]−2[/latex] | [latex]2[/latex] |
[latex]−1[/latex] | [latex]1[/latex] |
[latex]2[/latex] | [latex]4[/latex] |
[latex]3[/latex] | [latex]4[/latex] |
In the following video we provide another example of identifying domain and range. Determine whether the table of values represents a function.
In the above video, each domain value corresponds to exactly one range value. No $$x$$-coordinates were repeated so that relation is a function.
Function Notation
The notation [latex]y=f\left(x\right)[/latex] defines a function named [latex]f[/latex]. The letter [latex]x[/latex] represents the input value, or independent variable. The letter [latex]y[/latex] or [latex]f\left(x\right)[/latex], represents the output value, or dependent variable. When a function is defined by an equation, we usually use function notation.
For example, the equation $$y=3x+1$$ may also be written as $$f(x)=3x+1$$. $$f$$ is the name of the function, $$x$$ is an input from the domain of the function, and $$f(x)$$ is the function value at $$x$$ also called the output.
Inputs of Functions
A function can be evaluated at different values of $$x$$. Given the function $$f(x)=3x+1$$, find $$f(-2)$$. In other words, if $$x$$ is $$-2$$ find $$f(x)$$. We must substitute $$\color{Green}{-2}$$ in place of $$\color{Green}{x}$$ and evaluate.
$$\begin{align} f(\color{Green}{-2}\color{black}{)} &= 3(\color{Green}{-2}\color{black}{)+1}\\ &=-6+1\\ &= -5 \end{align}$$
So, when $$x=-2$$, $$f(x)=-5$$ (or $$y=-5$$). This can be written as the ordered pair $$(-2,-5)$$ and it is a point on the graph of the line $$f(x)=3x+1$$.
It is important to note that the parentheses that are part of function notation do not mean multiply. The notation $$f(x)$$ does not mean $$f$$ multiplied by $$x$$. Instead, the notation means “$$f\text{ of } x$$” or “the function of $$x$$.” To evaluate the function, take the value given for $$x$$, and substitute that value in for $$x$$ in the expression.
Let us look at a couple of examples.
ExAMple
Given [latex]f(x)=3x–4[/latex], evaluate [latex]f(5)[/latex].
Example
Given [latex]p(x)=-2x^{2}+5[/latex], evaluate [latex]p(−3)[/latex].
Example
Given [latex]f(x)=|4x-3|[/latex], evaluate [latex]f(0)[/latex], [latex]f(2)[/latex], and [latex]f(−1)[/latex].
Outputs of Functions
Reconsider the equation [latex]y=4x+1[/latex], which represents a function. If instead of having a given input value, you have a known output value, you can find the input value that would give that output. For example, for an output value of $$-7$$, you can find the input value. First substitute [latex]\color{Green}{y=-7}[/latex] into the equation and then solve for $$x$$.
$$\begin{align}\color{Green}{y} &= 4x+1\\ \color{Green}{-7} &= 4x+1\\ -7-1 &= 4x\\ -8 &= 4x\\ \frac{-8}{4} &= x\\ -2 &= x\\ x &= -2\end{align}$$
The output of $$-7$$ corresponds to an input of $$-2$$. These values make an ordered pair, $$(-2, -7)$$, that represents a point on the graph of this function. We will discuss this idea more fully later in this section.
In the next example, you will not be given the $$x$$-value but instead you will be given a $$y$$-value and asked to find the $$x$$-value.
Example
Given [latex]f(x)=3x–4[/latex], find the [latex]x[/latex]-value that yields an output of [latex]5[/latex].
Try It
Graphs of Functions and the Vertical Line Test
When both the independent quantity (input) and the dependent quantity (output) are real numbers, a function can be represented by a graph in the coordinate plane. The independent value is plotted on the $$x$$-axis and the dependent value is plotted on the $$y$$-axis. The fact that each input value has exactly one output value means graphs of functions have certain characteristics. For each input on the graph, there will be exactly one output. For a function defined as [latex]y = f(x)[/latex], or “$$y$$ is a function of [latex]x[/latex]“, we would write ordered pairs [latex](x, f(x))[/latex] using function notation instead of [latex](x,y)[/latex] as you may have seen previously.
We can identify whether the graph of a relation represents a function because for each $$x$$-coordinate there will be exactly one $$y$$-coordinate. The blue relation graphed below represents a function. Notice that when a vertical line is placed over the graph, the line does not intersect the graph more than once for any value of $$x$$. This indicates that the relation is a function.If instead a graph shows two or more intersections with a vertical line, then an input ($$x$$-coordinate) has more than one output ($$y$$-coordinate), and $$y$$ is not a function of $$x$$.
Examining the graph of a relation to determine if a vertical line would intersect with more than one point is a quick way to determine if the relation shown by the graph is a function. This method is often called the Vertical Line Test.
Example
Use the vertical line test to determine whether the relation plotted on this graph is a function.
Find the Value of a Function from a Graph
Example
A function is graphed below.
- For the given function, evaluate $$f(2)$$.
- For the given graph of a function, find $$x$$ when $$f(x)=-2$$.
ExAmple
A function is graphed below.
- For the given function, evaluate $$f(-1)$$.
- For the given function, evaluate $$f(0)$$.
- For the given graph of a function, find $$x$$ when $$f(x)=2$$.
Try It
Finding the Domain and Range of a Function from its Graph
Finding domain of different functions is often a matter of asking yourself, “what values of $$x$$ can this function not have?” Pictures make it easier to visualize what the domain and range are, so we will first show how to define the domain and range of functions given their graphs. What are the domain and range of the function [latex]f(x)=x+3[/latex]?
This is a linear function. Remember that linear functions are lines that continue forever in each direction.
For this function, any real number can be substituted for $$x$$ and you will get a meaningful output. Also, for any real number, you can always find an $$x$$ value that gives you that number for the output. Unless a linear function is a constant, such as [latex]f(x)=2[/latex], there is no restriction on the range. For the function [latex]f(x)=x+3[/latex], the domain and range are all real numbers. We can write this domain and range in a variety of formats.
Domain | Range | |
Set-Builder Notation | $$\{x|\text{all real numbers}\}$$ | $$\{y|\text{all real numbers}\}$$ |
Inequality Notation | $$-\infty<x<\infty$$ | $$-\infty<y<\infty$$ |
Interval Notation | $$(-\infty,\infty)$$ | $$(-\infty,\infty)$$ |
For the examples that follow, try to figure out the domain and range of the graphs before you look at the answer.
Example
Use the graph to determine the domain and range of the function [latex]f(x)=−3x^{2}+6x+1.[/latex]
Exercises
Use the graph to determine the domain and range of the real-valued function [latex]f(x)=-2+\sqrt{x+5}.[/latex]
Try the following problem, remembering to look at the graph for the lowest and highest $$x$$-values that appear in the graph to find the domain, then for the smallest and highest $$y$$-values to find the range. Make sure to notice if the graph has arrows or endpoints. That will change how you write your answer.
Try It
In the following video we show how to define the domain and range of functions from their graphs.
Finding the Domain and Range from the Equation of a Function
For this discussion, we will restrict all functions to real number values for the domain and range. Even with this starting point, it does not mean that for any function we discuss that all real numbers can be used for $$x$$. It also does not mean that all real numbers can be function output values, $$f(x)$$. There may be restrictions on the domain and range. The restrictions partly depend on the type of function.
Domain restrictions
In our course, there are two main reasons why domains are restricted.
- You cannot divide by [latex]0[/latex].
If you have a function like $$f(x)=\frac{1}{x-2}$$, the domain has to be restricted so that no inputs make the denominator zero. For this example, $$x$$ cannot be $$2$$ because if you replace $$x$$ with $$2$$, you will end up with the denominator as zero which is undefined. The domain would be $$(-\infty,2)\cup(2,\infty)$$. - You cannot take the square (or other even) root of a negative number, as the result will not be a real number.
If you have a function like $$f(x)=\sqrt{x}$$, the domain has to be restricted so that we don’t take the square root of a negative number. Recall that the number or expression written under a root symbol is called the radicand. The radicand of a square (or other even) root must not be negative. Then the domain for this example would be $$x\ge0$$ or $$[0,\infty)$$.
Example
State the domain of the function $$f(x)=\dfrac{x+1}{x-3}$$.
Example
State the domain of the function $$f(x)=\sqrt{2x+1}$$.
In the following video, only watch the first example given. We will talk about the other two examples later in the course.
Try It
State the domain of the function [latex]f\left(x\right)=\sqrt{7-x}[/latex].
Candela Citations
- Revision and Adaptation. Provided by: Lumen Learning. License: CC BY: Attribution
- Ex 1: Find Domain and Range of Ordered Pairs, Function or Not. Authored by: James Sousa (Mathispower4u.com) . Located at: https://youtu.be/kzgLfwgxE8g. License: CC BY: Attribution
- College Algebra. Provided by: OpenStax. Located at: http://cnx.org/contents/9b08c294-057f-4201-9f48-5d6ad992740d@3.278:1/Preface.%20. License: CC BY: Attribution
- Ex: Give the Domain and Range Given the Points in a Table. Authored by: James Sousa (Mathispower4u.com) . Located at: https://youtu.be/GPBq18fCEv4. License: CC BY: Attribution
- Ex: Determine if a Table of Values Represents a Function. Authored by: James Sousa (Mathispower4u.com) . Located at: https://youtu.be/y2TqnP_6M1s. License: CC BY: Attribution