stk.GenericFunctionalGroup
- class stk.GenericFunctionalGroup(atoms, bonders, deleters, placers=None)[source]
Bases:
FunctionalGroup
A functional group which defines general atomic classes.
Bonders are atoms which should have bonds added by a
Reaction
. Deleters are atoms which should be removed by aReaction
.This interface allows the same reactions to be carried out across different functional groups, without knowing which specific elements it holds.
Initialize a
GenericFunctionalGroup
.- Parameters:
atoms (tuple[Atom, ...]) – The atoms in the functional group.
bonders (tuple[Atom, ...]) – The bonder atoms in the functional group.
deleters (tuple[Atom, ...]) – The deleter atoms in the functional group.
placers (Optional[tuple[Atom, ...]]) – The placer atoms of the functional group. If
None
, the bonders will be used.
Methods
Return a clone.
Yield the ids of all atoms in the functional group.
Yield all the atoms in the functional group.
Yield the ids of bonder atoms.
Yield bonder atoms in the functional group.
Yield the ids of core atoms held by the functional group.
Yield the ids of deleter atoms.
Yield the deleter atoms in the functional group.
Get the number of bonder atoms.
Yield the ids of placer atoms.
Return a clone holding different atoms.
Return a clone holding different atom ids.
- get_atom_ids()
Yield the ids of all atoms in the functional group.
- get_atoms()
Yield all the atoms in the functional group.
- get_bonders()[source]
Yield bonder atoms in the functional group.
These are atoms which have bonds added during
ConstructedMolecule
construction.
- get_core_atom_ids()
Yield the ids of core atoms held by the functional group.
See also
- get_deleters()[source]
Yield the deleter atoms in the functional group.
These are atoms which are removed during
ConstructedMolecule
construction.
- get_num_bonders()[source]
Get the number of bonder atoms.
- Returns:
The number of bonder atoms.
- Return type:
- get_placer_ids()
Yield the ids of placer atoms.
Placer atoms are those, which should be used to calculate the position of the functional group.
- with_atoms(atom_map)[source]
Return a clone holding different atoms.
- with_ids(id_map)[source]
Return a clone holding different atom ids.