/[lmdze]/trunk/phylmd/Radlwsw/sw.f
ViewVC logotype

Diff of /trunk/phylmd/Radlwsw/sw.f

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

trunk/libf/phylmd/Radlwsw/sw.f90 revision 70 by guez, Mon Jun 24 15:39:52 2013 UTC trunk/phylmd/Radlwsw/sw.f revision 118 by guez, Thu Dec 18 17:30:24 2014 UTC
# Line 10  contains Line 10  contains
10         ZFSDN0, tauae, pizae, cgae, PTAUA, POMEGAA, PTOPSWAD, PSOLSWAD, &         ZFSDN0, tauae, pizae, cgae, PTAUA, POMEGAA, PTOPSWAD, PSOLSWAD, &
11         PTOPSWAI, PSOLSWAI, ok_ade, ok_aie)         PTOPSWAI, PSOLSWAI, ok_ade, ok_aie)
12    
13      ! PURPOSE.      ! Purpose.
14      ! THIS ROUTINE COMPUTES THE SHORTWAVE RADIATION FLUXES IN TWO      ! This routine computes the shortwave radiation fluxes in two
15      ! SPECTRAL INTERVALS FOLLOWING FOUQUART AND BONNEL (1980).      ! spectral intervals following Fouquart and Bonnel (1980).
16    
17      ! METHOD.      ! Method.
18      ! 1. COMPUTES ABSORBER AMOUNTS (SWU)      ! 1. Computes absorber amounts (swu)
19      ! 2. COMPUTES FLUXES IN 1ST SPECTRAL INTERVAL (SW1S)      ! 2. Computes fluxes in 1st spectral interval (SW1S)
20      ! 3. COMPUTES FLUXES IN 2ND SPECTRAL INTERVAL (SW2S)      ! 3. Computes fluxes in 2nd spectral interval (SW2S)
21    
22      ! REFERENCE.      ! Reference.
23      ! SEE RADIATION PART OF THE ECMWF RESEARCH DEPARTMENT      ! See radiation part of the ECMWF research department
24      ! DOCUMENTATION, AND FOUQUART AND BONNEL (1980)      ! documentation, and Fouquart and Bonnel (1980)
25    
26      ! AUTHOR.      ! Author.
27      ! JEAN-JACQUES MORCRETTE *ECMWF*      ! Jean-Jacques Morcrette *ecmwf*
28    
29      ! MODIFICATIONS.      ! Modifications.
30      ! ORIGINAL: 89-07-14      ! Original: 89-07-14
31      ! 95-01-01 J.-J. MORCRETTE Direct/Diffuse Albedo      ! 95-01-01 J.-J. Morcrette direct/diffuse albedo
32      ! 03-11-27 J. QUAAS Introduce aerosol forcings (based on BOUCHER)      ! 03-11-27 J. Quaas Introduce aerosol forcings (based on Boucher)
33    
     USE clesphys, ONLY: bug_ozone  
     USE suphec_m, ONLY: rcpd, rday, rg, md, rmo3  
34      USE raddim, ONLY: kdlon, kflev      USE raddim, ONLY: kdlon, kflev
35        USE suphec_m, ONLY: rcpd, rday, rg
36    
37      ! ARGUMENTS:      ! ARGUMENTS:
38    
# Line 92  contains Line 91  contains
91    
92      INTEGER inu, jl, jk, i, k, kpl1      INTEGER inu, jl, jk, i, k, kpl1
93    
94      INTEGER swpas ! Every swpas steps, sw is calculated      INTEGER, PARAMETER:: swpas = 1 ! Every swpas steps, sw is calculated
     PARAMETER(swpas=1)  
95    
96      INTEGER itapsw      INTEGER:: itapsw = 0
97      LOGICAL appel1er      LOGICAL:: appel1er = .TRUE.
     DATA itapsw /0/  
     DATA appel1er /.TRUE./  
98      !jq-Introduced for aerosol forcings      !jq-Introduced for aerosol forcings
99      double precision flag_aer      double precision, save:: flag_aer
100      logical, intent(in):: ok_ade, ok_aie ! use aerosol forcings or not?      logical, intent(in):: ok_ade, ok_aie ! use aerosol forcings or not?
101      double precision tauae(kdlon, kflev, 2) ! aerosol optical properties      double precision tauae(kdlon, kflev, 2) ! aerosol optical properties
102      double precision pizae(kdlon, kflev, 2)      double precision pizae(kdlon, kflev, 2)
# Line 124  contains Line 120  contains
120      ! (diagnosed aerosol forcing)SHORTWAVE FLUX AT SURFACE(+AEROSOL IND)      ! (diagnosed aerosol forcing)SHORTWAVE FLUX AT SURFACE(+AEROSOL IND)
121    
122      !jq - Fluxes including aerosol effects      !jq - Fluxes including aerosol effects
123      DOUBLE PRECISION ZFSUPAD(KDLON, KFLEV+1)      DOUBLE PRECISION, save:: ZFSUPAD(KDLON, KFLEV+1)
124      DOUBLE PRECISION ZFSDNAD(KDLON, KFLEV+1)      DOUBLE PRECISION, save:: ZFSDNAD(KDLON, KFLEV+1)
125      DOUBLE PRECISION ZFSUPAI(KDLON, KFLEV+1)      DOUBLE PRECISION, save:: ZFSUPAI(KDLON, KFLEV+1)
126      DOUBLE PRECISION ZFSDNAI(KDLON, KFLEV+1)      DOUBLE PRECISION, save:: ZFSDNAI(KDLON, KFLEV+1)
127      logical initialized  
128      SAVE ZFSUPAD, ZFSDNAD, ZFSUPAI, ZFSDNAI ! aerosol fluxes      logical:: initialized = .false.
129      !rv      REAL, PARAMETER :: dobson_u = 2.1415E-05 ! Dobson unit, in kg m-2
     save flag_aer  
     data initialized/.false./  
130    
131      !-------------------------------------------------------------------      !-------------------------------------------------------------------
132    
133      if(.not.initialized) then      if(.not.initialized) then
134         flag_aer=0.         flag_aer=0.
135         initialized=.TRUE.         initialized=.TRUE.
136           ZFSUPAD = 0.
137           ZFSDNAD = 0.
138           ZFSUPAI = 0.
139           ZFSDNAI = 0.
140      endif      endif
141      !rv      !rv
142    
# Line 152  contains Line 150  contains
150         DO JK = 1 , KFLEV         DO JK = 1 , KFLEV
151            DO JL = 1, KDLON            DO JL = 1, KDLON
152               ZCLDSW0(JL, JK) = 0.0               ZCLDSW0(JL, JK) = 0.0
153               IF (bug_ozone) then               ZOZ(JL, JK) = POZON(JL, JK) / (dobson_u * 1E3 * rg) * PDP(JL, JK)
                 ZOZ(JL, JK) = POZON(JL, JK)*46.6968/RG &  
                      *PDP(JL, JK)*(101325.0/PPSOL(JL))  
              ELSE  
                 ! Correction MPL 100505  
                 ZOZ(JL, JK) = POZON(JL, JK)*MD/RMO3*46.6968/RG*PDP(JL, JK)  
              ENDIF  
154            ENDDO            ENDDO
155         ENDDO         ENDDO
156    

Legend:
Removed from v.70  
changed lines
  Added in v.118

  ViewVC Help
Powered by ViewVC 1.1.21