Menu

#921 bond type 8 in SDF gives unexpected answers

2.3.x
open
nobody
sdf (1)
6
2014-04-17
2014-04-17
Craig
No

Bond type 8 ("any bond") is illegal in an SDF, but is accepted by OpenBabel. Internally it keeps the bond type as 8. The attached SDF is for [Rh]~C. If you call BOSum() on the carbon atom, it tells you 8, which leads to crazy valence assumptions.

I'm not sure what the right answer is. Strictly speaking the SDF is illegal and should be rejected. On the other hand, it's nice to be able to read and write these without losing the "any bond" designation. But if the internal representation shows the bond order as 8, then every application and every format has to be prepared to deal with this nonsensical case. A better approach might be to save "bond type 8" as a property on the bond that only mdlformat.cpp has to know about.

1 Attachments

Discussion