QPMS
Electromagnetic multiple scattering library and toolkit.
|
Quaternion-represented 3D point groups. More...
Go to the source code of this file.
Functions | |
static _Bool | qpms_pg_is_finite_axial (qpms_pointgroup_class cls) |
Returns true if the point group class belongs to one of the seven "axial" group series. | |
int | qpms_pg_irot3_approx_cmp (const qpms_irot3_t *, const qpms_irot3_t *, double atol) |
An ordering of qpms_irot3_t that considers close enough elements equal. More... | |
int | qpms_pg_irot3_approx_cmp_v (const void *, const void *) |
A search.h compatible ordering of qpms_irot3_t that considers close enough elements equal. More... | |
qpms_gmi_t | qpms_pg_order (qpms_pointgroup_class cls, qpms_gmi_t n) |
Returns the order of a given 3D point group type. More... | |
qpms_irot3_t * | qpms_pg_canonical_elems (qpms_irot3_t *target, qpms_pointgroup_class cls, qpms_gmi_t) |
Generates the canonical elements of a given 3D point group type. More... | |
qpms_gmi_t | qpms_pg_genset_size (qpms_pointgroup_class cls, qpms_gmi_t n) |
Returns the number of canonical generators of a given 3D point group type. More... | |
qpms_gmi_t | qpms_pg_genset (qpms_pointgroup_class cls, qpms_gmi_t n, qpms_irot3_t gen[]) |
Fills an array of canonical generators of a given 3D point group type. More... | |
qpms_irot3_t * | qpms_pg_elems (qpms_irot3_t *target, qpms_pointgroup_t g) |
Generates all elements of a given point group. More... | |
_Bool | qpms_pg_is_subgroup (qpms_pointgroup_t a, qpms_pointgroup_t b) |
Checks whether a is subgroup of b (in a dirty general way). | |
Variables | |
double | qpms_pg_quat_cmp_atol |
Absolute tolerance threshold used internally to consider two different qpms_irot3_t instances equal. More... | |
Quaternion-represented 3D point groups.
qpms_irot3_t* qpms_pg_canonical_elems | ( | qpms_irot3_t * | target, |
qpms_pointgroup_class | cls, | ||
qpms_gmi_t | then | ||
) |
Generates the canonical elements of a given 3D point group type.
Uses the canonical generators and DPS.
target | Target array (optional; if NULL, a new one is allocated) |
cls | Point group class. |
then | Number of rotations around z axis (only for axial group classes). |
qpms_irot3_t* qpms_pg_elems | ( | qpms_irot3_t * | target, |
qpms_pointgroup_t | g | ||
) |
Generates all elements of a given point group.
The order of elements corresponds to the one obtained from qpms_pg_canonical_elems().
target | Target array (optional; if NULL, a new one is allocated) |
g | Specification of the point group. |
qpms_gmi_t qpms_pg_genset | ( | qpms_pointgroup_class | cls, |
qpms_gmi_t | n, | ||
qpms_irot3_t | gen[] | ||
) |
Fills an array of canonical generators of a given 3D point group type.
TODO what does it do for infinite (Lie) groups?
cls | Point group class. |
n | Number of rotations around main axis (only for axial groups). |
gen | Target generator array |
qpms_gmi_t qpms_pg_genset_size | ( | qpms_pointgroup_class | cls, |
qpms_gmi_t | n | ||
) |
Returns the number of canonical generators of a given 3D point group type.
TODO what does it do for infinite (Lie) groups?
cls | Point group class. |
n | Number of rotations around main axis (only for axial groups). |
int qpms_pg_irot3_approx_cmp | ( | const qpms_irot3_t * | p1, |
const qpms_irot3_t * | p2, | ||
double | atol | ||
) |
An ordering of qpms_irot3_t that considers close enough elements equal.
atol | Absolute tolerance for the quaternion part difference. |
int qpms_pg_irot3_approx_cmp_v | ( | const void * | av, |
const void * | bv | ||
) |
A search.h
compatible ordering of qpms_irot3_t that considers close enough elements equal.
The tolerance is determined by global variable qpms_pg_quat_cmp_atol.
qpms_gmi_t qpms_pg_order | ( | qpms_pointgroup_class | cls, |
qpms_gmi_t | n | ||
) |
Returns the order of a given 3D point group type.
For infinite groups returns 0.
cls | Point group class. |
n | Number of rotations around main axis (only for finite axial groups). |
|
extern |
Absolute tolerance threshold used internally to consider two different qpms_irot3_t
instances equal.
Used by qpms_pg_irot3_approx_cmp_v. By default, set to QPMS_QUAT_ATOL. It should work fine if the point group orders stay reasonable (thousands or less). Do not touch if unsure what you are doing.