Main Page | Modules | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members | File Members

TMBLum.hpp

Go to the documentation of this file.
00001 #ifndef TMBLum_H
00002 #define TMBLum_H
00003 
00005 //                                                                      //
00006 // TMBTree Lum class                                                    //
00007 //   Storage format for Luminosity Montior in TMB_Trees.                //
00008 //   Sahal Yacoob 11/13/03                                              // 
00009 //   Based on Other TMBTree classes                                     //
00010 //   The Charge, TDC count, and Slew are stored.                        //
00011 //   The index is related to the physical wedge by the tabel            //
00012 //   to be found later in this file                                     //
00013 //                                                                      //  
00014 //                                                                      //
00016 
00017 #ifndef ROOT_TObject
00018 #include "TObject.h"
00019 #endif
00020 
00021 
00022 class TMBLum : public TObject {
00023   
00024 public:
00025 
00026   // Default Constructor
00027   TMBLum();
00028 
00029   // Constructor
00030   TMBLum(Int_t id, Int_t charge, Int_t time, Int_t slew, Int_t range, Int_t tc );
00031   
00032   TMBLum(Int_t id, Float_t charge, Float_t time, Float_t slew, Float_t range, Float_t tc);
00033   
00034   // Copy Constructor
00035   TMBLum (const TMBLum& orig):TObject(orig) {
00036     *this = orig;
00037   }
00038 
00039 
00040   //Tools for Lum Analysis
00041   Bool_t  IsNorth() const { // returns kTRUE if we are talking about a north side Wedge
00042     Bool_t dummy = kFALSE;
00043     if (_id < 0 || _id > 47){
00044       return dummy;
00045     }
00046     if (_id < 24)
00047       dummy = kTRUE;
00048     return dummy;
00049   }
00050 
00051   Bool_t  IsSouth() const { // returns kTRUE if we are talking about a north side Wedge
00052     Bool_t dummy = kFALSE;
00053     if (_id < 0 || _id > 47){
00054       return dummy;
00055     }
00056     if (_id > 23)
00057       dummy = kTRUE;
00058     return dummy;
00059   }
00060 
00061 
00062 
00063 
00064   // Operators
00065   TMBLum &operator=(const TMBLum &orig) {
00066     if(this != &orig) {
00067       _time     = orig._time;
00068       _id       = orig._id;
00069       _charge   = orig._charge;
00070       _slew     = orig._slew;
00071       _range    = orig._range;
00072       _tc       = orig._tc;             
00073     }
00074     return *this;
00075   }  
00076   
00077   Int_t       charge()       const { return _charge;}  // in femtoCoulomb
00078   Int_t       time()           const  {return _time;}  // in tdc counts (1 ns = 20 tdc counts)
00079   Int_t         id() const {return _id;}   // Wedge Id from 0 - 47
00080   Int_t range() const {return _range;} // Range between 0 and 3.
00081   Int_t tc() const {return _tc;} //  // in tdc counts (1 ns = 20 tdc counts)
00082 
00083 //   0= "NW01";   // WEDGE LABELS
00084 //   1= "NW02";
00085 //   2= "NW03";
00086 //   3= "NW04";
00087 //   4= "NW05";
00088 //   5= "NW06";
00089 //   6= "NW07";
00090 //   7= "NW08";
00091 //   8= "NW09";
00092 //   9= "NW10";
00093 //   10="NW11";
00094 //   11="NW12";
00095   
00096 //   12="NE01";
00097 //   13="NE02";
00098 //   14="NE03";
00099 //   15="NE04";
00100 //   16="NE05";
00101 //   17="NE06";
00102 //   18="NE07";
00103 //   19="NE08";
00104 //   20="NE09";
00105 //   21="NE10";
00106 //   22="NE11";
00107 //   23="NE12";
00108   
00109 //   24="SW01";
00110 //   25="SW02";
00111 //   26="SW03";
00112 //   27="SW04";
00113 //   28="SW05";
00114 //   29="SW06";
00115 //   30="SW07";
00116 //   31="SW08";
00117 //   32="SW09";
00118 //   33="SW10";
00119 //   34="SW11";
00120 //   35="SW12";
00121   
00122 //   36="SE01";
00123 //   37="SE02";
00124 //   38="SE03";
00125 //   39="SE04";
00126 //   40="SE05";
00127 //   41="SE06";
00128 //   42="SE07";
00129 //   43="SE08";
00130 //   44="SE09";
00131 //   45="SE10";
00132 //   46="SE11";
00133 //   47="SE12";
00134 
00135 //   48="TM01";
00136 //   49="TM02";
00137 //   50="TM03";
00138 //   51="TM04";
00139 //   52="TM05";
00140 //   53="TM06";
00141 //   54="TM07";
00142 //   55="TM08";
00143 
00144 
00145 
00146   Int_t       slew() const {return _slew;} // slew in tdc sounts
00147   Float_t       phi() const; // phi angle of centre of wedge with id (_id)
00148 
00149   void          id(Int_t id) { _id = id;}
00150   void          charge(Int_t charge) { _charge = charge;}
00151   void          time(Int_t time)        { _time = time;}
00152   void          slew(Int_t slew) {_slew = slew;}
00153   void          tc(Int_t tc) {_tc=tc;}
00154   // Destructor
00155   ~TMBLum() {;}
00156 
00157 private:
00158   Int_t     _time;       // time in TDC counts ( 1ns - 20 tdc)
00159   Int_t     _charge;     // charge in fC
00160   Int_t       _id;       // Wedge id
00161   Int_t     _slew;       // slew correction in TDC counts
00162   Int_t     _range;      // range.
00163   Int_t     _tc;         // tc 
00164   ClassDef(TMBLum, 2)   //TMBTree Lum class
00165 };
00166 
00167 #endif

Generated on Tue Mar 28 10:13:05 2006 for CAF by doxygen 1.3.4