ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/branches/new_design/OOPSE-3.0/src/UseTheForce/DarkSide/dipole.F90
(Generate patch)

Comparing branches/new_design/OOPSE-3.0/src/UseTheForce/DarkSide/dipole.F90 (file contents):
Revision 1858, Thu Oct 28 22:34:02 2004 UTC vs.
Revision 1859 by tim, Mon Dec 6 23:29:20 2004 UTC

# Line 20 | Line 20 | module dipole_dipole
20    public :: getDipoleMoment
21  
22    type :: MomentList
23 <     integer :: ident
23 >     integer :: c_ident
24       real(kind=DP) :: dipole_moment = 0.0_DP
25    end type MomentList
26  
# Line 28 | Line 28 | contains
28  
29   contains
30  
31 <  subroutine newDipoleType(ident, dipole_moment, status)
32 <    integer,intent(in) :: ident
31 >  subroutine newDipoleType(c_ident, dipole_moment, status)
32 >    integer,intent(in) :: c_ident
33      real(kind=dp),intent(in) :: dipole_moment
34      integer,intent(out) :: status
35 <    integer :: nAtypes
35 >    integer :: nAtypes, myATID
36  
37      status = 0
38 +    myATID = getFirstMatchingElement(atypes, "c_ident", c_ident)
39      
40      !! Be simple-minded and assume that we need a MomentMap that
41      !! is the same size as the total number of atom types
# Line 54 | Line 55 | contains
55        
56      end if
57  
58 <    if (ident .gt. size(MomentMap)) then
58 >    if (myATID .gt. size(MomentMap)) then
59         status = -1
60         return
61      endif
62      
63      ! set the values for MomentMap for this atom type:
64  
65 <    MomentMap(ident)%ident = ident
66 <    MomentMap(ident)%dipole_moment = dipole_moment
65 >    MomentMap(myATID)%c_ident = c_ident
66 >    MomentMap(myATID)%dipole_moment = dipole_moment
67      
68    end subroutine newDipoleType
69  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines