Skip to content

Commit

Permalink
Checkout tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
shuhangli98 committed Mar 22, 2024
1 parent 8855c90 commit 5ed05e9
Show file tree
Hide file tree
Showing 464 changed files with 261,249 additions and 99,535 deletions.
4 changes: 2 additions & 2 deletions tests/chemps2/dmrgscf-1/input.dat
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ cholesky_tolerance 1e-10
}

set forte{
job_type casscf
job_type mcscf_two_step
int_type cholesky
cholesky_tolerance 1e-10
casscf_g_convergence 1e-7
casscf_e_convergence 1e-8
casscf_ci_solver dmrg
active_space_solver dmrg
restricted_docc [2,0,0,0,0,2,0,0]
active [1,0,1,1,0,1,1,1]
dmrg_sweep_states [ 500, 1000, 2000 ]
Expand Down
2 changes: 1 addition & 1 deletion tests/chemps2/dmrgscf-2/input.dat
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ ints_tolerance 0.0

set forte{
job_type mcscf_two_step
casscf_ci_solver dmrg
active_space_solver dmrg
avg_state [[0,1,2], [1,1,1], [2,1,1]]
restricted_docc [ 1, 0, 0, 0 ]
active [ 3, 0, 4, 2 ]
Expand Down
2 changes: 1 addition & 1 deletion tests/chemps2/dmrgscf-3/input.dat
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,9 @@ compare_values(ref_scf, escf, 8, "DF-RHF/def2-SVP Energy")
set forte {
int_type df
job_type mcscf_two_step
active_space_solver dmrg
restricted_docc [9,6,0,0,0,0,7,7]
active [0,0,2,3,2,3,0,0]
casscf_ci_solver dmrg
dmrg_sweep_states [ 200, 500, 1000, 2000 ]
dmrg_sweep_energy_conv [ 1e-6, 1e-8, 1e-8, 1e-10 ]
dmrg_sweep_max_sweeps [ 5, 5, 5, 100 ]
Expand Down
33 changes: 29 additions & 4 deletions tests/code/test_determinant.hpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,32 @@
#ifndef _test_determinant_
#define _test_determinant_
/*
* @BEGIN LICENSE
*
* Forte: an open-source plugin to Psi4 (https://github.com/psi4/psi4)
* that implements a variety of quantum chemistry methods for strongly
* correlated electrons.
*
* Copyright (c) 2012-2024 by its authors (see COPYING, COPYING.LESSER, AUTHORS).
*
* The copyrights for code used from other parties are included in
* the corresponding files.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with this program. If not, see http://www.gnu.org/licenses/.
*
* @END LICENSE
*/

#pragma once

#include <cstddef>
#include <vector>
Expand Down Expand Up @@ -359,5 +386,3 @@ template <size_t N> void test_determinantimpl_count_functions() {
REQUIRE(d.npair() == npair);
}
}

#endif // _test_determinant_
24 changes: 24 additions & 0 deletions tests/manual/fci-1/input.dat
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# forte/tests/manual/fci-1/input.dat

import forte

molecule li2 {
0 1
Li
Li 1 1.6
}

set {
basis cc-pVDZ
reference rhf
}

set forte {
active_space_solver fci
}

# run a RHF computation
E_scf, scf_wfn = energy('scf', return_wfn=True)

# pass the RHF orbitals to Forte and run a FCI computation
energy('forte', ref_wfn=scf_wfn)
Loading

0 comments on commit 5ed05e9

Please sign in to comment.