[gmx-users] make_ndx treats "&" and "AND" differently -- expected?

Christopher Neale chris.neale at alum.utoronto.ca
Sat May 21 00:02:14 CEST 2016


Dear Users:

In an attempt to get around the '&' issue in index group names, I have tried using the 'AND' keyword, which is noted in the gmx make_ndx -h output. Indeed, the word "AND" replaces the ampersand in the index group in this case. However, the selection seems broken to me. Details are below. Specifically, with the '&' between selection of one atom name and one residue number, I get one atom in the group, as expected. However, when I use the 'AND' keyword, "r" seems to get promoted to "R" and then (for this or other reasons) the selection of one particular residue is not honored.

NOTE: same behaviour if using "AND" or "and"

Can anyone confirm whether this behaviour is indeed unexpected or whether I misinderstand the usage of "AND" ? I tried to look for info on make_ndx in the manual and the online documentation but there is no definition of what "AND" does, so I am presuming that it is intended to be the common interpretation.

$ echo -e "aC316 AND r1 \n aC316 & r1 \n q \n" | gmx make_ndx -f start.gro -o rdf.ndx
                 :-) GROMACS - gmx make_ndx, VERSION 5.1.2 (-:

                            GROMACS is written by:
     Emile Apol      Rossen Apostolov  Herman J.C. Berendsen    Par Bjelkmar   
 Aldert van Buuren   Rudi van Drunen     Anton Feenstra   Sebastian Fritsch 
  Gerrit Groenhof   Christoph Junghans   Anca Hamuraru    Vincent Hindriksen
 Dimitrios Karkoulis    Peter Kasson        Jiri Kraus      Carsten Kutzner  
    Per Larsson      Justin A. Lemkul   Magnus Lundborg   Pieter Meulenhoff 
   Erik Marklund      Teemu Murtola       Szilard Pall       Sander Pronk   
   Roland Schulz     Alexey Shvetsov     Michael Shirts     Alfons Sijbers  
   Peter Tieleman    Teemu Virolainen  Christian Wennberg    Maarten Wolf   
                           and the project leaders:
        Mark Abraham, Berk Hess, Erik Lindahl, and David van der Spoel

Copyright (c) 1991-2000, University of Groningen, The Netherlands.
Copyright (c) 2001-2015, The GROMACS development team at
Uppsala University, Stockholm University and
the Royal Institute of Technology, Sweden.
check out http://www.gromacs.org for more information.

GROMACS is free software; you can redistribute it and/or modify it
under the terms of the GNU Lesser General Public License
as published by the Free Software Foundation; either version 2.1
of the License, or (at your option) any later version.

GROMACS:      gmx make_ndx, VERSION 5.1.2
Executable:   /home/cneale/exec/GROMACS/exec/gromacs-5.1.2/serial/bin/gmx
Data prefix:  /home/cneale/exec/GROMACS/exec/gromacs-5.1.2/serial
Command line:
  gmx make_ndx -f start.gro -o rdf.ndx


Reading structure file
Going to read 0 old index file(s)
Analysing residue names:
There are:   128      Other residues
There are:  6396      Water residues
There are:    34        Ion residues
Analysing residues not classified as Protein/DNA/RNA/Water and splitting into groups...
Analysing residues not classified as Protein/DNA/RNA/Water and splitting into groups...

  0 System              : 35862 atoms
  1 Other               : 16640 atoms
  2 DPPC                : 16640 atoms
  3 K                   :    17 atoms
  4 CL                  :    17 atoms
  5 Water               : 19188 atoms
  6 SOL                 : 19188 atoms
  7 non-Water           : 16674 atoms
  8 Ion                 :    34 atoms
  9 DPPC                : 16640 atoms
 10 K                   :    17 atoms
 11 CL                  :    17 atoms
 12 Water_and_ions      : 19222 atoms

 nr : group       !   'name' nr name   'splitch' nr    Enter: list groups
 'a': atom        &   'del' nr         'splitres' nr   'l': list residues
 't': atom type   |   'keep' nr        'splitat' nr    'h': help
 'r': residue         'res' nr         'chain' char
 "name": group        'case': case sensitive           'q': save and quit
 'ri': residue index

> 
Found 128 atoms with names C316 AND R1

 13 C316_AND_R1         :   128 atoms

> 
Found 128 atoms with name C316
Merged two groups with AND: 128 130 -> 1

 14 C316_&_r_1          :     1 atoms

> 

Thank you,
Chris.



More information about the gromacs.org_gmx-users mailing list