Pure 3.1 - Equation of a straight line

Pure 3.1 - Equation of a straight line

A straight-line equation describes every point on a line with just a few constants. You will connect those constants to gradients, intercepts and perpendicular directions, then build and interpret straight-line models.

Gradient, intercept and equation forms

Can the Celsius and Fahrenheit readings ever be the same number? Their conversion graph is a straight line, but its intercept is not zero. We will build that line and find the meeting temperature by the end.

Start with a simpler line: from (2,2)(2, 2) to (6,4)(6, 4), moving 44 units right raises the height by 22. That is a rise of 12\frac12 for every unit right.

You already know

A coordinate pair gives horizontal position first and vertical position second. Substitution checks whether a point lies on a graph: (2,2)(2, 2) satisfies y=12x+1y=\frac12x+1, because 2=12(2)+12=\frac12(2)+1.

The same rise-to-run ratio applies between any two distinct points on a non-vertical straight line.

Gradient and intercept

The gradient is the change in yy divided by the change in xx. The yy-intercept is the value of yy at x=0x=0. For example, y=12x+1y=\frac12x+1 has gradient 12\frac12 and intercept 11. A vertical line has no finite gradient.

The picture links the ratio to the graph. A negative gradient descends as you move right; zero gradient gives a horizontal line.

[DIAGRAM: asset_slug: p1_3_1_understand_and_use_the_equation_of_a_straight_line_in_the_x_y_plane__diagram_01; asset_name: Gradient as rise over run; caption: A rise of 2 for a run of 4 gives gradient one half; description: Coordinate graph of y equals one half x plus 1 with points (2, 2) and (6, 4), a rise-run triangle and y-intercept (0, 1)]
A rise of 2 for a run of 4 gives gradient one half

Gradient and equation forms

For distinct points with x2≠x1x_2\ne x_1,

m=y2−y1x2−x1,y=mx+cm=\frac{y_2-y_1}{x_2-x_1},\qquad y=mx+c

In the second form, cc is the yy-intercept. The general form is ax+by+c=0ax+by+c=0, where aa and bb are not both zero. Its constant cc is generally not the intercept. Not in the formula booklet: learn it.

To read a finite gradient from general form, make yy the subject first.

Worked example 1: reading an expanded equation

Question. Find the gradient and yy-intercept of 4x−2y+6=04x-2y+6=0.

Plan. Rearrange into y=mx+cy=mx+c, then read the two constants.

−2y=−4x−6move the other termsy=2x+3divide every term by −2\begin{aligned} -2y&=-4x-6 &&\text{move the other terms}\\ y&=2x+3 &&\text{divide every term by }-2 \end{aligned}

Why this step? The coefficient of xx is the gradient only when the coefficient of yy is 11.

Answer. Gradient 22, yy-intercept 33.

Check. At x=0x=0, the original equation gives −2y+6=0-2y+6=0, so y=3y=3.

Change only the sign of the yy term. This reverses both signs after rearrangement, so watch the whole equation.

Worked example 2: a changed sign

Question. Find the gradient and yy-intercept of 4x+2y+6=04x+2y+6=0.

Plan. Isolate yy before interpreting the coefficients.

2y=−4x−6subtract 4x+6y=−2x−3divide by 2\begin{aligned} 2y&=-4x-6 &&\text{subtract }4x+6\\ y&=-2x-3 &&\text{divide by }2 \end{aligned}

Why this step? Reading 44 straight from the original equation would ignore the rearrangement.

Answer. Gradient −2-2, yy-intercept −3-3.

Check. The points (0,−3)(0, -3) and (1,−5)(1, -5) both satisfy the original equation and give gradient −2-2.

The exceptional lines still fit general form: x=4x=4 is vertical and y=−1y=-1 is horizontal. Only the second has a finite gradient.

Watch out

Wrong: “3x+2y−8=03x+2y-8=0 has intercept −8-8.” Right: y=−32x+4y=-\frac32x+4, so its intercept is 44. The constant in general form is not automatically the intercept.

Try the same reading method with one changed constant.

Finding a line through points

Two distinct points fix exactly one straight line. For a non-vertical line, find its gradient and attach it to one of the points.

Take A(2,−1)A(2, -1) and B(8,3)B(8, 3). Their horizontal separation is 66, so the gradient calculation is possible. Any other point (x,y)(x, y) on their line must share that same gradient from AA.

Point-gradient form

A non-vertical line through (x1,y1)(x_1, y_1) with gradient mm has equation

y−y1=m(x−x1)y-y_1=m(x-x_1)

It follows by multiplying y−y1x−x1=m\frac{y-y_1}{x-x_1}=m by x−x1x-x_1; the resulting equation also includes the known point. Not in the formula booklet: learn it.

Either known point works. Choose the one whose signs make the substitution easiest.

Worked example 3: two points to general form

Question. Find the line through A(2,−1)A(2, -1) and B(8,3)B(8, 3) in the form ax+by+c=0ax+by+c=0.

Plan. Calculate the gradient, use AA, then clear the denominator.

m=3−(−1)8−2=23rise divided by runy+1=23(x−2)use A3y+3=2x−4multiply by 3\begin{aligned} m&=\frac{3-(-1)}{8-2}=\frac23 &&\text{rise divided by run}\\ y+1&=\frac23(x-2) &&\text{use }A\\ 3y+3&=2x-4 &&\text{multiply by }3 \end{aligned}

Why this step? Point-gradient form uses both the direction and the position; a gradient alone describes many parallel lines.

Answer. 2x−3y−7=02x-3y-7=0.

Check. Substitution gives 4+3−7=04+3-7=0 at AA and 16−9−7=016-9-7=0 at BB.

Change only the height of BB, from 33 to −5-5. The line now falls, but the method stays put.

Worked example 4: a negative gradient

Question. Find the line through A(2,−1)A(2, -1) and B(8,−5)B(8, -5) in general form.

Plan. Keep the subtraction order consistent, then use AA.

m=−5−(−1)8−2=−23same point ordery+1=−23(x−2)point-gradient form3y+3=−2x+4clear the fraction\begin{aligned} m&=\frac{-5-(-1)}{8-2}=-\frac23 &&\text{same point order}\\ y+1&=-\frac23(x-2) &&\text{point-gradient form}\\ 3y+3&=-2x+4 &&\text{clear the fraction} \end{aligned}

Why this step? Both coordinate differences must run from the same first point to the same second point.

Answer. 2x+3y−1=02x+3y-1=0.

Check. At AA, 4−3−1=04-3-1=0; at BB, 16−15−1=016-15-1=0.

If the two xx-coordinates agree, stop before dividing: points such as (2,−1)(2, -1) and (2,5)(2, 5) give the vertical line x=2x=2. Two identical points do not determine a unique line.

Watch out

Wrong: m=−5+12−8=23m=\frac{-5+1}{2-8}=\frac23, mixing point orders. Right: m=−5+18−2=−23m=\frac{-5+1}{8-2}=-\frac23. A quick sketch would also expose the wrong sign.

Now change the second point's height again and keep the requested final form.

Parallel and perpendicular lines

Sliding a line without rotating it keeps its gradient. Turning its direction through a right angle swaps the roles of rise and run and reverses one sign.

For instance, direction steps (4,3)(4, 3) and (3,−4)(3, -4) give gradients 34\frac34 and −43-\frac43. Their product is −1-1.

[DIAGRAM: asset_slug: p1_3_1_understand_and_use_the_equation_of_a_straight_line_in_the_x_y_plane__diagram_02; asset_name: Parallel and perpendicular directions; caption: Parallel lines share a gradient while perpendicular finite gradients multiply to minus one; description: Two panels show parallel lines of gradient three quarters and perpendicular lines of gradients three quarters and minus four thirds]
Parallel lines share a gradient while perpendicular finite gradients multiply to minus one

Parallel and perpendicular gradients

For distinct non-vertical parallel lines, m′=mm'=m. For perpendicular lines with finite gradients,

mm′=−1,m′=−1m(m≠0)mm'=-1,\qquad m'=-\frac1m\quad(m\ne0)

A horizontal line is perpendicular to a vertical line; handle that case directly. Not in the formula booklet: learn it.

First identify the given gradient, then decide which relationship the question needs. Equal gradients can also describe the very same line, so check the point if distinct parallel lines are required.

Worked example 5: perpendicular to a given line

Question. Find the line perpendicular to 4x+3y−6=04x+3y-6=0 through (6,−2)(6, -2).

Plan. Read the original gradient, take its negative reciprocal and use the new point.

y=−43x+2isolate ym′=34negative reciprocaly+2=34(x−6)use the required point\begin{aligned} y&=-\frac43x+2 &&\text{isolate }y\\ m'&=\frac34 &&\text{negative reciprocal}\\ y+2&=\frac34(x-6) &&\text{use the required point} \end{aligned}

Why this step? The perpendicular line needs the reciprocal gradient, not the original direction.

Answer. 3x−4y−26=03x-4y-26=0.

Check. (−43)(34)=−1(-\frac43)(\frac34)=-1, and 18+8−26=018+8-26=0 at the point.

Change only the relationship from perpendicular to parallel. The same original line and point now lead to a different answer.

Worked example 6: parallel instead

Question. Find the line parallel to 4x+3y−6=04x+3y-6=0 through (6,−2)(6, -2).

Plan. Keep the gradient and use point-gradient form.

m′=−43parallel directiony+2=−43(x−6)use (6,−2)3y+6=−4x+24clear the denominator\begin{aligned} m'&=-\frac43 &&\text{parallel direction}\\ y+2&=-\frac43(x-6) &&\text{use }(6,-2)\\ 3y+6&=-4x+24 &&\text{clear the denominator} \end{aligned}

Why this step? Changing “perpendicular” to “parallel” changes the direction rule, not the line-through-a-point method.

Answer. 4x+3y−18=04x+3y-18=0.

Check. Both lines have gradient −43-\frac43; the new equation gives 24−6−18=024-6-18=0.

For a vertical starting line such as x=4x=4, a parallel line through (6,−2)(6, -2) is x=6x=6, and a perpendicular one is y=−2y=-2.

Watch out

Wrong: a perpendicular to gradient −43-\frac43 has gradient 43\frac43. Right: it has gradient 34\frac34. Change the sign and invert the fraction.

Change the point and retain the parallel requirement.

Straight-line models

A sensor that gives 1.2 V1.2\,\mathrm V at 10∘C10^\circ\mathrm C and 2.0 V2.0\,\mathrm V at 30∘C30^\circ\mathrm C rises by 0.8 V0.8\,\mathrm V over 20∘C20^\circ\mathrm C. Assuming a straight response between these readings turns that rate into the gradient of a model.

Straight-line model

A straight-line model assumes one quantity changes at a constant rate with another: y=mx+cy=mx+c. The gradient is that rate and the intercept is the predicted value at x=0x=0. Two measurements fit a line exactly but do not prove the actual relationship is linear.

A conversion scale and a measured sensor response can share the same algebra while having different reliability. A calibration range belongs with its model.

[DIAGRAM: asset_slug: p1_3_1_understand_and_use_the_equation_of_a_straight_line_in_the_x_y_plane__diagram_03; asset_name: Straight-line models and units; caption: The gradient has units of output per unit input; description: Celsius-Fahrenheit conversion through (0, 32) and (100, 212), beside a distance-time model s equals 8t plus 2 with intercept 2 metres and gradient 8 metres per second]
The gradient has units of output per unit input

Worked example 7: fitting a sensor model

Question. Model the sensor readings above as V=aT+bV=aT+b. Interpret aa.

Plan. Divide the output change by the temperature change, then use one reading for bb.

a=2.0−1.230−10=0.04volts per degree Celsius1.2=0.04(10)+buse the first readingb=0.8subtract 0.4\begin{aligned} a&=\frac{2.0-1.2}{30-10}=0.04 &&\text{volts per degree Celsius}\\ 1.2&=0.04(10)+b &&\text{use the first reading}\\ b&=0.8 &&\text{subtract }0.4 \end{aligned}

Why this step? The intercept must be found from a point; it is not the first measured voltage unless its temperature is zero.

Answer. V=0.04T+0.8V=0.04T+0.8. The voltage rises by 0.04 V0.04\,\mathrm V per 1∘C1^\circ\mathrm C, under the model.

Check. At T=30T=30, V=1.2+0.8=2.0V=1.2+0.8=2.0. The readings support use between 10∘C10^\circ\mathrm C and 30∘C30^\circ\mathrm C.

Change only the second voltage, to 2.4 V2.4\,\mathrm V. The intercept must be recalculated as well as the gradient.

Worked example 8: a changed calibration reading

Question. Fit V=aT+bV=aT+b through (10,1.2)(10, 1.2) and (30,2.4)(30, 2.4), and predict VV at 20∘C20^\circ\mathrm C.

Plan. Fit both constants, then interpolate inside the measured interval.

a=2.4−1.230−10=0.06change divided by changeb=1.2−0.06(10)=0.6use the first readingV(20)=0.06(20)+0.6=1.8substitute the temperature\begin{aligned} a&=\frac{2.4-1.2}{30-10}=0.06 &&\text{change divided by change}\\ b&=1.2-0.06(10)=0.6 &&\text{use the first reading}\\ V(20)&=0.06(20)+0.6=1.8 &&\text{substitute the temperature} \end{aligned}

Why this step? A new rate through a fixed measured point usually changes the intercept too.

Answer. V=0.06T+0.6V=0.06T+0.6, predicting 1.8 V1.8\,\mathrm V.

Check. 2020 is halfway between 1010 and 3030; 1.81.8 is halfway between 1.21.2 and 2.42.4.

The earlier distance model s=8t+2s=8t+2, with ss in metres and tt in seconds, gives constant speed 8 m s−18\,\mathrm{m\,s^{-1}} and initial distance 2 m2\,\mathrm m. In contrast, readings (3,17)(3, 17) and (9,53)(9, 53) give s=6t−1s=6t-1: use it over the observed interval, because its negative prediction at t=0t=0 cannot be a distance.

Watch out

Wrong: “Two correct predictions prove the sensor is linear at every temperature.” Right: the line fits the readings; extending beyond the measured range requires additional evidence. This extension is extrapolation.

Change only the second calibration voltage again; the prediction is still an interpolation.

Choosing the method

The information in a problem tells you where to begin. Two points determine a direction; a perpendicular condition changes that direction; a supplied point locates the required line.

For A(0,4)A(0, 4), B(6,1)B(6, 1), the line ABAB has gradient −12-\frac12. A perpendicular through BB therefore has gradient 22, giving y−1=2(x−6)y-1=2(x-6), or y=2x−11y=2x-11. The point belongs to the new line; the direction comes from the old one.

Given informationFirst mathematical decision
A point and a gradientUse point-gradient form
Two distinct pointsFind the gradient, or recognise a vertical line
A parallel or perpendicular conditionObtain the given gradient before choosing the new one
A conversion model and equal readingsSet the two measured numbers equal and solve

The opening puzzle uses the last row. A linear conversion through (C,F)=(0,32)(C, F)=(0, 32) and (100,212)(100, 212) has gradient 212−32100=95\frac{212-32}{100}=\frac95, so

F=95C+32F=\frac95C+32

At equal readings set F=CF=C:

C=95C+32⇒−45C=32⇒C=−40C=\frac95C+32\quad\Rightarrow\quad-\frac45C=32\quad\Rightarrow\quad C=-40

The surprising fact is that −40∘C-40^\circ\mathrm C and −40∘F-40^\circ\mathrm F are the same temperature. The algebra verifies it: 95(−40)+32=−40\frac95(-40)+32=-40. Unlike a sensor extrapolation, this follows from the conversion rule itself.

Key idea

Choose a starting equation from the information you actually have, then check that the result satisfies every condition in the question.

A useful check can catch a wrong choice before the algebra becomes long. Decide which line below has the first error.

Quick Recap

  • Read gradient and intercept after rearranging to y=mx+cy=mx+c.
  • Use two points for the gradient, then one point in y−y1=m(x−x1)y-y_1=m(x-x_1).
  • Parallel gradients agree; perpendicular finite gradients multiply to −1-1, with horizontal/vertical cases handled directly.
  • Interpret a model's rate, intercept and valid range in context.

The Celsius and Fahrenheit readings agree at −40-40, found by intersecting the conversion line with F=CF=C.