gen Namespace Reference

Small generic functions that are shared by all namespaces. More...

Functions

double radDeg (double angle)
 
double eigenVecAngle (std::vector< double > OO, std::vector< double > OH)
 Eigen function for getting the angle (in radians) between the O–O and O-H vectors. More...
 
double getAverageWithoutOutliers (std::vector< double > inpVec)
 Get the average, after excluding the outliers, using quartiles. More...
 
double calcMedian (std::vector< double > *input)
 Inline generic function for calculating the median given a vector of the values. More...
 
double periodicDist (molSys::PointCloud< molSys::Point< double >, double > *yCloud, int iatom, int jatom)
 Inline generic function for obtaining the unwrapped periodic distance between two particles, whose indices (not IDs) have been given. More...
 
double unWrappedDistFromPoint (molSys::PointCloud< molSys::Point< double >, double > *yCloud, int iatom, std::vector< double > singlePoint)
 
double distance (molSys::PointCloud< molSys::Point< double >, double > *yCloud, int iatom, int jatom)
 Inline generic function for obtaining the wrapped distance between two particles WITHOUT applying PBCs, whose indices (not IDs) have been given. More...
 
std::array< double, 3 > relDist (molSys::PointCloud< molSys::Point< double >, double > *yCloud, int iatom, int jatom)
 
bool compareByAtomID (const molSys::Point< double > &a, const molSys::Point< double > &b)
 
int prettyPrintYoda (molSys::PointCloud< molSys::Point< double >, double > *yCloud, std::string outFile)
 Generic function for printing all the struct information. More...
 
int unwrappedCoordShift (molSys::PointCloud< molSys::Point< double >, double > *yCloud, int iatomIndex, int jatomIndex, double *x_i, double *y_i, double *z_i, double *x_j, double *y_j, double *z_j)
 Shift particles (unwrapped coordinates) More...
 
double angDistDegQuaternions (std::vector< double > quat1, std::vector< double > quat2)
 
std::vector< std::stringtokenizer (std::string line)
 Function for tokenizing line strings into words (strings) delimited by whitespace. This returns a vector with the words in it. More...
 
std::vector< double > tokenizerDouble (std::string line)
 Function for tokenizing line strings into a vector of doubles. More...
 
std::vector< int > tokenizerInt (std::string line)
 Function for tokenizing line strings into a vector of ints. More...
 
bool file_exists (const std::string &name)
 Function for checking if a file exists or not. More...
 
std::vector< std::complex< double > > avgVector (std::vector< std::complex< double >> v, int l, int neigh)
 
molSys::PointCloud< molSys::Point< double >, double > getPointCloudOneAtomType (molSys::PointCloud< molSys::Point< double >, double > *yCloud, molSys::PointCloud< molSys::Point< double >, double > *outCloud, int atomTypeI, bool isSlice=false, std::array< double, 3 > coordLow=std::array< double, 3 >{0, 0, 0}, std::array< double, 3 > coordHigh=std::array< double, 3 >{0, 0, 0})
 
void moleculesInSingleSlice (molSys::PointCloud< molSys::Point< double >, double > *yCloud, bool clearPreviousSliceSelection=true, std::array< double, 3 > coordLow=std::array< double, 3 >{0, 0, 0}, std::array< double, 3 > coordHigh=std::array< double, 3 >{0, 0, 0})
 
void atomsInSingleSlice (molSys::PointCloud< molSys::Point< double >, double > *yCloud, bool clearPreviousSliceSelection=true, std::array< double, 3 > coordLow=std::array< double, 3 >{0, 0, 0}, std::array< double, 3 > coordHigh=std::array< double, 3 >{0, 0, 0})
 
void setAtomsWithSameMolID (molSys::PointCloud< molSys::Point< double >, double > *yCloud, std::unordered_multimap< int, int > molIDAtomIDmap, int molID, bool inSliceValue=true)
 

Variables

const double pi = boost::math::constants::pi<double>()
 

Detailed Description

Small generic functions that are shared by all namespaces.

These are general functions (eg. for finding the periodic distance) which are required by several namespaces.

Changelog