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

Merge pull request #97 from TREX-CoE/csf

Added CSF group
This commit is contained in:
Anthony Scemama 2022-09-06 17:29:37 +02:00 committed by GitHub
commit cb073ddac4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 40 additions and 3 deletions

View File

@ -8,6 +8,7 @@ CHANGES
- Added `trexio_has_group` functionality
- Added OCaml binding
- Added spin and energy in MOs
- Added CSF group
2.2
---

View File

@ -19,8 +19,8 @@ LT_INIT
# Activate developer mode when the source is the git repository.
# Otherwise, it is the source distribution and the developer mode should not be activated.
TEST_IFEXISTS=".git"
AC_CHECK_FILE([$TEST_IFEXISTS],
[enable_maintainer_mode="yes"],
AS_IF([test -d $TEST_IFEXISTS],
[enable_maintainer_mode="yes"]
)
VERSION_MAJOR=`echo ${PACKAGE_VERSION} | cut -d. -f1`

View File

@ -257,7 +257,7 @@ HDF5 support is being disabled (equivalent to --with-hdf5=no).
AC_MSG_WARN([Unable to compile HDF5 test program])
fi
dnl Look for HDF5's high level library
AC_HAVE_LIBRARY([hdf5_hl], [HDF5_LIBS="-lhdf5_hl $HDF5_LIBS"], [], [])
AC_CHECK_LIB([hdf5_hl], [main],[HDF5_LIBS="-lhdf5_hl $HDF5_LIBS"], [], [])
CC=$ax_lib_hdf5_save_CC
CPPFLAGS=$ax_lib_hdf5_save_CPPFLAGS

View File

@ -715,6 +715,42 @@ prim_factor =
#+end_src
:end:
* Configuration state functions (csf group)
The configuration interaction (CI) wave function $\Psi$ can be
expanded in the basis of [[https://en.wikipedia.org/wiki/Configuration_state_function][configuration state functions]] (CSFs)
$\Psi_I$ as follows
\[
\Psi = \sum_I C_I \psi_I.
\]
Each CSF is a linear combination of Slater determinants. Slater
determinants are stored in the =determinant= section. In this group
we store the CI coefficients in the basis of CSFs, and the
matrix $\langle D_I | \psi_J \rangle$ needed to project the CSFs in
the basis of Slater determinants.
#+NAME: csf
| Variable | Type | Dimensions | Description |
|-------------------+-----------------+-----------------------------+------------------------------------------------|
| ~num~ | ~dim readonly~ | | Number of CSFs |
| ~coefficient~ | ~float special~ | ~(state.num,csf.num)~ | Coefficients of the CSFs from the CI expansion |
| ~det_coefficient~ | ~float sparse~ | ~(determinant.num,csf.num)~ | Projection on the determinant basis |
#+CALL: json(data=csf, title="csf")
#+RESULTS:
:results:
#+begin_src python :tangle trex.json
"csf": {
"num" : [ "dim readonly" , [] ]
, "coefficient" : [ "float special", [ "csf.num", "state.num" ] ]
, "det_coefficient" : [ "float sparse" , [ "csf.num", "determinant.num" ] ]
} ,
#+end_src
:end:
* Excited states (state group)
By default, the ~determinant~ group corresponds to the ground state.