anchor.diff:  ! . iNew is iApeUp
     lApeUp=iApeUp.eq.iNew.and.ixApeUp.eq.ixNew
   
  -! . iNew is at the same s as iApeUp (inlcuding ring overvlow)
  -  lAupDcum=abs(dcum(iNew)-dcum(iApeUp)).lt.sPrec.or.abs(dcum(iNew)-dcum(iApeUp)-tlen).lt.sPrec
  +! . iNew is at the same s as iApeUp (inlcuding ring overflow)
  +  lAupDcum=abs(dcum(iNew)-dcum(iApeUp)).lt.sPrec.or.abs(dcum(iNew)-dcum(iApeUp)-dcum(iu)).lt.sPrec
   
   ! . iNew is iApeDw
     lApeDw=iApeDw.eq.iNew.and.ixApeDw.eq.ixNew
   
  -! . iNew is at the same s as ApeDw (inlcuding ring overvlow)
  -  lAdwDcum=abs(dcum(iNew)-dcum(iApeDw)).lt.sPrec.or.abs(dcum(iNew)-dcum(iApeDw)-tlen).lt.sPrec
  +! . iNew is at the same s as ApeDw (inlcuding ring overflow)
  +  lAdwDcum=abs(dcum(iNew)-dcum(iApeDw)).lt.sPrec.or.abs(dcum(iNew)-dcum(iApeDw)-dcum(iu)).lt.sPrec
   
   ! . constant aperture?
     lconst = sameAperture( ixApeUp, ixApeDw )
  
positive.code: 
      ! - pay attention to overflow:
      if( length .lt. zero ) then
        length = length+tlen
      end if
  
      ! - pay attention to too short thick elements
  
negative.code: 
       ! actual interpolation
       ddcum = spos-dcum(iUp)
       if( ddcum.lt.zero ) ddcum=dcum(iu)+ddcum
       mdcum = dcum(iDw)-dcum(iUp)
       if( mdcum.lt.zero ) mdcum=dcum(iu)+mdcum
       do jj=1,9
          oApe(jj)=((ape(jj,ixDw)-ape(jj,ixUp))/mdcum)*ddcum+ape(jj,ixUp)
       end do
  