Changeset 6986 for trunk/MagicSoft/Mars/mmuon
- Timestamp:
- 04/29/05 13:09:12 (20 years ago)
- Location:
- trunk/MagicSoft/Mars/mmuon
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mmuon/MHSingleMuon.cc
r6979 r6986 126 126 } 127 127 128 MMuonSetup *setup = (MMuonSetup*) plist->FindObject("MMuonSetup");128 MMuonSetup *setup = (MMuonSetup*)const_cast<MParList*>(plist)->FindCreateObj("MMuonSetup"); 129 129 if (!setup) 130 { 131 *fLog << warn << "MMuonSetup not found... abort." << endl; 132 return kFALSE; 133 } 130 return kFALSE; 131 134 132 fMargin = setup->GetMargin()/fGeomCam->GetConvMm2Deg(); 135 133 … … 185 183 // Up to now, the error of pedestal is not taken into accout. This is not 186 184 // of course correct. We will include this soon. 187 Double_t ADC2PhEl = 0.14; 188 Double_t Ffactor = 1.4; 185 const Double_t Ffactor = 1.4; 189 186 for (Int_t i=0; i<fHistPhi.GetNbinsX()+1; i++) 190 187 { 191 188 const Float_t abs = TMath::Abs(fHistPhi.GetBinContent(i)); 192 const Float_t rougherr = TMath::Sqrt(abs /ADC2PhEl)*Ffactor;189 const Float_t rougherr = TMath::Sqrt(abs)*Ffactor; 193 190 194 191 fHistPhi.SetBinError(i, rougherr); … … 198 195 { 199 196 const Float_t abs = TMath::Abs(fHistWidth.GetBinContent(i)); 200 const Float_t rougherr = TMath::Sqrt(abs /ADC2PhEl)*Ffactor;197 const Float_t rougherr = TMath::Sqrt(abs)*Ffactor; 201 198 202 199 fHistWidth.SetBinError(i, rougherr); … … 298 295 first = 0; // If maximum is on the left side of histogram 299 296 297 if (last-first<=3) 298 return kFALSE; 299 300 300 // Now get the fit range 301 301 const Float_t startfitval = fHistWidth.GetBinLowEdge(first+1); … … 316 316 fHistWidth.Fit(&f1, "NQR"); 317 317 318 if (last-first>3) 319 chi = f1.GetChisquare()/(last-first-3); 318 chi = f1.GetChisquare()/f1.GetNDF(); 320 319 321 320 Double_t err; -
trunk/MagicSoft/Mars/mmuon/MMuonCalibParCalc.cc
r6979 r6986 187 187 { 188 188 // Calculation of Arc Phi etc... 189 const Float_t thresphi = fMuonSetup->GetThresholdArcPhi() /fGeomCam->GetConvMm2Deg();190 const Float_t threswidth = fMuonSetup->GetThresholdArcWidth() /fGeomCam->GetConvMm2Deg();189 const Float_t thresphi = fMuonSetup->GetThresholdArcPhi(); 190 const Float_t threswidth = fMuonSetup->GetThresholdArcWidth(); 191 191 192 192 Double_t peakphi, arcphi; -
trunk/MagicSoft/Mars/mmuon/MMuonSetup.cc
r6979 r6986 45 45 // 46 46 MMuonSetup::MMuonSetup(const char *name, const char *title) 47 : fMargin(0.2), fThresholdArcPhi( 0.1), fThresholdArcWidth(0.1)47 : fMargin(0.2), fThresholdArcPhi(30), fThresholdArcWidth(30) 48 48 { 49 49 fName = name ? name : "MMuonSetup"; … … 55 55 // Read the setup from a TEnv, eg: 56 56 // MMuonSetup.Margin: 0.2 57 // MMuonSetup.ThresholdArcPhi: 0.158 // MMuonSetup.ThresholdArcWidth: 0.157 // MMuonSetup.ThresholdArcPhi: 30 58 // MMuonSetup.ThresholdArcWidth: 30 59 59 // 60 60 Int_t MMuonSetup::ReadEnv(const TEnv &env, TString prefix, Bool_t print) -
trunk/MagicSoft/Mars/mmuon/MMuonSetup.h
r6979 r6986 10 10 private: 11 11 Float_t fMargin; // [deg] margin to evaluate muons. The defaut value is 60 mm, corresponding to 0.2 deg. This value can be changed by using the function of SetMargin 12 Float_t fThresholdArcPhi; // [ deg] The threshold value to define arc phi13 Float_t fThresholdArcWidth; // [ deg] The threshold value to define arc width12 Float_t fThresholdArcPhi; // [phe] The threshold value to define arc phi 13 Float_t fThresholdArcWidth; // [phe] The threshold value to define arc width 14 14 15 15 Int_t ReadEnv(const TEnv &env, TString prefix, Bool_t print);
Note:
See TracChangeset
for help on using the changeset viewer.