Introduced PDG code everywhere and use of TParticlePDG.
authorfca <fca@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 24 Jun 1999 13:54:00 +0000 (13:54 +0000)
committerfca <fca@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 24 Jun 1999 13:54:00 +0000 (13:54 +0000)
30 files changed:
EVGEN/AliDimuCombinator.cxx
EVGEN/AliDimuCombinator.h
EVGEN/AliGenFLUKAsource.cxx
EVGEN/AliGenHalo.cxx
EVGEN/AliGenParam.cxx
EVGEN/AliGenParam.h
EVGEN/AliGenPythia.cxx
EVGEN/AliGenPythia.h
EVGEN/AliSimpleGen.cxx
MUON/AliMUON.cxx
MUON/AliMUON.h
MUON/AliMUONdisplay.cxx
RICH/AliRICH.cxx
STEER/AliConst.h
STEER/AliDigit.cxx
STEER/AliDisplay.cxx
STEER/AliHit.cxx
STEER/AliLego.cxx
STEER/AliMC.h
STEER/AliPoints.cxx
STEER/AliPoints.h
STEER/AliRun.cxx
STEER/AliRun.h
STEER/Makefile
STEER/STEERLinkDef.h
TGeant3/TGeant3.cxx
TGeant3/TGeant3.h
TGeant3/TGeant3Dummy.cxx
TGeant3/gucode.cxx
TPC/AliTPC.cxx

index a815a5e..94974a3 100644 (file)
@@ -10,43 +10,43 @@ ClassImp(AliDimuCombinator)
 //
 //                       Iterators
 // 
- GParticle* AliDimuCombinator::FirstMuon()
+ TParticle* AliDimuCombinator::FirstMuon()
      {
         fimuon1=fimin1;
-        fmuon1 = (GParticle*) fPartArray->UncheckedAt(fimuon1);
+        fmuon1 = (TParticle*) fPartArray->UncheckedAt(fimuon1);
         while(Type(fmuon1)!=5 && Type(fmuon1)!=6) {
             fimuon1++;
             if (fimuon1 >= fimax1) {fmuon1=0; break;}
-            fmuon1 = (GParticle*) fPartArray->UncheckedAt(fimuon1);
+            fmuon1 = (TParticle*) fPartArray->UncheckedAt(fimuon1);
         }
         return fmuon1;
      }
             
- GParticle* AliDimuCombinator::FirstMuonSelected()
+ TParticle* AliDimuCombinator::FirstMuonSelected()
      {
-        GParticle * muon=FirstMuon();
+        TParticle * muon=FirstMuon();
         while(muon!=0 && !Selected(muon)) {muon=NextMuon();}
         return muon;
      }
             
 
- GParticle* AliDimuCombinator::NextMuon()
+ TParticle* AliDimuCombinator::NextMuon()
      {
         fimuon1++;
         if (fimuon1>=fNParticle) {fmuon1 = 0; return fmuon1;}
         
-        fmuon1 = (GParticle*) fPartArray->UncheckedAt(fimuon1);
+        fmuon1 = (TParticle*) fPartArray->UncheckedAt(fimuon1);
         while(Type(fmuon1)!=5 && Type(fmuon1)!=6) {
             fimuon1++;
             if (fimuon1>=fimax1) {fmuon1 = 0; break;}
-            fmuon1 = (GParticle*) fPartArray->UncheckedAt(fimuon1);
+            fmuon1 = (TParticle*) fPartArray->UncheckedAt(fimuon1);
         }
         return fmuon1;
      }
 
-GParticle* AliDimuCombinator::NextMuonSelected()
+TParticle* AliDimuCombinator::NextMuonSelected()
      {
-        GParticle * muon=NextMuon();
+        TParticle * muon=NextMuon();
         while(muon !=0 && !Selected(muon)) {muon=NextMuon();}
         return muon;
      }
@@ -60,11 +60,11 @@ GParticle* AliDimuCombinator::NextMuonSelected()
             fimuon2=fimin2;
         }
         if (fimuon2 >= fimax2) {fmuon2=0; return;}
-        fmuon2 = (GParticle*) fPartArray->UncheckedAt(fimuon2);
+        fmuon2 = (TParticle*) fPartArray->UncheckedAt(fimuon2);
         while(Type(fmuon2)!=5 && Type(fmuon2)!=6) {
             fimuon2++;
             if (fimuon2 >= fimax2) {fmuon2=0; break;}
-            fmuon2 = (GParticle*) fPartArray->UncheckedAt(fimuon2);
+            fmuon2 = (TParticle*) fPartArray->UncheckedAt(fimuon2);
         }
      }
 void AliDimuCombinator::FirstPartnerSelected()
@@ -80,12 +80,12 @@ void AliDimuCombinator::FirstPartnerSelected()
         if (fimuon2>=fimax2) {fmuon2 = 0; return;}
 
         
-        fmuon2 = (GParticle*) fPartArray->UncheckedAt(fimuon2);
+        fmuon2 = (TParticle*) fPartArray->UncheckedAt(fimuon2);
 
         while(Type(fmuon2)!=5 && Type(fmuon2)!=6) {
             fimuon2++;
             if (fimuon2>=fimax2) {fmuon2 = 0; break;}
-            fmuon2 = (GParticle*) fPartArray->UncheckedAt(fimuon2);
+            fmuon2 = (TParticle*) fPartArray->UncheckedAt(fimuon2);
         }
 
      }
@@ -97,19 +97,19 @@ void AliDimuCombinator::NextPartnerSelected()
 }
 
 
- GParticle*  AliDimuCombinator::Partner()
+ TParticle*  AliDimuCombinator::Partner()
      {
         return fmuon2;
      }
 
-void AliDimuCombinator::FirstMuonPair(GParticle* & muon1, GParticle* & muon2)
+void AliDimuCombinator::FirstMuonPair(TParticle* & muon1, TParticle* & muon2)
      {
         FirstMuon();
         FirstPartner();
         muon1=fmuon1;
         muon2=fmuon2;   
      }
-void AliDimuCombinator::NextMuonPair(GParticle* & muon1, GParticle* & muon2)
+void AliDimuCombinator::NextMuonPair(TParticle* & muon1, TParticle* & muon2)
      {
         NextPartner();
         if (!Partner()) {
@@ -119,14 +119,14 @@ void AliDimuCombinator::NextMuonPair(GParticle* & muon1, GParticle* & muon2)
         muon1=fmuon1;
         muon2=fmuon2;   
      }
-void AliDimuCombinator::FirstMuonPairSelected(GParticle* & muon1, GParticle* & muon2)
+void AliDimuCombinator::FirstMuonPairSelected(TParticle* & muon1, TParticle* & muon2)
      {
         FirstMuonSelected();
         FirstPartnerSelected();
         muon1=fmuon1;
         muon2=fmuon2;   
      }
-void AliDimuCombinator::NextMuonPairSelected(GParticle* & muon1, GParticle* & muon2)
+void AliDimuCombinator::NextMuonPairSelected(TParticle* & muon1, TParticle* & muon2)
      {
         NextPartnerSelected();
         if (!Partner()) {
@@ -159,13 +159,13 @@ void AliDimuCombinator::SetSecondRange(Int_t from, Int_t to)
 //                       Selection
 //
 
-Bool_t AliDimuCombinator::Selected(GParticle* part)
+Bool_t AliDimuCombinator::Selected(TParticle* part)
 {
 // 
 //
     if (part==0) {return 0;}
     
-    if (part->GetPT() > fPtMin && part->GetEta()>fEtaMin && part->GetEta()<fEtaMax) {
+    if (part->Pt() > fPtMin && part->Eta()>fEtaMin && part->Eta()<fEtaMax) {
        return 1;
     } else {
        return 0;
@@ -174,20 +174,20 @@ Bool_t AliDimuCombinator::Selected(GParticle* part)
     
 }
 
-Bool_t AliDimuCombinator::Selected(GParticle* part1, GParticle* part2)
+Bool_t AliDimuCombinator::Selected(TParticle* part1, TParticle* part2)
 {
      return Selected(part1)*Selected(part2);
 }
 //
 //                       Kinematics
 //
-Float_t AliDimuCombinator::Mass(GParticle* part1, GParticle* part2)
+Float_t AliDimuCombinator::Mass(TParticle* part1, TParticle* part2)
 {
     Float_t px,py,pz,e;
-    px=part1->GetPx()+part2->GetPx();
-    py=part1->GetPy()+part2->GetPy();
-    pz=part1->GetPz()+part2->GetPz();    
-    e =part1->GetEnergy()+part2->GetEnergy();
+    px=part1->Px()+part2->Px();
+    py=part1->Py()+part2->Py();
+    pz=part1->Pz()+part2->Pz();    
+    e =part1->Energy()+part2->Energy();
     Float_t p=px*px+py*py+pz*pz;
     if (e*e < p) {
        return -1; 
@@ -196,24 +196,24 @@ Float_t AliDimuCombinator::Mass(GParticle* part1, GParticle* part2)
     }
 }
 
-Float_t AliDimuCombinator::PT(GParticle* part1, GParticle* part2)
+Float_t AliDimuCombinator::PT(TParticle* part1, TParticle* part2)
 {
     Float_t px,py;
-    px=part1->GetPx()+part2->GetPx();
-    py=part1->GetPy()+part2->GetPy();
+    px=part1->Px()+part2->Px();
+    py=part1->Py()+part2->Py();
     return TMath::Sqrt(px*px+py*py);
 }
 
-Float_t AliDimuCombinator::Pz(GParticle* part1, GParticle* part2)
+Float_t AliDimuCombinator::Pz(TParticle* part1, TParticle* part2)
 {
-    return part1->GetPz()+part2->GetPz();
+    return part1->Pz()+part2->Pz();
 }
 
-Float_t AliDimuCombinator::Y(GParticle* part1, GParticle* part2)
+Float_t AliDimuCombinator::Y(TParticle* part1, TParticle* part2)
 {
     Float_t pz,e;
-    pz=part1->GetPz()+part2->GetPz();
-    e =part1->GetEnergy()+part2->GetEnergy();
+    pz=part1->Pz()+part2->Pz();
+    e =part1->Energy()+part2->Energy();
     return 0.5*TMath::Log((e+pz)/(e-pz));
 }
 //                  Response
@@ -225,10 +225,10 @@ void AliDimuCombinator::SmearGauss(Float_t width, Float_t & value)
 //              Weighting
 // 
 
-Float_t AliDimuCombinator::Decay_Prob(GParticle* part)
+Float_t AliDimuCombinator::Decay_Prob(TParticle* part)
 {
     Float_t d, h, theta, CTau;
-    GParticle* parent = Parent(part);
+    TParticle* parent = Parent(part);
     Int_t ipar=Type(parent);
     if (ipar==8 || ipar==9) {
        CTau=780.4;
@@ -239,11 +239,11 @@ Float_t AliDimuCombinator::Decay_Prob(GParticle* part)
     }
     
     
-    Float_t GammaBeta=(parent->GetMomentum())/(parent->GetMass());
+    Float_t GammaBeta=(parent->P())/(parent->GetMass());
 //
 // this part is still very ALICE muon-arm specific
 //
-    theta=parent->GetTheta();
+    theta=parent->Theta();
     h=90*TMath::Tan(theta);
     
     if (h<4) {
@@ -259,23 +259,23 @@ Float_t AliDimuCombinator::Decay_Prob(GParticle* part)
     }
 }
 
-Float_t AliDimuCombinator::Weight(GParticle* part1, GParticle* part2)
+Float_t AliDimuCombinator::Weight(TParticle* part1, TParticle* part2)
 {
-    Float_t wgt=(part1->GetWgt())*(part2->GetWgt());
+    Float_t wgt=(part1->GetWeight())*(part2->GetWeight());
     
     if (Correlated(part1, part2)) {
-       return wgt/(Parent(part1)->GetWgt())*fRate1;
+       return wgt/(Parent(part1)->GetWeight())*fRate1;
     } else {
        return wgt*fRate1*fRate2;
     }
 } 
 
 
-Float_t AliDimuCombinator::Weight(GParticle* part)
+Float_t AliDimuCombinator::Weight(TParticle* part)
 {
-    return (part->GetWgt())*(Parent(part)->GetWgt())*fRate1;
+    return (part->GetWeight())*(Parent(part)->GetWeight())*fRate1;
 }
-Bool_t  AliDimuCombinator::Correlated(GParticle* part1, GParticle* part2)
+Bool_t  AliDimuCombinator::Correlated(TParticle* part1, TParticle* part2)
 {
     if (Origin(part1) == Origin(part2)) {
        return kTRUE;
@@ -283,18 +283,19 @@ Bool_t  AliDimuCombinator::Correlated(GParticle* part1, GParticle* part2)
        return kFALSE;
     }
 }
-GParticle* AliDimuCombinator::Parent(GParticle* part)
+
+TParticle* AliDimuCombinator::Parent(TParticle* part)
 {
-    return (GParticle*) (fPartArray->UncheckedAt(part->GetParent()));
+    return (TParticle*) (fPartArray->UncheckedAt(part->GetFirstMother()));
 }
 
-Int_t AliDimuCombinator::Origin(GParticle* part)
+Int_t AliDimuCombinator::Origin(TParticle* part)
 {
-    Int_t iparent= part->GetParent();
+    Int_t iparent= part->GetFirstMother();
     if (iparent < 0) return iparent;
     Int_t ip;
     while(1) {
-       ip=((GParticle*) fPartArray->UncheckedAt(iparent))->GetParent();
+       ip=((TParticle*) fPartArray->UncheckedAt(iparent))->GetFirstMother();
        if (ip < 0) {
            break;
        } else {
index 79dde52..8e408bd 100644 (file)
@@ -1,6 +1,6 @@
 #ifndef _AliDimuCombinator_H
 #define _AliDimuCombinator_H
-#include "GParticle.h"
+#include "TParticle.h"
 #include <TBrowser.h>
 #include <TList.h>
 #include <TTree.h>
@@ -32,17 +32,17 @@ public:
 //    
 //  Iterators
 //  Single muons
-    GParticle* FirstMuon();
-    GParticle* NextMuon();
+    TParticle* FirstMuon();
+    TParticle* NextMuon();
 //  Single muons selected
-    GParticle* FirstMuonSelected();
-    GParticle* NextMuonSelected();
+    TParticle* FirstMuonSelected();
+    TParticle* NextMuonSelected();
 //  Dimuons    
-    void FirstMuonPair(GParticle* & muon1, GParticle* & muon2);
-    void NextMuonPair(GParticle* & muon1, GParticle* & muon2);
+    void FirstMuonPair(TParticle* & muon1, TParticle* & muon2);
+    void NextMuonPair(TParticle* & muon1, TParticle* & muon2);
 //  Dimuons selected    
-    void FirstMuonPairSelected(GParticle* & muon1, GParticle* & muon2);
-    void NextMuonPairSelected(GParticle* & muon1, GParticle* & muon2);
+    void FirstMuonPairSelected(TParticle* & muon1, TParticle* & muon2);
+    void NextMuonPairSelected(TParticle* & muon1, TParticle* & muon2);
 //  Loop over all prticles    
     void ResetRange();
 //  Set two ranges for dimuon loop    
@@ -50,32 +50,32 @@ public:
     void SetSecondRange(Int_t from, Int_t to);    
 //  Cuts
     void SetPtMin(Float_t ptmin) {fPtMin=ptmin;}
-    void SetEtaCut(Float_t etamin, Float_t etamax){fEtaMin=etamin; fEtaMax=etamax;}      Bool_t Selected(GParticle* part);
-    Bool_t Selected(GParticle* part1, GParticle* part2);
+    void SetEtaCut(Float_t etamin, Float_t etamax){fEtaMin=etamin; fEtaMax=etamax;}      Bool_t Selected(TParticle* part);
+    Bool_t Selected(TParticle* part1, TParticle* part2);
 // Kinematics
-    Float_t Mass(GParticle* part1, GParticle* part);
-    Float_t PT(GParticle* part1, GParticle* part);
-    Float_t Pz(GParticle* part1, GParticle* part);
-    Float_t Y(GParticle* part1, GParticle* part);
+    Float_t Mass(TParticle* part1, TParticle* part);
+    Float_t PT(TParticle* part1, TParticle* part);
+    Float_t Pz(TParticle* part1, TParticle* part);
+    Float_t Y(TParticle* part1, TParticle* part);
 // Response
     void SmearGauss(Float_t width, Float_t & value);
 // Weight
-    Bool_t  Correlated(GParticle* part1, GParticle* part2);
+    Bool_t  Correlated(TParticle* part1, TParticle* part2);
     void    SetRate(Float_t rate){fRate1=rate;}
     void    SetRate(Float_t rate1, Float_t rate2 ){fRate1=rate1; fRate2=rate2;}
-    Float_t Weight(GParticle* part);
-    Float_t Weight(GParticle* part1, GParticle* part);
-    Float_t Decay_Prob(GParticle* part);
+    Float_t Weight(TParticle* part);
+    Float_t Weight(TParticle* part1, TParticle* part);
+    Float_t Decay_Prob(TParticle* part);
     
  private:
     void FirstPartner();
     void NextPartner();
     void FirstPartnerSelected();
     void NextPartnerSelected();
-    Int_t Origin(GParticle* part);
-    GParticle* Parent(GParticle* part);
-    GParticle* Partner();
-    Int_t Type(GParticle *part){return part->GetKF();}
+    Int_t Origin(TParticle* part);
+    TParticle* Parent(TParticle* part);
+    TParticle* Partner();
+    Int_t Type(TParticle *part){return part->GetPdgCode();}
 private:
     TClonesArray *fPartArray;
     Int_t fNParticle;
@@ -87,8 +87,8 @@ private:
     Int_t fimax2;
     Float_t fRate1;
     Float_t fRate2;
-    GParticle *fmuon1;
-    GParticle *fmuon2;
+    TParticle *fmuon1;
+    TParticle *fmuon2;
     Float_t fPtMin;
     Float_t fEtaMin;
     Float_t fEtaMax;
index 7df5486..dceb7b2 100644 (file)
@@ -2,6 +2,8 @@
 #include "AliGenMUONlib.h"
 #include "AliMC.h"
 #include "AliRun.h"
+#include "AliConst.h"
+
 #include <TDirectory.h>
 #include <TFile.h>
 #include <TTree.h>
@@ -114,8 +116,12 @@ void AliGenFLUKAsource::Generate()
 
   AliMC* pMC = AliMC::GetMC();
 
-  const Int_t ifluge[28]={14, 15, 3, 2, 4, 4, 1, 13, 25, 5, 6, 10, 8, 9,
-                         11, 12,18, 26, 16, 21, 19, 20, 7, 16,16,0,0,0};
+  const Int_t ifluge[28]={kProton, kProtonBar, kElectron, kPositron,
+                         kNuE, kNuEBar, kGamma, kNeutron, kNeutronBar,
+                         kMuonPlus, kMuonMinus, kK0Long , kPiPlus, kPiMinus,
+                         kKPlus, kKMinus, kLambda0, kLambda0Bar, kK0Short,
+                         kSigmaMinus, kSigmaPlus, kSigma0, kPi0, kK0, kK0Bar,
+                         0,kNuMu,kNuMuBar};
   Float_t polar[3]= {0,0,0};
   //
   Float_t origin[3];
index 955986a..4541a03 100644 (file)
@@ -2,7 +2,9 @@
 #include "AliGenMUONlib.h"
 #include "AliMC.h"
 #include "AliRun.h"
+#include "AliConst.h"
 #include <TDirectory.h>
+#include <TDatabasePDG.h>
 #include <TFile.h>
 #include <TTree.h>
 #include <stdlib.h>
@@ -45,7 +47,6 @@ void AliGenHalo::Init()
 //____________________________________________________________
 void AliGenHalo::Generate()
 {
-  AliMC* pMC = AliMC::GetMC();
     FILE *fp = fopen(fFileName,"r");
     if (fp) {
        printf("\n File %s opened for reading ! \n ", fFileName);
@@ -54,16 +55,17 @@ void AliGenHalo::Generate()
     }
 //
 // MARS particle codes
- const Int_t imars[12]={0,14, 13, 8, 9, 11, 12, 5, 6, 1, 3, 2};
+    // const Int_t imars[12]={0,14, 13, 8, 9, 11, 12, 5, 6, 1, 3, 2};
+  const Int_t imars[12]={0,kProton,kNeutron,kPiPlus,kPiMinus,kKPlus,kKMinus,
+                        kMuonPlus,kMuonMinus,kGamma,kElectron,kPositron};
  
   Float_t polar[3]= {0,0,0};
   Float_t origin[3];
   Float_t p[3], p0;
   Float_t ekin, wgt, tx, ty, tz, txy;
-  Float_t amass, charge, tlife;
-  char name[100];
+  Float_t amass;
   //
-  Int_t ipart, itrtyp, ncols, nt;
+  Int_t ipart, ncols, nt;
   
   Int_t nread=0;
   origin[2]=2650;
@@ -77,8 +79,7 @@ void AliGenHalo::Generate()
       nread++;
       if (fNpart !=-1 && nread > fNpart) break;
       ipart = imars[ipart];
-      pMC->Gfpart(ipart, name, itrtyp,  
-                 amass, charge, tlife); 
+      amass = TDatabasePDG::Instance()->GetParticle(ipart)->Mass();
       p0=sqrt(ekin*ekin + 2.*amass);
       
       txy=TMath::Sqrt(tx*tx+ty*ty);
index 47d642a..30075fe 100644 (file)
@@ -7,7 +7,7 @@
 #include <TFile.h>
 #include <TTree.h>
 #include <stdlib.h>
-#include <TMCParticle.h>
+#include <TParticle.h>
 
 ClassImp(AliGenParam)
 
@@ -202,12 +202,11 @@ void AliGenParam::Generate()
              }
          }
          
-         Int_t kg=fPythia->GetGeantCode(Ipart);
 //
 // parent
 
          gAlice->
-             SetTrack(0,-1,kg,p,origin,polar,0,"Primary",nt,wgtp);
+             SetTrack(0,-1,Ipart,p,origin,polar,0,"Primary",nt,wgtp);
          Int_t iparent=nt;
 //
 // use lujet to decay particle
@@ -218,22 +217,22 @@ void AliGenParam::Generate()
          
 //
 // select muons
-         TObjArray* particles = fPythia->GetPrimaries() ;
+         TObjArray* particles = fPythia->ImportParticles() ;
          Int_t np = particles->GetEntriesFast();
          for (Int_t i = 0; i<np; i++) {
-             TMCParticle *  iparticle = (TMCParticle *) particles->At(i);
-             Int_t kf = iparticle->GetKF();
+             TParticle *  iparticle = (TParticle *) particles->At(i);
+             Int_t kf = iparticle->GetPdgCode();
 //
 // children
              if (ChildSelected(TMath::Abs(kf)))
              {
-                 p[0]=iparticle->GetPx();
-                 p[1]=iparticle->GetPy();
-                 p[2]=iparticle->GetPz();
-                 origin[0]=origin0[0]+iparticle->GetVx()/10;
-                 origin[1]=origin0[1]+iparticle->GetVy()/10;
-                 origin[2]=origin0[2]+iparticle->GetVz()/10;
-                 gAlice->SetTrack(fTrackIt,iparent,fPythia->GetGeantCode(kf),
+                 p[0]=iparticle->Px();
+                 p[1]=iparticle->Py();
+                 p[2]=iparticle->Pz();
+                 origin[0]=origin0[0]+iparticle->Vx()/10;
+                 origin[1]=origin0[1]+iparticle->Vy()/10;
+                 origin[2]=origin0[2]+iparticle->Vz()/10;
+                 gAlice->SetTrack(fTrackIt,iparent,kf,
                                   p,origin,polar,
                                   0,"Decay",nt,wgtch);
                  gAlice->KeepTrack(nt);
@@ -253,11 +252,11 @@ Bool_t AliGenParam::ChildSelected(Int_t ip)
     return kFALSE;
 }
 
-Bool_t AliGenParam::KinematicSelection(TMCParticle *particle)
+Bool_t AliGenParam::KinematicSelection(TParticle *particle)
 {
-    Float_t px=particle->GetPx();
-    Float_t py=particle->GetPy();
-    Float_t pz=particle->GetPz();
+    Float_t px=particle->Px();
+    Float_t py=particle->Py();
+    Float_t pz=particle->Pz();
 //
 // momentum cut
     Float_t p=TMath::Sqrt(px*px+py*py+pz*pz);
index d3dadc1..a769e8a 100644 (file)
@@ -8,7 +8,7 @@
 #include "TArrayF.h"
 #include "TArrayI.h"
 #include "TTree.h"
-#include "TMCParticle.h"
+#include "TParticle.h"
 
 //-------------------------------------------------------------
 class AliGenParam : public AliGenerator
@@ -33,7 +33,7 @@ protected:
     // check if particle is selected as child
     Bool_t ChildSelected(Int_t ip);
     // all kinematic selection goes here
-    Bool_t KinematicSelection(TMCParticle *particle);
+    Bool_t KinematicSelection(TParticle *particle);
  public:
   AliGenParam();
   AliGenParam(Int_t npart, Param_t param);
index 529054b..150901c 100644 (file)
@@ -8,8 +8,8 @@
 #include <TTree.h>
 #include <stdlib.h>
 #include <AliPythia.h>
-#include <TMCParticle.h>
-#include <GParticle.h>
+#include <TParticle.h>
+//#include <GParticle.h>
  ClassImp(AliGenPythia)
 
 AliGenPythia::AliGenPythia()
@@ -148,15 +148,15 @@ void AliGenPythia::Generate()
     {
        fPythia->PyEvnt();
        fTrials++;
-       TObjArray* particles = fPythia->GetPrimaries() ;
+       TObjArray* particles = fPythia->ImportParticles();
        Int_t np = particles->GetEntriesFast();
        printf("\n **************************************************%d\n",np);
        Int_t nc=0;
        if (np == 0 ) continue;
        if (fProcess != mb) {
            for (Int_t i = 0; i<np; i++) {
-               TMCParticle *  iparticle = (TMCParticle *) particles->At(i);
-               Int_t kf = iparticle->GetKF();
+               TParticle *  iparticle = (TParticle *) particles->At(i);
+               Int_t kf = iparticle->GetPdgCode();
                fChildWeight=(fPythia->GetBraPart(kf))*fParentWeight;     
 //
 // Parent
@@ -183,17 +183,17 @@ void AliGenPythia::Generate()
                        nc++;
 //
 // store parent track information
-                       p[0]=iparticle->GetPx();
-                       p[1]=iparticle->GetPy();
-                       p[2]=iparticle->GetPz();
-                       origin[0]=origin0[0]+iparticle->GetVx()/10;
-                       origin[1]=origin0[1]+iparticle->GetVy()/10;
-                       origin[2]=origin0[2]+iparticle->GetVz()/10;
+                       p[0]=iparticle->Px();
+                       p[1]=iparticle->Py();
+                       p[2]=iparticle->Pz();
+                       origin[0]=origin0[0]+iparticle->Vx()/10;
+                       origin[1]=origin0[1]+iparticle->Vy()/10;
+                       origin[2]=origin0[2]+iparticle->Vz()/10;
 
-                       Int_t ifch=iparticle->GetFirstChild();
-                       Int_t ilch=iparticle->GetLastChild();   
+                       Int_t ifch=iparticle->GetFirstDaughter();
+                       Int_t ilch=iparticle->GetLastDaughter();        
                        if (ifch !=0 && ilch !=0) {
-                           gAlice->SetTrack(0,nt_p,fPythia->GetGeantCode(kf),
+                           gAlice->SetTrack(0,nt_p,kf,
                                             p,origin,polar,
                                             0,"Primary",nt,fParentWeight);
                            gAlice->KeepTrack(nt);
@@ -203,21 +203,20 @@ void AliGenPythia::Generate()
 
                            for (Int_t j=ifch; j<=ilch; j++)
                            {
-                               TMCParticle *  ichild = 
-                                   (TMCParticle *) particles->At(j-1);
-                               Int_t kf = ichild->GetKF();
+                               TParticle *  ichild = 
+                                   (TParticle *) particles->At(j-1);
+                               Int_t kf = ichild->GetPdgCode();
 //
 // 
                                if (ChildSelected(TMath::Abs(kf))) {
-                                   Int_t kg=fPythia->GetGeantCode(kf);
-                                   origin[0]=ichild->GetVx();
-                                   origin[1]=ichild->GetVy();
-                                   origin[2]=ichild->GetVz();          
-                                   p[0]=ichild->GetPx();
-                                   p[1]=ichild->GetPy();
-                                   p[2]=ichild->GetPz();
-                                   Float_t tof=kconv*ichild->GetTime();
-                                   gAlice->SetTrack(fTrackIt, iparent, kg,
+                                   origin[0]=ichild->Vx();
+                                   origin[1]=ichild->Vy();
+                                   origin[2]=ichild->Vz();             
+                                   p[0]=ichild->Px();
+                                   p[1]=ichild->Py();
+                                   p[2]=ichild->Pz();
+                                   Float_t tof=kconv*ichild->T();
+                                   gAlice->SetTrack(fTrackIt, iparent, kf,
                                                     p,origin,polar,
                                                     tof,"Decay",nt,fChildWeight);
                                    gAlice->KeepTrack(nt);
@@ -229,22 +228,21 @@ void AliGenPythia::Generate()
            } // particle loop
        } else {
            for (Int_t i = 0; i<np; i++) {
-               TMCParticle *  iparticle = (TMCParticle *) particles->At(i);
-               Int_t kf = iparticle->GetKF();
-               Int_t ks = iparticle->GetKS();
-               Int_t gc = fPythia->GetGeantCode(kf);
-               if (ks==1 && gc!=0 && KinematicSelection(iparticle)) {
+               TParticle *  iparticle = (TParticle *) particles->At(i);
+               Int_t kf = iparticle->GetPdgCode();
+               Int_t ks = iparticle->GetStatusCode();
+               if (ks==1 && kf!=0 && KinematicSelection(iparticle)) {
                        nc++;
 //
 // store track information
-                       p[0]=iparticle->GetPx();
-                       p[1]=iparticle->GetPy();
-                       p[2]=iparticle->GetPz();
-                       origin[0]=origin0[0]+iparticle->GetVx()/10;
-                       origin[1]=origin0[1]+iparticle->GetVy()/10;
-                       origin[2]=origin0[2]+iparticle->GetVz()/10;
-                       Float_t tof=kconv*iparticle->GetTime();
-                       gAlice->SetTrack(fTrackIt,-1,gc,p,origin,polar,
+                       p[0]=iparticle->Px();
+                       p[1]=iparticle->Py();
+                       p[2]=iparticle->Pz();
+                       origin[0]=origin0[0]+iparticle->Vx()/10;
+                       origin[1]=origin0[1]+iparticle->Vy()/10;
+                       origin[2]=origin0[2]+iparticle->Vz()/10;
+                       Float_t tof=kconv*iparticle->T();
+                       gAlice->SetTrack(fTrackIt,-1,kf,p,origin,polar,
                                         tof,"Primary",nt);
                        gAlice->KeepTrack(nt);
                } // select particle
@@ -284,12 +282,12 @@ Bool_t AliGenPythia::ChildSelected(Int_t ip)
     return kFALSE;
 }
 
-Bool_t AliGenPythia::KinematicSelection(TMCParticle *particle)
+Bool_t AliGenPythia::KinematicSelection(TParticle *particle)
 {
-    Float_t px=particle->GetPx();
-    Float_t py=particle->GetPy();
-    Float_t pz=particle->GetPz();
-    Float_t  e=particle->GetEnergy();
+    Float_t px=particle->Px();
+    Float_t py=particle->Py();
+    Float_t pz=particle->Pz();
+    Float_t  e=particle->Energy();
 
 //
 //  transverse momentum cut    
@@ -340,11 +338,11 @@ Bool_t AliGenPythia::KinematicSelection(TMCParticle *particle)
 void AliGenPythia::AdjustWeights()
 {
     TClonesArray *PartArray = gAlice->Particles();
-    GParticle *Part;
+    TParticle *Part;
     Int_t ntrack=gAlice->GetNtrack();
     for (Int_t i=0; i<ntrack; i++) {
-       Part= (GParticle*) PartArray->UncheckedAt(i);
-       Part->SetWgt(Part->GetWgt()*fKineBias);
+       Part= (TParticle*) PartArray->UncheckedAt(i);
+       Part->SetWeight(Part->GetWeight()*fKineBias);
     }
 }
 
index 77718c9..f42a7c8 100644 (file)
@@ -10,7 +10,7 @@
 #include "TTree.h"
 #include "AliPythia.h"
 #include "TArrayI.h"
-#include "TMCParticle.h"
+#include "TParticle.h"
 
 class AliGenPythia : public AliGenerator
 {
@@ -34,7 +34,7 @@ class AliGenPythia : public AliGenerator
     // check if particle is selected as child particle
     Bool_t ChildSelected(Int_t ip);
     // all kinematic selection cuts go here 
-    Bool_t KinematicSelection(TMCParticle *particle);
+    Bool_t KinematicSelection(TParticle *particle);
     // adjust the weight from kinematic cuts
     void   AdjustWeights();
  public:
index a7f302c..dbd3b79 100644 (file)
@@ -20,6 +20,7 @@
 
 #include "AliSimpleGen.h"
 #include "AliRun.h"
+#include "AliConst.h"
 
 ClassImp(AliGenHIJINGpara)
 
@@ -205,16 +206,8 @@ void AliGenHIJINGpara::Generate()
   const Float_t borne=1/(1+raKpic);
   Float_t polar[3]= {0,0,0};
   //
-  const Int_t pi0=7;
-  const Int_t piplus=8;
-  const Int_t piminus=9;
-  const Int_t k0l=10;
-  const Int_t k0s=16;
-  const Int_t kplus=11;
-  const Int_t kminus=12;
-  //
-  const Int_t pions[3] = {pi0, piplus, piminus};
-  const Int_t kaons[4] = {k0l, k0s, kplus, kminus};
+  const Int_t pions[3] = {kPi0, kPiPlus, kPiMinus};
+  const Int_t kaons[4] = {kK0Long, kK0Short, kKPlus, kKMinus};
   //
   Float_t origin[3];
   Float_t pt, pl, ptot;
@@ -293,7 +286,7 @@ AliGenFixed::AliGenFixed(Int_t npart)
   fName="Fixed";
   fTitle="Fixed Particle Generator";
   // Generate Proton by default
-  fIpart=14;
+  fIpart=kProton;
 }
 
 //_____________________________________________________________________________
@@ -345,7 +338,7 @@ AliGenBox::AliGenBox(Int_t npart)
   fName="Box";
   fTitle="Box particle generator";
   // Generate Proton by default
-  fIpart=14;
+  fIpart=kProton;
 }
 
 //_____________________________________________________________________________
index f0034c9..b2abd9f 100644 (file)
@@ -726,7 +726,7 @@ ClassImp(AliMUONhit)
        AliHit(shunt, track)
 {
     fChamber=vol[0];
-    fParticle=hits[0];
+    fParticle=(Int_t) hits[0];
     fX=hits[1];
     fY=hits[2];
     fZ=hits[3];
index a91baca..c755a5b 100644 (file)
@@ -297,7 +297,7 @@ class AliMUONlist : public AliMUONdigit {
 class AliMUONhit : public AliHit {
  public:
     Int_t     fChamber;       // Chamber number
-    Float_t   fParticle;      // Geant3 particle type
+    Int_t     fParticle;      // PDG particle type
     Float_t   fTheta ;        // Incident theta angle in degrees      
     Float_t   fPhi   ;        // Incident phi angle in degrees
     Float_t   fTlength;       // Track length inside the chamber
index b459fe2..af6a00e 100644 (file)
@@ -36,7 +36,7 @@
 #include "AliMUONConst.h"
 #include "AliMUONdisplay.h"
 #include "AliMUONpoints.h"
-#include "GParticle.h"
+#include "TParticle.h"
 
 
 ClassImp(AliMUONdisplay)
index e397114..c3d38b8 100644 (file)
@@ -613,7 +613,7 @@ void AliRICH::StepManager()
        stwght = geant3->Gctrak()->upwght;
        geant3->Gctrak()->upwght = (Float_t) sNphoton;
        geant3->Gskpho(i);
-       gAlice->SetTrack(0, gAlice->CurrentTrack(), 50, 
+       gAlice->SetTrack(0, gAlice->CurrentTrack(), 20000050, 
                         &geant3->Gckin2()->xphot[i-1][3],geant3->Gckin2()->xphot[i-1],
                         polar,geant3->Gctrak()->tofg,"Cherenkov", ncher);
        sMckov[sNphoton - 1] = ncher;
index 56d53f7..ff1b2ee 100644 (file)
@@ -8,4 +8,1176 @@ static const Double_t k2PI    = 2*kPI;
 static const Double_t kDegrad = kPI/180;
 static const Double_t kRaddeg = 180/kPI;
 
+enum PDG {kDown=1,kDownBar=-1,kUp=2,kUpBar=-2,kStrange=3,
+         kStrangeBar=-3,kCharm=4,kCharmBar=-4,kBottom=5,
+         kBottomBar=-5,kTop=6,kTopBar=-6,kGluon=21,kPythia92=92,
+         kDd1=1103,kDd1Bar=-1103,kUd0=2101,kUd0Bar=-2101,kUd1=2103,
+         kUd1Bar=-2103,kUu1=2203,kUu1Bar=-2203,kSd0=3101,kSd0Bar=-3101,
+         kSd1=3103,kSd1Bar=-3103,kSu0=3201,kSu0Bar=-3201,kSu1=3203,
+         kSu1Bar=-3203,kSearches0=7,kElectron=11,kPositron=-11,kNuE=12,
+         kNuEBar=-12,kMuonMinus=13,kMuonPlus=-13,kNuMu=14,kNuMuBar=-14,
+         kTauMinus=15,kTauPlus=-15,kNuTau=16,kNuTauBar=-16,kGamma=22,
+         kZ0=23,kWPlus=24,kWMinus=-24,kPi0=111,kRho770_0=113,
+         kA2_1320_0=115,kRho3_1690_0=117,kK0Long=130,kPiPlus=211,
+         kPiMinus=-211,kRho770Plus=213,kRho770Minus=-213,
+         kA2_1320Plus=215,kProton=2212,kProtonBar=-2212,
+         kNeutron=2112,kNeutronBar=-2112,kK0Short=310,kK0=311,
+         kK0Bar=-311,kKPlus=321,kKMinus=-321,kLambda0=3122,
+         kLambda0Bar=-3122,kSigmaMinus=3112,kSigmaBarPlus=-3112,
+         kSigmaPlus=3222,kSigmaBarMinus=-3222,kSigma0=3212,
+         kSigma0Bar=-3212};
+         
+
+/*
+   "a(2)(1320)-",  -215));
+   "rho(3)(1690)+", 217));
+   "rho(3)(1690)-",-217));
+   "eta0",          221));
+   "omega(782)0","M001",
+                                      .7819399,kFALSE, 8.43000E-03,
+                                     0.0,"Meson", 223));
+   "f(2)(1270)0","M005",
+                                      1.275,kFALSE, .185,
+                                     0.0,"Meson", 225));
+   "omega(3)(1670)0","M045",
+                                      1.668,kFALSE, .1729999,
+                                     0.0,"Meson", 227));
+   "f(4)(2050)0","M016",
+                                      2.044,kFALSE, .208,
+                                     0.0,"Meson", 229));
+   "K*(892)0","M018",
+                                      .8960999,kFALSE, 5.05000E-02,
+                                     0.0,"Meson", 313));
+   "K*(892)0 bar","M018",
+                                      .8960999,kFALSE, 5.05000E-02,
+                                     0.0,"Meson", -313));
+   "K(2)*(1430)0","M022",
+                                      1.4324,kFALSE, .1089999,
+                                     0.0,"Meson", 315));
+   "K(2)*(1430)0 bar","M022",
+                                      1.4324,kFALSE, .1089999,
+                                     0.0,"Meson", -315));
+   "K(3)*(1780)0","M060",
+                                      1.77,kFALSE, .164,
+                                     0.0,"Meson", 317));
+   "K(3)*(1780)0 bar","M060",
+                                      1.77,kFALSE, .164,
+                                     0.0,"Meson", -317));
+   "K(4)*(2045)0","M035",
+                                      2.045,kFALSE, .1979999,
+                                     0.0,"Meson", 319));
+   "K(4)*(2045)0 bar","M035",
+                                      2.045,kFALSE, .1979999,
+                                     0.0,"Meson", -319));
+   "K*(892)+","M018",
+                                      .8915899,kFALSE, 4.98000E-02,
+                                     0.0,"Meson", 323));
+   "K*(892)-","M018",
+                                      .8915899,kFALSE, 4.98000E-02,
+                                     0.0,"Meson", -323));
+   "K(2)*(1430)+","M022",
+                                      1.4254,kFALSE, 9.84000E-02,
+                                     0.0,"Meson", 325));
+   "K(2)*(1430)-","M022",
+                                      1.4254,kFALSE, 9.84000E-02,
+                                     0.0,"Meson", -325));
+   "K(3)*(1780)+","M060",
+                                      1.77,kFALSE, .164,
+                                     0.0,"Meson", 327));
+   "K(3)*(1780)-","M060",
+                                      1.77,kFALSE, .164,
+                                     0.0,"Meson", -327));
+   "K(4)*(2045)+","M035",
+                                      2.045,kFALSE, .1979999,
+                                     0.0,"Meson", 329));
+   "K(4)*(2045)-","M035",
+                                      2.045,kFALSE, .1979999,
+                                     0.0,"Meson", -329));
+   "eta'(958)0","M002",
+                                      .9577699,kFALSE, 2.01000E-04,
+                                     0.0,"Meson", 331));
+   "phi(1020)0","M004",
+                                      1.01941,kFALSE, 4.43000E-03,
+                                     0.0,"Meson", 333));
+   "f(2)'(1525)0","M013",
+                                      1.525,kFALSE, 7.60000E-02,
+                                     0.0,"Meson", 335));
+   "phi(3)(1850)0","M054",
+                                      1.854,kFALSE, 8.70000E-02,
+                                     0.0,"Meson", 337));
+   "D+","S031",
+                                      1.8694,kFALSE, 6.23000E-13,
+                                     0.0,"Meson", 411));
+   "D-","S031",
+                                      1.8694,kFALSE, 6.23000E-13,
+                                     0.0,"Meson", -411));
+   "D*(2010)+","M062",
+                                      2.01,kTRUE, .0,
+                                     0.0,"Meson", 413));
+   "D*(2010)-","M062",
+                                      2.01,kTRUE, .0,
+                                     0.0,"Meson", -413));
+   "D(2)*(2460)+","M150",
+                                      2.456,kFALSE, 2.30000E-02,
+                                     0.0,"Meson", 415));
+   "D(2)*(2460)-","M150",
+                                      2.456,kFALSE, 2.30000E-02,
+                                     0.0,"Meson", -415));
+   "D0","S032",
+                                      1.8646,kFALSE, 1.58600E-12,
+                                     0.0,"Meson", 421));
+   "D0 bar","S032",
+                                      1.8646,kFALSE, 1.58600E-12,
+                                     0.0,"Meson", -421));
+   "D*(2007)0","M061",
+                                      2.0067,kTRUE, .0,
+                                     0.0,"Meson", 423));
+   "D*(2007)0 bar","M061",
+                                      2.0067,kTRUE, .0,
+                                     0.0,"Meson", -423));
+   "D(2)*(2460)0","M119",
+                                      2.4577,kFALSE, 2.10000E-02,
+                                     0.0,"Meson", 425));
+   "D(2)*(2460)0 bar","M119",
+                                      2.4577,kFALSE, 2.10000E-02,
+                                     0.0,"Meson", -425));
+   "D(s)+","S034",
+                                      1.9685,kFALSE, 1.41000E-12,
+                                     0.0,"Meson", 431));
+   "D(s)-","S034",
+                                      1.9685,kFALSE, 1.41000E-12,
+                                     0.0,"Meson", -431));
+   "D(s)*+","S074",
+                                      2.11,kTRUE, .0,
+                                     0.0,"Meson", 433));
+   "D(s)*-","S074",
+                                      2.11,kTRUE, .0,
+                                     0.0,"Meson", -433));
+   "eta(c)(1S)0","M026",
+                                      2.9788,kFALSE, 1.03000E-02,
+                                     0.0,"Meson", 441));
+   "J/psi(1S)0","M070",
+                                      3.09688,kFALSE, 8.80000E-05,
+                                     0.0,"Meson", 443));
+   "chi(c2)(1P)0","M057",
+                                      3.55617,kFALSE, 2.00000E-03,
+                                     0.0,"Meson", 445));
+   "B0","S049",
+                                      5.279,kFALSE, 4.39000E-13,
+                                     0.0,"Meson", 511));
+   "B0 bar","S049",
+                                      5.279,kFALSE, 4.39000E-13,
+                                     0.0,"Meson", -511));
+   "B*0","S085",
+                                      5.3248,kTRUE, .0,
+                                     0.0,"Meson", 513));
+   "B*0 bar","S085",
+                                      5.3248,kTRUE, .0,
+                                     0.0,"Meson", -513));
+   "B+","S049",
+                                      5.2787,kFALSE, 4.28000E-13,
+                                     0.0,"Meson", 521));
+   "B-","S049",
+                                      5.2787,kFALSE, 4.28000E-13,
+                                     0.0,"Meson", -521));
+   "B*+","S085",
+                                      5.3248,kTRUE, .0,
+                                     0.0,"Meson", 523));
+   "B*-","S085",
+                                      5.3248,kTRUE, .0,
+                                     0.0,"Meson", -523));
+   "B(s)0","S086",
+                                      5.375,kFALSE, 4.90000E-13,
+                                     0.0,"Meson", 531));
+   "B(s)0 bar","S086",
+                                      5.375,kFALSE, 4.90000E-13,
+                                     0.0,"Meson", -531));
+   "chi(b0)(1P)0","M076",
+                                      9.8598,kTRUE, .0,
+                                     0.0,"Meson", 551));
+   "chi(b0)(1P)0 bar","M076",
+                                      9.8598,kTRUE, .0,
+                                     0.0,"Meson", -551));
+   "Upsilon(1S)0","M049",
+                                      9.46037,kFALSE, 5.25000E-05,
+                                     0.0,"Meson", 553));
+   "chi(b2)(1P)0","M078",
+                                      9.9132,kTRUE, .0,
+                                     0.0,"Meson", 555));
+   "Delta(1620)-","B082",
+                                      1.62,kFALSE, .15,
+                                     -1.,"Baryon", 1112));
+   "Delta(1620)+ bar","B082",
+                                      1.62,kFALSE, .15,
+                                     +1.,"Baryon", -1112));
+   "Delta(1232)-","B033",
+                                      1.232,kFALSE, .1199999,
+                                     -1.,"Baryon", 1114));
+   "Delta(1232)+ bar","B033",
+                                      1.232,kFALSE, .1199999,
+                                     +1.,"Baryon", -1114));
+   "Delta(1905)-","B011",
+                                      1.905,kFALSE, .3499999,
+                                     -1.,"Baryon", 1116));
+   "Delta(1905)+ bar","B011",
+                                      1.905,kFALSE, .3499999,
+                                     +1.,"Baryon", -1116));
+   "Delta(1950)-","B083",
+                                      1.95,kFALSE, .3,
+                                     -1.,"Baryon", 1118));
+   "Delta(1950)+ bar","B083",
+                                      1.95,kFALSE, .3,
+                                     +1.,"Baryon", -1118));
+   "Delta(1620)0","B082",
+                                      1.62,kFALSE, .15,
+                                     0.0,"Baryon", 1212));
+   "Delta(1620)0 bar","B082",
+                                      1.62,kFALSE, .15,
+                                     0.0,"Baryon", -1212));
+   "N(1520)0","B062",
+                                      1.52,kFALSE, .1199999,
+                                     0.0,"Baryon", 1214));
+   "N(1520)0 bar","B062",
+                                      1.52,kFALSE, .1199999,
+                                     0.0,"Baryon", -1214));
+   "Delta(1905)0","B011",
+                                      1.905,kFALSE, .3499999,
+                                     0.0,"Baryon", 1216));
+   "Delta(1905)0 bar","B011",
+                                      1.905,kFALSE, .3499999,
+                                     0.0,"Baryon", -1216));
+   "N(2190)0","B071",
+                                      2.19,kFALSE, .4499999,
+                                     0.0,"Baryon", 1218));
+   "N(2190)0 bar","B071",
+                                      2.19,kFALSE, .4499999,
+                                     0.0,"Baryon", -1218));
+   "n","S017",
+                                      .9395656,kFALSE, 7.42100E-28,
+                                     0.0,"Baryon", 2112));
+   "n bar","S017",
+                                      .9395656,kFALSE, 7.42100E-28,
+                                     0.0,"Baryon", -2112));
+   "Delta(1232)0","B033",
+                                      1.232,kFALSE, .1199999,
+                                     0.0,"Baryon", 2114));
+   "Delta(1232)0 bar","B033",
+                                      1.232,kFALSE, .1199999,
+                                     0.0,"Baryon", -2114));
+   "N(1675)0","B064",
+                                      1.675,kFALSE, .15,
+                                     0.0,"Baryon", 2116));
+   "N(1675)0 bar","B064",
+                                      1.675,kFALSE, .15,
+                                     0.0,"Baryon", -2116));
+   "Delta(1950)0","B083",
+                                      1.95,kFALSE, .3,
+                                     0.0,"Baryon", 2118));
+   "Delta(1950)0 bar","B083",
+                                      1.95,kFALSE, .3,
+                                     0.0,"Baryon", -2118));
+   "Delta(1620)+","B082",
+                                      1.62,kFALSE, .15,
+                                     +1.,"Baryon", 2122));
+   "Delta(1620)- bar","B082",
+                                      1.62,kFALSE, .15,
+                                     -1.,"Baryon", -2122));
+   "N(1520)+","B062",
+                                      1.52,kFALSE, .1199999,
+                                     +1.,"Baryon", 2124));
+   "N(1520)- bar","B062",
+                                      1.52,kFALSE, .1199999,
+                                     -1.,"Baryon", -2124));
+   "Delta(1905)+","B011",
+                                      1.905,kFALSE, .3499999,
+                                     +1.,"Baryon", 2126));
+   "Delta(1905)- bar","B011",
+                                      1.905,kFALSE, .3499999,
+                                     -1.,"Baryon", -2126));
+   "N(2190)+","B071",
+                                      2.19,kFALSE, .4499999,
+                                     +1.,"Baryon", 2128));
+   "N(2190)- bar","B071",
+                                      2.19,kFALSE, .4499999,
+                                     -1.,"Baryon", -2128));
+
+   "Delta(1232)+","B033",
+                                      1.232,kFALSE, .1199999,
+                                     +1.,"Baryon", 2214));
+   "Delta(1232)- bar","B033",
+                                      1.232,kFALSE, .1199999,
+                                     -1.,"Baryon", -2214));
+   "N(1675)+","B064",
+                                      1.675,kFALSE, .15,
+                                     +1.,"Baryon", 2216));
+   "N(1675)- bar","B064",
+                                      1.675,kFALSE, .15,
+                                     -1.,"Baryon", -2216));
+   "Delta(1950)+","B083",
+                                      1.95,kFALSE, .3,
+                                     +1.,"Baryon", 2218));
+   "Delta(1950)- bar","B083",
+                                      1.95,kFALSE, .3,
+                                     -1.,"Baryon", -2218));
+   "Delta(1620)++","B082",
+                                      1.62,kFALSE, .15,
+                                     +2.,"Baryon", 2222));
+   "Delta(1620)-- bar","B082",
+                                      1.62,kFALSE, .15,
+                                     -2.,"Baryon", -2222));
+   "Delta(1232)++","B033",
+                                      1.232,kFALSE, .1199999,
+                                     +2.,"Baryon", 2224));
+   "Delta(1232)-- bar","B033",
+                                      1.232,kFALSE, .1199999,
+                                     -2.,"Baryon", -2224));
+   "Delta(1905)++","B011",
+                                      1.905,kFALSE, .3499999,
+                                     +2.,"Baryon", 2226));
+   "Delta(1905)-- bar","B011",
+                                      1.905,kFALSE, .3499999,
+                                     -2.,"Baryon", -2226));
+   "Delta(1950)++","B083",
+                                      1.95,kFALSE, .3,
+                                     +2.,"Baryon", 2228));
+   "Delta(1950)-- bar","B083",
+                                      1.95,kFALSE, .3,
+                                     -2.,"Baryon", -2228));
+   "Sigma(1385)-","B043",
+                                      1.3872,kFALSE, 3.94000E-02,
+                                     -1.,"Baryon", 3114));
+   "Sigma(1385)+ bar","B043",
+                                      1.3872,kFALSE, 3.94000E-02,
+                                     +1.,"Baryon", -3114));
+   "Sigma(1775)-","B045",
+                                      1.775,kFALSE, .1199999,
+                                     -1.,"Baryon", 3116));
+   "Sigma(1775)+ bar","B045",
+                                      1.775,kFALSE, .1199999,
+                                     +1.,"Baryon", -3116));
+   "Sigma(2030)-","B047",
+                                      2.03,kFALSE, .18,
+                                     -1.,"Baryon", 3118));
+   "Sigma(2030)+ bar","B047",
+                                      2.03,kFALSE, .18,
+                                     +1.,"Baryon", -3118));
+   "Lambda(1520)0","B038",
+                                      1.5195,kFALSE, 1.56000E-02,
+                                     0.0,"Baryon", 3124));
+   "Lambda(1520)0 bar","B038",
+                                      1.5195,kFALSE, 1.56000E-02,
+                                     0.0,"Baryon", -3124));
+   "Lambda(1820)0","B039",
+                                      1.82,kFALSE, 8.00000E-02,
+                                     0.0,"Baryon", 3126));
+   "Lambda(1820)0 bar","B039",
+                                      1.82,kFALSE, 8.00000E-02,
+                                     0.0,"Baryon", -3126));
+   "Lambda(2100)0","B041",
+                                      2.1,kFALSE, .2,
+                                     0.0,"Baryon", 3128));
+   "Lambda(2100)0 bar","B041",
+                                      2.1,kFALSE, .2,
+                                     0.0,"Baryon", -3128));
+   "Sigma(1385)0","B043",
+                                      1.3837,kFALSE, 3.60000E-02,
+                                     0.0,"Baryon", 3214));
+   "Sigma(1385)0 bar","B043",
+                                      1.3837,kFALSE, 3.60000E-02,
+                                     0.0,"Baryon", -3214));
+   "Sigma(1775)0","B045",
+                                      1.775,kFALSE, .1199999,
+                                     0.0,"Baryon", 3216));
+   "Sigma(1775)0 bar","B045",
+                                      1.775,kFALSE, .1199999,
+                                     0.0,"Baryon", -3216));
+   "Sigma(2030)0","B047",
+                                      2.03,kFALSE, .18,
+                                     0.0,"Baryon", 3218));
+   "Sigma(2030)0 bar","B047",
+                                      2.03,kFALSE, .18,
+                                     0.0,"Baryon", -3218));
+   "Sigma(1385)+","B043",
+                                      1.3828,kFALSE, 3.58000E-02,
+                                     +1.,"Baryon", 3224));
+   "Sigma(1385)- bar","B043",
+                                      1.3828,kFALSE, 3.58000E-02,
+                                     -1.,"Baryon", -3224));
+   "Sigma(1775)+","B045",
+                                      1.775,kFALSE, .1199999,
+                                     +1.,"Baryon", 3226));
+   "Sigma(1775)- bar","B045",
+                                      1.775,kFALSE, .1199999,
+                                     -1.,"Baryon", -3226));
+   "Sigma(2030)+","B047",
+                                      2.03,kFALSE, .18,
+                                     +1.,"Baryon", 3228));
+   "Sigma(2030)- bar","B047",
+                                      2.03,kFALSE, .18,
+                                     -1.,"Baryon", -3228));
+   "Xi-","S022",
+                                      1.32132,kFALSE, 4.02000E-15,
+                                     -1.,"Baryon", 3312));
+   "Xi+ bar","S022",
+                                      1.32132,kFALSE, 4.02000E-15,
+                                     +1.,"Baryon", -3312));
+   "Xi(1530)-","B049",
+                                      1.535,kFALSE, 9.90000E-03,
+                                     -1.,"Baryon", 3314));
+   "Xi(1530)+ bar","B049",
+                                      1.535,kFALSE, 9.90000E-03,
+                                     +1.,"Baryon", -3314));
+   "Xi0","S023",
+                                      1.3149,kFALSE, 2.27000E-15,
+                                     0.0,"Baryon", 3322));
+   "Xi0 bar","S023",
+                                      1.3149,kFALSE, 2.27000E-15,
+                                     0.0,"Baryon", -3322));
+   "Xi(1530)0","B049",
+                                      1.5318,kFALSE, 9.10000E-03,
+                                     0.0,"Baryon", 3324));
+   "Xi(1530)0 bar","B049",
+                                      1.5318,kFALSE, 9.10000E-03,
+                                     0.0,"Baryon", -3324));
+   "Omega-","S024",
+                                      1.67245,kFALSE, 8.01000E-15,
+                                     -1.,"Baryon", 3334));
+   "Omega+ bar","S024",
+                                      1.67245,kFALSE, 8.01000E-15,
+                                     +1.,"Baryon", -3334));
+   "Sigma(c)(2455)0","B104",
+                                      2.4524,kTRUE, .0,
+                                     0.0,"Baryon", 4112));
+   "Sigma(c)(2455)0 bar","B104",
+                                      2.4524,kTRUE, .0,
+                                     0.0,"Baryon", -4112));
+   "Sigma(c)*0","Sigma(c)*0",
+                                      -1.,kTRUE, -1,
+                                     0.,"Baryon", 4114));
+   "Sigma(c)*0 bar","Sigma(c)*0 bar",
+                                      -1.,kTRUE, -1,
+                                     0.,"Baryon", -4114));
+   "Lambda(c)+","S033",
+                                      2.2851,kFALSE, 3.29000E-12,
+                                     +1.,"Baryon", 4122));
+   "Lambda(c)- bar","S033",
+                                      2.2851,kFALSE, 3.29000E-12,
+                                     -1.,"Baryon", -4122));
+   "Sigma(c)(2455)+","B104",
+                                      2.4538,kTRUE, .0,
+                                     +1.,"Baryon", 4212));
+   "Sigma(c)(2455)- bar","B104",
+                                      2.4538,kTRUE, .0,
+                                     -1.,"Baryon", -4212));
+   "Sigma(c)(2455)++","B104",
+                                      2.4531,kTRUE, .0,
+                                     +2.,"Baryon", 4222));
+   "Sigma(c)(2455)-- bar","B104",
+                                      2.4531,kTRUE, .0,
+                                     -2.,"Baryon", -4222));
+   "Sigma(c)*++","Sigma(c)*++",
+                                      -1.,kTRUE, -1.,
+                                     +2.,"Baryon", 4224));
+   "Sigma(c)*++ bar","Sigma(c)*++ bar",
+                                      -1.,kTRUE, -1.,
+                                     -2.,"Baryon", -4224));
+   "Xi(c)0","S048",
+                                      2.4703,kFALSE, 6.70000E-12,
+                                     0.0,"Baryon", 4312));
+   "Xi(c)0 bar","S048",
+                                      2.4703,kFALSE, 6.70000E-12,
+                                     0.0,"Baryon", -4312));
+   "Xi(c)+","S045",
+                                      2.4651,kFALSE, 1.86000E-12,
+                                     +1.,"Baryon", 4322));
+   "Xi(c)- bar","S045",
+                                      2.4651,kFALSE, 1.86000E-12,
+                                     -1.,"Baryon", -4322));
+//-----------------------------------------------------------------------------
+// B-baryons
+//-----------------------------------------------------------------------------
+   "Lambda(b)0","S040",
+                                      5.64,kFALSE, 6.20000E-13,
+                                     0.0,"Baryon", 5122));
+   "Lambda(b)0 bar","S040",
+                                      5.64,kFALSE, 6.20000E-13,
+                                     0.0,"Baryon", -5122));
+   "Sigma(b)-","Sigma(b)-",
+                                      -1.,kFALSE, -1.,
+                                     0.0,"Baryon", 5112));
+   "Sigma(b)- bar","Sigma(b)- bar",
+                                      -1.,kFALSE, -1.,
+                                     0.0,"Baryon", -5112));
+   "Sigma(b)+","Sigma(b)+",
+                                      -1.,kFALSE, -1.,
+                                     0.0,"Baryon", 5222));
+   "Sigma(b)+ bar","Sigma(b)+ bar",
+                                      -1.,kFALSE, -1.,
+                                     0.0,"Baryon", -5222));
+   "Sigma(b)0","Sigma(b)0",
+                                      -1.,kFALSE, -1.,
+                                     0.0,"Baryon", 5212));
+   "Sigma(b)0 bar","Sigma(b)0 bar",
+                                      -1.,kFALSE, -1.,
+                                     0.0,"Baryon", -5212));
+   "Sigma(b)*-","Sigma(b)*-",
+                                      -1.,kFALSE, -1.,
+                                     0.0,"Baryon", 5114));
+   "Sigma(b)*- bar","Sigma(b)*- bar",
+                                      -1.,kFALSE, -1.,
+                                     0.0,"Baryon", -5114));
+   "Sigma(b)*+","Sigma(b)*+",
+                                      -1.,kFALSE, -1.,
+                                      1.0,"Baryon", 5214));
+   "Sigma(b)*+ bar","Sigma(b)*+ bar",
+                                      -1.,kFALSE, -1.,
+                                      -1.0,"Baryon", -5214));
+   "Ksi(b)-","Ksi(b)-",
+                                      -1.,kFALSE, -1.,
+                                     -1.0,"Baryon", 5132));
+   "Ksi(b)- bar","Ksi(b)- bar",
+                                      -1.,kFALSE, -1.,
+                                      1.0,"Baryon", -5132));
+//-----------------------------------------------------------------------------
+   "a(0)(980)0","M036",
+                                      .9824,kTRUE, .0,
+                                     0.0,"Meson", 10111));
+   "b(1)(1235)0","M011",
+                                      1.231,kFALSE, .142,
+                                     0.0,"Meson", 10113));
+   "pi(2)(1670)0","M034",
+                                      1.67,kFALSE, .2399999,
+                                     0.0,"Meson", 10115));
+   "a(0)(980)+","M036",
+                                      .9824,kTRUE, .0,
+                                     0.0,"Meson", 10211));
+   "a(0)(980)-","M036",
+                                      .9824,kTRUE, .0,
+                                     0.0,"Meson", -10211));
+   "b(1)(1235)+","M011",
+                                      1.231,kFALSE, .142,
+                                     0.0,"Meson", 10213));
+   "b(1)(1235)-","M011",
+                                      1.231,kFALSE, .142,
+                                     0.0,"Meson", -10213));
+   "pi(2)(1670)+","M034",
+                                      1.67,kFALSE, .2399999,
+                                     0.0,"Meson", 10215));
+   "pi(2)(1670)-","M034",
+                                      1.67,kFALSE, .2399999,
+                                     0.0,"Meson", -10215));
+   "f(0)(980)0","M003",
+                                      .98,kTRUE, .0,
+                                     0.0,"Meson", 10221));
+   "h(1)(1170)0","M030",
+                                      1.17,kFALSE, .36,
+                                     0.0,"Meson", 10223));
+   "K(0)*(1430)0","M019",
+                                      1.429,kFALSE, .287,
+                                     0.0,"Meson", 10311));
+   "K(0)*(1430)0 bar","M019",
+                                      1.429,kFALSE, .287,
+                                     0.0,"Meson", -10311));
+   "K(1)(1270)0","M028",
+                                      1.272,kFALSE, 9.00000E-02,
+                                     0.0,"Meson", 10313));
+   "K(1)(1270)0 bar","M028",
+                                      1.272,kFALSE, 9.00000E-02,
+                                     0.0,"Meson", -10313));
+   "K(2)(1770)0","M023",
+                                      1.773,kFALSE, .186,
+                                     0.0,"Meson", 10315));
+   "K(2)(1770)0 bar","M023",
+                                      1.773,kFALSE, .186,
+                                     0.0,"Meson", -10315));
+   "K(0)*(1430)+","M019",
+                                      1.429,kFALSE, .287,
+                                     0.0,"Meson", 10321));
+   "K(0)*(1430)-","M019",
+                                      1.429,kFALSE, .287,
+                                     0.0,"Meson", -10321));
+   "K(1)(1270)+","M028",
+                                      1.272,kFALSE, 9.00000E-02,
+                                     0.0,"Meson", 10323));
+   "K(1)(1270)-","M028",
+                                      1.272,kFALSE, 9.00000E-02,
+                                     0.0,"Meson", -10323));
+   "K(2)(1770)+","M023",
+                                      1.773,kFALSE, .186,
+                                     0.0,"Meson", 10325));
+   "K(2)(1770)-","M023",
+                                      1.773,kFALSE, .186,
+                                     0.0,"Meson", -10325));
+   "phi(1680)0","M067",
+                                      1.68,kFALSE, .15,
+                                     0.0,"Meson", 10333));
+   "D(1)(2420)0","M097",
+                                      2.4228,kFALSE, 1.80000E-02,
+                                     0.0,"Meson", 10423));
+   "D(s1)(2536)+","M121",
+                                      2.53535,kTRUE, .0,
+                                     0.0,"Meson", 10433));
+   "D(s1)(2536)-","M121",
+                                      2.53535,kTRUE, .0,
+                                     0.0,"Meson", -10433));
+   "chi(c0)(1P)0","M056",
+                                      3.4151,kFALSE, 1.40000E-02,
+                                     0.0,"Meson", 10441));
+   "chi(c1)(1P)0","M055",
+                                      3.51053,kFALSE, 8.80000E-04,
+                                     0.0,"Meson", 10443));
+   "chi(b0)(2P)0","M079",
+                                      10.23209,kTRUE, .0,
+                                     0.0,"Meson", 10551));
+   "chi(b1)(1P)0","M077",
+                                      9.8919,kTRUE, .0,
+                                     0.0,"Meson", 10553));
+   "chi(b2)(2P)0","M081",
+                                      10.2685,kTRUE, .0,
+                                     0.0,"Meson", 10555));
+   "Delta(1900)-","B030",
+                                      1.9,kFALSE, .2,
+                                     -1.,"Baryon", 11112));
+   "Delta(1900)+ bar","B030",
+                                      1.9,kFALSE, .2,
+                                     +1.,"Baryon", -11112));
+   "Delta(1700)-","B010",
+                                      1.7,kFALSE, .3,
+                                     -1.,"Baryon", 11114));
+   "Delta(1700)+ bar","B010",
+                                      1.7,kFALSE, .3,
+                                     +1.,"Baryon", -11114));
+   "Delta(1930)-","B013",
+                                      1.93,kFALSE, .3499999,
+                                     -1.,"Baryon", 11116));
+   "Delta(1930)+ bar","B013",
+                                      1.93,kFALSE, .3499999,
+                                     +1.,"Baryon", -11116));
+   "Delta(1900)0","B030",
+                                      1.9,kFALSE, .2,
+                                     0.0,"Baryon", 11212));
+   "Delta(1900)0 bar","B030",
+                                      1.9,kFALSE, .2,
+                                     0.0,"Baryon", -11212));
+   "Delta(1930)0","B013",
+                                      1.93,kFALSE, .3499999,
+                                     0.0,"Baryon", 11216));
+   "Delta(1930)0 bar","B013",
+                                      1.93,kFALSE, .3499999,
+                                     0.0,"Baryon", -11216));
+   "N(1440)0","B061",
+                                      1.44,kFALSE, .3499999,
+                                     0.0,"Baryon", 12112));
+   "N(1440)0 bar","B061",
+                                      1.44,kFALSE, .3499999,
+                                     0.0,"Baryon", -12112));
+   "Delta(1700)0","B010",
+                                      1.7,kFALSE, .3,
+                                     0.0,"Baryon", 12114));
+   "Delta(1700)0 bar","B010",
+                                      1.7,kFALSE, .3,
+                                     0.0,"Baryon", -12114));
+   "N(1680)0","B065",
+                                      1.68,kFALSE, .1299999,
+                                     0.0,"Baryon", 12116));
+   "N(1680)0 bar","B065",
+                                      1.68,kFALSE, .1299999,
+                                     0.0,"Baryon", -12116));
+   "Delta(1900)+","B030",
+                                      1.9,kFALSE, .2,
+                                     +1.,"Baryon", 12122));
+   "Delta(1900)- bar","B030",
+                                      1.9,kFALSE, .2,
+                                     -1.,"Baryon", -12122));
+   "Delta(1930)+","B013",
+                                      1.93,kFALSE, .3499999,
+                                     +1.,"Baryon", 12126));
+   "Delta(1930)- bar","B013",
+                                      1.93,kFALSE, .3499999,
+                                     -1.,"Baryon", -12126));
+   "N(1440)+","B061",
+                                      1.44,kFALSE, .3499999,
+                                     +1.,"Baryon", 12212));
+   "N(1440)- bar","B061",
+                                      1.44,kFALSE, .3499999,
+                                     -1.,"Baryon", -12212));
+   "Delta(1700)+","B010",
+                                      1.7,kFALSE, .3,
+                                     +1.,"Baryon", 12214));
+   "Delta(1700)- bar","B010",
+                                      1.7,kFALSE, .3,
+                                     -1.,"Baryon", -12214));
+   "N(1680)+","B065",
+                                      1.68,kFALSE, .1299999,
+                                     +1.,"Baryon", 12216));
+   "N(1680)- bar","B065",
+                                      1.68,kFALSE, .1299999,
+                                     -1.,"Baryon", -12216));
+   "Delta(1900)++","B030",
+                                      1.9,kFALSE, .2,
+                                     +2.,"Baryon", 12222));
+   "Delta(1900)-- bar","B030",
+                                      1.9,kFALSE, .2,
+                                     -2.,"Baryon", -12222));
+   "Delta(1700)++","B010",
+                                      1.7,kFALSE, .3,
+                                     +2.,"Baryon", 12224));
+   "Delta(1700)-- bar","B010",
+                                      1.7,kFALSE, .3,
+                                     -2.,"Baryon", -12224));
+   "Delta(1930)++","B013",
+                                      1.93,kFALSE, .3499999,
+                                     +2.,"Baryon", 12226));
+   "Delta(1930)-- bar","B013",
+                                      1.93,kFALSE, .3499999,
+                                     -2.,"Baryon", -12226));
+   "Sigma(1660)-","B079",
+                                      1.66,kFALSE, .1,
+                                     -1.,"Baryon", 13112));
+   "Sigma(1660)+ bar","B079",
+                                      1.66,kFALSE, .1,
+                                     +1.,"Baryon", -13112));
+   "Sigma(1670)-","B051",
+                                      1.67,kFALSE, 6.00000E-02,
+                                     -1.,"Baryon", 13114));
+   "Sigma(1670)+ bar","B051",
+                                      1.67,kFALSE, 6.00000E-02,
+                                     +1.,"Baryon", -13114));
+   "Sigma(1915)-","B046",
+                                      1.915,kFALSE, .1199999,
+                                     -1.,"Baryon", 13116));
+   "Sigma(1915)+ bar","B046",
+                                      1.915,kFALSE, .1199999,
+                                     +1.,"Baryon", -13116));
+   "Lambda(1405)0","B037",
+                                      1.407,kFALSE, 5.00000E-02,
+                                     0.0,"Baryon", 13122));
+   "Lambda(1405)0 bar","B037",
+                                      1.407,kFALSE, 5.00000E-02,
+                                     0.0,"Baryon", -13122));
+   "Lambda(1690)0","B055",
+                                      1.69,kFALSE, 6.00000E-02,
+                                     0.0,"Baryon", 13124));
+   "Lambda(1690)0 bar","B055",
+                                      1.69,kFALSE, 6.00000E-02,
+                                     0.0,"Baryon", -13124));
+   "Lambda(1830)0","B056",
+                                      1.83,kFALSE, 9.50000E-02,
+                                     0.0,"Baryon", 13126));
+   "Lambda(1830)0 bar","B056",
+                                      1.83,kFALSE, 9.50000E-02,
+                                     0.0,"Baryon", -13126));
+   "Sigma(1660)0","B079",
+                                      1.66,kFALSE, .1,
+                                     0.0,"Baryon", 13212));
+   "Sigma(1660)0 bar","B079",
+                                      1.66,kFALSE, .1,
+                                     0.0,"Baryon", -13212));
+   "Sigma(1670)0","B051",
+                                      1.67,kFALSE, 6.00000E-02,
+                                     0.0,"Baryon", 13214));
+   "Sigma(1670)0 bar","B051",
+                                      1.67,kFALSE, 6.00000E-02,
+                                     0.0,"Baryon", -13214));
+   "Sigma(1915)0","B046",
+                                      1.915,kFALSE, .1199999,
+                                     0.0,"Baryon", 13216));
+   "Sigma(1915)0 bar","B046",
+                                      1.915,kFALSE, .1199999,
+                                     0.0,"Baryon", -13216));
+   "Sigma(1660)+","B079",
+                                      1.66,kFALSE, .1,
+                                     +1.,"Baryon", 13222));
+   "Sigma(1660)- bar","B079",
+                                      1.66,kFALSE, .1,
+                                     -1.,"Baryon", -13222));
+   "Sigma(1670)+","B051",
+                                      1.67,kFALSE, 6.00000E-02,
+                                     +1.,"Baryon", 13224));
+   "Sigma(1670)- bar","B051",
+                                      1.67,kFALSE, 6.00000E-02,
+                                     -1.,"Baryon", -13224));
+   "Sigma(1915)+","B046",
+                                      1.915,kFALSE, .1199999,
+                                     +1.,"Baryon", 13226));
+   "Sigma(1915)- bar","B046",
+                                      1.915,kFALSE, .1199999,
+                                     -1.,"Baryon", -13226));
+   "Xi(1820)-","B050",
+                                      1.823,kFALSE, 2.40000E-02,
+                                     -1.,"Baryon", 13314));
+   "Xi(1820)+ bar","B050",
+                                      1.823,kFALSE, 2.40000E-02,
+                                     +1.,"Baryon", -13314));
+   "Xi(1820)0","B050",
+                                      1.823,kFALSE, 2.40000E-02,
+                                     0.0,"Baryon", 13324));
+   "Xi(1820)0 bar","B050",
+                                      1.823,kFALSE, 2.40000E-02,
+                                     0.0,"Baryon", -13324));
+   "pi(1300)0","M058",
+                                      1.3,kTRUE, .0,
+                                     0.0,"Meson", 20111));
+   "a(1)(1260)0","M010",
+                                      1.23,kTRUE, .0,
+                                     0.0,"Meson", 20113));
+   "pi(1300)+","M058",
+                                      1.3,kTRUE, .0,
+                                     0.0,"Meson", 20211));
+   "pi(1300)-","M058",
+                                      1.3,kTRUE, .0,
+                                     0.0,"Meson", -20211));
+   "a(1)(1260)+","M010",
+                                      1.23,kTRUE, .0,
+                                     0.0,"Meson", 20213));
+   "a(1)(1260)-","M010",
+                                      1.23,kTRUE, .0,
+                                     0.0,"Meson", -20213));
+   "eta(1295)0","M037",
+                                      1.295,kFALSE, 5.30000E-02,
+                                     0.0,"Meson", 20221));
+   "f(1)(1285)0","M008",
+                                      1.282,kFALSE, 2.40000E-02,
+                                     0.0,"Meson", 20223));
+   "f(2)(2010)0","M106",
+                                      2.01,kFALSE, .2,
+                                     0.0,"Meson", 20225));
+   "K(1)(1400)0","M064",
+                                      1.402,kFALSE, .1739999,
+                                     0.0,"Meson", 20313));
+   "K(1)(1400)0 bar","M064",
+                                      1.402,kFALSE, .1739999,
+                                     0.0,"Meson", -20313));
+   "K(2)(1820)0","M146",
+                                      1.816,kFALSE, .2759999,
+                                     0.0,"Meson", 20315));
+   "K(2)(1820)0 bar","M146",
+                                      1.816,kFALSE, .2759999,
+                                     0.0,"Meson", -20315));
+   "K(1)(1400)+","M064",
+                                      1.402,kFALSE, .1739999,
+                                     0.0,"Meson", 20323));
+   "K(1)(1400)-","M064",
+                                      1.402,kFALSE, .1739999,
+                                     0.0,"Meson", -20323));
+   "K(2)(1820)+","M146",
+                                      1.816,kFALSE, .2759999,
+                                     0.0,"Meson", 20325));
+   "K(2)(1820)-","M146",
+                                      1.816,kFALSE, .2759999,
+                                     0.0,"Meson", -20325));
+   "psi(2S)0","M071",
+                                      3.686,kFALSE, 2.77000E-04,
+                                     0.0,"Meson", 20443));
+   "Upsilon(2S)0","M052",
+                                      10.0233,kFALSE, 4.40000E-05,
+                                     0.0,"Meson", 20553));
+   "Delta(1910)-","B012",
+                                      1.91,kFALSE, .25,
+                                     -1.,"Baryon", 21112));
+   "Delta(1910)+ bar","B012",
+                                      1.91,kFALSE, .25,
+                                     +1.,"Baryon", -21112));
+   "Delta(1920)-","B117",
+                                      1.92,kFALSE, .2,
+                                     -1.,"Baryon", 21114));
+   "Delta(1920)+ bar","B117",
+                                      1.92,kFALSE, .2,
+                                     +1.,"Baryon", -21114));
+   "Delta(1910)0","B012",
+                                      1.91,kFALSE, .25,
+                                     0.0,"Baryon", 21212));
+   "Delta(1910)0 bar","B012",
+                                      1.91,kFALSE, .25,
+                                     0.0,"Baryon", -21212));
+   "N(1700)0","B018",
+                                      1.7,kFALSE, .1,
+                                     0.0,"Baryon", 21214));
+   "N(1700)0 bar","B018",
+                                      1.7,kFALSE, .1,
+                                     0.0,"Baryon", -21214));
+   "N(1535)0","B063",
+                                      1.535,kFALSE, .15,
+                                     0.0,"Baryon", 22112));
+   "N(1535)0 bar","B063",
+                                      1.535,kFALSE, .15,
+                                     0.0,"Baryon", -22112));
+   "Delta(1920)0","B117",
+                                      1.92,kFALSE, .2,
+                                     0.0,"Baryon", 22114));
+   "Delta(1920)0 bar","B117",
+                                      1.92,kFALSE, .2,
+                                     0.0,"Baryon", -22114));
+   "Delta(1910)+","B012",
+                                      1.91,kFALSE, .25,
+                                     +1.,"Baryon", 22122));
+   "Delta(1910)- bar","B012",
+                                      1.91,kFALSE, .25,
+                                     -1.,"Baryon", -22122));
+   "N(1700)+","B018",
+                                      1.7,kFALSE, .1,
+                                     +1.,"Baryon", 22124));
+   "N(1700)- bar","B018",
+                                      1.7,kFALSE, .1,
+                                     -1.,"Baryon", -22124));
+   "N(1535)+","B063",
+                                      1.535,kFALSE, .15,
+                                     +1.,"Baryon", 22212));
+   "N(1535)- bar","B063",
+                                      1.535,kFALSE, .15,
+                                     -1.,"Baryon", -22212));
+   "Delta(1920)+","B117",
+                                      1.92,kFALSE, .2,
+                                     +1.,"Baryon", 22214));
+   "Delta(1920)- bar","B117",
+                                      1.92,kFALSE, .2,
+                                     -1.,"Baryon", -22214));
+   "Delta(1910)++","B012",
+                                      1.91,kFALSE, .25,
+                                     +2.,"Baryon", 22222));
+   "Delta(1910)-- bar","B012",
+                                      1.91,kFALSE, .25,
+                                     -2.,"Baryon", -22222));
+   "Delta(1920)++","B117",
+                                      1.92,kFALSE, .2,
+                                     +2.,"Baryon", 22224));
+   "Delta(1920)-- bar","B117",
+                                      1.92,kFALSE, .2,
+                                     -2.,"Baryon", -22224));
+   "Sigma(1750)-","B057",
+                                      1.75,kFALSE, 9.00000E-02,
+                                     -1.,"Baryon", 23112));
+   "Sigma(1750)+ bar","B057",
+                                      1.75,kFALSE, 9.00000E-02,
+                                     +1.,"Baryon", -23112));
+   "Sigma(1940)-","B098",
+                                      1.94,kFALSE, .2199999,
+                                     -1.,"Baryon", 23114));
+   "Sigma(1940)+ bar","B098",
+                                      1.94,kFALSE, .2199999,
+                                     +1.,"Baryon", -23114));
+   "Lambda(1600)0","B101",
+                                      1.6,kFALSE, .15,
+                                     0.0,"Baryon", 23122));
+   "Lambda(1600)0 bar","B101",
+                                      1.6,kFALSE, .15,
+                                     0.0,"Baryon", -23122));
+   "Lambda(1890)0","B060",
+                                      1.89,kFALSE, .1,
+                                     0.0,"Baryon", 23124));
+   "Lambda(1890)0 bar","B060",
+                                      1.89,kFALSE, .1,
+                                     0.0,"Baryon", -23124));
+   "Lambda(2110)0","B035",
+                                      2.11,kFALSE, .2,
+                                     0.0,"Baryon", 23126));
+   "Lambda(2110)0 bar","B035",
+                                      2.11,kFALSE, .2,
+                                     0.0,"Baryon", -23126));
+   "Sigma(1750)0","B057",
+                                      1.75,kFALSE, 9.00000E-02,
+                                     0.0,"Baryon", 23212));
+   "Sigma(1750)0 bar","B057",
+                                      1.75,kFALSE, 9.00000E-02,
+                                     0.0,"Baryon", -23212));
+   "Sigma(1940)0","B098",
+                                      1.94,kFALSE, .2199999,
+                                     0.0,"Baryon", 23214));
+   "Sigma(1940)0 bar","B098",
+                                      1.94,kFALSE, .2199999,
+                                     0.0,"Baryon", -23214));
+   "Sigma(1750)+","B057",
+                                      1.75,kFALSE, 9.00000E-02,
+                                     +1.,"Baryon", 23222));
+   "Sigma(1750)- bar","B057",
+                                      1.75,kFALSE, 9.00000E-02,
+                                     -1.,"Baryon", -23222));
+   "Sigma(1940)+","B098",
+                                      1.94,kFALSE, .2199999,
+                                     +1.,"Baryon", 23224));
+   "Sigma(1940)- bar","B098",
+                                      1.94,kFALSE, .2199999,
+                                     -1.,"Baryon", -23224));
+   "rho(1700)0","M065",
+                                      1.7,kFALSE, .23,
+                                     0.0,"Meson", 30113));
+   "rho(1700)+","M065",
+                                      1.7,kFALSE, .23,
+                                     0.0,"Meson", 30213));
+   "rho(1700)-","M065",
+                                      1.7,kFALSE, .23,
+                                     0.0,"Meson", -30213));
+   "f(1)(1420)0","M006",
+                                      1.4268,kFALSE, 5.20000E-02,
+                                     0.0,"Meson", 30223));
+   "f(2)(2300)0","M107",
+                                      2.297,kFALSE, .15,
+                                     0.0,"Meson", 30225));
+   "K*(1410)0","M094",
+                                      1.412,kFALSE, .2269999,
+                                     0.0,"Meson", 30313));
+   "K*(1410)0 bar","M094",
+                                      1.412,kFALSE, .2269999,
+                                     0.0,"Meson", -30313));
+   "K*(1410)+","M094",
+                                      1.412,kFALSE, .2269999,
+                                     0.0,"Meson", 30323));
+   "K*(1410)-","M094",
+                                      1.412,kFALSE, .2269999,
+                                     0.0,"Meson", -30323));
+   "psi(3770)0","M053",
+                                      3.7699,kFALSE, 2.36000E-02,
+                                     0.0,"Meson", 30443));
+   "Upsilon(3S)0","M048",
+                                      10.35529,kFALSE, 2.63000E-05,
+                                     0.0,"Meson", 30553));
+   "Delta(1600)-","B019",
+                                      1.6,kFALSE, .3499999,
+                                     -1.,"Baryon", 31114));
+   "Delta(1600)+ bar","B019",
+                                      1.6,kFALSE, .3499999,
+                                     +1.,"Baryon", -31114));
+   "N(1720)0","B015",
+                                      1.72,kFALSE, .15,
+                                     0.0,"Baryon", 31214));
+   "N(1720)0 bar","B015",
+                                      1.72,kFALSE, .15,
+                                     0.0,"Baryon", -31214));
+   "N(1650)0","B066",
+                                      1.65,kFALSE, .15,
+                                     0.0,"Baryon", 32112));
+   "N(1650)0 bar","B066",
+                                      1.65,kFALSE, .15,
+                                     0.0,"Baryon", -32112));
+   "Delta(1600)0","B019",
+                                      1.6,kFALSE, .3499999,
+                                     0.0,"Baryon", 32114));
+   "Delta(1600)0 bar","B019",
+                                      1.6,kFALSE, .3499999,
+                                     0.0,"Baryon", -32114));
+   "N(1720)+","B015",
+                                      1.72,kFALSE, .15,
+                                     +1.,"Baryon", 32124));
+   "N(1720)- bar","B015",
+                                      1.72,kFALSE, .15,
+                                     -1.,"Baryon", -32124));
+   "N(1650)+","B066",
+                                      1.65,kFALSE, .15,
+                                     +1.,"Baryon", 32212));
+   "N(1650)- bar","B066",
+                                      1.65,kFALSE, .15,
+                                     -1.,"Baryon", -32212));
+   "Delta(1600)+","B019",
+                                      1.6,kFALSE, .3499999,
+                                     +1.,"Baryon", 32214));
+   "Delta(1600)- bar","B019",
+                                      1.6,kFALSE, .3499999,
+                                     -1.,"Baryon", -32214));
+   "Delta(1600)++","B019",
+                                      1.6,kFALSE, .3499999,
+                                     +2.,"Baryon", 32224));
+   "Delta(1600)-- bar","B019",
+                                      1.6,kFALSE, .3499999,
+                                     -2.,"Baryon", -32224));
+   "Lambda(1670)0","B040",
+                                      1.67,kFALSE, 3.50000E-02,
+                                     0.0,"Baryon", 33122));
+   "Lambda(1670)0 bar","B040",
+                                      1.67,kFALSE, 3.50000E-02,
+                                     0.0,"Baryon", -33122));
+   "rho(1450)0","M105",
+                                      1.465,kFALSE, .31,
+                                     0.0,"Meson", 40113));
+   "rho(1450)+","M105",
+                                      1.465,kFALSE, .31,
+                                     0.0,"Meson", 40213));
+   "rho(1450)-","M105",
+                                      1.465,kFALSE, .31,
+                                     0.0,"Meson", -40213));
+   "eta(1440)0","M027",
+                                      1.42,kFALSE, 6.00000E-02,
+                                     0.0,"Meson", 40221));
+   "f(1)(1510)0","M084",
+                                      1.512,kFALSE, 3.50000E-02,
+                                     0.0,"Meson", 40223));
+   "f(2)(2340)0","M108",
+                                      2.34,kFALSE, .3199999,
+                                     0.0,"Meson", 40225));
+   "K*(1680)0","M095",
+                                      1.714,kFALSE, .3199999,
+                                     0.0,"Meson", 40313));
+   "K*(1680)0 bar","M095",
+                                      1.714,kFALSE, .3199999,
+                                     0.0,"Meson", -40313));
+   "K*(1680)+","M095",
+                                      1.714,kFALSE, .3199999,
+                                     0.0,"Meson", 40323));
+   "K*(1680)-","M095",
+                                      1.714,kFALSE, .3199999,
+                                     0.0,"Meson", -40323));
+   "psi(4040)0","M072",
+                                      4.04,kFALSE, 5.20000E-02,
+                                     0.0,"Meson", 40443));
+   "Upsilon(4S)0","M047",
+                                      10.57999,kFALSE, 2.38000E-02,
+                                     0.0,"Meson", 40553));
+   "N(1710)0","B014",
+                                      1.71,kFALSE, .1,
+                                     0.0,"Baryon", 42112));
+   "N(1710)0 bar","B014",
+                                      1.71,kFALSE, .1,
+                                     0.0,"Baryon", -42112));
+   "N(1710)+","B014",
+                                      1.71,kFALSE, .1,
+                                     +1.,"Baryon", 42212));
+   "N(1710)- bar","B014",
+                                      1.71,kFALSE, .1,
+                                     -1.,"Baryon", -42212));
+   "Lambda(1800)0","B036",
+                                      1.8,kFALSE, .3,
+                                     0.0,"Baryon", 43122));
+   "Lambda(1800)0 bar","B036",
+                                      1.8,kFALSE, .3,
+                                     0.0,"Baryon", -43122));
+   "f(0)(1590)0","M096",
+                                      1.581,kFALSE, .18,
+                                     0.0,"Meson", 50221));
+   "omega(1420)0","M125",
+                                      1.419,kFALSE, .17,
+                                     0.0,"Meson", 50223));
+   "psi(4160)0","M025",
+                                      4.159,kFALSE, 7.80000E-02,
+                                     0.0,"Meson", 50443));
+   "Upsilon(10860)0","M092",
+                                      10.86499,kFALSE, .1099999,
+                                     0.0,"Meson", 50553));
+   "Lambda(1810)0","B077",
+                                      1.81,kFALSE, .15,
+                                     0.0,"Baryon", 53122));
+   "Lambda(1810)0 bar","B077",
+                                      1.81,kFALSE, .15,
+                                     0.0,"Baryon", -53122));
+   "f(J)(1710)0","M068",
+                                      1.709,kFALSE, .14,
+                                     0.0,"Meson", 60221));
+   "omega(1600)0","M126",
+                                      1.662,kFALSE, .28,
+                                     0.0,"Meson", 60223));
+   "psi(4415)0","M073",
+                                      4.415,kFALSE, 4.30000E-02,
+                                     0.0,"Meson", 60443));
+   "Upsilon(11020)0","M093",
+                                      11.019,kFALSE, 7.90000E-02,
+                                     0.0,"Meson", 60553));
+   "chi(b1)(2P)0","M080",
+                                      10.2552,kTRUE, .0,
+                                     0.0,"Meson", 70553));
+// End of the entry point of the pdg table conversion
+    "Rootino","",
+                                    0.0,kTRUE,
+                                    1.e38,0.0,"Artificial",0));
+
+           */
+
+
 #endif 
index e4af1d2..a1f116e 100644 (file)
@@ -1,5 +1,4 @@
 #include "AliDigit.h"
-#include "GParticle.h"
  
 ClassImp(AliDigit)
 
index 517fb5a..7191052 100644 (file)
@@ -32,7 +32,7 @@
 #include "AliDetector.h"
 #include "AliDisplay.h"
 #include "AliPoints.h"
-#include "GParticle.h"
+#include "TParticle.h"
 
 const Float_t ptcutmax  = 2;
 const Float_t etacutmax = 1.5;
@@ -258,12 +258,12 @@ void AliDisplay::ShowTrack(Int_t idx) {
 //       fPad->Update();
 //       fPad->Modified();
          TClonesArray *particles=gAlice->Particles();
-         GParticle *p = (GParticle*)particles->UncheckedAt(idx);
+         TParticle *p = (TParticle*)particles->UncheckedAt(idx);
          printf("\nTrack index %d\n",idx);
-         printf("Particle ID %d\n",p->GetKF());
-         printf("Parent %d\n",p->GetParent());
-         printf("First child %d\n",p->GetFirstChild());
-         printf("Px,Py,Pz %f %f %f\n",p->GetPx(),p->GetPy(),p->GetPz());
+         printf("Particle ID %d\n",p->GetPdgCode());
+         printf("Parent %d\n",p->GetFirstMother());
+         printf("First child %d\n",p->GetFirstDaughter());
+         printf("Px,Py,Pz %f %f %f\n",p->Px(),p->Py(),p->Pz());
          return;
       }
    }
@@ -463,7 +463,7 @@ void AliDisplay::DrawHits()
    Float_t cutmin, cutmax, etamin, etamax, pmom, smin, smax, eta, theta, r;
    Float_t *pxyz;
    Int_t ntracks,track;
-   GParticle *particle;
+   TParticle *particle;
    TObjArray *points;
    AliPoints *pm;
       
@@ -495,7 +495,7 @@ void AliDisplay::DrawHits()
          if (!pm) continue;
          particle = pm->GetParticle();
          if (!particle) continue;
-         pmom = particle->GetMomentum();
+         pmom = particle->P();
          if (pmom < cutmin) continue;
          if (pmom > cutmax) continue;
          // as a first approximation, take eta of first point
index 5290861..cf5bd39 100644 (file)
@@ -1,5 +1,5 @@
 #include "AliHit.h"
-#include "GParticle.h"
+#include "TParticle.h"
 #include "AliRun.h"
  
 ClassImp(AliHit)
@@ -14,7 +14,7 @@ AliHit::AliHit(Int_t shunt, Int_t track)
   TClonesArray &particles = *(gAlice->Particles());
   if(shunt) {
     int primary = gAlice->GetPrimary(track);
-    ((GParticle *)particles[primary])->SetBit(Keep_Bit);
+    ((TParticle *)particles[primary])->SetBit(Keep_Bit);
     fTrack=primary;
   } else {
     fTrack=track;
index 19b5327..11eb76c 100644 (file)
@@ -29,7 +29,7 @@
 //////////////////////////////////////////////////////////////
 
 #include "TMath.h"
-#include "TGeant3.h"
+#include "AliLego.h"
 #include "AliRun.h"
 #include "AliConst.h"
 
@@ -70,7 +70,9 @@ void AliLego::GenerateKinematics()
 // Create a geantino with kinematics corresponding to the current
 // bins in theta and phi.
    
-   const Int_t mpart = 48;
+  //
+  // Rootinos are 0
+   const Int_t mpart = 0;
    Float_t orig[3], pmom[3];
    Float_t t, cost, sint, cosp, sinp;
    
@@ -192,7 +194,7 @@ void AliLego::Run()
          pMC->Gtrigi();
          pMC->Gtrigc();
          GenerateKinematics();
-         pMC->Gtreve();
+         pMC->Gtreve_root();
 
          thed = fCurTheta*kRaddeg;
          phid = fCurPhi*kRaddeg;
index 3ce2a44..8d184cc 100644 (file)
@@ -28,6 +28,9 @@ public:
   virtual Int_t   CurrentVolOff(Int_t, Text_t*, Int_t& ) const =0;
   virtual Int_t   NofVolumes() const =0;
   virtual Int_t   VolId(Text_t*) const =0;
+  virtual Int_t   IdFromPDG(Int_t) const =0;
+  virtual Int_t   PDGFromId(Int_t) const =0;
+  virtual void    DefineParticles() = 0;
   virtual void    TrackPosition(Float_t*) const =0;
   virtual void    TrackMomentum(Float_t*) const =0;
   virtual Float_t TrackCharge() const =0;
@@ -102,12 +105,12 @@ public:
   virtual  void  Gdhead(Int_t, const char*, Float_t=0)=0;   
   virtual  void  Gdman(Float_t, Float_t, const char*)=0;
   virtual  void  Gsord(const char *name, Int_t iax)=0;
-  virtual  void  Gpart()=0;
   virtual  void  Ggclos()=0;
   virtual  void  SetColors()=0;
   virtual  void  Gphysi()=0;
   virtual  void  Gtrigi()=0;
   virtual  void  Gtreve()=0;
+  virtual  void  Gtreve_root()=0;
   virtual  void  Gtrigc()=0;
   virtual  void  Gtrig()=0;
   virtual  void  Gckmat(Int_t, char*)=0;
index e430917..f0eb412 100644 (file)
@@ -77,7 +77,7 @@ void AliPoints::DumpParticle()
   //
   //   Dump particle corresponding to this point
   //
-  GParticle *particle = GetParticle();
+  TParticle *particle = GetParticle();
   if (particle) particle->Dump();
 }
 
@@ -106,7 +106,7 @@ const Text_t *AliPoints::GetName() const
   //
   // Return name of the Geant3 particle corresponding to this point
   //
-  GParticle *particle = GetParticle();
+  TParticle *particle = GetParticle();
   if (!particle) return "Particle";
   return particle->GetName();
 }
@@ -125,7 +125,7 @@ Text_t *AliPoints::GetObjectInfo(Int_t, Int_t)
 }
 
 //_____________________________________________________________________________
-GParticle *AliPoints::GetParticle() const
+TParticle *AliPoints::GetParticle() const
 {
   //
   //   Returns pointer to particle index in AliRun::fParticles
@@ -133,7 +133,7 @@ GParticle *AliPoints::GetParticle() const
   TClonesArray *particles = gAlice->Particles();
   Int_t nparticles = particles->GetEntriesFast();
   if (fIndex < 0 || fIndex >= nparticles) return 0;
-  return (GParticle*)particles->UncheckedAt(fIndex);
+  return (TParticle*)particles->UncheckedAt(fIndex);
 }
 
 //_____________________________________________________________________________
@@ -142,7 +142,7 @@ void AliPoints::InspectParticle()
   //
   //   Inspect particle corresponding to this point
   //
-  GParticle *particle = GetParticle();
+  TParticle *particle = GetParticle();
   if (particle) particle->Inspect();
 }
 
index 031b119..0d20ba4 100644 (file)
@@ -3,7 +3,7 @@
 
 #include "TPolyMarker3D.h"
 #include "AliDetector.h"
-#include "GParticle.h"
+#include "TParticle.h"
 
 class AliPoints : public TPolyMarker3D {
 protected:
@@ -18,7 +18,7 @@ public:
   virtual void          ExecuteEvent(Int_t event, Int_t px, Int_t py);
   AliDetector          *GetDetector() {return fDetector;}
   Int_t                 GetIndex() {return fIndex;}
-  GParticle            *GetParticle() const;
+  TParticle            *GetParticle() const;
   virtual const Text_t *GetName() const;
   virtual void          InspectParticle(); // *MENU*
   virtual void          DumpParticle(); // *MENU*
index a414845..0be6eab 100644 (file)
 #include <TRandom.h>
 #include <TBRIK.h> 
 #include <TNode.h> 
-#include <AliMC.h> 
 #include <TCint.h> 
 #include <TSystem.h>
 
-#include "GParticle.h"
+#include "TParticle.h"
 #include "AliRun.h"
-#include "AliModule.h"
 #include "AliDisplay.h"
 
 #include "AliCallf77.h" 
@@ -52,22 +50,18 @@ static AliHeader *header;
 # define rxstrak rxstrak_
 # define rxkeep  rxkeep_ 
 # define rxouth  rxouth_
-# define sxpart  sxpart_
 #else
 
 # define rxgtrak RXGTRAK 
 # define rxstrak RXSTRAK 
 # define rxkeep  RXKEEP  
 # define rxouth  RXOUTH
-# define sxpart  SXPART
 #endif
 
 static TArrayF sEventEnergy;
 static TArrayF sSummEnergy;
 static TArrayF sSum2Energy;
 
-extern "C" void type_of_call sxpart();
-
 ClassImp(AliRun)
 
 //_____________________________________________________________________________
@@ -99,6 +93,7 @@ AliRun::AliRun()
   fIdtmed    = 0;
   fInitDone  = kFALSE;
   fLego      = 0;
+  fPDGDB     = 0;        //Particle factory object!
 }
 
 //_____________________________________________________________________________
@@ -144,7 +139,7 @@ AliRun::AliRun(const char *name, const char *title)
   fEvent     = 0;
   //
   // Create the particle stack
-  fParticles = new TClonesArray("GParticle",100);
+  fParticles = new TClonesArray("TParticle",100);
   
   fDisplay = 0;
   //
@@ -184,6 +179,9 @@ AliRun::AliRun(const char *name, const char *title)
   for(i=0;i<1000;i++) (*fImedia)[i]=-99;
   fIdtmed = new Int_t[fNdets*100];
   for(i=0;i<fNdets*100;i++) fIdtmed[i]=0;
+  //
+  // Make particles
+  fPDGDB     = TDatabasePDG::Instance();        //Particle factory object!
 }
 
 //_____________________________________________________________________________
@@ -298,16 +296,16 @@ void AliRun::CleanParents()
 {
   //
   // Clean Particles stack.
-  // Set parent/child relations
+  // Set parent/daughter relations
   //
   TClonesArray &particles = *(gAlice->Particles());
-  GParticle *part;
+  TParticle *part;
   int i;
   for(i=0; i<fNtrack; i++) {
-    part = (GParticle *)particles.UncheckedAt(i);
-    if(!part->TestBit(Children_Bit)) {
-      part->SetFirstChild(-1);
-      part->SetLastChild(-1);
+    part = (TParticle *)particles.UncheckedAt(i);
+    if(!part->TestBit(Daughters_Bit)) {
+      part->SetFirstDaughter(-1);
+      part->SetLastDaughter(-1);
     }
   }
 }
@@ -329,7 +327,7 @@ void AliRun::DumpPart (Int_t i)
   // Dumps particle i in the stack
   //
   TClonesArray &particles = *fParticles;
-  ((GParticle*) particles[i])->Dump();
+  ((TParticle*) particles[i])->Print();
 }
 
 //_____________________________________________________________________________
@@ -343,7 +341,7 @@ void AliRun::DumpPStack ()
         "\n\n=======================================================================\n");
   for (Int_t i=0;i<fNtrack;i++) 
     {
-      printf("-> %d ",i); ((GParticle*) particles[i])->Dump();
+      printf("-> %d ",i); ((TParticle*) particles[i])->Print();
       printf("--------------------------------------------------------------\n");
     }
   printf(
@@ -516,11 +514,11 @@ void AliRun::FlagTrack(Int_t track)
   // Flags a track and all its family tree to be kept
   //
   int curr;
-  GParticle *particle;
+  TParticle *particle;
 
   curr=track;
   while(1) {
-    particle=(GParticle*)fParticles->UncheckedAt(curr);
+    particle=(TParticle*)fParticles->UncheckedAt(curr);
     
     // If the particle is flagged the three from here upward is saved already
     if(particle->TestBit(Keep_Bit)) return;
@@ -529,7 +527,7 @@ void AliRun::FlagTrack(Int_t track)
     particle->SetBit(Keep_Bit);
     
     // Move to father if any
-    if((curr=particle->GetParent())==-1) return;
+    if((curr=particle->GetFirstMother())==-1) return;
   }
 }
  
@@ -736,26 +734,28 @@ void AliRun::GetNextTrack(Int_t &mtrack, Int_t &ipart, Float_t *pmom,
   //
   // Return next track from stack of particles
   //
+  const TVector3 *pol;
   fCurrent=-1;
-  GParticle *track;
+  TParticle *track;
   for(Int_t i=fNtrack-1; i>=0; i--) {
-    track=(GParticle*) fParticles->UncheckedAt(i);
+    track=(TParticle*) fParticles->UncheckedAt(i);
     if(!track->TestBit(Done_Bit)) {
       //
       // The track has not yet been processed
       fCurrent=i;
-      ipart=track->GetKF();
-      pmom[0]=track->GetPx();
-      pmom[1]=track->GetPy(); 
-      pmom[2]=track->GetPz();
-      e     =track->GetEnergy();
-      vpos[0]=track->GetVx();
-      vpos[1]=track->GetVy();
-      vpos[2]=track->GetVz();
-      polar[0]=track->GetPolx();
-      polar[1]=track->GetPoly();
-      polar[2]=track->GetPolz();
-      tof=track->GetTime();
+      ipart=track->GetPdgCode();
+      pmom[0]=track->Px();
+      pmom[1]=track->Py(); 
+      pmom[2]=track->Pz();
+      e     =track->Energy();
+      vpos[0]=track->Vx();
+      vpos[1]=track->Vy();
+      vpos[2]=track->Vz();
+      pol = track->GetPolarisation();
+      polar[0]=pol->X();
+      polar[1]=pol->Y();
+      polar[2]=pol->Z();
+      tof=track->T();
       track->SetBit(Done_Bit);
       break;
     }
@@ -767,8 +767,8 @@ void AliRun::GetNextTrack(Int_t &mtrack, Int_t &ipart, Float_t *pmom,
   if (fCurrent >= nprimaries) return;
   if (fCurrent < nprimaries-1) {
     fTimer.Stop();
-    track=(GParticle*) fParticles->UncheckedAt(fCurrent+1);
-    track->SetProcessTime(fTimer.CpuTime());
+    track=(TParticle*) fParticles->UncheckedAt(fCurrent+1);
+    //    track->SetProcessTime(fTimer.CpuTime());
   }
   fTimer.Start();
 }
@@ -780,13 +780,13 @@ Int_t AliRun::GetPrimary(Int_t track)
   // return number of primary that has generated track
   //
   int current, parent;
-  GParticle *part;
+  TParticle *part;
   //
   parent=track;
   while (1) {
     current=parent;
-    part = (GParticle *)fParticles->UncheckedAt(current);
-    parent=part->GetParent();
+    part = (TParticle *)fParticles->UncheckedAt(current);
+    parent=part->GetFirstMother();
     if(parent<0) return current;
   }
 }
@@ -803,8 +803,7 @@ void AliRun::Init(const char *setup)
 
   AliMC* pMC = AliMC::GetMC();
 
-  pMC->Gpart();  //Create standard Geant particles
-  sxpart();        //Define additional particles
+  pMC->DefineParticles();  //Create standard MC particles
 
   TObject *objfirst, *objlast;
 
@@ -1072,7 +1071,7 @@ void AliRun::PurifyKine()
   //
   TClonesArray &particles = *fParticles;
   int nkeep=fHgwmk+1, parent, i;
-  GParticle *part, *partnew, *father;
+  TParticle *part, *partnew, *father;
   AliHit *OneHit;
   int *map = new int[particles.GetEntries()];
 
@@ -1084,7 +1083,7 @@ void AliRun::PurifyKine()
     if(i<=fHgwmk) map[i]=i ; else map[i] = -99 ;}
   // Second pass, build map between old and new numbering
   for(i=fHgwmk+1; i<fNtrack; i++) {
-    part = (GParticle *)particles.UncheckedAt(i);
+    part = (TParticle *)particles.UncheckedAt(i);
     if(part->TestBit(Keep_Bit)) {
       
       // This particle has to be kept
@@ -1092,35 +1091,35 @@ void AliRun::PurifyKine()
       if(i!=nkeep) {
        
        // Old and new are different, have to copy
-       partnew = (GParticle *)particles.UncheckedAt(nkeep);
+       partnew = (TParticle *)particles.UncheckedAt(nkeep);
        *partnew = *part;
       } else partnew = part;
       
       // as the parent is always *before*, it must be already
       // in place. This is what we are checking anyway!
-      if((parent=partnew->GetParent())>fHgwmk) {
+      if((parent=partnew->GetFirstMother())>fHgwmk) {
        if(map[parent]==-99) printf("map[%d] = -99!\n",parent);
-       partnew->SetParent(map[parent]);
+       partnew->SetFirstMother(map[parent]);
       }
       nkeep++;
     }
   }
   fNtrack=nkeep;
   
-  // Fix children information
+  // Fix daughters information
   for (i=fHgwmk+1; i<fNtrack; i++) {
-    part = (GParticle *)particles.UncheckedAt(i);
-    parent = part->GetParent();
-    father = (GParticle *)particles.UncheckedAt(parent);
-    if(father->TestBit(Children_Bit)) {
+    part = (TParticle *)particles.UncheckedAt(i);
+    parent = part->GetFirstMother();
+    father = (TParticle *)particles.UncheckedAt(parent);
+    if(father->TestBit(Daughters_Bit)) {
       
-      if(i<father->GetFirstChild()) father->SetFirstChild(i);
-      if(i>father->GetLastChild())  father->SetLastChild(i);
+      if(i<father->GetFirstDaughter()) father->SetFirstDaughter(i);
+      if(i>father->GetLastDaughter())  father->SetLastDaughter(i);
     } else {
-      // Iitialise children info for first pass
-      father->SetFirstChild(i);
-      father->SetLastChild(i);
-      father->SetBit(Children_Bit);
+      // Iitialise daughters info for first pass
+      father->SetFirstDaughter(i);
+      father->SetLastDaughter(i);
+      father->SetBit(Daughters_Bit);
     }
   }
   
@@ -1305,7 +1304,7 @@ void AliRun::SetCurrentTrack(Int_t track)
 }
  
 //_____________________________________________________________________________
-void AliRun::SetTrack(Int_t done, Int_t parent, Int_t ipart, Float_t *pmom,
+void AliRun::SetTrack(Int_t done, Int_t parent, Int_t pdg, Float_t *pmom,
                      Float_t *vpos, Float_t *polar, Float_t tof,
                      const char *mecha, Int_t &ntr, Float_t weight)
 { 
@@ -1315,7 +1314,7 @@ void AliRun::SetTrack(Int_t done, Int_t parent, Int_t ipart, Float_t *pmom,
   // done     0 if the track has to be transported
   //          1 if not
   // parent   identifier of the parent track. -1 for a primary
-  // ipart    particle code
+  // pdg    particle code
   // pmom     momentum GeV/c
   // vpos     position 
   // polar    polarisation 
@@ -1324,32 +1323,40 @@ void AliRun::SetTrack(Int_t done, Int_t parent, Int_t ipart, Float_t *pmom,
   // ntr      on output the number of the track stored
   //
   TClonesArray &particles = *fParticles;
-  GParticle *particle;
+  TParticle *particle;
   Float_t mass;
-  char pname[21];
-  const Int_t firstchild=-1;
-  const Int_t lastchild=-1;
+  const Int_t firstdaughter=-1;
+  const Int_t lastdaughter=-1;
   const Int_t KS=0;
-  const Float_t tlife=0;
+  //  const Float_t tlife=0;
   
-  AliMC::GetMC()->GetParticle(ipart,pname,mass);
+  //
+  // Here we get the static mass
+  // For MC is ok, but a more sophisticated method could be necessary
+  // if the calculated mass is required
+  // also, this method is potentially dangerous if the mass
+  // used in the MC is not the same of the PDG database
+  //
+  mass = TDatabasePDG::Instance()->GetParticle(pdg)->Mass();
   Float_t e=TMath::Sqrt(mass*mass+pmom[0]*pmom[0]+
                        pmom[1]*pmom[1]+pmom[2]*pmom[2]);
   
   //printf("Loading particle %s mass %f ene %f No %d ip %d pos %f %f %f mom %f %f %f KS %d m %s\n",
-  //pname,mass,e,fNtrack,ipart,vpos[0],vpos[1],vpos[2],pmom[0],pmom[1],pmom[2],KS,mecha);
+  //pname,mass,e,fNtrack,pdg,vpos[0],vpos[1],vpos[2],pmom[0],pmom[1],pmom[2],KS,mecha);
   
-  particle=new(particles[fNtrack]) GParticle(KS,ipart,parent,firstchild,
-                                            lastchild,pmom[0],pmom[1],pmom[2],
-                                            e,mass,vpos[0],vpos[1],vpos[2],
-                                            polar[0],polar[1],polar[2],tof,
-                                            tlife,mecha,weight);
+  particle=new(particles[fNtrack]) TParticle(pdg,KS,parent,-1,firstdaughter,
+                                            lastdaughter,pmom[0],pmom[1],pmom[2],
+                                            e,vpos[0],vpos[1],vpos[2],tof);
+  //                                        polar[0],polar[1],polar[2],tof,
+  //                                        mecha,weight);
+  ((TParticle*)particles[fNtrack])->SetPolarisation(TVector3(polar[0],polar[1],polar[2]));
+  ((TParticle*)particles[fNtrack])->SetWeight(weight);
   if(!done) particle->SetBit(Done_Bit);
   
   if(parent>=0) {
-    particle=(GParticle*) fParticles->UncheckedAt(parent);
-    particle->SetLastChild(fNtrack);
-    if(particle->GetFirstChild()<0) particle->SetFirstChild(fNtrack);
+    particle=(TParticle*) fParticles->UncheckedAt(parent);
+    particle->SetLastDaughter(fNtrack);
+    if(particle->GetFirstDaughter()<0) particle->SetFirstDaughter(fNtrack);
   } else { 
     //
     // This is a primary track. Set high water mark for this event
@@ -1369,7 +1376,7 @@ void AliRun::KeepTrack(const Int_t track)
   // flags a track to be kept
   //
   TClonesArray &particles = *fParticles;
-  ((GParticle*)particles[track])->SetBit(Keep_Bit);
+  ((TParticle*)particles[track])->SetBit(Keep_Bit);
 }
  
 //_____________________________________________________________________________
@@ -1672,6 +1679,7 @@ void AliRun::Streamer(TBuffer &R__b)
     R__b >> fTrRmax;
     R__b >> fTrZmax;
     R__b >> fGenerator;
+    R__b >> fPDGDB;        //Particle factory object!
   } else {
     R__b.WriteVersion(AliRun::IsA());
     TNamed::Streamer(R__b);
@@ -1687,6 +1695,7 @@ void AliRun::Streamer(TBuffer &R__b)
     R__b << fTrRmax;
     R__b << fTrZmax;
     R__b << fGenerator;
+    R__b << fPDGDB;        //Particle factory object!
   }
 } 
 
@@ -1714,7 +1723,9 @@ extern "C" void type_of_call  rxgtrak (Int_t &mtrack, Int_t &ipart, Float_t *pmo
   //      tof     Particle time of flight in seconds
   //
   Float_t polar[3];
-  gAlice->GetNextTrack(mtrack, ipart, pmom, e, vpos, polar, tof);
+  Int_t pdg;
+  gAlice->GetNextTrack(mtrack, pdg, pmom, e, vpos, polar, tof);
+  ipart = gMC->IdFromPDG(pdg);
   mtrack++;
 }
 
@@ -1753,7 +1764,8 @@ rxstrak (Int_t &keep, Int_t &parent, Int_t &ipart, Float_t *pmom,
   Float_t polar[3]={0.,0.,0.};
   for(int i=0; i<10 && i<cmlen; i++) mecha[i]=cmech[i];
   mecha[10]=0;
-  gAlice->SetTrack(keep, parent-1, ipart, pmom, vpos, polar, tof, mecha, ntr);
+  Int_t pdg=gMC->PDGFromId(ipart);
+  gAlice->SetTrack(keep, parent-1, pdg, pmom, vpos, polar, tof, mecha, ntr);
   ntr++;
 }
 
@@ -1769,7 +1781,7 @@ extern "C" void type_of_call  rxkeep(const Int_t &n)
       exit(1);
     }
   
-  ((GParticle*)(gAlice->Particles()->UncheckedAt(n-1)))->SetBit(Keep_Bit);
+  ((TParticle*)(gAlice->Particles()->UncheckedAt(n-1)))->SetBit(Keep_Bit);
 }
 
 //_____________________________________________________________________________
index e1f9c22..70e54f7 100644 (file)
@@ -6,6 +6,8 @@
 #include <TStopwatch.h>
 #include <TTree.h>
 #include <TGeometry.h>
+#include <TDatabasePDG.h>
+
 #include "AliDetector.h"
 #include "AliHeader.h"
 #include "AliMagF.h"
@@ -13,6 +15,8 @@
 #include "AliGenerator.h"
 #include "AliLego.h"
 
+enum {Keep_Bit=1, Daughters_Bit=2, Done_Bit=4};
+
 enum {kMaxModules = 25, kLenModuleName=7};
 
 class AliDisplay;
@@ -49,6 +53,7 @@ protected:
   Int_t        *fIdtmed;       //Array to contain media numbers
   Bool_t        fInitDone;     //true when initialisation done
   AliLego      *fLego;         //pointer to aliLego object if it exists
+  TDatabasePDG *fPDGDB;        //Particle factory object!
   
 public:
    // Creators - distructors
@@ -110,7 +115,7 @@ public:
    virtual  void  SetDisplay(AliDisplay *display) {fDisplay = display;}
    virtual  void  StepManager(Int_t id) const;
    virtual  void  SetField(Int_t type=2, Int_t version=1, Float_t scale=1, Float_t maxField=10, char*filename="$(ALICE_ROOT)/data/field01.dat");
-   virtual  void  SetTrack(Int_t done, Int_t parent, Int_t ipart, 
+   virtual  void  SetTrack(Int_t done, Int_t parent, Int_t pdg, 
                               Float_t *pmom, Float_t *vpos, Float_t *polar, 
                                Float_t tof, const char *mecha, Int_t &ntr,
                                Float_t weight=1);
@@ -124,6 +129,7 @@ public:
    virtual  void SetGenerator(AliGenerator *generator);
    virtual  void EnergySummary();
    virtual  Int_t* Idtmed() {return fIdtmed;}
+   virtual  const TDatabasePDG* PDGDB() const {return fPDGDB;}
 
   // Functions from GEOCAD
   //_______________________________________________________________________
index 08187c7..1bf9f06 100644 (file)
@@ -9,7 +9,7 @@ PACKAGE = STEER
 
 # C++ sources
 
-SRCS          = AliDetector.cxx  AliHeader.cxx    AliMagF.cxx GParticle.cxx \
+SRCS          = AliDetector.cxx  AliHeader.cxx    AliMagF.cxx \
                 AliDigit.cxx     AliHit.cxx       AliPoints.cxx \
                 AliDisplay.cxx   AliMC.cxx        AliRun.cxx AliGenerator.cxx \
                AliLego.cxx AliModule.cxx
index 827dec9..9862ff5 100644 (file)
@@ -13,7 +13,6 @@
 #pragma link C++ class  AliRun-;
 #pragma link C++ class  AliModule-;
 #pragma link C++ class  AliDetector-;
-#pragma link C++ class  GParticle;
 #pragma link C++ class  AliDigit;
 #pragma link C++ class  AliHit;
 #pragma link C++ class  AliHeader;
index 642e119..d16b14a 100644 (file)
@@ -15,6 +15,7 @@
 #include "TROOT.h" 
 #include "THIGZ.h" 
 #include "ctype.h" 
+#include <TDatabasePDG.h>
 #include "AliCallf77.h" 
  
 #ifndef WIN32 
@@ -57,6 +58,7 @@
 # define gsxyz   gsxyz_ 
 # define gtrack  gtrack_ 
 # define gtreve  gtreve_ 
+# define gtreve_root  gtreve_root_ 
 # define grndm   grndm_ 
 # define grndmq  grndmq_ 
 # define gdtom   gdtom_ 
 # define gsxyz   GSXYZ 
 # define gtrack  GTRACK 
 # define gtreve  GTREVE 
+# define gtreve_root  GTREVE_ROOT
 # define grndm   GRNDM
 # define grndmq  GRNDMQ
 # define gdtom   GDTOM 
@@ -268,6 +271,8 @@ extern "C"
 
   void type_of_call gtreve(); 
 
+  void type_of_call gtreve_root(); 
+
   void type_of_call grndm(Float_t *, const Int_t &); 
 
   void type_of_call grndmq(Int_t &, Int_t &, const Int_t &,
@@ -414,7 +419,7 @@ static Int_t defSize = 600;
 ClassImp(TGeant3) 
  
 //____________________________________________________________________________ 
-TGeant3::TGeant3() : AliMC()
+TGeant3::TGeant3()
 { 
   //
   // Default constructor
@@ -439,6 +444,9 @@ TGeant3::TGeant3(const char *title, Int_t nwgeant)
   //
   // Load Address of Geant3 commons    
   LoadAddress(); 
+  //
+  // Zero number of particles
+  fNPDGCodes=0;
 } 
 
 //____________________________________________________________________________ 
@@ -598,6 +606,282 @@ Int_t TGeant3::CurrentVolOff(Int_t off, Text_t *name, Int_t &copy) const
 }
 
 //_____________________________________________________________________________
+Int_t TGeant3::IdFromPDG(Int_t pdg) const 
+{
+  //
+  // Return Geant3 code from PDG and pseudo ENDF code
+
+  for(Int_t i=0;i<fNPDGCodes;++i)
+    if(pdg==fPDGCode[i]) return i;
+  return -1;
+}
+
+//_____________________________________________________________________________
+Int_t TGeant3::PDGFromId(Int_t id) const 
+{
+  if(id>0 && id<fNPDGCodes) return fPDGCode[id];
+  else return -1;
+}
+
+//_____________________________________________________________________________
+void TGeant3::DefineParticles() 
+{
+  //
+  // Define standard Geant 3 particles
+  Gpart();
+  //
+  // Load standard numbers for GEANT particles and PDG conversion
+  fPDGCode[fNPDGCodes++]=-99;   //  0 = unused location
+  fPDGCode[fNPDGCodes++]=22;    //  1 = photon
+  fPDGCode[fNPDGCodes++]=-11;   //  2 = positron
+  fPDGCode[fNPDGCodes++]=11;    //  3 = electron
+  fPDGCode[fNPDGCodes++]=12;    //  4 = neutrino e
+  fPDGCode[fNPDGCodes++]=-13;   //  5 = muon +
+  fPDGCode[fNPDGCodes++]=13;    //  6 = muon -
+  fPDGCode[fNPDGCodes++]=111;   //  7 = pi0
+  fPDGCode[fNPDGCodes++]=211;   //  8 = pi+
+  fPDGCode[fNPDGCodes++]=-211;  //  9 = pi-
+  fPDGCode[fNPDGCodes++]=130;   // 10 = Kaon Long
+  fPDGCode[fNPDGCodes++]=321;   // 11 = Kaon +
+  fPDGCode[fNPDGCodes++]=-321;  // 12 = Kaon -
+  fPDGCode[fNPDGCodes++]=2112;  // 13 = Neutron
+  fPDGCode[fNPDGCodes++]=2212;  // 14 = Proton
+  fPDGCode[fNPDGCodes++]=-2212; // 15 = Anti Proton
+  fPDGCode[fNPDGCodes++]=310;   // 16 = Kaon Short
+  fPDGCode[fNPDGCodes++]=221;   // 17 = Eta
+  fPDGCode[fNPDGCodes++]=3122;  // 18 = Lambda
+  fPDGCode[fNPDGCodes++]=3222;  // 19 = Sigma +
+  fPDGCode[fNPDGCodes++]=3212;  // 20 = Sigma 0
+  fPDGCode[fNPDGCodes++]=3112;  // 21 = Sigma -
+  fPDGCode[fNPDGCodes++]=3322;  // 22 = Xi0
+  fPDGCode[fNPDGCodes++]=3312;  // 23 = Xi-
+  fPDGCode[fNPDGCodes++]=3334;  // 24 = Omega-
+  fPDGCode[fNPDGCodes++]=-2112; // 25 = Anti Proton
+  fPDGCode[fNPDGCodes++]=-3122; // 26 = Anti Proton
+  fPDGCode[fNPDGCodes++]=-3222; // 27 = Anti Sigma -
+  fPDGCode[fNPDGCodes++]=-3212; // 28 = Anti Sigma 0
+  fPDGCode[fNPDGCodes++]=-3112; // 29 = Anti Sigma 0
+  fPDGCode[fNPDGCodes++]=-3322; // 30 = Anti Xi 0
+  fPDGCode[fNPDGCodes++]=-3312; // 31 = Anti Xi +
+  fPDGCode[fNPDGCodes++]=-3334; // 32 = Anti Omega +
+
+
+  Int_t mode[6];
+  Int_t kz, ipa;
+  Float_t bratio[6];
+
+  /* --- Define additional particles */
+  Gspart(33, "OMEGA(782)", 3, 0.782, 0., 7.836e-23);
+  fPDGCode[fNPDGCodes++]=223;   // 33 = Omega(782)
+  
+  Gspart(34, "PHI(1020)", 3, 1.019, 0., 1.486e-22);
+  fPDGCode[fNPDGCodes++]=333;   // 34 = PHI (1020)
+
+  Gspart(35, "D +", 4, 1.87, 1., 1.066e-12);
+  fPDGCode[fNPDGCodes++]=411;   // 35 = D+
+
+  Gspart(36, "D -", 4, 1.87, -1., 1.066e-12);
+  fPDGCode[fNPDGCodes++]=-411;  // 36 = D-
+
+  Gspart(37, "D 0", 3, 1.865, 0., 4.2e-13);
+  fPDGCode[fNPDGCodes++]=421;   // 37 = D0
+
+  Gspart(38, "ANTI D 0", 3, 1.865, 0., 4.2e-13);
+  fPDGCode[fNPDGCodes++]=-421;  // 38 = D0 bar
+
+  fPDGCode[fNPDGCodes++]=-99;  // 39 = unassigned
+
+  fPDGCode[fNPDGCodes++]=-99;  // 40 = unassigned
+
+  fPDGCode[fNPDGCodes++]=-99;  // 41 = unassigned
+
+  Gspart(42, "RHO +", 4, 0.768, 1., 4.353e-24);
+  fPDGCode[fNPDGCodes++]=213;   // 42 = RHO+
+
+  Gspart(43, "RHO -", 4, 0.768, -1., 4.353e-24);
+  fPDGCode[fNPDGCodes++]=-213;   // 40 = RHO-
+
+  Gspart(44, "RHO 0", 3, 0.768, 0., 4.353e-24);
+  fPDGCode[fNPDGCodes++]=113;   // 37 = D0
+
+  //
+  // Use ENDF-6 mapping for ions = 10000*z+10*a+iso
+  // and add 1 000 000
+  // and numbers above 5 000 000 for special applications
+  //
+
+  const Int_t kion=10000000;
+
+  const Int_t kspe=50000000;
+
+  TDatabasePDG *pdgDB = TDatabasePDG::Instance();
+
+  const Double_t autogev=0.9314943228;
+  const Double_t hslash = 1.0545726663e-27;
+  const Double_t erggev = 1/1.6021773349e-3;
+  const Double_t hshgev = hslash*erggev;
+  const Double_t yearstosec = 3600*24*365.25;
+
+
+  pdgDB->AddParticle("Deuteron","Deuteron",2*autogev+8.071e-3,kTRUE,
+                    0,1,"Ion",kion+10020);
+  fPDGCode[fNPDGCodes++]=kion+10020;   // 45 = Deuteron
+
+  pdgDB->AddParticle("Triton","Triton",3*autogev+14.931e-3,kFALSE,
+                    hshgev/(12.33*yearstosec),1,"Ion",kion+10030);
+  fPDGCode[fNPDGCodes++]=kion+10030;   // 46 = Triton
+
+  pdgDB->AddParticle("Alpha","Alpha",4*autogev+2.424e-3,kTRUE,
+                    hshgev/(12.33*yearstosec),2,"Ion",kion+20040);
+  fPDGCode[fNPDGCodes++]=kion+20040;   // 47 = Alpha
+
+  fPDGCode[fNPDGCodes++]=0;   // 48 = geantino mapped to rootino
+
+  pdgDB->AddParticle("HE3","HE3",3*autogev+14.931e-3,kFALSE,
+                    0,2,"Ion",kion+20030);
+  fPDGCode[fNPDGCodes++]=kion+20030;   // 49 = HE3
+
+  pdgDB->AddParticle("Cherenkov","Cherenkov",0,kFALSE,
+                    0,0,"Special",kspe+50);
+  fPDGCode[fNPDGCodes++]=kspe+50;   // 50 = Cherenkov
+
+/* --- Define additional decay modes --- */
+/* --- omega(783) --- */
+    for (kz = 0; kz < 6; ++kz) {
+       bratio[kz] = 0.;
+       mode[kz] = 0;
+    }
+    ipa = 33;
+    bratio[0] = 89.;
+    bratio[1] = 8.5;
+    bratio[2] = 2.5;
+    mode[0] = 70809;
+    mode[1] = 107;
+    mode[2] = 908;
+    Gsdk(ipa, bratio, mode);
+/* --- phi(1020) --- */
+    for (kz = 0; kz < 6; ++kz) {
+       bratio[kz] = 0.;
+       mode[kz] = 0;
+    }
+    ipa = 34;
+    bratio[0] = 49.;
+    bratio[1] = 34.4;
+    bratio[2] = 12.9;
+    bratio[3] = 2.4;
+    bratio[4] = 1.3;
+    mode[0] = 1112;
+    mode[1] = 1610;
+    mode[2] = 4407;
+    mode[3] = 90807;
+    mode[4] = 1701;
+    Gsdk(ipa, bratio, mode);
+/* --- D+ --- */
+    for (kz = 0; kz < 6; ++kz) {
+       bratio[kz] = 0.;
+       mode[kz] = 0;
+    }
+    ipa = 35;
+    bratio[0] = 25.;
+    bratio[1] = 25.;
+    bratio[2] = 25.;
+    bratio[3] = 25.;
+    mode[0] = 80809;
+    mode[1] = 120808;
+    mode[2] = 111208;
+    mode[3] = 110809;
+    Gsdk(ipa, bratio, mode);
+/* --- D- --- */
+    for (kz = 0; kz < 6; ++kz) {
+       bratio[kz] = 0.;
+       mode[kz] = 0;
+    }
+    ipa = 36;
+    bratio[0] = 25.;
+    bratio[1] = 25.;
+    bratio[2] = 25.;
+    bratio[3] = 25.;
+    mode[0] = 90908;
+    mode[1] = 110909;
+    mode[2] = 121109;
+    mode[3] = 120908;
+    Gsdk(ipa, bratio, mode);
+/* --- D0 --- */
+    for (kz = 0; kz < 6; ++kz) {
+       bratio[kz] = 0.;
+       mode[kz] = 0;
+    }
+    ipa = 37;
+    bratio[0] = 33.;
+    bratio[1] = 33.;
+    bratio[2] = 33.;
+    mode[0] = 809;
+    mode[1] = 1208;
+    mode[2] = 1112;
+    Gsdk(ipa, bratio, mode);
+/* --- Anti D0 --- */
+    for (kz = 0; kz < 6; ++kz) {
+       bratio[kz] = 0.;
+       mode[kz] = 0;
+    }
+    ipa = 38;
+    bratio[0] = 33.;
+    bratio[1] = 33.;
+    bratio[2] = 33.;
+    mode[0] = 809;
+    mode[1] = 1109;
+    mode[2] = 1112;
+    Gsdk(ipa, bratio, mode);
+/* --- rho+ --- */
+    for (kz = 0; kz < 6; ++kz) {
+       bratio[kz] = 0.;
+       mode[kz] = 0;
+    }
+    ipa = 42;
+    bratio[0] = 100.;
+    mode[0] = 807;
+    Gsdk(ipa, bratio, mode);
+/* --- rho- --- */
+    for (kz = 0; kz < 6; ++kz) {
+       bratio[kz] = 0.;
+       mode[kz] = 0;
+    }
+    ipa = 43;
+    bratio[0] = 100.;
+    mode[0] = 907;
+    Gsdk(ipa, bratio, mode);
+/* --- rho0 --- */
+    for (kz = 0; kz < 6; ++kz) {
+       bratio[kz] = 0.;
+       mode[kz] = 0;
+    }
+    ipa = 44;
+    bratio[0] = 100.;
+    mode[0] = 707;
+    Gsdk(ipa, bratio, mode);
+    /*
+// --- jpsi ---
+    for (kz = 0; kz < 6; ++kz) {
+       bratio[kz] = 0.;
+       mode[kz] = 0;
+    }
+    ipa = 113;
+    bratio[0] = 50.;
+    bratio[1] = 50.;
+    mode[0] = 506;
+    mode[1] = 605;
+    Gsdk(ipa, bratio, mode);
+// --- upsilon --- 
+    ipa = 114;
+    Gsdk(ipa, bratio, mode);
+// --- phi --- 
+    ipa = 115;
+    Gsdk(ipa, bratio, mode);
+    */
+
+}
+
+//_____________________________________________________________________________
 Int_t TGeant3::VolId(Text_t *name) const
 {
   //
@@ -1088,8 +1372,16 @@ void TGeant3::Matrix(Int_t& krot, Float_t thex, Float_t phix, Float_t they,
 }
 
 //_____________________________________________________________________________
-void TGeant3::GetParticle(const Int_t ipart, char *name, Float_t &mass) const
+void TGeant3::GetParticle(const Int_t pdg, char *name, Float_t &mass) const
 {
+  Int_t ipart = IdFromPDG(pdg);
+  if(ipart<0) {
+    printf("Particle %d not in geant\n",pdg);
+    name=new char[7];
+    strcpy(name,"Unknown");
+    mass=-1;
+    return;
+  }
   //
   // Return name and mass of particle code ipart
   // Geant321 conventions
@@ -1705,6 +1997,15 @@ void  TGeant3::Gtreve()
 } 
 
 //_____________________________________________________________________________
+void  TGeant3::Gtreve_root() 
+{ 
+  //
+  //   Controls tracking of all particles belonging to the current event
+  //
+  gtreve_root(); 
+} 
+
+//_____________________________________________________________________________
 void  TGeant3::Grndm(Float_t *rvec, const Int_t len) const
 {
   //
@@ -2957,13 +3258,18 @@ void TGeant3::SetTRIG(Int_t nevents)
 }
  
 //_____________________________________________________________________________
-void TGeant3::SetUserDecay(Int_t ipart)
+void TGeant3::SetUserDecay(Int_t pdg)
 {
   //
   // Force the decays of particles to be done with Pythia
   // and not with the Geant routines. 
   // just kill pointers doing mzdrop
   //
+  Int_t ipart = IdFromPDG(pdg);
+  if(ipart<0) {
+    printf("Particle %d not in geant\n",pdg);
+    return;
+  }
   Int_t jpart=fGclink->jpart;
   Int_t jpa=fZlq[jpart-ipart];
   //
@@ -3462,10 +3768,14 @@ void TGeant3::Streamer(TBuffer &R__b)
     Version_t R__v = R__b.ReadVersion(); if (R__v) { }
     AliMC::Streamer(R__b);
     R__b >> fNextVol;
+    R__b >> fNPDGCodes;
+    R__b.ReadStaticArray(fPDGCode);
   } else {
     R__b.WriteVersion(TGeant3::IsA());
     AliMC::Streamer(R__b);
     R__b << fNextVol;
+    R__b << fNPDGCodes;
+    R__b.WriteArray(fPDGCode, fNPDGCodes);
   }
 }
 
index 701ba60..a463559 100644 (file)
@@ -421,7 +421,11 @@ private:
   Gckin3_t *fGckin3; 
   Gctrak_t *fGctrak; 
 
+  enum {kMaxParticles = 100};
 
+  Int_t fNPDGCodes;
+
+  Int_t fPDGCode[kMaxParticles];
 
 public: 
   TGeant3(); 
@@ -444,6 +448,9 @@ public:
   Int_t CurrentVol(Text_t *name, Int_t &copy) const;
   Int_t CurrentVolOff(Int_t off, Text_t *name, Int_t &copy) const;
   Int_t VolId(Text_t *name) const;
+  Int_t IdFromPDG(Int_t pdg) const;
+  Int_t PDGFromId(Int_t pdg) const;
+  void  DefineParticles();
   const char* VolName(Int_t id) const;
   void  TrackPosition(Float_t *xyz) const;
   void  TrackMomentum(Float_t *xyz) const;  
@@ -472,7 +479,7 @@ public:
   void  SetMaxStep(Float_t maxstep);
   void  SetMaxNStep(Int_t maxnstp);
   Int_t GetMaxNStep() const;
-  void GetParticle(const Int_t ipart, char *name, Float_t &mass) const;
+  void GetParticle(const Int_t pdg, char *name, Float_t &mass) const;
   virtual Int_t GetMedium() const;
   virtual Float_t Edep() const;
   virtual Float_t Etot() const;
@@ -578,6 +585,7 @@ public:
    virtual  void  Gsxyz(); 
    virtual  void  Gtrack(); 
    virtual  void  Gtreve(); 
+   virtual  void  Gtreve_root(); 
    virtual  void  Grndm(Float_t *rvec, const Int_t len) const; 
    virtual  void  Grndmq(Int_t &is1, Int_t &is2, const Int_t iseq, const Text_t *chopt); 
  
index 37da746..a9d062c 100644 (file)
@@ -33,6 +33,9 @@ Int_t   TGeant3::NofVolumes() const {return 0;}
 Int_t   TGeant3::CurrentVolOff(Int_t, Text_t*, Int_t&) const {return 0;}
 void    TGeant3::TrackPosition(Float_t*) const {}
 void    TGeant3::TrackMomentum(Float_t*) const {}
+Int_t   TGeant3::IdFromPDG(Int_t pdg) const {return -1;}
+Int_t   TGeant3::PDGFromId(Int_t pdg) const {return -1;}
+void    TGeant3::DefineParticles() {}
 Int_t   TGeant3::VolId(Text_t*) const {return 0;}
 const char*   TGeant3::VolName(Int_t ) const {return 0;}
 Float_t TGeant3::TrackCharge() const {return 0;}
@@ -135,6 +138,7 @@ void  TGeant3::Gsstak(Int_t) {}
 void  TGeant3::Gsxyz() {}
 void  TGeant3::Gtrack() {}
 void  TGeant3::Gtreve() {}
+void  TGeant3::Gtreve_root() {}
 void  TGeant3::Grndm(Float_t*, const Int_t) const {}
 void  TGeant3::Grndmq(Int_t&, Int_t&, const Int_t, const Text_t*) {}
 
index 6c21f0e..51f82ba 100644 (file)
@@ -488,7 +488,7 @@ void gustep()
       ipp = Int_t (geant3->Gcking()->gkin[jk][4]+0.5);
       // --- Skip neutrinos! 
       if (ipp != 4) {
-       gAlice->SetTrack(1,gAlice->CurrentTrack(),ipp, geant3->Gcking()->gkin[jk], 
+       gAlice->SetTrack(1,gAlice->CurrentTrack(),gMC->PDGFromId(ipp), geant3->Gcking()->gkin[jk], 
                         geant3->Gckin3()->gpos[jk], polar,geant3->Gctrak()->tofg, chproc, nt);
       }
     }
index 26331bb..3fd91e2 100644 (file)
@@ -22,7 +22,7 @@
 #include <TNode.h>
 #include <TTUBS.h>
 #include <TObjectTable.h>
-#include "GParticle.h"
+#include "TParticle.h"
 #include "AliTPC.h"
 #include "AliRun.h"
 #include <iostream.h>
@@ -885,7 +885,7 @@ void AliTPC::Hits2Clusters()
   AliTPCParam * fTPCParam = &(fDigParam->GetParam());
   Float_t sigma_rphi,sigma_z,cl_rphi,cl_z;
   //
-  GParticle *particle; // pointer to a given particle
+  TParticle *particle; // pointer to a given particle
   AliTPChit *tpcHit; // pointer to a sigle TPC hit
   TClonesArray *Particles; //pointer to the particle list
   Int_t sector,nhits;
@@ -938,9 +938,9 @@ void AliTPC::Hits2Clusters()
        sector=tpcHit->fSector; // sector number
        if(sector != isec) continue; //terminate iteration
        ipart=tpcHit->fTrack;
-       particle=(GParticle*)Particles->UncheckedAt(ipart);
-       pl=particle->GetPz();
-       pt=particle->GetPT();
+       particle=(TParticle*)Particles->UncheckedAt(ipart);
+       pl=particle->Pz();
+       pt=particle->Pt();
        if(pt < 1.e-9) pt=1.e-9;
        tanth=pl/pt;
        tanth = TMath::Abs(tanth);