orthonym.rules.skeletal_replacement#

Note

Internal API. Names and behaviour may change between releases.

Skeletal replacement (“a”) nomenclature for chains with embedded heteroatoms.

Implements IUPAC 2013 replacement nomenclature where heteroatoms embedded in a carbon chain backbone are named using replacement terms (oxa, aza, thia, etc.) rather than substitutive prefixes (methoxy, amino, etc.).

Examples: the ‘a’ name is the PIN only with >= 4 heterounits):

COCCOCCOCCOC -> 2,5,8,11-tetraoxadodecane (4 O; BB:27762) OCCOCCOCCOCCOCC -> 3,6,9,12-tetraoxatetradecan-1-ol (4 O + -ol suffix) COCCOCCOC -> None (3 O: the substitutive PIN is

1-methoxy-2-(2-methoxyethoxy)ethane, BB:27756)

OCCOCCOCC -> None (2 O: 2-(2-ethoxyethoxy)ethan-1-ol) CCNCCC -> None (amine gate; substitutive N-ethylpropan-1-amine)

Scope: Chain-only (acyclic). Rings <= 10 atoms are handled by Hantzsch-Widman naming in the heterocycles module.

References

IUPAC 2013 Blue Book, (Replacement nomenclature) IUPAC 2013 Blue Book, (Order of citation of replacement terms)

orthonym.rules.skeletal_replacement.try_skeletal_replacement_name(mol)#

Try to name a molecule using skeletal replacement nomenclature.

Returns an IUPAC replacement name if the molecule is an acyclic chain with embedded heteroatoms suitable for replacement naming. Returns None if the molecule does not qualify (cyclic, has priority functional groups, too few heteroatoms, etc.).

Supports terminal alcohol (-OH) suffix integration:

OCCOCCOCC -> 3,6-dioxaoctan-1-ol

Parameters:

mol (Mol) – RDKit molecule object (already parsed from SMILES).

Returns:

Replacement name string (e.g., ‘2,5-dioxahexane’) or None.

Return type:

str | None