Skip to content
@Siderust

Siderust

Precision astronomy & orbit-analysis libraries in Rust.

Ephemerides · Time scales · Typed frames · Units · Orbit workflows · Satellite engineering

Website · Docs · Examples · Benchmarks · Discussions

Core repository Crates.io docs.rs Rust


Siderust is an open-source scientific-computing ecosystem for people building astronomy, astrodynamics, observation planning, satellite, and mission-analysis software.

The design goal is simple: scientific meaning should be visible in code. Units, time scales, reference frames, coordinate centers, and physical models are first-class concepts instead of comments attached to raw floating-point values.

Typed science

Physical quantities, epochs, frames, centers, and coordinate semantics are encoded in APIs wherever practical.

Research workflows

Solar-system ephemerides, observing windows, coordinate transforms, lunar properties, time scales, and orbit examples.

Systems-ready Rust

Composable crates, explicit features, reproducible examples, and bindings planned around a Rust source of truth.

Small taste

Compute Mars barycentric ecliptic coordinates through the Siderust planetary model:

use chrono::prelude::*;
use siderust::{
    bodies::Mars,
    time::{JulianDate, JD, TT, Time, UTC},
};
// or use siderust::prelude::*;

fn main() {
    // UTC now → Terrestrial Time → Julian Date
    let jd: JulianDate = Time::<UTC>::from_chrono(Utc::now())
        .to::<TT>()
        .to::<JD>();

    // VSOP87E: barycentric ecliptic rectangular coordinates, J2000 frame.
    let mars = Mars::vsop87e(jd);

    println!("Mars · VSOP87E · barycentric ecliptic J2000");
    println!("{}", mars.position);
}

This is the core idea: the code carries the scientific context — body, epoch, time scale, ephemeris model, and output quantity — instead of hiding it behind anonymous f64s.

Run something real

cargo new siderust-tour
cd siderust-tour
cargo add siderust chrono

Paste the example above into src/main.rs, then run:

cargo run

Or clone the main repository and run the curated examples:

git clone https://github.com/Siderust/siderust.git
cd siderust

cargo run --example 08_solar_system
cargo run --example 09_star_observability
cargo run --example 16_lambert_earth_to_mars
cargo run --example 17_sgp4_from_tle

The examples cover typed coordinates, frame and center transforms, observing windows, Moon properties, solar-system positions, time periods, runtime ephemerides, orbit models, Lambert transfer, SGP4/TLE, and POD-oriented workflows.

Ecosystem

Core Rust crates

Project Purpose
siderust Astronomy, ephemerides, observation workflows, coordinate transforms, and satellite-facing APIs.
qtty Unit-safe physical quantities, dimensions, conversions, and constants.
affn Affine geometry with typed reference frames, centers, vectors, positions, and transforms.
tempoch Scientific time primitives: epochs, durations, Julian dates, MJD, UTC, TAI, GPS, and conversions.
keplerian Two-body dynamics, conic elements, propagation, anomaly solving, and transfer helpers.
principia Typed Newtonian numerical dynamics, acceleration models, integrators, variational equations, covariance, and gravity-field kernels.
optica Participating-media and optics foundations: typed rays, optical coefficients, phase functions, spectra, and optical-depth integration.
cheby Chebyshev interpolation, approximation, series evaluation, and numerical primitives.

Bindings and front-ends

Language Projects
C++ siderust-cpp, qtty-cpp, tempoch-cpp
Python siderust-py, qtty-py, tempoch-py
JavaScript / WASM siderust-js, qtty-js, tempoch-js
Benchmarks benches
Website siderust.github.io

How the pieces fit

siderust
  astronomy · ephemerides · observations · satellites

  uses
  ├─ tempoch      scientific time, epochs, calendars, durations
  ├─ affn         typed frames, centers, positions, vectors, transforms
  ├─ keplerian    elements, propagation, conics, transfers
  ├─ principia    numerical dynamics, propagation, gravity-field kernels
  ├─ optica       rays, optical coefficients, spectra, optical depth
  ├─ qtty         units, dimensions, conversions, constants
  └─ cheby        interpolation, approximation, spectral numerics

The foundational crates are intentionally useful outside astronomy. siderust assembles them into higher-level workflows for observation, ephemeris, and orbit analysis.

Built for

Astronomy and observation

  • apparent positions and ephemeris-backed workflows
  • topocentric geometry
  • altitude, azimuth, and horizon searches
  • Sun, Moon, planet, asteroid, comet, and star computations
  • observatory and ground-station tooling

Orbit and satellite engineering

  • frame-aware state handling
  • Keplerian propagation and transfer searches
  • TLE/SGP4-oriented workflows
  • satellite pass analysis
  • precise-orbit-determination research infrastructure

Engineering principles

  • Make units explicit. Avoid APIs that rely on caller memory for meters vs. kilometers or degrees vs. radians.
  • Make frames explicit. Coordinate-heavy code should not silently mix inertial, body-fixed, topocentric, geocentric, and heliocentric semantics.
  • Make time explicit. Epochs, durations, calendars, and time scales need names and types, not anonymous numbers.
  • Keep crates composable. Foundational crates should remain focused and reusable.
  • Measure honestly. Benchmarks and validation should be reproducible, documented, and tied to clear scenarios.

Install

cargo add siderust

For lower-level building blocks:

cargo add qtty affn tempoch cheby

For production systems, pin explicit versions and review each repository's feature flags, runtime-data requirements, and license before deployment.

Contributing

Useful contributions usually fall into one of these areas:

  • reference validation against authoritative datasets;
  • numerical accuracy and performance improvements;
  • clearer examples and API documentation;
  • benchmark coverage and reproducibility;
  • C++, Python, and JavaScript binding parity;
  • packaging, release, and deployment reliability;
  • scientific workflows that can be reproduced end to end.

For Rust repositories, start with the usual checks:

cargo fmt --all
cargo test --all-targets
cargo clippy --all-targets -- -D warnings

Repository-specific instructions take precedence when a project defines additional validation, feature, data, or binding requirements.

License

Licensing is repository-specific. Each repository's LICENSE file is authoritative.

Some crates are permissively licensed, while core astronomy and satellite-mechanics components may use stronger copyleft terms. Review the target repository before using Siderust in proprietary or closed-source systems.


Precision-first astrodynamics for Rust systems that cannot afford silent unit, frame, or time-scale mistakes.

Pinned Loading

  1. siderust siderust Public

    Precision astrometry & satellite mechanics in safe, fast Rust.

    Rust 12 4

  2. siderust-cpp siderust-cpp Public

    A C++ support library of foundational utilities for safe, modern systems programming. Includes type-safe primitives and building blocks used across Siderust’s C++ projects.

    C++ 2 1

  3. siderust-js siderust-js Public

    Rust

  4. siderust-py siderust-py Public

    Rust

Repositories

Showing 10 of 22 repositories

Top languages

Loading…

Most used topics

Loading…