Ignore:
Timestamp:
04/03/04 17:27:50 (20 years ago)
Author:
gaug
Message:
*** empty log message ***
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/mcalib/MHCalibrationRelTimePix.cc

    r3625 r3636  
    4040using namespace std;
    4141//
    42 const Int_t   MHCalibrationRelTimePix::fgChargeNbins    = 900;
    43 const Axis_t  MHCalibrationRelTimePix::fgChargeFirst    = -13.;
    44 const Axis_t  MHCalibrationRelTimePix::fgChargeLast     =  13.;
     42const Int_t   MHCalibrationRelTimePix::fgRelTimeNbins    = 900;
     43const Axis_t  MHCalibrationRelTimePix::fgRelTimeFirst    = -13.;
     44const Axis_t  MHCalibrationRelTimePix::fgRelTimeLast     =  13.;
    4545// --------------------------------------------------------------------------
    4646//
     
    4848//
    4949// Sets:
    50 // - the default number for fChargeNbins  (fgChargeNbins)
    51 // - the default number for fChargeFirst  (fgChargeFirst)
    52 // - the default number for fChargeLast   (fgChargeLast)
     50// - the default number for fNbins  (fgRelTimeNbins)
     51// - the default number for fFirst  (fgRelTimeFirst)
     52// - the default number for fLast   (fgRelTimeLast)
    5353//
    5454// - the default name of the  fHGausHist ("HCalibrationRelTime")
     
    6464//
    6565MHCalibrationRelTimePix::MHCalibrationRelTimePix(const char *name, const char *title)
    66     : fPixId(-1)
    6766{
    6867
     
    7069  fTitle = title ? title : "Histogrammed Calibration Relative Arrival Time events";
    7170
    72   SetChargeNbins();
    73   SetChargeFirst();
    74   SetChargeLast();
     71  SetNbins ( fgRelTimeNbins );
     72  SetFirst ( fgRelTimeFirst );
     73  SetLast  ( fgRelTimeLast  );
    7574
    7675  // Create a large number of bins, later we will rebin
     
    9695
    9796  fPixId = -1;
     97
    9898  MHGausEvents::Clear();
    9999  return;
     
    109109}
    110110
    111 // --------------------------------------------------------------------------
    112 //
    113 // Sets:
    114 // - fHGausHist.SetBins(fChargeNbins,fChargeFirst,fChargeLast);
    115 //
    116 void MHCalibrationRelTimePix::Init()
    117 {
    118111
    119   fHGausHist.SetBins(fChargeNbins,fChargeFirst,fChargeLast);
    120 
    121 }
    122 
    123 // --------------------------------------------------------------------------
    124 //
    125 // - Set fPixId to id
    126 //
    127 // Add id to names and titles of:
    128 // - fHGausHist
    129 //
    130 void MHCalibrationRelTimePix::ChangeHistId(Int_t id)
    131 {
    132 
    133   fPixId = id;
    134 
    135   fHGausHist.SetName(  Form("%s%d", fHGausHist.GetName(),  id));
    136   fHGausHist.SetTitle( Form("%s%d", fHGausHist.GetTitle(), id));
    137 
    138 }
    139 
    140 
    141 // ----------------------------------------------------------------------
    142 //
    143 // Renorm the results from FADC slices to times.
    144 // The parameters slicewidth is the inverse of the FADC frequency and has the unit ns.
    145 //
    146 void MHCalibrationRelTimePix::Renorm(const Float_t slicewidth)
    147 {
    148 
    149   SetMean(     GetMean()    * slicewidth  );
    150   SetMeanErr(  GetMeanErr() * slicewidth  );
    151   SetSigma(    GetSigma()   * slicewidth  );
    152   SetSigmaErr( GetSigmaErr()* slicewidth  );
    153  
    154 }
    155 
Note: See TracChangeset for help on using the changeset viewer.