ATLAS Offline Software
Loading...
Searching...
No Matches
Starlight_i.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3*/
4
5// --------------------------------------------------
6//
7// File: Generators/Starlight_i.h
8// Description:
9// This code is used to get a Starlight Monte Carlo event.
10// genInitialize() is used to read parameters
11// callGenerator() makes the event
12// genFinalize() writes log files etc
13// fillEvt(GeneratorEvent* evt) passes the event to HepMC
14//
15// The output will be stored in the transient event store so it can be
16// passed to the simulation.
17//
18// AuthorList:
19// Andrzej Olszewski, March 2015
20
21#ifndef GENERATORMODULESSTARLIGHT_H
22#define GENERATORMODULESSTARLIGHT_H
23
25
26#include "starlight.h"
27#include "upcevent.h"
28#include "upcXevent.h" // not compatible with Starlight older than r330
29#include "inputParameters.h"
30
31class Starlight_i:public GenModule {
32public:
33 Starlight_i(const std::string& name, ISvcLocator* pSvcLocator);
34 virtual ~Starlight_i();
35
36 virtual StatusCode genInitialize();
37 virtual StatusCode callGenerator();
38 virtual StatusCode genFinalize();
39 virtual StatusCode fillEvt(HepMC::GenEvent* evt);
40
41protected:
42 IntegerProperty m_dsid{this, "Dsid", 999999, "Dataset ID number"};
43 StringProperty m_configFileName{this, "ConfigFileName", ""};
44 BooleanProperty m_lheOutput{this, "lheOutput", false};
45 UnsignedIntegerProperty m_maxevents{this, "maxevents", 5500};
46 BooleanProperty m_doTauolappLheFormat{this, "doTauolappLheFormat", false};
47 BooleanProperty m_suppressVMdecay{this, "suppressVMdecay", false};
48 // Commands to setup starlight
49 StringArrayProperty m_InitializeVector{this,
50 "Initialize",
51 {},
52 "List of parameters for Starlight initialization",
53 "GeneratorSettings<std::string>"};
54
55 int m_events{0}; // event counter
56 std::unique_ptr<starlight> m_starlight{}; // pointer to starlight instance
57 std::shared_ptr<randomGenerator> m_randomGenerator{};
58 inputParameters m_inputParameters; // parameter instance
59 double m_axionMass{1.};
60 std::variant<
61 std::unique_ptr<upcEvent>, // Starting from version r330 m_event can be either
62 std::unique_ptr<upcXEvent> // upcEvent or upcXEvent depending on the process
64
65 unsigned int m_beam1Z{0};
66 unsigned int m_beam1A{0};
67 unsigned int m_beam2Z{0};
68 unsigned int m_beam2A{0};
69 double m_beam1Gamma{0.};
70 double m_beam2Gamma{0.};
71 double m_maxW{0.};
72 double m_minW{0.};
73 unsigned int m_nmbWBins{0};
74 double m_maxRapidity{0.};
75 unsigned int m_nmbRapidityBins{0};
76 bool m_accCutPt{false};
77 double m_minPt{0.};
78 double m_maxPt{0.};
79 bool m_accCutEta{false};
80 double m_minEta{0.};
81 double m_maxEta{0.};
83 unsigned int m_nmbEventsTot{0};
91 double m_bford{0.};
95 bool m_xsecMethod{false};
96 int m_nThreads{1};
97 bool m_pythFullRec{false};
98
99 bool starlight2lhef();
100
101 bool set_user_params();
102 bool prepare_params_file();
103};
104
105#endif
GenModule(const std::string &name, ISvcLocator *pSvcLocator)
Constructor.
Definition GenModule.cxx:14
unsigned int m_beam1A
Definition Starlight_i.h:66
int m_beamBreakupMode
Definition Starlight_i.h:86
double m_interferenceStrength
Definition Starlight_i.h:88
unsigned int m_beam2A
Definition Starlight_i.h:68
unsigned int m_nmbRapidityBins
Definition Starlight_i.h:75
double m_maxW
Definition Starlight_i.h:71
int m_nmbPtBinsInterference
Definition Starlight_i.h:93
bool m_accCutEta
Definition Starlight_i.h:79
int m_productionMode
Definition Starlight_i.h:82
UnsignedIntegerProperty m_maxevents
Definition Starlight_i.h:45
virtual StatusCode fillEvt(HepMC::GenEvent *evt)
For filling the HepMC event object.
double m_incoherentFactor
Definition Starlight_i.h:90
bool set_user_params()
BooleanProperty m_lheOutput
Definition Starlight_i.h:44
IntegerProperty m_dsid
Definition Starlight_i.h:42
double m_maxEta
Definition Starlight_i.h:81
Starlight_i(const std::string &name, ISvcLocator *pSvcLocator)
StringArrayProperty m_InitializeVector
Definition Starlight_i.h:49
unsigned int m_nmbWBins
Definition Starlight_i.h:73
bool prepare_params_file()
bool starlight2lhef()
int m_outputFormat
Definition Starlight_i.h:85
unsigned int m_beam2Z
Definition Starlight_i.h:67
std::unique_ptr< starlight > m_starlight
Definition Starlight_i.h:56
BooleanProperty m_doTauolappLheFormat
Definition Starlight_i.h:46
double m_bford
Definition Starlight_i.h:91
unsigned int m_nmbEventsTot
Definition Starlight_i.h:83
int m_prodParticleId
Definition Starlight_i.h:84
double m_axionMass
Definition Starlight_i.h:59
virtual StatusCode callGenerator()
For calling the generator on each iteration of the event loop.
double m_beam1Gamma
Definition Starlight_i.h:69
bool m_xsecMethod
Definition Starlight_i.h:95
inputParameters m_inputParameters
Definition Starlight_i.h:58
double m_minEta
Definition Starlight_i.h:80
bool m_accCutPt
Definition Starlight_i.h:76
double m_minPt
Definition Starlight_i.h:77
double m_maxRapidity
Definition Starlight_i.h:74
unsigned int m_beam1Z
Definition Starlight_i.h:65
double m_maxPt
Definition Starlight_i.h:78
std::variant< std::unique_ptr< upcEvent >, std::unique_ptr< upcXEvent > > m_event
Definition Starlight_i.h:63
virtual ~Starlight_i()
double m_minW
Definition Starlight_i.h:72
virtual StatusCode genFinalize()
For finalising the generator, if required.
double m_ptBinWidthInterference
Definition Starlight_i.h:94
std::shared_ptr< randomGenerator > m_randomGenerator
Definition Starlight_i.h:57
StringProperty m_configFileName
Definition Starlight_i.h:43
bool m_coherentProduction
Definition Starlight_i.h:89
BooleanProperty m_suppressVMdecay
Definition Starlight_i.h:47
bool m_pythFullRec
Definition Starlight_i.h:97
virtual StatusCode genInitialize()
For initializing the generator, if required.
bool m_interferenceEnabled
Definition Starlight_i.h:87
double m_beam2Gamma
Definition Starlight_i.h:70
double m_maxPtInterference
Definition Starlight_i.h:92
HepMC3::GenEvent GenEvent
Definition GenEvent.h:39