]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Vertex truncation settings moved to AliGenMC.
authormorsch <morsch@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 15 Oct 2001 08:21:55 +0000 (08:21 +0000)
committermorsch <morsch@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 15 Oct 2001 08:21:55 +0000 (08:21 +0000)
EVGEN/AliGenPythia.cxx
EVGEN/AliGenPythia.h

index 3336bc45779a862e154845e023b5ae03752a797a..8ed573573a46108e4ccd01a80d0f74c6ac4ab66a 100644 (file)
@@ -15,6 +15,9 @@
 
 /*
 $Log$
+Revision 1.41  2001/10/08 08:45:42  morsch
+Possibility of vertex cut added.
+
 Revision 1.40  2001/09/25 11:30:23  morsch
 Pass event vertex to header.
 
@@ -291,13 +294,13 @@ void AliGenPythia::Generate()
        Int_t np = fParticles->GetEntriesFast();
        if (np == 0 ) continue;
 // Get event vertex and discard the event if the Z coord. is too big   
-       TParticle *  iparticle = (TParticle *) fParticles->At(0);
-       Float_t distz = iparticle->Vz()/10. - fOrigin.At(2);
-       if(TMath::Abs(distz)>fCutVertexZ)continue;
+       TParticle *iparticle = (TParticle *) fParticles->At(0);
+       Float_t distz = iparticle->Vz()/10.;
+       if(TMath::Abs(distz)>fCutVertexZ*fOsigma[2]) continue;
 //
-       fEventVertex[0] = iparticle->Vx()/10.;
-       fEventVertex[1] = iparticle->Vy()/10.;  
-       fEventVertex[2] = iparticle->Vz()/10.;
+       fEventVertex[0] = iparticle->Vx()/10.+fOrigin.At(0);
+       fEventVertex[1] = iparticle->Vy()/10.+fOrigin.At(1);
+       fEventVertex[2] = iparticle->Vz()/10.+fOrigin.At(2);
 //
        Int_t* pParent   = new Int_t[np];
        Int_t* pSelected = new Int_t[np];
index 5e8ee9d74e5e33cf448e3a81d8f6dbc38c963f31..0860884f097bca08516e586df8609d44e5868865 100644 (file)
@@ -23,7 +23,6 @@ class AliGenPythia : public AliGenMC
     virtual void    Generate();
     virtual void    Init();
     // set a cut on the Z coord. of the primary vertex (cm)
-    virtual void    SetCutVertexZ(Float_t cut=999999.) {fCutVertexZ = cut;}
     //
     virtual void    SetEventListRange(Int_t eventFirst=-1, Int_t eventLast=-1);
     // select process type
@@ -65,8 +64,6 @@ class AliGenPythia : public AliGenMC
     AliDecayer  *fDecayer;        //!Pointer to the decayer instance
     Int_t       fDebugEventFirst; //!First event to debug
     Int_t       fDebugEventLast;  //!Last  event to debug
-    TArrayF     fEventVertex;     //!The current event vertex
-    Float_t     fCutVertexZ;      //cut on Z vertex position (cm)
  private:
     // adjust the weight from kinematic cuts
     void   AdjustWeights();