1 SUBROUTINE CLUST(iwl,gamthr)
4 C GLASS CLUSTERS SEARCH
10 include 'comwlgen.for'
12 integer mark(nglal),icl(ialw)
17 c write (*,*) ' nwall ',nwall
18 if(iwl.gt.0.and.iwl.le.nwall) then
26 c call wlf(wl,ng,mgl(ip+1),egl(ip+1))
34 c write (*,*) ' m,e ',m,e
35 if(icl(m).eq.0.and.e.gt.gamthr) then
38 write (*,*) ' max cluster err !!! ',nmxcl
43 co write (*,*) ' new cluster ',nc,ipcl
51 co write (*,*) ' neib? #,m,icl',k1-ip,mgl(k1),icl(mgl(k1))
52 IF(MARK(K1).NE.0) GOTO 2
54 IF(ICL(M1).NE.NC) GOTO 2
55 co write (*,*) ' search ns,wl',ns(m1),wl(m1)
58 co write (*,*) ' sosed ',l,m1s,wl(m1s)
59 IF(WL(M1S).NE.0..AND.ICL(M1S).EQ.0) THEN
66 if(ipcl.eq.nglal) then
67 write (*,*) ' over cluster buff !!! ',ipcl
111 SUBROUTINE cCLUST(iwl)
115 include 'comalwl.for'
116 include 'comwlgen.for'
118 real xt(3),xmi(3),xma(3)
122 if(iwl.gt.0.and.iwl.le.nwall) then
135 ipgcc=ipclst(i+ipwcc)
139 call ucopy(x(1,mclst(ipgcc+1)),xmi,3)
140 call ucopy(x(1,mclst(ipgcc+1)),xma,3)
142 c new glass in cluster
150 if(xmi(1).gt.x(1,mgc)) xmi(1)=x(1,mgc)
151 if(xmi(2).gt.x(2,mgc)) xmi(2)=x(2,mgc)
152 if(xmi(3).gt.x(3,mgc)) xmi(3)=x(3,mgc)
153 if(xma(1).lt.x(1,mgc)) xma(1)=x(1,mgc)
154 if(xma(2).lt.x(2,mgc)) xma(2)=x(2,mgc)
155 if(xma(3).lt.x(3,mgc)) xma(3)=x(3,mgc)
157 xt(1)=xt(1)+x(1,mgc)*egc
158 xt(2)=xt(2)+x(2,mgc)*egc
159 xt(3)=xt(3)+x(3,mgc)*egc
161 c end glass in cluster
164 write (*,*) ' error!! energy cluster=0 '
165 write (*,*) ' wall,nc,lc,ipgcc ',iw,i,lc,ipgcc
175 call ucopy(xt,xavck(1,i,iw),3)
176 call ucopy(xmi,xmick(1,i,iw),3)
177 call ucopy(xma,xmack(1,i,iw),3)