anchor.diff:  
     do nit = 1, maxits
       ! norm_old = norm
  -    norm=0.d0
  -    do i=1, nx
  -      do j=1, ny
  +    norm = 0.d0
  +    do i = 1, nx
  +      do j = 1, ny
           res(i,j) = &
               a(1,i,j)*etanew(i+1,j) &
               + a(2,i,j)*etanew(i,j+1) &
  
positive.code:   ! using n-layer physics it is constrained to balance the layers
    ! above it.
    if (RedGrav) then
      do j=1, ny
        do i=1, nx
          dhdt_GM(i,j,layers) = &
              ah(layers)*(h(i+1,j,layers)*wetmask(i+1,j)   &
                + (1d0 - wetmask(i+1,j))*h(i,j,layers)     & ! boundary
  
negative.code:   zeta = 0d0
  
    do k = 1, layers
      do j = 1, ny+1
        do i = 1, nx+1
          zeta(i,j,k) = (v(i,j,k)-v(i-1,j,k))/dx-(u(i,j,k)-u(i,j-1,k))/dy
        end do
      end do
    end do
  