Kindfield
Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Enumerations
Enumerator
Properties
Friends
Pages
src
basisfunctions
gaussian
integrals
gaussianoverlapintegral.cpp
Go to the documentation of this file.
1
#include "
gaussianoverlapintegral.h
"
2
3
#include "
math/vector3.h
"
4
#include <
math/hermiteexpansioncoefficient.h
>
5
#include <
basisfunctions/gaussian/gaussianprimitiveorbital.h
>
6
7
GaussianOverlapIntegral::GaussianOverlapIntegral
(
int
angularMomentumMax) :
8
m_hermiteExpansionCoefficients(angularMomentumMax + 1)
9
{
10
}
11
12
void
GaussianOverlapIntegral::set
(
Vector3
corePositionA,
Vector3
corePositionB,
13
const
GaussianPrimitiveOrbital
& primitiveA,
14
const
GaussianPrimitiveOrbital
& primitiveB,
15
bool
expandForKinetic)
16
{
17
int
expansion = 0;
18
if
(expandForKinetic) {
19
expansion = 2;
20
}
21
m_exponentSum
= primitiveA.
exponent
() + primitiveB.
exponent
();
22
m_hermiteExpansionCoefficients
.
set
(primitiveA.
exponent
(), primitiveB.
exponent
(),
23
corePositionA, corePositionB,
24
primitiveA.
xExponent
(), primitiveB.
xExponent
() + expansion,
25
primitiveA.
yExponent
(), primitiveB.
yExponent
() + expansion,
26
primitiveA.
zExponent
(), primitiveB.
zExponent
() + expansion);
27
m_exponentSum
= primitiveA.
exponent
() + primitiveB.
exponent
();
28
}
29
30
double
GaussianOverlapIntegral::overlapIntegral
(
const
GaussianPrimitiveOrbital
& primitiveA,
31
const
GaussianPrimitiveOrbital
& primitiveB)
32
{
33
return
overlapIntegral
(primitiveA.
xExponent
(), primitiveA.
yExponent
(), primitiveA.
zExponent
(),
34
primitiveB.
xExponent
(), primitiveB.
yExponent
(), primitiveB.
zExponent
());
35
}
36
37
double
GaussianOverlapIntegral::overlapIntegral
(
int
dim,
int
iA,
int
iB)
38
{
39
double
p =
m_exponentSum
;
40
const
cube &E_dim =
m_hermiteExpansionCoefficients
[dim];
41
return
E_dim(iA,iB,0) * sqrt(M_PI / p);
42
}
43
44
double
GaussianOverlapIntegral::overlapIntegral
(
int
iA,
int
jA,
int
kA,
int
iB,
int
jB,
int
kB)
45
{
46
return
overlapIntegral
(0, iA, iB) *
overlapIntegral
(1, jA, jB) *
overlapIntegral
(2, kA, kB);
47
}
Generated on Sun Jun 22 2014 14:02:46 for Kindfield by
1.8.4