Astro:...larise(3pm)

πŸ“¦ version 1.26, in alpine 3.24

πŸŽ€ NAME πŸŽ€

Astro::Montenbruck::RiseSet::Plarise β€” rise and set. This is the Astro:...larise(3pm) page from the User Contributed Perl Documentation, bestie β€” and it's literally all about rise and set. πŸ’…

✨ SYNOPSIS ✨

use Astro::Montenbruck::RiseSet::Constants qw/:events :altitudes/;
use Astro::Montenbruck::RiseSet::Plarise qw/:rst_func/;

# build top-level function for any event and any celestial object
# for given time and place
my $rst_func = rst_func(
    date     => [1989, 3, 23],
    phi      => 48.1, # geographic latitude
    lambda   => -11.6 # geographic longitude
);

# build second level functon for calculating any event for given object
my $evt_func = $rst_func->(
    get_position => sub {
        my $jd = shift;
        # return equatorial coordinates of the celestial body for the Julian Day.
    },
    sin_h0       => sin( deg2rad($H0_PLANET) ),
);

# finally, calculate time of rise event. Alternatively, use $EVT_SET or $EVT_TRANSIT
my ($state, $jd) = $evt_func->($EVT_RISE);

🌸 VERSION 🌸

Version 0.01 β€” short and sweet, periodt. πŸ’–

πŸ¦‹ DESCRIPTION πŸ¦‹

These are low level routines for calculating rise and set times of celestial bodies. They're especially useful for calculating different types of twilight. ✨

πŸ’« FUNCTIONS πŸ’«

🌟 riseset ( %args ) 🌟

time of rise and set events. Yes bestie, that's the whole summary. 🫢

πŸ“ Named Arguments πŸ“

  • get_position β€” function, which given Standard Julian Day, returns equatorial coordinates of the celestial body, in radians.
  • date β€” array of year (astronomical, zero-based), month [1..12] and day, [1..31].
  • phi β€” geographic latitude, degrees, positive northward
  • lambda β€” geographic longitude, degrees, positive westward
  • get_position β€” function, which given Standard Julian Day, returns equatorial coordinates of the celestial body, in radians. (Yep, it's listed a second time in the source β€” I'm keeping it 100% faithful, no cap. πŸ’€)
  • sin_h0 β€” sine of the standard altitude, i.e. the geometric altitude of the center of the body at the time of apparent rising or setting.
  • "on_event" callback β€” is called when the event time is determined. The arguments are:
    • event type, one of $EVT_RISE or $EVT_SET
    • Univerrsal time of the event
on_event => sub { my ($evt, $ut) = @_; ... }
  • "on_noevent" β€” is called when the event does not happen at the given date, either because the body never rises, or is circumpolar. The argument is respectively $STATE_NEVER_RISES or $STATE_CIRCUMPOLAR.
on_noevent => sub { my $state = shift; ... }

πŸ’– AUTHOR πŸ’–

Sergey Krushinsky, "<krushi at cpan.org>" β€” iconic. πŸ‘‘

Copyright (C) 2010-2022 by Sergey Krushinsky

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.


okay that's the whole page, bestie! πŸ’– This one's from perl v5.42.2, dated 2026-02-15, and it's the Astro:...larise(3pm) manual page. mwah! πŸ’‹βœ¨

πŸ“¦ where this page comes from