source: trunk/LMDZ.TITAN/libf/phytitan/inicondens.F90 @ 1715

Last change on this file since 1715 was 1672, checked in by jvatant, 8 years ago

Re-plug chemistry of old Titan
+ minor correction on reading Titan's startfiles and haze routine
JVO

File size: 6.5 KB
Line 
1      SUBROUTINE inicondens(ny,press,temp,nomy,yc)
2
3!==================================================================================
4!        Purpose
5!        -------
6!        Initialisation des profils de saturation des traceurs
7!
8!        Authors
9!        -------
10!        S. Lebonnois
11!        J. Vatant d'Ollone (2017) : adaptation au nouveau titan et passage en F90
12!==================================================================================
13
14       
15!-----------------------------------------------------------------------
16!   Declarations:
17!   -------------
18
19      use dimphy
20      use mod_grid_phy_lmdz, only: nbp_lev
21      IMPLICIT NONE
22
23!    Arguments :
24!    -----------
25      INTEGER, INTENT(IN)     :: ny
26      CHARACTER*10,INTENT(IN) :: nomy(ny+1)
27      REAL, INTENT(IN)        :: press(nbp_lev),temp(nbp_lev)  ! pressure in mbar !
28      REAL, INTENT(OUT)       :: yc(nbp_lev,ny)
29     
30!    Local variables :
31!    -----------------
32      INTEGER                 ::  l,ic
33      REAL                    ::  sy,x
34       
35      do ic=1,ny
36       print*, 'traceur CH(', ic, ')=', nomy(ic),'------------'
37           do l=1,nbp_lev
38
39!  Par defaut, yc est a 1 c'est a dire qu'on ne condense pas
40              yc(l,ic)=1.
41
42              if(nomy(ic).eq."CH4") then
43                 if (temp(l).lt.90.65) then
44                   yc(l,ic)= 10.0**(4.42507e0 - ( ( ( 1165560.7e0 / TEMP(l) - &
45                        115352.19e0 ) / TEMP(l) + 4055.6016e0 ) / TEMP(l)     &
46                        + 453.92414e0 ) / TEMP(l) ) / PRESS(l) * 1013.25e0
47                 else
48                    yc(l,ic)= 10.0**(3.901408e0 - ( ( 154567.02e0 / TEMP(l) -  &
49                         1598.8512e0 ) / TEMP(l) + 437.54809e0 ) / TEMP(l))    &
50                         / PRESS(l) * 1013.25e0;
51                 endif
52! maintient a 1.4% minimum               
53                 if (yc(l,ic).lt.0.014) yc(l,ic)=0.014
54              endif
55
56              if(nomy(ic).eq."C2H2") then
57                 yc(l,ic)= 10.0**(6.09748e0-1644.1e0/TEMP(l)+7.42346e0     &
58                      * alog10(1.0e3/TEMP(l)) ) / PRESS(l)*1013.25e0/760.0
59              endif
60
61              if(nomy(ic).eq."C2H4") then
62                 if (temp(l).lt.89.0) then
63                   yc(l,ic)= 10.0**(1.5477e0 + (1.0e0/TEMP(l) - 0.011e0)     &
64                        *(16537.0e0*(1.0e0/TEMP(l) - 0.011e0) - 1038.1e0))   &
65                        / PRESS(l) * 1.01325e0 / 760.0
66                 elseif (temp(l).lt.104.0) then
67                   yc(l,ic)= 10.0**(8.724e0 - 901.6e0/(TEMP(l) - 2.555e0) )  &
68                        / PRESS(l) * 1013.25e0 / 760.0
69                 elseif (temp(l).lt.120.0) then
70                   yc(l,ic)= 10.0**(50.79e0 - 1703.0e0/TEMP(l) - 17.141e0 *  &
71                        alog10(TEMP(l)) ) / PRESS(l) * 1013.25e0 / 760.0
72                 elseif (temp(l).lt.155.0) then
73                   yc(l,ic)= 10.0**(6.74756e0 - 585.0e0/(TEMP(l) - 18.16e0) ) &
74                        / PRESS(l) * 1013.25e0 / 760.0
75                 endif
76              endif
77
78              if(nomy(ic).eq."C2H6") then
79                 if (temp(l).lt.90.) then
80                   yc(l,ic)= 10.0**(10.01e0-1085.0e0/(TEMP(l)-0.561e0) )  &
81                        / PRESS(l) * 1013.25e0 / 760.0e0
82                 else
83                   yc(l,ic)= 10.0**(5.9366e0 - 1086.17e0/TEMP(l) + 3.83464e0 *  &
84                        alog10(1.0e3/TEMP(l)) ) / PRESS(l)*1013.25e0/760.0
85                 endif
86              endif
87
88              if((nomy(ic).eq."CH3CCH").or.(nomy(ic).eq."CH2CCH2")) then
89                 yc(l,ic)= 10.0**(2.8808e0 - 4.5e0*(249.9e0 - TEMP(l))   &
90                      /(1.15e0*TEMP(l) - 37.485e0) ) / PRESS(l) * 1013.25e0 / 760.0e0
91              endif
92
93              if(nomy(ic).eq."C3H6")  then
94                 yc(l,ic)= 10.0**(7.4463e0 - 1028.5654e0/TEMP(l) ) / PRESS(l) * 1013.25e0 / 760.0e0
95              endif
96
97              if(nomy(ic).eq."C3H8")  then
98                 yc(l,ic)= 10.0**(7.217e0 - 994.30251e0/TEMP(l) ) / PRESS(l) * 1013.25e0 / 760.0e0
99              endif
100
101              if((nomy(ic).eq."C4H2").or.(nomy(ic).eq."C4H2s")) then
102                 yc(l,ic)= 10.0**(96.26781e0 - 4651.872e0/TEMP(l) - 31.68595e0 &
103                      *alog10(TEMP(l)) ) / PRESS(l) * 1013.25e0 / 760.0e0
104              endif
105
106              if(nomy(ic).eq."C4H4")  then
107                 yc(l,ic)= 1.0e3 * exp(9.3898e0 - 2203.57/(TEMP(l)-43.15e0) ) / PRESS(l)
108              endif
109
110              if(nomy(ic).eq."C4H6")  then
111                 yc(l,ic)= 10.0**(2.8808e0 - 4.6e0*(262.3e0 - TEMP(l)) &
112                      /(1.15e0*TEMP(l) - 39.345e0) ) / PRESS(l) * 1013.25e0 / 760.0e0
113              endif
114
115              if(nomy(ic).eq."C4H10")  then
116                 yc(l,ic)= 10.0**(8.446e0 - 1461.2e0/TEMP(l) ) / PRESS(l) * 1013.25e0 / 760.0e0
117              endif
118
119              if(nomy(ic).eq."C6H2")  then
120                 yc(l,ic)= 10.0**(4.666e0 - 4956e0/TEMP(l) + 25.845e0 * &
121                      alog10(1.0e3/TEMP(l)) ) / PRESS(l) * 1013.25e0 / 760.0e0
122              endif
123
124              if(nomy(ic).eq."C8H2")  then
125                 yc(l,ic)= 10.0**(3.95e0 - 6613e0/TEMP(l) + 35.055e0 * &
126                      alog10(1.0e3/TEMP(l)) ) / PRESS(l) * 1013.25e0 / 760.0e0
127              endif
128
129              if(nomy(ic).eq."AC6H6")  then
130                 x = 1.0e0 - TEMP(l) / 562.2e0
131                 yc(l,ic)= 48.9e3 * exp( ( 1.33213 * x**1.5 - 6.98273 * x &
132                      - x**3 * (2.62863 + 3.33399 * x**3) ) * 562.2e0/TEMP(l) ) / PRESS(l)
133              endif
134
135              if(nomy(ic).eq."HCN")  then
136                 yc(l,ic)= 10.0**(8.6165e0 - 1516.5e0/(TEMP(l) - 26.2e0) ) / PRESS(l) * 1013.25e0 / 760.0e0
137              endif
138
139              if(nomy(ic).eq."CH3CN")  then
140                 yc(l,ic)= 10.0**(8.458e0 - 1911.7e0/TEMP(l) ) / PRESS(l) * 1013.25e0 / 760.0e0
141              endif
142
143              if(nomy(ic).eq."C2H3CN")  then
144                 yc(l,ic)= 10.0**(9.3051e0 - 2782.21/(TEMP(l) - 51.15e0) ) / PRESS(l) * 1013.25e0 / 760.0e0
145              endif
146
147              if(nomy(ic).eq."NCCN")  then
148                 yc(l,ic)=  10.0**(7.454e0 - 1832e0/TEMP(l) ) / PRESS(l) * 1013.25e0 / 760.0e0
149              endif
150
151              if(nomy(ic).eq."HC3N")  then
152                 yc(l,ic)= 10.0**(7.7446e0 - 1453.5609e0/TEMP(l) ) / PRESS(l) * 1013.25e0 / 760.0e0
153              endif
154
155              if(nomy(ic).eq."C4N2")  then
156                 yc(l,ic)= 10.0**(8.269e0 - 2155.0e0/TEMP(l) ) / PRESS(l) * 1013.25e0 / 760.0e0
157              endif
158
159           enddo
160       enddo
161
162       print*, 'inicondens end'
163       
164      end subroutine inicondens
Note: See TracBrowser for help on using the repository browser.