Molecule insertion#
This script was designed for adding molecules into the simulation box with existing atoms inside. It is suitable for inserting molecules inside porous materials such as metal organic frameworks (MOFs). The positions and the orientations will be randomly determined considering the overlap with the existing and the pre-added atoms. CO2 and H2O are explicitly defined in the scripts, while the other molecular types are needed to be added by modifying the script.
Input#
optional arguments:
--helpShow helping message and exit
-frameInput framework structure from any format to ASE reader
-h2oThe number of H2O molecules inserted in framework
-co2The number of CO2 molecules inserted in framework
-maxiterMax iteration when placing each molecules
-thresholdThreshold for minimum intermolecular distance when placing molecules
-l_fix_frameworkFix framework or not
-l_sort_molSort molecule layer or not
-seedSeed for random (in case you want the same structure)
-outfileThe name of file to be written out
-formatThe format of output file to be written out
Example#
$ python ./src/insertmolecules.py \
-frame ./structure/calf20.vasp \
-h2o 4 \
-co2 2 \
-outfile output_calf
-format vasp \
-l_fix_framework True \
-threshold 2.1