|
[Rivet-svn] r3441 - in trunk: . data/anainfo data/plotinfo src/Analysesblackhole at projects.hepforge.org blackhole at projects.hepforge.orgThu Oct 13 22:26:51 BST 2011
Author: fsiegert Date: Thu Oct 13 22:26:50 2011 New Revision: 3441 Log: CMS QCD analyses: * Bugfix for weighted events in CMS_2011_S9120041.cc: nTransverse has to be multiplied by weight * Safeguard a few finalize steps against nan's * Using some Rivet utilities to simplify code (BinnedHistogram, deltaPhi) * Remove setBeams and setNeedsCrossSection (is specified in .info file now) * Changes for coding convention (whitespace cleanup, indentation consistency) Modified: trunk/ChangeLog trunk/data/anainfo/CMS_2011_S8950903.info trunk/data/anainfo/CMS_2011_S9086218.info trunk/data/anainfo/CMS_2011_S9088458.info trunk/data/anainfo/CMS_2011_S9120041.info trunk/data/plotinfo/CMS_2011_S8950903.plot trunk/data/plotinfo/CMS_2011_S9086218.plot trunk/data/plotinfo/CMS_2011_S9088458.plot trunk/data/plotinfo/CMS_2011_S9120041.plot trunk/src/Analyses/CMS_2011_S8950903.cc trunk/src/Analyses/CMS_2011_S9086218.cc trunk/src/Analyses/CMS_2011_S9088458.cc trunk/src/Analyses/CMS_2011_S9120041.cc Modified: trunk/ChangeLog ============================================================================== --- trunk/ChangeLog Thu Oct 13 22:13:45 2011 (r3440) +++ trunk/ChangeLog Thu Oct 13 22:26:50 2011 (r3441) @@ -1,3 +1,6 @@ +2011-10-13 Frank Siegert <frank.siegert at cern.ch> + * Add four CMS QCD analyses kindly provided by CMS. + 2011-10-12 Andy Buckley <andy at insectnation.org> * Adding a separate test program for non-matrix/vector math Modified: trunk/data/anainfo/CMS_2011_S8950903.info ============================================================================== --- trunk/data/anainfo/CMS_2011_S8950903.info Thu Oct 13 22:13:45 2011 (r3440) +++ trunk/data/anainfo/CMS_2011_S8950903.info Thu Oct 13 22:26:50 2011 (r3441) @@ -1,19 +1,21 @@ -Name: CMS_2011_S8950903 +Name: CMS_2011_S8950903 Year: 2011 -Summary: Dijet Azimuthal Decorrelations in pp Collisions at sqrt(s) = 7 TeV +Summary: Dijet Azimuthal Decorrelations in pp Collisions at sqrt(s) = 7 TeV Experiment: CMS Collider: LHC -SpiresID: 8950903 +SpiresID: 8950903 Status: VALIDATED Authors: - Tomo Umer <tomo.umer at cern.ch> References: - Phys. Rev. Lett. 106 (2011) 122003 + - arXiv:1101.5029 [hep-ex] RunInfo: Inclusive QCD at 7TeV comEnergy, ptHat (or equivalent) greater than 20 GeV NumEvents: 100k Beams: [p+, p+] Energies: [7000] +PtCuts: [20] Description: Measurements of dijet azimuthal decorrelations in pp collisions at sqrt(s) = 7 TeV using the CMS detector at the CERN LHC are presented. The analysis is based on an inclusive dijet event sample Modified: trunk/data/anainfo/CMS_2011_S9086218.info ============================================================================== --- trunk/data/anainfo/CMS_2011_S9086218.info Thu Oct 13 22:13:45 2011 (r3440) +++ trunk/data/anainfo/CMS_2011_S9086218.info Thu Oct 13 22:26:50 2011 (r3441) @@ -21,6 +21,7 @@ energy of 7 TeV at the LHC using the CMS experiment. The data sample corresponds to an integrated luminosity of 34 inverse picobarns. The measurement is made for jet transverse momenta in the range 18-1100 GeV and for absolute values of rapidity less than 3. +NeedCrossSection: yes BibKey: :2011me BibTeX: '@article{:2011me, author = "Chatrchyan, Serguei and others", Modified: trunk/data/anainfo/CMS_2011_S9088458.info ============================================================================== --- trunk/data/anainfo/CMS_2011_S9088458.info Thu Oct 13 22:13:45 2011 (r3440) +++ trunk/data/anainfo/CMS_2011_S9088458.info Thu Oct 13 22:26:50 2011 (r3441) @@ -1,9 +1,9 @@ -Name: CMS_2011_S9088458 +Name: CMS_2011_S9088458 Year: 2011 Summary: Measurement of ratio of the 3-jet over 2-jet cross section in pp collisions at sqrt(s) = 7 TeV Experiment: CMS Collider: LHC -SpiresID: 9088458 +SpiresID: 9088458 Status: VALIDATED Authors: - Tomo Umer <tomo.umer at cern.ch> Modified: trunk/data/anainfo/CMS_2011_S9120041.info ============================================================================== --- trunk/data/anainfo/CMS_2011_S9120041.info Thu Oct 13 22:13:45 2011 (r3440) +++ trunk/data/anainfo/CMS_2011_S9120041.info Thu Oct 13 22:26:50 2011 (r3441) @@ -6,28 +6,28 @@ SpiresID: 9120041 Status: VALIDATED Authors: - - Mohammed Zakaria (mzakaria at ufl.edu) + - Mohammed Zakaria (mzakaria at ufl.edu) References: - - J. High Energy Phys 09 (2011) 109 + - J. High Energy Phys 09 (2011) 109 RunInfo: - Non single diffrative events. Switch on single diffraction in generator. + Non single diffrative events. Switch on single diffraction in generator. The profile plots require large statistics. Beams: [p+, p+] Energies: [900, 7000] pT Cuts: pT > 0.5 GeV (all tracks). -Description: +Description: A measurement of the underlying activity in scattering processes with a hard scale in the several GeV region is performed in proton-proton collisions at Energies of 0.9 and 7 TeV, using data collected by the CMS experiment at the LHC. The production of charged particles with pseudorapidity |eta| < 2 and transverse momentum pT > 0.5 GeV/c is studied in the azimuthal region transverse - to that of the leading set of charged particles forming a track-jet. Various - comparisons are made between the two different energies and also beteen two + to that of the leading set of charged particles forming a track-jet. Various + comparisons are made between the two different energies and also beteen two sets of cuts on pT for leading track jet pT-leading > 3 GeV and pT-leading > 20 GeV. - The activity is studied using 5 types of plots. 2 profile plots for the - multiplcity of charged particles and the scalar sum of pT. and 3 distributions - for the two previous quantities as well we pT for all the particles in the - transverse region. + The activity is studied using 5 types of plots. 2 profile plots for the + multiplcity of charged particles and the scalar sum of pT. and 3 distributions + for the two previous quantities as well we pT for all the particles in the + transverse region. BibKey: Chatrchyan:2011id BibTeX: '@article{Chatrchyan:2011id, author = "Chatrchyan, Serguei and others", Modified: trunk/data/plotinfo/CMS_2011_S8950903.plot ============================================================================== --- trunk/data/plotinfo/CMS_2011_S8950903.plot Thu Oct 13 22:13:45 2011 (r3440) +++ trunk/data/plotinfo/CMS_2011_S8950903.plot Thu Oct 13 22:26:50 2011 (r3441) @@ -1,40 +1,22 @@ -# BEGIN PLOT /CMS_2011_S8950903/d01-x01-y01 -Title=CMS, Di-jet $\Delta\phi$, $\sqrt{s}=7$~TeV, $80.0<p_{T}^{leading}<110.0$~GeV +# BEGIN PLOT /CMS_2011_S8950903/d.* XLabel=$\Delta\phi$ [rad] YLabel=$\frac{1}{\sigma}\frac{d\sigma}{d\Delta\phi}$ [rad$^{-1}$] FullRange=1 LogY=1 LegendXPos=0.1 # END PLOT +# BEGIN PLOT /CMS_2011_S8950903/d01-x01-y01 +Title=Di-jet azimuthal decorrelation, $80<p_{T}^\text{leading}<110$~GeV +# END PLOT # BEGIN PLOT /CMS_2011_S8950903/d02-x01-y01 -Title=CMS, Di-jet $\Delta\phi$, $\sqrt{s}=7$~TeV, $110.0<p_{T}^{leading}<140.0$~GeV -XLabel=$\Delta\phi$ [rad] -YLabel=$\frac{1}{\sigma}\frac{d\sigma}{d\Delta\phi}$ [rad$^{-1}$] -FullRange=1 -LogY=1 -LegendXPos=0.1 +Title=Di-jet azimuthal decorrelation, $110<p_{T}^\text{leading}<140$~GeV # END PLOT # BEGIN PLOT /CMS_2011_S8950903/d03-x01-y01 -Title=CMS, Di-jet $\Delta\phi$, $\sqrt{s}=7$~TeV, $140.0<p_{T}^{leading}<200.0$~GeV -XLabel=$\Delta\phi$ [rad] -YLabel=$\frac{1}{\sigma}\frac{d\sigma}{d\Delta\phi}$ [rad$^{-1}$] -FullRange=1 -LogY=1 -LegendXPos=0.1 +Title=Di-jet azimuthal decorrelation, $140<p_{T}^\text{leading}<200$~GeV # END PLOT # BEGIN PLOT /CMS_2011_S8950903/d04-x01-y01 -Title=CMS, Di-jet $\Delta\phi$, $\sqrt{s}=7$~TeV, $200.0<p_{T}^{leading}<300.0$~GeV -XLabel=$\Delta\phi$ [rad] -YLabel=$\frac{1}{\sigma}\frac{d\sigma}{d\Delta\phi}$ [rad$^{-1}$] -FullRange=1 -LogY=1 -LegendXPos=0.1 +Title=Di-jet azimuthal decorrelation, $200<p_{T}^\text{leading}<300$~GeV # END PLOT # BEGIN PLOT /CMS_2011_S8950903/d05-x01-y01 -Title=CMS, Di-jet $\Delta\phi$, $\sqrt{s}=7$~TeV, $p_{T}^{leading}>300.0$~GeV -XLabel=$\Delta\phi$ [rad] -YLabel=$\frac{1}{\sigma}\frac{d\sigma}{d\Delta\phi}$ [rad$^{-1}$] -FullRange=1 -LogY=1 -LegendXPos=0.1 +Title=Di-jet azimuthal decorrelation, $p_{T}^\text{leading}>300$~GeV # END PLOT Modified: trunk/data/plotinfo/CMS_2011_S9086218.plot ============================================================================== --- trunk/data/plotinfo/CMS_2011_S9086218.plot Thu Oct 13 22:13:45 2011 (r3440) +++ trunk/data/plotinfo/CMS_2011_S9086218.plot Thu Oct 13 22:26:50 2011 (r3441) @@ -1,54 +1,26 @@ -# BEGIN PLOT /CMS_2011_S9086218/d01-x01-y01 -Title=CMS, Inclusive jets, $\sqrt{s}= 7$~TeV, $0.0 < |y| < 0.5$ +# BEGIN PLOT /CMS_2011_S9086218/d.* XLabel=$p_{T}$ [GeV] -YLabel=$\frac{d^{2}\sigma}{dp_{T}dy}$ [pb/GeV] +YLabel=d$^2\sigma$/d$p_{T}$d$y$ [pb/GeV] FullRange=1 LogY=1 LogX=1 LegendYPos=0.9 # END PLOT +# BEGIN PLOT /CMS_2011_S9086218/d01-x01-y01 +Title=Inclusive jets, $0.0 < |y| < 0.5$ +# END PLOT # BEGIN PLOT /CMS_2011_S9086218/d02-x01-y01 -Title=CMS, Inclusive jets, $\sqrt{s}= 7$~TeV, $0.5 < |y| < 1.0$ -XLabel=$p_{T}$ [GeV] -YLabel=$\frac{d^{2}\sigma}{dp_{T}dy}$ [pb/GeV] -FullRange=1 -LogY=1 -LogX=1 -LegendYPos=0.9 +Title=Inclusive jets, $0.5 < |y| < 1.0$ # END PLOT # BEGIN PLOT /CMS_2011_S9086218/d03-x01-y01 -Title=CMS, Inclusive jets, $\sqrt{s}= 7$~TeV, $1.0 < |y| < 1.5$ -XLabel=$p_{T}$ [GeV] -YLabel=$\frac{d^{2}\sigma}{dp_{T}dy}$ [pb/GeV] -FullRange=1 -LogY=1 -LogX=1 -LegendYPos=0.9 +Title=Inclusive jets, $1.0 < |y| < 1.5$ # END PLOT # BEGIN PLOT /CMS_2011_S9086218/d04-x01-y01 -Title=CMS, Inclusive jets, $\sqrt{s}= 7$~TeV, $1.5 < |y| < 2.0$ -XLabel=$p_{T}$ [GeV] -YLabel=$\frac{d^{2}\sigma}{dp_{T}dy}$ [pb/GeV] -FullRange=1 -LogY=1 -LogX=1 -LegendYPos=0.9 +Title=Inclusive jets, $1.5 < |y| < 2.0$ # END PLOT # BEGIN PLOT /CMS_2011_S9086218/d05-x01-y01 -Title=CMS, Inclusive jets, $\sqrt{s}= 7$~TeV, $2.0 < |y| < 2.5$ -XLabel=$p_{T}$ [GeV] -YLabel=$\frac{d^{2}\sigma}{dp_{T}dy}$ [pb/GeV] -FullRange=1 -LogY=1 -LogX=1 -LegendYPos=0.9 +Title=Inclusive jets, $2.0 < |y| < 2.5$ # END PLOT # BEGIN PLOT /CMS_2011_S9086218/d06-x01-y01 -Title=CMS, Inclusive jets, $\sqrt{s}= 7$~TeV, $2.5 < |y| < 3.0$ -XLabel=$p_{T}$ [GeV] -YLabel=$\frac{d^{2}\sigma}{dp_{T}dy}$ [pb/GeV] -FullRange=1 -LogY=1 -LegendYPos=0.9 -LogX=1 +Title=Inclusive jets, $2.5 < |y| < 3.0$ # END PLOT Modified: trunk/data/plotinfo/CMS_2011_S9088458.plot ============================================================================== --- trunk/data/plotinfo/CMS_2011_S9088458.plot Thu Oct 13 22:13:45 2011 (r3440) +++ trunk/data/plotinfo/CMS_2011_S9088458.plot Thu Oct 13 22:26:50 2011 (r3441) @@ -1,9 +1,9 @@ # BEGIN PLOT /CMS_2011_S9088458/d01-x01-y01 -Title=CMS, 3 jets over 2 jets ratio, $\sqrt{s}=7$~TeV +Title=3 jets over 2 jets ratio XLabel=H$_{T}$ [TeV] YLabel=R$_{32}$ FullRange=1 LogY=0 LegendYPos=0.4 -LegendXPos=0.7 +LegendXPos=0.5 # END PLOT Modified: trunk/data/plotinfo/CMS_2011_S9120041.plot ============================================================================== --- trunk/data/plotinfo/CMS_2011_S9120041.plot Thu Oct 13 22:13:45 2011 (r3440) +++ trunk/data/plotinfo/CMS_2011_S9120041.plot Thu Oct 13 22:26:50 2011 (r3441) @@ -1,42 +1,42 @@ # BEGIN PLOT /CMS_2011_S9120041/d01-x01-y01 -Title= Profile $\text{N}_\text{ch}$ at $\sqrt{s}$ = 7 TeV, $ 60 < | \Delta \phi | < 120$, $|\eta | < 2$ -XLabel=$Leading Track-jet$ \text{p}_T$ $[GeV/c]$ -YLabel=$(1/N_\text{ev})\; dN_\text{ch}/\Delta \eta \Delta (\Delta \phi) $ +Title= Profile $\text{N}_\text{ch}$ at $\sqrt{s}$ = 7 TeV, $ 60 < | \Delta \phi | < 120$ +XLabel=Leading Track-jet $\text{p}_T$ [GeV/c] +YLabel=$(1/N_\text{ev})\; \text{d}N_\text{ch}/\Delta \eta \Delta (\Delta \phi) $ FullRange=1 LogY=0 # END PLOT # BEGIN PLOT /CMS_2011_S9120041/d02-x01-y01 -Title= Profile $\Sigma \text{p}_\text{T}$ at $\sqrt{s}$ = 7 TeV, $ 60 < | \Delta \phi | < 120$, $|\eta | < 2$ -XLabel=$Leading Track-jet$ \text{p}_T$ $[GeV/c]$ -YLabel=$(1/N_\text{ev})\; d \Sigma p_\text{T}/ \Delta \eta \Delta (\Delta \phi)[\text{GeV}/c]^{-1}$ +Title= Profile $\Sigma \text{p}_\text{T}$ at $\sqrt{s}$ = 7 TeV, $ 60 < | \Delta \phi | < 120$ +XLabel=Leading Track-jet $\text{p}_T$ [GeV/c] +YLabel=$(1/N_\text{ev})\; \text{d}\Sigma p_\text{T}/ \Delta \eta \Delta (\Delta \phi)[\text{GeV}/c]^{-1}$ FullRange=1 LogY=0 # END PLOT # BEGIN PLOT /CMS_2011_S9120041/d03-x01-y01 -Title= Profile $\text{N}_\text{ch}$ at $\sqrt{s}$ = 0.9 TeV, $ 60 < | \Delta \phi | < 120$, $|\eta | < 2$ -XLabel=$Leading Track-jet$ \text{p}_T$ $[GeV/c]$ -YLabel=$(1/N_\text{ev})\; dN_\text{ch}/\Delta \eta \Delta (\Delta \phi) $ +Title= Profile $\text{N}_\text{ch}$ at $\sqrt{s}$ = 0.9 TeV, $ 60 < | \Delta \phi | < 120$ +XLabel=Leading Track-jet $\text{p}_T$ [GeV/c] +YLabel=$(1/N_\text{ev})\; \text{d}N_\text{ch}/\Delta \eta \Delta (\Delta \phi) $ FullRange=1 LogY=0 # END PLOT # BEGIN PLOT /CMS_2011_S9120041/d04-x01-y01 -Title= Profile $\Sigma \text{p}_\text{T}$ at $\sqrt{s}$ = 0.9 TeV, $ 60 < | \Delta \phi | < 120$, $|\eta | < 2$ -XLabel=$Leading Track-jet$ \text{p}_T$ $[GeV/c]$ -YLabel=$(1/N_\text{ev})\; d \Sigma p_\text{T}/ \Delta \eta \Delta (\Delta \phi)[\text{GeV}/c]^{-1}$ +Title= Profile $\Sigma \text{p}_\text{T}$ at $\sqrt{s}$ = 0.9 TeV, $ 60 < | \Delta \phi | < 120$ +XLabel=Leading Track-jet $\text{p}_T$ [GeV/c] +YLabel=$(1/N_\text{ev})\; \text{d}\Sigma p_\text{T}/ \Delta \eta \Delta (\Delta \phi)[\text{GeV}/c]^{-1}$ FullRange=1 LogY=0 # END PLOT # BEGIN PLOT /CMS_2011_S9120041/d05-x01-y01 Title= Distribution $\text{N}_\text{ch}$ at 7 TeV, max $p_\text{T} > 20$ GeV/c -XLabel=$N_\text{ch}$ -YLabel=$(1/N_\text{ev})\; d N_\text{ev} / d N_\text{ch}$ +XLabel=$N_\text{ch}$ +YLabel=$(1/N_\text{ev})\; \text{d}N_\text{ev} / \text{d} N_\text{ch}$ FullRange=1 LogY=1 # END PLOT # BEGIN PLOT /CMS_2011_S9120041/d06-x01-y01 Title= Distribution $\Sigma \text{p}_\text{T}$ at 7 TeV, max $p_\text{T} > 20$ GeV/c XLabel=$\Sigma p_\text{T}$ $[\text{GeV}/c]$ -YLabel=$(1/N_\text{ev})\; d N_\text{ev} / d \Sigma p_\text{T}$ $[\text{GeV}/c]^{-1}$ +YLabel=$(1/N_\text{ev})\; \text{d}N_\text{ev} / \text{d} \Sigma p_\text{T}$ $[\text{GeV}/c]^{-1}$ FullRange=1 LogY=1 @@ -44,49 +44,49 @@ # BEGIN PLOT /CMS_2011_S9120041/d07-x01-y01 Title= Distribution $ \text{p}_\text{T}$ at 7 TeV, max $p_\text{T} > 20$ GeV/c XLabel=$ p_\text{T}$ $[\text{GeV}/c]$ -YLabel=$ d N_\text{ch} / d p_\text{T}$ $[\text{GeV}/c]^{-1}$ +YLabel=$ \text{d} N_\text{ch} / \text{d}p_\text{T}$ $[\text{GeV}/c]^{-1}$ FullRange=1 LogY=1 # END PLOT # BEGIN PLOT /CMS_2011_S9120041/d08-x01-y01 Title= Distribution $\text{N}_\text{ch}$ at 7 TeV, max $p_\text{T} > 3$ GeV/c -XLabel=$N_\text{ch}$ -YLabel=$(1/N_\text{ev})\; d N_\text{ev} / d N_\text{ch}$ +XLabel=$N_\text{ch}$ +YLabel=$(1/N_\text{ev})\; \text{d}N_\text{ev} / \text{d} N_\text{ch}$ FullRange=1 LogY=1 # END PLOT # BEGIN PLOT /CMS_2011_S9120041/d09-x01-y01 Title= Distribution $\Sigma \text{p}_\text{T}$ at 7 TeV, max $p_\text{T} > 3$ GeV/c XLabel=$\Sigma p_\text{T}$ $[\text{GeV}/c]$ -YLabel=$(1/N_\text{ev})\; d N_\text{ev} / d \Sigma p_\text{T}$ $[\text{GeV}/c]^{-1}$ +YLabel=$(1/N_\text{ev})\; \text{d}N_\text{ev} / \text{d} \Sigma p_\text{T}$ $[\text{GeV}/c]^{-1}$ FullRange=1 LogY=1 # END PLOT # BEGIN PLOT /CMS_2011_S9120041/d10-x01-y01 Title= Distribution $ \text{p}_\text{T}$ at 7 TeV, max $p_\text{T} > 3$ GeV/c XLabel=$ p_\text{T}$ $[\text{GeV}/c]$ -YLabel=$ d N_\text{ch} / d p_\text{T}$ $[\text{GeV}/c]^{-1}$ +YLabel=$ \text{d} N_\text{ch} / \text{d} p_\text{T}$ $[\text{GeV}/c]^{-1}$ FullRange=1 LogY=1 # END PLOT # BEGIN PLOT /CMS_2011_S9120041/d11-x01-y01 Title= Distribution $\text{N}_\text{ch}$ at 0.9 TeV, max $p_\text{T} > 3$ GeV/c -XLabel=$N_\text{ch}$ -YLabel=$(1/N_\text{ev})\; d N_\text{ev} / d N_\text{ch}$ +XLabel=$N_\text{ch}$ +YLabel=$(1/N_\text{ev})\; \text{d} N_\text{ev} / \text{d} N_\text{ch}$ FullRange=1 LogY=1 # END PLOT # BEGIN PLOT /CMS_2011_S9120041/d12-x01-y01 Title= Distribution $\Sigma \text{p}_\text{T}$ at 0.9 TeV, max $p_\text{T} > 3$ GeV/c XLabel=$\Sigma p_\text{T}$ $[\text{GeV}/c]$ -YLabel=$(1/N_\text{ev})\; d N_\text{ev} / d \Sigma p_\text{T}$ $[\text{GeV}/c]^{-1}$ +YLabel=$(1/N_\text{ev})\; \text{d} N_\text{ev} / \text{d} \Sigma p_\text{T}$ $[\text{GeV}/c]^{-1}$ FullRange=1 LogY=1 # END PLOT # BEGIN PLOT /CMS_2011_S9120041/d13-x01-y01 Title= Distribution $ \text{p}_\text{T}$ at 0.9 TeV, max $p_\text{T} > 3$ GeV/c XLabel=$ p_\text{T}$ $[\text{GeV}/c]$ -YLabel=$ d N_\text{ch} / d p_\text{T}$ $[\text{GeV}/c]^{-1}$ +YLabel=$ \text{d} N_\text{ch} / \text{d} p_\text{T}$ $[\text{GeV}/c]^{-1}$ FullRange=1 LogY=1 # END PLOT Modified: trunk/src/Analyses/CMS_2011_S8950903.cc ============================================================================== --- trunk/src/Analyses/CMS_2011_S8950903.cc Thu Oct 13 22:13:45 2011 (r3440) +++ trunk/src/Analyses/CMS_2011_S8950903.cc Thu Oct 13 22:26:50 2011 (r3441) @@ -7,87 +7,56 @@ #include "Rivet/RivetAIDA.hh" namespace Rivet { - - - // CMS azimuthal decorellations - + + // CMS azimuthal decorrelations class CMS_2011_S8950903 : public Analysis { public: - - CMS_2011_S8950903() : Analysis("CMS_2011_S8950903") { - setBeams(PROTON, PROTON); - setNeedsCrossSection(true); - } - - -// ======================================================== init + + CMS_2011_S8950903() : Analysis("CMS_2011_S8950903") {} + void init() { FinalState fs; FastJets akt(fs, FastJets::ANTIKT, 0.5); addProjection(akt, "antikT"); - - if(fuzzyEquals(sqrtS(), 7000*GeV, 1E-3)){ - - _h_dPhi_pT1 = bookHistogram1D(1, 1, 1); - _h_dPhi_pT2 = bookHistogram1D(2, 1, 1); - _h_dPhi_pT3 = bookHistogram1D(3, 1, 1); - _h_dPhi_pT4 = bookHistogram1D(4, 1, 1); - _h_dPhi_pT5 = bookHistogram1D(5, 1, 1); - - } + + _h_deltaPhi.addHistogram(80., 110., bookHistogram1D(1, 1, 1)); + _h_deltaPhi.addHistogram(110., 140., bookHistogram1D(2, 1, 1)); + _h_deltaPhi.addHistogram(140., 200., bookHistogram1D(3, 1, 1)); + _h_deltaPhi.addHistogram(200., 300., bookHistogram1D(4, 1, 1)); + _h_deltaPhi.addHistogram(300., 7000., bookHistogram1D(5, 1, 1)); } - -// ======================================================== analyze - + + void analyze(const Event & event) { const double weight = event.weight(); - + const Jets& jets = applyProjection<JetAlg>(event, "antikT").jetsByPt(); if (jets.size() < 2) vetoEvent; - + if (fabs(jets[0].momentum().eta()) > 1.1 || jets[0].momentum().pT() < 80.) vetoEvent; if (fabs(jets[1].momentum().eta()) > 1.1 || jets[1].momentum().pT() < 30.) vetoEvent; - - double phi1 = jets[0].momentum().phi(); - double phi2 = jets[1].momentum().phi(); - - double dphi = fabs(phi1-phi2); - if (fabs(phi1-phi2) > 3.14159265358) dphi = 2*3.14159265358 - fabs(phi1-phi2); - - // ordering based on max pT - if (jets[0].momentum().pT() > 80. && jets[0].momentum().pT() < 110.) _h_dPhi_pT1->fill(dphi, weight); - if (jets[0].momentum().pT() > 110. && jets[0].momentum().pT() < 140.) _h_dPhi_pT2->fill(dphi, weight); - if (jets[0].momentum().pT() > 140. && jets[0].momentum().pT() < 200.) _h_dPhi_pT3->fill(dphi, weight); - if (jets[0].momentum().pT() > 200. && jets[0].momentum().pT() < 300.) _h_dPhi_pT4->fill(dphi, weight); - if (jets[0].momentum().pT() > 300.) _h_dPhi_pT5->fill(dphi, weight); - + + double dphi = deltaPhi(jets[0].momentum(), jets[1].momentum().phi()); + + _h_deltaPhi.fill(jets[0].momentum().pT(), dphi, weight); } - -// ======================================================== finalize - - void finalize() { - normalize(_h_dPhi_pT1,1.); - normalize(_h_dPhi_pT2,1.); - normalize(_h_dPhi_pT3,1.); - normalize(_h_dPhi_pT4,1.); - normalize(_h_dPhi_pT5,1.); - + + void finalize() { + foreach (AIDA::IHistogram1D* histo, _h_deltaPhi.getHistograms()) { + normalize(histo, 1.); + } } - + private: - - AIDA::IHistogram1D* _h_dPhi_pT1; - AIDA::IHistogram1D* _h_dPhi_pT2; - AIDA::IHistogram1D* _h_dPhi_pT3; - AIDA::IHistogram1D* _h_dPhi_pT4; - AIDA::IHistogram1D* _h_dPhi_pT5; - - }; - + + BinnedHistogram<double> _h_deltaPhi; + + }; + // This global object acts as a hook for the plugin system - AnalysisBuilder<CMS_2011_S8950903> plugin_CMS_2011_S8950903; - + DECLARE_RIVET_PLUGIN(CMS_2011_S8950903); + } Modified: trunk/src/Analyses/CMS_2011_S9086218.cc ============================================================================== --- trunk/src/Analyses/CMS_2011_S9086218.cc Thu Oct 13 22:13:45 2011 (r3440) +++ trunk/src/Analyses/CMS_2011_S9086218.cc Thu Oct 13 22:26:50 2011 (r3441) @@ -7,27 +7,16 @@ namespace Rivet { - // This analysis is a derived from the class Analysis: + // Inclusive jet pT class CMS_2011_S9086218 : public Analysis { - - - private: - BinnedHistogram<double> _hist_sigma; - public: - // @name Constructors, init, analyze, finalize - // @{ // Constructor - CMS_2011_S9086218() - : Analysis("CMS_2011_S9086218") { - setBeams(PROTON, PROTON); - setNeedsCrossSection(true); - } + CMS_2011_S9086218() : Analysis("CMS_2011_S9086218") {} + // Book histograms and initialize projections: void init() { - const FinalState fs; // Initialize the projectors: @@ -40,16 +29,13 @@ _hist_sigma.addHistogram(1.5, 2.0, bookHistogram1D(4, 1, 1)); _hist_sigma.addHistogram(2.0, 2.5, bookHistogram1D(5, 1, 1)); _hist_sigma.addHistogram(2.5, 3.0, bookHistogram1D(6, 1, 1)); - - } // Analysis void analyze(const Event &event) { - - const double weight = event.weight(); - const FastJets &fj = applyProjection<FastJets>(event,"Jets"); - const Jets& jets = fj.jets(18*GeV, 1100*GeV, -4.7, 4.7, RAPIDITY); + const double weight = event.weight(); + const FastJets &fj = applyProjection<FastJets>(event,"Jets"); + const Jets& jets = fj.jets(18.0*GeV, 1100.0*GeV, -4.7, 4.7, RAPIDITY); // Fill the relevant histograms: foreach(const Jet &j, jets) { @@ -59,15 +45,14 @@ // Finalize void finalize() { - - _hist_sigma.scale(crossSection()/sumOfWeights()/0.5/2, this); + _hist_sigma.scale(crossSection()/sumOfWeights()/0.5/2.0, this); } - //@} - + private: + BinnedHistogram<double> _hist_sigma; }; - // This global object acts as a hook for the plugin system. - AnalysisBuilder<CMS_2011_S9086218> plugin_CMS_2011_S9086218; + // This global object acts as a hook for the plugin system. + DECLARE_RIVET_PLUGIN(CMS_2011_S9086218); } Modified: trunk/src/Analyses/CMS_2011_S9088458.cc ============================================================================== --- trunk/src/Analyses/CMS_2011_S9088458.cc Thu Oct 13 22:13:45 2011 (r3440) +++ trunk/src/Analyses/CMS_2011_S9088458.cc Thu Oct 13 22:26:50 2011 (r3441) @@ -8,90 +8,76 @@ #include "LWH/Histogram1D.h" namespace Rivet { - - + + // CMS Ratio of the 3-jet to 2-jet Cross Sections by Tomo - class CMS_2011_S9088458 : public Analysis { public: - - CMS_2011_S9088458() : Analysis("CMS_2011_S9088458") { - setBeams(PROTON, PROTON); - setNeedsCrossSection(true); - } - - -// ======================================================== init - - void init() { - FinalState fs; - FastJets akt(fs, FastJets::ANTIKT, 0.5); - addProjection(akt, "antikT"); - - if(fuzzyEquals(sqrtS(), 7000*GeV, 1E-3)){ - - _h_dijet.reset (new LWH::Histogram1D(binEdges(1,1,1))); - _h_trijet.reset(new LWH::Histogram1D(binEdges(1,1,1))); - _h_r32 = bookDataPointSet(1, 1, 1); + CMS_2011_S9088458() : Analysis("CMS_2011_S9088458") {} + + + void init() { + FinalState fs; + FastJets akt(fs, FastJets::ANTIKT, 0.5); + addProjection(akt, "antikT"); + + _h_dijet = bookHistogram1D("dijet", binEdges(1, 1, 1)); + _h_trijet = bookHistogram1D("trijet", binEdges(1, 1, 1)); + _h_r32 = bookDataPointSet(1, 1, 1); + } + + + void analyze(const Event & event) { + const double weight = event.weight(); + + Jets highpT_jets; + double HT = 0; + foreach(const Jet & jet, applyProjection<JetAlg>(event, "antikT").jetsByPt(50.0*GeV)) { + if (fabs(jet.momentum().eta()) < 2.5) { + highpT_jets.push_back(jet); + HT += jet.momentum().pT(); + } + } + if (highpT_jets.size() < 2) vetoEvent; + + if (highpT_jets.size() >= 2) _h_dijet->fill(HT/TeV, weight) ; + if (highpT_jets.size() >= 3) _h_trijet->fill(HT/TeV, weight) ; } - } - - -// ======================================================== analyze - - void analyze(const Event & event) { - const double weight = event.weight(); - - const Jets& jets = applyProjection<JetAlg>(event, "antikT").jetsByPt(); - if (jets.size() < 2) vetoEvent; - Jets highpT_jets; - - unsigned int i; - for(i=0; i< jets.size(); i++) { - if (jets[i].momentum().pT() > 50*GeV && fabs(jets[i].momentum().eta()) < 2.5) highpT_jets.push_back(jets[i]); + + + void finalize() { + vector<double> yval_R32, yerr_R32; + for (size_t i = 0; i < 30; ++i) { + double yval, yerr; + if (_h_dijet->binHeight(i)==0.0 || _h_trijet->binHeight(i)==0.0) { + yval = 0.0; + yerr = 0.0; + } + else { + yval = _h_trijet->binHeight(i)/_h_dijet->binHeight(i); + yerr = sqrt(_h_dijet->binError(i)*_h_dijet->binError(i)/(_h_dijet->binHeight(i) * _h_dijet->binHeight(i)) + + _h_trijet->binError(i)*_h_trijet->binError(i)/(_h_trijet->binHeight(i) * _h_trijet->binHeight(i))) * yval; + } + yval_R32.push_back(yval); + yerr_R32.push_back(yerr); + } + _h_r32->setCoordinate(1, yval_R32, yerr_R32); + histogramFactory().destroy(_h_dijet); + histogramFactory().destroy(_h_trijet); } - if (highpT_jets.size() < 2) vetoEvent; - double HT = 0; - for(i=0; i< highpT_jets.size(); i++) - HT = HT + highpT_jets[i].momentum().pT(); - - - if (highpT_jets.size() >= 2) _h_dijet->fill(HT/TeV, weight) ; - if (highpT_jets.size() >= 3) _h_trijet->fill(HT/TeV, weight) ; - - - } - -// ======================================================== finalize - - void finalize() { - vector<double> yval_R32, yerr_R32; - for (size_t i = 0; i < 30; ++i) { - const double yval = _h_trijet->binHeight(i) / _h_dijet->binHeight(i); - yval_R32.push_back(yval); - const double yerr = sqrt(_h_dijet->binError(i)*_h_dijet->binError(i)/(_h_dijet->binHeight(i) * _h_dijet->binHeight(i)) + - _h_trijet->binError(i)*_h_trijet->binError(i)/(_h_trijet->binHeight(i) * _h_trijet->binHeight(i))) * yval; - yerr_R32.push_back(yerr); - } - _h_r32->setCoordinate(1, yval_R32, yerr_R32); - } - - - - private: - - shared_ptr<LWH::IHistogram1D> _h_dijet, _h_trijet; - AIDA::IDataPointSet* _h_r32; - - - }; - - // This global object acts as a hook for the plugin system - AnalysisBuilder<CMS_2011_S9088458> plugin_CMS_2011_S9088458; - + private: + + AIDA::IHistogram1D *_h_dijet, *_h_trijet; + AIDA::IDataPointSet *_h_r32; + + }; + + // This global object acts as a hook for the plugin system + DECLARE_RIVET_PLUGIN(CMS_2011_S9088458); + } Modified: trunk/src/Analyses/CMS_2011_S9120041.cc ============================================================================== --- trunk/src/Analyses/CMS_2011_S9120041.cc Thu Oct 13 22:13:45 2011 (r3440) +++ trunk/src/Analyses/CMS_2011_S9120041.cc Thu Oct 13 22:26:50 2011 (r3441) @@ -12,197 +12,178 @@ namespace Rivet { + // UE charged particles vs. leading jet class CMS_2011_S9120041 : public Analysis { - public: + public: + /// Constructor + CMS_2011_S9120041() : Analysis("CMS_2011_S9120041") {} - /// Constructor - CMS_2011_S9120041() - : Analysis("CMS_2011_S9120041") - { - setNeedsCrossSection(false); - } - - public: - void init() { + void init() { + const ChargedFinalState cfs(-2.0, 2.0, 500*MeV); + addProjection(cfs, "CFS"); - const ChargedFinalState cfs(-2.0, 2.0, 500*MeV); - addProjection(cfs, "CFS"); + const ChargedFinalState cfsforjet(-2.5, 2.5, 500*MeV); // tracks accepted are with pT > 0.5 GeV + addProjection(cfsforjet, "CFSforjet"); - const ChargedFinalState cfsforjet(-2.5, 2.5, 500*MeV); // tracks accepted are with pT > 0.5 GeV - addProjection(cfsforjet, "CFSforjet"); - - - const FastJets jetpro(cfsforjet, FastJets::SISCONE, 0.5); - addProjection(jetpro, "Jets"); - addProjection(Beam(), "Beam"); - - _hist_profile_Nch_pT_7TeV = bookProfile1D(1, 1, 1); //Profile plot for No. of Charged particles vs. pT max for 7 TeV. - _hist_profile_SumpT_pT_7TeV = bookProfile1D(2, 1, 1); //Profile plot Trans. Momentum sum vs. pT max for 7 TeV. - _hist_profile_Nch_09TeV = bookProfile1D(3, 1, 1); - _hist_profile_Sum_09TeV = bookProfile1D(4, 1, 1); - _hist_dist_Nch_7TeV_pT3 = bookHistogram1D(5, 1, 1); - _hist_dist_Sum_7TeV_pT3 = bookHistogram1D(6, 1, 1); - _hist_dist_pT_7TeV_pT3 = bookHistogram1D(7, 1, 1); - _hist_dist_Nch_7TeV_pT20 = bookHistogram1D(8, 1, 1); - _hist_dist_Sum_7TeV_pT20 = bookHistogram1D(9,1,1); - _hist_dist_pT_7TeV_pT20 = bookHistogram1D(10, 1, 1); - _hist_dist_Nch_09TeV_pT3 = bookHistogram1D(11, 1, 1); // No. of trans. charged particles Distribution for sqrt(s) = 0.9TeV, pT max > 3GeV. - _hist_dist_Sum_09TeV_pT3 = bookHistogram1D(12 , 1, 1); // No. of trans. momentum sum Distribution for sqrt(s) = 0.9TeV, pT max > 3GeV. - _hist_dist_pT_09TeV_pT3 = bookHistogram1D(13, 1, 1); // Trans. momentum Distribution for sqrt(s) = 0.9TeV, pT max > 3GeV. - - _j = 0; - _jj = 0; - _jjj = 0; - - _nch_tot_7TeV_pT3 = 0; - _nch_tot_7TeV_pT20 = 0; - _nch_tot_09TeV_pT3 = 0; - } + const FastJets jetpro(cfsforjet, FastJets::SISCONE, 0.5); + addProjection(jetpro, "Jets"); + addProjection(Beam(), "Beam"); - /// Perform the per-event analysis - void analyze(const Event& event) { - const double weight = event.weight(); + _hist_profile_Nch_pT_7TeV = bookProfile1D(1, 1, 1); //Profile plot for No. of Charged particles vs. pT max for 7 TeV. + _hist_profile_SumpT_pT_7TeV = bookProfile1D(2, 1, 1); //Profile plot Trans. Momentum sum vs. pT max for 7 TeV. + _hist_profile_Nch_09TeV = bookProfile1D(3, 1, 1); + _hist_profile_Sum_09TeV = bookProfile1D(4, 1, 1); + _hist_dist_Nch_7TeV_pT3 = bookHistogram1D(5, 1, 1); + _hist_dist_Sum_7TeV_pT3 = bookHistogram1D(6, 1, 1); + _hist_dist_pT_7TeV_pT3 = bookHistogram1D(7, 1, 1); + _hist_dist_Nch_7TeV_pT20 = bookHistogram1D(8, 1, 1); + _hist_dist_Sum_7TeV_pT20 = bookHistogram1D(9,1,1); + _hist_dist_pT_7TeV_pT20 = bookHistogram1D(10, 1, 1); + _hist_dist_Nch_09TeV_pT3 = bookHistogram1D(11, 1, 1); // No. of trans. charged particles Distribution for sqrt(s) = 0.9TeV, pT max > 3GeV. + _hist_dist_Sum_09TeV_pT3 = bookHistogram1D(12 , 1, 1); // No. of trans. momentum sum Distribution for sqrt(s) = 0.9TeV, pT max > 3GeV. + _hist_dist_pT_09TeV_pT3 = bookHistogram1D(13, 1, 1); // Trans. momentum Distribution for sqrt(s) = 0.9TeV, pT max > 3GeV. + _j = 0.0; + _jj = 0.0; + _jjj = 0.0; - Jets jets = applyProjection<FastJets>(event, "Jets").jetsByPt(1.0*GeV); // we require our jets to have pT > 1 GeV. - if (jets.size() < 1) vetoEvent; - - FourMomentum _p_lead = jets[0].momentum(); - const double _philead = _p_lead.phi(); - const double _pTlead = _p_lead.perp(); + _nch_tot_7TeV_pT3 = 0.0; + _nch_tot_7TeV_pT20 = 0.0; + _nch_tot_09TeV_pT3 = 0.0; + } - ParticleVector particles = - applyProjection<ChargedFinalState>(event, "CFS").particlesByPt(); - double _nTransverse(0.0), _ptSumTransverse(0.0), _pT, _nch_average = 0 ; - foreach (const Particle& p, particles) { + /// Perform the per-event analysis + void analyze(const Event& event) { + const double weight = event.weight(); - double _dphi = fabs(deltaPhi(_philead, p.momentum().phi())); - double _eta = fabs(p.momentum().eta()); - if (((PI/3.0 < _dphi) && (_dphi < 2*PI/3.0))&&(_eta < 2)) { - _nTransverse += 1.0; + Jets jets = applyProjection<FastJets>(event, "Jets").jetsByPt(1.0*GeV); + if (jets.size() < 1) vetoEvent; - _ptSumTransverse += p.momentum().perp(); - _pT = p.momentum().perp(); + FourMomentum p_lead = jets[0].momentum(); + const double philead = p_lead.phi(); + const double pTlead = p_lead.perp(); - if ( (fuzzyEquals(sqrtS(), 7*TeV)) && (_pTlead > 20*GeV) ) - _hist_dist_pT_7TeV_pT20 -> fill(_pT/GeV, weight); + ParticleVector particles = + applyProjection<ChargedFinalState>(event, "CFS").particlesByPt(); - if ( (fuzzyEquals(sqrtS(), 7*TeV)) && (_pTlead > 3*GeV) ) - _hist_dist_pT_7TeV_pT3 -> fill(_pT/GeV, weight); + double nTransverse(0.0), ptSumTransverse(0.0), pT; + foreach (const Particle& p, particles) { + double dphi = fabs(deltaPhi(philead, p.momentum().phi())); + double eta = fabs(p.momentum().eta()); + if (((PI/3.0 < dphi) && (dphi < 2.0*PI/3.0))&&(eta < 2.0)) { + nTransverse += 1.0; + + ptSumTransverse += p.momentum().perp(); + pT = p.momentum().perp(); - if ( (fuzzyEquals(sqrtS(), 900*GeV)) && (_pTlead > 3*GeV) ) - _hist_dist_pT_09TeV_pT3 -> fill(_pT/GeV, weight); + if ( (fuzzyEquals(sqrtS(), 7.0*TeV)) && (pTlead > 20.0*GeV) ) + _hist_dist_pT_7TeV_pT20 -> fill(pT/GeV, weight); + if ( (fuzzyEquals(sqrtS(), 7.0*TeV)) && (pTlead > 3.0*GeV) ) + _hist_dist_pT_7TeV_pT3 -> fill(pT/GeV, weight); - } + if ( (fuzzyEquals(sqrtS(), 900.0*GeV)) && (pTlead > 3.0*GeV) ) + _hist_dist_pT_09TeV_pT3 -> fill(pT/GeV, weight); } + } - if (fuzzyEquals(sqrtS(), 7*TeV)) - { - _hist_profile_Nch_pT_7TeV -> fill - (_pTlead/GeV, _nTransverse / ((8 * PI/3)), weight); - - _hist_profile_SumpT_pT_7TeV -> fill - (_pTlead/GeV , _ptSumTransverse / ((GeV * (8 * PI/3))) , weight); - if(_pTlead > 3*GeV) - { - _hist_dist_Nch_7TeV_pT3 -> fill(_nTransverse, weight); - _nch_average = _nch_average + _nTransverse; - _nch_tot_7TeV_pT3 = _nch_tot_7TeV_pT3 + _nTransverse; - _j += weight ; - _hist_dist_Sum_7TeV_pT3 -> fill(_ptSumTransverse / GeV, weight); - } - if(_pTlead > 20*GeV) - { - - _hist_dist_Nch_7TeV_pT20 -> fill(_nTransverse, weight); - _nch_tot_7TeV_pT20 = _nch_tot_7TeV_pT20 + _nTransverse; - _jj += weight; + if (fuzzyEquals(sqrtS(), 7.0*TeV)) + { + _hist_profile_Nch_pT_7TeV -> fill + (pTlead/GeV, nTransverse / ((8.0 * PI/3.0)), weight); - _hist_dist_Sum_7TeV_pT20 -> fill(_ptSumTransverse / GeV, weight); - } + _hist_profile_SumpT_pT_7TeV -> fill + (pTlead/GeV , ptSumTransverse / ((GeV * (8.0 * PI/3.0))) , weight); + if(pTlead > 3.0*GeV) + { + _hist_dist_Nch_7TeV_pT3 -> fill(nTransverse, weight); + _nch_tot_7TeV_pT3 += nTransverse*weight; + _j += weight ; + _hist_dist_Sum_7TeV_pT3 -> fill(ptSumTransverse / GeV, weight); } - else if (fuzzyEquals(sqrtS() , 900*GeV)) + if(pTlead > 20.0*GeV) { - _hist_profile_Nch_09TeV -> fill(_pTlead / GeV, _nTransverse / ((8 * PI/3)), weight); - _hist_profile_Sum_09TeV -> fill(_pTlead / GeV, _ptSumTransverse / ((GeV * (8 * PI/3))), weight); + _hist_dist_Nch_7TeV_pT20 -> fill(nTransverse, weight); + _nch_tot_7TeV_pT20 += nTransverse*weight; + _jj += weight; - if(_pTlead > 3*GeV) - { - _hist_dist_Nch_09TeV_pT3 -> fill(_nTransverse, weight); - _nch_tot_09TeV_pT3 = _nch_tot_09TeV_pT3 + _nTransverse; - _jjj += weight; //counts how many events - - _hist_dist_Sum_09TeV_pT3 -> fill(_ptSumTransverse/GeV, weight); - } + _hist_dist_Sum_7TeV_pT20 -> fill(ptSumTransverse / GeV, weight); } } + else if (fuzzyEquals(sqrtS() , 900.0*GeV)) + { + _hist_profile_Nch_09TeV -> fill(pTlead / GeV, nTransverse / ((8.0 * PI/3.0)), weight); + _hist_profile_Sum_09TeV -> fill(pTlead / GeV, ptSumTransverse / ((GeV * (8.0 * PI/3.0))), weight); + if(pTlead > 3.0*GeV) + { + _hist_dist_Nch_09TeV_pT3 -> fill(nTransverse, weight); + _nch_tot_09TeV_pT3 += nTransverse*weight; + _jjj += weight; - /// Normalise histograms etc., after the run - void finalize() { - scale(_hist_dist_Nch_7TeV_pT3 , 1/integral(_hist_dist_Nch_7TeV_pT3 )); - scale(_hist_dist_Sum_7TeV_pT3 , 1/integral(_hist_dist_Sum_7TeV_pT3 )); - scale(_hist_dist_Nch_7TeV_pT20 , 1/integral(_hist_dist_Nch_7TeV_pT20 )); - scale(_hist_dist_Sum_7TeV_pT20 , 1/integral(_hist_dist_Sum_7TeV_pT20 )); - scale(_hist_dist_Nch_09TeV_pT3 , 1/integral(_hist_dist_Nch_09TeV_pT3 )); - scale(_hist_dist_Sum_09TeV_pT3 , 1/integral(_hist_dist_Sum_09TeV_pT3 )); - - double _nch_avg_7TeV_pT3 = 0; - double _nch_avg_7TeV_pT20 = 0; - double _nch_avg_09TeV_pT3 = 0; - _nch_avg_7TeV_pT3 = (_nch_tot_7TeV_pT3 / _j) ; - _nch_avg_7TeV_pT20 = (_nch_tot_7TeV_pT20 / _jj) ; - _nch_avg_09TeV_pT3 = (_nch_tot_09TeV_pT3 / _jjj) ; - - scale(_hist_dist_pT_7TeV_pT20, _nch_avg_7TeV_pT20 / integral(_hist_dist_pT_7TeV_pT20) ); //normalizes pT Distribution so that area = avg Nch - scale(_hist_dist_pT_7TeV_pT3, _nch_avg_7TeV_pT3 / integral(_hist_dist_pT_7TeV_pT3) ); // normalizes Nch Distribution so that area = avg Nch - scale(_hist_dist_pT_09TeV_pT3, _nch_avg_09TeV_pT3 / integral(_hist_dist_pT_09TeV_pT3) ); // normalizes SumpT distribtuion so that area = avg Nch - + _hist_dist_Sum_09TeV_pT3 -> fill(ptSumTransverse/GeV, weight); + } } + } - private: + /// Normalise histograms etc., after the run + void finalize() { + normalize(_hist_dist_Nch_7TeV_pT3); + normalize(_hist_dist_Sum_7TeV_pT3); + normalize(_hist_dist_Nch_7TeV_pT20); + normalize(_hist_dist_Sum_7TeV_pT20); + normalize(_hist_dist_Nch_09TeV_pT3); + normalize(_hist_dist_Sum_09TeV_pT3); + + double _nch_avg_7TeV_pT3 = (_nch_tot_7TeV_pT3 / _j); + double _nch_avg_7TeV_pT20 = (_nch_tot_7TeV_pT20 / _jj); + double _nch_avg_09TeV_pT3 = (_nch_tot_09TeV_pT3 / _jjj); + + if (_j!=0.0) normalize(_hist_dist_pT_7TeV_pT20, _nch_avg_7TeV_pT20); + if (_jj!=0.0) normalize(_hist_dist_pT_7TeV_pT3, _nch_avg_7TeV_pT3); + if (_jjj!=0.0) normalize(_hist_dist_pT_09TeV_pT3, _nch_avg_09TeV_pT3); + } - int _j; - int _jj; - int _jjj; - - double _nch_tot_7TeV_pT3; - double _nch_tot_7TeV_pT20; - double _nch_tot_09TeV_pT3; - - AIDA::IProfile1D * _hist_profile_Nch_pT_7TeV; - AIDA::IProfile1D * _hist_profile_SumpT_pT_7TeV; - AIDA::IProfile1D * _hist_profile_Nch_09TeV; - AIDA::IProfile1D * _hist_profile_Sum_09TeV; - AIDA::IHistogram1D * _hist_dist_Nch_7TeV_pT3 ; - AIDA::IHistogram1D * _hist_dist_Sum_7TeV_pT3; - AIDA::IHistogram1D * _hist_dist_pT_7TeV_pT3; - AIDA::IHistogram1D * _hist_dist_Nch_7TeV_pT20; - AIDA::IHistogram1D * _hist_dist_Sum_7TeV_pT20; - AIDA::IHistogram1D * _hist_dist_pT_7TeV_pT20; - AIDA::IHistogram1D * _hist_dist_Nch_09TeV_pT3; - AIDA::IHistogram1D * _hist_dist_Sum_09TeV_pT3; - AIDA::IHistogram1D * _hist_dist_pT_09TeV_pT3; - //@} - - }; + private: + + double _j; + double _jj; + double _jjj; + + double _nch_tot_7TeV_pT3; + double _nch_tot_7TeV_pT20; + double _nch_tot_09TeV_pT3; + + AIDA::IProfile1D * _hist_profile_Nch_pT_7TeV; + AIDA::IProfile1D * _hist_profile_SumpT_pT_7TeV; + AIDA::IProfile1D * _hist_profile_Nch_09TeV; + AIDA::IProfile1D * _hist_profile_Sum_09TeV; + AIDA::IHistogram1D * _hist_dist_Nch_7TeV_pT3 ; + AIDA::IHistogram1D * _hist_dist_Sum_7TeV_pT3; + AIDA::IHistogram1D * _hist_dist_pT_7TeV_pT3; + AIDA::IHistogram1D * _hist_dist_Nch_7TeV_pT20; + AIDA::IHistogram1D * _hist_dist_Sum_7TeV_pT20; + AIDA::IHistogram1D * _hist_dist_pT_7TeV_pT20; + AIDA::IHistogram1D * _hist_dist_Nch_09TeV_pT3; + AIDA::IHistogram1D * _hist_dist_Sum_09TeV_pT3; + AIDA::IHistogram1D * _hist_dist_pT_09TeV_pT3; - // This global object acts as a hook for the plugin system - AnalysisBuilder<CMS_2011_S9120041> plugin_CMS_2011_S9120041; + }; + // This global object acts as a hook for the plugin system + DECLARE_RIVET_PLUGIN(CMS_2011_S9120041); }
More information about the Rivet-svn mailing list |