LSSTApplications
10.0+286,10.0+36,10.0+46,10.0-2-g4f67435,10.1+152,10.1+37,11.0,11.0+1,11.0-1-g47edd16,11.0-1-g60db491,11.0-1-g7418c06,11.0-2-g04d2804,11.0-2-g68503cd,11.0-2-g818369d,11.0-2-gb8b8ce7
LSSTDataManagementBasePackage
|
#include <Coord.h>
Public Types | |
typedef boost::shared_ptr< Coord > | Ptr |
typedef boost::shared_ptr < Coord const > | ConstPtr |
Public Member Functions | |
Coord (lsst::afw::geom::Point2D const &p2d, lsst::afw::geom::AngleUnit unit=lsst::afw::geom::degrees, double const epoch=2000.0) | |
Constructor for the Coord base class. More... | |
Coord (lsst::afw::geom::Point3D const &p3d, double const epoch=2000.0, bool normalize=true, lsst::afw::geom::Angle const defaultLongitude=lsst::afw::geom::Angle(0.)) | |
Constructor for the Coord base class. More... | |
Coord (lsst::afw::geom::Angle const ra, lsst::afw::geom::Angle const dec, double const epoch=2000.0) | |
Constructor for the Coord base class. More... | |
Coord (std::string const ra, std::string const dec, double const epoch=2000.0) | |
Constructor for the Coord base class. More... | |
Coord () | |
Default constructor for the Coord base class. More... | |
virtual | ~Coord () |
virtual Coord::Ptr | clone () const |
virtual void | reset (lsst::afw::geom::Angle const longitude, lsst::afw::geom::Angle const latitude) |
virtual void | reset (lsst::afw::geom::Angle const longitude, lsst::afw::geom::Angle const latitude, double const epoch) |
Reset our coordinates wholesale. More... | |
double | getEpoch () const |
lsst::afw::geom::Point2D | getPosition (lsst::afw::geom::AngleUnit unit=lsst::afw::geom::degrees) const |
Return our contents in a Point2D object. More... | |
lsst::afw::geom::Point3D | getVector () const |
Return our contents in a position vector. More... | |
virtual std::pair< std::string, std::string > | getCoordNames () const |
virtual std::string | getClassName () const |
lsst::afw::geom::Angle | operator[] (int const index) const |
Provide access to our contents via an index. More... | |
bool | operator== (Coord const &rhs) const |
Equality operator, compares each element directly. More... | |
lsst::afw::geom::Angle | getLongitude () const |
The main access method for the longitudinal coordinate. More... | |
lsst::afw::geom::Angle | getLatitude () const |
The main access method for the latitudinal coordinate. More... | |
std::string | getLongitudeStr (lsst::afw::geom::AngleUnit unit) const |
Allow quick access to the longitudinal coordinate as a string. More... | |
std::string | getLatitudeStr () const |
Allow quick access to the longitude coordinate as a string. More... | |
Coord | transform (Coord const &poleFrom, Coord const &poleTo) const |
Tranform our current coords to another spherical polar system. More... | |
lsst::afw::geom::Angle | angularSeparation (Coord const &c) const |
compute the angular separation between two Coords More... | |
std::pair < lsst::afw::geom::Angle, lsst::afw::geom::Angle > | getOffsetFrom (Coord const &c) const |
Compute the offset from a coordinate. More... | |
std::pair < lsst::afw::geom::Angle, lsst::afw::geom::Angle > | getTangentPlaneOffset (Coord const &c) const |
Get the offset on the tangent plane. More... | |
void | rotate (Coord const &axis, lsst::afw::geom::Angle const theta) |
Rotate our current coords about a pole. More... | |
lsst::afw::geom::Angle | offset (lsst::afw::geom::Angle const phi, lsst::afw::geom::Angle const arcLen) |
offset our current coords along a great circle defined by an angle wrt a declination parallel More... | |
Coord::Ptr | convert (CoordSystem system) const |
Convert to a specified Coord type. More... | |
virtual Fk5Coord | toFk5 (double const epoch) const |
Convert ourself to Fk5: RA, Dec (precess to new epoch) More... | |
virtual Fk5Coord | toFk5 () const |
Convert ourself to Fk5: RA, Dec (use current epoch) More... | |
virtual IcrsCoord | toIcrs () const |
Convert ourself to ICRS: RA, Dec (basically J2000) More... | |
virtual GalacticCoord | toGalactic () const |
Convert ourself to Galactic: l, b. More... | |
virtual EclipticCoord | toEcliptic (double const epoch) const |
Convert ourself to Ecliptic: lambda, beta (precess to new epoch) More... | |
virtual EclipticCoord | toEcliptic () const |
Convert ourself to Ecliptic: lambda, beta (use existing epoch) More... | |
virtual TopocentricCoord | toTopocentric (Observatory const &obs, lsst::daf::base::DateTime const &obsDate) const |
Convert ourself to Altitude/Azimuth: alt, az. More... | |
Private Member Functions | |
void | _verifyValues () const |
Make sure the values we've got are in the range 0 <= x < 2PI. More... | |
Private Attributes | |
lsst::afw::geom::Angle | _longitude |
lsst::afw::geom::Angle | _latitude |
double | _epoch |
typedef boost::shared_ptr<Coord const> lsst::afw::coord::Coord::ConstPtr |
typedef boost::shared_ptr<Coord> lsst::afw::coord::Coord::Ptr |
lsst::afw::coord::Coord::Coord | ( | lsst::afw::geom::Point2D const & | p2d, |
lsst::afw::geom::AngleUnit | unit = lsst::afw::geom::degrees , |
||
double const | epoch = 2000.0 |
||
) |
Constructor for the Coord base class.
p2d | Point2D |
unit | Rads, Degs, or Hrs |
epoch | epoch of coordinate |
Definition at line 373 of file Coord.cc.
lsst::afw::coord::Coord::Coord | ( | lsst::afw::geom::Point3D const & | p3d, |
double const | epoch = 2000.0 , |
||
bool | normalize = true , |
||
lsst::afw::geom::Angle const | defaultLongitude = lsst::afw::geom::Angle(0.) |
||
) |
Constructor for the Coord base class.
p3d | Point3D |
epoch | epoch of coordinate |
normalize | normalize the p3d provided |
defaultLongitude | longitude to use if x=y=0 |
Definition at line 388 of file Coord.cc.
lsst::afw::coord::Coord::Coord | ( | lsst::afw::geom::Angle const | ra, |
lsst::afw::geom::Angle const | dec, | ||
double const | epoch = 2000.0 |
||
) |
Constructor for the Coord base class.
ra | Right ascension, decimal degrees |
dec | Declination, decimal degrees |
epoch | epoch of coordinate |
Definition at line 408 of file Coord.cc.
lsst::afw::coord::Coord::Coord | ( | std::string const | ra, |
std::string const | dec, | ||
double const | epoch = 2000.0 |
||
) |
Constructor for the Coord base class.
ra | Right ascension, hh:mm:ss.s format |
dec | Declination, dd:mm:ss.s format |
epoch | epoch of coordinate |
Definition at line 422 of file Coord.cc.
lsst::afw::coord::Coord::Coord | ( | ) |
Default constructor for the Coord base class.
Set all values to NaN Don't call _veriftyValues() method ... it'll fail.
Definition at line 441 of file Coord.cc.
|
inlinevirtual |
|
private |
afwGeom::Angle lsst::afw::coord::Coord::angularSeparation | ( | Coord const & | c | ) | const |
compute the angular separation between two Coords
c | coordinate to compute our separation from |
Definition at line 689 of file Coord.cc.
|
inlinevirtual |
Reimplemented in lsst::afw::coord::TopocentricCoord, lsst::afw::coord::EclipticCoord, lsst::afw::coord::GalacticCoord, lsst::afw::coord::Fk5Coord, and lsst::afw::coord::IcrsCoord.
Definition at line 84 of file Coord.h.
afwCoord::Coord::Ptr lsst::afw::coord::Coord::convert | ( | CoordSystem | system | ) | const |
Convert to a specified Coord type.
Definition at line 637 of file Coord.cc.
|
inlinevirtual |
|
inlinevirtual |
Reimplemented in lsst::afw::coord::TopocentricCoord, lsst::afw::coord::EclipticCoord, and lsst::afw::coord::GalacticCoord.
|
inline |
|
inline |
Allow quick access to the longitude coordinate as a string.
Definition at line 460 of file Coord.h.
|
inline |
|
inline |
Allow quick access to the longitudinal coordinate as a string.
Definition at line 443 of file Coord.h.
std::pair< afwGeom::Angle, afwGeom::Angle > lsst::afw::coord::Coord::getOffsetFrom | ( | afwCoord::Coord const & | c | ) | const |
Compute the offset from a coordinate.
The resulting angles are suitable for input to Coord::offset
c | Coordinate from which to compute offset |
Definition at line 713 of file Coord.cc.
afwGeom::Point2D lsst::afw::coord::Coord::getPosition | ( | lsst::afw::geom::AngleUnit | unit = lsst::afw::geom::degrees | ) | const |
Return our contents in a Point2D object.
Definition at line 477 of file Coord.cc.
std::pair< afwGeom::Angle, afwGeom::Angle > lsst::afw::coord::Coord::getTangentPlaneOffset | ( | afwCoord::Coord const & | c | ) | const |
Get the offset on the tangent plane.
This is suitable only for small angles.
c | Coordinate from which to compute offset |
Definition at line 748 of file Coord.cc.
afwGeom::Point3D lsst::afw::coord::Coord::getVector | ( | ) | const |
Return our contents in a position vector.
Definition at line 491 of file Coord.cc.
afwGeom::Angle lsst::afw::coord::Coord::offset | ( | lsst::afw::geom::Angle const | phi, |
lsst::afw::geom::Angle const | arcLen | ||
) |
offset our current coords along a great circle defined by an angle wrt a declination parallel
phi | angle wrt parallel to offset |
arcLen | angle to offset |
Definition at line 566 of file Coord.cc.
|
inline |
|
inline |
|
inlinevirtual |
Reimplemented in lsst::afw::coord::GalacticCoord, and lsst::afw::coord::IcrsCoord.
Definition at line 86 of file Coord.h.
|
virtual |
Reset our coordinates wholesale.
This allows the user to instantiate Coords without values, and fill them later.
longitude | Longitude coord (eg. R.A. for Fk5) |
latitude | Latitude coord (eg. Declination for Fk5) |
epoch | epoch of coordinate |
Definition at line 460 of file Coord.cc.
void lsst::afw::coord::Coord::rotate | ( | Coord const & | axis, |
lsst::afw::geom::Angle const | theta | ||
) |
Rotate our current coords about a pole.
axis | axis of rotation (right handed) |
theta | angle to offset in radians |
Definition at line 529 of file Coord.cc.
|
virtual |
Convert ourself to Ecliptic: lambda, beta (precess to new epoch)
Reimplemented in lsst::afw::coord::EclipticCoord, and lsst::afw::coord::Fk5Coord.
Definition at line 806 of file Coord.cc.
|
virtual |
Convert ourself to Ecliptic: lambda, beta (use existing epoch)
Reimplemented in lsst::afw::coord::EclipticCoord, and lsst::afw::coord::Fk5Coord.
Definition at line 812 of file Coord.cc.
|
virtual |
Convert ourself to Fk5: RA, Dec (precess to new epoch)
Reimplemented in lsst::afw::coord::TopocentricCoord, lsst::afw::coord::EclipticCoord, lsst::afw::coord::GalacticCoord, lsst::afw::coord::Fk5Coord, and lsst::afw::coord::IcrsCoord.
Definition at line 778 of file Coord.cc.
|
virtual |
Convert ourself to Fk5: RA, Dec (use current epoch)
Reimplemented in lsst::afw::coord::TopocentricCoord, lsst::afw::coord::EclipticCoord, lsst::afw::coord::GalacticCoord, lsst::afw::coord::Fk5Coord, and lsst::afw::coord::IcrsCoord.
Definition at line 784 of file Coord.cc.
|
virtual |
Convert ourself to Galactic: l, b.
Reimplemented in lsst::afw::coord::GalacticCoord, and lsst::afw::coord::Fk5Coord.
Definition at line 799 of file Coord.cc.
|
virtual |
Convert ourself to ICRS: RA, Dec (basically J2000)
Reimplemented in lsst::afw::coord::Fk5Coord, and lsst::afw::coord::IcrsCoord.
Definition at line 792 of file Coord.cc.
|
virtual |
Convert ourself to Altitude/Azimuth: alt, az.
obs | observatory of observation |
obsDate | date of observation |
Reimplemented in lsst::afw::coord::TopocentricCoord, and lsst::afw::coord::Fk5Coord.
Definition at line 819 of file Coord.cc.
afwCoord::Coord lsst::afw::coord::Coord::transform | ( | Coord const & | poleTo, |
Coord const & | poleFrom | ||
) | const |
Tranform our current coords to another spherical polar system.
Variable names assume an equaltorial/galactic tranform, but it works for any spherical polar system when the appropriate poles are supplied.
poleTo | Pole of the destination system in the current coords |
poleFrom | Pole of the current system in the destination coords |
Definition at line 507 of file Coord.cc.
|
private |
|
private |