Changeset 3757
- Timestamp:
- 04/15/04 17:13:25 (21 years ago)
- Location:
- trunk/MagicSoft/Mars
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/Changelog
r3756 r3757 36 36 - added MArrivalTime::Init() 37 37 38 * msignal/MArrivalTime.[h,cc] 39 - added array fDataErr 38 40 39 41 -
trunk/MagicSoft/Mars/mcalib/MCalibrateRelTimes.cc
r3752 r3757 174 174 175 175 Float_t signal; 176 Float_t sigerr; 176 177 177 178 if (sig.IsLoGainUsed()) 178 signal = sig.GetArrivalTimeLoGain(); 179 { 180 signal = sig.GetArrivalTimeLoGain(); 181 sigerr = sig.GetArrivalTimeLoGainError(); 182 } 179 183 else 180 signal = sig.GetArrivalTimeHiGain(); 184 { 185 signal = sig.GetArrivalTimeHiGain(); 186 sigerr = sig.GetArrivalTimeHiGainError(); 187 } 181 188 182 189 const Float_t time = signal - offset; 183 184 // 185 // The following part is the outcommented first version of the error calculation 186 // Contact Markus Gaug for questions (or wait for the next documentation update...) 187 // 188 /* 189 nphotErr = signal > 0 ? signalErr*signalErr / (signal * signal) : 0. 190 + calibConv > 0 ? calibConvVar / (calibConv * calibConv ) : 0. 191 + calibQE > 0 ? calibQEVar / (calibQE * calibQE ) : 0.; 192 nphotErr = TMath::Sqrt(nphotErr) * nphot; 193 */ 190 Float_t err = sigerr*sigerr + precision*precision; 191 if (err > 0) 192 err = TMath::Sqrt(err); 194 193 195 194 fArrivalTime->SetTime(pixidx,time); 195 fArrivalTime->SetTimeErr(pixidx,err); 196 196 197 197 } /* for (UInt_t pixidx=0; pixidx<npix; pixidx++) */ -
trunk/MagicSoft/Mars/msignal/MArrivalTime.cc
r3306 r3757 17 17 ! 18 18 ! Author(s): Sebastian Raducci, 12/2003 <mailto:raducci@fisica.uniud.it> 19 ! Markus Gaug 04/2004 <mailto:markus@ifae.es> 19 20 ! 20 21 ! Copyright: MAGIC Software Development, 2000-2004 … … 62 63 void MArrivalTime::Reset() 63 64 { 64 fData.Reset(-1); 65 fData.Reset(-1); 66 fDataErr.Reset(-1); 65 67 } 66 68 67 69 void MArrivalTime::InitSize(Int_t i) 68 70 { 69 fData.Set(i); 71 fData.Set(i); 72 fDataErr.Set(i); 70 73 } 71 74 … … 77 80 { 78 81 fData[i] = t; 82 } 83 84 85 // ------------------------------------------------------------------------- 86 // 87 // Set the arrival time error in one pixel 88 // 89 void MArrivalTime::SetTimeErr(const Int_t i, const Float_t t) 90 { 91 fDataErr[i] = t; 79 92 } 80 93 -
trunk/MagicSoft/Mars/msignal/MArrivalTime.h
r3306 r3757 20 20 class MArrivalTime : public MParContainer, public MCamEvent 21 21 { 22 private: 23 TArrayF fData; // Stores the arrival times 22 private: 23 TArrayF fData; // Stores the calibrated arrival times 24 TArrayF fDataErr; // Stores the calibrated arrival time errors 24 25 25 26 public: … … 34 35 35 36 void SetTime(const Int_t i, const Float_t time); 37 void SetTimeErr(const Int_t i, const Float_t timeerr); 36 38 37 39 const TArrayF &GetData() const { return fData; } 40 const TArrayF &GetDataErr() const { return fDataErr; } 38 41 39 42 Double_t operator[](int i) { return fData[i]; } 43 Double_t operator()(int i) { return fDataErr[i]; } 40 44 41 45 Bool_t GetPixelContent(Double_t &val, Int_t idx, const MGeomCam &cam, Int_t type=0) const;
Note:
See TracChangeset
for help on using the changeset viewer.