Révision 5 ase/embed.py
embed.py (revision 5) | ||
---|---|---|
225 | 225 |
# go over all pairs of atoms |
226 | 226 |
for iat_sys in xrange(nat_sys): |
227 | 227 |
xyz = positions_new[iat_sys] |
228 |
self.atoms_system[iat_sys].set_position(xyz) |
|
228 | 229 |
iat_cl = self.atom_map_sys_cl[iat_sys] |
229 |
self.atoms_system[iat_sys].set_position(xyz) |
|
230 | 230 |
if iat_cl > -1: |
231 | 231 |
self.atoms_cluster[iat_cl].set_position(xyz) |
232 | 232 |
|
233 | 233 |
for cell_L, iat_cl_sys, iat_sys, r, iat in self.linkatoms: |
234 | 234 |
# determine position of the link atom |
235 |
xyz_cl = self.atoms_system[iat_cl_sys].get_position()
|
|
236 |
xyz = self.atoms_system[iat_sys].get_position() - xyz_cl + cell_L
|
|
235 |
xyz_cl = positions_new[iat_cl_sys]
|
|
236 |
xyz = positions_new[iat_sys] - xyz_cl + cell_L
|
|
237 | 237 |
xyz *= r / np.sqrt(np.dot(xyz, xyz)) |
238 | 238 |
xyz += xyz_cl |
239 | 239 |
# update xyz coordinates of the cluster |
Formats disponibles : Unified diff