mirror of
https://github.com/TREX-CoE/qmckl.git
synced 2025-01-03 18:16:28 +01:00
Added cutoff for the calculation of PE. #41
This commit is contained in:
parent
ad9ae8daf9
commit
cd0db55f9d
@ -1729,7 +1729,9 @@ integer function qmckl_compute_ee_potential_f(context, elec_num, walk_num, &
|
||||
do nw=1,walk_num
|
||||
do j=2,elec_num
|
||||
do i=1,j-1
|
||||
ee_pot(nw) = ee_pot(nw) + 1.0d0/(ee_distance(i,j,nw))
|
||||
if (dabs(ee_distance(i,j,nw)) > 1e-5) then
|
||||
ee_pot(nw) = ee_pot(nw) + 1.0d0/(ee_distance(i,j,nw))
|
||||
endif
|
||||
end do
|
||||
end do
|
||||
end do
|
||||
@ -2769,7 +2771,9 @@ integer function qmckl_compute_en_potential_f(context, elec_num, nucl_num, walk_
|
||||
do nw=1,walk_num
|
||||
do j=1,nucl_num
|
||||
do i=1,elec_num
|
||||
en_pot(nw) = en_pot(nw) - charge(j)/(en_distance(i,j,nw))
|
||||
if (dabs(en_distance(i,j,nw)) > 1e-5) then
|
||||
en_pot(nw) = en_pot(nw) - charge(j)/(en_distance(i,j,nw))
|
||||
endif
|
||||
end do
|
||||
end do
|
||||
end do
|
||||
|
@ -78,13 +78,13 @@ int main() {
|
||||
|
||||
Computed data:
|
||||
|
||||
|-----------------------------+------------------+--------------------------------------------------------------|
|
||||
| ~nn_distance~ | double[num][num] | Nucleus-nucleus distances |
|
||||
| ~nn_distance_date~ | int64_t | Date when Nucleus-nucleus distances were computed |
|
||||
| ~nn_distance_rescaled~ | double[num][num] | Nucleus-nucleus rescaled distances |
|
||||
| ~nn_distance_rescaled_date~ | int64_t | Date when Nucleus-nucleus rescaled distances were computed |
|
||||
| ~repulsion~ | double | Nuclear repulsion energy |
|
||||
| ~repulsion_date~ | int64_t | Date when the nuclear repulsion energy was computed |
|
||||
|-----------------------------+------------------+------------------------------------------------------------|
|
||||
| ~nn_distance~ | double[num][num] | Nucleus-nucleus distances |
|
||||
| ~nn_distance_date~ | int64_t | Date when Nucleus-nucleus distances were computed |
|
||||
| ~nn_distance_rescaled~ | double[num][num] | Nucleus-nucleus rescaled distances |
|
||||
| ~nn_distance_rescaled_date~ | int64_t | Date when Nucleus-nucleus rescaled distances were computed |
|
||||
| ~repulsion~ | double | Nuclear repulsion energy |
|
||||
| ~repulsion_date~ | int64_t | Date when the nuclear repulsion energy was computed |
|
||||
|
||||
** Data structure
|
||||
|
||||
@ -1087,7 +1087,9 @@ integer function qmckl_compute_nucleus_repulsion_f(context, nucl_num, charge, nn
|
||||
energy = 0.d0
|
||||
do j=2, nucl_num
|
||||
do i=1, j-1
|
||||
energy = energy + charge(i) * charge(j) / nn_distance(i,j)
|
||||
if (dabs(nn_distance(i,j)) > 1e-5) then
|
||||
energy = energy + charge(i) * charge(j) / nn_distance(i,j)
|
||||
endif
|
||||
end do
|
||||
end do
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user