ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/OOPSE-4/src/UseTheForce/DarkSide/eam.F90
(Generate patch)

Comparing trunk/OOPSE-4/src/UseTheForce/DarkSide/eam.F90 (file contents):
Revision 2290 by chrisfen, Fri Aug 26 22:39:25 2005 UTC vs.
Revision 2291 by chuckv, Wed Sep 14 20:31:38 2005 UTC

# Line 227 | Line 227 | contains
227      
228      eamID = EAMList%atidToEAMType(atomID)
229      cutValue = EAMList%EAMParams(eamID)%eam_rcut
230
230    end function getEAMCut
231  
232    subroutine init_EAM_FF(status)
# Line 560 | Line 559 | contains
559      ! we don't use the derivatives, dummy variables
560      real( kind = dp) :: drho,d2rho
561      integer :: eam_err
562 +    
563 +    integer :: atid1,atid2 ! Global atid    
564 +    integer :: myid_atom1 ! EAM atid
565 +    integer :: myid_atom2
566  
564    integer :: myid_atom1
565    integer :: myid_atom2
567  
568      ! check to see if we need to be cleaned at the start of a force loop
569  
# Line 570 | Line 571 | contains
571  
572  
573   #ifdef IS_MPI
574 <    myid_atom1 = atid_Row(atom1)
575 <    myid_atom2 = atid_Col(atom2)
576 < #else
577 <    myid_atom1 = atid(atom1)
578 <    myid_atom2 = atid(atom2)
574 >    Atid1 = Atid_row(Atom1)
575 >    Atid2 = Atid_col(Atom2)
576 > #else
577 >    Atid1 = Atid(Atom1)
578 >    Atid2 = Atid(Atom2)
579   #endif
580  
581 +    Myid_atom1 = Eamlist%atidtoeamtype(Atid1)
582 +    Myid_atom2 = Eamlist%atidtoeamtype(Atid2)
583 +
584      if (r.lt.EAMList%EAMParams(myid_atom1)%eam_rcut) then
585  
586  
# Line 594 | Line 598 | contains
598   #else
599         rho(atom2) = rho(atom2) + rho_i_at_j
600   #endif
601 <       !       write(*,*) atom1,atom2,r,rho_i_at_j
601 >             ! write(*,*) atom1,atom2,r,rho_i_at_j
602      endif
603  
604      if (r.lt.EAMList%EAMParams(myid_atom2)%eam_rcut) then
# Line 632 | Line 636 | contains
636      integer :: atom
637      real(kind=dp) :: U,U1,U2
638      integer :: atype1
639 <    integer :: me
639 >    integer :: me,atid1
640      integer :: n_rho_points
641  
642  
# Line 657 | Line 661 | contains
661  
662      !! Calculate F(rho) and derivative
663      do atom = 1, nlocal
664 <       me = atid(atom)
664 >       atid1 = atid(atom)
665 >       me = eamList%atidToEAMtype(atid1)
666         n_rho_points = EAMList%EAMParams(me)%eam_nrho
667         !  Check to see that the density is not greater than the larges rho we have calculated
668         if (rho(atom) < EAMList%EAMParams(me)%eam_rhovals(n_rho_points)) then
# Line 751 | Line 756 | contains
756      integer :: id1,id2
757      integer  :: mytype_atom1
758      integer  :: mytype_atom2
759 <
759 >    integer  :: atid1,atid2
760      !Local Variables
761  
762      ! write(*,*) "Frho: ", Frho(atom1)
# Line 763 | Line 768 | contains
768      if (rij .lt. EAM_rcut) then
769  
770   #ifdef IS_MPI
771 <       mytype_atom1 = atid_row(atom1)
772 <       mytype_atom2 = atid_col(atom2)
773 < #else
774 <       mytype_atom1 = atid(atom1)
775 <       mytype_atom2 = atid(atom2)
771 >       atid1 = atid_row(atom1)
772 >       atid2 = atid_col(atom2)
773 > #else
774 >       atid1 = atid(atom1)
775 >       atid2 = atid(atom2)
776   #endif
777 +
778 +       mytype_atom1 = EAMList%atidToEAMType(atid1)
779 +       mytype_atom2 = EAMList%atidTOEAMType(atid2)
780 +
781 +
782         ! get cutoff for atom 1
783         rci = EAMList%EAMParams(mytype_atom1)%eam_rcut
784         ! get type specific cutoff for atom 2

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines