In this article, we discuss in detail what a linear function is, its characteristics, equation, formula, graph, table, and go through several examples.
- Linear function definition
- Linear function equation
- Linear function formula
- Linear function graph
- Linear function table
- Linear function examples
- Linear functions - key takeaways
Linear Function Definition
What is a linear function?
A linear function is a polynomial function with a degree of 0 or 1. This means that each term in the function is either a constant or a constant multiplied by a single variable whose exponent is either 0 or 1.
When graphed, a linear function is a straight line in a coordinate plane.
By definition, a line is straight, so saying "straight line" is redundant. We use "straight line" often in this article, however, just saying "line" is sufficient.
Linear Function Characteristics
Linear vs Nonlinear Functions
Linear functions are a special type of polynomial function. Any other function that does not form a straight line when graphed on a coordinate plane is called a nonlinear function.
Some examples of nonlinear functions are:
- any polynomial function with a degree of 2 or higher, such as
- quadratic functions
- cubic functions
- rational functions
- exponential and logarithmic functions
When we think of a linear function in algebraic terms, two things come to mind:
The equation and
The formulas
Linear Function Equation
A linear function is an algebraic function, and the parent linear function is:
Which is a line that passes through the origin.
In general, a linear function is of the form:
Where and are constants.
In this equation,
- is the slope of the line
- is the y-intercept of the line
- is the independent variable
- or is the dependent variable
Linear Function Formula
There are several formulas that represent linear functions. All of them can be used to find the equation of any line (except vertical lines), and which one we use depends on the available information.
Since vertical lines have an undefined slope (and fail the vertical line test), they are not functions!
Standard Form
The standard form of a linear function is:
Where are constants.
Slope-intercept Form
The slope-intercept form of a linear function is:
Where:
Point-slope Form
The point-slope form of a linear function is:
Where:
Intercept Form
The intercept form of a linear function is:
Where:
Graphing a Linear Function
What information do we need to graph a linear function? Well, based on the formulas above, we need either:
Using Two Points
To graph a linear function using two points, we need to either be given two points to use, or we need to plug in values for the independent variable and solve for the dependent variable to find two points.
If we are given two points, graphing the linear function is just plotting the two points and connecting them with a straight line.
If, however, we are given a formula for a linear equation and asked to graph it, there are more steps to follow.
Using Slope and y-intercept
To graph a linear function using its slope and y-intercept, we plot the y-intercept on a coordinate plane, and use the slope to find a second point to plot.
Graph the function:
Solution:
- Plot the y-intercept, which is of the form: .
- The y-intercept for this linear function is:
- Write the slope as the fraction (if it isn't one already!) and identify the "rise" and the "run".
- For this linear function, the slope is .
- So, and .
- Starting at the y-intercept, move vertically by the "rise" and then move horizontally by the "run".
- Note that: if the rise is positive, we move up, and if the rise is negative, we move down.
- And note that: if the run is positive, we move right, and if the run is negative, we move left.
- For this linear function,
- We "rise" up by 1 unit.
- We "run" right by 2 units.
- Connect the points with a straight line, and extend it past both points.
- So, the graph looks like:
- Using the slope and y-intercept to graph a line, StudySmarter Originals
Domain and Range of a Linear Function
So, why do we extend the graph of a linear function past the points we use to plot it? We do that because the domain and range of a linear function are both the set of all real numbers!
Domain
Any linear function can take any real value of as an input, and give a real value of as an output. This can be confirmed by looking at the graph of a linear function. As we move along the function, for every value of , there is only one corresponding value of .
Therefore, as long as the problem doesn't give us a limited domain, the domain of a linear function is:
Range
Also, the outputs of a linear function can range from negative to positive infinity, meaning that the range is also the set of all real numbers. This can also be confirmed by looking at the graph of a linear function. As we move along the function, for every value of , there is only one corresponding value of .
Therefore, as long as the problem doesn't give us a limited range, and , the range of a linear function is:
When the slope of a linear function is 0, it is a horizontal line. In this case, the domain is still the set of all real numbers, but the range is just b.
Linear Function Table
Linear functions can also be represented by a table of data that contains x- and y-value pairs. To determine if a given table of these pairs is a linear function, we follow three steps:
Calculate the differences in the x-values.
Calculate the differences in the y-values.
Compare the ratio for each pair.
We can also check if a table of x- and y-values represents a linear function by determining if the rate of change of with respect to (also known as the slope) remains constant.
Typically, a table representing a linear function looks something like this:
Identifying a Linear Function
To determine if a function is a linear function depends on how the function is presented.
If a function is presented algebraically:
If a function is presented graphically:
If a function is presented using a table:
Determine if the given table represents a linear function.
x-value | y-value |
3 | 15 |
5 | 23 |
7 | 31 |
11 | 47 |
13 | 55 |
Solution:
To determine if the values given in the table represent a linear function, we need to follow these steps:
- Calculate the differences in x-values and y-values.
- Calculate the ratios of difference in x over difference in y.
- Verify whether the ratio is the same for all X,Y pairs.
- If the ratio is always the same, the function is linear!
Let's apply these steps to the given table:
Determining if a table of values represents a linear function, StudySmarter Originals
Since every number in the green box in the image above are the same,
the given table represents a linear function.
Special Types of Linear Functions
There are a couple of special types of linear functions that we will likely deal with in calculus. These are:
Piecewise Linear Functions
In our study of calculus, we will have to deal with linear functions that may not be uniformly defined throughout their domains. It could be that they are defined in two or more ways as their domains are split into two or more parts.
In these cases, these are called piecewise linear functions.
Inverse Linear Functions
Likewise, we will also deal with inverse linear functions, which are one of the types of Inverse Functions. To briefly explain, if a linear function is represented by:
Then its inverse is represented by:
such that
The superscript, -1, is not a power. It means "the inverse of", not "f to the power of -1".
Linear Function Examples
Real-World Applications of Linear Functions
There are several uses in the real world for linear functions. To name a few, there are:
Distance and rate problems in physics
Calculating dimensions
Determining prices of things (think taxes, fees, tips, etc. that are added to the price of things)
Say you enjoy playing video games.
You subscribe to a gaming service that charges a monthly fee of $5.75 plus an additional fee for each game you download of $0.35.
We can write your actual monthly fee using the linear function:
Where is the number of games you download in a month.
Linear Functions: Solved Example Problems
Write the given function as ordered pairs.
Solution:
The ordered pairs are: and .
The relationship between Fahrenheit and Celsius is linear. The table below shows a few of their equivalent values. Find the linear function representing the given data in the table.
Celsius (°C) | Fahrenheit (°F) |
5 | 41 |
10 | 50 |
15 | 59 |
20 | 68 |
Solution:
- To start, we can pick any two pairs of equivalent values from the table. These are the points on the line.
- Let's choose and .
- Calculate the slope of the line between the two chosen points.
- , so the slope is 9/5.
- Write the equation of the line using point-slope form.
- - point-slope form of a line.
- - substitute in values for .
- - distribute the fraction and cancel terms.
- - simplify.
- Note that based on the table,
- We can replace , the independent variable, with , for Celsius, and
- We can replace , the dependent variable, with , for Fahrenheit.
- So we have:
- is the linear relationship between Celsius and Fahrenheit.
Let's say that the cost of renting a car can be represented by the linear function:
Where is the number of days the car is rented.
What is the cost to rent the car for 10 days?
Solution:
- Substitute into the given function.
- - substitute.
- - simplify.
So, the cost of renting the car for 10 days is $320.
Linear Functions - Key takeaways
- A linear function is a function whose equation is: and its graph is a straight line.
- A function of any other form is a nonlinear function.
- There are forms the linear function formula can take:
- Standard form:
- Slope-intercept form:
- Point-slope form:
- Intercept form:
- If the slope of a linear function is 0, it is a horizontal line, which is known as a constant function.
- A vertical line is not a linear function because it fails the vertical line test.
- The domain and range of a linear function is the set of all real numbers.
- But the range of a constant function is just , the y-intercept.
- A linear function can be represented using a table of values.
- Piecewise linear functions are defined in two or more ways as their domains are split into two or more parts.
- Inverse linear function pairs are symmetric with respect to the line .
- A constant function has no inverse because it is not a one-to-one function.
How we ensure our content is accurate and trustworthy?
At StudySmarter, we have created a learning platform that serves millions of students. Meet
the people who work hard to deliver fact based content as well as making sure it is verified.
Content Creation Process:
Lily Hulatt is a Digital Content Specialist with over three years of experience in content strategy and curriculum design. She gained her PhD in English Literature from Durham University in 2022, taught in Durham University’s English Studies Department, and has contributed to a number of publications. Lily specialises in English Literature, English Language, History, and Philosophy.
Get to know Lily
Content Quality Monitored by:
Gabriel Freitas is an AI Engineer with a solid experience in software development, machine learning algorithms, and generative AI, including large language models’ (LLMs) applications. Graduated in Electrical Engineering at the University of São Paulo, he is currently pursuing an MSc in Computer Engineering at the University of Campinas, specializing in machine learning topics. Gabriel has a strong background in software engineering and has worked on projects involving computer vision, embedded AI, and LLM applications.
Get to know Gabriel