Changeset 3371 for trunk/MagicSoft/Mars/mastro
- Timestamp:
- 03/01/04 15:33:06 (21 years ago)
- Location:
- trunk/MagicSoft/Mars/mastro
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mastro/MAstro.cc
r3366 r3371 18 18 ! Author(s): Thomas Bretz, 11/2003 <mailto:tbretz@astro.uni-wuerzburg.de> 19 19 ! 20 ! Copyright: MAGIC Software Development, 2000-200 320 ! Copyright: MAGIC Software Development, 2000-2004 21 21 ! 22 22 ! … … 33 33 #include <TVector3.h> // TVector3 34 34 35 #include "MTime.h" // MTime::GetGmst 36 35 37 ClassImp(MAstro); 36 38 … … 56 58 { 57 59 /* pi/(180*3600): arcseconds to radians */ 58 #define DAS2R 4.8481368110953599358991410235794797595635330237270e-659 return Hms2Sec(deg, min, sec, sgn)* DAS2R;60 //#define DAS2R 4.8481368110953599358991410235794797595635330237270e-6 61 return Hms2Sec(deg, min, sec, sgn)*TMath::Pi()/(180*3600)/**DAS2R*/; 60 62 } 61 63 … … 63 65 { 64 66 /* pi/(12*3600): seconds of time to radians */ 65 #define DS2R 7.2722052166430399038487115353692196393452995355905e-566 return Hms2Sec(hor, min, sec, sgn)* DS2R;67 //#define DS2R 7.2722052166430399038487115353692196393452995355905e-5 68 return Hms2Sec(hor, min, sec, sgn)*TMath::Pi()/(12*3600)/**DS2R*/; 67 69 } 68 70 … … 295 297 return v0.Angle(v1); 296 298 } 299 300 // -------------------------------------------------------------------------- 301 // 302 // Calls MTime::GetGmst() Better use MTime::GetGmst() directly 303 // 304 Double_t MAstro::UT2GMST(Double_t ut1) 305 { 306 return MTime(ut1).GetGmst(); 307 } -
trunk/MagicSoft/Mars/mastro/MAstro.h
r3366 r3371 13 13 14 14 public: 15 // Angle/Time conversion functions 15 16 static Double_t Hms2Sec(Int_t deg, UInt_t min, Double_t sec, char sgn='+'); 16 17 static Double_t Dms2Rad(Int_t deg, UInt_t min, Double_t sec, Char_t sgn='+'); … … 37 38 static void Hor2Hm(Double_t rad, Char_t &sgn, UShort_t °, Double_t &min); 38 39 40 // Angle treatment functions 39 41 static Bool_t String2Angle(TString &str, Double_t &ret); 40 42 static Bool_t Coordinate2Angle(const TString &str, Double_t &ret); 41 43 42 44 static Double_t AngularDistance(Double_t theta0, Double_t phi0, Double_t theta1, Double_t phi1); 43 45 46 // Time treatment functions 44 47 static void Mjd2Ymd(UInt_t mjd, UShort_t &y, Byte_t &m, Byte_t &d); 45 48 static Int_t Ymd2Mjd(UShort_t y, Byte_t m, Byte_t d); 49 50 static Double_t UT2GMST(Double_t ut1); 46 51 47 52 ClassDef(MAstro, 0)
Note:
See TracChangeset
for help on using the changeset viewer.