GammaLib
2.0.0
|
COMPTEL Solar System Barycentre Data class. More...
#include <GCOMBvc.hpp>
Public Member Functions | |
GCOMBvc (void) | |
Void constructor. More... | |
GCOMBvc (const GCOMBvc &bvc) | |
Copy constructor. More... | |
virtual | ~GCOMBvc (void) |
Destructor. More... | |
GCOMBvc & | operator= (const GCOMBvc &bvc) |
Assignment operator. More... | |
virtual void | clear (void) |
Clear COMPTEL Solar System Barycentre Data. More... | |
virtual GCOMBvc * | clone (void) const |
Clone COMPTEL Solar System Barycentre Data. More... | |
virtual std::string | classname (void) const |
Return class name. More... | |
virtual std::string | print (const GChatter &chatter=NORMAL) const |
Print COMPTEL Solar System Barycentre Data. More... | |
const GTime & | time (void) const |
Return time of Solar System Barycentre Data. More... | |
void | time (const GTime &time) |
Set time of Solar System Barycentre Data. More... | |
const int & | tjd (void) const |
Return Truncated Julian Days of Solar System Barycentre Data. More... | |
void | tjd (const int &tjd) |
Set Truncated Julian Days of Solar System Barycentre Data. More... | |
const int & | tics (void) const |
Return tics of Solar System Barycentre Data. More... | |
void | tics (const int &tics) |
Set tics of Solar System Barycentre Data. More... | |
const GVector & | ssb (void) const |
Return Solar System Barycentre vector. More... | |
void | ssb (const GVector &ssb) |
Set Solar System Barycentre vector. More... | |
const double & | tdelta (void) const |
Return TDB-UTC time difference. More... | |
void | tdelta (const double &tdelta) |
Set TDB-UTC time difference. More... | |
double | tdelta (const GSkyDir &dir) const |
Return time difference between photon arrival time at CGRO and the Solar System Barycentre (SSB) More... | |
Public Member Functions inherited from GBase | |
virtual | ~GBase (void) |
Destructor. More... | |
Protected Member Functions | |
void | init_members (void) |
Initialise class members. More... | |
void | copy_members (const GCOMBvc &bvc) |
Copy class members. More... | |
void | free_members (void) |
Delete class members. More... | |
Protected Attributes | |
GTime | m_time |
Time for Solar System Barycentre Data. More... | |
int | m_tjd |
TJD of Solar System Barycentre Data. More... | |
int | m_tics |
Tics of Solar System Barycentre Data. More... | |
GVector | m_ssb |
Solar System Barycentre vector in celestial system (micro seconds) More... | |
double | m_tdelta |
Time difference TDB-UTC (sec) More... | |
COMPTEL Solar System Barycentre Data class.
The class holds one record of a COMPTEL Solar System Barycentre Data file.
Definition at line 49 of file GCOMBvc.hpp.
GCOMBvc::GCOMBvc | ( | void | ) |
Void constructor.
Definition at line 53 of file GCOMBvc.cpp.
References init_members().
Referenced by clone().
GCOMBvc::GCOMBvc | ( | const GCOMBvc & | bvc | ) |
Copy constructor.
[in] | bvc | COMPTEL Solar System Barycentre Data. |
Definition at line 68 of file GCOMBvc.cpp.
References copy_members(), and init_members().
|
virtual |
|
inlinevirtual |
Return class name.
Implements GBase.
Definition at line 100 of file GCOMBvc.hpp.
|
virtual |
Clear COMPTEL Solar System Barycentre Data.
Implements GBase.
Definition at line 136 of file GCOMBvc.cpp.
References free_members(), and init_members().
|
virtual |
Clone COMPTEL Solar System Barycentre Data.
Implements GBase.
Definition at line 154 of file GCOMBvc.cpp.
References GCOMBvc().
|
protected |
Copy class members.
[in] | bvc | COMPTEL Solar System Barycentre Data. |
Definition at line 295 of file GCOMBvc.cpp.
References m_ssb, m_tdelta, m_tics, m_time, and m_tjd.
Referenced by GCOMBvc(), and operator=().
|
protected |
Delete class members.
Definition at line 312 of file GCOMBvc.cpp.
Referenced by clear(), operator=(), and ~GCOMBvc().
|
protected |
Initialise class members.
Definition at line 276 of file GCOMBvc.cpp.
References GTime::clear(), GVector::clear(), m_ssb, m_tdelta, m_tics, m_time, and m_tjd.
Referenced by clear(), GCOMBvc(), and operator=().
Assignment operator.
[in] | bvc | COMPTEL Solar System Barycentre Data. |
Definition at line 106 of file GCOMBvc.cpp.
References copy_members(), free_members(), and init_members().
Print COMPTEL Solar System Barycentre Data.
[in] | chatter | Chattiness. |
Implements GBase.
Definition at line 238 of file GCOMBvc.cpp.
References m_tics, m_time, m_tjd, GTime::mjd(), gammalib::parformat(), SILENT, gammalib::str(), and GTime::utc().
|
inline |
Return Solar System Barycentre vector.
Returns the Solar System Barycentre vector in micro seconds. The vector is given in the celestial system. It's length specifies the light travel time in micro seconds.
Definition at line 205 of file GCOMBvc.hpp.
References m_ssb.
Referenced by GCOMBvcs::read(), and ssb().
|
inline |
Set Solar System Barycentre vector.
[in] | ssb | Solar System Barycentre vector (micro seconds). |
Set the Solar System Barycentre vector in micro seconds. The vector is defined in the celestial system. It's length specifies the light travel time in micro seconds.
Definition at line 221 of file GCOMBvc.hpp.
|
inline |
Return TDB-UTC time difference.
Returns the TDB-UTC time difference in seconds.
Definition at line 236 of file GCOMBvc.hpp.
References m_tdelta.
Referenced by GCOMBvcs::read(), and tdelta().
|
inline |
Set TDB-UTC time difference.
[in] | tdelta | TDB-UTC time difference (s). |
Set the TDB-UTC time difference.
Definition at line 250 of file GCOMBvc.hpp.
double GCOMBvc::tdelta | ( | const GSkyDir & | dir | ) | const |
Return time difference between photon arrival time at CGRO and the Solar System Barycentre (SSB)
[in] | dir | Source position. |
Returns the time difference between photon arrival time at CGRO and the Solar System Barycentre (SSB). The arrival time at the SSB is computed by adding the time difference to the photon arrival time as measured by COMPTEL
\[ T_{\rm SSB} = T_{\rm CGRO} + \Delta T \]
The routine implements the algorithm PUL-AL-004 and is inspried from the COMPASS code evpbin02.pulssb.f.
It computes
\[ \Delta T = \Delta T_{\rm travel} - \Delta T_{\rm rel} + \Delta T_{\rm BVC} \]
where
\[ \Delta T_{\rm travel} = \left( \vec{SSB} \cdot \vec{n} \right) \times 10^{-6} \]
is the light travel time in seconds between CGRO and the SSB, with \(\vec{SSB}\) being the vector going from the SSB to CGRO, specified using the GCOMBvc::ssb() method, and \(\vec{n}\) is the normalised vector of the source position, provided by the GSkyDir::celvector() method,
\[ \Delta T_{\rm rel} = -2 R \log \left( 1 + \frac{\Delta T_{\rm travel}}{|\vec{SSB}| * 10^{-6}} \right) \]
is the relativistic delay due to the Sun in seconds, with \(R=0.49254909 \times 10^{-5}\) s, and \(\Delta T_{\rm BVC}\) is the difference in seconds due to the time unit conversion as specified by the GCOMBvc::tdelta() method.
Definition at line 207 of file GCOMBvc.cpp.
References GSkyDir::celvector(), log(), m_ssb, norm(), and tdelta().
|
inline |
Return tics of Solar System Barycentre Data.
Returns the tics of the Solar System Barycentre Data.
Definition at line 174 of file GCOMBvc.hpp.
References m_tics.
Referenced by GCOMBvcs::read(), and tics().
|
inline |
Set tics of Solar System Barycentre Data.
[in] | tics | Tics of Solar System Barycentre Data. |
Set the tics of the Solar System Barycentre Data.
Definition at line 188 of file GCOMBvc.hpp.
|
inline |
Return time of Solar System Barycentre Data.
Returns the time of the Solar System Barycentre Data. The time is defined as the mid-point of the corresponding superpacket.
Definition at line 115 of file GCOMBvc.hpp.
References m_time.
Referenced by GCOMBvcs::read(), and time().
|
inline |
Set time of Solar System Barycentre Data.
[in] | time | Time of Solar System Barycentre Data. |
Set the time of the Solar System Barycentre Data. The time is defined as the mid-point of the corresponding superpacket.
Definition at line 130 of file GCOMBvc.hpp.
|
inline |
Return Truncated Julian Days of Solar System Barycentre Data.
Returns the Truncated Julian Days of Solar System Barycentre Data.
Definition at line 145 of file GCOMBvc.hpp.
References m_tjd.
Referenced by GCOMBvcs::read(), and tjd().
|
inline |
Set Truncated Julian Days of Solar System Barycentre Data.
[in] | tjd | Truncated Julian Days of Solar System Barycentre Data. |
Set the Truncated Julian Days of the Solar System Barycentre Data.
Definition at line 159 of file GCOMBvc.hpp.
|
protected |
Solar System Barycentre vector in celestial system (micro seconds)
Definition at line 89 of file GCOMBvc.hpp.
Referenced by copy_members(), init_members(), ssb(), and tdelta().
|
protected |
Time difference TDB-UTC (sec)
Definition at line 90 of file GCOMBvc.hpp.
Referenced by copy_members(), init_members(), and tdelta().
|
protected |
Tics of Solar System Barycentre Data.
Definition at line 88 of file GCOMBvc.hpp.
Referenced by copy_members(), init_members(), print(), and tics().
|
protected |
Time for Solar System Barycentre Data.
Definition at line 86 of file GCOMBvc.hpp.
Referenced by copy_members(), init_members(), print(), and time().
|
protected |
TJD of Solar System Barycentre Data.
Definition at line 87 of file GCOMBvc.hpp.
Referenced by copy_members(), init_members(), print(), and tjd().