00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00013
00014 #include "MessageService/MsgService.h"
00015 #include "Conventions/Detector.h"
00016 #include "AstroUtil/Ast.h"
00017
00018 CVSID("$Id: Ast.cxx,v 1.5 2005/12/13 15:57:30 rhatcher Exp $");
00019
00020
00021
00022
00023 double AstUtil::GetDetLatitude(Detector::Detector_t detector) {
00024
00025
00026
00027
00028 switch( detector ) {
00029
00030 case Detector::kFar:
00031 return kFarDetLatitude;
00032
00033 case Detector::kNear:
00034 return kNearDetLatitude;
00035
00036 default:
00037 MSG("Ast",Msg::kWarning) << "Latitudinal position for detector "
00038 << Detector::AsString(detector) << " unavailable." << endl;
00039 return 0;
00040
00041 }
00042
00043 }
00044
00045 double AstUtil::GetDetLongitude(Detector::Detector_t detector) {
00046
00047
00048
00049 switch( detector ) {
00050
00051 case Detector::kFar:
00052 return kFarDetLongitude;
00053
00054 case Detector::kNear:
00055 return kNearDetLongitude;
00056
00057 default:
00058 MSG("Ast",Msg::kWarning) << "Longitudinal position for detector "
00059 << Detector::AsString(detector) << " unavailable." << endl;
00060 return 0;
00061
00062 }
00063
00064 }
00065
00066 const double*
00067 AstUtil::GetDetRotMatrixLocalToIdeal(Detector::Detector_t detector) {
00068
00069
00070
00071
00072 switch( detector ) {
00073
00074 case Detector::kFar:
00075 return kFarDetRotMatrixLocalToIdeal;
00076
00077 case Detector::kNear:
00078 return kNearDetRotMatrixLocalToIdeal;
00079
00080 default:
00081 MSG("Ast",Msg::kWarning)
00082 << "Rotation matrix from local to ideal coordinates for detector "
00083 << Detector::AsString(detector) << " unavailable." << endl;
00084 return 0;
00085
00086 }
00087
00088 }
00089
00090 const double*
00091 AstUtil::GetDetRotMatrixIdealToLocal(Detector::Detector_t detector) {
00092
00093
00094
00095
00096 switch( detector ) {
00097
00098 case Detector::kFar:
00099 return kFarDetRotMatrixIdealToLocal;
00100
00101 case Detector::kNear:
00102 return kNearDetRotMatrixIdealToLocal;
00103
00104 default:
00105 MSG("Ast",Msg::kWarning)
00106 << "Rotation matrix from ideal to local coordinates for detector "
00107 << Detector::AsString(detector) << " unavailable." << endl;
00108 return 0;
00109
00110 }
00111
00112 }
00113
00114
00115
00116
00117
00118
00119