muller-eot

A Python package for M. Müller implementation of the "Equation of Time - Problem in Astronomy" to calculate the Equation of Time based on the individual effect of eccentricity and obliquity

https://github.com/cyschneck/muller-eot

Science Score: 44.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Committers with academic emails
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (9.2%) to scientific vocabulary

Keywords

astronomy astronomy-astrophysics eccentricity equation-of-time matplotlib matplotlib-figures matplotlib-pyplot obliquity open-science orbital-dynamics pip-package python
Last synced: 4 months ago · JSON representation ·

Repository

A Python package for M. Müller implementation of the "Equation of Time - Problem in Astronomy" to calculate the Equation of Time based on the individual effect of eccentricity and obliquity

Basic Info
  • Host: GitHub
  • Owner: cyschneck
  • License: mit
  • Language: Python
  • Default Branch: main
  • Homepage:
  • Size: 6.49 MB
Statistics
  • Stars: 1
  • Watchers: 1
  • Forks: 0
  • Open Issues: 0
  • Releases: 12
Topics
astronomy astronomy-astrophysics eccentricity equation-of-time matplotlib matplotlib-figures matplotlib-pyplot obliquity open-science orbital-dynamics pip-package python
Created about 3 years ago · Last pushed 6 months ago
Metadata Files
Readme License Citation

README.md

Muller-EOT

PyPi license PyPi-Versions

A Python package for M. Müller implementation of the "Equation of Time - Problem in Astronomy" to calculate the Equation of Time based on the individual effect of eccentricity and obliquity

Quickstart: muller-eot

Get a list of differences in time for each day of the Earth's orbit and then plot it as a function of days in orbit

``` import muller_eot

eartheot = mullereot.EOT(eccentricity=0.0167, obliquity=23.45, orbitperiod=365.25) eartheot.plotEOT() ``` effect_eot

Install

PyPi pip install at pypi.org/project/muller-eot/

pip install muller-eot

Functions

The combined effect of eccentricity and obliquity create the Equation of Time components.

| Effect of Eccentricity | Effect of Obliquity | | ------------- | ------------- | | effect_eccentricity | effect_obliquity |

Combined Effect of the Eccentricity and Obliquity = Equation of Time effect_eot

EOT Object

All Equation of Time calculations are done as a part of the EOT class object. First, create an EOT object for a specific eccentricity, obliquity, and orbit period (in days) python import muller_eot muller_eot.EOT(eccentricity=None, obliquity=None, orbit_period=None) - [REQUIRED] eccentricity (float/int): eccentricity of the planet's orbit - [REQUIRED] obliquity (float/int): obliquity/axial tilt of the planet - [REQUIRED] orbit_period (float/int): days in a solar year

EOT Class Attributes and Functions

eotDayAndMinutes Returns a dictionary for the difference in time for each day in a year {number_day: time difference} python EOT.eotDayAndMinutes

plotEOT Plot the differences in time for the EOT as well as the individual effect of obliquity and eccentricity python EOT.plotEOT(plot_title=None, plot_x_title=None, plot_y_title=None, show_plot=True, fig_plot_color="cornflowerblue", figsize_n=12, figsize_dpi=100, save_plot_name=None) - [OPTIONAL] plottitle (string): Title of plot, defaults to EOT Minute Difference (Min = <negative minutes>, Max = <postive minutes>) - [OPTIONAL] plotxtitle (string): X-axis title, defaults to Days in the Sidereal Year - [OPTIONAL] plotytitle (string): Y-axis title, defaults to Time Difference (Minutes) - [OPTIONAL] showplot (boolean): Show plot (triggers plt.show()), useful when generating multiple plots at once in the background, defaults to True - [OPTIONAL] figplotcolor (string): Scatter plot color, defaults to cornflowerblue blue - [OPTIONAL] figsizen (int/float): Figure size nxn, defaults to 12x12 - [OPTIONAL] figsizedpi (int/lfoat): Figure DPI, defaults to 100 - [OPTIONAL] saveplotname (boolean): Save plot as output, defaults to None (does not save)

Background

The length of a day on Earth is only close to being 24 hours four times a year. For the rest of the year when the sun is at its highest point (solar noon), a clock can run as much as 16 minutes ahead (12:16pm) or 13 minutes behind (11:47am). This discrepancy is the result of the combined effect of a planet's obliquity (axial tilt) and its eccentricity (as well as other smaller gravitational forces like moons that are ignored here). Both of these features form two sine curves that oscillate throughout the year. The combined sum of these two curves form the Equation of Time, a non-uniform change in time to fix to a clock. A planet with an obliquity of 0° and perfectly circular orbit (zero eccentricity) would have no difference in the Expected Solar Noon and the Actual Solar Noon.

To calculate the difference in time for an individual day:

Equation of Time = (Apparent Solar Time) - (Mean Solar Time)

Effect of Eccentricity:

Effect of Obliquity:

"Equation of time is determined by the following parameters: the eccentricity of the orbit of the Earth, the angle between the ecliptic and the equatorial planes, the angle P between the winter solstice and the perihelion relative to the sun or: the time span ∆t from the beginning of winter to the passage through periehlion" (Müller, 1995)

The effect of eccentricity is the result of Kepler's Law where:

"Two well-known features of our solar system are at the basis of the variations in the apparent motion of the sun: 1.) According to Kepler's second law, the angular velocity of the Earth relative to the sun varies throughout a year. 2) Equal angles which the sun in its apparent movement goes through in the eclipitic do not correspond to equal angles we measure on the equatorial plane. However, it is these latter angles which are relevant for the measure of time, since the daily movement of the sun is parallel to the equatorial plane" (Müller, 1995)

Effect on Angular Velocity (on Eccentricity):

As a result of Kepler's law, planets moving in an ellipitc orbit will have variable angular velocity as a result of the second law where the area swept during a constant period of time is constant (=dA/dt)

"1.) parameter: the eccentricity. If e = 0 a regular variation results that is caused by the inclination of the ecliptic plane. The deviations of the apparent solar time from the mean solar time increase with growing e in winter and autumn. Thus, the yearly variation becomes dominant. Since at the perihelion and aphelion the equation of time is only a function of the ecliptic inclination and the angle P, all plots have the same value at these two points. 2.) parameter: the inclination of the ecliptic. ε = 0 yields a plot which is symmetric to the passage through the aphelion. The greater ε the more dominant the variation with a period of half a year. All plots have four common points at the beginning of each season, for the equation of time depends only on the two other parameters there (eccentricity and P). As the projection from the ecliptic plane onto the equatorial plane does not change the polar angle relative to the winter solstice, ε does not influence the value of the equation of time at the beginning of a season. 3.) parameter: the time interval between the beginning of winter and the passage through the perihelion. If ∆t = 0 the two main variations vanish both at the beginning of winter and summer (because winter begins when the earth passes the perihelion; the aphelion is the summer solstice). Therefore, the resulting function is symmetric and the extreme values are in autumn and winter. If ∆t increases, the two components tend to compensate each other in winter whereas the negative value in summer begins to dominate." (Müller, 1995)

Equation of Time is the combination of the effect of eccentricity and obliquity

TODO:

  • Pytests
  • calculateOrbitalPeriod(semimajor_axis)
  • calculateDistanceBetweenSolisticePerhelion()
  • calculatePerihelionDay()
  • calculateWinterSolsticeDay()
  • calculateEccentricity()

Development Environment

To run or test against muller_eot github repo/fork, a development environment can be created via conda/miniconda

First, install Miniconda

Then, using the existing environment.yml, a new conda environment can be create to run/test scripts against

conda env create --file environment.yml Once the environment has been built, activate the environment: conda activate muller_eot

Owner

  • Name: Cora Schneck
  • Login: cyschneck
  • Kind: user
  • Company: NCAR/UCAR

A scientific programmer at NCAR who is collecting an infinite number of monkeys to test a theory

Citation (CITATION.cff)

cff-version: 1.2.0
title: "Python implementation of M. Müller's "Equation of Time - Problem in Astronomy""
version: 1.4.3
message: "Please acknowledge the use of this software in any publications by citing:"
authors:
- family-names: Schneck
  given-names: Cora Y.
  orchid: 'https://orcid.org/0009-0009-1415-5170'
repository-code:: "https://github.com/cyschneck/Muller-EOT"
url: "https://github.com/cyschneck/Muller-EOT"

GitHub Events

Total
  • Watch event: 1
  • Push event: 1
Last Year
  • Watch event: 1
  • Push event: 1

Committers

Last synced: almost 2 years ago

All Time
  • Total Commits: 41
  • Total Committers: 1
  • Avg Commits per committer: 41.0
  • Development Distribution Score (DDS): 0.0
Past Year
  • Commits: 41
  • Committers: 1
  • Avg Commits per committer: 41.0
  • Development Distribution Score (DDS): 0.0
Top Committers
Name Email Commits
cyschneck 2****k 41

Issues and Pull Requests

Last synced: 4 months ago

All Time
  • Total issues: 0
  • Total pull requests: 1
  • Average time to close issues: N/A
  • Average time to close pull requests: about 5 hours
  • Total issue authors: 0
  • Total pull request authors: 1
  • Average comments per issue: 0
  • Average comments per pull request: 1.0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 1
Past Year
  • Issues: 0
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 0
  • Pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
Pull Request Authors
  • dependabot[bot] (2)
Top Labels
Issue Labels
Pull Request Labels
dependencies (2)

Packages

  • Total packages: 1
  • Total downloads:
    • pypi 54 last-month
  • Total dependent packages: 0
  • Total dependent repositories: 1
  • Total versions: 12
  • Total maintainers: 1
pypi.org: muller-eot

A Python package for M. Müller implementation of the 'Equation of Time - Problem in Astronomy' to calculate EOT and the effect of eccentricity/obliquity

  • Documentation: https://muller-eot.readthedocs.io/
  • License: MIT License Copyright (c) 2022 C. Y. Schneck Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  • Latest release: 1.4.3
    published over 1 year ago
  • Versions: 12
  • Dependent Packages: 0
  • Dependent Repositories: 1
  • Downloads: 54 Last month
Rankings
Dependent packages count: 10.1%
Dependent repos count: 21.6%
Average: 28.2%
Forks count: 29.8%
Stargazers count: 38.8%
Downloads: 40.9%
Maintainers (1)
Last synced: 4 months ago

Dependencies

requirements.txt pypi
  • matplotlib ==3.1.0
setup.py pypi
  • matplotlib >=3.1.0