1 ////////////////////////////////////////////////////////////////////////////////
3 // AliFemtoCutMonitorParticleYPt - the cut monitor for particles to study //
4 // the difference between reconstructed and true momentum //
6 ////////////////////////////////////////////////////////////////////////////////
9 #include "AliFemtoCutMonitorParticleYPt.h"
10 #include "AliFemtoModelHiddenInfo.h"
12 AliFemtoCutMonitorParticleYPt::AliFemtoCutMonitorParticleYPt():
16 // Default constructor
17 fYPt = new TH2D("YPt", "Rapidity vs Pt", 100, -1.0, 1.0, 100, 0.1, 2.0);
20 AliFemtoCutMonitorParticleYPt::AliFemtoCutMonitorParticleYPt(const char *aName, float aMass):
26 snprintf(name, 200, "YPt%s", aName);
27 fYPt = new TH2D(name, "Rapdity vs Pt", 100, -1.0, 1.0, 100, 0.1, 2.0);
30 AliFemtoCutMonitorParticleYPt::AliFemtoCutMonitorParticleYPt(const AliFemtoCutMonitorParticleYPt &aCut):
35 if (fYPt) delete fYPt;
36 fYPt = new TH2D(*aCut.fYPt);
40 AliFemtoCutMonitorParticleYPt::~AliFemtoCutMonitorParticleYPt()
46 AliFemtoCutMonitorParticleYPt& AliFemtoCutMonitorParticleYPt::operator=(const AliFemtoCutMonitorParticleYPt& aCut)
48 // assignment operator
52 if (fYPt) delete fYPt;
53 fYPt = new TH2D(*aCut.fYPt);
58 AliFemtoString AliFemtoCutMonitorParticleYPt::Report(){
59 // Prepare report from the execution
60 string stemp = "*** AliFemtoCutMonitorParticleYPt report";
61 AliFemtoString returnThis = stemp;
65 void AliFemtoCutMonitorParticleYPt::Fill(const AliFemtoTrack* aTrack)
67 // Fill in the monitor histograms with the values from the current track
68 float tEnergy = ::sqrt(aTrack->P().mag2()+fMass*fMass);
69 float tRapidity = 0.5*::log((tEnergy+aTrack->P().z())/(tEnergy-aTrack->P().z()));
70 float tPt = ::sqrt((aTrack->P().x())*(aTrack->P().x())+(aTrack->P().y())*(aTrack->P().y()));
71 fYPt->Fill(tRapidity, tPt);
74 void AliFemtoCutMonitorParticleYPt::Write()
76 // Write out the relevant histograms