code: @Override
      public DescriptorValue calculate(IAtomContainer atomContainer) {
          IAtomContainer ac = null;
          try {
              ac = (IAtomContainer) atomContainer.clone();
          } catch (CloneNotSupportedException e) {
              return getDummyDescriptorValue(e);
          }
  
          int carbonCount = 0;
          int heteroCount = 0;
          for (IAtom atom : ac.atoms()) {
              if (!Elements.HYDROGEN.getSymbol().equals(atom.getSymbol())) {
                  if (Elements.CARBON.getSymbol().equals(atom.getSymbol())) {
                      carbonCount++;
                  } else {
                      heteroCount++;
                  }
              }
          }
          double mLogP = 1.46 + 0.11 * carbonCount - 0.11 * heteroCount;
  
          return new DescriptorValue(getSpecification(), getParameterNames(), getParameters(), new DoubleResult(mLogP),
                  getDescriptorNames());
      }
docs: Calculates the Mannhold LogP for an atom container.
  
  @param  atomContainer      {@link IAtomContainer} to calculate the
  descriptor value for.
  @return A descriptor value wrapping a {@link DoubleResult}.