********> bugfix.47 Correction Author: David A. Pearlman Correction Date: 8/18/92 Programs: GIBBS Severity: moderate Problem: On some computers and under some conditions, the GIBBS program could inexplicably crash (e.g. when concluding a dynamic windows run on an HP 700 series). Affects: The simulation would stop (with a coredump on a Unix type machine). The crash is triggered by a floating point exception in an arithmetic statement, the resultant of which is not subsequently used. There are absolutely no ill-effects if the program does not crash. On any machine where the program did not crash, the results would be correct. On any machine where the program did crash, any results printed prior to the crash would be correct. Cause: A small number of uninitialized variables were being used in arithmetic or format statements. These variables would only be uninitialized in cases where the resultant of the arithmetic expression or print was not subsequently used. But in some cases these operations could result in floating under/overflows. Fix: Make the following change to routine RUNMD ---To routine RUNMD in file giba.f ----------------------------------------- *** OLD giba.f --- NEW giba.f *************** *** 4033,4038 **** --- 4033,4046 ---- NRX = NR3 IF(NTWX.LT.0) NRX = NRPT3 C + C Zero a few variables so that if they're not used/set, they won't + C trigger over/underflows on certain compilers + C + CALL ZEROUT(40,EPSTG) + CALL ZEROUT(2,DE) + CALL ZEROUT(2,DS) + CALL ZEROUT(5,TIINT) + C C ----- CLEANUP THE VELOCITY IF BELLY RUN ----- C IF(BELLY) CALL BELLYF(NR,IX(I62),V) ------------------------------------------------------------------------------ Temporary workarounds: You may be able to avoid the problem by setting the ISANDE flag (report entropy/enthalpy contributions) to 1. Routines affected: GIBBS Routine RUNMD in file ...amber4/src/giba.f