Distance between the two parallel lines represented by ax² + 2hxy + by² + 2gx + 2fy + c = 0, when h² = ab. Equivalently written as 2√((f²−bc)/(b(a+b))) using the y-coefficient form.
Derivation
When ax2+2hxy+by2+2gx+2fy+c=0 represents two parallel lines (h2=ab, af2=bg2), they have the form:
(ax+by+p)(ax+by+q)=0
where p+q=2g/a=2f/b and pq=c.
The two lines are ax+by+p=0 and ax+by+q=0.
Distance between two parallel lines lx+my+p=0 and lx+my+q=0: