OpenMCTDHB v2.3

global.inc

Go to the documentation of this file.
00001 C***********************************************************************
00002 C
00003 C                         MCTDH include file GLOBAL 
00004 C                                                                     
00005 C  MCTDH include file defining various parameters and variables       
00006 C  global to the program.     
00007 C                                                                    
00008 C   V6.0 MB
00009 C                                                                    
00010 C***********************************************************************
00011 
00012 C-----------------------------------------------------------------------
00013 C PARAMETERS FOR CHARACTER STRING LENGTHS
00014 C
00015 C c1, c2, c3, c4, c5: various lengths
00016 C DO NOT CHANGE c3. Must match keyword length in rdinpf library routine
00017 C-----------------------------------------------------------------------
00018       integer c1, c2, c3, c4, c5
00019 
00020       parameter (c1=16)
00021       parameter (c2=32)
00022       parameter (c3=60)
00023       parameter (c4=80)
00024       parameter (c5=160)
00025 
00026 C-----------------------------------------------------------------------
00027 C progver: code version number, defines output formats etc.
00028 C tiny is added to all these numbers to ensure that version number is
00029 C .ge. to that desired!
00030 C Tiny is also used as a tolerance when real or complex numbers are
00031 C compared.
00032 C filever(i): file version number for file on channel i.
00033 C             Defines output formats etc.
00034 C  NB: filever must be dimensioned larger than largest channel no. used.
00035 C-----------------------------------------------------------------------
00036       real*8 tiny
00037       parameter (tiny=1.0d-8)
00038       real*8 progver,filever(100)
00039       common /version/ progver,filever
00040 
00041 C-----------------------------------------------------------------------
00042 C COMMON FOR INPUT / OUTPUT CHANNELS
00043 C initial channels are specified in main program, then transferred by
00044 C this common block to allow modifications to be made in the program
00045 C e.g. the output file is on channel 6 if printed to the screen, or
00046 C channel 13 if written to file
00047 C
00048 C iin:   .inp file 
00049 C ilog:  log file 
00050 C iolog: op.log file
00051 C irst:  restart file
00052 C itim:  timing file
00053 C ioper: operator file
00054 C idvr:  dvr file
00055 C iout:  output file
00056 C ichk:  check file
00057 C irho:  gridpop file
00058 C ipden: pdensity file (one particle density)
00059 C ictr:  ctrace file
00060 C icroco: cross file (cross-correlation function)
00061 C iaut:  auto file
00062 C iaute: autoe file 
00063 C iaut1: auto1 file (contains c_1 = <psi(0)| H |psi(t)>)
00064 C iaut2: auto2 file (contains c_2 = <psi(0)|H^2|psi(t)>)
00065 C istp:  intstep file
00066 C istop: stop file
00067 C iupd:  update file
00068 C ispeed: speed file
00069 C irlx:  rlx_info file
00070 C idat:  daten file
00071 C iop:   operator text file
00072 C ipar:  Hamiltonian parameter file
00073 C itmp:  scratch file used in building of operator 
00074 C iadwkb: diabatically corrected initial energy distribution
00075 C inpot   : 'natpot' file
00076 C ippsi   : 'ppsi' file
00077 C iit     : 'iteration' file
00078 C ipw     : 'prodwei' file
00079 C igit    : 'pgitter' file
00080 C icr1:   seems to be unused
00081 C iwtt:  <Psi(t)|W_gamma|Psi(t)> data
00082 C iflx:  reactive flux data
00083 C iexpect: file of expectation values
00084 C iexim: implicit psi file data
00085 C irp:   reaction probabilities
00086 C ipsi1: second psi file
00087 C iaus:  general output file used in analyse programs
00088 C ieigval: file of eigenvalues and intensities
00089 C ilancz:  file of Lanczos vectors
00090 C ieigvec: file of eigenvectors of tridiagonal Lanczos matrix
00091 C ivpot   : 'vpot' file
00092 C iveig   : veigen file
00093 C iorb    : orben file, orbital energies
00094 
00095 C-----------------------------------------------------------------------
00096       integer iin,ilog,irst,itim,ioper,idvr
00097       integer iout,ipsi,ichk,irho,iaut,iaute,istp,istop,
00098      +        iupd,ispeed,irlx,iaut1,iaut2,ictr,ipden
00099       integer idat,iop,ipar,itmp,iadwkb,iolog
00100       integer inpot,iit,ipw,ippsi,igit,iaus
00101       integer icr1,iwtt,iflx,iexpect,iexim,irp,ipsi1,ieigval,ilancz
00102       integer ieigvec,ivpot,iveig,iorb,icroco
00103 
00104       common /channels/ iin,ilog,iolog,irst,itim,ioper,idvr,
00105      +                  ipsi,ichk,iout,irho,iaut,iaute,istp,
00106      +                  istop,iupd,ispeed,irlx,iaut1,iaut2,ictr,
00107      +                  ipden,idat,iop,ipar,itmp,iadwkb,
00108      +                  inpot,iit,ipw,ippsi,igit,iaus,
00109      +                  icr1,iwtt,iflx,iexpect,iexim,irp,ipsi1,
00110      +                  ieigval,ilancz,ieigvec,ivpot,iveig,iorb,icroco
00111 
00112 
00113 C-----------------------------------------------------------------------
00114 C CHARACTER STRINGS TO PASS MESSAGES TO ERROR ROUTINE
00115 C-----------------------------------------------------------------------
00116       character*(c5) routine, message, inptit
00117 
00118       common /errorhandling/ routine, message, inptit
00119 
00120 
00121 C-----------------------------------------------------------------------
00122 C chkerr: array used for checking system definition
00123 C
00124 C chkerr(1)   : Error reading file
00125 C chkerr(2)   : Dofs differ from system
00126 C chkerr(3)   : DVR bases differ from system
00127 C chkerr(4)   : Mode combinations differ from system
00128 C chkerr(5)   : Electronic basis type differs from system
00129 C chkerr(6)   : Spf basis differs from system 
00130 C chkerr(7)   : Dofs not subset of system dofs
00131 C chkerr(8)   : ? not for this system
00132 C chkerr(9)   : Psi type differs from system
00133 C chkerr(10)  : Density matrix type differs from system
00134 C 
00135 C-----------------------------------------------------------------------
00136       integer nerr
00137       parameter (nerr=15)
00138 
00139       integer chkerr(nerr)
00140 
00141       common /rwerror/ chkerr
00142 
00143 
00144 C-----------------------------------------------------------------------
00145 C DIRECTORY DEFINITION FOR INPUT/OUTPUT FILES
00146 C
00147 C name      :  name of directory in which the output files are stored
00148 C inputfile : path of the inputfile (~.inp)
00149 C options   : string containing the list of options
00150 C laenge    : length of string name
00151 C inplaenge : length of string inputfile
00152 C optlaenge : length of string options
00153 C rname     : directory from which to take restart file
00154 C rlaenge   : length of string rname
00155 C oname     : directory from which to take operator file
00156 C olaenge   : length of string oname
00157 C dname     : directory from which to take dvr file
00158 C dlaenge   : length of string dname
00159 C vname     : name of a vpot file to read
00160 C vlength   : length of string vname
00161 C operfile  : path and name of oper file
00162 C opflaenge : length of string operfile
00163 C crossname : directory from which to take restart file used for
00164 C             calculating the cross-correlation-function
00165 C crosslng  : length of string crossname
00166 C-----------------------------------------------------------------------
00167       character*(c5)  name,inputfile,rname,dname,oname,vname,operfile
00168       character*(c5)  options,runtitle,crossname
00169       integer         laenge,inplaenge,optlaenge,rlaenge,dlaenge,
00170      +                olaenge,vlength,opflaenge,crosslng
00171 
00172       common /names/ name,inputfile,options,runtitle,rname,dname,oname,
00173      +               vname,operfile,crossname
00174       common /lengths/ laenge,inplaenge,optlaenge,rlaenge,dlaenge,
00175      +                 olaenge,vlength,opflaenge,crosslng
00176 
00177 C-----------------------------------------------------------------------
00178 C PARAMETERS FOR CALCULATIONS
00179 C
00180 C pi : pi is defined by 4d0*atan(1d0) in subroutine default.
00181 C fs : time conversion from a.u. to fs (x[a.u.] = fs*x[fs]).
00182 C ev : energy conversion from a.u. to ev (x[a.u.] = x[eV]/ev).
00183 C   Note: If a.u. are output, fs=ev=1
00184 C one: the variable 1
00185 C oner: the variable 1.0d0
00186 C True,False: the logicals .true. and .false., respectively
00187 C-----------------------------------------------------------------------
00188       integer   one,zeroi,onei,twoi,threei,fouri,fivei,sixi,seveni
00189      +          ,eighti,ninei,teni
00190       logical   true, false
00191 
00192       real*8    oner
00193       parameter (oner = 1.0d0)
00194       parameter (one=1,zeroi=0,onei=1,twoi=2,threei=3,fouri=4
00195      +  ,fivei=5,sixi=6,seveni=7,eighti=8,ninei=9,teni=10)
00196       parameter (true = .true., false = .false.)
00197 
00198       real*8    pi, fs, ev
00199       common /constants/ pi, fs, ev
00200 
00201 C-----------------------------------------------------------------------
00202 C PARAMETERS read from input 
00203 C
00204 C npar      : number of parameters read
00205 C apar(n)   : string with name of nth parameter
00206 C rpar(n)   : (real) value of nth parameter
00207 C-----------------------------------------------------------------------
00208       integer maxpar
00209       parameter (maxpar=350)
00210 
00211       integer npar
00212       real*8 rpar(maxpar)
00213       character*(c1) apar(maxpar)
00214 
00215       common /iparam/ npar
00216       common /rparam/ rpar
00217       common /aparam/ apar
00218 
00219 C-----------------------------------------------------------------------
00220 C  POINTERS for the start positions of
00221 C  the arrays stored in the memory arrays mc, mr, ms, mi and ml.
00222 C
00223 C see zeiger routines for definitions
00224 C
00225 C-----------------------------------------------------------------------
00226 
00227 C !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
00228 C !! If you add any further constant, change the mccount,..,mfcount   !!
00229 C !! values in subroutine checkmemprop !!                             !!
00230 C !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
00231 
00232       integer mcdim,mchpsi,mchunpsi,mcintpsi,mchin,mcrueck,mcexphin,
00233      +        mcexprueck,
00234      +        mchteil,mchloch,mcdicht1,mcdicht2,mcdicht4,mcdicht4o,
00235      +        mchnatur,mcwmat,mcipbt,mcipft,
00236      +        mcworkc,mccdvr2,mccdvr4,mcmfsum,mcoldpsi,
00237      +        mcpredpsi,mcautopsi,mcautodtpsi,mchc,mcspf1d,mcphi,
00238      +        mcpsiref,mcccdover
00239       integer mrdim,mrdicht3,mrort,mrdvrmat,mrtrafo,mrfftp,
00240      +        mrworkr,mrgpop1,mrgpop2,mrcdvr3,mrhunew,mrhunev,
00241      +        mrdicht3o,mrkinsph,mrhops,mrhr,mreigval,mreigerr,
00242      +        mreigint
00243       integer midim,miworki,mijsph,mimsph,mifftfak,mihi,mijindx,
00244      +        miccjindx
00245       integer mldim,mlworkl,mlhl
00246       integer msdim,msworks
00247       integer mfdim,mfworkf
00248 
00249       common /mcpoint/ mcdim,mchpsi,mchunpsi,mcintpsi,mchin,mcrueck,
00250      +        mchteil,mchloch,mcdicht1,mcdicht2,mcdicht4,mchnatur,
00251      +        mcdicht4o,mcwmat,mcipbt,mcipft,mcworkc,
00252      +        mccdvr2,mccdvr4,mcmfsum,mcoldpsi,mcpredpsi,mcautopsi,
00253      +        mcautodtpsi,mchc,mcspf1d,mcphi,mcexphin,mcexprueck,
00254      +        mcpsiref,mcccdover 
00255 
00256       common /mrpoint/ mrdim,mrdicht3,mrworkr,mrort,mrdvrmat,
00257      +        mrtrafo,mrfftp,mrdicht3o,mrgpop1,mrgpop2,mrcdvr3,
00258      +        mrhunew,mrhunev,mrkinsph,mrhops,mrhr,mreigval,mreigerr,
00259      +        mreigint
00260 
00261       common /mipoint/ midim,miworki,mijsph,mimsph,mifftfak,mihi,
00262      +        mijindx,miccjindx
00263 
00264       common /mlpoint/ mldim,mlworkl,mlhl
00265 
00266       common /mspoint/ msdim,msworks
00267 
00268       common /mfpoint/ mfdim,mfworkf
00269 
00270 C-----------------------------------------------------------------------
00271 C WORK ARRAY SIZES
00272 C
00273 C workcdim : Length of the complex*16 scratch array
00274 C workrdim : Size of real*8 scratch array 
00275 C workldim : Size of logical scratch array
00276 C workidim : Size of integer scratch array
00277 C worksdim : Size of complex*8 scratch array 
00278 C workfdim : Size of real*4 scratch array 
00279 C-----------------------------------------------------------------------
00280       integer workcdim,workrdim,workldim,workidim,worksdim,workfdim
00281 
00282       common /arraydim/ workcdim,workrdim,workldim,workidim,
00283      +        worksdim,workfdim
00284 
00285 C-----------------------------------------------------------------------
00286 C FLAG FOR WAVEFUNCTION / DENSITY MATRIX MODE
00287 C
00288 C dentype: 0 wavefunction
00289 C          1 density matrix type I
00290 C          2 density matrix type II
00291 C-----------------------------------------------------------------------
00292       integer dentype
00293 
00294       common /method/ dentype
00295 
00296 C-----------------------------------------------------------------------
00297 C LOGICALS TO CONTROL INPUT / OUTPUT OPTIONS
00298 C
00299 C If set to .true.,
00300 C     neu      : calculation is a new run
00301 C     cont     : calculation is a continuation run
00302 C     restart  : calculation is a restart run
00303 C     test     : runs up to propagation to test memory etc.
00304 C     test0    : short test-run (via option -s)
00305 C     lovwr    : files in directory are overwritten if neu 
00306 C     logisopen: the log file is open
00307 C     lwarn    : is set to 'true' in subroutine 'warnmsg'
00308 C     liopt    : is set to 'true' when input is read from name/input. 
00309 C     ltime    : controls timing output
00310 C     lnormstop: if true, the keyword 'normstop' in run-section is used
00311 C     lfast    : if true, the fast algorithm for H(npot)*A is used
00312 C-----------------------------------------------------------------------
00313       logical neu,cont,restart,test,lovwr,lwarn,lnpot,ltime
00314       logical test0,logisopen,liopt,lfast
00315       character*8 sstop,scpu
00316       real*8  nrmstop
00317       logical lnormstop, lstop
00318 
00319       common /blstop/ lnormstop, lstop
00320       common /stopnorm/ nrmstop
00321       common /stopstring/ sstop,scpu
00322       common /strtopt/ neu,cont,restart,test,lovwr,lnpot,test0,lfast
00323       common /ioopt/   logisopen,ltime,lwarn,liopt
00324 
00325 C-----------------------------------------------------------------------
00326 C 
00327 C FLAGS TO SPECIFY THE RUN-TYPE AND RW-FILE GENERATION
00328 C
00329 C  If set to .true., 
00330 C     lrundvr  : A DVR file will be generated
00331 C     lrunoper : An OPER file will be generated
00332 C     lruninwf : A RESTART file will be generated
00333 C     lrunpes  : A PES file will be generated
00334 C     lrunprop : A propagation will be made
00335 C     lrundiag : if true, the Hamiltonian is diagonalised using Lanczos
00336 C     lrddvr   : A DVR file will be read
00337 C     lrdoper  : An OPER file will be read
00338 C     lrdinwf  : A RESTART file will be read
00339 C     ldeldvr  : DVR file is deleted after use
00340 C     ldelop   : OPER file is deleted after use
00341 C     lexact   : numerically exact calculation
00342 C-----------------------------------------------------------------------
00343       logical lrundvr,lrunoper,lruninwf,lrunprop,lrddvr,lrdoper,
00344      +        lrdinwf,lrunpes,lrundiag,lexact,ldelop,ldeldvr
00345 
00346       common /runopts/ lrundvr,lrunoper,lruninwf,lrunprop,lrddvr,
00347      +                 lrdoper,lrdinwf,lexact,lrundiag,lrunpes,
00348      +                 ldelop,ldeldvr
00349 
00350 C-----------------------------------------------------------------------
00351 C ACCURACY VARIABLES
00352 C
00353 C macheps: machine precision, i. e. smallest positive number for which
00354 C          1.0+macheps > 1.0  (macheps=2.2d-16)
00355 C-----------------------------------------------------------------------
00356        real*8 macheps
00357        common /macheps/ macheps
00358 
00359 C-----------------------------------------------------------------------
00360 C VARIABLES USED TO READ INPUT FILE
00361 C (defined here so that same size arrays are used in different routines)
00362 C-----------------------------------------------------------------------
00363       integer maxkey
00364       parameter (maxkey=30)
00365 
00366       character*(c3) keyword(maxkey),keyorig(maxkey)
00367       integer      lc(maxkey)
00368 
00369       common /akey/ keyword,keyorig
00370       common /ikey/ lc
00371 
00372 
00373 C-----------------------------------------------------------------------
00374 C array needed to specify which parts of read-write files are to be read
00375 C-----------------------------------------------------------------------
00376       integer nrwdata
00377       parameter (nrwdata=15)
00378 
00379       logical dvrdata(nrwdata)
00380 
00381       common /rwlogicals/ dvrdata
00382 
00383 
00384 C-----------------------------------------------------------------------
00385 C integers for outputcontrol of pdensity: 
00386 C npd1...npd4 -- if set -- specify the modes for which the pdensity is 
00387 C written.
00388 C-----------------------------------------------------------------------
00389       integer npd1,npd2,npd3,npd4
00390       common /npd/ npd1,npd2,npd3,npd4
00391 
00392 
00393 
00394 
00395 
00396 
00397 
00398 
00399 
00400 
00401 
 All Namespaces Files Functions Variables