Math
Linear Function Graph (y = ax + b)
Enter slope a and intercept b to plot the graph of y = ax + b. Calculate y for any x value, and hover over the graph to check coordinates.
Tips
- Slope a represents how much y changes when x increases by 1. If a > 0, the line slopes upward; if a < 0, it slopes downward.
- Intercept b is the point where the graph crosses the y-axis (the y-intercept). It equals the value of y when x = 0.
- The x-intercept (where the graph crosses the x-axis) is found by solving y = 0: x = −b ÷ a. If a = 0, there is no intersection (horizontal line), unless b = 0, in which case y = 0 (along the x-axis).
- Hover over the graph to see the (x, y) coordinates of that point in a tooltip. To find y for a specific x, enter the x value in the input field on the left.
FAQ
Side Note — Why a Linear Function Is Called "Linear"
The function y = ax + b is called a "linear function" because its graph is always a straight line. The word "linear" comes from the Latin "linearis," meaning "of a line." Strictly speaking, mathematicians sometimes distinguish "linear" (b = 0, passing through the origin) from "affine" (b ≠ 0), but in everyday usage and in most school curricula, both are called linear functions.
Linear functions are used as foundational models in physics, economics, statistics, and many other fields. For example, "if you travel at 60 km/h, the distance y after t hours is y = 60t" is a linear function with slope 60 and intercept 0. Linear regression (least squares) is also a technique for finding the best-fitting linear function y = ax + b for a given dataset.