source: trunk/MagicSoft/Mars/mtemp/MVPObject.h@ 5138

Last change on this file since 5138 was 1681, checked in by rwagner, 22 years ago
Preliminary version of classes for the Visibility Plotter. You need slalib installed in Mars/.. Makefile therefore is currently not included in central MARS Makefile.
File size: 2.1 KB
Line 
1#ifndef MARS_MVPObject
2#define MARS_MVPObject
3
4#ifndef MARS_MTask
5#include "MTask.h"
6#endif
7
8#ifndef MARS_MObservatoryLocation
9#include "MObservatoryLocation.h"
10#endif
11
12#ifndef MARS_MVPTime
13#include "MVPTime.h"
14#endif
15
16class MVPObject : public MTask
17{
18private:
19 MObservatoryLocation *fObservatory;
20
21 Double_t fRA;
22 Double_t fDec;
23 Double_t fAlt;
24 Double_t fAz;
25 Double_t fZA;
26 Double_t fDiameter;
27 Double_t fEcLat;
28 Double_t fEcLong;
29 Bool_t fCalcEc;
30
31 Double_t fUT1;
32 MVPTime *fTime;
33
34 char* fObjectName;
35 UInt_t fBody;
36
37 Double_t UT1ToGMST(Double_t ut1);
38
39 Double_t fgDegToRad;
40 Double_t fgHrsToRad;
41
42 Bool_t fGotRA;
43 Bool_t fGotDec;
44 Bool_t fGotName;
45
46public:
47
48 MVPObject(const char *name=NULL, const char *title=NULL);
49 ~MVPObject();
50
51 Bool_t PreProcess(MParList *pList);
52 Bool_t Process();
53
54 void SetObservatory(MObservatoryLocation *observatory);
55
56 void SetRA(Double_t rad) { fRA = rad; fBody = 10; fGotRA = kTRUE; }
57 void SetDec(Double_t rad) { fDec = rad; fBody = 10; fGotDec = kTRUE; }
58
59 void SetRA(Int_t rh, Int_t rm, Int_t rs, Int_t ru = 0);
60 void SetDec(Int_t dh, Int_t dm, Int_t ds, Int_t du = 0);
61
62 void SetCalcEc(Bool_t calcEc) { fCalcEc = calcEc; }
63
64 void SetObjectName(char* name) { fObjectName = name; fGotName = kTRUE; }
65 void SetObjectByName(char* object);
66
67 Bool_t SetObject(UInt_t body);
68
69 Double_t GetRA() { return fRA/fgHrsToRad; }
70 Double_t GetDec() { return fDec/fgDegToRad; }
71
72 Double_t GetRARad() { return fRA; }
73 Double_t GetDecRad() { return fDec; }
74
75 Double_t GetZA() { return fZA; }
76 Double_t GetAltitude() { return fAlt; }
77 Double_t GetAzimut() { return fAz; }
78 Double_t GetDiameter() { return fDiameter; }
79
80 Double_t GetEcLat() { return fEcLat; }
81 Double_t GetEcLong() { return fEcLong; }
82
83 Double_t GetZADeg() { return fZA/fgDegToRad; }
84 Double_t GetAltitudeDeg() { return fAlt/fgDegToRad; }
85 Double_t GetAzimutDeg() { return fAz/fgDegToRad; }
86
87 Double_t GetDistance(MVPObject* object);
88 Double_t GetDistanceRad(MVPObject* object);
89
90 char* GetObjectName() { return fObjectName; }
91
92 void Print(Option_t *) const;
93
94 Double_t MJDStartOfYear(UInt_t year);
95
96 ClassDef(MVPObject, 1)
97};
98
99#endif
100
Note: See TracBrowser for help on using the repository browser.