Distance

From true

Jump to: navigation, search

Distance is a length, so it will be measured in units of length.

If the position of an object is known relative to some rectangular coordinate system, you can use the Pythagorean Theorem to determine the distance of that object from the origin:

distance_{from origin} = \sqrt{x^2 + y^2}

where 'x' and 'y' are simply the coordinates of the object.

Similarly, if the position of two objects are known relative to some rectangular coordinate system, you can determine the distance between the points:

distance_{between points} = \sqrt{\Delta x^2 + \Delta y^2}

where this time Δx and Δy are the differences in the coordinates of the points. That is, if you have the points (x1,y1) and (x2,y2), then Δx = x2x1 and Δy = y2y1.