Hi

How to calculate straight line starting point x,y values(a) and ending point x,y values(b). I know the slope of the line , width of the line and center point of the line(c).

Thanks in advance.

Printable View

- September 1st 2009, 06:25 AMkumarStraight line points
Hi

How to calculate straight line starting point x,y values(a) and ending point x,y values(b). I know the slope of the line , width of the line and center point of the line(c).

Thanks in advance. - September 1st 2009, 06:53 AMaidan
If you know the slope, and a point on the line then

what are you asking?

I'm guessing here:

Are you looking for the coordinates of a point that is

equidistant left & right from the center point?

You must be aware that

the HorizontalDistanceLeft will be NEGATIVE &

the HorizontalDistanceRight will be POSITIVE. - September 1st 2009, 07:28 AMHallsofIvy
What do you

**mean**by "calculate straight line"? If you know**any**one point on the line, a, or b, or c, and the slope, m, then the equation of the straight line is . You don't need to know the other points or the other information. If you know two points, say a and b, then you can calculate the slope, .

Do you mean "find the**length**of the line**segment**"? If so, any two of the facts you have will suffice.

If you know the end points, a and b, the length is .

If you know and endpoint, either a or b, and the center point, c, then the length is .

If you know the "width of the line" (by which, I take it, you mean the absolute value of the difference in x values of a and b) and the slope then, taking w= "width" and m= "slope", the "height", the absolute value of the difference in y value of a and b, is given by wm and so the length of the line segment is given by .