Random Bond Factory¶
-
class
RandomBondFactory(max_internal_bonds=4, required_bonds=(), max_bond_order=None, random_seed=None)[source]¶ Bases:
vabene.bond.factories.bond_factory.BondFactoryCreates random collections of bonds.
The bonds yielded will not necessarily create a single molecule.
Parameters: - max_internal_bonds (
int, optional) – Once all atoms have been connected into a single molecule, the factory will create a random number of internal bonds between atoms in the molecule. This sets the maximum number of such bonds. - required_bonds (
tupleofBond) – Bonds, which must be yielded by eachget_bonds()call. - max_bond_order (
int) – The maximum bond order the factory can make. IfNonethe maximum will be the maximum shared valence between the two atoms. - random_seed (
int, optional) – The random seed to use.
Methods
get_bonds(atoms)Yield the bonds of a molecule. - max_internal_bonds (