Commit Graph

13 Commits

Author SHA1 Message Date
degironc c209f8233b Modules/functionals.f90 modified.
The idea is that module funct contains data defining the DFT functional in use
and a number of functions and subroutines to manage them.
Data are PRIVATE and are (shuold be) accessed and set only by function calls.
Basic drivers to compute XC quantities are also included.

It should be the main place where definitions for and calculation of xc
functionals are centralized.

In CPV printout [A.U.] replaced by [HARTREE A.U.] in many places.

stefano


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@2411 c92efa57-630b-4861-b058-cf58834340f0
2005-11-02 15:42:06 +00:00
giannozz f533b052d5 dbl => DP (defined as previously dbl was)
syntax for declarations: real(DP), without "kind="


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@2135 c92efa57-630b-4861-b058-cf58834340f0
2005-08-28 14:09:42 +00:00
giannozz bf4bfe222f General cleanup of intrinsic functions:
conversion to real    => DBLE
(including real part of a complex number)
conversion to complex => CMPLX
complex conjugate     => CONJG
imaginary part        => AIMAG

All functions are uppercase.
CMPLX is preprocessed by f_defs.h and performs an explicit cast:
#define CMPLX(a,b)  cmplx(a,b,kind=DP)
This implies that 1) f_defs.h must be included whenever a CMPLX is present,
2) CMPLX should stay in a single line, 3) DP must be defined.

All occurrences of real, float, dreal, dfloat, dconjg, dimag, dcmplx
removed - please do not reintroduce any of them.
Tested only with ifc7 and g95 - beware unintended side effects

Maybe not the best solution (explicit casts everywhere would be better)
but it can be easily changed with a script if the need arises.
The following code might be used to test for possible trouble:

program test_intrinsic

  implicit none
  integer, parameter :: dp = selected_real_kind(14,200)
  real (kind=dp) :: a = 0.123456789012345_dp
  real (kind=dp) :: b = 0.987654321098765_dp
  complex (kind=dp) :: c = ( 0.123456789012345_dp, 0.987654321098765_dp)

  print *, '      A = ', a
  print *, ' DBLE(A)= ', DBLE(a)
  print *, '      C = ', c
  print *, 'CONJG(C)= ', CONJG(c)
  print *, 'DBLE(c),AIMAG(C)  = ', DBLE(c), AIMAG(c)
  print *, 'CMPLX(A,B,kind=dp)= ', CMPLX( a, b, kind=dp)

end program test_intrinsic

Note that CMPLX and REAL without a cast yield single precision numbers on
ifc7 and g95 !!!


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@2133 c92efa57-630b-4861-b058-cf58834340f0
2005-08-26 17:44:42 +00:00
giannozz b7d3d29b11 Added missing copyright notice
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@1733 c92efa57-630b-4861-b058-cf58834340f0
2005-03-21 14:33:57 +00:00
giannozz f109832e50 rab = dr/dx is now a global variable, always calculated
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@1649 c92efa57-630b-4861-b058-cf58834340f0
2005-02-17 14:27:59 +00:00
dalcorso 596c14b256 The core radii are written in the pseudopotential file and used by the
atomic code to improve the estimate of the starting charge in a
pseudo-test calculation.


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@1643 c92efa57-630b-4861-b058-cf58834340f0
2005-02-12 17:08:42 +00:00
giannozz 1eab3d7b77 Minor cleanup
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@1621 c92efa57-630b-4861-b058-cf58834340f0
2005-02-08 13:22:11 +00:00
giannozz c0dc0fc3a2 Bad default for relativistic/nonrelativistic atomic calculation
Misc documentation updates


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@1613 c92efa57-630b-4861-b058-cf58834340f0
2005-02-03 09:07:42 +00:00
giannozz 601ee35891 Fixed minor inconsistencies in reading NC-PP and in writing UPF
Removed some debugging messages  of questionable usefulness


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@1607 c92efa57-630b-4861-b058-cf58834340f0
2005-02-01 13:01:37 +00:00
giannozz 140b30e033 More PP copde cleanup - almost all functionalities restored
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@1585 c92efa57-630b-4861-b058-cf58834340f0
2005-01-28 14:30:50 +00:00
giannozz 1eab19081e UPF output for single-projector MT PP should work now
dftname => dft_name (conflict with dftname in flib/more_functionals.f90)


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@1538 c92efa57-630b-4861-b058-cf58834340f0
2005-01-05 16:33:42 +00:00
giannozz 29aaac751d Cleanup of the atomic code by Pascal Thibaudeau - mostly cosmetic
but some calls to lapack could lead to problems for some compilers


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@1504 c92efa57-630b-4861-b058-cf58834340f0
2004-12-10 15:33:00 +00:00
giannozz 0c5845465a PP generation code added in atomic/ - still some cleanup to do
Please do not work any longer on the old branches!!!


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@889 c92efa57-630b-4861-b058-cf58834340f0
2004-05-14 15:33:08 +00:00