Back to home page

sPhenix code displayed by LXR

 
 

    


File indexing completed on 2025-08-05 08:15:43

0001     
0002 C*********************************************************************  
0003     
0004       SUBROUTINE LUERRM(MERR,CHMESS)    
0005     
0006 C...Purpose: to inform user of errors in program execution. 
0007       COMMON/LUJETS/N,K(9000,5),P(9000,5),V(9000,5)
0008       SAVE /LUJETS/ 
0009       COMMON/LUDAT1/MSTU(200),PARU(200),MSTJ(200),PARJ(200) 
0010       SAVE /LUDAT1/ 
0011       CHARACTER CHMESS*(*)  
0012     
0013 C...Write first few warnings, then be silent.   
0014       IF(MERR.LE.10) THEN   
0015         MSTU(27)=MSTU(27)+1 
0016         MSTU(28)=MERR   
0017         IF(MSTU(25).EQ.1.AND.MSTU(27).LE.MSTU(26)) WRITE(MSTU(11),1000) 
0018      &  MERR,MSTU(31),CHMESS    
0019     
0020 C...Write first few errors, then be silent or stop program. 
0021       ELSEIF(MERR.LE.20) THEN   
0022         MSTU(23)=MSTU(23)+1 
0023         MSTU(24)=MERR-10    
0024         IF(MSTU(21).GE.1.AND.MSTU(23).LE.MSTU(22)) WRITE(MSTU(11),1100) 
0025      &  MERR-10,MSTU(31),CHMESS 
0026         IF(MSTU(21).GE.2.AND.MSTU(23).GT.MSTU(22)) THEN 
0027           WRITE(MSTU(11),1100) MERR-10,MSTU(31),CHMESS  
0028           WRITE(MSTU(11),1200)  
0029           IF(MERR.NE.17) CALL LULIST(2) 
0030           STOP  
0031         ENDIF   
0032     
0033 C...Stop program in case of irreparable error.  
0034       ELSE  
0035         WRITE(MSTU(11),1300) MERR-20,MSTU(31),CHMESS    
0036         STOP    
0037       ENDIF 
0038     
0039 C...Formats for output. 
0040  1000 FORMAT(/5X,'Advisory warning type',I2,' given after',I6,  
0041      &' LUEXEC calls:'/5X,A)    
0042  1100 FORMAT(/5X,'Error type',I2,' has occured after',I6,   
0043      &' LUEXEC calls:'/5X,A)    
0044  1200 FORMAT(5X,'Execution will be stopped after listing of last ', 
0045      &'event!') 
0046  1300 FORMAT(/5X,'Fatal error type',I2,' has occured after',I6, 
0047      &' LUEXEC calls:'/5X,A/5X,'Execution will now be stopped!')    
0048     
0049       RETURN    
0050       END