]> git.uio.no Git - u/mrichter/AliRoot.git/blame - STEER/AliKFVertex.h
A macro to test the secondary vertex package (S.Gorbunov, I.Kisel)
[u/mrichter/AliRoot.git] / STEER / AliKFVertex.h
CommitLineData
f826d409 1//---------------------------------------------------------------------------------
2// The AliKFVertex class
3// .
4// @author S.Gorbunov, I.Kisel
5// @version 1.0
6// @since 13.05.07
7//
8// Class to reconstruct and store primary and secondary vertices.
9// The method is described in CBM-SOFT note 2007-003,
10// ``Reconstruction of decayed particles based on the Kalman filter'',
11// http://www.gsi.de/documents/DOC-2007-May-14-1.pdf
12//
13// This class is ALICE interface to general mathematics in AliKFParticleBase
14//
15// -= Copyright &copy ALICE HLT Group =-
16//_________________________________________________________________________________
17
18#ifndef ALIKFVERTEX_H
19#define ALIKFVERTEX_H
20
21#include "AliKFParticle.h"
22#include "AliESDVertex.h"
23
24
25class AliKFVertex :public AliKFParticle
26{
27
28 public:
29
30 //*
31 //* INITIALIZATION
32 //*
33
34 //* Constructor (empty)
35
36 AliKFVertex():AliKFParticle(){}
37
38 //* Destructor (empty)
39
40 ~AliKFVertex(){}
41
42 //* Initialisation from ESD vertex
43
44 AliKFVertex( const AliESDVertex &vertex );
45
46 //* Copy vertex part to ESD vertex
47
48 void CopyToESDVertex( AliESDVertex &Vtx ) const ;
49
50
51 //*
52 //* CONSTRUCTION OF THE VERTEX BY ITS DAUGHTERS
53 //* USING THE KALMAN FILTER METHOD
54 //*
55
56
f826d409 57
58 //* Subtract particle from vertex
59
60 AliKFVertex operator -( const AliKFParticle &Daughter ) const;
61
62 void operator -=( const AliKFParticle &Daughter );
63
64 //* Construct vertex with selection of tracks (primary vertex)
65
66 void ConstructPrimaryVertex( const AliKFParticle *vDaughters[], int NDaughters,
67 Double_t ChiCut=3.5 );
68
3e90f604 69private:
70
71 //* Simple way to construct vertices ex. D0 = Pion + Kaon - NOT IMPLEMENTED
72
73 AliKFParticle operator +( const AliKFParticle &Daughter ) const;
74
75 void operator +=( const AliKFParticle &Daughter );
76
f826d409 77 ClassDef( AliKFVertex, 1 );
78
79};
80
81
82
83//---------------------------------------------------------------------
84//
85// Inline implementation of the AliKFVertex methods
86//
87//---------------------------------------------------------------------
88
89inline void AliKFVertex::CopyToESDVertex( AliESDVertex &v ) const
90{
91 AliKFVertex vTmp=*this;
92 v = AliESDVertex( vTmp.fP, vTmp.fC, vTmp.fChi2, (vTmp.fNDF +3)/2 );
93}
94
95
96inline void AliKFVertex::operator -=( const AliKFParticle &Daughter )
97{
98 Daughter.SubtractFromVertex( *this );
99}
100
101inline AliKFVertex AliKFVertex::operator -( const AliKFParticle &Daughter ) const
102{
103 AliKFVertex tmp = *this;
104 Daughter.SubtractFromVertex( tmp );
105 return tmp;
106}
107
108
109#endif