MCPcopy Create free account
hub / github.com/SINGROUP/dscribe / k3WeightSmooth

Method k3WeightSmooth

dscribe/ext/mbtr.cpp:569–577  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

567}
568
569inline double MBTR::k3WeightSmooth(const int &i, const int &j, const int &k, const vector<vector<double> > &distances, double sharpness, double cutoff)
570{
571 double dist1 = distances[i][j];
572 double dist2 = distances[j][k];
573 double f_ij = 1 + sharpness* pow((dist1/cutoff), (sharpness+1)) - (sharpness+1)* pow((dist1/cutoff), sharpness);
574 double f_jk = 1 + sharpness* pow((dist2/cutoff), (sharpness+1)) - (sharpness+1)* pow((dist2/cutoff), sharpness);
575
576 return f_ij*f_jk;
577}
578
579inline double MBTR::k3WeightUnity(const int &i, const int &j, const int &k, const vector<vector<double> > &distances)
580{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected