Newer
Older
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
CALL iom_rstput( kt, nitrst, numrow, 'e3t_b', e3t(:,:,:,Kbb) )
CALL iom_rstput( kt, nitrst, numrow, 'e3t_n', e3t(:,:,:,Kmm) )
! ! ----------------------- !
IF( ln_vvl_ztilde .OR. ln_vvl_layer ) THEN ! z_tilde and layer cases !
! ! ----------------------- !
CALL iom_rstput( kt, nitrst, numrow, 'tilde_e3t_b', tilde_e3t_b(:,:,:))
CALL iom_rstput( kt, nitrst, numrow, 'tilde_e3t_n', tilde_e3t_n(:,:,:))
END IF
! ! -------------!
IF( ln_vvl_ztilde ) THEN ! z_tilde case !
! ! ------------ !
CALL iom_rstput( kt, nitrst, numrow, 'hdiv_lf', hdiv_lf(:,:,:))
ENDIF
!
ENDIF
!
END SUBROUTINE dom_vvl_rst
SUBROUTINE dom_vvl_ctl
!!---------------------------------------------------------------------
!! *** ROUTINE dom_vvl_ctl ***
!!
!! ** Purpose : Control the consistency between namelist options
!! for vertical coordinate
!!----------------------------------------------------------------------
INTEGER :: ioptio, ios
!!
NAMELIST/nam_vvl/ ln_vvl_zstar, ln_vvl_ztilde, ln_vvl_layer, ln_vvl_ztilde_as_zstar, &
& ln_vvl_zstar_at_eqtor , rn_ahe3 , rn_rst_e3t , &
& rn_lf_cutoff , rn_zdef_max , ln_vvl_dbg , & ! not yet implemented: ln_vvl_kepe
& nn_vvl_interp
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
!!----------------------------------------------------------------------
!
READ ( numnam_ref, nam_vvl, IOSTAT = ios, ERR = 901)
901 IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_vvl in reference namelist' )
READ ( numnam_cfg, nam_vvl, IOSTAT = ios, ERR = 902 )
902 IF( ios > 0 ) CALL ctl_nam ( ios , 'nam_vvl in configuration namelist' )
IF(lwm) WRITE ( numond, nam_vvl )
!
IF(lwp) THEN ! Namelist print
WRITE(numout,*)
WRITE(numout,*) 'dom_vvl_ctl : choice/control of the variable vertical coordinate'
WRITE(numout,*) '~~~~~~~~~~~'
WRITE(numout,*) ' Namelist nam_vvl : chose a vertical coordinate'
WRITE(numout,*) ' zstar ln_vvl_zstar = ', ln_vvl_zstar
WRITE(numout,*) ' ztilde ln_vvl_ztilde = ', ln_vvl_ztilde
WRITE(numout,*) ' layer ln_vvl_layer = ', ln_vvl_layer
WRITE(numout,*) ' ztilde as zstar ln_vvl_ztilde_as_zstar = ', ln_vvl_ztilde_as_zstar
WRITE(numout,*) ' ztilde near the equator ln_vvl_zstar_at_eqtor = ', ln_vvl_zstar_at_eqtor
WRITE(numout,*) ' !'
WRITE(numout,*) ' thickness diffusion coefficient rn_ahe3 = ', rn_ahe3
WRITE(numout,*) ' maximum e3t deformation fractional change rn_zdef_max = ', rn_zdef_max
IF( ln_vvl_ztilde_as_zstar ) THEN
WRITE(numout,*) ' ztilde running in zstar emulation mode (ln_vvl_ztilde_as_zstar=T) '
WRITE(numout,*) ' ignoring namelist timescale parameters and using:'
WRITE(numout,*) ' hard-wired : z-tilde to zstar restoration timescale (days)'
WRITE(numout,*) ' rn_rst_e3t = 0.e0'
WRITE(numout,*) ' hard-wired : z-tilde cutoff frequency of low-pass filter (days)'
WRITE(numout,*) ' rn_lf_cutoff = 1.0/rn_Dt'
ELSE
WRITE(numout,*) ' z-tilde to zstar restoration timescale (days) rn_rst_e3t = ', rn_rst_e3t
WRITE(numout,*) ' z-tilde cutoff frequency of low-pass filter (days) rn_lf_cutoff = ', rn_lf_cutoff
ENDIF
WRITE(numout,*) ' debug prints flag ln_vvl_dbg = ', ln_vvl_dbg
WRITE(numout,*) ' Method to compute scale factors anomaly at U/V/F points nn_vvl_interp = ', nn_vvl_interp
ENDIF
!
ioptio = 0 ! Parameter control
IF( ln_vvl_ztilde_as_zstar ) ln_vvl_ztilde = .true.
IF( ln_vvl_zstar ) ioptio = ioptio + 1
IF( ln_vvl_ztilde ) ioptio = ioptio + 1
IF( ln_vvl_layer ) ioptio = ioptio + 1
!
IF( ioptio /= 1 ) CALL ctl_stop( 'Choose ONE vertical coordinate in namelist nam_vvl' )
!
IF( .NOT. ln_vvl_zstar .AND. (nn_vvl_interp==2 ) ) CALL ctl_stop( 'nn_vvl_interp must be < 2 if ln_vvl_zstar=F' )
!
IF(lwp) THEN ! Print the choice
WRITE(numout,*)
IF( ln_vvl_zstar ) WRITE(numout,*) ' ==>>> zstar vertical coordinate is used'
IF( ln_vvl_ztilde ) WRITE(numout,*) ' ==>>> ztilde vertical coordinate is used'
IF( ln_vvl_layer ) WRITE(numout,*) ' ==>>> layer vertical coordinate is used'
IF( ln_vvl_ztilde_as_zstar ) WRITE(numout,*) ' ==>>> to emulate a zstar coordinate'
ENDIF
!
#if defined key_agrif
IF( (.NOT.Agrif_Root()).AND.(.NOT.ln_vvl_zstar) ) CALL ctl_stop( 'AGRIF is implemented with zstar coordinate only' )
#endif
!
END SUBROUTINE dom_vvl_ctl
#endif
!!======================================================================
END MODULE domvvl