ATLAS Offline Software
Functions
TrigBjetMonitorAlgorithm.cxx File Reference
#include "TrigBjetMonitorAlgorithm.h"
#include "EventPrimitives/EventPrimitivesHelpers.h"
#include "TrigCompositeUtils/TrigCompositeUtils.h"
#include "xAODJet/JetContainer.h"
#include "xAODBTagging/BTaggingContainer.h"
Include dependency graph for TrigBjetMonitorAlgorithm.cxx:

Go to the source code of this file.

Functions

bool LLR (double pu, double pc, double pb, double &w)
 
bool LLRW (float pqcd, float ptop, float phbb, float &w)
 
bool CalcRelPt (float muonPt, float muonEta, float muonPhi, float jetPt, float jetEta, float jetPhi, float &RelPt)
 
float phiCorr (float phi)
 

Function Documentation

◆ CalcRelPt()

bool CalcRelPt ( float  muonPt,
float  muonEta,
float  muonPhi,
float  jetPt,
float  jetEta,
float  jetPhi,
float &  RelPt 
)

Definition at line 64 of file TrigBjetMonitorAlgorithm.cxx.

64  {
65 
66  bool r = false;
67  RelPt = -20.;
68 
69  float muonT, muonX, muonY, muonZ, muon, jetT, jetX, jetY, jetZ, jet, scprod;
70 
71  muonT = 2.*atan( exp(-muonEta) );
72  jetT = 2.*atan( exp(-jetEta) );
73  if ( (std::abs(muonT) > 0.) && (std::abs(jetT) > 0.) ) {
74  muon = muonPt/std::abs( sin(muonT) );
75  muonX = muonPt*cos(muonPhi);
76  muonY = muonPt*sin(muonPhi);
77  muonZ = muon*cos(muonT);
78  jet = jetPt/std::abs( sin(jetT) );
79  jetX = jetPt*cos(jetPhi);
80  jetY = jetPt*sin(jetPhi);
81  jetZ = jet*cos(jetT);
82  scprod = (muonX*jetX + muonY*jetY + muonZ*jetZ)/(muon*jet);
83  scprod *= scprod;
84  if ( (1. - scprod) > 0. ) {
85  RelPt = muon * sqrt(1. - scprod);
86  r = true;
87  }
88  }
89 
90  return r;
91 
92 }

◆ LLR()

bool LLR ( double  pu,
double  pc,
double  pb,
double &  w 
)

Definition at line 33 of file TrigBjetMonitorAlgorithm.cxx.

33  {
34  w = -100.;
35  bool ll = false;
36  double denom;
37  float cfrac(0.018); // DG 2022/07/28
38  if (pb > 0.) {
39  denom = pu*(1.-cfrac)+pc*cfrac;
40  if (denom > 0.) {
41  w = log(pb/denom);
42  ll = true;
43  }
44  }
45  return ll;
46 }

◆ LLRW()

bool LLRW ( float  pqcd,
float  ptop,
float  phbb,
float &  w 
)

Definition at line 48 of file TrigBjetMonitorAlgorithm.cxx.

48  { // RJ 17/02/2025
49  w = -100.;
50  bool ll = false;
51  float denom;
52  float topfrac(0.25);
53  if (phbb > 0.) {
54  denom = pqcd*(1.-topfrac)+ptop*topfrac;
55  if (denom > 0.) {
56  w = log(phbb/denom);
57  ll = true;
58  }
59  }
60  return ll;
61 }

◆ phiCorr()

float phiCorr ( float  phi)

Definition at line 94 of file TrigBjetMonitorAlgorithm.cxx.

94  {
95  if (phi < -M_PI) phi += 2*M_PI;
96  if (phi > M_PI) phi -= 2*M_PI;
97  return phi;
98 }
beamspotman.r
def r
Definition: beamspotman.py:672
xAOD::muon
@ muon
Definition: TrackingPrimitives.h:196
phi
Scalar phi() const
phi method
Definition: AmgMatrixBasePlugin.h:67
detail::ll
long long ll
Definition: PrimitiveHelpers.h:47
keylayer_zslicemap.pb
pb
Definition: keylayer_zslicemap.py:188
M_PI
#define M_PI
Definition: ActiveFraction.h:11
drawFromPickle.cos
cos
Definition: drawFromPickle.py:36
drawFromPickle.exp
exp
Definition: drawFromPickle.py:36
drawFromPickle.atan
atan
Definition: drawFromPickle.py:36
jet
Definition: JetCalibTools_PlotJESFactors.cxx:23
compute_lumi.denom
denom
Definition: compute_lumi.py:76
CheckAppliedSFs.pu
pu
Definition: CheckAppliedSFs.py:311
python.CaloCondTools.log
log
Definition: CaloCondTools.py:20
drawFromPickle.sin
sin
Definition: drawFromPickle.py:36
python.IoTestsLib.w
def w
Definition: IoTestsLib.py:198
python.SystemOfUnits.pc
float pc
Definition: SystemOfUnits.py:114