[AMBER] Output forces or gradients in sqm

From: Jinzhe Zeng <jz748.scarletmail.rutgers.edu>
Date: Thu, 7 Apr 2022 17:16:33 -0400

Dear AMBER sqm developers,

In sqm module, I found the following codes:

AmberTools/src/sqm/sqm.F90, line 416-440:
   !NOW PUT THE CALCULATED gradient (not force!) INTO THE SANDER FORCE ARRAY
   do i=1,qmmm_struct%nquant
     m = qmmm_struct%iqmatoms(i)
     m = (m-1)*3
     forces(m+1) = qmmm_struct%dxyzqm(1,i)
     forces(m+2) = qmmm_struct%dxyzqm(2,i)
     forces(m+3) = qmmm_struct%dxyzqm(3,i)
   enddo

   if (qmmm_mpi%commqmmm_master .AND. qmmm_nml%verbosity > 3) then

      !If verbosity level is greater than 3 we also print the force array
on the QM atoms
      write (6,'("QMMM:")')
      write (6,'("QMMM: Forces on QM atoms from SCF calculation")')
      write (6,'("QMMM: Atm ",i6,": ",3f20.14)')
(j,qmmm_struct%dxyzqm(1,j), qmmm_struct%dxyzqm(2,j), &
           qmmm_struct%dxyzqm(3,j), j=1,qmmm_struct%nquant_nlink)
      if (qmmm_nml%verbosity > 4) then
         !Also print info in KJ/mol
         write (6,'("QMMM:")')
         write (6,'("QMMM: Forces on QM atoms from SCF calculation
(KJ/mol)")')
         write (6,'("QMMM: Atm ",i6,": ",3f20.14)')
(j,qmmm_struct%dxyzqm(1,j)*4.184d0, &
              qmmm_struct%dxyzqm(2,j)*4.184d0,
qmmm_struct%dxyzqm(3,j)*4.184d0, &
              j=1,qmmm_struct%nquant_nlink)
      end if
   end if

Here it's confusing to me that, in line 416, a comment indicates
qmmm_struct%dxyzqm is the gradient but not force. However, in line 429, the
output message calls the same variable "forces". I want to confirm whether
it is gradients or forces.

regards,
Jinzhe
_______________________________________________
AMBER mailing list
AMBER.ambermd.org
http://lists.ambermd.org/mailman/listinfo/amber
Received on Thu Apr 07 2022 - 14:30:02 PDT
Custom Search