ROOT logo
#ifndef ALIGENPILEUP_H
#define ALIGENPILEUP_H
/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
 * See cxx source for full Copyright notice                               */

//-------------------------------------------------------------------------
//                          Class AliGenPileup
//   This is a generator of beam-beam pileup.
//   It generates interactions within 3 orbits (+-1) around
//   the trigger event. The trigger event itself is chosen
//   randomly among the bunch crossings within the central orbit.
//   The user can decide whenever to include in the simulation the
//   "trigger" interaction or not. This is handled by the
//   GenerateTrigInteraction(Bool_t flag) method.
//   In the case the trigger interaction is included, it is
//   generated using the same settings (vertex smear for example) as
//   the pileup events.
//   In case the trigger simulation is not included, the user can make
//   a cocktail of generator used to produce the trigger interaction and
//   AliGenPileup. In this case in order to avoid a fake increase of the rate around the
//   trigger, the number of background events within the bunch
//   crossing of the trigger is readuced by one.
//   The beam profile (the list of the active bunch crossings) can be
//   controlled via the SetBCMask(const char *mask) method. The syntax
//   follows the one in AliTriggerBCMask class. For example:
//   "3564H" would mean that all the bunch corssings within the orbit
//   are aloowed (which is of course unphysical). In case one wants to simulate
//   one-bunch-crossing-per-orbit scenario, the way to do it is to put something like:
//   "1H3563L" or similar.
//   The SetGenerator(AliGenerator *generator, Float_t rate) method is
//   used in order to define the generator to be used. The second argument is the pileup
//   rate in terms of #_of_interactions/bunch-crossing = sigma_tot * luminosity.
//   The pileup generation time window can be set via
//   AliGenerator::SetPileUpTimeWindow(Float_t pileUpTimeW) method. By the default the
//   window is set to 88micros (= TPC readout window).
//      
// cvetan.cheshkov@cern.ch  9/12/2008
//-------------------------------------------------------------------------

#include "AliGenCocktail.h"
#include "AliTriggerBCMask.h"
class TFormula;
class AliGenPileup : public AliGenCocktail
{
 public:
    AliGenPileup();
    virtual ~AliGenPileup();

    virtual void Generate();
    virtual void SetRandomise(Bool_t flag);
    virtual void UsePerEventRates();
	    
    void         SetGenerator(AliGenerator *generator, Float_t rate, Bool_t flag = kFALSE);
    //void         SetGenerator(AliGenerator *generator, Float_t rate);
    Bool_t       SetBCMask(const char *mask);
    void         GenerateTrigInteraction(Bool_t flag) {fGenTrig = flag;}

 protected:
    virtual void AddGenerator
      (AliGenerator *Generator, const char* Name, Float_t RateExp, TFormula* formula = 0,
       Int_t ntimes = 1);
    AliTriggerBCMask fBCMask;    // Mask used to tag the active bunch-crossings within an orbit
    Bool_t           fGenTrig;   // Generate or not the trigger interaction
    Bool_t           fFlag;      // fixed interaction rate (integer)

 private:
    AliGenPileup(const AliGenPileup &gen);
    AliGenPileup & operator=(const AliGenPileup & gen);

    ClassDef(AliGenPileup,1) // Beam-beam pileup generator based on cocktail generator
};

#endif

 AliGenPileup.h:1
 AliGenPileup.h:2
 AliGenPileup.h:3
 AliGenPileup.h:4
 AliGenPileup.h:5
 AliGenPileup.h:6
 AliGenPileup.h:7
 AliGenPileup.h:8
 AliGenPileup.h:9
 AliGenPileup.h:10
 AliGenPileup.h:11
 AliGenPileup.h:12
 AliGenPileup.h:13
 AliGenPileup.h:14
 AliGenPileup.h:15
 AliGenPileup.h:16
 AliGenPileup.h:17
 AliGenPileup.h:18
 AliGenPileup.h:19
 AliGenPileup.h:20
 AliGenPileup.h:21
 AliGenPileup.h:22
 AliGenPileup.h:23
 AliGenPileup.h:24
 AliGenPileup.h:25
 AliGenPileup.h:26
 AliGenPileup.h:27
 AliGenPileup.h:28
 AliGenPileup.h:29
 AliGenPileup.h:30
 AliGenPileup.h:31
 AliGenPileup.h:32
 AliGenPileup.h:33
 AliGenPileup.h:34
 AliGenPileup.h:35
 AliGenPileup.h:36
 AliGenPileup.h:37
 AliGenPileup.h:38
 AliGenPileup.h:39
 AliGenPileup.h:40
 AliGenPileup.h:41
 AliGenPileup.h:42
 AliGenPileup.h:43
 AliGenPileup.h:44
 AliGenPileup.h:45
 AliGenPileup.h:46
 AliGenPileup.h:47
 AliGenPileup.h:48
 AliGenPileup.h:49
 AliGenPileup.h:50
 AliGenPileup.h:51
 AliGenPileup.h:52
 AliGenPileup.h:53
 AliGenPileup.h:54
 AliGenPileup.h:55
 AliGenPileup.h:56
 AliGenPileup.h:57
 AliGenPileup.h:58
 AliGenPileup.h:59
 AliGenPileup.h:60
 AliGenPileup.h:61
 AliGenPileup.h:62
 AliGenPileup.h:63
 AliGenPileup.h:64
 AliGenPileup.h:65
 AliGenPileup.h:66
 AliGenPileup.h:67
 AliGenPileup.h:68
 AliGenPileup.h:69
 AliGenPileup.h:70
 AliGenPileup.h:71
 AliGenPileup.h:72
 AliGenPileup.h:73
 AliGenPileup.h:74