9
1
mirror of https://github.com/QuantumPackage/qp2.git synced 2024-11-09 06:53:38 +01:00

Compare commits

..

No commits in common. "1383368ccc82ce6d82d9dcf251945fa7d91bab96" and "3c353e990bc498321dd767ee96c48873df52982b" have entirely different histories.

4 changed files with 12 additions and 12 deletions

1
configure vendored
View File

@ -330,6 +330,7 @@ EOF
opam init --verbose --yes --compiler=4.07.1 --disable-sandboxing
eval $(opam env)
EOF
execute << EOF
opam install -y \${OCAML_PACKAGES} || exit 1
EOF

View File

@ -47,7 +47,6 @@
pages = {084103},
author = {Anthony Fert{\'{e}} and Emmanuel Giner and Julien Toulouse},
title = {Range-separated multideterminant density-functional theory with a short-range correlation functional of the on-top pair density},
journal = {The Journal of Chemical Physics}
}
@article{Caffarel_2019,

View File

@ -3,8 +3,7 @@ open Sexplib.Std
type t = int64 array [@@deriving sexp]
external to_int64_array : t -> int64 array = "%identity"
external of_int64_array_no_check : int64 array -> t = "%identity"
let to_int64_array (x:t) = (x:int64 array)
let to_alpha_beta x =
@ -62,6 +61,7 @@ let of_int64_array ~n_int ~alpha ~beta x =
end;
x
let of_int64_array_no_check x = x
let of_bitlist_couple ?n_int ~alpha ~beta (xa,xb) =
let ba, bb =

View File

@ -196,9 +196,8 @@ end = struct
let write_psi_coef ~n_det ~n_states c =
let n_det = Det_number.to_int n_det
and c =
Array.map Det_coef.to_float c
|> Array.to_list
and c = Array.to_list c
|> List.map Det_coef.to_float
and n_states =
States_number.to_int n_states
in
@ -240,11 +239,12 @@ end = struct
assert (n_int = dim.(0));
assert (dim.(1) = 2);
assert (dim.(2) = (Det_number.to_int (read_n_det ())));
Array.init dim.(2) (fun i ->
List.init dim.(2) (fun i ->
Array.sub data (2*n_int*i) (2*n_int) )
|> Array.map (Determinant.of_int64_array
|> List.map (Determinant.of_int64_array
~n_int:(N_int_number.of_int n_int)
~alpha:n_alpha ~beta:n_beta )
|> Array.of_list
;;
let write_psi_det ~n_int ~n_det d =
@ -363,7 +363,7 @@ Determinants ::
"
(b.expected_s2 |> Positive_float.to_string)
(b.n_det |> Det_number.to_string)
(b.state_average_weight |> Array.map Positive_float.to_string |> Array.to_list |> String.concat "\t")
(b.state_average_weight |> Array.to_list |> List.map Positive_float.to_string |> String.concat "\t")
det_text
|> Rst_string.of_string
;;
@ -387,10 +387,10 @@ psi_det = %s
(b.n_states |> States_number.to_string)
(b.expected_s2 |> Positive_float.to_string)
(b.state_average_weight |> Array.to_list |> List.map Positive_float.to_string |> String.concat ",")
(b.psi_coef |> Array.map Det_coef.to_string |> Array.to_list
(b.psi_coef |> Array.to_list |> List.map Det_coef.to_string
|> String.concat ", ")
(b.psi_det |> Array.map (Determinant.to_string ~mo_num) |> Array.to_list
|> String.concat "\n\n")
(b.psi_det |> Array.to_list |> List.map (Determinant.to_string
~mo_num) |> String.concat "\n\n")
;;
let of_rst r =