[gmx-users] dynamic selection memory allocation problem

gigo gigo at ibb.waw.pl
Mon Jun 30 22:03:43 CEST 2014

Dear Teemu,
Thank you very much for the reply and such a fast patching of the 
sources. I have another question. Are there any plans for importing the 
dynamic selection scheme into the "angle" command?


On 2014-06-29 06:58, Teemu Murtola wrote:
> There were some hardcoded string buffers left from C days that were
> necessary for error handling that placed a somewhat arbitrary 
> limitation of
> 1024 characters per a single selection.
> For the matter of what you are trying to achieve, you can probably do 
> that
> with gmx distance (with or without the fix for the limitation from 
> Gerrit),
> but that tool may not be that well suited for the task. On purpose, I 
> did
> not add functionality to do 1-to-many or many-to-many distances there,
> since that would better fit into another tool (which I or anyone else 
> has
> not had time to write yet), but it seems that this is the functionality 
> you
> desire.
> I would probably write a custom tool (based on the installed
> share/gromacs/template) that would actually calculate the properties 
> you
> want, based on a selection that provides the ligand atoms of interest 
> and
> the water molecules you want, but I understand that not everyone is 
> fluent
> in C/C++.
> If your system is big, you can probably also make your selection
> substantially more effective by using multiple selections (it does not
> appear that you actually need the plus keyword if you are only 
> interested
> in the -oall output) and a variable for the part after "or" that is 
> always
> evaluated for ~all atoms:
>   ligand_p = resname LIG and name P;
>   resid 14497 and resname SOL and name LP1 or ligand_p;
>   resid 14497 and resname SOL and name LP1 or ligand_p;
>   resid 14497 and resname SOL and name LP1 or ligand_p;
>   ...
> It also sounds that your script probably already has knowledge of the 
> atom
> indices, so it could generate the selection to use those directly.

More information about the gromacs.org_gmx-users mailing list