NAME

CXC::Types::Astro::Coords - type definitions for Coordinates

VERSION

version 0.12

SYNOPSIS

use CXC::Types::Astro::Coords -types;

DESCRIPTION

CXC::Types::Astro::Coords provides Type::Tiny compatible types for coordinate conventions used in Astronomy.

TYPES

Sexagesimal[`a]

$type = Sexagesimal[ @flags ];

$type = Sexagesimal; #  same as Sexagesimal[ qw( -any -optws -optsep -optunits -trim )]

Return a type tuned to recognize specific forms of sexagesimal coordinate notation. See the CXC::Types::Astro::Coords::Util mkSexagesimal subroutine for more information on the available flags.

SexagesimalArray

An array of three values (degrees, minutes, seconds), where the values have ranges and types

[unbounded]  <integer>
[0, 59]      <integer>
[0, 60)      <float>

Coercible from a string matching "Sexagesimal".

SexagesimalDegrees

A real number.

Coercible from either "SexagesimalArray" or "Sexagesimal"

Degrees

A real number in the range [0,360). Numbers are coerced by modulo 360.

LongitudeArray

An array of three values (degrees, minutes, seconds), where the values have ranges and types

[0,359]  <integer>
[0, 59]  <integer>
[0, 60)  <float>

Coercible from a string matching "LongitudeSexagesimal".

LongitudeDegrees

A real number in the range [0,360)

Coercible from either "LongitudeArray" or "LongitudeSexagesimal"

LongitudeSexagesimal

A string with three components (degrees, minutes, seconds), optionally separated by one of

  • white space;

  • the : character;

  • component specific suffices of d, m, or s.

The components have ranges of:

[0, 359]  <integer>
[0,  59]  <integer>
[0,  60)  <integer/float>

LatitudeArray

An array of three values (degrees, minutes, seconds), where the values have ranges and types of

[-90, 90]  <integer>
[  0, 59]  <integer>
[  0, 60)  <integer/float>

and

abs($A[0]) + ( $A[1] + $A[2] / 60 ) / 60 <= 90

Coercible from a string matching "LatitudeSexagesimal".

LatitudeDegrees

A real number in the range [-90,+90]

Coercible from either "LatitudeArray" or "LatitudeSexagesimal"

LatitudeSexagesimal

A string with three components (degrees, minutes, seconds) optionally separated by one of

  • white space

  • the : character,

  • component specific suffices of d, m, or s

The components have ranges and types of

[-90, 90]  <integer>
[  0, 59]  <integer>
[  0, 60)  <integer/float>

and

abs($A[0]) + ( $A[1] + $A[2] / 60 ) / 60 <= 90

RightAscensionArray

An array of three values (hours, minutes, seconds), where the values have ranges and types of

[0, 23]  <integer>
[0, 59]  <integer>
[0, 60)  <integer/float>

Coercible from a string matching "RightAscensionSexagesimal".

RightAscensionDegrees

A real number in the range [0,360]

Coercible from either "RightAscensionArray" or "RightAscensionSexagesimal"

RightAscensionSexagesimal

A string with three components (hours, minutes, seconds) optionally separated by one of

  • white space

  • the : character,

  • component specific suffices of h, m, or s

The components have ranges and types of:

[0, 23]  <integer>
[0, 59]  <integer>
[0, 60)  <integer/float>

DeclinationArray

An array of three values (degrees, minutes, seconds), where the values have ranges and types of

[-90, 90]  <integer>
[  0, 59]  <integer>
[  0, 60)  <integer/float>

and

abs($A[0]) + ( $A[1] + $A[2] / 60 ) / 60 <= 90

Coercible from a string matching "DeclinationSexagesimal".

DeclinationDegrees

A real number in the range [-90,+90]

Coercible from either "DeclinationArray" or "DeclinationSexagesimal"

DeclinationSexagesimal

A string with three components (degrees, minutes, seconds), optionally separated by one of

  • white space;

  • the : character;

  • component specific suffices of d, m, or s.

The components have ranges and types of

[-90, 90]  <integer>
[  0, 59]  <integer>
[  0, 60)  <integer/float>

and

abs($A[0]) + ( $A[1] + $A[2] / 60 ) / 60 <= 90

SexagesimalHMS

A string with three components (hours, minutes, seconds). Each component consists of a number and a suffix of h,m, s. Components may be separated by white space.

The components have ranges and types of:

[0, 23]  <integer>
[0, 59]  <integer>
[0, 60)  <integer/float>

SexagesimalDMS

A string with three components (degrees, minutes, seconds). Each component consists of a number, optional white space, and a suffix of d,m, s. Components may be separated by white space.

The components have ranges and types of:

[0, 359]  <integer>
[0,  59]  <integer>
[0,  60)  <integer/float>

SUPPORT

Bugs

Please report any bugs or feature requests to bug-cxc-types-astro-coords@rt.cpan.org or through the web interface at: https://rt.cpan.org/Public/Dist/Display.html?Name=CXC-Types-Astro-Coords

Source

Source is available at

https://gitlab.com/djerius/cxc-types-astro-coords

and may be cloned from

https://gitlab.com/djerius/cxc-types-astro-coords.git

AUTHORS

  • Terry Gaetz <tgaetz@cfa.harvard.edu>

  • Diab Jerius <djerius@cfa.harvard.edu>

COPYRIGHT AND LICENSE

This software is Copyright (c) 2018 by Smithsonian Astrophysical Observatory.

This is free software, licensed under:

The GNU General Public License, Version 3, June 2007