HepMC Reference Documentation

HepMC

HerwigWrapper.h

Go to the documentation of this file.
00001 //--------------------------------------------------------------------------
00002 #ifndef HERWIG_WRAPPER_H
00003 #define HERWIG_WRAPPER_H
00004 
00006 // Matt.Dobbs@Cern.CH, November 200July 2002
00007 // Wrapper for FORTRAN version of Herwig
00008 // Wrapper written for Herwig 6.4
00010 
00011 #include <ctype.h>
00012 
00013 // This pre-compiler directive is included (2002-01-16) to allow compatibility
00014 // with MS Visual C++, which interfaces to fortran in a different manner.
00015 // For it to work you need to define the _WIN32 variable when compiling.
00016 #ifdef _WIN32 // Platform: Windows MS Visual C++
00017 
00018 //  Sorry, there is NO version currently available for Vusual C++.
00019 
00020 #else // Generic version, tested on Linux ecgs/gcc
00021 
00022 //--------------------------------------------------------------------------
00023 // HERWIG Common Block Declarations
00024 
00025 //        COMMON/HWPROC/EBEAM1,EBEAM2,PBEAM1,PBEAM2,IPROC,MAXEV
00026 extern "C" {
00027     extern struct {
00028         double EBEAM1,EBEAM2,PBEAM1,PBEAM2;
00029         int IPROC,MAXEV;
00030     } hwproc_;
00031 }
00032 #define hwproc hwproc_
00033 
00034 //      COMMON/HWBEAM/IPART1,IPART2
00035 extern "C" {
00036     extern struct {
00037         int IPART1, IPART2;
00038     } hwbeam_;
00039 }
00040 #define hwbeam hwbeam_
00041 
00042 //        CHARACTER*8 PART1,PART2
00043 //        COMMON/HWBMCH/PART1,PART2
00044 extern "C" {
00045     extern struct {
00046         char PART1[8],PART2[8];
00047     } hwbmch_;
00048 }
00049 #define hwbmch hwbmch_
00050 
00051 //  COMMON/HWEVNT/AVWGT,EVWGT,GAMWT,TLOUT,WBIGST,WGTMAX,WGTSUM,WSQSUM,
00052 //       & IDHW(NMXHEP),IERROR,ISTAT,LWEVT,MAXER,MAXPR,NOWGT,NRN(2),NUMER,
00053 //       & NUMERU,NWGTS,GENSOF
00054 const int herwig_hepevt_size = 4000;
00055 extern "C" {
00056     extern struct hwgev {
00057         double AVWGT,EVWGT,GAMWT,TLOUT,WBIGST,WGTMAX,WGTSUM,WSQSUM;
00058         int IDHW[herwig_hepevt_size],IERROR,ISTAT,LWEVT,MAXER,MAXPR;
00059         int NOWGT,NRN[2],NUMER,NUMERU,NWGTS;
00060         int GENSOF; //Beware! in F77 this is logical
00061     } hwevnt_;
00062 }
00063 #define hwevnt hwevnt_
00064 
00065 //  C Basic parameters (and quantities derived from them)
00066 //        COMMON/HWPRAM/AFCH(16,2),ALPHEM,B1LIM,BETAF,BTCLM,CAFAC,CFFAC,
00067 //       & CLMAX,CLPOW,CLSMR(2),CSPEED,ENSOF,ETAMIX,F0MIX,F1MIX,F2MIX,GAMH,
00068 //       & GAMW,GAMZ,GAMZP,GEV2NB,H1MIX,PDIQK,PGSMX,PGSPL(4),PHIMIX,PIFAC,
00069 //       & PRSOF,PSPLT(2),PTRMS,PXRMS,QCDL3,QCDL5,QCDLAM,QDIQK,QFCH(16),QG,
00070 //       & QSPAC,QV,SCABI,SWEIN,TMTOP,VFCH(16,2),VCKM(3,3),VGCUT,VQCUT,
00071 //       & VPCUT,ZBINM,EFFMIN,OMHMIX,ET2MIX,PH3MIX,GCUTME,
00072 //       & IOPREM,IPRINT,ISPAC,LRSUD,LWSUD,MODPDF(2),NBTRY,NCOLO,NCTRY,
00073 //       & NDTRY,NETRY,NFLAV,NGSPL,NSTRU,NSTRY,NZBIN,IOP4JT(2),NPRFMT,
00074 //       & AZSOFT,AZSPIN,CLDIR(2),HARDME,NOSPAC,PRNDEC,PRVTX,SOFTME,ZPRIME,
00075 //       & PRNDEF,PRNTEX,PRNWEB
00076 
00077 extern "C" {
00078     extern struct {
00079         double AFCH[2][16],ALPHEM,B1LIM,BETAF,BTCLM,CAFAC,CFFAC,
00080             CLMAX,CLPOW,CLSMR[2],CSPEED,ENSOF,ETAMIX,F0MIX,F1MIX,F2MIX,GAMH,
00081             GAMW,GAMZ,GAMZP,GEV2NB,H1MIX,PDIQK,PGSMX,PGSPL[4],PHIMIX,PIFAC,
00082             PRSOF,PSPLT[2],PTRMS,PXRMS,QCDL3,QCDL5,QCDLAM,QDIQK,QFCH[16],QG,
00083             QSPAC,QV,SCABI,SWEIN,TMTOP,VFCH[2][16],VCKM[3][3],VGCUT,VQCUT,
00084             VPCUT,ZBINM,EFFMIN,OMHMIX,ET2MIX,PH3MIX,GCUTME;
00085         int IOPREM,IPRINT,ISPAC,LRSUD,LWSUD,MODPDF[2],NBTRY,NCOLO,NCTRY,
00086             NDTRY,NETRY,NFLAV,NGSPL,NSTRU,NSTRY,NZBIN,IOP4JT[2],NPRFMT;
00087         int AZSOFT,AZSPIN,CLDIR[2],HARDME,NOSPAC,PRNDEC,PRVTX,SOFTME,
00088             ZPRIME,PRNDEF,PRNTEX,PRNWEB; //Beware! in F77 these are logical
00089     } hwpram_;
00090 }
00091 #define hwpram hwpram_
00092 
00093 //--------------------------------------------------------------------------
00094 // HERWIG routines declaration
00095 
00096 #define hwigin hwigin_  // initialise other common blocks
00097 #define hwigup hwigup_  // initialise HepUP run common block
00098 #define hwuinc hwuinc_  // compute parameter-dependent constants
00099 #define hwusta hwusta_  // call hwusta to make any particle stable
00100 #define hweini hweini_  // initialise elementary process
00101 #define hwuine hwuine_  // initialise event
00102 #define hwepro hwepro_  // generate HERWIG hard subprocess
00103 #define hwupro hwupro_  // read USER hard subprocess from HepUP event common
00104 #define hwbgen hwbgen_  // generate parton cascades
00105 #define hwdhob hwdhob_  // do heavy object decays
00106 #define hwcfor hwcfor_  // do cluster hadronization
00107 #define hwcdec hwcdec_  // do cluster decay
00108 #define hwdhad hwdhad_  // do unstable particle decays
00109 #define hwdhvy hwdhvy_  // do heavy flavour decays
00110 #define hwmevt hwmevt_  // add soft underlying event if needed 
00111 #define hwufne hwufne_  // event generation completed, wrap up event .... 
00112 #define hwefin hwefin_  // terminate elementary process
00113 
00114 #define hwudpr hwudpr_  // prints out particle/decay properties
00115 #define hwuepr hwuepr_  // prints out event data
00116 #define hwupup hwupup_  // prints out HepEUP user common block event data
00117 #define hwegup hwegup_  // terminal calculations to replace HWEFIN for HepUP
00118     extern "C" {
00119         void hwigin(void);
00120         void hwigup(void);
00121         void hwuinc(void);
00122         void hwusta(const char*,int);
00123         void hweini(void);
00124         void hwuine(void);
00125         void hwepro(void);
00126         void hwupro(void);
00127         void hwbgen(void);
00128         void hwdhob(void);
00129         void hwcfor(void);
00130         void hwcdec(void);
00131         void hwdhad(void);
00132         void hwdhvy(void);
00133         void hwmevt(void);
00134         void hwufne(void);
00135         void hwefin(void);
00136         void hwudpr(void);
00137         void hwuepr(void);
00138         void hwupup(void);
00139         void hwegup(void);
00140     }
00141 
00142 //--------------------------------------------------------------------------
00143 // HERWIG block data
00144 // ( with gcc it works to initialize the block data by calling 
00145 //   "hwudat();" at beginning. )
00146 
00147 #define hwudat hwudat_
00148 extern "C" {
00149     void hwudat(void);
00150 }
00151 
00152 
00153 #include "HepMC/GenCrossSection.h"
00154 
00155 namespace HepMC {
00156 
00158 GenCrossSection getHerwigCrossSection(int ngen);
00159 
00160 } // HepMC
00161 
00162 #endif // Platform
00163 
00164 #endif  // HERWIG_WRAPPER_H
00165 
00166 //--------------------------------------------------------------------------

Generated on Fri Feb 17 00:31:25 2012 for HepMC by  doxygen 1.4.7