-void AliMUONFastTracking::SmearMuon(Float_t pgen, Float_t thetagen, Float_t phigen,
- Int_t charge, Float_t &psmear, Float_t &thetasmear,
- Float_t &phismear, Float_t &eff, Float_t &acc){
-
- // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
- // IMPORTANT NOTICE TO THE USER
- //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
- // THIS METHOD HAS BEEN REPLACED BY AliFastMuonTrackingEff::Evaluate()
- // AND WILL BE DELETED SOON
- // DO NOT USE THIS METHOD
- //
-
- printf ("AliMUONFastTracking::SmearMuon() THIS METHOD IS OBSOLETE ");
- printf ("PLEASE REFER TO AliFastMuonTrackingEff::Evaluate()\n");
- // angles are in degrees
-
- Double_t meanp = MeanP (pgen, thetagen, phigen, charge);
- Double_t sigmap = SigmaP (pgen, thetagen, phigen, charge);
- Double_t sigma1p = Sigma1P(pgen, thetagen, phigen, charge);
- Double_t normg2 = NormG2 (pgen, thetagen, phigen, charge);
- Double_t meang2 = MeanG2 (pgen, thetagen, phigen, charge);
- Double_t sigmag2 = SigmaG2(pgen, thetagen, phigen, charge);
-
- printf ("fBkg = %g normg2 (100,5,0,1) = %g \n",fBkg,NormG2(100,5,0,1));
- printf ("fBkg = %g meang2 (100,5,0,1) = %g \n",fBkg,MeanG2(100,5,0,1));
- printf ("fBkg = %g sigmag2 (100,5,0,1) = %g \n",fBkg,SigmaG2(100,5,0,1));
- Int_t ip,itheta,iphi;
- GetIpIthetaIphi(pgen, thetagen, phigen, charge, ip, itheta, iphi);
- if (sigmap == 0) {
- if (fPrintLevel>0) {
- printf ("WARNING!!! sigmap=0: ");
- printf ("ip= %d itheta = %d iphi = %d ", ip, itheta, iphi);
- printf ("p= %f theta = %f phi = %f\n", pgen, thetagen, phigen);
- }
- }
-
- if (fPrintLevel>1) printf ("setting parameters: meanp = %f sigmap = %f sigma1p = %f normg2 = %f meang2 = %f sigmag2 = %f \n",meanp,sigmap,sigma1p,normg2,meang2,sigmag2);
- fFitp->SetParameters(meanp,sigmap,sigma1p,normg2,meang2,sigmag2);
-
- Double_t meantheta = MeanTheta (pgen, thetagen, phigen, charge);
- Double_t sigmatheta = SigmaTheta(pgen, thetagen, phigen, charge);
- Double_t meanphi = MeanPhi (pgen, thetagen, phigen, charge);
- Double_t sigmaphi = SigmaPhi (pgen, thetagen, phigen, charge);
-
- // components different from ip=0 have the RMS bigger than mean
- Float_t ptp[3] = { 1.219576,-0.354764,-0.690117 };
- Float_t ptph[3] = { 0.977522, 0.016269, 0.023158 };
- Float_t pphp[3] = { 1.303256,-0.464847,-0.869322 };
- psmear = pgen + fFitp->GetRandom();
- Float_t dp = psmear - pgen;
- if (ip==0) sigmaphi *= pphp[0] + pphp[1] * dp + pphp[2] * dp*dp;
- phismear = phigen + gRandom->Gaus(meanphi, sigmaphi);
- Float_t dphi = phismear - phigen;
-
- if (ip==0) sigmatheta *= ptp[0] + ptp[1] * dp + ptp[2] * dp*dp;
- if (ip==0) sigmatheta *= ptph[0] + ptph[1] * dphi + ptph[2] * dphi*dphi;
- thetasmear = thetagen + gRandom->Gaus(meantheta,sigmatheta);
- eff = Efficiency(pgen, thetagen, phigen, charge);
- acc = Acceptance(pgen, thetagen, phigen, charge);
-}
-