# -*- mode: org -*-
# vim: syntax=c
#+TITLE: QMCkl C header
#+HTML_HEAD:
#+HTML_HEAD:
#+HTML_HEAD:
#+HTML_HEAD:
#+HTML_HEAD:
#+HTML_HEAD:
This file produces the =qmckl.h= header file, which is included in all
other C header files. It is the main entry point to the library.
#+BEGIN_SRC C :tangle qmckl.h
#ifndef QMCKL_H
#define QMCKL_H
#include
#include
#+END_SRC
* Constants
** Success/failure
These are the codes returned by the functions to indicate success
or failure. All such functions should have as a return type =qmckl_exit_code=.
#+BEGIN_SRC C :tangle qmckl.h
#define QMCKL_SUCCESS 0
#define QMCKL_FAILURE 1
typedef int32_t qmckl_exit_code;
typedef int64_t qmckl_context ;
#+END_SRC
** Precision-related constants
Controlling numerical precision enables optimizations. Here, the
default parameters determining the target numerical precision and
range are defined.
#+BEGIN_SRC C :tangle qmckl.h
#define QMCKL_DEFAULT_PRECISION 53
#define QMCKL_DEFAULT_RANGE 11
#+END_SRC
* Header files
All the functions expoed in the API are defined in the following
header files.
#+BEGIN_SRC C :tangle qmckl.h
#include "qmckl_memory.h"
#include "qmckl_context.h"
#include "qmckl_distance.h"
#include "qmckl_ao.h"
#+END_SRC
* End of header
#+BEGIN_SRC C :tangle qmckl.h
#endif
#+END_SRC