CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Functions
reco::helper::VirtualJetProducerHelper Namespace Reference

Functions

double intersection (double r12)
 
double intersection (double r12, double r23, double r13)
 

Function Documentation

double reco::helper::VirtualJetProducerHelper::intersection ( double  r12)

Definition at line 6 of file VirtualJetProducerHelper.cc.

References M_PI, and mathSSE::sqrt().

Referenced by BeautifulSoup.BeautifulStoneSoup::endData(), intersection(), edm::serviceregistry::ServicesManager::ServicesManager(), and VirtualJetProducer::writeJets().

7 {
8  if (r12 == 0) return M_PI;
9  if (r12 >= 2) return 0;
10  return 2 * acos(r12/2) - 0.5*r12*sqrt(4 - r12*r12);
11 }
T sqrt(T t)
Definition: SSEVec.h:48
#define M_PI
Definition: BFit3D.cc:3
double reco::helper::VirtualJetProducerHelper::intersection ( double  r12,
double  r23,
double  r13 
)

Definition at line 13 of file VirtualJetProducerHelper.cc.

References intersection(), M_PI, mathSSE::sqrt(), and groupFilesInBlocks::temp.

14 {
15  if (r12 >= 2 || r23 >= 2 || r13 >= 2) return 0;
16  const double r12_2 = r12*r12;
17  const double r13_2 = r13*r13;
18  const double temp = (r12_2 + r13_2 - r23*r23);
19  const double T2 = 4*r12_2*r13_2 - temp*temp;
20  const double common = 0.5*( intersection(r12) + intersection(r13) + intersection(r23) - M_PI + sqrt(T2)/2 );
21  return common;
22 }
T sqrt(T t)
Definition: SSEVec.h:48
#define M_PI
Definition: BFit3D.cc:3