Find points near end point of a line

100 Views Asked by At

Any equation to find points near to both start and end points of lines with different slopes. See image. Need P and Q. If Endpoints are named A and B, AP and BQ should be 1 cm enter image description here

1

There are 1 best solutions below

0
On

I'd say if it will be a straight line passing through the endpoints of the equation y = kx + q, will be a straight line perpendicular to the slope $\tan \alpha = -\frac{1}{k}$.

Then $\triangle x_{_P} = \triangle x_{_Q} = \pm 1\cdot \cos \alpha,\,\,\, \triangle y_{_P} = \triangle y_{_Q} = \pm 1\cdot \sin \alpha $,

and $x_{_P}=x_1+\triangle x_{_P}$ and $y_{_P}=y_1+\triangle y_{_P}$, (so two solutions for point P) and similarly for the point Q.