Ignore:
Timestamp:
04/04/04 19:06:45 (21 years ago)
Author:
gaug
Message:
*** empty log message ***
File:
1 edited

Legend:

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

    r3635 r3644  
    2727// MCalibrationRelTimeCam                                               
    2828//                                                               
    29 // Hold the whole Calibration results of the camera:
    30 //                                                               
    31 // 1) MCalibrationRelTimeCam initializes a TClonesArray whose elements are
    32 //    pointers to MCalibrationRelTimePix Containers
    33 //
     29// Storage container for relative arrival time calibration results         
     30// of the whole camera.
     31//
     32// Individual pixels have to be cast when retrieved e.g.:
     33// MCalibrationRelTimePix &avpix = (MCalibrationRelTimePix&)(*fRelCam)[i]
     34//
     35// The following "calibration" constants can be retrieved from each pixel:
     36// - GetTimeOffset(): The mean offset in relative times,
     37//   has to be added to any calculated relative time in the camera.
     38// - GetTimePrecision(): The Gauss sigma of histogrammed relative arrival
     39//   times for the calibration run. Gives an estimate about the timing
     40//   resolution.
     41//
     42// ALL RELATIVE TIMES HAVE TO BE CALCULATED W.R.T. PIXEL IDX 1
     43// (HARDWARE NUMBER: 2) !!
     44//
     45// Averaged values over one whole area index (e.g. inner or outer pixels for
     46// the MAGIC camera), can be retrieved via:
     47// MCalibrationRelTimePix &avpix = (MCalibrationRelTimePix&)fRelCam->GetAverageArea(i)
     48//
     49// Averaged values over one whole camera sector can be retrieved via:
     50// MCalibrationRelTimePix &avpix = (MCalibrationRelTimePix&)fRelCam->GetAverageSector(i)
     51//
     52// Note the averageing has been done on an event-by-event basis. Resulting
     53// Sigma's of the Gauss fit have been multiplied with the square root of the number
     54// of involved pixels in order to make a direct comparison possible with the mean of
     55// sigmas.
     56//
     57// See also: MHCalibrationRelTimePix, MHCalibrationRelTimeCam             
     58//                                                                         
    3459// The calculated values (types of GetPixelContent) are:
    3560//
     
    3762// ==============
    3863//
    39 // 0: Fitted RelTime
    40 // 1: Error of fitted RelTime
    41 // 2: Sigma of fitted RelTime
    42 // 3: Error of Sigma of fitted RelTime
     64// 0: Mean Time Offset
     65// 1: Error of Mean Time Offset
     66// 2: Sigma of Time Offset == Time Resolution
     67// 3: Error of Sigma of Time Offset
    4368//
    4469// Useful variables derived from the fit results:
    4570// =============================================
    4671//
    47 // 4: Returned probability of Gauss fit to RelTime distribution
     72// 4: Returned probability of Gauss fit to Rel. Arrival Time distribution
    4873//
    4974/////////////////////////////////////////////////////////////////////////////
     
    6994// Default constructor.
    7095//
    71 // Creates a TClonesArray of MCalibrationPix containers, initialized to 1 entry
    72 // Later, a call to MCalibrationRelTimeCam::InitSize(Int_t size) has to be performed
    73 //
    74 // Creates an MCalibrationBlindPix container
     96// Creates a TClonesArray of MCalibrationPix containers, initialized to 1 entry, destinated
     97// to hold one container per pixel. Later, a call to MCalibrationRelTimeCam::InitSize()
     98// has to be performed (in MGeomApply).
     99//
     100// Creates a TClonesArray of MCalibrationPix containers, initialized to 1 entry, destinated
     101// to hold one container per pixel AREA. Later, a call to MCalibrationRelTimeCam::InitAreas()
     102// has to be performed (in MGeomApply).
     103//
     104// Creates a TClonesArray of MCalibrationPix containers, initialized to 1 entry, destinated
     105// to hold one container per camera SECTOR. Later, a call to MCalibrationRelTimeCam::InitSectors()
     106// has to be performed (in MGeomApply).
    75107//
    76108MCalibrationRelTimeCam::MCalibrationRelTimeCam(const char *name, const char *title)
     
    83115    fAverageSectors   = new TClonesArray("MCalibrationRelTimePix",1);
    84116
    85     Clear();
    86 
    87 }
    88 
    89 
    90 
    91 // --------------------------------------
    92 //
    93 void MCalibrationRelTimeCam::Clear(Option_t *o)
    94 {
    95 
    96   MCalibrationCam::Clear();
    97 
    98   CLRBIT(fFlags,kValid);
    99 
    100   return;
    101 }
    102 
    103 void MCalibrationRelTimeCam::SetValid(const Bool_t b)
    104 {
    105     b ? SETBIT(fFlags, kValid) : CLRBIT(fFlags, kValid);
    106 }
    107 
    108 
    109 Bool_t  MCalibrationRelTimeCam::IsValid()   const
    110 {
    111   return TESTBIT(fFlags,kValid);
    112117}
    113118
     
    115120//
    116121// Print first the well fitted pixels
    117 // and then the ones which are not FitValid
     122// and then the ones which are not Valid
    118123//
    119124void MCalibrationRelTimeCam::Print(Option_t *o) const
     
    254259// --------------------------------------------------------------------------
    255260//
    256 // What MHCamera needs in order to draw an individual pixel in the camera
     261// Calls MCalibrationPix::DrawClone()
    257262//
    258263void MCalibrationRelTimeCam::DrawPixelContent(Int_t idx) const
     
    261266}
    262267
    263 
    264 
    265 Bool_t MCalibrationRelTimeCam::GetConversion(Int_t ipx, Float_t &mean, Float_t &err, Float_t &sigma)
    266 {
    267 
    268   MCalibrationRelTimePix &pix = (MCalibrationRelTimePix&)(*this)[ipx];
    269 
    270   mean  = pix.GetMeanConversion();
    271   err   = pix.GetConversionErr();
    272   sigma = pix.GetSigmaConversion();
    273 
    274   return kTRUE;
    275 }
    276 
    277 
Note: See TracChangeset for help on using the changeset viewer.