My Math Forum Calculate distance from hypotenuse in right triangle

 Applied Math Applied Math Forum

May 14th, 2012, 05:54 PM   #1
Newbie

Joined: May 2012

Posts: 2
Thanks: 0

Calculate distance from hypotenuse in right triangle

I'm working on a graphics issue and need some help.

Given a right triangle I want to keep track of x,y coordinates along the hypotenuse after a user draws a line.
The line is 3 pixels wide by default but can be changed. Working with 3 as a start will give me enough to get started.

How do I calculate if a x,y coordinate is within 1.5 units from the hypotenuse on either side? The attached graph is my example.
Every point within the red lines are the points I'm interested in.

Russ
Attached Files
 linegraph.pdf (47.7 KB, 21 views)

 May 14th, 2012, 07:15 PM #2 Senior Member     Joined: Jul 2010 From: St. Augustine, FL., U.S.A.'s oldest city Posts: 12,211 Thanks: 521 Math Focus: Calculus/ODEs Re: Calculate distance from hypotenuse in right triangle Let $$$x_0,y_0$$$ be the point in question and $y=mx+b$ be the equation of the black line. Then, if the point in question is less than or equal to 1.5 units from the black line, you will have: $\frac{\|mx_0+b-y_0\|}{\sqrt{m^2+1}}\le1.5$
 May 15th, 2012, 05:01 AM #3 Newbie   Joined: May 2012 Posts: 2 Thanks: 0 Re: Calculate distance from hypotenuse in right triangle perfect! Thank You!
 May 22nd, 2012, 09:10 AM #4 Newbie   Joined: May 2012 Posts: 1 Thanks: 0 Re: Calculate distance from hypotenuse in right triangle Very important calculation from yours post is so informative to me. I am a new about your article. I think your article about "calculate distance from hypotenuse in right triangle I mean. Thanks for your well sharing.

 Tags calculate, distance, hypotenuse, triangle

### distance to hypotenuse

Click on a term to search for related topics.
 Thread Tools Display Modes Linear Mode

 Similar Threads Thread Thread Starter Forum Replies Last Post iqbad Algebra 1 April 12th, 2013 03:38 PM clankill3r Algebra 1 December 21st, 2011 06:17 AM Dal123 Algebra 2 May 19th, 2010 12:06 AM ngm Algebra 1 December 8th, 2009 01:28 AM questioner1 Algebra 3 November 28th, 2009 10:13 AM

 Contact - Home - Forums - Cryptocurrency Forum - Top