Question: Write a MATLAB function (line_eq) that takes coordinates of two points as inputs and returns m and b such that y = mx + b

Write a MATLAB function (line_eq) that takes coordinates of two points as inputs and returns m and b such that y = mx + b represents the equation of the line passing through these points. This function should be able to handle row or column vector entries. [m, b] = line_eq (PA, PB) Write a MATLAB function (line_int) that takes coordinates of four points as inputs and returns the coordinates o intersection of line passing through points 1 and 2 and the line passing through points 3 and 4. This function should be able to handle row or column vector entries. This function can call function line_eq if needed. P = limw_int(P1, P2, P3, P4) Check your function to find the intersection of two lines: Line 1: passing through points (-1, 0) and (3, 6) Line 2: passing through points (-2, 6) and (7, -3)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
