Gromacs  2024.4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Functions | Variables
#include "gmxpre.h"
#include <cctype>
#include "gromacs/selection/position.h"
#include "gromacs/topology/mtop_lookup.h"
#include "gromacs/topology/topology.h"
#include "gromacs/utility/arraysize.h"
#include "gromacs/utility/exceptions.h"
#include "gromacs/utility/gmxassert.h"
#include "selmethod.h"
#include "selmethod_impl.h"
+ Include dependency graph for sm_simple.cpp:

Description

Implements simple keyword selection methods.

Author
Teemu Murtola teemu.nosp@m..mur.nosp@m.tola@.nosp@m.gmai.nosp@m.l.com

Functions

static void evaluate_all (const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
 Evaluates the all selection keyword. More...
 
static void evaluate_none (const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
 Evaluates the none selection keyword. More...
 
static void evaluate_atomnr (const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
 Evaluates the atomnr selection keyword. More...
 
static void evaluate_resnr (const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
 Evaluates the resnr selection keyword. More...
 
static void evaluate_resindex (const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
 Evaluates the resindex selection keyword. More...
 
static void check_molecules (const gmx_mtop_t *top, int npar, gmx_ana_selparam_t *param, void *data)
 Checks whether molecule information is present in the topology. More...
 
static void evaluate_molindex (const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
 Evaluates the molindex selection keyword. More...
 
static void evaluate_atomname (const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
 Evaluates the atomname selection keyword. More...
 
static void evaluate_pdbatomname (const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
 Evaluates the pdbatomname selection keyword. More...
 
static void check_atomtype (const gmx_mtop_t *top, int npar, gmx_ana_selparam_t *param, void *data)
 Checks whether atom types are present in the topology. More...
 
static void evaluate_atomtype (const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
 Evaluates the atomtype selection keyword. More...
 
static void evaluate_insertcode (const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
 Evaluates the insertcode selection keyword. More...
 
static void evaluate_chain (const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
 Evaluates the chain selection keyword. More...
 
static void evaluate_mass (const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
 Evaluates the mass selection keyword. More...
 
static void check_charge (const gmx_mtop_t *top, int npar, gmx_ana_selparam_t *param, void *data)
 Checks whether charges are present in the topology. More...
 
static void evaluate_charge (const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
 Evaluates the charge selection keyword. More...
 
static void check_pdbinfo (const gmx_mtop_t *top, int npar, gmx_ana_selparam_t *param, void *data)
 Checks whether PDB info is present in the topology. More...
 
static void evaluate_altloc (const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
 Evaluates the altloc selection keyword. More...
 
static void evaluate_occupancy (const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
 Evaluates the occupancy selection keyword. More...
 
static void evaluate_betafactor (const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
 Evaluates the betafactor selection keyword. More...
 
static void evaluate_resname (const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
 Evaluates the resname selection keyword. More...
 
static void evaluate_x (const gmx::SelMethodEvalContext &context, gmx_ana_pos_t *pos, gmx_ana_selvalue_t *out, void *data)
 Evaluates the x selection keyword. More...
 
static void evaluate_y (const gmx::SelMethodEvalContext &context, gmx_ana_pos_t *pos, gmx_ana_selvalue_t *out, void *data)
 Evaluates the y selection keyword. More...
 
static void evaluate_z (const gmx::SelMethodEvalContext &context, gmx_ana_pos_t *pos, gmx_ana_selvalue_t *out, void *data)
 Evaluates the z selection keyword. More...
 
static void evaluate_coord (real out[], gmx_ana_pos_t *pos, int d)
 Internal utility function for position keyword evaluation. More...
 

Variables

static const char helptitle_atomname [] = "Selecting atoms by name"
 Help title for atom name selection keywords.
 
static const char *const help_atomname []
 Help text for atom name selection keywords. More...
 
static const char helptitle_resindex [] = "Selecting atoms by residue number"
 Help title for residue index selection keywords.
 
static const char *const help_resindex []
 Help text for residue index selection keywords. More...
 
gmx_ana_selmethod_t sm_all
 Selection method data for all selection keyword. More...
 
gmx_ana_selmethod_t sm_none
 Selection method data for none selection keyword. More...
 
gmx_ana_selmethod_t sm_atomnr
 Selection method data for atomnr selection keyword. More...
 
gmx_ana_selmethod_t sm_resnr
 Selection method data for resnr selection keyword. More...
 
gmx_ana_selmethod_t sm_resindex
 Selection method data for resindex selection keyword. More...
 
gmx_ana_selmethod_t sm_molindex
 Selection method data for molindex selection keyword. More...
 
gmx_ana_selmethod_t sm_atomname
 Selection method data for atomname selection keyword. More...
 
gmx_ana_selmethod_t sm_pdbatomname
 Selection method data for pdbatomname selection keyword. More...
 
gmx_ana_selmethod_t sm_atomtype
 Selection method data for atomtype selection keyword. More...
 
gmx_ana_selmethod_t sm_resname
 Selection method data for resname selection keyword. More...
 
gmx_ana_selmethod_t sm_insertcode
 Selection method data for chain selection keyword. More...
 
gmx_ana_selmethod_t sm_chain
 Selection method data for chain selection keyword. More...
 
gmx_ana_selmethod_t sm_mass
 Selection method data for mass selection keyword. More...
 
gmx_ana_selmethod_t sm_charge
 Selection method data for charge selection keyword. More...
 
gmx_ana_selmethod_t sm_altloc
 Selection method data for chain selection keyword. More...
 
gmx_ana_selmethod_t sm_occupancy
 Selection method data for occupancy selection keyword. More...
 
gmx_ana_selmethod_t sm_betafactor
 Selection method data for betafactor selection keyword. More...
 
gmx_ana_selmethod_t sm_x
 Selection method data for x selection keyword. More...
 
gmx_ana_selmethod_t sm_y
 Selection method data for y selection keyword. More...
 
gmx_ana_selmethod_t sm_z
 Selection method data for z selection keyword. More...
 

Function Documentation

static void check_atomtype ( const gmx_mtop_t *  top,
int  npar,
gmx_ana_selparam_t param,
void *  data 
)
static

Checks whether atom types are present in the topology.

Parameters
[in]topTopology structure.
nparNot used.
paramNot used.
dataNot used.
static void check_charge ( const gmx_mtop_t *  top,
int  npar,
gmx_ana_selparam_t param,
void *  data 
)
static

Checks whether charges are present in the topology.

Parameters
[in]topTopology structure.
nparNot used.
paramNot used.
dataNot used.
static void check_molecules ( const gmx_mtop_t *  top,
int  npar,
gmx_ana_selparam_t param,
void *  data 
)
static

Checks whether molecule information is present in the topology.

Parameters
[in]topTopology structure.
nparNot used.
paramNot used.
dataNot used.
Returns
0 if molecule info is present in the topology, -1 otherwise.

If molecule information is not found, also prints an error message.

static void check_pdbinfo ( const gmx_mtop_t *  top,
int  npar,
gmx_ana_selparam_t param,
void *  data 
)
static

Checks whether PDB info is present in the topology.

Parameters
[in]topTopology structure.
nparNot used.
paramNot used.
dataNot used.
Returns
0 if PDB info is present in the topology, -1 otherwise.

If PDB info is not found, also prints an error message.

static void evaluate_all ( const gmx::SelMethodEvalContext context,
gmx_ana_index_t g,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the all selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Copies g to out->u.g.

static void evaluate_altloc ( const gmx::SelMethodEvalContext context,
gmx_ana_index_t g,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the altloc selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Returns the alternate location identifier for each atom in out->u.s.

static void evaluate_atomname ( const gmx::SelMethodEvalContext context,
gmx_ana_index_t g,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the atomname selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Returns the atom name for each atom in out->u.s.

static void evaluate_atomnr ( const gmx::SelMethodEvalContext context,
gmx_ana_index_t g,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the atomnr selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Returns the indices for each atom in out->u.i.

static void evaluate_atomtype ( const gmx::SelMethodEvalContext context,
gmx_ana_index_t g,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the atomtype selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Returns the atom type for each atom in out->u.s. Segfaults if atom types are not found in the topology.

static void evaluate_betafactor ( const gmx::SelMethodEvalContext context,
gmx_ana_index_t g,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the betafactor selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Returns the B-factors for each atom in out->u.r. Segfaults if PDB info is not found in the topology.

static void evaluate_chain ( const gmx::SelMethodEvalContext context,
gmx_ana_index_t g,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the chain selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Returns the chain for each atom in out->u.s.

static void evaluate_charge ( const gmx::SelMethodEvalContext context,
gmx_ana_index_t g,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the charge selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Returns the charge for each atom in out->u.r.

static void evaluate_coord ( real  out[],
gmx_ana_pos_t pos,
int  d 
)
static

Internal utility function for position keyword evaluation.

Parameters
[out]outOutput array.
[in]posPosition data to use instead of atomic coordinates.
[in]dCoordinate index to evaluate (XX, YY or ZZ).

This function is used internally by evaluate_x(), evaluate_y() and evaluate_z() to do the actual evaluation.

static void evaluate_insertcode ( const gmx::SelMethodEvalContext context,
gmx_ana_index_t g,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the insertcode selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Returns the insertion code for each atom in out->u.s.

static void evaluate_mass ( const gmx::SelMethodEvalContext context,
gmx_ana_index_t g,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the mass selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Returns the mass for each atom in out->u.r.

static void evaluate_molindex ( const gmx::SelMethodEvalContext context,
gmx_ana_index_t g,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the molindex selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Returns the molecule indices for each atom in out->u.i.

static void evaluate_none ( const gmx::SelMethodEvalContext context,
gmx_ana_index_t g,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the none selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Returns an empty out->u.g.

static void evaluate_occupancy ( const gmx::SelMethodEvalContext context,
gmx_ana_index_t g,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the occupancy selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Returns the occupancy numbers for each atom in out->u.r. Segfaults if PDB info is not found in the topology.

static void evaluate_pdbatomname ( const gmx::SelMethodEvalContext context,
gmx_ana_index_t g,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the pdbatomname selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Returns the PDB atom name for each atom in out->u.s.

static void evaluate_resindex ( const gmx::SelMethodEvalContext context,
gmx_ana_index_t g,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the resindex selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Returns the residue indices for each atom in out->u.i.

static void evaluate_resname ( const gmx::SelMethodEvalContext context,
gmx_ana_index_t g,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the resname selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Returns the residue name for each atom in out->u.s.

static void evaluate_resnr ( const gmx::SelMethodEvalContext context,
gmx_ana_index_t g,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the resnr selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Returns the residue numbers for each atom in out->u.i.

static void evaluate_x ( const gmx::SelMethodEvalContext context,
gmx_ana_pos_t pos,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the x selection keyword.

See sel_updatefunc_pos() for description of the parameters. data is not used.

Returns the x coordinate for each position in out->u.r.

static void evaluate_y ( const gmx::SelMethodEvalContext context,
gmx_ana_pos_t pos,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the y selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Returns the y coordinate for each position in out->u.r.

static void evaluate_z ( const gmx::SelMethodEvalContext context,
gmx_ana_pos_t pos,
gmx_ana_selvalue_t out,
void *  data 
)
static

Evaluates the z selection keyword.

See sel_updatefunc() for description of the parameters. data is not used.

Returns the z coordinate for each position in out->u.r.

Variable Documentation

const char* const help_atomname[]
static
Initial value:
= {
"::",
"",
" name",
" pdbname",
" atomname",
" pdbatomname",
"",
"These keywords select atoms by name. [TT]name[tt] selects atoms using",
"the GROMACS atom naming convention.",
"For input formats other than PDB, the atom names are matched exactly",
"as they appear in the input file. For PDB files, 4 character atom names",
"that start with a digit are matched after moving the digit to the end",
"(e.g., to match 3HG2 from a PDB file, use [TT]name HG23[tt]).",
"[TT]pdbname[tt] can only be used with a PDB input file, and selects",
"atoms based on the exact name given in the input file, without the",
"transformation described above.[PAR]",
"[TT]atomname[tt] and [TT]pdbatomname[tt] are synonyms for the above two",
"keywords."
}

Help text for atom name selection keywords.

const char* const help_resindex[]
static
Initial value:
= {
"::",
"",
" resnr",
" resid",
" resindex",
" residue",
"",
"[TT]resnr[tt] selects atoms using the residue numbering in the input",
"file. [TT]resid[tt] is synonym for this keyword for VMD compatibility.",
"",
"[TT]resindex N[tt] selects the [TT]N[tt] th residue starting from the",
"beginning of the input file. This is useful for uniquely identifying",
"residues if there are duplicate numbers in the input file (e.g., in",
"multiple chains).",
"[TT]residue[tt] is a synonym for [TT]resindex[tt]. This allows",
"[TT]same residue as[tt] to work as expected."
}

Help text for residue index selection keywords.

Initial value:
= {
"all", GROUP_VALUE, 0, 0, nullptr, nullptr, nullptr,
nullptr, nullptr, nullptr, nullptr, &evaluate_all, nullptr,
}
One group of atoms.
Definition: selvalue.h:58
static void evaluate_all(const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
Evaluates the all selection keyword.
Definition: sm_simple.cpp:413

Selection method data for all selection keyword.

Initial value:
= {
"altloc", STR_VALUE, 1 | 64 ,
0, nullptr, nullptr,
nullptr, &check_pdbinfo, nullptr,
nullptr, nullptr, &evaluate_altloc,
nullptr,
}
static void check_pdbinfo(const gmx_mtop_t *top, int npar, gmx_ana_selparam_t *param, void *data)
Checks whether PDB info is present in the topology.
Definition: sm_simple.cpp:706
One or more string values.
Definition: selvalue.h:56
static void evaluate_altloc(const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
Evaluates the altloc selection keyword.
Definition: sm_simple.cpp:720

Selection method data for chain selection keyword.

gmx_ana_selmethod_t sm_atomname
Initial value:
= {
"atomname", STR_VALUE,
1 , 0,
nullptr, nullptr,
nullptr, nullptr,
nullptr, nullptr,
nullptr, &evaluate_atomname,
}
static const char *const help_atomname[]
Help text for atom name selection keywords.
Definition: sm_simple.cpp:202
static void evaluate_atomname(const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
Evaluates the atomname selection keyword.
Definition: sm_simple.cpp:531
static const char helptitle_atomname[]
Help title for atom name selection keywords.
Definition: sm_simple.cpp:200
One or more string values.
Definition: selvalue.h:56
constexpr int asize(T(&)[N])
Calculates the number of elements in a static array at compile time.
Definition: arraysize.h:50

Selection method data for atomname selection keyword.

Initial value:
= {
"atomnr", INT_VALUE, 0, 0, nullptr, nullptr, nullptr,
nullptr, nullptr, nullptr, nullptr, &evaluate_atomnr, nullptr,
}
static void evaluate_atomnr(const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
Evaluates the atomnr selection keyword.
Definition: sm_simple.cpp:441
One or more integer values.
Definition: selvalue.h:54

Selection method data for atomnr selection keyword.

gmx_ana_selmethod_t sm_atomtype
Initial value:
= {
"atomtype", STR_VALUE, 1 , 0, nullptr, nullptr,
nullptr, &check_atomtype, nullptr, nullptr, nullptr, &evaluate_atomtype,
nullptr,
}
static void evaluate_atomtype(const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
Evaluates the atomtype selection keyword.
Definition: sm_simple.cpp:585
One or more string values.
Definition: selvalue.h:56
static void check_atomtype(const gmx_mtop_t *top, int npar, gmx_ana_selparam_t *param, void *data)
Checks whether atom types are present in the topology.
Definition: sm_simple.cpp:570

Selection method data for atomtype selection keyword.

gmx_ana_selmethod_t sm_betafactor
Initial value:
= {
"betafactor", REAL_VALUE, 1 , 0, nullptr, nullptr,
nullptr, &check_pdbinfo, nullptr, nullptr, nullptr, &evaluate_betafactor,
nullptr,
}
static void check_pdbinfo(const gmx_mtop_t *top, int npar, gmx_ana_selparam_t *param, void *data)
Checks whether PDB info is present in the topology.
Definition: sm_simple.cpp:706
One or more real values.
Definition: selvalue.h:55
static void evaluate_betafactor(const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
Evaluates the betafactor selection keyword.
Definition: sm_simple.cpp:760

Selection method data for betafactor selection keyword.

Initial value:
= {
"chain", STR_VALUE, 1 | 64 ,
0, nullptr, nullptr,
nullptr, nullptr, nullptr,
nullptr, nullptr, &evaluate_chain,
nullptr,
}
One or more string values.
Definition: selvalue.h:56
static void evaluate_chain(const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
Evaluates the chain selection keyword.
Definition: sm_simple.cpp:645

Selection method data for chain selection keyword.

Initial value:
= {
"charge", REAL_VALUE, 1 , 0, nullptr, nullptr, nullptr,
&check_charge, nullptr, nullptr, nullptr, &evaluate_charge, nullptr,
}
static void check_charge(const gmx_mtop_t *top, int npar, gmx_ana_selparam_t *param, void *data)
Checks whether charges are present in the topology.
Definition: sm_simple.cpp:679
One or more real values.
Definition: selvalue.h:55
static void evaluate_charge(const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
Evaluates the charge selection keyword.
Definition: sm_simple.cpp:693

Selection method data for charge selection keyword.

gmx_ana_selmethod_t sm_insertcode
Initial value:
= {
"insertcode",
1 | 64 ,
0,
nullptr,
nullptr,
nullptr,
nullptr,
nullptr,
nullptr,
nullptr,
nullptr,
}
One or more string values.
Definition: selvalue.h:56
static void evaluate_insertcode(const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
Evaluates the insertcode selection keyword.
Definition: sm_simple.cpp:626

Selection method data for chain selection keyword.

Initial value:
= {
"mass", REAL_VALUE, 2 , 0, nullptr, nullptr, nullptr,
nullptr, nullptr, nullptr, nullptr, &evaluate_mass, nullptr,
}
One or more real values.
Definition: selvalue.h:55
static void evaluate_mass(const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
Evaluates the mass selection keyword.
Definition: sm_simple.cpp:664

Selection method data for mass selection keyword.

gmx_ana_selmethod_t sm_molindex
Initial value:
= {
"molindex", INT_VALUE, 1 , 0, nullptr, nullptr,
nullptr, &check_molecules, nullptr, nullptr, nullptr, &evaluate_molindex,
nullptr,
}
static void evaluate_molindex(const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
Evaluates the molindex selection keyword.
Definition: sm_simple.cpp:512
One or more integer values.
Definition: selvalue.h:54
static void check_molecules(const gmx_mtop_t *top, int npar, gmx_ana_selparam_t *param, void *data)
Checks whether molecule information is present in the topology.
Definition: sm_simple.cpp:495

Selection method data for molindex selection keyword.

Initial value:
= {
"none", GROUP_VALUE, 0, 0, nullptr, nullptr, nullptr,
nullptr, nullptr, nullptr, nullptr, &evaluate_none, nullptr,
}
One group of atoms.
Definition: selvalue.h:58
static void evaluate_none(const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
Evaluates the none selection keyword.
Definition: sm_simple.cpp:427

Selection method data for none selection keyword.

gmx_ana_selmethod_t sm_occupancy
Initial value:
= {
"occupancy", REAL_VALUE, 1 , 0, nullptr, nullptr,
nullptr, &check_pdbinfo, nullptr, nullptr, nullptr, &evaluate_occupancy,
nullptr,
}
static void check_pdbinfo(const gmx_mtop_t *top, int npar, gmx_ana_selparam_t *param, void *data)
Checks whether PDB info is present in the topology.
Definition: sm_simple.cpp:706
One or more real values.
Definition: selvalue.h:55
static void evaluate_occupancy(const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
Evaluates the occupancy selection keyword.
Definition: sm_simple.cpp:740

Selection method data for occupancy selection keyword.

gmx_ana_selmethod_t sm_pdbatomname
Initial value:
= {
"pdbatomname", STR_VALUE,
1 , 0,
nullptr, nullptr,
nullptr, &check_pdbinfo,
nullptr, nullptr,
}
static void check_pdbinfo(const gmx_mtop_t *top, int npar, gmx_ana_selparam_t *param, void *data)
Checks whether PDB info is present in the topology.
Definition: sm_simple.cpp:706
static const char *const help_atomname[]
Help text for atom name selection keywords.
Definition: sm_simple.cpp:202
static const char helptitle_atomname[]
Help title for atom name selection keywords.
Definition: sm_simple.cpp:200
One or more string values.
Definition: selvalue.h:56
static void evaluate_pdbatomname(const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
Evaluates the pdbatomname selection keyword.
Definition: sm_simple.cpp:552
constexpr int asize(T(&)[N])
Calculates the number of elements in a static array at compile time.
Definition: arraysize.h:50

Selection method data for pdbatomname selection keyword.

gmx_ana_selmethod_t sm_resindex
Initial value:
= {
"resindex", INT_VALUE,
1 , 0,
nullptr, nullptr,
nullptr, nullptr,
nullptr, nullptr,
nullptr, &evaluate_resindex,
}
static void evaluate_resindex(const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
Evaluates the resindex selection keyword.
Definition: sm_simple.cpp:480
static const char *const help_resindex[]
Help text for residue index selection keywords.
Definition: sm_simple.cpp:227
constexpr int asize(T(&)[N])
Calculates the number of elements in a static array at compile time.
Definition: arraysize.h:50
One or more integer values.
Definition: selvalue.h:54
static const char helptitle_resindex[]
Help title for residue index selection keywords.
Definition: sm_simple.cpp:225

Selection method data for resindex selection keyword.

gmx_ana_selmethod_t sm_resname
Initial value:
= {
"resname", STR_VALUE, 1 , 0, nullptr, nullptr, nullptr,
nullptr, nullptr, nullptr, nullptr, &evaluate_resname, nullptr,
}
One or more string values.
Definition: selvalue.h:56
static void evaluate_resname(const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
Evaluates the resname selection keyword.
Definition: sm_simple.cpp:607

Selection method data for resname selection keyword.

Initial value:
= {
"resnr", INT_VALUE,
1 , 0,
nullptr, nullptr,
nullptr, nullptr,
nullptr, nullptr,
nullptr, &evaluate_resnr,
}
static void evaluate_resnr(const gmx::SelMethodEvalContext &context, gmx_ana_index_t *g, gmx_ana_selvalue_t *out, void *data)
Evaluates the resnr selection keyword.
Definition: sm_simple.cpp:461
static const char *const help_resindex[]
Help text for residue index selection keywords.
Definition: sm_simple.cpp:227
constexpr int asize(T(&)[N])
Calculates the number of elements in a static array at compile time.
Definition: arraysize.h:50
One or more integer values.
Definition: selvalue.h:54
static const char helptitle_resindex[]
Help title for residue index selection keywords.
Definition: sm_simple.cpp:225

Selection method data for resnr selection keyword.

Initial value:
= {
"x", REAL_VALUE, 4 , 0, nullptr, nullptr, nullptr,
nullptr, nullptr, nullptr, nullptr, nullptr, &evaluate_x,
}
static void evaluate_x(const gmx::SelMethodEvalContext &context, gmx_ana_pos_t *pos, gmx_ana_selvalue_t *out, void *data)
Evaluates the x selection keyword.
Definition: sm_simple.cpp:800
One or more real values.
Definition: selvalue.h:55

Selection method data for x selection keyword.

Initial value:
= {
"y", REAL_VALUE, 4 , 0, nullptr, nullptr, nullptr,
nullptr, nullptr, nullptr, nullptr, nullptr, &evaluate_y,
}
static void evaluate_y(const gmx::SelMethodEvalContext &context, gmx_ana_pos_t *pos, gmx_ana_selvalue_t *out, void *data)
Evaluates the y selection keyword.
Definition: sm_simple.cpp:815
One or more real values.
Definition: selvalue.h:55

Selection method data for y selection keyword.

Initial value:
= {
"z", REAL_VALUE, 4 , 0, nullptr, nullptr, nullptr,
nullptr, nullptr, nullptr, nullptr, nullptr, &evaluate_z,
}
One or more real values.
Definition: selvalue.h:55
static void evaluate_z(const gmx::SelMethodEvalContext &context, gmx_ana_pos_t *pos, gmx_ana_selvalue_t *out, void *data)
Evaluates the z selection keyword.
Definition: sm_simple.cpp:830

Selection method data for z selection keyword.