Solveeit Logo

Question

Mathematics Question on Slope of a line

Find the distance between P(x1,y1) and Q(x2,y2) when: (i) PQ is parallel to the y-axis, (ii) PQ is parallel to the x-axis

Answer

The given points are P(x1,y1) and Q(x2,y2).
(i) When PQ is parallel to the y-axis, x1 = x2.
In this case, distance between P and Q =(x2x1)2+(y2y1)2=\sqrt{(x_2-x_1)^2+(y_2-y_1)^2}

=(y2y1)2=\sqrt{(y_2-y_1)^2}

=y2y1=|y_2-y_1|

(ii) When PQ is parallel to the x-axis, y1 = y2.
In this case, distance between P and Q =(x2x1)2+(y2y1)2=\sqrt{(x_2-x_1)^2+(y_2-y_1)^2}

=(x2x1)2=\sqrt{(x_2-x_1)^2}

=x2x1=|x_2-x_1|