3 // Author: Uli Frankenfeld <mailto:franken@fi.uib.no>
4 //*-- Copyright © ALICE HLT Group
6 #include "AliHLTTPCStandardIncludes.h"
8 #include "AliHLTTPCLogging.h"
9 #include "AliHLTTPCVertexArray.h"
10 #include "AliHLTTPCVertex.h"
11 #include "AliHLTTPCVertexFinder.h"
12 #include "AliHLTTPCSpacePointData.h"
13 #include "AliHLTTPCTransform.h"
15 /** \class AliHLTTPCVertexFinder
17 //_____________________________________________________________
18 // AliHLTTPCVertexFinder
20 // Implementation of AliHLTTPCArray
24 // for(n=0;n<NMEMSEC;n++)
26 // FindSectorVertex();
27 // SetZ(GetZSector());
28 // SetZErr(GetZErrSector());
34 ClassImp(AliHLTTPCVertexFinder)
35 AliHLTTPCVertexFinder::AliHLTTPCVertexFinder(){
37 // default constructor for the AliHLTTPCVertexFinder class.
54 AliHLTTPCVertexFinder::~AliHLTTPCVertexFinder(){
60 void AliHLTTPCVertexFinder::Reset(){
65 void AliHLTTPCVertexFinder::Read(Int_t ncluster, AliHLTTPCSpacePointData* hits ){
70 const Int_t seedRow = AliHLTTPCTransform::GetNRows() - 1;
71 const Int_t firstRow = seedRow-32;
72 for(Int_t n=0;n<ncluster;n++){
73 if(hits[n].fPadRow==seedRow)
74 FillSectorSeed3D(hits[n].fX,hits[n].fY,hits[n].fZ); //copy seeds in 3D
75 if(hits[n].fPadRow<=seedRow && hits[n].fPadRow>=firstRow)
76 FillSector3D(hits[n].fX,hits[n].fY,hits[n].fZ); //copy data in 3D
80 void AliHLTTPCVertexFinder::Analyze(){
83 SetZErr(GetZSectorErr());
84 LOG(AliHLTTPCLog::kInformational,"AliHLTTPCVertexFinder::Analyze","Result")
85 <<AliHLTTPCLog::kDec<<"Vertex: "<<GetZ()<<" RMS: "<<GetZErr()<<ENDLOG;
88 void AliHLTTPCVertexFinder::Write(AliHLTTPCVertex *vertex){
92 vertex->SetXErr(GetXErr());
93 vertex->SetYErr(GetYErr());
94 vertex->SetZErr(GetZErr());
96 vertex->SetXYWeight(GetXYWeight());
99 void AliHLTTPCVertexFinder::Write(AliHLTTPCVertexData *vertex){
103 vertex->fXErr=GetXErr();
104 vertex->fYErr=GetYErr();
105 vertex->fZErr=GetZErr();