# Molecular representations (rmgpy.molecule)¶

The rmgpy.molecule subpackage contains classes and functions for working with molecular representations, particularly using chemical graph theory.

## Graphs¶

Class

Description

Vertex

A generic vertex (node) in a graph

Edge

A generic edge (arc) in a graph

Graph

A generic graph data type

## Graph isomorphism¶

Class

Description

VF2

Graph isomorphism using the VF2 algorithm

## Elements and atom types¶

Class/Function

Description

Element

A model of a chemical element

get_element()

Return the Element object for a given atomic number or symbol

AtomType

A model of an atom type: an element and local bond structure

get_atomtype()

Return the AtomType object for a given atom in a molecule

## Molecules¶

Class

Description

Atom

An atom in a molecule

Bond

A bond in a molecule

Molecule

A molecular structure represented using a chemical graph

## Functional groups¶

Class

Description

GroupAtom

An atom in a functional group

GroupBond

A bond in a functional group

Group

A functional group structure represented using a chemical graph

## Molecule Utilities¶

Class

Description

rmgpy.molecule.resonance

Resonance structure generation methods

rmgpy.molecule.kekulize

Kekule structure generation

rmgpy.molecule.filtration

Resonance structure filtration methods

rmgpy.molecule.pathfinder

Resonance path enumeration

rmgpy.molecule.converter

Molecule object converter (RDKit/OpenBabel)

rmgpy.molecule.translator

Molecule string representation translator

Function

Description

from_adjacency_list()

Convert an adjacency list to a set of atoms and bonds

to_adjacency_list()

Convert a set of atoms and bonds to an adjacency list

## Symmetry numbers¶

Class

Description

calculate_atom_symmetry_number()

Calculate the atom-centered symmetry number for an atom in a molecule

calculate_bond_symmetry_number()

Calculate the bond-centered symmetry number for a bond in a molecule

calculate_axis_symmetry_number()

Calculate the axis-centered symmetry number for a double bond axis in a molecule

calculate_cyclic_symmetry_number()

Calculate the ring-centered symmetry number for a ring in a molecule

calculate_symmetry_number()

Calculate the total internal + external symmetry number for a molecule

## Molecule and reaction drawing¶

Class

Description

MoleculeDrawer

Draw the skeletal formula of a molecule

ReactionDrawer

Draw a chemical reaction