mirror of
https://github.com/TREX-CoE/trexio.git
synced 2024-11-03 12:43:55 +01:00
Deploying to gh-pages from @ TREX-CoE/trexio@00f179d7f9 🚀
This commit is contained in:
parent
6a0d39e481
commit
3557fc39bf
@ -3,7 +3,7 @@
|
||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
||||
<head>
|
||||
<!-- 2023-04-26 Wed 08:13 -->
|
||||
<!-- 2023-05-05 Fri 07:24 -->
|
||||
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<title>TREXIO source code documentation</title>
|
||||
@ -383,7 +383,7 @@ The TREXIO library is licensed under the open-source 3-clause BSD license.
|
||||
</div>
|
||||
<div id="postamble" class="status">
|
||||
<p class="author">Author: TREX-CoE</p>
|
||||
<p class="date">Created: 2023-04-26 Wed 08:13</p>
|
||||
<p class="date">Created: 2023-05-05 Fri 07:24</p>
|
||||
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
|
||||
</div>
|
||||
</body>
|
||||
|
308
examples.html
308
examples.html
@ -3,7 +3,7 @@
|
||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
||||
<head>
|
||||
<!-- 2023-04-26 Wed 08:13 -->
|
||||
<!-- 2023-05-05 Fri 07:24 -->
|
||||
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<title>Examples</title>
|
||||
@ -346,46 +346,61 @@ for the JavaScript code in this tag.
|
||||
<h2>Table of Contents</h2>
|
||||
<div id="text-table-of-contents">
|
||||
<ul>
|
||||
<li><a href="#org4f82439">1. Writing nuclear coordinates</a>
|
||||
<li><a href="#orgd1bf383">1. Writing nuclear coordinates</a>
|
||||
<ul>
|
||||
<li><a href="#org816f8d4">1.1. C</a></li>
|
||||
<li><a href="#orgbd59c83">1.2. Python</a></li>
|
||||
<li><a href="#org5a8985c">1.3. Fortran</a></li>
|
||||
<li><a href="#org89bfed3">1.1. C</a></li>
|
||||
<li><a href="#org46d5da5">1.2. Python</a></li>
|
||||
<li><a href="#orgccd02c3">1.3. Fortran</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#org2d89b30">2. Accessing sparse quantities (integrals)</a>
|
||||
<li><a href="#org99b27b9">2. Accessing sparse quantities (integrals)</a>
|
||||
<ul>
|
||||
<li><a href="#orgc63e6f2">2.1. Fortran</a>
|
||||
<li><a href="#org30c0192">2.1. Fortran</a>
|
||||
<ul>
|
||||
<li><a href="#orgc39b282">2.1.1. Declare Temporary variables</a></li>
|
||||
<li><a href="#org8777066">2.1.2. Obtain the name of the TREXIO file from the command line, and open it for reading</a></li>
|
||||
<li><a href="#org75d7244">2.1.3. Read the nuclear repulsion energy</a></li>
|
||||
<li><a href="#org707c895">2.1.4. Read the number of molecular orbitals</a></li>
|
||||
<li><a href="#org9cee255">2.1.5. Allocate memory</a></li>
|
||||
<li><a href="#orga0e88c1">2.1.6. Read one-electron quantities</a></li>
|
||||
<li><a href="#org4e620a8">2.1.7. Read two-electron quantities</a>
|
||||
<li><a href="#org10d745c">2.1.1. Declare Temporary variables</a></li>
|
||||
<li><a href="#org8b2b534">2.1.2. Obtain the name of the TREXIO file from the command line, and open it for reading</a></li>
|
||||
<li><a href="#org159c7a1">2.1.3. Read the nuclear repulsion energy</a></li>
|
||||
<li><a href="#org2cbb499">2.1.4. Read the number of molecular orbitals</a></li>
|
||||
<li><a href="#org80a623f">2.1.5. Allocate memory</a></li>
|
||||
<li><a href="#org4f60590">2.1.6. Read one-electron quantities</a></li>
|
||||
<li><a href="#org4a0e1c8">2.1.7. Read two-electron quantities</a>
|
||||
<ul>
|
||||
<li><a href="#orgcc934cc">2.1.7.1. Electron repulsion integrals</a></li>
|
||||
<li><a href="#org4f4db3e">2.1.7.2. Reduced density matrix</a></li>
|
||||
<li><a href="#org5aabd62">2.1.7.1. Electron repulsion integrals</a></li>
|
||||
<li><a href="#org06def01">2.1.7.2. Reduced density matrix</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#orgb42c459">2.1.8. Compute the energy</a></li>
|
||||
<li><a href="#org153bb46">2.1.9. Terminate</a></li>
|
||||
<li><a href="#org2c7803a">2.1.8. Compute the energy</a></li>
|
||||
<li><a href="#org609a841">2.1.9. Terminate</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#org9d254f4">2.2. Python</a>
|
||||
<ul>
|
||||
<li><a href="#org236dacd">2.2.1. Obtain the name of the TREXIO file from the command line, and open it for reading</a></li>
|
||||
<li><a href="#org4f216e8">2.2.2. Read the nuclear repulsion energy</a></li>
|
||||
<li><a href="#org34e6dbc">2.2.3. Read the number of molecular orbitals</a></li>
|
||||
<li><a href="#org7d2602e">2.2.4. Read one-electron quantities</a></li>
|
||||
<li><a href="#orgc6a3f95">2.2.5. Read two-electron quantities</a>
|
||||
<ul>
|
||||
<li><a href="#orge9a2abe">2.2.5.1. Electron repulsion integrals</a></li>
|
||||
<li><a href="#org5ed5f4a">2.2.5.2. Reduced density matrix</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#orgbc6fa69">2.2.6. Compute the energy</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#org6432bef">3. Reading determinants</a>
|
||||
<li><a href="#orgcdd1b7c">3. Reading determinants</a>
|
||||
<ul>
|
||||
<li><a href="#orga136043">3.1. Fortran</a></li>
|
||||
<li><a href="#orgb8c47dc">3.1. Fortran</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org4f82439" class="outline-2">
|
||||
<h2 id="org4f82439"><span class="section-number-2">1</span> Writing nuclear coordinates</h2>
|
||||
<div id="outline-container-orgd1bf383" class="outline-2">
|
||||
<h2 id="orgd1bf383"><span class="section-number-2">1</span> Writing nuclear coordinates</h2>
|
||||
<div class="outline-text-2" id="text-1">
|
||||
<p>
|
||||
Here is a demonstration of how to use TREXIO to write the nuclear
|
||||
@ -395,8 +410,8 @@ as well as the necessary TREXIO functions to perform these actions.
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org816f8d4" class="outline-3">
|
||||
<h3 id="org816f8d4"><span class="section-number-3">1.1</span> C</h3>
|
||||
<div id="outline-container-org89bfed3" class="outline-3">
|
||||
<h3 id="org89bfed3"><span class="section-number-3">1.1</span> C</h3>
|
||||
<div class="outline-text-3" id="text-1-1">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c"><span style="color: #483d8b;">#include</span> <span style="color: #8b2252;"><stdio.h></span>
|
||||
@ -446,8 +461,8 @@ as well as the necessary TREXIO functions to perform these actions.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgbd59c83" class="outline-3">
|
||||
<h3 id="orgbd59c83"><span class="section-number-3">1.2</span> Python</h3>
|
||||
<div id="outline-container-org46d5da5" class="outline-3">
|
||||
<h3 id="org46d5da5"><span class="section-number-3">1.2</span> Python</h3>
|
||||
<div class="outline-text-3" id="text-1-2">
|
||||
<p>
|
||||
This code uses the TREXIO Python binding to create a new TREXIO file named
|
||||
@ -494,8 +509,8 @@ coordinates of the system.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org5a8985c" class="outline-3">
|
||||
<h3 id="org5a8985c"><span class="section-number-3">1.3</span> Fortran</h3>
|
||||
<div id="outline-container-orgccd02c3" class="outline-3">
|
||||
<h3 id="orgccd02c3"><span class="section-number-3">1.3</span> Fortran</h3>
|
||||
<div class="outline-text-3" id="text-1-3">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-f90"><span style="color: #a020f0;">program</span> <span style="color: #0000ff;">trexio_water</span>
|
||||
@ -552,12 +567,12 @@ coordinates of the system.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org2d89b30" class="outline-2">
|
||||
<h2 id="org2d89b30"><span class="section-number-2">2</span> Accessing sparse quantities (integrals)</h2>
|
||||
<div id="outline-container-org99b27b9" class="outline-2">
|
||||
<h2 id="org99b27b9"><span class="section-number-2">2</span> Accessing sparse quantities (integrals)</h2>
|
||||
<div class="outline-text-2" id="text-2">
|
||||
</div>
|
||||
<div id="outline-container-orgc63e6f2" class="outline-3">
|
||||
<h3 id="orgc63e6f2"><span class="section-number-3">2.1</span> Fortran</h3>
|
||||
<div id="outline-container-org30c0192" class="outline-3">
|
||||
<h3 id="org30c0192"><span class="section-number-3">2.1</span> Fortran</h3>
|
||||
<div class="outline-text-3" id="text-2-1">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-f90"><span style="color: #a020f0;">program</span> <span style="color: #0000ff;">print_energy</span>
|
||||
@ -603,8 +618,8 @@ One needs to read from the TREXIO file:
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgc39b282" class="outline-4">
|
||||
<h4 id="orgc39b282"><span class="section-number-4">2.1.1</span> Declare Temporary variables</h4>
|
||||
<div id="outline-container-org10d745c" class="outline-4">
|
||||
<h4 id="org10d745c"><span class="section-number-4">2.1.1</span> Declare Temporary variables</h4>
|
||||
<div class="outline-text-4" id="text-2-1-1">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-f90"><span style="color: #228b22;">integer</span> ::<span style="color: #a0522d;"> i, j, k, l, m</span>
|
||||
@ -619,13 +634,13 @@ One needs to read from the TREXIO file:
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org8777066" class="outline-4">
|
||||
<h4 id="org8777066"><span class="section-number-4">2.1.2</span> Obtain the name of the TREXIO file from the command line, and open it for reading</h4>
|
||||
<div id="outline-container-org8b2b534" class="outline-4">
|
||||
<h4 id="org8b2b534"><span class="section-number-4">2.1.2</span> Obtain the name of the TREXIO file from the command line, and open it for reading</h4>
|
||||
<div class="outline-text-4" id="text-2-1-2">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-f90"><span style="color: #a020f0;">call</span> <span style="color: #0000ff;">getarg</span>(1, filename)
|
||||
|
||||
f = trexio_open (filename, <span style="color: #8b2252;">'r'</span>, TREXIO_HDF5, rc)
|
||||
f = trexio_open (filename, <span style="color: #8b2252;">'r'</span>, TREXIO_AUTO, rc)
|
||||
<span style="color: #a020f0;">if</span> (rc /= TREXIO_SUCCESS) <span style="color: #a020f0;">then</span>
|
||||
<span style="color: #a020f0;">call</span> <span style="color: #0000ff;">trexio_string_of_error</span>(rc, err_msg)
|
||||
<span style="color: #a020f0;">print</span> *, <span style="color: #8b2252;">'Error opening TREXIO file: '</span>//<span style="color: #a020f0;">trim</span>(err_msg)
|
||||
@ -636,8 +651,8 @@ f = trexio_open (filename, <span style="color: #8b2252;">'r'</span>, TREXIO_HDF5
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org75d7244" class="outline-4">
|
||||
<h4 id="org75d7244"><span class="section-number-4">2.1.3</span> Read the nuclear repulsion energy</h4>
|
||||
<div id="outline-container-org159c7a1" class="outline-4">
|
||||
<h4 id="org159c7a1"><span class="section-number-4">2.1.3</span> Read the nuclear repulsion energy</h4>
|
||||
<div class="outline-text-4" id="text-2-1-3">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-f90">rc = trexio_read_nucleus_repulsion(f, E_nn)
|
||||
@ -651,8 +666,8 @@ f = trexio_open (filename, <span style="color: #8b2252;">'r'</span>, TREXIO_HDF5
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org707c895" class="outline-4">
|
||||
<h4 id="org707c895"><span class="section-number-4">2.1.4</span> Read the number of molecular orbitals</h4>
|
||||
<div id="outline-container-org2cbb499" class="outline-4">
|
||||
<h4 id="org2cbb499"><span class="section-number-4">2.1.4</span> Read the number of molecular orbitals</h4>
|
||||
<div class="outline-text-4" id="text-2-1-4">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-f90">rc = trexio_read_mo_num(f, n)
|
||||
@ -666,8 +681,8 @@ f = trexio_open (filename, <span style="color: #8b2252;">'r'</span>, TREXIO_HDF5
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org9cee255" class="outline-4">
|
||||
<h4 id="org9cee255"><span class="section-number-4">2.1.5</span> Allocate memory</h4>
|
||||
<div id="outline-container-org80a623f" class="outline-4">
|
||||
<h4 id="org80a623f"><span class="section-number-4">2.1.5</span> Allocate memory</h4>
|
||||
<div class="outline-text-4" id="text-2-1-5">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-f90"><span style="color: #a020f0;">allocate</span>( D(n,n), h0(n,n) )
|
||||
@ -679,8 +694,8 @@ W(:,:,:,:) = 0.d0
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orga0e88c1" class="outline-4">
|
||||
<h4 id="orga0e88c1"><span class="section-number-4">2.1.6</span> Read one-electron quantities</h4>
|
||||
<div id="outline-container-org4f60590" class="outline-4">
|
||||
<h4 id="org4f60590"><span class="section-number-4">2.1.6</span> Read one-electron quantities</h4>
|
||||
<div class="outline-text-4" id="text-2-1-6">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-f90">rc = trexio_has_mo_1e_int_core_hamiltonian(f)
|
||||
@ -712,8 +727,8 @@ rc = trexio_read_rdm_1e(f, D)
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org4e620a8" class="outline-4">
|
||||
<h4 id="org4e620a8"><span class="section-number-4">2.1.7</span> Read two-electron quantities</h4>
|
||||
<div id="outline-container-org4a0e1c8" class="outline-4">
|
||||
<h4 id="org4a0e1c8"><span class="section-number-4">2.1.7</span> Read two-electron quantities</h4>
|
||||
<div class="outline-text-4" id="text-2-1-7">
|
||||
<p>
|
||||
Reading is done with OpenMP. Each thread reads its own buffer, and
|
||||
@ -729,8 +744,8 @@ to be protected in the critical section when modified.
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgcc934cc" class="outline-5">
|
||||
<h5 id="orgcc934cc"><span class="section-number-5">2.1.7.1</span> Electron repulsion integrals</h5>
|
||||
<div id="outline-container-org5aabd62" class="outline-5">
|
||||
<h5 id="org5aabd62"><span class="section-number-5">2.1.7.1</span> Electron repulsion integrals</h5>
|
||||
<div class="outline-text-5" id="text-2-1-7-1">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-f90">rc = trexio_has_mo_2e_int_eri(f)
|
||||
@ -779,8 +794,8 @@ icount = BUFSIZE
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org4f4db3e" class="outline-5">
|
||||
<h5 id="org4f4db3e"><span class="section-number-5">2.1.7.2</span> Reduced density matrix</h5>
|
||||
<div id="outline-container-org06def01" class="outline-5">
|
||||
<h5 id="org06def01"><span class="section-number-5">2.1.7.2</span> Reduced density matrix</h5>
|
||||
<div class="outline-text-5" id="text-2-1-7-2">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-f90">rc = trexio_has_rdm_2e(f)
|
||||
@ -824,8 +839,8 @@ icount = bufsize
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgb42c459" class="outline-4">
|
||||
<h4 id="orgb42c459"><span class="section-number-4">2.1.8</span> Compute the energy</h4>
|
||||
<div id="outline-container-org2c7803a" class="outline-4">
|
||||
<h4 id="org2c7803a"><span class="section-number-4">2.1.8</span> Compute the energy</h4>
|
||||
<div class="outline-text-4" id="text-2-1-8">
|
||||
<p>
|
||||
When the orbitals are real, we can use
|
||||
@ -871,8 +886,8 @@ E = E + E_nn
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org153bb46" class="outline-4">
|
||||
<h4 id="org153bb46"><span class="section-number-4">2.1.9</span> Terminate</h4>
|
||||
<div id="outline-container-org609a841" class="outline-4">
|
||||
<h4 id="org609a841"><span class="section-number-4">2.1.9</span> Terminate</h4>
|
||||
<div class="outline-text-4" id="text-2-1-9">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-f90"> <span style="color: #a020f0;">deallocate</span>( D, h0, G, W )
|
||||
@ -883,14 +898,187 @@ E = E + E_nn
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org9d254f4" class="outline-3">
|
||||
<h3 id="org9d254f4"><span class="section-number-3">2.2</span> Python</h3>
|
||||
<div class="outline-text-3" id="text-2-2">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-python"><span style="color: #a020f0;">import</span> sys
|
||||
<span style="color: #a020f0;">import</span> trexio
|
||||
<span style="color: #a020f0;">import</span> numpy <span style="color: #a020f0;">as</span> np
|
||||
|
||||
<span style="color: #a0522d;">BUFSIZE</span> = 100000
|
||||
</pre>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org6432bef" class="outline-2">
|
||||
<h2 id="org6432bef"><span class="section-number-2">3</span> Reading determinants</h2>
|
||||
<p>
|
||||
This program computes the energy as:
|
||||
</p>
|
||||
|
||||
<p>
|
||||
\[
|
||||
E = E_{\text{NN}} + \sum_{ij} \gamma_{ij}\, \langle j | h | i \rangle\,
|
||||
+\, \frac{1}{2} \sum_{ijkl} \Gamma_{ijkl}\, \langle k l | i j
|
||||
\rangle\; \textrm{ with } \; 0 < i,j,k,l \le n
|
||||
\]
|
||||
One needs to read from the TREXIO file:
|
||||
</p>
|
||||
|
||||
<dl class="org-dl">
|
||||
<dt>\(n\)</dt><dd>The number of molecular orbitals</dd>
|
||||
<dt>\(E_{\text{NN}}\)</dt><dd>The nuclear repulsion energy</dd>
|
||||
<dt>\(\gamma_{ij}\)</dt><dd>The one-body reduced density matrix</dd>
|
||||
<dt>\(\langle j |h| i \rangle\)</dt><dd>The one-electron Hamiltonian integrals</dd>
|
||||
<dt>\(\Gamma_{ijkl}\)</dt><dd>The two-body reduced density matrix</dd>
|
||||
<dt>\(\langle k l | i j \rangle\)</dt><dd>The electron repulsion integrals</dd>
|
||||
</dl>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org236dacd" class="outline-4">
|
||||
<h4 id="org236dacd"><span class="section-number-4">2.2.1</span> Obtain the name of the TREXIO file from the command line, and open it for reading</h4>
|
||||
<div class="outline-text-4" id="text-2-2-1">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-python"><span style="color: #a0522d;">filename</span> = sys.argv[1]
|
||||
<span style="color: #a0522d;">f</span> = trexio.File(filename, <span style="color: #8b2252;">'r'</span>, trexio.TREXIO_AUTO)
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org4f216e8" class="outline-4">
|
||||
<h4 id="org4f216e8"><span class="section-number-4">2.2.2</span> Read the nuclear repulsion energy</h4>
|
||||
<div class="outline-text-4" id="text-2-2-2">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-python"><span style="color: #a0522d;">E_nn</span> = trexio.read_nucleus_repulsion(f)
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org34e6dbc" class="outline-4">
|
||||
<h4 id="org34e6dbc"><span class="section-number-4">2.2.3</span> Read the number of molecular orbitals</h4>
|
||||
<div class="outline-text-4" id="text-2-2-3">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-python"><span style="color: #a0522d;">n</span> = trexio.read_mo_num(f)
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org7d2602e" class="outline-4">
|
||||
<h4 id="org7d2602e"><span class="section-number-4">2.2.4</span> Read one-electron quantities</h4>
|
||||
<div class="outline-text-4" id="text-2-2-4">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-python"><span style="color: #a020f0;">if</span> <span style="color: #a020f0;">not</span> trexio.has_mo_1e_int_core_hamiltonian(f):
|
||||
<span style="color: #a020f0;">print</span>(<span style="color: #8b2252;">"No core hamiltonian in file"</span>)
|
||||
sys.<span style="color: #008b8b;">exit</span>(-1)
|
||||
|
||||
<span style="color: #a0522d;">h0</span> = trexio.read_mo_1e_int_core_hamiltonian(f)
|
||||
|
||||
<span style="color: #a020f0;">if</span> <span style="color: #a020f0;">not</span> trexio.has_rdm_1e(f):
|
||||
<span style="color: #a020f0;">print</span>(<span style="color: #8b2252;">"No 1e RDM in file"</span>)
|
||||
sys.<span style="color: #008b8b;">exit</span>(-1)
|
||||
|
||||
<span style="color: #a0522d;">D</span> = trexio.read_rdm_1e(f)
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgc6a3f95" class="outline-4">
|
||||
<h4 id="orgc6a3f95"><span class="section-number-4">2.2.5</span> Read two-electron quantities</h4>
|
||||
<div class="outline-text-4" id="text-2-2-5">
|
||||
</div>
|
||||
<div id="outline-container-orge9a2abe" class="outline-5">
|
||||
<h5 id="orge9a2abe"><span class="section-number-5">2.2.5.1</span> Electron repulsion integrals</h5>
|
||||
<div class="outline-text-5" id="text-2-2-5-1">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-python"><span style="color: #a020f0;">if</span> <span style="color: #a020f0;">not</span> trexio.has_mo_2e_int_eri(f):
|
||||
<span style="color: #a020f0;">print</span>(<span style="color: #8b2252;">"No electron repulsion integrals in file"</span>)
|
||||
sys.<span style="color: #008b8b;">exit</span>(-1)
|
||||
|
||||
<span style="color: #a0522d;">size_max</span> = trexio.read_mo_2e_int_eri_size(f)
|
||||
|
||||
<span style="color: #a0522d;">offset</span> = 0
|
||||
<span style="color: #a0522d;">icount</span> = BUFSIZE
|
||||
<span style="color: #a0522d;">feof</span> = <span style="color: #008b8b;">False</span>
|
||||
<span style="color: #a0522d;">W</span> = np.zeros( (n,n,n,n) )
|
||||
<span style="color: #a020f0;">while</span> <span style="color: #a020f0;">not</span> feof:
|
||||
<span style="color: #a0522d;">buffer_index</span>, <span style="color: #a0522d;">buffer_values</span>, <span style="color: #a0522d;">icount</span>, <span style="color: #a0522d;">feof</span> = trexio.read_mo_2e_int_eri(f, offset, icount)
|
||||
<span style="color: #a020f0;">for</span> m <span style="color: #a020f0;">in</span> <span style="color: #483d8b;">range</span>(icount):
|
||||
<span style="color: #a0522d;">i</span>, <span style="color: #a0522d;">j</span>, <span style="color: #a0522d;">k</span>, <span style="color: #a0522d;">l</span> = buffer_index[m]
|
||||
<span style="color: #a0522d;">W</span>[i,j,k,l] = buffer_values[m]
|
||||
<span style="color: #a0522d;">W</span>[k,j,i,l] = buffer_values[m]
|
||||
<span style="color: #a0522d;">W</span>[i,l,k,j] = buffer_values[m]
|
||||
<span style="color: #a0522d;">W</span>[k,l,i,j] = buffer_values[m]
|
||||
<span style="color: #a0522d;">W</span>[j,i,l,k] = buffer_values[m]
|
||||
<span style="color: #a0522d;">W</span>[j,k,l,i] = buffer_values[m]
|
||||
<span style="color: #a0522d;">W</span>[l,i,j,k] = buffer_values[m]
|
||||
<span style="color: #a0522d;">W</span>[l,k,j,i] = buffer_values[m]
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org5ed5f4a" class="outline-5">
|
||||
<h5 id="org5ed5f4a"><span class="section-number-5">2.2.5.2</span> Reduced density matrix</h5>
|
||||
<div class="outline-text-5" id="text-2-2-5-2">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-python"><span style="color: #a020f0;">if</span> <span style="color: #a020f0;">not</span> trexio.has_rdm_2e(f):
|
||||
<span style="color: #a020f0;">print</span>(<span style="color: #8b2252;">"No two-body density matrix in file"</span>)
|
||||
|
||||
<span style="color: #a0522d;">offset</span> = 0
|
||||
<span style="color: #a0522d;">icount</span> = BUFSIZE
|
||||
<span style="color: #a0522d;">feof</span> = <span style="color: #008b8b;">False</span>
|
||||
<span style="color: #a0522d;">G</span> = np.zeros( (n,n,n,n) )
|
||||
<span style="color: #a020f0;">while</span> <span style="color: #a020f0;">not</span> feof:
|
||||
<span style="color: #a0522d;">buffer_index</span>, <span style="color: #a0522d;">buffer_values</span>, <span style="color: #a0522d;">icount</span>, <span style="color: #a0522d;">feof</span> = trexio.read_rdm_2e(f, offset, icount)
|
||||
<span style="color: #a020f0;">for</span> m <span style="color: #a020f0;">in</span> <span style="color: #483d8b;">range</span>(icount):
|
||||
<span style="color: #a0522d;">i</span>, <span style="color: #a0522d;">j</span>, <span style="color: #a0522d;">k</span>, <span style="color: #a0522d;">l</span> = buffer_index[m]
|
||||
<span style="color: #a0522d;">G</span>[i,j,k,l] = buffer_values[m]
|
||||
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgbc6fa69" class="outline-4">
|
||||
<h4 id="orgbc6fa69"><span class="section-number-4">2.2.6</span> Compute the energy</h4>
|
||||
<div class="outline-text-4" id="text-2-2-6">
|
||||
<p>
|
||||
When the orbitals are real, we can use
|
||||
</p>
|
||||
\begin{eqnarray*}
|
||||
E &=& E_{\text{NN}} + \sum_{ij} \gamma_{ij}\, \langle j | h | i \rangle\,
|
||||
+\, \frac{1}{2} \sum_{ijkl} \Gamma_{ijkl}\, \langle k l | i j
|
||||
\rangle \\
|
||||
&=& E_{\text{NN}} + \sum_{ij} \gamma_{ij}\, \langle i | h | j \rangle\,
|
||||
+\, \frac{1}{2} \sum_{ijkl} \Gamma_{ijkl}\, \langle i j | k l
|
||||
\rangle \\
|
||||
\end{eqnarray*}
|
||||
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-python"><span style="color: #a0522d;">G</span> = np.reshape(G, (n*n, n*n) )
|
||||
<span style="color: #a0522d;">W</span> = np.reshape(W, (n*n, n*n) )
|
||||
<span style="color: #a0522d;">E</span> = E_nn
|
||||
<span style="color: #a0522d;">E</span> += 0.5*<span style="color: #483d8b;">sum</span>( [ np.dot(G[:,l], W[:,l]) <span style="color: #a020f0;">for</span> l <span style="color: #a020f0;">in</span> <span style="color: #483d8b;">range</span>(n*n) ] )
|
||||
<span style="color: #a0522d;">E</span> += <span style="color: #483d8b;">sum</span>( [ np.dot(D[:,l], h0[:,l]) <span style="color: #a020f0;">for</span> l <span style="color: #a020f0;">in</span> <span style="color: #483d8b;">range</span>(n) ] )
|
||||
|
||||
<span style="color: #a020f0;">print</span> (f<span style="color: #8b2252;">"Energy: {E}"</span>)
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgcdd1b7c" class="outline-2">
|
||||
<h2 id="orgcdd1b7c"><span class="section-number-2">3</span> Reading determinants</h2>
|
||||
<div class="outline-text-2" id="text-3">
|
||||
</div>
|
||||
<div id="outline-container-orga136043" class="outline-3">
|
||||
<h3 id="orga136043"><span class="section-number-3">3.1</span> Fortran</h3>
|
||||
<div id="outline-container-orgb8c47dc" class="outline-3">
|
||||
<h3 id="orgb8c47dc"><span class="section-number-3">3.1</span> Fortran</h3>
|
||||
<div class="outline-text-3" id="text-3-1">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-f90"><span style="color: #a020f0;">program</span> <span style="color: #0000ff;">test</span>
|
||||
@ -969,7 +1157,7 @@ end
|
||||
</div>
|
||||
<div id="postamble" class="status">
|
||||
<p class="author">Author: TREX-CoE</p>
|
||||
<p class="date">Created: 2023-04-26 Wed 08:13</p>
|
||||
<p class="date">Created: 2023-05-05 Fri 07:24</p>
|
||||
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
|
||||
</div>
|
||||
</body>
|
||||
|
135
examples.org
135
examples.org
@ -200,7 +200,7 @@ program print_energy
|
||||
#+begin_src f90
|
||||
call getarg(1, filename)
|
||||
|
||||
f = trexio_open (filename, 'r', TREXIO_HDF5, rc)
|
||||
f = trexio_open (filename, 'r', TREXIO_AUTO, rc)
|
||||
if (rc /= TREXIO_SUCCESS) then
|
||||
call trexio_string_of_error(rc, err_msg)
|
||||
print *, 'Error opening TREXIO file: '//trim(err_msg)
|
||||
@ -410,6 +410,139 @@ program print_energy
|
||||
end program
|
||||
#+end_src
|
||||
|
||||
** Python
|
||||
:PROPERTIES:
|
||||
:header-args: :tangle print_energy.py
|
||||
:END:
|
||||
|
||||
#+begin_src python
|
||||
import sys
|
||||
import trexio
|
||||
import numpy as np
|
||||
|
||||
BUFSIZE = 100000
|
||||
#+end_src
|
||||
|
||||
This program computes the energy as:
|
||||
|
||||
\[
|
||||
E = E_{\text{NN}} + \sum_{ij} \gamma_{ij}\, \langle j | h | i \rangle\,
|
||||
+\, \frac{1}{2} \sum_{ijkl} \Gamma_{ijkl}\, \langle k l | i j
|
||||
\rangle\; \textrm{ with } \; 0 < i,j,k,l \le n
|
||||
\]
|
||||
One needs to read from the TREXIO file:
|
||||
|
||||
- $n$ :: The number of molecular orbitals
|
||||
- $E_{\text{NN}}$ :: The nuclear repulsion energy
|
||||
- $\gamma_{ij}$ :: The one-body reduced density matrix
|
||||
- $\langle j |h| i \rangle$ :: The one-electron Hamiltonian integrals
|
||||
- $\Gamma_{ijkl}$ :: The two-body reduced density matrix
|
||||
- $\langle k l | i j \rangle$ :: The electron repulsion integrals
|
||||
|
||||
*** Obtain the name of the TREXIO file from the command line, and open it for reading
|
||||
|
||||
#+begin_src python
|
||||
filename = sys.argv[1]
|
||||
f = trexio.File(filename, 'r', trexio.TREXIO_AUTO)
|
||||
#+end_src
|
||||
|
||||
*** Read the nuclear repulsion energy
|
||||
|
||||
#+begin_src python
|
||||
E_nn = trexio.read_nucleus_repulsion(f)
|
||||
#+end_src
|
||||
|
||||
*** Read the number of molecular orbitals
|
||||
|
||||
#+begin_src python
|
||||
n = trexio.read_mo_num(f)
|
||||
#+end_src
|
||||
|
||||
*** Read one-electron quantities
|
||||
|
||||
#+begin_src python
|
||||
if not trexio.has_mo_1e_int_core_hamiltonian(f):
|
||||
print("No core hamiltonian in file")
|
||||
sys.exit(-1)
|
||||
|
||||
h0 = trexio.read_mo_1e_int_core_hamiltonian(f)
|
||||
|
||||
if not trexio.has_rdm_1e(f):
|
||||
print("No 1e RDM in file")
|
||||
sys.exit(-1)
|
||||
|
||||
D = trexio.read_rdm_1e(f)
|
||||
#+end_src
|
||||
|
||||
*** Read two-electron quantities
|
||||
|
||||
**** Electron repulsion integrals
|
||||
|
||||
#+begin_src python
|
||||
if not trexio.has_mo_2e_int_eri(f):
|
||||
print("No electron repulsion integrals in file")
|
||||
sys.exit(-1)
|
||||
|
||||
size_max = trexio.read_mo_2e_int_eri_size(f)
|
||||
|
||||
offset = 0
|
||||
icount = BUFSIZE
|
||||
feof = False
|
||||
W = np.zeros( (n,n,n,n) )
|
||||
while not feof:
|
||||
buffer_index, buffer_values, icount, feof = trexio.read_mo_2e_int_eri(f, offset, icount)
|
||||
for m in range(icount):
|
||||
i, j, k, l = buffer_index[m]
|
||||
W[i,j,k,l] = buffer_values[m]
|
||||
W[k,j,i,l] = buffer_values[m]
|
||||
W[i,l,k,j] = buffer_values[m]
|
||||
W[k,l,i,j] = buffer_values[m]
|
||||
W[j,i,l,k] = buffer_values[m]
|
||||
W[j,k,l,i] = buffer_values[m]
|
||||
W[l,i,j,k] = buffer_values[m]
|
||||
W[l,k,j,i] = buffer_values[m]
|
||||
#+end_src
|
||||
|
||||
**** Reduced density matrix
|
||||
|
||||
#+begin_src python
|
||||
if not trexio.has_rdm_2e(f):
|
||||
print("No two-body density matrix in file")
|
||||
|
||||
offset = 0
|
||||
icount = BUFSIZE
|
||||
feof = False
|
||||
G = np.zeros( (n,n,n,n) )
|
||||
while not feof:
|
||||
buffer_index, buffer_values, icount, feof = trexio.read_rdm_2e(f, offset, icount)
|
||||
for m in range(icount):
|
||||
i, j, k, l = buffer_index[m]
|
||||
G[i,j,k,l] = buffer_values[m]
|
||||
|
||||
#+end_src
|
||||
|
||||
*** Compute the energy
|
||||
|
||||
When the orbitals are real, we can use
|
||||
\begin{eqnarray*}
|
||||
E &=& E_{\text{NN}} + \sum_{ij} \gamma_{ij}\, \langle j | h | i \rangle\,
|
||||
+\, \frac{1}{2} \sum_{ijkl} \Gamma_{ijkl}\, \langle k l | i j
|
||||
\rangle \\
|
||||
&=& E_{\text{NN}} + \sum_{ij} \gamma_{ij}\, \langle i | h | j \rangle\,
|
||||
+\, \frac{1}{2} \sum_{ijkl} \Gamma_{ijkl}\, \langle i j | k l
|
||||
\rangle \\
|
||||
\end{eqnarray*}
|
||||
|
||||
#+begin_src python
|
||||
G = np.reshape(G, (n*n, n*n) )
|
||||
W = np.reshape(W, (n*n, n*n) )
|
||||
E = E_nn
|
||||
E += 0.5*sum( [ np.dot(G[:,l], W[:,l]) for l in range(n*n) ] )
|
||||
E += sum( [ np.dot(D[:,l], h0[:,l]) for l in range(n) ] )
|
||||
|
||||
print (f"Energy: {E}")
|
||||
#+end_src
|
||||
|
||||
* Reading determinants
|
||||
|
||||
** Fortran
|
||||
|
@ -3,7 +3,7 @@
|
||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
||||
<head>
|
||||
<!-- 2023-04-26 Wed 08:13 -->
|
||||
<!-- 2023-05-05 Fri 07:24 -->
|
||||
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<title>TREXIO source code documentation</title>
|
||||
@ -383,7 +383,7 @@ The TREXIO library is licensed under the open-source 3-clause BSD license.
|
||||
</div>
|
||||
<div id="postamble" class="status">
|
||||
<p class="author">Author: TREX-CoE</p>
|
||||
<p class="date">Created: 2023-04-26 Wed 08:13</p>
|
||||
<p class="date">Created: 2023-05-05 Fri 07:24</p>
|
||||
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
|
||||
</div>
|
||||
</body>
|
||||
|
@ -3,7 +3,7 @@
|
||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
||||
<head>
|
||||
<!-- 2023-04-26 Wed 08:13 -->
|
||||
<!-- 2023-05-05 Fri 07:24 -->
|
||||
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<title>Motivation</title>
|
||||
@ -384,7 +384,7 @@ still lacking, and the purpose of the TREXIO library is to fill this gap.
|
||||
</div>
|
||||
<div id="postamble" class="status">
|
||||
<p class="author">Author: TREX-CoE</p>
|
||||
<p class="date">Created: 2023-04-26 Wed 08:13</p>
|
||||
<p class="date">Created: 2023-05-05 Fri 07:24</p>
|
||||
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
|
||||
</div>
|
||||
</body>
|
||||
|
58
lib.html
58
lib.html
@ -3,7 +3,7 @@
|
||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
||||
<head>
|
||||
<!-- 2023-04-26 Wed 08:13 -->
|
||||
<!-- 2023-05-05 Fri 07:24 -->
|
||||
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<title>The TREXIO library</title>
|
||||
@ -346,19 +346,19 @@ for the JavaScript code in this tag.
|
||||
<h2>Table of Contents</h2>
|
||||
<div id="text-table-of-contents">
|
||||
<ul>
|
||||
<li><a href="#orgcb7a139">1. Format specification</a>
|
||||
<li><a href="#orgde54ba8">1. Format specification</a>
|
||||
<ul>
|
||||
<li><a href="#org49f1819">1.1. Organization of the data</a></li>
|
||||
<li><a href="#org4ead64b">1.2. Data types</a></li>
|
||||
<li><a href="#orgac90981">1.1. Organization of the data</a></li>
|
||||
<li><a href="#org1f52fd5">1.2. Data types</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#org425c20d">2. The TREXIO library</a>
|
||||
<li><a href="#orge5fc1cc">2. The TREXIO library</a>
|
||||
<ul>
|
||||
<li><a href="#org286a381">2.1. The front-end</a></li>
|
||||
<li><a href="#orgdfb8627">2.2. The back-end</a></li>
|
||||
<li><a href="#org2169f9d">2.3. Supported languages</a></li>
|
||||
<li><a href="#orga4b7a27">2.4. Source code generation and documentation</a></li>
|
||||
<li><a href="#orga748157">2.5. Availability</a></li>
|
||||
<li><a href="#orgc502b12">2.1. The front-end</a></li>
|
||||
<li><a href="#org5daaef6">2.2. The back-end</a></li>
|
||||
<li><a href="#orgf025038">2.3. Supported languages</a></li>
|
||||
<li><a href="#org08f1a1f">2.4. Source code generation and documentation</a></li>
|
||||
<li><a href="#org82ad967">2.5. Availability</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
@ -366,8 +366,8 @@ for the JavaScript code in this tag.
|
||||
</div>
|
||||
|
||||
|
||||
<div id="outline-container-orgcb7a139" class="outline-2">
|
||||
<h2 id="orgcb7a139"><span class="section-number-2">1</span> Format specification</h2>
|
||||
<div id="outline-container-orgde54ba8" class="outline-2">
|
||||
<h2 id="orgde54ba8"><span class="section-number-2">1</span> Format specification</h2>
|
||||
<div class="outline-text-2" id="text-1">
|
||||
</td>
|
||||
<td>
|
||||
@ -388,8 +388,8 @@ calculation are stored.
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org49f1819" class="outline-3">
|
||||
<h3 id="org49f1819"><span class="section-number-3">1.1</span> Organization of the data</h3>
|
||||
<div id="outline-container-orgac90981" class="outline-3">
|
||||
<h3 id="orgac90981"><span class="section-number-3">1.1</span> Organization of the data</h3>
|
||||
<div class="outline-text-3" id="text-1-1">
|
||||
<p>
|
||||
The data in TREXIO are organized into <b>groups</b>, each containing
|
||||
@ -405,8 +405,8 @@ number of nuclei.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org4ead64b" class="outline-3">
|
||||
<h3 id="org4ead64b"><span class="section-number-3">1.2</span> Data types</h3>
|
||||
<div id="outline-container-org1f52fd5" class="outline-3">
|
||||
<h3 id="org1f52fd5"><span class="section-number-3">1.2</span> Data types</h3>
|
||||
<div class="outline-text-3" id="text-1-2">
|
||||
<p>
|
||||
So that TREXIO can be used in any language, we use a limited number
|
||||
@ -473,8 +473,8 @@ with the same name suffixed by <code>_im</code>.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org425c20d" class="outline-2">
|
||||
<h2 id="org425c20d"><span class="section-number-2">2</span> The TREXIO library</h2>
|
||||
<div id="outline-container-orge5fc1cc" class="outline-2">
|
||||
<h2 id="orge5fc1cc"><span class="section-number-2">2</span> The TREXIO library</h2>
|
||||
<div class="outline-text-2" id="text-2">
|
||||
</td>
|
||||
<td>
|
||||
@ -497,8 +497,8 @@ interface between the library and the physical storage.
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org286a381" class="outline-3">
|
||||
<h3 id="org286a381"><span class="section-number-3">2.1</span> The front-end</h3>
|
||||
<div id="outline-container-orgc502b12" class="outline-3">
|
||||
<h3 id="orgc502b12"><span class="section-number-3">2.1</span> The front-end</h3>
|
||||
<div class="outline-text-3" id="text-2-1">
|
||||
<p>
|
||||
By using the TREXIO library, users can store and extract data in a
|
||||
@ -539,8 +539,8 @@ made are safe.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgdfb8627" class="outline-3">
|
||||
<h3 id="orgdfb8627"><span class="section-number-3">2.2</span> The back-end</h3>
|
||||
<div id="outline-container-org5daaef6" class="outline-3">
|
||||
<h3 id="org5daaef6"><span class="section-number-3">2.2</span> The back-end</h3>
|
||||
<div class="outline-text-3" id="text-2-2">
|
||||
<p>
|
||||
At present, TREXIO supports two back-ends: one relying only on the
|
||||
@ -610,8 +610,8 @@ repositories.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org2169f9d" class="outline-3">
|
||||
<h3 id="org2169f9d"><span class="section-number-3">2.3</span> Supported languages</h3>
|
||||
<div id="outline-container-orgf025038" class="outline-3">
|
||||
<h3 id="orgf025038"><span class="section-number-3">2.3</span> Supported languages</h3>
|
||||
<div class="outline-text-3" id="text-2-3">
|
||||
<p>
|
||||
One of the main benefits of using C as the interface for a library is
|
||||
@ -668,8 +668,8 @@ via the Binder platform.
|
||||
</div>
|
||||
|
||||
|
||||
<div id="outline-container-orga4b7a27" class="outline-3">
|
||||
<h3 id="orga4b7a27"><span class="section-number-3">2.4</span> Source code generation and documentation</h3>
|
||||
<div id="outline-container-org08f1a1f" class="outline-3">
|
||||
<h3 id="org08f1a1f"><span class="section-number-3">2.4</span> Source code generation and documentation</h3>
|
||||
<div class="outline-text-3" id="text-2-4">
|
||||
<p>
|
||||
Source code generation is a valuable technique that can significantly
|
||||
@ -723,8 +723,8 @@ regardless of their programming skills.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orga748157" class="outline-3">
|
||||
<h3 id="orga748157"><span class="section-number-3">2.5</span> Availability</h3>
|
||||
<div id="outline-container-org82ad967" class="outline-3">
|
||||
<h3 id="org82ad967"><span class="section-number-3">2.5</span> Availability</h3>
|
||||
<div class="outline-text-3" id="text-2-5">
|
||||
<p>
|
||||
The TREXIO library is designed to be portable and easy to install
|
||||
@ -754,7 +754,7 @@ are available in Ubuntu 23.04.
|
||||
</div>
|
||||
<div id="postamble" class="status">
|
||||
<p class="author">Author: TREX-CoE</p>
|
||||
<p class="date">Created: 2023-04-26 Wed 08:13</p>
|
||||
<p class="date">Created: 2023-05-05 Fri 07:24</p>
|
||||
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
|
||||
</div>
|
||||
</body>
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -3,7 +3,7 @@
|
||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
||||
<head>
|
||||
<!-- 2023-04-26 Wed 08:13 -->
|
||||
<!-- 2023-05-05 Fri 07:23 -->
|
||||
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<title>HDF5 back end</title>
|
||||
@ -324,25 +324,25 @@ for the JavaScript code in this tag.
|
||||
<h2>Table of Contents</h2>
|
||||
<div id="text-table-of-contents">
|
||||
<ul>
|
||||
<li><a href="#orgc1db2a8">1. Template for HDF5 definitions</a></li>
|
||||
<li><a href="#orge6e94ef">2. Template for HDF5 structures</a></li>
|
||||
<li><a href="#org3b723b2">3. Template for HDF5 init/deinit</a></li>
|
||||
<li><a href="#orgf678d23">4. Template for HDF5 has a group</a></li>
|
||||
<li><a href="#org5a18ef5">5. Template for HDF5 has/read/write a numerical attribute</a></li>
|
||||
<li><a href="#org3ee8e80">6. Template for HDF5 has/read/write a dataset of numerical data</a></li>
|
||||
<li><a href="#org47051e3">7. Template for HDF5 has/read/write a dataset of sparse data</a></li>
|
||||
<li><a href="#org2a34b6e">8. Template for HDF5 has/read/write a dataset of buffered vectors</a></li>
|
||||
<li><a href="#orgad3c9af">9. Template for HDF5 has/read/write a dataset of strings</a></li>
|
||||
<li><a href="#org8e4e5ba">10. Template for HDF5 has/read/write a string attribute</a></li>
|
||||
<li><a href="#org8842713">11. Template for HDF5 delete a group (UNSAFE mode)</a></li>
|
||||
<li><a href="#org16f88ad">12. Source code for the determinant part</a></li>
|
||||
<li><a href="#orge15a637">13. Helper functions</a></li>
|
||||
<li><a href="#orgb4fdca2">1. Template for HDF5 definitions</a></li>
|
||||
<li><a href="#orgc36c137">2. Template for HDF5 structures</a></li>
|
||||
<li><a href="#org40ed074">3. Template for HDF5 init/deinit</a></li>
|
||||
<li><a href="#orga363ad3">4. Template for HDF5 has a group</a></li>
|
||||
<li><a href="#org33eceb8">5. Template for HDF5 has/read/write a numerical attribute</a></li>
|
||||
<li><a href="#org41bf8c6">6. Template for HDF5 has/read/write a dataset of numerical data</a></li>
|
||||
<li><a href="#orgac9b6f9">7. Template for HDF5 has/read/write a dataset of sparse data</a></li>
|
||||
<li><a href="#org345d427">8. Template for HDF5 has/read/write a dataset of buffered vectors</a></li>
|
||||
<li><a href="#org8959415">9. Template for HDF5 has/read/write a dataset of strings</a></li>
|
||||
<li><a href="#org6319d95">10. Template for HDF5 has/read/write a string attribute</a></li>
|
||||
<li><a href="#orga74081e">11. Template for HDF5 delete a group (UNSAFE mode)</a></li>
|
||||
<li><a href="#orga869654">12. Source code for the determinant part</a></li>
|
||||
<li><a href="#org20f41f5">13. Helper functions</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgc1db2a8" class="outline-2">
|
||||
<h2 id="orgc1db2a8"><span class="section-number-2">1</span> Template for HDF5 definitions</h2>
|
||||
<div id="outline-container-orgb4fdca2" class="outline-2">
|
||||
<h2 id="orgb4fdca2"><span class="section-number-2">1</span> Template for HDF5 definitions</h2>
|
||||
<div class="outline-text-2" id="text-1">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c"><span style="color: #483d8b;">#define</span> $GROUP$_GROUP_NAME <span style="color: #8b2252;">"$group$"</span>
|
||||
@ -354,8 +354,8 @@ for the JavaScript code in this tag.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orge6e94ef" class="outline-2">
|
||||
<h2 id="orge6e94ef"><span class="section-number-2">2</span> Template for HDF5 structures</h2>
|
||||
<div id="outline-container-orgc36c137" class="outline-2">
|
||||
<h2 id="orgc36c137"><span class="section-number-2">2</span> Template for HDF5 structures</h2>
|
||||
<div class="outline-text-2" id="text-2">
|
||||
<p>
|
||||
Polymorphism of the <code>trexio_t</code> type is handled by ensuring that the
|
||||
@ -375,8 +375,8 @@ corresponding types for all back ends can be safely casted to
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org3b723b2" class="outline-2">
|
||||
<h2 id="org3b723b2"><span class="section-number-2">3</span> Template for HDF5 init/deinit</h2>
|
||||
<div id="outline-container-org40ed074" class="outline-2">
|
||||
<h2 id="org40ed074"><span class="section-number-2">3</span> Template for HDF5 init/deinit</h2>
|
||||
<div class="outline-text-2" id="text-3">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c"><span style="color: #228b22;">trexio_exit_code</span>
|
||||
@ -496,8 +496,8 @@ corresponding types for all back ends can be safely casted to
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgf678d23" class="outline-2">
|
||||
<h2 id="orgf678d23"><span class="section-number-2">4</span> Template for HDF5 has a group</h2>
|
||||
<div id="outline-container-orga363ad3" class="outline-2">
|
||||
<h2 id="orga363ad3"><span class="section-number-2">4</span> Template for HDF5 has a group</h2>
|
||||
<div class="outline-text-2" id="text-4">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c"><span style="color: #228b22;">trexio_exit_code</span>
|
||||
@ -527,8 +527,8 @@ corresponding types for all back ends can be safely casted to
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org5a18ef5" class="outline-2">
|
||||
<h2 id="org5a18ef5"><span class="section-number-2">5</span> Template for HDF5 has/read/write a numerical attribute</h2>
|
||||
<div id="outline-container-org33eceb8" class="outline-2">
|
||||
<h2 id="org33eceb8"><span class="section-number-2">5</span> Template for HDF5 has/read/write a numerical attribute</h2>
|
||||
<div class="outline-text-2" id="text-5">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c"><span style="color: #228b22;">trexio_exit_code</span>
|
||||
@ -632,8 +632,8 @@ corresponding types for all back ends can be safely casted to
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org3ee8e80" class="outline-2">
|
||||
<h2 id="org3ee8e80"><span class="section-number-2">6</span> Template for HDF5 has/read/write a dataset of numerical data</h2>
|
||||
<div id="outline-container-org41bf8c6" class="outline-2">
|
||||
<h2 id="org41bf8c6"><span class="section-number-2">6</span> Template for HDF5 has/read/write a dataset of numerical data</h2>
|
||||
<div class="outline-text-2" id="text-6">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c"><span style="color: #228b22;">trexio_exit_code</span>
|
||||
@ -770,8 +770,8 @@ corresponding types for all back ends can be safely casted to
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org47051e3" class="outline-2">
|
||||
<h2 id="org47051e3"><span class="section-number-2">7</span> Template for HDF5 has/read/write a dataset of sparse data</h2>
|
||||
<div id="outline-container-orgac9b6f9" class="outline-2">
|
||||
<h2 id="orgac9b6f9"><span class="section-number-2">7</span> Template for HDF5 has/read/write a dataset of sparse data</h2>
|
||||
<div class="outline-text-2" id="text-7">
|
||||
<p>
|
||||
Sparse data is stored using extensible datasets of HDF5. Extensibility is required
|
||||
@ -973,8 +973,8 @@ due to the fact that the sparse data will be written in chunks of user-defined s
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org2a34b6e" class="outline-2">
|
||||
<h2 id="org2a34b6e"><span class="section-number-2">8</span> Template for HDF5 has/read/write a dataset of buffered vectors</h2>
|
||||
<div id="outline-container-org345d427" class="outline-2">
|
||||
<h2 id="org345d427"><span class="section-number-2">8</span> Template for HDF5 has/read/write a dataset of buffered vectors</h2>
|
||||
<div class="outline-text-2" id="text-8">
|
||||
<p>
|
||||
Chunked I/O in HDF5 for <code>buffered</code> data.
|
||||
@ -1108,8 +1108,8 @@ Chunked I/O in HDF5 for <code>buffered</code> data.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgad3c9af" class="outline-2">
|
||||
<h2 id="orgad3c9af"><span class="section-number-2">9</span> Template for HDF5 has/read/write a dataset of strings</h2>
|
||||
<div id="outline-container-org8959415" class="outline-2">
|
||||
<h2 id="org8959415"><span class="section-number-2">9</span> Template for HDF5 has/read/write a dataset of strings</h2>
|
||||
<div class="outline-text-2" id="text-9">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c"><span style="color: #228b22;">trexio_exit_code</span>
|
||||
@ -1306,8 +1306,8 @@ Chunked I/O in HDF5 for <code>buffered</code> data.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org8e4e5ba" class="outline-2">
|
||||
<h2 id="org8e4e5ba"><span class="section-number-2">10</span> Template for HDF5 has/read/write a string attribute</h2>
|
||||
<div id="outline-container-org6319d95" class="outline-2">
|
||||
<h2 id="org6319d95"><span class="section-number-2">10</span> Template for HDF5 has/read/write a string attribute</h2>
|
||||
<div class="outline-text-2" id="text-10">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c"><span style="color: #228b22;">trexio_exit_code</span>
|
||||
@ -1434,8 +1434,8 @@ Chunked I/O in HDF5 for <code>buffered</code> data.
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-org8842713" class="outline-2">
|
||||
<h2 id="org8842713"><span class="section-number-2">11</span> Template for HDF5 delete a group (UNSAFE mode)</h2>
|
||||
<div id="outline-container-orga74081e" class="outline-2">
|
||||
<h2 id="orga74081e"><span class="section-number-2">11</span> Template for HDF5 delete a group (UNSAFE mode)</h2>
|
||||
<div class="outline-text-2" id="text-11">
|
||||
<p>
|
||||
<b><b>Note:</b></b> in early versions of the HDF5 library (v < 1.10) unlinking an object was not working as expected
|
||||
@ -1475,8 +1475,8 @@ Thus, any corrupted/lost file space will remain in the first file. The use of <c
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org16f88ad" class="outline-2">
|
||||
<h2 id="org16f88ad"><span class="section-number-2">12</span> Source code for the determinant part</h2>
|
||||
<div id="outline-container-orga869654" class="outline-2">
|
||||
<h2 id="orga869654"><span class="section-number-2">12</span> Source code for the determinant part</h2>
|
||||
<div class="outline-text-2" id="text-12">
|
||||
<p>
|
||||
Each array is stored in a separate HDF5 dataset due to the fact that determinant I/O has to be decoupled.
|
||||
@ -1578,8 +1578,8 @@ Size specifies the number of data items (e.g. determinants) to process.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orge15a637" class="outline-2">
|
||||
<h2 id="orge15a637"><span class="section-number-2">13</span> Helper functions</h2>
|
||||
<div id="outline-container-org20f41f5" class="outline-2">
|
||||
<h2 id="org20f41f5"><span class="section-number-2">13</span> Helper functions</h2>
|
||||
<div class="outline-text-2" id="text-13">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c"><span style="color: #228b22;">trexio_exit_code</span>
|
||||
@ -1842,7 +1842,7 @@ Size specifies the number of data items (e.g. determinants) to process.
|
||||
</div>
|
||||
<div id="postamble" class="status">
|
||||
<p class="author">Author: TREX-CoE</p>
|
||||
<p class="date">Created: 2023-04-26 Wed 08:13</p>
|
||||
<p class="date">Created: 2023-05-05 Fri 07:23</p>
|
||||
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
|
||||
</div>
|
||||
</body>
|
||||
|
@ -3,7 +3,7 @@
|
||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
||||
<head>
|
||||
<!-- 2023-04-26 Wed 08:13 -->
|
||||
<!-- 2023-05-05 Fri 07:23 -->
|
||||
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<title>TEXT back end</title>
|
||||
@ -324,23 +324,23 @@ for the JavaScript code in this tag.
|
||||
<h2>Table of Contents</h2>
|
||||
<div id="text-table-of-contents">
|
||||
<ul>
|
||||
<li><a href="#org345e95b">1. Template for group-related structures in text back end</a></li>
|
||||
<li><a href="#org48f6982">2. Template for general structure in text back end</a></li>
|
||||
<li><a href="#org73b5574">3. Initialize function (constant part)</a></li>
|
||||
<li><a href="#orgbe1c005">4. Deinitialize function (templated part)</a></li>
|
||||
<li><a href="#orgd869fa1">5. Flush function (templated part)</a></li>
|
||||
<li><a href="#org7a73d7c">6. Template for text read a group</a></li>
|
||||
<li><a href="#orge573356">7. Template for text has a group</a></li>
|
||||
<li><a href="#orgcb41bf7">8. Template for text flush a group</a></li>
|
||||
<li><a href="#orgf6eecb5">9. Template for text free memory</a></li>
|
||||
<li><a href="#org90e8315">10. Template for has/read/write a numerical attribute</a></li>
|
||||
<li><a href="#org4327d78">11. Template for has/read/write a dataset of numerical data</a></li>
|
||||
<li><a href="#orgda7d9ea">12. Template for has/read/write a dataset of strings</a></li>
|
||||
<li><a href="#orgd789d72">13. Template for has/read/write a string attribute</a></li>
|
||||
<li><a href="#org403fba1">14. Template for has/read/write the dataset of sparse data</a></li>
|
||||
<li><a href="#orgde960af">15. Template for has/read/write a buffered vector</a></li>
|
||||
<li><a href="#org81c4d61">16. Template for text delete a group (UNSAFE mode)</a></li>
|
||||
<li><a href="#orgff39153">17. Source code for the determinant part</a></li>
|
||||
<li><a href="#org17ccb6f">1. Template for group-related structures in text back end</a></li>
|
||||
<li><a href="#org5505aae">2. Template for general structure in text back end</a></li>
|
||||
<li><a href="#org3a5e6f1">3. Initialize function (constant part)</a></li>
|
||||
<li><a href="#org7ade52e">4. Deinitialize function (templated part)</a></li>
|
||||
<li><a href="#orgee3fc62">5. Flush function (templated part)</a></li>
|
||||
<li><a href="#org84af45d">6. Template for text read a group</a></li>
|
||||
<li><a href="#orgc81cb8b">7. Template for text has a group</a></li>
|
||||
<li><a href="#org922ae37">8. Template for text flush a group</a></li>
|
||||
<li><a href="#orgec65eb0">9. Template for text free memory</a></li>
|
||||
<li><a href="#org1599ae0">10. Template for has/read/write a numerical attribute</a></li>
|
||||
<li><a href="#org001a998">11. Template for has/read/write a dataset of numerical data</a></li>
|
||||
<li><a href="#orgbcd4fdf">12. Template for has/read/write a dataset of strings</a></li>
|
||||
<li><a href="#org4f01966">13. Template for has/read/write a string attribute</a></li>
|
||||
<li><a href="#orgbbab33a">14. Template for has/read/write the dataset of sparse data</a></li>
|
||||
<li><a href="#org7196b49">15. Template for has/read/write a buffered vector</a></li>
|
||||
<li><a href="#org2f53c0e">16. Template for text delete a group (UNSAFE mode)</a></li>
|
||||
<li><a href="#org7e9da88">17. Source code for the determinant part</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
@ -362,8 +362,8 @@ directory.
|
||||
The file is written when closed, or when the flush function is called.
|
||||
</p>
|
||||
|
||||
<div id="outline-container-org345e95b" class="outline-2">
|
||||
<h2 id="org345e95b"><span class="section-number-2">1</span> Template for group-related structures in text back end</h2>
|
||||
<div id="outline-container-org17ccb6f" class="outline-2">
|
||||
<h2 id="org17ccb6f"><span class="section-number-2">1</span> Template for group-related structures in text back end</h2>
|
||||
<div class="outline-text-2" id="text-1">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c"><span style="color: #a020f0;">typedef</span> <span style="color: #a020f0;">struct</span> $group$_s {
|
||||
@ -382,8 +382,8 @@ The file is written when closed, or when the flush function is called.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org48f6982" class="outline-2">
|
||||
<h2 id="org48f6982"><span class="section-number-2">2</span> Template for general structure in text back end</h2>
|
||||
<div id="outline-container-org5505aae" class="outline-2">
|
||||
<h2 id="org5505aae"><span class="section-number-2">2</span> Template for general structure in text back end</h2>
|
||||
<div class="outline-text-2" id="text-2">
|
||||
<p>
|
||||
Polymorphism of the <code>trexio_t</code> type is handled by ensuring that the
|
||||
@ -403,8 +403,8 @@ corresponding types for all back ends can be safely casted to
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org73b5574" class="outline-2">
|
||||
<h2 id="org73b5574"><span class="section-number-2">3</span> Initialize function (constant part)</h2>
|
||||
<div id="outline-container-org3a5e6f1" class="outline-2">
|
||||
<h2 id="org3a5e6f1"><span class="section-number-2">3</span> Initialize function (constant part)</h2>
|
||||
<div class="outline-text-2" id="text-3">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c"><span style="color: #228b22;">bool</span>
|
||||
@ -597,8 +597,8 @@ In that case, we define an alternate one, which is not as safe as the original o
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgbe1c005" class="outline-2">
|
||||
<h2 id="orgbe1c005"><span class="section-number-2">4</span> Deinitialize function (templated part)</h2>
|
||||
<div id="outline-container-org7ade52e" class="outline-2">
|
||||
<h2 id="org7ade52e"><span class="section-number-2">4</span> Deinitialize function (templated part)</h2>
|
||||
<div class="outline-text-2" id="text-4">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c"><span style="color: #228b22;">trexio_exit_code</span>
|
||||
@ -620,8 +620,8 @@ In that case, we define an alternate one, which is not as safe as the original o
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgd869fa1" class="outline-2">
|
||||
<h2 id="orgd869fa1"><span class="section-number-2">5</span> Flush function (templated part)</h2>
|
||||
<div id="outline-container-orgee3fc62" class="outline-2">
|
||||
<h2 id="orgee3fc62"><span class="section-number-2">5</span> Flush function (templated part)</h2>
|
||||
<div class="outline-text-2" id="text-5">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c"><span style="color: #228b22;">trexio_exit_code</span>
|
||||
@ -644,8 +644,8 @@ In that case, we define an alternate one, which is not as safe as the original o
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org7a73d7c" class="outline-2">
|
||||
<h2 id="org7a73d7c"><span class="section-number-2">6</span> Template for text read a group</h2>
|
||||
<div id="outline-container-org84af45d" class="outline-2">
|
||||
<h2 id="org84af45d"><span class="section-number-2">6</span> Template for text read a group</h2>
|
||||
<div class="outline-text-2" id="text-6">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c">$group$_t*
|
||||
@ -871,8 +871,8 @@ trexio_text_read_$group$ (<span style="color: #228b22;">trexio_text_t</span>* <s
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orge573356" class="outline-2">
|
||||
<h2 id="orge573356"><span class="section-number-2">7</span> Template for text has a group</h2>
|
||||
<div id="outline-container-orgc81cb8b" class="outline-2">
|
||||
<h2 id="orgc81cb8b"><span class="section-number-2">7</span> Template for text has a group</h2>
|
||||
<div class="outline-text-2" id="text-7">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c"><span style="color: #228b22;">trexio_exit_code</span>
|
||||
@ -912,8 +912,8 @@ trexio_text_read_$group$ (<span style="color: #228b22;">trexio_text_t</span>* <s
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgcb41bf7" class="outline-2">
|
||||
<h2 id="orgcb41bf7"><span class="section-number-2">8</span> Template for text flush a group</h2>
|
||||
<div id="outline-container-org922ae37" class="outline-2">
|
||||
<h2 id="org922ae37"><span class="section-number-2">8</span> Template for text flush a group</h2>
|
||||
<div class="outline-text-2" id="text-8">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c"><span style="color: #228b22;">trexio_exit_code</span>
|
||||
@ -977,8 +977,8 @@ trexio_text_read_$group$ (<span style="color: #228b22;">trexio_text_t</span>* <s
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgf6eecb5" class="outline-2">
|
||||
<h2 id="orgf6eecb5"><span class="section-number-2">9</span> Template for text free memory</h2>
|
||||
<div id="outline-container-orgec65eb0" class="outline-2">
|
||||
<h2 id="orgec65eb0"><span class="section-number-2">9</span> Template for text free memory</h2>
|
||||
<div class="outline-text-2" id="text-9">
|
||||
<p>
|
||||
Memory is allocated when reading. The following function frees memory.
|
||||
@ -1047,8 +1047,8 @@ This function is called upon the non-successful exit from the <code>trexio_text_
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org90e8315" class="outline-2">
|
||||
<h2 id="org90e8315"><span class="section-number-2">10</span> Template for has/read/write a numerical attribute</h2>
|
||||
<div id="outline-container-org1599ae0" class="outline-2">
|
||||
<h2 id="org1599ae0"><span class="section-number-2">10</span> Template for has/read/write a numerical attribute</h2>
|
||||
<div class="outline-text-2" id="text-10">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c"><span style="color: #228b22;">trexio_exit_code</span>
|
||||
@ -1111,8 +1111,8 @@ This function is called upon the non-successful exit from the <code>trexio_text_
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org4327d78" class="outline-2">
|
||||
<h2 id="org4327d78"><span class="section-number-2">11</span> Template for has/read/write a dataset of numerical data</h2>
|
||||
<div id="outline-container-org001a998" class="outline-2">
|
||||
<h2 id="org001a998"><span class="section-number-2">11</span> Template for has/read/write a dataset of numerical data</h2>
|
||||
<div class="outline-text-2" id="text-11">
|
||||
<p>
|
||||
The <code>group_dset</code> array is assumed allocated with the appropriate size.
|
||||
@ -1208,8 +1208,8 @@ The <code>group_dset</code> array is assumed allocated with the appropriate size
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgda7d9ea" class="outline-2">
|
||||
<h2 id="orgda7d9ea"><span class="section-number-2">12</span> Template for has/read/write a dataset of strings</h2>
|
||||
<div id="outline-container-orgbcd4fdf" class="outline-2">
|
||||
<h2 id="orgbcd4fdf"><span class="section-number-2">12</span> Template for has/read/write a dataset of strings</h2>
|
||||
<div class="outline-text-2" id="text-12">
|
||||
<p>
|
||||
The <code>group_dset</code> array is assumed allocated with the appropriate size.
|
||||
@ -1310,8 +1310,8 @@ The <code>group_dset</code> array is assumed allocated with the appropriate size
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgd789d72" class="outline-2">
|
||||
<h2 id="orgd789d72"><span class="section-number-2">13</span> Template for has/read/write a string attribute</h2>
|
||||
<div id="outline-container-org4f01966" class="outline-2">
|
||||
<h2 id="org4f01966"><span class="section-number-2">13</span> Template for has/read/write a string attribute</h2>
|
||||
<div class="outline-text-2" id="text-13">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c"><span style="color: #228b22;">trexio_exit_code</span>
|
||||
@ -1385,8 +1385,8 @@ The <code>group_dset</code> array is assumed allocated with the appropriate size
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-org403fba1" class="outline-2">
|
||||
<h2 id="org403fba1"><span class="section-number-2">14</span> Template for has/read/write the dataset of sparse data</h2>
|
||||
<div id="outline-container-orgbbab33a" class="outline-2">
|
||||
<h2 id="orgbbab33a"><span class="section-number-2">14</span> Template for has/read/write the dataset of sparse data</h2>
|
||||
<div class="outline-text-2" id="text-14">
|
||||
<p>
|
||||
Each sparse array is stored in a separate <code>.txt</code> file due to the fact that sparse I/O has to be decoupled
|
||||
@ -1676,8 +1676,8 @@ User provides indices and values of the sparse array as two separate variables.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgde960af" class="outline-2">
|
||||
<h2 id="orgde960af"><span class="section-number-2">15</span> Template for has/read/write a buffered vector</h2>
|
||||
<div id="outline-container-org7196b49" class="outline-2">
|
||||
<h2 id="org7196b49"><span class="section-number-2">15</span> Template for has/read/write a buffered vector</h2>
|
||||
<div class="outline-text-2" id="text-15">
|
||||
<p>
|
||||
Each array is stored in a separate <code>.txt</code> file due to the fact that buffered I/O has to be decoupled
|
||||
@ -1907,8 +1907,8 @@ Size specifies the number of vector elements to be written.
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-org81c4d61" class="outline-2">
|
||||
<h2 id="org81c4d61"><span class="section-number-2">16</span> Template for text delete a group (UNSAFE mode)</h2>
|
||||
<div id="outline-container-org2f53c0e" class="outline-2">
|
||||
<h2 id="org2f53c0e"><span class="section-number-2">16</span> Template for text delete a group (UNSAFE mode)</h2>
|
||||
<div class="outline-text-2" id="text-16">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-c"><span style="color: #228b22;">trexio_exit_code</span>
|
||||
@ -1936,8 +1936,8 @@ Size specifies the number of vector elements to be written.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgff39153" class="outline-2">
|
||||
<h2 id="orgff39153"><span class="section-number-2">17</span> Source code for the determinant part</h2>
|
||||
<div id="outline-container-org7e9da88" class="outline-2">
|
||||
<h2 id="org7e9da88"><span class="section-number-2">17</span> Source code for the determinant part</h2>
|
||||
<div class="outline-text-2" id="text-17">
|
||||
<p>
|
||||
Each array is stored in a separate <code>.txt</code> file due to the fact that determinant I/O has to be decoupled
|
||||
@ -2129,7 +2129,7 @@ Size specifies the number of data items, e.g. determinants.
|
||||
</div>
|
||||
<div id="postamble" class="status">
|
||||
<p class="author">Author: TREX-CoE</p>
|
||||
<p class="date">Created: 2023-04-26 Wed 08:13</p>
|
||||
<p class="date">Created: 2023-05-05 Fri 07:23</p>
|
||||
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
|
||||
</div>
|
||||
</body>
|
||||
|
242
trex.html
242
trex.html
@ -3,7 +3,7 @@
|
||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
||||
<head>
|
||||
<!-- 2023-04-26 Wed 08:13 -->
|
||||
<!-- 2023-05-05 Fri 07:24 -->
|
||||
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<title>Data stored in TREXIO</title>
|
||||
@ -346,70 +346,70 @@ for the JavaScript code in this tag.
|
||||
<h2>Table of Contents</h2>
|
||||
<div id="text-table-of-contents">
|
||||
<ul>
|
||||
<li><a href="#org52113ee">1. Metadata (metadata group)</a></li>
|
||||
<li><a href="#orgc97f36d">2. System</a>
|
||||
<li><a href="#org9cb3921">1. Metadata (metadata group)</a></li>
|
||||
<li><a href="#org8e72032">2. System</a>
|
||||
<ul>
|
||||
<li><a href="#org8fe552a">2.1. Nucleus (nucleus group)</a></li>
|
||||
<li><a href="#org7fd3ca9">2.2. Cell (cell group)</a></li>
|
||||
<li><a href="#orgcc4ffcb">2.3. Periodic boundary calculations (pbc group)</a></li>
|
||||
<li><a href="#org54e0b84">2.4. Electron (electron group)</a></li>
|
||||
<li><a href="#orgaeebd1a">2.5. Ground or excited states (state group)</a></li>
|
||||
<li><a href="#org1613910">2.1. Nucleus (nucleus group)</a></li>
|
||||
<li><a href="#org61d39fe">2.2. Cell (cell group)</a></li>
|
||||
<li><a href="#orgce86b75">2.3. Periodic boundary calculations (pbc group)</a></li>
|
||||
<li><a href="#orgdcb53ed">2.4. Electron (electron group)</a></li>
|
||||
<li><a href="#orgfbf81f7">2.5. Ground or excited states (state group)</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#org8f4676b">3. Basis functions</a>
|
||||
<li><a href="#org196e8d2">3. Basis functions</a>
|
||||
<ul>
|
||||
<li><a href="#org24b642a">3.1. Basis set (basis group)</a>
|
||||
<li><a href="#orgc0f3f1c">3.1. Basis set (basis group)</a>
|
||||
<ul>
|
||||
<li><a href="#orgbbbbc3c">3.1.1. Gaussian and Slater-type orbitals</a></li>
|
||||
<li><a href="#orgc385a5b">3.1.2. Plane waves</a></li>
|
||||
<li><a href="#orge491313">3.1.3. Data definitions</a></li>
|
||||
<li><a href="#orge4436c6">3.1.4. Example</a></li>
|
||||
<li><a href="#orgca8d913">3.1.1. Gaussian and Slater-type orbitals</a></li>
|
||||
<li><a href="#org79c6672">3.1.2. Plane waves</a></li>
|
||||
<li><a href="#orgeb8efcd">3.1.3. Data definitions</a></li>
|
||||
<li><a href="#org6af085b">3.1.4. Example</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#orge23a1f7">3.2. Effective core potentials (ecp group)</a>
|
||||
<li><a href="#orgb5841c2">3.2. Effective core potentials (ecp group)</a>
|
||||
<ul>
|
||||
<li><a href="#org6d3530f">3.2.1. Example</a></li>
|
||||
<li><a href="#orge0ae08e">3.2.1. Example</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#org94b5aa9">3.3. Numerical integration grid (grid group)</a></li>
|
||||
<li><a href="#org3b31a21">3.3. Numerical integration grid (grid group)</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#orge2309b7">4. Orbitals</a>
|
||||
<li><a href="#org332b63f">4. Orbitals</a>
|
||||
<ul>
|
||||
<li><a href="#org0220bca">4.1. Atomic orbitals (ao group)</a>
|
||||
<li><a href="#orgc53e7eb">4.1. Atomic orbitals (ao group)</a>
|
||||
<ul>
|
||||
<li><a href="#ao_one_e">4.1.1. One-electron integrals (<code>ao_1e_int</code> group)</a></li>
|
||||
<li><a href="#ao_two_e">4.1.2. Two-electron integrals (<code>ao_2e_int</code> group)</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#orge43073a">4.2. Molecular orbitals (mo group)</a>
|
||||
<li><a href="#org4045f98">4.2. Molecular orbitals (mo group)</a>
|
||||
<ul>
|
||||
<li><a href="#org96b1638">4.2.1. One-electron integrals (<code>mo_1e_int</code> group)</a></li>
|
||||
<li><a href="#orgcbfd718">4.2.2. Two-electron integrals (<code>mo_2e_int</code> group)</a></li>
|
||||
<li><a href="#orga28d47c">4.2.1. One-electron integrals (<code>mo_1e_int</code> group)</a></li>
|
||||
<li><a href="#org61e257d">4.2.2. Two-electron integrals (<code>mo_2e_int</code> group)</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#org1714ecd">5. Multi-determinant information</a>
|
||||
<li><a href="#org1d52fba">5. Multi-determinant information</a>
|
||||
<ul>
|
||||
<li><a href="#org3a47fb0">5.1. Slater determinants (determinant group)</a></li>
|
||||
<li><a href="#org1de4c82">5.2. Configuration state functions (csf group)</a></li>
|
||||
<li><a href="#orgcfe855b">5.3. Amplitudes (amplitude group)</a></li>
|
||||
<li><a href="#orgba4ea53">5.4. Reduced density matrices (rdm group)</a></li>
|
||||
<li><a href="#orgd3586fa">5.1. Slater determinants (determinant group)</a></li>
|
||||
<li><a href="#org9309407">5.2. Configuration state functions (csf group)</a></li>
|
||||
<li><a href="#org12c69ea">5.3. Amplitudes (amplitude group)</a></li>
|
||||
<li><a href="#org26ff340">5.4. Reduced density matrices (rdm group)</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#org5b9d350">6. Correlation factors</a>
|
||||
<li><a href="#org08838cd">6. Correlation factors</a>
|
||||
<ul>
|
||||
<li><a href="#org3bd58e3">6.1. Jastrow factor (jastrow group)</a>
|
||||
<li><a href="#orga7697dd">6.1. Jastrow factor (jastrow group)</a>
|
||||
<ul>
|
||||
<li><a href="#orgc0a8ff4">6.1.1. CHAMP</a></li>
|
||||
<li><a href="#org0f419c1">6.1.2. Mu</a></li>
|
||||
<li><a href="#org29d0798">6.1.3. Table of values</a></li>
|
||||
<li><a href="#orgec8b4ff">6.1.1. CHAMP</a></li>
|
||||
<li><a href="#orgc9f5362">6.1.2. Mu</a></li>
|
||||
<li><a href="#org5ee9fd8">6.1.3. Table of values</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#org08c11fb">7. Quantum Monte Carlo data (qmc group)</a></li>
|
||||
<li><a href="#org88b5d83">7. Quantum Monte Carlo data (qmc group)</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
@ -422,8 +422,8 @@ is reversed in the produced <code>trex.json</code> configuration file as the
|
||||
library is written in C.
|
||||
</p>
|
||||
|
||||
<div id="outline-container-org52113ee" class="outline-2">
|
||||
<h2 id="org52113ee"><span class="section-number-2">1</span> Metadata (metadata group)</h2>
|
||||
<div id="outline-container-org9cb3921" class="outline-2">
|
||||
<h2 id="org9cb3921"><span class="section-number-2">1</span> Metadata (metadata group)</h2>
|
||||
<div class="outline-text-2" id="text-1">
|
||||
<p>
|
||||
As we expect TREXIO files to be archived in open-data repositories,
|
||||
@ -433,7 +433,7 @@ have participated to the creation of the file, a list of authors of
|
||||
the file, and a textual description.
|
||||
</p>
|
||||
|
||||
<table id="org3a0b0f2" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="org446bb00" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -516,19 +516,19 @@ value can be manually overwritten (in unsafe mode) from <code>1</code> to <code>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgc97f36d" class="outline-2">
|
||||
<h2 id="orgc97f36d"><span class="section-number-2">2</span> System</h2>
|
||||
<div id="outline-container-org8e72032" class="outline-2">
|
||||
<h2 id="org8e72032"><span class="section-number-2">2</span> System</h2>
|
||||
<div class="outline-text-2" id="text-2">
|
||||
</div>
|
||||
<div id="outline-container-org8fe552a" class="outline-3">
|
||||
<h3 id="org8fe552a"><span class="section-number-3">2.1</span> Nucleus (nucleus group)</h3>
|
||||
<div id="outline-container-org1613910" class="outline-3">
|
||||
<h3 id="org1613910"><span class="section-number-3">2.1</span> Nucleus (nucleus group)</h3>
|
||||
<div class="outline-text-3" id="text-2-1">
|
||||
<p>
|
||||
The nuclei are considered as fixed point charges. Coordinates are
|
||||
given in Cartesian \((x,y,z)\) format.
|
||||
</p>
|
||||
|
||||
<table id="orge897227" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="org9a95ce8" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -595,15 +595,15 @@ given in Cartesian \((x,y,z)\) format.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org7fd3ca9" class="outline-3">
|
||||
<h3 id="org7fd3ca9"><span class="section-number-3">2.2</span> Cell (cell group)</h3>
|
||||
<div id="outline-container-org61d39fe" class="outline-3">
|
||||
<h3 id="org61d39fe"><span class="section-number-3">2.2</span> Cell (cell group)</h3>
|
||||
<div class="outline-text-3" id="text-2-2">
|
||||
<p>
|
||||
3 Lattice vectors to define a box containing the system, for example
|
||||
used in periodic calculations.
|
||||
</p>
|
||||
|
||||
<table id="org997af63" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="orgf3358ba" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -677,15 +677,15 @@ used in periodic calculations.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgcc4ffcb" class="outline-3">
|
||||
<h3 id="orgcc4ffcb"><span class="section-number-3">2.3</span> Periodic boundary calculations (pbc group)</h3>
|
||||
<div id="outline-container-orgce86b75" class="outline-3">
|
||||
<h3 id="orgce86b75"><span class="section-number-3">2.3</span> Periodic boundary calculations (pbc group)</h3>
|
||||
<div class="outline-text-3" id="text-2-3">
|
||||
<p>
|
||||
A single $k$-point per TREXIO file can be stored. The $k$-point is
|
||||
defined in this group.
|
||||
</p>
|
||||
|
||||
<table id="org12333a2" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="org571cd01" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -724,8 +724,8 @@ defined in this group.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org54e0b84" class="outline-3">
|
||||
<h3 id="org54e0b84"><span class="section-number-3">2.4</span> Electron (electron group)</h3>
|
||||
<div id="outline-container-orgdcb53ed" class="outline-3">
|
||||
<h3 id="orgdcb53ed"><span class="section-number-3">2.4</span> Electron (electron group)</h3>
|
||||
<div class="outline-text-3" id="text-2-4">
|
||||
<p>
|
||||
The chemical system consists of nuclei and electrons, where the
|
||||
@ -744,7 +744,7 @@ the number of ↑ and ↓ electrons is fixed.
|
||||
</p>
|
||||
|
||||
|
||||
<table id="orgcd50c32" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="org9dd2b06" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -790,8 +790,8 @@ the number of ↑ and ↓ electrons is fixed.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgaeebd1a" class="outline-3">
|
||||
<h3 id="orgaeebd1a"><span class="section-number-3">2.5</span> Ground or excited states (state group)</h3>
|
||||
<div id="outline-container-orgfbf81f7" class="outline-3">
|
||||
<h3 id="orgfbf81f7"><span class="section-number-3">2.5</span> Ground or excited states (state group)</h3>
|
||||
<div class="outline-text-3" id="text-2-5">
|
||||
<p>
|
||||
This group contains information about excited states. Since only a
|
||||
@ -808,7 +808,7 @@ integrals, etc.
|
||||
The <code>id</code> and <code>current_label</code> attributes need to be specified for each file.
|
||||
</p>
|
||||
|
||||
<table id="orgd040aa5" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="org3283171" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -869,16 +869,16 @@ The <code>id</code> and <code>current_label</code> attributes need to be specifi
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org8f4676b" class="outline-2">
|
||||
<h2 id="org8f4676b"><span class="section-number-2">3</span> Basis functions</h2>
|
||||
<div id="outline-container-org196e8d2" class="outline-2">
|
||||
<h2 id="org196e8d2"><span class="section-number-2">3</span> Basis functions</h2>
|
||||
<div class="outline-text-2" id="text-3">
|
||||
</div>
|
||||
<div id="outline-container-org24b642a" class="outline-3">
|
||||
<h3 id="org24b642a"><span class="section-number-3">3.1</span> Basis set (basis group)</h3>
|
||||
<div id="outline-container-orgc0f3f1c" class="outline-3">
|
||||
<h3 id="orgc0f3f1c"><span class="section-number-3">3.1</span> Basis set (basis group)</h3>
|
||||
<div class="outline-text-3" id="text-3-1">
|
||||
</div>
|
||||
<div id="outline-container-orgbbbbc3c" class="outline-4">
|
||||
<h4 id="orgbbbbc3c"><span class="section-number-4">3.1.1</span> Gaussian and Slater-type orbitals</h4>
|
||||
<div id="outline-container-orgca8d913" class="outline-4">
|
||||
<h4 id="orgca8d913"><span class="section-number-4">3.1.1</span> Gaussian and Slater-type orbitals</h4>
|
||||
<div class="outline-text-4" id="text-3-1-1">
|
||||
<p>
|
||||
We consider here basis functions centered on nuclei. Hence, it is
|
||||
@ -932,8 +932,8 @@ All the basis set parameters are stored in one-dimensional arrays.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgc385a5b" class="outline-4">
|
||||
<h4 id="orgc385a5b"><span class="section-number-4">3.1.2</span> Plane waves</h4>
|
||||
<div id="outline-container-org79c6672" class="outline-4">
|
||||
<h4 id="org79c6672"><span class="section-number-4">3.1.2</span> Plane waves</h4>
|
||||
<div class="outline-text-4" id="text-3-1-2">
|
||||
<p>
|
||||
A plane wave is defined as
|
||||
@ -954,10 +954,10 @@ plane waves.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orge491313" class="outline-4">
|
||||
<h4 id="orge491313"><span class="section-number-4">3.1.3</span> Data definitions</h4>
|
||||
<div id="outline-container-orgeb8efcd" class="outline-4">
|
||||
<h4 id="orgeb8efcd"><span class="section-number-4">3.1.3</span> Data definitions</h4>
|
||||
<div class="outline-text-4" id="text-3-1-3">
|
||||
<table id="org0c421e2" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="org0a361e5" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -1066,8 +1066,8 @@ plane waves.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orge4436c6" class="outline-4">
|
||||
<h4 id="orge4436c6"><span class="section-number-4">3.1.4</span> Example</h4>
|
||||
<div id="outline-container-org6af085b" class="outline-4">
|
||||
<h4 id="org6af085b"><span class="section-number-4">3.1.4</span> Example</h4>
|
||||
<div class="outline-text-4" id="text-3-1-4">
|
||||
<p>
|
||||
For example, consider H<sub>2</sub> with the following basis set (in GAMESS
|
||||
@ -1145,8 +1145,8 @@ prim_factor =
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orge23a1f7" class="outline-3">
|
||||
<h3 id="orge23a1f7"><span class="section-number-3">3.2</span> Effective core potentials (ecp group)</h3>
|
||||
<div id="outline-container-orgb5841c2" class="outline-3">
|
||||
<h3 id="orgb5841c2"><span class="section-number-3">3.2</span> Effective core potentials (ecp group)</h3>
|
||||
<div class="outline-text-3" id="text-3-2">
|
||||
<p>
|
||||
An effective core potential (ECP) \(V_A^{\text{ECP}}\) replacing the
|
||||
@ -1180,7 +1180,7 @@ where \(Z_\text{eff}\) is the effective nuclear charge of the center.
|
||||
See <a href="http://dx.doi.org/10.1063/1.4984046">http://dx.doi.org/10.1063/1.4984046</a> or <a href="https://doi.org/10.1063/1.5121006">https://doi.org/10.1063/1.5121006</a> for more info.
|
||||
</p>
|
||||
|
||||
<table id="orgc7e96cd" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="orge3d97ef" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -1284,8 +1284,8 @@ If you encounter the aforementioned issue, please report it to our
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org6d3530f" class="outline-4">
|
||||
<h4 id="org6d3530f"><span class="section-number-4">3.2.1</span> Example</h4>
|
||||
<div id="outline-container-orge0ae08e" class="outline-4">
|
||||
<h4 id="orge0ae08e"><span class="section-number-4">3.2.1</span> Example</h4>
|
||||
<div class="outline-text-4" id="text-3-2-1">
|
||||
<p>
|
||||
For example, consider H<sub>2</sub> molecule with the following
|
||||
@ -1348,8 +1348,8 @@ power = [
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org94b5aa9" class="outline-3">
|
||||
<h3 id="org94b5aa9"><span class="section-number-3">3.3</span> Numerical integration grid (grid group)</h3>
|
||||
<div id="outline-container-org3b31a21" class="outline-3">
|
||||
<h3 id="org3b31a21"><span class="section-number-3">3.3</span> Numerical integration grid (grid group)</h3>
|
||||
<div class="outline-text-3" id="text-3-3">
|
||||
<p>
|
||||
In some applications, such as DFT calculations, integrals have to
|
||||
@ -1364,7 +1364,7 @@ The structure of this group is adapted for the <a href="https://github.com/dftli
|
||||
Feel free to submit a PR if you find missing options/functionalities.
|
||||
</p>
|
||||
|
||||
<table id="orgabb3b27" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="org9ef2a82" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -1481,12 +1481,12 @@ Feel free to submit a PR if you find missing options/functionalities.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orge2309b7" class="outline-2">
|
||||
<h2 id="orge2309b7"><span class="section-number-2">4</span> Orbitals</h2>
|
||||
<div id="outline-container-org332b63f" class="outline-2">
|
||||
<h2 id="org332b63f"><span class="section-number-2">4</span> Orbitals</h2>
|
||||
<div class="outline-text-2" id="text-4">
|
||||
</div>
|
||||
<div id="outline-container-org0220bca" class="outline-3">
|
||||
<h3 id="org0220bca"><span class="section-number-3">4.1</span> Atomic orbitals (ao group)</h3>
|
||||
<div id="outline-container-orgc53e7eb" class="outline-3">
|
||||
<h3 id="orgc53e7eb"><span class="section-number-3">4.1</span> Atomic orbitals (ao group)</h3>
|
||||
<div class="outline-text-3" id="text-4-1">
|
||||
<p>
|
||||
AOs are defined as
|
||||
@ -1567,7 +1567,7 @@ AO, so the correction factor \(\mathcal{N}_i'\) for \(d_{xy}\) in the
|
||||
</p>
|
||||
|
||||
|
||||
<table id="org275ce0c" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="org0d7ea90" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -1619,7 +1619,7 @@ AO, so the correction factor \(\mathcal{N}_i'\) for \(d_{xy}\) in the
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org84c4720" class="outline-4">
|
||||
<div id="outline-container-orgf830d71" class="outline-4">
|
||||
<h4 id="ao_one_e"><span class="section-number-4">4.1.1</span> One-electron integrals (<code>ao_1e_int</code> group)</h4>
|
||||
<div class="outline-text-4" id="text-ao_one_e">
|
||||
<ul class="org-ul">
|
||||
@ -1637,7 +1637,7 @@ The one-electron integrals for a one-electron operator \(\hat{O}\) are
|
||||
over atomic orbitals.
|
||||
</p>
|
||||
|
||||
<table id="orgb688ad5" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="orgea63df0" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -1732,7 +1732,7 @@ over atomic orbitals.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgeab7bd6" class="outline-4">
|
||||
<div id="outline-container-orgb0013d0" class="outline-4">
|
||||
<h4 id="ao_two_e"><span class="section-number-4">4.1.2</span> Two-electron integrals (<code>ao_2e_int</code> group)</h4>
|
||||
<div class="outline-text-4" id="text-ao_two_e">
|
||||
<p>
|
||||
@ -1758,7 +1758,7 @@ The Cholesky decomposition of the integrals can also be stored:
|
||||
\]
|
||||
</p>
|
||||
|
||||
<table id="org7aa6ce5" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="org5fbcc4a" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -1826,10 +1826,10 @@ The Cholesky decomposition of the integrals can also be stored:
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orge43073a" class="outline-3">
|
||||
<h3 id="orge43073a"><span class="section-number-3">4.2</span> Molecular orbitals (mo group)</h3>
|
||||
<div id="outline-container-org4045f98" class="outline-3">
|
||||
<h3 id="org4045f98"><span class="section-number-3">4.2</span> Molecular orbitals (mo group)</h3>
|
||||
<div class="outline-text-3" id="text-4-2">
|
||||
<table id="org17a602a" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="orga6f879a" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -1916,8 +1916,8 @@ The Cholesky decomposition of the integrals can also be stored:
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org96b1638" class="outline-4">
|
||||
<h4 id="org96b1638"><span class="section-number-4">4.2.1</span> One-electron integrals (<code>mo_1e_int</code> group)</h4>
|
||||
<div id="outline-container-orga28d47c" class="outline-4">
|
||||
<h4 id="orga28d47c"><span class="section-number-4">4.2.1</span> One-electron integrals (<code>mo_1e_int</code> group)</h4>
|
||||
<div class="outline-text-4" id="text-4-2-1">
|
||||
<p>
|
||||
The operators as the same as those defined in the
|
||||
@ -1925,7 +1925,7 @@ The operators as the same as those defined in the
|
||||
the basis of molecular orbitals.
|
||||
</p>
|
||||
|
||||
<table id="orgac0a369" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="org3033ef9" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -2020,8 +2020,8 @@ the basis of molecular orbitals.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgcbfd718" class="outline-4">
|
||||
<h4 id="orgcbfd718"><span class="section-number-4">4.2.2</span> Two-electron integrals (<code>mo_2e_int</code> group)</h4>
|
||||
<div id="outline-container-org61e257d" class="outline-4">
|
||||
<h4 id="org61e257d"><span class="section-number-4">4.2.2</span> Two-electron integrals (<code>mo_2e_int</code> group)</h4>
|
||||
<div class="outline-text-4" id="text-4-2-2">
|
||||
<p>
|
||||
The operators are the same as those defined in the
|
||||
@ -2029,7 +2029,7 @@ The operators are the same as those defined in the
|
||||
the basis of molecular orbitals.
|
||||
</p>
|
||||
|
||||
<table id="orgdec4970" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="org056a475" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -2098,12 +2098,12 @@ the basis of molecular orbitals.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org1714ecd" class="outline-2">
|
||||
<h2 id="org1714ecd"><span class="section-number-2">5</span> Multi-determinant information</h2>
|
||||
<div id="outline-container-org1d52fba" class="outline-2">
|
||||
<h2 id="org1d52fba"><span class="section-number-2">5</span> Multi-determinant information</h2>
|
||||
<div class="outline-text-2" id="text-5">
|
||||
</div>
|
||||
<div id="outline-container-org3a47fb0" class="outline-3">
|
||||
<h3 id="org3a47fb0"><span class="section-number-3">5.1</span> Slater determinants (determinant group)</h3>
|
||||
<div id="outline-container-orgd3586fa" class="outline-3">
|
||||
<h3 id="orgd3586fa"><span class="section-number-3">5.1</span> Slater determinants (determinant group)</h3>
|
||||
<div class="outline-text-3" id="text-5-1">
|
||||
<p>
|
||||
The configuration interaction (CI) wave function \(\Psi\)
|
||||
@ -2145,7 +2145,7 @@ produced by the code generator.
|
||||
An illustration on how to read determinants is presented in the <a href="./examples.html">examples</a>.
|
||||
</p>
|
||||
|
||||
<table id="orgdd31333" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="orgd061a7b" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -2191,8 +2191,8 @@ An illustration on how to read determinants is presented in the <a href="./examp
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org1de4c82" class="outline-3">
|
||||
<h3 id="org1de4c82"><span class="section-number-3">5.2</span> Configuration state functions (csf group)</h3>
|
||||
<div id="outline-container-org9309407" class="outline-3">
|
||||
<h3 id="org9309407"><span class="section-number-3">5.2</span> Configuration state functions (csf group)</h3>
|
||||
<div class="outline-text-3" id="text-5-2">
|
||||
<p>
|
||||
The configuration interaction (CI) wave function \(\Psi\) can be
|
||||
@ -2214,7 +2214,7 @@ matrix \(\langle D_I | \psi_J \rangle\) needed to project the CSFs in
|
||||
the basis of Slater determinants.
|
||||
</p>
|
||||
|
||||
<table id="orgf3ae2dd" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="org207358d" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -2260,8 +2260,8 @@ the basis of Slater determinants.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgcfe855b" class="outline-3">
|
||||
<h3 id="orgcfe855b"><span class="section-number-3">5.3</span> Amplitudes (amplitude group)</h3>
|
||||
<div id="outline-container-org12c69ea" class="outline-3">
|
||||
<h3 id="org12c69ea"><span class="section-number-3">5.3</span> Amplitudes (amplitude group)</h3>
|
||||
<div class="outline-text-3" id="text-5-3">
|
||||
<p>
|
||||
The wave function may be expressed in terms of action of the cluster
|
||||
@ -2332,7 +2332,7 @@ The order of the indices is chosen such that
|
||||
<li>\(\dots\)</li>
|
||||
</ul>
|
||||
|
||||
<table id="orgda164e3" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="org725d8e2" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -2413,8 +2413,8 @@ The order of the indices is chosen such that
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgba4ea53" class="outline-3">
|
||||
<h3 id="orgba4ea53"><span class="section-number-3">5.4</span> Reduced density matrices (rdm group)</h3>
|
||||
<div id="outline-container-org26ff340" class="outline-3">
|
||||
<h3 id="org26ff340"><span class="section-number-3">5.4</span> Reduced density matrices (rdm group)</h3>
|
||||
<div class="outline-text-3" id="text-5-4">
|
||||
<p>
|
||||
The reduced density matrices are defined in the basis of molecular
|
||||
@ -2486,7 +2486,7 @@ expressed in a basis of a one-electron function
|
||||
\(g_{ik}(\mathbf{r}_1) = \phi_i(\mathbf{r}_1) \phi_k(\mathbf{r}_1)\).
|
||||
</p>
|
||||
|
||||
<table id="orga85627f" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="orgcf20b56" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -2617,12 +2617,12 @@ expressed in a basis of a one-electron function
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org5b9d350" class="outline-2">
|
||||
<h2 id="org5b9d350"><span class="section-number-2">6</span> Correlation factors</h2>
|
||||
<div id="outline-container-org08838cd" class="outline-2">
|
||||
<h2 id="org08838cd"><span class="section-number-2">6</span> Correlation factors</h2>
|
||||
<div class="outline-text-2" id="text-6">
|
||||
</div>
|
||||
<div id="outline-container-org3bd58e3" class="outline-3">
|
||||
<h3 id="org3bd58e3"><span class="section-number-3">6.1</span> Jastrow factor (jastrow group)</h3>
|
||||
<div id="outline-container-orga7697dd" class="outline-3">
|
||||
<h3 id="orga7697dd"><span class="section-number-3">6.1</span> Jastrow factor (jastrow group)</h3>
|
||||
<div class="outline-text-3" id="text-6-1">
|
||||
<p>
|
||||
The Jastrow factor is an $N$-electron function which multiplies the CI
|
||||
@ -2647,8 +2647,8 @@ following:
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-orgc0a8ff4" class="outline-4">
|
||||
<h4 id="orgc0a8ff4"><span class="section-number-4">6.1.1</span> CHAMP</h4>
|
||||
<div id="outline-container-orgec8b4ff" class="outline-4">
|
||||
<h4 id="orgec8b4ff"><span class="section-number-4">6.1.1</span> CHAMP</h4>
|
||||
<div class="outline-text-4" id="text-6-1-1">
|
||||
<p>
|
||||
The first form of Jastrow factor is the one used in
|
||||
@ -2749,8 +2749,8 @@ The terms \(J_{\text{ee},ij}^\infty\) and \(J_{\text{eN}}^\infty\) are shifts to
|
||||
</div>
|
||||
|
||||
|
||||
<div id="outline-container-org0f419c1" class="outline-4">
|
||||
<h4 id="org0f419c1"><span class="section-number-4">6.1.2</span> Mu</h4>
|
||||
<div id="outline-container-orgc9f5362" class="outline-4">
|
||||
<h4 id="orgc9f5362"><span class="section-number-4">6.1.2</span> Mu</h4>
|
||||
<div class="outline-text-4" id="text-6-1-2">
|
||||
<p>
|
||||
<a href="https://aip.scitation.org/doi/10.1063/5.0044683">Mu-Jastrow</a> is based on a one-parameter correlation factor that has
|
||||
@ -2847,10 +2847,10 @@ The parameter \(\mu\) is stored in the <code>ee</code> array, the parameters
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org29d0798" class="outline-4">
|
||||
<h4 id="org29d0798"><span class="section-number-4">6.1.3</span> Table of values</h4>
|
||||
<div id="outline-container-org5ee9fd8" class="outline-4">
|
||||
<h4 id="org5ee9fd8"><span class="section-number-4">6.1.3</span> Table of values</h4>
|
||||
<div class="outline-text-4" id="text-6-1-3">
|
||||
<table id="org0592c93" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="orgd4c622b" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -2954,8 +2954,8 @@ The parameter \(\mu\) is stored in the <code>ee</code> array, the parameters
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="outline-container-org08c11fb" class="outline-2">
|
||||
<h2 id="org08c11fb"><span class="section-number-2">7</span> Quantum Monte Carlo data (qmc group)</h2>
|
||||
<div id="outline-container-org88b5d83" class="outline-2">
|
||||
<h2 id="org88b5d83"><span class="section-number-2">7</span> Quantum Monte Carlo data (qmc group)</h2>
|
||||
<div class="outline-text-2" id="text-7">
|
||||
<p>
|
||||
In quantum Monte Carlo calculations, the wave function is evaluated
|
||||
@ -2969,7 +2969,7 @@ By convention, the electron coordinates contain first all the electrons
|
||||
of $↑$-spin and then all the $↓$-spin.
|
||||
</p>
|
||||
|
||||
<table id="org0a65d36" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
<table id="orgc0b3466" border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||
|
||||
|
||||
<colgroup>
|
||||
@ -3024,7 +3024,7 @@ of $↑$-spin and then all the $↓$-spin.
|
||||
</div>
|
||||
<div id="postamble" class="status">
|
||||
<p class="author">Author: TREX-CoE</p>
|
||||
<p class="date">Created: 2023-04-26 Wed 08:13</p>
|
||||
<p class="date">Created: 2023-05-05 Fri 07:24</p>
|
||||
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
|
||||
</div>
|
||||
</body>
|
||||
|
Loading…
Reference in New Issue
Block a user