From 8e182d1d9d8d6d8f898f9e0279cca14a1cb70783 Mon Sep 17 00:00:00 2001 From: Jim Carr Date: Sun, 7 Apr 2024 09:27:36 -0400 Subject: [PATCH] Updates for create publishing --- practical-astronomy-rust-tests/Cargo.toml | 2 +- practical-astronomy-rust/Cargo.toml | 7 ++- practical-astronomy-rust/README.md | 67 +++++++++++++++++++++++ 3 files changed, 74 insertions(+), 2 deletions(-) create mode 100644 practical-astronomy-rust/README.md diff --git a/practical-astronomy-rust-tests/Cargo.toml b/practical-astronomy-rust-tests/Cargo.toml index 3640bb7..3408b4d 100644 --- a/practical-astronomy-rust-tests/Cargo.toml +++ b/practical-astronomy-rust-tests/Cargo.toml @@ -6,4 +6,4 @@ edition = "2021" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -practical-astronomy-rust = { version = "0.1.0", path = "../practical-astronomy-rust" } +practical-astronomy-rust = { version = "0.2.0", path = "../practical-astronomy-rust" } diff --git a/practical-astronomy-rust/Cargo.toml b/practical-astronomy-rust/Cargo.toml index 16795b0..e07a0a2 100644 --- a/practical-astronomy-rust/Cargo.toml +++ b/practical-astronomy-rust/Cargo.toml @@ -1,7 +1,12 @@ [package] name = "practical-astronomy-rust" -version = "0.1.0" +description = "Algorithms from Practical Astronomy, implemented in Rust" +version = "0.2.0" edition = "2021" +license = "MIT" +documentation = "https://jfcarr.github.io/practical-astronomy-rust/" +repository = "https://github.com/jfcarr/practical-astronomy-rust" +readme = "README.md" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/practical-astronomy-rust/README.md b/practical-astronomy-rust/README.md new file mode 100644 index 0000000..c843af4 --- /dev/null +++ b/practical-astronomy-rust/README.md @@ -0,0 +1,67 @@ +# Practical Astronomy in Rust + +Algorithms from "[Practical Astronomy with your Calculator or Spreadsheet](https://www.amazon.com/Practical-Astronomy-your-Calculator-Spreadsheet/dp/1108436072)" by Peter Duffett-Smith, implemented in Rust. API documentation is published [here](https://jfcarr.github.io/practical-astronomy-rust/). + +If you're interested in this topic, please buy the book! It provides far more detail and context. + +## Library Functions - Status + +### Date/Time + +- [x] Calculate -> Date of Easter +- [x] Convert -> Civil Date to Day Number +- [x] Convert -> Civil Time <-> Decimal Hours +- [x] Extract -> Hour, Minutes, and Seconds parts of Decimal Hours +- [x] Convert -> Local Civil Time <-> Universal Time +- [x] Convert -> Universal Time <-> Greenwich Sidereal Time +- [x] Convert -> Greenwich Sidereal Time <-> Local Sidereal Time +- [x] Calculate -> Day of Week for Julian Date + +### Coordinates + +- [x] Convert -> Angle <-> Decimal Degrees +- [x] Convert -> Right Ascension <-> Hour Angle +- [x] Convert -> Equatorial Coordinates <-> Horizon Coordinates +- [x] Calculate -> Obliquity of the Ecliptic +- [x] Convert -> Ecliptic Coordinates <-> Equatorial Coordinates +- [x] Convert -> Equatorial Coordinates <-> Galactic Coordinates +- [x] Calculate -> Angle between two objects +- [x] Calculate -> Rising and Setting times for an object +- [x] Calculate -> Precession (corrected coordinates between two epochs) +- [x] Calculate -> Nutation (in ecliptic longitude and obliquity) for a Greenwich date +- [x] Calculate -> Effects of aberration for ecliptic coordinates +- [x] Calculate -> RA and Declination values, corrected for atmospheric refraction +- [x] Calculate -> RA and Declination values, corrected for geocentric parallax +- [x] Calculate -> Heliographic coordinates +- [x] Calculate -> Carrington rotation number +- [x] Calculate -> Selenographic (lunar) coordinates (sub-Earth and sub-Solar) + +### The Sun + +- [x] Calculate -> Approximate and precise positions of the Sun +- [x] Calculate -> Sun's distance and angular size +- [x] Calculate -> Local sunrise and sunset +- [x] Calculate -> Morning and evening twilight +- [x] Calculate -> Equation of time +- [x] Calculate -> Solar elongation + +### Planets + +- [x] Calculate -> Approximate position of planet +- [x] Calculate -> Precise position of planet +- [x] Calculate -> Visual aspects of planet (distance, angular diameter, phase, light time, position angle of bright limb, and apparent magnitude) +- [x] Calculate -> Position of comet (elliptical and parabolic) +- [x] Calculate -> Binary star orbit data + +### The Moon + +- [x] Calculate -> Approximate and precise position of Moon +- [x] Calculate -> Moon phase and position angle of bright limb +- [x] Calculate -> Times of new Moon and full Moon +- [x] Calculate -> Moon's distance, angular diameter, and horizontal parallax +- [x] Calculate -> Local moonrise and moonset + +### Eclipses + +- [x] Calculate -> Lunar eclipse occurrence and circumstances +- [x] Calculate -> Solar eclipse occurrence and circumstances