Note: The two lines must have identical coefficients of x and y (not just proportional) before applying this formula. If given a1x+b1y+c1=0 and a2x+b2y+c2=0 with a2a1=b2b1=k, first rewrite the second line as a1x+b1y+kc2=0, then apply the formula.