Astro-MoonPhase-Simple

 view release on metacpan or  search on metacpan

README  view on Meta::CPAN

    time. However, we add 23:00-15:00=8:00 hours to that epoch to make it
    "localepoch" and this is what we pass on to Astro::MoonPhase to
    calculate the moon phase.

    On failure it returns undef. On success it returns a HASHref with keys:

      * MoonPhase : the moon phase (terminator phase angle) as a number
      between 0 and 1. New Moon (dark) being 0 and Full Moon (bright) being
      1.

      * MoonPhase% : the above as a percentage.

      * MoonIllum : the illuminated fraction of the moon's disc as a number
      between 0 and 1. New Moon (dark) being 0 and Full Moon (bright) being
      1.

      * MoonIllum% : the above as a percentage.

      * MoonAge : the fractional number of days since the Moon's birth (new
      moon), at specified date.

      * MoonDist : the distance of the Moon from the centre of the Earth
      (kilometers).

      * MoonAng : the angular diameter subtended by the Moon as seen by an
      observer at the centre of the Earth

README.md  view on Meta::CPAN

It means UTC time is 15:00. The epoch will be calculated
on UTC time. However, we add `23:00-15:00=8:00` hours to
that epoch to make it "_localepoch_" and this is
what we pass on to [Astro::MoonPhase](https://metacpan.org/pod/Astro%3A%3AMoonPhase) to calculate
the moon phase.

On failure it returns `undef`.
On success it returns a HASHref with keys:

- `MoonPhase` : the moon phase (terminator phase angle) as a number between 0 and 1. New Moon (dark) being 0 and Full Moon (bright) being 1.
- `MoonPhase%` : the above as a percentage.
- `MoonIllum` : the illuminated fraction of the moon's disc as a number between 0 and 1. New Moon (dark) being 0 and Full Moon (bright) being 1.
- `MoonIllum%` : the above as a percentage.
- `MoonAge` : the fractional number of days since the Moon's birth (new moon), at specified date.
- `MoonDist` : the distance of the Moon from the centre of the Earth (kilometers).
- `MoonAng` : the angular diameter subtended by the Moon as seen by an observer at the centre of the Earth
- `SunDist` : Moon's distance from the Sun (kilometers).
- `SunAng` : the angular size of Sun (degrees).
- `phases` : a HASHref containing the date and time for the various Moon phases (at specified date). It contains keys `New Moon, First quarter, Full moon, Last quarter, Next New Moon`
- `asString` : a string representation of the above.

# SCRIPT

lib/Astro/MoonPhase/Simple.pm  view on Meta::CPAN

what we pass on to L<Astro::MoonPhase> to calculate
the moon phase.

On failure it returns C<undef>.
On success it returns a HASHref with keys:

=over 2

=item * C<MoonPhase> : the moon phase (terminator phase angle) as a number between 0 and 1. New Moon (dark) being 0 and Full Moon (bright) being 1.

=item * C<MoonPhase%> : the above as a percentage.

=item * C<MoonIllum> : the illuminated fraction of the moon's disc as a number between 0 and 1. New Moon (dark) being 0 and Full Moon (bright) being 1.

=item * C<MoonIllum%> : the above as a percentage.

=item * C<MoonAge> : the fractional number of days since the Moon's birth (new moon), at specified date.

=item * C<MoonDist> : the distance of the Moon from the centre of the Earth (kilometers).

=item * C<MoonAng> : the angular diameter subtended by the Moon as seen by an observer at the centre of the Earth

=item * C<SunDist> : Moon's distance from the Sun (kilometers).

=item * C<SunAng> : the angular size of Sun (degrees).



( run in 0.420 second using v1.01-cache-2.11-cpan-709fd43a63f )