Speed up stardate counter (1 SD = 1 JD)

master
nirenjan 2013-01-22 16:58:43 -08:00
parent 92c27287b8
commit 91ca8e118f
1 changed files with 3 additions and 3 deletions

6
sdate
View File

@ -8,9 +8,9 @@ t = time.time()
""" Technically, we should be adding 2440587.5, """ Technically, we should be adding 2440587.5,
however, since we are trying to stick to the stardate however, since we are trying to stick to the stardate
concept, we add only 440587.5""" concept, we add only 40587.5"""
jd = math.floor(t / 86400.0 + 440587.5) jd = (t / 86400.0 + 40587.5)
# Use the idea that 10 Julian days is equal to 1 stardate # Use the idea that 10 Julian days is equal to 1 stardate
print "%05.1f" % (jd / 10.0) print "%05.1f" % jd