3 C Define constants and zero out tables.
5 implicit real*8 (a-h,o-z)
7 include 'DIMENSIONS.ZSCOPT'
11 include 'COMMON.IOUNITS'
12 include 'COMMON.CHAIN'
13 include 'COMMON.INTERACT'
15 include 'COMMON.LOCAL'
16 include 'COMMON.TORSION'
17 include 'COMMON.FFIELD'
18 include 'COMMON.SBRIDGE'
19 include 'COMMON.MINIM'
20 include 'COMMON.DERIV'
21 include "COMMON.WEIGHTS"
22 include "COMMON.NAMES"
23 include "COMMON.TIME1"
24 include "COMMON.THERMAL"
25 include "COMMON.TORCNSTR"
26 include "COMMON.ENERGIES"
28 C The following is just to define auxiliary variables used in angle conversion
65 C CSA I/O units (separated from others especially for Jooyoung)
76 icsa_bank_reminimized=38
80 C Set default weights of the energy terms.
124 athet(j,i,ichir1,ichir2)=0.0D0
125 bthet(j,i,ichir1,ichir2)=0.0D0
145 gaussc(l,k,j,i)=0.0D0
158 v1(k,j,i,iblock)=0.0D0
159 v2(k,j,i,iblock)=0.0D0
168 C Initialize the bridge arrays
187 C Initialize variables used in minimization.
196 C Initialize the variables responsible for the mode of gradient storage.
202 if (print_order(i).eq.j) then
210 C Set timers and counters for the respective routines
229 nprint_ene=nprint_ene-1
234 c-------------------------------------------------------------------------
236 implicit real*8 (a-h,o-z)
238 include 'DIMENSIONS.ZSCOPT'
239 include 'COMMON.NAMES'
240 include 'COMMON.WEIGHTS'
241 include 'COMMON.FFIELD'
243 &'DD','DAU','DAI','DDB','DSM','DPR','DLY','DAR','DHI','DAS','DGL',
244 & 'DSG','DGN','DSN','DTH',
245 &'DYY','DAL','DTY','DTR','DVA','DLE','DIL','DPN','MED','DCY','ZER',
246 &'CYS','MET','PHE','ILE','LEU','VAL','TRP','TYR','ALA','GLY','THR',
247 &'SER','GLN','ASN','GLU','ASP','HIS','ARG','LYS','PRO','SME','DBZ',
250 &'z','z','z','z','z','p','k','r','h','d','e','n','q','s','t','g',
251 &'a','y','w','v','l','i','f','m','c','x',
252 &'C','M','F','I','L','V','W','Y','A','G','T',
253 &'S','Q','N','E','D','H','R','K','P','z','z','z','z','X'/
254 data potname /'LJ','LJK','BP','GB','GBV','MM'/
256 & "EVDW SC-SC","EVDW2 SC-p","EES p-p","ECORR4 ","ECORR5 ",
257 & "ECORR6 ","EELLO ","ETURN3 ","ETURN4 ","ETURN6 ",
258 & "EBE bend","ESC SCloc","ETORS ","ETORSD ","EHPB","EVDWPP",
259 & "ESTR","EVDW2_14","ESCCOR","EDIHC","EVDW_T","ELIPTRAN",
260 & "EAFM","ETHETC","EMPTY"/
262 & "WSC","WSCP","WELEC","WCORR","WCORR5","WCORR6","WEL_LOC",
263 & "WTURN3","WTURN4","WTURN6","WANG","WSCLOC","WTOR","WTORD",
264 & "WHPB","WVDWPP","WBOND","WSCP14","WSCCOR","WDIHC","WSC_T",
265 & "WLIPTRAN","WAFM","WTHETC","WSHIELD"/
266 data ww0 /1.0d0,1.0d0,1.0d0,1.0d0,1.0d0,1.0d0,1.0d0,1.0d0,1.0d0,
267 & 1.0d0,1.0d0,1.0d0,1.0d0,1.0d0,1.0d0,1.0d0,1.0d0,0.0d0,1.0d0,
268 & 0.0d0,0.0,0.0d0,0.0d0,0.0d0,0.0d0/
270 data print_order /1,2,3,17,11,12,13,14,4,5,6,7,8,9,10,19,16,15,18,
273 c---------------------------------------------------------------------------
274 subroutine init_int_table
275 implicit real*8 (a-h,o-z)
277 include 'DIMENSIONS.ZSCOPT'
282 include 'COMMON.INFO'
284 include 'COMMON.CHAIN'
285 include 'COMMON.INTERACT'
286 include 'COMMON.LOCAL'
287 include 'COMMON.SBRIDGE'
288 include 'COMMON.IOUNITS'
289 logical scheck,lprint
305 cd write (iout,*) 'ns=',ns,' nss=',nss,' ihpb,jhpb',
306 cd & (ihpb(i),jhpb(i),i=1,nss)
310 if (ihpb(ii).eq.i+nres) then
317 cd write (iout,*) 'i=',i,' scheck=',scheck,' jj=',jj
323 else if (jj.eq.nct) then
338 ind_scint=int_scint+nct-i
345 write (iout,'(a)') 'Interaction array:'
347 write (iout,'(i3,2(2x,2i3))')
348 & i,(istart(i,iint),iend(i,iint),iint=1,nint_gr(i))
359 write (iout,'(a)') 'Electrostatic interaction array:'
361 write (iout,'(i3,2(2x,2i3))') i,ielstart(i),ielend(i)
366 C Partition the SC-p interaction array
370 if (i.lt.nnt+iscp) then
372 iscpstart(i,1)=i+iscp
374 elseif (i.gt.nct-iscp) then
382 iscpstart(i,2)=i+iscp
387 write (iout,'(a)') 'SC-p interaction array:'
388 do i=iatscp_s,iatscp_e
389 write (iout,'(i3,2(2x,2i3))')
390 & i,(iscpstart(i,j),iscpend(i,j),j=1,nscp_gr(i))
393 C Partition local interactions
405 idihconstr_end=ndih_constr
407 ithetaconstr_end=ntheta_constr
412 c---------------------------------------------------------------------------
413 subroutine int_partition(int_index,lower_index,upper_index,atom,
414 & at_start,at_end,first_atom,last_atom,int_gr,jat_start,jat_end,*)
415 implicit real*8 (a-h,o-z)
417 include 'DIMENSIONS.ZSCOPT'
418 include 'COMMON.IOUNITS'
419 integer int_index,lower_index,upper_index,atom,at_start,at_end,
420 & first_atom,last_atom,int_gr,jat_start,jat_end
423 if (lprn) write (iout,*) 'int_index=',int_index
424 int_index_old=int_index
425 int_index=int_index+last_atom-first_atom+1
427 & write (iout,*) 'int_index=',int_index,
428 & ' int_index_old',int_index_old,
429 & ' lower_index=',lower_index,
430 & ' upper_index=',upper_index,
431 & ' atom=',atom,' first_atom=',first_atom,
432 & ' last_atom=',last_atom
433 if (int_index.ge.lower_index) then
435 if (at_start.eq.0) then
437 jat_start=first_atom-1+lower_index-int_index_old
441 if (lprn) write (iout,*) 'jat_start',jat_start
442 if (int_index.ge.upper_index) then
444 jat_end=first_atom-1+upper_index-int_index_old
449 if (lprn) write (iout,*) 'jat_end',jat_end
453 c------------------------------------------------------------------------------
454 subroutine hpb_partition
455 implicit real*8 (a-h,o-z)
457 include 'DIMENSIONS.ZSCOPT'
458 include 'COMMON.SBRIDGE'
459 include 'COMMON.IOUNITS'
462 cd write (iout,*) 'Processor',MyID,' MyRank',MyRank,
463 cd & ' nhpb',nhpb,' link_start=',link_start,
464 cd & ' link_end',link_end