--- DarthVader/TrackerLevel2/src/F77/reductionflight.f 2007/05/24 16:45:48 1.20 +++ DarthVader/TrackerLevel2/src/F77/reductionflight.f 2007/08/07 13:56:29 1.21 @@ -454,7 +454,7 @@ c------------------------------------------------------------------------ if( (rmax-lmax+1).ge.nclstrp )goto 210 !exits inclusion loop - if(rstop.eq.0) then !if right cluster morder has not been reached + if(rstop.eq.0) then !if right cluster border has not been reached if(value(ir).gt.clinclcut(ir)) then rmax=ir !include a strip on the right else @@ -464,7 +464,7 @@ if( (rmax-lmax+1).ge.nclstrp )goto 210 !exits inclusion loop - if(lstop.eq.0) then !if left cluster morder has not been reached + if(lstop.eq.0) then !if left cluster border has not been reached if(value(il).gt.clinclcut(il)) then lmax=il !include a strip on the left else @@ -472,6 +472,8 @@ endif endif +c if( (rmax-lmax+1).ge.nclstrp )goto 210 !exits inclusion loop + enddo !ends strip inclusion loop goto 211 210 continue !jumps here if more than nclstrp have been included @@ -492,6 +494,20 @@ rmax = rmax+1 if( (rmax-lmax+1).gt.nclstrp )lmax=lmax+1 endif +c------------------------------------------------------------------------------- +c adjust the cluster in order to have at least ANOTHER strip around the seed +c------------------------------------------------------------------------------- +c$$$ if(iseed-1.eq.lmax.and.lmax.ne.first)then +c$$$ lmax = lmax-1 +c$$$ if( (rmax-lmax+1).gt.nclstrp )rmax=rmax-1 +c$$$ endif +c$$$ if(iseed+1.eq.rmax.and.rmax.ne.last )then +c$$$ rmax = rmax+1 +c$$$ if( (rmax-lmax+1).gt.nclstrp )lmax=lmax+1 +c$$$ endif +c--------------------------------------------------- +c now we have 5 stored-strips around the maximum +c--------------------------------------------------- c------------------------------------------------------------------------ c adjust the cluster in order to store a minimum number of strips