Technical fix: additional protection in the printout
authorhristov <hristov@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sun, 22 Mar 2009 09:03:17 +0000 (09:03 +0000)
committerhristov <hristov@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sun, 22 Mar 2009 09:03:17 +0000 (09:03 +0000)
DPMJET/dpmjet3.0-5.f

index 3c45db6..b6c53be 100644 (file)
@@ -27730,29 +27730,34 @@ C      IF (NCOMPO.GT.0) CALL DT_LTINI(ID,EPN,PPN,ECM)
       WRITE(LOUT,1000)
  1000 FORMAT(/,/,1X,'STATIS:',20X,'statistics of the run',/,
      &       28X,'---------------------')
+      IF (ICREQU.GT.0) THEN
       WRITE(LOUT,1001) ICREQU,ICSAMP,DBLE(ICSAMP)/DBLE(ICREQU)
  1001 FORMAT(/,1X,'number of events requested / sampled',13X,
      &       I8,' / ',I8,/,1X,'number of samp. evts per requested ',
      &       'event',11X,F9.1)
+      ENDIF
       IF (ICDIFF(1).NE.0) THEN
          WRITE(LOUT,1009) ICDIFF
  1009    FORMAT(/,1X,'diffractive events:    total   ',I8,/,49X,
      &          'low mass   high mass',/,24X,'single diffraction',
      &          7X,I8,4X,I8,/,24X,'double diffraction',7X,I8,4X,I8)
       ENDIF
-      IF (ICENTR.GT.0) THEN
+      IF (ICENTR.GT.0.AND.ICSAMP.GT.0.AND.ICCPRO.GT.0) THEN
          WRITE(LOUT,1002) DBLE(ICCPRO)/DBLE(ICSAMP),
      &                    DBLE(ICSAMP)/DBLE(ICCPRO)
  1002    FORMAT(/,1X,'central production:',/,2X,'mean number',
      &          ' of sampled Glauber-events per event',9X,F9.1,/,
      &          2X,'fraction of production cross section',21X,F10.6)
       ENDIF
+      IF (ICSAMP.GT.0) THEN
       WRITE(LOUT,1003) DBLE(ICDPR)/DBLE(ICSAMP),
      &                 DBLE(ICDTA)/DBLE(ICSAMP)
  1003 FORMAT(/,54X,'proj.    targ.',/,1X,'average number of wounded',
      &       ' nucleons after x-sampling',2(4X,F6.2))
+      ENDIF
 
       IF (MCGENE.EQ.1) THEN
+         IF (ICSAMP.GT.0) THEN
          WRITE(LOUT,1004) DBLE(ICRJSS)/DBLE(ICSAMP)
  1004    FORMAT(/,1X,'mean number of sea-sea chain rejections per',
      &          ' event',3X,F9.1)
@@ -27761,6 +27766,8 @@ C      IF (NCOMPO.GT.0) CALL DT_LTINI(ID,EPN,PPN,ECM)
  1005       FORMAT(/,1X,'Reggeon contribution:',/,1X,'mean number ',
      &             'of single chains  per event',13X,F9.1)
          ENDIF
+         ENDIF
+         IF (ICSAMP.GT.0.AND.ICREQU.GT.0) THEN
          WRITE(LOUT,1006)
  1006    FORMAT(/,1X,'chain system statistics:  (per event)',/,
      &       23X,'mean number of chains      mean number of chains',/,
@@ -27807,6 +27814,7 @@ C      IF (NCOMPO.GT.0) CALL DT_LTINI(ID,EPN,PPN,ECM)
      &       'Treatment of final nucleon conf.',10X,'IREXCI(1)/NEVT = '
      &       ,F7.2,/,43X,'IREXCI(2)/NEVT = ',F7.2,/,48X,
      &       'IREXCI(3) = ',I5,/)
+         ENDIF
       ELSEIF (MCGENE.EQ.2) THEN
          WRITE(LOUT,1010) ELOJET
  1010    FORMAT(/,/,1X,'PHOJET-treatment of chain systems above  ',
@@ -27841,6 +27849,7 @@ C      IF (NCOMPO.GT.0) CALL DT_LTINI(ID,EPN,PPN,ECM)
  1013    FORMAT(/,1X,'2. chain system statistics -',
      &          ' mean numbers per evt:',/,30X,'---------------------',
      &          /,/,16X,'s-s',7X,'d-s',7X,'s-d')
+         IF (ICSAMP.GT.0) THEN
          WRITE(LOUT,1014)
      &                 ((DBLE(ICEVTG(I,J))/DBLE(ICSAMP),I=1,3),J=0,1),
      &                 (DBLE(ICCHAI(2,I))/(2.0D0*DBLE(ICSAMP)),I=1,3),
@@ -27855,8 +27864,10 @@ C      IF (NCOMPO.GT.0) CALL DT_LTINI(ID,EPN,PPN,ECM)
      &          ' dbl-dir    ',3E10.2,/,' s-Pom.     ',3E10.2,/,
      &          ' h-Pom.     ',3E10.2,/,' s-Reg.     ',3E10.2,/,
      &          ' enh-trg    ',3E10.2,/,' enh-log    ',3E10.2)
+         ENDIF
          WRITE(LOUT,1015)
  1015    FORMAT(/,16X,'s-v',7X,'d-v',7X,'v-s',7X,'v-d',7X,'v-v')
+         IF (ICSAMP.GT.0) THEN
          WRITE(LOUT,1016)
      &                 ((DBLE(ICEVTG(I,J))/DBLE(ICSAMP),I=4,8),J=0,1),
      &                 (DBLE(ICCHAI(2,I))/(2.0D0*DBLE(ICSAMP)),I=4,8),
@@ -27871,6 +27882,7 @@ C      IF (NCOMPO.GT.0) CALL DT_LTINI(ID,EPN,PPN,ECM)
      &          ' dbl-dir    ',5E10.2,/,' s-Pom.     ',5E10.2,/,
      &          ' h-Pom.     ',5E10.2,/,' s-Reg.     ',5E10.2,/,
      &          ' enh-trg    ',5E10.2,/,' enh-log    ',5E10.2)
+         ENDIF
 
       ENDIF
       CALL DT_CHASTA(1)