2.1 Equations of straight lines

2.1 Equations of straight lines

IB Maths: Analysis and Approaches SL: Revision notes

Studying this course? Keep your progress in one place.

Key facts

  • Three forms: y=mx+cy = mx + c, ax+by+d=0ax + by + d = 0 and y−y1=m(x−x1)y - y_1 = m(x - x_1).
  • Gradient m=y2−y1x2−x1m = \dfrac{y_2 - y_1}{x_2 - x_1}; find intercepts by setting x=0x = 0 or y=0y = 0.
  • Parallel lines: m1=m2m_1 = m_2. Perpendicular lines: m1m2=−1m_1m_2 = -1.
  • In context, gradient = vertical change ÷\div horizontal change, in the same units.

Three forms of a line

The same line can be written in gradient-intercept, general or point-gradient form; rearrange between them as needed.

  • Gradient–intercept form: y=mx+cy = mx + c, where mm is the gradient and cc the yy-intercept.
  • General form: ax+by+d=0ax + by + d = 0. Examiners often ask for integer aa, bb, dd.
  • Point–gradient form: y−y1=m(x−x1)y - y_1 = m(x - x_1).
−6−4−2246−6−4−22468xyy = mx + c
Change mm and cc to see how the line moves. The line crosses the yy-axis at cc.

Worked example

Write 3x−4y+12=03x - 4y + 12 = 0 in the form y=mx+cy = mx + c.

What is the gradient of 2x+5y−10=02x + 5y - 10 = 0?

Gradient and intercepts

The gradient is the change in yy over the change in xx; the intercepts are where x=0x=0 and y=0y=0.

A positive gradient slopes up to the right; a negative one slopes down. The yy-intercept is found by setting x=0x = 0; the xx-intercept by setting y=0y = 0.

−3−2−1123−4−2246xy(0, 1)(½, 0)y = −2x + 1
The line y=−2x+1y = -2x + 1 has yy-intercept 1 and xx-intercept 12\frac12.
  • Gradientm=y2−y1x2−x1m = \dfrac{y_2 - y_1}{x_2 - x_1}

What is the gradient of the line through (1,2)(1, 2) and (4,11)(4, 11)?

Parallel and perpendicular

Parallel lines have equal gradients; perpendicular lines have gradients that multiply to −1-1.

For gradients m1m_1 and m2m_2: parallel if m1=m2m_1 = m_2; perpendicular if m1×m2=−1m_1\times m_2 = -1, i.e. m2=−1m1m_2 = -\frac{1}{m_1}, the negative reciprocal.

−6−4−22468−4−22468xy(6, −1)y = ¾x + 34x + 3y = 21
Perpendicular lines meet at a right angle. Their gradients are 34\frac34 and −43-\frac43.

Worked example

Find the line perpendicular to y=34x+3y = \frac34x + 3 through (6,−1)(6, -1).

Which line is perpendicular to y=2x+1y = 2x + 1?

Intersections and distance

Solve two equations together to find where lines meet; the shortest distance from a point is along the perpendicular.

A point lies on a line if its coordinates satisfy the equation. For the shortest distance, find the foot of the perpendicular (an intersection) and use (x2−x1)2+(y2−y1)2\sqrt{(x_2-x_1)^2 + (y_2-y_1)^2}.

shortestABFP
The shortest distance from PP to the line is the perpendicular PFPF.

Which point lies on y=2x−3y = 2x - 3?

Gradients in context

Inclines are described by a decimal, a ratio or a percentage: always use the horizontal distance and consistent units.

A road rising 84 m over a horizontal 1200 m has gradient 841200=0.07\frac{84}{1200} = 0.07, i.e. 7%7\%. In a model y=mx+cy = mx + c, mm is the rate of change and cc the starting value.

2004006008001000120020406080100xy(1200, 84)y = 0.07x
A road rising 84 m over 1200 m of horizontal distance: y = 0.07x, a 7% gradient.
  • Percentage gradientverticalhorizontal×100\dfrac{\text{vertical}}{\text{horizontal}}\times100

A path rises 15 m over a horizontal distance of 300 m. What is its percentage gradient?

Try an exam question

The line L1L_1 has equation 2x+3y=122x + 3y = 12. The line L2L_2 is perpendicular to L1L_1 and passes through (4,1)(4, 1). Find the equation of L2L_2 in the form ax+by+d=0ax + by + d = 0 with integer aa, bb, dd.

[4 marks]

That's the notes covered.

Carry on to the next subtopic.

Try a question

Find the gradient of L1L_1.

1 mark, marked against the mark scheme

Revision notes