JOIN
 Select a Forum     Round Tables New Member Discussions News Discussions Algorithm Matches Marathon Matches NASA Tournament Lab TopCoder Cookbook High School Matches Sponsor Discussions Development Forums Design Forums Search | Watch Thread  |  My Post History  |  My Watches  |  User Settings View: Flat (newest first)  | Threaded  | Tree Previous Thread  |  Next Thread Forums Tutorial Discussions Geometry Concepts Line Line Intersections Explanation ....
 Line Line Intersections Explanation .... | Reply Nice article - one of the clearest explanations i have seen so far - there is one thing im not sure of ...In the Line-Line Intersection part....for 2 points on a straight line ```(x1, y1) (x2, y2) ```if ```Ax + By = C ``` then ```A = y2 - y1 B = x1 - x2 C = A*x1 + B *y1 ```could you expand on how this is derived / why it works ?thanksJim
 Re: Line Line Intersections Explanation .... (response to post by jimbarritt) | Reply We know ```A.x1 + B.y1 = C and A.x2 + B.y2 = C ``` so combining these gives ```A.x1 + B.y1 = A.x2 + B.y2 => A(x1 - x2) = B(y2 - y1) ```The thing to remember is that A, B and C can all be scaled by a constant as much as we like - i.e. if {A, B, C} represent the line, so does {2A, 2B, 2C} - so we just have to find a solution to the above equation. One solution happens to be ```A = y2 - y1 and B = x1 - x2 ```You can then work out C by putting those values into one of the original equations (the example you give uses the first one).
 Re: Line Line Intersections Explanation .... (response to post by sql_lall) | Reply thats a cool trick So one solution to```A.c = B.d ```is```d.c = c.d ```nice.thanks for your help and quick answer!
 Forums Tutorial Discussions Geometry Concepts Line Line Intersections Explanation .... Previous Thread  |  Next Thread