eic-smear
1.0.3
A collection of ROOT classes for Monte Carlo events and a fast-smearing code simulating detector effects for the Electron-Ion Collider task force
|
Go to the documentation of this file.
69 useNM = s.Contains(
"nm") || s.Contains(
"null");
70 useJB = s.Contains(
"jb") || s.Contains(
"jacquet");
71 useDA = s.Contains(
"da") || s.Contains(
"double");
76 if (
unsigned(n) <
Devices.size()) {
92 typedef std::auto_ptr<erhic::DisKinematics> KinPtr;
93 if (
useNM && scattered) {
108 if (
useDA && scattered) {
117 std::list<Smearer*> devices;
121 std::vector<Smearer*>::const_iterator iter;
124 if ((*iter)->Accept.Is(p)) {
125 devices.push_back(*iter);
135 std::list<Smearer*> devices =
Accept(prt);
137 if (!devices.empty()) {
141 std::list<Smearer*>::iterator iter;
142 for (iter = devices.begin(); iter != devices.end(); ++iter) {
143 (*iter)->Smear(prt, *prtOut);
146 prtOut->
px = prtOut->
p * sin(prtOut->
theta) * cos(prtOut->
phi);
147 prtOut->
py = prtOut->
p * sin(prtOut->
theta) * sin(prtOut->
phi);
148 prtOut->
pt = sqrt(pow(prtOut->
px, 2.) + pow(prtOut->
py, 2.));
149 prtOut->
pz = prtOut->
p * cos(prtOut->
theta);
155 std::vector<Smearer*> copies;
157 std::back_inserter(copies),
void FillEventKinematics(Event *event)
Calculate event-wise smeared kinematics for an event which has already had its particles smeared and ...
virtual void SetLeptonKinematics(const DisKinematics &)
Set the kinematics computed from the scattered lepton.
Double32_t p
Total momentum of particle.
Double32_t pt
Transverse momentum of particle.
void DeleteAllDevices()
Delete all devices in the detector.
std::list< Smear::Smearer * > Accept(const erhic::VirtualParticle &) const
Returns the list of devices in this detector that accept a particle.
Double32_t pz
z component of particle momentum
A collection of DIS kinematic variables.
Double32_t phi
Azimuthal angle.
Computes DIS event kinematics from the scattered lepton.
Computes DIS event kinematics from final-state hadrons using the Jacquet-Blondel method.
Double32_t py
y component of particle momentum
Detector()
Default contructor.
virtual DisKinematics * Calculate()
virtual UShort_t GetStatus() const =0
A general "status" code for the particle (definition depends on implementation).
UInt_t GetNDevices() const
Returns the number of devices in the detector.
virtual void SetDoubleAngleKinematics(const DisKinematics &)
Set the kinematics computed from the double-angle method.
virtual void Print(Option_t *="") const
Print information about all smearers to standard output.
Abstract base class for a general particle.
Abstract base class for objects performing smearing.
virtual ~Detector()
Destructor.
virtual void SetJacquetBlondelKinematics(const DisKinematics &)
Set the kinematics computed from the Jacquet-Blondel method.
A smeared Monte Carlo particle.
virtual DisKinematics * Calculate()
Double32_t theta
Polar angle.
virtual DisKinematics * Calculate()
std::vector< Smearer * > Devices
void SetEventKinematicsCalculator(TString)
Set the method for calculating event kinematics if FillEventKinematics is used.
void AddDevice(Smearer &device)
Adds a copy of the smearing device to this detector.
ParticleMCS * Smear(const erhic::VirtualParticle &) const
Detector level particle smearing.
Computes DIS event kinematics from a mixture of hadronic and lepton variables using the double-angle ...
Detector & operator=(const Detector &)
Assignment operator.
virtual const ParticleMCS * ScatteredLepton() const
Returns a pointer to the lepton beam particle after scattering.
std::vector< Smear::Smearer * > CopyDevices() const
Returns pointers to new copies of all devices.
virtual Smearer * Clone(const char *="") const =0
Inherited from TObject.
Smearer * GetDevice(int index)
Return a pointer to device number n from the detector.
Double32_t px
x component of particle momentum