Count single, double and tripple bonds in a molecule?

User 2225b9a678

03-05-2013 18:18:08

Is there a way using cxcalc or evaluate (or something else) to separately count the number of single, double, and triple bonds in a molecule?


i was trying to use evaluate's count(filter(...))   but could not figure out how to just filter by one kind of bond. 


I am aware of the stereoDoubleBondCount, but that does not count all double bonds so not quite what i am looking for.


Any help would be much appreciated

ChemAxon e08c317633

06-05-2013 08:22:12

The matchCount() Chemical Terms function can be used to count single, double, and triple bonds.


Example:


$ evaluate -e "matchCount('*-*')" "CC\C=C\C=C\C#CCC"
6

$ evaluate -e "matchCount('*=*')" "CC\C=C\C=C\C#CCC"
2

$ evaluate -e "matchCount('*#*')" "CC\C=C\C=C\C#CCC"
1

User 2225b9a678

06-05-2013 19:01:37

Thanks for the reply, however this does not seem to take into account aromatic rings


ie:


evaluate -e "matchCount('*-*')" "CC1N(CC2N(CCC3=CC=CC=C23)C1=O)C(=O)CC#C"
14


evaluate -e "matchCount('*=*')" "CC1N(CC2N(CCC3=CC=CC=C23)C1=O)C(=O)CC#C"
2


evaluate -e "matchCount('*#*')" "CC1N(CC2N(CCC3=CC=CC=C23)C1=O)C(=O)CC#C"
1


is not taking into account the 3 single/3 double bonds from the aromatic ring


Any way to include those?

ChemAxon e08c317633

07-05-2013 06:56:47










kask382 wrote:

... is not taking into account the 3 single/3 double bonds from the aromatic ring


Any way to include those?



The 3 single and 3 double bonds in the aromatic ring are considered as aromatic bonds. We think this is the correct approach.


Aromatic bonds can be counted as well:


$ evaluate -e "matchCount('[*,#1]:[*,#1]')" "CC1N(CC2N(CCC3=CC=CC=C23)C1=O)C(=O)CC#C"
6