{{ toc.signature }}
{{ toc.name }}
{{ stepNode.name }}
Proceed to next lesson
An error ocurred, try again later!
Chapter {{ article.chapter.number }}
{{ article.number }}.

# {{ article.displayTitle }}

{{ article.introSlideInfo.summary }}
{{ 'ml-btn-show-less' | message }} {{ 'ml-btn-show-more' | message }} expand_more
##### {{ 'ml-heading-abilities-covered' | message }}
{{ ability.description }}

#### {{ 'ml-heading-lesson-settings' | message }}

{{ 'ml-lesson-show-solutions' | message }}
{{ 'ml-lesson-show-hints' | message }}
 {{ 'ml-lesson-number-slides' | message : article.introSlideInfo.bblockCount}} {{ 'ml-lesson-number-exercises' | message : article.introSlideInfo.exerciseCount}} {{ 'ml-lesson-time-estimation' | message }}
When elements of one set are connected somehow with elements of another set, there is a relation between the sets. This lesson will present the formal definition of a relation and its different representations. Also, a particular type of relation, called a function, will be explored in more depth.

### Catch-Up and Review

Here are a few recommended readings before getting started with this lesson.

## Comparing Graphs

Consider the following pair of graphs. Apart from the shape of the graphs, what difference can be established between them? If needed, press the button to show a vertical line. Then, move the line horizontally and watch for the number of times it intersects each graph along the way. ## Relations and Mapping Diagrams

In the previous exploration, each graph represented a certain relationship between the variables and In fact, the value of depends on the value of Next, the definition of relation is developed along with one way of visualizing it.

## Relation

A relation, or relationship, is a rule that relates the elements of one set to the elements of another set. The first set is called the set of inputs and the second set is called the set of outputs. In a relation, an input can have zero outputs, one output, or more than one output. Often, a relation is thought of as a set of ordered pairs of the form In this case, the values represent the inputs and the values the outputs. However, a relation can also be represented using a mapping diagram, a table of values, or a set of points on a coordinate plane. ## Mapping Diagram

A mapping diagram is a graphic tool that helps to visualize a relation. In a mapping diagram, the inputs are listed in one set and the outputs in another. Then, arrows are drawn from each input to its corresponding outputs. This mapping diagram shows the relation defined by the set Note that is the output of two different inputs, and

## Representing a Relation in Different Ways

Ignacio, the younger brother of Kriz, loves watching Kriz's college volleyball games. He recorded Kriz and their teammates' names, ages, and heights. Ignacio is such a curious kid that he wants to describe some relations based on these values. Then he will share them with his big sibling. Represent the relation between Kriz's teammates' ages and heights using a table of values, a mapping diagram, a set of ordered pairs, and points in a coordinate plane.

Table of Values:

Mapping Diagram: Ordered Pairs:
Coordinate Plane: ### Hint

To make a mapping diagram, place all the ages in one set and all the heights in another set. Then, connect each age with its corresponding height using an arrow. To write the relation as a set of ordered pairs, place the ages in the first component and the corresponding heights in the second component.

### Solution

Using the information that Ignacio gathered, a relation between the ages and heights can be made and represented using different visualizations.

### Table of Values

First, organize the relation using a table of values. Place the ages in the first row and the heights in the second row.

### Mapping Diagram

The same relation can be displayed using a mapping diagram. Place the ages in a set and the heights in a different set. Then, connect each age with its corresponding height by using arrows. It is not necessary to write twice in the ages set. ### Set of Ordered Pairs

To write the relation using ordered pairs, the ages will be placed in the first coordinate of each ordered pair, and the corresponding heights will be placed in the second coordinate.

### Points in the Coordinate Plane

Finally, the relation between the ages and heights of the players can be represented using points in the coordinate plane. To do so, the ages will be placed along the horizontal axis and the heights along the vertical axis. Here, the axes will be drawn using different scales. Note that by hovering over each point, the corresponding information is shown.

## Functions, Domain, and Range

Among all the possible relations, those assigning only one output to every input are of particular interest.

## Function

A function is a relation in which each input is assigned to exactly one output. The set of all possible inputs is called the domain of the function and the set of all possible outputs is called the range. If represents the inputs and the outputs of a function, it is often said that is a function of or that depends on

This way of representing the dependent variable is called function notation. A function can be represented using a table, a mapping diagram, an equation, or a graph. Note that every function is a relation, but not every relation is a function. In the following applet, three different relations are analyzed to determine whether they are functions. In Relation III, although one of the outputs corresponds to two different inputs, it is still a function because each input has exactly one output. Depending on how a relation is represented, there are different methods to determine whether or not it is a function.
Determining Whether a Relation Is a Function
If represented as Use
A set of coordinates or a table of values A mapping diagram
A graph in the coordinate plane The Vertical Line Test

## Domain

The domain of a function is the set of all values, or inputs, for which the function is defined. For example, consider the following functions.
By analyzing the definition of each function, their domains can be written.
Function Analysis Domain
Multiplication by is defined for all real numbers. All real numbers.
Square roots are not defined for negative numbers. All non-negative numbers, that is,
Division by zero is undefined. All real numbers except , that is,
Depending on how a function is represented, its domain can be determined using different methods. The domain of a function also depends on what the function describes. For example, let be a function representing the price of apples at a market. Although the function is defined for all real numbers, it does not make sense to find the price of a negative number of apples or a fraction of an apple. Here, the domain of is all non-negative integers.

## Range

The range of a function is the set of all -values, or outputs, of the function. The range of a function depends on both the domain and the function itself. For example, consider the following functions with their corresponding domains.
By analyzing the definition of each function along with the given domains, the ranges can be determined.
Function Domain Analysis Range
All integers.
Every input is multiplied by
Then, every output is an even number.
All even numbers.
All real numbers. Every input is squared. Then, every output is non-negative. All non-negative numbers, that is,
All real numbers. Every input is sent to Only the number that is, the range is
Depending on how a function is represented, its range can be determined using different methods. If two different inputs have the same output, it is not necessary to repeat such output when writing the range.

## Viewing Functions as Machines

A comparison for a function is to think of it as a machine. The inputs are the materials placed in the machine, and the outputs are the objects created. In the following applet, there are four preset inputs. This particular machine only accepts numbers between and to be plugged in as materials. See what happens! ## Methods to Determine Whether a Relation Is a Function

It is essential to determine whether a relation describes a function or not. For example, imagine that a programmer wrote the following relation for a printer's software. If a user selects then they cannot be sure if the document will be printed in black or In this case, the programmer needs to write a relation that is a function. Determining if a relation is a function can be done by using either a mapping diagram or the Vertical Line Test. The appropriate method to be used depends on how the relation is represented.

## Determining if a Relation Is a Function Using Mapping Diagrams

Given a relation, a mapping diagram can be used to determine whether the relation is a function. For example, consider the relation given by the following set of coordinates.
To figure out if a relation is a function, there are four steps to follow.
1
List the Inputs
expand_more

Start by writing all the inputs in a column. When the relation is given as a set of coordinates, the inputs are the first components of each pair. If the relation is given as a vertical table, the inputs are the values in the first column. For the given relation, the inputs are and 2
List the Outputs
expand_more

Write all the outputs in a second column. When the relation is given as a set of coordinates, the outputs are the second components of each pair. If the relation is given as a vertical table, the outputs are the values in the second column. For the given relation, the outputs are and 3
Connect Inputs and Outputs
expand_more

From each input, draw an arrow pointing to its corresponding output. 4
Look For Arrows With the Same Tail
expand_more

Look for different arrows that have the same tail. That is, inputs from which more than one arrow is drawn. By definition, for a relation to be a function, every input must be assigned to exactly one output. Here, the input has two different outputs, and Therefore, the given relation is not a function.

## Vertical Line Test

The vertical line test is a graphical method to determine whether a given relation is a function. For example, consider the following relations.

Relation I Relation II Relation III
To determine whether the above relations are functions, these two steps can be followed.
1
Draw the Relation on the Coordinate Plane
expand_more

Draw the relation on the coordinate plane. The first two relations can be drawn using a graphing calculator or another mathematical software. 2
Draw a Vertical Line and Look at the Intersection Points
expand_more

Draw vertical lines at different places of the coordinate plane. If one line intersects the graph more than once, the relation is not a function. On the contrary, if no vertical line cuts the graph more than once, the relation is a function. Notice that cuts the first graph at two different points. Also, passes through two different points. Then, neither Relation I nor Relation III is a function. In contrast, any vertical line cuts the graph of Relation II at most once. Thus, Relation II is a function.

• Relation I is not a function.
• Relation II is a function.
• Relation III is not a function.

Keep in mind that, before stating that a relation is a function, the vertical lines drawn have to cover the entire domain to ensure that no vertical line cuts the graph more than once.

### Why

Intuition Behind the Method

When a relation is not a function, it is because there are multiple values that proceed from the same value. Therefore, the graph of such relation would show at least two points directly above the other.

Points with the same value belong to the same vertical line.

This is why drawing a vertical line and moving it across the graph reveals if the graph is a function or not. Note that, when concluded that a graph is a function, it must be assumed that the graph of the relation continues without any significant change beyond the boundaries of the coordinate plane. If not, it could never be concluded from a graph that a relation is a function.

## Analyzing Relations Using Mapping Diagrams

Ignacio enjoyed displaying the relations between the ages and heights of Kriz's teammates so much that he wanted to go a step further and continue analyzing relations. He then asked Ramsha and Diego the ages and heights of their family members and wrote that data, including each player's values, in the following sets. Note that means that some member of Ramsha's family is years old and meters tall.

a What is the domain of
What is the range of
b What is the domain of
What is the range of
c Using mapping diagrams, determine which of the sets represents a function?

### Hint

a The domain of a set of coordinate pairs is formed by all the coordinates written first, while the range is formed by all the coordinates written second. When writing sets, do not repeat elements.
b To find the domain, look at the first coordinates of each pair. Similarly, to find the range, look at the second coordinate of each pair. When writing sets, do not repeat elements.
c When represented as a mapping diagram, if only one arrow is drawn from each input, the relation is a function.

### Solution

a Given a set of coordinate pairs, the domain includes all the first coordinates, and the range includes all the second coordinates. By listing the numbers from least to greatest, and including each element only once, the domain and range of are as follows.
b As done in Part A, to find the domain of look at the first coordinate of each pair. To find the range, look at the second coordinate of each pair. By listing the numbers from least to greatest, and including each element only once, the domain and range of are as follows.
c Start by drawing a mapping diagram representing the relation given by the sets and The elements in the domains — the ages — will be grouped in one column, and the elements in the ranges — the heights — will be grouped in a second column. Then, each age will be connected to the corresponding height using an arrow. Remember that for mapping diagrams, a relation is a function if there is only one arrow drawn from each input to an output. In this case, the age is the input. In the first mapping diagram, each age is assigned to only one height. Therefore, represents a function. On the contrary, in the second mapping diagram, is assigned to two different heights. In that case, set cannot represent a function.

Only set represents a function.

By analyzing the two data sets, some other conclusions can be drawn.

• Ramsha's guardians are of different ages and are the same height.
• Ramsha has two siblings.
• Diego's guardians are both years old.
• Diego has one sibling.

Of course, based on the given information, it does not have to be the exact situation. The conclusions were done simply to show one way of interpreting the data recorded.

## Analyzing Graphs Using the Vertical Line Test

Hhaving completed some analysis for Kriz's volleyball team, Ignacio now has some free time. He is digging around his school's library computer. He finds some juicy information about a recently created virtual coin. There is a graph that shows the fluctuation in the coin's exchange rate during its first ten days after it was created. Ignacio accidentally deletes some part of the database code, and whoa! The graph switched the axes labels. Take a look at the shape of the graph. It changed. Ignacio figures he can use what he has learned recently and make sense of all this! a Find the domain and range of the first graph. Write the answer using compound inequalities.
b Find the domain and range of the second graph.
c Which of the two graphs represents a function?

### Hint

a The domain is all the values for which the graph is drawn. Similarly, the range is all the values for which the graph is drawn.
b The domain goes from the minimum to the maximum value along the axis for which the graph is drawn. Similarly, the range goes from the minimum to the maximum value along the axis for which the graph is drawn.
c Use the Vertical Line Test.

### Solution

a To find the domain of the graph, travel along the graph making note of the values. As seen, the graph is drawn for every value from to both ends included. Therefore, the domain is To find the range, look at all the values for which the graph is drawn. The range goes from to both endpoints included. Therefore, the range is
b As in Part A, to find the domain of the graph, travel along the graph making note of the values. From the above, the domain is Next, look at the values. The range goes from to It can be written as
c To determine if the first graph represents a function, the Vertical Line Test can be applied. To do so, draw a vertical line, move it horizontally along the domain, focusing on the intersection point. As seen, any vertical line never intersects the graph more than once. That means the first graph represents a function. Now, repeat the same procedure for the second graph. Unlike the previous graph, here, there is at least one vertical line that intersects the graph more than once. This graph does not represent a function.

Only the first graph represents a function.

At first, Ignacio was glad that his mistake only caused the graph to change domains and ranges. He only realized that it was no longer a function when he applied the vertical line test. He better change it back before someone needs to use the database!

## Analyzing Different Relations

The following applet displays a relation either as a set of ordered pairs, a group of coordinate points in the coordinate plane, or a curve in the coordinate plane. For any given relation, determine whether it is a function. ## Restricting a Relation to Make It a Function

Consider a relation represented by the following graph. Note that any vertical line drawn between and intersects the graph more than once. Then, by the Vertical Line Test, the graph is not a function. However, by changing the relation's domain using and it is possible to convert the graph into a function. Now consider the graph of the relation where the domain is all non-negative numbers and the range is all real numbers. As before, the initial graph is not a function, but it can be converted into a function by restricting either its domain or range. By moving and investigate whether restricting the domain will make the graph a function. As can be seen, no matter where and are placed, the resulting graph cannot be made into a function. Not to give up too soon, try moving and to restrict the range. There it is! In this case, the graph becomes a function when the range is restricted to a set containing either only non-negative or only non-positive numbers.
In conclusion, when given a relation that is not a function, it might be useful to check whether restricting its domain or range can make the relation become a function.
{{ subexercise.title }}