Problem 44839. Homogeneous lines and points in 2D: problem 1

Solution 1715225

Submitted on 25 Jan 2019 by Binbin Qi
  • Size: 19
  • This is the leading solution.
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

Test Suite

Test Status Code Input and Output
1   Pass
assert(isreal(L), 'L must be real');

2   Pass
assert(all(size(L)==[1 3]), 'L must be a 3-element row vector')

3   Pass
assert(abs(L*[P1;1]) < 1e-10, 'Point P1 does not exist on this line');

4   Pass
assert(abs(L*[P2;1]) < 1e-10, 'Point P2 does not exist on this line');

Suggested Problems

More from this Author16

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!