ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/OOPSE-2.0/test/brains/DirectioanlAtom.cpp
(Generate patch)

Comparing trunk/OOPSE-2.0/test/brains/DirectioanlAtom.cpp (file contents):
Revision 1681 by tim, Sat Oct 23 23:09:46 2004 UTC vs.
Revision 1682 by tim, Thu Oct 28 22:34:01 2004 UTC

# Line 37 | Line 37 | void DirectionalAtom::setI(Mat3x3d& I) {
37  
38   void DirectionalAtom::setI(Mat3x3d& I) {
39      inertiaTensor_ = I;
40 + }
41 +
42 + void DirectionalAtom::setPrevA(const RotMat3x3d& a) {
43 +    (snapshotMan_->getPrevSnapshot())->storage_->aMat[localIndex_] = a;
44 +    (snapshotMan_->getPrevSnapshot())->storage_->unitVector[localIndex_] = a.inverse() * sU_.getColum(2);
45 + }
46 +
47 +      
48 + void DirectionalAtom::setA(const RotMat3x3d& a) {
49 +    (snapshotMan_->getCurrentSnapshot())->storage_->aMat[localIndex_] = a;
50 +    (snapshotMan_->getCurrentSnapshot())->storage_->unitVector[localIndex_] = a.inverse() * sU_.getColum(2);
51   }    
52 +    
53 + void DirectionalAtom::setA(const RotMat3x3d& a, int snapshotNo) {
54 +    (snapshotMan_->getSnapshot(snapshotNo))->storage_->aMat[localIndex_] = a;
55 +    (snapshotMan_->getSnapshot(snapshotNo))->storage_->unitVector[localIndex_] = a.inverse() * sU_.getColum(2);    
56 + }    
57  
58 +
59 +
60 + void  DirectionalAtom::setUnitFrameFromEuler(double phi, double theta, double psi) {
61 +    sU_.setupRotMat(phi,theta,psi);
62 +
63 + }
64 +
65   std::vector<double> DirectionalAtom::getGrad() {
66      vector<double> grad(6, 0.0);
67      Vector3d force;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines