ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/OpenMD/branches/development/src/brains/ForceManager.cpp
(Generate patch)

Comparing branches/development/src/brains/ForceManager.cpp (file contents):
Revision 1469 by gezelter, Mon Jul 19 14:07:59 2010 UTC vs.
Revision 1483 by gezelter, Tue Jul 27 21:17:31 2010 UTC

# Line 62 | Line 62 | namespace OpenMD {
62    
63    ForceManager::ForceManager(SimInfo * info) : info_(info),
64                                                 NBforcesInitialized_(false) {
65 <    std::cerr << __PRETTY_FUNCTION__ << "\n";
66 <    lj_ = new LJ(info_->getForceField());
65 >    lj_ = LJ::Instance();
66 >    lj_->setForceField(info_->getForceField());
67 >
68 >    gb_ = GB::Instance();
69 >    gb_->setForceField(info_->getForceField());
70 >
71 >    eam_ = EAM::Instance();
72 >    eam_->setForceField(info_->getForceField());
73    }
74  
75    void ForceManager::calcForces() {
76      
71    std::cerr << __PRETTY_FUNCTION__ << "\n";
77      if (!info_->isFortranInitialized()) {
78        info_->update();
79      }
80      
76    if (!NBforcesInitialized_) {
77      lj_->initialize();    
78    }
79
81      preCalculation();
82      
83      calcShortRangeInteraction();

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines