[11637] | 1 | MODULE usrdef_zgr |
---|
| 2 | !!====================================================================== |
---|
[12629] | 3 | !! *** MODULE usrdef_zgr *** |
---|
[11637] | 4 | !! |
---|
| 5 | !! === STATION_ASF case === |
---|
| 6 | !! |
---|
[12629] | 7 | !! User defined : vertical coordinate system of a user configuration |
---|
[11637] | 8 | !!====================================================================== |
---|
[12629] | 9 | !! History : 4.0 ! 2016-06 (G. Madec) Original code |
---|
| 10 | !! 4.x ! 2019-10 (L. Brodeau) Station ASF |
---|
[11637] | 11 | !!---------------------------------------------------------------------- |
---|
| 12 | |
---|
| 13 | !!---------------------------------------------------------------------- |
---|
[12629] | 14 | !! usr_def_zgr : user defined vertical coordinate system |
---|
[14072] | 15 | !! zgr_z : reference 1D z-coordinate |
---|
[12629] | 16 | !! zgr_top_bot: ocean top and bottom level indices |
---|
| 17 | !! zgr_zco : 3D verticl coordinate in pure z-coordinate case |
---|
[11637] | 18 | !!--------------------------------------------------------------------- |
---|
| 19 | USE oce ! ocean variables |
---|
| 20 | USE usrdef_nam ! User defined : namelist variables |
---|
| 21 | ! |
---|
| 22 | USE in_out_manager ! I/O manager |
---|
| 23 | USE lbclnk ! ocean lateral boundary conditions (or mpp link) |
---|
| 24 | USE lib_mpp ! distributed memory computing library |
---|
| 25 | |
---|
| 26 | IMPLICIT NONE |
---|
| 27 | PRIVATE |
---|
| 28 | |
---|
[12629] | 29 | PUBLIC usr_def_zgr ! called by domzgr.F90 |
---|
[11637] | 30 | |
---|
| 31 | !!---------------------------------------------------------------------- |
---|
| 32 | !! NEMO/OCE 4.0 , NEMO Consortium (2018) |
---|
[14072] | 33 | !! $Id: usrdef_zgr.F90 13226 2020-07-02 14:24:31Z orioltp $ |
---|
[11637] | 34 | !! Software governed by the CeCILL license (see ./LICENSE) |
---|
| 35 | !!---------------------------------------------------------------------- |
---|
| 36 | CONTAINS |
---|
| 37 | |
---|
| 38 | SUBROUTINE usr_def_zgr( ld_zco , ld_zps , ld_sco , ld_isfcav, & ! type of vertical coordinate |
---|
| 39 | & pdept_1d, pdepw_1d, pe3t_1d , pe3w_1d , & ! 1D reference vertical coordinate |
---|
| 40 | & pdept , pdepw , & ! 3D t & w-points depth |
---|
| 41 | & pe3t , pe3u , pe3v , pe3f , & ! vertical scale factors |
---|
| 42 | & pe3w , pe3uw , pe3vw , & ! - - - |
---|
| 43 | & k_top , k_bot ) ! top & bottom ocean level |
---|
| 44 | !!--------------------------------------------------------------------- |
---|
| 45 | !! *** ROUTINE usr_def_zgr *** |
---|
| 46 | !! |
---|
| 47 | !! ** Purpose : User defined the vertical coordinates |
---|
| 48 | !! |
---|
| 49 | !!---------------------------------------------------------------------- |
---|
[12629] | 50 | LOGICAL , INTENT(out) :: ld_zco, ld_zps, ld_sco ! vertical coordinate flags |
---|
| 51 | LOGICAL , INTENT(out) :: ld_isfcav ! under iceshelf cavity flag |
---|
| 52 | REAL(wp), DIMENSION(:) , INTENT(out) :: pdept_1d, pdepw_1d ! 1D grid-point depth [m] |
---|
| 53 | REAL(wp), DIMENSION(:) , INTENT(out) :: pe3t_1d , pe3w_1d ! 1D grid-point depth [m] |
---|
| 54 | REAL(wp), DIMENSION(:,:,:), INTENT(out) :: pdept, pdepw ! grid-point depth [m] |
---|
| 55 | REAL(wp), DIMENSION(:,:,:), INTENT(out) :: pe3t , pe3u , pe3v , pe3f ! vertical scale factors [m] |
---|
[14072] | 56 | REAL(wp), DIMENSION(:,:,:), INTENT(out) :: pe3w , pe3uw, pe3vw ! i-scale factors |
---|
[12629] | 57 | INTEGER , DIMENSION(:,:) , INTENT(out) :: k_top, k_bot ! first & last ocean level |
---|
[11637] | 58 | !!---------------------------------------------------------------------- |
---|
| 59 | ! |
---|
| 60 | IF(lwp) WRITE(numout,*) |
---|
[12038] | 61 | IF(lwp) WRITE(numout,*) 'usr_def_zgr : STATION_ASF configuration, setting first level properties.' |
---|
[11637] | 62 | IF(lwp) WRITE(numout,*) '~~~~~~~~~~~' |
---|
| 63 | ! |
---|
[12629] | 64 | ! |
---|
| 65 | ! type of vertical coordinate |
---|
| 66 | ! --------------------------- |
---|
[11637] | 67 | ld_zco = .TRUE. ! z-coordinate without ocean cavities |
---|
| 68 | ld_zps = .FALSE. |
---|
| 69 | ld_sco = .FALSE. |
---|
| 70 | ld_isfcav = .FALSE. |
---|
[12629] | 71 | |
---|
| 72 | !! 1st level (the only one that matters) |
---|
[11637] | 73 | pdept_1d(1) = rn_dept1 ! depth (m) at which the SST is taken/measured == depth of first T point! |
---|
| 74 | pdepw_1d(1) = 0._wp |
---|
| 75 | pe3t_1d(1) = 2._wp*rn_dept1 |
---|
| 76 | pe3w_1d(1) = rn_dept1 ! LB??? |
---|
| 77 | |
---|
[12629] | 78 | pdept(:,:,1) = rn_dept1 |
---|
| 79 | pdepw(:,:,1) = 0._wp |
---|
| 80 | pe3t(:,:,1) = 2._wp*rn_dept1 |
---|
| 81 | pe3u(:,:,1) = 2._wp*rn_dept1 |
---|
| 82 | pe3v(:,:,1) = 2._wp*rn_dept1 |
---|
| 83 | pe3f(:,:,1) = 2._wp*rn_dept1 |
---|
| 84 | pe3w(:,:,1) = rn_dept1 ! LB??? |
---|
| 85 | pe3uw(:,:,1) = rn_dept1 ! LB??? |
---|
| 86 | pe3vw(:,:,1) = rn_dept1 ! LB??? |
---|
[14072] | 87 | |
---|
[12629] | 88 | !! 2nd level, technically useless (only for the sake of code stability) |
---|
| 89 | pdept_1d(2) = 3._wp*rn_dept1 |
---|
| 90 | pdepw_1d(2) = 2._wp*rn_dept1 |
---|
| 91 | pe3t_1d(2) = 2._wp*rn_dept1 |
---|
| 92 | pe3w_1d(2) = 2._wp*rn_dept1 |
---|
| 93 | |
---|
| 94 | pdept(:,:,2) = 3._wp*rn_dept1 |
---|
| 95 | pdepw(:,:,2) = 2._wp*rn_dept1 |
---|
| 96 | pe3t(:,:,2) = 2._wp*rn_dept1 |
---|
| 97 | pe3u(:,:,2) = 2._wp*rn_dept1 |
---|
| 98 | pe3v(:,:,2) = 2._wp*rn_dept1 |
---|
| 99 | pe3f(:,:,2) = 2._wp*rn_dept1 |
---|
| 100 | pe3w(:,:,2) = 2._wp*rn_dept1 |
---|
| 101 | pe3uw(:,:,2) = 2._wp*rn_dept1 |
---|
| 102 | pe3vw(:,:,2) = 2._wp*rn_dept1 |
---|
| 103 | |
---|
[11637] | 104 | k_top = 1 |
---|
| 105 | k_bot = 1 |
---|
[12629] | 106 | |
---|
[11637] | 107 | END SUBROUTINE usr_def_zgr |
---|
| 108 | !!====================================================================== |
---|
| 109 | END MODULE usrdef_zgr |
---|