Changeset 5039
- Timestamp:
- Jul 9, 2024, 10:33:13 PM (2 months ago)
- Location:
- LMDZ6/trunk
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ6/trunk/DefLists/field_def_lmdz.xml
r5007 r5039 636 636 <field id="tke_buoy" long_name="TKE Buoyancy term" unit="m2/s3" /> 637 637 <field id="tke_shear" long_name="TKE Shear term" unit="m2/s3" /> 638 <field id="tke_trans" long_name="TKE Transport term" unit="m2/s3" /> 638 639 <field id="tke_ter" long_name="Max Turb. Kinetic Energy ter" unit="m2/s2" /> 639 640 <field id="tke_lic" long_name="Max Turb. Kinetic Energy lic" unit="m2/s2" /> -
LMDZ6/trunk/libf/phylmd/lmdz_atke_exchange_coeff.F90
r4884 r5039 7 7 subroutine atke_compute_km_kh(ngrid,nlay,dtime, & 8 8 wind_u,wind_v,temp,qvap,play,pinterf,cdrag_uv, & 9 tke,eps, Km_out,Kh_out)9 tke,eps,tke_shear,tke_buoy,tke_trans,Km_out,Kh_out) 10 10 11 11 !======================================================================== … … 79 79 80 80 REAL, DIMENSION(ngrid,nlay+1), INTENT(OUT) :: eps ! output: TKE dissipation rate at interface between layers (m2/s3) 81 REAL, DIMENSION(ngrid,nlay+1), INTENT(OUT) :: tke_shear! output: TKE shear production rate (m2/s3) 82 REAL, DIMENSION(ngrid,nlay+1), INTENT(OUT) :: tke_buoy ! output: TKE buoyancy production rate (m2/s3) 83 REAL, DIMENSION(ngrid,nlay+1), INTENT(OUT) :: tke_trans! output: TKE transport (diffusion) term (m2/s3) 81 84 REAL, DIMENSION(ngrid,nlay), INTENT(OUT) :: Km_out ! output: Exchange coefficient for momentum at interface between layers (m2/s) 82 85 REAL, DIMENSION(ngrid,nlay), INTENT(OUT) :: Kh_out ! output: Exchange coefficient for heat flux at interface between layers (m2/s) … … 261 264 shear2(igrid,ilay) * (1. - Ri(igrid,ilay) / Prandtl(igrid,ilay)) 262 265 eps(igrid,ilay) = (tke(igrid,ilay)**(3./2))/(cepsilon*l_exchange(igrid,ilay)) 266 tke_shear(igrid,ilay)=l_exchange(igrid,ilay)*Sm(igrid,ilay)*sqrt(tke(igrid,ilay))*shear2(igrid,ilay) 267 tke_buoy(igrid,ilay)=-l_exchange(igrid,ilay)*Sm(igrid,ilay)*sqrt(tke(igrid,ilay))*shear2(igrid,ilay) & 268 *(Ri(igrid,ilay) / Prandtl(igrid,ilay)) 263 269 ENDDO 264 270 ENDDO … … 278 284 qq=max(0.,qq) 279 285 tke(igrid,ilay)=0.5*(qq**2) 280 eps(igrid,ilay) = (tke(igrid,ilay)**(3./2))/(cepsilon*l_exchange(igrid,ilay)) 286 eps(igrid,ilay) = (tke(igrid,ilay)**(3./2))/(cepsilon*l_exchange(igrid,ilay)) 287 tke_shear(igrid,ilay)=l_exchange(igrid,ilay)*Sm(igrid,ilay)*sqrt(tke(igrid,ilay))*shear2(igrid,ilay) 288 tke_buoy(igrid,ilay)=-l_exchange(igrid,ilay)*Sm(igrid,ilay)*sqrt(tke(igrid,ilay))*shear2(igrid,ilay) & 289 *(Ri(igrid,ilay) / Prandtl(igrid,ilay)) 281 290 ENDDO 282 291 ENDDO … … 293 302 qq=(qq+l_exchange(igrid,ilay)*Sm(igrid,ilay)*dtime/sqrt(2.) & 294 303 *shear2(igrid,ilay)*(1.-Ri(igrid,ilay)/Prandtl(igrid,ilay))) & 295 /(1.+qq*dtime/(cepsilon*l_exchange(igrid,ilay)*2.*sqrt(2.))) 304 /(1.+qq*dtime/(cepsilon*l_exchange(igrid,ilay)*2.*sqrt(2.))) 305 tke_shear(igrid,ilay)=l_exchange(igrid,ilay)*Sm(igrid,ilay)*qq/sqrt(2.)*shear2(igrid,ilay) 306 tke_buoy(igrid,ilay)=-l_exchange(igrid,ilay)*Sm(igrid,ilay)*qq/sqrt(2.)*shear2(igrid,ilay) & 307 *(Ri(igrid,ilay) / Prandtl(igrid,ilay)) 296 308 tke(igrid,ilay)=0.5*(qq**2) 297 309 eps(igrid,ilay) = (tke(igrid,ilay)**(3./2))/(cepsilon*l_exchange(igrid,ilay)) … … 308 320 eps(igrid,ilay) = (tke(igrid,ilay)**(3./2))/(cepsilon*l_exchange(igrid,ilay)) 309 321 qq=max(sqrt(2.*tke(igrid,ilay)),1.e-10) 322 tke_shear(igrid,ilay)=l_exchange(igrid,ilay)*Sm(igrid,ilay)*qq/sqrt(2.)*shear2(igrid,ilay) 323 tke_buoy(igrid,ilay)=-l_exchange(igrid,ilay)*Sm(igrid,ilay)*qq/sqrt(2.)*shear2(igrid,ilay) & 324 *(Ri(igrid,ilay) / Prandtl(igrid,ilay)) 310 325 IF (Ri(igrid,ilay) .LT. 0.) THEN 311 326 netloss=qq/(2.*sqrt(2.)*cepsilon*l_exchange(igrid,ilay)) … … 327 342 DO igrid=1,ngrid 328 343 qq=max(sqrt(2.*tke(igrid,ilay)),1.e-10) 344 tke_shear(igrid,ilay)=l_exchange(igrid,ilay)*Sm(igrid,ilay)*qq/sqrt(2.)*shear2(igrid,ilay) 345 tke_buoy(igrid,ilay)=-l_exchange(igrid,ilay)*Sm(igrid,ilay)*qq/sqrt(2.)*shear2(igrid,ilay) & 346 *(Ri(igrid,ilay) / Prandtl(igrid,ilay)) 329 347 qq=(l_exchange(igrid,ilay)*Sm(igrid,ilay)/sqrt(2.)*shear2(igrid,ilay)*(1.-Ri(igrid,ilay)/Prandtl(igrid,ilay)) & 330 348 +qq*(1.+dtime*qq/(cepsilon*l_exchange(igrid,ilay)*2.*sqrt(2.)))) & … … 349 367 tke(igrid,nlay+1)=0. 350 368 eps(igrid,nlay+1)=0. 369 tke_shear(igrid,nlay+1)=0. 370 tke_buoy(igrid,nlay+1)=0. 351 371 END DO 352 372 … … 359 379 tke(igrid,1)=ctkes*(ustar**2) 360 380 eps(igrid,1)=0. ! arbitrary as TKE is not properly defined at the surface 381 tke_shear(igrid,1)=0. 382 tke_buoy(igrid,1)=0. 361 383 END DO 362 384 … … 364 386 ! vertical diffusion of TKE 365 387 !========================== 388 tke_trans(:,:)=0. 366 389 IF (atke_ok_vdiff) THEN 367 CALL atke_vdiff_tke(ngrid,nlay,dtime,z_lay,z_interf,temp,play,l_exchange,Sm,tke )390 CALL atke_vdiff_tke(ngrid,nlay,dtime,z_lay,z_interf,temp,play,l_exchange,Sm,tke,tke_trans) 368 391 ENDIF 369 392 … … 387 410 388 411 !=============================================================================================== 389 subroutine atke_vdiff_tke(ngrid,nlay,dtime,z_lay,z_interf,temp,play,l_exchange,Sm,tke )412 subroutine atke_vdiff_tke(ngrid,nlay,dtime,z_lay,z_interf,temp,play,l_exchange,Sm,tke,tke_trans) 390 413 391 414 ! routine that computes the vertical diffusion of TKE by the turbulence … … 408 431 409 432 REAL, DIMENSION(ngrid,nlay+1), INTENT(INOUT) :: tke ! turbulent kinetic energy at interface between layers 410 433 REAL, DIMENSION(ngrid,nlay+1), INTENT(INOUT) :: tke_trans ! turbulent kinetic energy transport term (m2/s3) 411 434 412 435 … … 480 503 ! update TKE 481 504 tke(:,:)=tke(:,:)+dtke(:,:) 505 tke_trans(:,:)=dtke(:,:)/dtime 482 506 483 507 -
LMDZ6/trunk/libf/phylmd/lmdz_call_atke.F90
r4881 r5039 8 8 contains 9 9 10 subroutine call_atke(dtime,ngrid,nlay, cdrag_uv,cdrag_t,u_surf,v_surf,temp_surf, &10 subroutine call_atke(dtime,ngrid,nlay,nsrf,ni,cdrag_uv,cdrag_t,u_surf,v_surf,temp_surf, & 11 11 wind_u,wind_v,temp,qvap,play,pinterf, & 12 12 tke,eps,Km_out,Kh_out) … … 16 16 17 17 USE lmdz_atke_turbulence_ini, ONLY : iflag_num_atke, rg, rd 18 USE phys_local_var_mod, ONLY: tke_shear, tke_buoy, tke_trans 18 19 19 20 implicit none … … 26 27 INTEGER, INTENT(IN) :: ngrid ! number of horizontal index (flat grid) 27 28 INTEGER, INTENT(IN) :: nlay ! number of vertical index 29 INTEGER, INTENT(IN) :: nsrf ! surface tile index 30 INTEGER, DIMENSION(ngrid), INTENT(IN) :: ni ! array of indices to move from knon to klon arrays 28 31 29 32 … … 50 53 51 54 55 REAL, DIMENSION(ngrid,nlay+1) :: tke_shear_term,tke_buoy_term,tke_trans_term 52 56 REAL, DIMENSION(ngrid,nlay) :: wind_u_predict, wind_v_predict 53 57 REAL, DIMENSION(ngrid) :: wind1 54 INTEGER i 58 INTEGER i,j,k 55 59 56 60 57 61 call atke_compute_km_kh(ngrid,nlay,dtime,& 58 62 wind_u,wind_v,temp,qvap,play,pinterf,cdrag_uv,& 59 tke,eps, Km_out,Kh_out)63 tke,eps,tke_shear_term,tke_buoy_term,tke_trans_term,Km_out,Kh_out) 60 64 61 65 … … 76 80 call atke_compute_km_kh(ngrid,nlay,dtime,& 77 81 wind_u_predict,wind_v_predict,temp,qvap,play,pinterf,cdrag_uv, & 78 tke,eps, Km_out,Kh_out)82 tke,eps,tke_shear_term,tke_buoy_term,tke_trans_term,Km_out,Kh_out) 79 83 80 84 end if 81 85 82 86 87 ! Diagnostics of tke loss/source terms 83 88 89 DO k=1,nlay+1 90 DO i=1,ngrid 91 j=ni(i) 92 tke_shear(j,k,nsrf)=tke_shear_term(i,k) 93 tke_buoy(j,k,nsrf)=tke_buoy_term(i,k) 94 tke_trans(j,k,nsrf)=tke_trans_term(i,k) 95 ENDDO 96 ENDDO 84 97 85 98 -
LMDZ6/trunk/libf/phylmd/pbl_surface_mod.F90
r5022 r5039 1996 1996 1997 1997 IF (iflag_pbl>=50) THEN 1998 CALL call_atke(dtime,knon,klev, ycdragm(1:knon), ycdragh(1:knon),yus0(1:knon),yvs0(1:knon),yts(1:knon), &1998 CALL call_atke(dtime,knon,klev,nsrf,ni,ycdragm(1:knon), ycdragh(1:knon),yus0(1:knon),yvs0(1:knon),yts(1:knon), & 1999 1999 yu(1:knon,:),yv(1:knon,:),yt(1:knon,:),yq(1:knon,:),ypplay(1:knon,:),ypaprs(1:knon,:), & 2000 2000 ytke(1:knon,:),yeps(1:knon,:), ycoefm(1:knon,:), ycoefh(1:knon,:)) … … 2041 2041 IF (iflag_pbl>=50) THEN 2042 2042 2043 CALL call_atke(dtime,knon,klev, ycdragm_x(1:knon),ycdragh_x(1:knon),yus0(1:knon),yvs0(1:knon),yts_x(1:knon), &2043 CALL call_atke(dtime,knon,klev,nsrf,ni,ycdragm_x(1:knon),ycdragh_x(1:knon),yus0(1:knon),yvs0(1:knon),yts_x(1:knon), & 2044 2044 yu_x(1:knon,:),yv_x(1:knon,:),yt_x(1:knon,:),yq_x(1:knon,:),ypplay(1:knon,:),ypaprs(1:knon,:), & 2045 2045 ytke_x(1:knon,:),yeps_x(1:knon,:),ycoefm_x(1:knon,:), ycoefh_x(1:knon,:)) … … 2081 2081 IF (iflag_pbl>=50) THEN 2082 2082 2083 CALL call_atke(dtime,knon,klev, ycdragm_w(1:knon),ycdragh_w(1:knon),yus0(1:knon),yvs0(1:knon),yts_w(1:knon), &2083 CALL call_atke(dtime,knon,klev,nsrf,ni,ycdragm_w(1:knon),ycdragh_w(1:knon),yus0(1:knon),yvs0(1:knon),yts_w(1:knon), & 2084 2084 yu_w(1:knon,:),yv_w(1:knon,:),yt_w(1:knon,:),yq_w(1:knon,:),ypplay(1:knon,:),ypaprs(1:knon,:), & 2085 2085 ytke_w(1:knon,:),yeps_w(1:knon,:),ycoefm_w(1:knon,:),ycoefh_w(1:knon,:)) -
LMDZ6/trunk/libf/phylmd/phys_local_var_mod.F90
r5007 r5039 26 26 REAL, SAVE, ALLOCATABLE :: pbl_eps(:,:,:) 27 27 !$OMP THREADPRIVATE(pbl_eps) 28 REAL, SAVE, ALLOCATABLE :: tke_shear(:,:,:), tke_buoy(:,:,:), tke_trans(:,:,:) 29 !$OMP THREADPRIVATE(tke_shear(:,:,:),tke_buoy(:,:,:),tke_trans(:,:,:)) 28 30 REAL, SAVE, ALLOCATABLE :: tr_seri(:,:,:) 29 31 !$OMP THREADPRIVATE(tr_seri) … … 694 696 ALLOCATE(l_mixmin(klon,klev+1,nbsrf),l_mix(klon,klev+1,nbsrf),wprime(klon,klev+1,nbsrf)) 695 697 ALLOCATE(pbl_eps(klon,klev+1,nbsrf+1)) 698 ALLOCATE(tke_shear(klon,klev+1,nbsrf), tke_buoy(klon,klev+1,nbsrf), tke_trans(klon,klev+1,nbsrf)) 696 699 pbl_eps(:,:,:)=0. 700 tke_shear(:,:,:)=0.; tke_buoy(:,:,:)=0.; tke_trans(:,:,:)=0. 697 701 l_mix(:,:,:)=0.;l_mixmin(:,:,:)=0.;wprime(:,:,:)=0. ! doit etre initialse car pas toujours remplis 698 702 ALLOCATE(rhcl(klon,klev)) … … 1055 1059 DEALLOCATE(u_seri,v_seri) 1056 1060 DEALLOCATE(l_mixmin,l_mix,wprime) 1061 DEALLOCATE(tke_shear,tke_buoy,tke_trans) 1057 1062 DEALLOCATE(pbl_eps) 1058 1063 DEALLOCATE(rhcl) -
LMDZ6/trunk/libf/phylmd/phys_output_ctrlout_mod.F90
r5007 r5039 1114 1114 TYPE(ctrl_out), SAVE :: o_tke = ctrl_out((/ 4, 10, 10, 10, 10, 10, 11, 11, 11, 11/), & 1115 1115 'tke ', 'TKE', 'm2/s2', (/ ('', i=1, 10) /)) 1116 TYPE(ctrl_out), SAVE :: o_tke_shear = ctrl_out((/ 11, 11, 11, 11, 11, 11, 11, 11, 11, 11/), & 1117 'tke_shear ', 'TKE shear term', 'm2/s3', (/ ('', i=1, 10) /)) 1118 TYPE(ctrl_out), SAVE :: o_tke_buoy = ctrl_out((/ 11, 11, 11, 11, 11, 11, 11, 11, 11, 11/), & 1119 'tke_buoy ', 'TKE buoyancy term', 'm2/s3', (/ ('', i=1, 10) /)) 1120 TYPE(ctrl_out), SAVE :: o_tke_trans = ctrl_out((/ 11, 11, 11, 11, 11, 11, 11, 11, 11, 11/), & 1121 'tke_trans ', 'TKE transport term', 'm2/s3', (/ ('', i=1, 10) /)) 1116 1122 TYPE(ctrl_out), SAVE :: o_tke_dissip = ctrl_out((/ 10, 10, 10, 10, 10, 10, 11, 11, 11, 11/), & 1117 'tke_dissip ', 'TKE DISSIPATION', 'm2/s3', (/ ('', i=1, 10) /)) 1123 'tke_dissip ', 'TKE dissipation term', 'm2/s3', (/ ('', i=1, 10) /)) 1124 1118 1125 TYPE(ctrl_out), SAVE :: o_tke_max = ctrl_out((/ 4, 10, 10, 10, 10, 10, 11, 11, 11, 11/), & 1119 1126 'tke_max', 'TKE max', 'm2/s2', & -
LMDZ6/trunk/libf/phylmd/phys_output_write_mod.F90
r5022 r5039 146 146 o_dqsphy, o_dqsphy2d, o_dqbsphy, o_dqbsphy2d, o_albe_srf, o_z0m_srf, o_z0h_srf, & 147 147 o_ages_srf, o_snow_srf, o_alb1, o_alb2, o_tke, o_tke_dissip, & 148 o_tke_max, o_kz, o_kz_max, o_clwcon, &148 o_tke_max, o_kz, o_kz_max, o_clwcon, o_tke_shear, o_tke_buoy, o_tke_trans, & 149 149 o_dtdyn, o_dqdyn, o_dqdyn2d, o_dqldyn, o_dqldyn2d, & 150 150 o_dqsdyn, o_dqsdyn2d, o_dqbsdyn, o_dqbsdyn2d, o_dudyn, o_dvdyn, & … … 314 314 zn2mout, t2m_min_mon, t2m_max_mon, evap, & 315 315 snowerosion, zxustartlic, zxrhoslic, zxqsaltlic, & 316 l_mixmin,l_mix, pbl_eps, &316 l_mixmin,l_mix, pbl_eps, tke_shear, tke_buoy, tke_trans, & 317 317 zu10m, zv10m, zq2m, zustar, zxqsurf, & 318 318 rain_lsc, rain_num, snow_lsc, bils, sens, fder, & … … 1313 1313 ENDIF 1314 1314 1315 CALL histwrite_phy(o_tke_dissip, zx_tmp_fi3d) 1315 CALL histwrite_phy(o_tke_dissip, zx_tmp_fi3d) 1316 1317 zx_tmp_fi3d=0. 1318 IF (vars_defined) THEN 1319 DO nsrf=1,nbsrf 1320 DO k=1,klev 1321 zx_tmp_fi3d(:,k)=zx_tmp_fi3d(:,k) & 1322 +pctsrf(:,nsrf)*tke_shear(:,k,nsrf) 1323 ENDDO 1324 ENDDO 1325 ENDIF 1326 1327 CALL histwrite_phy(o_tke_shear, zx_tmp_fi3d) 1328 1329 zx_tmp_fi3d=0. 1330 IF (vars_defined) THEN 1331 DO nsrf=1,nbsrf 1332 DO k=1,klev 1333 zx_tmp_fi3d(:,k)=zx_tmp_fi3d(:,k) & 1334 +pctsrf(:,nsrf)*tke_buoy(:,k,nsrf) 1335 ENDDO 1336 ENDDO 1337 ENDIF 1338 1339 CALL histwrite_phy(o_tke_buoy, zx_tmp_fi3d) 1340 1341 1342 zx_tmp_fi3d=0. 1343 IF (vars_defined) THEN 1344 DO nsrf=1,nbsrf 1345 DO k=1,klev 1346 zx_tmp_fi3d(:,k)=zx_tmp_fi3d(:,k) & 1347 +pctsrf(:,nsrf)*tke_trans(:,k,nsrf) 1348 ENDDO 1349 ENDDO 1350 ENDIF 1351 1352 CALL histwrite_phy(o_tke_trans, zx_tmp_fi3d) 1353 1316 1354 ENDIF 1317 1355 -
LMDZ6/trunk/libf/phylmdiso/phys_local_var_mod.F90
r5023 r5039 28 28 REAL, SAVE, ALLOCATABLE :: pbl_eps(:,:,:) 29 29 !$OMP THREADPRIVATE(pbl_eps) 30 REAL, SAVE, ALLOCATABLE :: tke_shear(:,:,:), tke_buoy(:,:,:), tke_trans(:,:,:) 31 !$OMP THREADPRIVATE(tke_shear(:,:,:),tke_buoy(:,:,:),tke_trans(:,:,:)) 30 32 REAL, SAVE, ALLOCATABLE :: tr_seri(:,:,:) 31 33 !$OMP THREADPRIVATE(tr_seri) … … 815 817 ALLOCATE(l_mixmin(klon,klev+1,nbsrf),l_mix(klon,klev+1,nbsrf),wprime(klon,klev+1,nbsrf)) 816 818 ALLOCATE(pbl_eps(klon,klev+1,nbsrf+1)) 819 ALLOCATE(tke_shear(klon,klev+1,nbsrf), tke_buoy(klon,klev+1,nbsrf), tke_trans(klon,klev+1,nbsrf)) 817 820 pbl_eps(:,:,:)=0. 821 tke_shear(:,:,:)=0.; tke_buoy(:,:,:)=0.; tke_trans(:,:,:)=0. 818 822 l_mix(:,:,:)=0.;l_mixmin(:,:,:)=0.;wprime(:,:,:)=0. ! doit etre initialse car pas toujours remplis 819 823 ALLOCATE(rhcl(klon,klev)) … … 1253 1257 DEALLOCATE(u_seri,v_seri) 1254 1258 DEALLOCATE(l_mixmin,l_mix,wprime) 1259 DEALLOCATE(tke_shear,tke_buoy,tke_trans) 1255 1260 DEALLOCATE(pbl_eps) 1256 1261 DEALLOCATE(rhcl) -
LMDZ6/trunk/libf/phylmdiso/phys_output_ctrlout_mod.F90
r5023 r5039 1114 1114 TYPE(ctrl_out), SAVE :: o_tke = ctrl_out((/ 4, 10, 10, 10, 10, 10, 11, 11, 11, 11/), & 1115 1115 'tke ', 'TKE', 'm2/s2', (/ ('', i=1, 10) /)) 1116 TYPE(ctrl_out), SAVE :: o_tke_shear = ctrl_out((/ 11, 11, 11, 11, 11, 11, 11, 11, 11, 11/), & 1117 'tke_shear ', 'TKE shear term', 'm2/s3', (/ ('', i=1, 10) /)) 1118 TYPE(ctrl_out), SAVE :: o_tke_buoy = ctrl_out((/ 11, 11, 11, 11, 11, 11, 11, 11, 11, 11/), & 1119 'tke_buoy ', 'TKE buoyancy term', 'm2/s3', (/ ('', i=1, 10) /)) 1120 TYPE(ctrl_out), SAVE :: o_tke_trans = ctrl_out((/ 11, 11, 11, 11, 11, 11, 11, 11, 11, 11/), & 1121 'tke_trans ', 'TKE transport term', 'm2/s3', (/ ('', i=1, 10) /)) 1116 1122 TYPE(ctrl_out), SAVE :: o_tke_dissip = ctrl_out((/ 10, 10, 10, 10, 10, 10, 11, 11, 11, 11/), & 1117 'tke_dissip ', 'TKE DISSIPATION', 'm2/s3', (/ ('', i=1, 10) /)) 1123 'tke_dissip ', 'TKE dissipation term', 'm2/s3', (/ ('', i=1, 10) /)) 1124 1118 1125 TYPE(ctrl_out), SAVE :: o_tke_max = ctrl_out((/ 4, 10, 10, 10, 10, 10, 11, 11, 11, 11/), & 1119 1126 'tke_max', 'TKE max', 'm2/s2', &
Note: See TracChangeset
for help on using the changeset viewer.