1
0
mirror of https://github.com/TREX-CoE/qmckl.git synced 2024-11-03 20:54:09 +01:00

Deploying to gh-pages from @ TREX-CoE/qmckl@16595f898b 🚀

This commit is contained in:
scemama 2021-05-18 23:38:22 +00:00
parent df88ceaaf5
commit eb0a74a4dd
12 changed files with 449 additions and 419 deletions

View File

@ -3,7 +3,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head> <head>
<!-- 2021-05-18 Tue 23:32 --> <!-- 2021-05-18 Tue 23:38 -->
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
<title>QMCkl source code documentation</title> <title>QMCkl source code documentation</title>
@ -352,7 +352,7 @@ and bug reports should be submitted at
</div> </div>
<div id="postamble" class="status"> <div id="postamble" class="status">
<p class="author">Author: TREX CoE</p> <p class="author">Author: TREX CoE</p>
<p class="date">Created: 2021-05-18 Tue 23:32</p> <p class="date">Created: 2021-05-18 Tue 23:38</p>
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p> <p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
</div> </div>
</body> </body>

View File

@ -3,7 +3,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head> <head>
<!-- 2021-05-18 Tue 23:32 --> <!-- 2021-05-18 Tue 23:38 -->
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Introduction</title> <title>Introduction</title>
@ -333,30 +333,30 @@ for the JavaScript code in this tag.
<h2>Table of Contents</h2> <h2>Table of Contents</h2>
<div id="text-table-of-contents"> <div id="text-table-of-contents">
<ul> <ul>
<li><a href="#orgd1006c4">1. Using QMCkl</a></li> <li><a href="#org3948b0c">1. Using QMCkl</a></li>
<li><a href="#orga0b07a9">2. Developing in QMCkl</a> <li><a href="#orgb87ea93">2. Developing in QMCkl</a>
<ul> <ul>
<li><a href="#orgf235310">2.1. Literate programming</a></li> <li><a href="#org2be7fb5">2.1. Literate programming</a></li>
<li><a href="#org2efd276">2.2. Source code editing</a></li> <li><a href="#org1a024f2">2.2. Source code editing</a></li>
<li><a href="#org91a43fd">2.3. Choice of the programming language</a></li> <li><a href="#org24c1948">2.3. Choice of the programming language</a></li>
<li><a href="#org0bb366f">2.4. Coding rules</a></li> <li><a href="#orgf1b9107">2.4. Coding rules</a></li>
<li><a href="#orgd5dd075">2.5. Design of the library</a></li> <li><a href="#org911a770">2.5. Design of the library</a></li>
<li><a href="#org7092a15">2.6. Naming conventions</a></li> <li><a href="#orgfe0ce17">2.6. Naming conventions</a></li>
<li><a href="#org0811a18">2.7. Application programming interface</a></li> <li><a href="#org0112712">2.7. Application programming interface</a></li>
<li><a href="#orgd4e885b">2.8. Global state</a></li> <li><a href="#org81c0d79">2.8. Global state</a></li>
<li><a href="#orgd9d3690">2.9. Headers</a></li> <li><a href="#orge38a904">2.9. Headers</a></li>
<li><a href="#org19e4e9e">2.10. Low-level functions</a></li> <li><a href="#org26e0604">2.10. Low-level functions</a></li>
<li><a href="#org64e0a70">2.11. High-level functions</a></li> <li><a href="#org4a679a6">2.11. High-level functions</a></li>
<li><a href="#org96f36d7">2.12. Numerical precision</a></li> <li><a href="#orgc0dc7fa">2.12. Numerical precision</a></li>
<li><a href="#org9785916">2.13. Algorithms</a></li> <li><a href="#orgc4ed845">2.13. Algorithms</a></li>
</ul> </ul>
</li> </li>
</ul> </ul>
</div> </div>
</div> </div>
<div id="outline-container-orgd1006c4" class="outline-2"> <div id="outline-container-org3948b0c" class="outline-2">
<h2 id="orgd1006c4"><span class="section-number-2">1</span> Using QMCkl</h2> <h2 id="org3948b0c"><span class="section-number-2">1</span> Using QMCkl</h2>
<div class="outline-text-2" id="text-1"> <div class="outline-text-2" id="text-1">
<p> <p>
The <code>qmckl.h</code> header file installed in the <code>${prefix}/include</code> directory The <code>qmckl.h</code> header file installed in the <code>${prefix}/include</code> directory
@ -385,12 +385,12 @@ Both files are located in the <code>include/</code> directory.
</div> </div>
</div> </div>
<div id="outline-container-orga0b07a9" class="outline-2"> <div id="outline-container-orgb87ea93" class="outline-2">
<h2 id="orga0b07a9"><span class="section-number-2">2</span> Developing in QMCkl</h2> <h2 id="orgb87ea93"><span class="section-number-2">2</span> Developing in QMCkl</h2>
<div class="outline-text-2" id="text-2"> <div class="outline-text-2" id="text-2">
</div> </div>
<div id="outline-container-orgf235310" class="outline-3"> <div id="outline-container-org2be7fb5" class="outline-3">
<h3 id="orgf235310"><span class="section-number-3">2.1</span> Literate programming</h3> <h3 id="org2be7fb5"><span class="section-number-3">2.1</span> Literate programming</h3>
<div class="outline-text-3" id="text-2-1"> <div class="outline-text-3" id="text-2-1">
<p> <p>
In a traditional source code, most of the lines of source files of a program In a traditional source code, most of the lines of source files of a program
@ -435,8 +435,8 @@ interactively, in the same spirit as Jupyter notebooks.
</div> </div>
</div> </div>
<div id="outline-container-org2efd276" class="outline-3"> <div id="outline-container-org1a024f2" class="outline-3">
<h3 id="org2efd276"><span class="section-number-3">2.2</span> Source code editing</h3> <h3 id="org1a024f2"><span class="section-number-3">2.2</span> Source code editing</h3>
<div class="outline-text-3" id="text-2-2"> <div class="outline-text-3" id="text-2-2">
<p> <p>
For a tutorial on literate programming with org-mode, follow <a href="http://www.howardism.org/Technical/Emacs/literate-programming-tutorial.html">this link</a>. For a tutorial on literate programming with org-mode, follow <a href="http://www.howardism.org/Technical/Emacs/literate-programming-tutorial.html">this link</a>.
@ -467,8 +467,8 @@ org-mode.
</div> </div>
</div> </div>
<div id="outline-container-org91a43fd" class="outline-3"> <div id="outline-container-org24c1948" class="outline-3">
<h3 id="org91a43fd"><span class="section-number-3">2.3</span> Choice of the programming language</h3> <h3 id="org24c1948"><span class="section-number-3">2.3</span> Choice of the programming language</h3>
<div class="outline-text-3" id="text-2-3"> <div class="outline-text-3" id="text-2-3">
<p> <p>
Most of the codes of the <a href="https://trex-coe.eu">TREX CoE</a> are written in Fortran with some scripts in Most of the codes of the <a href="https://trex-coe.eu">TREX CoE</a> are written in Fortran with some scripts in
@ -516,8 +516,8 @@ For more guidelines on using Fortran to generate a C interface, see
</div> </div>
</div> </div>
<div id="outline-container-org0bb366f" class="outline-3"> <div id="outline-container-orgf1b9107" class="outline-3">
<h3 id="org0bb366f"><span class="section-number-3">2.4</span> Coding rules</h3> <h3 id="orgf1b9107"><span class="section-number-3">2.4</span> Coding rules</h3>
<div class="outline-text-3" id="text-2-4"> <div class="outline-text-3" id="text-2-4">
<p> <p>
The authors should follow the recommendations of the C99 The authors should follow the recommendations of the C99
@ -535,8 +535,8 @@ Compliance can be checked with <code>cppcheck</code> as:
</div> </div>
</div> </div>
<div id="outline-container-orgd5dd075" class="outline-3"> <div id="outline-container-org911a770" class="outline-3">
<h3 id="orgd5dd075"><span class="section-number-3">2.5</span> Design of the library</h3> <h3 id="org911a770"><span class="section-number-3">2.5</span> Design of the library</h3>
<div class="outline-text-3" id="text-2-5"> <div class="outline-text-3" id="text-2-5">
<p> <p>
The proposed API should allow the library to: deal with memory transfers The proposed API should allow the library to: deal with memory transfers
@ -547,8 +547,8 @@ functions (see below).
</div> </div>
</div> </div>
<div id="outline-container-org7092a15" class="outline-3"> <div id="outline-container-orgfe0ce17" class="outline-3">
<h3 id="org7092a15"><span class="section-number-3">2.6</span> Naming conventions</h3> <h3 id="orgfe0ce17"><span class="section-number-3">2.6</span> Naming conventions</h3>
<div class="outline-text-3" id="text-2-6"> <div class="outline-text-3" id="text-2-6">
<p> <p>
To avoid namespace collisions, we use <code>qmckl_</code> as a prefix for all exported To avoid namespace collisions, we use <code>qmckl_</code> as a prefix for all exported
@ -573,8 +573,8 @@ form is allowed.
</div> </div>
</div> </div>
<div id="outline-container-org0811a18" class="outline-3"> <div id="outline-container-org0112712" class="outline-3">
<h3 id="org0811a18"><span class="section-number-3">2.7</span> Application programming interface</h3> <h3 id="org0112712"><span class="section-number-3">2.7</span> Application programming interface</h3>
<div class="outline-text-3" id="text-2-7"> <div class="outline-text-3" id="text-2-7">
<p> <p>
In the C language, the number of bits used by the integer types can change In the C language, the number of bits used by the integer types can change
@ -606,15 +606,15 @@ bindings in other languages in other repositories.
</div> </div>
</div> </div>
<div id="outline-container-orgd4e885b" class="outline-3"> <div id="outline-container-org81c0d79" class="outline-3">
<h3 id="orgd4e885b"><span class="section-number-3">2.8</span> Global state</h3> <h3 id="org81c0d79"><span class="section-number-3">2.8</span> Global state</h3>
<div class="outline-text-3" id="text-2-8"> <div class="outline-text-3" id="text-2-8">
<p> <p>
Global variables should be avoided in the library, because it is Global variables should be avoided in the library, because it is
possible that one single program needs to use multiple instances possible that one single program needs to use multiple instances
of the library. To solve this problem we propose to use a pointer of the library. To solve this problem we propose to use a pointer
to a <a href="./qmckl_context.html"><code>context</code></a> variable, built by the library with the to a <a href="./qmckl_context.html"><code>context</code></a> variable, built by the library with the
<code>qmckl_context_create</code> function. The <a id="org6c95d82">=context=</a> contains the global <code>qmckl_context_create</code> function. The <a id="org143d39a">=context=</a> contains the global
state of the library, and is used as the first argument of many state of the library, and is used as the first argument of many
QMCkl functions. QMCkl functions.
</p> </p>
@ -628,8 +628,8 @@ the state is done by setters and getters, prefixed by
</div> </div>
</div> </div>
<div id="outline-container-orgd9d3690" class="outline-3"> <div id="outline-container-orge38a904" class="outline-3">
<h3 id="orgd9d3690"><span class="section-number-3">2.9</span> Headers</h3> <h3 id="orge38a904"><span class="section-number-3">2.9</span> Headers</h3>
<div class="outline-text-3" id="text-2-9"> <div class="outline-text-3" id="text-2-9">
<p> <p>
A single <code>qmckl.h</code> header to be distributed by the library A single <code>qmckl.h</code> header to be distributed by the library
@ -717,8 +717,8 @@ and the types definitions should be written in the <code>*_f_type.f90</code> fil
</div> </div>
</div> </div>
<div id="outline-container-org19e4e9e" class="outline-3"> <div id="outline-container-org26e0604" class="outline-3">
<h3 id="org19e4e9e"><span class="section-number-3">2.10</span> Low-level functions</h3> <h3 id="org26e0604"><span class="section-number-3">2.10</span> Low-level functions</h3>
<div class="outline-text-3" id="text-2-10"> <div class="outline-text-3" id="text-2-10">
<p> <p>
Low-level functions are very simple functions which are leaves of Low-level functions are very simple functions which are leaves of
@ -727,14 +727,14 @@ the function call tree (they don't call any other QMCkl function).
<p> <p>
These functions are <i>pure</i>, and unaware of the QMCkl These functions are <i>pure</i>, and unaware of the QMCkl
<a href="#org6c95d82"><code>context</code></a>. They are not allowed to allocate/deallocate memory, and <a href="#org143d39a"><code>context</code></a>. They are not allowed to allocate/deallocate memory, and
if they need temporary memory it should be provided in input. if they need temporary memory it should be provided in input.
</p> </p>
</div> </div>
</div> </div>
<div id="outline-container-org64e0a70" class="outline-3"> <div id="outline-container-org4a679a6" class="outline-3">
<h3 id="org64e0a70"><span class="section-number-3">2.11</span> High-level functions</h3> <h3 id="org4a679a6"><span class="section-number-3">2.11</span> High-level functions</h3>
<div class="outline-text-3" id="text-2-11"> <div class="outline-text-3" id="text-2-11">
<p> <p>
High-level functions are at the top of the function call tree. High-level functions are at the top of the function call tree.
@ -747,27 +747,27 @@ temporary storage, to simplify the use of accelerators.
<p> <p>
The high-level functions should be pure, unless the introduction The high-level functions should be pure, unless the introduction
of non-purity is justified. All the side effects should be made in of non-purity is justified. All the side effects should be made in
the <a href="#org6c95d82"><code>context</code></a> variable. the <a href="#org143d39a"><code>context</code></a> variable.
</p> </p>
</div> </div>
</div> </div>
<div id="outline-container-org96f36d7" class="outline-3"> <div id="outline-container-orgc0dc7fa" class="outline-3">
<h3 id="org96f36d7"><span class="section-number-3">2.12</span> Numerical precision</h3> <h3 id="orgc0dc7fa"><span class="section-number-3">2.12</span> Numerical precision</h3>
<div class="outline-text-3" id="text-2-12"> <div class="outline-text-3" id="text-2-12">
<p> <p>
The number of bits of precision required for a function should be The number of bits of precision required for a function should be
given as an input of low-level computational functions. This input given as an input of low-level computational functions. This input
will be used to define the values of the different thresholds that will be used to define the values of the different thresholds that
might be used to avoid computing unnecessary noise. High-level might be used to avoid computing unnecessary noise. High-level
functions will use the precision specified in the <a href="#org6c95d82"><code>context</code></a> functions will use the precision specified in the <a href="#org143d39a"><code>context</code></a>
variable. variable.
</p> </p>
</div> </div>
</div> </div>
<div id="outline-container-org9785916" class="outline-3"> <div id="outline-container-orgc4ed845" class="outline-3">
<h3 id="org9785916"><span class="section-number-3">2.13</span> Algorithms</h3> <h3 id="orgc4ed845"><span class="section-number-3">2.13</span> Algorithms</h3>
<div class="outline-text-3" id="text-2-13"> <div class="outline-text-3" id="text-2-13">
<p> <p>
Reducing the scaling of an algorithm usually implies also reducing Reducing the scaling of an algorithm usually implies also reducing
@ -783,7 +783,7 @@ implemented adapted to different problem sizes.
</div> </div>
<div id="postamble" class="status"> <div id="postamble" class="status">
<p class="author">Author: TREX CoE</p> <p class="author">Author: TREX CoE</p>
<p class="date">Created: 2021-05-18 Tue 23:32</p> <p class="date">Created: 2021-05-18 Tue 23:38</p>
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p> <p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
</div> </div>
</body> </body>

View File

@ -3,7 +3,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head> <head>
<!-- 2021-05-18 Tue 23:32 --> <!-- 2021-05-18 Tue 23:38 -->
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Atomic Orbitals</title> <title>Atomic Orbitals</title>
@ -333,52 +333,52 @@ for the JavaScript code in this tag.
<h2>Table of Contents</h2> <h2>Table of Contents</h2>
<div id="text-table-of-contents"> <div id="text-table-of-contents">
<ul> <ul>
<li><a href="#orge566884">1. Context</a> <li><a href="#orga809886">1. Context</a>
<ul> <ul>
<li><a href="#org2c49619">1.1. Data structure</a></li> <li><a href="#org5c709ac">1.1. Data structure</a></li>
<li><a href="#org97c8b5c">1.2. Access functions</a></li> <li><a href="#org9af54b8">1.2. Access functions</a></li>
<li><a href="#org28fd348">1.3. Initialization functions</a></li> <li><a href="#org003106f">1.3. Initialization functions</a></li>
<li><a href="#orga0917a7">1.4. <span class="todo TODO">TODO</span> Fortran interfaces</a></li> <li><a href="#org8627bc2">1.4. <span class="todo TODO">TODO</span> Fortran interfaces</a></li>
</ul> </ul>
</li> </li>
<li><a href="#orga732f29">2. Polynomial part</a> <li><a href="#org790af08">2. Polynomial part</a>
<ul> <ul>
<li><a href="#org0689079">2.1. Powers of \(x-X_i\)</a> <li><a href="#org050eba2">2.1. Powers of \(x-X_i\)</a>
<ul> <ul>
<li><a href="#org5f8e212">2.1.1. Requirements</a></li> <li><a href="#orga8e3aa1">2.1.1. Requirements</a></li>
<li><a href="#orgdd6b0af">2.1.2. C Header</a></li> <li><a href="#org19ad258">2.1.2. C Header</a></li>
<li><a href="#org3a10081">2.1.3. Source</a></li> <li><a href="#org66b4fc4">2.1.3. Source</a></li>
<li><a href="#orgf57b5e6">2.1.4. C interface</a></li> <li><a href="#orgdf16851">2.1.4. C interface</a></li>
<li><a href="#org898f254">2.1.5. Fortran interface</a></li> <li><a href="#orgd54be83">2.1.5. Fortran interface</a></li>
<li><a href="#orgb4ff218">2.1.6. Test</a></li> <li><a href="#orgc26b6f3">2.1.6. Test</a></li>
</ul> </ul>
</li> </li>
<li><a href="#org9aa3e7c">2.2. Value, Gradient and Laplacian of a polynomial</a> <li><a href="#org3238ff8">2.2. Value, Gradient and Laplacian of a polynomial</a>
<ul> <ul>
<li><a href="#org05f71d2">2.2.1. Requirements</a></li> <li><a href="#org93123f2">2.2.1. Requirements</a></li>
<li><a href="#org1527e1b">2.2.2. C Header</a></li> <li><a href="#org965b7ad">2.2.2. C Header</a></li>
<li><a href="#orgc927910">2.2.3. Source</a></li> <li><a href="#org375d0fa">2.2.3. Source</a></li>
<li><a href="#org172b6f2">2.2.4. C interface</a></li> <li><a href="#orga3a66b0">2.2.4. C interface</a></li>
<li><a href="#org2d4b852">2.2.5. Fortran interface</a></li> <li><a href="#org8d562b3">2.2.5. Fortran interface</a></li>
<li><a href="#org6fd7e9b">2.2.6. Test</a></li> <li><a href="#org2d34055">2.2.6. Test</a></li>
</ul> </ul>
</li> </li>
</ul> </ul>
</li> </li>
<li><a href="#org42e061e">3. Radial part</a> <li><a href="#org0bc195a">3. Radial part</a>
<ul> <ul>
<li><a href="#org9c9f595">3.1. Gaussian basis functions</a></li> <li><a href="#org60113b2">3.1. Gaussian basis functions</a></li>
<li><a href="#org1a9549b">3.2. <span class="todo TODO">TODO</span> Slater basis functions</a></li> <li><a href="#orgd4e1d85">3.2. <span class="todo TODO">TODO</span> Slater basis functions</a></li>
<li><a href="#org70b226c">3.3. <span class="todo TODO">TODO</span> Radial functions on a grid</a></li> <li><a href="#org3b5c9fc">3.3. <span class="todo TODO">TODO</span> Radial functions on a grid</a></li>
</ul> </ul>
</li> </li>
<li><a href="#orgaca3955">4. Combining radial and polynomial parts</a></li> <li><a href="#org6971b57">4. Combining radial and polynomial parts</a></li>
</ul> </ul>
</div> </div>
</div> </div>
<div id="outline-container-orge566884" class="outline-2"> <div id="outline-container-orga809886" class="outline-2">
<h2 id="orge566884"><span class="section-number-2">1</span> Context</h2> <h2 id="orga809886"><span class="section-number-2">1</span> Context</h2>
<div class="outline-text-2" id="text-1"> <div class="outline-text-2" id="text-1">
<p> <p>
The following arrays are stored in the context: The following arrays are stored in the context:
@ -503,8 +503,8 @@ coefficient = [ 0.006068, 0.045308, 0.202822, 0.503903, 0.383421,
</pre> </pre>
</div> </div>
<div id="outline-container-org2c49619" class="outline-3"> <div id="outline-container-org5c709ac" class="outline-3">
<h3 id="org2c49619"><span class="section-number-3">1.1</span> Data structure</h3> <h3 id="org5c709ac"><span class="section-number-3">1.1</span> Data structure</h3>
<div class="outline-text-3" id="text-1-1"> <div class="outline-text-3" id="text-1-1">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c"><span style="color: #a020f0;">typedef</span> <span style="color: #a020f0;">struct</span> <span style="color: #228b22;">qmckl_ao_basis_struct</span> { <pre class="src src-c"><span style="color: #a020f0;">typedef</span> <span style="color: #a020f0;">struct</span> <span style="color: #228b22;">qmckl_ao_basis_struct</span> {
@ -533,8 +533,8 @@ struct is then initialized and <code>provided == true</code>.
</div> </div>
</div> </div>
<div id="outline-container-org97c8b5c" class="outline-3"> <div id="outline-container-org9af54b8" class="outline-3">
<h3 id="org97c8b5c"><span class="section-number-3">1.2</span> Access functions</h3> <h3 id="org9af54b8"><span class="section-number-3">1.2</span> Access functions</h3>
<div class="outline-text-3" id="text-1-2"> <div class="outline-text-3" id="text-1-2">
<p> <p>
When all the data for the AOs have been provided, the following When all the data for the AOs have been provided, the following
@ -548,8 +548,8 @@ function returns <code>true</code>.
</div> </div>
</div> </div>
<div id="outline-container-org28fd348" class="outline-3"> <div id="outline-container-org003106f" class="outline-3">
<h3 id="org28fd348"><span class="section-number-3">1.3</span> Initialization functions</h3> <h3 id="org003106f"><span class="section-number-3">1.3</span> Initialization functions</h3>
<div class="outline-text-3" id="text-1-3"> <div class="outline-text-3" id="text-1-3">
<p> <p>
To set the basis set, all the following functions need to be To set the basis set, all the following functions need to be
@ -572,17 +572,17 @@ called. When
</div> </div>
</div> </div>
<div id="outline-container-orga0917a7" class="outline-3"> <div id="outline-container-org8627bc2" class="outline-3">
<h3 id="orga0917a7"><span class="section-number-3">1.4</span> <span class="todo TODO">TODO</span> Fortran interfaces</h3> <h3 id="org8627bc2"><span class="section-number-3">1.4</span> <span class="todo TODO">TODO</span> Fortran interfaces</h3>
</div> </div>
</div> </div>
<div id="outline-container-orga732f29" class="outline-2"> <div id="outline-container-org790af08" class="outline-2">
<h2 id="orga732f29"><span class="section-number-2">2</span> Polynomial part</h2> <h2 id="org790af08"><span class="section-number-2">2</span> Polynomial part</h2>
<div class="outline-text-2" id="text-2"> <div class="outline-text-2" id="text-2">
</div> </div>
<div id="outline-container-org0689079" class="outline-3"> <div id="outline-container-org050eba2" class="outline-3">
<h3 id="org0689079"><span class="section-number-3">2.1</span> Powers of \(x-X_i\)</h3> <h3 id="org050eba2"><span class="section-number-3">2.1</span> Powers of \(x-X_i\)</h3>
<div class="outline-text-3" id="text-2-1"> <div class="outline-text-3" id="text-2-1">
<p> <p>
The <code>qmckl_ao_power</code> function computes all the powers of the <code>n</code> The <code>qmckl_ao_power</code> function computes all the powers of the <code>n</code>
@ -594,7 +594,7 @@ the \(n\) points:
\[ P_{ik} = X_i^k \] \[ P_{ik} = X_i^k \]
</p> </p>
<table id="org6373930" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides"> <table id="org2e89c7f" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
<colgroup> <colgroup>
@ -652,8 +652,8 @@ the \(n\) points:
</table> </table>
</div> </div>
<div id="outline-container-org5f8e212" class="outline-4"> <div id="outline-container-orga8e3aa1" class="outline-4">
<h4 id="org5f8e212"><span class="section-number-4">2.1.1</span> Requirements</h4> <h4 id="orga8e3aa1"><span class="section-number-4">2.1.1</span> Requirements</h4>
<div class="outline-text-4" id="text-2-1-1"> <div class="outline-text-4" id="text-2-1-1">
<ul class="org-ul"> <ul class="org-ul">
<li><code>context</code> is not <code>QMCKL_NULL_CONTEXT</code></li> <li><code>context</code> is not <code>QMCKL_NULL_CONTEXT</code></li>
@ -666,8 +666,8 @@ the \(n\) points:
</div> </div>
</div> </div>
<div id="outline-container-orgdd6b0af" class="outline-4"> <div id="outline-container-org19ad258" class="outline-4">
<h4 id="orgdd6b0af"><span class="section-number-4">2.1.2</span> C Header</h4> <h4 id="org19ad258"><span class="section-number-4">2.1.2</span> C Header</h4>
<div class="outline-text-4" id="text-2-1-2"> <div class="outline-text-4" id="text-2-1-2">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_ao_power</span> ( <pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_ao_power</span> (
@ -682,8 +682,8 @@ the \(n\) points:
</div> </div>
</div> </div>
<div id="outline-container-org3a10081" class="outline-4"> <div id="outline-container-org66b4fc4" class="outline-4">
<h4 id="org3a10081"><span class="section-number-4">2.1.3</span> Source</h4> <h4 id="org66b4fc4"><span class="section-number-4">2.1.3</span> Source</h4>
<div class="outline-text-4" id="text-2-1-3"> <div class="outline-text-4" id="text-2-1-3">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-f90"><span style="color: #228b22;">integer </span><span style="color: #a020f0;">function</span><span style="color: #a0522d;"> </span><span style="color: #0000ff;">qmckl_ao_power_f</span><span style="color: #000000; background-color: #ffffff;">(context, n, X, LMAX, P, ldp) result(info)</span> <pre class="src src-f90"><span style="color: #228b22;">integer </span><span style="color: #a020f0;">function</span><span style="color: #a0522d;"> </span><span style="color: #0000ff;">qmckl_ao_power_f</span><span style="color: #000000; background-color: #ffffff;">(context, n, X, LMAX, P, ldp) result(info)</span>
@ -734,15 +734,15 @@ the \(n\) points:
</div> </div>
</div> </div>
<div id="outline-container-orgf57b5e6" class="outline-4"> <div id="outline-container-orgdf16851" class="outline-4">
<h4 id="orgf57b5e6"><span class="section-number-4">2.1.4</span> C interface</h4> <h4 id="orgdf16851"><span class="section-number-4">2.1.4</span> C interface</h4>
</div> </div>
<div id="outline-container-org898f254" class="outline-4"> <div id="outline-container-orgd54be83" class="outline-4">
<h4 id="org898f254"><span class="section-number-4">2.1.5</span> Fortran interface</h4> <h4 id="orgd54be83"><span class="section-number-4">2.1.5</span> Fortran interface</h4>
</div> </div>
<div id="outline-container-orgb4ff218" class="outline-4"> <div id="outline-container-orgc26b6f3" class="outline-4">
<h4 id="orgb4ff218"><span class="section-number-4">2.1.6</span> Test</h4> <h4 id="orgc26b6f3"><span class="section-number-4">2.1.6</span> Test</h4>
<div class="outline-text-4" id="text-2-1-6"> <div class="outline-text-4" id="text-2-1-6">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-f90"><span style="color: #228b22;">integer</span>(<span style="color: #008b8b;">c_int32_t</span>) <span style="color: #a020f0;">function</span> <span style="color: #0000ff;">test_qmckl_ao_power</span>(context) <span style="color: #a020f0;">bind</span>(C) <pre class="src src-f90"><span style="color: #228b22;">integer</span>(<span style="color: #008b8b;">c_int32_t</span>) <span style="color: #a020f0;">function</span> <span style="color: #0000ff;">test_qmckl_ao_power</span>(context) <span style="color: #a020f0;">bind</span>(C)
@ -793,8 +793,8 @@ the \(n\) points:
</div> </div>
</div> </div>
<div id="outline-container-org9aa3e7c" class="outline-3"> <div id="outline-container-org3238ff8" class="outline-3">
<h3 id="org9aa3e7c"><span class="section-number-3">2.2</span> Value, Gradient and Laplacian of a polynomial</h3> <h3 id="org3238ff8"><span class="section-number-3">2.2</span> Value, Gradient and Laplacian of a polynomial</h3>
<div class="outline-text-3" id="text-2-2"> <div class="outline-text-3" id="text-2-2">
<p> <p>
A polynomial is centered on a nucleus \(\mathbf{R}_i\) A polynomial is centered on a nucleus \(\mathbf{R}_i\)
@ -839,7 +839,7 @@ Laplacians at a given point in space, of all polynomials with an
angular momentum up to <code>lmax</code>. angular momentum up to <code>lmax</code>.
</p> </p>
<table id="orge94f30d" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides"> <table id="org87b439e" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
<colgroup> <colgroup>
@ -918,8 +918,8 @@ angular momentum up to <code>lmax</code>.
</table> </table>
</div> </div>
<div id="outline-container-org05f71d2" class="outline-4"> <div id="outline-container-org93123f2" class="outline-4">
<h4 id="org05f71d2"><span class="section-number-4">2.2.1</span> Requirements</h4> <h4 id="org93123f2"><span class="section-number-4">2.2.1</span> Requirements</h4>
<div class="outline-text-4" id="text-2-2-1"> <div class="outline-text-4" id="text-2-2-1">
<ul class="org-ul"> <ul class="org-ul">
<li><code>context</code> is not <code>QMCKL_NULL_CONTEXT</code></li> <li><code>context</code> is not <code>QMCKL_NULL_CONTEXT</code></li>
@ -944,8 +944,8 @@ For example, with a=0, b=2 and c=1 the string is "yyz"</li>
</div> </div>
</div> </div>
<div id="outline-container-org1527e1b" class="outline-4"> <div id="outline-container-org965b7ad" class="outline-4">
<h4 id="org1527e1b"><span class="section-number-4">2.2.2</span> C Header</h4> <h4 id="org965b7ad"><span class="section-number-4">2.2.2</span> C Header</h4>
<div class="outline-text-4" id="text-2-2-2"> <div class="outline-text-4" id="text-2-2-2">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_ao_polynomial_vgl</span> ( <pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_ao_polynomial_vgl</span> (
@ -963,8 +963,8 @@ For example, with a=0, b=2 and c=1 the string is "yyz"</li>
</div> </div>
</div> </div>
<div id="outline-container-orgc927910" class="outline-4"> <div id="outline-container-org375d0fa" class="outline-4">
<h4 id="orgc927910"><span class="section-number-4">2.2.3</span> Source</h4> <h4 id="org375d0fa"><span class="section-number-4">2.2.3</span> Source</h4>
<div class="outline-text-4" id="text-2-2-3"> <div class="outline-text-4" id="text-2-2-3">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-f90"><span style="color: #228b22;">integer </span><span style="color: #a020f0;">function</span><span style="color: #a0522d;"> </span><span style="color: #0000ff;">qmckl_ao_polynomial_vgl_f</span><span style="color: #000000; background-color: #ffffff;">(context, X, R, lmax, n, L, ldl, VGL, ldv) result(info)</span> <pre class="src src-f90"><span style="color: #228b22;">integer </span><span style="color: #a020f0;">function</span><span style="color: #a0522d;"> </span><span style="color: #0000ff;">qmckl_ao_polynomial_vgl_f</span><span style="color: #000000; background-color: #ffffff;">(context, X, R, lmax, n, L, ldl, VGL, ldv) result(info)</span>
@ -1099,16 +1099,16 @@ For example, with a=0, b=2 and c=1 the string is "yyz"</li>
</div> </div>
</div> </div>
<div id="outline-container-org172b6f2" class="outline-4"> <div id="outline-container-orga3a66b0" class="outline-4">
<h4 id="org172b6f2"><span class="section-number-4">2.2.4</span> C interface</h4> <h4 id="orga3a66b0"><span class="section-number-4">2.2.4</span> C interface</h4>
</div> </div>
<div id="outline-container-org2d4b852" class="outline-4"> <div id="outline-container-org8d562b3" class="outline-4">
<h4 id="org2d4b852"><span class="section-number-4">2.2.5</span> Fortran interface</h4> <h4 id="org8d562b3"><span class="section-number-4">2.2.5</span> Fortran interface</h4>
</div> </div>
<div id="outline-container-org6fd7e9b" class="outline-4"> <div id="outline-container-org2d34055" class="outline-4">
<h4 id="org6fd7e9b"><span class="section-number-4">2.2.6</span> Test</h4> <h4 id="org2d34055"><span class="section-number-4">2.2.6</span> Test</h4>
<div class="outline-text-4" id="text-2-2-6"> <div class="outline-text-4" id="text-2-2-6">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-f90"><span style="color: #228b22;">integer</span>(<span style="color: #008b8b;">c_int32_t</span>) <span style="color: #a020f0;">function</span> <span style="color: #0000ff;">test_qmckl_ao_polynomial_vgl</span>(context) <span style="color: #a020f0;">bind</span>(C) <pre class="src src-f90"><span style="color: #228b22;">integer</span>(<span style="color: #008b8b;">c_int32_t</span>) <span style="color: #a020f0;">function</span> <span style="color: #0000ff;">test_qmckl_ao_polynomial_vgl</span>(context) <span style="color: #a020f0;">bind</span>(C)
@ -1213,12 +1213,12 @@ assert(0 == test_qmckl_ao_polynomial_vgl(context));
</div> </div>
</div> </div>
<div id="outline-container-org42e061e" class="outline-2"> <div id="outline-container-org0bc195a" class="outline-2">
<h2 id="org42e061e"><span class="section-number-2">3</span> Radial part</h2> <h2 id="org0bc195a"><span class="section-number-2">3</span> Radial part</h2>
<div class="outline-text-2" id="text-3"> <div class="outline-text-2" id="text-3">
</div> </div>
<div id="outline-container-org9c9f595" class="outline-3"> <div id="outline-container-org60113b2" class="outline-3">
<h3 id="org9c9f595"><span class="section-number-3">3.1</span> Gaussian basis functions</h3> <h3 id="org60113b2"><span class="section-number-3">3.1</span> Gaussian basis functions</h3>
<div class="outline-text-3" id="text-3-1"> <div class="outline-text-3" id="text-3-1">
<p> <p>
<code>qmckl_ao_gaussian_vgl</code> computes the values, gradients and <code>qmckl_ao_gaussian_vgl</code> computes the values, gradients and
@ -1450,21 +1450,21 @@ Requirements
</div> </div>
</div> </div>
<div id="outline-container-org1a9549b" class="outline-3"> <div id="outline-container-orgd4e1d85" class="outline-3">
<h3 id="org1a9549b"><span class="section-number-3">3.2</span> <span class="todo TODO">TODO</span> Slater basis functions</h3> <h3 id="orgd4e1d85"><span class="section-number-3">3.2</span> <span class="todo TODO">TODO</span> Slater basis functions</h3>
</div> </div>
<div id="outline-container-org70b226c" class="outline-3"> <div id="outline-container-org3b5c9fc" class="outline-3">
<h3 id="org70b226c"><span class="section-number-3">3.3</span> <span class="todo TODO">TODO</span> Radial functions on a grid</h3> <h3 id="org3b5c9fc"><span class="section-number-3">3.3</span> <span class="todo TODO">TODO</span> Radial functions on a grid</h3>
</div> </div>
</div> </div>
<div id="outline-container-orgaca3955" class="outline-2"> <div id="outline-container-org6971b57" class="outline-2">
<h2 id="orgaca3955"><span class="section-number-2">4</span> Combining radial and polynomial parts</h2> <h2 id="org6971b57"><span class="section-number-2">4</span> Combining radial and polynomial parts</h2>
</div> </div>
</div> </div>
<div id="postamble" class="status"> <div id="postamble" class="status">
<p class="author">Author: TREX CoE</p> <p class="author">Author: TREX CoE</p>
<p class="date">Created: 2021-05-18 Tue 23:32</p> <p class="date">Created: 2021-05-18 Tue 23:38</p>
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p> <p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
</div> </div>
</body> </body>

View File

@ -3,7 +3,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head> <head>
<!-- 2021-05-18 Tue 23:32 --> <!-- 2021-05-18 Tue 23:38 -->
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Context</title> <title>Context</title>
@ -311,21 +311,21 @@ for the JavaScript code in this tag.
<h2>Table of Contents</h2> <h2>Table of Contents</h2>
<div id="text-table-of-contents"> <div id="text-table-of-contents">
<ul> <ul>
<li><a href="#org6298d6e">1. Context handling</a> <li><a href="#orgc0ed7ce">1. Context handling</a>
<ul> <ul>
<li><a href="#org5b6c069">1.1. Data structure</a></li> <li><a href="#org81ea35b">1.1. Data structure</a></li>
<li><a href="#orgcd54caa">1.2. Creation</a></li> <li><a href="#org7284395">1.2. Creation</a></li>
<li><a href="#org68f7f9f">1.3. Locking</a></li> <li><a href="#org7381299">1.3. Locking</a></li>
<li><a href="#orgb6b1ac9">1.4. <span class="todo TODO">TODO</span> Copy</a></li> <li><a href="#org1c3ffe4">1.4. <span class="todo TODO">TODO</span> Copy</a></li>
<li><a href="#orge80cdd5">1.5. Destroy</a></li> <li><a href="#org6a82e8c">1.5. Destroy</a></li>
</ul> </ul>
</li> </li>
</ul> </ul>
</div> </div>
</div> </div>
<div id="outline-container-org6298d6e" class="outline-2"> <div id="outline-container-orgc0ed7ce" class="outline-2">
<h2 id="org6298d6e"><span class="section-number-2">1</span> Context handling</h2> <h2 id="orgc0ed7ce"><span class="section-number-2">1</span> Context handling</h2>
<div class="outline-text-2" id="text-1"> <div class="outline-text-2" id="text-1">
<p> <p>
The context variable is a handle for the state of the library, The context variable is a handle for the state of the library,
@ -338,7 +338,7 @@ A value of <code>QMCKL_NULL_CONTEXT</code> for the context is equivalent to a
</p> </p>
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c" id="org51ef2cd"><span style="color: #a020f0;">typedef</span> <span style="color: #228b22;">int64_t</span> <span style="color: #228b22;">qmckl_context</span> ; <pre class="src src-c" id="orge56eb17"><span style="color: #a020f0;">typedef</span> <span style="color: #228b22;">int64_t</span> <span style="color: #228b22;">qmckl_context</span> ;
<span style="color: #483d8b;">#define</span> <span style="color: #a0522d;">QMCKL_NULL_CONTEXT</span> (qmckl_context) 0 <span style="color: #483d8b;">#define</span> <span style="color: #a0522d;">QMCKL_NULL_CONTEXT</span> (qmckl_context) 0
</pre> </pre>
</div> </div>
@ -356,8 +356,8 @@ and <code>ctx</code> is a <code>qmckl_context_struct*</code> pointer.
</p> </p>
</div> </div>
<div id="outline-container-org5b6c069" class="outline-3"> <div id="outline-container-org81ea35b" class="outline-3">
<h3 id="org5b6c069"><span class="section-number-3">1.1</span> Data structure</h3> <h3 id="org81ea35b"><span class="section-number-3">1.1</span> Data structure</h3>
<div class="outline-text-3" id="text-1-1"> <div class="outline-text-3" id="text-1-1">
<p> <p>
The context keeps a ``date'' that allows to check which data needs The context keeps a ``date'' that allows to check which data needs
@ -367,7 +367,7 @@ coordinates are updated.
<p> <p>
When a new element is added to the context, the functions When a new element is added to the context, the functions
<a href="#orgcd54caa">qmckl<sub>context</sub><sub>create</sub></a>, <a href="#orge80cdd5">qmckl<sub>context</sub><sub>destroy</sub></a> and <a href="#orgb6b1ac9">qmckl<sub>context</sub><sub>copy</sub></a> <a href="#org7284395">qmckl<sub>context</sub><sub>create</sub></a>, <a href="#org6a82e8c">qmckl<sub>context</sub><sub>destroy</sub></a> and <a href="#org1c3ffe4">qmckl<sub>context</sub><sub>copy</sub></a>
should be updated inorder to make deep copies. should be updated inorder to make deep copies.
</p> </p>
@ -416,8 +416,8 @@ if the context is valid, <code>QMCKL_NULL_CONTEXT</code> otherwise.
</div> </div>
</div> </div>
<div id="outline-container-orgcd54caa" class="outline-3"> <div id="outline-container-org7284395" class="outline-3">
<h3 id="orgcd54caa"><span class="section-number-3">1.2</span> Creation</h3> <h3 id="org7284395"><span class="section-number-3">1.2</span> Creation</h3>
<div class="outline-text-3" id="text-1-2"> <div class="outline-text-3" id="text-1-2">
<p> <p>
To create a new context, <code>qmckl_context_create()</code> should be used. To create a new context, <code>qmckl_context_create()</code> should be used.
@ -492,8 +492,8 @@ To create a new context, <code>qmckl_context_create()</code> should be used.
</div> </div>
</div> </div>
</div> </div>
<div id="outline-container-org68f7f9f" class="outline-3"> <div id="outline-container-org7381299" class="outline-3">
<h3 id="org68f7f9f"><span class="section-number-3">1.3</span> Locking</h3> <h3 id="org7381299"><span class="section-number-3">1.3</span> Locking</h3>
<div class="outline-text-3" id="text-1-3"> <div class="outline-text-3" id="text-1-3">
<p> <p>
For thread safety, the context may be locked/unlocked. The lock is For thread safety, the context may be locked/unlocked. The lock is
@ -538,8 +538,8 @@ number of times the thread has locked it is saved in the
</div> </div>
</div> </div>
<div id="outline-container-orgb6b1ac9" class="outline-3"> <div id="outline-container-org1c3ffe4" class="outline-3">
<h3 id="orgb6b1ac9"><span class="section-number-3">1.4</span> <span class="todo TODO">TODO</span> Copy</h3> <h3 id="org1c3ffe4"><span class="section-number-3">1.4</span> <span class="todo TODO">TODO</span> Copy</h3>
<div class="outline-text-3" id="text-1-4"> <div class="outline-text-3" id="text-1-4">
<p> <p>
<code>qmckl_context_copy</code> makes a deep copy of a context. It returns <code>qmckl_context_copy</code> makes a deep copy of a context. It returns
@ -587,8 +587,8 @@ number of times the thread has locked it is saved in the
</div> </div>
</div> </div>
</div> </div>
<div id="outline-container-orge80cdd5" class="outline-3"> <div id="outline-container-org6a82e8c" class="outline-3">
<h3 id="orge80cdd5"><span class="section-number-3">1.5</span> Destroy</h3> <h3 id="org6a82e8c"><span class="section-number-3">1.5</span> Destroy</h3>
<div class="outline-text-3" id="text-1-5"> <div class="outline-text-3" id="text-1-5">
<p> <p>
The context is destroyed with <code>qmckl_context_destroy</code>, leaving the ancestors untouched. The context is destroyed with <code>qmckl_context_destroy</code>, leaving the ancestors untouched.
@ -642,7 +642,7 @@ It frees the context, and returns the previous context.
</div> </div>
<div id="postamble" class="status"> <div id="postamble" class="status">
<p class="author">Author: TREX CoE</p> <p class="author">Author: TREX CoE</p>
<p class="date">Created: 2021-05-18 Tue 23:32</p> <p class="date">Created: 2021-05-18 Tue 23:38</p>
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p> <p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
</div> </div>
</body> </body>

View File

@ -3,7 +3,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head> <head>
<!-- 2021-05-18 Tue 23:33 --> <!-- 2021-05-18 Tue 23:38 -->
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Inter-particle distances</title> <title>Inter-particle distances</title>
@ -333,26 +333,26 @@ for the JavaScript code in this tag.
<h2>Table of Contents</h2> <h2>Table of Contents</h2>
<div id="text-table-of-contents"> <div id="text-table-of-contents">
<ul> <ul>
<li><a href="#orgfd597cc">1. Squared distance</a> <li><a href="#orgfc06996">1. Squared distance</a>
<ul> <ul>
<li><a href="#orgf842b40">1.1. <code>qmckl_distance_sq</code></a> <li><a href="#org0601f32">1.1. <code>qmckl_distance_sq</code></a>
<ul> <ul>
<li><a href="#orgca18732">1.1.1. Requirements</a></li> <li><a href="#orge06636c">1.1.1. Requirements</a></li>
<li><a href="#org6b79fc4">1.1.2. C header</a></li> <li><a href="#org9e7ccfc">1.1.2. C header</a></li>
<li><a href="#orgd7230eb">1.1.3. Source</a></li> <li><a href="#orge152dd9">1.1.3. Source</a></li>
<li><a href="#orgbe9540c">1.1.4. Performance</a></li> <li><a href="#org2f7f813">1.1.4. Performance</a></li>
</ul> </ul>
</li> </li>
</ul> </ul>
</li> </li>
<li><a href="#org7b49a08">2. Distance</a> <li><a href="#orgdd5384d">2. Distance</a>
<ul> <ul>
<li><a href="#orgc93a75f">2.1. <code>qmckl_distance</code></a> <li><a href="#org57bda28">2.1. <code>qmckl_distance</code></a>
<ul> <ul>
<li><a href="#org8a65fdd">2.1.1. Requirements</a></li> <li><a href="#org86bf38b">2.1.1. Requirements</a></li>
<li><a href="#org3a6aa2c">2.1.2. C header</a></li> <li><a href="#orgf09ca9a">2.1.2. C header</a></li>
<li><a href="#orgfc61a7b">2.1.3. Source</a></li> <li><a href="#orgade8cb5">2.1.3. Source</a></li>
<li><a href="#orgf5df4ab">2.1.4. Performance</a></li> <li><a href="#org400427d">2.1.4. Performance</a></li>
</ul> </ul>
</li> </li>
</ul> </ul>
@ -361,12 +361,12 @@ for the JavaScript code in this tag.
</div> </div>
</div> </div>
<div id="outline-container-orgfd597cc" class="outline-2"> <div id="outline-container-orgfc06996" class="outline-2">
<h2 id="orgfd597cc"><span class="section-number-2">1</span> Squared distance</h2> <h2 id="orgfc06996"><span class="section-number-2">1</span> Squared distance</h2>
<div class="outline-text-2" id="text-1"> <div class="outline-text-2" id="text-1">
</div> </div>
<div id="outline-container-orgf842b40" class="outline-3"> <div id="outline-container-org0601f32" class="outline-3">
<h3 id="orgf842b40"><span class="section-number-3">1.1</span> <code>qmckl_distance_sq</code></h3> <h3 id="org0601f32"><span class="section-number-3">1.1</span> <code>qmckl_distance_sq</code></h3>
<div class="outline-text-3" id="text-1-1"> <div class="outline-text-3" id="text-1-1">
<p> <p>
<code>qmckl_distance_sq</code> computes the matrix of the squared distances <code>qmckl_distance_sq</code> computes the matrix of the squared distances
@ -379,7 +379,7 @@ between all pairs of points in two sets, one point within each set:
\] \]
</p> </p>
<table id="orgdbc0c13" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides"> <table id="org87c5752" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
<colgroup> <colgroup>
@ -472,8 +472,8 @@ between all pairs of points in two sets, one point within each set:
</table> </table>
</div> </div>
<div id="outline-container-orgca18732" class="outline-4"> <div id="outline-container-orge06636c" class="outline-4">
<h4 id="orgca18732"><span class="section-number-4">1.1.1</span> Requirements</h4> <h4 id="orge06636c"><span class="section-number-4">1.1.1</span> Requirements</h4>
<div class="outline-text-4" id="text-1-1-1"> <div class="outline-text-4" id="text-1-1-1">
<ul class="org-ul"> <ul class="org-ul">
<li><code>context</code> is not <code>QMCKL_NULL_CONTEXT</code></li> <li><code>context</code> is not <code>QMCKL_NULL_CONTEXT</code></li>
@ -491,8 +491,8 @@ between all pairs of points in two sets, one point within each set:
</div> </div>
</div> </div>
<div id="outline-container-org6b79fc4" class="outline-4"> <div id="outline-container-org9e7ccfc" class="outline-4">
<h4 id="org6b79fc4"><span class="section-number-4">1.1.2</span> C header</h4> <h4 id="org9e7ccfc"><span class="section-number-4">1.1.2</span> C header</h4>
<div class="outline-text-4" id="text-1-1-2"> <div class="outline-text-4" id="text-1-1-2">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_distance</span> ( <pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_distance</span> (
@ -512,8 +512,8 @@ between all pairs of points in two sets, one point within each set:
</div> </div>
</div> </div>
<div id="outline-container-orgd7230eb" class="outline-4"> <div id="outline-container-orge152dd9" class="outline-4">
<h4 id="orgd7230eb"><span class="section-number-4">1.1.3</span> Source</h4> <h4 id="orge152dd9"><span class="section-number-4">1.1.3</span> Source</h4>
<div class="outline-text-4" id="text-1-1-3"> <div class="outline-text-4" id="text-1-1-3">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-f90"><span style="color: #228b22;">integer</span><span style="color: #a0522d;"> function qmckl_distance_sq_f(context, transa, transb, m, n, </span><span style="color: #a020f0;">&amp;</span> <pre class="src src-f90"><span style="color: #228b22;">integer</span><span style="color: #a0522d;"> function qmckl_distance_sq_f(context, transa, transb, m, n, </span><span style="color: #a020f0;">&amp;</span>
@ -648,8 +648,8 @@ between all pairs of points in two sets, one point within each set:
</div> </div>
</div> </div>
<div id="outline-container-orgbe9540c" class="outline-4"> <div id="outline-container-org2f7f813" class="outline-4">
<h4 id="orgbe9540c"><span class="section-number-4">1.1.4</span> Performance</h4> <h4 id="org2f7f813"><span class="section-number-4">1.1.4</span> Performance</h4>
<div class="outline-text-4" id="text-1-1-4"> <div class="outline-text-4" id="text-1-1-4">
<p> <p>
This function is more efficient when <code>A</code> and <code>B</code> are This function is more efficient when <code>A</code> and <code>B</code> are
@ -659,12 +659,12 @@ transposed.
</div> </div>
</div> </div>
</div> </div>
<div id="outline-container-org7b49a08" class="outline-2"> <div id="outline-container-orgdd5384d" class="outline-2">
<h2 id="org7b49a08"><span class="section-number-2">2</span> Distance</h2> <h2 id="orgdd5384d"><span class="section-number-2">2</span> Distance</h2>
<div class="outline-text-2" id="text-2"> <div class="outline-text-2" id="text-2">
</div> </div>
<div id="outline-container-orgc93a75f" class="outline-3"> <div id="outline-container-org57bda28" class="outline-3">
<h3 id="orgc93a75f"><span class="section-number-3">2.1</span> <code>qmckl_distance</code></h3> <h3 id="org57bda28"><span class="section-number-3">2.1</span> <code>qmckl_distance</code></h3>
<div class="outline-text-3" id="text-2-1"> <div class="outline-text-3" id="text-2-1">
<p> <p>
<code>qmckl_distance</code> computes the matrix of the distances between all <code>qmckl_distance</code> computes the matrix of the distances between all
@ -682,7 +682,7 @@ If the input array is normal (<code>'N'</code>), the xyz coordinates are in
the leading dimension: <code>[n][3]</code> in C and <code>(3,n)</code> in Fortran. the leading dimension: <code>[n][3]</code> in C and <code>(3,n)</code> in Fortran.
</p> </p>
<table id="orge4c6738" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides"> <table id="orgf4b27d1" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
<colgroup> <colgroup>
@ -775,8 +775,8 @@ the leading dimension: <code>[n][3]</code> in C and <code>(3,n)</code> in Fortra
</table> </table>
</div> </div>
<div id="outline-container-org8a65fdd" class="outline-4"> <div id="outline-container-org86bf38b" class="outline-4">
<h4 id="org8a65fdd"><span class="section-number-4">2.1.1</span> Requirements</h4> <h4 id="org86bf38b"><span class="section-number-4">2.1.1</span> Requirements</h4>
<div class="outline-text-4" id="text-2-1-1"> <div class="outline-text-4" id="text-2-1-1">
<ul class="org-ul"> <ul class="org-ul">
<li><code>context</code> is not <code>QMCKL_NULL_CONTEXT</code></li> <li><code>context</code> is not <code>QMCKL_NULL_CONTEXT</code></li>
@ -794,8 +794,8 @@ the leading dimension: <code>[n][3]</code> in C and <code>(3,n)</code> in Fortra
</div> </div>
</div> </div>
<div id="outline-container-org3a6aa2c" class="outline-4"> <div id="outline-container-orgf09ca9a" class="outline-4">
<h4 id="org3a6aa2c"><span class="section-number-4">2.1.2</span> C header</h4> <h4 id="orgf09ca9a"><span class="section-number-4">2.1.2</span> C header</h4>
<div class="outline-text-4" id="text-2-1-2"> <div class="outline-text-4" id="text-2-1-2">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_distance</span> ( <pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_distance</span> (
@ -815,8 +815,8 @@ the leading dimension: <code>[n][3]</code> in C and <code>(3,n)</code> in Fortra
</div> </div>
</div> </div>
<div id="outline-container-orgfc61a7b" class="outline-4"> <div id="outline-container-orgade8cb5" class="outline-4">
<h4 id="orgfc61a7b"><span class="section-number-4">2.1.3</span> Source</h4> <h4 id="orgade8cb5"><span class="section-number-4">2.1.3</span> Source</h4>
<div class="outline-text-4" id="text-2-1-3"> <div class="outline-text-4" id="text-2-1-3">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-f90"><span style="color: #228b22;">integer</span><span style="color: #a0522d;"> function qmckl_distance_f(context, transa, transb, m, n, </span><span style="color: #a020f0;">&amp;</span> <pre class="src src-f90"><span style="color: #228b22;">integer</span><span style="color: #a0522d;"> function qmckl_distance_f(context, transa, transb, m, n, </span><span style="color: #a020f0;">&amp;</span>
@ -955,8 +955,8 @@ the leading dimension: <code>[n][3]</code> in C and <code>(3,n)</code> in Fortra
</div> </div>
</div> </div>
<div id="outline-container-orgf5df4ab" class="outline-4"> <div id="outline-container-org400427d" class="outline-4">
<h4 id="orgf5df4ab"><span class="section-number-4">2.1.4</span> Performance</h4> <h4 id="org400427d"><span class="section-number-4">2.1.4</span> Performance</h4>
<div class="outline-text-4" id="text-2-1-4"> <div class="outline-text-4" id="text-2-1-4">
<p> <p>
This function is more efficient when <code>A</code> and <code>B</code> are transposed. This function is more efficient when <code>A</code> and <code>B</code> are transposed.
@ -968,7 +968,7 @@ This function is more efficient when <code>A</code> and <code>B</code> are trans
</div> </div>
<div id="postamble" class="status"> <div id="postamble" class="status">
<p class="author">Author: TREX CoE</p> <p class="author">Author: TREX CoE</p>
<p class="date">Created: 2021-05-18 Tue 23:33</p> <p class="date">Created: 2021-05-18 Tue 23:38</p>
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p> <p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
</div> </div>
</body> </body>

View File

@ -3,7 +3,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head> <head>
<!-- 2021-05-18 Tue 23:32 --> <!-- 2021-05-18 Tue 23:38 -->
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Electrons</title> <title>Electrons</title>
@ -311,34 +311,34 @@ for the JavaScript code in this tag.
<h2>Table of Contents</h2> <h2>Table of Contents</h2>
<div id="text-table-of-contents"> <div id="text-table-of-contents">
<ul> <ul>
<li><a href="#orgc550db7">1. Context</a> <li><a href="#org0c7a537">1. Context</a>
<ul> <ul>
<li><a href="#org21908af">1.1. Data structure</a></li> <li><a href="#orgf8bf8e1">1.1. Data structure</a></li>
<li><a href="#orgc205ade">1.2. Access functions</a> <li><a href="#org6263198">1.2. Access functions</a>
<ul> <ul>
<li><a href="#orgc4b796a">1.2.1. Number of electrons</a></li> <li><a href="#org557e536">1.2.1. Number of electrons</a></li>
<li><a href="#org09c0ebc">1.2.2. Number of walkers</a></li> <li><a href="#org3d95a4d">1.2.2. Number of walkers</a></li>
<li><a href="#org926985c">1.2.3. Electron coordinates</a></li> <li><a href="#orgfd24937">1.2.3. Electron coordinates</a></li>
</ul> </ul>
</li> </li>
<li><a href="#org0af01cc">1.3. Initialization functions</a></li> <li><a href="#org42b0293">1.3. Initialization functions</a></li>
<li><a href="#orge550a96">1.4. Test</a></li> <li><a href="#org7b15da7">1.4. Test</a></li>
</ul> </ul>
</li> </li>
<li><a href="#orgd481931">2. Computation</a> <li><a href="#org3d6cc0b">2. Computation</a>
<ul> <ul>
<li><a href="#org3b53198">2.1. Electron-electron distances</a> <li><a href="#orgb5be66d">2.1. Electron-electron distances</a>
<ul> <ul>
<li><a href="#org59b0f4a">2.1.1. Get</a></li> <li><a href="#orgcbc7f22">2.1.1. Get</a></li>
<li><a href="#org0352ed3">2.1.2. Compute</a></li> <li><a href="#org2efd1d4">2.1.2. Compute</a></li>
<li><a href="#org9ec7f5a">2.1.3. Test</a></li> <li><a href="#org324613b">2.1.3. Test</a></li>
</ul> </ul>
</li> </li>
<li><a href="#org15a922e">2.2. Electron-nucleus distances</a> <li><a href="#org4e5458a">2.2. Electron-nucleus distances</a>
<ul> <ul>
<li><a href="#org6d804db">2.2.1. Get</a></li> <li><a href="#orgb4f1577">2.2.1. Get</a></li>
<li><a href="#org7e27cb4">2.2.2. Compute</a></li> <li><a href="#orgb470a79">2.2.2. Compute</a></li>
<li><a href="#orgd04408e">2.2.3. Test</a></li> <li><a href="#org17ff798">2.2.3. Test</a></li>
</ul> </ul>
</li> </li>
</ul> </ul>
@ -347,8 +347,8 @@ for the JavaScript code in this tag.
</div> </div>
</div> </div>
<div id="outline-container-orgc550db7" class="outline-2"> <div id="outline-container-org0c7a537" class="outline-2">
<h2 id="orgc550db7"><span class="section-number-2">1</span> Context</h2> <h2 id="org0c7a537"><span class="section-number-2">1</span> Context</h2>
<div class="outline-text-2" id="text-1"> <div class="outline-text-2" id="text-1">
<p> <p>
The following data stored in the context: The following data stored in the context:
@ -446,8 +446,8 @@ The following data stored in the context:
</table> </table>
</div> </div>
<div id="outline-container-org21908af" class="outline-3"> <div id="outline-container-orgf8bf8e1" class="outline-3">
<h3 id="org21908af"><span class="section-number-3">1.1</span> Data structure</h3> <h3 id="orgf8bf8e1"><span class="section-number-3">1.1</span> Data structure</h3>
<div class="outline-text-3" id="text-1-1"> <div class="outline-text-3" id="text-1-1">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c"><span style="color: #a020f0;">typedef</span> <span style="color: #a020f0;">struct</span> <span style="color: #228b22;">qmckl_electron_struct</span> { <pre class="src src-c"><span style="color: #a020f0;">typedef</span> <span style="color: #a020f0;">struct</span> <span style="color: #228b22;">qmckl_electron_struct</span> {
@ -487,8 +487,8 @@ following function returns <code>true</code>.
</div> </div>
</div> </div>
<div id="outline-container-orgc205ade" class="outline-3"> <div id="outline-container-org6263198" class="outline-3">
<h3 id="orgc205ade"><span class="section-number-3">1.2</span> Access functions</h3> <h3 id="org6263198"><span class="section-number-3">1.2</span> Access functions</h3>
<div class="outline-text-3" id="text-1-2"> <div class="outline-text-3" id="text-1-2">
<p> <p>
Access functions return <code>QMCKL_SUCCESS</code> when the data has been Access functions return <code>QMCKL_SUCCESS</code> when the data has been
@ -500,12 +500,12 @@ contains the requested data. Otherwise, this variable is untouched.
</p> </p>
</div> </div>
<div id="outline-container-orgc4b796a" class="outline-4"> <div id="outline-container-org557e536" class="outline-4">
<h4 id="orgc4b796a"><span class="section-number-4">1.2.1</span> Number of electrons</h4> <h4 id="org557e536"><span class="section-number-4">1.2.1</span> Number of electrons</h4>
</div> </div>
<div id="outline-container-org09c0ebc" class="outline-4"> <div id="outline-container-org3d95a4d" class="outline-4">
<h4 id="org09c0ebc"><span class="section-number-4">1.2.2</span> Number of walkers</h4> <h4 id="org3d95a4d"><span class="section-number-4">1.2.2</span> Number of walkers</h4>
<div class="outline-text-4" id="text-1-2-2"> <div class="outline-text-4" id="text-1-2-2">
<p> <p>
A walker is a set of electron coordinates that are arguments of A walker is a set of electron coordinates that are arguments of
@ -514,21 +514,53 @@ the wave function. <code>walk_num</code> is the number of walkers.
</div> </div>
</div> </div>
<div id="outline-container-org926985c" class="outline-4"> <div id="outline-container-orgfd24937" class="outline-4">
<h4 id="org926985c"><span class="section-number-4">1.2.3</span> Electron coordinates</h4> <h4 id="orgfd24937"><span class="section-number-4">1.2.3</span> Electron coordinates</h4>
<div class="outline-text-4" id="text-1-2-3"> <div class="outline-text-4" id="text-1-2-3">
<p> <p>
Returns the current electron coordinates. The pointer is assumed Returns the current electron coordinates. The pointer is assumed
to point on a memory block of size <code>3 * elec_num * walk_num</code>. In C to point on a memory block of size <code>3 * elec_num * walk_num</code>.
the order of the indices is <code>[walk_num][3][elec_num]</code> and in The normal order of the indices is:
Fortran it is <code>(elec_num,3,walk_num)</code>.
</p> </p>
<table border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
<colgroup>
<col class="org-left" />
<col class="org-left" />
<col class="org-left" />
</colgroup>
<thead>
<tr>
<th scope="col" class="org-left">&#xa0;</th>
<th scope="col" class="org-left">Normal</th>
<th scope="col" class="org-left">Transposed</th>
</tr>
</thead>
<tbody>
<tr>
<td class="org-left">C</td>
<td class="org-left"><code>[walk_num][elec_num][3]</code></td>
<td class="org-left"><code>[walk_num][3][elec_num]</code></td>
</tr>
<tr>
<td class="org-left">Fortran</td>
<td class="org-left"><code>(3,elec_num,walk_num)</code></td>
<td class="org-left"><code>(elec_num,3,walk_num)</code></td>
</tr>
</tbody>
</table>
</div> </div>
</div> </div>
</div> </div>
<div id="outline-container-org0af01cc" class="outline-3">
<h3 id="org0af01cc"><span class="section-number-3">1.3</span> Initialization functions</h3> <div id="outline-container-org42b0293" class="outline-3">
<h3 id="org42b0293"><span class="section-number-3">1.3</span> Initialization functions</h3>
<div class="outline-text-3" id="text-1-3"> <div class="outline-text-3" id="text-1-3">
<p> <p>
To set the data relative to the electrons in the context, the To set the data relative to the electrons in the context, the
@ -540,7 +572,7 @@ both allocated.
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_set_electron_num</span> (<span style="color: #228b22;">qmckl_context</span> <span style="color: #a0522d;">context</span>, <span style="color: #a020f0;">const</span> <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">up_num</span>, <span style="color: #a020f0;">const</span> <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">down_num</span>); <pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_set_electron_num</span> (<span style="color: #228b22;">qmckl_context</span> <span style="color: #a0522d;">context</span>, <span style="color: #a020f0;">const</span> <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">up_num</span>, <span style="color: #a020f0;">const</span> <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">down_num</span>);
<span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_set_electron_walk_num</span> (<span style="color: #228b22;">qmckl_context</span> <span style="color: #a0522d;">context</span>, <span style="color: #a020f0;">const</span> <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">walk_num</span>); <span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_set_electron_walk_num</span> (<span style="color: #228b22;">qmckl_context</span> <span style="color: #a0522d;">context</span>, <span style="color: #a020f0;">const</span> <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">walk_num</span>);
<span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_set_electron_coord</span> (<span style="color: #228b22;">qmckl_context</span> <span style="color: #a0522d;">context</span>, <span style="color: #a020f0;">const</span> <span style="color: #228b22;">double</span>* <span style="color: #a0522d;">coord</span>); <span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_set_electron_coord</span> (<span style="color: #228b22;">qmckl_context</span> <span style="color: #a0522d;">context</span>, <span style="color: #a020f0;">const</span> <span style="color: #228b22;">char</span> <span style="color: #a0522d;">transp</span>, <span style="color: #a020f0;">const</span> <span style="color: #228b22;">double</span>* <span style="color: #a0522d;">coord</span>);
</pre> </pre>
</div> </div>
@ -556,35 +588,28 @@ of coordinates are swapped, and the new coordinates are
overwritten. This can be done only when the data relative to overwritten. This can be done only when the data relative to
electrons have been set. electrons have been set.
</p> </p>
<p>
Important: changing the electron coordinates increments the date
in the context.
</p>
</div> </div>
</div> </div>
<div id="outline-container-orge550a96" class="outline-3"> <div id="outline-container-org7b15da7" class="outline-3">
<h3 id="orge550a96"><span class="section-number-3">1.4</span> Test</h3> <h3 id="org7b15da7"><span class="section-number-3">1.4</span> Test</h3>
<div class="outline-text-3" id="text-1-4"> <div class="outline-text-3" id="text-1-4">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c">/* <span style="color: #b22222;">Reference input data </span>*/ <pre class="src src-c">/* <span style="color: #b22222;">Reference input data </span>*/
<span style="color: #a020f0;">const</span> <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">walk_num</span> = chbrclf_walk_num; <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">walk_num</span> = chbrclf_walk_num;
<span style="color: #a020f0;">const</span> <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">elec_num</span> = chbrclf_elec_num; <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">elec_num</span> = chbrclf_elec_num;
<span style="color: #a020f0;">const</span> <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">elec_up_num</span> = chbrclf_elec_up_num; <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">elec_up_num</span> = chbrclf_elec_up_num;
<span style="color: #a020f0;">const</span> <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">elec_dn_num</span> = chbrclf_elec_dn_num; <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">elec_dn_num</span> = chbrclf_elec_dn_num;
<span style="color: #a020f0;">const</span> <span style="color: #228b22;">double</span>*** <span style="color: #a0522d;">elec_coord</span> = chbrclf_elec_coord; <span style="color: #228b22;">double</span>* <span style="color: #a0522d;">elec_coord</span> = &amp;(chbrclf_elec_coord[0][0][0]);
<span style="color: #a020f0;">const</span> <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">nucl_num</span> = chbrclf_nucl_num; <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">nucl_num</span> = chbrclf_nucl_num;
<span style="color: #a020f0;">const</span> <span style="color: #228b22;">double</span>* <span style="color: #a0522d;">charge</span> = chbrclf_charge; <span style="color: #228b22;">double</span>* <span style="color: #a0522d;">charge</span> = chbrclf_charge;
<span style="color: #a020f0;">const</span> <span style="color: #228b22;">double</span>** <span style="color: #a0522d;">nucl_coord</span> = chbrclf_nucl_coord; <span style="color: #228b22;">double</span>* <span style="color: #a0522d;">nucl_coord</span> = &amp;(chbrclf_nucl_coord[0][0]);
<span style="color: #228b22;">double</span>* <span style="color: #a0522d;">coord</span> = (<span style="color: #228b22;">double</span>*) <span style="color: #0000ff;">malloc</span>(<span style="color: #228b22;">walk_num</span>*<span style="color: #0000ff;">num</span>*3*<span style="color: #a020f0;">sizeof</span>(<span style="color: #228b22;">double</span>));
<span style="color: #228b22;">double</span>* <span style="color: #a0522d;">x</span> = coord;
<span style="color: #a020f0;">for</span> (<span style="color: #228b22;">int</span> <span style="color: #a0522d;">i</span>=0 ; i&lt;walk_num ; ++i) {
<span style="color: #a020f0;">for</span> (<span style="color: #228b22;">int</span> <span style="color: #a0522d;">k</span>=0 ; k&lt;3 ; ++k) {
<span style="color: #a020f0;">for</span> (<span style="color: #228b22;">int</span> <span style="color: #a0522d;">j</span>=0 ; j&lt;num ; ++j) {
*x = coord_in[i][j][k];
x += 1;
}
}
}
/* <span style="color: #b22222;">--- </span>*/ /* <span style="color: #b22222;">--- </span>*/
@ -603,21 +628,21 @@ rc = qmckl_get_electron_down_num (context, &amp;n);
<span style="color: #0000ff;">assert</span>(rc == QMCKL_NOT_PROVIDED); <span style="color: #0000ff;">assert</span>(rc == QMCKL_NOT_PROVIDED);
rc = qmckl_set_electron_num (context, up_num, down_num); rc = qmckl_set_electron_num (context, elec_up_num, elec_dn_num);
<span style="color: #0000ff;">assert</span>(rc == QMCKL_SUCCESS); <span style="color: #0000ff;">assert</span>(rc == QMCKL_SUCCESS);
assert(!qmckl_electron_provided(context)); assert(!qmckl_electron_provided(context));
rc = qmckl_get_electron_up_num (context, &amp;n); rc = qmckl_get_electron_up_num (context, &amp;n);
<span style="color: #0000ff;">assert</span>(rc == QMCKL_SUCCESS); <span style="color: #0000ff;">assert</span>(rc == QMCKL_SUCCESS);
<span style="color: #0000ff;">assert</span>(n == up_num); <span style="color: #0000ff;">assert</span>(n == elec_up_num);
rc = qmckl_get_electron_down_num (context, &amp;n); rc = qmckl_get_electron_down_num (context, &amp;n);
<span style="color: #0000ff;">assert</span>(rc == QMCKL_SUCCESS); <span style="color: #0000ff;">assert</span>(rc == QMCKL_SUCCESS);
<span style="color: #0000ff;">assert</span>(n == down_num); <span style="color: #0000ff;">assert</span>(n == elec_dn_num);
rc = qmckl_get_electron_num (context, &amp;n); rc = qmckl_get_electron_num (context, &amp;n);
<span style="color: #0000ff;">assert</span>(rc == QMCKL_SUCCESS); <span style="color: #0000ff;">assert</span>(rc == QMCKL_SUCCESS);
<span style="color: #0000ff;">assert</span>(n == num); <span style="color: #0000ff;">assert</span>(n == elec_num);
<span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">w</span>; <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">w</span>;
@ -634,15 +659,15 @@ rc = qmckl_get_electron_walk_num (context, &amp;w);
<span style="color: #0000ff;">assert</span>(<span style="color: #228b22;">qmckl_electron_provided</span>(<span style="color: #a0522d;">context</span>)); <span style="color: #0000ff;">assert</span>(<span style="color: #228b22;">qmckl_electron_provided</span>(<span style="color: #a0522d;">context</span>));
rc = qmckl_set_electron_coord (context, coord); rc = qmckl_set_electron_coord (context, <span style="color: #8b2252;">'N'</span>, elec_coord);
<span style="color: #0000ff;">assert</span>(rc == QMCKL_SUCCESS); <span style="color: #0000ff;">assert</span>(rc == QMCKL_SUCCESS);
<span style="color: #228b22;">double</span> <span style="color: #a0522d;">coord2</span>[walk_num*3*num]; <span style="color: #228b22;">double</span> <span style="color: #a0522d;">elec_coord2</span>[walk_num*3*elec_num];
rc = qmckl_get_electron_coord (context, coord2); rc = qmckl_get_electron_coord (context, <span style="color: #8b2252;">'N'</span>, elec_coord2);
<span style="color: #0000ff;">assert</span>(rc == QMCKL_SUCCESS); <span style="color: #0000ff;">assert</span>(rc == QMCKL_SUCCESS);
<span style="color: #a020f0;">for</span> (<span style="color: #228b22;">size_t</span> <span style="color: #a0522d;">i</span>=0 ; i&lt;3*num ; ++i) { <span style="color: #a020f0;">for</span> (<span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">i</span>=0 ; i&lt;3*elec_num ; ++i) {
assert( coord[i] == coord2[i] ); assert( elec_coord[i] == elec_coord2[i] );
} }
</pre> </pre>
@ -651,8 +676,8 @@ rc = qmckl_get_electron_coord (context, coord2);
</div> </div>
</div> </div>
<div id="outline-container-orgd481931" class="outline-2"> <div id="outline-container-org3d6cc0b" class="outline-2">
<h2 id="orgd481931"><span class="section-number-2">2</span> Computation</h2> <h2 id="org3d6cc0b"><span class="section-number-2">2</span> Computation</h2>
<div class="outline-text-2" id="text-2"> <div class="outline-text-2" id="text-2">
<p> <p>
The computed data is stored in the context so that it can be reused The computed data is stored in the context so that it can be reused
@ -665,24 +690,24 @@ current date is stored.
</p> </p>
</div> </div>
<div id="outline-container-org3b53198" class="outline-3"> <div id="outline-container-orgb5be66d" class="outline-3">
<h3 id="org3b53198"><span class="section-number-3">2.1</span> Electron-electron distances</h3> <h3 id="orgb5be66d"><span class="section-number-3">2.1</span> Electron-electron distances</h3>
<div class="outline-text-3" id="text-2-1"> <div class="outline-text-3" id="text-2-1">
</div> </div>
<div id="outline-container-org59b0f4a" class="outline-4"> <div id="outline-container-orgcbc7f22" class="outline-4">
<h4 id="org59b0f4a"><span class="section-number-4">2.1.1</span> Get</h4> <h4 id="orgcbc7f22"><span class="section-number-4">2.1.1</span> Get</h4>
<div class="outline-text-4" id="text-2-1-1"> <div class="outline-text-4" id="text-2-1-1">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_get_electron_ee_distance</span>(<span style="color: #228b22;">qmckl_context</span> <span style="color: #a0522d;">context</span>, <span style="color: #228b22;">double</span>* <span style="color: #a0522d;">distance</span>); <pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_get_electron_ee_distance</span>(<span style="color: #228b22;">qmckl_context</span> <span style="color: #a0522d;">context</span>, <span style="color: #228b22;">double</span>* <span style="color: #a020f0;">const</span> <span style="color: #a0522d;">distance</span>);
</pre> </pre>
</div> </div>
</div> </div>
</div> </div>
<div id="outline-container-org0352ed3" class="outline-4"> <div id="outline-container-org2efd1d4" class="outline-4">
<h4 id="org0352ed3"><span class="section-number-4">2.1.2</span> Compute</h4> <h4 id="org2efd1d4"><span class="section-number-4">2.1.2</span> Compute</h4>
<div class="outline-text-4" id="text-2-1-2"> <div class="outline-text-4" id="text-2-1-2">
<table id="org310b126" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides"> <table id="orgbdc936a" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
<colgroup> <colgroup>
@ -778,13 +803,14 @@ current date is stored.
</div> </div>
</div> </div>
<div id="outline-container-org9ec7f5a" class="outline-4"> <div id="outline-container-org324613b" class="outline-4">
<h4 id="org9ec7f5a"><span class="section-number-4">2.1.3</span> Test</h4> <h4 id="org324613b"><span class="section-number-4">2.1.3</span> Test</h4>
<div class="outline-text-4" id="text-2-1-3"> <div class="outline-text-4" id="text-2-1-3">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c"><span style="color: #0000ff;">assert</span>(<span style="color: #228b22;">qmckl_electron_provided</span>(<span style="color: #a0522d;">context</span>)); <pre class="src src-c"><span style="color: #0000ff;">assert</span>(<span style="color: #228b22;">qmckl_electron_provided</span>(<span style="color: #a0522d;">context</span>));
<span style="color: #228b22;">double</span> <span style="color: #a0522d;">ee_distance</span>[walk_num*num*num];
<span style="color: #228b22;">double</span> <span style="color: #a0522d;">ee_distance</span>[walk_num * elec_num * elec_num];
rc = qmckl_get_electron_ee_distance(context, ee_distance); rc = qmckl_get_electron_ee_distance(context, ee_distance);
// <span style="color: #b22222;">(e1,e2,w)</span> // <span style="color: #b22222;">(e1,e2,w)</span>
@ -792,19 +818,19 @@ rc = qmckl_get_electron_ee_distance(context, ee_distance);
<span style="color: #0000ff;">assert</span>(<span style="color: #228b22;">ee_distance</span>[0] == 0.); <span style="color: #0000ff;">assert</span>(<span style="color: #228b22;">ee_distance</span>[0] == 0.);
// <span style="color: #b22222;">(1,0,0) == (0,1,0)</span> // <span style="color: #b22222;">(1,0,0) == (0,1,0)</span>
<span style="color: #0000ff;">assert</span>(<span style="color: #228b22;">ee_distance</span>[1] == ee_distance[num]); <span style="color: #0000ff;">assert</span>(<span style="color: #228b22;">ee_distance</span>[1] == ee_distance[elec_num]);
// <span style="color: #b22222;">value of (1,0,0)</span> // <span style="color: #b22222;">value of (1,0,0)</span>
<span style="color: #0000ff;">assert</span>(fabs(<span style="color: #228b22;">ee_distance</span>[1]-7.152322512964209) &lt; 1.e-12); <span style="color: #0000ff;">assert</span>(fabs(<span style="color: #228b22;">ee_distance</span>[1]-7.152322512964209) &lt; 1.e-12);
// <span style="color: #b22222;">(0,0,1) == 0.</span> // <span style="color: #b22222;">(0,0,1) == 0.</span>
<span style="color: #0000ff;">assert</span>(<span style="color: #228b22;">ee_distance</span>[num*num] == 0.); <span style="color: #0000ff;">assert</span>(<span style="color: #228b22;">ee_distance</span>[elec_num*elec_num] == 0.);
// <span style="color: #b22222;">(1,0,1) == (0,1,1)</span> // <span style="color: #b22222;">(1,0,1) == (0,1,1)</span>
<span style="color: #0000ff;">assert</span>(<span style="color: #228b22;">ee_distance</span>[num*num+1] == ee_distance[num*num+num]); <span style="color: #0000ff;">assert</span>(<span style="color: #228b22;">ee_distance</span>[elec_num*elec_num+1] == ee_distance[elec_num*elec_num+elec_num]);
// <span style="color: #b22222;">value of (1,0,1)</span> // <span style="color: #b22222;">value of (1,0,1)</span>
<span style="color: #0000ff;">assert</span>(fabs(<span style="color: #228b22;">ee_distance</span>[num*num+1]-6.5517646321055665) &lt; 1.e-12); <span style="color: #0000ff;">assert</span>(fabs(<span style="color: #228b22;">ee_distance</span>[elec_num*elec_num+1]-6.5517646321055665) &lt; 1.e-12);
</pre> </pre>
</div> </div>
@ -812,12 +838,12 @@ rc = qmckl_get_electron_ee_distance(context, ee_distance);
</div> </div>
</div> </div>
<div id="outline-container-org15a922e" class="outline-3"> <div id="outline-container-org4e5458a" class="outline-3">
<h3 id="org15a922e"><span class="section-number-3">2.2</span> Electron-nucleus distances</h3> <h3 id="org4e5458a"><span class="section-number-3">2.2</span> Electron-nucleus distances</h3>
<div class="outline-text-3" id="text-2-2"> <div class="outline-text-3" id="text-2-2">
</div> </div>
<div id="outline-container-org6d804db" class="outline-4"> <div id="outline-container-orgb4f1577" class="outline-4">
<h4 id="org6d804db"><span class="section-number-4">2.2.1</span> Get</h4> <h4 id="orgb4f1577"><span class="section-number-4">2.2.1</span> Get</h4>
<div class="outline-text-4" id="text-2-2-1"> <div class="outline-text-4" id="text-2-2-1">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_get_electron_en_distance</span>(<span style="color: #228b22;">qmckl_context</span> <span style="color: #a0522d;">context</span>, <span style="color: #228b22;">double</span>* <span style="color: #a0522d;">distance</span>); <pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_get_electron_en_distance</span>(<span style="color: #228b22;">qmckl_context</span> <span style="color: #a0522d;">context</span>, <span style="color: #228b22;">double</span>* <span style="color: #a0522d;">distance</span>);
@ -826,10 +852,10 @@ rc = qmckl_get_electron_ee_distance(context, ee_distance);
</div> </div>
</div> </div>
<div id="outline-container-org7e27cb4" class="outline-4"> <div id="outline-container-orgb470a79" class="outline-4">
<h4 id="org7e27cb4"><span class="section-number-4">2.2.2</span> Compute</h4> <h4 id="orgb470a79"><span class="section-number-4">2.2.2</span> Compute</h4>
<div class="outline-text-4" id="text-2-2-2"> <div class="outline-text-4" id="text-2-2-2">
<table id="orge984116" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides"> <table id="org3a32192" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
<colgroup> <colgroup>
@ -946,11 +972,12 @@ rc = qmckl_get_electron_ee_distance(context, ee_distance);
</div> </div>
</div> </div>
<div id="outline-container-orgd04408e" class="outline-4"> <div id="outline-container-org17ff798" class="outline-4">
<h4 id="orgd04408e"><span class="section-number-4">2.2.3</span> Test</h4> <h4 id="org17ff798"><span class="section-number-4">2.2.3</span> Test</h4>
<div class="outline-text-4" id="text-2-2-3"> <div class="outline-text-4" id="text-2-2-3">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c">assert(!qmckl_nucleus_provided(context)); <pre class="src src-c">
assert(!qmckl_nucleus_provided(context));
<span style="color: #0000ff;">assert</span>(<span style="color: #228b22;">qmckl_electron_provided</span>(<span style="color: #a0522d;">context</span>)); <span style="color: #0000ff;">assert</span>(<span style="color: #228b22;">qmckl_electron_provided</span>(<span style="color: #a0522d;">context</span>));
rc = qmckl_set_nucleus_num (context, nucl_num); rc = qmckl_set_nucleus_num (context, nucl_num);
@ -959,31 +986,34 @@ rc = qmckl_set_nucleus_num (context, nucl_num);
rc = qmckl_set_nucleus_charge (context, charge); rc = qmckl_set_nucleus_charge (context, charge);
<span style="color: #0000ff;">assert</span> (rc == QMCKL_SUCCESS); <span style="color: #0000ff;">assert</span> (rc == QMCKL_SUCCESS);
rc = qmckl_set_nucleus_coord (context, &amp;(nucl_coord[0])); rc = qmckl_set_nucleus_coord (context, <span style="color: #8b2252;">'T'</span>, nucl_coord);
<span style="color: #0000ff;">assert</span> (rc == QMCKL_SUCCESS); <span style="color: #0000ff;">assert</span> (rc == QMCKL_SUCCESS);
<span style="color: #0000ff;">assert</span>(<span style="color: #228b22;">qmckl_nucleus_provided</span>(<span style="color: #a0522d;">context</span>)); <span style="color: #0000ff;">assert</span>(<span style="color: #228b22;">qmckl_nucleus_provided</span>(<span style="color: #a0522d;">context</span>));
<span style="color: #228b22;">double</span> <span style="color: #a0522d;">en_distance</span>[walk_num][nucl_num][num]; <span style="color: #228b22;">double</span> <span style="color: #a0522d;">en_distance</span>[walk_num][nucl_num][elec_num];
rc = qmckl_get_electron_en_distance(context, &amp;(en_distance[0][0][0])); rc = qmckl_get_electron_en_distance(context, &amp;(en_distance[0][0][0]));
<span style="color: #0000ff;">assert</span> (rc == QMCKL_SUCCESS); <span style="color: #0000ff;">assert</span> (rc == QMCKL_SUCCESS);
// <span style="color: #b22222;">(e,n,w) in Fortran notation</span> // <span style="color: #b22222;">(e,n,w) in Fortran notation</span>
// <span style="color: #b22222;">(1,1,1)</span> // <span style="color: #b22222;">(1,1,1)</span>
<span style="color: #0000ff;">assert</span>(fabs(<span style="color: #228b22;">en_distance</span>[0][0][0] - 6.855624268793153) &lt; 1.e-12); <span style="color: #0000ff;">assert</span>(fabs(<span style="color: #228b22;">en_distance</span>[0][0][0] - 7.546738741619978) &lt; 1.e-12);
// <span style="color: #b22222;">(1,2,1)</span>
<span style="color: #0000ff;">assert</span>(fabs(<span style="color: #228b22;">en_distance</span>[0][1][0] - 8.77102435246984) &lt; 1.e-12);
// <span style="color: #b22222;">(2,1,1)</span> // <span style="color: #b22222;">(2,1,1)</span>
<span style="color: #0000ff;">assert</span>(fabs(<span style="color: #228b22;">en_distance</span>[0][0][1] - 3.698922010513608) &lt; 1.e-12); <span style="color: #0000ff;">assert</span>(fabs(<span style="color: #228b22;">en_distance</span>[0][0][1] - 3.698922010513608) &lt; 1.e-12);
// <span style="color: #b22222;">(1,2,1)</span> // <span style="color: #b22222;">(1,1,2)</span>
<span style="color: #0000ff;">assert</span>(fabs(<span style="color: #228b22;">en_distance</span>[0][1][0] - 8.143800105434433) &lt; 1.e-12); <span style="color: #0000ff;">assert</span>(fabs(<span style="color: #228b22;">en_distance</span>[1][0][0] - 5.824059436060509) &lt; 1.e-12);
// <span style="color: #b22222;">(2,2,1)</span> // <span style="color: #b22222;">(1,2,2)</span>
<span style="color: #0000ff;">assert</span>(fabs(<span style="color: #228b22;">en_distance</span>[0][1][1] - 5.16360835635664) &lt; 1.e-12); <span style="color: #0000ff;">assert</span>(fabs(<span style="color: #228b22;">en_distance</span>[1][1][0] - 7.080482110317645) &lt; 1.e-12);
// <span style="color: #b22222;">(4,3,2)</span> // <span style="color: #b22222;">(2,1,2)</span>
<span style="color: #0000ff;">assert</span>(fabs(<span style="color: #228b22;">en_distance</span>[1][2][3] - 12.599138999960012) &lt; 1.e-12); <span style="color: #0000ff;">assert</span>(fabs(<span style="color: #228b22;">en_distance</span>[1][0][1] - 3.1804527583077356) &lt; 1.e-12);
</pre> </pre>
</div> </div>
@ -994,7 +1024,7 @@ rc = qmckl_get_electron_en_distance(context, &amp;(en_distance[0][0][0]));
</div> </div>
<div id="postamble" class="status"> <div id="postamble" class="status">
<p class="author">Author: TREX CoE</p> <p class="author">Author: TREX CoE</p>
<p class="date">Created: 2021-05-18 Tue 23:32</p> <p class="date">Created: 2021-05-18 Tue 23:38</p>
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p> <p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
</div> </div>
</body> </body>

View File

@ -3,7 +3,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head> <head>
<!-- 2021-05-18 Tue 23:32 --> <!-- 2021-05-18 Tue 23:38 -->
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Error handling</title> <title>Error handling</title>
@ -311,16 +311,16 @@ for the JavaScript code in this tag.
<h2>Table of Contents</h2> <h2>Table of Contents</h2>
<div id="text-table-of-contents"> <div id="text-table-of-contents">
<ul> <ul>
<li><a href="#org20768f0">1. Decoding errors</a></li> <li><a href="#org3edbcc8">1. Decoding errors</a></li>
<li><a href="#org3674e93">2. Data structure in context</a></li> <li><a href="#orgf448738">2. Data structure in context</a></li>
<li><a href="#org8db481f">3. Updating errors in the context</a></li> <li><a href="#orga9cebb5">3. Updating errors in the context</a></li>
<li><a href="#orga79f7e7">4. Failing</a></li> <li><a href="#org1fb1379">4. Failing</a></li>
</ul> </ul>
</div> </div>
</div> </div>
<div id="outline-container-org20768f0" class="outline-2"> <div id="outline-container-org3edbcc8" class="outline-2">
<h2 id="org20768f0"><span class="section-number-2">1</span> Decoding errors</h2> <h2 id="org3edbcc8"><span class="section-number-2">1</span> Decoding errors</h2>
<div class="outline-text-2" id="text-1"> <div class="outline-text-2" id="text-1">
<p> <p>
To decode the error messages, <code>qmckl_string_of_error</code> converts an To decode the error messages, <code>qmckl_string_of_error</code> converts an
@ -417,8 +417,8 @@ The text strings are extracted from the previous table.
</div> </div>
</div> </div>
<div id="outline-container-org3674e93" class="outline-2"> <div id="outline-container-orgf448738" class="outline-2">
<h2 id="org3674e93"><span class="section-number-2">2</span> Data structure in context</h2> <h2 id="orgf448738"><span class="section-number-2">2</span> Data structure in context</h2>
<div class="outline-text-2" id="text-2"> <div class="outline-text-2" id="text-2">
<p> <p>
The strings are declared with a maximum fixed size to avoid The strings are declared with a maximum fixed size to avoid
@ -441,8 +441,8 @@ dynamic memory allocation.
</div> </div>
</div> </div>
<div id="outline-container-org8db481f" class="outline-2"> <div id="outline-container-orga9cebb5" class="outline-2">
<h2 id="org8db481f"><span class="section-number-2">3</span> Updating errors in the context</h2> <h2 id="orga9cebb5"><span class="section-number-2">3</span> Updating errors in the context</h2>
<div class="outline-text-2" id="text-3"> <div class="outline-text-2" id="text-3">
<p> <p>
The error is updated in the context using <code>qmckl_set_error</code>. The error is updated in the context using <code>qmckl_set_error</code>.
@ -488,8 +488,8 @@ explaining the error. The exit code can't be <code>QMCKL_SUCCESS</code>.
</div> </div>
</div> </div>
<div id="outline-container-orga79f7e7" class="outline-2"> <div id="outline-container-org1fb1379" class="outline-2">
<h2 id="orga79f7e7"><span class="section-number-2">4</span> Failing</h2> <h2 id="org1fb1379"><span class="section-number-2">4</span> Failing</h2>
<div class="outline-text-2" id="text-4"> <div class="outline-text-2" id="text-4">
<p> <p>
To make a function fail, the <code>qmckl_failwith</code> function should be To make a function fail, the <code>qmckl_failwith</code> function should be
@ -552,7 +552,7 @@ For example, this function can be used as
</div> </div>
<div id="postamble" class="status"> <div id="postamble" class="status">
<p class="author">Author: TREX CoE</p> <p class="author">Author: TREX CoE</p>
<p class="date">Created: 2021-05-18 Tue 23:32</p> <p class="date">Created: 2021-05-18 Tue 23:38</p>
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p> <p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
</div> </div>
</body> </body>

View File

@ -3,7 +3,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head> <head>
<!-- 2021-05-18 Tue 23:32 --> <!-- 2021-05-18 Tue 23:38 -->
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Memory management</title> <title>Memory management</title>
@ -311,15 +311,15 @@ for the JavaScript code in this tag.
<h2>Table of Contents</h2> <h2>Table of Contents</h2>
<div id="text-table-of-contents"> <div id="text-table-of-contents">
<ul> <ul>
<li><a href="#org939aa30">1. Memory data structure for the context</a></li> <li><a href="#orgbe91de8">1. Memory data structure for the context</a></li>
<li><a href="#org532191c">2. Passing info to allocation routines</a></li> <li><a href="#org9f4a11b">2. Passing info to allocation routines</a></li>
<li><a href="#org40c01f6">3. Allocation/deallocation functions</a></li> <li><a href="#orgae16e6b">3. Allocation/deallocation functions</a></li>
</ul> </ul>
</div> </div>
</div> </div>
<div id="outline-container-org939aa30" class="outline-2"> <div id="outline-container-orgbe91de8" class="outline-2">
<h2 id="org939aa30"><span class="section-number-2">1</span> Memory data structure for the context</h2> <h2 id="orgbe91de8"><span class="section-number-2">1</span> Memory data structure for the context</h2>
<div class="outline-text-2" id="text-1"> <div class="outline-text-2" id="text-1">
<p> <p>
Every time a new block of memory is allocated, the information Every time a new block of memory is allocated, the information
@ -361,8 +361,8 @@ array, and the number of allocated blocks.
</div> </div>
</div> </div>
<div id="outline-container-org532191c" class="outline-2"> <div id="outline-container-org9f4a11b" class="outline-2">
<h2 id="org532191c"><span class="section-number-2">2</span> Passing info to allocation routines</h2> <h2 id="org9f4a11b"><span class="section-number-2">2</span> Passing info to allocation routines</h2>
<div class="outline-text-2" id="text-2"> <div class="outline-text-2" id="text-2">
<p> <p>
Passing information to the allocation routine should be done by Passing information to the allocation routine should be done by
@ -371,8 +371,8 @@ passing an instance of a <code>qmckl_memory_info_struct</code>.
</div> </div>
</div> </div>
<div id="outline-container-org40c01f6" class="outline-2"> <div id="outline-container-orgae16e6b" class="outline-2">
<h2 id="org40c01f6"><span class="section-number-2">3</span> Allocation/deallocation functions</h2> <h2 id="orgae16e6b"><span class="section-number-2">3</span> Allocation/deallocation functions</h2>
<div class="outline-text-2" id="text-3"> <div class="outline-text-2" id="text-3">
<p> <p>
Memory allocation inside the library should be done with Memory allocation inside the library should be done with
@ -535,7 +535,7 @@ allocation and needs to be updated.
</div> </div>
<div id="postamble" class="status"> <div id="postamble" class="status">
<p class="author">Author: TREX CoE</p> <p class="author">Author: TREX CoE</p>
<p class="date">Created: 2021-05-18 Tue 23:32</p> <p class="date">Created: 2021-05-18 Tue 23:38</p>
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p> <p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
</div> </div>
</body> </body>

View File

@ -3,7 +3,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head> <head>
<!-- 2021-05-18 Tue 23:33 --> <!-- 2021-05-18 Tue 23:38 -->
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Nucleus</title> <title>Nucleus</title>
@ -333,28 +333,28 @@ for the JavaScript code in this tag.
<h2>Table of Contents</h2> <h2>Table of Contents</h2>
<div id="text-table-of-contents"> <div id="text-table-of-contents">
<ul> <ul>
<li><a href="#org9f37522">1. Context</a> <li><a href="#org4d17d26">1. Context</a>
<ul> <ul>
<li><a href="#orgab0aa73">1.1. Data structure</a></li> <li><a href="#orgec98d24">1.1. Data structure</a></li>
<li><a href="#org0153f10">1.2. Access functions</a></li> <li><a href="#orgfda2fa5">1.2. Access functions</a></li>
<li><a href="#org24b49e6">1.3. Initialization functions</a></li> <li><a href="#orgba8ea0c">1.3. Initialization functions</a></li>
<li><a href="#org14a850d">1.4. Test</a></li> <li><a href="#orge2b079c">1.4. Test</a></li>
</ul> </ul>
</li> </li>
<li><a href="#org009476a">2. Computation</a> <li><a href="#org15dbd5e">2. Computation</a>
<ul> <ul>
<li><a href="#org501b136">2.1. Nucleus-nucleus distances</a> <li><a href="#org0b00503">2.1. Nucleus-nucleus distances</a>
<ul> <ul>
<li><a href="#org67c0e6f">2.1.1. Get</a></li> <li><a href="#org166731d">2.1.1. Get</a></li>
<li><a href="#orgd6729f5">2.1.2. Compute</a></li> <li><a href="#org94601cc">2.1.2. Compute</a></li>
<li><a href="#orgcf4c735">2.1.3. Test</a></li> <li><a href="#org40621c5">2.1.3. Test</a></li>
</ul> </ul>
</li> </li>
<li><a href="#org4bd7b85">2.2. Nuclear repulsion energy</a> <li><a href="#org8be8ee2">2.2. Nuclear repulsion energy</a>
<ul> <ul>
<li><a href="#org254299a">2.2.1. Get</a></li> <li><a href="#orgc230bce">2.2.1. Get</a></li>
<li><a href="#org8a90dc0">2.2.2. Compute</a></li> <li><a href="#orgb440eb7">2.2.2. Compute</a></li>
<li><a href="#org1c127a4">2.2.3. Test</a></li> <li><a href="#orgf8b7a70">2.2.3. Test</a></li>
</ul> </ul>
</li> </li>
</ul> </ul>
@ -363,8 +363,8 @@ for the JavaScript code in this tag.
</div> </div>
</div> </div>
<div id="outline-container-org9f37522" class="outline-2"> <div id="outline-container-org4d17d26" class="outline-2">
<h2 id="org9f37522"><span class="section-number-2">1</span> Context</h2> <h2 id="org4d17d26"><span class="section-number-2">1</span> Context</h2>
<div class="outline-text-2" id="text-1"> <div class="outline-text-2" id="text-1">
<p> <p>
The following data stored in the context: The following data stored in the context:
@ -438,8 +438,8 @@ The following data stored in the context:
</table> </table>
</div> </div>
<div id="outline-container-orgab0aa73" class="outline-3"> <div id="outline-container-orgec98d24" class="outline-3">
<h3 id="orgab0aa73"><span class="section-number-3">1.1</span> Data structure</h3> <h3 id="orgec98d24"><span class="section-number-3">1.1</span> Data structure</h3>
<div class="outline-text-3" id="text-1-1"> <div class="outline-text-3" id="text-1-1">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c"><span style="color: #a020f0;">typedef</span> <span style="color: #a020f0;">struct</span> <span style="color: #228b22;">qmckl_nucleus_struct</span> { <pre class="src src-c"><span style="color: #a020f0;">typedef</span> <span style="color: #a020f0;">struct</span> <span style="color: #228b22;">qmckl_nucleus_struct</span> {
@ -465,8 +465,8 @@ struct is then initialized and <code>provided == true</code>.
</div> </div>
</div> </div>
<div id="outline-container-org0153f10" class="outline-3"> <div id="outline-container-orgfda2fa5" class="outline-3">
<h3 id="org0153f10"><span class="section-number-3">1.2</span> Access functions</h3> <h3 id="orgfda2fa5"><span class="section-number-3">1.2</span> Access functions</h3>
<div class="outline-text-3" id="text-1-2"> <div class="outline-text-3" id="text-1-2">
<p> <p>
When all the data relative to nuclei have been set, the following When all the data relative to nuclei have been set, the following
@ -480,8 +480,8 @@ function returns <code>true</code>.
</div> </div>
</div> </div>
<div id="outline-container-org24b49e6" class="outline-3"> <div id="outline-container-orgba8ea0c" class="outline-3">
<h3 id="org24b49e6"><span class="section-number-3">1.3</span> Initialization functions</h3> <h3 id="orgba8ea0c"><span class="section-number-3">1.3</span> Initialization functions</h3>
<div class="outline-text-3" id="text-1-3"> <div class="outline-text-3" id="text-1-3">
<p> <p>
To set the data relative to the nuclei in the context, the To set the data relative to the nuclei in the context, the
@ -510,8 +510,8 @@ atoms. The coordinates should be given in atomic units.
</div> </div>
</div> </div>
<div id="outline-container-org14a850d" class="outline-3"> <div id="outline-container-orge2b079c" class="outline-3">
<h3 id="org14a850d"><span class="section-number-3">1.4</span> Test</h3> <h3 id="orge2b079c"><span class="section-number-3">1.4</span> Test</h3>
<div class="outline-text-3" id="text-1-4"> <div class="outline-text-3" id="text-1-4">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c"><span style="color: #a020f0;">const</span> <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">nucl_num</span> = chbrclf_nucl_num; <pre class="src src-c"><span style="color: #a020f0;">const</span> <span style="color: #228b22;">int64_t</span> <span style="color: #a0522d;">nucl_num</span> = chbrclf_nucl_num;
@ -581,8 +581,8 @@ rc = qmckl_get_nucleus_charge(context, nucl_charge2);
</div> </div>
</div> </div>
<div id="outline-container-org009476a" class="outline-2"> <div id="outline-container-org15dbd5e" class="outline-2">
<h2 id="org009476a"><span class="section-number-2">2</span> Computation</h2> <h2 id="org15dbd5e"><span class="section-number-2">2</span> Computation</h2>
<div class="outline-text-2" id="text-2"> <div class="outline-text-2" id="text-2">
<p> <p>
The computed data is stored in the context so that it can be reused The computed data is stored in the context so that it can be reused
@ -595,12 +595,12 @@ current date is stored.
</p> </p>
</div> </div>
<div id="outline-container-org501b136" class="outline-3"> <div id="outline-container-org0b00503" class="outline-3">
<h3 id="org501b136"><span class="section-number-3">2.1</span> Nucleus-nucleus distances</h3> <h3 id="org0b00503"><span class="section-number-3">2.1</span> Nucleus-nucleus distances</h3>
<div class="outline-text-3" id="text-2-1"> <div class="outline-text-3" id="text-2-1">
</div> </div>
<div id="outline-container-org67c0e6f" class="outline-4"> <div id="outline-container-org166731d" class="outline-4">
<h4 id="org67c0e6f"><span class="section-number-4">2.1.1</span> Get</h4> <h4 id="org166731d"><span class="section-number-4">2.1.1</span> Get</h4>
<div class="outline-text-4" id="text-2-1-1"> <div class="outline-text-4" id="text-2-1-1">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_get_nucleus_nn_distance</span>(<span style="color: #228b22;">qmckl_context</span> <span style="color: #a0522d;">context</span>, <span style="color: #228b22;">double</span>* <span style="color: #a0522d;">distance</span>); <pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_get_nucleus_nn_distance</span>(<span style="color: #228b22;">qmckl_context</span> <span style="color: #a0522d;">context</span>, <span style="color: #228b22;">double</span>* <span style="color: #a0522d;">distance</span>);
@ -609,10 +609,10 @@ current date is stored.
</div> </div>
</div> </div>
<div id="outline-container-orgd6729f5" class="outline-4"> <div id="outline-container-org94601cc" class="outline-4">
<h4 id="orgd6729f5"><span class="section-number-4">2.1.2</span> Compute</h4> <h4 id="org94601cc"><span class="section-number-4">2.1.2</span> Compute</h4>
<div class="outline-text-4" id="text-2-1-2"> <div class="outline-text-4" id="text-2-1-2">
<table id="orgfa4dfe4" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides"> <table id="org360ad39" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
<colgroup> <colgroup>
@ -690,8 +690,8 @@ current date is stored.
</div> </div>
</div> </div>
<div id="outline-container-orgcf4c735" class="outline-4"> <div id="outline-container-org40621c5" class="outline-4">
<h4 id="orgcf4c735"><span class="section-number-4">2.1.3</span> Test</h4> <h4 id="org40621c5"><span class="section-number-4">2.1.3</span> Test</h4>
<div class="outline-text-4" id="text-2-1-3"> <div class="outline-text-4" id="text-2-1-3">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c">/* <span style="color: #b22222;">Reference input data </span>*/ <pre class="src src-c">/* <span style="color: #b22222;">Reference input data </span>*/
@ -710,8 +710,8 @@ rc = qmckl_get_nucleus_nn_distance(context, distance);
</div> </div>
</div> </div>
<div id="outline-container-org4bd7b85" class="outline-3"> <div id="outline-container-org8be8ee2" class="outline-3">
<h3 id="org4bd7b85"><span class="section-number-3">2.2</span> Nuclear repulsion energy</h3> <h3 id="org8be8ee2"><span class="section-number-3">2.2</span> Nuclear repulsion energy</h3>
<div class="outline-text-3" id="text-2-2"> <div class="outline-text-3" id="text-2-2">
<p> <p>
\[ \[
@ -720,8 +720,8 @@ rc = qmckl_get_nucleus_nn_distance(context, distance);
</p> </p>
</div> </div>
<div id="outline-container-org254299a" class="outline-4"> <div id="outline-container-orgc230bce" class="outline-4">
<h4 id="org254299a"><span class="section-number-4">2.2.1</span> Get</h4> <h4 id="orgc230bce"><span class="section-number-4">2.2.1</span> Get</h4>
<div class="outline-text-4" id="text-2-2-1"> <div class="outline-text-4" id="text-2-2-1">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_get_nucleus_repulsion</span>(<span style="color: #228b22;">qmckl_context</span> <span style="color: #a0522d;">context</span>, <span style="color: #228b22;">double</span>* <span style="color: #a0522d;">energy</span>); <pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_get_nucleus_repulsion</span>(<span style="color: #228b22;">qmckl_context</span> <span style="color: #a0522d;">context</span>, <span style="color: #228b22;">double</span>* <span style="color: #a0522d;">energy</span>);
@ -730,10 +730,10 @@ rc = qmckl_get_nucleus_nn_distance(context, distance);
</div> </div>
</div> </div>
<div id="outline-container-org8a90dc0" class="outline-4"> <div id="outline-container-orgb440eb7" class="outline-4">
<h4 id="org8a90dc0"><span class="section-number-4">2.2.2</span> Compute</h4> <h4 id="orgb440eb7"><span class="section-number-4">2.2.2</span> Compute</h4>
<div class="outline-text-4" id="text-2-2-2"> <div class="outline-text-4" id="text-2-2-2">
<table id="orgde71515" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides"> <table id="org2a760cb" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
<colgroup> <colgroup>
@ -821,8 +821,8 @@ rc = qmckl_get_nucleus_nn_distance(context, distance);
</div> </div>
</div> </div>
<div id="outline-container-org1c127a4" class="outline-4"> <div id="outline-container-orgf8b7a70" class="outline-4">
<h4 id="org1c127a4"><span class="section-number-4">2.2.3</span> Test</h4> <h4 id="orgf8b7a70"><span class="section-number-4">2.2.3</span> Test</h4>
<div class="outline-text-4" id="text-2-2-3"> <div class="outline-text-4" id="text-2-2-3">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c">/* <span style="color: #b22222;">Reference input data </span>*/ <pre class="src src-c">/* <span style="color: #b22222;">Reference input data </span>*/
@ -842,7 +842,7 @@ rc = qmckl_get_nucleus_repulsion(context, &amp;rep);
</div> </div>
<div id="postamble" class="status"> <div id="postamble" class="status">
<p class="author">Author: TREX CoE</p> <p class="author">Author: TREX CoE</p>
<p class="date">Created: 2021-05-18 Tue 23:33</p> <p class="date">Created: 2021-05-18 Tue 23:38</p>
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p> <p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
</div> </div>
</body> </body>

View File

@ -3,7 +3,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head> <head>
<!-- 2021-05-18 Tue 23:32 --> <!-- 2021-05-18 Tue 23:38 -->
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Numerical precision</title> <title>Numerical precision</title>
@ -333,16 +333,16 @@ for the JavaScript code in this tag.
<h2>Table of Contents</h2> <h2>Table of Contents</h2>
<div id="text-table-of-contents"> <div id="text-table-of-contents">
<ul> <ul>
<li><a href="#org7e3cfa0">1. Control of the numerical precision</a></li> <li><a href="#orgb63cea5">1. Control of the numerical precision</a></li>
<li><a href="#org8a69568">2. Precision</a></li> <li><a href="#orgc2432f1">2. Precision</a></li>
<li><a href="#org9dfff30">3. Range</a></li> <li><a href="#orga70674b">3. Range</a></li>
<li><a href="#org6f82e86">4. Helper functions</a></li> <li><a href="#orga5865a8">4. Helper functions</a></li>
</ul> </ul>
</div> </div>
</div> </div>
<div id="outline-container-org7e3cfa0" class="outline-2"> <div id="outline-container-orgb63cea5" class="outline-2">
<h2 id="org7e3cfa0"><span class="section-number-2">1</span> Control of the numerical precision</h2> <h2 id="orgb63cea5"><span class="section-number-2">1</span> Control of the numerical precision</h2>
<div class="outline-text-2" id="text-1"> <div class="outline-text-2" id="text-1">
<p> <p>
Controlling numerical precision enables optimizations. Here, the Controlling numerical precision enables optimizations. Here, the
@ -353,7 +353,7 @@ Arithmetic (IEEE 754),
refers to the number of exponent bits. refers to the number of exponent bits.
</p> </p>
<table id="orgdf94399" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides"> <table id="org82a9053" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
<colgroup> <colgroup>
@ -397,8 +397,8 @@ integer. The update functions return <code>QMCKL_SUCCESS</code> or
</div> </div>
</div> </div>
<div id="outline-container-org8a69568" class="outline-2"> <div id="outline-container-orgc2432f1" class="outline-2">
<h2 id="org8a69568"><span class="section-number-2">2</span> Precision</h2> <h2 id="orgc2432f1"><span class="section-number-2">2</span> Precision</h2>
<div class="outline-text-2" id="text-2"> <div class="outline-text-2" id="text-2">
<p> <p>
<code>qmckl_context_set_numprec_precision</code> modifies the parameter for the <code>qmckl_context_set_numprec_precision</code> modifies the parameter for the
@ -485,8 +485,8 @@ numerical precision in the context.
</div> </div>
</div> </div>
<div id="outline-container-org9dfff30" class="outline-2"> <div id="outline-container-orga70674b" class="outline-2">
<h2 id="org9dfff30"><span class="section-number-2">3</span> Range</h2> <h2 id="orga70674b"><span class="section-number-2">3</span> Range</h2>
<div class="outline-text-2" id="text-3"> <div class="outline-text-2" id="text-3">
<p> <p>
<code>qmckl_set_numprec_range</code> modifies the parameter for the numerical <code>qmckl_set_numprec_range</code> modifies the parameter for the numerical
@ -561,8 +561,8 @@ range in a given context.
</div> </div>
</div> </div>
</div> </div>
<div id="outline-container-org6f82e86" class="outline-2"> <div id="outline-container-orga5865a8" class="outline-2">
<h2 id="org6f82e86"><span class="section-number-2">4</span> Helper functions</h2> <h2 id="orga5865a8"><span class="section-number-2">4</span> Helper functions</h2>
<div class="outline-text-2" id="text-4"> <div class="outline-text-2" id="text-4">
<p> <p>
<code>qmckl_get_numprec_epsilon</code> returns \(\epsilon = 2^{1-n}\) where <code>n</code> is the precision. <code>qmckl_get_numprec_epsilon</code> returns \(\epsilon = 2^{1-n}\) where <code>n</code> is the precision.
@ -581,7 +581,7 @@ We need to remove the sign bit from the precision.
</div> </div>
<div id="postamble" class="status"> <div id="postamble" class="status">
<p class="author">Author: TREX CoE</p> <p class="author">Author: TREX CoE</p>
<p class="date">Created: 2021-05-18 Tue 23:32</p> <p class="date">Created: 2021-05-18 Tue 23:38</p>
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p> <p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
</div> </div>
</body> </body>

View File

@ -3,7 +3,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head> <head>
<!-- 2021-05-18 Tue 23:32 --> <!-- 2021-05-18 Tue 23:38 -->
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Data for Tests</title> <title>Data for Tests</title>
@ -233,19 +233,19 @@ for the JavaScript code in this tag.
<h2>Table of Contents</h2> <h2>Table of Contents</h2>
<div id="text-table-of-contents"> <div id="text-table-of-contents">
<ul> <ul>
<li><a href="#org6531a1b">1. CHBrClF</a> <li><a href="#org325559a">1. CHBrClF</a>
<ul> <ul>
<li><a href="#orgde3bc84">1.1. XYZ coordinates</a></li> <li><a href="#orgaf012ea">1.1. XYZ coordinates</a></li>
<li><a href="#orga23fd21">1.2. Atomic basis set</a></li> <li><a href="#org60f649a">1.2. Atomic basis set</a></li>
<li><a href="#org31468ee">1.3. Electron coordinates</a></li> <li><a href="#org345efc5">1.3. Electron coordinates</a></li>
</ul> </ul>
</li> </li>
</ul> </ul>
</div> </div>
</div> </div>
<div id="outline-container-org6531a1b" class="outline-2"> <div id="outline-container-org325559a" class="outline-2">
<h2 id="org6531a1b"><span class="section-number-2">1</span> CHBrClF</h2> <h2 id="org325559a"><span class="section-number-2">1</span> CHBrClF</h2>
<div class="outline-text-2" id="text-1"> <div class="outline-text-2" id="text-1">
<p> <p>
This test is the all-electron Hartree-Fock wave function of CHClBr, This test is the all-electron Hartree-Fock wave function of CHClBr,
@ -329,8 +329,8 @@ and with a high maximum angular momentum.
</div> </div>
<div id="outline-container-orgde3bc84" class="outline-3"> <div id="outline-container-orgaf012ea" class="outline-3">
<h3 id="orgde3bc84"><span class="section-number-3">1.1</span> XYZ coordinates</h3> <h3 id="orgaf012ea"><span class="section-number-3">1.1</span> XYZ coordinates</h3>
<div class="outline-text-3" id="text-1-1"> <div class="outline-text-3" id="text-1-1">
<pre class="example"> <pre class="example">
5 5
@ -349,9 +349,9 @@ Nuclear coordinates are stored in atomic units in transposed format.
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c"><span style="color: #483d8b;">#define</span> <span style="color: #a0522d;">chbrclf_nucl_num</span> ((<span style="color: #228b22;">int64_t</span>) 5) <pre class="src src-c"><span style="color: #483d8b;">#define</span> <span style="color: #a0522d;">chbrclf_nucl_num</span> ((<span style="color: #228b22;">int64_t</span>) 5)
<span style="color: #a020f0;">const</span> <span style="color: #228b22;">double</span> <span style="color: #a0522d;">chbrclf_charge</span>[chbrclf_nucl_num] = { 6., 1., 9., 17., 35. }; <span style="color: #228b22;">double</span> <span style="color: #a0522d;">chbrclf_charge</span>[chbrclf_nucl_num] = { 6., 1., 9., 17., 35. };
<span style="color: #a020f0;">const</span> <span style="color: #228b22;">double</span> <span style="color: #a0522d;">chbrclf_nucl_coord</span>[3][chbrclf_nucl_num] = <span style="color: #228b22;">double</span> <span style="color: #a0522d;">chbrclf_nucl_coord</span>[3][chbrclf_nucl_num] =
{ { 1.096243353458458e+00, 1.168459237342663e+00, 1.487097297712132e+00, 3.497663849983889e+00, -2.302574592081335e+00 }, { { 1.096243353458458e+00, 1.168459237342663e+00, 1.487097297712132e+00, 3.497663849983889e+00, -2.302574592081335e+00 },
{ 8.907054016973815e-01, 1.125660720053393e+00, 3.119652484478797e+00, -1.302920810073182e+00, -3.542027060505035e-01 }, { 8.907054016973815e-01, 1.125660720053393e+00, 3.119652484478797e+00, -1.302920810073182e+00, -3.542027060505035e-01 },
{ 7.777092280258892e-01, 2.833370314829343e+00, -3.855438138411500e-01, -1.272220319439064e-01, -5.334129934317614e-02 } }; { 7.777092280258892e-01, 2.833370314829343e+00, -3.855438138411500e-01, -1.272220319439064e-01, -5.334129934317614e-02 } };
@ -360,8 +360,8 @@ Nuclear coordinates are stored in atomic units in transposed format.
</div> </div>
</div> </div>
<div id="outline-container-orga23fd21" class="outline-3"> <div id="outline-container-org60f649a" class="outline-3">
<h3 id="orga23fd21"><span class="section-number-3">1.2</span> Atomic basis set</h3> <h3 id="org60f649a"><span class="section-number-3">1.2</span> Atomic basis set</h3>
<div class="outline-text-3" id="text-1-2"> <div class="outline-text-3" id="text-1-2">
<pre class="example"> <pre class="example">
HYDROGEN HYDROGEN
@ -836,8 +836,8 @@ F 1
</div> </div>
</div> </div>
<div id="outline-container-org31468ee" class="outline-3"> <div id="outline-container-org345efc5" class="outline-3">
<h3 id="org31468ee"><span class="section-number-3">1.3</span> Electron coordinates</h3> <h3 id="org345efc5"><span class="section-number-3">1.3</span> Electron coordinates</h3>
<div class="outline-text-3" id="text-1-3"> <div class="outline-text-3" id="text-1-3">
<p> <p>
Electron coordinates are stored in atomic units in normal format. Electron coordinates are stored in atomic units in normal format.
@ -849,7 +849,7 @@ Electron coordinates are stored in atomic units in normal format.
<span style="color: #483d8b;">#define</span> <span style="color: #a0522d;">chbrclf_elec_num</span> ((<span style="color: #228b22;">int64_t</span>) 68) <span style="color: #483d8b;">#define</span> <span style="color: #a0522d;">chbrclf_elec_num</span> ((<span style="color: #228b22;">int64_t</span>) 68)
<span style="color: #483d8b;">#define</span> <span style="color: #a0522d;">chbrclf_walk_num</span> ((<span style="color: #228b22;">int64_t</span>) 2) <span style="color: #483d8b;">#define</span> <span style="color: #a0522d;">chbrclf_walk_num</span> ((<span style="color: #228b22;">int64_t</span>) 2)
<span style="color: #a020f0;">const</span> <span style="color: #228b22;">double</span> <span style="color: #a0522d;">chbrclf_elec_coord</span>[chbrclf_walk_num][chbrclf_elec_num][3] = { { <span style="color: #228b22;">double</span> <span style="color: #a0522d;">chbrclf_elec_coord</span>[chbrclf_walk_num][chbrclf_elec_num][3] = { {
{-2.26995253563, -5.15737533569, -2.22940072417}, {-2.26995253563, -5.15737533569, -2.22940072417},
{ 3.51983380318, -1.08717381954, -1.19617708027}, { 3.51983380318, -1.08717381954, -1.19617708027},
{-1.66791832447, -3.11651110649, 2.11557179689}, {-1.66791832447, -3.11651110649, 2.11557179689},
@ -997,7 +997,7 @@ Electron coordinates are stored in atomic units in normal format.
</div> </div>
</div> </div>
<div id="postamble" class="status"> <div id="postamble" class="status">
<p class="date">Created: 2021-05-18 Tue 23:32</p> <p class="date">Created: 2021-05-18 Tue 23:38</p>
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p> <p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
</div> </div>
</body> </body>

View File

@ -3,7 +3,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head> <head>
<!-- 2021-05-18 Tue 23:32 --> <!-- 2021-05-18 Tue 23:38 -->
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Utility functions</title> <title>Utility functions</title>
@ -333,13 +333,13 @@ for the JavaScript code in this tag.
<h2>Table of Contents</h2> <h2>Table of Contents</h2>
<div id="text-table-of-contents"> <div id="text-table-of-contents">
<ul> <ul>
<li><a href="#org09f8af3">1. Matrix operations</a> <li><a href="#orge4d7b5c">1. Matrix operations</a>
<ul> <ul>
<li><a href="#orgd2b51a9">1.1. <code>qmckl_transpose</code></a> <li><a href="#org1ccd038">1.1. <code>qmckl_transpose</code></a>
<ul> <ul>
<li><a href="#org8ccd87e">1.1.1. Requirements</a></li> <li><a href="#orgf6dd856">1.1.1. Requirements</a></li>
<li><a href="#org4f2e36a">1.1.2. C header</a></li> <li><a href="#org19dc4ac">1.1.2. C header</a></li>
<li><a href="#orgf5f7428">1.1.3. Source</a></li> <li><a href="#org1a44dab">1.1.3. Source</a></li>
</ul> </ul>
</li> </li>
</ul> </ul>
@ -348,18 +348,18 @@ for the JavaScript code in this tag.
</div> </div>
</div> </div>
<div id="outline-container-org09f8af3" class="outline-2"> <div id="outline-container-orge4d7b5c" class="outline-2">
<h2 id="org09f8af3"><span class="section-number-2">1</span> Matrix operations</h2> <h2 id="orge4d7b5c"><span class="section-number-2">1</span> Matrix operations</h2>
<div class="outline-text-2" id="text-1"> <div class="outline-text-2" id="text-1">
</div> </div>
<div id="outline-container-orgd2b51a9" class="outline-3"> <div id="outline-container-org1ccd038" class="outline-3">
<h3 id="orgd2b51a9"><span class="section-number-3">1.1</span> <code>qmckl_transpose</code></h3> <h3 id="org1ccd038"><span class="section-number-3">1.1</span> <code>qmckl_transpose</code></h3>
<div class="outline-text-3" id="text-1-1"> <div class="outline-text-3" id="text-1-1">
<p> <p>
Transposes a matrix: \(B_{ji} = A_{ij}\) Transposes a matrix: \(B_{ji} = A_{ij}\)
</p> </p>
<table id="org55a674c" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides"> <table id="orga151ea6" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
<colgroup> <colgroup>
@ -424,8 +424,8 @@ Transposes a matrix: \(B_{ji} = A_{ij}\)
</table> </table>
</div> </div>
<div id="outline-container-org8ccd87e" class="outline-4"> <div id="outline-container-orgf6dd856" class="outline-4">
<h4 id="org8ccd87e"><span class="section-number-4">1.1.1</span> Requirements</h4> <h4 id="orgf6dd856"><span class="section-number-4">1.1.1</span> Requirements</h4>
<div class="outline-text-4" id="text-1-1-1"> <div class="outline-text-4" id="text-1-1-1">
<ul class="org-ul"> <ul class="org-ul">
<li><code>context</code> is not <code>QMCKL_NULL_CONTEXT</code></li> <li><code>context</code> is not <code>QMCKL_NULL_CONTEXT</code></li>
@ -439,8 +439,8 @@ Transposes a matrix: \(B_{ji} = A_{ij}\)
</div> </div>
</div> </div>
<div id="outline-container-org4f2e36a" class="outline-4"> <div id="outline-container-org19dc4ac" class="outline-4">
<h4 id="org4f2e36a"><span class="section-number-4">1.1.2</span> C header</h4> <h4 id="org19dc4ac"><span class="section-number-4">1.1.2</span> C header</h4>
<div class="outline-text-4" id="text-1-1-2"> <div class="outline-text-4" id="text-1-1-2">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_transpose</span> ( <pre class="src src-c"><span style="color: #228b22;">qmckl_exit_code</span> <span style="color: #0000ff;">qmckl_transpose</span> (
@ -456,8 +456,8 @@ Transposes a matrix: \(B_{ji} = A_{ij}\)
</div> </div>
</div> </div>
<div id="outline-container-orgf5f7428" class="outline-4"> <div id="outline-container-org1a44dab" class="outline-4">
<h4 id="orgf5f7428"><span class="section-number-4">1.1.3</span> Source</h4> <h4 id="org1a44dab"><span class="section-number-4">1.1.3</span> Source</h4>
<div class="outline-text-4" id="text-1-1-3"> <div class="outline-text-4" id="text-1-1-3">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-f90"><span style="color: #228b22;">integer </span><span style="color: #a020f0;">function</span><span style="color: #a0522d;"> </span><span style="color: #0000ff;">qmckl_transpose_f</span><span style="color: #000000; background-color: #ffffff;">(context, m, n, A, LDA, B, LDB)</span><span style="color: #a0522d;"> </span><span style="color: #a020f0;">&amp;</span> <pre class="src src-f90"><span style="color: #228b22;">integer </span><span style="color: #a020f0;">function</span><span style="color: #a0522d;"> </span><span style="color: #0000ff;">qmckl_transpose_f</span><span style="color: #000000; background-color: #ffffff;">(context, m, n, A, LDA, B, LDB)</span><span style="color: #a0522d;"> </span><span style="color: #a020f0;">&amp;</span>
@ -516,7 +516,7 @@ Transposes a matrix: \(B_{ji} = A_{ij}\)
</div> </div>
<div id="postamble" class="status"> <div id="postamble" class="status">
<p class="author">Author: TREX CoE</p> <p class="author">Author: TREX CoE</p>
<p class="date">Created: 2021-05-18 Tue 23:32</p> <p class="date">Created: 2021-05-18 Tue 23:38</p>
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p> <p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
</div> </div>
</body> </body>