MOF Builder#
Initialize the Mofbuilder
mof = vlx.MofBuilder()
/home/rocky/.conda/envs/vlxenv-dev/lib/python3.13/site-packages/veloxchem/database
There are saeveral predefined families of MOFs defined in VeloxChem.
mof.show_available_mof_families()
Available MOF Family:
UiO-66 UiO-67 UiO-68 PCN-222 MOF-545 NU-1000 PCN-224 MOF-525 MOF-535 MOF-808 MOF-818 PCN-777 NU-901 MIL-100 PCN-228 PCN-229 PCN-230 MIL-101
To build a target MOF, you need to:
assign MOF family
assign the node metal type
upload the linker file (with carboxylate) in xyz format \
you can also set the supercell size of the model
then we can build the MOF
we can save the model with gromacs file format and show it
mof.mof_family = 'UiO-66'
mof.node_metal = 'Zr'
mof.linker_xyz_file = '../input_files/linker.xyz'
mof.supercell = (1, 1, 1) # (1,1,1) means primitive cell
mof.build()
mof.show(residue_indices=True, residue_names=False)
node_res_num: 14
edge_res_num: 36
term_res_num: 96
3Dmol.js failed to load for some reason. Please check your browser console for error messages.
we can make defective models by remove linkers or nodes
here we just want to remove the linker in the corner
#the index of the linkers or nodes to be removed can be shown
# in the last cell output
# remove the linker with index "17, 18, 19"
mof.remove(linkers=[17, 18, 39], update_node_termination=True)
mof.show(residue_indices=True)
mof.write_gromacs_files()
built MOF is saved
defective MOF is updated
node_res_num: 14
edge_res_num: 33
term_res_num: 102
node_res_num: 14
edge_res_num: 33
term_res_num: 102
3Dmol.js failed to load for some reason. Please check your browser console for error messages.
gro_name is not set, will be saved as: mof_UiO-66_linker.gro
node_res_num: 14
edge_res_num: 36
term_res_num: 96
writing the gromacs file output_gros/mof_UiO-66_linker.gro
writing the gromacs file output_gros/defective_mof_UiO-66_linker.gro
node_res_num: 14
edge_res_num: 33
term_res_num: 102