45 |
|
|
46 |
|
!! @author Charles F. Vardeman II |
47 |
|
!! @author Matthew Meineke |
48 |
< |
!! @version $Id: doForces.F90,v 1.85 2007-04-06 21:53:41 gezelter Exp $, $Date: 2007-04-06 21:53:41 $, $Name: not supported by cvs2svn $, $Revision: 1.85 $ |
48 |
> |
!! @version $Id: doForces.F90,v 1.86 2007-04-09 18:24:00 gezelter Exp $, $Date: 2007-04-09 18:24:00 $, $Name: not supported by cvs2svn $, $Revision: 1.86 $ |
49 |
|
|
50 |
|
|
51 |
|
module doForces |
576 |
|
|
577 |
|
write(errMsg, *) & |
578 |
|
'cutoffRadius and switchingRadius are set to the same', newline & |
579 |
< |
// tab, 'value. OOPSE will use shifted ', newline & |
579 |
> |
// tab, 'value. OOPSE will use shifted force van der Waals', newline & |
580 |
|
// tab, 'potentials instead of switching functions.' |
581 |
|
|
582 |
|
call handleInfo("setCutoffs", errMsg) |
1088 |
|
fij(1) = fij(1) + fpair(1) |
1089 |
|
fij(2) = fij(2) + fpair(2) |
1090 |
|
fij(3) = fij(3) + fpair(3) |
1091 |
< |
if (do_stress.and.SIM_uses_AtomicVirial) then |
1091 |
> |
if (do_stress) then |
1092 |
|
call add_stress_tensor(d_atm, fpair, tau) |
1093 |
|
endif |
1094 |
|
endif |
1117 |
|
f(2,atom1) = f(2,atom1) + fg(2) |
1118 |
|
f(3,atom1) = f(3,atom1) + fg(3) |
1119 |
|
#endif |
1120 |
< |
if (do_stress.and.SIM_uses_AtomicVirial) then |
1121 |
< |
! find the distance between the atom and the center of |
1122 |
< |
! the cutoff group: |
1120 |
> |
if (n_in_i .gt. 1) then |
1121 |
> |
if (do_stress.and.SIM_uses_AtomicVirial) then |
1122 |
> |
! find the distance between the atom and the center of |
1123 |
> |
! the cutoff group: |
1124 |
|
#ifdef IS_MPI |
1125 |
< |
call get_interatomic_vector(q_Row(:,atom1), & |
1126 |
< |
q_group_Row(:,i), dag, rag) |
1125 |
> |
call get_interatomic_vector(q_Row(:,atom1), & |
1126 |
> |
q_group_Row(:,i), dag, rag) |
1127 |
|
#else |
1128 |
< |
call get_interatomic_vector(q(:,atom1), & |
1129 |
< |
q_group(:,i), dag, rag) |
1128 |
> |
call get_interatomic_vector(q(:,atom1), & |
1129 |
> |
q_group(:,i), dag, rag) |
1130 |
|
#endif |
1131 |
< |
call add_stress_tensor(dag,fg,tau) |
1131 |
> |
call add_stress_tensor(dag,fg,tau) |
1132 |
> |
endif |
1133 |
|
endif |
1134 |
|
enddo |
1135 |
|
|
1148 |
|
f(2,atom2) = f(2,atom2) + fg(2) |
1149 |
|
f(3,atom2) = f(3,atom2) + fg(3) |
1150 |
|
#endif |
1151 |
< |
if (do_stress.and.SIM_uses_AtomicVirial) then |
1152 |
< |
! find the distance between the atom and the center of |
1153 |
< |
! the cutoff group: |
1151 |
> |
if (n_in_j .gt. 1) then |
1152 |
> |
if (do_stress.and.SIM_uses_AtomicVirial) then |
1153 |
> |
! find the distance between the atom and the center of |
1154 |
> |
! the cutoff group: |
1155 |
|
#ifdef IS_MPI |
1156 |
< |
call get_interatomic_vector(q_Col(:,atom2), & |
1157 |
< |
q_group_Col(:,j), dag, rag) |
1156 |
> |
call get_interatomic_vector(q_Col(:,atom2), & |
1157 |
> |
q_group_Col(:,j), dag, rag) |
1158 |
|
#else |
1159 |
< |
call get_interatomic_vector(q(:,atom2), & |
1160 |
< |
q_group(:,j), dag, rag) |
1159 |
> |
call get_interatomic_vector(q(:,atom2), & |
1160 |
> |
q_group(:,j), dag, rag) |
1161 |
|
#endif |
1162 |
< |
call add_stress_tensor(dag,fg,tau) |
1163 |
< |
endif |
1164 |
< |
|
1162 |
> |
call add_stress_tensor(dag,fg,tau) |
1163 |
> |
endif |
1164 |
> |
endif |
1165 |
|
enddo |
1163 |
– |
endif |
1164 |
– |
if (do_stress.and.(.not.SIM_uses_AtomicVirial)) then |
1165 |
– |
call add_stress_tensor(d_grp, fij, tau) |
1166 |
|
endif |
1167 |
|
endif |
1168 |
|
endif |