[Rivet-svn] rivet: Add FinalState and Cut (optional) constructor arguments a...

Rivet Mercurial rivet at projects.hepforge.org
Sat Jun 3 14:45:02 BST 2017


details:   https://rivet.hepforge.org/hg/rivet/rev/e371e83848e1
branches:  release-2-5-x
changeset: 5799:e371e83848e1
user:      Andy Buckley <andy at insectnation.org>
date:      Sat Jun 03 14:34:15 2017 +0100
description:
Add FinalState and Cut (optional) constructor arguments and usage to DISFinalState. Thanks to Andrii Verbytskyi for the idea and initial patch.

diffs (truncated from 141 to 50 lines):

--- a/ChangeLog	Thu May 25 16:09:07 2017 +0100
+++ b/ChangeLog	Sat Jun 03 14:34:15 2017 +0100
@@ -1,3 +1,9 @@
+2017-06-03  Andy Buckley  <andy.buckley at cern.ch>
+
+	* Add FinalState and Cut (optional) constructor arguments and
+	usage to DISFinalState. Thanks to Andrii Verbytskyi for the idea
+	and initial patch.
+
 2017-05-23  Andy Buckley  <andy.buckley at cern.ch>
 
 	* Add ATLAS_2016_I1448301, Z/gamma cross section measurement at 8 TeV.
--- a/include/Rivet/Projections/DISFinalState.hh	Thu May 25 16:09:07 2017 +0100
+++ b/include/Rivet/Projections/DISFinalState.hh	Sat Jun 03 14:34:15 2017 +0100
@@ -15,20 +15,53 @@
   public:
 
     /// Type of DIS boost to apply
-    enum BoostType { HCM, BREIT };
+    enum BoostType { HCM, BREIT, LAB };
 
 
     /// @name Constructors
     //@{
 
-    /// Constructor
-    DISFinalState(const DISKinematics& kinematicsp, BoostType boosttype)
+    /// Constructor with explicit FinalState
+    /// @note The DISKinematics has no parameters, hence explicitly passing it as an arg shouldn't be necessary.
+    DISFinalState(const FinalState& fs, BoostType boosttype, const DISKinematics& kinematicsp=DISKinematics())
       : _boosttype(boosttype)
     {
       setName("DISFinalState");
-      addProjection(kinematicsp, "Kinematics");
+      declare(fs, "FS");
+      declare(kinematicsp, "Kinematics");
     }
 
+    /// Constructor with optional FinalState
+    /// @note The DISKinematics has no parameters, hence explicitly passing it as an arg shouldn't be necessary.
+    DISFinalState(BoostType boosttype, const FinalState& fs=FinalState(), const DISKinematics& kinematicsp=DISKinematics())
+      : DISFinalState(fs, boosttype, kinematicsp)
+    {    }
+
+    /// Constructor with explicit cuts to define final-state particles
+    /// @note The DISKinematics has no parameters, hence explicitly passing it as an arg shouldn't be necessary.
+    DISFinalState(const Cut& c, BoostType boosttype, const DISKinematics& kinematicsp=DISKinematics())
+      : DISFinalState(FinalState(c), boosttype, kinematicsp)
+    {    }
+


More information about the Rivet-svn mailing list