source: LMDZ5/branches/LMDZ5_SPLA/libf/phylmd/bcscav_spl.F @ 2175

Last change on this file since 2175 was 2175, checked in by jescribano, 10 years ago

SPLA code included for first time

File size: 1.7 KB
Line 
1      SUBROUTINE bcscav_spl(pdtime,flxr,flxs,alpha_r,alpha_s,x,dx)
2
3      USE dimphy
4      IMPLICIT NONE
5c=====================================================================
6c Objet : below-cloud scavenging of tracers
7c Date : september 1999
8c Auteur: O. Boucher (LOA)
9c=====================================================================
10c
11#include "dimensions.h"
12#include "chem.h"
13c #include "../phylmd/dimphy.h"
14#include "../phylmd/YOMCST.h"
15#include "../phylmd/YOECUMF.h"
16c
17      REAL pdtime, alpha_r, alpha_s, R_r, R_s
18      PARAMETER (R_r=0.001)          !--mean raindrop radius (m)
19      PARAMETER (R_s=0.001)          !--mean snow crystal radius (m)
20      REAL flxr(klon,klev)         ! liquid precipitation rate (kg/m2/s)
21      REAL flxs(klon,klev)         ! solid  precipitation rate (kg/m2/s)
22      REAL flxr_aux(klon,klev+1)
23      REAL flxs_aux(klon,klev+1)
24      REAL x(klon,klev)              ! q de traceur 
25      REAL dx(klon,klev)             ! tendance de traceur
26c
27c--variables locales     
28      INTEGER i, k
29      REAL pr, ps, ice, water
30c
31c------------------------------------------
32c
33! NHL
34! Auxiliary variables defined to deal with the fact that precipitation
35! fluxes are defined on klev levels only.
36! NHL
37!
38      flxr_aux(:,klev+1)=0.0
39      flxs_aux(:,klev+1)=0.0
40      flxr_aux(:,1:klev)=flxr(:,:)
41      flxs_aux(:,1:klev)=flxs(:,:)
42!
43      DO k=1, klev
44      DO i=1, klon
45       pr=0.5*(flxr_aux(i,k)+flxr_aux(i,k+1))
46       ps=0.5*(flxs_aux(i,k)+flxs_aux(i,k+1))
47       water=pr*alpha_r/R_r/rho_water
48       ice=ps*alpha_s/R_s/rho_ice
49       dx(i,k)=-3./4.*x(i,k)*pdtime*(water+ice)
50ctmp       dx(i,k)=-3./4.*x(i,k)*pdtime*
51ctmp     .         (pr*alpha_r/R_r/rho_water+ps*alpha_s/R_s/rho_ice)
52      ENDDO
53      ENDDO
54c
55      RETURN
56      END
Note: See TracBrowser for help on using the repository browser.