54 |
|
SC::SC() : name_("SC"), initialized_(false), forceField_(NULL), |
55 |
|
scRcut_(0.0), np_(3000) {} |
56 |
|
|
57 |
+ |
SC::~SC() { |
58 |
+ |
initialized_ = false; |
59 |
+ |
|
60 |
+ |
map<pair<AtomType*, AtomType*>, SCInteractionData>::iterator it; |
61 |
+ |
for (it = MixingMap.begin(); it != MixingMap.end(); ++it) { |
62 |
+ |
SCInteractionData mixer = (*it).second; |
63 |
+ |
delete mixer.V; |
64 |
+ |
delete mixer.phi; |
65 |
+ |
} |
66 |
+ |
|
67 |
+ |
MixingMap.clear(); |
68 |
+ |
SCMap.clear(); |
69 |
+ |
SClist.clear(); |
70 |
+ |
} |
71 |
+ |
|
72 |
|
RealType SC::getM(AtomType* atomType1, AtomType* atomType2) { |
73 |
|
SuttonChenAdapter sca1 = SuttonChenAdapter(atomType1); |
74 |
|
SuttonChenAdapter sca2 = SuttonChenAdapter(atomType2); |