Celeb Glow
general | April 10, 2026

linear interpolation in 3 dimensions

$\begingroup$

Say that I have 2 points in 3 dimensional space specified in Euclidean coordinates $p_0(x_0,y_0,z_0)$ and $p_1(x_1,y_1,z_1)$. How would I go about finding the coordinates of an unknown point that lies on the line segment from $p_0$ to $p_1$ that is a known Euclidean distance $d$ from $p0$?

$\endgroup$ 1

1 Answer

$\begingroup$

Pretty simple you just have to find the vector between the two points

$$v=p_1-p_0=(x_1-x_0,y_1-y_0,z_1-z_0)=(x,y,z)$$

now since you know the total distance between $p_0$ and $p_1$ (which is $\|v\|$) and the distance to your $p_d$ (which is just $d$):

$$p_d=(x_d,y_d,z_d)=p_0+\frac{d}{\|v\|}v$$

$\endgroup$ 1

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy