LSST Applications g0f08755f38+9c285cab97,g1635faa6d4+bcae251498,g1653933729+a8ce1bb630,g1a0ca8cf93+bf6eb00ceb,g28da252d5a+0829b12dee,g29321ee8c0+18ecbd06b3,g2bbee38e9b+9634bc57db,g2bc492864f+9634bc57db,g2cdde0e794+c2c89b37c4,g3156d2b45e+41e33cbcdc,g347aa1857d+9634bc57db,g35bb328faa+a8ce1bb630,g3a166c0a6a+9634bc57db,g3e281a1b8c+9f2c4e2fc3,g414038480c+077ccc18e7,g41af890bb2+fde0dd39b6,g5fbc88fb19+17cd334064,g7642f7d749+9c285cab97,g781aacb6e4+a8ce1bb630,g80478fca09+55a9465950,g82479be7b0+ed77629bff,g858d7b2824+9c285cab97,g9125e01d80+a8ce1bb630,g9726552aa6+10f999ec6a,ga5288a1d22+2a84bb7594,gacf8899fa4+c69c5206e8,gae0086650b+a8ce1bb630,gb58c049af0+d64f4d3760,gbd46683f8f+1c79523530,gc28159a63d+9634bc57db,gcf0d15dbbd+4b7d09cae4,gda3e153d99+9c285cab97,gda6a2b7d83+4b7d09cae4,gdaeeff99f8+1711a396fd,ge2409df99d+dfd3d5294a,ge79ae78c31+9634bc57db,gf0baf85859+147a0692ba,gf3967379c6+02b11634a5,w.2024.46
LSST Data Management Base Package
Loading...
Searching...
No Matches
Public Member Functions | Friends | List of all members
lsst::jointcal::ProperMotion Class Reference

Proper motion data for a reference star or fitted star. More...

#include <ProperMotion.h>

Public Member Functions

 ProperMotion (double ra, double dec, double raErr, double decErr, double raDecCov=0)
 
 ProperMotion (ProperMotion const &)=default
 
 ProperMotion (ProperMotion &&)=default
 
ProperMotionoperator= (ProperMotion const &)=default
 
ProperMotionoperator= (ProperMotion &&)=default
 
 ~ProperMotion ()=default
 
Point apply (const Point &star, double timeDeltaYears) const
 Apply proper motion correction to the input star, returning a star with PM-corrected coordinates.
 

Friends

std::ostreamoperator<< (std::ostream &stream, ProperMotion const &pm)
 

Detailed Description

Proper motion data for a reference star or fitted star.

Whether to just use these values or fit them is determined by the RefStar and FittedStar they belong to.

Units are radians/year Note: RA proper motion is pm_ra*cos(dec)

Definition at line 45 of file ProperMotion.h.

Constructor & Destructor Documentation

◆ ProperMotion() [1/3]

lsst::jointcal::ProperMotion::ProperMotion ( double ra,
double dec,
double raErr,
double decErr,
double raDecCov = 0 )
inline

Definition at line 47 of file ProperMotion.h.

48 : _ra(ra), _dec(dec), _raErr(raErr), _decErr(decErr), _raDecCov(raDecCov) {
49 _offsetBearing = atan2(dec, ra);
50 };
double dec
Definition Match.cc:41
T atan2(T... args)

◆ ProperMotion() [2/3]

lsst::jointcal::ProperMotion::ProperMotion ( ProperMotion const & )
default

◆ ProperMotion() [3/3]

lsst::jointcal::ProperMotion::ProperMotion ( ProperMotion && )
default

◆ ~ProperMotion()

lsst::jointcal::ProperMotion::~ProperMotion ( )
default

Member Function Documentation

◆ apply()

Point lsst::jointcal::ProperMotion::apply ( const Point & star,
double timeDeltaYears ) const

Apply proper motion correction to the input star, returning a star with PM-corrected coordinates.

NOTE: This method does not apply to the coordinate errors (Point does not include uncertainty).

Parameters
starThe star to correct for this proper motion.
timeDeltaYearsThe difference in time from the correction epoch to correct for, in years.
Returns
The star with corrected coordinates.

Definition at line 34 of file ProperMotion.cc.

34 {
35 geom::SpherePoint spherePoint(star.x, star.y, geom::degrees);
36 double amount = std::hypot(_ra * timeDeltaYears, _dec * timeDeltaYears);
37 // If delta-time is negative, the correction is in the opposite direction.
38 amount = timeDeltaYears < 0 ? -amount : amount;
39 auto result = spherePoint.offset(_offsetBearing * geom::radians, amount * geom::radians);
40 Point newStar(star);
41 newStar.x = result.getRa().asDegrees();
42 newStar.y = result.getDec().asDegrees();
43 return newStar;
44}
py::object result
Definition _schema.cc:429
Point in an unspecified spherical coordinate system.
Definition SpherePoint.h:57
T hypot(T... args)
AngleUnit constexpr degrees
constant with units of degrees
Definition Angle.h:110
AngleUnit constexpr radians
constant with units of radians
Definition Angle.h:109

◆ operator=() [1/2]

ProperMotion & lsst::jointcal::ProperMotion::operator= ( ProperMotion && )
default

◆ operator=() [2/2]

ProperMotion & lsst::jointcal::ProperMotion::operator= ( ProperMotion const & )
default

Friends And Related Symbol Documentation

◆ operator<<

std::ostream & operator<< ( std::ostream & stream,
ProperMotion const & pm )
friend

Definition at line 46 of file ProperMotion.cc.

46 {
47 stream << "pm_ra*cos(dec)=" << pm._ra << "rad/yr, pm_dec=" << pm._dec << "rad/yr, pm_raErr=" << pm._raErr
48 << "rad/yr, pm_decErr=" << pm._decErr << "rad/yr, pm_raDecCov=" << pm._raDecCov;
49 return stream;
50}

The documentation for this class was generated from the following files: