Skip to content

Commit 75d8269

Browse files
authored
Merge pull request #7 from fkfest/auto/from-devel-repo
Merge changes from development repository
2 parents 1de7803 + 0802edd commit 75d8269

File tree

2,282 files changed

+1231397
-519
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,282 files changed

+1231397
-519
lines changed

.github/workflows/CompatHelper.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: CompatHelper
2+
on:
3+
schedule:
4+
- cron: 0 0 * * *
5+
workflow_dispatch:
6+
permissions:
7+
contents: write
8+
pull-requests: write
9+
jobs:
10+
CompatHelper:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Check if Julia is already available in the PATH
14+
id: julia_in_path
15+
run: which julia
16+
continue-on-error: true
17+
- name: Install Julia, but only if it is not already available in the PATH
18+
uses: julia-actions/setup-julia@v1
19+
with:
20+
version: '1'
21+
arch: ${{ runner.arch }}
22+
if: steps.julia_in_path.outcome != 'success'
23+
- name: "Add the General registry via Git"
24+
run: |
25+
import Pkg
26+
ENV["JULIA_PKG_SERVER"] = ""
27+
Pkg.Registry.add("General")
28+
shell: julia --color=yes {0}
29+
- name: "Install CompatHelper"
30+
run: |
31+
import Pkg
32+
name = "CompatHelper"
33+
uuid = "aa819f21-2bde-4658-8897-bab36330d9b7"
34+
version = "3"
35+
Pkg.add(; name, uuid, version)
36+
shell: julia --color=yes {0}
37+
- name: "Run CompatHelper"
38+
run: |
39+
import CompatHelper
40+
CompatHelper.main()
41+
shell: julia --color=yes {0}
42+
env:
43+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
44+
COMPATHELPER_PRIV: ${{ secrets.DOCUMENTER_KEY }}
45+
# COMPATHELPER_PRIV: ${{ secrets.COMPATHELPER_PRIV }}

CHANGELOG.md

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,33 @@
11
# Release notes
22

3+
## Version [v0.12.0] - 2024.05.28
4+
5+
### Breaking
6+
7+
* the `mp2fit` (`rifit`) basis sets have been renamed to `mpfit`.
8+
* `ERI_?e?c` routines have been renamed to `eri_?e?idx`.
9+
10+
### Changed
11+
12+
* use SVD in DIIS.
13+
* increase number of iterations in 2D-CCSD IAS test.
14+
* interface to `libcint_jll` has been implemented. The basis set library is added (in Molpro format), and basis sets are parsed to a `BasisSet` object. `GaussianBasis.jl` dependency is removed.
15+
16+
### Added
17+
18+
* Expand README
19+
* `amdmkl()` function to speed up MKL on AMD machines.
20+
* CROP-DIIS option (JCTC 11, 1518 (2015)) which is less sensitive to the DIIS dimension. To activate, set `diis` option `crop=true`, the DIIS dimension can be changed using `maxcrop` (default is 3).
21+
* An option `print_init` is added to the `@print_input` macro (default is `false`). If set to `true`, the `ElemCo.jl` info is printed again (useful if the output is redirected in julia to a file).
22+
* A simple DMRG routine is added based on `ITensors` (adapted from `ITensorChemistry.jl`).
23+
* A Molpro interface to import matrop matrices (orbitals or overlap).
24+
25+
### Fixed
26+
27+
* Get rid of error message from git if .git is not available (e.g., in the case of the released version).
28+
* Sort orblist, which fixes issues if user occupations are not provided in a sorted list.
29+
* Fix amplitudes before Hylleraas energy calculation for FR-CC, which will properly report the energy in a (2,2) (single iteration) calculation.
30+
331
## Version [v0.11.1] - 2024.04.12
432

533
### Changed

Project.toml

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,39 @@
11
name = "ElemCo"
22
uuid = "094d408e-8508-40f4-9646-a254980d91ac"
33
authors = ["Daniel Kats <d.kats@fkf.mpg.de> and contributors"]
4-
version = "0.11.1"
4+
version = "0.12.0"
55

66
[deps]
77
AtomsBase = "a963bdd2-2df7-4f54-a1ee-49d51e6be12a"
88
Dates = "ade2ca70-3891-5945-98fb-dc099432e06a"
99
DocStringExtensions = "ffbed154-4ef7-542d-bbb7-c09d3a79fcae"
10-
GaussianBasis = "9bb1a3dc-0d1c-467e-84f5-0c4ef701360a"
10+
ITensors = "9136182c-28ba-11e9-034c-db9fb085ebd5"
1111
IterativeSolvers = "42fd0dbc-a981-5370-80f2-aaf504508153"
1212
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
1313
MKL = "33e6dc65-8f57-5167-99aa-e5a354878fb2"
1414
Mmap = "a63ad114-7e13-5084-954f-fe012c677804"
1515
NPZ = "15e1cf62-19b3-5cfa-8e77-841668bca605"
1616
Printf = "de0858da-6303-5e67-8744-51eddeeeb8d7"
17+
StaticArrays = "90137ffa-7385-5640-81b9-e52037218182"
1718
TensorOperations = "6aa20fa7-93e2-5fca-9bc0-fbd0db3c71a2"
1819
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
1920
Unitful = "1986cc42-f94f-5a68-af5c-568840ba703d"
2021
UnitfulAtomic = "a7773ee8-282e-5fa2-be4e-bd808c38a91a"
22+
libcint_jll = "574b78ca-bebd-517c-801d-4735c93a9686"
2123

2224
[compat]
23-
julia = "1.8.5"
2425
AtomsBase = "0.3.5 - 0.3"
2526
DocStringExtensions = "0.9"
26-
GaussianBasis = "0.4"
27+
ITensors = "0.4.0 - 0.7"
2728
IterativeSolvers = "0.9"
2829
MKL = "0.6"
2930
NPZ = "0.4"
3031
TensorOperations = "3.2.5 - 4"
32+
StaticArrays = "1.4"
3133
Unitful = "1"
3234
UnitfulAtomic = "1"
33-
35+
libcint_jll = "5.1"
36+
julia = "1.8.5"
3437

3538
[extras]
3639
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

README.md

Lines changed: 51 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# ElemCo.jl <img align="right" src="files/coil.png" height=74> <br/><br/>
22

33
Julia implementation of various electron-correlation methods (main focus on coupled cluster methods).
4-
The integrals are obtained from a FCIDUMP file or calculated using the `GaussianBasis` package.
4+
The integrals are obtained from a FCIDUMP file or calculated using an interface to [libcint](https://github.com/sunqm/libcint).
55

66
## Capabilities
77

@@ -32,39 +32,80 @@ The integrals are obtained from a FCIDUMP file or calculated using the `Gaussian
3232
| 2D-DCSD | :heavy_check_mark: | | |
3333
| SVD-DCSD | :heavy_check_mark: |:heavy_check_mark:|:heavy_exclamation_mark:|
3434
| SVD-DC-CCSDT|:heavy_check_mark:|:heavy_check_mark:|:heavy_exclamation_mark:|
35-
35+
| DMRG | :heavy_check_mark: | |:heavy_exclamation_mark:|
3636

3737
## Getting started
3838

3939
Requirements: julia (>1.8)
4040

4141
## Usage
42-
For a development version of `ElemCo.jl`, clone the repository and create an alias to set the project to the `ElemCo.jl` directory,
42+
43+
### Installation
44+
45+
To install `ElemCo.jl`, run the following command in the Julia REPL,
46+
47+
```julia
48+
julia> using Pkg
49+
julia> Pkg.add("ElemCo")
4350
```
51+
52+
For a development version of `ElemCo.jl`, clone the [ElemCo.jl-devel](https://github.com/fkfest/ElemCo.jl-devel) repository and create an alias to set the project to the `ElemCo.jl` directory,
53+
54+
```bash
4455
alias jlm='julia --project=<path_to_ElemCo.jl>'
4556
```
57+
4658
Now the command `jlm` can be used to start the calculations,
47-
```
59+
60+
```bash
4861
jlm input.jl
4962
```
5063

51-
Default scratch directory path on Windows is the first environment variable found in the ordered list `TMP`, `TEMP`, `USERPROFILE`.
52-
On all other operating systems `TMPDIR`, `TMP`, `TEMP`, and `TEMPDIR`. If none of these are found, the path `/tmp` is used.
53-
Default scratch folder name is `elemcojlscr`.
64+
### Input file
65+
66+
The input file is a Julia script that contains the calculation details. The script should start with the following lines,
67+
68+
```julia
69+
using ElemCo
70+
@print_input
71+
```
72+
73+
The `@print_input` macro prints the input file to the standard output. The calculation details are specified using the macros provided by `ElemCo.jl`.
74+
75+
### Macros
76+
77+
The following macros are available in `ElemCo.jl` (see [the documentation for more details and macros](https://elem.co.il/stable/elemco/)),
78+
79+
- `@dfhf` - Performs a density-fitted Hartree-Fock calculation.
80+
- `@cc <method>` - Performs a coupled cluster calculation.
81+
- `@dfcc <method>` - Performs a coupled cluster calculation using density fitting.
82+
- `@set <option> <setting>` - Sets the options for the calculation.
83+
84+
etc.
85+
86+
Default scratch directory path on Windows is the first environment variable found in the ordered list `TMP`, `TEMP`, `USERPROFILE`.
87+
On all other operating systems `TMPDIR`, `TMP`, `TEMP`, and `TEMPDIR`. If none of these are found, the path `/tmp` is used.
88+
Default scratch folder name is `elemcojlscr`.
5489

5590
Variable names `fcidump`, `geometry` and `basis` are reserved for the file name of FCIDUMP, geometry specification and basis sets, respectively.
5691

5792
### Example
93+
5894
#### DCSD calculation using integrals from a FCIDUMP file
95+
5996
The ground state energy can be calculated using the DCSD method with the following script:
97+
6098
```julia
6199
using ElemCo
62100
@print_input
63101
fcidump = "../test/H2O.FCIDUMP"
64102
@cc dcsd
65103
```
104+
66105
#### DCSD calculation of the water molecule using density-fitted integrals
106+
67107
In order to calculate the ground state energy of the water molecule using the DCSD method, the following script can be used:
108+
68109
```julia
69110
using ElemCo
70111
@print_input
@@ -73,18 +114,17 @@ geometry="bohr
73114
H1 0.000000000 1.489124508 1.033245507
74115
H2 0.000000000 -1.489124508 1.033245507"
75116

76-
basis = Dict("ao"=>"cc-pVDZ",
77-
"jkfit"=>"cc-pvtz-jkfit",
78-
"mp2fit"=>"cc-pvdz-rifit")
117+
basis = "vdz"
79118
@dfhf
80119
@cc dcsd
81120
```
121+
82122
The `@dfhf` macro calculates the density-fitted Hartree-Fock energy and orbitals
83123
and then DCSD calculation is performed using density-fitted integrals.
84124

85125
Further example scripts are provided in the `examples` directory.
86126

87-
Documentation is available at https://elem.co.il.
127+
Documentation is available at <https://elem.co.il>.
88128

89129
```
90130
Electron coil

docs/Project.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ Dates = "ade2ca70-3891-5945-98fb-dc099432e06a"
44
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
55
ElemCo = "094d408e-8508-40f4-9646-a254980d91ac"
66
MKL = "33e6dc65-8f57-5167-99aa-e5a354878fb2"
7+
StaticArrays = "90137ffa-7385-5640-81b9-e52037218182"
8+
Unitful = "1986cc42-f94f-5a68-af5c-568840ba703d"
9+
UnitfulAtomic = "a7773ee8-282e-5fa2-be4e-bd808c38a91a"
710

811
[compat]
912
Documenter = "1.1"

docs/make.jl

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ makedocs(
2828
"Options" => "options.md"
2929
],
3030
"Internals" => [
31+
"basisset.md",
3132
"bohf.md",
3233
"cc.md",
3334
"ccdriver.md",
@@ -40,17 +41,22 @@ makedocs(
4041
"dfmcscf.md",
4142
"dftools.md",
4243
"diis.md",
44+
"dmrg.md",
4345
"dump.md",
4446
"dumptools.md",
47+
"elements.md",
4548
"ecinfos.md",
4649
"ecmethod.md",
4750
"fockfactory.md",
51+
"integrals.md",
4852
"mio.md",
4953
"mnpy.md",
5054
"msystem.md",
5155
"orbtools.md",
5256
"tensortools.md",
53-
"utils.md"
57+
"utils.md",
58+
"interfaces.md",
59+
"molpro.md"
5460
],
5561
"release-notes.md",
5662
],

docs/src/basisset.md

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
# Basis set
2+
3+
```@meta
4+
CurrentModule = ElemCo.BasisSets
5+
```
6+
7+
The basis set is defined as a dictionary, where the keys are
8+
the types of the basis sets, and the values are the basis set:
9+
10+
```julia
11+
basis = Dict("ao"=>"cc-pVTZ",
12+
"jkfit"=>"cc-pvtz-jkfit",
13+
"mpfit"=>"cc-pvtz-mpfit")
14+
```
15+
16+
The basis set dictionary contains three keys: `ao`, `jkfit`, and
17+
`mpfit`. The `ao` key contains the basis set for the AO integrals, the
18+
`jkfit` key contains the basis set for the density fitting integrals in the Hartree-Fock calculations,
19+
and the `mpfit` key contains the fitting basis set for the correlated calculations.
20+
21+
Alternatively, you can define the basis set using a string that defines the AO basis. In this case, the `jkfit` and `mpfit` basis names will be generated automatically. Here's an example of how you can define the basis set using a string:
22+
23+
```julia
24+
basis = "cc-pVDZ"
25+
```
26+
27+
Common acronyms are also supported for the basis set names, e.g., `cc-pVDZ` can be written as `vdz`, and
28+
`aug-cc-pVTZ` can be written as `avtz`.
29+
30+
```@docs
31+
BasisSets
32+
```
33+
34+
## Exported functions and types
35+
36+
```@autodocs
37+
Modules = [BasisSets]
38+
Private = false
39+
Order = [:type, :function]
40+
```
41+
42+
## Internal functions and types
43+
44+
```@autodocs
45+
Modules = [BasisSets]
46+
Public = false
47+
Order = [:type, :function]
48+
```

docs/src/dfhf.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ geometry="bohr
2020

2121
basis = Dict("ao"=>"cc-pVDZ",
2222
"jkfit"=>"cc-pvtz-jkfit",
23-
"mp2fit"=>"cc-pvdz-rifit")
23+
"mpfit"=>"cc-pvdz-mpfit")
2424

2525
# Compute DF-HF
2626
@dfhf

docs/src/dmrg.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# DMRG
2+
3+
```@docs
4+
ElemCo.DMRG
5+
```
6+
7+
## Exported functions
8+
9+
```@autodocs
10+
Modules = [ElemCo.DMRG]
11+
Private = false
12+
Order = [:function]
13+
```
14+
15+
## Internal functions
16+
17+
```@autodocs
18+
Modules = [ElemCo.DMRG]
19+
Public = false
20+
Order = [:function]
21+
```

docs/src/elemco.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ One can print the keys of the returned `NamedTuple` to see all the available key
3939
julia> println(keys(energies))
4040
```
4141

42-
## Macros
42+
## [Macros](@id list_of_macros)
4343

4444
```@autodocs
4545
Modules = [ElemCo]

0 commit comments

Comments
 (0)