AmpGen 2.1
Loading...
Searching...
No Matches
RecursivePhaseSpace.h
Go to the documentation of this file.
1#ifndef AMPGEN_RECURSIVEPHASESPACE_H
2#define AMPGEN_RECURSIVEPHASESPACE_H
3
4#include <memory.h>
5#include <stddef.h>
6#include <algorithm>
7#include <memory>
8#include <ostream>
9#include <string>
10#include <vector>
11#include <utility>
12
13#include "AmpGen/EventType.h"
14#include "AmpGen/PhaseSpace.h"
15
16#include <TRandom3.h>
17
18class TRandom;
19
20namespace AmpGen
21{
22 class Particle;
23 class Event;
34 {
35 private:
36 struct Node
37 {
38 std::string name = {""};
39 int sink = {-1};
40 std::shared_ptr<RecursivePhaseSpace> decayProds = {nullptr};
41 explicit Node( const std::string& _name ) : name( _name ) {};
42 };
43 public:
44 explicit RecursivePhaseSpace(const EventType& type);
45 RecursivePhaseSpace(const Particle& decayChain, const EventType& type, TRandom* rndm = gRandom);
46 std::vector<Node*> getFinalStates();
47
48 void print( const size_t& offset = 0 ) const;
49 void setRandom( TRandom* rand );
51 size_t size() const;
53 void debug( const Event& /*event*/ ) {};
54 private:
55 PhaseSpace m_phsp;
56 unsigned m_totalSize = {0};
57 std::string m_name = {""};
58 EventType m_eventType;
59 std::vector<Node> m_nodes;
60 };
61} // namespace AmpGen
62
63#endif
Encapsulates the final state particles of a single event.
Definition Event.h:18
Deals with final state configuration of events, specifically dealing with the ordering of particles i...
Definition EventType.h:22
Describes a particle, its decay process and subsequent decay products, which are also Particles.
Definition Particle.h:103
Phase-space generator taken from the ROOT routine, from Rene Brun and Valerio Filippini,...
Definition PhaseSpace.h:24
RecursivePhaseSpace(const EventType &type)
void print(const size_t &offset=0) const
EventType eventType() const
std::vector< Node * > getFinalStates()
RecursivePhaseSpace(const Particle &decayChain, const EventType &type, TRandom *rndm=gRandom)
void setRandom(TRandom *rand)