1 | |
---|
2 | ! $Id$ |
---|
3 | |
---|
4 | SUBROUTINE freinage(knon, uu, vv, & |
---|
5 | tt,veget,lai, height,ypaprs,ypplay,drag_pro,d_u,d_v) |
---|
6 | |
---|
7 | !ONLINE: |
---|
8 | USE dimphy, ONLY: klon, klev |
---|
9 | USE lmdz_clesphys |
---|
10 | USE lmdz_compbl, ONLY: iflag_pbl, iflag_pbl_split, iflag_order2_sollw, ifl_pbltree |
---|
11 | USE lmdz_dimpft, ONLY: nvm_lmdz |
---|
12 | ! USE control, ONLY: nvm |
---|
13 | ! USE indice_sol_mod, ONLY: nvm_orch |
---|
14 | |
---|
15 | IMPLICIT NONE |
---|
16 | |
---|
17 | |
---|
18 | include "YOMCST.h" |
---|
19 | include "YOEGWD.h" |
---|
20 | |
---|
21 | ! 0. DECLARATIONS: |
---|
22 | |
---|
23 | ! 0.1 INPUTS |
---|
24 | |
---|
25 | REAL, DIMENSION(klon,klev), INTENT(IN) :: ypplay |
---|
26 | REAL, DIMENSION(klon,klev+1), INTENT(IN) :: ypaprs |
---|
27 | |
---|
28 | |
---|
29 | REAL, DIMENSION(klon, klev), INTENT(IN) :: uu |
---|
30 | REAL, DIMENSION(klon, klev), INTENT(IN) :: vv |
---|
31 | REAL, DIMENSION(klon, klev), INTENT(IN) :: tt |
---|
32 | REAL, DIMENSION(klon,nvm_lmdz), INTENT(IN) :: veget,lai |
---|
33 | REAL, DIMENSION(klon,nvm_lmdz), INTENT(IN) :: height |
---|
34 | |
---|
35 | REAL, DIMENSION(klon,klev) :: wind |
---|
36 | REAL, DIMENSION(klon, klev) :: yzlay |
---|
37 | INTEGER knon |
---|
38 | |
---|
39 | ! 0.2 OUTPUTS |
---|
40 | |
---|
41 | REAL, DIMENSION(klon, klev), INTENT(OUT) :: d_v ! change in v |
---|
42 | REAL, DIMENSION(klon, klev), INTENT(OUT) :: d_u ! change in v |
---|
43 | !knon nombre de points concernes |
---|
44 | REAL, DIMENSION(klon,klev) :: sumveg ! change in v |
---|
45 | |
---|
46 | REAL, DIMENSION(klon,klev), INTENT(OUT) :: drag_pro |
---|
47 | ! (KLON, KLEV) tendencies on winds |
---|
48 | |
---|
49 | |
---|
50 | INTEGER k,jv,i |
---|
51 | |
---|
52 | |
---|
53 | !FCCCC REAL Cd_frein |
---|
54 | |
---|
55 | ! 0.3.1 LOCAL VARIABLE |
---|
56 | |
---|
57 | |
---|
58 | !----------------------------------------------------------------- |
---|
59 | |
---|
60 | ! 1. INITIALISATIONS |
---|
61 | |
---|
62 | |
---|
63 | ! Cd_frein = 7.5E-2 ! (0.075) ! Drag from MASSON 2009 |
---|
64 | !FC ESSAI |
---|
65 | ! Cd_frein = 1.5E-2 ! (0.075) ! Drag from MASSON 2009 |
---|
66 | ! Cd_frein = 0.005 ! (0.075) ! Drag from MASSON 2009 |
---|
67 | |
---|
68 | ! initialisation |
---|
69 | d_u(:,:) =0. |
---|
70 | d_v(:,:) =0. |
---|
71 | drag_pro(:,:) =0. |
---|
72 | sumveg(:,:) =0. |
---|
73 | !! PRINT*, "Cd_frein" , Cd_frein |
---|
74 | |
---|
75 | wind(:,:)= sqrt(uu(:,:)*uu(:,:)+vv(:,:)*vv(:,:)) |
---|
76 | |
---|
77 | yzlay(1:knon,1)= & |
---|
78 | RD*tt(1:knon,1)/(0.5*(ypaprs(1:knon,1)+ypplay(1:knon,1))) & |
---|
79 | *(ypaprs(1:knon,1)-ypplay(1:knon,1))/RG |
---|
80 | DO k=2,klev |
---|
81 | yzlay(1:knon,k)= & |
---|
82 | yzlay(1:knon,k-1)+RD*0.5*(tt(1:knon,k-1)+tt(1:knon,k)) & |
---|
83 | /ypaprs(1:knon,k)*(ypplay(1:knon,k-1)-ypplay(1:knon,k))/RG |
---|
84 | END DO |
---|
85 | |
---|
86 | ! verifier les indexes ..... |
---|
87 | !! PRINT*, " calcul de drag_pro FC " |
---|
88 | |
---|
89 | do k= 1,klev |
---|
90 | |
---|
91 | do jv=2,nvm_lmdz ! (on peut faire 9 ?) |
---|
92 | |
---|
93 | do i=1,knon |
---|
94 | |
---|
95 | sumveg(i,k)= sumveg(i,k)+ veget(i,jv) |
---|
96 | |
---|
97 | ! if ( (height(i,jv) .gt. yzlay(i,k)) .AND. (height(i,jv) .gt. 0.1) .AND. LAI(i,jv).gt.0. ) THEN |
---|
98 | IF ( (height(i,jv) > yzlay(i,k)) .AND. (height(i,jv) > 0.1) ) THEN |
---|
99 | !FC attention veut on le test sur le LAI ? |
---|
100 | IF (ifl_pbltree==1) THEN |
---|
101 | drag_pro(i,k)= drag_pro(i,k)+ & |
---|
102 | veget(i,jv) |
---|
103 | elseif (ifl_pbltree==2) THEN |
---|
104 | drag_pro(i,k)= drag_pro(i,k)+ & |
---|
105 | 6*LAI(i,jv)*veget(i,jv)*( yzlay(i,k)*(height(i,jv)-yzlay(i,k))/(height(i,jv)*height(i,jv)+ 0.01)) |
---|
106 | elseif (ifl_pbltree==3) THEN |
---|
107 | drag_pro(i,k)= drag_pro(i,k)+ & |
---|
108 | veget(i,jv)*( yzlay(i,k)*(height(i,jv)-yzlay(i,k))/(height(i,jv)*height(i,jv)+ 0.01)) |
---|
109 | elseif (ifl_pbltree==0) THEN |
---|
110 | drag_pro(i,k)=0.0 |
---|
111 | endif |
---|
112 | else |
---|
113 | drag_pro(i,k)= drag_pro(i,k) |
---|
114 | endif |
---|
115 | |
---|
116 | |
---|
117 | enddo |
---|
118 | enddo |
---|
119 | enddo |
---|
120 | do k=1,klev |
---|
121 | where (sumveg(1:knon,k) > 0.05 ) |
---|
122 | ! drag_pro(1:knon,k)=Cd_frein*drag_pro(1:knon,k)/sumveg(1:knon,k) |
---|
123 | drag_pro(1:knon,k)=Cd_frein*drag_pro(1:knon,k) |
---|
124 | elsewhere |
---|
125 | drag_pro(1:knon,k)=0.0 |
---|
126 | endwhere |
---|
127 | d_u(1:knon,k) =(-1)*drag_pro(1:knon,k)*uu(1:knon,k)*wind(1:knon,k) |
---|
128 | d_v(1:knon,k) =(-1)*drag_pro(1:knon,k)*vv(1:knon,k)*wind(1:knon,k) |
---|
129 | enddo |
---|
130 | |
---|
131 | |
---|
132 | END SUBROUTINE freinage |
---|
133 | |
---|