fmcQvector.h 582 B

123456789101112131415161718192021222324252627282930
  1. #ifndef FMC_QVECTOR_H
  2. #define FMC_QVECTOR_H
  3. #include <TROOT.h>
  4. #include <TMath.h>
  5. #include <TVector2.h>
  6. #include "fmcTypes.h"
  7. class fmcQvector : public TVector2
  8. {
  9. private:
  10. fmcDouble fHarm;
  11. public:
  12. fmcQvector();
  13. virtual ~fmcQvector();
  14. // Setters
  15. virtual void SetHarmonic(fmcDouble h) { fHarm = h; }
  16. // Getters
  17. fmcDouble GetX() { return (fmcDouble) X(); }
  18. fmcDouble GetY() { return (fmcDouble) Y(); }
  19. fmcDouble GetHarmonic() { return fHarm; }
  20. fmcDouble GetPhi() { return TMath::ATan2(fY,fX)/fHarm; }
  21. ClassDef(fmcQvector,0);
  22. };
  23. #endif