From: Christoph S. <c.s...@un...> - 2005-06-25 14:36:37
|
Uli Fechner wrote: > I totally like the idea of carrying around an already calculated ringse= t=20 > as a property of the respective AtomContainer. Of course, it is=20 > important to discriminate between AllRings and SSSR. I have two=20 > suggestions: >=20 > - single property ringset; then the client who is dealing with the=20 > ringset has to figure out which one is actually stored in the property=20 > (e.g. with instanceof) > - two different ringset properties (e.g. "ALLRINGS", "SSSRINGS") >=20 > I personally favour the second one. Me too. So let's wait until monday evening for others to respond. Then we can go=20 for the implementation. Cheers, Chris --=20 Priv. Doz. Dr. Christoph Steinbeck (c.s...@un...) Head of the Research Group for Molecular Informatics Cologne University BioInformatics Center (http://www.cubic.uni-koeln.de) Z=FClpicher Str. 47, 50674 Cologne Tel: +49(0)221-470-7426 Fax: +49 (0) 221-470-7786 What is man but that lofty spirit - that sense of enterprise. ... Kirk, "I, Mudd," stardate 4513.3.. Uli Fechner wrote: >>> I have an additional suggestion. In CDKConstants is the following >>> constant: >>> >>> /** Flag that is set when the chemobject is part of a ring. >>> */ >>> public final static int ISINRING =3D 1; >>> >>> If the ring finder algorithms (cdk.ringsearch.{AllRingsFinder, >>> FiguerasSSSRFinder, SSSRFinder) actually set this flag for an Atom o= r >>> Bond that is in a Ring the problem of identifying if an atom is part >>> of a ring w/o doing a ring search more than once would be solved. >> >> >> >> Most of the algorithms actually need to know which atom belongs to >> which ring, not just if it is in a ring. >> So we need the ringset with all the rings in it. >> We could introduce a property "Ringnumber", from which the ringset ca= n >> be quickly reconstructed. Another, even more efficient solution shoul= d >> be a property "ringset", to be set for an atomcontainer, which points >> to an already computed ringset. There, we also need to memorize, >> whether we are talking about a SetOfAllRings or an SSSR. >> This we are dealing with reference here, this should not be a memory >> problem. > > |