| 73 | 
  | 
     | 
| 74 | 
  | 
    RealType firstDerivative; | 
| 75 | 
  | 
     | 
| 76 | 
< | 
    bendType_->calcForce(theta, firstDerivative, potential_); | 
| 76 | 
> | 
    bendType_->calcForce(theta, potential_, firstDerivative); | 
| 77 | 
  | 
     | 
| 78 | 
  | 
    RealType sinTheta = sqrt(1.0 - cosTheta * cosTheta); | 
| 79 | 
  | 
     | 
| 89 | 
  | 
    atom1_->addFrc(force1); | 
| 90 | 
  | 
    ghostAtom->addFrc(-force1); | 
| 91 | 
  | 
    /**@todo test correctness */ | 
| 92 | 
< | 
    ghostAtom->addTrq(cross(r32, force3) ); | 
| 93 | 
< | 
     | 
| 92 | 
> | 
    ghostAtom->addTrq(cross(r32, force3) );     | 
| 93 | 
> | 
 | 
| 94 | 
> | 
    atom1_->addParticlePot(potential_); | 
| 95 | 
> | 
    ghostAtom->addParticlePot(potential_); | 
| 96 | 
> | 
 | 
| 97 | 
  | 
    angle = theta /M_PI * 180.0; | 
| 98 | 
  | 
     | 
| 99 | 
  | 
  }   |