- some additional information in HIJGLBR
authormorsch <morsch@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 18 Aug 2010 15:13:23 +0000 (15:13 +0000)
committermorsch <morsch@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 18 Aug 2010 15:13:23 +0000 (15:13 +0000)
- corrections from 8525 and 30837 re-introduced
  (got lost during previous updates)

HIJING/hijing/hijglbr.inc
HIJING/hijing1_36/hijing.F
THijing/Hcommon.h

index 752816c..d852bea 100644 (file)
@@ -1,2 +1,2 @@
-        COMMON/HIJGLBR/NELT,NINT,NELP,NINP
-        SAVE  /HIJGLBR/
\ No newline at end of file
+      COMMON/HIJGLBR/NELT,NINT,NELP,NINP,
+     +NPSPECP, NNSPECP, NPSPECT, NNSPECT 
index 9df2e92..9a50bd2 100644 (file)
@@ -321,6 +321,10 @@ C                  ********Initialize for a new event
         NINP=0
        NSG=0
        NCOLT=0
+        NPSPECP=0
+        NNSPECP=0
+        NPSPECT=0
+        NNSPECT=0 
 
 C****  BB IS THE ABSOLUTE VALUE OF IMPACT PARAMETER,BB**2 IS 
 C       RANDOMLY GENERATED AND ITS ORIENTATION IS RANDOMLY SET 
@@ -542,11 +546,20 @@ c
 c**************************
 c
        DO 201 JP=1,IHNT2(1)
+c           write(6,*) JP, NFP(JP,3), NFP(JP,4), NFP(JP,5)
            IF(NFP(JP,5).GT.2) THEN
               NINP=NINP+1
            ELSE IF(NFP(JP,5).EQ.2.OR.NFP(JP,5).EQ.1) THEN
               NELP=NELP+1
            ENDIF
+
+           IF(NFP(JP,5).LE.2) THEN
+              IF (NFP(JP,3) .EQ. 2212) THEN
+                 NPSPECP = NPSPECP + 1
+              ELSE IF (NFP(JP,3) .EQ. 2112) THEN
+                 NNSPECP = NNSPECP + 1
+              ENDIF
+           ENDIF
  201    continue
        DO 202 JT=1,IHNT2(3)
            IF(NFT(JT,5).GT.2) THEN
@@ -554,6 +567,14 @@ c
            ELSE IF(NFT(JT,5).EQ.2.OR.NFT(JT,5).EQ.1) THEN
               NELT=NELT+1
            ENDIF
+
+           IF(NFT(JT,5).LE.2) THEN
+              IF (NFT(JT,3) .EQ. 2212) THEN
+                 NPSPECT = NPSPECT + 1
+              ELSE IF (NFT(JT,3) .EQ. 2112) THEN
+                 NNSPECT = NNSPECT + 1
+              ENDIF
+           ENDIF
  202    continue
 c     
 c*******************************
@@ -601,7 +622,7 @@ C
                IDSTR=92
                IF(IHPR2(21).EQ.0) THEN
                   CALL LUEDIT_HIJING(2)
-               ELSE
+               ELSE IF (NFTP.EQ. 3 .OR. NFTP .EQ. 13) THEN
 351               N_ST=N_ST+1
                   IF(K(N_ST,2).LT.91.OR.K(N_ST,2).GT.93) GO TO  351
                   IDSTR=K(N_ST,2)
@@ -624,11 +645,15 @@ C
                   KATT(NATT,1)=K(I,2)
                   KATT(NATT,2)=20
                   KATT(NATT,4)=K(I,1)
-                  IF(K(I,3).EQ.0 .OR. K(K(I,3),2).EQ.IDSTR) THEN
-                     KATT(NATT,3)=0
-                  ELSE
-                     KATT(NATT,3)=NATT-I+K(I,3)+N_STR-K(K(I,3),4)
-                  ENDIF
+                   IF(K(I,3).EQ.0 ) THEN
+                      KATT(NATT,3)=0
+                   ELSE
+                      IF(K(K(I,3),2).EQ.IDSTR) THEN
+                         KATT(NATT,3)=0
+                      ELSE
+                         KATT(NATT,3)=NATT-I+K(I,3)+N_STR-K(K(I,3),4)
+                      ENDIF
+                   ENDIF
 C       ****** identify the mother particle
                   PATT(NATT,1)=P(I,1)
                   PATT(NATT,2)=P(I,2)
@@ -681,9 +706,12 @@ C
                N_ST=1
                IDSTR=92
 
+               NFTP=NFP(J_JTP,5)
+               IF(NTP.EQ.2) NFTP=10+NFT(J_JTP,5)
+
                IF(IHPR2(21).EQ.0) THEN
                   CALL LUEDIT_HIJING(2)
-               ELSE
+               ELSE IF (NFTP.EQ. 3 .OR. NFTP .EQ. 13) THEN
 381               N_ST=N_ST+1
                   IF(K(N_ST,2).LT.91.OR.K(N_ST,2).GT.93) GO TO  381
                   IDSTR=K(N_ST,2)
@@ -694,8 +722,7 @@ C
                ENDIF
 C              ******** boost back to lab frame(if it was in)
 C
-               NFTP=NFP(J_JTP,5)
-               IF(NTP.EQ.2) NFTP=10+NFT(J_JTP,5)
+
                N_STR=0
                DO 390 I=N_ST,N
                   IF(K(I,2).EQ.IDSTR) THEN
index 2804eaa..fc1c862 100644 (file)
@@ -511,6 +511,33 @@ typedef struct {
 
 #define HISTRNG COMMON_BLOCK(HISTRNG,histrng)
 COMMON_BLOCK_DEF(HistrngCommon,HISTRNG);
+
+
+/*************************************************************************/
+/*           D E S C R I P T I O N :                                     */
+/*-----------------------------------------------------------------------*/
+/*    The following common block is added to record the number of elastic*/
+/*    (NELT, NELP) and inelastic (NINT, NINP) participants               */
+/*                                                                       */
+/*=======================================================================*/
+/*     COMMON/HIJGLBR/NELT,NINT,NELP,NINP                                */
+/*     SAVE  /HIJGLBR/                                                   */
+/*=======================================================================*/
+typedef struct {
+    Int_t    nelt;
+    Int_t    nint;
+    Int_t    nelp;
+    Int_t    ninp;
+    Int_t    npspecp;
+    Int_t    nnspecp;
+    Int_t    npspect;
+    Int_t    nnspect;
+} HijglbrCommon;
+
+#define HIJGLBR COMMON_BLOCK(HIJGLBR,hijglbr)
+COMMON_BLOCK_DEF(HijglbrCommon,HIJGLBR);    
+
+    
 /*************************************************************************/
 /*           D E S C R I P T I O N :                                     */
 /*-----------------------------------------------------------------------*/
@@ -581,4 +608,5 @@ COMMON_BLOCK_DEF(HistrngCommon,HISTRNG);
 COMMON_BLOCK_DEF(Ludat1_HijingCommon,LUDAT1_HIJING);
 }
 
+
 #endif