Bond Rearrangement#

class autode.bond_rearrangement.BondRearrangement(forming_bonds=None, breaking_bonds=None)#
__eq__(other)#

Return self==value.

__init__(forming_bonds=None, breaking_bonds=None)#

Bond rearrangement

Keyword Arguments:

breaking_bonds (list(tuple(int))) – List of atom pairs that are breaking in the reaction

__str__()#

Return str(self).

property active_atoms#

Unique atom indexes in forming or breaking bonds

property batoms#

Unique atoms indexes involved in breaking bonds

property fatoms#

Unique atoms indexes involved in forming bonds

get_active_atom_neighbour_lists(species, depth)#

Get neighbour lists of all the active atoms in the molecule (reactant complex)

Parameters:

depth (int) – Depth of the neighbour list to consider

Return type:

(list(list(str)))

property n_bbonds#
property n_fbonds#
n_membered_rings(mol)#

Find the membered-ness of the rings involved in this bond rearrangement will add the forming bonds to the graph to determine

Return type:

(list(int))

autode.bond_rearrangement.add_bond_rearrangment(bond_rearrangs, reactant, product, fbonds, bbonds)#

For a possible bond rearrangement, sees if the products are made, and adds it to the bond rearrang list if it does

Parameters:
  • reactant (autode.species.Complex) – Reactant complex

  • product (autode.species.Complex) – Product complex

  • fbonds (list(tuple)) – list of bonds to be made

  • bbonds (list(tuple)) – list of bonds to be broken

Return type:

(list(autode.bond_rearrangements.BondRearrangement))

autode.bond_rearrangement.generate_rearranged_graph(graph, fbonds, bbonds)#

Generate a rearranged graph by breaking bonds (edge) and forming others (edge)

Parameters:
  • fbonds (list(tuple)) – list of bonds to be made

  • bbonds (list(tuple)) – list of bonds to be broken

Returns:

rearranged graph

Return type:

nx.Graph

autode.bond_rearrangement.get_bond_rearrangs(reactant, product, name, save=True)#

For a reactant and product (mol_complex) find the set of breaking and forming bonds that will turn reactants into products. This works by determining the types of bonds that have been made/broken (i.e CH) and then only considering rearrangements involving those bonds.

Parameters:
  • product (autode.species.ProductComplex) –

  • name (str) –

Keyword Arguments:

save (bool) – Save bond rearrangements to a file for fast reloading

Return type:

(list(autode.bond_rearrangements.BondRearrangement))

autode.bond_rearrangement.get_bond_rearrangs_from_file(filename='bond_rearrangs.txt')#

Extract a list of bond rearrangements from a file

Return type:

(list(autode.bond_rearrangements.BondRearrangement))

autode.bond_rearrangement.get_fbonds_bbonds_1b(reac, prod, possible_brs, all_possible_bbonds, all_possible_fbonds, possible_bbond_and_fbonds, bbond_atom_type_fbonds, fbond_atom_type_bbonds)#
autode.bond_rearrangement.get_fbonds_bbonds_1b1f(reac, prod, possible_brs, all_possible_bbonds, all_possible_fbonds, possible_bbond_and_fbonds, bbond_atom_type_fbonds, fbond_atom_type_bbonds)#
autode.bond_rearrangement.get_fbonds_bbonds_2b(reac, prod, possible_brs, all_possible_bbonds, all_possible_fbonds, possible_bbond_and_fbonds, bbond_atom_type_fbonds, fbond_atom_type_bbonds)#
autode.bond_rearrangement.get_fbonds_bbonds_2b1f(reac, prod, possible_brs, all_possible_bbonds, all_possible_fbonds, possible_bbond_and_fbonds, bbond_atom_type_fbonds, fbond_atom_type_bbonds)#
autode.bond_rearrangement.get_fbonds_bbonds_2b2f(reac, prod, possible_brs, all_possible_bbonds, all_possible_fbonds, possible_bbond_and_fbonds, bbond_atom_type_fbonds, fbond_atom_type_bbonds)#
autode.bond_rearrangement.prune_small_ring_rearrs(possible_brs, mol)#

Remove any bond rearrangements that go via small (3, 4) rings if there is an alternative that goes vie

Parameters:

mol (autode.species.Complex) – Reactant

autode.bond_rearrangement.save_bond_rearrangs_to_file(brs, filename='bond_rearrangs.txt')#

Save a list of bond rearrangements to a file in plane text

Parameters:

filename (str) –

autode.bond_rearrangement.strip_equiv_bond_rearrs(possible_brs, mol, depth=6)#

Remove any bond rearrangement from possible_brs for which there is already an equivalent in the unique_bond_rearrangements list

Parameters:

mol (autode.species.Complex) – Reactant

Keyword Arguments:

depth (int) – Depth of neighbour list that must be identical for a set of atoms to be considered equivalent (default: {6})

Returns:

stripped list of BondRearrangement objects

Return type:

(list(BondRearrangement))