Skip to content

Commit

Permalink
Merge with cuda stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
pecchia committed Mar 9, 2024
2 parents ab4b5be + eb5ea1c commit 30df87a
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 15 deletions.
1 change: 1 addition & 0 deletions config.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ option(WITH_ELSI "Whether DFTB+ with MPI-parallelism should use the ELSI librari
# enabled (and must have been built with GPU support).

option(WITH_TRANSPORT "Whether transport via libNEGF should be included." FALSE)
option(WITH_TRANSPORT_GPU "Whether libNEGF should enable GPU." FALSE)
# Works only when building static libraries (see option BUILD_SHARED_LIBS)

option(WITH_POISSON "Whether the Poisson-solver should be included" ${WITH_TRANSPORT})
Expand Down
2 changes: 0 additions & 2 deletions src/dftbp/dftbplus/initprogram.F90
Original file line number Diff line number Diff line change
Expand Up @@ -4502,8 +4502,6 @@ subroutine initTransport_(env, input, electronicSolver, nSpin, tempElec, tNegf,
end associate

if (tNegf) then
write(stdOut,*) 'init negf'

! Some checks and initialization of GDFTB/NEGF
call TNegfInt_init(negfInt, input%transpar, env, input%ginfo%greendens,&
& input%ginfo%tundos, tempElec, kPoint, kWeight, localKS)
Expand Down
21 changes: 9 additions & 12 deletions src/dftbp/transport/negfint.F90
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ subroutine TNegfInt_init(this, transpar, env, greendens, tundos, tempElec, kPoin
params%FictCont(i) = transpar%contacts(i)%wideBand
params%contact_DOS(i) = transpar%contacts(i)%wideBandDOS

write(stdOut,"(1X,A,I0,A)") '(negf_init) CONTACT INFO #', i,&
write(stdOut,"(1X,A,I0,A)") 'CONTACT INFO #', i,&
& ' "'//trim(transpar%contacts(i)%name)//'"'

if (params%FictCont(i)) then
Expand All @@ -241,20 +241,17 @@ subroutine TNegfInt_init(this, transpar, env, greendens, tundos, tempElec, kPoin
end if
write(stdOut,*) 'Temperature (DM): ', params%kbT_dm(i)
write(stdOut,*) 'Temperature (Current): ', params%kbT_t(i)
if (transpar%contacts(i)%tFermiSet) then
write(stdOut,format2U)'Potential (with built-in)', pot(i), 'H', Hartree__eV*pot(i), 'eV'
write(stdOut,format2U)'eFermi', eFermi(i), 'H', Hartree__eV*eFermi(i), 'eV'
end if
write(stdOut,*)

! Define electrochemical potentials
params%mu(i) = eFermi(i) - pot(i)

if (transpar%contacts(i)%tFermiSet) then
write(stdOut,format2U)'Potential (with built-in)', pot(i), 'H', Hartree__eV*pot(i), 'eV'
write(stdOut,format2U)'eFermi', eFermi(i), 'H', Hartree__eV*eFermi(i), 'eV'
write(stdOut,format2U)'Electro-chemical potentials', params%mu(i), 'H',&
& Hartree__eV*params%mu(i), 'eV'
write(stdOut,*)
end if

write(stdOut,*)

enddo

Expand Down Expand Up @@ -770,10 +767,10 @@ subroutine setup_str(this, denseDescr, transpar, greendens, coords, latVec, &

end if

write(stdOut,*) ' Structure info:'
write(stdOut,*) ' Number of PLs:',nbl
write(stdOut,*) ' PLs coupled to contacts:',cblk(1:ncont)
write(stdOut,*)
!write(stdOut,*) ' Structure info:'
!write(stdOut,*) ' Number of PLs:',nbl
!write(stdOut,*) ' PLs coupled to contacts:',cblk(1:ncont)
!write(stdOut,*)

end if

Expand Down
2 changes: 1 addition & 1 deletion test/app/dftb+/transport/local-curr/dftb_in.hsd
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ Transport{

Hamiltonian = DFTB {
SCC = Yes
MaxSCCIterations = 100
MaxSCCIterations = 1
SCCTolerance = 1e-6
ReadInitialCharges = Yes

Expand Down

0 comments on commit 30df87a

Please sign in to comment.