[5790] | 1 | MODULE iscplini |
---|
| 2 | !!====================================================================== |
---|
[7646] | 3 | !! *** MODULE sbciscpl *** |
---|
[9168] | 4 | !! Ocean forcing: ????? |
---|
[5790] | 5 | !!===================================================================== |
---|
| 6 | !! History : NEMO ! 2015-01 P. Mathiot: original |
---|
| 7 | !!---------------------------------------------------------------------- |
---|
| 8 | |
---|
| 9 | !!---------------------------------------------------------------------- |
---|
[5835] | 10 | !! iscpl_init : initialisation routine (namelist) |
---|
| 11 | !! iscpl_alloc : allocation of correction variables |
---|
[5790] | 12 | !!---------------------------------------------------------------------- |
---|
[9019] | 13 | USE oce ! global tra/dyn variable |
---|
[5790] | 14 | USE dom_oce ! ocean space and time domain |
---|
[9019] | 15 | ! |
---|
[5790] | 16 | USE lib_mpp ! MPP library |
---|
| 17 | USE lib_fortran ! MPP library |
---|
[5823] | 18 | USE in_out_manager ! I/O manager |
---|
[5790] | 19 | |
---|
| 20 | IMPLICIT NONE |
---|
| 21 | PRIVATE |
---|
| 22 | |
---|
| 23 | PUBLIC iscpl_init |
---|
| 24 | PUBLIC iscpl_alloc |
---|
[9168] | 25 | ! !!* namsbc_iscpl namelist * |
---|
[11395] | 26 | LOGICAL , PUBLIC :: ln_iscpl_hsb !: |
---|
[9168] | 27 | INTEGER , PUBLIC :: nn_fiscpl !: |
---|
| 28 | INTEGER , PUBLIC :: nn_drown !: |
---|
[11395] | 29 | ! |
---|
[9168] | 30 | INTEGER , PUBLIC :: nstp_iscpl !: |
---|
| 31 | REAL(wp), PUBLIC :: rdt_iscpl !: |
---|
| 32 | ! |
---|
| 33 | REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:,:) :: hdiv_iscpl !: |
---|
| 34 | REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:,:,:) :: htsc_iscpl !: |
---|
| 35 | |
---|
[5790] | 36 | !!---------------------------------------------------------------------- |
---|
[9598] | 37 | !! NEMO/OCE 4.0 , NEMO Consortium (2018) |
---|
[10068] | 38 | !! $Id$ |
---|
| 39 | !! Software governed by the CeCILL license (see ./LICENSE) |
---|
[5790] | 40 | !!---------------------------------------------------------------------- |
---|
| 41 | CONTAINS |
---|
| 42 | |
---|
| 43 | INTEGER FUNCTION iscpl_alloc() |
---|
| 44 | !!---------------------------------------------------------------------- |
---|
| 45 | !! *** ROUTINE sbc_iscpl_alloc *** |
---|
| 46 | !!---------------------------------------------------------------------- |
---|
| 47 | ALLOCATE( htsc_iscpl(jpi,jpj,jpk,jpts) , hdiv_iscpl(jpi,jpj,jpk) , STAT=iscpl_alloc ) |
---|
| 48 | ! |
---|
[10425] | 49 | CALL mpp_sum ( 'iscplini', iscpl_alloc ) |
---|
[5790] | 50 | IF( iscpl_alloc > 0 ) CALL ctl_warn('iscpl_alloc: allocation of arrays failed') |
---|
| 51 | END FUNCTION iscpl_alloc |
---|
| 52 | |
---|
[9019] | 53 | |
---|
[5790] | 54 | SUBROUTINE iscpl_init() |
---|
[9019] | 55 | !!---------------------------------------------------------------------- |
---|
[9168] | 56 | !!---------------------------------------------------------------------- |
---|
[5790] | 57 | INTEGER :: ios ! Local integer output status for namelist read |
---|
[11395] | 58 | NAMELIST/namsbc_iscpl/ nn_fiscpl, ln_iscpl_hsb, nn_drown |
---|
[5790] | 59 | !!---------------------------------------------------------------------- |
---|
| 60 | ! |
---|
[5920] | 61 | nn_fiscpl = 0 |
---|
[11395] | 62 | ln_iscpl_hsb = .FALSE. |
---|
[5790] | 63 | REWIND( numnam_ref ) ! Namelist namsbc_iscpl in reference namelist : Ice sheet coupling |
---|
| 64 | READ ( numnam_ref, namsbc_iscpl, IOSTAT = ios, ERR = 901) |
---|
[9168] | 65 | 901 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namsbc_iscpl in reference namelist', lwp ) |
---|
[5790] | 66 | REWIND( numnam_cfg ) ! Namelist namsbc_iscpl in configuration namelist : Ice Sheet coupling |
---|
| 67 | READ ( numnam_cfg, namsbc_iscpl, IOSTAT = ios, ERR = 902 ) |
---|
[9168] | 68 | 902 IF( ios > 0 ) CALL ctl_nam ( ios , 'namsbc_iscpl in configuration namelist', lwp ) |
---|
[5790] | 69 | IF(lwm) WRITE ( numond, namsbc_iscpl ) |
---|
| 70 | ! |
---|
[9168] | 71 | nstp_iscpl=MIN( nn_fiscpl, nitend-nit000+1 ) ! the coupling period have to be less or egal than the total number of time step |
---|
[5920] | 72 | rdt_iscpl = nstp_iscpl * rn_rdt |
---|
[5790] | 73 | ! |
---|
| 74 | IF (lwp) THEN |
---|
| 75 | WRITE(numout,*) 'iscpl_rst:' |
---|
| 76 | WRITE(numout,*) '~~~~~~~~~' |
---|
[11395] | 77 | WRITE(numout,*) ' coupling flag (ln_iscpl ) = ', ln_iscpl |
---|
| 78 | WRITE(numout,*) ' conservation flag (ln_iscpl_hsb) = ', ln_iscpl_hsb |
---|
| 79 | WRITE(numout,*) ' nb of stp for cons (rn_fiscpl ) = ', nstp_iscpl |
---|
[5920] | 80 | IF (nstp_iscpl .NE. nn_fiscpl) WRITE(numout,*) 'W A R N I N G: nb of stp for cons has been modified & |
---|
| 81 | & (larger than run length)' |
---|
| 82 | WRITE(numout,*) ' coupling time step = ', rdt_iscpl |
---|
| 83 | WRITE(numout,*) ' number of call of the extrapolation loop = ', nn_drown |
---|
[9019] | 84 | ENDIF |
---|
| 85 | ! |
---|
[5790] | 86 | END SUBROUTINE iscpl_init |
---|
| 87 | |
---|
[9019] | 88 | !!====================================================================== |
---|
[5790] | 89 | END MODULE iscplini |
---|