anchor.diff:              end if
             end do
           end if
  -      end do
  +        do j=1,nwsets
  +          if(ibcfac.eq.iwcode(j)) then
  +            area=acomp(x,ibcvert,nsd,numnp,iwdir(j))
  +            do k=1,3
  +              iwbcnode(ibcvert(k),j)=ibcfac
  +              wink(ibcvert(k),j)=wink(ibcvert(k),j)+
  +     &         area*rhow(j)*gw(j)/3.0d0
  +            end do
  +          end if
  +        end do
  +      end do
  +      close(kr)
         nfltnodes=0
         do i=1,numnp
           if(ifltnode(i).eq.1) then
  
positive.code:         read(kr,*) (fsplit(j,1,i),j=1,nsd),(ifmat(1,i,j),j=1,nmatf(1,i))
          call pskip(kr)
          read(kr,*) (fsplit(j,2,i),j=1,nsd),(ifmat(2,i,j),j=1,nmatf(2,i))
        end do
        close(kr)
  c
  
negative.code: c
  c...  external routines
  c
        double precision tetcmp,acomp
        integer nnblnk,nchar
        external nnblnk,nchar,tetcmp,acomp
  c
  c...  local variables
  c
        double precision det,sgn,xl(nsd,nen),xtmp(nsd),wout(3)
        double precision wink(maxnodes,maxwsets),area
        integer iadjf(maxflts*maxfnodes,maxnbrs),inodef(maxflts*maxfnodes)
        integer ientmp(nen),nelsf(maxflts*maxfnodes),ifltnode(maxnodes)
        integer ifhist(maxflts),idir(nsd),ibcnode(maxnodes,maxbnds)
        integer iwbcnode(maxnodes,maxwsets),iwout(3)
        integer i,j,k,l,jj,i1,i2,j1,j2,nenl,nsdl,nfltnodes,kk
        integer iel,nflip
        character cstring*15,cbound(maxbnds)*3,cwink(maxwsets)*3,cfnum*2
        data cstring/"coord_units = m"/
        data cbound/
       & "b01","b02","b03","b04","b05","b06","b07","b08","b09","b10",
       & "b11","b12","b13","b14","b15","b16","b17","b18","b19","b20",
       & "b21","b22","b23","b24","b25","b26","b27","b28","b29","b30"/
        data cwink/"w01","w02"/
  c
        nenl=nen
        nsdl=nsd
  