Commit ba4d8193 authored by Matthias Redies's avatar Matthias Redies

remove kinED debugging output

parent 6aaaf2f8
......@@ -103,132 +103,5 @@ CONTAINS
CALL mpi_bc_potden(mpi,stars,sphhar,atoms,input,vacuum,oneD,noco,vCoul)
CALL mpi_bc_potden(mpi,stars,sphhar,atoms,input,vacuum,oneD,noco,vx)
#endif
call integrate_lapl(xcpot, stars, atoms, sym, vacuum, input, cell, oneD, sphhar,noco)
call integrate_kED_schr(xcpot, stars, atoms, sym, vacuum, input, cell, oneD, sphhar,noco)
call integrate_kED_libxc(xcpot, stars, atoms, sym, vacuum, input, cell, oneD, sphhar,noco)
END SUBROUTINE vgen
SUBROUTINE integrate_lapl(xcpot, stars, atoms, sym, vacuum, input, cell, oneD, sphhar,noco)
use m_cdntot
use m_types
implicit none
CLASS(t_xcpot),INTENT(IN) :: xcpot
TYPE(t_stars),INTENT(IN) :: stars
TYPE(t_atoms),INTENT(IN) :: atoms
TYPE(t_sym),INTENT(IN) :: sym
TYPE(t_vacuum),INTENT(IN) :: vacuum
TYPE(t_input),INTENT(IN) :: input
TYPE(t_cell),INTENT(IN) :: cell
TYPE(t_oneD),INTENT(IN) :: oneD
TYPE(t_sphhar), INTENT(IN):: sphhar
TYPE(t_noco), INTENT(INOUT) :: noco
REAL :: q(input%jspins), qis(input%jspins), qmt(atoms%ntype,input%jspins),&
qvac(2,input%jspins), qtot, qistot
if(allocated(xcpot%is_lapl%grid)) then
call integrate_grid(xcpot, stars, atoms, sym, vacuum, input, cell, oneD, sphhar,noco,&
xcpot%is_lapl, xcpot%mt_lapl, &
q, qis, qmt, qvac, qtot, qistot)
call print_qs(q,qis,qmt,qvac,qtot,qistot,"laplace")
endif
END SUBROUTINE integrate_lapl
SUBROUTINE integrate_kED_schr(xcpot, stars, atoms, sym, vacuum, input, cell, oneD, sphhar,noco)
use m_cdntot
use m_types
implicit none
CLASS(t_xcpot),INTENT(IN) :: xcpot
TYPE(t_stars),INTENT(IN) :: stars
TYPE(t_atoms),INTENT(IN) :: atoms
TYPE(t_sym),INTENT(IN) :: sym
TYPE(t_vacuum),INTENT(IN) :: vacuum
TYPE(t_input),INTENT(IN) :: input
TYPE(t_cell),INTENT(IN) :: cell
TYPE(t_oneD),INTENT(IN) :: oneD
TYPE(t_sphhar), INTENT(IN):: sphhar
TYPE(t_noco), INTENT(INOUT) :: noco
REAL :: q(input%jspins), qis(input%jspins), qmt(atoms%ntype,input%jspins),&
qvac(2,input%jspins), qtot, qistot
if(allocated(xcpot%is_kED_schr%grid) .and. allocated(xcpot%mt_kED_schr)) then
call integrate_grid(xcpot, stars, atoms, sym, vacuum, input, cell, oneD, sphhar,noco,&
xcpot%is_kED_schr, xcpot%mt_kED_schr, &
q, qis, qmt, qvac, qtot, qistot)
call print_qs(q,qis,qmt,qvac,qtot,qistot,"kED_schr")
endif
END SUBROUTINE integrate_kED_schr
SUBROUTINE integrate_kED_libxc(xcpot, stars, atoms, sym, vacuum, input, cell, oneD, sphhar,noco)
use m_cdntot
use m_types
use m_npy
use m_juDFT
implicit none
CLASS(t_xcpot),INTENT(IN) :: xcpot
TYPE(t_stars),INTENT(IN) :: stars
TYPE(t_atoms),INTENT(IN) :: atoms
TYPE(t_sym),INTENT(IN) :: sym
TYPE(t_vacuum),INTENT(IN) :: vacuum
TYPE(t_input),INTENT(IN) :: input
TYPE(t_cell),INTENT(IN) :: cell
TYPE(t_oneD),INTENT(IN) :: oneD
TYPE(t_sphhar), INTENT(IN):: sphhar
TYPE(t_noco), INTENT(INOUT) :: noco
REAL :: q(input%jspins), qis(input%jspins), qmt(atoms%ntype,input%jspins),&
qvac(2,input%jspins), qtot, qistot
TYPE(t_grid) :: is_kED_libxc
TYPE(t_grid), allocatable :: mt_kED_libxc(:)
INTEGER :: i
if(allocated(xcpot%is_kED_schr%grid) .and. allocated(xcpot%mt_kED_schr)) then
allocate(mt_kED_libxc(size(xcpot%mt_kED_schr)))
is_kED_libXC%grid = xcpot%is_kED_schr%grid + 0.25 * xcpot%is_lapl%grid
call save_npy("pw_kED_libXC.npy", is_kED_libXC%grid)
do i = 1,atoms%ntype
mt_kED_libXC(i)%grid = xcpot%mt_kED_schr(i)%grid + 0.25 * xcpot%mt_lapl(i)%grid
call save_npy("mt=" // int2str(i) // "_kED_libXC.npy", mt_kED_libXC(i)%grid)
enddo
call integrate_grid(xcpot, stars, atoms, sym, vacuum, input, cell, oneD, sphhar,noco,&
is_kED_libXC, mt_kED_libXC, &
q, qis, qmt, qvac, qtot, qistot)
call print_qs(q,qis,qmt,qvac,qtot,qistot,"kED_libxc")
endif
END SUBROUTINE integrate_kED_libxc
subroutine print_qs(q,qis,qmt,qvac,qtot,qistot, label)
implicit none
REAL, INTENT(in) :: q(:), qis(:), qmt(:,:), qvac(:,:), qtot, qistot
character(len=*), intent(in) :: label
write (*,*) "------------------------"
write (*,*) label // " integration:"
write (*,*) "q = "
write (*,'(ES17.10)') q
write (*,*) "qis = "
write (*,'(ES17.10)') qis
write (*,*) "qmt = "
write (*,'(ES17.10)') qmt
if(.not. all(isnan(qvac))) then
write (*,*) "qvac = "
write (*,'(ES17.10)') qvac
endif
write (*,*) "qtot = "
write (*,'(ES17.10)') qtot
write (*,*) "qistot = "
write (*,'(ES17.10)') qistot
write (*,*) "------------------------"
end subroutine print_qs
END MODULE m_vgen
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment