~ubuntu-branches/ubuntu/utopic/nwchem/utopic

« back to all changes in this revision

Viewing changes to src/tools/ga-5-1/global/examples/md_cluster/common.fh

  • Committer: Package Import Robot
  • Author(s): Michael Banck, Daniel Leidert, Andreas Tille, Michael Banck
  • Date: 2013-07-04 12:14:55 UTC
  • mfrom: (1.1.2)
  • Revision ID: package-import@ubuntu.com-20130704121455-5tvsx2qabor3nrui
Tags: 6.3-1
* New upstream release.
* Fixes anisotropic properties (Closes: #696361).
* New features include:
  + Multi-reference coupled cluster (MRCC) approaches
  + Hybrid DFT calculations with short-range HF 
  + New density-functionals including Minnesota (M08, M11) and HSE hybrid
    functionals
  + X-ray absorption spectroscopy (XAS) with TDDFT
  + Analytical gradients for the COSMO solvation model
  + Transition densities from TDDFT 
  + DFT+U and Electron-Transfer (ET) methods for plane wave calculations
  + Exploitation of space group symmetry in plane wave geometry optimizations
  + Local density of states (LDOS) collective variable added to Metadynamics
  + Various new XC functionals added for plane wave calculations, including
    hybrid and range-corrected ones
  + Electric field gradients with relativistic corrections 
  + Nudged Elastic Band optimization method
  + Updated basis sets and ECPs 

[ Daniel Leidert ]
* debian/watch: Fixed.

[ Andreas Tille ]
* debian/upstream: References

[ Michael Banck ]
* debian/upstream (Name): New field.
* debian/patches/02_makefile_flags.patch: Refreshed.
* debian/patches/06_statfs_kfreebsd.patch: Likewise.
* debian/patches/07_ga_target_force_linux.patch: Likewise.
* debian/patches/05_avoid_inline_assembler.patch: Removed, no longer needed.
* debian/patches/09_backported_6.1.1_fixes.patch: Likewise.
* debian/control (Build-Depends): Added gfortran-4.7 and gcc-4.7.
* debian/patches/10_force_gcc-4.7.patch: New patch, explicitly sets
  gfortran-4.7 and gcc-4.7, fixes test suite hang with gcc-4.8 (Closes:
  #701328, #713262).
* debian/testsuite: Added tests for COSMO analytical gradients and MRCC.
* debian/rules (MRCC_METHODS): New variable, required to enable MRCC methods.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
c
2
 
c                                   NOTICE
3
 
c
4
 
c   This software is being made available for internal testing and
5
 
c   evaluation purposes only. This software is a pre-release test version
6
 
c   which has not yet been authenticated and cleared for publication. Adherence
7
 
c   to this notice may be necessary for the author, Battelle Memorial
8
 
c   Institute, to successfully assert copyright in and commercialize this
9
 
c   software. This software is not intended for duplication or distribution
10
 
c   to third parties without the permission of the Manager of Software
11
 
c   Products at Pacific Northwest Laboratory, Richland, Washington,  99352.
12
 
c
13
 
      implicit none
14
 
#include "mafdecls.fh"
15
 
#include "global.fh"
16
 
#ifdef MPI
17
 
#   include "mpif.h"
18
 
#else
19
 
#   include "tcgmsg.fh"
20
 
#endif
21
 
      integer MAXNRG,MAXNB,MAXAT,MAXTIM
22
 
      integer NSTES,NSTDF
23
 
      integer MD_MAXPROC,MAXBINS
24
 
      parameter (MAXNRG=50, MAXNB=100)
25
 
      parameter (MAXAT = 40000)
26
 
      parameter (MAXTIM=50)
27
 
      parameter (NSTES=1000)
28
 
      parameter (MAXBINS = 2000)
29
 
      parameter (MD_MAXPROC=1024)
30
 
c
31
 
c   Arrays containing locally held atoms and their properties. atot is
32
 
c   the total number of atoms and antot is the number of locally held
33
 
c   atoms. aidx is an array containing the absolute atomic index of
34
 
c   each locally held atom. at is an array containing an index to the
35
 
c   atom type, and ra is an array containing the coordinates, velocities,
36
 
c   and forces of each locally held atom. The array ra contains
37
 
c        ra(i,j,1): periodic coordinates that all are within the
38
 
c                   simulation cell
39
 
c        ra(i,j,2): velocities
40
 
c        ra(i,j,3): accelerations
41
 
c        ra(i,j,4): forces (not including constraint forces)
42
 
c        ra(i,j,5): momentum
43
 
c        ra(i,j,6): absolute coordinates
44
 
c        ra(i,j,7): complete forces from previous timestep
45
 
c        ra(i,j,8): temporary storage to construct accelations with
46
 
c                   constraints
47
 
c
48
 
      common /syspar/ ra(MAXAT,3,8),mass(MAXAT),at(MAXAT),aidx(MAXAT),
49
 
     +                atot,antot
50
 
      double precision ra,mass
51
 
      integer at,aidx,atot,antot
52
 
c
53
 
c   Global array handles and utility arrays for moving data around
54
 
c
55
 
      common /ga_data/ g_size, gsize_lo(0:MD_MAXPROC), gsize_hi,
56
 
     +                 g_coords, gcoords_lo(2,0:MD_MAXPROC),
57
 
     +                 gcoords_hi(2),
58
 
     +                 g_frc, gfrc_lo(2,0:MD_MAXPROC), gfrc_hi(2),
59
 
     +                 g_acc, gacc_lo(2,0:MD_MAXPROC), gacc_hi(2),
60
 
     +                 g_index, gindex_lo(0:MD_MAXPROC), gindex_hi,
61
 
     +                 g_iat, giat_lo(2,0:MD_MAXPROC), giat_hi(2),
62
 
     +                 g_rvec, grvec_lo(0:MD_MAXPROC), grvec_hi
63
 
      integer g_size, gsize_lo, gsize_hi, g_coords,gcoords_lo,
64
 
     +        gcoords_hi, g_frc, gfrc_hi, gfrc_lo, g_acc, gacc_lo,
65
 
     +        gacc_hi, g_index, gindex_lo, gindex_hi, g_iat, giat_hi,
66
 
     +        giat_lo, g_rvec, grvec_lo, grvec_hi
67
 
      common /md_par/ tau,dftmp,dfprs,dftm,dfpm,rsc(20,4),
68
 
     +                tmprtr,prssr,tmass,pmass,tvol,tavg,tmstrt,
69
 
     +                nsc,nstep,istep,ilist,dflalg,isc(20,4),istart,
70
 
     +                istop,tmpflg,prsflg,ptflg,istat,itarg,itavg,
71
 
     +                ipmode,iseed,mbflg,cmflg
72
 
      double precision tau,dftmp,dfprs,dftm,dfpm,rsc,
73
 
     +                tmprtr,prssr,tmass,pmass,tvol,tavg
74
 
      integer tmstrt,nsc,nstep,istep,ilist,dflalg,isc
75
 
      integer istart,istop,istat,itarg
76
 
      integer itavg,ipmode,iseed
77
 
      logical tmpflg,prsflg,ptflg,mbflg,cmflg
78
 
      common /simpar/ xbox,ybox,zbox,xbox2,ybox2,zbox2,
79
 
     +                vol1,vol2,vol3,scal1,scal2,scal3,
80
 
     +                alen1(3),alen2(3),alen3(3)
81
 
      double precision xbox,ybox,zbox,xbox2,ybox2,zbox2,
82
 
     +       vol1,vol2,vol3,scal1,scal2,scal3,alen1,alen2,alen3
83
 
      common /nrgpar/ nrg(MAXNRG),anrg(MAXNRG),anrg2(MAXNRG),
84
 
     +                presf,presfx,presfy,presfz,esvr,esvd,esvoh,
85
 
     +                esva,asev(MAXAT),nrgcnt,nrg2ct
86
 
      double precision nrg,anrg,anrg2,presf,esvr,esvd,esvoh,esva,asev,
87
 
     +       presfx,presfy,presfz
88
 
      integer nrgcnt,nrg2ct
89
 
      common /apars/ amass(50),e12(50,50),e6(50,50),
90
 
     +               dcorr(50,50),rcorr(50,50),
91
 
     +               frcorr(50,50),fdcorr(50,50),
92
 
     +               rcut,acut(50,50),acut2(50,50),rcmax,icut,atnum
93
 
      double precision amass,e12,e6,dcorr,rcorr,frcorr,fdcorr,acut,rcut,
94
 
     +               acut2,rcmax
95
 
      integer icut,atnum
96
 
      common /md_timer/ tmstat(MAXTIM)
97
 
      double precision tmstat
98
 
      common /espar/ pmvac(NSTES),tmvac(NSTES),ipmvac(NSTES),
99
 
     +               itmvac(NSTES),esinc,esstps,esflg
100
 
      double precision pmvac,tmvac
101
 
      integer ipmvac,itmvac,esinc,esstps
102
 
      logical esflg
103
 
c
104
 
c   coordinates of atoms that are not held locally are stored in xcrc,
105
 
c   ycrd, zcrd, similarly, forces for atoms not held locally are stored
106
 
c   in xfrc, yfrc, zfrc
107
 
c
108
 
      common /md_buffer/xcrd(MAXAT),ycrd(MAXAT),zcrd(MAXAT),xfrc(MAXAT),
109
 
     +                  yfrc(MAXAT),zfrc(MAXAT),xacc(MAXAT),yacc(MAXAT),
110
 
     +                  zacc(MAXAT),mbuf(MAXAT),bidx(MAXAT),bat(MAXAT),
111
 
     +                  btot,savtot
112
 
      double precision xcrd,ycrd,zcrd,xfrc,yfrc,zfrc,xacc,yacc,zacc,mbuf
113
 
      integer bidx,bat,btot,savtot
114
 
c
115
 
      common /md_cell/rcell,kcmax,nix(2000),niy(2000),niz(2000)
116
 
      double precision rcell
117
 
      integer kcmax,nix,niy,niz
118
 
c
119
 
c   the xgru, xgrd etc. buffers keep track of which atoms are within a
120
 
c   cutoff distance of the upper (u) and lower (d) boundaries of the
121
 
c   cell. The ygbu, ygbd etc. buffers keep track of which buffer atoms
122
 
c   are within a cutoff distance of the boundaries (these buffers are
123
 
c   not needed for the x-direction updates). The ygbu, etc. buffers are
124
 
c   used in the gather routine. The ysbu, etc. buffers are used in a
125
 
c   similar way in the scatter routine.
126
 
c
127
 
      common /svlist/ xgru(MAXAT),xgrd(MAXAT),ygru(MAXAT),ygrd(MAXAT),
128
 
     +                zgru(MAXAT),zgrd(MAXAT),
129
 
     +                ygbu(MAXAT),ygbd(MAXAT),zgbu(MAXAT),zgbd(MAXAT),
130
 
     +                xsbu(MAXAT),xsbd(MAXAT),ysbu(MAXAT),ysbd(MAXAT),
131
 
     +                zsbu(MAXAT),zsbd(MAXAT),
132
 
     +                clist(6,MAXAT),
133
 
     +                ixgru,ixgrd,iygru,iygrd,izgru,izgrd,
134
 
     +                iygbu,iygbd,izgbu,izgbd
135
 
      integer xgru,xgrd,ygru,ygrd,zgru,zgrd,
136
 
     +        ygbu,ygbd,zgbu,zgbd,
137
 
     +        ixgru,ixgrd,iygru,iygrd,izgru,izgrd,
138
 
     +        iygbu,iygbd,izgbu,izgbd,ixsbu,ixsbd,iysbu,iysbd,
139
 
     +        izsbu,izsbd
140
 
      logical xsbu,xsbd,ysbu,ysbd,zsbu,zsbd
141
 
      logical clist
142
 
c
143
 
      common /neighbors/ nblist(MAXAT*MAXNB),nalast(MAXAT),
144
 
     +                   nblast(MAXAT),nafirst(MAXAT),nbfirst(MAXAT),
145
 
     +                   blist(3*MAXAT),balast(MAXAT),
146
 
     +                   bblast(MAXAT),bafirst(MAXAT),bbfirst(MAXAT)
147
 
      integer nblist,nalast,nblast,nafirst,nbfirst
148
 
      integer blist,balast,bblast,bafirst,bbfirst
149
 
c
150
 
      common /clusterpar/ cl_cmx, cl_cmy, cl_cmz, r_cluster, cl_sep,
151
 
     +                    cl_vcmx, cl_vcmy, cl_vcmz,
152
 
     +                    cl_acmx, cl_acmy, cl_acmz,
153
 
     +                    cl_prssr, cl_mass, r_cluster_old,
154
 
     +                    cl_old(MAXAT,3,3), cl_cm_old(3),
155
 
     +                    cl_vcm_old(3), cl_vol1_old, cl_vol2_old,
156
 
     +                    cl_box_old(3), cl_alen1_old(3),
157
 
     +                    cl_alen2_old(3), cl_scal1_old, cl_scal2_old,
158
 
     +                    cl_at(MAXAT), cl_tot, ctot, nocluster
159
 
      double precision cl_cmx, cl_cmy, cl_cmz, r_cluster, cl_sep,
160
 
     +                 cl_vcmx, cl_vcmy, cl_vcmz,
161
 
     +                 cl_acmx, cl_acmy, cl_acmz,
162
 
     +                 cl_prssr, cl_mass, cl_old, r_cluster_old,
163
 
     +                 cl_cm_old, cl_vcm_old, cl_vol1_old, cl_vol2_old,
164
 
     +                 cl_box_old, cl_alen1_old, cl_alen2_old,
165
 
     +                 cl_scal1_old, cl_scal2_old 
166
 
      integer cl_at, ctot, cl_tot
167
 
      logical nocluster
168
 
      common /solventpar/ sl_old(MAXAT,3,3),sl_at(MAXAT),sl_tot
169
 
      double precision sl_old
170
 
      integer sl_at, sl_tot
171
 
      common /equil_protocol/ r_confine, equil_1, equil_2, equil_3,
172
 
     +                        window_1, window_2
173
 
      double precision r_confine
174
 
      integer equil_1, equil_2, equil_3, window_1, window_2
175
 
      common /cllsnpar/ mmass, cllsn_idx, l_cllsn, cllsn_cnt,
176
 
     +                  cllsn_isav, failcount
177
 
      double precision mmass
178
 
      integer cllsn_idx, cllsn_cnt, cllsn_isav, failcount
179
 
      logical l_cllsn
180
 
      common /mcpar/ cl_lower, cl_upper, mc_step, mc_tmprtr, mc_dr,
181
 
     +               r_distr(0:MAXBINS,10), r_cnt(10), mcbins, mcfreq,
182
 
     +               mc_cnt, mc_start
183
 
      double precision cl_lower, cl_upper, mc_step, mc_tmprtr, mc_dr
184
 
      integer r_distr, r_cnt, mcbins, mcfreq, mc_cnt, mc_start
185
 
      common /taskpar/ task_id, g_counter
186
 
      integer task_id, g_counter
187
 
      common /iopar/ l_stdio, l_rad, l_rst, l_step, l_oldcfg
188
 
      logical l_stdio, l_rad, l_rst, l_step, l_oldcfg
189
 
      common /adapt/ t_done, t_rmndr
190
 
      double precision t_done, t_rmndr
191
 
      common /hashpar/ link_a(MAXAT), top_a(MAXAT), hash_key_a(MAXAT),
192
 
     +                 hash_value_a(MAXAT), a_cnt
193
 
      integer link_a, top_a, hash_key_a, hash_value_a, a_cnt