[Rivet-svn] r4057 - in branches/2012-06-aidarivet: . data/anainfo data/plotinfo data/refdata src/Analyses

blackhole at projects.hepforge.org blackhole at projects.hepforge.org
Thu Dec 6 10:41:12 GMT 2012


Author: hoeth
Date: Thu Dec  6 10:41:12 2012
New Revision: 4057

Log:
Added ATLAS_2012_I1188891 analysis

Added:
   branches/2012-06-aidarivet/data/anainfo/ATLAS_2012_I1188891.info
   branches/2012-06-aidarivet/data/plotinfo/ATLAS_2012_I1188891.plot
   branches/2012-06-aidarivet/data/refdata/ATLAS_2012_I1188891.aida
   branches/2012-06-aidarivet/src/Analyses/ATLAS_2012_I1188891.cc
Modified:
   branches/2012-06-aidarivet/ChangeLog
   branches/2012-06-aidarivet/data/anainfo/Makefile.am
   branches/2012-06-aidarivet/data/plotinfo/Makefile.am
   branches/2012-06-aidarivet/data/refdata/Makefile.am
   branches/2012-06-aidarivet/src/Analyses/Makefile.am

Modified: branches/2012-06-aidarivet/ChangeLog
==============================================================================
--- branches/2012-06-aidarivet/ChangeLog	Sun Dec  2 10:47:23 2012	(r4056)
+++ branches/2012-06-aidarivet/ChangeLog	Thu Dec  6 10:41:12 2012	(r4057)
@@ -1,3 +1,7 @@
+2012-12-06  Hendrik Hoeth <hendrik.hoeth at cern.ch>
+
+	* Added ATLAS_2012_I1188891 analysis
+
 2012-11-27  Hendrik Hoeth <hendrik.hoeth at cern.ch>
 
 	* Fix make-plots png creation for SL5

Added: branches/2012-06-aidarivet/data/anainfo/ATLAS_2012_I1188891.info
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/2012-06-aidarivet/data/anainfo/ATLAS_2012_I1188891.info	Thu Dec  6 10:41:12 2012	(r4057)
@@ -0,0 +1,41 @@
+Name: ATLAS_2012_I1188891
+Year: 2012
+Summary: flavour composition of dijet events at 7 TeV 
+Experiment: ATLAS
+Collider: LHC 7TeV
+InspireID: 1188891
+Status: VALIDATED
+Authors:
+ - Cecile Lapoire <clapoire at cern.ch>
+ - Roman Lysak <lysak at fzu.cz>
+References:
+ - arXiv:1210.0441
+RunInfo:
+  pp di-jet events at 7 TeV 
+NumEvents: 1000000
+NeedCrossSection: no
+Beams: [p+, p+]
+Energies: [7000]
+Description:
+  'The measurement of the flavour composition of dijet events produced 
+   in pp collisions at $\sqrt{s}=7 TeV$ using the ATLAS detector. 
+   Six possible combinations of light, charm and bottom jets are identified 
+   in the dijet events, where the jet flavour is defined by the presence 
+   of bottom, charm or solely light flavour hadrons in the jet. 
+   The fractions of these dijet flavour states as functions of the leading 
+   jet transverse momentum in the range 40 GeV to 500 GeV and jet 
+   rapidity $|y| < 2.1$ are measured.'
+BibKey: Aad:2012ma
+BibTeX: '@article{Aad:2012ma,
+      author         = "Aad, Georges and others",
+      title          = "{Measurement of the flavour composition of dijet events
+                        in $pp$ collisions at $\sqrt{s}=7$ TeV with the ATLAS
+                        detector}",
+      collaboration  = "ATLAS Collaboration",
+      year           = "2012",
+      eprint         = "1210.0441",
+      archivePrefix  = "arXiv",
+      primaryClass   = "hep-ex",
+      SLACcitation   = "%%CITATION = ARXIV:1210.0441;%%",
+}'
+

Modified: branches/2012-06-aidarivet/data/anainfo/Makefile.am
==============================================================================
--- branches/2012-06-aidarivet/data/anainfo/Makefile.am	Sun Dec  2 10:47:23 2012	(r4056)
+++ branches/2012-06-aidarivet/data/anainfo/Makefile.am	Thu Dec  6 10:41:12 2012	(r4057)
@@ -55,6 +55,7 @@
   ATLAS_2012_I1082009.info \
   ATLAS_2012_I1091481.info \
   ATLAS_2012_I1183818.info \
+  ATLAS_2012_I1188891.info \
   ATLAS_2012_I946427.info \
   ATLAS_2012_CONF_2012_001.info \
   ATLAS_2012_I1112263.info \

Added: branches/2012-06-aidarivet/data/plotinfo/ATLAS_2012_I1188891.plot
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/2012-06-aidarivet/data/plotinfo/ATLAS_2012_I1188891.plot	Thu Dec  6 10:41:12 2012	(r4057)
@@ -0,0 +1,28 @@
+# BEGIN PLOT /ATLAS_2012_I1188891/d0
+XLabel=Leading jet $p_\perp$~[GeV]
+LogY=0
+# END PLOT
+
+# BEGIN PLOT /ATLAS_2012_I1188891/d01-x01-y01
+YLabel=$bb$ fraction [\%]
+# END PLOT
+
+# BEGIN PLOT /ATLAS_2012_I1188891/d02-x01-y01
+YLabel=$bc$ fraction [\%]
+# END PLOT
+
+# BEGIN PLOT /ATLAS_2012_I1188891/d03-x01-y01
+YLabel=$cc$ fraction [\%]
+# END PLOT
+
+# BEGIN PLOT /ATLAS_2012_I1188891/d04-x01-y01
+YLabel=$b$-light fraction [\%]
+# END PLOT
+
+# BEGIN PLOT /ATLAS_2012_I1188891/d05-x01-y01
+YLabel=$c$-light fraction [\%]
+# END PLOT
+
+# BEGIN PLOT /ATLAS_2012_I1188891/d06-x01-y01
+YLabel=light-light fraction [\%]
+# END PLOT

Modified: branches/2012-06-aidarivet/data/plotinfo/Makefile.am
==============================================================================
--- branches/2012-06-aidarivet/data/plotinfo/Makefile.am	Sun Dec  2 10:47:23 2012	(r4056)
+++ branches/2012-06-aidarivet/data/plotinfo/Makefile.am	Thu Dec  6 10:41:12 2012	(r4057)
@@ -59,6 +59,7 @@
   ATLAS_2012_I1180197.plot \
   ATLAS_2012_I1082009.plot \
   ATLAS_2012_I1183818.plot \
+  ATLAS_2012_I1188891.plot \
   ATLAS_2012_I1186556.plot \
   ATLAS_2012_I1190891.plot \
   ATLAS_2012_CONF_2012_103.plot \

Added: branches/2012-06-aidarivet/data/refdata/ATLAS_2012_I1188891.aida
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/2012-06-aidarivet/data/refdata/ATLAS_2012_I1188891.aida	Thu Dec  6 10:41:12 2012	(r4057)
@@ -0,0 +1,191 @@
+<?xml version="1.0" ?>
+<!DOCTYPE aida SYSTEM "http://aida.freehep.org/schemas/3.3/aida.dtd">
+<aida version="3.3">
+  <implementation version="1.1" package="Rivet"/>
+  <dataPointSet name="d01-x01-y01" dimension="2"
+      path="/REF/ATLAS_2012_I1188891" title="">
+    <annotation>
+      <item key="Title" value="" sticky="true"/>
+      <item key="AidaPath" value="/REF/ATLAS_2012_I1188891/d01-x01-y01" sticky="true"/>
+    </annotation>
+    <dataPoint>
+      <measurement errorPlus="1.000000e+01" value="5.000000e+01" errorMinus="1.000000e+01"/>
+      <measurement errorPlus="1.264910e-01" value="6.500000e-01" errorMinus="1.264910e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="1.000000e+01" value="7.000000e+01" errorMinus="1.000000e+01"/>
+      <measurement errorPlus="1.170470e-01" value="6.300000e-01" errorMinus="1.170470e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="2.000000e+01" value="1.000000e+02" errorMinus="2.000000e+01"/>
+      <measurement errorPlus="1.118030e-01" value="5.800000e-01" errorMinus="1.118030e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="2.000000e+01" value="1.400000e+02" errorMinus="2.000000e+01"/>
+      <measurement errorPlus="1.044030e-01" value="6.100000e-01" errorMinus="1.044030e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="4.500000e+01" value="2.050000e+02" errorMinus="4.500000e+01"/>
+      <measurement errorPlus="8.602330e-02" value="5.800000e-01" errorMinus="8.602330e-02"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="1.250000e+02" value="3.750000e+02" errorMinus="1.250000e+02"/>
+      <measurement errorPlus="1.000000e-01" value="3.900000e-01" errorMinus="1.000000e-01"/>
+    </dataPoint>
+  </dataPointSet>
+  <dataPointSet name="d02-x01-y01" dimension="2"
+      path="/REF/ATLAS_2012_I1188891" title="">
+    <annotation>
+      <item key="Title" value="" sticky="true"/>
+      <item key="AidaPath" value="/REF/ATLAS_2012_I1188891/d02-x01-y01" sticky="true"/>
+    </annotation>
+    <dataPoint>
+      <measurement errorPlus="1.000000e+01" value="5.000000e+01" errorMinus="1.000000e+01"/>
+      <measurement errorPlus="2.343070e-01" value="4.900000e-01" errorMinus="2.343070e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="1.000000e+01" value="7.000000e+01" errorMinus="1.000000e+01"/>
+      <measurement errorPlus="2.220360e-01" value="3.100000e-01" errorMinus="2.220360e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="2.000000e+01" value="1.000000e+02" errorMinus="2.000000e+01"/>
+      <measurement errorPlus="2.061550e-01" value="5.300000e-01" errorMinus="2.061550e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="2.000000e+01" value="1.400000e+02" errorMinus="2.000000e+01"/>
+      <measurement errorPlus="2.376970e-01" value="5.200000e-01" errorMinus="2.376970e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="4.500000e+01" value="2.050000e+02" errorMinus="4.500000e+01"/>
+      <measurement errorPlus="2.941090e-01" value="2.800000e-01" errorMinus="2.941090e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="1.250000e+02" value="3.750000e+02" errorMinus="1.250000e+02"/>
+      <measurement errorPlus="4.326660e-01" value="9.300000e-01" errorMinus="4.326660e-01"/>
+    </dataPoint>
+  </dataPointSet>
+  <dataPointSet name="d03-x01-y01" dimension="2"
+      path="/REF/ATLAS_2012_I1188891" title="">
+    <annotation>
+      <item key="Title" value="" sticky="true"/>
+      <item key="AidaPath" value="/REF/ATLAS_2012_I1188891/d03-x01-y01" sticky="true"/>
+    </annotation>
+    <dataPoint>
+      <measurement errorPlus="1.000000e+01" value="5.000000e+01" errorMinus="1.000000e+01"/>
+      <measurement errorPlus="4.313930e-01" value="1.080000e+00" errorMinus="4.313930e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="1.000000e+01" value="7.000000e+01" errorMinus="1.000000e+01"/>
+      <measurement errorPlus="4.393180e-01" value="1.510000e+00" errorMinus="4.393180e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="2.000000e+01" value="1.000000e+02" errorMinus="2.000000e+01"/>
+      <measurement errorPlus="3.008320e-01" value="1.030000e+00" errorMinus="3.008320e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="2.000000e+01" value="1.400000e+02" errorMinus="2.000000e+01"/>
+      <measurement errorPlus="2.729470e-01" value="8.600000e-01" errorMinus="2.729470e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="4.500000e+01" value="2.050000e+02" errorMinus="4.500000e+01"/>
+      <measurement errorPlus="5.325410e-01" value="1.680000e+00" errorMinus="5.325410e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="1.250000e+02" value="3.750000e+02" errorMinus="1.250000e+02"/>
+      <measurement errorPlus="6.862220e-01" value="7.000000e-01" errorMinus="6.862220e-01"/>
+    </dataPoint>
+  </dataPointSet>
+  <dataPointSet name="d04-x01-y01" dimension="2"
+      path="/REF/ATLAS_2012_I1188891" title="">
+    <annotation>
+      <item key="Title" value="" sticky="true"/>
+      <item key="AidaPath" value="/REF/ATLAS_2012_I1188891/d04-x01-y01" sticky="true"/>
+    </annotation>
+    <dataPoint>
+      <measurement errorPlus="1.000000e+01" value="5.000000e+01" errorMinus="1.000000e+01"/>
+      <measurement errorPlus="4.712750e-01" value="4.070000e+00" errorMinus="4.712750e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="1.000000e+01" value="7.000000e+01" errorMinus="1.000000e+01"/>
+      <measurement errorPlus="4.808330e-01" value="4.780000e+00" errorMinus="4.808330e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="2.000000e+01" value="1.000000e+02" errorMinus="2.000000e+01"/>
+      <measurement errorPlus="5.458940e-01" value="5.430000e+00" errorMinus="5.458940e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="2.000000e+01" value="1.400000e+02" errorMinus="2.000000e+01"/>
+      <measurement errorPlus="5.277310e-01" value="6.020000e+00" errorMinus="5.277310e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="4.500000e+01" value="2.050000e+02" errorMinus="4.500000e+01"/>
+      <measurement errorPlus="4.531000e-01" value="6.550000e+00" errorMinus="4.531000e-01"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="1.250000e+02" value="3.750000e+02" errorMinus="1.250000e+02"/>
+      <measurement errorPlus="5.953990e-01" value="6.690000e+00" errorMinus="5.953990e-01"/>
+    </dataPoint>
+  </dataPointSet>
+  <dataPointSet name="d05-x01-y01" dimension="2"
+      path="/REF/ATLAS_2012_I1188891" title="">
+    <annotation>
+      <item key="Title" value="" sticky="true"/>
+      <item key="AidaPath" value="/REF/ATLAS_2012_I1188891/d05-x01-y01" sticky="true"/>
+    </annotation>
+    <dataPoint>
+      <measurement errorPlus="1.000000e+01" value="5.000000e+01" errorMinus="1.000000e+01"/>
+      <measurement errorPlus="1.772000e+00" value="1.060000e+01" errorMinus="1.772000e+00"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="1.000000e+01" value="7.000000e+01" errorMinus="1.000000e+01"/>
+      <measurement errorPlus="1.392840e+00" value="1.030000e+01" errorMinus="1.392840e+00"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="2.000000e+01" value="1.000000e+02" errorMinus="2.000000e+01"/>
+      <measurement errorPlus="1.520690e+00" value="1.130000e+01" errorMinus="1.520690e+00"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="2.000000e+01" value="1.400000e+02" errorMinus="2.000000e+01"/>
+      <measurement errorPlus="1.815930e+00" value="1.090000e+01" errorMinus="1.815930e+00"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="4.500000e+01" value="2.050000e+02" errorMinus="4.500000e+01"/>
+      <measurement errorPlus="2.061550e+00" value="1.100000e+01" errorMinus="2.061550e+00"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="1.250000e+02" value="3.750000e+02" errorMinus="1.250000e+02"/>
+      <measurement errorPlus="2.912040e+00" value="1.240000e+01" errorMinus="2.912040e+00"/>
+    </dataPoint>
+  </dataPointSet>
+  <dataPointSet name="d06-x01-y01" dimension="2"
+      path="/REF/ATLAS_2012_I1188891" title="">
+    <annotation>
+      <item key="Title" value="" sticky="true"/>
+      <item key="AidaPath" value="/REF/ATLAS_2012_I1188891/d06-x01-y01" sticky="true"/>
+    </annotation>
+    <dataPoint>
+      <measurement errorPlus="1.000000e+01" value="5.000000e+01" errorMinus="1.000000e+01"/>
+      <measurement errorPlus="2.088060e+00" value="8.310000e+01" errorMinus="2.088060e+00"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="1.000000e+01" value="7.000000e+01" errorMinus="1.000000e+01"/>
+      <measurement errorPlus="1.772000e+00" value="8.240000e+01" errorMinus="1.772000e+00"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="2.000000e+01" value="1.000000e+02" errorMinus="2.000000e+01"/>
+      <measurement errorPlus="1.824830e+00" value="8.120000e+01" errorMinus="1.824830e+00"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="2.000000e+01" value="1.400000e+02" errorMinus="2.000000e+01"/>
+      <measurement errorPlus="2.022370e+00" value="8.110000e+01" errorMinus="2.022370e+00"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="4.500000e+01" value="2.050000e+02" errorMinus="4.500000e+01"/>
+      <measurement errorPlus="2.473860e+00" value="8.000000e+01" errorMinus="2.473860e+00"/>
+    </dataPoint>
+    <dataPoint>
+      <measurement errorPlus="1.250000e+02" value="3.750000e+02" errorMinus="1.250000e+02"/>
+      <measurement errorPlus="3.710800e+00" value="7.890000e+01" errorMinus="3.710800e+00"/>
+    </dataPoint>
+  </dataPointSet>
+</aida>

Modified: branches/2012-06-aidarivet/data/refdata/Makefile.am
==============================================================================
--- branches/2012-06-aidarivet/data/refdata/Makefile.am	Sun Dec  2 10:47:23 2012	(r4056)
+++ branches/2012-06-aidarivet/data/refdata/Makefile.am	Thu Dec  6 10:41:12 2012	(r4057)
@@ -54,6 +54,7 @@
   ATLAS_2012_I943401.aida \
   ATLAS_2012_I1082009.aida \
   ATLAS_2012_I1183818.aida \
+  ATLAS_2012_I1188891.aida \
   ATLAS_2012_CONF_2012_001.aida \
   BABAR_2005_S6181155.aida \
   BABAR_2006_S6511112.aida \

Added: branches/2012-06-aidarivet/src/Analyses/ATLAS_2012_I1188891.cc
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/2012-06-aidarivet/src/Analyses/ATLAS_2012_I1188891.cc	Thu Dec  6 10:41:12 2012	(r4057)
@@ -0,0 +1,183 @@
+// -*- C++ -*-
+#include "Rivet/Analysis.hh"
+#include "Rivet/RivetAIDA.hh"
+#include "Rivet/Tools/Logging.hh"
+#include "Rivet/Projections/FastJets.hh"
+#include "Rivet/Tools/BinnedHistogram.hh"
+#include "Rivet/Projections/ChargedFinalState.hh"
+#include "LWH/Histogram1D.h"
+#include "Rivet/Tools/ParticleIdUtils.hh"
+#include "Rivet/Particle.hh"
+
+//#include <iostream>
+
+namespace Rivet {
+
+
+  class ATLAS_2012_I1188891 : public Analysis {
+
+  public:
+
+
+    ATLAS_2012_I1188891()
+      : Analysis("ATLAS_2012_I1188891")
+    {
+    }
+
+
+
+  public:
+
+    void init() {
+
+      const FinalState fs;
+      FastJets fj04(fs,  FastJets::ANTIKT, 0.4);
+      addProjection(fj04, "AntiKT04");
+
+      //double xbins[7] = { 40.,60.,80.,120.,160.,250.,500. };
+      vector<double> xbins;
+      xbins.push_back(40.);
+      xbins.push_back(60.);
+      xbins.push_back(80.);
+      xbins.push_back(120.);
+      xbins.push_back(160.);
+      xbins.push_back(250.);
+      xbins.push_back(500.);
+
+      string histotitle[7]={"BBfraction","BCfraction","CCfraction","BUfraction","CUfraction","UUfraction","Total"};
+      for (int i = 0 ; i < 7 ; i++){
+        _fracHistos[i] = bookHistogram1D(histotitle[i],xbins);
+      }
+    }
+
+
+    void analyze(const Event& event) {
+
+      double weight    = event.weight();
+      double weight100 = event.weight() * 100.;  //to get results in %
+
+      //keeps jets with pt>20 geV and ordered in decreasing pt
+      Jets jetAr = applyProjection<FastJets>(event, "AntiKT04").jetsByPt(20*GeV);
+
+      int flav[2]={1,1};
+      vector<FourMomentum> leadjets;
+
+      //get b/c-hadrons
+      std::vector<HepMC::GenParticle*> B_hadrons;
+      std::vector<HepMC::GenParticle*> C_hadrons;
+      std::vector<HepMC::GenParticle*> allParticles = particles(event.genEvent());
+      for(unsigned int i = 0; i < allParticles.size(); i++) {
+        GenParticle* p = allParticles.at(i);
+        if(p->momentum().perp()*GeV < 5) continue;
+        if ( (Rivet::PID::isHadron ( p->pdg_id() ) &&
+              Rivet::PID::hasBottom( p->pdg_id() )    ) ) {
+          B_hadrons.push_back(p);
+        }
+        if ( (Rivet::PID::isHadron( p->pdg_id() ) &&
+              Rivet::PID::hasCharm( p->pdg_id() )    ) ) {
+          C_hadrons.push_back(p);
+        }
+      }
+
+      //select dijet
+      foreach (const Jet& jet, jetAr) {
+
+        const double pT   = jet.momentum().pT();
+        const double absy = fabs(jet.momentum().rapidity());
+
+        bool isBjet = false;
+        //not using this
+        //isBjet = jet.containsBottom();
+        foreach(HepMC::GenParticle* b, B_hadrons) {
+          FourMomentum hadron = b->momentum();
+          double hadron_jet_dR = deltaR(jet.momentum(), hadron);
+          if(hadron_jet_dR < 0.3) isBjet = true;
+        }
+
+        bool isCjet = false;
+        //bool isCjet = jet.containsCharm();
+        foreach(HepMC::GenParticle* c, C_hadrons) {
+          FourMomentum hadron = c->momentum();
+          double hadron_jet_dR = deltaR(jet.momentum(), hadron);
+          if(hadron_jet_dR < 0.3) isCjet = true;
+        }
+
+        int jetflav=1;
+        if      (isBjet)jetflav=5;
+        else if (isCjet)jetflav=4;
+
+        if (absy <= 2.1 && leadjets.size() < 2) {
+
+          if (pT > 500*GeV) continue;
+          if ((leadjets.empty() && pT < 40*GeV) || pT < 20*GeV) continue;
+
+          leadjets.push_back(jet.momentum());
+
+          if (leadjets.size()==1) flav[0] = jetflav;
+          if (leadjets.size()==2) flav[1] = jetflav;
+        }
+      }
+
+      if (leadjets.size() < 2) vetoEvent;
+
+
+      double pBinsLJ[7] = {40.,60.,80.,120.,160.,250.,500.};
+      int    iPBinLJ = -1;
+
+      for (int k = 0 ; k < 7 ; k++) {
+        if (leadjets[0].pT() > pBinsLJ[k]*GeV) iPBinLJ=k;
+        else break;
+      }
+
+      bool c_ljpt  = (iPBinLJ != -1);
+      bool c_nljpt = leadjets[1].pT() > 20*GeV;
+      bool c_dphi  = fabs( deltaPhi(leadjets[0],leadjets[1]) ) > 2.1;
+      bool isDijet = c_ljpt & c_nljpt & c_dphi;
+      if (!isDijet) vetoEvent;
+
+      _fracHistos[6]->fill(leadjets[0].pT(), weight);
+
+      if (flav[0]==5 && flav[1]==5)                                  // BB dijet
+        _fracHistos[0]->fill(leadjets[0].pT(), weight100);
+
+      if ((flav[0]==5 && flav[1]==4) || (flav[0]==4 && flav[1]==5))  // BC dijet
+        _fracHistos[1]->fill(leadjets[0].pT(), weight100);
+
+      if (flav[0]==4 && flav[1]==4)                                  // CC dijet
+        _fracHistos[2]->fill(leadjets[0].pT(), weight100);
+
+      if ((flav[0]==5 && flav[1]==1) || (flav[0]==1 && flav[1]==5))  // B-light dijet
+        _fracHistos[3]->fill(leadjets[0].pT(), weight100);
+
+      if ((flav[0]==4 && flav[1]==1) || (flav[0]==1 && flav[1]==4))  // C-light dijet
+        _fracHistos[4]->fill(leadjets[0].pT(), weight100);
+
+      if (flav[0]==1 && flav[1]==1)                                  // light-light dijet
+        _fracHistos[5]->fill(leadjets[0].pT(), weight100);
+    }
+
+
+    void finalize() {
+      AIDA::IHistogramFactory& hf = histogramFactory();
+
+      hf.divide( histoPath(1,1,1), *_fracHistos[0], *_fracHistos[6]);
+      hf.divide( histoPath(2,1,1), *_fracHistos[1], *_fracHistos[6]);
+      hf.divide( histoPath(3,1,1), *_fracHistos[2], *_fracHistos[6]);
+      hf.divide( histoPath(4,1,1), *_fracHistos[3], *_fracHistos[6]);
+      hf.divide( histoPath(5,1,1), *_fracHistos[4], *_fracHistos[6]);
+      hf.divide( histoPath(6,1,1), *_fracHistos[5], *_fracHistos[6]);
+
+      // remove temporary histograms
+      for (size_t i=0; i<7; i++) {
+        hf.destroy(_fracHistos[i]);
+      }
+    }
+
+  private:
+
+    AIDA::IHistogram1D * _fracHistos[7];
+  };
+
+  DECLARE_RIVET_PLUGIN(ATLAS_2012_I1188891);
+
+}

Modified: branches/2012-06-aidarivet/src/Analyses/Makefile.am
==============================================================================
--- branches/2012-06-aidarivet/src/Analyses/Makefile.am	Sun Dec  2 10:47:23 2012	(r4056)
+++ branches/2012-06-aidarivet/src/Analyses/Makefile.am	Thu Dec  6 10:41:12 2012	(r4057)
@@ -79,7 +79,8 @@
     ATLAS_2012_I1112263.cc \
     ATLAS_2012_I1117704.cc \
     ATLAS_2012_I1125961.cc \
-    ATLAS_2012_I1183818.cc
+    ATLAS_2012_I1183818.cc \
+    ATLAS_2012_I1188891.cc
 if ENABLE_PRELIMINARY
 RivetATLASAnalyses_la_SOURCES += \
     ATLAS_2012_CONF_2012_001.cc


More information about the Rivet-svn mailing list