Fork me on GitHub

source: git/external/fastjet/contribs/Nsubjettiness/Nsubjettiness.cc@ a98c7ef

ImprovedOutputFile Timing dual_readout llp
Last change on this file since a98c7ef was 35cdc46, checked in by Pavel Demin <demin@…>, 10 years ago

upgrade FastJet to version 3.1.0-beta.1, upgrade Nsubjettiness to version 2.1.0, add SoftKiller version 1.0.0

  • Property mode set to 100644
File size: 2.0 KB
Line 
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// $Id: Nsubjettiness.cc 597 2014-04-16 23:07:55Z jthaler $
8//----------------------------------------------------------------------
9// This file is part of FastJet contrib.
10//
11// It is free software; you can redistribute it and/or modify it under
12// the terms of the GNU General Public License as published by the
13// Free Software Foundation; either version 2 of the License, or (at
14// your option) any later version.
15//
16// It is distributed in the hope that it will be useful, but WITHOUT
17// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
18// or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
19// License for more details.
20//
21// You should have received a copy of the GNU General Public License
22// along with this code. If not, see <http://www.gnu.org/licenses/>.
23//----------------------------------------------------------------------
24
25#include "Nsubjettiness.hh"
26
27FASTJET_BEGIN_NAMESPACE // defined in fastjet/internal/base.hh
28
29namespace contrib {
30
31//result returns tau_N with normalization dependent on what is specified in constructor
32double Nsubjettiness::result(const PseudoJet& jet) const {
33 std::vector<fastjet::PseudoJet> particles = jet.constituents();
34 return _njettinessFinder.getTau(_N, particles);
35}
36
37TauComponents Nsubjettiness::component_result(const PseudoJet& jet) const {
38 std::vector<fastjet::PseudoJet> particles = jet.constituents();
39 return _njettinessFinder.getTauComponents(_N, particles);
40}
41
42//ratio result uses Nsubjettiness result to find the ratio tau_N/tau_M, where N and M are specified by user
43double NsubjettinessRatio::result(const PseudoJet& jet) const {
44 double numerator = _nsub_numerator.result(jet);
45 double denominator = _nsub_denominator.result(jet);
46 return numerator/denominator;
47}
48
49} // namespace contrib
50
51FASTJET_END_NAMESPACE
Note: See TracBrowser for help on using the repository browser.