Changeset 4351
- Timestamp:
- 2014-01-16T15:27:29+01:00 (10 years ago)
- Location:
- branches/2013/dev_ECMWF_waves/NEMOGCM
- Files:
-
- 2 added
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2013/dev_ECMWF_waves/NEMOGCM/ARCH/arch-ALTIX_NAUTILUS_MPT.fcm
r4306 r4351 47 47 %LD ifort 48 48 %FPPFLAGS -P -C -traditional 49 %LDFLAGS -lmpi -lstdc++ -lcurl 49 %LDFLAGS -lmpi -lstdc++ -lcurl -L/fibre/acc/PIN2CPU -lsgipin 50 50 %AR ar 51 51 %ARFLAGS -r -
branches/2013/dev_ECMWF_waves/NEMOGCM/CONFIG/ORCA2_LIM/EXP00/namelist_cfg
r4257 r4351 184 184 !----------------------------------------------------------------------- 185 185 / 186 !----------------------------------------------------------------------- 187 &namsbc_wave ! External fields from wave model 188 !----------------------------------------------------------------------- 189 / 190 !----------------------------------------------------------------------- 191 &namsbc_wave_ecmwf ! ECWMF external wave model drag coefficient 192 !----------------------------------------------------------------------- 193 / 194 !----------------------------------------------------------------------- 195 &namsbc_wavepar ! namsbc_wavepar parameters from wave model 196 !----------------------------------------------------------------------- 197 / 198 !----------------------------------------------------------------------- 199 &namsbc_waveparlim 200 !----------------------------------------------------------------------- 201 / -
branches/2013/dev_ECMWF_waves/NEMOGCM/CONFIG/SHARED/namelist_ref
r4347 r4351 225 225 ln_cdgw = .false. ! Neutral drag coefficient read from wave model (T => fill namsbc_wave) 226 226 ln_sdw = .false. ! Computation of 3D stokes drift (T => fill namsbc_wave) 227 ln_stcor = .false. ! Stokes drift read from wave model 228 ln_wavetke = .false. ! Wave parameters from wave model for the TKE BC 229 ln_tauoc = .false. ! Wave-modified stress from wave model 227 230 cn_iceflx = 'linear' ! redistribution of solar input into ice categories during coupling ice/atm. 228 231 / … … 1146 1149 / 1147 1150 !----------------------------------------------------------------------- 1151 &namsbc_wave_ecmwf ! External fields from wave model 1152 !----------------------------------------------------------------------- 1153 ! ! file name ! frequency (hours) ! variable ! time interp. ! clim ! 'yearly'/ ! weights ! rotation ! land/sea mask ! 1154 ! ! ! (if <0 months) ! name ! (logical) ! (T/F) ! 'monthly' ! filename ! pairing ! filename ! 1155 sn_cdg = 'cdww' , 6 , 'cdww' , .true. , .false. , 'monthly' , '' , '' , '' ! 1156 cn_dir_cdg = './' ! root directory for the location of drag coefficient files 1157 / 1158 !----------------------------------------------------------------------- 1148 1159 &namdyn_nept ! Neptune effect (simplified: lateral and vertical diffusions removed) 1149 1160 !----------------------------------------------------------------------- … … 1160 1171 rn_htrmax = 200.0 ! max. depth of transition range 1161 1172 / 1173 !----------------------------------------------------------------------- 1174 &namsbc_wavepar ! namsbc_wavepar parameters from wave model (CCC not identical to namsbc_wave) 1175 !----------------------------------------------------------------------- 1176 ! ! file name ! frequency (hours) ! variable ! time interp. ! clim ! 'yearly'/ ! weights ! rotation ! 1177 ! ! (if <0 months) ! name ! (logical) ! (T/F) ! 'monthly' ! filename ! pairing ! 1178 sn_ust = 'ust' , 6 , 'ust' , .true. , .false. , 'monthly' , '' , '' 1179 sn_vst = 'vst' , 6 , 'vst' , .true. , .false. , 'monthly' , '' , '' 1180 sn_swh = 'swh' , 6 , 'swh' , .true. , .false. , 'monthly' , '' , '' 1181 sn_mwp = 'mwp' , 6 , 'mwp' , .true. , .false. , 'monthly' , '' , '' 1182 sn_wspd = 'wspd' , 6 , 'wspd' , .true. , .false. , 'monthly' , '' , '' 1183 sn_phioc = 'physphioc' , 6 , 'physphioc', .true. , .false. , 'monthly' , '' , '' 1184 sn_tauoc = 'tauoc' , 6 , 'tauoc' , .true. , .false. , 'monthly' , '' , '' 1185 cn_dir_wavepar = './' ! root directory for the location of the ECWAM files 1186 / 1187 !----------------------------------------------------------------------- 1188 &namsbc_waveparlim 1189 !----------------------------------------------------------------------- 1190 ! ! file name ! frequency (hours) ! variable ! time interp. ! clim ! 'yearly'/ ! weights ! rotation ! 1191 ! ! (if <0 months) ! name ! (logical) ! (T/F) ! 'monthly' ! filename ! pairing ! 1192 sn_strn = 'istr' , 6 , 'icestrain' , .true. , .false. , 'monthly' , '' , '' 1193 cn_dir_waveparlim = './' ! root directory for the location of the ECWAM files 1194 / 1195 !----------------------------------------------------------------------- 1196 &namsbc_wave ! External fields from wave model 1197 !----------------------------------------------------------------------- 1198 sn_cdg = 'cdww' , 6 , 'cdww' , .true. , .false. , 'monthly' ,'' , '' ! 1199 cn_dir_cdg = './' ! root directory for the location of drag coefficient files 1200 / -
branches/2013/dev_ECMWF_waves/NEMOGCM/NEMO/OPA_SRC/SBC/sbc_oce.F90
r4306 r4351 53 53 LOGICAL , PUBLIC :: ln_sdw !: true if 3d stokes drift from wave model 54 54 ! 55 REAL(wp), PUBLIC :: rn_rrelwind = 1.0 !: relative wind ratio (1.0 means surface currents are subtracted, 0.0 means no current) 56 LOGICAL , PUBLIC :: ln_wavetke = .FALSE. !: true if wave parameters are read 57 LOGICAL , PUBLIC :: ln_stcor = .FALSE. !: true if Stokes-Coriolis forcing is included 58 LOGICAL , PUBLIC :: ln_tauoc = .FALSE. !: true if wave-modified water-side stress is used 59 55 60 LOGICAL , PUBLIC :: ln_icebergs !: Icebergs 56 61 ! … … 69 74 REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) :: vtau , vtau_b !: sea surface j-stress (ocean referential) [N/m2] 70 75 REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) :: taum !: module of sea surface stress (at T-point) [N/m2] 76 REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) :: cdn_wave !: wave model drag coefficient [N/m2] 77 REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) :: wspd_wavepar !: wave model 10-m neutral wind [m/s] CCC 78 REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) :: tauoc_wavepar !: normalized stress into the ocean from wave model CCC 71 79 !! wndm is used onmpute surface gases exchanges in ice-free ocean or leads 72 80 REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) :: wndm !: wind speed module at T-point (=|U10m-Uoce|) [m/s] … … 131 139 ALLOCATE( rnf (jpi,jpj) , sbc_tsc (jpi,jpj,jpts) , qsr_hc (jpi,jpj,jpk) , & 132 140 & rnf_b(jpi,jpj) , sbc_tsc_b(jpi,jpj,jpts) , qsr_hc_b(jpi,jpj,jpk) , STAT=ierr(3) ) 141 ! Initialize these since that is not done in the code. 142 rnf (:,:) = 0.0_wp 143 sbc_tsc (:,:,:) = 0.0_wp 144 qsr_hc (:,:,:) = 0.0_wp 145 rnf_b (:,:) = 0.0_wp 146 sbc_tsc_b(:,:,:) = 0.0_wp 147 qsr_hc_b (:,:,:) = 0.0_wp 148 133 149 ! 134 150 ALLOCATE( tprecip(jpi,jpj) , sprecip(jpi,jpj) , fr_i(jpi,jpj) , & … … 138 154 & ssu_m (jpi,jpj) , sst_m(jpi,jpj) , & 139 155 & ssv_m (jpi,jpj) , sss_m (jpi,jpj), ssh_m(jpi,jpj) , STAT=ierr(4) ) 156 ALLOCATE( cdn_wave(jpi,jpj) ) 157 ALLOCATE( wspd_wavepar(jpi,jpj) ) 140 158 ! 141 159 #if defined key_vvl -
branches/2013/dev_ECMWF_waves/NEMOGCM/NEMO/OPA_SRC/SBC/sbcblk_core.F90
r4333 r4351 38 38 USE lbclnk ! ocean lateral boundary conditions (or mpp link) 39 39 USE prtctl ! Print control 40 USE sbcwave,ONLY : cdn_wave !wave module40 !USE sbcwave,ONLY : cdn_wave !wave module ! moved to sbc_oce 41 41 #if defined key_lim3 || defined key_cice 42 42 USE sbc_ice ! Surface boundary condition: ice fields … … 64 64 65 65 TYPE(FLD), ALLOCATABLE, DIMENSION(:) :: sf ! structure of input fields (file informations, fields read) 66 REAL(wp), PUBLIC, DIMENSION(:,:), ALLOCATABLE :: Cd_n10 ! 10m neutral drag coefficient for output 66 67 67 68 ! !!! CORE bulk parameters … … 83 84 REAL(wp) :: rn_zqt ! z(q,t) : height of humidity and temperature measurements 84 85 REAL(wp) :: rn_zu ! z(u) : height of wind measurements 86 LOGICAL :: ln_cdec = .FALSE. ! logical flag for using ec neutral wind drag coef 87 ! References : P. Janssen, 2008, ECMWF Workshop on Ocean-Atmosphere Interactions, 10-12 November p47-60 85 88 86 89 !! * Substitutions … … 138 141 NAMELIST/namsbc_core/ cn_dir , ln_2m , ln_taudif, rn_pfac, rn_efac, rn_vfac, & 139 142 & sn_wndi, sn_wndj, sn_humi , sn_qsr , & 143 & sn_ccov, ln_cdec, ln_cldcov, rn_rrelwind 140 144 & sn_qlw , sn_tair, sn_prec , sn_snow, & 141 145 & sn_tdif, rn_zqt , ln_bulk2z, rn_zu … … 163 167 sn_qsr%ln_tint = .false. 164 168 ENDIF 169 IF( ln_cdec .AND. lwp ) WRITE(numout,*)'Using Hans Hersbach formula for drag.' 165 170 ! ! store namelist information in an array 166 171 slf_i(jp_wndi) = sn_wndi ; slf_i(jp_wndj) = sn_wndj … … 182 187 CALL fld_fill( sf, slf_i, cn_dir, 'sbc_blk_core', 'flux formulation for ocean surface boundary condition', 'namsbc_core' ) 183 188 ! 189 ! Drag coefficent so we can write to disk 190 ALLOCATE(Cd_n10(jpi,jpj)) 191 184 192 sfx(:,:) = 0._wp ! salt flux; zero unless ice is present (computed in limsbc(_2).F90) 185 193 ! … … 239 247 INTEGER :: ji, jj ! dummy loop indices 240 248 REAL(wp) :: zcoef_qsatw, zztmp ! local variable 249 REAL(wp) :: ztheta ! local variable, wind direction 241 250 REAL(wp), DIMENSION(:,:), POINTER :: zwnd_i, zwnd_j ! wind speed components at T-point 242 251 REAL(wp), DIMENSION(:,:), POINTER :: zqsatw ! specific humidity at pst … … 283 292 !CDIR COLLAPSE 284 293 #endif 285 DO jj = 2, jpjm1 286 DO ji = fs_2, fs_jpim1 ! vect. opt. 287 zwnd_i(ji,jj) = ( sf(jp_wndi)%fnow(ji,jj,1) - rn_vfac * 0.5 * ( pu(ji-1,jj ) + pu(ji,jj) ) ) 288 zwnd_j(ji,jj) = ( sf(jp_wndj)%fnow(ji,jj,1) - rn_vfac * 0.5 * ( pv(ji ,jj-1) + pv(ji,jj) ) ) 294 ! Wind vector at T points 295 IF ( ln_cdgw ) THEN 296 ! Use neutral 10-m wind speed from wave model if available 297 DO jj = 2, jpjm1 298 DO ji = fs_2, fs_jpim1 ! vect. opt. 299 ! Local wind direction from non-neutral 10-m wind vector (relative to grid and no current) 300 ! since we do not have the directional information from the wave model 301 ztheta = ATAN2(sf(jp_wndi)%fnow(ji,jj,1), sf(jp_wndj)%fnow(ji,jj,1)) 302 ! Wind vector magnitude from 10-m neutral wind speed from wave model 303 zwnd_i(ji,jj) = wspd_wavepar(ji,jj) * SIN(ztheta) 304 zwnd_j(ji,jj) = wspd_wavepar(ji,jj) * COS(ztheta) 305 ! Correct for surface current, 0.0 <= rn_rrelwind <= 1.0 306 zwnd_i(ji,jj) = (zwnd_i(ji,jj) - 0.5*rn_rrelwind*(pu(ji-1,jj ) + pu(ji,jj))) 307 zwnd_j(ji,jj) = (zwnd_j(ji,jj) - 0.5*rn_rrelwind*(pv(ji ,jj-1) + pv(ji,jj))) 308 END DO 289 309 END DO 290 END DO 310 ELSE 311 DO jj = 2, jpjm1 312 DO ji = fs_2, fs_jpim1 ! vect. opt. 313 ! Correct for surface current, 0.0 <= rn_rrelwind <= 1.0 314 zwnd_i(ji,jj) = ( sf(jp_wndi)%fnow(ji,jj,1) - 0.5*rn_rrelwind*( pu(ji-1,jj ) + pu(ji,jj) ) ) 315 zwnd_j(ji,jj) = ( sf(jp_wndj)%fnow(ji,jj,1) - 0.5*rn_rrelwind*( pv(ji ,jj-1) + pv(ji,jj) ) ) 316 END DO 317 END DO 318 ENDIF 291 319 CALL lbc_lnk( zwnd_i(:,:) , 'T', -1. ) 292 320 CALL lbc_lnk( zwnd_j(:,:) , 'T', -1. ) … … 353 381 354 382 ! ... tau module, i and j component 355 DO jj = 1, jpj 356 DO ji = 1, jpi 357 zztmp = rhoa * wndm(ji,jj) * Cd(ji,jj) 358 taum (ji,jj) = zztmp * wndm (ji,jj) 359 zwnd_i(ji,jj) = zztmp * zwnd_i(ji,jj) 360 zwnd_j(ji,jj) = zztmp * zwnd_j(ji,jj) 361 END DO 362 END DO 383 ! Use cdn_wave instead of Cd if we have wave parameters 384 IF ( ln_cdgw ) THEN 385 DO jj = 1, jpj 386 DO ji = 1, jpi 387 !zztmp = rhoa * wspd_wavepar(ji,jj) * Cd_n10(ji,jj) 388 zztmp = rhoa * wndm(ji,jj) * cdn_wave(ji,jj) 389 !taum(ji,jj) = tauoc_wavepar(ji,jj) 390 !taum(ji,jj) = zztmp * wspd_wavepar(ji,jj) 391 taum (ji,jj) = zztmp * wndm (ji,jj) 392 zwnd_i(ji,jj) = zztmp * zwnd_i(ji,jj) 393 zwnd_j(ji,jj) = zztmp * zwnd_j(ji,jj) 394 ENDDO 395 ENDDO 396 ELSE 397 DO jj = 1, jpj 398 DO ji = 1, jpi 399 zztmp = rhoa * wndm(ji,jj) * Cd(ji,jj) 400 taum (ji,jj) = zztmp * wndm (ji,jj) 401 zwnd_i(ji,jj) = zztmp * zwnd_i(ji,jj) 402 zwnd_j(ji,jj) = zztmp * zwnd_j(ji,jj) 403 ENDDO 404 ENDDO 405 ENDIF 363 406 364 407 ! ... add the HF tau contribution to the wind stress module? … … 379 422 CALL lbc_lnk( utau(:,:), 'U', -1. ) 380 423 CALL lbc_lnk( vtau(:,:), 'V', -1. ) 424 425 IF (ln_tauoc) THEN 426 utau(:,:) = utau(:,:)*tauoc_wavepar(:,:) 427 vtau(:,:) = vtau(:,:)*tauoc_wavepar(:,:) 428 taum(:,:) = taum(:,:)*tauoc_wavepar(:,:) 429 ENDIF 381 430 382 431 ! Turbulent fluxes over ocean … … 755 804 REAL(wp), DIMENSION(:,:), POINTER :: dT ! air/sea temperature differeence [K] 756 805 REAL(wp), DIMENSION(:,:), POINTER :: dq ! air/sea humidity difference [K] 757 REAL(wp), DIMENSION(:,:), POINTER :: Cd_n10 ! 10m neutral drag coefficient758 806 REAL(wp), DIMENSION(:,:), POINTER :: Ce_n10 ! 10m neutral latent coefficient 759 807 REAL(wp), DIMENSION(:,:), POINTER :: Ch_n10 ! 10m neutral sensible coefficient … … 775 823 ! 776 824 CALL wrk_alloc( jpi,jpj, stab ) ! integer 777 CALL wrk_alloc( jpi,jpj, dU10, dT, dq, C d_n10, Ce_n10, Ch_n10, sqrt_Cd_n10, sqrt_Cd, L )825 CALL wrk_alloc( jpi,jpj, dU10, dT, dq, Ce_n10, Ch_n10, sqrt_Cd_n10, sqrt_Cd, L ) 778 826 CALL wrk_alloc( jpi,jpj, T_vpot, T_star, q_star, U_star, zeta, U_n10, xlogt, xct, zpsi_h, zpsi_m ) 779 827 780 828 !! * Start 781 829 !! Air/sea differences 782 dU10 = max(0.5, dU) ! we don't want to fall under 0.5 m/s830 dU10 = MAX(0.5, dU) ! we don't want to fall under 0.5 m/s 783 831 dT = T_a - sst ! assuming that T_a is allready the potential temp. at zzu 784 832 dq = q_a - q_sat … … 788 836 !! 789 837 !! Neutral Drag Coefficient 790 stab = 0.5 + sign(0.5,dT) ! stable : stab = 1 ; unstable : stab = 0 791 IF ( ln_cdgw ) THEN 792 cdn_wave = cdn_wave - rsmall*(tmask(:,:,1)-1) 793 Cd_n10(:,:) = cdn_wave 838 stab = 0.5 + SIGN(0.5,dT) ! stable : stab = 1 ; unstable : stab = 0 839 840 ! Use drag coefficient from a wave model ... 841 IF (ln_cdgw) THEN 842 cdn_wave = cdn_wave - rsmall*(tmask(:,:,1)-1) 843 Cd_n10(:,:) = cdn_wave(:,:) 794 844 ELSE 795 Cd_n10 = 1.e-3 * ( 2.7/dU10 + 0.142 + dU10/13.09 ) ! L & Y eq. (6a) 845 ! ... or choose a drag law 846 IF (ln_cdec) THEN 847 Cd_n10 = 1E-3 * ( 1.03 + 0.04 * dU10**1.48 ) / (dU10**0.21) ! PJ (6) 848 ELSE 849 Cd_n10 = 1E-3 * ( 2.7/dU10 + 0.142 + dU10/13.09 ) ! L & Y eq. (6a) 850 ENDIF 796 851 ENDIF 797 852 sqrt_Cd_n10 = sqrt(Cd_n10) … … 824 879 825 880 !! Updating the neutral 10m transfer coefficients : 826 Cd_n10 = 1.e-3 * (2.7/U_n10 + 0.142 + U_n10/13.09) ! L & Y eq. (6a) 881 IF (ln_cdec) THEN 882 Cd_n10 = 1E-3 * ( 1.03 + 0.04 * U_n10**1.48 ) / (U_n10**0.21) ! PJ (6) 883 ELSE 884 Cd_n10 = 1E-3 * ( 2.7/U_n10 + 0.142 + U_n10/13.09 ) ! L & Y eq. (6a) 885 ENDIF 827 886 sqrt_Cd_n10 = sqrt(Cd_n10) 828 887 Ce_n10 = 1.e-3 * (34.6 * sqrt_Cd_n10) ! L & Y eq. (6b) … … 847 906 !! 848 907 CALL wrk_dealloc( jpi,jpj, stab ) ! integer 849 CALL wrk_dealloc( jpi,jpj, dU10, dT, dq, C d_n10, Ce_n10, Ch_n10, sqrt_Cd_n10, sqrt_Cd, L )908 CALL wrk_dealloc( jpi,jpj, dU10, dT, dq, Ce_n10, Ch_n10, sqrt_Cd_n10, sqrt_Cd, L ) 850 909 CALL wrk_dealloc( jpi,jpj, T_vpot, T_star, q_star, U_star, zeta, U_n10, xlogt, xct, zpsi_h, zpsi_m ) 851 910 ! … … 891 950 REAL(wp), DIMENSION(:,:), POINTER :: dT ! air/sea temperature differeence [K] 892 951 REAL(wp), DIMENSION(:,:), POINTER :: dq ! air/sea humidity difference [K] 893 REAL(wp), DIMENSION(:,:), POINTER :: Cd_n10 ! 10m neutral drag coefficient894 952 REAL(wp), DIMENSION(:,:), POINTER :: Ce_n10 ! 10m neutral latent coefficient 895 953 REAL(wp), DIMENSION(:,:), POINTER :: Ch_n10 ! 10m neutral sensible coefficient … … 911 969 IF( nn_timing == 1 ) CALL timing_start('TURB_CORE_2Z') 912 970 ! 913 CALL wrk_alloc( jpi,jpj, dU10, dT, dq, C d_n10, Ce_n10, Ch_n10, sqrt_Cd_n10, sqrt_Cd, L )971 CALL wrk_alloc( jpi,jpj, dU10, dT, dq, Ce_n10, Ch_n10, sqrt_Cd_n10, sqrt_Cd, L ) 914 972 CALL wrk_alloc( jpi,jpj, T_vpot, T_star, q_star, U_star, zeta_u, zeta_t, U_n10 ) 915 973 CALL wrk_alloc( jpi,jpj, xlogt, xct, zpsi_hu, zpsi_ht, zpsi_m ) … … 923 981 !! Neutral Drag Coefficient : 924 982 stab = 0.5 + sign(0.5,dT) ! stab = 1 if dT > 0 -> STABLE 925 IF( ln_cdgw ) THEN 926 cdn_wave = cdn_wave - rsmall*(tmask(:,:,1)-1) 927 Cd_n10(:,:) = cdn_wave 983 984 ! Use drag coefficient from a wave model ... 985 IF (ln_cdgw) THEN 986 cdn_wave = cdn_wave - rsmall*(tmask(:,:,1)-1) 987 Cd_n10(:,:) = cdn_wave 928 988 ELSE 929 Cd_n10 = 1.e-3*( 2.7/dU10 + 0.142 + dU10/13.09 ) 989 ! ... or choose a drag law 990 IF (ln_cdec) THEN 991 Cd_n10 = 1E-3 * ( 1.03 + 0.04 * dU10**1.48 ) / (dU10**0.21) ! PJ (6) 992 ELSE 993 Cd_n10 = 1E-3 * ( 2.7/dU10 + 0.142 + dU10/13.09 ) ! L & Y eq. (6a) 994 ENDIF 930 995 ENDIF 931 996 sqrt_Cd_n10 = sqrt(Cd_n10) … … 996 1061 END DO 997 1062 !! 998 CALL wrk_dealloc( jpi,jpj, dU10, dT, dq, C d_n10, Ce_n10, Ch_n10, sqrt_Cd_n10, sqrt_Cd, L )1063 CALL wrk_dealloc( jpi,jpj, dU10, dT, dq, Ce_n10, Ch_n10, sqrt_Cd_n10, sqrt_Cd, L ) 999 1064 CALL wrk_dealloc( jpi,jpj, T_vpot, T_star, q_star, U_star, zeta_u, zeta_t, U_n10 ) 1000 1065 CALL wrk_dealloc( jpi,jpj, xlogt, xct, zpsi_hu, zpsi_ht, zpsi_m ) -
branches/2013/dev_ECMWF_waves/NEMOGCM/NEMO/OPA_SRC/SBC/sbcmod.F90
r4333 r4351 50 50 USE timing ! Timing 51 51 USE sbcwave ! Wave module 52 USE sbcwave_ecmwf ! ECMWF wave module 53 USE sbcwavelim ! Wave for LIM module 52 54 53 55 IMPLICIT NONE … … 82 84 INTEGER :: icpt ! local integer 83 85 !! 84 NAMELIST/namsbc/ nn_fsbc , ln_ana , ln_flx, ln_blk_clio, ln_blk_core, ln_cpl, & 85 & ln_blk_mfs, ln_apr_dyn, nn_ice, nn_ice_embd, ln_dm2dc , ln_rnf, & 86 & ln_ssr , nn_fwb , ln_cdgw , ln_wave , ln_sdw, nn_lsm, cn_iceflx 86 NAMELIST/namsbc/ nn_fsbc , ln_ana , ln_flx , ln_blk_clio, ln_blk_core, ln_cpl, & 87 & ln_blk_mfs, ln_apr_dyn, nn_ice , nn_ice_embd, ln_dm2dc , ln_rnf, & 88 & ln_ssr , nn_fwb , ln_cdgw , ln_wave , ln_sdw , nn_lsm, & 89 & cn_iceflx , ln_stcor , ln_tauoc, ln_wavetke 87 90 INTEGER :: ios 88 91 !!---------------------------------------------------------------------- … … 135 138 WRITE(numout,*) ' closed sea (=0/1) (set in namdom) nn_closea = ', nn_closea 136 139 WRITE(numout,*) ' n. of iterations if land-sea-mask applied nn_lsm = ', nn_lsm 140 WRITE(numout,*) ' Drag coefficient from wave model ln_cdgw = ', ln_cdgw 141 WRITE(numout,*) ' Stokes-Coriolis forcing from wave model ln_stcor = ', ln_stcor 142 WRITE(numout,*) ' TKE wave breaking BC from wave model ln_wavetke = ', ln_wavetke 143 WRITE(numout,*) ' Wave-modified stress from wave model ln_tauoc = ', ln_tauoc 144 WRITE(numout,*) ' Wave-modified stress min. sea. frac rn_taouc_cimin = ', rn_taouc_cimin 137 145 ENDIF 138 146 … … 216 224 ELSE 217 225 IF ( ln_cdgw .OR. ln_sdw ) & 218 & CALL ctl_ stop('Not Activated Wave Module (ln_wave=F) but &226 & CALL ctl_warn('Not Activated Wave Module (ln_wave=F) but & 219 227 & asked coupling with drag coefficient (ln_cdgw =T) or Stokes drift (ln_sdw=T) ') 220 228 ENDIF … … 300 308 CALL sbc_ssm( kt ) ! ocean sea surface variables (sst_m, sss_m, ssu_m, ssv_m) 301 309 ! ! averaged over nf_sbc time-step 310 311 IF (ln_cdgw) CALL sbc_wave_ecmwf( kt ) 312 ! Read wave parameters if Stokes-Coriolis forcing OR wave parameters for TKE are needed 313 ! Also read it if drag coefficient to ensure that we use the neutral 10m from WAM. 314 IF (ln_stcor .OR. ln_wavetke .OR. ln_tauoc .OR. ln_cdgw) THEN 315 CALL sbc_wavepar( kt ) 316 ENDIF 302 317 303 318 IF (ln_wave) CALL sbc_wave( kt ) -
branches/2013/dev_ECMWF_waves/NEMOGCM/NEMO/OPA_SRC/ZDF/zdftke.F90
r4147 r4351 26 26 !! ! + cleaning of the parameters + bugs correction 27 27 !! 3.3 ! 2010-10 (C. Ethe, G. Madec) reorganisation of initialisation phase 28 !! ! 2012-12 (oyvind.breivik@ecwmf.int) Changed to wave breaking source term 28 29 !!---------------------------------------------------------------------- 29 30 #if defined key_zdftke || defined key_esopa … … 42 43 USE domvvl ! domain: variable volume layer 43 44 USE sbc_oce ! surface boundary condition: ocean 45 USE sbcwave ! wave parameters 46 USE sbcwave_ecmwf ! ECMWF wave parameters 44 47 USE zdf_oce ! vertical physics: ocean variables 45 48 USE zdfmxl ! vertical physics: mixed layer … … 78 81 LOGICAL :: ln_lc ! Langmuir cells (LC) as a source term of TKE or not 79 82 REAL(wp) :: rn_lc ! coef to compute vertical velocity of Langmuir cells 83 REAL(wp) :: rn_alpavg = 100.0_wp ! Average alpha (normalized, water-side energy flux, only used in 84 ! case we use the source term formulation with no wave model information 85 ! NB! The option of running with source term and no wave model has 86 ! not been properly tested yet but is included for consistency (Oyvind Breivik, 2013-07-16) 87 REAL(wp) :: rn_deptmaxtkew = 50.0_wp ! maximum depth [m] to be affected by TKE from breaking waves 80 88 81 89 REAL(wp) :: ri_cri ! critic Richardson number (deduced from rn_ediff and rn_ediss values) … … 85 93 86 94 REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:,:) :: en !: now turbulent kinetic energy [m2/s2] 95 REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) :: e0 !: top level turbulent kinetic energy [m2/s2] from waves 96 REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) :: dfac !: wave depth scaling factor 87 97 REAL(wp) , ALLOCATABLE, SAVE, DIMENSION(:,:) :: htau ! depth of tke penetration (nn_htau) 88 98 REAL(wp) , ALLOCATABLE, SAVE, DIMENSION(:,:,:) :: dissl ! now mixing lenght of dissipation … … 109 119 !! *** FUNCTION zdf_tke_alloc *** 110 120 !!---------------------------------------------------------------------- 121 INTEGER :: iexalloc 111 122 ALLOCATE( & 112 123 #if defined key_c1d … … 118 129 & avmu_k(jpi,jpj,jpk) , avmv_k(jpi,jpj,jpk), STAT= zdf_tke_alloc ) 119 130 ! 131 IF ( ln_wavetke ) THEN 132 ALLOCATE( e0(jpi,jpj) , dfac(jpi,jpj), STAT= iexalloc ) 133 ! Setting arrays to zero initially. 134 e0(:,:) = 0.0_wp 135 dfac(:,:) = 0.0_wp 136 ! 137 zdf_tke_alloc = zdf_tke_alloc + iexalloc 138 ENDIF 120 139 IF( lk_mpp ) CALL mpp_sum ( zdf_tke_alloc ) 121 140 IF( zdf_tke_alloc /= 0 ) CALL ctl_warn('zdf_tke_alloc: failed to allocate arrays') … … 219 238 REAL(wp) :: zus , zwlc , zind ! - - 220 239 REAL(wp) :: zzd_up, zzd_lw ! - - 240 REAL(wp) :: lambda ! - - 241 REAL(wp) :: zphio_flux ! - - 242 REAL(wp) :: sbr, z0, fb ! - - 243 221 244 !!bfr REAL(wp) :: zebot ! - - 222 245 INTEGER , POINTER, DIMENSION(:,: ) :: imlc … … 239 262 ! ! Surface boundary condition on tke 240 263 ! !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 241 DO jj = 2, jpjm1 ! en(1) = rn_ebb taum / rau0 (min value rn_emin0) 242 DO ji = fs_2, fs_jpim1 ! vector opt. 243 en(ji,jj,1) = MAX( rn_emin0, zbbrau * taum(ji,jj) ) * tmask(ji,jj,1) 244 END DO 245 END DO 246 264 ! Wave parameters read? 265 IF ( ln_wavetke ) THEN 266 ! Breaking-wave TKE injection as flux 267 DO jj = 2, jpjm1 ! en(1) = rn_ebb taum / rau0 (min value rn_emin0) 268 DO ji = fs_2, fs_jpim1 ! vector opt. 269 ! Roughness length proportional to wave height, capped at Hs = 0.1 m 270 z0 = 0.5_wp*MAX(swh_wavepar(ji,jj), 0.1_wp) 271 lambda = 2.38_wp/z0 272 ! The energy flux from the wave model in physical units 273 zphio_flux = phioc_wavepar(ji,jj) 274 ! TKE at surface (Mellor and Blumberg, 2004) 275 e0(ji,jj) = 0.5_wp*( 15.8_wp*zphio_flux/rau0 )**0.67_wp 276 ! Reducing the surface TKE by scaling with T-depth of first vertical level 277 dfac(ji,jj) = MAX( (2.0_wp*lambda*fsdept(ji,jj,1) )/3.0_wp, 0.00001_wp ) 278 ! TKE surface boundary condition weighted by the thickness of the first level 279 en(ji,jj,1) = MAX( rn_emin0, e0(ji,jj) * ( 1.0_wp - EXP(-dfac(ji,jj)) ) / dfac(ji,jj) ) * tmask(ji,jj,1) 280 ENDDO 281 ENDDO 282 ! If wave parameters are not read, use rn_ebb, corresponding to alpha = 100.0 283 ELSE 284 DO jj = 2, jpjm1 ! en(1) = rn_ebb taum / rau0 (min value rn_emin0) 285 DO ji = fs_2, fs_jpim1 ! vector opt. 286 ! Estimate average energy flux from std value found in rn_ebb (corresponds to alpha=100.0) 287 en(ji,jj,1) = MAX( rn_emin0, zbbrau * taum(ji,jj) ) * tmask(ji,jj,1) 288 ENDDO 289 ENDDO 290 ENDIF 291 247 292 !!bfr - start commented area 248 293 ! !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< … … 443 488 ENDIF 444 489 CALL lbc_lnk( en, 'W', 1. ) ! Lateral boundary conditions (sign unchanged) 490 IF ( ln_wavetke ) THEN 491 CALL lbc_lnk( e0, 'W', 1. ) ! Lateral boundary conditions (sign unchanged) 492 CALL lbc_lnk( dfac, 'W', 1. ) ! Lateral boundary conditions (sign unchanged) 493 ENDIF 445 494 ! 446 495 CALL wrk_dealloc( jpi,jpj, imlc ) ! integer -
branches/2013/dev_ECMWF_waves/NEMOGCM/NEMO/OPA_SRC/step.F90
r4338 r4351 284 284 CALL dyn_ldf( kstp ) ! lateral mixing 285 285 IF( ln_neptsimp ) CALL dyn_nept_cor( kstp ) ! add Neptune velocities (simplified) 286 IF( ln_stcor ) CALL dyn_stcor ( kstp ) ! Stokes-Coriolis forcing (ln_stcor set in SBC/sbc_oce.F90) 286 287 #if defined key_agrif 287 288 IF(.NOT. Agrif_Root()) CALL Agrif_Sponge_dyn ! momemtum sponge -
branches/2013/dev_ECMWF_waves/NEMOGCM/NEMO/OPA_SRC/step_oce.F90
r4328 r4351 51 51 USE dynspg ! surface pressure gradient (dyn_spg routine) 52 52 USE dynnept ! simp. form of Neptune effect(dyn_nept_cor routine) 53 USE dynstcor ! Stokes-Coriolis forcing (dyn_stcor routine) 53 54 54 55 USE dynnxt ! time-stepping (dyn_nxt routine)
Note: See TracChangeset
for help on using the changeset viewer.