Help Please!!

I need help on writing a program that it will compute and display the angel of equation L1 and L2.

Equation:

L1: A1x + B1y + C1 = 0
L2: A2x + B2y + C2 = 0

O = TAN -1 [m2-m1
1+m2m1
I think you need to show some effort in code before anyone will help you.

BTW, that is not a good way of finding the angle between two lines computationally. If either B is zero then the corresponding gradient m1 or m2 will be infinite, making it very difficult to handle. Better is to note that (A1,B1,0) and (A2,B2,0) give normals to the two lines. The angle between these normals is the same as the angle between the lines, and can be recovered by expressing their scalar product in terms of the cosine of the angle.
Last edited on
Topic archived. No new replies allowed.