ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/branches/new_design/OOPSE-4/src/types/AtomType.cpp
(Generate patch)

Comparing branches/new_design/OOPSE-4/src/types/AtomType.cpp (file contents):
Revision 1769 by tim, Tue Nov 23 06:03:47 2004 UTC vs.
Revision 1813 by tim, Wed Dec 1 17:38:32 2004 UTC

# Line 7 | Line 7
7   #include "utils/simError.h"
8   #define __C
9   #include "UseTheForce/DarkSide/atype_interface.h"
10 <
11 < name_space oopse {
10 > #include "UseTheForce/DarkSide/lj_interface.h"
11 > #include "UseTheForce/DarkSide/eam_interface.h"
12 > #include "UseTheForce/DarkSide/charge_interface.h"
13 > namespace oopse {
14    AtomType::AtomType(){
15      
16      // initialize to an error:
17 <    atp_.ident = -1;
17 >    atp.ident = -1;
18  
19      // and mass_less:
20      mass_ = 0.0;
21      
22      // atom type is a Tabula Rasa:
23 <    atp_.is_Directional = 0;
24 <    atp_.is_LennardJones = 0;
25 <    atp_.is_Electrostatic = 0;
26 <    atp_.is_Charge = 0;
27 <    atp_.is_Dipole = 0;
28 <    atp_.is_Sticky = 0;
29 <    atp_.is_GayBerne = 0;
30 <    atp_.is_EAM = 0;
31 <    atp_.is_Shape = 0;
32 <    atp_.is_FLARB = 0;  
23 >    atp.is_Directional = 0;
24 >    atp.is_LennardJones = 0;
25 >    atp.is_Electrostatic = 0;
26 >    atp.is_Charge = 0;
27 >    atp.is_Dipole = 0;
28 >    atp.is_Multipole = 0;
29 >    atp.is_Sticky = 0;
30 >    atp.is_GayBerne = 0;
31 >    atp.is_EAM = 0;
32 >    atp.is_Shape = 0;
33 >    atp.is_FLARB = 0;  
34    }
35      
36    void AtomType::makeFortranAtomType() {
# Line 43 | Line 46 | name_space oopse {
46        simError();
47      }
48      
49 <    if (atp_.ident == -1) {
49 >    if (atp.ident == -1) {
50        sprintf( painCave.errMsg,
51                 "Attempting to complete AtomType %s without setting the"
52                 " ident!/n", name_.c_str());
# Line 54 | Line 57 | name_space oopse {
57  
58      status = 0;
59  
60 <    makeAtype(&atp_, &status);  
60 >    makeAtype(&atp, &status);  
61      
62      if (status != 0) {
63        sprintf( painCave.errMsg,
# Line 79 | Line 82 | void AtomType::complete() {
82              if (ljData != NULL) {
83                  LJParam ljParam = ljData->getData();
84                  
85 <                newLJtype(&atp_.ident, &ljParam.sigma, &ljParam.epsilon, &isError);
85 >                newLJtype(&atp.ident, &ljParam.sigma, &ljParam.epsilon, &isError);
86  
87                  if (isError != 0) {
88                      sprintf( painCave.errMsg,
# Line 111 | Line 114 | void AtomType::complete() {
114  
115              if (doubleData != NULL) {
116                  double charge = doubleData->getData();
117 <                newChargeType(&atp_.ident,, &charge, &isError);
117 >                newChargeType(&atp.ident, &charge, &isError);
118  
119                  if (isError != 0) {
120                      sprintf( painCave.errMsg,
# Line 146 | Line 149 | void AtomType::complete() {
149                  
150  
151                  newEAMtype(&eamParam.latticeConstant, &eamParam.nrho, &eamParam.drho,  &eamParam.nr, &eamParam.dr, &eamParam.rcut,
152 <                                &eamParam.rvals[0], &eamParam.rhovals[0], &eamParam.Frhovals[0], &atp_.ident,, &isError );
152 >                                &eamParam.rvals[0], &eamParam.rhovals[0], &eamParam.Frhovals[0], &atp.ident, &isError );
153  
154                  if (isError != 0) {
155                      sprintf( painCave.errMsg,

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines