Revisão | 9a880c2b8fb817ba57ba353e3dbbdcc1fe5f3e29 (tree) |
---|---|
Hora | 2013-05-22 14:11:56 |
Autor | Mikiya Fujii <mikiya.fujii@gmai...> |
Commiter | Mikiya Fujii |
Refactoring of protected or private for some methods. #31221
git-svn-id: https://svn.sourceforge.jp/svnroot/molds/trunk@1346 1136aad2-a195-0410-b898-f5ea1d11b9d8
@@ -38,6 +38,7 @@ public: | ||
38 | 38 | protected: |
39 | 39 | std::string errorMessageDavidsonNotConverged; |
40 | 40 | std::string errorMessageCalcCISMatrix; |
41 | + std::string errorMessageCalcZMatrixForceEtaNull; | |
41 | 42 | std::string messageStartCIS; |
42 | 43 | std::string messageDoneCIS; |
43 | 44 | std::string messageDavidsonConverge; |
@@ -45,89 +46,32 @@ protected: | ||
45 | 46 | std::string messageOmpElapsedTimeCalcCISMarix; |
46 | 47 | std::string messageOmpElapsedTimeCIS; |
47 | 48 | std::string messageDoneCalcCISMatrix; |
48 | - /*** from MNDO ***/ | |
49 | - std::string errorMessageCalcZMatrixForceEtaNull; | |
50 | - int zMatrixForceElecStatesNum; | |
51 | - int etaMatrixForceElecStatesNum; | |
52 | 49 | double*** zMatrixForce; |
53 | 50 | double*** etaMatrixForce; |
54 | 51 | struct MoIndexPair{int moI; int moJ; bool isMoICIMO; bool isMoJCIMO;}; |
55 | - void CheckZMatrixForce(const std::vector<int>& elecStates); | |
56 | - void CheckEtaMatrixForce(const std::vector<int>& elecStates); | |
57 | 52 | void CalcEtaMatrixForce(const std::vector<int>& elecStates); |
58 | 53 | void CalcZMatrixForce(const std::vector<int>& elecStates); |
59 | - double GetZMatrixForceElement(double const* y, | |
60 | - double const* q, | |
61 | - double const* const* transposedFockMatrix, | |
62 | - const std::vector<MoIndexPair>& nonRedundantQIndeces, | |
63 | - const std::vector<MoIndexPair>& redundantQIndeces, | |
64 | - int mu, | |
65 | - int nu) const; | |
66 | - void MallocTempMatrixForZMatrix(double** delta, | |
67 | - double** q, | |
68 | - double*** gammaNRMinusKNR, | |
69 | - double*** kRDag, | |
70 | - double** y, | |
71 | - double*** transposedFockMatrix, | |
72 | - double*** xiOcc, | |
73 | - double*** xiVir, | |
74 | - int sizeQNR, | |
75 | - int sizeQR) const; | |
76 | - void FreeTempMatrixForZMatrix(double** delta, | |
77 | - double** q, | |
78 | - double*** gammaNRMinusKNR, | |
79 | - double*** kRDag, | |
80 | - double** y, | |
81 | - double*** transposedFockMatrix, | |
82 | - double*** xiOcc, | |
83 | - double*** xiVir, | |
84 | - int sizeQNR, | |
85 | - int sizeQR) const; | |
86 | - void CalcDeltaVector(double* delta, int exciteState) const; | |
87 | 54 | void CalcActiveSetVariablesQ(std::vector<MoIndexPair>* nonRedundantQIndeces, |
88 | 55 | std::vector<MoIndexPair>* redundantQIndeces, |
89 | 56 | int numberActiveOcc, |
90 | 57 | int numberActiveVir) const; |
91 | - void CalcQVector(double* q, | |
92 | - double const* delta, | |
93 | - double const* const* xiOcc, | |
94 | - double const* const* xiVir, | |
95 | - double const* const* eta, | |
96 | - const std::vector<MoIndexPair>& nonRedundantQIndeces, | |
97 | - const std::vector<MoIndexPair>& redundantQIndeces) const; | |
98 | 58 | virtual double GetSmallQElement(int moI, |
99 | 59 | int moP, |
100 | 60 | double const* const* xiOcc, |
101 | 61 | double const* const* xiVir, |
102 | 62 | double const* const* eta) const; |
103 | - void CalcXiMatrices(double** xiOcc, | |
104 | - double** xiVir, | |
105 | - int exciteState, | |
106 | - double const* const* transposedFockMatrix) const; | |
107 | - void CalcAuxiliaryVector(double* y, | |
108 | - double const* q, | |
109 | - double const* const* kRDagerGammaRInv, | |
110 | - const std::vector<MoIndexPair>& nonRedundantQIndeces, | |
111 | - const std::vector<MoIndexPair>& redundantQIndeces) const; | |
112 | 63 | double GetGammaNRElement(int moI, int moJ, int moK, int moL) const; |
113 | - double GetGammaRElement(int moI, int moJ, int moK, int moL) const; | |
114 | - double GetNNRElement(int moI, int moJ, int moK, int moL) const; | |
115 | - double GetNRElement(int moI, int moJ, int moK, int moL) const; | |
116 | - double GetKNRElement(int moI, int moJ, int moK, int moL) const; | |
117 | - double GetKRElement(int moI, int moJ, int moK, int moL) const; | |
118 | - double GetKRDagerElement(int moI, int moJ, int moK, int moL) const; | |
64 | + double GetGammaRElement (int moI, int moJ, int moK, int moL) const; | |
65 | + double GetNNRElement (int moI, int moJ, int moK, int moL) const; | |
66 | + double GetNRElement (int moI, int moJ, int moK, int moL) const; | |
67 | + double GetKNRElement (int moI, int moJ, int moK, int moL) const; | |
68 | + double GetKRElement (int moI, int moJ, int moK, int moL) const; | |
119 | 69 | virtual double GetAuxiliaryKNRKRElement(int moI, int moJ, int moK, int moL) const; |
120 | - void CalcGammaNRMinusKNRMatrix(double** gammaNRMinusKNR, | |
121 | - const std::vector<MoIndexPair>& nonRedundantQIndeces) const; | |
122 | - void CalcKRDagerGammaRInvMatrix(double** kRDagerGammaRInv, | |
123 | - const std::vector<MoIndexPair>& nonRedundantQIndeces, | |
124 | - const std::vector<MoIndexPair>& redundantQIndeces) const; | |
125 | 70 | void CalcForceExcitedOverlapAOsPart(double* force, |
126 | 71 | int elecStateIndex, |
127 | 72 | int indexAtomA, |
128 | 73 | int indexAtomB, |
129 | 74 | double const* const* const* diatomicOverlapAOs1stDerivs) const; |
130 | - /*** end from MNDO ***/ | |
131 | 75 | virtual void SetMessages(); |
132 | 76 | virtual void SetEnableAtomTypes(); |
133 | 77 | virtual void CalcCISProperties(); |
@@ -232,30 +176,14 @@ private: | ||
232 | 176 | double nishimotoMatagaParamB; |
233 | 177 | double overlapAOsCorrectionSigma; |
234 | 178 | double overlapAOsCorrectionPi; |
179 | + int zMatrixForceElecStatesNum; | |
180 | + int etaMatrixForceElecStatesNum; | |
235 | 181 | void DoCISDirect(); |
236 | 182 | void DoCISDavidson(); |
237 | 183 | void OutputCISDipole() const; |
238 | 184 | void OutputCISTransitionDipole() const; |
239 | 185 | void OutputCISMulliken() const; |
240 | 186 | void OutputCISUnpairedPop() const; |
241 | - void CalcDiatomicTwoElecTwoCore1stDerivatives(double*** matrix, | |
242 | - int indexAtomA, | |
243 | - int indexAtomB) const; | |
244 | - void CalcForceExcitedStaticPart(double* force, | |
245 | - int elecStateIndex, | |
246 | - int indexAtomA, | |
247 | - int indexAtomB, | |
248 | - double const* const* const* diatomicTwoElecTwoCore1stDerivs) const; | |
249 | - void CalcForceExcitedElecCoreAttractionPart(double* force, | |
250 | - int elecStateIndex, | |
251 | - int indexAtomA, | |
252 | - int indexAtomB, | |
253 | - double const* const* const* diatomicTwoElecTwoCore1stDerivs) const; | |
254 | - void CalcForceExcitedTwoElecPart(double* force, | |
255 | - int elecStateIndex, | |
256 | - int indexAtomA, | |
257 | - int indexAtomB, | |
258 | - double const* const* const* diatomicTwoElecTwoCore1stDerivs) const; | |
259 | 187 | void CalcFreeExcitonEnergies(double** freeExcitonEnergiesCIS, |
260 | 188 | const MolDS_base::Molecule& molecule, |
261 | 189 | double const* energiesMO, |
@@ -336,6 +264,76 @@ private: | ||
336 | 264 | void FreeDavidsonRoopCISTemporaryMtrices(double*** interactionMatrix, |
337 | 265 | int interactionMatrixDimension, |
338 | 266 | double** interactionEigenEnergies) const; |
267 | + void CalcDiatomicTwoElecTwoCore1stDerivatives(double*** matrix, | |
268 | + int indexAtomA, | |
269 | + int indexAtomB) const; | |
270 | + void CalcForceExcitedStaticPart(double* force, | |
271 | + int elecStateIndex, | |
272 | + int indexAtomA, | |
273 | + int indexAtomB, | |
274 | + double const* const* const* diatomicTwoElecTwoCore1stDerivs) const; | |
275 | + void CalcForceExcitedElecCoreAttractionPart(double* force, | |
276 | + int elecStateIndex, | |
277 | + int indexAtomA, | |
278 | + int indexAtomB, | |
279 | + double const* const* const* diatomicTwoElecTwoCore1stDerivs) const; | |
280 | + void CalcForceExcitedTwoElecPart(double* force, | |
281 | + int elecStateIndex, | |
282 | + int indexAtomA, | |
283 | + int indexAtomB, | |
284 | + double const* const* const* diatomicTwoElecTwoCore1stDerivs) const; | |
285 | + void CheckZMatrixForce(const std::vector<int>& elecStates); | |
286 | + void CheckEtaMatrixForce(const std::vector<int>& elecStates); | |
287 | + double GetZMatrixForceElement(double const* y, | |
288 | + double const* q, | |
289 | + double const* const* transposedFockMatrix, | |
290 | + const std::vector<MoIndexPair>& nonRedundantQIndeces, | |
291 | + const std::vector<MoIndexPair>& redundantQIndeces, | |
292 | + int mu, | |
293 | + int nu) const; | |
294 | + void MallocTempMatrixForZMatrix(double** delta, | |
295 | + double** q, | |
296 | + double*** gammaNRMinusKNR, | |
297 | + double*** kRDag, | |
298 | + double** y, | |
299 | + double*** transposedFockMatrix, | |
300 | + double*** xiOcc, | |
301 | + double*** xiVir, | |
302 | + int sizeQNR, | |
303 | + int sizeQR) const; | |
304 | + void FreeTempMatrixForZMatrix(double** delta, | |
305 | + double** q, | |
306 | + double*** gammaNRMinusKNR, | |
307 | + double*** kRDag, | |
308 | + double** y, | |
309 | + double*** transposedFockMatrix, | |
310 | + double*** xiOcc, | |
311 | + double*** xiVir, | |
312 | + int sizeQNR, | |
313 | + int sizeQR) const; | |
314 | + void CalcDeltaVector(double* delta, int exciteState) const; | |
315 | + void CalcQVector(double* q, | |
316 | + double const* delta, | |
317 | + double const* const* xiOcc, | |
318 | + double const* const* xiVir, | |
319 | + double const* const* eta, | |
320 | + const std::vector<MoIndexPair>& nonRedundantQIndeces, | |
321 | + const std::vector<MoIndexPair>& redundantQIndeces) const; | |
322 | + void CalcXiMatrices(double** xiOcc, | |
323 | + double** xiVir, | |
324 | + int exciteState, | |
325 | + double const* const* transposedFockMatrix) const; | |
326 | + void CalcAuxiliaryVector(double* y, | |
327 | + double const* q, | |
328 | + double const* const* kRDagerGammaRInv, | |
329 | + const std::vector<MoIndexPair>& nonRedundantQIndeces, | |
330 | + const std::vector<MoIndexPair>& redundantQIndeces) const; | |
331 | + double GetKRDagerElement(int moI, int moJ, int moK, int moL) const; | |
332 | + void CalcGammaNRMinusKNRMatrix(double** gammaNRMinusKNR, | |
333 | + const std::vector<MoIndexPair>& nonRedundantQIndeces) const; | |
334 | + void CalcKRDagerGammaRInvMatrix(double** kRDagerGammaRInv, | |
335 | + const std::vector<MoIndexPair>& nonRedundantQIndeces, | |
336 | + const std::vector<MoIndexPair>& redundantQIndeces) const; | |
339 | 337 | }; |
340 | 338 | |
341 | 339 | } |