Conjunction Data Message (CCSDS 508.0-B-1)
OCaml 91.6%
Dune 0.7%
Other 7.7%
17 1 0

Clone this repository

https://tangled.org/gazagnaire.org/ocaml-cdm https://tangled.org/did:plc:jhift2vwcxhou52p3sewcrpx/ocaml-cdm
git@git.recoil.org:gazagnaire.org/ocaml-cdm git@git.recoil.org:did:plc:jhift2vwcxhou52p3sewcrpx/ocaml-cdm

For self-hosted knots, clone URLs may differ based on your setup.

Download tar.gz
README.md

cdm#

Conjunction Data Message (CCSDS 508.0-B-1).

Parse and manipulate Conjunction Data Messages for space debris collision risk assessment. Supports CSV (TraCSS CA verification dataset), JSON-ST (Space-Track compatible), and KVN (Keyword=Value Notation) formats.

Installation#

opam install cdm

Usage#

(* Parse CDMs from a TraCSS CSV file *)
match Cdm.Csv.of_file "tracss_ca.csv" with
| Ok cdms ->
  List.iter (fun cdm ->
    Printf.printf "TCA: %s  Pc: %e  miss: %.1f m\n"
      (Cdm.tca cdm) (Cdm.pc cdm) cdm.miss_distance
  ) cdms
| Error e -> Fmt.epr "%a\n" Cdm.pp_error e

(* Parse a single CDM from KVN format *)
let cdm = Cdm.Kvn.of_string kvn_string

API Overview#

  • type t -- A conjunction event: run_id, conj_id, obj1, obj2, probability, miss_distance, epoch
  • type object_data -- Per-object data: state vector, covariance, metadata, OD/physical parameters
  • type state_vector -- Position (vec3 km) and velocity (vec3 km/s) in J2000
  • type covariance -- 3x3 position covariance upper triangle in RTN frame (m^2)
  • Csv -- Parse TraCSS CA verification dataset CSV (of_file, of_string, fold_channel)
  • Json_st -- Parse Space-Track JSON format (of_string, of_single)
  • Kvn -- Parse CCSDS KVN format (of_string)
  • tca, tca_ptime, pc -- Accessors for TCA and probability of collision

License#

ISC