Commit Graph

24 Commits

Author SHA1 Message Date
giannozz a2fdf32348 More removal of unused variables, or of annoying compiler messages, by SP
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@12307 c92efa57-630b-4861-b058-cf58834340f0
2016-04-14 13:04:19 +00:00
giannozz 3c5e774079 Misc changes for NAG compiler, by Samuel, plus make.depend update
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@12286 c92efa57-630b-4861-b058-cf58834340f0
2016-04-06 16:41:55 +00:00
giannozz b5db8d6d76 Standard F2003 calls to: get_environment_variable, get_command_argument,
command_argument_count, flush, are used everywhere instead of wrappers.
Some old versions of compilers may no longer work.


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@11759 c92efa57-630b-4861-b058-cf58834340f0
2015-09-24 10:24:03 +00:00
ccavazzoni 34781504de - more implicit world communicator clean-up
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@10511 c92efa57-630b-4861-b058-cf58834340f0
2013-10-06 19:09:46 +00:00
giannozz 309c53412a Cleanup
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@7991 c92efa57-630b-4861-b058-cf58834340f0
2011-07-19 13:47:16 +00:00
giannozz 23ffbbed84 Fixed compilation problem after yesterday commmits, removed some unused
variables


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@6986 c92efa57-630b-4861-b058-cf58834340f0
2010-08-18 07:06:04 +00:00
ccavazzoni 148576a7c6 - a syntax error in a write statement was causing ibm compiler to stop
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@6247 c92efa57-630b-4861-b058-cf58834340f0
2009-12-12 17:18:59 +00:00
aschauer a2ced1810c Bug fixes and output cleanup for cp.x autopilot
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@6237 c92efa57-630b-4861-b058-cf58834340f0
2009-12-09 15:41:54 +00:00
dalcorso 56956b5622 Small cleanup.
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@5475 c92efa57-630b-4861-b058-cf58834340f0
2009-03-17 10:30:32 +00:00
giannozz e3cc136770 Spelling errors
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@5383 c92efa57-630b-4861-b058-cf58834340f0
2009-02-04 20:54:44 +00:00
paulatto 08fedbe2f0 SCF with Projector-Augmented Wave Pseudopotential (PAW) routines added.
This means that a lot of routines have been modified and a few files have
been added. During the year several people have contributed to this code,
mainly Guido Fratesi, Ricardo Mazzarello, Stefano de Gironcoli, Andrea Dal
Corso and me (Lorenzo Paulatto).

A brief report of modified or added files follows, further down you will
find a loger report of modifications that was necessary to merge develop_PAW
branch with the current CVS version.

Current version is not 100% functional, but it doesn't brake anything else and
can be used to generate and test PAW pseudopotential.

      *************************************
      *** Brief report of modifications ***
      *************************************
Modified files:
PW/clean_pw.f90
PW/electrons.f90
PW/print_clock_pw.f90
PW/hinit0.f90
PW/potinit.f90
PW/newd.f90
PW/summary.f90
PW/setup.f90
PW/read_pseudo.f90
PW/init_us_1.f90
PW/init_run.f90
PW/mix_rho.f90
atomic/atomic_paw.f90
atomic/write_paw_recon.f90
atomic/ld1_writeout.f90
atomic/write_resultsps.f90
atomic/ld1inc.f90
atomic/ld1_readin.f90
atomic/gener_pseudo.f90
atomic/parameters.f900
atomic/run_pseudo.f900
atomic/set_rho_core.f90
atomic/pseudovloc.f90
Modules/read_upf.f90
Modules/uspp.f90
Modules/pseudo_types.f90
Modules/parameters.f90

Added files:
PW/grid_paw_routines.f90
PW/rad_paw_routines.f90
Modules/grid_paw_variables.f90
Modules/read_paw.f90

Added files that will be removed:
PW/rad_paw_trash.f90
PW/paw_xc.f90

Examples:
examples/PAWexample contains a full test of PAW pseudopotential
for Oxygen. The test consist in these tasks:
 - 2 norm conserving, 2 US and 4 PAW pseudopotentials are
   generated and tested in ld1
 - pw test for an isolated O atom at different cutoffs
 - pw test for an O2 molecule at different O-O distance
please read examples/PAWexample/README for (a few) details.

NOTES:
1. new modifications to atomic_paw (and related) from ADC have been rolled
   back, as they were breaking a lot of things, I will reintroduce them
   later when I am sure that everything works properly.
2. the files PW/paw_xc.f90 and Modules/rad_paw_trash.f90 will be removed in
   the next few weeks.

TODO:
1. use new ld1 XC code as much as possible, and remove legacy XC routines
   from rad_paw_routines
2. full self-consistency with radial energies
3. make new Harris-Foulkes estimate paw-aware
4. provide some kind error estimate
5. FORCES and stress!! (require symmetrization of becsums)
6. cleanup

    ************************
    *** merge of PW code ***
    ************************
Versions notation:
OLD=version from 2 years ago used as reference to generate the patches
NEW=CURRENT=current trunk version
PAW=current develop_PAW version

Note: pseudo-potential input and allocation routines changed
      a lot in the last years, this is a diagram:
OLD:PW/readin ~~> PAW:PW/read_pseudo --> disappears
pops out --> PAW:PW/readin ~~> NEW:PW/read_pseudo

added files:
Modules/read_paw.f90    (contains module read_paw_module with subroutines
                         paw_io nullify_pseudo_paw, allocate_pseudo_paw and
                         deallocate_pseudo_paw previously in removed file
                         Modules/readpseudo.f90. Also contains module
                         paw_to_internal with subroutine set_pseudo_paw,
                         previously in upf_to_internal.f90)
PW/paw_xc.f90           (contains OLD=PAW xc and gcxc routines as adapting paw
                         grid code to use new routines was very error prone and
                         quite worthless, as it has to be removed anyway)

Conflicts reported by CVS during merge:
DONE */Makefiles                    (all replaced with new, redone by hand)

DONE  flib/functionals.f90          (nothing to do)

DONE Modules/functionals.f90        (RNV == replaced with NEW version)
DONE Modules/atom.f90               (trivial: duped rgrid)
DONE Modules/autopilot.f90          (trivial)
DONE Modules/bfgs_module.f90        (RNV)
DONE Modules/cell_base.f90          (RNV)
DONE Modules/check_stop.f90         (RNV)
DONE Modules/constants.f90          (RNV)
DONE Modules/constraints_module.f90 (RNV)
DONE Modules/energies.f90           (RNV)
DONE Modules/input_parameters.f90   (RNV)
DONE Modules/ions_base.f90          (RNV, has 3 new subs)
DONE Modules/ions_nose.f90          (RNV)
DONE Modules/parameters.f90         (actually RNV)
DONE Modules/path_base.f90          (RNV)
DONE Modules/path_opt_routines.f90  (RNV)
DONE Modules/path_reparametrisation.f90 (RNV)
DONE Modules/path_variables.f90     (RNV)
DONE Modules/pseudo_types.f90       (cleaned double def of paw_t)
DONE Modules/read_cards.f90         (RNV)
DONE Modules/read_namelists.f90     (checked and RNV)
DONE Modules/uspp.f90               (trivial)
DONE Modules/xml_io_base.f90        (RNV)

DONE PW/read_pseudo.f90             (merged by hand with PAW PW/readin)

DONE PW/bp_calc_btq.f90             (trivial)
DONE PW/c_bands.f90                 (actually RNV)
DONE PW/ccgdiagg.f90                (RNV)
DONE PW/cegterg.f90                 (RNV)
DONE PW/cft3s.f90                   (RNV)
DONE PW/cinitcgg.f90                (RNV)
DONE PW/c_phase_field.f90           (RNV)
DONE PW/divide_et_impera.f90        (nothing to do?)
DONE PW/exx.f90                     (RNV)
DONE PW/hinit0.f90                  (easy)
DONE PW/h_psi.f90                   (RNV)
DONE PW/init_run.f90                (easy)
DONE PW/kpoint_grid.f90             (nothing to do?)
DONE PW/newd.f90                    (required mod in newd_paw_grid, CHECK!!)
DONE PW/openfil.f90                 (actually RNV)
DONE PW/paw.f90                     (actually RNV)
DONE PW/punch.f90                   (RNV)
DONE PW/pwscf.f90                   (quite RNV)
DONE PW/set_kup_and_kdw.f90         (RNV)
DONE PW/setup.f90                   (RNV + 2 line merged by hand)
DONE PW/sgama.f9                    (actually RNV)
DONE PW/sgam_at_mag.f90             (actually RNV)
DONE PW/stop_run.f90                (actually RNV)
DONE PW/stres_gradcorr.f90          (actually RNV)
DONE PW/symrho_mag.f90              (nothing to do)
DONE PW/v_of_rho.f90                (RNV)

DONE PW/compute_fes_grads.f90       (RNV)
DONE PW/gradcorr.f90                (RNV)
DONE PW/input.f90                   (RNV)
DONE PW/pw_restart.f90              (RNV)
DONE PW/read_ncpp.f90               (actually RNV)
DONE PW/summary.f90                 (RNV + inserted new PP type)
DONE PW/wfcinit.f90                 (RNV)

the hard ones:
DONE PW/electrons.f90   (adapted code to new syntaxes, a lot of cleanup, removed
                         some PAW junk that can be readded later, removed parts
                         that were applyed twice, or had been removed in trunk,
                         the rhog allocations and usage may need fixes)
DONE PW/mix_rho.f90     (merged tauk and paw additions, a bit of cleanup and smarter
                         variables names)
DONE PW/init_us_1.f90   (qtot redefined with "triangular" index nb,mb-->ijv)

modified for compiling:
Modules/io_files.f90    (depatched)
PW/pwcom.f90            (depatched)
Modules/parameters.f90  (temporary readded cp_lmax = lmaxx+1)
PW/newd.f90             (merge was wrong, redone mostly by hand)
PW/read_ncpp.f90        (depatched)
PW/read_pseudo          (small fixes)
PW/sgam_at_mag.f90      (depatched)
PW/sgama.f90            (depatched)
PW/stres_gradcorr.f90   (depatched)

modified for running:
PW/clean_pw.f90         (added call to deallocate_paw_internals)

Modifications to PAW routines:
1. compute_onecenter_charges and compute_onecenter_charges modified to
   comply with new structure of v_xc (in v_of_rho.f90), requiring new
   g-space densities to be saved and computed --> using old xc routines
   as this code will be removed.
2. qrad size has changed, prad and ptrad had to be changed accordingly.
3. several minor modifications to use new radial grid structure.
4. infomsg arguments changed, very funny bug followed.
5. added new routine deallocate_paw_internals, called by PW/clean_pw.f90
   required to run pp.x with more than one q-point(and good programming
   practice)


    *************************
    *** merge of LD1 code ***
    *************************
2nd try: atomic code replaced with current version, then merge by hand
the files that are used by paw subsystem:
* atomic_paw.f90        (replaced with most recent version from develop_PAW
                         routine us2paw and paw2us taken from newer trunk
                         version, a lot of minor changes.)
* gener_pseudo.f90      (fixes)
* ld1inc.f90            (PAW variables added)
* ld1_readin.f90        (PAW variables added, I am not sure if lpaw should go
                         in input or inputp namelist)
* ld1_writeout.f90      (it was only necessary to add a few lines)
* pseudovloc.f90        (nothing to do)
* run_pseudo.f90        (almost nothing to do)
* set_rho_core.f90      (readded a few lines for lnc2paw)
* write_paw_recon.f90   (nothing to do)
* write_resultsps.f90   (nothing to do: trunk version is more
                         PAW-aware than PAW version)

Main problems were found in subroutines run_pseudo and gen_pseudo,
a little code had to be rewritten to comply with new variable names
and fix with merge.

TODO: fix atomic_paw routines to use minimal allocated arrays insetad
of ndmx sized ones; try to use the pawet as much as possible. Remove
test lines and other garbage. Find a fix for PAW2.

The first week of september Andrea Dal Corso uploaded a few modifications to
the atomic_paw routines. I had to rollback them as the structure of atomic_paw
has changed a lot and reimplementing them is probably easier and definitely
safer than fixing everything. I will do it soon, I swear!

LP


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@4257 c92efa57-630b-4861-b058-cf58834340f0
2007-09-18 10:05:46 +00:00
giannozz 45ae58d60b All occurrences of d0, d+N, d-N, replaced with fortran-90 style _DP.
Please do not re-introduce old-style syntax. A uniform syntax allows
if the need arises to change the precision in less than no time.
Courtesy of Pascal Thibeaudeau. Modules/ directory only.


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@3964 c92efa57-630b-4861-b058-cf58834340f0
2007-06-11 17:13:15 +00:00
giannozz 3a98e2d9d4 More patches from Axel:
- correct an unquoted string (iosys) in PW/input.f90:483
(this was the cause of tonight compilation failere)
- correct a few incorrect format strings
- make more use of the constants module and thus
  provide more consistent units. NOTE, this has some
  numerical changes in the outputs, as in some places
  rather low precision and inconsistent numbers were
  used for unit conversion.
- convert all(?) single precision constants to double
  using the attached little perl program.
  exceptions: efermi.f90 (as it is supposed to be rewritten
  anyways), plotbands.f90 (it uses single precision everywhere,
  which may result in saving a significant amount of memory,
  so i converted the two double precision constants to single).
Unused routine 'set_fft_grid' removed


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@3602 c92efa57-630b-4861-b058-cf58834340f0
2006-12-14 08:53:47 +00:00
giannozz 19aaac89fa More miscellanous cleanup from Axel:
- disable locales via use of LC_ALL=C in all shell scripts
   (which will hopefully make sorted lists more consistent
    between people running with different locales).
 - remove redundant files from PW, NMR_new, VdW, VIB;
   rename subroutines if their functionality is noI
   unchanged from the original source it was taken from.
 - corresponding updates to Makefiles and dependencies.
 - whitespace cleanups (eleminate remaining tabs).
 - a few more float->DBLE


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@3596 c92efa57-630b-4861-b058-cf58834340f0
2006-12-12 11:02:09 +00:00
giannozz dc6d1c35e6 Removed multiple prints in parallel execution (Giovanni Cantele)
Removed unused variables (Axel)


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@3573 c92efa57-630b-4861-b058-cf58834340f0
2006-11-27 14:42:47 +00:00
giannozz 44c8bc4b7f Autopilot patch from Yonas Abraham
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@3445 c92efa57-630b-4861-b058-cf58834340f0
2006-10-09 17:07:23 +00:00
cavazzon a31b50db3e - confusing scradir substituted everywhere with outdir,
that for CP now indicates the directory containing
   all outputs


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@3326 c92efa57-630b-4861-b058-cf58834340f0
2006-08-12 12:27:56 +00:00
kkudin a914e9ea61 Added a new thermostat type (nhptyp=3) with a control array 'nhgrp',
allowing fine control over how thermostats are assigned to atoms
 Kostya


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@3226 c92efa57-630b-4861-b058-cf58834340f0
2006-06-29 22:43:58 +00:00
giannozz 72c3d2d060 Bug fix: electron_damping read but not used (courtesy of G. Cantele)
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@3082 c92efa57-630b-4861-b058-cf58834340f0
2006-05-05 09:39:55 +00:00
giannozz 8eda231bbb - Variable cell: use Cesar Da Silva's version of the damping algorithm
(he claims it is more tested); documentation updated (sort of)
- routines find_free_unit, delete_if_present, moved from 'parser'
  to 'io_files' (it is a more natural place)
- routines int_to_char moved from 'parser' to flib/ (it is quite
  unrelated with the rest of the module)
- routine trimcheck moved from flib/ to 'io_files' (more natural place)


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@2753 c92efa57-630b-4861-b058-cf58834340f0
2006-02-01 17:56:16 +00:00
giannozz 4834884e77 uninitialised variable nrules replaced by n_rules
: ----------------------------------------------------------------------


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@2500 c92efa57-630b-4861-b058-cf58834340f0
2005-11-22 08:05:17 +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
cavazzon 5d41c109c5 - autopilot.f90 wasn't compiling on IBM AIX machines
- compiler complains for espression like: logical_var == .FALSE.
  this is not standard f90, use: .NOT. logical_var
  instead
- subroutine "flush" is not a standard intrinsic f90 sub.
  use our "flush_unit" wrapper


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@2129 c92efa57-630b-4861-b058-cf58834340f0
2005-08-25 13:01:04 +00:00
targacept 9f487bd7ad Adding Autopilot Feature Suite
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@2122 c92efa57-630b-4861-b058-cf58834340f0
2005-08-24 14:23:09 +00:00