2 !-----------------------------------------------------------------------------
6 real(kind=8),dimension(:,:),allocatable :: friction,stochforc !(3,0:MAXRES2)
7 real(kind=8),dimension(:),allocatable :: fric_work,stoch_work,&
9 real(kind=8),dimension(:,:),allocatable :: fricmat,fricvec,&
10 pfric_mat,vfric_mat,afric_mat,prand_mat,vrand_mat1,&
11 vrand_mat2 !(MAXRES2,MAXRES2)
12 real(kind=8),dimension(:,:,:),allocatable :: pfric0_mat,&
13 afric0_mat,vfric0_mat,prand0_mat,vrand0_mat1,vrand0_mat2 !(MAXRES2,MAXRES2,0:maxflag_stoch)
14 logical,dimension(:),allocatable :: flag_stoch !(0:maxflag_stoch)
16 real(kind=8),dimension(:,:),allocatable :: mt1,mt2,mt3 !(maxres2,maxres2)
17 !-----------------------------------------------------------------------------
19 ! commom.langevin.lang0
21 real(kind=8),dimension(:,:),allocatable :: friction,stochforc !(3,0:MAXRES2)
22 real(kind=8),dimension(:,:),allocatable :: fricmat,fricvec !(MAXRES2,MAXRES2)
23 real(kind=8),dimension(:),allocatable :: fric_work,stoch_work,&
25 logical,dimension(:),allocatable :: flag_stoch !(0:maxflag_stoch)
26 real(kind=8) :: vrand_mat1,vrand_mat2,prand_mat,vfric_mat,&
27 afric_mat,pfric_mat,pfric0_mat,afric0_mat,vfric0_mat,prand0_mat,&
28 vrand0_mat1,vrand0_mat2
30 integer :: mt1,mt2,mt3
32 !-----------------------------------------------------------------------------
33 ! commom.hairpin in CSA module
34 !-----------------------------------------------------------------------------
35 ! common.mce in MCM_MD module
36 !-----------------------------------------------------------------------------
38 ! common /mdgrad/ in module.energy
39 ! common /back_constr/ in module.energy
40 ! common /qmeas/ others in module.geometry
41 real(kind=8) :: eq_time
42 integer :: iset,nset,itime_mat
43 integer,dimension(:),allocatable :: mset !(maxprocs/20)
46 real(kind=8) :: v_ini,d_time,d_time0,scal_fric,&
47 t_bath,tau_bath,dvmax,damax
48 integer :: n_timestep,ntime_split,ntime_split0,maxtime_split,&
50 logical :: mdpdb,large,print_compon,tbf,rest,fodson
52 real(kind=8) :: totT,totE,potE,EK,amax,edriftmax,kinetic_T,totTafm
53 real(kind=8),dimension(:),allocatable :: potEcomp !(0:n_ene+4)
55 real(kind=8),dimension(:,:),allocatable :: d_t,d_a,d_t_old !(3,0:MAXRES2)
56 real(kind=8),dimension(:),allocatable :: d_a_work !(6*MAXRES)
57 real(kind=8),dimension(:,:),allocatable :: Gmat,Ginv,A,&
58 Gsqrp,Gsqrm,Gvec !(maxres2,maxres2)
59 real(kind=8),dimension(:),allocatable :: DM,DU1,DU2
60 real(kind=8),dimension(:),allocatable :: DMorig,DU1orig,DU2orig
61 real(kind=8),dimension(:),allocatable :: Geigen !(maxres2)
62 real(kind=8),dimension(:),allocatable ::vtot !(maxres2)
63 logical :: reset_moment,reset_vel,rattle,RESPA
64 integer :: dimen,dimen1,dimen3
65 integer :: lang,count_reset_moment,count_reset_vel
67 real(kind=8),dimension(5) :: IP,mp
68 real(kind=8),dimension(:,:),allocatable :: ISC,msc !(ntyp+1)
70 real(kind=8) :: rwat,etawat
71 real(kind=8), dimension(5) :: pstok,gamp,stdfp
72 real(kind=8) :: cPoise=2.9361d0, Rb=0.001986d0
73 real(kind=8),dimension(:,:),allocatable :: gamsc !(ntyp1)
74 real(kind=8),dimension(:,:),allocatable :: stdfsc !(ntyp)
76 real(kind=8),dimension(:,:),allocatable :: restok !(ntyp+1)
78 integer :: reset_fricmat
80 integer :: igmult_start,igmult_end,my_ng_count,myginv_ng_count
81 integer,dimension(:),allocatable :: ng_start,ng_counts,&
82 nginv_counts !(0:MaxProcs-1)
83 integer,dimension(:),allocatable :: nginv_start !(0:MaxProcs)
84 !-----------------------------------------------------------------------------
86 ! common /double_muca/
87 real(kind=8) :: elow,ehigh,factor,hbin,factor_min
88 real(kind=8),dimension(:),allocatable :: emuca,nemuca,&
89 nemuca2,hist !(4*maxres)
90 ! common /integer_muca/
91 integer :: nmuca,imtime,muca_smooth
93 real(kind=8),dimension(:),allocatable :: elowi,ehighi !(maxprocs)
94 !-----------------------------------------------------------------------------
95 ! Maximum number of timesteps for which stochastic MD matrices can be stored
96 integer,parameter :: maxflag_stoch=0
97 !-----------------------------------------------------------------------------
98 ! common /przechowalnia/ subroutines: setup_MD_matrices
99 real(kind=8),dimension(:,:),allocatable :: Gcopy !(maxres2,maxres2), maxres2=2*maxres
100 !-----------------------------------------------------------------------------
101 ! common /przechowalnia/ subroutines: setup_fricmat,setup_MD_matrices
102 real(kind=8),dimension(:),allocatable :: Ghalf
103 !-----------------------------------------------------------------------------
105 real(kind=8),DIMENSION(:),allocatable :: D_ban !(MAXRES6) maxres6=6*maxres
106 !-----------------------------------------------------------------------------
107 logical preminim, forceminim ! pre-minimizaation flag
109 integer,parameter :: maxchain=50
110 integer,dimension(maxchain) :: dimen_chain,iposd_chain
111 real(kind=8),dimension(:),allocatable :: DMfric,DU1fric,&