Changeset 4009
- Timestamp:
- Nov 17, 2021, 11:23:39 PM (3 years ago)
- Location:
- LMDZ6/trunk/libf
- Files:
-
- 2 added
- 1 deleted
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ6/trunk/libf/phylmd/calcratqs.F90
r3856 r4009 3 3 ratqsbas,ratqshaut,ratqsp0,ratqsdp, & 4 4 tau_ratqs,fact_cldcon,wake_s, wake_deltaq, & 5 ptconv,ptconvth,clwcon0th, rnebcon0th, & 6 paprs,pplay,q_seri,zqsat,fm_therm, & 5 ptconv,ptconvth,clwcon0th, rnebcon0th, & 6 paprs,pplay,t_seri,q_seri, & 7 qtc_cv, sigt_cv, zqsat, & 8 tke,tke_dissip,lmix,wprime, & 9 t2m,q2m,fm_therm, & 7 10 ratqs,ratqsc,ratqs_inter) 11 12 13 USE indice_sol_mod 14 USE phys_state_var_mod, ONLY: pctsrf 15 USE calcratqs_multi_mod, ONLY: calcratqs_inter, calcratqs_oro, calcratqs_hetero, calcratqs_tke 8 16 9 17 implicit none … … 23 31 real,intent(in) :: pdtphys,ratqsbas,ratqshaut,fact_cldcon,tau_ratqs 24 32 real,intent(in) :: ratqsp0, ratqsdp 25 real, dimension(klon,klev+1),intent(in) :: paprs 26 real, dimension(klon,klev),intent(in) :: pplay, q_seri,zqsat,fm_therm33 real, dimension(klon,klev+1),intent(in) :: paprs,tke,tke_dissip,lmix,wprime 34 real, dimension(klon,klev),intent(in) :: pplay,t_seri,q_seri,zqsat,fm_therm, qtc_cv, sigt_cv 27 35 logical, dimension(klon,klev),intent(in) :: ptconv 28 36 real, dimension(klon,klev),intent(in) :: rnebcon0th,clwcon0th 29 37 real, dimension(klon,klev),intent(in) :: wake_deltaq,wake_s 38 real, dimension(klon,nbsrf),intent(in) :: t2m,q2m 30 39 ! Output 31 40 real, dimension(klon,klev),intent(inout) :: ratqs,ratqsc,ratqs_inter 41 32 42 logical, dimension(klon,klev),intent(inout) :: ptconvth 33 43 … … 36 46 real, dimension(klon,klev) :: ratqss 37 47 real facteur,zfratqs1,zfratqs2 48 real, dimension(klon,klev) :: ratqs_hetero,ratqs_oro,ratqs_tke 49 38 50 39 51 !------------------------------------------------------------------------- … … 131 143 enddo 132 144 133 else if (iflag_ratqs==10) then ! ratqs interactif dépendant de la présence de poches froides 134 call calcratqs_inter(klon,klev,pdtphys,ratqsbas,wake_deltaq,wake_s,q_seri,ratqs_inter) 135 do k=1,klev 136 do i=1, klon 137 ratqss(i,k)=ratqs_inter(i,k)+0.5*(ratqshaut-ratqs_inter(i,k)) & 138 *( tanh( (ratqsp0-pplay(i,k))/ratqsdp) + 1.) 139 enddo 140 enddo 141 145 else if (iflag_ratqs .GT. 9) then 146 147 ! interactive ratqs calculations that depend on cold pools, orography, surface heterogeneity and small-scale turbulence 148 ! This should help getting a more realistic ratqs in the low and mid troposphere 149 ! We however need a "background" ratqs to account for subgrid distribution of qt (or qt/qs) 150 ! in the high troposphere 151 152 ! background ratqs and initialisations 153 do k=1,klev 154 do i=1,klon 155 ratqss(i,k)=ratqsbas+0.5*(ratqshaut-ratqsbas) & 156 *( tanh( (ratqsp0-pplay(i,k))/ratqsdp) + 1.) 157 ratqss(i,k)=max(ratqss(i,k),0.0) 158 159 ratqs_hetero(i,k)=0. 160 ratqs_oro(i,k)=0. 161 ratqs_tke(i,k)=0. 162 ratqs_inter(i,k)=0 163 enddo 164 enddo 165 166 if (iflag_ratqs .EQ. 10) then 167 ! interactive ratqs in presence of cold pools 168 call calcratqs_inter(klon,klev,iflag_ratqs,pdtphys,ratqsbas,wake_deltaq,wake_s,q_seri,qtc_cv, sigt_cv,ratqs_inter) 169 do k=1,klev 170 do i=1,klon 171 ratqs_inter(i,k)=ratqs_inter(i,k)-0.5*ratqs_inter(i,k)*(tanh((ratqsp0-pplay(i,k))/ratqsdp)+1.) 172 enddo 173 enddo 174 ratqss=ratqss+ratqs_inter 175 else if (iflag_ratqs .EQ. 11) then 176 ! interactive ratqs with several sources 177 call calcratqs_inter(klon,klev,iflag_ratqs,pdtphys,ratqsbas,wake_deltaq,wake_s,q_seri,qtc_cv, sigt_cv,ratqs_inter) 178 ratqss=ratqss+ratqs_inter 179 else if (iflag_ratqs .EQ. 12) then 180 ! contribution of surface heterogeneities to ratqs 181 call calcratqs_hetero(klon,klev,t2m,q2m,t_seri,q_seri,pplay,paprs,ratqs_hetero) 182 ratqss=ratqss+ratqs_hetero 183 else if (iflag_ratqs .EQ. 13) then 184 ! contribution of ubgrid orography to ratqs 185 call calcratqs_oro(klon,klev,zqsat,t_seri,pplay,paprs,ratqs_oro) 186 ratqss=ratqss+ratqs_oro 187 else if (iflag_ratqs .EQ. 14) then 188 ! effect of subgrid-scale TKE on ratqs (in development) 189 call calcratqs_tke(klon,klev,pdtphys,t_seri,q_seri,zqsat,pplay,paprs,tke,tke_dissip,lmix,wprime,ratqs_tke) 190 ratqss=ratqss+ratqs_tke 191 endif 192 193 142 194 endif 143 195 -
LMDZ6/trunk/libf/phylmd/phys_local_var_mod.F90
r3999 r4009 16 16 REAL, SAVE, ALLOCATABLE :: u_seri(:,:), v_seri(:,:) 17 17 !$OMP THREADPRIVATE(u_seri, v_seri) 18 REAL, SAVE, ALLOCATABLE :: l_mixmin(:,:,:), l_mix(:,:,:), tke_dissip(:,:,:)19 !$OMP THREADPRIVATE(l_mixmin, l_mix, tke_dissip )18 REAL, SAVE, ALLOCATABLE :: l_mixmin(:,:,:),l_mix(:,:,:),tke_dissip(:,:,:),wprime(:,:,:) 19 !$OMP THREADPRIVATE(l_mixmin, l_mix, tke_dissip,wprime) 20 20 REAL, SAVE, ALLOCATABLE :: tr_seri(:,:,:) 21 21 !$OMP THREADPRIVATE(tr_seri) … … 559 559 ALLOCATE(t_seri(klon,klev),q_seri(klon,klev),ql_seri(klon,klev),qs_seri(klon,klev)) 560 560 ALLOCATE(u_seri(klon,klev),v_seri(klon,klev)) 561 ALLOCATE(l_mixmin(klon,klev+1,nbsrf), l_mix(klon,klev+1,nbsrf), tke_dissip(klon,klev+1,nbsrf))562 l_mix(:,:,:)=0. ; l_mixmin(:,:,:)=0. ; tke_dissip(:,:,:)=0. ! doit etre initialse car pas toujours remplis561 ALLOCATE(l_mixmin(klon,klev+1,nbsrf),l_mix(klon,klev+1,nbsrf),tke_dissip(klon,klev+1,nbsrf),wprime(klon,klev+1,nbsrf)) 562 l_mix(:,:,:)=0.;l_mixmin(:,:,:)=0.;tke_dissip(:,:,:)=0.;wprime(:,:,:)=0. ! doit etre initialse car pas toujours remplis 563 563 564 564 ALLOCATE(tr_seri(klon,klev,nbtr)) … … 878 878 DEALLOCATE(t_seri,q_seri,ql_seri,qs_seri) 879 879 DEALLOCATE(u_seri,v_seri) 880 DEALLOCATE(l_mixmin,l_mix, tke_dissip )880 DEALLOCATE(l_mixmin,l_mix, tke_dissip,wprime) 881 881 882 882 DEALLOCATE(tr_seri) -
LMDZ6/trunk/libf/phylmd/physiq_mod.F90
r3999 r4009 220 220 d_t_vdf_x, d_t_vdf_w, & 221 221 d_q_vdf_x, d_q_vdf_w, & 222 pbl_tke_input, &222 pbl_tke_input, tke_dissip, l_mix, wprime,& 223 223 t_therm, q_therm, u_therm, v_therm, & 224 224 cdragh_x, cdragh_w, & … … 1186 1186 integer iostat 1187 1187 1188 REAL, dimension(klon,klev+1) :: tke_dissip_ave, l_mix_ave, wprime_ave 1188 1189 REAL zzz 1189 1190 !albedo SB >>> … … 3498 3499 ! Computation of ratqs, the width (normalized) of the subrid scale 3499 3500 ! water distribution 3501 3502 tke_dissip_ave(:,:)=0. 3503 l_mix_ave(:,:)=0. 3504 wprime_ave(:,:)=0. 3505 3506 3507 DO nsrf = 1, nbsrf 3508 DO i = 1, klon 3509 tke_dissip_ave(i,:) = tke_dissip_ave(i,:) + tke_dissip(i,:,nsrf)*pctsrf(i,nsrf) 3510 l_mix_ave(i,:) = l_mix_ave(i,:) + l_mix(i,:,nsrf)*pctsrf(i,nsrf) 3511 wprime_ave(i,:) = wprime_ave(i,:) + wprime(i,:,nsrf)*pctsrf(i,nsrf) 3512 ENDDO 3513 ENDDO 3514 3515 3500 3516 CALL calcratqs(klon,klev,prt_level,lunout, & 3501 3517 iflag_ratqs,iflag_con,iflag_cld_th,pdtphys, & … … 3503 3519 tau_ratqs,fact_cldcon,wake_s, wake_deltaq, & 3504 3520 ptconv,ptconvth,clwcon0th, rnebcon0th, & 3505 paprs,pplay,q_seri,zqsat,fm_therm, & 3521 paprs,pplay,t_seri,q_seri, qtc_cv, sigt_cv, zqsat, & 3522 pbl_tke(:,:,is_ave),tke_dissip_ave,l_mix_ave,wprime_ave,t2m,q2m,fm_therm, & 3506 3523 ratqs,ratqsc,ratqs_inter) 3507 3524 -
LMDZ6/trunk/libf/phylmd/yamada4.F90
r3784 r4009 6 6 USE dimphy 7 7 USE ioipsl_getin_p_mod, ONLY : getin_p 8 USE phys_local_var_mod, only: tke_dissip 8 USE phys_local_var_mod, only: tke_dissip,wprime 9 9 10 10 IMPLICIT NONE … … 726 726 lyam(1:ngrid, 2:klev)*5.17*kn(1:ngrid, 2:klev)*n2(1:ngrid, 2:klev)/ & 727 727 sqrt(q2(1:ngrid,2:klev)) 728 728 729 729 t2yam(1:ngrid, 2:klev) = 9.1*kn(1:ngrid, 2:klev)* & 730 730 dtetadz(1:ngrid, 2:klev)**2/sqrt(q2(1:ngrid,2:klev))* & … … 750 750 751 751 !============================================================================ 752 ! Diagnostique de la dissipation 752 ! Diagnostique de la dissipation et vitesse verticale 753 753 !============================================================================ 754 754 755 755 ! Diagnostics 756 756 tke_dissip(1:ngrid,:,nsrf)=0. 757 ! DO k=2,klev 758 ! DO ig=1,ngrid 759 ! jg=ni(ig) 760 ! tke_dissip(jg,k,nsrf)=dissip(ig,k) 761 ! ENDDO 762 ! ENDDO 757 wprime(1:ngrid,:,nsrf)=0. 758 DO k=2,klev 759 DO ig=1,ngrid 760 jg=ni(ig) 761 wprime(jg,k,nsrf)=sqrt(MAX(1./3*q2(ig,k),0.)) 762 tke_dissip(jg,k,nsrf)=dissip(ig,k) 763 ENDDO 764 ENDDO 763 765 764 766 !============================================================================= -
LMDZ6/trunk/libf/phylmdiso/phys_local_var_mod.F90
r4003 r4009 16 16 REAL, SAVE, ALLOCATABLE :: u_seri(:,:), v_seri(:,:) 17 17 !$OMP THREADPRIVATE(u_seri, v_seri) 18 REAL, SAVE, ALLOCATABLE :: l_mixmin(:,:,:), l_mix(:,:,:), tke_dissip(:,:,:) 19 !$OMP THREADPRIVATE(l_mixmin, l_mix, tke_dissip )18 REAL, SAVE, ALLOCATABLE :: l_mixmin(:,:,:), l_mix(:,:,:), tke_dissip(:,:,:), wprime(:,:,:) 19 !$OMP THREADPRIVATE(l_mixmin, l_mix, tke_dissip, wprime) 20 20 REAL, SAVE, ALLOCATABLE :: tr_seri(:,:,:) 21 21 !$OMP THREADPRIVATE(tr_seri) … … 693 693 ALLOCATE(t_seri(klon,klev),q_seri(klon,klev),ql_seri(klon,klev),qs_seri(klon,klev)) 694 694 ALLOCATE(u_seri(klon,klev),v_seri(klon,klev)) 695 ALLOCATE(l_mixmin(klon,klev+1,nbsrf), l_mix(klon,klev+1,nbsrf), tke_dissip(klon,klev+1,nbsrf) )696 l_mix(:,:,:)=0. ; l_mixmin(:,:,:)=0. ; tke_dissip(:,:,:)=0. ! doit etre initialse car pas toujours remplis695 ALLOCATE(l_mixmin(klon,klev+1,nbsrf), l_mix(klon,klev+1,nbsrf), tke_dissip(klon,klev+1,nbsrf), wprime(klon,klev+1,nbsrf)) 696 l_mix(:,:,:)=0. ; l_mixmin(:,:,:)=0. ; tke_dissip(:,:,:)=0. ; wprime(:,:,:)=0. ! doit etre initialse car pas toujours remplis 697 697 698 698 ALLOCATE(tr_seri(klon,klev,nbtr)) … … 1090 1090 DEALLOCATE(t_seri,q_seri,ql_seri,qs_seri) 1091 1091 DEALLOCATE(u_seri,v_seri) 1092 DEALLOCATE(l_mixmin,l_mix, tke_dissip )1092 DEALLOCATE(l_mixmin,l_mix, tke_dissip, wprime) 1093 1093 1094 1094 DEALLOCATE(tr_seri) -
LMDZ6/trunk/libf/phylmdiso/physiq_mod.F90
r4003 r4009 264 264 d_t_vdf_x, d_t_vdf_w, & 265 265 d_q_vdf_x, d_q_vdf_w, & 266 pbl_tke_input, &266 pbl_tke_input, tke_dissip, l_mix, wprime, & 267 267 t_therm, q_therm, u_therm, v_therm, & 268 268 cdragh_x, cdragh_w, & … … 1288 1288 integer iostat 1289 1289 1290 REAL, dimension(klon,klev+1) :: tke_dissip_ave, l_mix_ave, wprime_ave 1290 1291 REAL zzz 1291 1292 !albedo SB >>> … … 4468 4469 ! Computation of ratqs, the width (normalized) of the subrid scale 4469 4470 ! water distribution 4470 CALL calcratqs(klon,klev,prt_level,lunout, & 4471 4472 tke_dissip_ave(:,:)=0. 4473 l_mix_ave(:,:)=0. 4474 wprime_ave(:,:)=0. 4475 4476 DO nsrf = 1, nbsrf 4477 DO i = 1, klon 4478 tke_dissip_ave(i,:) = tke_dissip_ave(i,:) + tke_dissip(i,:,nsrf)*pctsrf(i,nsrf) 4479 l_mix_ave(i,:) = l_mix_ave(i,:) + l_mix(i,:,nsrf)*pctsrf(i,nsrf) 4480 wprime_ave(i,:) = wprime_ave(i,:) + wprime(i,:,nsrf)*pctsrf(i,nsrf) 4481 ENDDO 4482 ENDDO 4483 4484 CALL calcratqs(klon,klev,prt_level,lunout, & 4471 4485 iflag_ratqs,iflag_con,iflag_cld_th,pdtphys, & 4472 4486 ratqsbas,ratqshaut,ratqsp0, ratqsdp, & 4473 4487 tau_ratqs,fact_cldcon,wake_s, wake_deltaq, & 4474 4488 ptconv,ptconvth,clwcon0th, rnebcon0th, & 4475 paprs,pplay,q_seri,zqsat,fm_therm, & 4489 paprs,pplay,t_seri,q_seri, qtc_cv, sigt_cv, zqsat, & 4490 pbl_tke(:,:,is_ave),tke_dissip_ave,l_mix_ave,wprime_ave,t2m,q2m,fm_therm, & 4476 4491 ratqs,ratqsc,ratqs_inter) 4492 4477 4493 4478 4494 !
Note: See TracChangeset
for help on using the changeset viewer.