Changes in src/analysis_bonds.cpp [fe238c:4eb4fe]
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/analysis_bonds.cpp
rfe238c r4eb4fe 51 51 * \param &Max maximum distance on return, 0 if no bond between the two elements 52 52 */ 53 void MinMeanMaxBondDistanceBetweenElements(const molecule *mol, element *type1,element *type2, double &Min, double &Mean, double &Max)53 void MinMeanMaxBondDistanceBetweenElements(const molecule *mol, const element *type1, const element *type2, double &Min, double &Mean, double &Max) 54 54 { 55 55 Min = 2e+6; … … 93 93 Vector OOBond; 94 94 95 OHBond.CopyVector(first); 96 OHBond.SubtractVector(central); 97 OOBond.CopyVector(second); 98 OOBond.SubtractVector(central); 99 const double angle = OHBond.Angle(&OOBond); 95 OHBond = (*first) - (*central); 96 OOBond = (*second) - (*central); 97 const double angle = OHBond.Angle(OOBond); 100 98 return angle; 101 99 }; … … 126 124 * \param *InterfaceElement or NULL 127 125 */ 128 int CountHydrogenBridgeBonds(MoleculeListClass *molecules, element * InterfaceElement = NULL)126 int CountHydrogenBridgeBonds(MoleculeListClass *molecules, const element * InterfaceElement = NULL) 129 127 { 130 128 atom *Walker = NULL; … … 145 143 if ((Walker->type->Z == 8) && (Runner->type->Z == 8)) { 146 144 // check distance 147 const double distance = Runner->x.DistanceSquared( &Walker->x);145 const double distance = Runner->x.DistanceSquared(Walker->x); 148 146 if ((distance > MYEPSILON) && (distance < HBRIDGEDISTANCE*HBRIDGEDISTANCE)) { // distance >0 means different atoms 149 147 // on other atom(Runner) we check for bond to interface element and
Note:
See TracChangeset
for help on using the changeset viewer.