Skip to content
Browse files

Ensure that we set the diagonal values of the Burden matrix correctly…

…. Fixes bug 3347528

Signed-off-by: Egon Willighagen <egonw@users.sourceforge.net>
  • Loading branch information...
1 parent 20f3639 commit b008a4b1e9987b7cdaffc8a3374db1358cc5ead2 @rajarshi rajarshi committed with egonw Jul 1, 2011
Showing with 3 additions and 4 deletions.
  1. +3 −4 src/main/org/openscience/cdk/qsar/descriptors/molecular/BCUTDescriptor.java
View
7 src/main/org/openscience/cdk/qsar/descriptors/molecular/BCUTDescriptor.java
@@ -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;
@@ -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}.
@@ -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);

0 comments on commit b008a4b

Please sign in to comment.
Something went wrong with that request. Please try again.