> Hi Miguel!
>
> Very nice! I checked through the calculations and I added a slight fix
> (see below)
> void findSheets(char[] structureTags) {
> for (int a = 0; a < count; ++a)
> for (int b = 0; b < count; ++b) {
> if (
> (isHbonded(a+1, b) && isHbonded(b, a-1)) ||
> (isHbonded(b+1, a) && isHbonded(a, b-1))
> )
> {
> System.out.println("parallel found");
> structureTags[a] = structureTags[b] = 'p';
I removed this second test because it is redundant.
Since both a & b are running all the way up to 'count' then you don't need
to test this twice.
Put another way, if you leave both tests in then structureTags[x] will be
set to 'p' two times.
Miguel
-----
Open Source Molecular Visualization
www.jmol.org
[EMAIL PROTECTED]
-----
-------------------------------------------------------
This SF.Net email is sponsored by:
Sybase ASE Linux Express Edition - download now for FREE
LinuxWorld Reader's Choice Award Winner for best database on Linux.
http://ads.osdn.com/?ad_idU88&alloc_id065&op=click
_______________________________________________
Jmol-developers mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jmol-developers