Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Given a point A with coordinates (a,b) ; a point B with coordinates (c,d) , I want to find a point C's coordinate (x,y) ,with C lying on the line joining A and B and C is at a distance Dist from point A. This is the representation

share|cite|improve this question
up vote 2 down vote accepted

You will want to use Linear Interpolation. You can interpolate both the x and y coordinate independently. Let $\alpha = Dist/\sqrt{(c-a)^2+(d-b)^2}$. Then the interpolated point is given by:

$$x = a + \alpha(c-a)$$


$$y = b + \alpha(d-b)$$

share|cite|improve this answer

You will want to use linear interpolation. You can interpolate both the $x$ and $y$ coordinate independently. Let a = dist (c-a)2+(d-b)2.Then then the interpolated point is given by:


share|cite|improve this answer
Please edit your inline equation using the proper markup: this way it is not too clear and it looks like two different objects are called with the same name a. – MattAllegro Aug 25 '14 at 8:59

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.