• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

Commit MetaInfo

Revisão818049e2c3a2f9916288eb9a3e3fe386515d3b8c (tree)
Hora2014-01-04 17:51:32
AutorMikiya Fujii <mikiya.fujii@gmai...>
CommiterMikiya Fujii

Mensagem de Log

Some methods which are not used actually is modified. #32750

git-svn-id: https://svn.sourceforge.jp/svnroot/molds/trunk@1610 1136aad2-a195-0410-b898-f5ea1d11b9d8

Mudança Sumário

Diff

--- a/src/am1/Am1.cpp
+++ b/src/am1/Am1.cpp
@@ -164,19 +164,16 @@ double Am1::GetDiatomCoreRepulsionEnergy(const Atom& atomA, const Atom& atomB) c
164164
165165 // First derivative of diatomic core repulsion energy.
166166 // This derivative is related to the coordinate of atomA.
167-double Am1::GetDiatomCoreRepulsion1stDerivative(int indexAtomA,
168- int indexAtomB,
169- CartesianType axisA) const{
167+double Am1::GetDiatomCoreRepulsion1stDerivative(const Atom& atomA, const Atom& atomB,
168+ CartesianType axisA) const{
170169 // MNDO term
171- double mndoTerms = Mndo::GetDiatomCoreRepulsion1stDerivative(indexAtomA, indexAtomB, axisA);
170+ double mndoTerms = Mndo::GetDiatomCoreRepulsion1stDerivative(atomA, atomB, axisA);
172171
173172 // additional term, first derivative of eq. (4) in [S_1989]
174173 double ang2AU = Parameters::GetInstance()->GetAngstrom2AU();
175- const Atom& atomA = *this->molecule->GetAtomVect()[indexAtomA];
176- const Atom& atomB = *this->molecule->GetAtomVect()[indexAtomB];
177174 double alphaA = atomA.GetNddoAlpha(this->theory);
178175 double alphaB = atomB.GetNddoAlpha(this->theory);
179- double distance = this->molecule->GetDistanceAtoms(indexAtomA, indexAtomB);
176+ double distance = this->molecule->GetDistanceAtoms(atomA, atomB);
180177 double dCartesian = (atomA.GetXyz()[axisA] - atomB.GetXyz()[axisA]);
181178 double kA, lA, mA;
182179 double kB, lB, mB;
@@ -204,20 +201,18 @@ double Am1::GetDiatomCoreRepulsion1stDerivative(int indexAtomA,
204201
205202 // Second derivative of diatomic core repulsion energy.
206203 // Both derivatives are related to the coordinate of atomA.
207-double Am1::GetDiatomCoreRepulsion2ndDerivative(int indexAtomA,
208- int indexAtomB,
209- CartesianType axisA1,
210- CartesianType axisA2) const{
204+double Am1::GetDiatomCoreRepulsion2ndDerivative(const Atom& atomA,
205+ const Atom& atomB,
206+ CartesianType axisA1,
207+ CartesianType axisA2) const{
211208 // MNDO term
212- double mndoTerm = Mndo::GetDiatomCoreRepulsion2ndDerivative(indexAtomA, indexAtomB, axisA1, axisA2);
209+ double mndoTerm = Mndo::GetDiatomCoreRepulsion2ndDerivative(atomA, atomB, axisA1, axisA2);
213210
214211 // additional term, first derivative of eq. (4) in [S_1989]
215212 double ang2AU = Parameters::GetInstance()->GetAngstrom2AU();
216- const Atom& atomA = *this->molecule->GetAtomVect()[indexAtomA];
217- const Atom& atomB = *this->molecule->GetAtomVect()[indexAtomB];
218213 double alphaA = atomA.GetNddoAlpha(this->theory);
219214 double alphaB = atomB.GetNddoAlpha(this->theory);
220- double distance = this->molecule->GetDistanceAtoms(indexAtomA, indexAtomB);
215+ double distance = this->molecule->GetDistanceAtoms(atomA, atomB);
221216 double kA, lA, mA;
222217 double kB, lB, mB;
223218 double temp1 = 0.0;
--- a/src/am1/Am1.h
+++ b/src/am1/Am1.h
@@ -34,11 +34,11 @@ protected:
3434 virtual void CalcSCFProperties();
3535 virtual double GetDiatomCoreRepulsionEnergy(const MolDS_base_atoms::Atom& atomA,
3636 const MolDS_base_atoms::Atom& atomB) const;
37- virtual double GetDiatomCoreRepulsion1stDerivative(int indexAtomA,
38- int indexAtomB,
37+ virtual double GetDiatomCoreRepulsion1stDerivative(const MolDS_base_atoms::Atom& atomA,
38+ const MolDS_base_atoms::Atom& atomB,
3939 MolDS_base::CartesianType axisA) const;
40- virtual double GetDiatomCoreRepulsion2ndDerivative(int indexAtomA,
41- int indexAtomB,
40+ virtual double GetDiatomCoreRepulsion2ndDerivative(const MolDS_base_atoms::Atom& atomA,
41+ const MolDS_base_atoms::Atom& atomB,
4242 MolDS_base::CartesianType axisA1,
4343 MolDS_base::CartesianType axisA2) const;
4444 private:
--- a/src/cndo/Cndo2.cpp
+++ b/src/cndo/Cndo2.cpp
@@ -382,12 +382,10 @@ double Cndo2::GetAtomCoreEpcCoulombEnergy(const Atom& atom, const Atom& epc) con
382382
383383 // First derivative of diatomic core repulsion energy.
384384 // This derivative is related to the coordinate of atomA.
385-double Cndo2::GetDiatomCoreRepulsion1stDerivative(int indexAtomA, int indexAtomB,
385+double Cndo2::GetDiatomCoreRepulsion1stDerivative(const Atom& atomA, const Atom& atomB,
386386 CartesianType axisA) const{
387387 double value=0.0;
388- const Atom& atomA = *this->molecule->GetAtomVect()[indexAtomA];
389- const Atom& atomB = *this->molecule->GetAtomVect()[indexAtomB];
390- double distance = this->molecule->GetDistanceAtoms(indexAtomA, indexAtomB);
388+ double distance = this->molecule->GetDistanceAtoms(atomA, atomB);
391389 value = atomA.GetCoreCharge()*atomB.GetCoreCharge();
392390 value *= (atomA.GetXyz()[axisA] - atomB.GetXyz()[axisA])/distance;
393391 value *= -1.0/(distance*distance);
@@ -396,8 +394,8 @@ double Cndo2::GetDiatomCoreRepulsion1stDerivative(int indexAtomA, int indexAtomB
396394
397395 // Second derivative of diatomic core repulsion energy.
398396 // Both derivatives are related to the coordinate of atomA.
399-double Cndo2::GetDiatomCoreRepulsion2ndDerivative(int indexAtomA,
400- int indexAtomB,
397+double Cndo2::GetDiatomCoreRepulsion2ndDerivative(const Atom& atomA,
398+ const Atom& atomB,
401399 CartesianType axisA1,
402400 CartesianType axisA2) const{
403401 stringstream ss;
@@ -409,10 +407,10 @@ double Cndo2::GetDiatomCoreRepulsion2ndDerivative(int indexAtomA,
409407 void Cndo2::CalcVdWCorrectionEnergy(){
410408 double value = 0.0;
411409 for(int i=0; i<this->molecule->GetRealAtomVect().size(); i++){
412- const int indexAtomI = this->molecule->GetRealAtomVect()[i]->GetIndex();
410+ const Atom& atomI = *this->molecule->GetAtomVect()[i];
413411 for(int j=i+1; j<this->molecule->GetRealAtomVect().size(); j++){
414- const int indexAtomJ = this->molecule->GetRealAtomVect()[j]->GetIndex();
415- value += this->GetDiatomVdWCorrectionEnergy(indexAtomI, indexAtomJ);
412+ const Atom& atomJ = *this->molecule->GetAtomVect()[j];
413+ value += this->GetDiatomVdWCorrectionEnergy(atomI, atomJ);
416414 }
417415 }
418416 this->vdWCorrectionEnergy = value;
@@ -444,10 +442,8 @@ double Cndo2::GetVdwDampingValue2ndDerivative(double vdWDistance, double distanc
444442 }
445443
446444 // See (2) in [G_2004] ((11) in [G_2006])
447-double Cndo2::GetDiatomVdWCorrectionEnergy(int indexAtomA, int indexAtomB) const{
448- const Atom& atomA = *this->molecule->GetAtomVect()[indexAtomA];
449- const Atom& atomB = *this->molecule->GetAtomVect()[indexAtomB];
450- double distance = this->molecule->GetDistanceAtoms(indexAtomA, indexAtomB);
445+double Cndo2::GetDiatomVdWCorrectionEnergy(const Atom& atomA, const Atom& atomB) const{
446+ double distance = this->molecule->GetDistanceAtoms(atomA, atomB);
451447 double vdWDistance = atomA.GetVdWRadii() + atomB.GetVdWRadii();
452448 double tmpSum = atomA.GetVdWCoefficient()+atomB.GetVdWCoefficient();
453449 if(tmpSum<=0e0){return 0e0;}
@@ -460,11 +456,9 @@ double Cndo2::GetDiatomVdWCorrectionEnergy(int indexAtomA, int indexAtomB) const
460456
461457 // First derivative of the vdW correction related to the coordinate of atom A.
462458 // See (2) in [G_2004] ((11) in [G_2006]).
463-double Cndo2::GetDiatomVdWCorrection1stDerivative(int indexAtomA, int indexAtomB,
459+double Cndo2::GetDiatomVdWCorrection1stDerivative(const Atom& atomA, const Atom& atomB,
464460 CartesianType axisA) const{
465- const Atom& atomA = *this->molecule->GetAtomVect()[indexAtomA];
466- const Atom& atomB = *this->molecule->GetAtomVect()[indexAtomB];
467- double distance = this->molecule->GetDistanceAtoms(indexAtomA, indexAtomB);
461+ double distance = this->molecule->GetDistanceAtoms(atomA, atomB);
468462 double vdWDistance = atomA.GetVdWRadii() + atomB.GetVdWRadii();
469463 double tmpSum = atomA.GetVdWCoefficient()+atomB.GetVdWCoefficient();
470464 if(tmpSum<=0e0){return 0e0;}
@@ -485,13 +479,11 @@ double Cndo2::GetDiatomVdWCorrection1stDerivative(int indexAtomA, int indexAtomB
485479 // Second derivative of the vdW correction.
486480 // Both derivative sare related to the coordinate of atom A.
487481 // See (2) in [G_2004] ((11) in [G_2006]).
488-double Cndo2::GetDiatomVdWCorrection2ndDerivative(int indexAtomA,
489- int indexAtomB,
490- CartesianType axisA1,
491- CartesianType axisA2) const{
492- const Atom& atomA = *this->molecule->GetAtomVect()[indexAtomA];
493- const Atom& atomB = *this->molecule->GetAtomVect()[indexAtomB];
494- double distance = this->molecule->GetDistanceAtoms(indexAtomA, indexAtomB);
482+double Cndo2::GetDiatomVdWCorrection2ndDerivative(const Atom& atomA,
483+ const Atom& atomB,
484+ CartesianType axisA1,
485+ CartesianType axisA2) const{
486+ double distance = this->molecule->GetDistanceAtoms(atomA, atomB);
495487 double dCartesian1 = atomA.GetXyz()[axisA1] - atomB.GetXyz()[axisA1];
496488 double dCartesian2 = atomA.GetXyz()[axisA2] - atomB.GetXyz()[axisA2];
497489 double vdWDistance = atomA.GetVdWRadii() + atomB.GetVdWRadii();
--- a/src/cndo/Cndo2.h
+++ b/src/cndo/Cndo2.h
@@ -136,19 +136,20 @@ protected:
136136 const MolDS_base_atoms::Atom& epc) const;
137137 virtual double GetDiatomCoreRepulsionEnergy(const MolDS_base_atoms::Atom& atomA,
138138 const MolDS_base_atoms::Atom& atomB) const;
139- virtual double GetDiatomCoreRepulsion1stDerivative(int indexAtomA,
140- int indexAtomB,
139+ virtual double GetDiatomCoreRepulsion1stDerivative(const MolDS_base_atoms::Atom& atomA,
140+ const MolDS_base_atoms::Atom& atomB,
141141 MolDS_base::CartesianType axisA) const;
142- virtual double GetDiatomCoreRepulsion2ndDerivative(int indexAtomA,
143- int indexAtomB,
142+ virtual double GetDiatomCoreRepulsion2ndDerivative(const MolDS_base_atoms::Atom& atomA,
143+ const MolDS_base_atoms::Atom& atomB,
144144 MolDS_base::CartesianType axisA1,
145145 MolDS_base::CartesianType axisA2) const;
146- virtual double GetDiatomVdWCorrectionEnergy(int indexAtomA, int indexAtomB) const;
147- virtual double GetDiatomVdWCorrection1stDerivative(int indexAtomA,
148- int indexAtomB,
146+ virtual double GetDiatomVdWCorrectionEnergy(const MolDS_base_atoms::Atom& atomA,
147+ const MolDS_base_atoms::Atom& atomB) const;
148+ virtual double GetDiatomVdWCorrection1stDerivative(const MolDS_base_atoms::Atom& atomA,
149+ const MolDS_base_atoms::Atom& atomB,
149150 MolDS_base::CartesianType axisA) const;
150- virtual double GetDiatomVdWCorrection2ndDerivative(int indexAtomA,
151- int indexAtomB,
151+ virtual double GetDiatomVdWCorrection2ndDerivative(const MolDS_base_atoms::Atom& atomA,
152+ const MolDS_base_atoms::Atom& atomB,
152153 MolDS_base::CartesianType axisA1,
153154 MolDS_base::CartesianType axisA2) const;
154155 double GetReducedOverlapAOs (int na, int nb, double alpha, double beta) const;
--- a/src/mndo/Mndo.cpp
+++ b/src/mndo/Mndo.cpp
@@ -331,14 +331,11 @@ double Mndo::GetAtomCoreEpcCoulombEnergy(const Atom& atom, const Atom& epc) cons
331331
332332 // First derivative of diatomic core repulsion energy.
333333 // This derivative is related to the coordinate of atomA.
334-double Mndo::GetDiatomCoreRepulsion1stDerivative(int indexAtomA,
335- int indexAtomB,
334+double Mndo::GetDiatomCoreRepulsion1stDerivative(const Atom& atomA, const Atom& atomB,
336335 CartesianType axisA) const{
337336 double value =0.0;
338- const Atom& atomA = *this->molecule->GetAtomVect()[indexAtomA];
339- const Atom& atomB = *this->molecule->GetAtomVect()[indexAtomB];
340- double distanceAB = this->molecule->GetDistanceAtoms(indexAtomA, indexAtomB);
341- double twoElecInt = this->twoElecsTwoAtomCores[indexAtomA][indexAtomB][s][s][s][s];
337+ double distanceAB = this->molecule->GetDistanceAtoms(atomA, atomB);
338+ double twoElecInt = this->twoElecsTwoAtomCores[atomA.GetIndex()][atomB.GetIndex()][s][s][s][s];
342339 double twoElecInt1stDeriv = this->GetNddoRepulsionIntegral1stDerivative(
343340 atomA, s, s, atomB, s, s, axisA);
344341 double tmp = this->GetAuxiliaryDiatomCoreRepulsionEnergy(atomA, atomB, distanceAB);
@@ -350,15 +347,13 @@ double Mndo::GetDiatomCoreRepulsion1stDerivative(int indexAtomA,
350347
351348 // Second derivative of diatomic core repulsion energy.
352349 // Both derivatives are related to the coordinate of atomA.
353-double Mndo::GetDiatomCoreRepulsion2ndDerivative(int indexAtomA,
354- int indexAtomB,
355- CartesianType axisA1,
356- CartesianType axisA2) const{
350+double Mndo::GetDiatomCoreRepulsion2ndDerivative(const Atom& atomA,
351+ const Atom& atomB,
352+ CartesianType axisA1,
353+ CartesianType axisA2) const{
357354 double value =0.0;
358- const Atom& atomA = *this->molecule->GetAtomVect()[indexAtomA];
359- const Atom& atomB = *this->molecule->GetAtomVect()[indexAtomB];
360- double distanceAB = this->molecule->GetDistanceAtoms(indexAtomA, indexAtomB);
361- double twoElecInt = this->twoElecsTwoAtomCores[indexAtomA][indexAtomB][s][s][s][s];
355+ double distanceAB = this->molecule->GetDistanceAtoms(atomA, atomB);
356+ double twoElecInt = this->twoElecsTwoAtomCores[atomA.GetIndex()][atomB.GetIndex()][s][s][s][s];
362357 double twoElecInt1stDeriv1 = this->GetNddoRepulsionIntegral1stDerivative(atomA, s, s,
363358 atomB, s, s,
364359 axisA1);
@@ -1595,14 +1590,14 @@ double Mndo::GetHessianElementSameAtomsSCF(int indexAtomA,
15951590 }
15961591
15971592 // second derivatives of the nuclear repulsions
1598- value += this->GetDiatomCoreRepulsion2ndDerivative(indexAtomA,
1599- indexAtomC,
1593+ value += this->GetDiatomCoreRepulsion2ndDerivative(atomA,
1594+ atomC,
16001595 static_cast<CartesianType>(axisA1),
16011596 static_cast<CartesianType>(axisA2));
16021597 // second derivatives of the van der waals corrections
16031598 if(Parameters::GetInstance()->RequiresVdWSCF()){
1604- value += this->GetDiatomVdWCorrection2ndDerivative(indexAtomA,
1605- indexAtomC,
1599+ value += this->GetDiatomVdWCorrection2ndDerivative(atomA,
1600+ atomC,
16061601 static_cast<CartesianType>(axisA1),
16071602 static_cast<CartesianType>(axisA2));
16081603 }
@@ -1759,14 +1754,14 @@ double Mndo::GetHessianElementDifferentAtomsSCF(int indexAtomA,
17591754 }
17601755
17611756 // second derivatives of the nuclear repulsions
1762- value -= this->GetDiatomCoreRepulsion2ndDerivative(indexAtomA,
1763- indexAtomB,
1757+ value -= this->GetDiatomCoreRepulsion2ndDerivative(atomA,
1758+ atomB,
17641759 static_cast<CartesianType>(axisA),
17651760 static_cast<CartesianType>(axisB));
17661761 // second derivatives of the van der waals corrections
17671762 if(Parameters::GetInstance()->RequiresVdWSCF()){
1768- value -= this->GetDiatomVdWCorrection2ndDerivative(indexAtomA,
1769- indexAtomB,
1763+ value -= this->GetDiatomVdWCorrection2ndDerivative(atomA,
1764+ atomB,
17701765 static_cast<CartesianType>(axisA),
17711766 static_cast<CartesianType>(axisB));
17721767 }
@@ -2723,10 +2718,10 @@ void Mndo::CalcForce(const vector<int>& elecStates){
27232718 double coreRepulsion[CartesianType_end] = {0.0,0.0,0.0};
27242719 for(int i=0; i<CartesianType_end; i++){
27252720 coreRepulsion[i] += this->GetDiatomCoreRepulsion1stDerivative(
2726- a, b, (CartesianType)i);
2721+ atomA, atomB, (CartesianType)i);
27272722 if(Parameters::GetInstance()->RequiresVdWSCF()){
27282723 coreRepulsion[i] += this->GetDiatomVdWCorrection1stDerivative(
2729- a, b, (CartesianType)i);
2724+ atomA, atomB, (CartesianType)i);
27302725 }
27312726 }
27322727 // electron core attraction part (ground state)
--- a/src/mndo/Mndo.h
+++ b/src/mndo/Mndo.h
@@ -56,11 +56,11 @@ protected:
5656 const MolDS_base_atoms::Atom& epc) const;
5757 virtual double GetDiatomCoreRepulsionEnergy(const MolDS_base_atoms::Atom& atomA,
5858 const MolDS_base_atoms::Atom& atomB) const;
59- virtual double GetDiatomCoreRepulsion1stDerivative(int indexAtomA,
60- int indexAtomB,
59+ virtual double GetDiatomCoreRepulsion1stDerivative(const MolDS_base_atoms::Atom& atomA,
60+ const MolDS_base_atoms::Atom& atomB,
6161 MolDS_base::CartesianType axisA) const;
62- virtual double GetDiatomCoreRepulsion2ndDerivative(int indexAtomA,
63- int indexAtomB,
62+ virtual double GetDiatomCoreRepulsion2ndDerivative(const MolDS_base_atoms::Atom& atomA,
63+ const MolDS_base_atoms::Atom& atomB,
6464 MolDS_base::CartesianType axisA1,
6565 MolDS_base::CartesianType axisA2) const;
6666 virtual double GetFockDiagElement(const MolDS_base_atoms::Atom& atomA,
--- a/src/pm3/Pm3Pddg.cpp
+++ b/src/pm3/Pm3Pddg.cpp
@@ -163,18 +163,15 @@ double Pm3Pddg::GetDiatomCoreRepulsionEnergy(const Atom& atomA, const Atom& atom
163163
164164 // First derivative of diatomic core repulsion energy.
165165 // This derivative is related to the coordinate of atomA.
166-double Pm3Pddg::GetDiatomCoreRepulsion1stDerivative(int indexAtomA,
167- int indexAtomB,
166+double Pm3Pddg::GetDiatomCoreRepulsion1stDerivative(const Atom& atomA, const Atom& atomB,
168167 CartesianType axisA) const{
169168 // PM3 term
170- double pm3Term = Pm3::GetDiatomCoreRepulsion1stDerivative(indexAtomA, indexAtomB, axisA);
169+ double pm3Term = Pm3::GetDiatomCoreRepulsion1stDerivative(atomA, atomB, axisA);
171170
172171 // pddg additional term, first derivative of eq. (4) in [RCJ_2002]
173- const Atom& atomA = *this->molecule->GetAtomVect()[indexAtomA];
174- const Atom& atomB = *this->molecule->GetAtomVect()[indexAtomB];
175172 int na = atomA.GetNumberValenceElectrons();
176173 int nb = atomB.GetNumberValenceElectrons();
177- double distance = this->molecule->GetDistanceAtoms(indexAtomA, indexAtomB);
174+ double distance = this->molecule->GetDistanceAtoms(atomA, atomB);
178175 double temp = 0.0;
179176 for(int i=0; i<2; i++){
180177 double pa = atomA.GetPm3PddgParameterPa(i);
@@ -193,17 +190,15 @@ double Pm3Pddg::GetDiatomCoreRepulsion1stDerivative(int indexAtomA,
193190
194191 // Second derivative of diatomic core repulsion energy.
195192 // Both derivative are related to the coordinate of atomA.
196-double Pm3Pddg::GetDiatomCoreRepulsion2ndDerivative(int indexAtomA,
197- int indexAtomB,
198- CartesianType axisA1,
199- CartesianType axisA2) const{
193+double Pm3Pddg::GetDiatomCoreRepulsion2ndDerivative(const Atom& atomA,
194+ const Atom& atomB,
195+ CartesianType axisA1,
196+ CartesianType axisA2) const{
200197 // PM3 term
201- double pm3Term = Pm3::GetDiatomCoreRepulsion2ndDerivative(indexAtomA, indexAtomB, axisA1, axisA2);
198+ double pm3Term = Pm3::GetDiatomCoreRepulsion2ndDerivative(atomA, atomB, axisA1, axisA2);
202199
203200 // pddg additional term, first derivative of eq. (4) in [RCJ_2002]
204- const Atom& atomA = *this->molecule->GetAtomVect()[indexAtomA];
205- const Atom& atomB = *this->molecule->GetAtomVect()[indexAtomB];
206- double distance = this->molecule->GetDistanceAtoms(indexAtomA, indexAtomB);
201+ double distance = this->molecule->GetDistanceAtoms(atomA, atomB);
207202 double dCartesian1 = (atomA.GetXyz()[axisA1] - atomB.GetXyz()[axisA1]);
208203 double dCartesian2 = (atomA.GetXyz()[axisA2] - atomB.GetXyz()[axisA2]);
209204 int na = atomA.GetNumberValenceElectrons();
--- a/src/pm3/Pm3Pddg.h
+++ b/src/pm3/Pm3Pddg.h
@@ -32,11 +32,11 @@ protected:
3232 virtual void SetEnableAtomTypes();
3333 virtual double GetDiatomCoreRepulsionEnergy(const MolDS_base_atoms::Atom& atomA,
3434 const MolDS_base_atoms::Atom& atomB) const;
35- virtual double GetDiatomCoreRepulsion1stDerivative(int indexAtomA,
36- int indexAtomB,
35+ virtual double GetDiatomCoreRepulsion1stDerivative(const MolDS_base_atoms::Atom& atomA,
36+ const MolDS_base_atoms::Atom& atomB,
3737 MolDS_base::CartesianType axisA) const;
38- virtual double GetDiatomCoreRepulsion2ndDerivative(int indexAtomA,
39- int indexAtomB,
38+ virtual double GetDiatomCoreRepulsion2ndDerivative(const MolDS_base_atoms::Atom& atomA,
39+ const MolDS_base_atoms::Atom& atomB,
4040 MolDS_base::CartesianType axisA1,
4141 MolDS_base::CartesianType axisA2) const;
4242 private:
--- a/src/zindo/ZindoS.cpp
+++ b/src/zindo/ZindoS.cpp
@@ -3717,9 +3717,9 @@ void ZindoS::CalcForce(const vector<int>& elecStates){
37173717 double forceElecCoreAttPart[CartesianType_end] = {0.0,0.0,0.0};
37183718 for(int i=0; i<CartesianType_end; i++){
37193719 // core repulsion part (ground state)
3720- coreRepulsion[i] = this->GetDiatomCoreRepulsion1stDerivative(a, b, static_cast<CartesianType>(i));
3720+ coreRepulsion[i] = this->GetDiatomCoreRepulsion1stDerivative(atomA, atomB, static_cast<CartesianType>(i));
37213721 if(Parameters::GetInstance()->RequiresVdWSCF()){
3722- coreRepulsion[i] += this->GetDiatomVdWCorrection1stDerivative(a, b, static_cast<CartesianType>(i));
3722+ coreRepulsion[i] += this->GetDiatomVdWCorrection1stDerivative(atomA, atomB, static_cast<CartesianType>(i));
37233723 }
37243724 // electron core attraction part (ground state)
37253725 forceElecCoreAttPart[i] = ( atomA.GetCoreCharge()*atomicElectronPopulation[b]
@@ -3867,10 +3867,10 @@ void ZindoS::CalcForce(const vector<int>& elecStates){
38673867
38683868 // Calculation of core repusion force
38693869 coreRepulsion += this->GetDiatomCoreRepulsion1stDerivative(
3870- a, b, (CartesianType)i);
3870+ atomA, atomB, (CartesianType)i);
38713871 if(Parameters::GetInstance()->RequiresVdWSCF()){
38723872 coreRepulsion += this->GetDiatomVdWCorrection1stDerivative(
3873- a, b, (CartesianType)i);
3873+ atomA, atomB, (CartesianType)i);
38743874 }
38753875
38763876 // Calculate force arise from electronic part.