[66b590f] | 1 | Delphes 4 LHCb
|
---|
| 2 | ==============
|
---|
| 3 |
|
---|
| 4 | The card "delphes_card_prelLHCb.tcl" contains a preliminary parametrization of the LHCb detector.
|
---|
| 5 |
|
---|
| 6 | - ParticlePropagator
|
---|
| 7 |
|
---|
| 8 | particles are propagated in a constant B field.
|
---|
| 9 |
|
---|
| 10 | - ChargedHadronMomentumSmearing/ElectronEnergySmearing/MuonMomentumSmearing
|
---|
| 11 |
|
---|
| 12 | charged particles momenta are smeared according to detector resolution
|
---|
| 13 |
|
---|
| 14 | - TrackMerger
|
---|
| 15 |
|
---|
| 16 | charged particles are merged into single collection for simpler future processing
|
---|
| 17 |
|
---|
| 18 | - ImpactParameterSmearing
|
---|
| 19 |
|
---|
| 20 | charged particles transverse IP are smeared according to known LHCb tracking
|
---|
| 21 | performance.
|
---|
| 22 |
|
---|
| 23 |
|
---|
| 24 | - IdentificationMap
|
---|
| 25 |
|
---|
| 26 | This module is a recent addition in order to map particle misindentification rates
|
---|
| 27 | and reconstruction efficiencies.
|
---|
| 28 |
|
---|
| 29 | An example is given in the card but can be expanded if needed.
|
---|
| 30 |
|
---|
| 31 | - ECAL/HCAL
|
---|
| 32 |
|
---|
| 33 | Calorimeter modules are used to parametrize the energy response and angular
|
---|
| 34 | resolution of neutral objects such as photons/neutral hadrons.
|
---|
| 35 |
|
---|
| 36 | - TreeWriter
|
---|
| 37 |
|
---|
| 38 | user specifies here which collections are stored in the output.
|
---|
| 39 | By default tracks, neutral hadrons and photons are stored in this card.
|
---|
| 40 | Tracks contain muons, electrons, and charged hadrons.
|
---|
| 41 |
|
---|
| 42 |
|
---|
[6519cfb] | 43 | Quick start with Delphes
|
---|
| 44 | ========================
|
---|
| 45 |
|
---|
| 46 | 1) Compile:
|
---|
| 47 |
|
---|
| 48 | make
|
---|
| 49 |
|
---|
| 50 | 2) Simulate p p -> b b~ events
|
---|
| 51 |
|
---|
[835f0d5] | 52 | tar -xzvf pp2bb.hep.tgz
|
---|
[6519cfb] | 53 | ./DelphesSTDHEP examples/delphes_card_prelLHCb.tcl delphes_output.root pp2bb.hep
|
---|
| 54 |
|
---|
| 55 |
|
---|
| 56 | For more details, please visit:
|
---|
| 57 |
|
---|
| 58 | https://cp3.irmp.ucl.ac.be/projects/delphes
|
---|
| 59 |
|
---|
| 60 |
|
---|
| 61 |
|
---|
[66b590f] | 62 | Simple analysis using TTree::Draw
|
---|
| 63 | =================================
|
---|
| 64 |
|
---|
| 65 | Now we can start ROOT and look at the data stored in the output ROOT file.
|
---|
| 66 |
|
---|
| 67 | Start ROOT and load Delphes shared library:
|
---|
| 68 |
|
---|
| 69 | root -l
|
---|
| 70 | gSystem->Load("libDelphes");
|
---|
| 71 |
|
---|
| 72 | Open ROOT file and do some basic analysis using Draw or TBrowser:
|
---|
| 73 |
|
---|
| 74 | TFile::Open("delphes_output.root");
|
---|
| 75 | Delphes->Draw("Track.PT");
|
---|
| 76 | TBrowser browser;
|
---|
| 77 |
|
---|
| 78 | Note 1: Delphes - tree name, it can be learned e.g. from TBrowser
|
---|
| 79 |
|
---|
| 80 | Note 2: Track - branch name; PT - variable (leaf) of this branch
|
---|
| 81 |
|
---|
| 82 | Complete description of all branches can be found in
|
---|
| 83 |
|
---|
| 84 | doc/RootTreeDescription.html
|
---|
| 85 |
|
---|
| 86 | This information is also available at
|
---|
| 87 |
|
---|
| 88 | https://cp3.irmp.ucl.ac.be/projects/delphes/wiki/WorkBook/RootTreeDescription
|
---|
| 89 |
|
---|
| 90 |
|
---|
| 91 | Macro-based analysis
|
---|
| 92 | ====================
|
---|
| 93 |
|
---|
| 94 | Analysis macro consists of histogram booking, event loop (histogram filling),
|
---|
| 95 | histogram display.
|
---|
| 96 |
|
---|
| 97 | Start ROOT and load Delphes shared library:
|
---|
| 98 |
|
---|
| 99 | root -l
|
---|
| 100 | gSystem->Load("libDelphes");
|
---|
| 101 |
|
---|
| 102 | Basic analysis macro:
|
---|
| 103 |
|
---|
| 104 | {
|
---|
| 105 | // Create chain of root trees
|
---|
| 106 | TChain chain("Delphes");
|
---|
| 107 | chain.Add("delphes_output.root");
|
---|
| 108 |
|
---|
| 109 | // Create object of class ExRootTreeReader
|
---|
| 110 | ExRootTreeReader *treeReader = new ExRootTreeReader(&chain);
|
---|
| 111 | Long64_t numberOfEntries = treeReader->GetEntries();
|
---|
| 112 |
|
---|
| 113 | // Get pointers to branches used in this analysis
|
---|
| 114 | TClonesArray *branchTrack = treeReader->UseBranch("Track");
|
---|
| 115 |
|
---|
| 116 | // Book histograms
|
---|
| 117 | TH1 *histTrackPT = new TH1F("track pt", "track P_{T}", 50, 0.0, 20.0);
|
---|
| 118 |
|
---|
| 119 | // Loop over all events
|
---|
| 120 | for(Int_t entry = 0; entry < numberOfEntries; ++entry)
|
---|
| 121 | {
|
---|
| 122 |
|
---|
| 123 | // Load selected branches with data from specified event
|
---|
| 124 | treeReader->ReadEntry(entry);
|
---|
| 125 |
|
---|
[5babc8b] | 126 | // If event contains at least 1 track
|
---|
[66b590f] | 127 | if(branchTrack->GetEntries() > 0)
|
---|
| 128 | {
|
---|
[5babc8b] | 129 | // Take first track
|
---|
[66b590f] | 130 | Track *track = (Track*) branchTrack->At(0);
|
---|
| 131 |
|
---|
| 132 | // Plot track transverse momentum
|
---|
| 133 | histTrackPT->Fill(track->PT);
|
---|
| 134 |
|
---|
[5babc8b] | 135 | // Print electron transverse momentum and Particle Data Group ID
|
---|
| 136 | cout << track->PID<< " " << track->PT << endl;
|
---|
[66b590f] | 137 | }
|
---|
| 138 |
|
---|
| 139 | }
|
---|
| 140 |
|
---|
| 141 | // Show resulting histograms
|
---|
[5babc8b] | 142 | histTrackPT->Draw();
|
---|
[66b590f] | 143 | }
|
---|
| 144 |
|
---|