Distance between two parallel lines: Difference between revisions

Content deleted Content added
m Reverted 1 edit by 103.94.216.28 (talk) to last revision by Raycheng200.
Tags: Mobile edit Mobile app edit
Line 8:
Because the lines are parallel, the perpendicular distance between them is a constant, so it does not matter which point is chosen to measure the distance. Given the equations of two non-vertical parallel lines
 
:<math>y = mx+b_1q_1\,</math>
:<math>y = mx+b_2q_2\,,</math>
 
the distance between the two lines is the distance between the two intersection points of these lines with the perpendicular line
Line 18:
 
:<math>\begin{cases}
y = mx+b_1q_1 \\
y = -x/m \, ,
\end{cases}</math>
Line 25:
 
:<math>\begin{cases}
y = mx+b_2q_2 \\
y = -x/m \, ,
\end{cases}</math>
Line 31:
to get the coordinates of the intersection points. The solutions to the linear systems are the points
 
:<math>\left( x_1,y_1 \right)\ = \left( \frac{-b_1mq_1m}{m^2+1},\frac{b_1q_1}{m^2+1} \right)\, ,</math>
 
and
 
:<math>\left( x_2,y_2 \right)\ = \left( \frac{-b_2mq_2m}{m^2+1},\frac{b_2q_2}{m^2+1} \right)\, .</math>
 
The distance between the points is
 
:<math>d = \sqrt{\left(\frac{b_1mq_1m-b_2mq_2m}{m^2+1}\right)^2 + \left(\frac{b_2q_2-b_1q_1}{m^2+1}\right)^2}\,,</math>
 
which reduces to
 
:<math>d = \frac{|b_2q_2-b_1q_1|}{\sqrt{m^2+1}}\,.</math>
 
When the lines are given by