seams-core v2.14.0
libyodaLib, the C++ engine of d-SEAMS
Loading...
Searching...
No Matches
Further analyses

Aliases, k-nearest lists, RDF, hydrogen bonds, density, fingerprints, sites. More...

Functions

SEAMS_API seams_status seams_cages (seams_system *sys, double cutoff, int type, int graph, int k, int complete, seams_cage_set **out)
 Hexagonal and double-diamond cages.
SEAMS_API seams_status seams_signature_cages (seams_system *sys, double cutoff, int type, int graph, const char *spec, size_t *n_cages, size_t *n_atoms)
 Closed cages of one ring census.
SEAMS_API seams_status seams_signature_cages_edge (seams_system *sys, double cutoff, int type, int graph, const char *spec, const char *edge, size_t *n_cages, size_t *n_atoms)
 Closed cages of one ring census with an explicit face-edge window.
SEAMS_API seams_status seams_steinhardt (seams_system *sys, double cutoff, int type, int order_l, double *ql, size_t ql_len, double *qlbar, size_t qlbar_len)
 Local Steinhardt q_l on the cutoff shell, and the average on request.
SEAMS_API seams_status seams_neighbours_knn (seams_system *sys, int k, double cutoff, int type, int mutual, seams_neighbours **out)
 k-nearest neighbour list.
SEAMS_API seams_status seams_rdf (seams_system *sys, double rmax, int bins, int type_i, int type_j, double *r, double *g, int *count, size_t cap, size_t *n_out, double *volume)
 Partial radial distribution.
SEAMS_API seams_status seams_running_cn (seams_system *sys, double rmax, int bins, int type_i, int type_j, double *r, double *cn, size_t cap, size_t *n_out)
 Running coordination number along the partial RDF.
SEAMS_API seams_status seams_coordination (seams_system *sys, double rmax, int bins, int type_i, int type_j, double *cn)
 Coordination number integrated to rmax.
SEAMS_API seams_status seams_hbonds (seams_system *sys, double cutoff, int oxygen_type, int hydrogen_type, double dist_cutoff, double angle_cutoff, int *n_bonds)
 Hydrogen-bond count on one frame.
SEAMS_API seams_status seams_density_axis (seams_system *sys, int type, int bins, int axis, double *z, double *rho, size_t cap, size_t *n_out)
 Number density along one cell axis.
SEAMS_API seams_status seams_fingerprint (seams_system *sys, double cutoff, int type, int k, int graph, int hops, int color_types, seams_topo **out)
 Topological fingerprint of the bonded graph.
SEAMS_API void seams_fingerprint_destroy (seams_topo *fp)
 Free a fingerprint.
SEAMS_API seams_status seams_fingerprint_key (const seams_topo *fp, char *buf, size_t cap, size_t *n_out)
 Frame key text.
SEAMS_API seams_status seams_fingerprint_atom (const seams_topo *fp, int index, char *buf, size_t cap, size_t *n_out)
 Local key of one atom.
SEAMS_API seams_status seams_fingerprint_rings (const seams_topo *fp, int *counts, size_t counts_len)
 Primitive-ring census stored on the fingerprint.
SEAMS_API seams_status seams_contact_pairs (seams_system *sys, const char *site_spec, size_t *n_pairs, int *n_cation, int *n_anion)
 Mutual nearest unlike contacts of a site table.
SEAMS_API seams_status seams_domains (seams_system *sys, double cutoff, const char *site_spec, int subset, int *n_subset, int *largest, double *percolation)
 Largest domain of a polar or apolar site subset.
SEAMS_API seams_status seams_prisms (seams_system *sys, double cutoff, int type, int *perfect, int *imperfect, size_t len)
 Perfect and imperfect prism counts by ring size.
SEAMS_API seams_status seams_monolayer (seams_system *sys, double cutoff, int type, int max_depth, double sheet_area, int *counts, size_t counts_len)
 Primitive-ring histogram of a monolayer.
SEAMS_API seams_status seams_site_table (seams_system *sys, const char *spec, int *kinds, size_t len)
 Per-atom site kind from a site-table spec.

Detailed Description

Aliases, k-nearest lists, RDF, hydrogen bonds, density, fingerprints, sites.

Function Documentation

◆ seams_cages()

SEAMS_API seams_status seams_cages ( seams_system * sys,
double cutoff,
int type,
int graph,
int k,
int complete,
seams_cage_set ** out )

Hexagonal and double-diamond cages.

Same search as seams_cages_find().

Parameters
sysFrame handle.
cutoffPositive finite cutoff, Angstrom.
typeSpecies filter.
graphSEAMS_GRAPH_CUTOFF, SEAMS_GRAPH_MUTUAL, or SEAMS_GRAPH_SEEDED.
kNeighbour count for the seeded graph. Zero selects 4.
completeNon-zero runs ring-adjacent completion on seeded labels.
outReceives a seams_cage_set. On failure *out is NULL.
Returns
Same codes as seams_cages_find().
Handle access
Non-const only because the call clears the handle's error slot on entry, so seams_handle_error() reports this call. It reads the frame and keeps no scratch on the handle.
Ownership
The caller frees *out with seams_cages_destroy().
Thread safety
Exclusive use of sys.
Example
seams_cage_set *cages = NULL;
seams_cages(sys, 3.5, 0, SEAMS_GRAPH_SEEDED, 4, 1, &cages);
SEAMS_API void seams_cages_destroy(seams_cage_set *cages)
Free a cage-membership handle.
SEAMS_API seams_status seams_cages(seams_system *sys, double cutoff, int type, int graph, int k, int complete, seams_cage_set **out)
Hexagonal and double-diamond cages.
struct seams_cage_set seams_cage_set
Hexagonal and double-diamond membership.
Definition seams.h:247
@ SEAMS_GRAPH_SEEDED
Mutual seeds with union completions, for cages only.
Definition seams.h:210

◆ seams_contact_pairs()

SEAMS_API seams_status seams_contact_pairs ( seams_system * sys,
const char * site_spec,
size_t * n_pairs,
int * n_cation,
int * n_anion )

Mutual nearest unlike contacts of a site table.

Cation and anion counts are molecules in the ion cloud.

Parameters
sysFrame handle.
site_specText such as "1=cationHead,2=anion". Must be non-NULL.
n_pairsReceives the contact count, or NULL.
n_cationReceives the cation molecule count, or NULL.
n_anionReceives the anion molecule count, or NULL. At least one of the three outputs must be non-NULL.
Returns
SEAMS_OK, or SEAMS_ERR_NULL, SEAMS_ERR_STATE, SEAMS_ERR_ARG, SEAMS_ERR_NOMEM, SEAMS_ERR_INTERNAL.
Handle access
Non-const only because the call clears the handle's error slot on entry, so seams_handle_error() reports this call. It reads the frame and keeps no scratch on the handle.
Ownership
The caller owns sys; the call borrows it. site_spec is read during the call only. n_pairs, n_cation and n_anion are caller storage that the call fills. The library keeps no pointer to any argument.
Thread safety
Exclusive use of sys.
Example
size_t pairs = 0;
seams_contact_pairs(sys, "1=cationHead,2=anion", &pairs, NULL, NULL);
SEAMS_API seams_status seams_contact_pairs(seams_system *sys, const char *site_spec, size_t *n_pairs, int *n_cation, int *n_anion)
Mutual nearest unlike contacts of a site table.

◆ seams_coordination()

SEAMS_API seams_status seams_coordination ( seams_system * sys,
double rmax,
int bins,
int type_i,
int type_j,
double * cn )

Coordination number integrated to rmax.

Parameters
sysFrame handle.
rmaxPositive finite outer radius, Angstrom.
binsBin count. Zero selects about rmax / 0.1.
type_iCentral species, as in seams_rdf().
type_jCounted species, as in seams_rdf().
cnReceives the coordination number.
Returns
SEAMS_OK, or SEAMS_ERR_NULL, SEAMS_ERR_STATE, SEAMS_ERR_RANGE, SEAMS_ERR_NOMEM, SEAMS_ERR_INTERNAL.
Handle access
Non-const only because the call clears the handle's error slot on entry, so seams_handle_error() reports this call. It reads the frame and keeps no scratch on the handle.
Ownership
The caller owns sys; the call borrows it. cn is caller storage that the call fills. The library keeps no pointer to any argument.
Thread safety
Exclusive use of sys.
Example
double cn = 0;
seams_coordination(sys, 3.5, 0, 1, 1, &cn);
SEAMS_API seams_status seams_coordination(seams_system *sys, double rmax, int bins, int type_i, int type_j, double *cn)
Coordination number integrated to rmax.

◆ seams_density_axis()

SEAMS_API seams_status seams_density_axis ( seams_system * sys,
int type,
int bins,
int axis,
double * z,
double * rho,
size_t cap,
size_t * n_out )

Number density along one cell axis.

z is Angstrom. rho is number density, atoms per cubic Angstrom.

Parameters
sysFrame handle.
typeSpecies filter. Zero keeps every atom.
binsBin count. Zero selects about one bin per 0.1 Angstrom.
axis0, 1, or 2.
zBin centers, or NULL to query.
rhoDensity per bin, or NULL to query.
capCapacity of each non-NULL column.
n_outReceives the bin count.
Returns
SEAMS_OK, or SEAMS_ERR_NULL, SEAMS_ERR_STATE, SEAMS_ERR_RANGE, SEAMS_ERR_NOMEM, SEAMS_ERR_INTERNAL.
Handle access
Non-const only because the call clears the handle's error slot on entry, so seams_handle_error() reports this call. It reads the frame and keeps no scratch on the handle.
Ownership
The caller owns the columns.
Thread safety
Exclusive use of sys.
Example
double z[50], rho[50];
size_t bins = 0;
seams_density_axis(sys, 0, 50, 2, z, rho, 50, &bins);
SEAMS_API seams_status seams_density_axis(seams_system *sys, int type, int bins, int axis, double *z, double *rho, size_t cap, size_t *n_out)
Number density along one cell axis.

◆ seams_domains()

SEAMS_API seams_status seams_domains ( seams_system * sys,
double cutoff,
const char * site_spec,
int subset,
int * n_subset,
int * largest,
double * percolation )

Largest domain of a polar or apolar site subset.

Parameters
sysFrame handle.
cutoffPositive finite cluster cutoff, Angstrom.
site_specSite table text. Must be non-NULL.
subset0 is apolar, 1 is polar.
n_subsetReceives the number of sites in the subset, or NULL.
largestReceives the size of the largest domain, or NULL.
percolationReceives the largest domain size over the subset size, or NULL. At least one output must be non-NULL.
Returns
SEAMS_OK, or SEAMS_ERR_NULL, SEAMS_ERR_STATE, SEAMS_ERR_RANGE, SEAMS_ERR_ARG, SEAMS_ERR_NOMEM, SEAMS_ERR_INTERNAL.
Handle access
Non-const only because the call clears the handle's error slot on entry, so seams_handle_error() reports this call. It reads the frame and keeps no scratch on the handle.
Ownership
The caller owns sys; the call borrows it. site_spec is read during the call only. n_subset, largest and percolation are caller storage that the call fills. The library keeps no pointer to any argument.
Thread safety
Exclusive use of sys.
Example
int largest = 0;
seams_domains(sys, 5.0, "1=cationHead,2=anion,3=tail", 0, NULL, &largest, NULL);
SEAMS_API seams_status seams_domains(seams_system *sys, double cutoff, const char *site_spec, int subset, int *n_subset, int *largest, double *percolation)
Largest domain of a polar or apolar site subset.

◆ seams_fingerprint()

SEAMS_API seams_status seams_fingerprint ( seams_system * sys,
double cutoff,
int type,
int k,
int graph,
int hops,
int color_types,
seams_topo ** out )

Topological fingerprint of the bonded graph.

Parameters
sysFrame handle.
cutoffPositive finite cutoff, Angstrom.
typeSpecies filter.
kNeighbour count for the mutual graph. Zero selects 4.
graphSEAMS_GRAPH_CUTOFF or SEAMS_GRAPH_MUTUAL.
hopsNeighbourhood depth. Zero selects 2.
color_typesNon-zero colors vertices by LAMMPS type.
outReceives a seams_topo. On failure *out is NULL.
Returns
SEAMS_OK, or SEAMS_ERR_NULL, SEAMS_ERR_STATE, SEAMS_ERR_RANGE, SEAMS_ERR_ARG, SEAMS_ERR_NOMEM, SEAMS_ERR_INTERNAL.
Handle access
Non-const only because the call clears the handle's error slot on entry, so seams_handle_error() reports this call. It reads the frame and keeps no scratch on the handle.
Ownership
The caller frees *out with seams_fingerprint_destroy().
Thread safety
Exclusive use of sys.
Example
seams_topo *fp = NULL;
seams_fingerprint(sys, 3.5, 0, 4, SEAMS_GRAPH_CUTOFF, 2, 0, &fp);
SEAMS_API seams_status seams_fingerprint(seams_system *sys, double cutoff, int type, int k, int graph, int hops, int color_types, seams_topo **out)
Topological fingerprint of the bonded graph.
SEAMS_API void seams_fingerprint_destroy(seams_topo *fp)
Free a fingerprint.
struct seams_topo seams_topo
Topological fingerprint of one bonded frame.
Definition seams.h:251
@ SEAMS_GRAPH_CUTOFF
Every neighbour inside the cutoff.
Definition seams.h:208

◆ seams_fingerprint_atom()

SEAMS_API seams_status seams_fingerprint_atom ( const seams_topo * fp,
int index,
char * buf,
size_t cap,
size_t * n_out )

Local key of one atom.

Same buffer rule as seams_fingerprint_key().

Parameters
fpFingerprint handle.
indexAtom index in the frame.
bufCaller buffer of cap bytes, or NULL to query.
capCapacity of buf, including the terminating NUL.
n_outReceives the key length without the terminating NUL.
Returns
SEAMS_OK, or SEAMS_ERR_NULL, SEAMS_ERR_RANGE for a bad index or a short buffer.
Ownership
The caller owns buf.
Thread safety
Read-only: may run alongside other const calls on fp, and not alongside a non-const call on fp.
Example
char key[256];
size_t len = 0;
seams_fingerprint_atom(fp, 0, key, sizeof key, &len);
SEAMS_API seams_status seams_fingerprint_atom(const seams_topo *fp, int index, char *buf, size_t cap, size_t *n_out)
Local key of one atom.

◆ seams_fingerprint_destroy()

SEAMS_API void seams_fingerprint_destroy ( seams_topo * fp)

Free a fingerprint.

Parameters
fpHandle from seams_fingerprint(), or NULL. NULL is ignored.
Ownership
Releases the handle and its key strings.
Thread safety
The caller must not use fp after this returns.
Example

◆ seams_fingerprint_key()

SEAMS_API seams_status seams_fingerprint_key ( const seams_topo * fp,
char * buf,
size_t cap,
size_t * n_out )

Frame key text.

Parameters
fpFingerprint handle.
bufCaller buffer of cap bytes, or NULL to query.
capCapacity of buf, including the terminating NUL.
n_outReceives the key length without the terminating NUL.
Returns
SEAMS_OK, or SEAMS_ERR_NULL, SEAMS_ERR_RANGE when buf is short.
Ownership
The caller owns buf. The copy is NUL-terminated.
Thread safety
Read-only: may run alongside other const calls on fp, and not alongside a non-const call on fp.
Example
size_t len = 0;
seams_fingerprint_key(fp, NULL, 0, &len);
char *key = malloc(len + 1);
seams_fingerprint_key(fp, key, len + 1, &len);
free(key);
SEAMS_API seams_status seams_fingerprint_key(const seams_topo *fp, char *buf, size_t cap, size_t *n_out)
Frame key text.

◆ seams_fingerprint_rings()

SEAMS_API seams_status seams_fingerprint_rings ( const seams_topo * fp,
int * counts,
size_t counts_len )

Primitive-ring census stored on the fingerprint.

Parameters
fpFingerprint handle.
countsCaller buffer. counts[k] receives the number of rings of size k. Sizes past the buffer are dropped.
counts_lenLength of counts. Must be positive.
Returns
SEAMS_OK, or SEAMS_ERR_NULL, SEAMS_ERR_RANGE when counts_len is 0.
Ownership
The caller owns counts.
Thread safety
Read-only: may run alongside other const calls on fp, and not alongside a non-const call on fp.
Example
int census[13];
seams_fingerprint_rings(fp, census, 13);
SEAMS_API seams_status seams_fingerprint_rings(const seams_topo *fp, int *counts, size_t counts_len)
Primitive-ring census stored on the fingerprint.

◆ seams_hbonds()

SEAMS_API seams_status seams_hbonds ( seams_system * sys,
double cutoff,
int oxygen_type,
int hydrogen_type,
double dist_cutoff,
double angle_cutoff,
int * n_bonds )

Hydrogen-bond count on one frame.

Parameters
sysFrame handle.
cutoffPositive finite donor-acceptor cutoff, Angstrom.
oxygen_typeHeavy-atom species. Zero keeps every atom that is not hydrogen_type.
hydrogen_typePositive hydrogen species.
dist_cutoffAcceptor-H distance, Angstrom.
angle_cutoffO-O-H angle, degrees.
n_bondsReceives the number of hydrogen bonds.
Returns
SEAMS_OK, or SEAMS_ERR_NULL, SEAMS_ERR_STATE, SEAMS_ERR_RANGE, SEAMS_ERR_ARG, SEAMS_ERR_NOMEM, SEAMS_ERR_INTERNAL.
Handle access
Non-const only because the call clears the handle's error slot on entry, so seams_handle_error() reports this call. It reads the frame and keeps no scratch on the handle.
Ownership
The caller owns sys; the call borrows it. n_bonds is caller storage that the call fills. The library keeps no pointer to any argument.
Thread safety
Exclusive use of sys.
Example
int n_bonds = 0;
seams_hbonds(sys, 3.5, 1, 2, 2.4, 30.0, &n_bonds);
SEAMS_API seams_status seams_hbonds(seams_system *sys, double cutoff, int oxygen_type, int hydrogen_type, double dist_cutoff, double angle_cutoff, int *n_bonds)
Hydrogen-bond count on one frame.

◆ seams_monolayer()

SEAMS_API seams_status seams_monolayer ( seams_system * sys,
double cutoff,
int type,
int max_depth,
double sheet_area,
int * counts,
size_t counts_len )

Primitive-ring histogram of a monolayer.

Parameters
sysFrame handle.
cutoffPositive finite cutoff, Angstrom.
typeSpecies filter.
max_depthLargest ring size, at least 3.
sheet_areaSheet area, square Angstrom. Must be positive.
countscounts[k] is the number of rings of size k.
counts_lenMust be at least max_depth + 1.
Returns
SEAMS_OK, or SEAMS_ERR_NULL, SEAMS_ERR_STATE, SEAMS_ERR_RANGE, SEAMS_ERR_NOMEM, SEAMS_ERR_INTERNAL.
Handle access
Non-const only because the call clears the handle's error slot on entry, so seams_handle_error() reports this call. It reads the frame and keeps no scratch on the handle.
Ownership
The caller owns counts.
Thread safety
Exclusive use of sys.
Example
int counts[7];
seams_monolayer(sys, 3.5, 0, 6, 900.0, counts, 7);
SEAMS_API seams_status seams_monolayer(seams_system *sys, double cutoff, int type, int max_depth, double sheet_area, int *counts, size_t counts_len)
Primitive-ring histogram of a monolayer.

◆ seams_neighbours_knn()

SEAMS_API seams_status seams_neighbours_knn ( seams_system * sys,
int k,
double cutoff,
int type,
int mutual,
seams_neighbours ** out )

k-nearest neighbour list.

Parameters
sysFrame handle.
kPositive neighbour count.
cutoffNominal positive cutoff, Angstrom. Candidates are taken inside cutoff + 1.5.
typeSpecies filter. Zero and negative keep every atom.
mutualNon-zero keeps the mutual graph. Zero keeps the one-way k-nearest graph.
outReceives a neighbour handle. On failure *out is NULL.
Returns
SEAMS_OK, or SEAMS_ERR_NULL, SEAMS_ERR_STATE, SEAMS_ERR_RANGE, SEAMS_ERR_ARG, SEAMS_ERR_NOMEM, SEAMS_ERR_INTERNAL.
Handle access
Non-const only because the call clears the handle's error slot on entry, so seams_handle_error() reports this call. It reads the frame and keeps no scratch on the handle.
Ownership
The caller frees *out with seams_neighbours_destroy().
Thread safety
Exclusive use of sys.
Example
seams_neighbours *nb = NULL;
seams_neighbours_knn(sys, 4, 3.5, 0, 1, &nb);
SEAMS_API seams_status seams_neighbours_knn(seams_system *sys, int k, double cutoff, int type, int mutual, seams_neighbours **out)
k-nearest neighbour list.
SEAMS_API void seams_neighbours_destroy(seams_neighbours *nb)
Free a neighbour list.
struct seams_neighbours seams_neighbours
One neighbour list.
Definition seams.h:243

◆ seams_prisms()

SEAMS_API seams_status seams_prisms ( seams_system * sys,
double cutoff,
int type,
int * perfect,
int * imperfect,
size_t len )

Perfect and imperfect prism counts by ring size.

Rings come from the mutual four-nearest graph inside cutoff + 1.5.

Parameters
sysFrame handle.
cutoffPositive finite cutoff, Angstrom.
typeSpecies filter.
perfectCaller buffer. perfect[k] receives the perfect k-prisms.
imperfectCaller buffer. imperfect[k] receives the deformed k-prisms.
lenLength of each buffer. At least 7, so that sizes 3 through 6 are filled.
Returns
SEAMS_OK, or SEAMS_ERR_NULL, SEAMS_ERR_STATE, SEAMS_ERR_RANGE, SEAMS_ERR_NOMEM, SEAMS_ERR_INTERNAL.
Handle access
Non-const only because the call clears the handle's error slot on entry, so seams_handle_error() reports this call. It reads the frame and keeps no scratch on the handle.
Ownership
The caller owns both buffers.
Thread safety
Exclusive use of sys.
Example
int perfect[7], imperfect[7];
seams_prisms(sys, 3.5, 0, perfect, imperfect, 7);
SEAMS_API seams_status seams_prisms(seams_system *sys, double cutoff, int type, int *perfect, int *imperfect, size_t len)
Perfect and imperfect prism counts by ring size.

◆ seams_rdf()

SEAMS_API seams_status seams_rdf ( seams_system * sys,
double rmax,
int bins,
int type_i,
int type_j,
double * r,
double * g,
int * count,
size_t cap,
size_t * n_out,
double * volume )

Partial radial distribution.

r is Angstrom. g is dimensionless. volume is cubic Angstrom.

Parameters
sysFrame handle.
rmaxPositive finite outer radius, Angstrom.
binsBin count. Zero selects about rmax / 0.1.
type_iFirst species. Zero and negative keep every atom of a single-species frame, or every atom as one species otherwise.
type_jSecond species. Zero and negative reuse the type_i species.
rBin centers, or NULL to query.
gg(r) per bin, or NULL to query.
countPair count per bin, or NULL to query.
capCapacity of each non-NULL column.
n_outReceives the bin count.
volumeReceives the cell volume, or NULL.
Returns
SEAMS_OK, or SEAMS_ERR_NULL, SEAMS_ERR_STATE, SEAMS_ERR_RANGE, SEAMS_ERR_NOMEM, SEAMS_ERR_INTERNAL.
Handle access
Non-const only because the call clears the handle's error slot on entry, so seams_handle_error() reports this call. It reads the frame and keeps no scratch on the handle.
Ownership
The caller owns the columns.
Thread safety
Exclusive use of sys.
Example
size_t bins = 0;
seams_rdf(sys, 8.0, 80, 0, 0, NULL, NULL, NULL, 0, &bins, NULL);
SEAMS_API seams_status seams_rdf(seams_system *sys, double rmax, int bins, int type_i, int type_j, double *r, double *g, int *count, size_t cap, size_t *n_out, double *volume)
Partial radial distribution.

◆ seams_running_cn()

SEAMS_API seams_status seams_running_cn ( seams_system * sys,
double rmax,
int bins,
int type_i,
int type_j,
double * r,
double * cn,
size_t cap,
size_t * n_out )

Running coordination number along the partial RDF.

Parameters
sysFrame handle.
rmaxPositive finite outer radius, Angstrom.
binsBin count. Zero selects about rmax / 0.1.
type_iCentral species, as in seams_rdf().
type_jCounted species, as in seams_rdf().
rBin centers, Angstrom, or NULL to query.
cnRunning coordination number, or NULL to query.
capCapacity of each non-NULL column.
n_outReceives the bin count.
Returns
SEAMS_OK, or SEAMS_ERR_NULL, SEAMS_ERR_STATE, SEAMS_ERR_RANGE, SEAMS_ERR_NOMEM, SEAMS_ERR_INTERNAL.
Handle access
Non-const only because the call clears the handle's error slot on entry, so seams_handle_error() reports this call. It reads the frame and keeps no scratch on the handle.
Ownership
The caller owns the columns.
Thread safety
Exclusive use of sys.
Example
double r[80], cn[80];
size_t bins = 0;
seams_running_cn(sys, 8.0, 80, 0, 0, r, cn, 80, &bins);
SEAMS_API seams_status seams_running_cn(seams_system *sys, double rmax, int bins, int type_i, int type_j, double *r, double *cn, size_t cap, size_t *n_out)
Running coordination number along the partial RDF.

◆ seams_signature_cages()

SEAMS_API seams_status seams_signature_cages ( seams_system * sys,
double cutoff,
int type,
int graph,
const char * spec,
size_t * n_cages,
size_t * n_atoms )

Closed cages of one ring census.

Same search as seams_cages_signature().

Parameters
sysFrame handle.
cutoffPositive finite cutoff, Angstrom.
typeSpecies filter.
graphSEAMS_GRAPH_CUTOFF or SEAMS_GRAPH_MUTUAL.
specSignature text such as "512" or "hc". Must be non-NULL.
n_cagesReceives the cage count.
n_atomsReceives the vertex count.
Returns
Same codes as seams_cages_signature().
Handle access
Non-const only because the call clears the handle's error slot on entry, so seams_handle_error() reports this call. It reads the frame and keeps no scratch on the handle.
Ownership
The caller owns sys; the call borrows it. spec is read during the call only. n_cages and n_atoms are caller storage that the call fills. The library keeps no pointer to any argument.
Thread safety
Exclusive use of sys.
Example
size_t n_cages = 0, n_atoms = 0;
seams_signature_cages(sys, 3.5, 0, SEAMS_GRAPH_CUTOFF, "hc", &n_cages, &n_atoms);
SEAMS_API seams_status seams_signature_cages(seams_system *sys, double cutoff, int type, int graph, const char *spec, size_t *n_cages, size_t *n_atoms)
Closed cages of one ring census.

◆ seams_signature_cages_edge()

SEAMS_API seams_status seams_signature_cages_edge ( seams_system * sys,
double cutoff,
int type,
int graph,
const char * spec,
const char * edge,
size_t * n_cages,
size_t * n_atoms )

Closed cages of one ring census with an explicit face-edge window.

Same search as seams_signature_cages(). edge NULL or "" keeps the default window 2.65,3.15 in the coordinate units of the file. "none" leaves the cage bound to the face census.

Parameters
sysFrame handle.
cutoffPositive finite cutoff, Angstrom.
typeSpecies filter.
graphSEAMS_GRAPH_CUTOFF or SEAMS_GRAPH_MUTUAL.
specSignature text such as "512" or "hc". Must be non-NULL.
edgeFace-edge window, or NULL. "none" turns the window off.
n_cagesReceives the cage count.
n_atomsReceives the vertex count.
Returns
Same codes as seams_cages_signature().
Handle access
Non-const only because the call clears the handle's error slot on entry, so seams_handle_error() reports this call. It reads the frame and keeps no scratch on the handle.
Ownership
The caller owns sys; the call borrows it. spec and edge are read during the call only. n_cages and n_atoms are caller storage that the call fills. The library keeps no pointer to any argument.
Thread safety
Exclusive use of sys.
Example
size_t n_cages = 0, n_atoms = 0;
seams_signature_cages_edge(sys, 3.5, 0, SEAMS_GRAPH_CUTOFF, "512", "none", &n_cages, &n_atoms);
SEAMS_API seams_status seams_signature_cages_edge(seams_system *sys, double cutoff, int type, int graph, const char *spec, const char *edge, size_t *n_cages, size_t *n_atoms)
Closed cages of one ring census with an explicit face-edge window.

◆ seams_site_table()

SEAMS_API seams_status seams_site_table ( seams_system * sys,
const char * spec,
int * kinds,
size_t len )

Per-atom site kind from a site-table spec.

Parameters
sysFrame handle.
specSite table text such as "1=cationHead,2=anion". Must be non-NULL.
kindsOne seams_site_kind per atom.
lenLength of kinds. Must be at least the frame count.
Returns
SEAMS_OK, or SEAMS_ERR_NULL, SEAMS_ERR_STATE, SEAMS_ERR_RANGE, SEAMS_ERR_ARG, SEAMS_ERR_NOMEM, SEAMS_ERR_INTERNAL.
Handle access
Non-const only because the call clears the handle's error slot on entry, so seams_handle_error() reports this call. It reads the frame and keeps no scratch on the handle.
Ownership
The caller owns kinds.
Thread safety
Exclusive use of sys.
Example
seams_site_table(sys, "1=cationHead,2=anion", kinds, n);
SEAMS_API seams_status seams_site_table(seams_system *sys, const char *spec, int *kinds, size_t len)
Per-atom site kind from a site-table spec.

◆ seams_steinhardt()

SEAMS_API seams_status seams_steinhardt ( seams_system * sys,
double cutoff,
int type,
int order_l,
double * ql,
size_t ql_len,
double * qlbar,
size_t qlbar_len )

Local Steinhardt q_l on the cutoff shell, and the average on request.

This is seams_ql() with the cutoff graph.

Parameters
sysFrame handle.
cutoffPositive finite cutoff, Angstrom.
typeSpecies filter.
order_l3, 4, 6, 8, or 12.
qlLocal q_l, or NULL.
ql_lenLength of ql. Ignored when ql is NULL.
qlbarAveraged q_l, or NULL to skip the Lechner-Dellago average.
qlbar_lenLength of qlbar. Ignored when qlbar is NULL.
Returns
Same codes as seams_ql().
Handle access
Non-const only because the call clears the handle's error slot on entry; it reads the frame and nothing else on the handle. The q_lm work arrays belong to the calling thread, so calls on different handles may run at the same time.
Ownership
The caller owns both arrays.
Thread safety
Exclusive use of sys. Any q call on another handle may run beside it.
Example
seams_steinhardt(sys, 3.5, 0, 6, q6, n, NULL, 0);
SEAMS_API seams_status seams_steinhardt(seams_system *sys, double cutoff, int type, int order_l, double *ql, size_t ql_len, double *qlbar, size_t qlbar_len)
Local Steinhardt q_l on the cutoff shell, and the average on request.