25 subroutine smartbis(badpts,npts,cutoff,numptc,nclust,
26 1 lbase,intcorn,idim,jdim)
32 implicit double precision (a-h,o-z)
37 dimension iscr(idim), jscr(jdim)
38 integer nclust, numptc(
maxcl)
53 100
format(
' starting smart bisection with ',i5,
' clusters')
59 10
call moment(intcorn(1,icl),badpts(1,ist),numptc(icl),usenew)
61 101
format(
' testing cluster ',i8,
' with ',i9,
' pts. use ',e12.4)
63 if (usenew .lt. cutoff)
go to 20
68 write(
outunit,102) icl,numptc(icl),usenew
69 102
format(
' accepting smart bisected cluster',i4,
' with ',i5,
70 1
' pts. use = ',e10.3)
72 if (icl .gt. nclust)
go to 200
74 iend = ist + numptc(icl) - 1
79 20
if (nclust .lt.
maxcl)
go to 25
82 900
format(
' too many clusters: > ',i5)
88 call signs(badpts,npts,iscr,jscr,idim,jdim,
89 & ist,iend,ilo,ihi,jlo,jhi)
90 call findcut(icl,iscr,jscr,idim,jdim,index,iside,
92 if (index .eq. 0)
then 113 if (icl .gt. nclust)
go to 200
115 iend = ist + numptc(icl) - 1
131 50
if (badpts(idir,i) .lt. fmid)
go to 60
136 if (itop+1 .ge. ibot)
go to 80
144 temp = badpts(1,ibot)
145 badpts(1,ibot) = badpts(1,i)
147 temp = badpts(2,ibot)
148 badpts(2,ibot) = badpts(2,i)
150 if (itop+1 .lt. ibot)
go to 50
154 80 numptc(icl) = itop - ist + 1
159 if (ibump .gt. nclust)
go to 120
160 do 90 ico = ibump, nclust
161 nmove = nclust - ico + ibump
162 90 numptc(nmove + 1) = numptc(nmove)
164 120 numptc(ibump) = iend - ibot + 1
integer, parameter maxcl
maximum number of clusters (grids) on each grid level
integer, parameter vertical
subroutine moment(intrect, badpts, npt, usage)
Compute enclosing rectangle around flagged points.
subroutine findcut(icl, iscr, jscr, idim, jdim, index, iside,
Find best place to split the 2D array of flagged points.
integer, parameter outunit
subroutine smartbis(badpts, npts, cutoff, numptc, nclust, lbase, intcorn, idim, jdim)
Smart bisect rectangles until cutoff reached for each.
subroutine signs(badpts, npts, iscr, jscr, idim, jdim, ist, iend,
Compute signatures of a rectangle Signature is defined as number of flagged cells in each row/column...
The module contains the definition of a "node descriptor" as well as other global variables used duri...