test_class.declarator: builder = SilentChemObjectBuilder.getInstance()
test_class.modifier: private
test_class.original_string: private IChemObjectBuilder      builder = SilentChemObjectBuilder.getInstance();
test_class.type: IChemObjectBuilder
test_class.var_name: builder
test_class.declarator: lpcheck = new LonePairElectronChecker()
test_class.modifier: private
test_class.original_string: private LonePairElectronChecker lpcheck = new LonePairElectronChecker();
test_class.type: LonePairElectronChecker
test_class.var_name: lpcheck
test_class.file: tool/charges/src/test/java/org/openscience/cdk/charges/GasteigerMarsiliPartialChargesTest.java
test_class.identifier: GasteigerMarsiliPartialChargesTest
test_class.superclass: extends CDKTestCase
test_case.body: @Test
      public void testAssignGasteigerSigmaMarsiliFactors_IAtomContainer() throws Exception {
          GasteigerMarsiliPartialCharges peoe = new GasteigerMarsiliPartialCharges();
  
          IAtomContainer molecule = builder.newInstance(IAtomContainer.class);
          molecule.addAtom(new Atom("C"));
          molecule.getAtom(0).setCharge(0.0);
          molecule.addAtom(new Atom("F"));
          molecule.getAtom(1).setCharge(0.0);
          molecule.addBond(0, 1, IBond.Order.SINGLE);
  
          addExplicitHydrogens(molecule);
          AtomContainerManipulator.percieveAtomTypesAndConfigureAtoms(molecule);
          lpcheck.saturate(molecule);
          for (IAtom atom : molecule.atoms())
              atom.setCharge(0.0);
  
          org.hamcrest.MatcherAssert.assertThat(peoe.assignGasteigerSigmaMarsiliFactors(molecule).length,
                            is(not(0)));
  
      }
test_case.class_method_signature: GasteigerMarsiliPartialChargesTest.testAssignGasteigerSigmaMarsiliFactors_IAtomContainer()
test_case.full_signature: @Test public void testAssignGasteigerSigmaMarsiliFactors_IAtomContainer()
test_case.identifier: testAssignGasteigerSigmaMarsiliFactors_IAtomContainer
test_case.invocations: newInstance addAtom setCharge getAtom addAtom setCharge getAtom addBond addExplicitHydrogens percieveAtomTypesAndConfigureAtoms saturate atoms setCharge assertThat assignGasteigerSigmaMarsiliFactors is not
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testAssignGasteigerSigmaMarsiliFactors_IAtomContainer()
focal_class.declarator: DEOC_HYDROGEN = 20.02
focal_class.modifier: private
focal_class.original_string: private double DEOC_HYDROGEN = 20.02;
focal_class.type: double
focal_class.var_name: DEOC_HYDROGEN
focal_class.declarator: MX_DAMP       = 0.5
focal_class.modifier: private
focal_class.original_string: private double MX_DAMP       = 0.5;
focal_class.type: double
focal_class.var_name: MX_DAMP
focal_class.declarator: MX_ITERATIONS = 20
focal_class.modifier: private
focal_class.original_string: private double MX_ITERATIONS = 20;
focal_class.type: double
focal_class.var_name: MX_ITERATIONS
focal_class.declarator: STEP_SIZE     = 5
focal_class.modifier: private
focal_class.original_string: private int    STEP_SIZE     = 5;
focal_class.type: int
focal_class.var_name: STEP_SIZE
focal_class.file: tool/charges/src/main/java/org/openscience/cdk/charges/GasteigerMarsiliPartialCharges.java
focal_class.identifier: GasteigerMarsiliPartialCharges
focal_class.interfaces: implements IChargeCalculator
focal_class.class_method_signature: GasteigerMarsiliPartialCharges.GasteigerMarsiliPartialCharges()
focal_class.full_signature: public  GasteigerMarsiliPartialCharges()
focal_class.identifier: GasteigerMarsiliPartialCharges
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.signature:  GasteigerMarsiliPartialCharges()
focal_class.class_method_signature: GasteigerMarsiliPartialCharges.setChiCatHydrogen(double chiCat)
focal_class.full_signature: public void setChiCatHydrogen(double chiCat)
focal_class.identifier: setChiCatHydrogen
focal_class.modifiers: public
focal_class.parameters: (double chiCat)
focal_class.return: void
focal_class.signature: void setChiCatHydrogen(double chiCat)
focal_class.class_method_signature: GasteigerMarsiliPartialCharges.setMaxGasteigerDamp(double damp)
focal_class.full_signature: public void setMaxGasteigerDamp(double damp)
focal_class.identifier: setMaxGasteigerDamp
focal_class.modifiers: public
focal_class.parameters: (double damp)
focal_class.return: void
focal_class.signature: void setMaxGasteigerDamp(double damp)
focal_class.class_method_signature: GasteigerMarsiliPartialCharges.setMaxGasteigerIters(double iters)
focal_class.full_signature: public void setMaxGasteigerIters(double iters)
focal_class.identifier: setMaxGasteigerIters
focal_class.modifiers: public
focal_class.parameters: (double iters)
focal_class.return: void
focal_class.signature: void setMaxGasteigerIters(double iters)
focal_class.class_method_signature: GasteigerMarsiliPartialCharges.getChiCatHydrogen()
focal_class.full_signature: public double getChiCatHydrogen()
focal_class.identifier: getChiCatHydrogen
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: double
focal_class.signature: double getChiCatHydrogen()
focal_class.class_method_signature: GasteigerMarsiliPartialCharges.getMaxGasteigerDamp()
focal_class.full_signature: public double getMaxGasteigerDamp()
focal_class.identifier: getMaxGasteigerDamp
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: double
focal_class.signature: double getMaxGasteigerDamp()
focal_class.class_method_signature: GasteigerMarsiliPartialCharges.getMaxGasteigerIters()
focal_class.full_signature: public double getMaxGasteigerIters()
focal_class.identifier: getMaxGasteigerIters
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: double
focal_class.signature: double getMaxGasteigerIters()
focal_class.class_method_signature: GasteigerMarsiliPartialCharges.assignGasteigerMarsiliSigmaPartialCharges(IAtomContainer ac, boolean setCharge)
focal_class.full_signature: public IAtomContainer assignGasteigerMarsiliSigmaPartialCharges(IAtomContainer ac, boolean setCharge)
focal_class.identifier: assignGasteigerMarsiliSigmaPartialCharges
focal_class.modifiers: public
focal_class.parameters: (IAtomContainer ac, boolean setCharge)
focal_class.return: IAtomContainer
focal_class.signature: IAtomContainer assignGasteigerMarsiliSigmaPartialCharges(IAtomContainer ac, boolean setCharge)
focal_class.class_method_signature: GasteigerMarsiliPartialCharges.calculateCharges(IAtomContainer container)
focal_class.full_signature: @Override public void calculateCharges(IAtomContainer container)
focal_class.identifier: calculateCharges
focal_class.modifiers: @Override public
focal_class.parameters: (IAtomContainer container)
focal_class.return: void
focal_class.signature: void calculateCharges(IAtomContainer container)
focal_class.class_method_signature: GasteigerMarsiliPartialCharges.getStepSize()
focal_class.full_signature: public int getStepSize()
focal_class.identifier: getStepSize
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: int
focal_class.signature: int getStepSize()
focal_class.class_method_signature: GasteigerMarsiliPartialCharges.setStepSize(int step)
focal_class.full_signature: public void setStepSize(int step)
focal_class.identifier: setStepSize
focal_class.modifiers: public
focal_class.parameters: (int step)
focal_class.return: void
focal_class.signature: void setStepSize(int step)
focal_class.class_method_signature: GasteigerMarsiliPartialCharges.assignGasteigerSigmaMarsiliFactors(IAtomContainer ac)
focal_class.full_signature: public double[] assignGasteigerSigmaMarsiliFactors(IAtomContainer ac)
focal_class.identifier: assignGasteigerSigmaMarsiliFactors
focal_class.modifiers: public
focal_class.parameters: (IAtomContainer ac)
focal_class.return: double[]
focal_class.signature: double[] assignGasteigerSigmaMarsiliFactors(IAtomContainer ac)
focal_method.body: public double[] assignGasteigerSigmaMarsiliFactors(IAtomContainer ac) throws CDKException {
          //a,b,c,denom,chi,q
          double[] gasteigerFactors = new double[(ac.getAtomCount() * (STEP_SIZE + 1))];
          double[] factors = new double[]{0.0, 0.0, 0.0};
          for (int i = 0; i < ac.getAtomCount(); i++) {
              factors[0] = 0.0;
              factors[1] = 0.0;
              factors[2] = 0.0;
              final IAtom       atom         = ac.getAtom(i);
              final String      symbol       = atom.getSymbol();
              final IBond.Order maxBondOrder = ac.getMaximumBondOrder(atom);
              final Integer     charge       = atom.getFormalCharge();
              switch (symbol) {
                  case "H":
                      factors[0] = 7.17;
                      factors[1] = 6.24;
                      factors[2] = -0.56;
                      break;
                  case "C":
                      if (maxBondOrder == IBond.Order.DOUBLE ||
                          (maxBondOrder == IBond.Order.SINGLE && (charge == -1 || charge == +1))) {
                          factors[0] = 8.79;/* 8.79 *//* 8.81 */
                          factors[1] = 9.32;/* 9.32 *//* 9.34 */
                          factors[2] = 1.51;/* 1.51 *//* 1.52 */
                      } else if (maxBondOrder == IBond.Order.SINGLE && charge == 0) {
                          factors[0] = 7.98;
                          factors[1] = 9.18;
                          factors[2] = 1.88;
                      } else if (maxBondOrder == IBond.Order.TRIPLE
                                 || maxBondOrder == IBond.Order.QUADRUPLE) {
                          factors[0] = 10.39;/* 10.39 */
                          factors[1] = 9.45;/* 9.45 */
                          factors[2] = 0.73;
                      }
                      break;
                  case "N":
                      if ((maxBondOrder == IBond.Order.SINGLE)
                          && (charge != -1)) {
                          factors[0] = 11.54;
                          factors[1] = 10.82;
                          factors[2] = 1.36;
                      } else if ((maxBondOrder == IBond.Order.DOUBLE)
                                 || ((maxBondOrder == IBond.Order.SINGLE))) {
                          factors[0] = 12.87;
                          factors[1] = 11.15;
                          factors[2] = 0.85;
                      } else if (maxBondOrder == IBond.Order.TRIPLE
                                 || maxBondOrder == IBond.Order.QUADRUPLE) {
                          factors[0] = 17.68;/* 15.68 */
                          factors[1] = 12.70;/* 11.70 */
                          factors[2] = -0.27;/*-0.27*/
                      }
                      break;
                  case "O":
                      if ((maxBondOrder == IBond.Order.SINGLE)
                          && (charge != -1)) {
                          factors[0] = 14.18;
                          factors[1] = 12.92;
                          factors[2] = 1.39;
                      } else if ((maxBondOrder == IBond.Order.DOUBLE)
                                 || ((maxBondOrder == IBond.Order.SINGLE))) {
                          factors[0] = 17.07;/*
                                              * paramaters aren'T correct
                                              * parametrized.
                                              */
                          factors[1] = 13.79;
                          factors[2] = 0.47;/* 0.47 */
                      }
                      break;
                  case "Si": // <--not correct
                      factors[0] = 8.10;// <--not correct
  
                      factors[1] = 7.92;// <--not correct
  
                      factors[2] = 1.78;// <--not correct
  
                      break;
                  case "P":
                      factors[0] = 8.90;
                      factors[1] = 8.32;
                      factors[2] = 1.58;
                      break;
                  case "S":
  /*
                                                     * &&
                                                     * ac.getMaximumBondOrder(ac.getAtomAt
                                                     * (i)) == 1
                                                     */
  
                      factors[0] = 10.14;/* 10.14 */
                      factors[1] = 9.13;/* 9.13 */
                      factors[2] = 1.38;/* 1.38 */
                      break;
                  case "F":
                      factors[0] = 14.66;
                      factors[1] = 13.85;
                      factors[2] = 2.31;
                      break;
                  case "Cl":
                      factors[0] = 12.31;/* 11.0 *//* 12.31 */
                      factors[1] = 10.84;/* 9.69 *//* 10.84 */
                      factors[2] = 1.512;/* 1.35 *//* 1.512 */
                      break;
                  case "Br":
                      factors[0] = 11.44;/* 10.08 *//* 11.2 */
                      factors[1] = 9.63;/* 8.47 *//* 9.4 */
                      factors[2] = 1.31;/* 1.16 *//* 1.29 */
                      break;
                  case "I":
                      factors[0] = 9.88;/* 9.90 */
                      factors[1] = 7.95;/* 7.96 */
                      factors[2] = 0.945;/* 0.96 */
                      break;
                  default:
                      throw new CDKException("Partial charge not-supported for element: '" + symbol + "'.");
              }
  
  
              gasteigerFactors[STEP_SIZE * i + i] = factors[0];
              gasteigerFactors[STEP_SIZE * i + i + 1] = factors[1];
              gasteigerFactors[STEP_SIZE * i + i + 2] = factors[2];
              gasteigerFactors[STEP_SIZE * i + i + 5] = atom.getCharge();
              if (factors[0] == 0 && factors[1] == 0 && factors[2] == 0) {
                  gasteigerFactors[STEP_SIZE * i + i + 3] = 1;
              } else {
                  gasteigerFactors[STEP_SIZE * i + i + 3] = factors[0] + factors[1] + factors[2];
              }
          }
          return gasteigerFactors;
      }
focal_method.class_method_signature: GasteigerMarsiliPartialCharges.assignGasteigerSigmaMarsiliFactors(IAtomContainer ac)
focal_method.full_signature: public double[] assignGasteigerSigmaMarsiliFactors(IAtomContainer ac)
focal_method.identifier: assignGasteigerSigmaMarsiliFactors
focal_method.invocations: getAtomCount getAtomCount getAtom getSymbol getMaximumBondOrder getFormalCharge getCharge
focal_method.modifiers: public
focal_method.parameters: (IAtomContainer ac)
focal_method.return: double[]
focal_method.signature: double[] assignGasteigerSigmaMarsiliFactors(IAtomContainer ac)