Created
October 5, 2017 16:35
-
-
Save ddavaham/03fe6c1135c93e025ab5fcafe888dace to your computer and use it in GitHub Desktop.
Calculate the Distance between two points in space with x,y,z values
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$distance = sqrt(pow($x2-$x1,2)+pow($y2-$y1,2)+pow($z2-$z1,2))/9.4605284e15 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment