StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
EvtTwoBodyKine.hh
1 /*******************************************************************************
2  * Project: BaBar detector at the SLAC PEP-II B-factory
3  * Package: EvtGenBase
4  * File: $Id: EvtTwoBodyKine.hh,v 1.1 2016/09/23 18:37:33 jwebb Exp $
5  * Author: Alexei Dvoretskii, dvoretsk@slac.stanford.edu, 2001-2002
6  *
7  * Copyright (C) 2002 Caltech
8  *******************************************************************************/
9 
10 // Descriptions of the kinematics of a two-body decay.
11 
12 #ifndef EVT_TWO_BODY_KINE_HH
13 #define EVT_TWO_BODY_KINE_HH
14 
15 #include <iostream>
16 
18 
19 public:
20 
21  enum Index {A,B,AB};
22 
24  EvtTwoBodyKine(double mA, double mB, double mAB);
25  EvtTwoBodyKine(const EvtTwoBodyKine& other);
26  ~EvtTwoBodyKine();
27 
28  // Accessors
29 
30  inline double mA() const { return _mA; }
31  inline double mB() const { return _mB; }
32  inline double mAB() const { return _mAB; }
33  double m(Index i) const;
34 
35  // Momentum of the other two particles in the
36  // rest-frame of particle i.
37 
38  double p(Index i = AB) const;
39 
40  // Energy of particle i in the rest frame of particle j
41 
42  double e(Index i, Index j) const;
43 
44  void print(std::ostream& os) const;
45 
46 private:
47 
48  double _mA;
49  double _mB;
50  double _mAB;
51 };
52 
53 std::ostream& operator<<(std::ostream& os, const EvtTwoBodyKine& p);
54 
55 #endif