Skip to main content
Mathematics LibreTexts

0.2: Lines in the Plane

  • Page ID
    209799
  • \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    \( \newcommand{\dsum}{\displaystyle\sum\limits} \)

    \( \newcommand{\dint}{\displaystyle\int\limits} \)

    \( \newcommand{\dlim}{\displaystyle\lim\limits} \)

    \( \newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\)

    ( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\)

    \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

    \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\)

    \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

    \( \newcommand{\Span}{\mathrm{span}}\)

    \( \newcommand{\id}{\mathrm{id}}\)

    \( \newcommand{\Span}{\mathrm{span}}\)

    \( \newcommand{\kernel}{\mathrm{null}\,}\)

    \( \newcommand{\range}{\mathrm{range}\,}\)

    \( \newcommand{\RealPart}{\mathrm{Re}}\)

    \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

    \( \newcommand{\Argument}{\mathrm{Arg}}\)

    \( \newcommand{\norm}[1]{\| #1 \|}\)

    \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

    \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    \( \newcommand{\vectorA}[1]{\vec{#1}}      % arrow\)

    \( \newcommand{\vectorAt}[1]{\vec{\text{#1}}}      % arrow\)

    \( \newcommand{\vectorB}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vectorC}[1]{\textbf{#1}} \)

    \( \newcommand{\vectorD}[1]{\overrightarrow{#1}} \)

    \( \newcommand{\vectorDt}[1]{\overrightarrow{\text{#1}}} \)

    \( \newcommand{\vectE}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash{\mathbf {#1}}}} \)

    \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \(\newcommand{\longvect}{\overrightarrow}\)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    \(\newcommand{\avec}{\mathbf a}\) \(\newcommand{\bvec}{\mathbf b}\) \(\newcommand{\cvec}{\mathbf c}\) \(\newcommand{\dvec}{\mathbf d}\) \(\newcommand{\dtil}{\widetilde{\mathbf d}}\) \(\newcommand{\evec}{\mathbf e}\) \(\newcommand{\fvec}{\mathbf f}\) \(\newcommand{\nvec}{\mathbf n}\) \(\newcommand{\pvec}{\mathbf p}\) \(\newcommand{\qvec}{\mathbf q}\) \(\newcommand{\svec}{\mathbf s}\) \(\newcommand{\tvec}{\mathbf t}\) \(\newcommand{\uvec}{\mathbf u}\) \(\newcommand{\vvec}{\mathbf v}\) \(\newcommand{\wvec}{\mathbf w}\) \(\newcommand{\xvec}{\mathbf x}\) \(\newcommand{\yvec}{\mathbf y}\) \(\newcommand{\zvec}{\mathbf z}\) \(\newcommand{\rvec}{\mathbf r}\) \(\newcommand{\mvec}{\mathbf m}\) \(\newcommand{\zerovec}{\mathbf 0}\) \(\newcommand{\onevec}{\mathbf 1}\) \(\newcommand{\real}{\mathbb R}\) \(\newcommand{\twovec}[2]{\left[\begin{array}{r}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\ctwovec}[2]{\left[\begin{array}{c}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\threevec}[3]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\cthreevec}[3]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\fourvec}[4]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\cfourvec}[4]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\fivevec}[5]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\cfivevec}[5]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\mattwo}[4]{\left[\begin{array}{rr}#1 \amp #2 \\ #3 \amp #4 \\ \end{array}\right]}\) \(\newcommand{\laspan}[1]{\text{Span}\{#1\}}\) \(\newcommand{\bcal}{\cal B}\) \(\newcommand{\ccal}{\cal C}\) \(\newcommand{\scal}{\cal S}\) \(\newcommand{\wcal}{\cal W}\) \(\newcommand{\ecal}{\cal E}\) \(\newcommand{\coords}[2]{\left\{#1\right\}_{#2}}\) \(\newcommand{\gray}[1]{\color{gray}{#1}}\) \(\newcommand{\lgray}[1]{\color{lightgray}{#1}}\) \(\newcommand{\rank}{\operatorname{rank}}\) \(\newcommand{\row}{\text{Row}}\) \(\newcommand{\col}{\text{Col}}\) \(\renewcommand{\row}{\text{Row}}\) \(\newcommand{\nul}{\text{Nul}}\) \(\newcommand{\var}{\text{Var}}\) \(\newcommand{\corr}{\text{corr}}\) \(\newcommand{\len}[1]{\left|#1\right|}\) \(\newcommand{\bbar}{\overline{\bvec}}\) \(\newcommand{\bhat}{\widehat{\bvec}}\) \(\newcommand{\bperp}{\bvec^\perp}\) \(\newcommand{\xhat}{\widehat{\xvec}}\) \(\newcommand{\vhat}{\widehat{\vvec}}\) \(\newcommand{\uhat}{\widehat{\uvec}}\) \(\newcommand{\what}{\widehat{\wvec}}\) \(\newcommand{\Sighat}{\widehat{\Sigma}}\) \(\newcommand{\lt}{<}\) \(\newcommand{\gt}{>}\) \(\newcommand{\amp}{&}\) \(\definecolor{fillinmathshade}{gray}{0.9}\)

    The first graphs and functions you encountered in algebra were straight lines and their equations. These lines  were easy to graph, and the equations were easy to evaluate and to solve. They described a variety of physical, biological and financial phenomena such as \(d = rt\) relating the distance \(d\) traveled to the rate \(r\) and time \(t\) spent  traveling, and \(C = \frac59 (F - 32)\) for converting the temperature in degrees Fahrenheit (\(F\)) to degrees Celsius (\(C\)).

    The first part of calculus — differential calculus — will deal with ideas, techniques and applications of tangent lines to the graphs of functions, so it is important that you understand the graphs, properties and equations of straight lines.

    The Real Number Line

    The real numbers (consisting of all integers, fractions, rational and irrational numbers) can be represented as a  line, called the real number line. Once we have selected a starting location, called the origin, a positive direction (usually up or to the right), and unit of length, then every number can be located as a point on the number line.

    A number line with -2, -1, 0, 1 and 2 marked and 0 labeled as the origin.

    If we move from a point \(x = a\) to a point \(x = b\) on the line, then we  will have moved an increment of \(b - a\). We denote this increment with the symbol \( \Delta x \) (read “delta x”).

    A horizontal line with two points marked a (on the left) and b (on the right). A line segment with arrows on both ends denotes the distance between a and b, labeled as Delta x = b - a.

    Note

    The capital Greek letter delta (\(\Delta\)) appears often in calculus to represent the “change” in something.

    Caution

    \(\Delta x\) does not mean \(\Delta\) times \(x\), but rather the difference between two \(x\)-coordinates.

    • If \(b\) is larger than \(a\), then we will have moved in the positive direction, and \(\Delta x = b - a\) will be positive.
    • If \(b\) is smaller than \(a\), then \(\Delta x = b - a\) will be negative and we will have moved in the negative direction.
    • Finally, if \(\Delta x = b - a =0\), then \(a=b\) and we did not move at all.

    We can also use the \(\Delta\) notation and absolute values to express the distance that we have moved. On the number line,  the distance from \(x = a\) to \(x = b\) is
    \[\mbox{dist}(a,b) = \left\{
    \begin{array}{lr}
           b - a & \mbox{if }  b \geq a\\
           a - b & \mbox{if }  b < a\\
         \end{array}\right. \nonumber\]
    or:
    \[\mbox{dist}(a,b) = \left|b - a\right| = \left|\Delta x\right| = \sqrt{(\Delta x)^2}\nonumber\]

    The midpoint of the interval from \(x = a\) to \(x = b\) is the point \(M\) such that \(\mbox{dist}(a,M) = \mbox{dist}(M,b)\), or \(|M-a| = |b-M|\). If \(a < M < b\),\[M-a = b - M \Rightarrow 2M = a+b \Rightarrow M = \frac{a+b}{2}\nonumber\]It’s not difficult to check that this formula also works when \(b < M < a\).

    Example \(\PageIndex{1}\)

    Find the length and midpoint of the interval from \(x = -3\) to \(x = 6\).

    Solution

    \(\mbox{dist}(-3,6) = \left|6 - (-3) \right| = \left| 9 \right| = 9\); \(M = \frac{(-3) + 6}{2} = \frac32\).

    Practice \(\PageIndex{1}\)

    Find the length and midpoint of the interval from \(x = -7\) to \(x = -2\).

    Answer

    Length \(= \mbox{dist}( -7, -2 ) = | (-7) - (-2) | = | -5 | = 5\). The midpoint is at \(\displaystyle \frac{(-7) + (-2)}{2} = \frac{-9}{2} = - 4.5\).

    Note

    You should work through each of the Practice problems as you encounter them when reading this book. You can click on “Answer” above to check your answer and see a solution.

    The Cartesian Plane

    Two perpendicular number lines, called coordinate axes, determine a real number plane. The axes intersect at a point called the origin. Each point \(P\) in the plane can be described by an ordered pair \((x,y)\) of numbers that specify how far, and in which directions, we must move from the origin to reach the point \(P\). We can locate the point \(P = (x,y)\) in the plane by starting at the origin and moving \(x\) units horizontally and then \(y\) units vertically. Similarly, we can label each point in the plane with the ordered pair \((x,y)\), which directs us how to reach that point from the origin.

    a graph with x- and y-axes labeled -2, -1, 0, 1, 2, the point where the axes crossed labeled as the origin, and a point 2 units to the left and 1 unit up from the origin labeled as (2,1) 

    In this book, a point in the plane will be labeled either with a name, say \(P\), or with an ordered pair, say \((x,y)\), or with both: \(P = (x,y)\).}

    This coordinate system is called the rectangular coordinate system or the Cartesian coordinate system (after René Descartes), and the resulting plane the Cartesian plane. The coordinate axes divide the plane into four quadrants, labeled quadrants I, II, III and IV moving counterclockwise from the upper-right quadrant. We will often call the horizontal axis the \(\boldsymbol{x}\)-axis and the vertical axis the \(\boldsymbol{y}\)-axis and then refer to the plane as the \(\boldsymbol{xy}\)-plane. This choice of (x\) and \(y\) as labels for the axes is a common choice, but we will sometimes prefer to use different labels — and even different units of measurement — on the two axes.

    x- and y-axes, with the upper-right region labeled quadrant I, the upper-left region labeled II, lower-left region labeled III and lower-right region labeled IV 

    Increments and Distance Between Points in the Plane

    If we move from a point \(P = (x_1,y_1)\) in the plane to another point \(Q = (x_2,y_2)\), then we will need to consider two increments or changes.

    • The increment in the \(x\) (horizontal) direction is \(x_2 - x_1\), denoted by \(\Delta x = x_2 - x_1\). 
    • The increment in the \(y\) (vertical) direction is \(y_2 - y_1\), denoted by \(\Delta y = y_2 - y_1\). 

    The first quadrant of a Cartesian plane, with points (x1,y1) and (x2,y2) shown; the distance between x1 and x2 is labeled as "rise" and the distance between y1 and y2 is labeled as "run."

    Computing the distance between the points \(P = (x_1,y_1)\) and \(Q = (x_2,y_2)\) involves a simple application of the Pythagorean Theorem:\[\mbox{dist}(P,Q) = \sqrt{(\Delta x)^2 + (\Delta y)^2}= \sqrt{(x_2 - x_1)^2 + (y_2 - y_1)^2}\nonumber\]The midpoint \(M\) of the line segment joining \(P\) and \(Q\) is:\[M = \left(\frac{x_1 + x_2}{2}, \frac{y_1 + y_2}{2}\right)\nonumber\]where we have just used the one-dimension midpoint formula for each coordinate.

    Example \(\PageIndex{2}\)

    Find an equation describing all the points \(P = (x,y)\) equidistant from \(Q = (2,3)\) and \(R = (5,-1)\).

    The first quadrant of a Cartesian plane with points P at (x,y), Q at (2,3) and R at (5,-1), along with a line through P.

    Solution

    The points \(P=(x,y)\) must satisfy \(\mbox{dist}(P,Q) = \mbox{dist}(P,R)\) so:\[\sqrt{(x-2)^2+(y-3)^2} = \sqrt{(x-5)^2 +(y-(-1))^2}\nonumber\]By squaring each side we get:\[(x-2)^2 +(y-3)^2 = (x-5)^2+(y+1)^2\nonumber\]Expanding we get:\[x^2 - 4x + 4 + y^2 - 6y + 9 = x^2 - 10x + 25 + y^2 + 2y + 1\nonumber\]and canceling like terms yields:\[-4x - 6y + 13 = -10x + 2y + 26\nonumber\]so \(y = 0.75x - 1.625\), the equation of a line. Every point on the line \(y = 0.75x - 1.625\) is equally distant from both \(Q\) and \(R\).

    Practice \(\PageIndex{2}\)

    Find an equation describing all points \(P = (x,y)\) equidistant from \(Q = (1,-4)\) and \(R = (0,-3)\).

    Answer

    \(\displaystyle \mbox{dist}(P,Q) = \mbox{dist}(P,R) \Rightarrow (x - 1)^2 + (y + 4)^2 = (x - 0)^2 + (y + 3)^2\); squaring each side and simplifying eventually yields \(y = x - 4\).

     A circle with radius \(r\) and center at the point \(C = (a,b)\) consists of all points \(P = (x,y)\) at a distance of \(r\) from the center \(C\): the points \(P\) that satisfy \(\mbox{dist}(P,C) = r\).

    Example \(\PageIndex{3}\)

    Find an equation of a circle with radius \(r = 4\) and center\(C = (5,-3)\).

    A circle centered at (5,-3) with radius 4.

    Solution

    A circle consists of the set of points \(P=(x,y)\) at a fixed distance \(r\) from the center point \(C\), so this circle will be the set of points\(P=(x,y)\) at a distance of\(4\) units from the point\(C= (5,-3)\); \(P\) will be on this circle if \(\mbox{dist}(P,C) = 4\). 

    Using the distance formula and rewriting:\[\sqrt{(x-5)^2 + (y+3)^2} = 4 \quad \Rightarrow \quad (x-5)^2 + (y+3)^2 =16\nonumber\]which we can also express as \(x^2 - 10x + 25 + y^2 + 6y + 9 = 16\).

    Practice \(\PageIndex{3}\)

    Find an equation of a circle with radius \(r = 5\) and center\(C = (-2,6)\).

    Answer

    The point \(P = ( x , y)\) is on the circle when it is \(5\) units from the center \(C = ( -2, 6)\), so \(\mbox{dist}(P,C) = 5\). Then \(\mbox{dist}\left( (x,y) , (-2,6) \right) = 5\), so \(\sqrt{(x + 2)^2 + (y - 6)^2} = 5 \, \Rightarrow \, (x + 2)^2 + (y - 6)^2 = 25\).

    The Slope Between Points in the Plane

    In one dimension (on the number line), our only choice was to move in the positive direction (so the \(x\)-values  were increasing) or in the negative direction. In two dimensions (in the plane), we can move in infinitely many directions, so we need a precise way to describe direction.

    The slope of the line segment joining \(P = (x_1,y_1)\) to \(Q = (x_2,y_2)\) is\[m = \mbox{slope from }P\mbox{ to }Q  = \frac{\mbox{rise}}{\mbox{run}} = \frac{y_2-y_1}{x_2-x1} = \frac{\Delta y}{\Delta x} \nonumber\nonumber\]

    The first quadrant of a Cartesian plane, with points (x1,y1) and (x2,y2) shown, along with a line passing through these points; the distance between x1 and x2 is labeled as "rise" and the distance between y1 and y2 is labeled as "run,"

    The slope of a line measures how fast we rise or fall as we move from left to right along the line. It measures the rate of change of the \(y\)-coordinate with respect to changes in the \(x\)-coordinate. Most of our work will occur in two dimensions, and slope will be a very useful concept that will appear often.

    If \(P\) and \(Q\) have the same \(x\)-coordinate, then \(x_1 = x_2 \Rightarrow x = 0\). The line from \(P\) to \(Q\) is thus vertical and the slope \(m = \frac{\Delta y}{\Delta x}\) is undefined because \(\Delta x = 0\). If \(P\) and \(Q\) have the same \(y\)-coordinate, then \(y_1 = y_2 \Rightarrow \Delta y = 0\), so the line is horizontal and the slope is \(m = \frac{\Delta y}{\Delta x} = \frac{0}{\Delta x} = 0\) (assuming \(\Delta x \ne 0\)).

    Practice \(\PageIndex{4}\)

    For \(P = (-3,2)\) and \(Q = (5,-14)\), find \(\Delta x\), \(\Delta y\), and the slope of the line segment from\(P\) to\(Q\).

    Answer

    \(\Delta x = 5 - (-3) = 8\) and \(\Delta y = -14 - 2 = -16\), so: \(\displaystyle \mbox{slope} = \frac{\Delta y}{\Delta x} = \frac{-16}{8} = - 2\)

    If the coordinates of \(P\) or \(Q\) contain variables, then the slope \(m\) is still given by \(m = \frac{\Delta y}{\Delta x}\), but we will need to use algebra to evaluate and simplify \(m\).

    Example \(\PageIndex{4}\)

    Find the slope of the line segment from\(P = (1,3)\) to\(Q = (1+h, 3 + 2h)\).

    A line in the first quadrant passing through (1,) and (1+h,2+h), with the x-increment labeled as h and the y-increment as 2+h.

    Solution

    \(y_1 = 3\) and \(y_2 = 3 + 2h\), so \(\Delta y = (3 + 2h) - (3) = 2h\); \(x_1 = 1\) and\(x_2 = 1 + h\), so\(\Delta x = (1 + h) - (1) = h\). The slope is:\[m = \frac{\Delta y}{\Delta x} = \frac{2h}{h} = 2\nonumber\]In this example, the value of \(m\) is constant (\(2\)) and does not depend on the value of \(h\).

    Practice \(\PageIndex{5}\)

    Find the slope and midpoint of the line segment from \(P = (2,-3)\) to \(Q = (2 + h, -3 + 5h)\).

    Answer

    slope \(\displaystyle = \frac{\Delta y}{\Delta x} = \frac{(3a^2 + 5a) - (3x^2 + 5x)}{a - x} = \frac{3(a^2- x^2) + 5(a - x)}{a - x} = \frac{3(a + x)(a - x) + 5(a - x)}{a - x} = 3(a + x) + 5\)

    Example \(\PageIndex{5}\)

    Find the slope between the points \(P = (x, x^2 + x )\) and \(Q = (a, a^2 + a)\) for \(a \ne x\).

    Solution

    \(y_1 = x^2 + x\) and \(y_2 = a^2 + a \Rightarrow \Delta y = (a^2 + a) - (x^2 + x)\); \(x_1 = x\) and \(x_2 = a\), so \(\Delta x = a-x\) and the slope is: \begin{align*} m &= \frac{\Delta y}{\Delta x} = \frac{(a^2+a) - (x^2 +x)}{a-x}\\ &= \frac{a^2 - x^2 + a - x}{a - x} = \frac{(a-x)(a+x) + (a-x)}{a - x}\\ &= \frac{(a-x)\left((a+x) + 1\right)}{a - x} = (a + x) + 1\end{align*}Here the value of \(m\) depends on the values of both \(a\) and \(x\).

    Practice \(\PageIndex{6}\)

    Find the slope between the points \(P = (x, 3x^2 + 5x)\) and \(Q = (a, 3a^2 + 5a)\) for \(a \ne x\).

    Answer

    slope \(\displaystyle = \frac{\Delta y}{\Delta x} = \frac{(-3 + 5h) - (-3)}{(2 + h) - 2} = \frac{5h}{h} = 5\). The midpoint is at \(\displaystyle \left(\frac{(2) + (2 + h)}{2}, \frac{(-3 + 5h) + (-3)}{2}\right) = \left(2 + \frac{h}{2}, -3 + \frac{5h}{2}\right)\)

    In application problems, it is important to read the information and the questions very carefully — including the units of measurement of the variables can help you avoid “silly” answers.

    Example \(\PageIndex{6}\)

    In 1970, the population of Houston was 1,233,535 and in 1980 it was 1,595,138. Find the slope of the line through the points \((1970, 1233535)\) and \((1980, 1595138)\).

    Solution

    \(\displaystyle m = \frac{\Delta y}{\Delta x} = \frac{1595138 - 1233535}{1980 - 1970} = \frac{361603}{10} = 36,160.3\) but \(36,160.3\) is just a number that may or may not have any meaning to you.

    If we include the units of  measurement along with the numbers we will get a more meaningful result:\[\frac{1595138\mbox{ people} - 1233535\mbox{ people}}{\mbox{year }1980 - \mbox{year }1970} = \frac{361603\mbox{ people}}{10\mbox{ years}} = 36,160.3 \, \frac{\mbox{people}}{\mbox{year}}\nonumber\]which says that during the decade from 1970 to 1980 the population of Houston grew at an average rate of \(36,160\) people per year.

    If the \(x\)-unit is time (in hours) and the \(y\)-unit is distance (in kilometers), then\[m = \frac{\Delta y \mbox{ km}}{\Delta x \mbox{ hours}}\nonumber\]so the units for \(m\) are \(\frac{\mbox{km}}{\mbox{hour}}\) (``kilometers per hour''), a measure of velocity, the rate of change of distance with respect to time.

    If the \(x\)-unit is the number of employees at a bicycle factory and the \(y\)-unit is the number of bicycles manufactured, then\[m = \frac{\Delta y \mbox{ bicycles}}{\Delta x \mbox{ employees}}\nonumber\]and the units for \(m\) are \(\frac{\mbox{bicycles}}{\mbox{employee}}\) (``bicycles per employee''), a measure of the rate of production per employee.

    Equations of Lines

    Every (non-vertical) line has the property that the slope of the segment between any two points on the line is the same, and this constant slope property of straight lines leads to ways of finding equations to represent non-vertical lines.

    Point-Slope Form

    In calculus, we will usually know a point on a line and the slope of that line, so the point-slope form will be the easiest to apply. Other forms of equations for lines can be derived from the point-slope form.

    A line in the first quadrant passing through (x,y) and (x1,y1), with the labels "m = slope" and "equation: y-y1=m(x-x1)."

    If \(L\) is a non-vertical line through a known point \(P = (x_1,y_1)\) with a known slope \(m\), then the equation of the line \(L\) is:

    Point-Slope: \(y - y_1 = m(x - x_1)\)

    Example \(\PageIndex{7}\)

    Find an equation of the line through \((2,-3)\) with slope \(5\).

    A line in the fourth quadrant passing through (2,-3) and labeled "m= 5."

    Solution

    We can simply use the point-slope formula: \(m = 5\), \(y_1 = -3\) and \(x_1 = 2\), so \(y - (-3) = 5(x - 2)\), which simplifies to \(y = 5x - 13\).

    An equation for a vertical line through a point \(P = (a,b)\) is \(x = a\). All points \(Q = (x,y)\) on the vertical line through the point \(P\) have the same (x\)-coordinate as \(P\). 

    Two-Point Form

    If two points \(P = (x_1,y_1)\) and \(Q = (x_2,y_2)\) are on the line \(L\), then we can calculate the slope between them and use the first point and the point-slope equation to find an equation for $L$:

    Two-Point: \(y - y_1 = m(x - x_1)\) where \(\displaystyle m = \frac{y_2 - y_1}{x_2 - x_1}\)

    Once we have the slope, \(m\), it does not matter whether we use \(P\) or \(Q\) as the point. Either choice will result in the same equation for the line once we simplify it.

    Slope-Intercept Form

    It is common practice to rewrite an  equation of a line into the form \(y = mx + b\), the slope-intercept form of the line. The line \(y = mx + b\) has slope \(m\) and crosses the \(y\)-axis at the point \((0, b)\).

    Practice \(\PageIndex{7}\)

    Use the \(\frac{\Delta y}{\Delta x}\) definition of slope to calculate the slope of the line \(y = mx + b\).

    Answer

    Let \(y_1 = m x_1 + b\) and \(y_2 = m x_2 + b\). Then:\[\mbox{slope} = \frac{\Delta y}{\Delta x} = \frac{(mx_2 + b) - (mx_1 + b)}{x_2 - x_1} = \frac{m(x_2 - x_1)}{x_2 - x_1} = m\]

    The point-slope and the two-point forms are usually more useful for finding an equation of a line, but the slope-intercept form is usually the most useful form for an answer because it allows us to easily picture the graph of the line and to quickly calculate \(y\)-values given \(x\)-values.

    Angles Between Lines

    The angle of inclination of a line with the \(x\)-axis is the smallest angle $\(\theta\) that the line makes with the positive (x\)-axis as measured from the \(x\)-axis counterclockwise to the line.

    A line passing through a point on the positive x-axis and a point in the first quadrant. The x-increment between these points is labeled Delta x and the y-increment Delta y. The angle between the line and the positive x-axis is labeled theta. The text above the line reads "m = Delta y / Delta x = tan(theta)."

    Because the slope \(m = \frac{\Delta y}{\Delta x}\) and because \(\tan(\theta) = \frac{\mbox{opposite}}{\mbox{adjacent}}\) in a right triangle, \(m = \tan(\theta)\).

    The slope of a line is the tangent of its angle of inclination.

    Parallel Lines

    Two parallel lines \(L_1\) and \(L_2\) make equal angles with the \(x\)-axis, so their angles of inclination will be equal and hence so will their slopes.

    Two parallel lines with positive slopes in the first quadrant, with L1 on the left and L2 on the right. The angles between each line and the positive x-axis is labeled theta.

    Similarly, if the slopes, \(m_1\) and \(m_2\), of two lines are equal, then the equations of the lines (in slope-intercept form) will always differ by a constant:\[y_1 - y_2 = (m_1 x + b_1) - (m_2 x + b_2) = (m_1 - m_2)x + (b_1 - b_2) = b_1 - b_2 \nonumber \]which is a constant, so the lines will be parallel.

    The two preceding ideas can be combined into a single statement:

    Two non-vertical lines \(L_1\) and \(L_2\) with slopes \(m_1\) and \(m_2\) are parallel if and only if \(m_1 = m_2\).

    Practice \(\PageIndex{8}\)

    Find an equation of the line that contains the point \((-2,3)\) and is parallel to the line \(3x + 5y = 17\).

    A red line labeled x+5y=17 and a parallel dashed-blue line passing through (-2,3).

    Answer

    The line \(3x + 5y = 17\) has slope \(-\frac{3}{5}\), so the slope of the parallel line is \(m = -\frac{3}{5}\). Using the form \(y = -\frac{3}{5} x + b\) and the point \(( -2, 3)\) on the line, we have \(3 = -\frac{3}{5} (-2) + b \Rightarrow b = \frac95 \Rightarrow y = -\frac{3}{5} x + \frac95\), 
    or \(5y + 3x = 9\).

    Perpendicular Lines

    If two lines are perpendicular, the situation is a bit more complicated.

    Assume \(L_1\) and \(L_2\) are two non-vertical lines that intersect at the origin (for simplicity), with \(P = (x_1,y_1)\) and \(Q = (x_2,y_2)\) points away from the origin on \(L_1\) and \(L_2\), respectively.

    Lines L1 (with negative slope) and L2 (with positive slope) pass through the origin. P(x1,y1) is on L1 and Q(x2,y2) is on L2, with P and Q connected by a line segment.

    Then the slopes of \(L_1\) and \(L_2\) will be \(m_1 = \frac{y_1}{x_1}\) and \(m_2 = \frac{y_2}{x_2}\). The line connecting \(P\) and \(Q\) forms the third side of triangle \(OPQ\), which will be a right triangle if and only if \(L_1\) and \(L_2\) are perpendicular. 

    In particular, \(L_1\) and \(L_2\) are perpendicular if and only if the triangle \(OPQ\) satisfies the Pythagorean Theorem:\[\left(\mbox{dist}(O,P)\right)^2 + \left(\mbox{dist}(O,Q)\right)^2 = \left(\mbox{dist}(P,Q)\right)^2\nonumber\]or:\[(x_1-0)^2 + (y_1-0)^2 + (x_2-0)^2 + (y_2-0)^2 = (x_1-x_2)^2 + (y_1 - y_2)^2\nonumber\]Squaring and simplifying, this reduces to \(0 = -2x_1 x_2 - 2y_1 y_2\), so:\[\frac{y_2}{x_2} = -\frac{x_1}{y_1} \Rightarrow m_2 = \frac{y_2}{x_2} = -\frac{x_1}{y_1} = -\frac{1}{\frac{y_1}{x_1}} = -\frac{1}{m_1}\nonumber\]We have just proved the following result:

    Theorem

    Two non-vertical lines \(L_1\) and \(L_2\) with slopes \(m_1\) and \(m_2\) are perpendicular if and only if their slopes are negative reciprocals of each other: \(\displaystyle m_2 = -\frac{1}{m_1}\).

    Practice \(\PageIndex{9}\)

    Find an equation of the line that goes through the point \((2,-5)\) and is perpendicular to the line \(3y - 7x = 2\).

    Answer

    The line \(3y - 7x = 2\) has slope \(\frac73\), so the slope of the perpendicular line is \(m = -\frac37\). Using the form \(y = -\frac37 x + b\) and the point \((2, -5)\) on the line, we have \(-5 = -\frac37 (2) + b \Rightarrow b = -\frac{29}{7} \Rightarrow y = -\frac37 x - \frac{29}{7}\), or \(7y + 3x = -29\).

    Example \(\PageIndex{8}\)

    Find the distance (that is, the shortest distance) from the point \((1,8)\) to the line \(L: 3y - x = 3\).

    Solution

    This is a sophisticated problem that requires several steps to solve. First we need a picture of the problem:

    The blue line 3y-x=3 is shown in the first quadrant, along with a dashed-red line segment (labeled L*) perpendicular to the blue line and extending from that line to a point at (1,8).

    We will find an equation for the line \(L^{*}\) through the point \((1,8)\) and perpendicular to \(L\). Then we will find the point \(P\) where \(L\) and \(L^{*}\) intersect. Finally, we will find the distance from \(P\) to \((1,8)\).

    Step 1: \(L\) has slope \(\frac13\) so \(L^{*}\) has slope \(m = -\frac{1}{\frac13} = -3\), and \(L^{*}\) has equation \(y - 8 = -3(x - 1)\), which simplifies to \(y = -3x + 11\).

    Step 2: We can find the point where \(L$ intersects \(L^{*}\) by replacing the \(y\)-value in the equation for \(L\) with the \(y\)-value from our equation for \(L^{*}\):\[3(-3x + 11) - x = 3 \Rightarrow x = 3 \Rightarrow y = -3x + 11 = -3(3) + 11 = 2\nonumber

    \]which tells us that \(L\) and \(L^{*}\) intersect at \(P = (3,2)\).

    Step 3: Finally, the distance from \(L\) to \((1,8)\) is just the distance from the point \((1,8)\) to the point \(P = (3,2)\), which is\[\sqrt{(1 - 3)^2 + (8 - 2)^2} = \sqrt{40} \approx 6.325 \nonumber \]The distance is (exactly) \(\sqrt{40}\), or (approximately) 6.325.

    Angle Formed by Intersecting Lines

    If two lines that are not perpendicular intersect at a point (and neither line is vertical), then we can use some geometry and trigonometry to determine the angles formed by the intersection of those lines.

    Because \(\theta_2\) in the figure below is an exterior angle of the triangle \(ABC\), \(\theta_2\) is equal to the sum of the two opposite interior angles, so \(\theta_2 = \theta_1 + \theta \Rightarrow \theta = \theta_2 - \theta_1\):

    Line L1 makes an angle of theta1 with a horizontal line, and line L2 makes an angle of theta2. They intersect at a point above the horizontal line, with the angle of intersection labeled theta.

    From trigonometry, we then know that:\[\tan(\theta) = \tan(\theta_2 - \theta_1) = \frac{\tan(\theta_2) - \tan(\theta_1)}{1 + \tan(\theta_2)\tan(\theta_1)} = \frac{m_2 - m_1}{1 + m_2 m_1} \nonumber \]The range of the \(\arctan\) function is \(\left[-\frac{\pi}{2}, \frac{\pi}{2}\right]\), so \(\theta = \arctan\left(\frac{m_2 - m_1}{1 + m_2 m_1}\right)\) always gives the smaller of the angles. The larger angle is \(\pi - \theta\) (or \(180^{\circ} - \theta^{\circ}\) if we measure the angles in degrees). 

    The smaller angle \(\theta\) formed by two non-perpendicular lines with slopes \(m_1\) and \(m_2\) is:\[\theta = \arctan\left(\frac{m_2 - m_1}{1 + m_2 m_1}\right) \nonumber \]

    Example \(\PageIndex{9}\)

    Find the point of intersection and the angle between the lines \(y = x + 3\) and \(y = 2x + 1\).

    The lines y = 2x+1 and y=x+3 intersect at (2,5), where the angle of intersection is labeled theta.

    Solution

    Solving the first equation for \(y\) and then substituting into the second equation:\[(x + 3) = 2x + 1 \quad \Rightarrow \quad x = 2 \quad \Rightarrow \quad y = 2 +3 = 5 \nonumber \]The point of intersection is \((2,5)\). Because both lines are in slope-intercept form, it is easy to see that \(m_1 = 1\) and \(m_2 = 2\):\begin{align*}\theta &= \arctan\left(\frac{m_2 - m_1}{1 + m_2 m_1}\right) = \arctan\left(\frac{2 - 1}{1 + 2\cdot 1}\right)\\ &= \arctan\left(\frac13\right) \approx 0.322\mbox{ radians} = 18.43^{\circ}\end{align*}The lines intersect at an angle of (approximately) \(18.43^{\circ}\).

    Problems

    1. Estimate the slope of each line shown below.
      A red line labeled a passes through (0,3) and (4,0); blue line b passes through (-2,0) and (0,1); dashed-pink line c is horizontal and passes through (0,1); green line d passes through (0,-1) and (1,1); dashed-black line e is vertical and passes through (1,0).
    2. Estimate the slope of each line shown below.
      A red line labeled a passes through (0,0) and (1,-2); dashed-black line b passes through (0,0) and (1,-1); blue line c passes through (-2,0) and (0,2); dash-pink line d is horiztonal and passes through (0,-1) and (1,1); green line e passes through (-1,-1) and (1,2).
    3. Compute the slope of the line that passes through:
      1. \((2,4)\) and\((5,8)\)
      2. \((-2,4)\) and\((3,-5)\)
      3. \((2,4)\) and\((x,x^2)\)
      4. \((2,5)\) and\((2+h, 1+ (2+h)^2)\)
      5. \((x,x^2 + 3)\) and\((a, a^2 + 3)\)
    4. Compute the slope of the line that passes through:
      1. \((5,-2)\) and \((3,8)\)
      2. \((-2,-4)\) and \((5,-3)\)
      3. \((x,3x+5)\) and \((a,3a+5)\)
      4. \((4,5)\) and \((4+h, 5-3h)\)
      5. \((1,2)\) and \((x, 1+x^2)\)
      6. \((2,-3)\) and \((2+h, 1-(1+h)^2)\)
      7. \((x,x^2)\) and \((x+h, x^2+2xh+h^2)\)
      8. \((x,x^2)\) and \((x-h, x^2-2xh+h^2)\)
    5.  A small airplane at an altitude of 5,000 feet is flying east at 300 feet per second (a bit over 200 miles per hour), and you are watching it with a small telescope as it passes directly overhead.
      A blue airplane has a dashed-line horizontal path marked as 5000 feet above the solid-line horizontal ground. A line segment extends from a point on the ground to the airplane, with is to the right and above the point on the ground.
      1. What is the slope of the telescope 5, 10 and 20 seconds after the plane passes overhead?
      2. What is the slope of the telescope \(t\) seconds after the plane passes overhead?
      3. After the plane passes overhead, is the slope of the telescope increasing, decreasing or staying the same?
    6. You are at the origin, \((0,0)\), and are watching a small bug at the point \((t, 1+t^2)\) at time \(t\) seconds.
      1. What is the slope of your line of vision when \(t = 5\), \(10\) and \(15\) seconds?
      2. What is the slope of your line of vision at an arbitrary time \(t\)?
    7. The blocks in a city are all perfect squares. A friend gives you directions to a good restaurant: “Go north 3 blocks, turn east and go 5 blocks, turn south and go 7 blocks, turn west and go 3 blocks.” How far away (straight-line distance) is it?
    8. At the restaurant (see previous problem), a fellow diner gives you directions to a hotel: “Go north 5 blocks, turn right and go 6 blocks, turn right and go 3 blocks, turn left and go 2 blocks.” How far away is the hotel from the restaurant?
    9. The bottom of a \(20\)-foot ladder is \(4\) feet from the base of a wall.
      1. How far up the wall does the ladder reach?
      2. What is the slope of the ladder?
      3. What angle does it make with the ground?
    10. Let \(P = (1, -2)\) and \(Q = (5, 4)\). Find:
      1. the midpoint \(R\) of the line segment \(PQ\).
      2. the point \(T\) that is \(\frac13\) of the way from \(P\) to \(Q\):
        \( \qquad \mbox{dist}(P,T) = \frac13 \mbox{dist}(P,Q)\)
      3. the point \(S\) that is \(\frac25\) of the way from \(P\) to \(Q\).
    11. If \(P = (2,3)\), \(Q = (8,11)\) and \(R = (x,y)\), where:
      \( \qquad x = 2a + 8(1-a), \ y = 3a + 11(1-a), \ 0 \leq a \leq 1\)
      1. Verify that \(R\) is on the line segment \(PQ\).
      2. Verify that \(\mbox{dist}(P,R) = (1-a) \cdot \mbox{dist}(P,Q)\).
    12. A rectangular box is 24 inches long, 18 inches wide and 12 inches high.
      1. Find the length of the longest (straight) stick that will fit into the box.
      2. What angle (in degrees) does that stick make with the base of the box?
    13. The lines \(y = x\) and \(y = 4 - x\) intersect at \((2, 2)\).
      1. Show that the lines are perpendicular.
      2. Graph the lines together on your calculator using the “window” \(\left[-10,10\right]\times\left[-10,10\right]\).
      3. Why do the lines not appear to be perpendicular on the calculator display?
      4. Find a suitable window so that the lines do appear perpendicular.
    14. Two lines both go through the point \((1, 2)\), one with slope \(3\) and one with slope \(-\frac13\).
      1. Find equations for the lines.
      2. Choose a suitable window so that the lines will appear perpendicular, and then graph them together on your calculator
    15. Sketch the line with slope \(m\) that goes through the point \(P\), then find an equation for the line.
      1. \(m = 3\), \(P = (2,5)\)
      2. \(m = -2\), \(P = (3,2)\)
      3. \(m = -\frac12\), \(P=(1,4)\)
    16. Sketch the line with slope \(m\) that goes through the point \(P\), then find an equation for the line.
      1. \(m = 5\), \(P = (2,1)\)
      2. \(m = -\frac23\), \(P = (1,3)\)
      3. \(m = \pi\), \(P=(1,-3)\)
    17. Find an equation for each line.
      1. \(L_1\) goes through the point \((2, 5)\) and is parallel to \(3x - 2y = 9\).
      2. \(L_2\) goes through the point \((-1,2)\) and is perpendicular to \(2x = 7-3y\).
      3. \(L_3\) goes through the point \((3, -2)\) and is perpendicular to \(y = 1\)
    18. Find a value for the constant \(A\), \(B\) or \(D\) so that:
      1. the line \(y = 2x + A\) goes through \((3,10)\).
      2. the line \(y = Bx + 2\) goes through \((3,10)\).
      3. the line \(y = Dx + 7\) crosses the \(y\)-axis at the point \((0,4)\).
      4. the line \(Ay = Bx + 1\) goes through the points \((1,3)\) and \((5,13)\)
    19. Find the shortest distance between the circles with centers \(C_1 = (1,2)\) and \(C_2 = (7,10)\) with radii \(r_1\) and \(r_2\) when:
      1. \(r_1 = 2\) and \(r_2 = 4\)
      2. \(r_1 = 2\) and \(r_2 = 7\)
      3. \(r_1 = 5\) and \(r_2 = 8\)
      4. \(r_1 = 3\) and \(r_2 = 15\)
      5. \(r_1 = 12\) and \(r_2 = 1\)
    20. Find an equation of the circle with center \(C\) and radius \(r\) when:
      1. \(C = (2,7)\) and \(r = 4\)
      2. \(C = (3,-2)\) and \(r = 1\)
      3. \(C = (-5,1)\) and \(r = 7\)
      4. \(C = (-3,-1)\) and \(r = 4\)
    21. Explain how to show, without graphing, whether a point \(P = (x,y)\) is inside, on, or outside the circle with center \(C = (h,k)\) and radius \(r\).
    22. A box with a base of dimensions \(2\) cm and \(8\) cm is definitely big enough to hold two semicircular rods with radii of \(2\) cm, as shown in this figure:
      A rectangular box of height 2 contains two side-by-side upper semicircles of radius 2.
      1. Will these same two rods fit in a box \(2\) cm high and \(7.6\) cm wide?
      2. Will they fit in a box \(2\) cm high and \(7.2\) cm wide? (Suggestion: Turn one of the rods over.)
    23. Show that an equation of the circle with center \(C = (h,k)\) and radius \(r\) is \((x - h)^2 + (y - k)^2 = r^2\).
    24. Find an equation of the line tangent to the circle \(x^2 + y^2 = 25\) at the point \(P\) when:
      1. \(P = (3,4)\)
      2. \(P = (-4,3)\)
      3. \(P = (0,5)\)
      4. \(P = (-5,0)\)
    25. Find an equation of the line tangent to the circle with center \(C = (3,1)\) at the point \(P\) when:
      1. \(P = (8,13)\)
      2. \(P = (-10,1)\)
      3. \(P = (-9,6)\)
      4. \(P = (3,14)\)
    26. Find the center \(C = (h,k)\) and the radius \(r\) of the circle that goes through the three points:
      1. \((0,1)\), \((1,0)\) and \((0,5)\)
      2. \((1,4)\), \((2,2)\) and \((8,2)\)
      3. \((1,3)\), \((4,12)\) and \((8,4)\)
    27. How close does:
      1. the line \(3x - 2y = 4\) come to the point \((2,5)\)?
      2. the line \(y = 5-2x\) come to the point \((1,-2)\)?
      3. the circle with radius \(3\) and center at \((2,3)\) come to the point \((8,3)\)
    28. How close does:
      1. the line \(2x - 5y = 4\) come to the point \((1,5)\)?
      2. the line \(y = 3 - 2x\) come to the point \((5,-2)\)?
      3. the circle with radius \(4\) and center at \((4,3)\) come to the point \((10,3)\)
    29. Follow the steps below (and refer to the figure below) to find a formula for the distance from the origin to the line \(Ax + By = C\).
      A blue line with negative slope and equation Ax+By=C passes through the positive y-axis and positive x-axis. A dashed-red perpendicular line segment labeled L* intersects the blue line at a point in the first quadrant.
      1. Show that the line \(L\) given by \(Ax + By = C\) has slope \(m = -\frac{A}{B}\).
      2. Find the equation of the line \(L^{*}\) that goes through \((0,0)\) and is perpendicular to \(L\).
      3. Show that \(L\) and \(L^{*}\) intersect at the point: \(\displaystyle (x,y) = \left(\frac{AC}{A^2 + B^2}, \frac{BC}{A^2 + B^2}\right)\)
      4. Show that the distance from the origin to the point \((x,y)\) is: \(\displaystyle \frac{|C|}{\sqrt{A^2 + B^2}}\)
    30. Show that a formula for the distance from the point \((p,q)\) to the line \(Ax + By = C\) is: \(\displaystyle \frac{|Ap + Bq - C|}{\sqrt{A^2 + B^2}}\)
      (The steps will be similar to those in the previous problem, but the algebra will be more complicated.)

    0.2: Lines in the Plane is shared under a CC BY-NC-SA license and was authored, remixed, and/or curated by LibreTexts.

    • Was this article helpful?