11#include <framework/core/Module.h>
12#include <framework/datastore/StoreArray.h>
13#include <framework/core/RandomGenerator.h>
14#include <framework/gearbox/Const.h>
15#include <mdst/dataobjects/MCParticle.h>
16#include <Math/Vector4D.h>
45 virtual void event()
override;
57 void displaceDaughter(ROOT::Math::PxPyPzEVector& motherDisplacementVector, std::vector<MCParticle*> daughters);
"Takes a list of PDG values and lifetime paramters to displaces the vertex of MCParticles with matchi...
void getDisplacement(const MCParticle &particle, float lifetime, ROOT::Math::PxPyPzEVector &displacement)
Helper function to calculate the numerical value of the vertex displacement (x,y,z,...
virtual void initialize() override
Register input and output data, initialises the module.
virtual void event() override
Method is called for each event.
bool m_ctau
Input unit option.
StoreArray< MCParticle > m_mcparticles
store array for the MCParticles
float m_maxDecayTime
Set the maximal decayTime for the options 'flat' and 'exponential'.
void displaceDaughter(ROOT::Math::PxPyPzEVector &motherDisplacementVector, std::vector< MCParticle * > daughters)
Helper function to loop over subsequent daughters and displaces their vertices corresponding to their...
virtual void terminate() override
Terminates the module.
GeneratedVertexDisplacerModule()
Constructor: Sets the description, the properties and the parameters of the module.
void displace(MCParticle &particle, float lifetime)
Helper function to displace the mother particles (corresponding to given pdf values).
std::string m_lifetimeOption
Set the lifetime option, either fixed, flat exponential.
std::vector< int > m_pdgVals
Set the particles whose vertices should be displaced
std::string m_particleList
The name of the MCParticle collection.
std::vector< float > m_lifetime
Set the numerical value of the lifetime ctau [cm]
A Class to store the Monte Carlo particle information.
Accessor to arrays stored in the data store.
Abstract base class for different kinds of events.