public class SmilesAromatic
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
private static int[][] |
OS_PI_COUNTS
Index to inner array is covalent bond count (b) + valence (v) + charge (c,
carbon only) - 4.
|
| Constructor and Description |
|---|
SmilesAromatic() |
| Modifier and Type | Method and Description |
|---|---|
private static boolean |
addNormal(javajs.util.V3 vTemp,
javajs.util.V3 vMean,
float maxDev)
adds a normal if similarity is within limits
|
(package private) static void |
checkAromaticDefined(Node[] jmolAtoms,
javajs.util.BS bsSelected,
javajs.util.BS bsAromatic)
Set aromatic atoms based on predefined BOND_AROMATIC definitions.
|
private static void |
checkBridges(javajs.util.Lst<?> lst,
javajs.util.BS bsBad,
javajs.util.Lst<?> lst2,
javajs.util.BS bsBad2,
javajs.util.BS bs) |
private static void |
checkFusedRings(javajs.util.Lst<SmilesRing> rings,
int[] eCounts,
javajs.util.Lst<javajs.util.BS> lstAromatic)
Add fused rings based on the Hueckel 4n+2 rule.
|
private static int |
checkHueckelAromatic(int nAtoms,
Node[] jmolAtoms,
javajs.util.BS bsAromatic,
javajs.util.BS bsRing,
int strictness,
int[] eCounts)
For each atom in the ring, look up a unique combination of covalent bond
count, valence, and charge for each atom and use that as a key into the
PI_COUNTS array.
|
private static boolean |
checkStandardDeviation(javajs.util.V3[] vNorms,
javajs.util.V3 vMean,
int n,
float cutoff)
calculates a dot-product standard deviation and reports if it is below a
cutoff
|
(package private) static void |
finalizeAromatic(Node[] jmolAtoms,
javajs.util.BS bsAromatic,
javajs.util.Lst<javajs.util.BS> lstAromatic,
javajs.util.Lst<SmilesRing> lstSP2,
int[] eCounts,
boolean isOpenNotStrict,
boolean isStrict)
Iteratively trims a set of aromatic atoms that may be initially assigned to
be aromatic but because their double bonds extend to non-aromatic atoms
must be removed.
|
private static boolean |
isSp2Ring(int n,
Node[] atoms,
javajs.util.BS bsSelected,
javajs.util.BS bs,
float cutoff,
boolean checkExplicit,
boolean allowSOxide)
3D-SEARCH aromaticity test.
|
private static void |
removeBridgingRings(javajs.util.Lst<javajs.util.BS> lstAromatic,
javajs.util.Lst<SmilesRing> lstSP2)
check for any two rings with more than two common atoms and remove them
from the pool
|
(package private) static void |
setAromatic(int n,
Node[] jmolAtoms,
javajs.util.BS bsSelected,
javajs.util.Lst<java.lang.Object> vR,
javajs.util.BS bsAromatic,
int strictness,
boolean isOpenSMILES,
boolean justCheckBonding,
boolean checkExplicit,
VTemp v,
javajs.util.Lst<javajs.util.BS> vOK,
javajs.util.Lst<SmilesRing> lstSP2,
int[] eCounts,
boolean doTestAromatic)
Main entry point.
|
private static final int[][] OS_PI_COUNTS
static void setAromatic(int n,
Node[] jmolAtoms,
javajs.util.BS bsSelected,
javajs.util.Lst<java.lang.Object> vR,
javajs.util.BS bsAromatic,
int strictness,
boolean isOpenSMILES,
boolean justCheckBonding,
boolean checkExplicit,
VTemp v,
javajs.util.Lst<javajs.util.BS> vOK,
javajs.util.Lst<SmilesRing> lstSP2,
int[] eCounts,
boolean doTestAromatic)
n - jmolAtoms - bsSelected - vR - bsAromatic - strictness - isOpenSMILES - justCheckBonding - checkExplicit - v - vOK - lstSP2 - eCounts - doTestAromatic - static void checkAromaticDefined(Node[] jmolAtoms, javajs.util.BS bsSelected, javajs.util.BS bsAromatic)
jmolAtoms - bsSelected - bsAromatic - private static final boolean isSp2Ring(int n,
Node[] atoms,
javajs.util.BS bsSelected,
javajs.util.BS bs,
float cutoff,
boolean checkExplicit,
boolean allowSOxide)
n - atoms - a set of atoms with coordinate positions and associated bonds.bs - a bitset of atoms within the set of atoms, defining the ringbsSelected - must not be nullcutoff - an arbitrary value to test the standard deviation against. 0.01 is
appropriate here. Use Float.MAX_VALUE to just do bond connectivity
checkcheckExplicit - check bonds that are explicit only - for XYZ and QM calcsallowSOxide - set TRUE to skip S atomsprivate static final boolean addNormal(javajs.util.V3 vTemp,
javajs.util.V3 vMean,
float maxDev)
vTemp - vMean - maxDev - private static final boolean checkStandardDeviation(javajs.util.V3[] vNorms,
javajs.util.V3 vMean,
int n,
float cutoff)
vNorms - vMean - n - cutoff - private static int checkHueckelAromatic(int nAtoms,
Node[] jmolAtoms,
javajs.util.BS bsAromatic,
javajs.util.BS bsRing,
int strictness,
int[] eCounts)
nAtoms - this ring's sizejmolAtoms - could also be constructed nodes from a SMILES stringbsAromatic - at least nominally aromatic atomsbsRing - specific atoms of this ringstrictness - 0 (not) 1 (OpenSMILES), 2 (MMFF94) standard organic chemist's
Hueckel interpretation, not allowing c=OeCounts - static void finalizeAromatic(Node[] jmolAtoms, javajs.util.BS bsAromatic, javajs.util.Lst<javajs.util.BS> lstAromatic, javajs.util.Lst<SmilesRing> lstSP2, int[] eCounts, boolean isOpenNotStrict, boolean isStrict)
jmolAtoms - bsAromatic - lstAromatic - all rings passing the sp2 test and (if strict) the Hueckel strict testlstSP2 - all rings passing the sp2 testeCounts - isOpenNotStrict - /open/ optionisStrict - remove noncyclic double bonds and do not allow bridging aromatic
ring systems (/strict/ option)private static void removeBridgingRings(javajs.util.Lst<javajs.util.BS> lstAromatic,
javajs.util.Lst<SmilesRing> lstSP2)
lstAromatic - lstSP2 - private static void checkBridges(javajs.util.Lst<?> lst,
javajs.util.BS bsBad,
javajs.util.Lst<?> lst2,
javajs.util.BS bsBad2,
javajs.util.BS bs)
private static void checkFusedRings(javajs.util.Lst<SmilesRing> rings, int[] eCounts, javajs.util.Lst<javajs.util.BS> lstAromatic)
rings - eCounts - lstAromatic - list to be appended to