Changeset 2613 for branches/dev_r2586_dynamic_mem/NEMOGCM/NEMO/OPA_SRC/BDY
- Timestamp:
- 2011-02-25T11:45:57+01:00 (13 years ago)
- Location:
- branches/dev_r2586_dynamic_mem/NEMOGCM/NEMO/OPA_SRC/BDY
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/dev_r2586_dynamic_mem/NEMOGCM/NEMO/OPA_SRC/BDY/bdy_oce.F90
r2590 r2613 32 32 LOGICAL :: ln_vol = .false. !: =T volume correction 33 33 LOGICAL :: ln_mask = .false. !: =T read bdymask from file 34 LOGICAL :: ln_clim = .false. !: if true, we assume that bdy data files contain 35 ! ! 1 time dump (-->bdy forcing will be constant) 36 ! ! or 12 months (-->bdy forcing will be cyclic) 34 LOGICAL :: ln_clim = .false. !: =T bdy data files contain 1 time dump (-->bdy forcing will be constant) 35 ! ! or 12 months (-->bdy forcing will be cyclic) 37 36 LOGICAL :: ln_dyn_fla = .false. !: =T Flather boundary conditions on barotropic velocities 38 37 LOGICAL :: ln_dyn_frs = .false. !: =T FRS boundary conditions on velocities … … 40 39 LOGICAL :: ln_ice_frs = .false. !: =T FRS boundary conditions on seaice (leads fraction, ice depth, snow depth) 41 40 ! 42 INTEGER :: nn_rimwidth = 7 43 INTEGER :: nn_dtactl = 1 !: = 0 use the initial state as bdy dta or= 1 read it in a NetCDF file44 INTEGER :: nn_volctl = 1 45 ! 41 INTEGER :: nn_rimwidth = 7 !: boundary rim width 42 INTEGER :: nn_dtactl = 1 !: = 0 use the initial state as bdy dta ; = 1 read it in a NetCDF file 43 INTEGER :: nn_volctl = 1 !: = 0 the total volume will have the variability of the surface Flux E-P 44 ! ! = 1 the volume will be constant during all the integration. 46 45 47 46 !!---------------------------------------------------------------------- … … 63 62 INTEGER, DIMENSION(jpbdim,jpbgrd) :: nbmap !: Indices of data in file for data in memory 64 63 65 REAL(wp) :: bdysurftot !: Lateral surface of unstructured open boundary64 REAL(wp) :: bdysurftot !: Lateral surface of unstructured open boundary 66 65 67 66 REAL(wp), DIMENSION(jpbdim) :: flagu, flagv !: Flag for normal velocity compnt for velocity components … … 75 74 REAL(wp), DIMENSION(jpbdim) :: utide, vtide !: Tidal boundary array : U and V 76 75 #if defined key_lim2 77 REAL(wp), DIMENSION(jpbdim) :: &78 frld_bdy, hicif_bdy, & !: Now clim of ice leads fraction, ice79 hsnif_bdy !: thickness andsnow thickness76 REAL(wp), DIMENSION(jpbdim) :: frld_bdy !: now ice leads fraction climatology 77 REAL(wp), DIMENSION(jpbdim) :: hicif_bdy !: Now ice thickness climatology 78 REAL(wp), DIMENSION(jpbdim) :: hsnif_bdy !: now snow thickness 80 79 #endif 80 81 !!---------------------------------------------------------------------- 82 !! NEMO/OPA 4.0 , NEMO Consortium (2011) 83 !! $Id$ 84 !! Software governed by the CeCILL licence (NEMOGCM/NEMO_CeCILL.txt) 85 !!---------------------------------------------------------------------- 86 CONTAINS 87 88 FUNCTION bdy_oce_alloc() 89 !!---------------------------------------------------------------------- 90 INTEGER :: bdy_oce_alloc 91 !!---------------------------------------------------------------------- 92 ! 93 ALLOCATE( bdytmask(jpi,jpj) , tbdy(jpbdim,jpk) , sbdy(jpbdim,jpk) , & 94 & bdyumask(jpi,jpj) , ubdy(jpbdim,jpk) , & 95 & bdyvmask(jpi,jpj) , vbdy(jpbdim,jpk) , STAT=bdy_oce_alloc ) 96 ! 97 IF( lk_mpp ) CALL mpp_sum ( bdy_oce_alloc ) 98 IF( bdy_oce_alloc /= 0 ) CALL ctl_warn('bdy_oce_alloc: failed to allocate arrays.') 99 ! 100 END FUNCTION bdy_oce_alloc 81 101 82 102 #else … … 87 107 #endif 88 108 89 !!----------------------------------------------------------------------90 !! NEMO/OPA 3.3 , NEMO Consortium (2010)91 !! $Id$92 !! Software governed by the CeCILL licence (NEMOGCM/NEMO_CeCILL.txt)93 109 !!====================================================================== 94 #if defined key_bdy95 CONTAINS96 97 FUNCTION bdy_oce_alloc()98 INTEGER :: bdy_oce_alloc99 100 ALLOCATE(bdytmask(jpi,jpj), bdyumask(jpi,jpj), bdyvmask(jpi,jpj), &101 tbdy(jpbdim,jpk), sbdy(jpbdim,jpk), &102 ubdy(jpbdim,jpk), vbdy(jpbdim,jpk), &103 Stat=bdy_oce_alloc)104 105 IF(bdy_oce_alloc /= 0)THEN106 CALL ctl_warn('bdy_oce_alloc: failed to allocate arrays.')107 END IF108 109 END FUNCTION bdy_oce_alloc110 #endif111 112 110 END MODULE bdy_oce -
branches/dev_r2586_dynamic_mem/NEMOGCM/NEMO/OPA_SRC/BDY/bdyini.F90
r2528 r2613 33 33 34 34 !!---------------------------------------------------------------------- 35 !! NEMO/OPA 3.3 , NEMO Consortium (2010)35 !! NEMO/OPA 4.0 , NEMO Consortium (2011) 36 36 !! $Id$ 37 !! Software governed by the CeCILL licence (NEMOGCM/NEMO_CeCILL.txt)37 !! Software governed by the CeCILL licence (NEMOGCM/NEMO_CeCILL.txt) 38 38 !!---------------------------------------------------------------------- 39 39 CONTAINS … … 44 44 !! 45 45 !! ** Purpose : Initialization of the dynamics and tracer fields with 46 !! unstructured open boundaries.46 !! unstructured open boundaries. 47 47 !! 48 !! ** Method : Read initialization arrays (mask, indices) to identify49 !! 48 !! ** Method : Read initialization arrays (mask, indices) to identify 49 !! an unstructured open boundary 50 50 !! 51 51 !! ** Input : bdy_init.nc, input file for unstructured open boundaries 52 52 !!---------------------------------------------------------------------- 53 INTEGER :: ii, ij, ik, igrd, ib, ir ! dummy loop indices 54 INTEGER :: icount, icountr 55 INTEGER :: ib_len, ibr_max 56 INTEGER :: iw, ie, is, in 57 INTEGER :: inum ! local logical unit 58 INTEGER :: id_dummy ! local integers 59 INTEGER :: igrd_start, igrd_end ! start and end of loops on igrd 53 INTEGER :: ii, ij, ik, igrd, ib, ir ! dummy loop indices 54 INTEGER :: icount, icountr, ib_len, ibr_max ! local integers 55 INTEGER :: iw, ie, is, in, inum, id_dummy ! - - 56 INTEGER :: igrd_start, igrd_end ! - - 57 REAL(wp) :: zefl, zwfl, znfl, zsfl ! local scalars 60 58 INTEGER, DIMENSION (2) :: kdimsz 61 59 INTEGER, DIMENSION(jpbdta, jpbgrd) :: nbidta, nbjdta ! Index arrays: i and j indices of bdy dta 62 60 INTEGER, DIMENSION(jpbdta, jpbgrd) :: nbrdta ! Discrete distance from rim points 63 REAL(wp) :: zefl, zwfl, znfl, zsfl ! temporary scalars 64 REAL(wp) , DIMENSION(jpidta,jpjdta) :: zmask ! global domain mask 65 REAL(wp) , DIMENSION(jpbdta,1) :: zdta ! temporary array 66 CHARACTER(LEN=80),DIMENSION(6) :: clfile 61 REAL(wp), DIMENSION(jpidta,jpjdta) :: zmask ! global domain mask 62 REAL(wp), DIMENSION(jpbdta,1) :: zdta ! temporary array 63 CHARACTER(LEN=80),DIMENSION(6) :: clfile 67 64 !! 68 NAMELIST/nambdy/cn_mask, cn_dta_frs_T, cn_dta_frs_U, cn_dta_frs_V, 69 & cn_dta_fla_T, cn_dta_fla_U, cn_dta_fla_V, 70 & ln_tides, ln_clim, ln_vol, ln_mask, &71 & ln_dyn_fla, ln_dyn_frs, ln_tra_frs,ln_ice_frs, &65 NAMELIST/nambdy/cn_mask, cn_dta_frs_T, cn_dta_frs_U, cn_dta_frs_V, & 66 & cn_dta_fla_T, cn_dta_fla_U, cn_dta_fla_V, & 67 & ln_tides, ln_clim, ln_vol, ln_mask, & 68 & ln_dyn_fla, ln_dyn_frs, ln_tra_frs,ln_ice_frs, & 72 69 & nn_dtactl, nn_rimwidth, nn_volctl 73 70 !!---------------------------------------------------------------------- … … 77 74 IF(lwp) WRITE(numout,*) '~~~~~~~~' 78 75 ! 76 ! ! allocate bdy_oce arrays 77 IF( bdy_oce_alloc() /= 0 ) CALL ctl_stop( 'STOP', 'bdy_init : unable to allocate arrays' ) 78 79 79 IF( jperio /= 0 ) CALL ctl_stop( 'Cyclic or symmetric,', & 80 80 & ' and unstructured open boundary condition are not compatible' )
Note: See TracChangeset
for help on using the changeset viewer.