LCOV - code coverage report
Current view: top level - PYTHIA8/pythia8210dev/include/Pythia8 - ProcessLevel.h (source / functions) Hit Total Coverage
Test: coverage.info Lines: 0 7 0.0 %
Date: 2016-06-14 17:26:59 Functions: 0 5 0.0 %

          Line data    Source code
       1             : // ProcessLevel.h is a part of the PYTHIA event generator.
       2             : // Copyright (C) 2015 Torbjorn Sjostrand.
       3             : // PYTHIA is licenced under the GNU GPL version 2, see COPYING for details.
       4             : // Please respect the MCnet Guidelines, see GUIDELINES for details.
       5             : 
       6             : // This file contains the main class for process-level event generation.
       7             : // ProcessLevel: administrates the selection of "hard" process.
       8             : 
       9             : #ifndef Pythia8_ProcessLevel_H
      10             : #define Pythia8_ProcessLevel_H
      11             : 
      12             : #include "Pythia8/Basics.h"
      13             : #include "Pythia8/BeamParticle.h"
      14             : #include "Pythia8/Event.h"
      15             : #include "Pythia8/Info.h"
      16             : #include "Pythia8/ParticleData.h"
      17             : #include "Pythia8/PartonDistributions.h"
      18             : #include "Pythia8/ProcessContainer.h"
      19             : #include "Pythia8/PythiaStdlib.h"
      20             : #include "Pythia8/ResonanceDecays.h"
      21             : #include "Pythia8/Settings.h"
      22             : #include "Pythia8/SigmaTotal.h"
      23             : #include "Pythia8/SusyCouplings.h"
      24             : #include "Pythia8/SLHAinterface.h"
      25             : #include "Pythia8/StandardModel.h"
      26             : #include "Pythia8/UserHooks.h"
      27             : 
      28             : namespace Pythia8 {
      29             : 
      30             : //==========================================================================
      31             : 
      32             : // The ProcessLevel class contains the top-level routines to generate
      33             : // the characteristic "hard" process of an event.
      34             : 
      35             : class ProcessLevel {
      36             : 
      37             : public:
      38             : 
      39             :   // Constructor.
      40           0 :   ProcessLevel() : iLHACont(-1) {}
      41             : 
      42             :   // Destructor to delete processes in containers.
      43             :   ~ProcessLevel();
      44             : 
      45             :   // Initialization.
      46             :   bool init( Info* infoPtrIn, Settings& settings,
      47             :     ParticleData* particleDataPtrIn, Rndm* rndmPtrIn,
      48             :     BeamParticle* beamAPtrIn, BeamParticle* beamBPtrIn,
      49             :     Couplings* couplingsPtrIn, SigmaTotal* sigmaTotPtrIn, bool doLHAin,
      50             :     SLHAinterface* slhaInterfacePtrIn, UserHooks* userHooksPtrIn,
      51             :     vector<SigmaProcess*>& sigmaPtrs, vector<PhaseSpace*>& phaseSpacePtrs,
      52             :     ostream& os = cout);
      53             : 
      54             :   // Store or replace Les Houches pointer.
      55           0 :   void setLHAPtr( LHAup* lhaUpPtrIn) {lhaUpPtr = lhaUpPtrIn;
      56           0 :     if (iLHACont >= 0) containerPtrs[iLHACont]->setLHAPtr(lhaUpPtr);}
      57             : 
      58             :   // Generate the next "hard" process.
      59             :   bool next( Event& process);
      60             : 
      61             :   // Special case: LHA input of resonance decay only.
      62             :   bool nextLHAdec( Event& process);
      63             : 
      64             :   // Accumulate and update statistics (after possible user veto).
      65             :   void accumulate();
      66             : 
      67             :   // Print statistics on cross sections and number of events.
      68             :   void statistics(bool reset = false, ostream& os = cout);
      69             : 
      70             :   // Reset statistics.
      71             :   void resetStatistics();
      72             : 
      73             :   // Add any junctions to the process event record list.
      74             :   void findJunctions( Event& junEvent);
      75             : 
      76             :   // Initialize and call resonance decays separately.
      77             :   void initDecays( Info* infoPtrIn, ParticleData* particleDataPtrIn,
      78           0 :     Rndm* rndmPtrIn, LHAup* lhaUpPtrIn) { infoPtr = infoPtrIn;
      79           0 :     resonanceDecays.init( infoPtrIn, particleDataPtrIn, rndmPtrIn);
      80           0 :     containerLHAdec.setLHAPtr(lhaUpPtrIn, particleDataPtrIn); }
      81           0 :   bool nextDecays( Event& process) { return resonanceDecays.next( process);}
      82             : 
      83             : private:
      84             : 
      85             :   // Constants: could only be changed in the code itself.
      86             :   static const int MAXLOOP;
      87             : 
      88             :   // Generic info for process generation.
      89             :   bool   doSecondHard, doSameCuts, allHardSame, noneHardSame,
      90             :          someHardSame, cutsAgree, cutsOverlap, doResDecays;
      91             :   int    nImpact, startColTag;
      92             :   double mHatMin1, mHatMax1, pTHatMin1, pTHatMax1, mHatMin2, mHatMax2,
      93             :          pTHatMin2, pTHatMax2, sigmaND, sumImpactFac, sum2ImpactFac;
      94             : 
      95             :   // Vector of containers of internally-generated processes.
      96             :   vector<ProcessContainer*> containerPtrs;
      97             :   int    iContainer, iLHACont;
      98             :   double sigmaMaxSum;
      99             : 
     100             :   // Ditto for optional choice of a second hard process.
     101             :   vector<ProcessContainer*> container2Ptrs;
     102             :   int    i2Container;
     103             :   double sigma2MaxSum;
     104             : 
     105             :   // Single half-dummy container for LHA input of resonance decay only.
     106             :   ProcessContainer containerLHAdec;
     107             : 
     108             :   // Pointer to various information on the generation.
     109             :   Info*           infoPtr;
     110             : 
     111             :   // Pointer to the particle data table.
     112             :   ParticleData*   particleDataPtr;
     113             : 
     114             :   // Pointer to the random number generator.
     115             :   Rndm*           rndmPtr;
     116             : 
     117             :   // Pointers to the two incoming beams.
     118             :   BeamParticle*   beamAPtr;
     119             :   BeamParticle*   beamBPtr;
     120             : 
     121             :   // Pointer to Standard Model couplings, including alphaS and alphaEM.
     122             :   Couplings*      couplingsPtr;
     123             : 
     124             :   // Pointer to SigmaTotal object needed to handle soft QCD processes.
     125             :   SigmaTotal*     sigmaTotPtr;
     126             : 
     127             :   // Pointer to SusyLesHouches object for interface to SUSY spectra.
     128             :   SLHAinterface*  slhaInterfacePtr;
     129             : 
     130             :   // Pointer to userHooks object for user interaction with program.
     131             :   UserHooks*      userHooksPtr;
     132             : 
     133             :   // Pointer to LHAup for generating external events.
     134             :   LHAup*          lhaUpPtr;
     135             : 
     136             :   // ResonanceDecay object does sequential resonance decays.
     137             :   ResonanceDecays resonanceDecays;
     138             : 
     139             :   // Generate the next event with one interaction.
     140             :   bool nextOne( Event& process);
     141             : 
     142             :   // Generate the next event with two hard interactions.
     143             :   bool nextTwo( Event& process);
     144             : 
     145             :   // Append the second to the first process list.
     146             :   void combineProcessRecords( Event& process, Event& process2);
     147             : 
     148             :   // Check that colours match up.
     149             :   bool checkColours( Event& process);
     150             : 
     151             :   // Print statistics when two hard processes allowed.
     152             :   void statistics2(bool reset, ostream& os = cout);
     153             : 
     154             : };
     155             : 
     156             : //==========================================================================
     157             : 
     158             : } // end namespace Pythia8
     159             : 
     160             : #endif // Pythia8_ProcessLevel_H

Generated by: LCOV version 1.11