#include "hhyplistfiller.h" |
HHypListFiller
class description - source file - inheritance tree (.pdf)
private:
void create_pid_table()
Bool_t fill_pid_fprob(HHypComb* hypcomb, Int_t* numpidtracks)
void fill_pid_idx(HHypComb* hypcomb)
void fill_pid_table(HHypComb* hypcomb)
Bool_t FindNextPermutation(Int_t* array, Int_t count)
Bool_t generateNumberOfCombinations()
void PermReverser(Int_t* array, Int_t a, Int_t b)
void PermSwapper(Int_t* array, Int_t a, Int_t b)
void remove_fakes_pid_table()
public:
HHypListFiller()
HHypListFiller(Text_t* name, Text_t* title)
~HHypListFiller()
Bool_t AddTrack(Int_t particle)
static TClass* Class()
virtual Int_t execute()
virtual Bool_t finalize()
virtual Bool_t init()
virtual TClass* IsA() const
void setContCatComb(HCategory* pContCat)
void setContCatList(HCategory* pContCat)
Bool_t SetExitList(Int_t e_list)
virtual void ShowMembers(TMemberInspector& insp, char* parent)
virtual void Streamer(TBuffer& b)
void StreamerNVirtual(TBuffer& b)
private:
Int_t exitList
Int_t nPlus
Int_t nMinus
Int_t numberOfParticles Total Number of Particles including Fakes
Int_t nPlusReal
Int_t nMinusReal
Int_t numberOfRealParticles Number of REAL Particles (without Fakes)
Int_t numberOfCombinations
Int_t numberOfNegCombinations
Int_t numberOfPosCombinations
Int_t** pid_real_array only real particles
Int_t** pid_full_array real and fake particles
TArrayI particleArrayPlus
TArrayI particleArrayMinus
HCategory* m_pContCatList !Pointer to the hit data category HHypList
HCategory* m_pContCatComb !Pointer to the hit data category HHypComb
HCategory* m_pContCatPart !Pointer to the hit data category HPidPArticle
HIterator* m_pContItPart !Pointer to the hit data category HPidPArticle
HHypListFiller
HypListFiller is creating a permutated list for all particle types
which are needed for the Algorithm. This list is created once at
init time and then copied to HypComp for every event on execute.
HHypListFiller(Text_t * name, Text_t * title):
HReconstructor(name, title)
HHypListFiller()
~HHypListFiller(void)
Bool_t SetExitList(Int_t e_list)
Bool_t init()
Before init is called, all the tracks need to be added.
Next the number of possible combinations is computed and a pid
table with all permutaions is created. Next steps done are to init
HypComb, HypList and PidParticle Containers
Int_t execute()
Bool_t finalize()
cout<<" n\nn HHypListFiller::finalize() n\n";
Bool_t AddTrack(Int_t particle)
Adds a particle type track to filler
must be done before init is called
Bool_t generateNumberOfCombinations()
computes number of combinations and number of pos/neg particle combination
This function is normally called by init.
Mathematics (Bronstein ;-)):
Permutation of n elements in m groups with k1 to km elements each
P=n! / ( k1! * k2! *...* km! )
this is true for positive and negative independently
-> everything is done for positive AND negativ particles
the following things happen here:
1) sort positive and negative particle IDs
-> now every "difference" between two particles is one additional type
2) now k1! * k2! ... is calculated
-> if particle type changes, loop-last_index is k1, next is k2... last is km
3) result is produkt of ks
3) from these differences calculate number of combinations allcombination/doubles
4) numberofcombinations is numberofpositive times numberofnegative
void PermSwapper(Int_t * array, Int_t a, Int_t b)
Swap array-values for indizes a,b
only used for permutations by FindNextPermutation
and PermReverser
void PermReverser(Int_t * array, Int_t a, Int_t b)
Swap array-values from indizes a to b, meaning [a]<->[b] [a-1]<->[b-1] ...
a MUST be smaller or equal than b or nothing will be done
only used for permutations by FindNextPermutation
Bool_t FindNextPermutation(Int_t * array, Int_t count)
Finds next permution of array. perms are deivered in right order
starting from 11223 to 32211. If last one is reached, return false
for the first call, array values MUST be in the right order!!!
This is done by init() -> generateNumberOfCombinations
Array values can be ANY number... negativ, 0, 1, 9999... dont care about this
void create_pid_table(void)
This function create all possible permutation for the given
particles and stores it into pid_array, which is then copied
to hypcomb for every event by fill_pid_table.
number of possible combinations must be calculated before by
generateNumberOfCombinations ...
function is normally called by init
void remove_fakes_pid_table(void)
void fill_pid_table(HHypComb * hypcomb)
void fill_pid_idx(HHypComb * hypcomb)
Bool_t fill_pid_fprob(HHypComb * hypcomb,Int_t *numpidtracks)
Inline Functions
void setContCatList(HCategory* pContCat)
void setContCatComb(HCategory* pContCat)
TClass* Class()
TClass* IsA() const
void ShowMembers(TMemberInspector& insp, char* parent)
void Streamer(TBuffer& b)
void StreamerNVirtual(TBuffer& b)
Last update: Fri Jan 26 11:56:53 2007
ROOT page - Class index - Class Hierarchy - Top of the page
This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.