Revisão | 2386d906de80ec68742c6d5d3fd2097a7a34a449 (tree) |
---|---|
Hora | 2012-06-03 16:16:13 |
Autor | Mikiya Fujii <mikiya.fujii@gmai...> |
Commiter | Mikiya Fujii |
Cndo2::reeDiatomicOverlapFirstDeriTemps is refactored #28554
git-svn-id: https://svn.sourceforge.jp/svnroot/molds/trunk@695 1136aad2-a195-0410-b898-f5ea1d11b9d8
@@ -3373,25 +3373,25 @@ void Cndo2::CalcDiatomicOverlapFirstDerivative(double*** overlapFirstDeri, | ||
3373 | 3373 | pow(Cartesian[ZAxis],2.0) ); |
3374 | 3374 | |
3375 | 3375 | double** diatomicOverlap = NULL; |
3376 | - double** rotatingMatrix = NULL; | |
3377 | 3376 | double** diaOverlapFirstDeri = NULL; |
3377 | + double** rotatingMatrix = NULL; | |
3378 | 3378 | double*** rotMatFirstDerivatives = NULL; |
3379 | 3379 | |
3380 | 3380 | try{ |
3381 | 3381 | MallocerFreer::GetInstance()->Malloc<double>(&diatomicOverlap, |
3382 | 3382 | OrbitalType_end, |
3383 | 3383 | OrbitalType_end); |
3384 | + MallocerFreer::GetInstance()->Malloc<double>(&diaOverlapFirstDeri, OrbitalType_end, OrbitalType_end); | |
3384 | 3385 | MallocerFreer::GetInstance()->Malloc<double>(&rotatingMatrix, |
3385 | 3386 | OrbitalType_end, |
3386 | 3387 | OrbitalType_end); |
3387 | - MallocerFreer::GetInstance()->Malloc<double>(&diaOverlapFirstDeri, OrbitalType_end, OrbitalType_end); | |
3388 | 3388 | MallocerFreer::GetInstance()->Malloc<double>(&rotMatFirstDerivatives, |
3389 | 3389 | OrbitalType_end, |
3390 | 3390 | OrbitalType_end, |
3391 | 3391 | CartesianType_end); |
3392 | 3392 | this->CalcDiatomicOverlapInDiatomicFrame(diatomicOverlap, atomA, atomB); |
3393 | - this->CalcRotatingMatrix(rotatingMatrix, atomA, atomB); | |
3394 | 3393 | this->CalcDiatomicOverlapFirstDerivativeInDiatomicFrame(diaOverlapFirstDeri, atomA, atomB); |
3394 | + this->CalcRotatingMatrix(rotatingMatrix, atomA, atomB); | |
3395 | 3395 | this->CalcRotatingMatrixFirstDerivatives(rotMatFirstDerivatives, atomA, atomB); |
3396 | 3396 | |
3397 | 3397 | // rotate |
@@ -3424,25 +3424,25 @@ void Cndo2::CalcDiatomicOverlapFirstDerivative(double*** overlapFirstDeri, | ||
3424 | 3424 | } |
3425 | 3425 | catch(MolDSException ex){ |
3426 | 3426 | this->FreeDiatomicOverlapFirstDeriTemps(&diatomicOverlap, |
3427 | - &rotatingMatrix, | |
3428 | 3427 | &diaOverlapFirstDeri, |
3428 | + &rotatingMatrix, | |
3429 | 3429 | &rotMatFirstDerivatives); |
3430 | 3430 | throw ex; |
3431 | 3431 | } |
3432 | 3432 | // free |
3433 | 3433 | this->FreeDiatomicOverlapFirstDeriTemps(&diatomicOverlap, |
3434 | - &rotatingMatrix, | |
3435 | 3434 | &diaOverlapFirstDeri, |
3435 | + &rotatingMatrix, | |
3436 | 3436 | &rotMatFirstDerivatives); |
3437 | 3437 | } |
3438 | 3438 | |
3439 | 3439 | void Cndo2::FreeDiatomicOverlapFirstDeriTemps(double*** diatomicOverlap, |
3440 | - double*** rotatingMatrix, | |
3441 | 3440 | double*** diaOverlapFirstDeri, |
3441 | + double*** rotatingMatrix, | |
3442 | 3442 | double**** rotMatFirstDerivatives) const{ |
3443 | 3443 | MallocerFreer::GetInstance()->Free<double>(diatomicOverlap, OrbitalType_end, OrbitalType_end); |
3444 | - MallocerFreer::GetInstance()->Free<double>(rotatingMatrix, OrbitalType_end, OrbitalType_end); | |
3445 | 3444 | MallocerFreer::GetInstance()->Free<double>(diaOverlapFirstDeri, OrbitalType_end, OrbitalType_end); |
3445 | + MallocerFreer::GetInstance()->Free<double>(rotatingMatrix, OrbitalType_end, OrbitalType_end); | |
3446 | 3446 | MallocerFreer::GetInstance()->Free<double>(rotMatFirstDerivatives, OrbitalType_end, OrbitalType_end, CartesianType_end); |
3447 | 3447 | } |
3448 | 3448 |
@@ -170,8 +170,8 @@ protected: | ||
170 | 170 | const MolDS_base_atoms::Atom& atomA, |
171 | 171 | const MolDS_base_atoms::Atom& atomB) const; |
172 | 172 | void FreeDiatomicOverlapFirstDeriTemps(double*** diatomicOverlap, |
173 | - double*** rotatingMatrix, | |
174 | 173 | double*** diaOverlapFirstDeri, |
174 | + double*** rotatingMatrix, | |
175 | 175 | double**** rotMatFirstDerivatives) const; |
176 | 176 | virtual double GetMolecularIntegralElement(int moI, int moJ, int moK, int moL, |
177 | 177 | const MolDS_base::Molecule& molecule, |