update_2d_bdy - update 2D boundaries every time step. (Source File: update_2d_bdy.F90)

INTERFACE:

    subroutine update_2d_bdy(loop,bdyramp)
DESCRIPTION:

In this routine sea surface elevation boundary conditions are read in from a file, interpolated to the actual time step, and distributed to the open boundary grid boxes. Only for a special test case (SYLT_TEST), ascii data reading is supported. For a few special simple cases, analytical calculation of boundary elevations is supported. The generic way is reading in boundary data from a netcdf file, which is managed in get_2d_bdy via get_2d_bdy_ncdf. USES:

    use domain, only: NWB,NNB,NEB,NSB,H,min_depth,imin,imax,jmin,jmax,az
    use domain, only: wi,wfj,wlj,nj,nfi,nli,ei,efj,elj,sj,sfi,sli
    use domain, only: bdy_index,nsbv
    use domain, only: bdy_2d_type
    use m2d, only: dtm,bdyfmt_2d,bdy_data,bdy_data_u,bdy_data_v
    use variables_2d, only: z,D,U,DU,V,DV
 #if defined(SPHERICAL) || defined(CURVILINEAR)
    use domain, only: dxc,dyc
 #else
    use domain, only: dx,dy
 #endif
    IMPLICIT NONE
INPUT PARAMETERS:
    integer, intent(in)                 :: loop,bdyramp
REVISION HISTORY:
    Original author(s): Karsten Bolding & Hans Burchard
LOCAL VARIABLES:
    logical, save             :: first=.true.
    REALTYPE, save            :: time_array(1000),zbo(1000),zbn(1000)
    REALTYPE, save            :: t,t1,t2
    REALTYPE                  :: a,ratio,fac
    integer                   :: i,j,k,l,n
    REALTYPE, parameter       :: FOUR=4.*_ONE_