Compare exact slopes between consecutive pairs of points to decide whether all three points lie on one line.

Example

Compare slopes to decide whether three plotted points are collinear.

highlighted = computed this step

Step 1 — Plot points

Plot the three test points.

Coordinate plot\text{Coordinate plot}
Collinear test plotPoints A(1, 2), B(3, 6), and C(5, 10).ABC

Step 2 — Slope from A to B

Compute the slope from A to B.

mAB=(62)/(31)=2m_{AB}=( 6 - 2 )/( 3 - 1 )= \hl{2}

Step 3 — Slope from B to C

Compute the slope from B to C.

mBC=(106)/(53)=2m_{BC}=( 10 - 6 )/( 5 - 3 )= \hl{2}

Step 4 — Verdict

Compare slopes to decide collinearity.

mAB=mBCcollinear: yesm_{AB}=m_{BC}\Rightarrow\text{collinear: yes}
collinear-test Three points are collinear when their slopes match.