40 #define G_AT "GCOMOads::at(int&)"
41 #define G_INSERT "GCOMOads::insert(int&, GCOMOad&)"
42 #define G_REMOVE "GCOMOads::remove(int&)"
43 #define G_READ "GCOMOads::read(GFitsTable&)"
204 if (index < 0 || index >=
size()) {
227 if (index < 0 || index >=
size()) {
271 #if defined(G_RANGE_CHECK)
279 if (index < 0 || index >=
size()) {
307 #if defined(G_RANGE_CHECK)
308 if (index < 0 || index >=
size()) {
337 int num = oads.
size();
343 for (
int i = 0; i < num; ++i) {
344 m_oads.push_back(oads[i]);
364 GFits fits(filename);
390 const double era = 6451.03;
393 const double erd = 6378.5;
394 const double erd_min = erd + 300.0;
395 const double erd_max = erd + 530.0;
401 int num = table.
nrows();
423 double georad = 73.5;
426 for (
int i = 0; i < num; ++i) {
433 int tics = ptr_tics->
integer(i);
460 ptr_posy->
real(i) * ptr_posy->
real(i) +
461 ptr_posz->
real(i) * ptr_posz->
real(i));
462 if ((radius > erd_min) && (radius < erd_max)) {
465 #if defined(G_GEORAD_WARNING)
467 std::string msg =
"Error in CGRO position. Distance from "
469 "while it should be in the interval ["+
472 "spacecraft altitude.";
505 result.append(
"=== GCOMOads ===");
517 result.append(
" - ");
523 result.append(
" - ");
525 result.append(
" days");
527 result.append(
m_oads[0].tstart().utc());
528 result.append(
" - ");
529 result.append(
m_oads[
size()-1].tstop().utc());
533 if (reduced_chatter >
SILENT) {
538 for (
int i = 0; i <
size(); ++i) {
539 if (
m_oads[i].tjd() != tjd) {
GCOMOads * clone(void) const
Clone COMPTEL Orbit Aspect Data container.
GFitsTable * table(const int &extno)
Get pointer to table HDU.
std::vector< GCOMOad > m_oads
Orbit Aspect Data records.
void warning(const std::string &origin, const std::string &message)
Emits warning.
GCOMOad & insert(const int &index, const GCOMOad &oad)
Insert Orbit Aspect Data into container.
const float & gcel(void) const
Return Geocentre zenith angle.
bool is_empty(void) const
Signals if there are no Orbit Aspect Data in container.
const GSkyDir & xaxis(void) const
Return telescope X-axis.
std::string print(const GChatter &chatter=NORMAL) const
Print COMPTEL Orbit Aspect Data container.
const GTime & tstop(void) const
Return stop time of superpacket.
int size(void) const
Return number of Orbit Aspect Data in container.
void clear(void)
Clear COMPTEL Orbit Aspect Data container.
FITS file class interface definition.
GCOMOad & at(const int &index)
Return reference to Orbit Aspect Data.
GTime com_time(const int &tjd, const int &tics)
Convert TJD and COMPTEL tics in GTime object.
const float & georad(void) const
Return apparent radius of Earth.
COMPTEL Orbit Aspect Data class.
Implementation of support function used by COMPTEL classes.
const GTime & tstart(void) const
Return start time of superpacket.
void read(const GFitsTable &table)
Read COMPTEL Orbit Aspect Data FITS table.
void radec(const double &ra, const double &dec)
Set equatorial sky direction (radians)
GVector sqrt(const GVector &vector)
Computes square root of vector elements.
void load(const GFilename &filename)
Load COMPTEL Orbit Aspect Data FITS file.
const GVector & pos(void) const
Return telescope position vector (km)
const GSkyDir & zaxis(void) const
Return telescope Z-axis.
Abstract interface for FITS table column.
virtual ~GCOMOads(void)
Destructor.
Abstract interface for FITS table.
GCOMOad & append(const GCOMOad &oad)
Append Orbit Aspect Data to container.
void extend(const GCOMOads &oads)
Append Orbit Aspect Data container.
GVector asin(const GVector &vector)
Computes arcsin of vector elements.
const int & nrows(void) const
Return number of rows in table.
void init_members(void)
Initialise class members.
void free_members(void)
Delete class members.
virtual int integer(const int &row, const int &inx=0) const =0
virtual double real(const int &row, const int &inx=0) const =0
const int & tjd(void) const
Return Truncated Julian Days of Orbit Aspect Record.
GCOMOads & operator=(const GCOMOads &oads)
Assignment operator.
void reserve(const int &num)
Reserves space for Orbit Aspect Data in container.
GChatter reduce(const GChatter &chatter)
Reduce chattiness by one level.
Exception handler interface definition.
COMPTEL Orbit Aspect Data container class.
GCOMOads(void)
Void constructor.
void remove(const int &index)
Remove Orbit Aspect Data from container.
const int & tics(void) const
Return tics of Orbit Aspect Record.
void copy_members(const GCOMOads &oads)
Copy class members.
std::string parformat(const std::string &s, const int &indent=0)
Convert string in parameter format.
void close(void)
Close FITS file.
COMPTEL Orbit Aspect Data container class definition.
Mathematical function definitions.
const float & gcaz(void) const
Return Geocentre azimuth angle.
std::string str(const unsigned short int &value)
Convert unsigned short integer value into string.
FITS table abstract base class interface definition.