mirror of
https://github.com/TREX-CoE/qmckl.git
synced 2025-01-03 10:06:09 +01:00
Added test to set basis set parameters
This commit is contained in:
parent
5c285dcdb6
commit
afd3f6ae7a
@ -163,8 +163,7 @@ cppcheck --addon=cert --enable=all *.c &> cppcheck.out
|
||||
and terminated by a ~'\0'~ character (C convention).
|
||||
- Complex numbers can be represented by an array of 2 floats.
|
||||
- Boolean variables are stored as integers, ~1~ for ~true~ and ~0~ for ~false~
|
||||
- Floating point variables should be by default
|
||||
- ~double~ unless explicitly mentioned
|
||||
- Floating point variables should be by default ~double~ unless explicitly mentioned
|
||||
- integers used for counting should always be ~int64_t~
|
||||
|
||||
To facilitate the use in other languages than C, we will provide some
|
||||
@ -265,15 +264,3 @@ cppcheck --addon=cert --enable=all *.c &> cppcheck.out
|
||||
QMCkl is a general purpose library, multiple algorithms should be
|
||||
implemented adapted to different problem sizes.
|
||||
|
||||
** Rules for the API
|
||||
|
||||
- =stdint= should be used for integers (=int32_t=, =int64_t=)
|
||||
- integers used for counting should always be =int64_t=
|
||||
- floats should be by default =double=, unless explicitly mentioned
|
||||
- pointers are converted to =int64_t= to increase portability
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
208
src/qmckl_ao.org
208
src/qmckl_ao.org
@ -116,7 +116,7 @@ shell_center = [1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2]
|
||||
shell_ang_mom = ['S', 'S', 'S', 'P', 'P', 'D', 'S', 'S', 'S', 'P', 'P', 'D']
|
||||
shell_factor = [ 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1.]
|
||||
shell_prim_num = [5, 1, 1, 1, 1, 1, 5, 1, 1, 1, 1, 1]
|
||||
prim_index = [1, 6, 7, 8, 9, 10, 11, 16, 17, 18, 19, 20]
|
||||
shell_prim_index = [1, 6, 7, 8, 9, 10, 11, 16, 17, 18, 19, 20]
|
||||
exponent = [ 33.87, 5.095, 1.159, 0.3258, 0.1027, 0.3258, 0.1027,
|
||||
1.407, 0.388, 1.057, 33.87, 5.095, 1.159, 0.3258, 0.1027,
|
||||
0.3258, 0.1027, 1.407, 0.388, 1.057]
|
||||
@ -134,7 +134,7 @@ typedef struct qmckl_ao_basis_struct {
|
||||
int64_t shell_num;
|
||||
int64_t prim_num;
|
||||
int64_t * shell_center;
|
||||
int32_t * shell_ang_mom;
|
||||
char * shell_ang_mom;
|
||||
int64_t * shell_prim_num;
|
||||
int64_t * shell_prim_index;
|
||||
double * shell_factor;
|
||||
@ -145,36 +145,41 @@ typedef struct qmckl_ao_basis_struct {
|
||||
#+end_src
|
||||
|
||||
The ~uninitialized~ integer contains one bit set to one for each
|
||||
initialization function which has not bee called. When it is equal
|
||||
to zero, the struct is initialized and ~provided == 1~.
|
||||
initialization function which has not bee called. It becomes equal
|
||||
to zero after all initialization functions have been called. The
|
||||
struct is then initialized and ~provided == 1~.
|
||||
|
||||
** Access functions
|
||||
|
||||
Access to scalars copies the values at the passed address, and
|
||||
for array values a pointer to the array is returned.
|
||||
|
||||
#+begin_src c :comments org :tangle (eval h_private_func)
|
||||
char qmckl_get_ao_basis_type (const qmckl_context context);
|
||||
int64_t qmckl_get_ao_basis_shell_num (const qmckl_context context);
|
||||
int64_t qmckl_get_ao_basis_prim_num (const qmckl_context context);
|
||||
int64_t* qmckl_get_ao_basis_shell_center (const qmckl_context context);
|
||||
char* qmckl_get_ao_basis_shell_ang_mom (const qmckl_context context);
|
||||
int64_t* qmckl_get_ao_basis_shell_prim_num (const qmckl_context context);
|
||||
int64_t* qmckl_get_ao_basis_shell_prim_index (const qmckl_context context);
|
||||
double* qmckl_get_ao_basis_shell_factor (const qmckl_context context);
|
||||
double* qmckl_get_ao_basis_exponent (const qmckl_context context);
|
||||
double* qmckl_get_ao_basis_coefficient (const qmckl_context context);
|
||||
#+end_src
|
||||
|
||||
#+begin_src c :comments org :tangle (eval h_func)
|
||||
char qmckl_get_ao_basis_type (qmckl_context context);
|
||||
int64_t qmckl_get_ao_basis_shell_num (qmckl_context context);
|
||||
int64_t qmckl_get_ao_basis_prim_num (qmckl_context context);
|
||||
int64_t* qmckl_get_ao_basis_shell_center (qmckl_context context);
|
||||
int32_t* qmckl_get_ao_basis_shell_ang_mom (qmckl_context context);
|
||||
int64_t* qmckl_get_ao_basis_shell_prim_num (qmckl_context context);
|
||||
double* qmckl_get_ao_basis_shell_factor (qmckl_context context);
|
||||
double* qmckl_get_ao_basis_exponent (qmckl_context context);
|
||||
double* qmckl_get_ao_basis_coefficient (qmckl_context context);
|
||||
int32_t qmckl_ao_basis_provided (const qmckl_context context);
|
||||
#+end_src
|
||||
|
||||
#+NAME:post
|
||||
#+begin_src c
|
||||
if (ctx->ao_basis.uninitialized &= mask != 0) {
|
||||
if ( (ctx->ao_basis.uninitialized & mask) != 0) {
|
||||
return NULL;
|
||||
}
|
||||
#+end_src
|
||||
|
||||
|
||||
#+begin_src c :comments org :tangle (eval c) :noweb yes
|
||||
char qmckl_get_ao_basis_type (qmckl_context context) {
|
||||
char qmckl_get_ao_basis_type (const qmckl_context context) {
|
||||
|
||||
if (qmckl_context_check(context) == QMCKL_NULL_CONTEXT) {
|
||||
return (char) 0;
|
||||
@ -185,7 +190,7 @@ char qmckl_get_ao_basis_type (qmckl_context context) {
|
||||
|
||||
int32_t mask = 1;
|
||||
|
||||
if (ctx->ao_basis.uninitialized &= mask != 0) {
|
||||
if ( (ctx->ao_basis.uninitialized & mask) != 0) {
|
||||
return (char) 0;
|
||||
}
|
||||
|
||||
@ -194,7 +199,7 @@ char qmckl_get_ao_basis_type (qmckl_context context) {
|
||||
}
|
||||
|
||||
|
||||
int64_t qmckl_get_ao_basis_shell_num (qmckl_context context) {
|
||||
int64_t qmckl_get_ao_basis_shell_num (const qmckl_context context) {
|
||||
if (qmckl_context_check(context) == QMCKL_NULL_CONTEXT) {
|
||||
return (int64_t) 0;
|
||||
}
|
||||
@ -204,16 +209,16 @@ int64_t qmckl_get_ao_basis_shell_num (qmckl_context context) {
|
||||
|
||||
int32_t mask = 1 << 1;
|
||||
|
||||
if (ctx->ao_basis.uninitialized &= mask != 0) {
|
||||
if ( (ctx->ao_basis.uninitialized & mask) != 0) {
|
||||
return (int64_t) 0;
|
||||
}
|
||||
|
||||
assert (ctx->ao_basis.shell_num != (int64_t) 0);
|
||||
assert (ctx->ao_basis.shell_num > (int64_t) 0);
|
||||
return ctx->ao_basis.shell_num;
|
||||
}
|
||||
|
||||
|
||||
int64_t qmckl_get_ao_basis_prim_num (qmckl_context context) {
|
||||
int64_t qmckl_get_ao_basis_prim_num (const qmckl_context context) {
|
||||
if (qmckl_context_check(context) == QMCKL_NULL_CONTEXT) {
|
||||
return (int64_t) 0;
|
||||
}
|
||||
@ -223,16 +228,16 @@ int64_t qmckl_get_ao_basis_prim_num (qmckl_context context) {
|
||||
|
||||
int32_t mask = 1 << 2;
|
||||
|
||||
if (ctx->ao_basis.uninitialized &= mask != 0) {
|
||||
if ( (ctx->ao_basis.uninitialized & mask) != 0) {
|
||||
return (int64_t) 0;
|
||||
}
|
||||
|
||||
assert (ctx->ao_basis.prim_num != (int64_t) 0);
|
||||
assert (ctx->ao_basis.prim_num > (int64_t) 0);
|
||||
return ctx->ao_basis.prim_num;
|
||||
}
|
||||
|
||||
|
||||
int64_t* qmckl_get_ao_basis_shell_center (qmckl_context context) {
|
||||
int64_t* qmckl_get_ao_basis_shell_center (const qmckl_context context) {
|
||||
if (qmckl_context_check(context) == QMCKL_NULL_CONTEXT) {
|
||||
return NULL;
|
||||
}
|
||||
@ -242,7 +247,7 @@ int64_t* qmckl_get_ao_basis_shell_center (qmckl_context context) {
|
||||
|
||||
int32_t mask = 1 << 3;
|
||||
|
||||
if (ctx->ao_basis.uninitialized &= mask != 0) {
|
||||
if ( (ctx->ao_basis.uninitialized & mask) != 0) {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
@ -251,7 +256,7 @@ int64_t* qmckl_get_ao_basis_shell_center (qmckl_context context) {
|
||||
}
|
||||
|
||||
|
||||
int32_t* qmckl_get_ao_basis_shell_ang_mom (qmckl_context context) {
|
||||
char* qmckl_get_ao_basis_shell_ang_mom (const qmckl_context context) {
|
||||
if (qmckl_context_check(context) == QMCKL_NULL_CONTEXT) {
|
||||
return NULL;
|
||||
}
|
||||
@ -261,7 +266,7 @@ int32_t* qmckl_get_ao_basis_shell_ang_mom (qmckl_context context) {
|
||||
|
||||
int32_t mask = 1 << 4;
|
||||
|
||||
if (ctx->ao_basis.uninitialized &= mask != 0) {
|
||||
if ( (ctx->ao_basis.uninitialized & mask) != 0) {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
@ -270,7 +275,7 @@ int32_t* qmckl_get_ao_basis_shell_ang_mom (qmckl_context context) {
|
||||
}
|
||||
|
||||
|
||||
int64_t* qmckl_get_ao_basis_shell_prim_num (qmckl_context context) {
|
||||
int64_t* qmckl_get_ao_basis_shell_prim_num (const qmckl_context context) {
|
||||
if (qmckl_context_check(context) == QMCKL_NULL_CONTEXT) {
|
||||
return NULL;
|
||||
}
|
||||
@ -280,7 +285,7 @@ int64_t* qmckl_get_ao_basis_shell_prim_num (qmckl_context context) {
|
||||
|
||||
int32_t mask = 1 << 5;
|
||||
|
||||
if (ctx->ao_basis.uninitialized &= mask != 0) {
|
||||
if ( (ctx->ao_basis.uninitialized & mask) != 0) {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
@ -289,7 +294,7 @@ int64_t* qmckl_get_ao_basis_shell_prim_num (qmckl_context context) {
|
||||
}
|
||||
|
||||
|
||||
int64_t* qmckl_get_ao_basis_shell_prim_index (qmckl_context context) {
|
||||
int64_t* qmckl_get_ao_basis_shell_prim_index (const qmckl_context context) {
|
||||
if (qmckl_context_check(context) == QMCKL_NULL_CONTEXT) {
|
||||
return NULL;
|
||||
}
|
||||
@ -299,7 +304,7 @@ int64_t* qmckl_get_ao_basis_shell_prim_index (qmckl_context context) {
|
||||
|
||||
int32_t mask = 1 << 6;
|
||||
|
||||
if (ctx->ao_basis.uninitialized &= mask != 0) {
|
||||
if ( (ctx->ao_basis.uninitialized & mask) != 0) {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
@ -308,7 +313,7 @@ int64_t* qmckl_get_ao_basis_shell_prim_index (qmckl_context context) {
|
||||
}
|
||||
|
||||
|
||||
double* qmckl_get_ao_basis_shell_factor (qmckl_context context) {
|
||||
double* qmckl_get_ao_basis_shell_factor (const qmckl_context context) {
|
||||
if (qmckl_context_check(context) == QMCKL_NULL_CONTEXT) {
|
||||
return NULL;
|
||||
}
|
||||
@ -318,7 +323,7 @@ double* qmckl_get_ao_basis_shell_factor (qmckl_context context) {
|
||||
|
||||
int32_t mask = 1 << 7;
|
||||
|
||||
if (ctx->ao_basis.uninitialized &= mask != 0) {
|
||||
if ( (ctx->ao_basis.uninitialized & mask) != 0) {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
@ -327,7 +332,7 @@ double* qmckl_get_ao_basis_shell_factor (qmckl_context context) {
|
||||
}
|
||||
|
||||
|
||||
double* qmckl_get_ao_basis_exponent (qmckl_context context) {
|
||||
double* qmckl_get_ao_basis_exponent (const qmckl_context context) {
|
||||
if (qmckl_context_check(context) == QMCKL_NULL_CONTEXT) {
|
||||
return NULL;
|
||||
}
|
||||
@ -338,7 +343,7 @@ double* qmckl_get_ao_basis_exponent (qmckl_context context) {
|
||||
|
||||
int32_t mask = 1 << 8;
|
||||
|
||||
if (ctx->ao_basis.uninitialized &= mask != 0) {
|
||||
if ( (ctx->ao_basis.uninitialized & mask) != 0) {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
@ -347,7 +352,7 @@ double* qmckl_get_ao_basis_exponent (qmckl_context context) {
|
||||
}
|
||||
|
||||
|
||||
double* qmckl_get_ao_basis_coefficient (qmckl_context context) {
|
||||
double* qmckl_get_ao_basis_coefficient (const qmckl_context context) {
|
||||
if (qmckl_context_check(context) == QMCKL_NULL_CONTEXT) {
|
||||
return NULL;
|
||||
}
|
||||
@ -357,13 +362,26 @@ double* qmckl_get_ao_basis_coefficient (qmckl_context context) {
|
||||
|
||||
int32_t mask = 1 << 9;
|
||||
|
||||
if (ctx->ao_basis.uninitialized &= mask != 0) {
|
||||
if ( (ctx->ao_basis.uninitialized & mask) != 0) {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
assert (ctx->ao_basis.coefficient != NULL);
|
||||
return ctx->ao_basis.coefficient;
|
||||
}
|
||||
|
||||
|
||||
int32_t qmckl_ao_basis_provided(const qmckl_context context) {
|
||||
|
||||
if (qmckl_context_check(context) == QMCKL_NULL_CONTEXT) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
qmckl_context_struct* const ctx = (qmckl_context_struct* const) context;
|
||||
assert (ctx != NULL);
|
||||
|
||||
return ctx->ao_basis.provided;
|
||||
}
|
||||
#+end_src
|
||||
|
||||
** Initialization functions
|
||||
@ -375,9 +393,10 @@ double* qmckl_get_ao_basis_coefficient (qmckl_context context) {
|
||||
qmckl_exit_code qmckl_set_ao_basis_type (qmckl_context context, const char t);
|
||||
qmckl_exit_code qmckl_set_ao_basis_shell_num (qmckl_context context, const int64_t shell_num);
|
||||
qmckl_exit_code qmckl_set_ao_basis_prim_num (qmckl_context context, const int64_t prim_num);
|
||||
qmckl_exit_code qmckl_set_ao_basis_shell_prim_index (qmckl_context context, const int64_t * shell_prim_index);
|
||||
qmckl_exit_code qmckl_set_ao_basis_shell_center (qmckl_context context, const int64_t * shell_center);
|
||||
qmckl_exit_code qmckl_set_ao_basis_shell_ang_mom (qmckl_context context, const int32_t * shell_ang_mom);
|
||||
qmckl_exit_code qmckl_set_ao_basis_shell_center (qmckl_context context, const int64_t * shell_prim_num);
|
||||
qmckl_exit_code qmckl_set_ao_basis_shell_ang_mom (qmckl_context context, const char * shell_ang_mom);
|
||||
qmckl_exit_code qmckl_set_ao_basis_shell_prim_num (qmckl_context context, const int64_t * shell_prim_num);
|
||||
qmckl_exit_code qmckl_set_ao_basis_shell_factor (qmckl_context context, const double * shell_factor);
|
||||
qmckl_exit_code qmckl_set_ao_basis_exponent (qmckl_context context, const double * exponent);
|
||||
qmckl_exit_code qmckl_set_ao_basis_coefficient (qmckl_context context, const double * coefficient);
|
||||
@ -394,7 +413,7 @@ qmckl_context_struct* const ctx = (qmckl_context_struct* const) context;
|
||||
|
||||
#+NAME:post2
|
||||
#+begin_src c
|
||||
ctx->ao_basis.uninitialized &= !(mask);
|
||||
ctx->ao_basis.uninitialized &= ~mask;
|
||||
|
||||
if (ctx->ao_basis.uninitialized == 0) {
|
||||
ctx->ao_basis.provided = 1;
|
||||
@ -515,7 +534,7 @@ qmckl_exit_code qmckl_set_ao_basis_shell_center(qmckl_context context, const in
|
||||
}
|
||||
|
||||
|
||||
qmckl_exit_code qmckl_set_ao_basis_shell_ang_mom(qmckl_context context, const int32_t* shell_ang_mom) {
|
||||
qmckl_exit_code qmckl_set_ao_basis_shell_ang_mom(qmckl_context context, const char* shell_ang_mom) {
|
||||
<<pre2>>
|
||||
|
||||
int32_t mask = 1 << 4;
|
||||
@ -539,8 +558,8 @@ qmckl_exit_code qmckl_set_ao_basis_shell_ang_mom(qmckl_context context, const i
|
||||
|
||||
|
||||
qmckl_memory_info_struct mem_info = qmckl_memory_info_struct_zero;
|
||||
mem_info.size = shell_num * sizeof(int64_t);
|
||||
int32_t* new_array = (int32_t*) qmckl_malloc(context, mem_info);
|
||||
mem_info.size = shell_num * sizeof(char);
|
||||
char* new_array = (char*) qmckl_malloc(context, mem_info);
|
||||
|
||||
if (new_array == NULL) {
|
||||
return qmckl_failwith( context,
|
||||
@ -763,6 +782,101 @@ qmckl_exit_code qmckl_set_ao_basis_coefficient(qmckl_context context, const dou
|
||||
|
||||
#+end_src
|
||||
|
||||
|
||||
** Fortran interfaces
|
||||
#+NAME: qmckl_ao_power_args
|
||||
| qmckl_context | context | in | Global state |
|
||||
| int64_t | n | in | Number of values |
|
||||
| double | X[n] | in | Array containing the input values |
|
||||
| int32_t | LMAX[n] | in | Array containing the maximum power for each value |
|
||||
| double | P[n][ldp] | out | Array containing all the powers of ~X~ |
|
||||
| int64_t | ldp | in | Leading dimension of array ~P~ |
|
||||
|
||||
** Test
|
||||
|
||||
#+begin_src c :tangle (eval c_test)
|
||||
/* Reference input data */
|
||||
|
||||
char typ = 'G';
|
||||
#define shell_num ((int64_t) 12)
|
||||
#define prim_num ((int64_t) 20)
|
||||
|
||||
int64_t shell_center [shell_num] =
|
||||
{ 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2 };
|
||||
|
||||
char shell_ang_mom [shell_num] =
|
||||
{ 'S', 'S', 'S', 'P', 'P', 'D', 'S', 'S', 'S', 'P', 'P', 'D' };
|
||||
|
||||
double shell_factor [shell_num] =
|
||||
{ 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1. };
|
||||
|
||||
int64_t shell_prim_num [shell_num] =
|
||||
{5, 1, 1, 1, 1, 1, 5, 1, 1, 1, 1, 1};
|
||||
|
||||
int64_t shell_prim_index [shell_num] =
|
||||
{1, 6, 7, 8, 9, 10, 11, 16, 17, 18, 19, 20};
|
||||
|
||||
double exponent [prim_num] =
|
||||
{ 33.87, 5.095, 1.159, 0.3258, 0.1027, 0.3258, 0.1027,
|
||||
1.407, 0.388, 1.057, 33.87, 5.095, 1.159, 0.3258, 0.1027,
|
||||
0.3258, 0.1027, 1.407, 0.388, 1.057 };
|
||||
|
||||
double coefficient [prim_num] =
|
||||
{ 0.006068, 0.045308, 0.202822, 0.503903, 0.383421,
|
||||
1.0, 1.0, 1.0, 1.0, 1.0, 0.006068, 0.045308, 0.202822,
|
||||
0.503903, 0.383421, 1.0, 1.0, 1.0, 1.0, 1.0 };
|
||||
/* --- */
|
||||
|
||||
qmckl_exit_code rc;
|
||||
|
||||
munit_assert_int(qmckl_ao_basis_provided(context), ==, 0);
|
||||
|
||||
rc = qmckl_set_ao_basis_type (context, typ);
|
||||
munit_assert_int64(rc, ==, QMCKL_SUCCESS);
|
||||
munit_assert_int(qmckl_ao_basis_provided(context), ==, 0);
|
||||
|
||||
rc = qmckl_set_ao_basis_shell_num (context, shell_num);
|
||||
munit_assert_int64(rc, ==, QMCKL_SUCCESS);
|
||||
munit_assert_int(qmckl_ao_basis_provided(context), ==, 0);
|
||||
|
||||
rc = qmckl_set_ao_basis_prim_num (context, prim_num);
|
||||
munit_assert_int64(rc, ==, QMCKL_SUCCESS);
|
||||
munit_assert_int(qmckl_ao_basis_provided(context), ==, 0);
|
||||
|
||||
rc = qmckl_set_ao_basis_shell_center (context, shell_center);
|
||||
munit_assert_int64(rc, ==, QMCKL_SUCCESS);
|
||||
munit_assert_int(qmckl_ao_basis_provided(context), ==, 0);
|
||||
|
||||
rc = qmckl_set_ao_basis_shell_ang_mom (context, shell_ang_mom);
|
||||
munit_assert_int64(rc, ==, QMCKL_SUCCESS);
|
||||
munit_assert_int(qmckl_ao_basis_provided(context), ==, 0);
|
||||
|
||||
rc = qmckl_set_ao_basis_shell_factor (context, shell_factor);
|
||||
munit_assert_int64(rc, ==, QMCKL_SUCCESS);
|
||||
munit_assert_int(qmckl_ao_basis_provided(context), ==, 0);
|
||||
|
||||
rc = qmckl_set_ao_basis_shell_center (context, shell_prim_num);
|
||||
munit_assert_int64(rc, ==, QMCKL_SUCCESS);
|
||||
munit_assert_int(qmckl_ao_basis_provided(context), ==, 0);
|
||||
|
||||
rc = qmckl_set_ao_basis_shell_prim_num (context, shell_prim_num);
|
||||
munit_assert_int64(rc, ==, QMCKL_SUCCESS);
|
||||
munit_assert_int(qmckl_ao_basis_provided(context), ==, 0);
|
||||
|
||||
rc = qmckl_set_ao_basis_shell_prim_index (context, shell_prim_index);
|
||||
munit_assert_int64(rc, ==, QMCKL_SUCCESS);
|
||||
munit_assert_int(qmckl_ao_basis_provided(context), ==, 0);
|
||||
|
||||
rc = qmckl_set_ao_basis_exponent (context, exponent);
|
||||
munit_assert_int64(rc, ==, QMCKL_SUCCESS);
|
||||
munit_assert_int(qmckl_ao_basis_provided(context), ==, 0);
|
||||
|
||||
rc = qmckl_set_ao_basis_coefficient (context, coefficient);
|
||||
munit_assert_int64(rc, ==, QMCKL_SUCCESS);
|
||||
munit_assert_int(qmckl_ao_basis_provided(context), ==, 1);
|
||||
|
||||
#+end_src
|
||||
|
||||
* Polynomial part
|
||||
** Powers of $x-X_i$
|
||||
:PROPERTIES:
|
||||
@ -924,7 +1038,6 @@ integer(c_int32_t) function test_qmckl_ao_power(context) bind(C)
|
||||
double precision :: epsilon
|
||||
|
||||
epsilon = qmckl_get_numprec_epsilon(context)
|
||||
print *, epsilon
|
||||
|
||||
n = 100;
|
||||
LDP = 10;
|
||||
@ -1337,7 +1450,8 @@ int test_qmckl_ao_polynomial_vgl(qmckl_context context);
|
||||
munit_assert_int(0, ==, test_qmckl_ao_polynomial_vgl(context));
|
||||
#+end_src
|
||||
|
||||
* Gaussian basis functions
|
||||
* Radial part
|
||||
** Gaussian basis functions
|
||||
|
||||
~qmckl_ao_gaussian_vgl~ computes the values, gradients and
|
||||
Laplacians at a given point of ~n~ Gaussian functions centered at
|
||||
@ -1546,8 +1660,10 @@ int test_qmckl_ao_gaussian_vgl(qmckl_context context);
|
||||
munit_assert_int(0, ==, test_qmckl_ao_gaussian_vgl(context));
|
||||
#+end_src
|
||||
|
||||
* TODO Slater basis functions
|
||||
** TODO Slater basis functions
|
||||
|
||||
** TODO Radial functions on a grid
|
||||
* Combining radial and polynomial parts
|
||||
* End of files :noexport:
|
||||
|
||||
#+begin_src c :tangle (eval h_private_type)
|
||||
|
Loading…
Reference in New Issue
Block a user