eabffunc Namespace Reference


Functions

std::string & trim (std::string &s)
void split (const std::string &s, std::vector< std::string > &ret)
int chartoint (const std::string &c)
double chartodouble (const std::string &c)
int doubletoint (const double a)

Variables

const double BOLTZMANN = 0.00198721


Function Documentation

std::string & eabffunc::trim ( std::string &  s  ) 

Definition at line 22 of file eabffunc.C.

00023 {
00024         if (s.empty())
00025         {
00026                 return s;
00027         }
00028 
00029         s.erase(0, s.find_first_not_of(" "));
00030         s.erase(s.find_last_not_of(" ") + 1);
00031         return s;
00032 }

void eabffunc::split ( const std::string &  s,
std::vector< std::string > &  ret 
)

Definition at line 37 of file eabffunc.C.

Referenced by bin_evaluation_1away(), ReductionMgr::buildSpanTree(), Communicate::Communicate(), partition(), Molecule::prepare_qm(), ComputeMsmSerialMgr::recvCoord(), WorkDistrib::saveComputeMap(), WorkDistrib::savePatchMap(), setup_grids(), eABF2D::update(), and eABF1D::update().

00038 {
00039         std::stringstream temp(s);
00040         std::string token;
00041         while (temp >> token)
00042         {
00043                 ret.push_back(token);
00044         }
00045 }

int eabffunc::chartoint ( const std::string &  c  ) 

Definition at line 48 of file eabffunc.C.

Referenced by Tcl_mergefile(), Tcl_setcol(), Tcl_startrun(), eABF2D::update(), and eABF1D::update().

00049 {
00050         std::stringstream temp(c);
00051         int token;
00052         temp >> token;
00053         return token;
00054 }

double eabffunc::chartodouble ( const std::string &  c  ) 

Definition at line 57 of file eabffunc.C.

Referenced by Tcl_mergefile(), Tcl_startrun(), eABF2D::update(), and eABF1D::update().

00058 {
00059         std::stringstream temp(c);
00060         double token;
00061         temp >> token;
00062         return token;
00063 }

int eabffunc::doubletoint ( const double  a  ) 

Definition at line 66 of file eabffunc.C.

Referenced by eABF1D::initialize().

00067 {
00068         if (a > 0)
00069                 return int(a + 0.000001);
00070         else
00071                 return int(a - 0.000001);
00072 }


Variable Documentation

const double eabffunc::BOLTZMANN = 0.00198721

Definition at line 23 of file eabffunc.h.

Referenced by eABF1D::calpmf().


Generated on Thu Nov 23 01:17:20 2017 for NAMD by  doxygen 1.4.7