1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
| #include <Rivet/Analysis.hh>
#include <Rivet/Projections/AliceCommon.hh>
#include <Rivet/Projections/HepMCHeavyIon.hh>
namespace Rivet {
/// Dummy analysis for centrality calibration in Pb-Pb at 5.02TeV
///
/// @author Christian Holm Christensen <cholm@nbi.dk>
class ALICE_2015_PBPBCentrality : public Analysis {
public:
/// Constructor
ALICE_2015_PBPBCentrality()
: Analysis("ALICE_2015_PBPBCentrality")
{ }
/// Initialize this analysis.
void init() {
ALICE::V0AndTrigger v0and;
declare<ALICE::V0AndTrigger>(v0and,"V0-AND");
ALICE::V0MMultiplicity v0m;
declare<ALICE::V0MMultiplicity>(v0m,"V0M");
// Access the HepMC heavy ion info
declare(HepMCHeavyIon(), "HepMC");
book(_v0m, "V0M", 500, -5.0, 39995.0);
book(_imp, "V0M_IMP",100,0,20);
}
/// Analyse a single event.
void analyze(const Event& event) {
// Get and fill in the impact parameter value if the information is valid.
_imp->fill(apply<HepMCHeavyIon>(event, "HepMC").impact_parameter());
// Check if we have any hit in either V0-A or -C. If not, the
// event is not selected and we get out.
if (!apply<ALICE::V0AndTrigger>(event,"V0-AND")()) return;
// Fill in the V0 multiplicity for this event
_v0m->fill(apply<ALICE::V0MMultiplicity>(event,"V0M")());
}
/// Finalize this analysis
void finalize() {
_v0m->normalize();
_imp->normalize();
}
/// The distribution of V0M multiplicity
Histo1DPtr _v0m;
/// The distribution of impact parameters
Histo1DPtr _imp;
};
// The hook for the plugin system
RIVET_DECLARE_PLUGIN(ALICE_2015_PBPBCentrality);
}
|