Skip to content

Commit

Permalink
Ensure that we set the diagonal values of the Burden matrix correctly…
Browse files Browse the repository at this point in the history
…. Fixes bug 3347528

Signed-off-by: Egon Willighagen <egonw@users.sourceforge.net>
  • Loading branch information
rajarshi authored and egonw committed Jul 1, 2011
1 parent 20f3639 commit b008a4b
Showing 1 changed file with 3 additions and 4 deletions.
Expand Up @@ -23,6 +23,8 @@
*/
package org.openscience.cdk.qsar.descriptors.molecular;

import Jama.EigenvalueDecomposition;
import Jama.Matrix;
import org.openscience.cdk.CDKConstants;
import org.openscience.cdk.annotations.TestClass;
import org.openscience.cdk.annotations.TestMethod;
Expand All @@ -48,9 +50,6 @@
import org.openscience.cdk.tools.LonePairElectronChecker;
import org.openscience.cdk.tools.manipulator.AtomContainerManipulator;

import Jama.EigenvalueDecomposition;
import Jama.Matrix;

/**
* Eigenvalue based descriptor noted for its utility in chemical diversity.
* Described by Pearlman et al. {@cdk.cite PEA99}.
Expand Down Expand Up @@ -391,7 +390,7 @@ public DescriptorValue calculate(IAtomContainer container) {
counter = 0;
for (int i = 0; i < molecule.getAtomCount(); i++) {
if (molecule.getAtom(i).getSymbol().equals("H")) continue;
diagvalue[counter] = 1.0; molecule.getAtom(i).getCharge();
diagvalue[counter] = molecule.getAtom(i).getCharge();
counter++;
}
burdenMatrix = BurdenMatrix.evalMatrix(molecule, diagvalue);
Expand Down

0 comments on commit b008a4b

Please sign in to comment.