Cody

Problem 2100. distance to a straight line (2D) given any 2 distinct points on this straight line

Given 2 points P1,P2 on a straight line and a 3rd point, determine the distance of the 3rd point to the straight line. Your answer should have an accuracy of 1e-6.

Hint: create a parameter representation of the (very...) long line.

Solution Stats

64.0% Correct | 36.0% Incorrect
Last solution submitted on Nov 11, 2014

Problem Comments

Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

MATLAB Academy

New to MATLAB?

Learn MATLAB today!

Join the 15-year community celebration.

Play games and win prizes!

Learn more