![]() |
ProSHADE
0.7.5.3 (FEB 2021)
Protein Shape Detection
|
This namespace contains all the miscellaneous functions used throughout the code but unrelated to it. More...
Functions | |
void | addToStringVector (std::vector< std::string > *vecToAddTo, std::string elementToAdd) |
Adds the element to the vector. More... | |
void | addToSingleVector (std::vector< proshade_single > *vecToAddTo, proshade_single elementToAdd) |
Adds the element to the vector. More... | |
void | addToDoubleVector (std::vector< proshade_double > *vecToAddTo, proshade_double elementToAdd) |
Adds the element to the vector. More... | |
void | addToUnsignVector (std::vector< proshade_unsign > *vecToAddTo, proshade_unsign elementToAdd) |
Adds the element to the vector. More... | |
void | addToSignedVector (std::vector< proshade_signed > *vecToAddTo, proshade_signed elementToAdd) |
Adds the element to the vector. More... | |
void | addToDblPtrVector (std::vector< proshade_double * > *vecToAddTo, proshade_double *elementToAdd) |
Adds the element to the vector. More... | |
void | addToSigPtrVector (std::vector< proshade_signed * > *vecToAddTo, proshade_signed *elementToAdd) |
Adds the element to the vector. More... | |
void | addToUnsignVectorVector (std::vector< std::vector< proshade_unsign > > *vecToAddTo, std::vector< proshade_unsign > elementToAdd) |
Adds the element to the vector of vectors. More... | |
void | addToDoubleVectorVector (std::vector< std::vector< proshade_double > > *vecToAddTo, std::vector< proshade_double > elementToAdd) |
Adds the element to the vector of vectors. More... | |
bool | sortSymHlp (const proshade_double *a, const proshade_double *b) |
This function compares two arrays of two based on the fifth number, sorting lowest first. More... | |
bool | sortSymHlpInv (const proshade_double *a, const proshade_double *b) |
This function compares two arrays of two based on the fifth number, sorting highest first. More... | |
bool | sortDSymHlpInv (const proshade_double *a, const proshade_double *b) |
This function compares two arrays of the ProSHADE dihedral symmetry list based on combination of axes folds and heightst. More... | |
bool | sortSymInvFoldHlp (const proshade_double *a, const proshade_double *b) |
This function compares two arrays of two based on the first number, sorting highest first. More... | |
void | deepCopyAxisToDblPtrVector (std::vector< proshade_double * > *dblPtrVec, proshade_double *axis) |
Does a deep copy of a double array to a vector of double arrays. More... | |
void | deepCopyBoundsSigPtrVector (std::vector< proshade_signed * > *sigPtrVec, proshade_signed *xFrom, proshade_signed *xTo, proshade_signed *yFrom, proshade_signed *yTo, proshade_signed *zFrom, proshade_signed *zTo) |
Does a deep copy of a signed int array to a vector of signed int arrays. More... | |
template<class chVar > | |
void | checkMemoryAllocation (chVar checkVar, std::string fileP, unsigned int lineP, std::string funcP, std::string infoP="This error may occurs when ProSHADE requests memory to be\n : allocated to it and this operation fails. This could\n : happen when not enough memory is available, either due to\n : other processes using a lot of memory, or when the machine\n : does not have sufficient memory available. Re-run to see\n : if this problem persists.") |
Checks if memory was allocated properly. More... | |
This namespace contains all the miscellaneous functions used throughout the code but unrelated to it.
The ProSHADE_internal_misc namespace contains all the functions which are useful, but not really related to shape description or data processing.
void ProSHADE_internal_misc::addToDblPtrVector | ( | std::vector< proshade_double * > * | vecToAddTo, |
proshade_double * | elementToAdd | ||
) |
Adds the element to the vector.
This function takes a pointer to a vector of complex<double> and a single complex<double> element and adds this element to the end of the vector. The reason for this function is to make vector elongation C++ standard independent (push_back vs. emplace_back)
[in] | vecToAddTo | Pointer to vector of complex<double>'s which should be elongated. |
[in] | elementToAdd | complex<double> to be added to the back of the vector. |
Definition at line 143 of file ProSHADE_misc.cpp.
void ProSHADE_internal_misc::addToDoubleVector | ( | std::vector< proshade_double > * | vecToAddTo, |
proshade_double | elementToAdd | ||
) |
Adds the element to the vector.
This function takes a pointer to a vector of proshade_double and a single proshade_double element and adds this element to the end of the vector. The reason for this function is to make vector elongation C++ standard independent (push_back vs. emplace_back)
[in] | vecToAddTo | Pointer to vector of proshade_double's which should be elongated. |
[in] | elementToAdd | proshade_double to be added to the back of the vector. |
Definition at line 77 of file ProSHADE_misc.cpp.
void ProSHADE_internal_misc::addToDoubleVectorVector | ( | std::vector< std::vector< proshade_double > > * | vecToAddTo, |
std::vector< proshade_double > | elementToAdd | ||
) |
Adds the element to the vector of vectors.
This function takes a pointer to a vector of vectors of doubles and a single vector of doubles and adds this element to the end of the vector of vectors. The reason for this function is to make vector elongation C++ standard independent (push_back vs. emplace_back)
[in] | vecToAddTo | Pointer to vector of vectors of doubles which should be elongated. |
[in] | elementToAdd | vector of doubles to be added to the back of the vector. |
Definition at line 210 of file ProSHADE_misc.cpp.
void ProSHADE_internal_misc::addToSignedVector | ( | std::vector< proshade_signed > * | vecToAddTo, |
proshade_signed | elementToAdd | ||
) |
Adds the element to the vector.
This function takes a pointer to a vector of proshade_signed and a single proshade_signed element and adds this element to the end of the vector. The reason for this function is to make vector elongation C++ standard independent (push_back vs. emplace_back)
[in] | vecToAddTo | Pointer to vector of proshade_signed's which should be elongated. |
[in] | elementToAdd | proshade_signed to be added to the back of the vector. |
Definition at line 121 of file ProSHADE_misc.cpp.
void ProSHADE_internal_misc::addToSigPtrVector | ( | std::vector< proshade_signed * > * | vecToAddTo, |
proshade_signed * | elementToAdd | ||
) |
Adds the element to the vector.
This function takes a pointer to a vector of proshade_signed pointers and a single proshade_signed pointer and adds this element to the end of the vector. The reason for this function is to make vector elongation C++ standard independent (push_back vs. emplace_back)
[in] | vecToAddTo | Pointer to vector of complex<double>'s which should be elongated. |
[in] | elementToAdd | complex<double> to be added to the back of the vector. |
Definition at line 166 of file ProSHADE_misc.cpp.
void ProSHADE_internal_misc::addToSingleVector | ( | std::vector< proshade_single > * | vecToAddTo, |
proshade_single | elementToAdd | ||
) |
Adds the element to the vector.
This function takes a pointer to a vector of proshade_single and a single proshade_single element and adds this element to the end of the vector. The reason for this function is to make vector elongation C++ standard independent (push_back vs. emplace_back)
[in] | vecToAddTo | Pointer to vector of proshade_single's which should be elongated. |
[in] | elementToAdd | proshade_single to be added to the back of the vector. |
Definition at line 55 of file ProSHADE_misc.cpp.
void ProSHADE_internal_misc::addToStringVector | ( | std::vector< std::string > * | vecToAddTo, |
std::string | elementToAdd | ||
) |
Adds the element to the vector.
This function takes a pointer to a vector of strings and a single string element and adds this element to the end of the vector. The reason for this function is to make vector elongation C++ standard independent (push_back vs. emplace_back)
[in] | vecToAddTo | Pointer to vector of strings which should be elongated. |
[in] | elementToAdd | String to be added to the back of the vector. |
Definition at line 33 of file ProSHADE_misc.cpp.
void ProSHADE_internal_misc::addToUnsignVector | ( | std::vector< proshade_unsign > * | vecToAddTo, |
proshade_unsign | elementToAdd | ||
) |
Adds the element to the vector.
This function takes a pointer to a vector of proshade_unsign and a single proshade_unsign element and adds this element to the end of the vector. The reason for this function is to make vector elongation C++ standard independent (push_back vs. emplace_back)
[in] | vecToAddTo | Pointer to vector of proshade_unsign's which should be elongated. |
[in] | elementToAdd | proshade_unsign to be added to the back of the vector. |
Definition at line 99 of file ProSHADE_misc.cpp.
void ProSHADE_internal_misc::addToUnsignVectorVector | ( | std::vector< std::vector< proshade_unsign > > * | vecToAddTo, |
std::vector< proshade_unsign > | elementToAdd | ||
) |
Adds the element to the vector of vectors.
This function takes a pointer to a vector of vectors of unsigns and a single vector of unsigns adds this element to the end of the vector of vectors. The reason for this function is to make vector elongation C++ standard independent (push_back vs. emplace_back)
[in] | vecToAddTo | Pointer to vector of vectors of unsigns which should be elongated. |
[in] | elementToAdd | vector of unsigns to be added to the back of the vector. |
Definition at line 188 of file ProSHADE_misc.cpp.
|
inline |
Checks if memory was allocated properly.
This function checks if the memory allocation has suceeded for a given pointer, printing error message if not.
[in] | checkVar | Pointer to be checked. |
Definition at line 65 of file ProSHADE_misc.hpp.
void ProSHADE_internal_misc::deepCopyAxisToDblPtrVector | ( | std::vector< proshade_double * > * | dblPtrVec, |
proshade_double * | axis | ||
) |
Does a deep copy of a double array to a vector of double arrays.
This function deep copies a single symmetry axis ( proshade_double[6] ) into a vector of such arrays.
[in] | dblPtrVec | Pointer to vector of proshade_double arrays to which the second argument is to be deep copied. |
[in] | axis | The proshade_double array to be copied to the first argument. |
Definition at line 287 of file ProSHADE_misc.cpp.
void ProSHADE_internal_misc::deepCopyBoundsSigPtrVector | ( | std::vector< proshade_signed * > * | sigPtrVec, |
proshade_signed * | xFrom, | ||
proshade_signed * | xTo, | ||
proshade_signed * | yFrom, | ||
proshade_signed * | yTo, | ||
proshade_signed * | zFrom, | ||
proshade_signed * | zTo | ||
) |
Does a deep copy of a signed int array to a vector of signed int arrays.
This function deep copies a single bounds array ( proshade_signed[6] ) into a vector of such arrays.
[in] | sigPtrVec | Pointer to vector of proshade_signed arrays to which the second argument is to be deep copied. |
[in] | xFrom | Pointer to the index value from which the x dimension start. |
[in] | xTo | Pointer to the index value to which the x dimensions runs. |
[in] | yFrom | Pointer to the index value from which the y dimension start. |
[in] | yTo | Pointer to the index value to which the y dimensions runs. |
[in] | zFrom | Pointer to the index value from which the z dimension start. |
[in] | zTo | Pointer to the index value to which the z dimensions runs. |
Definition at line 323 of file ProSHADE_misc.cpp.
bool ProSHADE_internal_misc::sortDSymHlpInv | ( | const proshade_double * | a, |
const proshade_double * | b | ||
) |
This function compares two arrays of the ProSHADE dihedral symmetry list based on combination of axes folds and heightst.
[in] | a | The first array to compare. |
[in] | b | The second array to compare. |
[out] | X | Boolean whether the first is smaller than the second. |
Definition at line 256 of file ProSHADE_misc.cpp.
bool ProSHADE_internal_misc::sortSymHlp | ( | const proshade_double * | a, |
const proshade_double * | b | ||
) |
This function compares two arrays of two based on the fifth number, sorting lowest first.
[in] | a | The first array to compare. |
[in] | b | The second array to compare. |
[out] | X | Boolean whether the first is smaller than the second. |
Definition at line 230 of file ProSHADE_misc.cpp.
bool ProSHADE_internal_misc::sortSymHlpInv | ( | const proshade_double * | a, |
const proshade_double * | b | ||
) |
This function compares two arrays of two based on the fifth number, sorting highest first.
[in] | a | The first array to compare. |
[in] | b | The second array to compare. |
[out] | X | Boolean whether the first is smaller than the second. |
Definition at line 243 of file ProSHADE_misc.cpp.
bool ProSHADE_internal_misc::sortSymInvFoldHlp | ( | const proshade_double * | a, |
const proshade_double * | b | ||
) |
This function compares two arrays of two based on the first number, sorting highest first.
[in] | a | The first array to compare. |
[in] | b | The second array to compare. |
[out] | X | Boolean whether the first is smaller than the second. |
Definition at line 273 of file ProSHADE_misc.cpp.