Révision fe91ddb2 modules/screening.py
b/modules/screening.py | ||
---|---|---|
381 | 381 |
@param coll_coeff: The coefficient that multiplies the covalent radius of |
382 | 382 |
atoms resulting in a distance that two atoms being closer to that is |
383 | 383 |
considered as atomic collision. |
384 |
@param height: Height on which to try adsorption |
|
384 |
@param height: Height on which to try adsorption.
|
|
385 | 385 |
@return collision: bool, whether the structure generated has collisions |
386 | 386 |
between slab and adsorbate. |
387 | 387 |
""" |
... | ... | |
506 | 506 |
|
507 | 507 |
def ads_euler(orig_molec, slab, ctr_coord, site_coord, num_pts, |
508 | 508 |
min_coll_height, coll_coeff, norm_vect, slab_nghbs, molec_nghbs, |
509 |
h_donor, h_acceptor): |
|
509 |
h_donor, h_acceptor, height):
|
|
510 | 510 |
"""Generates adsorbate-surface structures by sampling over Euler angles. |
511 | 511 |
|
512 | 512 |
This function generates a number of adsorbate-surface structures at |
... | ... | |
529 | 529 |
@param molec_nghbs: Number of neighbors in the molecule. |
530 | 530 |
@param h_donor: List of atom types or atom numbers that are H-donors. |
531 | 531 |
@param h_acceptor: List of atom types or atom numbers that are H-acceptors. |
532 |
@param height: Height on which to try adsorption. |
|
532 | 533 |
@return: list of ase.Atoms object conatining all the orientations of a given |
533 | 534 |
conformer. |
534 | 535 |
""" |
... | ... | |
550 | 551 |
num_pts, min_coll_height, |
551 | 552 |
norm_vect, |
552 | 553 |
slab_nghbs, molec_nghbs, |
553 |
coll_coeff) |
|
554 |
coll_coeff, height)
|
|
554 | 555 |
if not collision and not any([np.allclose(slab_molec.positions, |
555 | 556 |
conf.positions) |
556 | 557 |
for conf in slab_ads_list]): |
... | ... | |
831 | 832 |
|
832 | 833 |
def ads_internal(orig_molec, slab, ctr1_mol, ctr2_mol, ctr3_mol, ctr1_surf, |
833 | 834 |
ctr2_surf, num_pts, min_coll_height, coll_coeff, norm_vect, |
834 |
slab_nghbs, molec_nghbs, h_donor, h_acceptor, max_hel): |
|
835 |
slab_nghbs, molec_nghbs, h_donor, h_acceptor, max_hel, height):
|
|
835 | 836 |
"""Generates adsorbate-surface structures by sampling over internal angles. |
836 | 837 |
|
837 | 838 |
@param orig_molec: ase.Atoms object of the molecule to adsorb (adsorbate). |
... | ... | |
859 | 860 |
@param h_acceptor: List of atom types or atom numbers that are H-acceptors. |
860 | 861 |
@param max_hel: Maximum value for sampling the helicopter |
861 | 862 |
(surf-adsorbate dihedral) angle. |
863 |
@param height: Height on which to try adsorption. |
|
862 | 864 |
@return: list of ase.Atoms object conatining all the orientations of a given |
863 | 865 |
conformer. |
864 | 866 |
""" |
... | ... | |
884 | 886 |
ctr_coords, site_coords, |
885 | 887 |
num_pts, min_coll_height, |
886 | 888 |
norm_vect, slab_nghbs, |
887 |
molec_nghbs, coll_coeff) |
|
889 |
molec_nghbs, coll_coeff, |
|
890 |
height) |
|
888 | 891 |
if not collision and \ |
889 | 892 |
not any([np.allclose(slab_molec.positions, |
890 | 893 |
conf.positions) |
... | ... | |
920 | 923 |
coll_coeff = inp_vars['collision_threshold'] |
921 | 924 |
h_donor = inp_vars['h_donor'] |
922 | 925 |
h_acceptor = inp_vars['h_acceptor'] |
926 |
height = inp_vars['adsorption_height'] |
|
923 | 927 |
|
924 | 928 |
if inp_vars['pbc_cell'] is not False: |
925 | 929 |
surf.set_pbc(True) |
... | ... | |
954 | 958 |
num_pts, min_coll_height, |
955 | 959 |
coll_coeff, norm_vect, |
956 | 960 |
surf_nghbs, molec_nghbs, |
957 |
h_donor, h_acceptor)) |
|
961 |
h_donor, h_acceptor, height))
|
|
958 | 962 |
elif angles == 'internal': |
959 | 963 |
mol_ctr1 = molec_ctrs[c] |
960 | 964 |
mol_ctr2 = inp_vars["molec_ctrs2"][c] |
... | ... | |
969 | 973 |
coll_coeff, norm_vect, |
970 | 974 |
surf_nghbs, molec_nghbs, |
971 | 975 |
h_donor, h_acceptor, |
972 |
max_h)) |
|
976 |
max_h, height))
|
|
973 | 977 |
return surf_ads_list |
974 | 978 |
|
975 | 979 |
|
Formats disponibles : Unified diff