choclo.utils.distance_cartesian

choclo.utils.distance_cartesian#

choclo.utils.distance_cartesian(easting_p, northing_p, upward_p, easting_q, northing_q, upward_q)[source]#

Euclidean distance between two points given in Cartesian coordinates.

Warning

All coordinates should be in the same units.

Parameters:
easting_p, northing_p, upward_pfloat

Easting, northing and upward coordinates of point p.

easting_q, northing_q, upward_qfloat

Easting, northing and upward coordinates of point q.

Returns:
distancefloat

Euclidean distance between point_p and point_q.

Notes

Given two points p=(xp,yp,zp) and q=(xq,yq,zq) defined in a Cartesian coordinate system (x,y,z), return the Euclidean (L2) distance between them:

d=(xpxq)2+(ypyq)2+(zpzq)2