4
1
mirror of https://github.com/pfloos/quack synced 2024-07-25 12:17:35 +02:00

numgrid project done

This commit is contained in:
Pierre-Francois Loos 2020-03-25 13:31:15 +01:00
parent e3af2bb0aa
commit 1b3be7ae89
6 changed files with 73 additions and 76 deletions

View File

@ -1,38 +1,30 @@
1 6 1 6
S 8
1 1469.0000000 0.0007660
2 220.5000000 0.0058920
3 50.2600000 0.0296710
4 14.2400000 0.1091800
5 4.5810000 0.2827890
6 1.5800000 0.4531230
7 0.5640000 0.2747740
8 0.0734500 0.0097510
S 8
1 1469.0000000 -0.0001200
2 220.5000000 -0.0009230
3 50.2600000 -0.0046890
4 14.2400000 -0.0176820
5 4.5810000 -0.0489020
6 1.5800000 -0.0960090
7 0.5640000 -0.1363800
8 0.0734500 0.5751020
S 1
1 0.0280500 1.0000000
P 3
1 1.5340000 0.0227840
2 0.2749000 0.1391070
3 0.0736200 0.5003750
P 1
1 0.0240300 1.0000000
D 1
1 0.1239000 1.0000000
2 3
S 3 S 3
1 13.0100000 0.0196850 1 33.8700000 0.0060680
2 1.9620000 0.1379770 2 5.0950000 0.0453080
3 0.4446000 0.4781480 3 1.1590000 0.2028220
S 1 S 1
1 0.1220000 1.0000000 1 0.3258000 1.0000000
S 1
1 0.1027000 1.0000000
P 1 P 1
1 0.7270000 1.0000000 1 1.4070000 1.0000000
P 1
1 0.3880000 1.0000000
D 1
1 1.0570000 1.0000000
2 6
S 3
1 33.8700000 0.0060680
2 5.0950000 0.0453080
3 1.1590000 0.2028220
S 1
1 0.3258000 1.0000000
S 1
1 0.1027000 1.0000000
P 1
1 1.4070000 1.0000000
P 1
1 0.3880000 1.0000000
D 1
1 1.0570000 1.0000000

View File

@ -15,10 +15,10 @@
# Hartree-Fock = 666 # Hartree-Fock = 666
1 RVWN5 1 RVWN5
# quadrature grid SG-n # quadrature grid SG-n
2 1
# Number of states in ensemble (nEns) # Number of states in ensemble (nEns)
2 2
# Ensemble weights: wEns(1),...,wEns(nEns-1) # Ensemble weights: wEns(1),...,wEns(nEns-1)
0.50000 0.00000 0.00000 0.00000
# GOK-DFT: maxSCF thresh DIIS n_diis guess_type ortho_type # GOK-DFT: maxSCF thresh DIIS n_diis guess_type ortho_type
32 0.00001 T 5 1 1 32 0.00001 T 5 1 1

View File

@ -1,5 +1,5 @@
# nAt nEla nElb nCore nRyd # nAt nEla nElb nCore nRyd
2 2 2 0 0 2 1 1 0 0
# Znuc x y z # Znuc x y z
Li 0. 0. 0. H 0. 0. 0.
H 0. 0. 3.099 H 0. 0. 1.4

View File

@ -1,4 +1,4 @@
2 2
Li 0.0000000000 0.0000000000 0.0000000000 H 0.0000000000 0.0000000000 0.0000000000
H 0.0000000000 0.0000000000 1.6399202947 H 0.0000000000 0.0000000000 0.7408481486

View File

@ -1,38 +1,30 @@
1 6 1 6
S 8
1 1469.0000000 0.0007660
2 220.5000000 0.0058920
3 50.2600000 0.0296710
4 14.2400000 0.1091800
5 4.5810000 0.2827890
6 1.5800000 0.4531230
7 0.5640000 0.2747740
8 0.0734500 0.0097510
S 8
1 1469.0000000 -0.0001200
2 220.5000000 -0.0009230
3 50.2600000 -0.0046890
4 14.2400000 -0.0176820
5 4.5810000 -0.0489020
6 1.5800000 -0.0960090
7 0.5640000 -0.1363800
8 0.0734500 0.5751020
S 1
1 0.0280500 1.0000000
P 3
1 1.5340000 0.0227840
2 0.2749000 0.1391070
3 0.0736200 0.5003750
P 1
1 0.0240300 1.0000000
D 1
1 0.1239000 1.0000000
2 3
S 3 S 3
1 13.0100000 0.0196850 1 33.8700000 0.0060680
2 1.9620000 0.1379770 2 5.0950000 0.0453080
3 0.4446000 0.4781480 3 1.1590000 0.2028220
S 1 S 1
1 0.1220000 1.0000000 1 0.3258000 1.0000000
S 1
1 0.1027000 1.0000000
P 1 P 1
1 0.7270000 1.0000000 1 1.4070000 1.0000000
P 1
1 0.3880000 1.0000000
D 1
1 1.0570000 1.0000000
2 6
S 3
1 33.8700000 0.0060680
2 5.0950000 0.0453080
3 1.1590000 0.2028220
S 1
1 0.3258000 1.0000000
S 1
1 0.1027000 1.0000000
P 1
1 1.4070000 1.0000000
P 1
1 0.3880000 1.0000000
D 1
1 1.0570000 1.0000000

View File

@ -24,7 +24,6 @@ subroutine build_grid(nNuc,ZNuc,rNuc,nShell,TotAngMomShell,ExpShell,max_ang_mom,
double precision,intent(in) :: max_exponent(nNuc) double precision,intent(in) :: max_exponent(nNuc)
double precision,intent(in) :: radial_precision double precision,intent(in) :: radial_precision
integer,intent(in) :: nRad
integer,intent(in) :: nAng integer,intent(in) :: nAng
integer,intent(in) :: nGrid integer,intent(in) :: nGrid
@ -37,12 +36,14 @@ subroutine build_grid(nNuc,ZNuc,rNuc,nShell,TotAngMomShell,ExpShell,max_ang_mom,
integer :: min_num_angular_points integer :: min_num_angular_points
integer :: max_num_angular_points integer :: max_num_angular_points
integer :: num_points integer :: num_points
integer :: num_radial_points
integer :: center_index integer :: center_index
type(c_ptr) :: context type(c_ptr) :: context
! Output variables ! Output variables
integer,intent(out) :: nRad
double precision,intent(out) :: root(ncart,nGrid) double precision,intent(out) :: root(ncart,nGrid)
double precision,intent(out) :: weight(nGrid) double precision,intent(out) :: weight(nGrid)
@ -56,6 +57,7 @@ subroutine build_grid(nNuc,ZNuc,rNuc,nShell,TotAngMomShell,ExpShell,max_ang_mom,
!------------------------------------------------------------------------ !------------------------------------------------------------------------
iG = 0 iG = 0
nRad = 0
do iNuc=1,nNuc do iNuc=1,nNuc
@ -65,12 +67,15 @@ subroutine build_grid(nNuc,ZNuc,rNuc,nShell,TotAngMomShell,ExpShell,max_ang_mom,
center_index = iNuc - 1 center_index = iNuc - 1
num_points = numgrid_get_num_grid_points(context) num_points = numgrid_get_num_grid_points(context)
num_radial_points = numgrid_get_num_radial_grid_points(context)
call numgrid_get_grid(context,nNuc,center_index,rNuc(:,1),rNuc(:,2),rNuc(:,3),int(ZNuc(:)), & call numgrid_get_grid(context,nNuc,center_index,rNuc(:,1),rNuc(:,2),rNuc(:,3),int(ZNuc(:)), &
root(1,iG+1:iG+num_points),root(2,iG+1:iG+num_points),root(3,iG+1:iG+num_points), & root(1,iG+1:iG+num_points),root(2,iG+1:iG+num_points),root(3,iG+1:iG+num_points), &
weight(iG+1:iG+num_points)) weight(iG+1:iG+num_points))
iG = iG + num_points iG = iG + num_points
nRad = nRad + num_radial_points
call numgrid_free_atom_grid(context) call numgrid_free_atom_grid(context)
@ -82,11 +87,19 @@ subroutine build_grid(nNuc,ZNuc,rNuc,nShell,TotAngMomShell,ExpShell,max_ang_mom,
! Print grid ! Print grid
write(*,*)
write(*,'(A30,E10.1)') 'Radial precision = ',radial_precision
write(*,'(A30,I10)') 'Number of radial points = ',nRad
write(*,'(A30,I10)') 'Number of angular points = ',nAng
write(*,'(A30,I10)') 'Total number of points = ',nGrid
write(*,*)
if(dump_grid) then if(dump_grid) then
write(*,*) ' ***********************' write(*,*) ' ***********************'
write(*,*) ' *** QUADRATURE GRID ***' write(*,*) ' *** QUADRATURE GRID ***'
write(*,*) ' ***********************' write(*,*) ' ***********************'
write(*,'(A10,3X,3A15)') 'Grid point','X','Y','Z' write(*,'(A10,3X,3A15)') 'Grid point','X','Y','Z'
do iG=1,nGrid do iG=1,nGrid
write(*,'(I10,3X,4F15.10)') iG,weight(iG),root(:,iG) write(*,'(I10,3X,4F15.10)') iG,weight(iG),root(:,iG)