]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Merge revs 30349 and 30378 from the EVE-root-trunk branch - they were committed there...
authormtadel <mtadel@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 11 Dec 2008 22:33:37 +0000 (22:33 +0000)
committermtadel <mtadel@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 11 Dec 2008 22:33:37 +0000 (22:33 +0000)
EVE/EveBase/AliEveV0.cxx
EVE/EveBase/AliEveV0.h
EVE/EveBase/AliEveV0Editor.cxx
EVE/macros/anyscan_init.C

index fcdd140885d2b42aac85e1181016e1e9f83b6d78..1fbad9b31aea07659a8085ea2972d16a8f2df924 100644 (file)
@@ -17,6 +17,9 @@
 #include <TPolyMarker3D.h>
 #include <TColor.h>
 
+#include <TDatabasePDG.h>
+#include <TParticlePDG.h>
+
 #include <vector>
 
 
@@ -106,6 +109,24 @@ AliEveV0::~AliEveV0()
   fPointingLine->DecDenyDestroy();
 }
 
+//______________________________________________________________________________
+Float_t AliEveV0::GetInvMass(Float_t nPdgCode, Float_t pPdgCode) const
+{
+  // Returns Invariant Mass assuming the masses of the daughter particles
+  TEveVector lNegMomentum = fNegTrack->GetMomentum();
+  // Does not work properly because momenta at the primary vertex !!!!!!!
+  TEveVector lPosMomentum = fPosTrack->GetMomentum();
+  Double_t nMass=TDatabasePDG::Instance()->GetParticle(nPdgCode)->Mass();
+  Double_t pMass=TDatabasePDG::Instance()->GetParticle(pPdgCode)->Mass();
+
+  printf("\n check the mass of the particle negative %.5f positive %.5f \n",nMass,pMass);
+
+  Double_t eNeg = TMath::Sqrt(nMass*nMass + lNegMomentum.Mag2());
+  Double_t ePos = TMath::Sqrt(pMass*pMass + lPosMomentum.Mag2());
+
+  return TMath::Sqrt( (eNeg+ePos)*(eNeg+ePos) - fRecDecayP.Mag2() );
+}
+
 //______________________________________________________________________________
 void AliEveV0::MakeV0()
 {
index eb61fcfe00105254167da8e23c59bea3419dd856..be70c02c370d59e6d1ba3781f76893aad4a947d3 100644 (file)
@@ -26,6 +26,8 @@
 #include <TPolyMarker3D.h>
 #include <TPolyLine3D.h>
 
+#include <TPDGCode.h>
+
 class TH1F;
 class TH2F;
 
@@ -59,6 +61,11 @@ public:
   Float_t GetRadius() const { return fRecDecayV.Perp(); }
   Float_t GetPt()     const { return fRecDecayP.Perp(); }
 
+  Float_t GetInvMass(Float_t nPdgCode, Float_t pPdgCode) const;
+  Float_t GetK0sInvMass() const { return GetInvMass(kPiMinus,kPiPlus); }
+  Float_t GetLambdaInvMass() const { return GetInvMass(kPiMinus,kProton); }
+  Float_t GetAntiLambdaInvMass() const { return GetInvMass(kProton,kPiPlus); }
+
   Bool_t GetOnFlyStatus()    const { return fOnFlyStatus; }
   void   SetOnFlyStatus(Bool_t fs) { fOnFlyStatus = fs; }
 
index 3dbb159787bd18b4cc009d0e45596dab9ffb1304..38a8c90989740eebce3d2ffc6ba22279647ab8ea 100644 (file)
@@ -96,7 +96,7 @@ void AliEveV0Editor::SetModel(TObject* obj)
 
 void AliEveV0Editor::DisplayDetailed()
 {
-  printf("Hura!\n");
+  printf("\n Checking invariant mass calculations: K0s %.3f lambda %.3f antilambda %.3f \n",fM->GetK0sInvMass(),fM->GetLambdaInvMass(),fM->GetAntiLambdaInvMass());
 
   TEveWindowSlot *slot = TEveWindow::CreateWindowMainFrame();
   TEveWindowPack *pack = slot->MakePack();
@@ -119,7 +119,8 @@ void AliEveV0Editor::DisplayDetailed()
   TEveWindowFrame *frame = slot->MakeFrame(new TRootEmbeddedCanvas());
   frame->SetElementName("Details");
 
-  TLatex* ltx = new TLatex(0.2, 0.2, "#frac{Jacques}{Zoozoo}");
+  TLatex* ltx = new TLatex(0.2, 0.2, "#eta = #frac{1}{2} #times Ln(#frac{E+p_{z}}{E-p_{z}} )");
+  ltx->SetTextSize(0.08);
   ltx->Draw();
 
   gEve->Redraw3D();
index 90d386825bdad43b430fdf28cacd9582f997ee5f..69741a2fb91b68f5c8ccc7d417871e4c38420d5b 100644 (file)
@@ -78,6 +78,7 @@ void anyscan_init()
 
   gRPhiMgr = new TEveProjectionManager();
   gRPhiMgr->SetProjection(TEveProjection::kPT_RPhi);
+  gEve->AddToListTree(gRPhiMgr, kFALSE);
   {
     TEveProjectionAxes* a = new TEveProjectionAxes(gRPhiMgr);
     a->SetMainColor(kWhite);
@@ -94,6 +95,7 @@ void anyscan_init()
 
   gRhoZMgr = new TEveProjectionManager();
   gRhoZMgr->SetProjection(TEveProjection::kPT_RhoZ);
+  gEve->AddToListTree(gRhoZMgr, kFALSE);
   {
     TEveProjectionAxes* a = new TEveProjectionAxes(gRhoZMgr);
     a->SetMainColor(kWhite);