!&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
      subroutine bocovs(vs,lsd)
!     ******************************************************************
!     *                                                                *
!     *   Scalar boundary conditions for wind-points                   *
!     *                                                                *
!     ******************************************************************

      include 'param_o.h'

!-----------------------------------------------------------------------
      integer::lsd
!-----------------------------------------------------------------------
      real, dimension(0:im+1,0:jm+1,nm,lsd)::  vs
!-----------------------------------------------------------------------   
      do n=1,4
        nl = n-1+4*((5-n)/4)
        nr = n+1-4*(n/4)
          do j=1,jm1
            vs(0 , j, n,:) = vs(im1, j, nl,:)
            vs(im, j, n,:) = vs(1  , j, nr,:)
          end do
      end do

      do i=1,im1
       imi = im-i
       jmi = jm-i
        vs(i,jm,1,:) = vs(i  ,1  ,5,:) 
        vs(i,jm,2,:) = vs(im1,i  ,5,:) 
        vs(i,jm,3,:) = vs(imi,jm1,5,:) 
        vs(i,jm,4,:) = vs(1  ,jmi,5,:) 
        vs(i,0, 1,:) = vs(i  ,jm1,6,:) 
        vs(i,0, 2,:) = vs(im1,jmi,6,:) 
        vs(i,0, 3,:) = vs(imi,1  ,6,:) 
        vs(i,0, 4,:) = vs(1  ,i  ,6,:) 
      end do

      do i=1,im1
       imi = im-i
       jmi = jm-i
        vs( i, 0, 5,:) = vs(i  ,jm1, 1,:)
        vs(im, i, 5,:) = vs(i  ,jm1, 2,:)
        vs(i ,jm, 5,:) = vs(imi,jm1, 3,:)
        vs(0 , i, 5,:) = vs(imi,jm1, 4,:)
        vs( i, 0, 6,:) = vs(imi,1, 3,:)
        vs(im, i, 6,:) = vs(imi,1, 2,:)
        vs(i ,jm, 6,:) = vs(i  ,1, 1,:)
        vs(0 , i, 6,:) = vs(i  ,1, 4,:)
      end do
!-----------------------------------------------------------------------
      end subroutine bocovs
