mofbuilder.md.LinkerForceFieldGenerator#
- class mofbuilder.md.LinkerForceFieldGenerator(comm=None, ostream=None)[source]#
Bases:
objectForcefield generation and mapping for linker molecules in MOFs.
Handles optimization (with QM/xtb), reintroduction of missing bonds, and mapping of existing forcefields onto new linker instances.
- Parameters:
comm (Any)
ostream (veloxchem.outputstream.OutputStream | None)
- comm#
MPI communicator (defaults to MPI.COMM_WORLD).
- Type:
Any
- rank#
MPI process rank.
- Type:
int
- nodes#
Number of MPI processes.
- Type:
int
- ostream#
Output stream for logging.
- Type:
OutputStream
- linker_optimization#
Whether to optimize linker geometry.
- Type:
bool
- optimize_drv#
Optimization method, ‘xtb’ or ‘qm’.
- Type:
str
- linker_ff_name#
Name for linker forcefield.
- Type:
str
- linker_residue_name#
Residue name for linker in topology.
- Type:
str
- resp_charges#
Whether to use RESP charges.
- Type:
bool
- linker_fake_edge#
If True, treats X-X as fake edges.
- Type:
bool
- linker_charge#
Net charge of linker molecule.
- Type:
int
- linker_multiplicity#
Multiplicity for linker molecule.
- Type:
int
- target_directory#
Directory where output files will be written.
- Type:
Optional[str]
- save_files#
Whether to save output structures.
- Type:
bool
- src_linker_forcefield_itpfile#
Path to reference linker .itp.
- Type:
Optional[str]
- src_linker_molecule#
Reference linker molecule object.
- Type:
Optional[Molecule]
- dest_linker_molecule#
Reconnected linker molecule (after-building).
- Type:
Optional[Molecule]
- dest_molecule_connectivity_matrix#
Connectivity matrix for MOF-linked linker.
- Type:
Optional[np.ndarray]
- linker_itp_path#
Path to generated linker .itp file.
- Type:
Optional[Path]
- free_opt_linker_mol#
Free optimized linker molecule (QM or xtb).
- Type:
Optional[Molecule]
- _debug#
Print debug output if True.
- Type:
bool
- _reconnect_linker_molecule()[source]#
Generates a VeloxChem Molecule from input coordinates, rebuilding X-X bonds.
- generate_reconnected_molecule_forcefield()[source]#
Generates a GROMACS forcefield (.itp) for the reconnected linker.
- Parameters:
linker_mol_data (ndarray | None)
- Return type:
None
- map_existing_forcefield()[source]#
Maps existing forcefield (.itp) from source to a reconnected/new linker instance.
- Parameters:
linker_mol_data (ndarray | None)
- Return type:
None