10#include <generators/modules/SmearPrimaryVertexModule.h>
13#include <framework/dataobjects/MCInitialParticles.h>
14#include <framework/datastore/StoreArray.h>
15#include <framework/logging/Logger.h>
16#include <mdst/dataobjects/MCParticle.h>
29 setDescription(
"Smears primary vertex and all subsequent vertices of all the MCParticles using the informations stored in BeamParameters.");
50 if (shift == ROOT::Math::XYZVector(0, 0, 0))
return;
53 mcParticle.setProductionVertex(mcParticle.getProductionVertex() + shift);
55 if (mcParticle.getNDaughters() > 0)
56 mcParticle.setDecayVertex(mcParticle.getDecayVertex() + shift);
This class contains the nominal beam parameters and the parameters used for smearing of the primary v...
A Class to store the Monte Carlo particle information.
void setDescription(const std::string &description)
Sets the description of the module.
virtual void initialize() override
Initialize the module.
virtual void event() override
This method is called for each event.
SmearPrimaryVertexModule()
Constructor.
InitialParticleGeneration m_Initial
Initial particle generation.
std::string m_MCParticlesName
Name of the MCParticles StoreArray.
virtual ~SmearPrimaryVertexModule()
Destructor.
bool isRequired(const std::string &name="")
Ensure this array/object has been registered previously.
Accessor to arrays stored in the data store.
void addParam(const std::string &name, T ¶mVariable, const std::string &description, const T &defaultValue)
Adds a new parameter to the module.
#define REG_MODULE(moduleName)
Register the given module (without 'Module' suffix) with the framework.
void initialize()
function to be executed on initialize()
ROOT::Math::XYZVector updateVertex(bool force=false)
Update the vertex position:
Abstract base class for different kinds of events.