Commit Graph

14 Commits

Author SHA1 Message Date
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
degironc ac7906dc29 - makefile update after yesterday changes
- variable "ishybrid" added to Modules/funct.f90 to manage hybrid functionals
- duplicated subroutines in upftools/nclib.f90 removed


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@2095 c92efa57-630b-4861-b058-cf58834340f0
2005-08-09 07:34:23 +00:00
giannozz b001e60d82 Possible out-of-bound error in ncpp2upf (found by Axel Kohlmeyer)
Updated Makefile with better dependencies (also by AK)


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@2086 c92efa57-630b-4861-b058-cf58834340f0
2005-08-03 16:55:41 +00:00
giannozz b30d8d2ab8 Filenames from command line read in a single routine (get_file
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@1975 c92efa57-630b-4861-b058-cf58834340f0
2005-06-22 10:16:54 +00:00
giannozz f16aa6f635 Small patch from Axel: try to guess the wavefunction label
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@1855 c92efa57-630b-4861-b058-cf58834340f0
2005-05-11 15:30:16 +00:00
giannozz 1648ab6bf2 Patches from Axel Kohlmayer:
- iotk_scan in iotk_module had a mixed up 'intent' statement.
- sun ultra fire 3 compiler warnings
- cleanup in filename length (brought to 256)
- cleanup in include files


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@1399 c92efa57-630b-4861-b058-cf58834340f0
2004-10-26 09:32:48 +00:00
cavazzon 18191b514c - applied patch from axel kohlmeyer
carlo


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@1381 c92efa57-630b-4861-b058-cf58834340f0
2004-10-14 16:04:56 +00:00
sbraccia 0caeadbd7b Machine-dependent definitions are now contained in two different files (both in /include):
1) f_defs.h  for definitions to be included in FORTRAN files ONLY
   2) c_defs.h  for definitions to be included in C       files ONLY

C.S.


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@1012 c92efa57-630b-4861-b058-cf58834340f0
2004-06-25 17:25:37 +00:00
giannozz b4da6fadb8 Various T3E compilation problems
Any kind soul replacing the calls to zgefa and zgesl with lapack calls?


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@997 c92efa57-630b-4861-b058-cf58834340f0
2004-06-25 10:12:10 +00:00
giannozz 3a086b820c Installation cleanup; fftw are compiled by default
All Makefiles updated for addition of Berry phase code
iargc, getenv, getarg preprocessed
Missing Blas/Lapack sources for pw added


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@228 c92efa57-630b-4861-b058-cf58834340f0
2003-06-12 07:43:14 +00:00
giannozz 5542a00340 Misc. installation and doc fixes
T3D, T3E, __CRAY => __T3E  ; PC => __LINUX


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@99 c92efa57-630b-4861-b058-cf58834340f0
2003-02-27 13:59:04 +00:00
giannozz 9e3a2de758 Support for lahey compiler added: "error" renamed to "errore", "rnd" to "rndx"
bug in io_base fixed
PARA => __PARA
cinterpolate moved into interpolate


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@86 c92efa57-630b-4861-b058-cf58834340f0
2003-02-21 14:57:00 +00:00
giannozz ac9f2144c0 O-sesame
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@2 c92efa57-630b-4861-b058-cf58834340f0
2003-01-19 21:58:50 +00:00