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