SUBROUTINE zero3(array,lx)
  !
  ! $Author: CPTEC $
  ! $Date: 2000/02/24 13:15:43 $
  ! $Revision: 1.0 $
  !
  !
  !$$$  subprogram documentation block
  !                .      .    .     
  ! subprogram:    zero3       zero out out-of-bounds edges for 3-d array
  !   prgrmmr: black           org: w/np2      date: 96-03-28       
  !     
  ! abstract:
  !     set the values of the artificial external (out-of-bounds) edges
  !     to zero for a 3-d array
  !
  ! program history log:
  !   96-03-28  black      - originator
  !     
  ! usage: call zero2 from any routine needing this procedure
  !   input argument list:
  !       the dummy array name,vertical dimension
  !  
  !   output argument list: 
  !     the dummy array name
  !     
  !   output files:
  !     none
  !     
  !   subprograms called:
  !  
  !     unique: none
  !  
  !     library: none
  !  
  !
  IMPLICIT NONE
  INCLUDE "parmeta.f90"
  INTEGER, INTENT(IN) :: lx
  REAL, DIMENSION(0:im+1,0:jm+1,lx), INTENT(OUT) :: array
  INTEGER :: l, j, i
  DO l=1,lx
     DO j=0,jm+1
        DO i=0,im+1
           array(i,j,l)=0.
        ENDDO
     ENDDO
  END DO
END SUBROUTINE zero3
