source: trunk/MagicSoft/Mars/mpointing/MPointingPos.h@ 4017

Last change on this file since 4017 was 3666, checked in by tbretz, 21 years ago
*** empty log message ***
File size: 1.5 KB
Line 
1#ifndef MARS_MPointingPos
2#define MARS_MPointingPos
3
4#ifndef MARS_MParContainer
5#include "MParContainer.h"
6#endif
7
8class MTime;
9class MObservatory;
10
11class MPointingPos : public MParContainer
12{
13private:
14 Double_t fZd; // [deg] Zenith distance (ZA)
15 Double_t fAz; // [deg] Azimuth
16
17 Double_t fRa; // [h] Right ascension
18 Double_t fHa; // [h] Hour angle
19 Double_t fDec; // [deg] Declination
20
21public:
22 MPointingPos(const char *name=0, const char *title=0)
23 {
24 fName = name ? name : "MPointingPos";
25 fTitle = title ? title : "Container storing the (corrected) telescope pointing position";
26 }
27
28 void SetLocalPosition(Double_t zd, Double_t az) { fZd=zd; fAz=az; }
29 void SetSkyPosition(Double_t ra, Double_t dec, Double_t ha=0) { fRa=ra; fDec=dec; fHa=ha; }
30
31 Double_t GetZd() const { return fZd; }
32 Double_t GetAz() const { return fAz; }
33
34 Double_t GetRa() const { return fRa; }
35 Double_t GetDec() const { return fDec; }
36
37 Double_t GetRaRad() const { return fRa*TMath::DegToRad()*15; }
38 Double_t GetDecRad() const { return fDec*TMath::DegToRad(); }
39
40 Double_t RotationAngle(const MObservatory &o) const;
41 Double_t RotationAngle(const MObservatory &o, const MTime &t) const;
42 Double_t RotationAngle(const MObservatory &o, const MTime *t) const
43 {
44 return t ? RotationAngle(o, *t) : RotationAngle(o);
45 }
46
47 ClassDef(MPointingPos, 1) //Container storing the (corrected) telescope pointing position
48};
49
50#endif
Note: See TracBrowser for help on using the repository browser.