Dear all,
I would like to write a SMARTS chain that matches any compound with a
decalin ring system,
whatever bond multiplicity.
I wrote it as 'C1~C~C2~C~C~C~C~C2~C~C1' with ~ standing for "any bond".
The C1-C1 and C2-C2 bonds have the "default type", which is single or
aromatic.
The code
m1
I think this will do it
pattern = Chem.MolFromSmarts('C1~C~C2~C~C~C~C~C~2~C~C~1')
you need to ring closure bonds to be set to any as well
hope that helps
Rich
From: Jean-Marc Nuzillard
Sent: 17 January 2020 09:54
To: RDKit Discuss
Subject: [EXTERNAL] [Rdkit-discuss] SMARTS and ring closure
D
Dear Jean-Marc,
adding '~' between C and ring number seems to work:
'm1 = Chem.MolFromSmiles('C1(=C12)2')
m2 = Chem.MolFromSmiles('C1CCC=C(C12)2')
pattern = Chem.MolFromSmarts('C~1~C~C~2~C~C~C~C~C~2~C~C~1')
print(m1.HasSubstructMatch(pattern))
print(m2.HasSubstructMatch(pattern))
retu
The latest cartridge containers for
informaticsmatters/rdkit-cartridge-debian are based on PostgreSQL
version 11.
This can/will change with different RDKit major version builds as the
base Debian packages change and I have little control over this.
I'd like to do this better but building all c
4 matches
Mail list logo