********>Bugfix 8:
Author: Bob Duke
Date: 08/01/06
                                                                                
Programs: pmemd
                                                                                
Description: The iwrap=1 option does not work correctly.
                                                                                
Fix:  apply the following patch to amber9/src/pmemd/src/pbc.fpp

------------------------------------------------------------------------------
*** pbc.fpp	2006-04-03 19:35:48.000000000 -0400
--- pbc.fpp	2006-08-02 11:07:19.000000000 -0400
***************
*** 769,774 ****
--- 769,775 ----
                  crd(3, j) * recip(3, 3)
      end do
  
+ #if 0
      f1 = f1/molsiz(i)
      f2 = f2/molsiz(i)
      f3 = f3/molsiz(i)
***************
*** 784,789 ****
--- 785,799 ----
      g3 = f3
      if (f3 .lt. 0.d0) g3 = f3 + 1.d0
      if (f3 .ge. 1.d0) g3 = f3 - 1.d0
+ #else
+     f1 = f1/molsiz(i) - 0.5d0
+     f2 = f2/molsiz(i) - 0.5d0
+     f3 = f3/molsiz(i) - 0.5d0
+ 
+     g1 = f1 - anint(f1)
+     g2 = f2 - anint(f2)
+     g3 = f3 - anint(f3)
+ #endif
  
      if (f1 .ne. g1 .or. f2 .ne. g2 .or. f3 .ne. g3) then
        tran(1) = (g1 - f1) * ucell(1, 1) + (g2 - f2) * ucell(1, 2) + &
------------------------------------------------------------------------------
                                                                                
Temporary workarounds: none