orthonym.assembly.universal_halane#
Note
Internal API. Names and behaviour may change between releases.
UN lane H – a hypervalent halogen atom (Cl, Br, I) in the universal floor, as a one-atom parent hydride or substituent root with the lambda convention.
The floor (universal_substituent) builds a name from a spine of skeletal atoms (carbon and the
‘a’-replacement heteroatoms) and cites everything else as a prefix. A halogen with a bonding number
other than its standard one is neither: it is not an ‘a’ atom (no REPLACEMENT_TERMS morpheme), and a
spine that threaded it would count it as a carbon of the chain and drop it from the name (a phantom
methane, universal_substituent._chain_spine_from_path). That guard stays; this module gives the
atom a way to be named that does not go through a spine at all: it is its own one-atom parent, or the
root of one substituent, and every neighbour is a prefix named by the floor’s own recursion.
“Nomenclature based on halogen parent hydrides” (the Blue Book): “For cyclic and acyclic parent hydrides the lambda convention is used to indicate nonstandard bonding numbers.” ‘CH3-ICl2 dichloro(methyl)-lambda3-iodane (PIN)’, ‘C6H5-I(OH)2 phenyl-lambda3-iodanediol (PIN)’, ‘(CH3-CO-O)2I- bis(acetyloxy)-lambda3-iodanyl (preferred prefix)’. The token comes from
rules.lambda_convention(LAMBDA,nonstandard_bonding_number), the one home of the lambda convention.“Seniority order for classes”, Table 4.1 (the Blue Book): class 39 “lambda7, lambda5 and lambda3 halogen compounds in the order F > Cl > Br > I” (:18215) is senior to class 40 “Carbon compounds: rings, chains”. That is the only seniority applied here:
halane_parentmakes a hypervalent halogen the parent of the whole molecule whatever else it holds, and a ring or chain a prefix of it. The classes above 39 are NOT checked: the principal characteristic groups (classes 1-20: an acid, an ester, an alcohol, an amine… would take the suffix and the parent) and the heteroatom hydrides N > P > As > Sb > Bi > Si > Ge > Sn > Pb > B > Al > Ga > In > Tl > O > S > Se > Te (classes 21-38,,:18917). The floor writes no suffix and ranks no class anywhere, so its names are systematic, never a PIN; applying to a hypervalent halogen is a lead, not built. A second hypervalent halogen of the molecule is the root of a substituent of the first.“The locant ‘1’ is omitted: (a) in substituted mononuclear parent hydrides” (the Blue Book): the prefixes of the one-atom parent carry no locant, the second and further enclosed, (:7272: “The second and further substituents are each enclosed with parentheses even for simple substituents”), by the shared assembler
composer._assemble_decorated_amino_prefixthat spells ‘dimethylphosphanyl’ and ‘hydroxy(methyl)’ for the other mononuclear parents.“Substituent prefixes derived from mononuclear parent hydrides” (:15856): “Other mononuclear parent hydrides, i.e., those derived from O, F, Cl, Br, I, S,… are named by method (2) in “, the ‘-yl’ of the hydride name with its final ‘e’ elided (iodane -> iodanyl, iodanylidene), and “Substituent groups derived from mononuclear parent hydrides modified by the lambda-convention are discussed… in
for elements of Group 17”.
A chlorine or bromine of bonding number 3, 5 or 7 is drawn charge-separated by RDKit (
Cl(=O)(=O)=Ois[Cl+3]([O-])([O-])[O-]), a 1,2-dipolar drawing “1,2-Dipolar compounds”,:42497) of the same oxo groups; each of theqterminal[O-]of a+qhalogen is read as theoxoof the uncharged drawing, whose name is the lambda-convention one of, and the halogen and those oxygens are the charges the name accounts for.
Off by default (_Ctx.halane_forms): universal_substituent.name_universal_substitutive asks for it
only after every other floor spelling has declined, so the floor’s own names are not changed; it is a
last rung of the floor, which comes before the fallbacks after it (the neutral-form naming of a
charge-separated chalcogenide, and the producers the namer tries when the floor gives nothing), so a
molecule one of those named can now get the halane name instead. A shape this module does not name (a
halogen in a ring, a stereogenic halogen, a halogen with a charge it cannot account for, a halogen with
a bond other than single, double or triple – a dative bond – or an attachment that is not a single or
double bond) returns None and the floor voids as it always did.
- orthonym.assembly.universal_halane.HALANE_STEM: Dict[str, str] = {'Br': 'bromane', 'Cl': 'chlorane', 'I': 'iodane'}#
the parent hydride of each halogen that carries the lambda convention
- class orthonym.assembly.universal_halane.HalaneUnit(atom, stem, lam, ending='e', ionic=False, oxides=frozenset({}))#
Bases:
objectOne halogen atom the floor can name as a mononuclear parent hydride.
- atom: int#
- stem: str#
- lam: int | None#
- ending: str = 'e'#
- ionic: bool = False#
- oxides: FrozenSet[int] = frozenset({})#
- orthonym.assembly.universal_halane.has_halane_candidate(mol)#
True when mol has a Cl, Br or I that is not a plain monovalent halide: bonded to two or more heavy atoms, or charged (the cheap test ahead of
halane_unit).
- orthonym.assembly.universal_halane.names_the_input(mol)#
True unless a
namecall is running and mol is not the molecule it was asked to name: a nested frame names structures it derives from the input (the neutral skeleton of a cation, a capped fragment), and the outer name is built from theirs, so their provenance is the outer name’s. The molecule is the same when its molecular formula (atoms, hydrogens and charge) is: a drawing the namer normalised keeps it, a skeleton with another hydron or a part of the molecule does not.
- orthonym.assembly.universal_halane.halane_unit(mol, idx)#
The:class:HalaneUnit of atom idx, or
Nonewhen the floor cannot name it as one.a neutral halogen of non-standard bonding number (3, 5, 7:
nonstandard_bonding_number, the lambda home):-lambda3-iodane;a
+qhalogen with exactlyqterminal[O-]neighbours, the charge-separated drawing of a halogen oxide: bonding numbervalence + qof the uncharged drawing, the oxides citedoxo;a
+1halogen of bonding number 2,-ium“General rule for systematically naming cationic centers in parent hydrides”, the Blue Book: “replacing the final letter ‘e’ of the parent hydride name, if any, by the suffix ‘ium’”; ‘diphenyliodanium (PIN)’,:41362), and a-1one, the anion of “ANIONS FORMED BY ADDITION OF HYDRIDE IONS” (:41089) in its method (2) spelling,-lambda3-iodanide(“(2) by adding the suffix ‘ide’ to a parent hydride in which the bonding number at the anionic site is higher than the standard bonding number and is expressed by the lambda-convention”,:41094; ‘diphenyliodanuide (PIN) diphenyl-lambda3-iodanide’,:41110). OPSIN 2.9.0 has no grammar for the substituted method (1) ‘-uide’ token (validation.uide_twin); the method (2) spelling reads, so the floor’s own round trip verifies it. The number is the one the twin of the default tier cites (rules.ions._UIDE_STD_VALENCE+ 2).
Nonefor a halogen in a ring, with an isotope, a radical or a chiral tag (the descriptor of a stereogenic hypervalent atom is not cited), with a bond that is not single, double or triple (a dative bond counts in the bonding number ofGetTotalValencebut is no valence bond of the lambda name:N->I(C)Cwould be named with one hydrogen fewer than the input), or with a charge none of these accounts for. A stereo double bond at the halogen is not declined: no descriptor is cited for it, and the name ships only if its read-back reaches the input’s full InChIKey, which decides whether the key sees that bond.
- orthonym.assembly.universal_halane.halane_parent(ctx, component)#
The halogen that is the parent of the whole molecule: an ionic centre first (its charge suffix names it on a parent only), then the senior halogen
F > Cl > Br > Iclass 39), then the canonical rank (numbering-invariant, never the atom index). A hypervalent halogen is the parent whatever else the molecule holds: classes 1-38, which rank above class 39, are not applied here (see the module docstring).
- orthonym.assembly.universal_halane.name_halane_component(ctx, component, attach_hint, is_top, emit_branch_stereo=False, relative_ring_override=None)#
A
_ComponentResultthat names component on its halogen, orNone.is_top: the halogen is the parent hydride of the whole molecule,<prefixes>-lambda3-iodane(halane_parent). Otherwise the component is a branch attached through its halogen (attach_hint) and the result is the substituent prefix<prefixes>-lambda3-iodanyl, bound to the order of its attachment bond. The prefixes are the neighbours, each named by the floor’s own recursion on its piece (its stereo block and charges carried as in the branch loop of_name_component), without locants and in the order.