Tempo.jl

Efficient Astronomical Time transformations in Julia.
Author JuliaSpaceMissionDesign
Popularity
15 Stars
Updated Last
4 Months Ago
Started In
May 2023

Tempo.jl

Efficient Astronomical Time transformations in Julia.

Stable Documentation Dev Documentation Build Status codecov Code Style: Blue

Tempo.jl is an astronomical library that enables fast, efficient and high-accuracy time transformations between common and user-defined time scales and time representations.

Installation

This package can be installed using Julia's package manager:

julia> import Pkg

julia> Pkg.add("Tempo.jl");

Quickstart

Create different Epochs:

# Create an Epoch from an ISO-formatted string
tai = Epoch("2022-10-02T12:04:23.043 TAI")

# Create an Epoch from a Julian Date
jd = Epoch("JD 2451545.0")

# Create an Epoch from a DateTime object and a timescale
dt = DateTime(2001, 6, 15, 0, 0, 0, 0.0)
e = Epoch(dt, TT)

Efficiently transform epochs between various timescales:

# Convert an Epoch from TAI to TDB 
tai = Epoch("2022-10-02T12:04:23.043 TAI")
tdb = convert(TDB, tai)

# Convert an Epoch from TAI to UTC automatically handling leapseconds 
utc = convert(UTC, tai)

Documentation

For further information on this package please refer to the stable documentation

Tempo.jl vs AstroTime.jl

Tempo.jl and AstroTime.jl are very similar libraries that allow transformations between various astronomical time representations. The major differences are:

  • AstroTime.jl supports accurate Epoch transformations by leveraging high precision arithmetics.
  • Tempo.jl is more efficient when multiple timescales conversions must be performed to convert a given Epoch (e.g., it does not allocate memory).

Support

If you found this package useful, please consider starring the repository. We also encourage you to take a look at other astrodynamical packages of the JSMD organisation.

Acknowledgments

The authors would like to acknowledge the developers of AstroTime.jl which inspired and provided many usefull tips for the realisation of this package.