| 1 |
|
#include <math.h> |
| 2 |
|
#include "OOPSEMinimizer.hpp" |
| 3 |
+ |
#include "ShakeMin.hpp" |
| 4 |
|
|
| 5 |
|
OOPSEMinimizer::OOPSEMinimizer( SimInfo *theInfo, ForceFields* the_ff , |
| 6 |
|
MinimizerParameterSet * param) |
| 18 |
|
curX = getCoor(); |
| 19 |
|
curG.resize(ndim); |
| 20 |
|
|
| 21 |
< |
preMove(); |
| 21 |
> |
//preMove(); |
| 22 |
|
} |
| 23 |
|
|
| 24 |
|
OOPSEMinimizer::~OOPSEMinimizer(){ |
| 41 |
|
|
| 42 |
|
setCoor(x); |
| 43 |
|
|
| 44 |
< |
if (nConstrained && bShake){ |
| 45 |
< |
shakeStatus = shakeR(); |
| 46 |
< |
} |
| 44 |
> |
//if (nConstrained && bShake){ |
| 45 |
> |
// shakeStatus = shakeR(); |
| 46 |
> |
//} |
| 47 |
> |
|
| 48 |
> |
shakeAlgo->doShakeR(); |
| 49 |
|
|
| 50 |
|
calcForce(1, 1); |
| 51 |
|
|
| 52 |
< |
if (nConstrained && bShake){ |
| 53 |
< |
shakeStatus |= shakeF(); |
| 54 |
< |
} |
| 52 |
> |
//if (nConstrained && bShake){ |
| 53 |
> |
// shakeStatus |= shakeF(); |
| 54 |
> |
//} |
| 55 |
> |
|
| 56 |
> |
shakeAlgo->doShakeF(); |
| 57 |
|
|
| 58 |
|
x = getCoor(); |
| 59 |
|
|
| 167 |
|
|
| 168 |
|
} |
| 169 |
|
|
| 170 |
+ |
/* |
| 171 |
|
int OOPSEMinimizer::shakeR(){ |
| 172 |
|
int i, j; |
| 173 |
|
int done; |
| 407 |
|
return 1; |
| 408 |
|
} |
| 409 |
|
|
| 410 |
< |
//calculate the value of object function |
| 410 |
> |
*/ |
| 411 |
> |
|
| 412 |
> |
//calculate the value of object function |
| 413 |
|
void OOPSEMinimizer::calcF(){ |
| 414 |
|
calcEnergyGradient(curX, curG, curF, egEvalStatus); |
| 415 |
|
} |