Fork me on GitHub

source: git/external/fastjet/contribs/Nsubjettiness/WinnerTakeAllRecombiner.hh@ e2a76ae

ImprovedOutputFile Timing dual_readout llp
Last change on this file since e2a76ae was 9687203, checked in by mselvaggi <mselvaggi@…>, 11 years ago

added nsubjettiness

  • Property mode set to 100644
File size: 2.4 KB
RevLine 
[9687203]1// Nsubjettiness Package
2// Questions/Comments? jthaler@jthaler.net
3//
4// Copyright (c) 2011-14
5// Jesse Thaler, Ken Van Tilburg, Christopher K. Vermilion, and TJ Wilkason
6//
7//----------------------------------------------------------------------
8// This file is part of FastJet contrib.
9//
10// It is free software; you can redistribute it and/or modify it under
11// the terms of the GNU General Public License as published by the
12// Free Software Foundation; either version 2 of the License, or (at
13// your option) any later version.
14//
15// It is distributed in the hope that it will be useful, but WITHOUT
16// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
17// or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
18// License for more details.
19//
20// You should have received a copy of the GNU General Public License
21// along with this code. If not, see <http://www.gnu.org/licenses/>.
22//----------------------------------------------------------------------
23
24#ifndef __FASTJET_CONTRIB_WINNERTAKEALLRECOMBINER_HH__
25#define __FASTJET_CONTRIB_WINNERTAKEALLRECOMBINER_HH__
26
27#include "fastjet/PseudoJet.hh"
28#include "fastjet/JetDefinition.hh"
29
30#include <cmath>
31#include <vector>
32#include <list>
33
34FASTJET_BEGIN_NAMESPACE // defined in fastjet/internal/base.hh
35
36namespace contrib {
37
38//------------------------------------------------------------------------
39/// \class WinnerTakeAllRecombiner
40// WinnerTakeAllRecombiner defines a new recombination scheme by inheriting from JetDefinition::Recombiner.
41// This scheme compares the energy of two input particles, and then combines them into a particle with
42// an energy equal to the sum of the two particle energies and a direction identical to that of the harder
43// particle. This creates a jet with an axis guaranteed to align with a particle in the event.
44class WinnerTakeAllRecombiner : public fastjet::JetDefinition::Recombiner {
45public:
46 // Constructor to choose value of alpha (defaulted to 1 for normal pT sum)
47 WinnerTakeAllRecombiner(double alpha = 1.0) : _alpha(alpha) {}
48
49 virtual std::string description() const;
50
51 /// recombine pa and pb and put result into pab
52 virtual void recombine(const fastjet::PseudoJet & pa, const fastjet::PseudoJet & pb, fastjet::PseudoJet & pab) const;
53
54private:
55 double _alpha; //power of (pt/E) term when recombining particles
56};
57
58} //namespace contrib
59
60FASTJET_END_NAMESPACE
61
62#endif // __FASTJET_CONTRIB_WINNERTAKEALLRECOMBINER_HH__
Note: See TracBrowser for help on using the repository browser.