1
0
mirror of https://github.com/TREX-CoE/trexio.git synced 2024-12-23 04:43:57 +01:00

split the basis format to depend on shell_num and prim_num

This commit is contained in:
q-posev 2021-10-21 15:51:21 +02:00
parent 64b3e25da5
commit 9321213a21

View File

@ -216,16 +216,17 @@ arrays are 0-based. Hence, we introduce the ~index~ type which is an
#+NAME: basis #+NAME: basis
| Variable | Type | Dimensions | Description | | Variable | Type | Dimensions | Description |
|-----------------+---------+---------------+------------------------------------------------------------------| |-----------------+---------+---------------------+--------------------------------------------------------------|
| ~type~ | ~str~ | | Type of basis set: "Gaussian" or "Slater" | | ~type~ | ~str~ | | Type of basis set: "Gaussian" or "Slater" |
| ~num~ | ~dim~ | | Total number of primitives | | ~prim_num~ | ~dim~ | | Total number of primitives |
| ~nucleus_index~ | ~index~ | ~(basis.num)~ | One-to-one correspondence between primitives and atomic indices | | ~shell_num~ | ~dim~ | | Total number of shells |
| ~ang_mom~ | ~int~ | ~(basis.num)~ | One-to-one correspondence between primitives and angular momenta | | ~nucleus_index~ | ~index~ | ~(basis.shell_num)~ | One-to-one correspondence between shells and atomic indices |
| ~shell_index~ | ~index~ | ~(basis.num)~ | One-to-one correspondence between primitives and atomic shells | | ~ang_mom~ | ~int~ | ~(basis.shell_num)~ | One-to-one correspondence between shells and angular momenta |
| ~shell_factor~ | ~float~ | ~(basis.num)~ | Normalization factor of the shell ($\mathcal{N}_s$) | | ~shell_factor~ | ~float~ | ~(basis.shell_num)~ | Normalization factor of each shell ($\mathcal{N}_s$) |
| ~exponent~ | ~float~ | ~(basis.num)~ | Exponents of the primitives ($\gamma_{ks}$) | | ~shell_index~ | ~index~ | ~(basis.prim_num)~ | One-to-one correspondence between primitives and shell index |
| ~coefficient~ | ~float~ | ~(basis.num)~ | Coefficients of the primitives ($a_{ks}$) | | ~exponent~ | ~float~ | ~(basis.prim_num)~ | Exponents of the primitives ($\gamma_{ks}$) |
| ~prim_factor~ | ~float~ | ~(basis.num)~ | Normalization coefficients for the primitives ($f_{ks}$) | | ~coefficient~ | ~float~ | ~(basis.prim_num)~ | Coefficients of the primitives ($a_{ks}$) |
| ~prim_factor~ | ~float~ | ~(basis.prim_num)~ | Normalization coefficients for the primitives ($f_{ks}$) |
#+CALL: json(data=basis, title="basis") #+CALL: json(data=basis, title="basis")
@ -234,14 +235,15 @@ arrays are 0-based. Hence, we introduce the ~index~ type which is an
#+begin_src python :tangle trex.json #+begin_src python :tangle trex.json
"basis": { "basis": {
"type" : [ "str" , [] ] "type" : [ "str" , [] ]
, "num" : [ "dim" , [] ] , "prim_num" : [ "dim" , [] ]
, "nucleus_index" : [ "index", [ "basis.num" ] ] , "shell_num" : [ "dim" , [] ]
, "ang_mom" : [ "int" , [ "basis.num" ] ] , "nucleus_index" : [ "index", [ "basis.shell_num" ] ]
, "shell_index" : [ "index", [ "basis.num" ] ] , "ang_mom" : [ "int" , [ "basis.shell_num" ] ]
, "shell_factor" : [ "float", [ "basis.num" ] ] , "shell_factor" : [ "float", [ "basis.shell_num" ] ]
, "exponent" : [ "float", [ "basis.num" ] ] , "shell_index" : [ "index", [ "basis.prim_num" ] ]
, "coefficient" : [ "float", [ "basis.num" ] ] , "exponent" : [ "float", [ "basis.prim_num" ] ]
, "prim_factor" : [ "float", [ "basis.num" ] ] , "coefficient" : [ "float", [ "basis.prim_num" ] ]
, "prim_factor" : [ "float", [ "basis.prim_num" ] ]
} , } ,
#+end_src #+end_src
:END: :END:
@ -275,27 +277,28 @@ D 1
#+BEGIN_EXAMPLE #+BEGIN_EXAMPLE
type = "Gaussian" type = "Gaussian"
num = 20 prim_num = 20
shell_num = 12
# 10 primitives per H atom # 6 shells per H atom
nucleus_index = nucleus_index =
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, [ 0, 0, 0, 0, 0, 0,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ] 1, 1, 1, 1, 1, 1 ]
# 7 primitives for S (l=0), 2 primitives for P (l=1), 1 primitive for D (l=2) shells # 3 shells in S (l=0), 2 in P (l=1), 1 in D (l=2)
ang_mom = ang_mom =
[ 0, 0, 0, 0, 0, 0, 0, 1, 1, 2, [ 0, 0, 0, 1, 1, 2,
0, 0, 0, 0, 0, 0, 0, 1, 1, 2 ] 0, 0, 0, 1, 1, 2 ]
# 5 primitives for first S shell and then 1 primitive per remaining shells
shell_index =
[ 0, 0, 0, 0, 0, 1, 2, 3, 4, 5,
0, 0, 0, 0, 0, 1, 2, 3, 4, 5 ]
# no need to renormalize shells # no need to renormalize shells
shell_factor = shell_factor =
[ 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., [ 1., 1., 1., 1., 1., 1.,
1., 1., 1., 1., 1., 1., 1., 1., 1., 1. ] 1., 1., 1., 1., 1., 1. ]
# 5 primitives for the first S shell and then 1 primitive per remaining shells in each H atom
shell_index =
[ 0, 0, 0, 0, 0, 1, 2, 3, 4, 5,
6, 6, 6, 6, 6, 7, 8, 9, 10, 11 ]
# parameters of the primitives (10 per H atom) # parameters of the primitives (10 per H atom)
exponent = exponent =