Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Accurate setting and rising times for punctual bodies #29

Merged
merged 6 commits into from
Mar 8, 2024

Conversation

rhannequin
Copy link
Owner

@rhannequin rhannequin commented Mar 2, 2024

This changes the method to compute setting and rising times for punctual bodies in order to achieve better precision.

This new method is based on Practical Astronomy with your Calculator or Spreadsheet as it makes it easier to add a vertical shift component and reach more accurate apparent coordinates.

This profoundly changes Astronoby::Refraction class in naming and flexibility. It now allows to either return a refraction angle, or corrected horizontal coordinates.

A new Astronoby::Observer class is introduced to represent an observer and several component based on their location such as the temperature, elevation and atmospheric pressure, if such information are available.

For now, Astronoby::Body doesn't benefit much from these new changes. The class will probably be refactored at some point depending on the features that will be developed around rising and setting times for different bodies such as stars, planets, etc.

@rhannequin rhannequin self-assigned this Mar 2, 2024
Before, the rising and setting times of a punctual body (mostly stars)
were computed based on formulas from Celestial Calculations.

Now, they are computed based on formulas from Practical Astronomy with
your Calculator or Spreadsheet. These formulas feel a bit more natural
to me and allow for an easy add of vertical shift angle.

At the moment, the vertical shift is either ignored, or a fixed value of
34 arc minutes for the atmospheric refraction.
@rhannequin rhannequin force-pushed the accurate-rising-setting-times branch from d99751e to 281efd2 Compare March 4, 2024 20:39
@rhannequin rhannequin marked this pull request as ready for review March 4, 2024 21:41
@rhannequin rhannequin merged commit 36912cb into main Mar 8, 2024
8 checks passed
@rhannequin rhannequin deleted the accurate-rising-setting-times branch March 8, 2024 09:18
rhannequin added a commit that referenced this pull request Mar 24, 2024
## 0.2.0 - 2024-03-24

_If you are upgrading: please see [`UPGRADING.md`]._

[`UPGRADING.md`]: https://github.com/rhannequin/astronoby/blob/main/UPGRADING.md

### Features

* Angle comparison ([#21])
* Add `#distance` and `#angular_size` to `Astronoby::Sun` ([#30])
* Add geocentric parallax `Astronoby::GeocentricParallax` ([#31])
* Ability to calculate equinoxes and solstices times ([#32])
* Round rising and setting times to the second ([#38])
* Provide sunrise and sunset times ([#35])
* Provide sunrise and sunset azimuths ([#39])
* Ability to calculate the equation of time ([#40])

### Breaking changes

* **breaking:** Accurate setting and rising times for punctual bodies ([#29])
* **breaking:** Drop `Astronoby::Util::Time` in favor of
  `Astronoby::GreenwichSiderealTime` and `Astonoby::LocalSiderealTime` ([#36])

### Improvements

* Add Dependabot for Bundler and GitHub Actions ([#24])
* Add bundler-audit GitHub Action ([#25])
* Bump actions/checkout from 3 to 4 ([#26])
* Bump standard from 1.29.0 to 1.35.1 ([#27], [#37])
* Bump rspec from 3.12.0 to 3.13.0 ([#28])

[#21]: #21
[#24]: #24
[#25]: #25
[#26]: #26
[#27]: #27
[#28]: #28
[#29]: #29
[#30]: #30
[#31]: #31
[#32]: #32
[#35]: #35
[#36]: #36
[#37]: #37
[#38]: #38
[#39]: #39
[#40]: #40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant