scine_chemoton.gears.elementary_steps.trial_generator.connectivity_analyzer

Classes

ConnectivityAnalyzer(structure)

A class holding the molecule representation of a structure allowing to retrieve information about its bonding situation and the connectivity effect of trial reaction coordinates.

ReactionType(value)

Different types of reactions to be distinguished here.

class scine_chemoton.gears.elementary_steps.trial_generator.connectivity_analyzer.ConnectivityAnalyzer(structure)[source]

A class holding the molecule representation of a structure allowing to retrieve information about its bonding situation and the connectivity effect of trial reaction coordinates.

Attributes:
structuredb.Structure

The structure of interest. It has to be connected to a database and has to have a graph attached.

get_adjacency_matrix()[source]

Gets the adjacency matrix for the structure with the indices ordered as in the structure.

Return type:

lil_matrix

Returns:
lil_matrix

The adjacency matrix which is True if there is a direct bond and False otherwise.

get_graph_distance(atom1, atom2)[source]

Calculates the graph distance between the atoms with indices atom1 and atom2.

Parameters:
atom1int

The index of the first atom of interest.

atom2int

The index of the second atom of interest.

Returns:
int

The graph distance between atoms 1 and 2.

Notes

Return infinity if the two atoms do not belong to the same graph

get_reaction_type(reactive_pair_list)[source]

Determines what kind of intrastructural reaction (associative, dissociative, disconnective) a reactive complex guess describes.

Return type:

ReactionType

Parameters:
reactive_pair_listList[Tuple[int]]

List of reacting atom index pairs

Returns:
reaction_typeElementaryStepGear.ElementaryStepType

What kind of reaction is initiated by this reactive complex.

pair_is_bound(atom1, atom2)[source]

Check whether two atoms are bound in a structure according to its graph.

Return type:

bool

Parameters:
atom1int

Index of the first atom.

atom2int

Index of the second atom.

Returns:
bool

True if the two atoms are bound and False if not.

class scine_chemoton.gears.elementary_steps.trial_generator.connectivity_analyzer.ReactionType(value)[source]

Different types of reactions to be distinguished here.

  • Mixed: Neither purely associative nor dissociative

  • Associative: Only new bonds are generated

  • Dissociative: Only bond breaking but the molecule is not split

  • Disconnective: Only bond breaking and the molecule is split

Associative = 0
Disconnective = 2
Dissociative = 1
Mixed = None