1
0
mirror of https://github.com/TREX-CoE/qmckl.git synced 2024-12-22 12:23:56 +01:00

Added noexport

This commit is contained in:
Anthony Scemama 2020-10-25 15:16:02 +01:00
parent 5e9e74f743
commit 959d4d1110
4 changed files with 47 additions and 42 deletions

View File

@ -17,7 +17,7 @@ values, gradients and Laplacian of the atomic basis functions.
- a source file : =qmckl_ao.f90=
- a test file : =test_qmckl_ao.c=
*** Header
*** Header :noexport:
#+BEGIN_SRC C :comments link :tangle qmckl_ao.h
#ifndef QMCKL_AO_H
#define QMCKL_AO_H
@ -25,12 +25,12 @@ values, gradients and Laplacian of the atomic basis functions.
#include "qmckl_distance.h"
#+END_SRC
*** Source
*** Source :noexport:
#+BEGIN_SRC f90 :comments link :tangle qmckl_ao.f90
#+END_SRC
*** Test
*** Test :noexport:
#+BEGIN_SRC C :comments link :tangle test_qmckl_ao.c
#include <math.h>
#include "qmckl.h"
@ -58,7 +58,7 @@ MunitResult test_qmckl_ao() {
| =n= | input | Number of values |
| =X(n)= | input | Array containing the input values |
| =LMAX(n)= | input | Array containing the maximum power for each value |
| =P(LDP,n)= | output | Array containing all the powers of $X$ |
| =P(LDP,n)= | output | Array containing all the powers of =X= |
| =LDP= | input | Leading dimension of array =P= |
*** Requirements
@ -129,7 +129,7 @@ integer(c_int32_t) function qmckl_ao_powers(context, n, X, LMAX, P, ldp) &
end function qmckl_ao_powers
#+END_SRC
*** Test
*** Test :noexport:
#+BEGIN_SRC C :comments link :tangle test_qmckl_ao.c
{
int64_t n, LDP ;
@ -166,8 +166,7 @@ end function qmckl_ao_powers
** =qmckl_ao_polynomial_vgl=
Computes the value, gradient and Laplacian of the Polynomials for each
point given in input and for each center
Computes the value, gradient and Laplacian of a Polynomial.
*** Arguments
@ -176,10 +175,10 @@ end function qmckl_ao_powers
| =R(3)= | input | Array containing the x,y,z coordinates of the center |
| =lmax= | input | Maximum angular momentum |
| =n= | output | Number of computed polynomials |
| =L(LDL,n)= | output | Contains a,b,c for all =n= results |
| =LDL= | input | Leading dimension of =L= |
| =VGL(LDV,n)= | output | Value, gradients and Laplacian of the polynomials |
| =LDV= | input | Leading dimension of array =VGL= |
| =L(ldl,n)= | output | Contains a,b,c for all =n= results |
| =ldl= | input | Leading dimension of =L= |
| =VGL(ldv,n)= | output | Value, gradients and Laplacian of the polynomials |
| =ldv= | input | Leading dimension of array =VGL= |
*** Requirements
@ -289,6 +288,7 @@ integer function qmckl_ao_polynomial_vgl_f(context, X, R, lmax, n, L, ldl, VGL,
end function qmckl_ao_polynomial_vgl_f
! C interface
integer(c_int32_t) function qmckl_ao_polynomial_vgl(context, X, R, lmax, n, L, ldl, VGL, ldv) &
bind(C) result(info)
use, intrinsic :: iso_c_binding
@ -307,7 +307,7 @@ integer(c_int32_t) function qmckl_ao_polynomial_vgl(context, X, R, lmax, n, L, l
end function qmckl_ao_polynomial_vgl
#+END_SRC
*** Test
*** Test :noexport:
#+BEGIN_SRC C :comments link :tangle test_qmckl_ao.c
{
#include <stdio.h>
@ -383,8 +383,8 @@ end function qmckl_ao_polynomial_vgl
* TODO Slater basis functions
* End of files
* End of files :noexport:
*** Header
#+BEGIN_SRC C :comments link :tangle qmckl_ao.h
#endif

View File

@ -18,19 +18,19 @@ C than in Fortran.
- a source file : =qmckl_context.c=
- a test file : =test_qmckl_context.c=
*** Header
*** Header :noexport:
#+BEGIN_SRC C :comments link :tangle qmckl_context.h
#ifndef QMCKL_CONTEXT_H
#define QMCKL_CONTEXT_H
#include "qmckl.h"
#+END_SRC
*** Source
*** Source :noexport:
#+BEGIN_SRC C :comments link :tangle qmckl_context.c
#include "qmckl.h"
#+END_SRC
*** Test
*** Test :noexport:
#+BEGIN_SRC C :comments link :tangle test_qmckl_context.c
#include "qmckl.h"
#include "munit.h"
@ -62,7 +62,7 @@ typedef struct qmckl_context_struct {
The tag is used internally to check if the memory domain pointed by
a pointer is a valid context.
*** Test
*** Test :noexport:
We declare here the variables used in the tests.
#+BEGIN_SRC C :comments link :tangle test_qmckl_context.c
qmckl_context context;
@ -125,7 +125,7 @@ qmckl_context qmckl_context_create() {
}
#+END_SRC
*** Test
*** Test :noexport:
#+BEGIN_SRC C :comments link :tangle test_qmckl_context.c
context = qmckl_context_create();
munit_assert_int64( context, !=, (qmckl_context) 0);
@ -176,7 +176,7 @@ qmckl_context qmckl_context_copy(const qmckl_context context) {
#+END_SRC
*** Test
*** Test :noexport:
#+BEGIN_SRC C :comments link :tangle test_qmckl_context.c
new_context = qmckl_context_copy(context);
munit_assert_int64(new_context, !=, (qmckl_context) 0);
@ -213,7 +213,7 @@ qmckl_context qmckl_context_previous(const qmckl_context context) {
}
#+END_SRC
*** Test
*** Test :noexport:
#+BEGIN_SRC C :comments link :tangle test_qmckl_context.c
munit_assert_int64(qmckl_context_previous(new_context), !=, (qmckl_context) 0);
munit_assert_int64(qmckl_context_previous(new_context), ==, context);
@ -253,7 +253,7 @@ qmckl_exit_code qmckl_context_destroy(qmckl_context context) {
}
#+END_SRC
*** Test
*** Test :noexport:
#+BEGIN_SRC C :comments link :tangle test_qmckl_context.c
munit_assert_int64(qmckl_context_check(new_context), ==, new_context);
munit_assert_int64(new_context, !=, (qmckl_context) 0);
@ -275,7 +275,7 @@ qmckl_exit_code qmckl_context_destroy(qmckl_context context) {
The update functions return =QMCKL_SUCCESS= or =QMCKL_FAILURE=.
** =qmckl_context_update_precision=
*** Source
#+BEGIN_SRC C :comments link :tangle qmckl_context.h
qmckl_exit_code qmckl_context_update_precision(const qmckl_context context, const int precision);
#+END_SRC
@ -295,7 +295,9 @@ qmckl_exit_code qmckl_context_update_precision(const qmckl_context context, cons
}
#+END_SRC
*** TODO Tests :noexport:
** =qmckl_context_update_range=
*** Source
#+BEGIN_SRC C :comments link :tangle qmckl_context.h
qmckl_exit_code qmckl_context_update_range(const qmckl_context context, const int range);
#+END_SRC
@ -315,10 +317,9 @@ qmckl_exit_code qmckl_context_update_range(const qmckl_context context, const in
}
#+END_SRC
*** TODO Tests :noexport:
** =qmckl_context_set_precision=
*** Source
#+BEGIN_SRC C :comments link :tangle qmckl_context.h
qmckl_context qmckl_context_set_precision(const qmckl_context context, const int precision);
#+END_SRC
@ -336,7 +337,9 @@ qmckl_context qmckl_context_set_precision(const qmckl_context context, const int
}
#+END_SRC
*** TODO Tests :noexport:
** =qmckl_context_set_range=
*** Source
#+BEGIN_SRC C :comments link :tangle qmckl_context.h
qmckl_context qmckl_context_set_range(const qmckl_context context, const int range);
#+END_SRC
@ -354,10 +357,10 @@ qmckl_context qmckl_context_set_range(const qmckl_context context, const int ran
}
#+END_SRC
*** TODO Tests :noexport:
** =qmckl_context_get_precision=
*** Source
#+BEGIN_SRC C :comments link :tangle qmckl_context.h
int qmckl_context_get_precision(const qmckl_context context);
#+END_SRC
@ -370,7 +373,9 @@ int qmckl_context_get_precision(const qmckl_context context) {
}
#+END_SRC
*** TODO Tests :noexport:
** =qmckl_context_get_range=
*** Source
#+BEGIN_SRC C :comments link :tangle qmckl_context.h
int qmckl_context_get_range(const qmckl_context context);
@ -384,9 +389,9 @@ int qmckl_context_get_range(const qmckl_context context) {
}
#+END_SRC
*** TODO Tests :noexport:
* End of files
* End of files :noexport:
*** Header
#+BEGIN_SRC C :comments link :tangle qmckl_context.h

View File

@ -16,18 +16,18 @@ Function for the computation of distances between particles.
- a source file : =qmckl_distance.f90=
- a test file : =test_qmckl_distance.c=
*** Header
*** Header :noexport:
#+BEGIN_SRC C :comments link :tangle qmckl_distance.h
#ifndef QMCKL_DISTANCE_H
#define QMCKL_DISTANCE_H
#include "qmckl_context.h"
#+END_SRC
*** Source
*** Source :noexport:
#+BEGIN_SRC f90 :comments link :tangle qmckl_distance.f90
#+END_SRC
*** Test
*** Test :noexport:
#+BEGIN_SRC C :comments link :tangle test_qmckl_distance.c
#include <math.h>
#include "qmckl.h"
@ -186,7 +186,7 @@ integer(c_int32_t) function qmckl_distance_sq(context, m, n, A, LDA, B, LDB, C,
end function qmckl_distance_sq
#+END_SRC
*** Test
*** Test :noexport:
#+BEGIN_SRC C :comments link :tangle test_qmckl_distance.c
munit_assert_int64(QMCKL_SUCCESS, ==,
@ -205,12 +205,12 @@ end function qmckl_distance_sq
#+END_SRC
* End of files
*** Header
*** Header :noexport:
#+BEGIN_SRC C :comments link :tangle qmckl_distance.h
#endif
#+END_SRC
*** Test
*** Test :noexport:
#+BEGIN_SRC C :comments link :tangle test_qmckl_distance.c
qmckl_free(A);
qmckl_free(B);

View File

@ -18,20 +18,20 @@ optimized libraries to fine-tune the memory allocation.
- a source file : =qmckl_memory.c=
- a test file : =test_qmckl_memory.c=
** Header
** Header :noexport:
#+BEGIN_SRC C :comments link :tangle qmckl_memory.h
#ifndef QMCKL_MEMORY_H
#define QMCKL_MEMORY_H
#include "qmckl.h"
#+END_SRC
** Source
** Source :noexport:
#+BEGIN_SRC C :comments link :tangle qmckl_memory.c
#include <stdlib.h>
#include "qmckl_memory.h"
#+END_SRC
** Test
** Test :noexport:
#+BEGIN_SRC C :comments link :tangle test_qmckl_memory.c
#include "qmckl.h"
#include "munit.h"
@ -57,7 +57,7 @@ void* qmckl_malloc(const qmckl_context ctx, const size_t size) {
#+END_SRC
** Test
** Test :noexport:
#+BEGIN_SRC C :comments link :tangle test_qmckl_memory.c
int *a;
a = (int*) qmckl_malloc( (qmckl_context) 1, 3*sizeof(int));
@ -83,12 +83,12 @@ void qmckl_free(void *ptr) {
}
#+END_SRC
** Test
** Test :noexport:
#+BEGIN_SRC C :comments link :tangle test_qmckl_memory.c
qmckl_free(a);
#+END_SRC
* End of files
* End of files :noexport:
** Header
#+BEGIN_SRC C :comments link :tangle qmckl_memory.h