Dist

Distance between stars with linear algebra in #Python (example used is the milk run from Rigilkent to Proxima):

#!/usr/bin/env python3
import sys
import numpy as np
p1 = np.array(sys.argv[1:4], dtype=float)
p2 = np.array(sys.argv[4:7], dtype=float)
print(np.linalg.norm(p2 - p1))


Unknown's avatar

About Linuxgal

Need a spiritual home? Consider joining us at Mary Queen of the Universe Latter-day Buddhislamic Free Will Christian UFO Synagogue of Vishnu
This entry was posted in Uncategorized. Bookmark the permalink.

Leave a comment