namespace pore#

Overview#

namespace pore {
 
// typedefs
 
typedef molSys::PointCloud<molSys::Point<double>, double> Cloud;
 
// structs
 
struct BoxError;
struct Frame;
struct HostGuest;
struct Profile;
struct Profiles;
 
// global functions
 
Profile fractionalAxis(const Cloud& cloud, int type, int bins, int axis, double origin, const double* masses);
Profile alongDirection(const Cloud& cloud, int type, int bins, const double direction[3], double origin, const double* masses);
Frame poreFrame(const Cloud& cloud, int framework_type, int axis, const double* direction, const double* centre_frac);
Profiles poreProfiles(const Cloud& cloud, int type, int radial_bins, int azimuthal_bins, int axial_bins, double r_max, int axis, const double* direction, const double* centre_frac, int framework_type, double origin, const double* masses);
double clippedDiskArea(const std::vector<std::array<double, 2>>& polygon, double radius, double cover, double full);
HostGuest hostGuest(const Cloud& cloud, int guest_type, int framework_type, double cutoff);
 
} // namespace pore

Detailed Documentation#

Global Functions#

Profile fractionalAxis(const Cloud& cloud, int type, int bins, int axis, double origin, const double* masses)

Fractional density along cell axis 0, 1, or 2. Origin is in [0, 1) after wrapping.

Profile alongDirection(const Cloud& cloud, int type, int bins, const double direction[3], double origin, const double* masses)

Density of the reduced cell projected on a Cartesian direction.

Frame poreFrame(const Cloud& cloud, int framework_type, int axis, const double* direction, const double* centre_frac)

Pore axis and centre. axis -1 and direction == nullptr selects the longest edge. Any other negative axis is rejected. centre_frac == nullptr selects the framework centroid in the perpendicular plane.

Profiles poreProfiles(const Cloud& cloud, int type, int radial_bins, int azimuthal_bins, int axial_bins, double r_max, int axis, const double* direction, const double* centre_frac, int framework_type, double origin, const double* masses)

Radial, azimuthal, and axial profiles. The axis must be a cell edge. r_max of zero covers the perpendicular face. A negative value is rejected. Azimuth zero points along the perpendicular projection of cell edge (axis + 1) mod 3. Masses follow fractionalAxis.

double clippedDiskArea(const std::vector<std::array<double, 2>>& polygon, double radius, double cover, double full)

Area of a convex polygon clipped to the disk of radius centred at the origin. Vertices are an (x, y) ring. A non-positive radius returns 0. Once radius reaches cover, the result is full, which is the polygon’s own area when the disk contains it.

HostGuest hostGuest(const Cloud& cloud, int guest_type, int framework_type, double cutoff)

Nearest framework site and contact counts inside cutoff, one row per guest. framework_type 0 keeps every atom whose type is not guest_type. framework_type equal to guest_type is rejected. distance is negative when the guest has no framework atom.