1 subroutine read_general_data(*)
4 include "DIMENSIONS.ZSCOPT"
5 include "DIMENSIONS.FREE"
6 include "COMMON.TORSION"
7 include "COMMON.INTERACT"
8 include "COMMON.IOUNITS"
11 include "COMMON.PROTFILES"
12 include "COMMON.CHAIN"
13 include "COMMON.NAMES"
14 include "COMMON.FFIELD"
15 include "COMMON.ENEPS"
16 include "COMMON.WEIGHTS"
18 include "COMMON.CONTROL"
19 include "COMMON.ENERGIES"
20 include "COMMON.SPLITELE"
21 include "COMMON.SBRIDGE"
22 character*800 controlcard
23 integer i,j,k,ii,n_ene_found
24 integer ind,itype1,itype2,itypf,itypsc,itypp
31 call card_concat(controlcard,.true.)
32 call readi(controlcard,"N_ENE",n_ene,max_ene)
33 if (n_ene.gt.max_ene) then
34 write (iout,*) "Error: parameter out of range: N_ENE",n_ene,
38 call readi(controlcard,"NPARMSET",nparmset,1)
39 separate_parset = index(controlcard,"SEPARATE_PARSET").gt.0
40 call readi(controlcard,"IPARMPRINT",iparmprint,1)
41 write (iout,*) "PARMPRINT",iparmprint
42 if (nparmset.gt.max_parm) then
43 write (iout,*) "Error: parameter out of range: NPARMSET",
47 call readi(controlcard,"MAXIT",maxit,5000)
48 call reada(controlcard,"FIMIN",fimin,1.0d-3)
49 call readi(controlcard,"ENSEMBLES",ensembles,0)
50 hamil_rep=index(controlcard,"HAMIL_REP").gt.0
51 write (iout,*) "Number of energy parameter sets",nparmset
52 call multreadi(controlcard,"ISAMPL",isampl,nparmset,1)
53 write (iout,*) "MaxSlice",MaxSlice
54 call readi(controlcard,"NSLICE",nslice,1)
56 if (nslice.gt.MaxSlice) then
57 write (iout,*) "Error: parameter out of range: NSLICE",nslice,
61 write (iout,*) "Frequency of storing conformations",
62 & (isampl(i),i=1,nparmset)
63 write (iout,*) "Maxit",maxit," Fimin",fimin
64 call readi(controlcard,"NQ",nQ,1)
66 write (iout,*) "Error: parameter out of range: NQ",nq,
71 if (index(controlcard,"CLASSIFY").gt.0) indpdb=1
72 call reada(controlcard,"DELTA",delta,1.0d-2)
73 call readi(controlcard,"EINICHECK",einicheck,2)
74 call reada(controlcard,"DELTRMS",deltrms,5.0d-2)
75 call reada(controlcard,"DELTRGY",deltrgy,5.0d-2)
76 call readi(controlcard,"RESCALE",rescale_mode,1)
77 check_conf=index(controlcard,"NO_CHECK_CONF").eq.0
78 call reada(controlcard,'DISTCHAINMAX',distchainmax,50.0d0)
79 call reada(controlcard,'BOXX',boxxsize,100.0d0)
80 call reada(controlcard,'BOXY',boxysize,100.0d0)
81 call reada(controlcard,'BOXZ',boxzsize,100.0d0)
82 c Cutoff range for interactions
83 call reada(controlcard,"R_CUT",r_cut,15.0d0)
84 call reada(controlcard,"LAMBDA",rlamb,0.3d0)
85 call reada(controlcard,"LIPTHICK",lipthick,0.0d0)
86 call reada(controlcard,"LIPAQBUF",lipbufthick,0.0d0)
87 if (lipthick.gt.0.0d0) then
88 bordliptop=(boxzsize+lipthick)/2.0
89 bordlipbot=bordliptop-lipthick
91 if ((bordliptop.gt.boxzsize).or.(bordlipbot.lt.0.0))
92 & write(iout,*) "WARNING WRONG SIZE OF LIPIDIC PHASE"
93 buflipbot=bordlipbot+lipbufthick
94 bufliptop=bordliptop-lipbufthick
95 if ((lipbufthick*2.0d0).gt.lipthick)
96 &write(iout,*) "WARNING WRONG SIZE OF LIP AQ BUF"
98 write(iout,*) "bordliptop=",bordliptop
99 write(iout,*) "bordlipbot=",bordlipbot
100 write(iout,*) "bufliptop=",bufliptop
101 write(iout,*) "buflipbot=",buflipbot
102 call readi(controlcard,'SYM',symetr,1)
103 write (iout,*) "DISTCHAINMAX",distchainmax
104 write (iout,*) "delta",delta
105 write (iout,*) "einicheck",einicheck
106 write (iout,*) "rescale_mode",rescale_mode
108 bxfile=index(controlcard,"BXFILE").gt.0
109 cxfile=index(controlcard,"CXFILE").gt.0
110 if (nslice .eq. 1 .and. .not.bxfile .and. .not.cxfile)
112 histfile=index(controlcard,"HISTFILE").gt.0
113 histout=index(controlcard,"HISTOUT").gt.0
114 entfile=index(controlcard,"ENTFILE").gt.0
115 zscfile=index(controlcard,"ZSCFILE").gt.0
116 with_dihed_constr = index(controlcard,"WITH_DIHED_CONSTR").gt.0
117 write (iout,*) "with_dihed_constr ",with_dihed_constr
118 with_theta_constr = index(controlcard,"WITH_THETA_CONSTR").gt.0
119 write (iout,*) "with_theta_constr ",with_theta_constr
120 call readi(controlcard,'CONSTR_DIST',constr_dist,0)
121 dyn_ss=index(controlcard,"DYN_SS").gt.0
124 c------------------------------------------------------------------------------
125 subroutine read_efree(*)
127 C Read molecular data
131 include 'DIMENSIONS.ZSCOPT'
132 include 'DIMENSIONS.COMPAR'
133 include 'DIMENSIONS.FREE'
134 include 'COMMON.IOUNITS'
135 include 'COMMON.TIME1'
136 include 'COMMON.SBRIDGE'
137 include 'COMMON.CONTROL'
138 include 'COMMON.CHAIN'
139 include 'COMMON.HEADER'
141 include 'COMMON.FREE'
142 character*320 controlcard,ucase
143 integer iparm,ib,i,j,npars
155 call card_concat(controlcard,.true.)
156 call readi(controlcard,'NT',nT_h(iparm),1)
157 write (iout,*) "iparm",iparm," nt",nT_h(iparm)
159 if (nT_h(iparm).gt.MaxT_h) then
160 write (iout,*) "Error: parameter out of range: NT",nT_h(iparm),
164 replica(iparm)=index(controlcard,"REPLICA").gt.0
165 umbrella(iparm)=index(controlcard,"UMBRELLA").gt.0
166 read_iset(iparm)=index(controlcard,"READ_ISET").gt.0
167 write (iout,*) "nQ",nQ," nT",nT_h(iparm)," replica ",
168 & replica(iparm)," umbrella ",umbrella(iparm),
169 & " read_iset",read_iset(iparm)
172 call card_concat(controlcard,.true.)
173 call readi(controlcard,'NR',nR(ib,iparm),1)
174 if (umbrella(iparm)) then
177 nRR(ib,iparm)=nR(ib,iparm)
179 if (nR(ib,iparm).gt.MaxR) then
180 write (iout,*) "Error: parameter out of range: NR",
184 call reada(controlcard,'TEMP',beta_h(ib,iparm),298.0d0)
185 beta_h(ib,iparm)=1.0d0/(beta_h(ib,iparm)*1.987D-3)
186 call multreada(controlcard,'FI',f(1,ib,iparm),nR(ib,iparm),
189 call card_concat(controlcard,.true.)
190 call multreada(controlcard,'KH',KH(1,i,ib,iparm),nQ,
192 call multreada(controlcard,'Q0',Q0(1,i,ib,iparm),nQ,
197 write (iout,*) "ib",ib," beta_h",
198 & 1.0d0/(0.001987*beta_h(ib,iparm))
199 write (iout,*) "nR",nR(ib,iparm)
200 write (iout,*) "fi",(f(i,ib,iparm),i=1,nR(ib,iparm))
202 write (iout,*) "i",i," Kh",(Kh(j,i,ib,iparm),j=1,nQ),
203 & "q0",(q0(j,i,ib,iparm),j=1,nQ)
215 nR(ib,iparm)=nR(ib,1)
216 if (umbrella(iparm)) then
219 nRR(ib,iparm)=nR(ib,1)
221 beta_h(ib,iparm)=beta_h(ib,1)
223 f(i,ib,iparm)=f(i,ib,1)
225 KH(j,i,ib,iparm)=KH(j,i,ib,1)
226 Q0(j,i,ib,iparm)=Q0(j,i,ib,1)
229 replica(iparm)=replica(1)
230 umbrella(iparm)=umbrella(1)
231 read_iset(iparm)=read_iset(1)
239 c-----------------------------------------------------------------------------
240 subroutine read_protein_data(*)
243 include "DIMENSIONS.ZSCOPT"
244 include "DIMENSIONS.FREE"
247 integer IERROR,ERRCODE,STATUS(MPI_STATUS_SIZE)
250 include "COMMON.CHAIN"
251 include "COMMON.IOUNITS"
252 include "COMMON.PROT"
253 include "COMMON.PROTFILES"
254 include "COMMON.NAMES"
255 include "COMMON.FREE"
256 include "COMMON.OBCINKA"
258 character*16000 controlcard
259 integer i,ii,ib,iR,iparm,ilen,iroof,nthr,npars
269 C Read names of files with conformation data.
270 if (replica(iparm)) then
276 do ii=1,nRR(ib,iparm)
277 write (iout,*) "Parameter set",iparm," temperature",ib,
280 call card_concat(controlcard,.true.)
281 write (iout,*) controlcard(:ilen(controlcard))
282 call readi(controlcard,"NFILE_BIN",nfile_bin(ii,ib,iparm),0)
283 call readi(controlcard,"NFILE_ASC",nfile_asc(ii,ib,iparm),0)
284 call readi(controlcard,"NFILE_CX",nfile_cx(ii,ib,iparm),0)
285 call readi(controlcard,"REC_START",rec_start(ii,ib,iparm),1)
286 call readi(controlcard,"REC_END",rec_end(ii,ib,iparm),
287 & maxstr*isampl(iparm)+rec_start(ii,ib,iparm)-1)
288 call reada(controlcard,"TIME_START",
289 & time_start_collect(ii,ib,iparm),0.0d0)
290 call reada(controlcard,"TIME_END",time_end_collect(ii,ib,iparm),
292 write (iout,*) "rec_start",rec_start(ii,ib,iparm),
293 & " rec_end",rec_end(ii,ib,iparm)
294 write (iout,*) "time_start",time_start_collect(ii,ib,iparm),
295 & " time_end",time_end_collect(ii,ib,iparm)
297 if (replica(iparm)) then
298 call readi(controlcard,"TOTRAJ",totraj(ii,iparm),1)
299 write (iout,*) "Number of trajectories",totraj(ii,iparm)
302 if (nfile_bin(ii,ib,iparm).lt.2
303 & .and. nfile_asc(ii,ib,iparm).eq.0
304 & .and. nfile_cx(ii,ib,iparm).eq.0) then
305 write (iout,*) "Error - no action specified!"
308 if (nfile_bin(ii,ib,iparm).gt.0) then
309 call card_concat(controlcard,.false.)
310 call split_string(controlcard,protfiles(1,1,ii,ib,iparm),
311 & maxfile_prot,nfile_bin(ii,ib,iparm))
313 write(iout,*)"nfile_bin",nfile_bin(ii,ib,iparm)
314 write(iout,*) (protfiles(i,1,ii,ib,iparm),
315 & i=1,nfile_bin(ii,ib,iparm))
318 if (nfile_asc(ii,ib,iparm).gt.0) then
319 call card_concat(controlcard,.false.)
320 call split_string(controlcard,protfiles(1,2,ii,ib,iparm),
321 & maxfile_prot,nfile_asc(ii,ib,iparm))
323 write(iout,*) "nfile_asc(ii,ib,iparm)",nfile_asc(ii,ib,iparm)
324 write(iout,*) (protfiles(i,2,ii,ib,iparm),
325 & i=1,nfile_asc(ii,ib,iparm))
327 else if (nfile_cx(ii,ib,iparm).gt.0) then
328 call card_concat(controlcard,.false.)
329 call split_string(controlcard,protfiles(1,2,ii,ib,iparm),
330 & maxfile_prot,nfile_cx(ii,ib,iparm))
332 write(iout,*) "nfile_cx(ii,ib,iparm)",nfile_cx(ii,ib,iparm)
333 write(iout,*) (protfiles(i,2,ii,ib,iparm),
334 & i=1,nfile_cx(ii,ib,iparm))
345 c-------------------------------------------------------------------------------
346 subroutine opentmp(islice,iunit,bprotfile_temp)
349 include "DIMENSIONS.ZSCOPT"
350 include "DIMENSIONS.FREE"
353 integer IERROR,ERRCODE,STATUS(MPI_STATUS_SIZE)
356 include "COMMON.IOUNITS"
357 include "COMMON.PROTFILES"
358 include "COMMON.PROT"
359 include "COMMON.FREE"
360 character*64 bprotfile_temp
361 character*3 liczba,liczba2
368 write (liczba1,'(bz,i2.2)') islice
369 write (liczba,'(bz,i3.3)') me
371 c write (iout,*) "separate_parset ",separate_parset,
373 if (separate_parset) then
374 write (liczba2,'(bz,i3.3)') myparm
375 bprotfile_temp = scratchdir(:ilen(scratchdir))//"/"//
376 & prefix(:ilen(prefix))//liczba//"_"//liczba2//".xbin.tmp"//liczba1
377 open (iunit,file=bprotfile_temp,status="unknown",
378 & form="unformatted",access="direct",recl=lenrec)
380 bprotfile_temp = scratchdir(:ilen(scratchdir))//"/"//
381 & prefix(:ilen(prefix))//liczba//".xbin.tmp"//liczba1
382 open (iunit,file=bprotfile_temp,status="unknown",
383 & form="unformatted",access="direct",recl=lenrec)
386 bprotfile_temp = scratchdir(:ilen(scratchdir))//
387 & "/"//prefix(:ilen(prefix))//".xbin.tmp"//liczba1
388 open (iunit,file=bprotfile_temp,status="unknown",
389 & form="unformatted",access="direct",recl=lenrec)
391 c write (iout,*) "OpenTmp iunit",iunit," bprotfile_temp",
396 c-------------------------------------------------------------------------------
397 subroutine read_database(*)
400 include "DIMENSIONS.ZSCOPT"
401 include "DIMENSIONS.FREE"
404 integer IERROR,ERRCODE,STATUS(MPI_STATUS_SIZE)
407 include "COMMON.CHAIN"
408 include "COMMON.IOUNITS"
409 include "COMMON.PROTFILES"
410 include "COMMON.NAMES"
413 include "COMMON.ENEPS"
414 include "COMMON.PROT"
415 include "COMMON.INTERACT"
416 include "COMMON.FREE"
417 include "COMMON.SBRIDGE"
418 include "COMMON.OBCINKA"
419 real*4 csingle(3,maxres2)
420 character*64 nazwa,bprotfile_temp
423 integer i,j,ii,jj(maxslice),k,kk(maxslice),l,
424 & ll(maxslice),mm(maxslice),if
425 integer nrec,nlines,iscor,iunit,islice
426 double precision energ
429 double precision rmsdev,energia(0:max_ene),efree,eini,temp
430 double precision prop(maxQ)
431 integer ntot_all(maxslice,0:maxprocs-1), maxslice_buff
432 integer iparm,ib,iib,ir,nprop,nthr,npars
433 double precision etot,time
437 lenrec1=12*(nres+nct-nnt+1)+4*(2*nss+2)+24
438 lenrec2=12*(nres+nct-nnt+1)+4*(2*nss+2)+24+8*nQ
440 write (iout,*) "lenrec",lenrec," lenrec1",lenrec1,
450 write (iout,*) "nparmset",nparmset
458 if (replica(iparm)) then
465 do iR=1,nRR(ib,iparm)
467 write (iout,*) "iparm",iparm," ib",ib," iR",iR," nQ",nQ
473 IF (NFILE_BIN(iR,ib,iparm).GT.0) THEN
474 c Read conformations from binary DA files (one per batch) and write them to
475 c a binary DA scratchfile.
476 write (liczba,'(bz,i3.3)') me
477 do if=1,nfile_bin(iR,ib,iparm)
478 nazwa=protfiles(if,1,iR,ib,iparm)
479 & (:ilen(protfiles(if,1,iR,ib,iparm)))//".bx"
480 open (ientin,file=nazwa,status="old",form="unformatted",
481 & access="direct",recl=lenrec2,err=1111)
484 call opentmp(islice,ientout,bprotfile_temp)
485 call bxread(nazwa,ii,jj(islice),kk(islice),ll(islice),
486 & mm(islice),iR,ib,iparm)
493 IF (NFILE_ASC(iR,ib,iparm).GT.0) THEN
494 c Read conformations from multiple ASCII int files and write them to a binary
496 do if=1,nfile_asc(iR,ib,iparm)
497 nazwa=protfiles(if,2,iR,ib,iparm)
498 & (:ilen(protfiles(if,2,iR,ib,iparm)))//".x"
499 open(unit=ientin,file=nazwa,status='old',err=1111)
500 write(iout,*) "reading ",nazwa(:ilen(nazwa))
502 call xread(nazwa,ii,jj,kk,ll,mm,iR,ib,iparm)
505 IF (NFILE_CX(iR,ib,iparm).gt.0) THEN
506 c Read conformations from cx files and write them to a binary
508 do if=1,nfile_cx(iR,ib,iparm)
509 nazwa=protfiles(if,2,iR,ib,iparm)
510 & (:ilen(protfiles(if,2,iR,ib,iparm)))//".cx"
511 write(iout,*) "reading ",nazwa(:ilen(nazwa))
513 print *,"Calling cxread"
514 call cxread(nazwa,ii,jj,kk,ll,mm,iR,ib,iparm,
517 write (iout,*) "exit cxread"
523 stot(islice)=stot(islice)+jj(islice)
528 write (iout,*) "IPARM",iparm
531 if (nslice.eq.1) then
533 write (liczba,'(bz,i3.3)') me
534 bprotfile_temp = scratchdir(:ilen(scratchdir))//"/"//
535 & prefix(:ilen(prefix))//liczba//".xbin.tmp"
537 bprotfile_temp = scratchdir(:ilen(scratchdir))//
538 & "/"//prefix(:ilen(prefix))//".xbin.tmp"
540 write(iout,*) mm(1)," conformations read",ll(1),
541 & " conformations written to ",
542 & bprotfile_temp(:ilen(bprotfile_temp))
545 write (liczba1,'(bz,i2.2)') islice
547 write (liczba,'(bz,i3.3)') me
548 bprotfile_temp = scratchdir(:ilen(scratchdir))//"/"//
549 & prefix(:ilen(prefix))//liczba//".xbin.tmp"//liczba1
551 bprotfile_temp = scratchdir(:ilen(scratchdir))//
552 & "/"//prefix(:ilen(prefix))//".xbin.tmp"//liczba1
554 write(iout,*) mm(islice)," conformations read",ll(islice),
555 & " conformations written to ",
556 & bprotfile_temp(:ilen(bprotfile_temp))
561 c Check if everyone has the same number of conformations
563 c call MPI_ALLgather(MPI_IN_PLACE,stot(1),MPI_DATATYPE_NULL,
564 c & ntot_all(1,0),maxslice,MPI_INTEGER,MPI_Comm_World,IERROR)
566 maxslice_buff=maxslice
568 call MPI_Allgather(stot(1),maxslice_buff,MPI_INTEGER,
569 & ntot_all(1,0),maxslice,MPI_INTEGER,MPI_Comm_World,IERROR)
574 if (stot(islice).ne.ntot_all(islice,i)) then
575 write (iout,*) "Number of conformations at processor",i,
576 & " differs from that at processor",me,
577 & stot(islice),ntot_all(islice,i)," slice",islice
585 write (iout,*) "Numbers of conformations read by processors"
588 write (iout,'(8i10)') i,(ntot_all(islice,i),islice=1,nslice)
590 write (iout,*) "Calculation terminated."
595 ntot(islice)=stot(islice)
599 1111 write(iout,*) "Error opening coordinate file ",nazwa(:ilen(nazwa))
603 c------------------------------------------------------------------------------
604 subroutine card_concat(card,to_upper)
606 include 'DIMENSIONS.ZSCOPT'
607 include "COMMON.IOUNITS"
609 character*80 karta,ucase
613 read (inp,'(a)') karta
614 if (to_upper) karta=ucase(karta)
616 do while (karta(80:80).eq.'&')
617 card=card(:ilen(card)+1)//karta(:79)
618 read (inp,'(a)') karta
619 if (to_upper) karta=ucase(karta)
621 card=card(:ilen(card)+1)//karta
624 c------------------------------------------------------------------------------
625 subroutine readi(rekord,lancuch,wartosc,default)
627 character*(*) rekord,lancuch
628 integer wartosc,default
631 iread=index(rekord,lancuch(:ilen(lancuch))//"=")
636 iread=iread+ilen(lancuch)+1
637 read (rekord(iread:),*) wartosc
640 c----------------------------------------------------------------------------
641 subroutine reada(rekord,lancuch,wartosc,default)
643 character*(*) rekord,lancuch
645 double precision wartosc,default
648 iread=index(rekord,lancuch(:ilen(lancuch))//"=")
653 iread=iread+ilen(lancuch)+1
654 read (rekord(iread:),*) wartosc
657 c----------------------------------------------------------------------------
658 subroutine multreadi(rekord,lancuch,tablica,dim,default)
661 integer tablica(dim),default
662 character*(*) rekord,lancuch
669 iread=index(rekord,lancuch(:ilen(lancuch))//"=")
670 if (iread.eq.0) return
671 iread=iread+ilen(lancuch)+1
672 read (rekord(iread:),*,end=10,err=10) (tablica(i),i=1,dim)
675 c----------------------------------------------------------------------------
676 subroutine multreada(rekord,lancuch,tablica,dim,default)
679 double precision tablica(dim),default
680 character*(*) rekord,lancuch
687 iread=index(rekord,lancuch(:ilen(lancuch))//"=")
688 if (iread.eq.0) return
689 iread=iread+ilen(lancuch)+1
690 read (rekord(iread:),*,end=10,err=10) (tablica(i),i=1,dim)
693 c----------------------------------------------------------------------------
694 subroutine reads(rekord,lancuch,wartosc,default)
696 character*(*) rekord,lancuch,wartosc,default
698 integer ilen,lenlan,lenrec,iread,ireade
704 iread=index(rekord,lancuch(:lenlan)//"=")
705 c print *,"rekord",rekord," lancuch",lancuch
706 c print *,"iread",iread," lenlan",lenlan," lenrec",lenrec
712 c print *,"iread",iread
713 c print *,"|",rekord(iread:iread),"|",iblnk(rekord(iread:iread))
714 do while (iread.le.lenrec .and. iblnk(rekord(iread:iread)))
716 c print *,"|",rekord(iread:iread),"|",iblnk(rekord(iread:iread))
718 c print *,"iread",iread
719 if (iread.gt.lenrec) then
724 c print *,"ireade",ireade
725 do while (ireade.lt.lenrec .and.
726 & .not.iblnk(rekord(ireade:ireade)))
729 wartosc=rekord(iread:ireade)
732 c----------------------------------------------------------------------------
733 subroutine multreads(rekord,lancuch,tablica,dim,default)
736 character*(*) rekord,lancuch,tablica(dim),default
738 integer ilen,lenlan,lenrec,iread,ireade
747 iread=index(rekord,lancuch(:lenlan)//"=")
748 c print *,"rekord",rekord," lancuch",lancuch
749 c print *,"iread",iread," lenlan",lenlan," lenrec",lenrec
750 if (iread.eq.0) return
753 c print *,"iread",iread
754 c print *,"|",rekord(iread:iread),"|",iblnk(rekord(iread:iread))
755 do while (iread.le.lenrec .and. iblnk(rekord(iread:iread)))
757 c print *,"|",rekord(iread:iread),"|",iblnk(rekord(iread:iread))
759 c print *,"iread",iread
760 if (iread.gt.lenrec) return
762 c print *,"ireade",ireade
763 do while (ireade.lt.lenrec .and.
764 & .not.iblnk(rekord(ireade:ireade)))
767 tablica(i)=rekord(iread:ireade)
771 c----------------------------------------------------------------------------
772 subroutine split_string(rekord,tablica,dim,nsub)
774 integer dim,nsub,i,ii,ll,kk
775 character*(*) tablica(dim)
786 C Find the start of term name
788 do while (ii.le.ll .and. rekord(ii:ii).eq." ")
791 C Parse the name into TABLICA(i) until blank found
792 do while (ii.le.ll .and. rekord(ii:ii).ne." ")
794 tablica(i)(kk:kk)=rekord(ii:ii)
797 if (kk.gt.0) nsub=nsub+1
802 c--------------------------------------------------------------------------------
803 integer function iroof(n,m)
805 if (ii*m .lt. n) ii=ii+1