37 #include "Eigen/Geometry"
39 #include "lsst/pex/exceptions.h"
40 #include "boost/algorithm/string.hpp"
41 #include "boost/tuple/tuple.hpp"
42 #include "boost/format.hpp"
45 #include "lsst/daf/base/DateTime.h"
47 namespace ex = lsst::pex::exceptions;
48 namespace dafBase = lsst::daf::base;
56 typedef std::map<std::string, CoordSystem> CoordSystemMap;
58 CoordSystemMap
const getCoordSystemMap() {
81 double const cosDelta2) {
82 double const havDDelta = std::sin(dDelta / 2.0) * std::sin(dDelta / 2.0);
83 double const havDAlpha = std::sin(dAlpha / 2.0) * std::sin(dAlpha / 2.0);
84 double const havD = havDDelta + cosDelta1 * cosDelta2 * havDAlpha;
85 double const sinDHalf = std::sqrt(havD);
91 double const epochTolerance = 1.0e-12;
94 std::pair<Fk5Coord, Fk5Coord> commonFk5(
Coord const &c1,
Coord const &c2) {
96 Fk5Coord fk51 = c1.toFk5();
97 Fk5Coord fk5tmp = c2.toFk5();
101 if (fabs(fk51.getEpoch() - fk5tmp.getEpoch()) > epochTolerance) {
102 fk52 = fk5tmp.precess(fk51.getEpoch());
107 return std::make_pair(fk51, fk52);
113 static CoordSystemMap idmap = getCoordSystemMap();
114 if (idmap.find(system) != idmap.end()) {
115 return idmap[system];
117 throw LSST_EXCEPT(ex::InvalidParameterError,
"System " + system +
" not defined.");
123 double const NaN = std::numeric_limits<double>::quiet_NaN();
124 double const JD2000 = 2451544.50;
143 Dms(
int const d,
int const m,
double const s,
bool const isSouth =
false) {
144 sign = (d < 0 || isSouth) ? -1 : 1;
151 double deg0 = deg00.asAngularUnits(unit);
152 double const absVal = std::fabs(deg0);
153 sign = (deg0 >= 0) ? 1 : -1;
156 sec = ((absVal -
deg) * 60.0 -
min) * 60.0;
169 Coord const &GalacticPoleInFk5() {
174 Coord const &Fk5PoleInGalactic() {
183 geom::Angle meanSiderealTimeGreenwich(
double const jd
185 double const T = (jd - 2451545.0) / 36525.0;
186 return (280.46061837 + 360.98564736629 * (jd - 2451545.0) + 0.000387933 * T * T -
187 (T * T * T / 38710000.0)) *
194 double const atPoleEpsilon = 0.0;
197 if (fabs(p3d.getX()) <= atPoleEpsilon && fabs(p3d.getY()) <= atPoleEpsilon) {
200 lon = (std::atan2(p3d.getY(), p3d.getX()) *
geom::radians).wrap();
206 if (fabs(p3d.getX()) <= atPoleEpsilon && fabs(p3d.getY()) <= atPoleEpsilon) {
213 std::pair<geom::Angle, geom::Angle> pointToLonLat(
geom::Point3D const &p3d,
214 double const defaultLongitude = 0.0,
215 bool normalize =
true) {
216 std::pair<geom::Angle, geom::Angle> lonLat;
219 double const inorm = 1.0 / p3d.asEigen().norm();
220 double const x = inorm * p3d.getX();
221 double const y = inorm * p3d.getY();
222 double const z = inorm * p3d.getZ();
223 if (fabs(x) <= atPoleEpsilon && fabs(y) <= atPoleEpsilon) {
231 if (fabs(p3d.getX()) <= atPoleEpsilon && fabs(p3d.getY()) <= atPoleEpsilon) {
235 lonLat.first = (atan2(p3d.getY(), p3d.getX()) *
geom::radians).wrap();
246 static std::string angleToXmsString(
geom::Angle const a, geom::AngleUnit
const unit) {
250 if ((60.00 - dms.sec) < 0.005) {
256 if (dms.deg == 360) {
262 std::string fmt(
"%02d:%02d:%05.2f");
263 std::string s = (boost::format(fmt) % dms.deg % dms.min % dms.sec).str();
282 if (dms.find(
":") == std::string::npos) {
283 throw LSST_EXCEPT(ex::InvalidParameterError,
284 (boost::format(
"String is not in xx:mm:ss format: %s") % dms).str());
286 std::vector<std::string> elements;
287 boost::split(elements, dms, boost::is_any_of(
":"));
288 if (elements.size() != 3) {
289 throw LSST_EXCEPT(ex::InvalidParameterError,
290 (boost::format(
"Could not parse string as xx:mm:ss format: %s") % dms).str());
292 int const deg = abs(atoi(elements[0].c_str()));
293 int const min = atoi(elements[1].c_str());
294 double const sec = atof(elements[2].c_str());
296 geom::Angle ang = (deg + min / 60.0 + sec / 3600.0) * unit;
297 if ((elements[0].c_str())[0] ==
'-') {
308 double const T = (epoch - 2000.0) / 100.0;
309 return (23.0 + 26.0 / 60.0 + (21.448 - 46.82 * T - 0.0006 * T * T - 0.0018 * T * T * T) / 3600.0) *
320 : _longitude(NaN), _latitude(NaN), _epoch(epoch) {
327 : _longitude(0. * geom::
radians), _latitude(0. * geom::
radians), _epoch(epoch) {
328 std::pair<geom::Angle, geom::Angle> lonLat = pointToLonLat(p3d, defaultLongitude, normalize);
329 _longitude = lonLat.first;
330 _latitude = lonLat.second;
335 : _longitude(ra.wrap()), _latitude(dec), _epoch(epoch) {
339 Coord::Coord(std::string
const ra, std::string
const dec,
double const epoch)
346 void Coord::_verifyValues()
const {
349 ex::InvalidParameterError,
350 (boost::format(
"Latitude coord must be: -PI/2 <= lat <= PI/2 (%f).") % _latitude).str());
355 _longitude = longitude.
wrap();
373 double const x = std::cos(lng) * std::cos(lat);
374 double const y = std::sin(lng) * std::cos(lat);
375 double const z = std::sin(lat);
380 double const alphaGP = poleFrom[0];
381 double const deltaGP = poleFrom[1];
382 double const lCP = poleTo[0];
387 geom::Angle const l = (lCP - std::atan2(std::sin(alpha - alphaGP),
388 std::tan(delta) * std::cos(deltaGP) -
389 std::cos(alpha - alphaGP) * std::sin(deltaGP))) *
391 geom::Angle const b = std::asin((std::sin(deltaGP) * std::sin(delta) +
392 std::cos(deltaGP) * std::cos(delta) * std::cos(alpha - alphaGP))) *
398 double const c = std::cos(theta);
399 double const mc = 1.0 - c;
400 double const s = std::sin(theta);
405 double const ux = u[0];
406 double const uy = u[1];
407 double const uz = u[2];
411 xprime[0] = (ux * ux + (1.0 - ux * ux) * c) * x[0] + (ux * uy * mc - uz * s) * x[1] +
412 (ux * uz * mc + uy * s) * x[2];
413 xprime[1] = (uy * uy + (1.0 - uy * uy) * c) * x[1] + (uy * uz * mc - ux * s) * x[2] +
414 (ux * uy * mc + uz * s) * x[0];
415 xprime[2] = (uz * uz + (1.0 - uz * uz) * c) * x[2] + (uz * ux * mc - uy * s) * x[0] +
416 (uy * uz * mc + ux * s) * x[1];
419 std::pair<geom::Angle, geom::Angle> lonLat = pointToLonLat(xprime);
420 _longitude = lonLat.first;
421 _latitude = lonLat.second;
453 Eigen::Vector3d w = r.cross(u);
454 Eigen::Vector3d v = arcLen * std::cos(phi) * u + arcLen * std::sin(phi) * w;
457 Eigen::Vector3d axisVector = r.cross(v);
458 axisVector.normalize();
461 rotate(axisCoord, arcLen);
473 Eigen::Vector3d w2 = r2.cross(u2);
478 v2Coord.
rotate(axisCoord, arcLen);
490 return std::shared_ptr<Fk5Coord>(
503 return std::shared_ptr<EclipticCoord>(
507 throw LSST_EXCEPT(ex::InvalidParameterError,
508 "Cannot make Topocentric with convert() (must also specify Observatory).\n"
509 "Instantiate TopocentricCoord() directly.");
512 throw LSST_EXCEPT(ex::InvalidParameterError,
"Cannot convert to UNKNOWN coordinate system");
515 throw LSST_EXCEPT(ex::InvalidParameterError,
516 "Undefined CoordSystem: only FK5, ICRS, GALACTIC, ECLIPTIC allowed.");
524 std::pair<Fk5Coord, Fk5Coord>
const &fk5 = commonFk5(*
this, c);
530 return haversine(alpha1 - alpha2, delta1 - delta2, std::cos(delta1), std::cos(delta2));
536 std::pair<Fk5Coord, Fk5Coord>
const &fk5 = commonFk5(*
this, c);
545 double const cosDelta1 = std::cos(delta1);
546 double const cosDelta2 = std::cos(delta2);
548 geom::Angle separation = haversine(dAlpha, dDelta, cosDelta1, cosDelta2);
551 double const y = std::sin(dAlpha) * cosDelta2;
552 double const x = cosDelta1 * std::sin(delta2) - std::sin(delta1) * cosDelta2 * std::cos(dAlpha);
555 return std::make_pair(bearing, separation);
561 std::pair<Fk5Coord, Fk5Coord>
const &fk5 = commonFk5(*
this, c);
568 double const sinDelta1 = std::sin(delta1);
569 double const cosDelta1 = std::cos(delta1);
570 double const sinDelta2 = std::sin(delta2);
571 double const cosDelta2 = std::cos(delta2);
572 double const cosAlphaDiff = std::cos(alpha2 - alpha1);
573 double const sinAlphaDiff = std::sin(alpha2 - alpha1);
575 double const div = cosDelta1 * cosAlphaDiff * cosDelta2 + sinDelta1 * sinDelta2;
576 double const xi = cosDelta1 * sinAlphaDiff / div;
577 double const eta = (cosDelta1 * cosAlphaDiff * sinDelta2 - sinDelta1 * cosDelta2) / div;
579 return std::make_pair(xi *
geom::radians, eta * geom::radians);
595 lsst::daf::base::DateTime
const &obsDate)
const {
612 if (fabs(
getEpoch() - 2000.0) > epochTolerance) {
623 if (fabs(
getEpoch() - 2000.0) > epochTolerance) {
643 lsst::daf::base::DateTime
const &obsDate)
const {
648 geom::Angle theta0 = meanSiderealTimeGreenwich(obsDate.get(dafBase::DateTime::JD)).wrap();
661 double const sinh = std::sin(phi) * std::sin(delta) + std::cos(phi) * std::cos(delta) * std::cos(H);
665 double const tanAnumerator = std::sin(H);
666 double const tanAdenominator = (std::cos(H) * std::sin(phi) - std::tan(delta) * std::cos(phi));
677 if (fabs(
getEpoch() - epochTo) < epochTolerance) {
681 dafBase::DateTime
const dateFrom(
getEpoch(), dafBase::DateTime::EPOCH, dafBase::DateTime::TAI);
682 dafBase::DateTime
const dateTo(epochTo, dafBase::DateTime::EPOCH, dafBase::DateTime::TAI);
683 double const jd0 = dateFrom.get(dafBase::DateTime::JD);
684 double const jd = dateTo.get(dafBase::DateTime::JD);
686 double const T = (jd0 - JD2000) / 36525.0;
687 double const t = (jd - jd0) / 36525.0;
688 double const tt = t * t;
689 double const ttt = tt * t;
691 geom::Angle const xi = ((2306.2181 + 1.39656 * T - 0.000139 * T * T) * t + (0.30188 - 0.000344 * T) * tt +
694 geom::Angle const z = ((2306.2181 + 1.39656 * T - 0.000139 * T * T) * t + (1.09468 + 0.000066 * T) * tt +
697 geom::Angle const theta = ((2004.3109 - 0.85330 * T - 0.000217 * T * T) * t -
698 (0.42665 + 0.000217 * T) * tt - 0.041833 * ttt) *
705 double const a = std::cos(delta0) * std::sin((alpha0 + xi));
707 std::cos(theta) * std::cos(delta0) * std::cos((alpha0 + xi)) - std::sin(theta) * std::sin(delta0);
709 std::sin(theta) * std::cos(delta0) * std::cos((alpha0 + xi)) + std::cos(theta) * std::sin(delta0);
714 return Fk5Coord(alpha, delta, epochTo);
735 return (boost::format(
"%s(%.7f, %.7f)") %
getClassName() % (*
this)[0].asDegrees() %
736 (*
this)[1].asDegrees())
761 return (boost::format(
"%s(%.7f, %.7f)") %
getClassName() % (*
this)[0].asDegrees() %
762 (*
this)[1].asDegrees())
783 Coord const fk5PoleInEcliptic(ninety, ninety - eclPoleIncl, epoch);
808 double const jd = dafBase::DateTime(epoch, dafBase::DateTime::EPOCH, dafBase::DateTime::TAI)
809 .get(dafBase::DateTime::JD);
812 double const tanHnum = std::sin(A);
813 double const tanHdenom = std::cos(A) * std::sin(phi) + std::tan(h) * std::cos(phi);
817 double const sinDelta = std::sin(phi) * std::sin(h) - std::cos(phi) * std::cos(h) * std::cos(A);
820 return Fk5Coord(alpha, delta, epoch);
825 lsst::daf::base::DateTime
const &date)
const {
827 throw LSST_EXCEPT(ex::InvalidParameterError,
828 (boost::format(
"Expected observatory %s, saw %s") % _obs % obs).str());
830 if (fabs(date.get() -
getEpoch()) > std::numeric_limits<double>::epsilon()) {
831 throw LSST_EXCEPT(ex::InvalidParameterError,
832 (boost::format(
"Expected date %g, saw %g") %
getEpoch() % date.get()).str());
843 return (boost::format(
"%s(%.7f, %.7f, %.12f, (%s))") %
getClassName() % (*
this)[0].asDegrees() %
862 double const epoch) {
865 return std::shared_ptr<Fk5Coord>(
new Fk5Coord(ra, dec, epoch));
868 throw LSST_EXCEPT(ex::InvalidParameterError,
869 "ICRS has no epoch, use overloaded makeCoord with args (system, ra, dec).");
872 throw LSST_EXCEPT(ex::InvalidParameterError,
873 "Galactic has no epoch, use overloaded makeCoord with (system, ra, dec).");
876 return std::shared_ptr<EclipticCoord>(
new EclipticCoord(ra, dec, epoch));
879 throw LSST_EXCEPT(ex::InvalidParameterError,
880 "Cannot make Topocentric with makeCoord() (must also specify Observatory).\n"
881 "Instantiate TopocentricCoord() directly.");
885 ex::InvalidParameterError,
886 "Undefined CoordSystem: only FK5, ICRS, GALACTIC, ECLIPTIC, and TOPOCENTRIC allowed.");
894 return std::shared_ptr<Fk5Coord>(
new Fk5Coord(ra, dec, 2000.0));
897 return std::shared_ptr<IcrsCoord>(
new IcrsCoord(ra, dec));
900 return std::shared_ptr<GalacticCoord>(
new GalacticCoord(ra, dec));
903 return std::shared_ptr<EclipticCoord>(
new EclipticCoord(ra, dec, 2000.0));
906 throw LSST_EXCEPT(ex::InvalidParameterError,
907 "Cannot make Topocentric with makeCoord() (must also specify Observatory).\n"
908 "Instantiate TopocentricCoord() directly.");
912 ex::InvalidParameterError,
913 "Undefined CoordSystem: only FK5, ICRS, GALACTIC, ECLIPTIC, and TOPOCENTRIC allowed.");
919 bool normalize,
geom::Angle const defaultLongitude) {
920 Coord c(p3d, 2000.0, normalize, defaultLongitude);
925 Coord c(p3d, 2000.0, normalize, defaultLongitude);
930 double const epoch) {
949 double const epoch) {
959 return std::shared_ptr<Fk5Coord>(
new Fk5Coord());
962 return std::shared_ptr<IcrsCoord>(
new IcrsCoord());
971 throw LSST_EXCEPT(ex::InvalidParameterError,
972 "Cannot make Topocentric with makeCoord() (must also specify Observatory).\n"
973 "Instantiate TopocentricCoord() directly.");
976 throw LSST_EXCEPT(ex::InvalidParameterError,
977 "Undefined CoordSystem: only FK5, ICRS, GALACTIC, ECLIPTIC, allowed.");
983 return (boost::format(
"%s(%.7f, %.7f, %.2f)") %
getClassName() % (*
this)[0].asDegrees() %
984 (*
this)[1].asDegrees() %
getEpoch())
996 std::shared_ptr<Coord> doAverageCoord(std::vector<std::shared_ptr<Coord const>>
const coords,
999 assert(coords.size() > 0);
1002 for (
auto &&cc : coords) {
1010 sum.
scale(1.0 / coords.size());
1016 std::shared_ptr<Coord>
averageCoord(std::vector<std::shared_ptr<Coord const>>
const coords,
1018 if (coords.size() == 0) {
1019 throw LSST_EXCEPT(ex::LengthError,
"No coordinates provided to average");
1024 system = coords[0]->getCoordSystem();
1025 for (
auto &&cc : coords) {
1026 if (cc->getCoordSystem() != system) {
1027 throw LSST_EXCEPT(ex::InvalidParameterError,
1028 (boost::format(
"Coordinates are not all in the same system: %d vs %d") %
1029 cc->getCoordSystem() %
1033 return doAverageCoord(coords, system);
1037 std::vector<std::shared_ptr<Coord const>> converted;
1038 converted.reserve(coords.size());
1039 for (
auto &&cc : coords) {
1040 converted.push_back(cc->getCoordSystem() == system ? cc : cc->convert(system));
1042 return doAverageCoord(converted, system);
std::shared_ptr< Coord > makeCoord(CoordSystem const system, lsst::afw::geom::Angle const ra, lsst::afw::geom::Angle const dec, double const epoch)
Factory function to create a Coord of arbitrary type with decimal RA,Dec.
virtual std::string getClassName() const
virtual GalacticCoord toGalactic() const
Convert ourself to Galactic: l, b.
virtual void reset(lsst::afw::geom::Angle const longitude, lsst::afw::geom::Angle const latitude)
special reset() overload to make sure no epoch can be set
virtual Fk5Coord toFk5() const
Convert outself from Topocentric to Fk5 (use current epoch)
lsst::afw::geom::Angle Angle
lsst::afw::coord::Coord Coord
virtual std::string toString() const
Get string representation.
void scale(double factor)
table::Key< geom::Angle > longitude
A class to handle Galactic coordinates (inherits from Coord)
lsst::afw::geom::Angle dmsStringToAngle(std::string const dms)
Convert a dd:mm:ss string to Angle.
lsst::afw::geom::Angle getAltitude() const
lsst::afw::geom::Angle getAzimuth() const
virtual TopocentricCoord toTopocentric(Observatory const &obs, lsst::daf::base::DateTime const &obsDate) const
Convert ourself to Altitude/Azimuth: alt, az.
std::pair< lsst::afw::geom::Angle, lsst::afw::geom::Angle > getTangentPlaneOffset(Coord const &c) const
Get the offset on the tangent plane.
Hold the location of an observatory.
AngleUnit constexpr radians
constant with units of radians
lsst::afw::geom::Point2D getPosition(lsst::afw::geom::AngleUnit unit=lsst::afw::geom::degrees) const
Return our contents in a Point2D object.
A coordinate class intended to represent offsets and dimensions.
virtual Fk5Coord toFk5() const
Convert ourself from Ecliptic to Fk5 (use current epoch)
lsst::afw::geom::Angle getLongitude() const
The main access method for the longitudinal coordinate.
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 ...
virtual GalacticCoord toGalactic() const
Convert ourself to Galactic: l, b.
AngleUnit constexpr degrees
constant with units of degrees
lsst::afw::geom::Angle eclipticPoleInclination(double const epoch)
get the inclination of the ecliptic pole (obliquity) at epoch
virtual EclipticCoord toEcliptic(double const epoch) const
Convert ourself to Ecliptic: lambda, beta (precess to new epoch)
virtual void reset(lsst::afw::geom::Angle const longitude, lsst::afw::geom::Angle const latitude)
special reset() overload to make sure no epoch can be set
virtual std::string toString() const
Get string representation.
virtual Fk5Coord toFk5() const
Convert ourself from galactic to Fk5 (no epoch specified)
virtual Fk5Coord toFk5() const
Convert ourself to Fk5 (ie.
virtual std::string toString() const
Get string representation.
virtual Fk5Coord toFk5() const
Convert ourself to Fk5: RA, Dec (use current epoch)
virtual IcrsCoord toIcrs() const
Convert ourself to ICRS: RA, Dec (basically J2000)
A class used to convert scalar POD types such as double to Angle.
std::shared_ptr< Coord > convert(CoordSystem system, double epoch=2000) const
Convert to a specified Coord type at a specified epoch.
EclipticCoord precess(double const epochTo) const
precess to new epoch
virtual TopocentricCoord toTopocentric() const
Convert ourself from Topocentric to Topocentric with no observatory or date arguments.
Coord transform(Coord const &poleTo, Coord const &poleFrom) const
Transform our current coords to another spherical polar system.
std::ostream & operator<<(std::ostream &os, Coord const &coord)
virtual std::string getClassName() const
Extent< int, N > floor(Extent< double, N > const &input)
Return the component-wise floor (round towards more negative).
TopocentricCoord(lsst::afw::geom::Point2D const &p2d, lsst::afw::geom::AngleUnit unit, double const epoch, Observatory const &obs)
A class representing an angle.
A class to handle topocentric (AltAz) coordinates (inherits from Coord)
void rotate(Coord const &axis, lsst::afw::geom::Angle const theta)
Rotate our current coords about a pole.
Angle wrap() const noexcept
Wrap this angle to the range [0, 2π).
lsst::afw::geom::Angle angularSeparation(Coord const &c) const
compute the angular separation between two Coords
lsst::afw::geom::Angle getLongitude() const
get telescope longitude (positive values are E of Greenwich)
lsst::afw::coord::IcrsCoord IcrsCoord
Point< double, 2 > Point2D
table::Key< geom::Angle > latitude
virtual GalacticCoord toGalactic() const
Convert ourself from Galactic to Galactic ...
virtual std::string getClassName() const
std::string angleToDmsString(lsst::afw::geom::Angle const deg)
a Function to convert a coordinate in decimal degrees to a string with form dd:mm:ss ...
AngleUnit constexpr hours
constant with units of hours
std::string angleToHmsString(lsst::afw::geom::Angle const deg)
a function to convert decimal degrees to a string with form hh:mm:ss.s
lsst::afw::geom::Point3D getVector() const
Return our contents in a position vector.
Fk5Coord precess(double const epochTo) const
Precess ourselves from whence we are to a new epoch.
A class to handle Fk5 coordinates (inherits from Coord)
Extent< double, 3 > Extent3D
virtual std::string toString() const
Get string representation.
A class to handle Ecliptic coordinates (inherits from Coord)
Observatory getObservatory() const
virtual void reset(lsst::afw::geom::Angle const longitude, lsst::afw::geom::Angle const latitude)
AngleUnit constexpr arcseconds
constant with units of arcseconds
EigenVector const & asEigen() const
Return a fixed-size Eigen representation of the coordinate object.
virtual IcrsCoord toIcrs() const
Convert ourself to ICRS: RA, Dec (basically J2000)
Coord()
Default constructor for the Coord base class.
lsst::afw::geom::Angle hmsStringToAngle(std::string const hms)
Convert a hh:mm:ss string to Angle.
constexpr double asRadians() const noexcept
Return an Angle's value in radians.
std::shared_ptr< Coord > averageCoord(std::vector< std::shared_ptr< Coord const >> const coords, CoordSystem system=UNKNOWN)
Return average of a list of coordinates.
std::pair< lsst::afw::geom::Angle, lsst::afw::geom::Angle > getOffsetFrom(Coord const &c) const
Compute the offset from a coordinate.
lsst::afw::geom::Angle getDec() const
CoordSystem makeCoordEnum(std::string const system)
A utility function to get the enum value of a coordinate system from a string name.
virtual std::string getClassName() const
virtual TopocentricCoord toTopocentric(Observatory const &obs, lsst::daf::base::DateTime const &obsDate) const
Convert ourself to Altitude/Azimuth: alt, az.
virtual IcrsCoord toIcrs() const
Icrs converter for IcrsCoord.
lsst::afw::geom::Angle getLatitude() const
The main access method for the latitudinal coordinate.
virtual EclipticCoord toEcliptic() const
Convert ourself to Ecliptic: lambda, beta (use current epoch)
lsst::afw::geom::Angle getRa() const
This is the base class for spherical coordinates.
Point< double, 3 > Point3D
lsst::afw::geom::Angle getLatitude() const
get telescope latitude
A class to handle Icrs coordinates (inherits from Coord)
virtual EclipticCoord toEcliptic() const
Convert ourself to Ecliptic: lambda, beta (use existing epoch)
virtual EclipticCoord toEcliptic() const
Convert ourself from Ecliptic to Ecliptic ...
virtual Fk5Coord toFk5() const
Fk5 converter for IcrsCoord.