PhotosBranch.h
1 #ifndef _PhotosBranch_h_included_
2 #define _PhotosBranch_h_included_
3 
4 /**
5  * @class PhotosBranch
6  *
7  * @brief Single branching point
8  *
9  * Contains information about daughters and mothers of a single branch.
10  * Each branch will be converted to HEPEVT and processed by photos.
11  *
12  * @author Tomasz Przedzinski
13  * @date 8 July 2010
14  */
15 
16 #include <vector>
17 #include "PhotosParticle.h"
18 using std::vector;
19 
20 namespace Photospp
21 {
22 
24 {
25 public:
26  /** Create branch out of decaying particle */
28 
29  /** Return decaying particle. NULL if branching does not have mid-particle */
31 
32  /** Get list of mothers */
33  vector<PhotosParticle *> getMothers() { return mothers; }
34 
35  /** Get list of daughters */
36  vector<PhotosParticle *> getDaughters() { return daughters; }
37 
38  /** Get list of all particles used by branch */
39  vector<PhotosParticle *> getParticles();
40 
41  /** Check if branch is suppressed */
43 
44  /** Check if branch is forced */
45  int getForcingStatus() { return forcing; }
46 
47  /** Checks momentum conservation of decaying particle.
48  If it does not exist, checks momentum of first mother passed to photos */
50 
51  /** Process single branch */
52  void process();
53 
54  /** Create branches from particles list */
55  static vector<PhotosBranch *> createBranches(vector<PhotosParticle *> particles);
56 private:
57  /** Checks if branching is suppressed by PHOTOS. */
58  int checkSuppressionLevel() { return checkList(false); }
59 
60  /** Checks if branching is forced by PHOTOS. */
61  int checkForcingLevel() { return checkList(true); }
62 
63  /** Algorithm used for suppression/forcing check */
64  int checkList(bool forceOrSuppress);
65 private:
66  /** State of branching suppression*/
68  /** State of branching forcing*/
69  int forcing;
70  /** Decaying particle */
72  /** List of mothers */
73  vector<PhotosParticle *> mothers;
74  /** List of daughters */
75  vector<PhotosParticle *> daughters;
76 };
77 
78 } // namespace Photospp
79 #endif
vector< PhotosParticle * > getMothers()
Definition: PhotosBranch.h:33
vector< PhotosParticle * > getDaughters()
Definition: PhotosBranch.h:36
int checkList(bool forceOrSuppress)
vector< PhotosParticle * > daughters
Definition: PhotosBranch.h:75
PhotosParticle * particle
Definition: PhotosBranch.h:71
vector< PhotosParticle * > mothers
Definition: PhotosBranch.h:73
PhotosParticle * getDecayingParticle()
Definition: PhotosBranch.h:30
static vector< PhotosBranch * > createBranches(vector< PhotosParticle * > particles)
PhotosBranch(PhotosParticle *p)
vector< PhotosParticle * > getParticles()