|
ATLAS Offline Software
|
Go to the documentation of this file.
20 int dphiB = std::abs( tob1->
phi() - tob2->
phi() );
30 double deta = std::abs( tob1->
eta() - tob2->
eta() );
38 int phi_tob1 = tob1->
phi();
39 int phi_tob2 = tob2->
phi();
41 if ( std::abs(phi_tob1-phi_tob2)>=64 )
43 if(phi_tob1 >= 32) phi_tob1 = phi_tob1-64;
44 if(phi_tob2 >= 32) phi_tob2 = phi_tob2-64;
49 auto bit_invmass2 = bit_Et1*bit_Et2*(bit_cosheta - bit_cosphi)*2;
50 return static_cast<unsigned>(bit_invmass2) ;
58 return static_cast<unsigned>(bit_tmass2) ;
63 int detaB = std::abs( tob1->
eta() - tob2->
eta() );
64 int dphiB = std::abs( tob1->
phi() - tob2->
phi() );
70 unsigned int bit_dr2 = dphiB*dphiB + detaB*detaB;
83 int dphiB = std::abs( tob1->
phi() - tob2->
phi() );
93 double deta = std::abs( tob1->
eta() - tob2->
eta() );
102 int phi_tob1 = tob1->
phi();
103 int phi_tob2 = tob2->
phi();
104 if ( std::abs(phi_tob1-phi_tob2)>=128 )
106 if(phi_tob1 >= 64) phi_tob1 = phi_tob1-128;
107 if(phi_tob2 >= 64) phi_tob2 = phi_tob2-128;
112 auto bit_invmass2 = bit_Et1*bit_Et2*(bit_cosheta - bit_cosphi)*2;
114 auto u_invmass2 =
static_cast<unsigned long long>(bit_invmass2);
127 return static_cast<unsigned>(bit_tmass2) ;
132 int detaB = std::abs( tob1->
eta() - tob2->
eta() );
133 int dphiB = std::abs( tob1->
phi() - tob2->
phi() );
142 unsigned int bit_dr2 = dphiB*dphiB + detaB*detaB;
147 unsigned int ui1 = i1, ui2=i2;
148 unsigned int a = ui1*ui1 + ui2*ui2;
158 unsigned int bitmask = 0b11111111111111111111111111111111;
159 bitmask >>= (32 - halflength*2);
161 for(
int i = 0;
i < halflength;
i++){
163 left = (
r<<2) + (
a >> (2*halflength-2));
166 r =
sign ? (left + right) : (left - right);
167 sign = ((
r & (1 << (halflength+1) )) > 0) ? 1 : 0;
183 auto xi_bit = bit_Et1*bit_eeta1+bit_Et2*bit_eeta2;
185 return static_cast<unsigned>(xi_bit);
194 auto xi_bit = bit_Et1*bit_eeta1+bit_Et2*bit_eeta2;
196 return static_cast<unsigned>(xi_bit);
212 dphi = 2*
M_PI - dphi;
214 return round( 10 * dphi );
219 return round( 10 * deta );
226 dphi = 2*
M_PI - dphi;
228 return round ( 100 * ((dphi)*(dphi) + (deta)*(deta) )) ;
234 dphi = 2*
M_PI - dphi;
236 return round( 20 * dphi );
241 return round( 40 * deta );
248 dphi = 2*
M_PI - dphi;
250 double cosheta = cosh ( deta);
251 double cosphi =
cos ( dphi);
252 double invmass2 = 2*tob1->
Et()*tob2->
Et()*(cosheta - cosphi);
253 return round( invmass2 );
259 dphi = 2*
M_PI - dphi;
261 double cosphi =
cos ( dphi);
262 double tmass2 = 2*tob1->
Et()*tob2->
Et()*(1 - cosphi);
263 return round( tmass2 );
270 dphi = 2*
M_PI - dphi;
273 return round ( 40*40 * ((dphi)*(dphi) + (deta)*(deta) )) ;
static unsigned int calcTMassBW(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2)
static const std::vector< std::string > Cosh
static unsigned int calcDeltaR2BWLegacy(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2)
static unsigned int calcInvMass(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2)
static unsigned int calcTMass(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2)
static unsigned int calcDeltaPhiBW(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2)
static const std::vector< std::string > Sin
float round(const float toRound, const unsigned int decimals)
static float calcCos(unsigned phi)
static unsigned int calcDeltaPhi(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2)
static unsigned int calcInvMassBWLegacy(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2)
static unsigned int calcDeltaEtaBWLegacy(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2)
static unsigned int calcDeltaR2BW(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2)
static unsigned int calcXi1(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2, unsigned ptShift, unsigned ptScale)
static unsigned int calcDeltaEtaBW(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2)
static unsigned int calcDeltaR2Legacy(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2)
static unsigned int calcXi2(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2, unsigned ptShift, unsigned ptScale)
static unsigned int calcDeltaR2(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2)
static unsigned int calcDeltaPhiBWLegacy(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2)
static float calcSinLegacy(unsigned phi)
static unsigned int calcDeltaEtaLegacy(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2)
static unsigned int calcInvMassBW(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2)
static unsigned long quadraticSumBW(int i1, int i2)
compute the sum in quadrature of two ints
static unsigned int calcDeltaPhiLegacy(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2)
static const std::unordered_map< int, std::string > E
static const std::vector< std::string > Cosleg
static const std::vector< std::string > Sinleg
static float calcCosLegacy(unsigned phi)
static unsigned int calcTMassBWLegacy(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2)
static unsigned int calcDeltaEta(const TCS::GenericTOB *tob1, const TCS::GenericTOB *tob2)
static const std::vector< std::string > Cos
static const std::vector< std::string > Coshleg
static float calcSin(unsigned phi)