Skip to main content

Lunastro

Lunastro is a python library for calculating astronomical data, such as, but not limited to:

  • RA of the sun
  • Hour angle of the sun
  • Declination of the sun
  • Longitude of the Sun's Ascending Node (Omega)
  • Solar Geometric mean Anomaly
  • Solar Geometric mean Longitude
  • True Solar Longitude
  • Distance to the sun
  • Local sidereal time (accurate to the second)
  • Sun altitude
  • Sun azimuth
  • Moon Position

Usage

Lunastro's functions return objects of information. Here is a list of each function and what it returns:

Solar Data

latitude = 47.6101 # Bellevue WA latitude
solar_data = getSunData(latitude) # get the solar data

This returns:

Attribute Description
dec current solar declination
hour_angle current solar hour angle
ra current solar right ascension
long_omega Longitude of the Sun's ascending node
true_solar_anomaly true solar anomaly
true_solar_longitude true solar longitude
geo_anomaly geometric mean anomaly of the sun
geo_long geometric mean longitude of the sun
dist distance to the sun in miles

Altitude of the Sun

# lat and long are of Bellevue WA
latitude = 47.6101
longitude = -122
alt = altitude(latitude, longitude)

This returns the altitude of the sun in radians

Azimuth of the Sun

# lat and long are of Bellevue WA
latitude = 47.6101
longitude = -122
azi = azimuth(latitude, longitude)

This returns the azimuth of the sun in radians

Local Sidereal Time

# longitude 
long = -122
time = localSiderealTime(long)

This returns the local sidereal time as an object:

Attribute Description
raw raw sidereal time
hour hours of sidereal time
minute minutes of sidereal time
second seconds of sidereal time

Moon Positioning

# lat and long are of Bellevue WA
lat = 47.6101
long = -122
moon_pos = getMoonPosition(lat, long)

This returns the positioning of the moon as an object:

Attribute Description
azimuth azimuth of the moon
altitude altitude of the moon
distance distance to the moon in KM
parallacticAngle parallactic angle of the moon

Changelog

Version 0.0.21 (March 18th 2023)

  • Edited most of the files by making the functions more accurate. Changed the functions to output objects.

Metadata

Release files for lunastro 0.0.22

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for lunastro 0.0.22
File Size Uploaded Provenance Actions
lunastro-0.0.22.tar.gz 5.8 kB Without provenance Details for lunastro-0.0.22.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for lunastro 0.0.22
File Interpreter ABI Platform Actions
lunastro-0.0.22-py3-none-any.whl Python 3 none any Details for lunastro-0.0.22-py3-none-any.whl

Total release size: 12.0 kB

Release files / lunastro-0.0.22.tar.gz

Download URL lunastro-0.0.22.tar.gz
Size 5.8 kB
Tags Source
SHA-256 checksum
How to use checksums
d2a0df2d652ed1dcb083953ba312d49d8ac7022f8c1ccecd24d73d42435e8711
BLAKE2b-256 checksum
How to use checksums
5ca8b162394a215b826a73451db91c237c5e59cf5fcf43cfbf30ab2d63dd2d2d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16

Release files / lunastro-0.0.22-py3-none-any.whl

Download URL lunastro-0.0.22-py3-none-any.whl
Size 6.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
7e0f1e72ee2739154a3a5c1c56066662e160d1bf65575e69ef9e09627974cd28
BLAKE2b-256 checksum
How to use checksums
e622df9cccc697aed67c86a01803b32eb5516867014d505f37d776bf8779e665
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16

Security for lunastro 0.0.22

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page