ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/FAS/src/fasatom.cpp
(Generate patch)

Comparing trunk/FAS/src/fasatom.cpp (file contents):
Revision 77 by tim, Wed Aug 14 23:27:28 2002 UTC vs.
Revision 81 by tim, Thu Aug 15 22:14:31 2002 UTC

# Line 23 | Line 23 | void TFASAtom::Clear()
23  
24   using namespace std;
25  
26 + /***********************************************************************
27 + * Class TFASAtom
28 + ***********************************************************************/
29   void TFASAtom::Clear()
30   {
31          _index = 0;
32 +  _frameIndex = 0;
33          _atomicNum = 0;
34          _nameIndex = 0;
35          _typeIndex = 0;
# Line 47 | Line 51 | void TFASAtom::Clear()
51          _residue = NULL;
52          _mol = NULL;
53          _model = NULL;
54 <        _bondList.clear();      
55 <        
54 >        _bondList.clear();
55 >
56   }
57  
58 + TFASAtom::TFASAtom()
59 + {
60 +  Clear();
61 + }
62 +
63   TFASAtom::TFASAtom(int index)
64   {
65          Clear();
66          _index = index;
67 +  _frameIndex = (index - 1) * 3;
68   }
69  
70 + TFASAtom::TFASAtom(const TFASAtom &src)
71 + {
72 +
73 + }
74 +
75   TFASAtom::~TFASAtom()
76   {
77 <        
77 >  Clear();
78   }
79  
80 + //
81   unsigned int TFASAtom::GetHvyValence()
82   {
83          unsigned int count;
84          vector<TFASBond *>::iterator i;
85          TFASAtom *atom;
86          count=0;
87 <        
87 >
88          for(atom = BeginNbrAtom(i); atom != NULL; atom = NextNbrAtom(i))
89                  if(!atom->IsHydrogen()) count++;
90 <        
90 >
91          return count;
92   }
93  
94 + //Get Coordinate & Velocity
95 + /*
96 + float TFASAtom::GetRX(int frameNum)
97 + {
98 +  if (_model != NULL)
99 +  {
100 +    return _model->GetRX(_frameIndex, frameNum);
101 +  }
102 +  else
103 +  {
104 +
105 +  }
106 + }
107 +
108 + float TFASAtom::GetRY(int frameNum)
109 + {
110 +  if (_model != NULL)
111 +  {
112 +    return _model->GetRY(_frameIndex+1, frameNum);
113 +  }
114 +  else
115 +  {
116 +
117 +  }
118 +
119 + }
120 +
121 + float TFASAtom::GetRZ(int frameNum)
122 + {
123 +  if (_model != NULL)
124 +  {
125 +    return _model->GetRZ(_frameIndex+2, frameNum);
126 +  }
127 +  else
128 +  {
129 +
130 +  }
131 +
132 + }
133 +
134 + float TFASAtom::GetVX(int frameNum)
135 + {
136 +  if (_model != NULL)
137 +  {
138 +    return _model->GetVX(_frameIndex, frameNum);
139 +  }
140 +  else
141 +  {
142 +
143 +  }
144 +
145 + }
146 +
147 + float TFASAtom::GetVY(int frameNum)
148 + {
149 +  if (_model != NULL)
150 +  {
151 +    return _model->GetVY(_frameIndex+1, frameNum);
152 +  }
153 +  else
154 +  {
155 +
156 +  }
157 +
158 + }
159 +
160 + float TFASAtom::GetVZ(int frameNum)
161 + {
162 +  if (_model != NULL)
163 +  {
164 +    return _model->GetVZ(_frameIndex+2, frameNum);
165 +  }
166 +  else
167 +  {
168 +
169 +  }
170 +
171 + }
172 + */
173   void TFASAtom::AddBond(TFASBond * bond)
174   {
175          if (bond==NULL)
176          {
177 <                
177 >
178          }
179          else
180          {
# Line 224 | Line 319 | bool TFASAtom::IsPhosphateOxygen()
319  
320   bool TFASAtom::IsPhosphateOxygen()
321   {
322 +  if (!IsOxygen()) return false;
323  
324 +
325   }
326  
327   bool TFASAtom::IsSulfateOxygen()

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines