PDA

View Full Version : How to calculate points distance to point?



03-15-2003, 06:36 AM
Allright, i have 2 3d-points, and i'd like to know the distance between them. So how to calculate it?

mikael_aronsson
03-15-2003, 08:07 AM
Hi !

Have a look here:
http://freespace.virgin.net/hugo.elias/routines/r_dist.htm

Mikael

jiangerlai
03-15-2003, 04:27 PM
sqrt(sqr(x1-x2)+sqr(y1-y2)+sqr(z1-z2))