~maddevelopers/mg5amcnlo/2.5.3

« back to all changes in this revision

Viewing changes to vendor/StdHEP/src/stdhep/stdxwrt.F

  • Committer: olivier-mattelaer
  • Date: 2017-03-08 12:31:17 UTC
  • Revision ID: olivier-mattelaer-20170308123117-h0zkqjyh9sihsc61
empty version to have an effective freeze of the code

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
      subroutine stdxwrt(ilbl,istream,lok)
2
 
 
3
 
C...Purpose: to write a buffer or an event from the standard common block.
4
 
C
5
 
C       if ilbl = 1     write HEPEVT common block
6
 
C          ilbl = 2     write HEPEVT, HEPEV2, and HEPEV3 common blocks
7
 
C          ilbl = 4     write HEPEVT and HEPEV4 common blocks
8
 
C          ilbl = 5     write HEPEVT, HEPEV2, HEPEV3, and HEPEV4 common blocks
9
 
C          ilbl = 11    write HEPEUP common block
10
 
C          ilbl = 12    write HEPRUP common block
11
 
C          ilbl = 100   write STDHEP begin run record
12
 
C          ilbl = 200   write STDHEP end run record
13
 
C          otherwise,   don't do anything
14
 
C
15
 
C       lok = 0 if no problems were encountered
16
 
 
17
 
#include "stdcnt.inc"
18
 
#include "stdlun.inc"
19
 
 
20
 
      integer ilbl,lok,istream
21
 
      logical lfirst
22
 
      data lfirst/.TRUE./
23
 
      save lfirst
24
 
 
25
 
C...print version number if this is the first call
26
 
      if(lfirst)then
27
 
        call stdversn
28
 
        nstdwrt = 0
29
 
        nlhwrt = 0
30
 
        lfirst=.FALSE.
31
 
      endif
32
 
 
33
 
      lok=0
34
 
      if(ilbl.eq.1 .or. ilbl.eq.2)then
35
 
C... the stdhep common block and maybe the multiple interaction common
36
 
        call stdxwevt(ilbl,istream,lok)
37
 
      elseif(ilbl.eq.4 .or. ilbl.eq.5)then
38
 
C... the stdhep common block and maybe the multiple interaction common
39
 
C... include HEPEV4
40
 
        call stdxwevtlh(ilbl,istream,lok)
41
 
      elseif(ilbl.eq.11 .or. ilbl.eq.12)then
42
 
C... the Les Houches common blocks
43
 
        call stdxwevtup(ilbl,istream,lok)
44
 
      elseif(ilbl.eq.100)then
45
 
        call stdxwcm1(ilbl,istream,lok)
46
 
      elseif(ilbl.eq.200)then
47
 
        call stdxwcm1(ilbl,istream,lok)
48
 
      else
49
 
        write(lnhout,902) ilbl
50
 
      endif
51
 
      return
52
 
  900 write (lnhout,901)
53
 
      lok=1
54
 
      return
55
 
  101 format(/5X,'STDXWRT: the output buffer is empty')
56
 
  901 format(/5X,'STDXWRT: write error')
57
 
  902 format(/5X,'STDXWRT: do not know what to do with record type',i5)
58
 
      end