[7715] | 1 | MODULE usrdef_istate |
---|
| 2 | !!====================================================================== |
---|
| 3 | !! *** MODULE usrdef_istate *** |
---|
| 4 | !! |
---|
| 5 | !! === ISOMIP configuration === |
---|
| 6 | !! |
---|
| 7 | !! User defined : set the initial state of a user configuration |
---|
| 8 | !!====================================================================== |
---|
| 9 | !! History : NEMO ! 2016-11 (S. Flavoni) Original code |
---|
| 10 | !! ! 2017-02 (P. Mathiot, S. Flavoni) Adapt code to ISOMIP case |
---|
| 11 | !!---------------------------------------------------------------------- |
---|
| 12 | |
---|
| 13 | !!---------------------------------------------------------------------- |
---|
| 14 | !! usr_def_istate : initial state in Temperature and salinity |
---|
| 15 | !!---------------------------------------------------------------------- |
---|
| 16 | USE par_oce ! ocean space and time domain |
---|
| 17 | USE dom_oce , ONLY : glamt |
---|
| 18 | USE phycst ! physical constants |
---|
| 19 | ! |
---|
| 20 | USE in_out_manager ! I/O manager |
---|
| 21 | USE lib_mpp ! MPP library |
---|
| 22 | |
---|
| 23 | IMPLICIT NONE |
---|
| 24 | PRIVATE |
---|
| 25 | |
---|
| 26 | PUBLIC usr_def_istate ! called by istate.F90 |
---|
| 27 | |
---|
| 28 | !!---------------------------------------------------------------------- |
---|
[10073] | 29 | !! NEMO/OCE 4.0 , NEMO Consortium (2018) |
---|
[7715] | 30 | !! $Id$ |
---|
[10073] | 31 | !! Software governed by the CeCILL license (see ./LICENSE) |
---|
[7715] | 32 | !!---------------------------------------------------------------------- |
---|
| 33 | CONTAINS |
---|
| 34 | |
---|
| 35 | SUBROUTINE usr_def_istate( pdept, ptmask, pts, pu, pv, pssh ) |
---|
| 36 | !!---------------------------------------------------------------------- |
---|
| 37 | !! *** ROUTINE usr_def_istate *** |
---|
| 38 | !! |
---|
| 39 | !! ** Purpose : Initialization of the dynamics and tracers |
---|
| 40 | !! Here ISOMIP configuration |
---|
| 41 | !! |
---|
| 42 | !! ** Method : - set temperature field |
---|
| 43 | !! - set salinity field |
---|
| 44 | !!---------------------------------------------------------------------- |
---|
| 45 | REAL(wp), DIMENSION(jpi,jpj,jpk) , INTENT(in ) :: pdept ! depth of t-point [m] |
---|
| 46 | REAL(wp), DIMENSION(jpi,jpj,jpk) , INTENT(in ) :: ptmask ! t-point ocean mask [m] |
---|
| 47 | REAL(wp), DIMENSION(jpi,jpj,jpk,jpts), INTENT( out) :: pts ! T & S fields [Celsius ; g/kg] |
---|
| 48 | REAL(wp), DIMENSION(jpi,jpj,jpk) , INTENT( out) :: pu ! i-component of the velocity [m/s] |
---|
| 49 | REAL(wp), DIMENSION(jpi,jpj,jpk) , INTENT( out) :: pv ! j-component of the velocity [m/s] |
---|
| 50 | REAL(wp), DIMENSION(jpi,jpj) , INTENT( out) :: pssh ! sea-surface height |
---|
| 51 | ! |
---|
| 52 | INTEGER :: jk ! dummy loop indices |
---|
| 53 | !!---------------------------------------------------------------------- |
---|
| 54 | ! |
---|
| 55 | IF(lwp) WRITE(numout,*) |
---|
| 56 | IF(lwp) WRITE(numout,*) 'usr_def_istate : ISOMIP configuration, analytical definition of initial state' |
---|
| 57 | IF(lwp) WRITE(numout,*) '~~~~~~~~~~~~~~ Ocean at rest, with a constant salinity and temperature. ' |
---|
| 58 | pu (:,:,:) = 0._wp ! ocean at rest |
---|
| 59 | pv (:,:,:) = 0._wp |
---|
| 60 | pssh(:,:) = 0._wp |
---|
| 61 | ! |
---|
| 62 | ! ! T & S profiles |
---|
| 63 | pts(:,:,:,jp_tem) = - 1.9 * ptmask(:,:,:) ! ISOMIP configuration : start from constant T+S fields |
---|
| 64 | pts(:,:,:,jp_sal) = 34.4 * ptmask(:,:,:) |
---|
| 65 | ! |
---|
| 66 | END SUBROUTINE usr_def_istate |
---|
| 67 | |
---|
| 68 | !!====================================================================== |
---|
| 69 | END MODULE usrdef_istate |
---|