On 08/06/2012 04:02 PM, Geoff Hutchison wrote:
I am using OpenBabels C++ API to minimize ligands and I was wondering if there's a possibility to minimize hydrogens only?Not directly, but it's a nice idea. You could do this right now by freezing every heavy atom:OBForceField* pFF = OBForceField::FindForceField("MMFF94"); if (!pFF->Setup(mol)) { // error } FOR_ATOMS_OF_MOL(a, mol) { if (!a->IsHydrogen()) pFF->SetFixAtom(a->GetIdx()); // Fix the geometry of the heavy atom } // do what you want Hope that helps, -Geoff
Thanks again for quick help!I tried this but my non-hydrogen atoms have not been fixed during minimization ... Finally, I found a way to get it working by calling the pFF->Setup(OBMol&, OBFFConstraints&) method with previously defined constraints (AddAtomConstraint) on the non-hydrogen atoms.
-- Philipp Thiel Diplom-Inform. (Bioinformatics) Chemical Genomics Centre of the MPG Otto-Hahn-Straße 15 D-44227 Dortmund Tel: +49-231-1332729 Fax: +49-231-1332797 eMail: philipp.th...@cgc.mpg.de
<<attachment: philipp_thiel.vcf>>
------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________ OpenBabel-discuss mailing list OpenBabel-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openbabel-discuss