MpdVertexZfinder.h 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. #ifndef MPD_VERTEXZFINDER_H
  2. #define MPD_VERTEXZFINDER_H
  3. #include "FairTask.h"
  4. #include "TH1.h"
  5. #include "TF1.h"
  6. #include "TClonesArray.h"
  7. class MpdVertexZfinder :public FairTask
  8. {
  9. public:
  10. /** Constructor **/
  11. MpdVertexZfinder(const char *name="MpdVertexZfinder", Int_t iVerbose = 1);
  12. /** Destructor **/
  13. virtual ~MpdVertexZfinder();
  14. /// * FairTask methods
  15. /** Intialisation at begin of run. To be implemented in the derived class.
  16. *@value Success If not kSUCCESS, task will be set inactive.
  17. **/
  18. InitStatus Init();
  19. /** Reinitialisation.
  20. *@value Success If not kSUCCESS, task will be set inactive.
  21. **/
  22. InitStatus ReInit();
  23. /** Intialise parameter containers.
  24. **/
  25. void SetParContainers();
  26. void Exec(Option_t * option);
  27. /** Action after each event. **/
  28. void Finish();
  29. void Reset();
  30. void SetHits(const TClonesArray *hits, const TH1F *hLays); // set hits container and histo
  31. Double_t FindZ(const Int_t *layPointers, Int_t &flag); // evaluate vertex Z-position
  32. private:
  33. TH1F *fhZ; // histogram of Z-positions
  34. const TH1F *fhLays; // histogram of layer occupancy
  35. const TClonesArray *fKHits; // array of Kalman hits
  36. TF1 *fUnc; // fitting function
  37. private:
  38. // Some constants
  39. //static const Double_t fgkChi2Cut; // max accepted Chi2 of hit for track
  40. ClassDef(MpdVertexZfinder,1);
  41. };
  42. #endif