#include "AliGenSlowNucleons.h"
#include "AliSlowNucleonModel.h"
-ClassImp(AliGenSlowNucleons);
+ClassImp(AliGenSlowNucleons)
AliGenSlowNucleons::AliGenSlowNucleons()
fATarget (0.),
fZTarget (0.),
fCharge(0),
- fProtonDirection(0.),
+ fProtonDirection(1.),
fTemperatureG(0.),
fBetaSourceG(0.),
fTemperatureB(0.),
fATarget (208.),
fZTarget (82.),
fCharge(1),
- fProtonDirection(0.),
+ fProtonDirection(1.),
fTemperatureG(0.04),
fBetaSourceG(0.05),
fTemperatureB(0.004),
fCollisionGeometry = 0;
}
-//____________________________________________________________
-AliGenSlowNucleons::AliGenSlowNucleons(const AliGenSlowNucleons & sn):
- AliGenerator(sn),
- fCMS(0.),
- fMomentum(0.),
- fBeta(0.),
- fPmax (0.),
- fATarget (0.),
- fZTarget (0.),
- fCharge(0),
- fProtonDirection(0.),
- fTemperatureG(0.),
- fBetaSourceG(0.),
- fTemperatureB(0.),
- fBetaSourceB(0.),
- fNgp(0),
- fNgn(0),
- fNbp(0),
- fNbn(0),
- fDebug(0),
- fDebugHist1(0),
- fDebugHist2(0),
- fThetaDistribution(),
- fCosThetaGrayHist(),
- fCosTheta(),
- fSlowNucleonModel(0)
-{
-// Copy constructor
- sn.Copy(*this);
-}
-
//____________________________________________________________
AliGenSlowNucleons::~AliGenSlowNucleons()
{
//
Float_t p[3], theta=0;
Float_t origin[3] = {0., 0., 0.};
+ Float_t time = 0.;
Float_t polar [3] = {0., 0., 0.};
Int_t nt, i, j;
Int_t kf;
if(fVertexSmear == kPerEvent) {
Vertex();
for (j=0; j < 3; j++) origin[j] = fVertex[j];
+ time = fTime;
} // if kPerEvent
//
// Gray protons
GenerateSlow(fCharge, fTemperatureG, fBetaSourceG, p, theta);
if (fDebug) fCosThetaGrayHist->Fill(TMath::Cos(theta));
PushTrack(fTrackIt, -1, kf, p, origin, polar,
- 0., kPNoProcess, nt, 1.);
+ time, kPNoProcess, nt, 1.);
KeepTrack(nt);
}
//
GenerateSlow(fCharge, fTemperatureG, fBetaSourceG, p, theta);
if (fDebug) fCosThetaGrayHist->Fill(TMath::Cos(theta));
PushTrack(fTrackIt, -1, kf, p, origin, polar,
- 0., kPNoProcess, nt, 1.);
+ time, kPNoProcess, nt, 1.);
KeepTrack(nt);
}
//
for(i = 0; i < fNbp; i++) {
GenerateSlow(fCharge, fTemperatureB, fBetaSourceB, p, theta);
PushTrack(fTrackIt, -1, kf, p, origin, polar,
- 0., kPNoProcess, nt, 1.);
+ time, kPNoProcess, nt, 1.);
KeepTrack(nt);
}
//
for(i = 0; i < fNbn; i++) {
GenerateSlow(fCharge, fTemperatureB, fBetaSourceB, p, theta);
PushTrack(fTrackIt, -1, kf, p, origin, polar,
- 0., kPNoProcess, nt, 1.);
+ time, kPNoProcess, nt, 1.);
KeepTrack(nt);
}
}
{
/* Lorentz transform in the direction of q[2] */
- Double_t gamma = 1/sqrt(1-beta*beta);
+ Double_t gamma = 1./sqrt((1.-beta)*(1.+beta));
Double_t energy = sqrt(m*m + q[0]*q[0] + q[1]*q[1] + q[2]*q[2]);
q[2] = gamma * (q[2] + beta*energy);
}
-
-
-AliGenSlowNucleons& AliGenSlowNucleons::operator=(const AliGenSlowNucleons& rhs)
-{
-// Assignment operator
- rhs.Copy(*this);
- return *this;
-}
-
-void AliGenSlowNucleons::Copy(TObject&) const
-{
- //
- // Copy
- //
- Fatal("Copy","Not implemented!\n");
-}
-
-
-
-
-
-
-