| 124 |
|
} |
| 125 |
|
} |
| 126 |
|
|
| 127 |
< |
void MAW::calcForce(InteractionData idat) { |
| 127 |
> |
void MAW::calcForce(InteractionData &idat) { |
| 128 |
|
|
| 129 |
|
if (!initialized_) initialize(); |
| 130 |
|
|
| 220 |
|
RealType Vang = ca1 * x2 / idat.r2 + cb1 * z / idat.rij + (0.8 - ca1 / 3.0); |
| 221 |
|
|
| 222 |
|
RealType pot_temp = idat.vdwMult * Vmorse * Vang; |
| 223 |
< |
idat.vpair += pot_temp; |
| 224 |
< |
idat.pot += idat.sw * pot_temp; |
| 223 |
> |
idat.vpair[0] += pot_temp; |
| 224 |
> |
idat.pot[0] += idat.sw * pot_temp; |
| 225 |
|
|
| 226 |
|
Vector3d dVmorsedr = (myDeriv - myDerivC) * Vector3d(x, y, z) / idat.rij; |
| 227 |
|
|