CascadeWrapper.h

Go to the documentation of this file.
00001 //--------------------------------------------------------------------------
00002 #ifndef CASCADE_WRAPPER_H
00003 #define CASCADE_WRAPPER_H
00004 
00005 //////////////////////////////////////////////////////////////////////////
00006 // Wrapper for FORTRAN version of CASCADE
00007 // This wrapper is NOT intended as a part of HepMC - it is only supplied
00008 // for your convenience.
00009 //////////////////////////////////////////////////////////////////////////
00010 // 
00011 //
00012 // Note the pyhepc routine is used by Pythia to fill
00013 // the HEPEVT common block uses double precision and 4000 entries.
00014 //
00015 
00016 #include <ctype.h>
00017 #include <cstring>
00018 
00019 //--------------------------------------------------------------------------
00020 // Initialization routine
00021 
00022 
00023 
00024 
00025 //--------------------------------------------------------------------------
00026 // CASCADE routine declarations
00027 #define casini casini_
00028 #define steer steer_
00029 #define cascha cascha_
00030 #define pytcha pytcha_
00031 #define pyedit pyedit_
00032 #define cascade cascade_
00033 #define caend caend_
00034 #define event event_
00035 #define rluxgo rluxgo_
00036     extern "C" {
00037 // CASCADE routines
00038       void pytcha();
00039       void pyedit(int*);
00040       void casini();
00041       void casini();
00042       void steer();
00043       void cascha();
00044       void cascade();
00045       void caend(int*);
00046       void event();
00047       void rluxgo(int*,int*,int*,int*);
00048     }
00049 
00050 // define methods to hide the subtle syntax necessary to call fortran from C++
00051 //inline void call_pyhepc( int mode ){ pyhepc( &mode ); }
00052 //inline void call_pylist( int mode ){ pylist( &mode ); }
00053 //inline void call_pystat( int mode ){ pystat( &mode ); }
00054 //inline void call_pyevnt(){ pyevnt(); }
00055 // CASCADE
00056 inline void call_casini() {casini();}
00057 inline void call_steer() {steer();}
00058 inline void call_cascha() {cascha();}
00059 inline void call_pytcha() {pytcha();}
00060 inline void call_cascade() {cascade();}
00061 inline void call_caend( int mode){caend( &mode);}
00062 inline void call_pyedit( int mode){pyedit( &mode);}
00063 inline void call_event() {event();}
00064 inline void call_rluxgo(int mode1, int mode2, int mode3, int mode4) {rluxgo(&mode1, &mode2, &mode3, &mode4 );}
00065 
00066 
00067 //--------------------------------------------------------------------------
00068 // PYTHIA block data
00069 // ( with gcc it works to initialize the block data by calling 
00070 //   "pydata();" at beginning, but this fails for f77, so the fortran routine
00071 //   initpydata.f is supplied ... call it instead for platform independent
00072 //   behaviour )
00073 
00074 #define pydata pydata_
00075 extern "C" {
00076     void pydata(void);
00077 }
00078 
00079 #endif  // PYTHIA_WRAPPER_H
00080 //--------------------------------------------------------------------------

Generated on Wed Aug 31 09:44:48 2011 for HepMCAnalysis by  doxygen 1.4.7